alert

Stacked alerts within a Frame

Stacked alerts within a Frame

Загрузка превью…

src/alert/c-alert-13.vue

<script setup lang="ts">
import { Alert, AlertAction, AlertDescription, AlertTitle } from "@/components/reui/alert"
import { Frame, FramePanel } from "@/components/reui/frame"
import { Button } from "@/components/ui/button"
</script>

<template>
  <div class="mx-auto mb-auto w-full max-w-lg">
    <Frame stacked>
      <FramePanel class="p-0!">
        <Alert variant="success" class="rounded-none border-0 shadow-none">
          <svg
            xmlns="http://www.w3.org/2000/svg"
            width="24"
            height="24"
            viewBox="0 0 24 24"
            fill="none"
            stroke="currentColor"
            stroke-width="2"
            stroke-linecap="round"
            stroke-linejoin="round"
            aria-hidden="true"
            class="lucide lucide-circle-check"
          >
            <circle cx="12" cy="12" r="10" />
            <path d="m9 12 2 2 4-4" />
          </svg>
          <AlertTitle>Deployment Successful</AlertTitle>
          <AlertDescription>
            Your application has been successfully deployed to the production
            environment.
          </AlertDescription>
        </Alert>
      </FramePanel>
      <FramePanel class="p-0!">
        <Alert variant="warning" class="rounded-none border-0 shadow-none">
          <svg
            xmlns="http://www.w3.org/2000/svg"
            width="24"
            height="24"
            viewBox="0 0 24 24"
            fill="none"
            stroke="currentColor"
            stroke-width="2"
            stroke-linecap="round"
            stroke-linejoin="round"
            aria-hidden="true"
            class="lucide lucide-triangle-alert text-yellow-500"
          >
            <path
              d="m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3"
            />
            <path d="M12 9v4" />
            <path d="M12 17h.01" />
          </svg>
          <AlertTitle>Resource Limit Reached</AlertTitle>
          <AlertAction>
            <Button size="xs">Verify</Button>
          </AlertAction>
          <AlertDescription>
            Your current plan has reached its resource limits. Consider
            upgrading to a higher tier.
          </AlertDescription>
        </Alert>
      </FramePanel>
    </Frame>
  </div>
</template>

Установка

npx shadcn-vue@latest add https://revueui.rootapi.dev/r/c-alert-13.json

Зависимости реестра

Источник: порт из ReUI (Keenthemes, MIT)