Skip to main content

ColorPaletteItem

<ui5-color-palette-item> | Since 1.0.0-rc.12

The ui5-color-palette-item component represents a color in the the ui5-color-palette.

Properties​

selected​

DescriptionDefines if the component is selected.
Note: Only one item must be selected per ui5-color-palette. If more than one item is defined as selected, the last one would be considered as the selected one.
Typeboolean
Defaultfalse
Since2.0.0

tooltip​

DescriptionDefines the tooltip of the component. When not set, the color value is used as the tooltip.
Typestring | undefined
Defaultundefined
Since2.22.0

value​

DescriptionDefines the colour of the component.
Note: The value should be a valid CSS color.
Typestring
Default""

Slots​

No slots available for this component.

Events​

click​

DescriptionFired when the component is activated either with a mouse/tap or by using the Enter or Space key.
Note: The event will not be fired if the disabled property is set to true.
TypeCustomEvent<ColorPaletteItemNativeClickEventDetail>
ParametersoriginalEvent: Event
The original DOM event that triggered the click. Use this to access modifier keys (altKey, ctrlKey, metaKey, shiftKey) and other native event properties.
Since2.22.0
BubblesYes
CancelableYes - via preventDefault()

Methods​

No methods available for this component.

CSS Parts​

No CSS parts available for this component.

CSS Custom States​

No CSS custom states available for this component.