From b7b543fda0c228b2c95b1dd180a20df6d115752a Mon Sep 17 00:00:00 2001 From: Joost De Cock Date: Wed, 13 Sep 2023 11:58:00 +0200 Subject: [PATCH] fix(react-components): Accept data-render-always attributes on points --- packages/react-components/src/pattern/point.mjs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/packages/react-components/src/pattern/point.mjs b/packages/react-components/src/pattern/point.mjs index 2e4f8d6ffcf..3e9c2784ff2 100644 --- a/packages/react-components/src/pattern/point.mjs +++ b/packages/react-components/src/pattern/point.mjs @@ -3,8 +3,11 @@ import React from 'react' import { withinPartBounds } from './utils.mjs' export const Point = ({ stackName, partName, pointName, part, point, components, t }) => { - // Don't include points outside the part bounding box - if (!withinPartBounds(point, part)) return null + /* + * Don't include points outside the part bounding box + * Unless the `data-render-always` attribute is set + */ + if (!withinPartBounds(point, part) && !point.attributes.list['data-render-always']) return null // Get potentially swizzled components const { Circle, Text } = components