diff --git a/src/display/change/stroke-style.js b/src/display/change/stroke-style.js index 5cdb62fd..6a5d8df5 100644 --- a/src/display/change/stroke-style.js +++ b/src/display/change/stroke-style.js @@ -1,3 +1,4 @@ +import { getColor } from '../../utils/get'; import { selector } from '../../utils/selector/selector'; import { updateConfig } from './utils'; @@ -5,6 +6,10 @@ export const changeStrokeStyle = (object, { strokeStyle, links }) => { const path = selector(object, '$.children[?(@.type==="path")]')[0]; if (!path) return; + if ('color' in strokeStyle) { + strokeStyle.color = getColor(strokeStyle.color); + } + path.setStrokeStyle({ ...path.strokeStyle, ...strokeStyle }); if (!links && path.links.length > 0) { reRenderPath(path);