Skip to content

Commit

Permalink
fix(NcDialog): Add slighly more padding on the bottom and fix example…
Browse files Browse the repository at this point in the history
… button order

Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
  • Loading branch information
susnux committed Nov 29, 2023
1 parent d4bcd4c commit 5b44909
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions src/components/NcDialog/NcDialog.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,16 +44,16 @@ export default {
showDialog: false,
lastResponse: 'None',
buttons: [
{
label: 'Cancel',
icon: IconCancel,
callback: () => { this.lastResponse = 'Pressed "Cancel"' },
},
{
label: 'Ok',
type: 'primary',
icon: IconCheck,
callback: () => { this.lastResponse = 'Pressed "Ok"' },
},
{
label: 'Cancel',
icon: IconCancel,
callback: () => { this.lastResponse = 'Pressed "Cancel"' },
}
]
}
Expand Down Expand Up @@ -106,7 +106,9 @@ export default {
<!-- Main dialog content -->
<div class="dialog__content" :class="contentClasses">
<slot>
<p>{{ message }}</p>
<p class="dialog__text">
{{ message }}
</p>
</slot>
</div>
</div>
Expand Down Expand Up @@ -442,6 +444,12 @@ export default defineComponent({
overflow: auto;
}

// In case only text content is show
&__text {
// Also add padding to the bottom to make it more readable
padding-block-end: 6px;
}

&__actions {
display: flex;
gap: 6px;
Expand Down

0 comments on commit 5b44909

Please sign in to comment.