Skip to content

KErrorState

示例

Something went wrong

An error state placeholder with a retry button.

Props

NameTypeDefaultDescription
titlestring'Oops! Something went wrong'Heading text for the error state.
descriptionstringSecondary description text.
classstringAdditional CSS classes for the root element.
theme'auto' | 'day' | 'night''auto'Theme mode. auto follows the current theme; day and night force a specific mode.

Emits

NameParametersDescription
retryFired when the "Try Again" button is clicked.

Slots

NameDescription
This component does not provide slots.

Basic Usage

vue
<script setup>
import { KErrorState } from '@kK-2004/ui-component'
</script>

<template>
  <KErrorState
    title="Failed to load data"
    description="Check your network connection and try again."
    @retry="fetchData"
  />
</template>