mirror of
https://github.com/unraid/api.git
synced 2026-01-21 16:09:39 -06:00
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit * **New Features** * Standalone web bundle with auto-mount utilities and a self-contained test page. * New responsive modal components for consistent mobile/desktop dialogs. * Header actions to copy OS/API versions. * **Improvements** * Refreshed UI styles (muted borders), accessibility and animation refinements. * Theming updates and Tailwind v4–aligned, component-scoped styles. * Runtime GraphQL endpoint override and CSRF header support. * **Bug Fixes** * Safer network fetching and improved manifest/asset loading with duplicate protection. * **Tests/Chores** * Parallel plugin tests, new extractor test suite, and updated build/test scripts. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
31 lines
1.1 KiB
Vue
31 lines
1.1 KiB
Vue
<script setup lang="ts">
|
|
// eslint-disable vue/no-v-html
|
|
import { storeToRefs } from 'pinia';
|
|
import type { ComposerTranslation } from 'vue-i18n';
|
|
|
|
import { useErrorsStore } from '~/store/errors';
|
|
import type { UserProfileLink } from '~/types/userProfile';
|
|
import UpcDropdownItem from './DropdownItem.vue';
|
|
|
|
defineProps<{ t: ComposerTranslation; }>();
|
|
|
|
const errorsStore = useErrorsStore();
|
|
const { errors } = storeToRefs(errorsStore);
|
|
</script>
|
|
|
|
<template>
|
|
<ul v-if="errors.length" class="list-reset flex flex-col gap-y-2 mb-1 border-2 border-solid border-muted rounded-md">
|
|
<li v-for="(error, index) in errors" :key="index" class="flex flex-col gap-2">
|
|
<h3 class="text-lg py-1 px-3 text-white bg-unraid-red/90 font-semibold">
|
|
<span>{{ t(error.heading) }}</span>
|
|
</h3>
|
|
<div class="text-sm px-3 flex flex-col gap-y-2" :class="{ 'pb-2': !error.actions }" v-html="t(error.message)" />
|
|
<nav v-if="error.actions">
|
|
<li v-for="(link, idx) in error.actions" :key="`link_${idx}`">
|
|
<UpcDropdownItem :item="link as UserProfileLink" :rounded="false" :t="t" />
|
|
</li>
|
|
</nav>
|
|
</li>
|
|
</ul>
|
|
</template>
|