diff --git a/components/lib/button/BaseButton.vue b/components/lib/button/BaseButton.vue index 43525ca75..74ff2dc58 100644 --- a/components/lib/button/BaseButton.vue +++ b/components/lib/button/BaseButton.vue @@ -32,7 +32,7 @@ export default { }, badgeSeverity: { type: String, - default: null + default: 'secondary' }, loading: { type: Boolean, diff --git a/components/lib/button/style/ButtonStyle.js b/components/lib/button/style/ButtonStyle.js index bbb5ad0c5..74d5311d0 100644 --- a/components/lib/button/style/ButtonStyle.js +++ b/components/lib/button/style/ButtonStyle.js @@ -16,7 +16,8 @@ const theme = ({ dt }) => ` font-size: 1rem; font-family: inherit; font-feature-settings: inherit; - transition: background ${dt('button.transition.duration')}, color ${dt('button.transition.duration')}, border-color ${dt('button.transition.duration')}, outline-color ${dt('button.transition.duration')}, box-shadow ${dt('button.transition.duration')}; + transition: background ${dt('button.transition.duration')}, color ${dt('button.transition.duration')}, border-color ${dt('button.transition.duration')}, + outline-color ${dt('button.transition.duration')}, box-shadow ${dt('button.transition.duration')}; border-radius: ${dt('button.border.radius')}; outline-color: transparent; gap: ${dt('button.gap')}; @@ -99,11 +100,9 @@ const theme = ({ dt }) => ` } .p-button .p-badge { - min-width: 1rem; - height: 1rem; - line-height: 1rem; - background: ${dt('button.primary.color')}; - color: ${dt('button.primary.background')}; + min-width: ${dt('button.badge.size')}; + height: ${dt('button.badge.size')}; + line-height: ${dt('button.badge.size')}; } .p-button-raised { diff --git a/components/lib/themes/aura/button/index.js b/components/lib/themes/aura/button/index.js index ea3d027b3..790f5ad2c 100644 --- a/components/lib/themes/aura/button/index.js +++ b/components/lib/themes/aura/button/index.js @@ -25,6 +25,7 @@ export default { style: '{focus.ring.style}', offset: '{focus.ring.offset}' }, + badgeSize: '1rem', transitionDuration: '{form.field.transition.duration}' }, colorScheme: { diff --git a/components/lib/themes/lara/button/index.js b/components/lib/themes/lara/button/index.js index 701c691bb..36d5f0e54 100644 --- a/components/lib/themes/lara/button/index.js +++ b/components/lib/themes/lara/button/index.js @@ -25,6 +25,7 @@ export default { style: '{form.field.focus.ring.style}', offset: '{form.field.focus.ring.offset}' }, + badgeSize: '1rem', transitionDuration: '{form.field.transition.duration}' }, colorScheme: { diff --git a/components/lib/themes/nora/button/index.js b/components/lib/themes/nora/button/index.js index 927336a99..62a35d105 100644 --- a/components/lib/themes/nora/button/index.js +++ b/components/lib/themes/nora/button/index.js @@ -25,6 +25,7 @@ export default { style: '{focus.ring.style}', offset: '{focus.ring.offset}' }, + badgeSize: '1rem', transitionDuration: '{form.field.transition.duration}' }, colorScheme: { diff --git a/doc/badge/ButtonDoc.vue b/doc/badge/ButtonDoc.vue index 12a1854ed..ed48c9969 100644 --- a/doc/badge/ButtonDoc.vue +++ b/doc/badge/ButtonDoc.vue @@ -2,9 +2,9 @@

Buttons have built-in support for badges to display a badge inline.

-
-
@@ -15,14 +15,14 @@ export default { return { code: { basic: ` -