From f4298abe0dabebc0d8bcf116883986106119b089 Mon Sep 17 00:00:00 2001 From: Bohdan Imiela Date: Wed, 27 Nov 2024 12:55:01 +0100 Subject: [PATCH] feat: track repeat prop of new link field added --- packages/manager/src/managers/telemetry/types.ts | 1 + .../src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx | 1 + .../src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx | 1 + .../legacy/lib/models/common/widgets/Group/ListItem/index.jsx | 1 + 4 files changed, 4 insertions(+) diff --git a/packages/manager/src/managers/telemetry/types.ts b/packages/manager/src/managers/telemetry/types.ts index 9fe6aa855..9d0f64d15 100644 --- a/packages/manager/src/managers/telemetry/types.ts +++ b/packages/manager/src/managers/telemetry/types.ts @@ -207,6 +207,7 @@ type FieldAddedSegmentEvent = SegmentEvent< isInAGroup: boolean; contentType: "page type" | "custom type" | "slice"; allowText?: boolean; + repeat?: boolean; } >; diff --git a/packages/slice-machine/src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx b/packages/slice-machine/src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx index 5d8a5037c..596f61952 100644 --- a/packages/slice-machine/src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx +++ b/packages/slice-machine/src/legacy/lib/builders/CustomTypeBuilder/TabZone/index.tsx @@ -149,6 +149,7 @@ const TabZone: FC = ({ tabId }) => { contentType: getContentTypeForTracking(window.location.pathname), ...(newField.type === "Link" && { allowText: newField.config?.allowText, + repeat: newField.config?.repeat, }), }); }; diff --git a/packages/slice-machine/src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx b/packages/slice-machine/src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx index 19575b74d..43e902349 100644 --- a/packages/slice-machine/src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx +++ b/packages/slice-machine/src/legacy/lib/builders/SliceBuilder/FieldZones/index.tsx @@ -168,6 +168,7 @@ const FieldZones: FC = () => { contentType: getContentTypeForTracking(window.location.pathname), ...(newField.type === "Link" && { allowText: newField.config?.allowText, + repeat: newField.config?.repeat, }), }); }; diff --git a/packages/slice-machine/src/legacy/lib/models/common/widgets/Group/ListItem/index.jsx b/packages/slice-machine/src/legacy/lib/models/common/widgets/Group/ListItem/index.jsx index 3282ee4ea..0bcb3dae9 100644 --- a/packages/slice-machine/src/legacy/lib/models/common/widgets/Group/ListItem/index.jsx +++ b/packages/slice-machine/src/legacy/lib/models/common/widgets/Group/ListItem/index.jsx @@ -78,6 +78,7 @@ export const CustomListItem = ({ contentType: getContentTypeForTracking(window.location.pathname), ...(newField.type === "Link" && { allowText: newField.config?.allowText, + repeat: newField.config?.repeat, }), }); };