diff --git a/src/components/ColorPicker.vue b/src/components/ColorPicker.vue
index 0e087cb0d..6e55d6304 100644
--- a/src/components/ColorPicker.vue
+++ b/src/components/ColorPicker.vue
@@ -2,7 +2,7 @@
import { ref, computed, watch } from 'vue'
import { PopoverRoot, PopoverTrigger, PopoverPortal, PopoverContent } from 'reka-ui'
-import { colorToHex, parseColor } from '../engine/color'
+import { colorToHexRaw, parseColor } from '../engine/color'
import type { Color } from '../types'
@@ -74,7 +74,7 @@ function emitColor() {
}
const hexValue = computed(() => {
- return colorToHex(props.color).slice(1)
+ return colorToHexRaw(props.color)
})
function onHexInput(e: Event) {
diff --git a/src/components/properties/FillSection.vue b/src/components/properties/FillSection.vue
index be4643afc..f76e7f720 100644
--- a/src/components/properties/FillSection.vue
+++ b/src/components/properties/FillSection.vue
@@ -2,17 +2,13 @@
import ColorPicker from '../ColorPicker.vue'
import { useEditorStore } from '../../stores/editor'
import { DEFAULT_SHAPE_FILL } from '../../constants'
-import { colorToHex, parseColor } from '../../engine/color'
+import { colorToHexRaw, parseColor } from '../../engine/color'
import type { Color, Fill } from '../../engine/scene-graph'
const props = defineProps<{ nodeId: string; fills: Fill[] }>()
const store = useEditorStore()
-function hexString(c: Color) {
- return colorToHex(c).slice(1).toUpperCase()
-}
-
function updateColor(index: number, color: Color) {
const fills = [...props.fills]
fills[index] = { ...fills[index], color }
@@ -56,7 +52,7 @@ function remove(index: number) {
import ColorPicker from '../ColorPicker.vue'
import { useEditorStore } from '../../stores/editor'
-import { colorToHex, parseColor } from '../../engine/color'
+import { colorToHexRaw, parseColor } from '../../engine/color'
import type { Color, Stroke } from '../../engine/scene-graph'
const props = defineProps<{ nodeId: string; strokes: Stroke[] }>()
const store = useEditorStore()
-function hexString(c: Color) {
- return colorToHex(c).slice(1).toUpperCase()
-}
-
function updateColor(index: number, color: Color) {
const strokes = [...props.strokes]
strokes[index] = { ...strokes[index], color }
@@ -62,7 +58,7 @@ function remove(index: number) {