mirror of
https://github.com/zyycn/codex-proxy-rs.git
synced 2026-12-03 08:01:10 +00:00
Use a shared 24px square help trigger for request settings and automatic approval details. Align the UI dependency and submodule with the disabled link background fix. Co-authored-by: Codex <noreply@openai.com>
23 lines
869 B
Vue
23 lines
869 B
Vue
<script setup lang="ts">
|
|
import { ZIconButton, ZPopover } from '@codex-proxy/ui'
|
|
import { CircleAlert } from '@lucide/vue'
|
|
import { useMediaQuery } from '@vueuse/core'
|
|
|
|
defineProps<{ label: string, content?: string }>()
|
|
|
|
const canHover = useMediaQuery('(hover: hover)')
|
|
</script>
|
|
|
|
<template>
|
|
<ZPopover class="h-4 items-center" :trigger="canHover ? 'hover-click' : 'click'" placement="top-start" :hover-delay="240">
|
|
<template #reference="{ open }">
|
|
<ZIconButton variant="link" size="small" class="size-6!" :aria-label="label" :aria-expanded="open" aria-haspopup="dialog">
|
|
<CircleAlert class="size-3" aria-hidden="true" />
|
|
</ZIconButton>
|
|
</template>
|
|
<section role="dialog" :aria-label="label" class="max-w-72 p-3 text-z-xs leading-relaxed text-z-text-secondary">
|
|
<slot>{{ content }}</slot>
|
|
</section>
|
|
</ZPopover>
|
|
</template>
|