mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-18 05:58:07 +01:00
fix(Tooltip): missing conditions on slots
This commit is contained in:
@@ -57,11 +57,11 @@ const ui = computed(() => tv({ extend: tooltip, slots: props.ui })())
|
||||
<TooltipPortal :disabled="!portal">
|
||||
<TooltipContent v-bind="contentProps" :class="ui.content({ class: props.class })">
|
||||
<slot name="content">
|
||||
<span v-if="text" :class="ui.text()">
|
||||
<span v-if="text || $slots.text" :class="ui.text()">
|
||||
<slot name="text">{{ text }}</slot>
|
||||
</span>
|
||||
|
||||
<span v-if="shortcuts?.length" :class="ui.shortcuts()">
|
||||
<span v-if="shortcuts?.length || $slots.shortcuts" :class="ui.shortcuts()">
|
||||
<slot name="shortcuts">
|
||||
<UKbd v-for="(shortcut, index) in shortcuts" :key="index" size="xs" v-bind="typeof shortcut === 'string' ? { value: shortcut } : shortcut" />
|
||||
</slot>
|
||||
|
||||
Reference in New Issue
Block a user