diff --git a/packages/uui-color-swatch/lib/uui-color-swatch.element.ts b/packages/uui-color-swatch/lib/uui-color-swatch.element.ts
index aa52fa2f2..c6d48d09f 100644
--- a/packages/uui-color-swatch/lib/uui-color-swatch.element.ts
+++ b/packages/uui-color-swatch/lib/uui-color-swatch.element.ts
@@ -129,7 +129,7 @@ export class UUIColorSwatchElement extends LabelMixin(
html`
${repeat(args.swatches, (swatch: any) => {
+ label="My color palette">${repeat(args.swatches, (swatch: any) => {
const label = typeof swatch === 'string' ? swatch : swatch.label;
const value = typeof swatch === 'string' ? swatch : swatch.value;
+ const color = typeof swatch === 'string' ? swatch : swatch.color;
return html`
`;
+ .color="${color}"
+ .value=${value}>
+ `;
})}
`,
@@ -72,3 +114,11 @@ export const ShowLabel: Story = {
showLabel: true,
},
};
+
+export const Gradient: Story = {
+ args: {
+ swatches: gradients,
+ showLabel: true,
+ value: 'lemon-twist',
+ },
+};