feat: align BaseTooltip with Figma design, add Storybook, fix as-child nesting

- Update tooltip variants: shadow-interface, leading-none, export FOR_STORIES
- Add keybind and showIcon props to BaseTooltip per Figma design spec
- Add comprehensive Storybook stories for all tooltip variants
- Fix Popover + BaseTooltip as-child nesting conflict in
  JobHistoryActionsMenu and JobFilterActions by moving BaseTooltip
  outside the Popover #button slot

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
dante01yoon
2026-03-24 21:44:44 +09:00
parent 77105602c0
commit 30e4b443d1
5 changed files with 388 additions and 166 deletions

View File

@@ -18,6 +18,8 @@ const {
side = 'top',
sideOffset = 4,
size = 'small',
keybind,
showIcon = false,
delayDuration,
disabled = false,
class: className
@@ -26,6 +28,8 @@ const {
side?: 'top' | 'bottom' | 'left' | 'right'
sideOffset?: number
size?: NonNullable<TooltipVariants['size']>
keybind?: string
showIcon?: boolean
delayDuration?: number
disabled?: boolean
class?: HTMLAttributes['class']
@@ -43,7 +47,23 @@ const {
:side-offset="sideOffset"
:class="cn(tooltipVariants({ size }), className)"
>
{{ text }}
<span
v-if="keybind || (showIcon && size === 'small')"
class="inline-flex items-center gap-2"
>
<span>{{ text }}</span>
<i
v-if="showIcon && size === 'small'"
class="icon-[lucide--chevron-right] size-4 shrink-0"
/>
<span
v-if="keybind"
class="shrink-0 rounded-sm bg-interface-menu-keybind-surface-default px-1 text-xs leading-none"
>
{{ keybind }}
</span>
</span>
<template v-else>{{ text }}</template>
<TooltipArrow
:width="8"
:height="5"