@useinsider/guido 3.19.0-beta.80b64cf → 3.19.0-beta.84c97db

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (110) hide show
  1. package/dist/@types/config/schemas.js +9 -8
  2. package/dist/components/Guido.vue.js +8 -8
  3. package/dist/components/Guido.vue2.js +104 -86
  4. package/dist/components/organisms/AutoSaveController.vue2.js +18 -8
  5. package/dist/components/organisms/base/AuthErrorModal.vue.js +18 -0
  6. package/dist/components/organisms/base/AuthErrorModal.vue2.js +42 -0
  7. package/dist/components/organisms/header/AutoSaveStatus.vue.js +17 -0
  8. package/dist/components/organisms/header/AutoSaveStatus.vue2.js +25 -0
  9. package/dist/components/organisms/header/EditorActions.vue.js +13 -13
  10. package/dist/components/organisms/header/EditorActions.vue2.js +37 -52
  11. package/dist/components/organisms/header/EditorActionsMenu.vue.js +20 -0
  12. package/dist/components/organisms/header/EditorActionsMenu.vue2.js +98 -0
  13. package/dist/components/organisms/header/HeaderWrapper.vue.js +6 -6
  14. package/dist/components/organisms/header/HeaderWrapper.vue2.js +9 -17
  15. package/dist/components/organisms/header/LeftSlot.vue.js +5 -5
  16. package/dist/components/organisms/header/LeftSlot.vue2.js +32 -23
  17. package/dist/components/organisms/header/MiddleSlot.vue.js +4 -4
  18. package/dist/components/organisms/header/MiddleSlot.vue2.js +8 -7
  19. package/dist/components/organisms/header/RightSlot.vue.js +9 -8
  20. package/dist/components/organisms/header/RightSlot.vue2.js +13 -18
  21. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue.js +18 -0
  22. package/dist/components/organisms/header/accessibility/AccessibilityToolbar.vue2.js +37 -0
  23. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue.js +22 -0
  24. package/dist/components/organisms/header/accessibility/ColorVisionSelect.vue2.js +48 -0
  25. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue.js +19 -0
  26. package/dist/components/organisms/onboarding/EditorTabBarOnboarding.vue2.js +90 -0
  27. package/dist/components/organisms/onboarding/OnboardingWrapper.vue.js +12 -12
  28. package/dist/components/organisms/onboarding/OnboardingWrapper.vue2.js +56 -38
  29. package/dist/components/wrappers/WpModal.vue.js +1 -1
  30. package/dist/components/wrappers/WpModal.vue2.js +4 -3
  31. package/dist/composables/useAccessibilityApi.js +45 -0
  32. package/dist/composables/useAuthError.js +52 -0
  33. package/dist/composables/useAutoSave.js +11 -11
  34. package/dist/composables/useCortexBlueprintBridge.js +122 -54
  35. package/dist/composables/useCustomInterfaceAppearance.js +42 -41
  36. package/dist/composables/useEmailTemplateApplier.js +111 -50
  37. package/dist/composables/useHttp.js +64 -54
  38. package/dist/composables/useLegacyStrategyConversion.js +23 -19
  39. package/dist/composables/useStripo.js +24 -20
  40. package/dist/composables/useToaster.js +17 -15
  41. package/dist/composables/validators/useLiquidValidator.js +15 -15
  42. package/dist/config/i18n/en/labels.json.js +36 -4
  43. package/dist/config/i18n/en/tooltips.json.js +2 -1
  44. package/dist/config/migrator/index.js +14 -13
  45. package/dist/config/migrator/itemsBlockMigrator.js +236 -248
  46. package/dist/config/migrator/recommendationMigrator.js +28 -21
  47. package/dist/config/migrator/recommendationPartnerMigrator.js +56 -0
  48. package/dist/enums/extensions/recommendationBlock.js +30 -29
  49. package/dist/extensions/Blocks/Items/constants/cardLayout.js +20 -0
  50. package/dist/extensions/Blocks/Items/controls/name/trimming.js +18 -17
  51. package/dist/extensions/Blocks/Items/controls/settingsControl.js +114 -105
  52. package/dist/extensions/Blocks/Items/enums/productEnums.js +14 -9
  53. package/dist/extensions/Blocks/Items/layouts/horizontal.html.js +11 -9
  54. package/dist/extensions/Blocks/Items/template.js +219 -204
  55. package/dist/extensions/Blocks/Recommendation/block.js +54 -88
  56. package/dist/extensions/Blocks/Recommendation/store/recommendation.js +32 -51
  57. package/dist/extensions/Blocks/Recommendation/utils/partnerScope.js +11 -12
  58. package/dist/guido.css +1 -1
  59. package/dist/sprite.svg +10 -0
  60. package/dist/src/@types/config/schemas.d.ts +2 -0
  61. package/dist/src/components/organisms/AutoSaveController.vue.d.ts +3 -1
  62. package/dist/src/components/organisms/header/AutoSaveStatus.vue.d.ts +2 -0
  63. package/dist/src/components/organisms/header/EditorActionsMenu.vue.d.ts +2 -0
  64. package/dist/src/components/organisms/header/HeaderWrapper.vue.d.ts +1 -3
  65. package/dist/src/components/organisms/header/RightSlot.vue.d.ts +1 -3
  66. package/dist/src/components/organisms/header/accessibility/AccessibilityToolbar.vue.d.ts +2 -0
  67. package/dist/src/components/organisms/header/accessibility/ColorVisionSelect.vue.d.ts +2 -0
  68. package/dist/src/components/organisms/onboarding/EditorTabBarOnboarding.vue.d.ts +2 -0
  69. package/dist/src/components/wrappers/WpModal.vue.d.ts +5 -1
  70. package/dist/src/composables/useAccessibilityApi.d.ts +13 -0
  71. package/dist/src/composables/useActionsApi.d.ts +2 -2
  72. package/dist/src/composables/useAuthError.d.ts +12 -0
  73. package/dist/src/composables/useConfig.d.ts +2 -0
  74. package/dist/src/composables/useCortexBlueprintBridge.d.ts +2 -3
  75. package/dist/src/composables/useEmailTemplateApplier.d.ts +18 -5
  76. package/dist/src/composables/useGuidoActions.d.ts +2 -0
  77. package/dist/src/composables/useHttp.d.ts +2 -0
  78. package/dist/src/config/migrator/index.d.ts +2 -1
  79. package/dist/src/config/migrator/recommendationPartnerMigrator.d.ts +19 -0
  80. package/dist/src/enums/extensions/recommendationBlock.d.ts +1 -1
  81. package/dist/src/extensions/Blocks/Items/constants/cardLayout.d.ts +44 -0
  82. package/dist/src/extensions/Blocks/Items/enums/productEnums.d.ts +3 -0
  83. package/dist/src/extensions/Blocks/Items/template.d.ts +19 -0
  84. package/dist/src/extensions/Blocks/Recommendation/block.d.ts +0 -6
  85. package/dist/src/extensions/Blocks/Recommendation/store/recommendation.d.ts +0 -5
  86. package/dist/src/extensions/Blocks/Recommendation/utils/partnerScope.d.ts +13 -7
  87. package/dist/src/mock/cortexChatStore.d.ts +12 -0
  88. package/dist/src/stores/autosave.d.ts +73 -1
  89. package/dist/src/stores/config.d.ts +20 -0
  90. package/dist/src/stores/editor.d.ts +109 -0
  91. package/dist/src/stores/guido-email-editor.d.ts +20 -10
  92. package/dist/src/stores/onboarding.d.ts +956 -21
  93. package/dist/src/stores/recommendation.d.ts +5 -0
  94. package/dist/src/stores/version-history.d.ts +1 -1
  95. package/dist/src/utils/dateUtil.d.ts +10 -0
  96. package/dist/src/utils/genericUtil.d.ts +3 -0
  97. package/dist/src/utils/timeUtil.d.ts +5 -0
  98. package/dist/static/styles/components/accessibility.css.js +234 -0
  99. package/dist/static/styles/components/version-history.css.js +2 -6
  100. package/dist/static/styles/variables.css.js +2 -0
  101. package/dist/stores/autosave.js +12 -7
  102. package/dist/stores/editor.js +7 -4
  103. package/dist/stores/guido-email-editor.js +3 -1
  104. package/dist/stores/onboarding.js +47 -21
  105. package/dist/utils/pairProductVariables.js +71 -71
  106. package/dist/utils/timeUtil.js +6 -17
  107. package/package.json +2 -1
  108. package/dist/components/organisms/header/AutoSaveToggle.vue.js +0 -22
  109. package/dist/components/organisms/header/AutoSaveToggle.vue2.js +0 -19
  110. /package/dist/src/components/organisms/{header/AutoSaveToggle.vue.d.ts → base/AuthErrorModal.vue.d.ts} +0 -0
@@ -1,4 +1,2 @@
1
- declare const _default: import("vue").DefineComponent<{}, {
2
- handleSave: (isSilent: boolean) => Promise<Omit<import("../../../@types/stripo.js").SavedTemplateDetails, "metadata" | "silent"> | undefined> | undefined;
3
- }, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
4
2
  export default _default;
@@ -1,4 +1,2 @@
1
- declare const _default: import("vue").DefineComponent<{}, {
2
- handleSave: (isSilent: boolean) => Promise<Omit<import("../../../@types/stripo.js").SavedTemplateDetails, "metadata" | "silent"> | undefined> | undefined;
3
- }, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
4
2
  export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
2
+ export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
2
+ export default _default;
@@ -0,0 +1,2 @@
1
+ declare const _default: import("vue").DefineComponent<{}, {}, {}, {}, {}, import("vue/types/v3-component-options.js").ComponentOptionsMixin, import("vue/types/v3-component-options.js").ComponentOptionsMixin, {}, string, Readonly<import("vue").ExtractPropTypes<{}>>, {}>;
2
+ export default _default;
@@ -3,6 +3,7 @@ type __VLS_Props = {
3
3
  id: string;
4
4
  title: string;
5
5
  description?: string;
6
+ state?: 'default' | 'primary' | 'warning' | 'danger';
6
7
  size?: 'X-small' | 'small' | 'medium' | 'large';
7
8
  footerButtonOptions?: FooterButtonGroup;
8
9
  closeButtonStatus?: boolean;
@@ -15,6 +16,7 @@ type __VLS_Slots = {} & {
15
16
  };
16
17
  declare const __VLS_component: import("vue").DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_Props>, {
17
18
  description: string;
19
+ state: string;
18
20
  size: string;
19
21
  footerButtonOptions: undefined;
20
22
  closeButtonStatus: boolean;
@@ -26,6 +28,7 @@ declare const __VLS_component: import("vue").DefineComponent<__VLS_WithDefaults<
26
28
  "secondary-action": () => void;
27
29
  }, string, Readonly<import("vue").ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToOption<__VLS_Props>, {
28
30
  description: string;
31
+ state: string;
29
32
  size: string;
30
33
  footerButtonOptions: undefined;
31
34
  closeButtonStatus: boolean;
@@ -34,9 +37,10 @@ declare const __VLS_component: import("vue").DefineComponent<__VLS_WithDefaults<
34
37
  }>>>, {
35
38
  size: "X-small" | "small" | "medium" | "large";
36
39
  description: string;
37
- closeOnOutsideClick: boolean;
40
+ state: "default" | "primary" | "warning" | "danger";
38
41
  footerButtonOptions: FooterButtonGroup;
39
42
  closeButtonStatus: boolean;
43
+ closeOnOutsideClick: boolean;
40
44
  footerStatus: boolean;
41
45
  }>;
42
46
  declare const _default: __VLS_WithSlots<typeof __VLS_component, __VLS_Slots>;
@@ -0,0 +1,13 @@
1
+ import type { ColorVisionDeficiency } from '@@/Types/api/accessibility-api';
2
+ export declare const useAccessibilityApi: () => {
3
+ openAccessibilityTestingMode: () => void;
4
+ closeAccessibilityTestingMode: () => void;
5
+ toggleAccessibilityTestingMode: () => void;
6
+ showImages: () => void;
7
+ hideImages: () => void;
8
+ toggleImages: () => void;
9
+ setColorVisionDeficiency: (type: ColorVisionDeficiency) => void;
10
+ switchToDesktopPreview: () => void;
11
+ switchToMobilePreview: () => void;
12
+ toggleCodeEditor: () => void;
13
+ };
@@ -1,5 +1,5 @@
1
- import type { CompileEmailOptions } from '@@/Types/actions-api';
2
- import { GetCompiledEmailOptions, CompiledEmailResult, TemplateData } from '@@/Types/actions-api';
1
+ import type { CompileEmailOptions } from '@@/Types/api/actions-api';
2
+ import { GetCompiledEmailOptions, CompiledEmailResult, TemplateData } from '@@/Types/api/actions-api';
3
3
  export declare const useActionsApi: () => {
4
4
  getCompiledEmail: (options?: GetCompiledEmailOptions) => Promise<CompiledEmailResult>;
5
5
  getTemplateData: () => Promise<TemplateData>;
@@ -0,0 +1,12 @@
1
+ export interface AuthErrorState {
2
+ status: number;
3
+ data: Record<string, unknown> | null;
4
+ }
5
+ export declare const isPanelOrigin: (url: string) => boolean;
6
+ export declare const reportAuthError: (status: number, body: string, url: string) => void;
7
+ export declare const useAuthError: () => {
8
+ authError: import("vue").Ref<{
9
+ status: number;
10
+ data: Record<string, unknown> | null;
11
+ } | null>;
12
+ };
@@ -100,6 +100,7 @@ export declare const useConfig: () => {
100
100
  modulesDisabled: boolean;
101
101
  liquidSyntax: boolean;
102
102
  autosave: boolean;
103
+ accessibilityTesting: boolean;
103
104
  allowlistEnabled: boolean;
104
105
  linkTrackingIds: boolean;
105
106
  reusableRecommendationStrategy: boolean;
@@ -238,6 +239,7 @@ export declare const useConfig: () => {
238
239
  modulesDisabled: boolean;
239
240
  liquidSyntax: boolean;
240
241
  autosave: boolean;
242
+ accessibilityTesting: boolean;
241
243
  allowlistEnabled: boolean;
242
244
  linkTrackingIds: boolean;
243
245
  reusableRecommendationStrategy: boolean;
@@ -17,12 +17,11 @@
17
17
  * - `error` segments (and message-level `isError` / `isCancelled`) trigger
18
18
  * a localized toaster.
19
19
  *
20
+ * Every apply settles into a terminal `applyAcks` entry, so cortex moves its button on the write, not the click.
21
+ *
20
22
  * In dev (`import.meta.env.DEV`) every observed segment + message-level flag
21
23
  * change is also `console.debug`-logged with the prefix `[guido:cortex]` so a
22
24
  * developer can watch the agent stream in real time. In production this is
23
25
  * gated behind `localStorage.guido:debug:ai === '1'`.
24
- *
25
- * If cortex-fe isn't loaded the chat store is undefined and the bridge is a
26
- * no-op (intentional — Guido must still work standalone).
27
26
  */
28
27
  export declare const useCortexBlueprintBridge: () => void;
@@ -1,4 +1,16 @@
1
1
  type ApplyStatus = 'pending' | 'applying' | 'applied' | 'failed';
2
+ /**
3
+ * Terminal outcome of an apply; every promise here settles with one, since the bridge acks on it.
4
+ * `superseded`: a newer payload for the same key replaced this one and owns the ack.
5
+ */
6
+ export type ApplyOutcome = {
7
+ status: 'applied';
8
+ } | {
9
+ status: 'failed';
10
+ error: unknown;
11
+ } | {
12
+ status: 'superseded';
13
+ };
2
14
  /**
3
15
  * Applies email_template blueprints from the chat agent to the Stripo editor.
4
16
  *
@@ -9,18 +21,19 @@ type ApplyStatus = 'pending' | 'applying' | 'applied' | 'failed';
9
21
  * - manual Apply click (first apply): immediate.
10
22
  * - blueprint_update after the user has applied once: debounced 250 ms trailing
11
23
  * so rapid mid-stream updates don't thrash updateHtmlAndCss.
24
+ * - a click before Stripo is ready is queued and flushed when `isStripoInitialized` flips.
12
25
  */
13
26
  export declare const useEmailTemplateApplier: () => {
14
27
  applyStatus: import("vue").Ref<Record<string, ApplyStatus>>;
15
- markPending: (blueprintId: string) => void;
16
- applyTemplate: (blueprintId: string, data: {
28
+ markPending: (key: string) => void;
29
+ applyTemplate: (key: string, data: {
17
30
  html?: string;
18
31
  css?: string;
19
- }) => void;
20
- applyTemplateDebounced: (blueprintId: string, data: {
32
+ }) => Promise<ApplyOutcome>;
33
+ applyTemplateDebounced: (key: string, data: {
21
34
  html?: string;
22
35
  css?: string;
23
- }) => void;
36
+ }) => Promise<ApplyOutcome>;
24
37
  };
25
38
  export declare const resetEmailTemplateApplier: () => void;
26
39
  export {};
@@ -19,6 +19,8 @@ export declare const provideGuidoActions: (actions: {
19
19
  }) => void;
20
20
  /**
21
21
  * Provides individual Guido action handlers
22
+ * @deprecated No consumer in src/ and not exported from library.ts — provideGuidoActions
23
+ * provides all four keys itself. Slated for deletion, see the SD-667788 dead-code ledger.
22
24
  */
23
25
  export declare const provideBackHandler: (handler: BackHandler) => void;
24
26
  export declare const provideSaveStartHandler: (handler: SaveStartHandler) => void;
@@ -16,6 +16,7 @@ export interface HttpError {
16
16
  status?: number;
17
17
  statusText?: string;
18
18
  response?: Response;
19
+ authReported?: boolean;
19
20
  }
20
21
  export declare const useHttp: (defaultOptions?: HttpOptions) => {
21
22
  loading: import("vue").ComputedRef<boolean>;
@@ -65,6 +66,7 @@ export declare const useHttp: (defaultOptions?: HttpOptions) => {
65
66
  json: () => Promise<any>;
66
67
  text: () => Promise<string>;
67
68
  } | undefined;
69
+ authReported?: boolean | undefined;
68
70
  } | null>;
69
71
  hasError: import("vue").ComputedRef<boolean>;
70
72
  request: <T = unknown>(method: HttpMethod, url: string, data?: unknown, options?: HttpOptions) => Promise<HttpResponse<T>>;
@@ -1,2 +1,3 @@
1
1
  import type { LegacyRecommendationConfig } from '@@/Types/config';
2
- export declare const migrate: (html: string, recommendationConfigs?: Record<string, LegacyRecommendationConfig>) => Promise<string>;
2
+ import { type PartnerScopeMigrationOptions } from './recommendationPartnerMigrator';
3
+ export declare const migrate: (html: string, recommendationConfigs?: Record<string, LegacyRecommendationConfig>, partnerScope?: PartnerScopeMigrationOptions) => Promise<string>;
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Empties recommendation blocks copied in from another account and stamps the
3
+ * current one, before the editor ever sees the template (SD-151945).
4
+ *
5
+ * Runs at load rather than on document change: the stamp makes it a one-time
6
+ * pass per template, the campaign-URL rule only ever applies to the loaded HTML,
7
+ * and Stripo takes the result as the original document, so nothing is dirtied.
8
+ */
9
+ export interface PartnerScopeMigrationOptions {
10
+ partnerName: string;
11
+ /** `undefined` when the host does not pass the map — the unstamped check is then off. */
12
+ campaignUrls?: Record<string, unknown>;
13
+ rrsEnabled: boolean;
14
+ }
15
+ /**
16
+ * @param html Template HTML, already normalized by `migrateRecommendation`.
17
+ * @returns Migrated HTML, or the original when no block needed a reset or a stamp.
18
+ */
19
+ export declare function migrateRecommendationPartnerScope(html: string, { partnerName, campaignUrls, rrsEnabled }: PartnerScopeMigrationOptions): string;
@@ -8,8 +8,8 @@ export declare const URLS: {
8
8
  NEWSLETTER_RECOMMENDATIONS_PATH: string;
9
9
  MIGRATE_STRATEGIES_PATH: string;
10
10
  TEMPLATE_MIGRATE_STRATEGIES_PATH: string;
11
- RECOMMENDATION_STRATEGY_CREATE_PATH: string;
12
11
  };
12
+ export declare const strategyCreatePath: () => string;
13
13
  export declare const strategyEditPath: (strategyId: string | number) => string;
14
14
  export declare const MIGRATION_PATHS: Record<RrsMigrationTarget['scope'], string>;
15
15
  export declare const QUERY_PARAMS: {
@@ -0,0 +1,44 @@
1
+ /**
2
+ * Single owner for the Items card orientation-dependent layout contract (SD-149368).
3
+ *
4
+ * Two things depend on a card's orientation and are written across several layers:
5
+ *
6
+ * 1. Name column width — a horizontal card lays the name in a narrow side-by-side
7
+ * column, so it is capped; a vertical card gives it a full-width row.
8
+ * 2. Block-cell padding — the collapsible price / original-price block-cell carries its
9
+ * own inter-cell spacing (horizontal cards pad left/right, vertical cards pad
10
+ * top/bottom) so a hidden element removes its own spacing instead of leaving a gap.
11
+ *
12
+ * Every layer that writes these — template render, layouts/horizontal.html,
13
+ * NameTrimmingControl (trimming toggle) and settingsControl (orientation change) — MUST
14
+ * derive them here, or a migrated / re-toggled card silently drifts out of sync with
15
+ * freshly generated markup (convention B1: cross-layer literals live in one module).
16
+ */
17
+ export declare const NAME_HORIZONTAL_MAX_WIDTH = "130px";
18
+ export declare const NAME_VERTICAL_MAX_WIDTH = "100%";
19
+ /** Name max-width for a card orientation. Non-horizontal (incl. undefined) → full width. */
20
+ export declare const nameMaxWidthFor: (orientation?: string) => string;
21
+ /** Orientation-dependent inter-cell padding classes for a collapsible block-cell. */
22
+ export declare const BLOCK_CELL_PADDING: {
23
+ readonly VERTICAL: "es-p5b es-p5t";
24
+ readonly HORIZONTAL: "es-p5l es-p5r";
25
+ };
26
+ /**
27
+ * Attribute the block-cell carries to mark its LAYOUT-owned padding orientation ('v'|'h').
28
+ * The orientation toggle keys off this marker so it only ever rewrites the padding the
29
+ * layout itself baked — a user's own es-p* padding classes are never matched or clobbered
30
+ * (SD-149368 F1), and a cell without the marker is left untouched rather than mis-swapped.
31
+ */
32
+ export declare const BLOCK_CELL_PAD_ATTR = "data-items-cell-pad";
33
+ /** Marker attribute (`data-items-cell-pad="v|h"`) for a block-cell in the given orientation. */
34
+ export declare const blockCellPadMarker: (isVertical: boolean) => string;
35
+ /** Padding classes (leading space included) for a block-cell in the given orientation. */
36
+ export declare const blockCellPaddingFor: (isVertical: boolean) => string;
37
+ /**
38
+ * Rewrites a block-cell's LAYOUT-owned padding classes to the target orientation, keyed off
39
+ * the BLOCK_CELL_PAD_ATTR marker. The orientation-change rebuild re-injects existing cells
40
+ * via getOuterHTML(), which still carry the previous orientation's padding — swap only the
41
+ * layout pair (and flip the marker) so price/original-price cells stay padded after a toggle
42
+ * (SD-149368 F3), while a user's own padding and any unmarked cell are left alone (F1).
43
+ */
44
+ export declare const reorientBlockCellPadding: (html: string, toVertical: boolean) => string;
@@ -39,14 +39,17 @@ export declare const productPairs: {
39
39
  CART_ITEMS: {
40
40
  ATTR: string;
41
41
  DEFAULT: string;
42
+ LEGACY_DEFAULTS: readonly string[];
42
43
  };
43
44
  BROWSED_ITEMS: {
44
45
  ATTR: string;
45
46
  DEFAULT: string;
47
+ LEGACY_DEFAULTS: readonly string[];
46
48
  };
47
49
  PURCHASED_ITEMS: {
48
50
  ATTR: string;
49
51
  DEFAULT: string;
52
+ LEGACY_DEFAULTS: readonly string[];
50
53
  };
51
54
  };
52
55
  price: {
@@ -37,6 +37,25 @@ type TemplateParameters = {
37
37
  /** Price orientation within the card ('vertical' = stacked, 'horizontal' = side-by-side) */
38
38
  priceOrientation?: PriceOrientationType;
39
39
  };
40
+ /**
41
+ * Applies price orientation styles to the generated HTML template.
42
+ *
43
+ * For Vertical Layout:
44
+ * - vertical price orientation: both cells 100% (stacked)
45
+ * - horizontal price orientation with both visible: both cells 50% (side-by-side)
46
+ * - horizontal price orientation with one hidden: visible cell 100%
47
+ *
48
+ * For Horizontal Layout:
49
+ * - horizontal price orientation: .horizontal-price visible, .vertical-price hidden
50
+ * - vertical price orientation: .horizontal-price hidden, .vertical-price visible
51
+ * @param html - The HTML template string with placeholders replaced
52
+ * @param layoutOrientation - The card layout orientation ('vertical' or 'horizontal')
53
+ * @param priceOrientation - The price orientation within the card ('vertical' or 'horizontal')
54
+ * @param isPriceVisible - Whether the price element is visible
55
+ * @param isOriginalPriceVisible - Whether the original price element is visible
56
+ * @returns HTML string with price orientation styles applied
57
+ */
58
+ export declare const applyPriceOrientationStyles: (html: string, layoutOrientation: OrientationType, priceOrientation: PriceOrientationType, isPriceVisible?: boolean, isOriginalPriceVisible?: boolean) => string;
40
59
  /**
41
60
  * Generates the default template for the Items Block.
42
61
  * @param params - Template parameters including orientation, items type, item ID, and formatting options
@@ -137,12 +137,6 @@ export declare class RecommendationBlock extends Block {
137
137
  * heals templates saved before this feature without dirtying current ones.
138
138
  */
139
139
  private _healHidePriceAttr;
140
- /**
141
- * Empties a block copied in from another account: its strategy and attribute types
142
- * are account-scoped and would not resolve here (SD-151945). Layout, locale and
143
- * currency stay. The write stamps the current account, so the next pass is a no-op.
144
- */
145
- private _resetForeignPartnerConfig;
146
140
  /**
147
141
  * Gets the recommendation-id from a block node
148
142
  */
@@ -543,11 +543,6 @@ export declare const useRecommendationExtensionStore: import("pinia").StoreDefin
543
543
  openRemoveStrategyModal(): void;
544
544
  closeRemoveStrategyModal(): void;
545
545
  fetchStrategies(): Promise<void>;
546
- /**
547
- * Drops what the store still holds for a block whose account-scoped config was just
548
- * reset in the document (SD-151945), so the panel re-seeds from the emptied node.
549
- */
550
- resetPartnerScopedConfig(id: number): void;
551
546
  /**
552
547
  * Clears what a block inherited from the id it arrived holding, so the panel fetches for it.
553
548
  * A re-dropped saved module can keep the source's id — and its "already fetched" entry —
@@ -4,24 +4,30 @@ import type { RecommendationNodeConfig } from '../types/nodeConfig';
4
4
  * string or an entry that names a strategy.
5
5
  */
6
6
  export declare function isDefinedCampaignUrl(value: unknown): boolean;
7
- /** Recommendation block ids present in the HTML the host loaded the editor with. */
8
- export declare function loadedRecommendationIds(html: string): Set<number>;
9
7
  export interface PartnerScopeInputs {
10
8
  config: Pick<RecommendationNodeConfig, 'strategyId' | 'partnerName'>;
11
9
  blockId: number;
12
10
  partnerName: string;
13
11
  /** `undefined` when the host does not pass the map — the unstamped check is then off. */
14
12
  campaignUrls: Record<string, unknown> | undefined;
15
- loadedIds: Set<number>;
13
+ /** With RRS off `buildCampaignUrl` drops the block's map entry, so the map says nothing. */
14
+ rrsEnabled: boolean;
16
15
  }
17
16
  /**
18
17
  * Whether a block carries another account's strategy config (SD-151945).
19
18
  *
20
19
  * A stamped block is judged by its stamp. An unstamped one predates the stamp, so it
21
20
  * falls back to the backend's own signal: a cross-account duplicate drops the block's
22
- * strategy entry from the campaign URL map but leaves the HTML untouched. That check
23
- * only holds for blocks the host loaded, whose map entry the host actually sent — a
24
- * saved module or a clone arrives under an id the map never had.
21
+ * strategy entry from the campaign URL map but leaves the HTML untouched. That signal
22
+ * only holds while RRS is on, and only for the HTML the host loaded — which is what
23
+ * the caller, a load-time migrator, runs on.
25
24
  */
26
- export declare function carriesForeignPartnerConfig({ config, blockId, partnerName, campaignUrls, loadedIds }: PartnerScopeInputs): boolean;
25
+ export declare function carriesForeignPartnerConfig({ config, blockId, partnerName, campaignUrls, rrsEnabled }: PartnerScopeInputs): boolean;
26
+ /**
27
+ * Whether an unstamped block's ownership can be decided at all. `carriesForeignPartnerConfig`
28
+ * answers `false` both for "clean" and for "cannot tell", and stamping on the latter would
29
+ * record a foreign block as this account's and silence every later check. A block with no
30
+ * strategy reference has nothing foreign to carry, so it is always decidable.
31
+ */
32
+ export declare function canJudgeUnstampedBlock({ config, campaignUrls, rrsEnabled }: Pick<PartnerScopeInputs, 'config' | 'campaignUrls' | 'rrsEnabled'>): boolean;
27
33
  export declare function withoutCustomAttributes(composition: string[]): string[];
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Dev-harness stand-in for the cortex-fe MFE's shared `chat` store.
3
+ *
4
+ * `useCortexBlueprintBridge` resolves that store by id off the host's pinia at
5
+ * Guido's setup time, so a store registered after mount is never seen. Installing
6
+ * it here — before `<Guido>` renders — lets e2e drive the bridge through its real
7
+ * registration path instead of re-invoking the composable by hand.
8
+ *
9
+ * Activated with `?chatStore=true`; the instance is exposed on `window` so a test
10
+ * can push agent messages into it.
11
+ */
12
+ export declare const installMockChatStore: () => void;
@@ -9,4 +9,76 @@ export declare const useAutosaveStore: import("pinia").StoreDefinition<"guidoAut
9
9
  isOn: boolean;
10
10
  lastSavedAt: Date | null;
11
11
  status: AutosaveStatus;
12
- }, {}, {}>;
12
+ }, {
13
+ hasStatusLabel: (state: {
14
+ isOn: boolean;
15
+ lastSavedAt: {
16
+ toString: () => string;
17
+ toDateString: () => string;
18
+ toTimeString: () => string;
19
+ toLocaleString: {
20
+ (): string;
21
+ (locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;
22
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions): string;
23
+ };
24
+ toLocaleDateString: {
25
+ (): string;
26
+ (locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;
27
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions): string;
28
+ };
29
+ toLocaleTimeString: {
30
+ (): string;
31
+ (locales?: string | string[], options?: Intl.DateTimeFormatOptions): string;
32
+ (locales?: Intl.LocalesArgument, options?: Intl.DateTimeFormatOptions): string;
33
+ };
34
+ valueOf: () => number;
35
+ getTime: () => number;
36
+ getFullYear: () => number;
37
+ getUTCFullYear: () => number;
38
+ getMonth: () => number;
39
+ getUTCMonth: () => number;
40
+ getDate: () => number;
41
+ getUTCDate: () => number;
42
+ getDay: () => number;
43
+ getUTCDay: () => number;
44
+ getHours: () => number;
45
+ getUTCHours: () => number;
46
+ getMinutes: () => number;
47
+ getUTCMinutes: () => number;
48
+ getSeconds: () => number;
49
+ getUTCSeconds: () => number;
50
+ getMilliseconds: () => number;
51
+ getUTCMilliseconds: () => number;
52
+ getTimezoneOffset: () => number;
53
+ setTime: (time: number) => number;
54
+ setMilliseconds: (ms: number) => number;
55
+ setUTCMilliseconds: (ms: number) => number;
56
+ setSeconds: (sec: number, ms?: number) => number;
57
+ setUTCSeconds: (sec: number, ms?: number) => number;
58
+ setMinutes: (min: number, sec?: number, ms?: number) => number;
59
+ setUTCMinutes: (min: number, sec?: number, ms?: number) => number;
60
+ setHours: (hours: number, min?: number, sec?: number, ms?: number) => number;
61
+ setUTCHours: (hours: number, min?: number, sec?: number, ms?: number) => number;
62
+ setDate: (date: number) => number;
63
+ setUTCDate: (date: number) => number;
64
+ setMonth: (month: number, date?: number) => number;
65
+ setUTCMonth: (month: number, date?: number) => number;
66
+ setFullYear: (year: number, month?: number, date?: number) => number;
67
+ setUTCFullYear: (year: number, month?: number, date?: number) => number;
68
+ toUTCString: () => string;
69
+ toISOString: () => string;
70
+ toJSON: (key?: any) => string;
71
+ [Symbol.toPrimitive]: {
72
+ (hint: "default"): string;
73
+ (hint: "string"): string;
74
+ (hint: "number"): number;
75
+ (hint: string): string | number;
76
+ };
77
+ } | null;
78
+ status: AutosaveStatus;
79
+ } & import("pinia").PiniaCustomStateProperties<{
80
+ isOn: boolean;
81
+ lastSavedAt: Date | null;
82
+ status: AutosaveStatus;
83
+ }>) => boolean;
84
+ }, {}>;
@@ -105,6 +105,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
105
105
  modulesDisabled: boolean;
106
106
  liquidSyntax: boolean;
107
107
  autosave: boolean;
108
+ accessibilityTesting: boolean;
108
109
  allowlistEnabled: boolean;
109
110
  linkTrackingIds: boolean;
110
111
  reusableRecommendationStrategy: boolean;
@@ -249,6 +250,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
249
250
  modulesDisabled: boolean;
250
251
  liquidSyntax: boolean;
251
252
  autosave: boolean;
253
+ accessibilityTesting: boolean;
252
254
  allowlistEnabled: boolean;
253
255
  linkTrackingIds: boolean;
254
256
  reusableRecommendationStrategy: boolean;
@@ -393,6 +395,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
393
395
  modulesDisabled: boolean;
394
396
  liquidSyntax: boolean;
395
397
  autosave: boolean;
398
+ accessibilityTesting: boolean;
396
399
  allowlistEnabled: boolean;
397
400
  linkTrackingIds: boolean;
398
401
  reusableRecommendationStrategy: boolean;
@@ -537,6 +540,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
537
540
  modulesDisabled: boolean;
538
541
  liquidSyntax: boolean;
539
542
  autosave: boolean;
543
+ accessibilityTesting: boolean;
540
544
  allowlistEnabled: boolean;
541
545
  linkTrackingIds: boolean;
542
546
  reusableRecommendationStrategy: boolean;
@@ -681,6 +685,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
681
685
  modulesDisabled: boolean;
682
686
  liquidSyntax: boolean;
683
687
  autosave: boolean;
688
+ accessibilityTesting: boolean;
684
689
  allowlistEnabled: boolean;
685
690
  linkTrackingIds: boolean;
686
691
  reusableRecommendationStrategy: boolean;
@@ -825,6 +830,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
825
830
  modulesDisabled: boolean;
826
831
  liquidSyntax: boolean;
827
832
  autosave: boolean;
833
+ accessibilityTesting: boolean;
828
834
  allowlistEnabled: boolean;
829
835
  linkTrackingIds: boolean;
830
836
  reusableRecommendationStrategy: boolean;
@@ -969,6 +975,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
969
975
  modulesDisabled: boolean;
970
976
  liquidSyntax: boolean;
971
977
  autosave: boolean;
978
+ accessibilityTesting: boolean;
972
979
  allowlistEnabled: boolean;
973
980
  linkTrackingIds: boolean;
974
981
  reusableRecommendationStrategy: boolean;
@@ -1113,6 +1120,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1113
1120
  modulesDisabled: boolean;
1114
1121
  liquidSyntax: boolean;
1115
1122
  autosave: boolean;
1123
+ accessibilityTesting: boolean;
1116
1124
  allowlistEnabled: boolean;
1117
1125
  linkTrackingIds: boolean;
1118
1126
  reusableRecommendationStrategy: boolean;
@@ -1257,6 +1265,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1257
1265
  modulesDisabled: boolean;
1258
1266
  liquidSyntax: boolean;
1259
1267
  autosave: boolean;
1268
+ accessibilityTesting: boolean;
1260
1269
  allowlistEnabled: boolean;
1261
1270
  linkTrackingIds: boolean;
1262
1271
  reusableRecommendationStrategy: boolean;
@@ -1401,6 +1410,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1401
1410
  modulesDisabled: boolean;
1402
1411
  liquidSyntax: boolean;
1403
1412
  autosave: boolean;
1413
+ accessibilityTesting: boolean;
1404
1414
  allowlistEnabled: boolean;
1405
1415
  linkTrackingIds: boolean;
1406
1416
  reusableRecommendationStrategy: boolean;
@@ -1545,6 +1555,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1545
1555
  modulesDisabled: boolean;
1546
1556
  liquidSyntax: boolean;
1547
1557
  autosave: boolean;
1558
+ accessibilityTesting: boolean;
1548
1559
  allowlistEnabled: boolean;
1549
1560
  linkTrackingIds: boolean;
1550
1561
  reusableRecommendationStrategy: boolean;
@@ -1689,6 +1700,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1689
1700
  modulesDisabled: boolean;
1690
1701
  liquidSyntax: boolean;
1691
1702
  autosave: boolean;
1703
+ accessibilityTesting: boolean;
1692
1704
  allowlistEnabled: boolean;
1693
1705
  linkTrackingIds: boolean;
1694
1706
  reusableRecommendationStrategy: boolean;
@@ -1833,6 +1845,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1833
1845
  modulesDisabled: boolean;
1834
1846
  liquidSyntax: boolean;
1835
1847
  autosave: boolean;
1848
+ accessibilityTesting: boolean;
1836
1849
  allowlistEnabled: boolean;
1837
1850
  linkTrackingIds: boolean;
1838
1851
  reusableRecommendationStrategy: boolean;
@@ -1977,6 +1990,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
1977
1990
  modulesDisabled: boolean;
1978
1991
  liquidSyntax: boolean;
1979
1992
  autosave: boolean;
1993
+ accessibilityTesting: boolean;
1980
1994
  allowlistEnabled: boolean;
1981
1995
  linkTrackingIds: boolean;
1982
1996
  reusableRecommendationStrategy: boolean;
@@ -2121,6 +2135,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2121
2135
  modulesDisabled: boolean;
2122
2136
  liquidSyntax: boolean;
2123
2137
  autosave: boolean;
2138
+ accessibilityTesting: boolean;
2124
2139
  allowlistEnabled: boolean;
2125
2140
  linkTrackingIds: boolean;
2126
2141
  reusableRecommendationStrategy: boolean;
@@ -2265,6 +2280,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2265
2280
  modulesDisabled: boolean;
2266
2281
  liquidSyntax: boolean;
2267
2282
  autosave: boolean;
2283
+ accessibilityTesting: boolean;
2268
2284
  allowlistEnabled: boolean;
2269
2285
  linkTrackingIds: boolean;
2270
2286
  reusableRecommendationStrategy: boolean;
@@ -2409,6 +2425,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2409
2425
  modulesDisabled: boolean;
2410
2426
  liquidSyntax: boolean;
2411
2427
  autosave: boolean;
2428
+ accessibilityTesting: boolean;
2412
2429
  allowlistEnabled: boolean;
2413
2430
  linkTrackingIds: boolean;
2414
2431
  reusableRecommendationStrategy: boolean;
@@ -2553,6 +2570,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2553
2570
  modulesDisabled: boolean;
2554
2571
  liquidSyntax: boolean;
2555
2572
  autosave: boolean;
2573
+ accessibilityTesting: boolean;
2556
2574
  allowlistEnabled: boolean;
2557
2575
  linkTrackingIds: boolean;
2558
2576
  reusableRecommendationStrategy: boolean;
@@ -2697,6 +2715,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2697
2715
  modulesDisabled: boolean;
2698
2716
  liquidSyntax: boolean;
2699
2717
  autosave: boolean;
2718
+ accessibilityTesting: boolean;
2700
2719
  allowlistEnabled: boolean;
2701
2720
  linkTrackingIds: boolean;
2702
2721
  reusableRecommendationStrategy: boolean;
@@ -2843,6 +2862,7 @@ export declare const useConfigStore: import("pinia").StoreDefinition<"guido-conf
2843
2862
  modulesDisabled: boolean;
2844
2863
  liquidSyntax: boolean;
2845
2864
  autosave: boolean;
2865
+ accessibilityTesting: boolean;
2846
2866
  allowlistEnabled: boolean;
2847
2867
  linkTrackingIds: boolean;
2848
2868
  reusableRecommendationStrategy: boolean;