Files
artchat/app/components/chat/Typing.vue
Arthur DANJOU 3fa4f574d3 refactor: update ESLint configuration and remove unused dependencies
- Replaced Nuxt ESLint configuration with Antfu's ESLint config.
- Removed 'nuxt-visitors' module from Nuxt configuration.
- Added linting scripts to package.json for easier code quality checks.
- Introduced a new API endpoint for fetching weather data from OpenWeather.
- Enhanced chat types with new enums and properties for better state management.
- Added OpenWeather response types for improved type safety.
- Updated social links in types/index.ts to include an email contact.
2025-09-02 17:45:01 +02:00

35 lines
712 B
Vue

<script setup lang="ts">
const children = ref<HTMLElement[]>([])
const shown = ref<HTMLElement[]>([])
const container = ref<HTMLElement | null>(null)
onMounted(async () => {
if (!container.value)
return
children.value = Array.from(container.value.children) as HTMLElement[]
for (const child of children.value) {
shown.value.push(child)
await new Promise(resolve => setTimeout(resolve, 400))
}
})
</script>
<template>
<div>
<div ref="container" class="hidden">
<slot />
</div>
<div>
<component
:is="el.tagName.toLowerCase()"
v-for="(el, index) in shown"
:key="index"
v-html="el.innerHTML"
/>
</div>
</div>
</template>