refactor: migrate to nuxt compatibilityVersion: 4 (#3298)

This commit is contained in:
Daniel Roe 2025-05-20 15:05:01 +01:00 committed by GitHub
parent 46e4433e1c
commit a3fbc056a9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
342 changed files with 1200 additions and 2932 deletions

View file

@ -1,38 +0,0 @@
<script setup lang="ts">
import type { AriaLive } from '~/composables/aria'
const {
ariaLive = 'polite',
heading = 'h2',
messageKey = (message: any) => message,
} = defineProps<{
ariaLive?: AriaLive
heading?: 'h2' | 'h3' | 'h4' | 'h5' | 'h6'
title: string
messageKey?: (message: any) => any
}>()
const { announceLogs, appendLogs, clearLogs, logs } = useAriaLog()
defineExpose({
announceLogs,
appendLogs,
clearLogs,
})
</script>
<template>
<slot />
<div sr-only role="log" :aria-live="ariaLive">
<component :is="heading">
{{ title }}
</component>
<ul>
<li v-for="log in logs" :key="messageKey(log)">
<slot name="log" :log="log">
{{ log }}
</slot>
</li>
</ul>
</div>
</template>