Badge Theming

Theming documentation for badge component

Styled#

Badge CSS Classes#

List of class names used in the styled mode.

classNamedescription
p-badgeClass name of the root element

OverlayBadge CSS Classes#

List of class names used in the styled mode.

classNamedescription
p-overlaybadgeClass name of the root element

Design Tokens#

List of design tokens.

tokenCSS Variabledescription
badge.border.radius
--p-badge-border-radius
Border radius of root
badge.padding
--p-badge-padding
Padding of root
badge.font.size
--p-badge-font-size
Font size of root
badge.font.weight
--p-badge-font-weight
Font weight of root
badge.min.width
--p-badge-min-width
Min width of root
badge.height
--p-badge-height
Height of root
badge.dot.size
--p-badge-dot-size
Size of dot
badge.sm.font.size
--p-badge-sm-font-size
Font size of sm
badge.sm.min.width
--p-badge-sm-min-width
Min width of sm
badge.sm.height
--p-badge-sm-height
Height of sm
badge.lg.font.size
--p-badge-lg-font-size
Font size of lg
badge.lg.min.width
--p-badge-lg-min-width
Min width of lg
badge.lg.height
--p-badge-lg-height
Height of lg
badge.xl.font.size
--p-badge-xl-font-size
Font size of xl
badge.xl.min.width
--p-badge-xl-min-width
Min width of xl
badge.xl.height
--p-badge-xl-height
Height of xl
badge.primary.background
--p-badge-primary-background
Background of primary
badge.primary.color
--p-badge-primary-color
Color of primary
badge.secondary.background
--p-badge-secondary-background
Background of secondary
badge.secondary.color
--p-badge-secondary-color
Color of secondary
badge.success.background
--p-badge-success-background
Background of success
badge.success.color
--p-badge-success-color
Color of success
badge.info.background
--p-badge-info-background
Background of info
badge.info.color
--p-badge-info-color
Color of info
badge.warn.background
--p-badge-warn-background
Background of warn
badge.warn.color
--p-badge-warn-color
Color of warn
badge.danger.background
--p-badge-danger-background
Background of danger
badge.danger.color
--p-badge-danger-color
Color of danger
badge.contrast.background
--p-badge-contrast-background
Background of contrast
badge.contrast.color
--p-badge-contrast-color
Color of contrast

Unstyled#

Theming is implemented with the pass through properties in unstyled mode.