Skip to content

Commit

Permalink
fix(Alert/Notification): use div for description
Browse files Browse the repository at this point in the history
Resolves #1551
  • Loading branch information
benjamincanac committed Jun 13, 2024
1 parent f65aefb commit e8898d1
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/runtime/components/elements/Alert.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,11 @@
{{ title }}
</slot>
</p>
<p v-if="description || $slots.description" :class="twMerge(ui.description, !(title && $slots.title) && 'mt-0 leading-5')">
<div v-if="description || $slots.description" :class="twMerge(ui.description, !(title && $slots.title) && 'mt-0 leading-5')">
<slot name="description" :description="description">
{{ description }}
</slot>
</p>
</div>

<div v-if="(description || $slots.description) && (actions.length || $slots.actions)" :class="ui.actions">
<slot name="actions">
Expand Down
4 changes: 2 additions & 2 deletions src/runtime/components/overlays/Notification.vue
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@
{{ title }}
</slot>
</p>
<p v-if="(description || $slots.description)" :class="twMerge(ui.description, !(title && $slots.title) && 'mt-0 leading-5')">
<div v-if="(description || $slots.description)" :class="twMerge(ui.description, !(title && $slots.title) && 'mt-0 leading-5')">
<slot name="description" :description="description">
{{ description }}
</slot>
</p>
</div>

<div v-if="(description || $slots.description) && actions.length" :class="ui.actions">
<UButton v-for="(action, index) of actions" :key="index" v-bind="{ ...(ui.default.actionButton || {}), ...action }" @click.stop="onAction(action)" />
Expand Down

0 comments on commit e8898d1

Please sign in to comment.