diff --git a/packages/uui-color-picker/lib/uui-color-picker.element.ts b/packages/uui-color-picker/lib/uui-color-picker.element.ts index f97716da4..4de94086e 100644 --- a/packages/uui-color-picker/lib/uui-color-picker.element.ts +++ b/packages/uui-color-picker/lib/uui-color-picker.element.ts @@ -379,7 +379,7 @@ export class UUIColorPickerElement extends LabelMixin('label', LitElement) { this.hue = h; this.saturation = s; this.lightness = l; - this.alpha = this.opacity ? a * 100 : 100; + this.alpha = this.opacity != undefined ? a * 100 : 100; const hslaColor = colorString as HslaColor; @@ -395,7 +395,6 @@ export class UUIColorPickerElement extends LabelMixin('label', LitElement) { this.dispatchEvent( new UUIColorPickerChangeEvent(UUIColorPickerChangeEvent.CHANGE), ); - return true; } diff --git a/packages/uui-color-picker/lib/uui-color-picker.story.ts b/packages/uui-color-picker/lib/uui-color-picker.story.ts index 50964b038..48336f6b5 100644 --- a/packages/uui-color-picker/lib/uui-color-picker.story.ts +++ b/packages/uui-color-picker/lib/uui-color-picker.story.ts @@ -73,6 +73,7 @@ export const Inline: Story = { export const Opacity: Story = { args: { opacity: true, + value: undefined, inline: true, }, };