mirror of
https://github.com/lukaszraczylo/ghtracker.git
synced 2026-10-13 00:48:42 +00:00
Alerts that match a configured action get a button labelled from the config. A confirm dialog opens first when the action defines confirm text. After a press the UI posts the alert, reloads the state through the existing poll path and shows the reported status as a chip, with an anchor when the status carries a link. The alert dialog comes from reka-ui through the usual shadcn-vue wrappers.
23 lines
665 B
Vue
23 lines
665 B
Vue
<script setup lang="ts">
|
|
import type { AlertDialogTitleProps } from 'reka-ui'
|
|
import type { HTMLAttributes } from 'vue'
|
|
import { reactiveOmit } from '@vueuse/core'
|
|
import { AlertDialogTitle, useForwardProps } from 'reka-ui'
|
|
import { cn } from '@/lib/utils'
|
|
|
|
const props = defineProps<AlertDialogTitleProps & { class?: HTMLAttributes['class'] }>()
|
|
|
|
const delegatedProps = reactiveOmit(props, 'class')
|
|
const forwardedProps = useForwardProps(delegatedProps)
|
|
</script>
|
|
|
|
<template>
|
|
<AlertDialogTitle
|
|
data-slot="alert-dialog-title"
|
|
v-bind="forwardedProps"
|
|
:class="cn('text-lg font-semibold', props.class)"
|
|
>
|
|
<slot />
|
|
</AlertDialogTitle>
|
|
</template>
|