@spiffcommerce/core 32.4.0 → 33.1.0-beta.862b8150-11b4-59dd-84cf-02e1089dd07d

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.
package/CHANGELOG.md CHANGED
@@ -14,140 +14,165 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
14
14
  - `Fixed` for any bug fixes.
15
15
  - `Security` in case of vulnerabilities.
16
16
 
17
+ ## [33.2.0] - 20-10-2025
18
+
19
+ ### Changed
20
+
21
+ - Global aspects can now be configured to check their conditions using a logical "AND" or "OR", rather than just "OR".
22
+
23
+ ## [33.1.0] - 20-10-2025
24
+
25
+ ### Fixed
26
+
27
+ - Global aspects that are transitively conditional now get cleared correctly when deactivated.
28
+
29
+ ## [33.0.0] - 14-10-2025
30
+
31
+ ### Changed
32
+
33
+ - Updated `WorkflowExperience` to store `transaction`, `product`, `profanityList`, and `workflow` as direct properties, initialized in the constructor for improved encapsulation and performance.
34
+
35
+ ### Added
36
+
37
+ - Added new methods to `WorkflowExperience`: `getProduct()`, `getProfanityList()`, `setProduct(integrationProductId: string)`, `getTransaction()`, `getWorkflow()`, and `setWorkflow(workflow: Workflow)` for easier access and mutation of core experience data.
38
+ - Introduced `getIntegrationProductIds()` and `addIntegrationProductId(id: string)` methods to `Bundle` and `BundleImpl` for tracking associated integration product IDs.
39
+ - Added GraphQL mutation for updating a transaction's integration product, enabling backend synchronization of integration product changes.
40
+ - Added `getState()` method to `BundleStateManager` for easier external access to the current bundle state.
41
+
17
42
  ## [32.4.0] - 16-10-2025
18
43
 
19
- ## Added
44
+ ### Added
20
45
 
21
46
  - The interface `GetWorkflowFromIntegrationProductOptions` now has optional `quantity` and `recipient` arguments.
22
47
 
23
48
  ## [32.3.1] - 09-10-2025
24
49
 
25
- ## Added
50
+ ### Added
26
51
 
27
52
  - Added the `SelectionChanged` event to `WorkflowExperienceEventType`. This event fires whenever the selection in a workflow experience changes. This includes changes to variant selections.
28
53
 
29
54
  ## [32.3.0] - 08-10-2025
30
55
 
31
- ## Added
56
+ ### Added
32
57
 
33
58
  - Added the new global function `deleteBundle` which takes a bundle id string and deletes the marks the bundle as deleted on the server.
34
59
 
35
60
  ## [32.2.6] - 08-10-2025
36
61
 
37
- ## Fixed
62
+ ### Fixed
38
63
 
39
64
  - Resolved an issue where `finish` function on `Bundle` would return no items if the bundle was being edited.
40
65
 
41
66
  ## [32.2.5] - 01-10-2025
42
67
 
43
- ## Fixed
68
+ ### Fixed
44
69
 
45
70
  - Fixed various bugs with custom colors for global properties.
46
71
 
47
72
  ## [32.2.4] - 29-09-2025
48
73
 
49
- ## Fixed
74
+ ### Fixed
50
75
 
51
76
  - Fixed a regression from 32.2.3 which causes defaults to incorrectly be applied when applying a saved global state to a bundle.
52
77
 
53
78
  ## [32.2.3] - 29-09-2025
54
79
 
55
- ## Fixed
80
+ ### Fixed
56
81
 
57
82
  - Whenever global property handles change, they will correctly apply their defaults if no value is set.
58
83
 
59
84
  ## [32.2.2] - 29-09-2025
60
85
 
61
- ## Fixed
86
+ ### Fixed
62
87
 
63
88
  - Text steps will no longer incorrectly clear templated text under certain configurations.
64
89
 
65
90
  ## [32.2.1] - 24-09-2025
66
91
 
67
- ## Changed
92
+ ### Changed
68
93
 
69
94
  - Whenever the Global Property State of a bundle has changed, every active handle will re-apply their current state.
70
95
 
71
96
  ## [32.2.0] - 24-09-2025
72
97
 
73
- ## Added
98
+ ### Added
74
99
 
75
100
  - Added new field `addressValidationStatus` on the Transaction type, which is fetched whenever the transaction is read.
76
101
 
77
- ## Changed
102
+ ### Changed
78
103
 
79
104
  - When calling `overrideWorkflowExperienceRecipientAddress`, the associated Transaction's `addressValidationStatus` is updated locally.
80
105
 
81
106
  ## [32.1.0] - 23-09-2025
82
107
 
83
- ## Added
108
+ ### Added
84
109
 
85
110
  - Added new `overrideWorkflowExperienceRecipientAddress` function to override the address of a specific workflow experience recipient.
86
111
 
87
112
  ## [31.4.0] - 10-09-2025
88
113
 
89
- ## Added
114
+ ### Added
90
115
 
91
116
  - Fetching new `limit` option for Theme Configurations
92
117
 
93
118
  ## [31.3.0] - 10-09-2025
94
119
 
95
- ## Added
120
+ ### Added
96
121
 
97
122
  - The function `ProductCollection.fetchProductsFeed` now supports an additional metafield filters parameter for filtering via attached workflows.
98
123
 
99
124
  ## [31.2.4] - 04-09-2025
100
125
 
101
- ## Fixed
126
+ ### Fixed
102
127
 
103
128
  - Vertical text steps now respect region boundaries, even if the text is really long.
104
129
 
105
130
  ## [30.2.2] - 01-09-2025
106
131
 
107
- ## Added
132
+ ### Added
108
133
 
109
134
  - The `collectionId` field will now be available on the complete event.
110
135
 
111
136
  ## [31.2.2] - 01-09-2025
112
137
 
113
- ## Fixed
138
+ ### Fixed
114
139
 
115
140
  - Text steps with templated input should have their font correctly resized in appropriate situations.
116
141
  - The templating context for a WorkflowManager now correctly provides first/last name fields with a custom `uniqueIdentifier`.
117
142
 
118
143
  ## [30.2.1] - 01-09-2025
119
144
 
120
- ## Added
145
+ ### Added
121
146
 
122
147
  - The `name`, `dispatchDate`, `purchaseOrder` and `collectionName` fields will now be available on the complete event.
123
148
 
124
149
  ## [30.2.0] - 01-09-2025
125
150
 
126
- ## Added
151
+ ### Added
127
152
 
128
153
  - The `getOrCreateCustomer` call will fetch an existing customer's product collection customers.
129
154
 
130
155
  ## [31.1.0] - 01-09-2025
131
156
 
132
- ## Added
157
+ ### Added
133
158
 
134
159
  - The function `ProductCollection.fetchProductsFeed` now supports an additional string parameter to further filter the returned products by name.
135
160
 
136
161
  ## [31.0.0] - 29-08-2025
137
162
 
138
- ## Added
163
+ ### Added
139
164
 
140
165
  - Latest versions of internal build tools and libraries. EG. Vite and ESLint
141
166
 
142
167
  ## [30.0.0] - 27-08-2025
143
168
 
144
- ## Added
169
+ ### Added
145
170
 
146
171
  - The `updateRecipient` method now has extra arguments, primarily for custom fields.
147
172
 
148
173
  ## [29.3.0] - 27-08-2025
149
174
 
150
- ## Added
175
+ ### Added
151
176
 
152
177
  - Added new functionality regarding mandatory Global Property aspects:
153
178
  - New function `GlobalPropertyHandle.isMandatory(): boolean`: returns a boolean indicating whether the aspect has been marked as required to be completed before the user can continue.
@@ -156,144 +181,144 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
156
181
 
157
182
  ## [29.2.0] - 25-08-2025
158
183
 
159
- ## Added
184
+ ### Added
160
185
 
161
186
  - Added the function `TextGlobalPropertyHandle.isTemplatingEnabled(): boolean`. Use this to determine whether you should display any templating tools.
162
187
 
163
188
  ## [29.1.2] - 25-08-2025
164
189
 
165
- ## Changed
190
+ ### Changed
166
191
 
167
192
  - Text steps now render any templated values prior to calculating the character limit
168
193
 
169
194
  ## [29.1.1] - 20-08-2025
170
195
 
171
- ## Fixed
196
+ ### Fixed
172
197
 
173
198
  - Inputting an incorrect code when calling `verifyCode` will no longer prevent you from succeeding if you then input the correct code in a subsequent request.
174
199
 
175
200
  ## [29.0.4] - 14-08-2025
176
201
 
177
- ## Fixed
202
+ ### Fixed
178
203
 
179
204
  - Existing dispatchDate is now correctly applied when reloading a bundle
180
205
 
181
206
  ## [29.0.3] - 14-08-2025
182
207
 
183
- ## Added
208
+ ### Added
184
209
 
185
210
  - `getDispatchStartDate` method to `ProductCollection`.
186
211
  - `getDispatchEndDate` method to `ProductCollection`.
187
212
 
188
213
  ## [29.0.2] - 08-08-2025
189
214
 
190
- ## Fixed
215
+ ### Fixed
191
216
 
192
217
  - `getExportedStepData` now returns only steps with properties as per original behavior.
193
218
 
194
219
  ## [29.0.1] - 07-08-2025
195
220
 
196
- ## Fixed
221
+ ### Fixed
197
222
 
198
223
  - Missing `ExportedStepData` types.
199
224
 
200
225
  ## [29.0.0] - 06-08-2025
201
226
 
202
- ## Changed
227
+ ### Changed
203
228
 
204
229
  - The `getExportedData` method has been renamed `getExportedStepData` for clarity, it now returns a list of steps and their metadata chronological to the workflow. Localization has also been removed as this is a theme concern.
205
230
 
206
231
  ## [28.0.0] - 30-07-2025
207
232
 
208
- ## Changed
233
+ ### Changed
209
234
 
210
235
  - The `duplicateBundle` method now returns a function that creates a bundle object, rather than creating the object automatically.
211
236
 
212
- ## Fixed
237
+ ### Fixed
213
238
 
214
239
  - Fixed bugs around reloading state.
215
240
 
216
241
  ## [27.3.0] - 28-07-2025
217
242
 
218
- ## Added
243
+ ### Added
219
244
 
220
245
  - CurrencyService & CurrencyContext can now be used to correctly transform values for display. See `client.getCurrencyContext`
221
246
 
222
247
  ## [27.2.1] - 28-07-2025
223
248
 
224
- ## Fixed
249
+ ### Fixed
225
250
 
226
251
  - `WorkflowExperience.assignCustomerDetails` should no longer fail when you have ownership of the associated Transaction.
227
252
 
228
253
  ## [27.2.0] - 24-07-2025
229
254
 
230
- ## Added
255
+ ### Added
231
256
 
232
257
  - Bundles now have the `applyGlobalPropertyState` method for copying one global state onto another.
233
258
 
234
259
  ## [27.1.1] - 23-07-2025
235
260
 
236
- ## Fixed
261
+ ### Fixed
237
262
 
238
263
  - Correctly the case of handle multiple text steps that are conditional and share a text aspect.
239
264
 
240
265
  ## [27.1.0] - 16-07-2025
241
266
 
242
- ## Changed
267
+ ### Changed
243
268
 
244
269
  - Added support for Handlebars in text steps.
245
270
 
246
271
  ## [27.0.0] - 15-07-2025
247
272
 
248
- ## Changed
273
+ ### Changed
249
274
 
250
275
  - Modified the functions for logging in as a customer.
251
276
 
252
277
  ## [26.40.0] - 10-07-2025
253
278
 
254
- ## Added
279
+ ### Added
255
280
 
256
281
  - Added `setDispatchDate` and `setPurchaseOrder` to `Bundle`.
257
282
 
258
283
  ## [26.39.0] - 08-07-2025
259
284
 
260
- ## Fixed
285
+ ### Fixed
261
286
 
262
287
  - The function `fetchProductsFeed` on `ProductCollection` now correctly reads from the in-memory cache for repeated calls with the same inputs.
263
288
 
264
289
  ## [26.38.0] - 07-07-2025
265
290
 
266
- ## Added
291
+ ### Added
267
292
 
268
293
  - `WorkflowManager` now has the function `addRecipientCallback` to listen to changes to the attached Recipient.
269
294
 
270
295
  ## [26.35.0] - 03-07-2025
271
296
 
272
- ## Added
297
+ ### Added
273
298
 
274
299
  - The `Bundle` type now has the `productsCount` property.
275
300
 
276
301
  ## [26.33.0] - 02-07-2025
277
302
 
278
- ## Added
303
+ ### Added
279
304
 
280
305
  - The method `getBundlesForCustomer` now has an "ordered" option.
281
306
 
282
307
  ## [26.31.0] - 24-06-2025
283
308
 
284
- ## Fixed
309
+ ### Fixed
285
310
 
286
311
  - Fixed issues with authorizing certain requests affecting recipients.
287
312
 
288
313
  ## [26.30.0] - 23-06-2025
289
314
 
290
- ## Added
315
+ ### Added
291
316
 
292
317
  - New global function `getProductCollections`, which fetches a list of Product Collections by their ids.
293
318
 
294
319
  ## [26.29.3] - 19-06-2025
295
320
 
296
- ## Fixed
321
+ ### Fixed
297
322
 
298
323
  - The method `updateRecipient` now saves its arguments correctly.
299
324
 
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { FunctionComponent, ReactNode } from 'preact/compat';
2
2
  import * as _apollo_client_core from '@apollo/client/core';
3
3
  import { OperationVariables, QueryOptions, ApolloQueryResult, DefaultContext, MutationOptions, FetchResult, ApolloClient } from '@apollo/client/core';
4
- import { RenderableContextService, RenderableContext, ThreeDPreviewService, ModelContainer } from '@spiffcommerce/preview';
4
+ import { RenderableContextService, RenderableContext, ModelContainer, ThreeDPreviewService } from '@spiffcommerce/preview';
5
5
  import * as lodash from 'lodash';
6
6
  import { CompleteQuoteMessage, ThemeInstallConfigurationGraphQl, ConversionConfiguration } from '@spiffcommerce/theme-bridge';
7
7
  export { ConversionConfiguration, ConversionData, ConversionDataType, ConversionLocation } from '@spiffcommerce/theme-bridge';
@@ -1049,16 +1049,10 @@ interface Scene {
1049
1049
  * State related to a workflow experience.
1050
1050
  */
1051
1051
  interface ExperienceOptions {
1052
- product: Product;
1053
1052
  transaction: Transaction;
1054
1053
  workflow?: Workflow;
1055
- /**
1056
- * @deprecated favor inject / eject functions.
1057
- */
1058
- previewService?: ThreeDPreviewService;
1059
1054
  modelContainer?: ModelContainer;
1060
1055
  renderableContextService?: LayoutPreviewService;
1061
- layouts: ILayout[];
1062
1056
  reloadedState?: LayoutsState;
1063
1057
  /**
1064
1058
  * When true the experience is intended to be immutable.
@@ -1094,6 +1088,10 @@ interface ExperienceOptions {
1094
1088
  * should get an instance of this class from a Client you have constructed previously.
1095
1089
  */
1096
1090
  interface WorkflowExperience {
1091
+ /**
1092
+ * Get the current transaction for this experience.
1093
+ */
1094
+ getTransaction(): Transaction;
1097
1095
  /**
1098
1096
  * Get the bundle this experience is part of. May be undefined.
1099
1097
  */
@@ -1102,6 +1100,28 @@ interface WorkflowExperience {
1102
1100
  * Set the bundle this experience is part of. Can be cleared using undefined.
1103
1101
  */
1104
1102
  setBundle(bundle: Bundle$1 | undefined): any;
1103
+ /**
1104
+ * Get the current product for this experience. May be undefined.
1105
+ */
1106
+ getProduct(): Product | undefined;
1107
+ /**
1108
+ * Get the current profanity list for this experience. May be empty.
1109
+ */
1110
+ getProfanityList(): string[];
1111
+ /**
1112
+ * Set the current product for this experience.
1113
+ * @param product The new product to set.
1114
+ */
1115
+ setProduct(integrationProductId: string): Promise<void>;
1116
+ /**
1117
+ * Get the current workflow for this experience. May be undefined.
1118
+ */
1119
+ getWorkflow(): Workflow | undefined;
1120
+ /**
1121
+ * Set the current workflow for this experience.
1122
+ * @param workflow The new workflow to set.
1123
+ */
1124
+ setWorkflow(workflow: Workflow): Promise<void>;
1105
1125
  /**
1106
1126
  * Returns the client that was responsible for spawning this experience.
1107
1127
  */
@@ -1290,7 +1310,7 @@ declare enum WorkflowExperienceEventType {
1290
1310
  }
1291
1311
  declare class WorkflowExperienceImpl implements WorkflowExperience {
1292
1312
  readonly client: SpiffCommerceClient;
1293
- readonly commandContext: CommandContext;
1313
+ readonly transaction: Transaction;
1294
1314
  readonly graphQlClient: GraphQlClientFunc;
1295
1315
  readonly workflowManager: WorkflowManager;
1296
1316
  readonly isReadOnly: boolean;
@@ -1299,11 +1319,19 @@ declare class WorkflowExperienceImpl implements WorkflowExperience {
1299
1319
  * Bundle this experience has been added to.
1300
1320
  */
1301
1321
  private bundle?;
1322
+ private profanityList;
1323
+ private workflow?;
1302
1324
  private currentPriceBreak;
1303
1325
  private renderableScenes;
1304
1326
  private renderableSceneCallbacks;
1305
1327
  private eventCallbacks;
1306
1328
  constructor(client: SpiffCommerceClient, experienceOptions: ExperienceOptions);
1329
+ getTransaction(): Transaction;
1330
+ getProduct(): Product | undefined;
1331
+ getProfanityList(): string[];
1332
+ setProduct(integrationProductId: string): Promise<void>;
1333
+ getWorkflow(): Workflow | undefined;
1334
+ setWorkflow(workflow: Workflow): Promise<void>;
1307
1335
  attachAddress(streetAddress?: string, apartment?: string, city?: string, country?: string, state?: string, postCode?: string): Promise<void>;
1308
1336
  attachOrganization(name: string): Promise<void>;
1309
1337
  getBundle(): Bundle$1 | undefined;
@@ -1555,6 +1583,7 @@ interface GlobalPropertyStateManager {
1555
1583
  setBundleOptions(bundleOptions?: BundleOptions): void;
1556
1584
  getBundleOptions(): BundleOptions | undefined;
1557
1585
  setConfiguration(configuration: GlobalPropertyConfiguration | undefined): void;
1586
+ clearAspects(names: string[]): Promise<void>;
1558
1587
  }
1559
1588
  interface BundleOptions {
1560
1589
  additionalHeaders?: {
@@ -1784,6 +1813,9 @@ declare class Transform {
1784
1813
  }
1785
1814
  declare const getProductCollections: (ids: string[]) => Promise<ProductCollection[] | undefined>;
1786
1815
 
1816
+ interface BundleIntegrationProductsAddedEventData {
1817
+ integrationProductIds: string[];
1818
+ }
1787
1819
  interface ConditionalGlobalPropertiesChangedEventData {
1788
1820
  globalProperties: GlobalPropertyHandle[];
1789
1821
  }
@@ -1801,6 +1833,7 @@ interface WorkflowExperienceAddedEventData {
1801
1833
  interface WorkflowExperienceRemovedEventData extends WorkflowExperienceAddedEventData {
1802
1834
  }
1803
1835
  type BundleEventMap = {
1836
+ "bundle-integration-products-added": BundleIntegrationProductsAddedEventData;
1804
1837
  "conditional-global-properties-changed": ConditionalGlobalPropertiesChangedEventData;
1805
1838
  "global-properties-mandatory-changed": GlobalPropertiesMandatoryChangedEventData;
1806
1839
  "workflow-experience-hover-enter": WorkflowExperienceHoverEventData;
@@ -1809,7 +1842,7 @@ type BundleEventMap = {
1809
1842
  "workflow-experience-removed": WorkflowExperienceRemovedEventData;
1810
1843
  };
1811
1844
  type BundleEventType = keyof BundleEventMap;
1812
- type BundleEventData = WorkflowExperienceHoverEventData | ConditionalGlobalPropertiesChangedEventData | WorkflowExperienceAddedEventData;
1845
+ type BundleEventData = BundleIntegrationProductsAddedEventData | WorkflowExperienceHoverEventData | ConditionalGlobalPropertiesChangedEventData | WorkflowExperienceAddedEventData;
1813
1846
  type BundleEvent<K extends BundleEventType = BundleEventType> = BundleEventMap[K];
1814
1847
 
1815
1848
  /**
@@ -2053,6 +2086,8 @@ interface Bundle$1 {
2053
2086
  generateQuoteId(): Promise<string>;
2054
2087
  getQuoteCompleteMessage(): CompleteQuoteMessage;
2055
2088
  applyGlobalPropertyState(state: GlobalPropertyState): Promise<void>;
2089
+ getIntegrationProductIds(): undefined | string[];
2090
+ addIntegrationProductId(id: string): void;
2056
2091
  }
2057
2092
 
2058
2093
  /**
@@ -2357,29 +2392,32 @@ interface GetWorkflowFromTransactionOptions extends GetWorkflowOptionsBase {
2357
2392
  workflowState?: string;
2358
2393
  type: "transaction";
2359
2394
  }
2360
- interface GetNewWorkflowOptionsBase extends GetWorkflowOptionsBase {
2395
+ interface GetNewWorkflowExperienceOptionsBase extends GetWorkflowOptionsBase {
2361
2396
  /** A name for the new transaction. */
2362
2397
  designName?: string;
2363
2398
  /** The workflow to load. */
2364
- workflowId: string;
2399
+ workflowId?: string;
2365
2400
  /** An existing workflow state, if available. */
2366
2401
  workflowState?: string;
2367
2402
  }
2368
- interface GetWorkflowFromIntegrationProductOptions extends GetNewWorkflowOptionsBase {
2403
+ interface GetWorkflowExperienceFromBlankOptions extends GetNewWorkflowExperienceOptionsBase {
2404
+ type: "blank";
2405
+ }
2406
+ interface GetWorkflowExperienceFromIntegrationProductOptions extends GetNewWorkflowExperienceOptionsBase {
2369
2407
  integrationProductId: string;
2370
2408
  quantity?: number;
2371
2409
  recipient?: any;
2372
2410
  type: "integration";
2373
2411
  }
2374
- interface GetWorkflowFromExternalProductOptions extends GetNewWorkflowOptionsBase {
2412
+ interface GetWorkflowExperienceFromExternalProductOptions extends GetNewWorkflowExperienceOptionsBase {
2375
2413
  /** The external ID associated with an integration. */
2376
2414
  externalIntegrationId: string;
2377
2415
  /** The ID of the product from the external system. */
2378
2416
  externalProductId: string;
2379
2417
  type: "external";
2380
2418
  }
2381
- type GetNewWorkflowOptions = GetWorkflowFromIntegrationProductOptions | GetWorkflowFromExternalProductOptions;
2382
- type GetWorkflowOptions = GetWorkflowFromTransactionOptions | GetNewWorkflowOptions;
2419
+ type GetNewWorkflowExperienceOptions = GetWorkflowExperienceFromBlankOptions | GetWorkflowExperienceFromIntegrationProductOptions | GetWorkflowExperienceFromExternalProductOptions;
2420
+ type GetWorkflowOptions = GetWorkflowFromTransactionOptions | GetNewWorkflowExperienceOptions;
2383
2421
  interface ClientConfiguration {
2384
2422
  hubUrl: string;
2385
2423
  serverUrl: string;
@@ -2659,7 +2697,6 @@ interface WorkflowManager {
2659
2697
  getAllLayoutData: () => LayoutState[];
2660
2698
  getLayoutPreviewService: () => LayoutPreviewService | undefined;
2661
2699
  getPreviewService: () => ThreeDPreviewService | undefined;
2662
- getProfanities: () => string[];
2663
2700
  getRegionElements: (stepName: string) => RegionElement[];
2664
2701
  getSerializedStep: (stepName: string, serializedSteps: SerializableStep[]) => SerializableStep | undefined;
2665
2702
  getStepSpecificServices: (stepName: string) => StepSpecificServices | undefined;
@@ -2667,19 +2704,22 @@ interface WorkflowManager {
2667
2704
  getMetadata: (stepName: string) => StepMetadata | undefined;
2668
2705
  getWorkflowMetadata: () => WorkflowMetadata;
2669
2706
  getInformationResults(): InformationResult[];
2670
- getTransaction: () => Transaction;
2671
2707
  getTransactionCustomer: () => Customer | undefined;
2672
2708
  setTransactionCustomer: (customer: Customer) => void;
2709
+ /**
2710
+ * Sets the current workflow for this experience.
2711
+ * @param workflow The new workflow to set.
2712
+ * @returns A promise that resolves when the workflow has been set.
2713
+ */
2714
+ setWorkflow: (workflow: Workflow) => Promise<void>;
2673
2715
  /**
2674
2716
  * @deprecated Use setTransactionCustomer instead.
2675
2717
  */
2676
2718
  setTransactionCustomerDetails: (details: {
2677
2719
  email: string;
2678
2720
  }) => void;
2679
- getWorkflow: () => Workflow;
2680
2721
  getWorkflowSelections: () => WorkflowSelections;
2681
2722
  getStepSelections: () => StepSelections;
2682
- getProduct: () => Product;
2683
2723
  /**
2684
2724
  * A promise resolving when the initial state of the workflow has completed loading.
2685
2725
  */
@@ -2925,6 +2965,10 @@ interface GlobalPropertyConfiguration {
2925
2965
  id: string;
2926
2966
  aspects: GlobalPropertyConfigurationAspect[];
2927
2967
  }
2968
+ declare enum GlobalPropertyConfigurationConditionMode {
2969
+ AND = "AND",
2970
+ OR = "OR"
2971
+ }
2928
2972
  interface GlobalPropertyConfigurationAspect {
2929
2973
  name: string;
2930
2974
  type: AspectType;
@@ -2932,6 +2976,7 @@ interface GlobalPropertyConfigurationAspect {
2932
2976
  description: string;
2933
2977
  entityId?: string;
2934
2978
  conditions?: GlobalPropertyConfigurationAspectCondition[];
2979
+ conditionMode?: GlobalPropertyConfigurationConditionMode;
2935
2980
  data?: GlobalPropertyConfigurationAspectData;
2936
2981
  mandatory?: boolean;
2937
2982
  }
@@ -5178,6 +5223,7 @@ declare class MockWorkflowManager implements WorkflowManager {
5178
5223
  getWorkflowExperience(): WorkflowExperience;
5179
5224
  setClient(client: SpiffCommerceClient): void;
5180
5225
  getInitializationPromise(): Promise<void>;
5226
+ setWorkflow: (workflow: Workflow) => Promise<void>;
5181
5227
  getProduct: () => Product;
5182
5228
  isInitialized(): boolean;
5183
5229
  getCommandContext: () => CommandContext;
@@ -5208,7 +5254,6 @@ declare class MockWorkflowManager implements WorkflowManager {
5208
5254
  getPreviewService(): undefined;
5209
5255
  setModelContainer: (container: any) => void;
5210
5256
  getModelContainer(): undefined;
5211
- getProfanities(): never[];
5212
5257
  getRegionElements(_stepName: string): never[];
5213
5258
  getSerializedStep(_stepName: string, _serializedSteps: SerializableStep[]): undefined;
5214
5259
  getStepSpecificServices(_stepName: string): undefined;
@@ -6034,4 +6079,4 @@ declare const overrideWorkflowExperienceRecipientAddress: (workflowExperience: W
6034
6079
  */
6035
6080
  declare const getGlobalPropertyStateForBundle: (bundleId: string) => Promise<GlobalPropertyState | undefined>;
6036
6081
 
6037
- export { AddonHandle, type AddressComponent, type AddressValidationJob, AddressValidationJobStatus, type AddressValidationResult, AddressValidationResultConfirmationLevel, AddressValidationStatus, type Animatable, type AnyStepData, ArrayInput, AspectType, type Asset, type AssetConfiguration, AssetNotFoundError, type AssetObjectVersion, AssetType, BringForwardCommand, BringToBackCommand, BringToFrontCommand, type Bundle$1 as Bundle, BundleDesignCreationCartAddMode, type BundleDesignCreationMessage, type BundleEvent, type BundleEventData, type BundleEventType, type Bundle as BundleRaw, type BundleStakeholder, CanvasCommand, CollectionProduct, type ColorDefinition, type ColorOption, ColorOptionGlobalPropertyHandle, type ColorProfileProps, CommandContext, type CommandState, type Condition, type ConditionalGlobalPropertiesChangedEventData, CreateElementCommand, CreateLayoutCommand, CurrencyContext, CurrencyService, type Customer, type CustomerDetailsInput, DeleteElementCommand, type DesignCreationMessage, type DesignCreationProgressUpdate, type DesignInputStep, type DigitalContentStepData, DigitalContentStepHandle, type EditedSteps, type ExportedStepData, type ExportedStepDataProperty, type ExportedStepDataPropertyType, FileUploadGlobalPropertyHandle, FlowExecutionNodeResult, FlowExecutionResult, FlowService, FontAlignmentCommand, FontColorCommand, FontSizeCommand, FontSourceCommand, type FrameElement, FrameService, FrameStep, type FrameStepData, FrameStepHandle, type FrameThresholdSettings, type GetNewWorkflowOptions, type GetWorkflowOptions, type GlobalPropertiesMandatoryChangedEventData, type GlobalPropertyConfiguration, GlobalPropertyHandle, GroupCommand, type ILayout, type IllustrationElement, type IllustrationStepData, IllustrationStepHandle, type ImageElement, InformationMessageType, type InformationResult, type InformationStepData, InformationStepHandle, type Integration, type IntegrationOptionResource, IntegrationProduct, IntegrationType, type LayoutComponentConfiguration, type LayoutData, type LayoutElement, LayoutElementFactory, LayoutElementType, LayoutNotFoundError, LayoutRenderingPurpose, type LayoutState, type LayoutsState, type MandatorySteps, MaterialEffectMode, type MaterialStepData, MaterialStepHandle, MisconfigurationError, MockWorkflowManager, type ModelStepData, ModelStepHandle, type ModuleStepData, ModuleStepHandle, MoveCommand, NodeType, ObjectInput, ObjectInputType, OptionGlobalPropertyHandle, OptionNotFoundError, type OptionResource, type Order, type OrderItem, type PapyrusComponent, ParseError, type PictureStepData, PictureStepHandle, type Placeable, type PmsSearchResult, type Point, type Product, ProductCameraRig, ProductCollection, ProductCollectionProductSortKey, ProductWorkflow$1 as ProductWorkflow, promiseCache as PromiseCache, PromiseQueue, type QuestionStepData, QuestionStepHandle, QueueablePromise, type Recipient, type Region, type RegionElement, type RenderableScene, ResizeCommand, ResourceNotFoundError, RotateCommand, type SavedDesign, ScaleAxis, type SelectionStorage, SendBackwardsCommand, type ShapeStepData, ShapeStepHandle, type ShareAction, ShareActionType, type SilentIllustrationStepData, SpiffCommerceClient, type Stakeholder, StakeholderType, type StateMutationFunc, type Step, type StepAspect, StepAspectType, type StepElements, type StepGroup, StepHandle, type StepStorage, StepType, TextAlgorithm, TextChangeCommand, type TextChangeResult, TextGlobalPropertyHandle, TextInput, type TextStepData, TextStepHandle, type TextStepStorage, type TextboxElement, type Theme, type ToastCallback, type Transaction, Transform, TransformCollection$1 as TransformCollection, UnhandledBehaviorError, UnitOfMeasurement, UpdateImageSourceCommand, Variant, type VariantResource, type Vector3, type Workflow, type WorkflowExperience, WorkflowExperienceEventType, type WorkflowExperienceHoverEventData, WorkflowExperienceImpl, type WorkflowManager, type WorkflowMetadata, type WorkflowPanel, type WorkflowScene, type WorkflowSelections, type WorkflowStorage, assetService, browserColorToHex, cmPerPixel, createDesign, currentDirection, dataUrlFromExternalUrl, deleteBundle, designService, determineCorrectFontSizeAndLines, digitalContentStepService, domParser, duplicateBundle, duplicateTransaction, fetchAsString, findAngle, findElement, findPmsColors, frameDataCache, frameStepService, generate, generateCommands, generateSVGWithUnknownColors, generateStateFromDesignInputSteps, getAddressValidationJobs, getAttributesFromArrayBuffer, getAxisAlignedBoundingBox, getBoundedOffsets, getBundleThemeConfiguration, getCustomer, getCustomerBundles, getElementVertices, getFrameData, getGlobalPropertyStateForBundle, getIntegration, getNEPoint, getNWPoint, getOrderedTransactions, getOverrideThemeConfiguration, getPointOfRotation, getProductCollections, getSEPoint, getSvgElement, getTemplateBundles, getTemplateTransactions, getTransaction, getTransactionThemeConfiguration, getTransactionsForBundle, getTrueCoordinates, getUnorderedTransactions, getValidationJobsForWorkflowExperiences, getWorkflow, getWorkflows, graphQlManager, illustrationStepService, isCloseToValue, loadFont, matchHexToPms, materialStepService, metafieldManager, mmPerPixel, modelStepService, modifySVGColors, moduleStepService, nameBundle, nameTransaction, optionService, outlineFontsInSvg, overrideWorkflowExperienceRecipientAddress, patternImageDataCache, persistenceService, pictureStepService, pmsToRgb, questionStepService, registerFetchImplementation, registerWindowImplementation, rehydrateSerializedLayout, rgbToPms, rotateAroundPoint, sanitizeSvgTree, setBearerAuthenticationToken, setCanvasModule, shapeStepService, shortenUrl, spiffCoreConfiguration, stepAspectValuesToDesignInputSteps, svgColorValueToDefinition, svgStringDimensions, svgToDataUrl, textStepService, toast, validateWorkflowExperienceRecipient, validateWorkflowExperienceRecipients, xmlSerializer };
6082
+ export { AddonHandle, type AddressComponent, type AddressValidationJob, AddressValidationJobStatus, type AddressValidationResult, AddressValidationResultConfirmationLevel, AddressValidationStatus, type Animatable, type AnyStepData, ArrayInput, AspectType, type Asset, type AssetConfiguration, AssetNotFoundError, type AssetObjectVersion, AssetType, BringForwardCommand, BringToBackCommand, BringToFrontCommand, type Bundle$1 as Bundle, BundleDesignCreationCartAddMode, type BundleDesignCreationMessage, type BundleEvent, type BundleEventData, type BundleEventType, type Bundle as BundleRaw, type BundleStakeholder, CanvasCommand, CollectionProduct, type ColorDefinition, type ColorOption, ColorOptionGlobalPropertyHandle, type ColorProfileProps, CommandContext, type CommandState, type Condition, type ConditionalGlobalPropertiesChangedEventData, CreateElementCommand, CreateLayoutCommand, CurrencyContext, CurrencyService, type Customer, type CustomerDetailsInput, DeleteElementCommand, type DesignCreationMessage, type DesignCreationProgressUpdate, type DesignInputStep, type DigitalContentStepData, DigitalContentStepHandle, type EditedSteps, type ExportedStepData, type ExportedStepDataProperty, type ExportedStepDataPropertyType, FileUploadGlobalPropertyHandle, FlowExecutionNodeResult, FlowExecutionResult, FlowService, FontAlignmentCommand, FontColorCommand, FontSizeCommand, FontSourceCommand, type FrameElement, FrameService, FrameStep, type FrameStepData, FrameStepHandle, type FrameThresholdSettings, type GetNewWorkflowExperienceOptions as GetNewWorkflowOptions, type GetWorkflowOptions, type GlobalPropertiesMandatoryChangedEventData, type GlobalPropertyConfiguration, GlobalPropertyHandle, GroupCommand, type ILayout, type IllustrationElement, type IllustrationStepData, IllustrationStepHandle, type ImageElement, InformationMessageType, type InformationResult, type InformationStepData, InformationStepHandle, type Integration, type IntegrationOptionResource, IntegrationProduct, IntegrationType, type LayoutComponentConfiguration, type LayoutData, type LayoutElement, LayoutElementFactory, LayoutElementType, LayoutNotFoundError, LayoutRenderingPurpose, type LayoutState, type LayoutsState, type MandatorySteps, MaterialEffectMode, type MaterialStepData, MaterialStepHandle, MisconfigurationError, MockWorkflowManager, type ModelStepData, ModelStepHandle, type ModuleStepData, ModuleStepHandle, MoveCommand, NodeType, ObjectInput, ObjectInputType, OptionGlobalPropertyHandle, OptionNotFoundError, type OptionResource, type Order, type OrderItem, type PapyrusComponent, ParseError, type PictureStepData, PictureStepHandle, type Placeable, type PmsSearchResult, type Point, type Product, ProductCameraRig, ProductCollection, ProductCollectionProductSortKey, ProductWorkflow$1 as ProductWorkflow, promiseCache as PromiseCache, PromiseQueue, type QuestionStepData, QuestionStepHandle, QueueablePromise, type Recipient, type Region, type RegionElement, type RenderableScene, ResizeCommand, ResourceNotFoundError, RotateCommand, type SavedDesign, ScaleAxis, type SelectionStorage, SendBackwardsCommand, type ShapeStepData, ShapeStepHandle, type ShareAction, ShareActionType, type SilentIllustrationStepData, SpiffCommerceClient, type Stakeholder, StakeholderType, type StateMutationFunc, type Step, type StepAspect, StepAspectType, type StepElements, type StepGroup, StepHandle, type StepStorage, StepType, TextAlgorithm, TextChangeCommand, type TextChangeResult, TextGlobalPropertyHandle, TextInput, type TextStepData, TextStepHandle, type TextStepStorage, type TextboxElement, type Theme, type ToastCallback, type Transaction, Transform, TransformCollection$1 as TransformCollection, UnhandledBehaviorError, UnitOfMeasurement, UpdateImageSourceCommand, Variant, type VariantResource, type Vector3, type Workflow, type WorkflowExperience, WorkflowExperienceEventType, type WorkflowExperienceHoverEventData, WorkflowExperienceImpl, type WorkflowManager, type WorkflowMetadata, type WorkflowPanel, type WorkflowScene, type WorkflowSelections, type WorkflowStorage, assetService, browserColorToHex, cmPerPixel, createDesign, currentDirection, dataUrlFromExternalUrl, deleteBundle, designService, determineCorrectFontSizeAndLines, digitalContentStepService, domParser, duplicateBundle, duplicateTransaction, fetchAsString, findAngle, findElement, findPmsColors, frameDataCache, frameStepService, generate, generateCommands, generateSVGWithUnknownColors, generateStateFromDesignInputSteps, getAddressValidationJobs, getAttributesFromArrayBuffer, getAxisAlignedBoundingBox, getBoundedOffsets, getBundleThemeConfiguration, getCustomer, getCustomerBundles, getElementVertices, getFrameData, getGlobalPropertyStateForBundle, getIntegration, getNEPoint, getNWPoint, getOrderedTransactions, getOverrideThemeConfiguration, getPointOfRotation, getProductCollections, getSEPoint, getSvgElement, getTemplateBundles, getTemplateTransactions, getTransaction, getTransactionThemeConfiguration, getTransactionsForBundle, getTrueCoordinates, getUnorderedTransactions, getValidationJobsForWorkflowExperiences, getWorkflow, getWorkflows, graphQlManager, illustrationStepService, isCloseToValue, loadFont, matchHexToPms, materialStepService, metafieldManager, mmPerPixel, modelStepService, modifySVGColors, moduleStepService, nameBundle, nameTransaction, optionService, outlineFontsInSvg, overrideWorkflowExperienceRecipientAddress, patternImageDataCache, persistenceService, pictureStepService, pmsToRgb, questionStepService, registerFetchImplementation, registerWindowImplementation, rehydrateSerializedLayout, rgbToPms, rotateAroundPoint, sanitizeSvgTree, setBearerAuthenticationToken, setCanvasModule, shapeStepService, shortenUrl, spiffCoreConfiguration, stepAspectValuesToDesignInputSteps, svgColorValueToDefinition, svgStringDimensions, svgToDataUrl, textStepService, toast, validateWorkflowExperienceRecipient, validateWorkflowExperienceRecipients, xmlSerializer };