diff --git a/common/changes/@visactor/vrender/develop_2023-08-29-07-53.json b/common/changes/@visactor/vrender/develop_2023-08-29-07-53.json new file mode 100644 index 000000000..f062e1c47 --- /dev/null +++ b/common/changes/@visactor/vrender/develop_2023-08-29-07-53.json @@ -0,0 +1,10 @@ +{ + "changes": [ + { + "packageName": "@visactor/vrender", + "comment": "fix: fix the issue of area stroke, closed #392", + "type": "patch" + } + ], + "packageName": "@visactor/vrender" +} \ No newline at end of file diff --git a/packages/vrender/src/render/contributions/render/area-render.ts b/packages/vrender/src/render/contributions/render/area-render.ts index f6242503b..a28e8780c 100644 --- a/packages/vrender/src/render/contributions/render/area-render.ts +++ b/packages/vrender/src/render/contributions/render/area-render.ts @@ -574,7 +574,7 @@ export class DefaultCanvasAreaRender implements IGraphicRender { if (strokeCb) { strokeCb(context, attribute, defaultAttribute); } else { - const { stroke } = attribute; + const { stroke = defaultAttribute && defaultAttribute[1] && defaultAttribute[1].stroke } = attribute; if (isArray(stroke) && (stroke[0] || stroke[2]) && stroke[1] === false) { context.beginPath(); drawSegments(