diff --git a/packages/builder/src/components/userInterface/Colorpicker/components/Colorpicker.svelte b/packages/builder/src/components/userInterface/Colorpicker/components/Colorpicker.svelte index 254dc1f288..7fa536a474 100644 --- a/packages/builder/src/components/userInterface/Colorpicker/components/Colorpicker.svelte +++ b/packages/builder/src/components/userInterface/Colorpicker/components/Colorpicker.svelte @@ -154,7 +154,7 @@ } function removeSwatch(idx) { - let removedSwatch = swatches.splice(idx, 1); + let [removedSwatch] = swatches.splice(idx, 1); swatches = swatches; dispatch("removeswatch", removedSwatch); if (swatchesSetFromLocalStore) { diff --git a/packages/builder/src/components/userInterface/Colorpicker/components/Colorpreview.svelte b/packages/builder/src/components/userInterface/Colorpicker/components/Colorpreview.svelte index f3ab6f6f22..2d9426fbae 100644 --- a/packages/builder/src/components/userInterface/Colorpicker/components/Colorpreview.svelte +++ b/packages/builder/src/components/userInterface/Colorpicker/components/Colorpreview.svelte @@ -114,8 +114,6 @@ cursor: pointer; border-radius: 3px; border: 1px solid #dedada; - position: absolute; - left: 110px; } .preview-error { diff --git a/packages/builder/src/components/userInterface/Colorpicker/components/Swatch.svelte b/packages/builder/src/components/userInterface/Colorpicker/components/Swatch.svelte index 11bd4d3821..e56e6d0b6f 100644 --- a/packages/builder/src/components/userInterface/Colorpicker/components/Swatch.svelte +++ b/packages/builder/src/components/userInterface/Colorpicker/components/Swatch.svelte @@ -1,39 +1,15 @@ -
- -
dispatch('click') }} - in:fade - title={color} - class="swatch" - style={`background: ${color};`} - on:click|self - on:mouseover={() => (hovered = true)} - on:mouseleave={() => (hovered = false)}> - {#if hovered} -
dispatch('removeswatch')}> - dispatch('removeswatch')}>× -
- {/if} -
-
-
- + +
+ +
dispatch('click') }} + in:fade + title={color} + class="swatch" + style={`background: ${color};`} + on:mouseover={() => (hovered = true)} + on:mouseleave={() => (hovered = false)} + on:click|self> + {#if hovered} + dispatch('removeswatch')} /> + {/if} +
+
+