@spiffcommerce/core 0.10.25 → 0.10.27

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/dist/types.d.ts CHANGED
@@ -348,12 +348,12 @@ declare class TextStepService implements StepService<_TextStepData1> {
348
348
  /**
349
349
  * Given an element and a string, filters any characters from the string that are
350
350
  * not supported by the font of the given element.
351
- * @param layoutElement The element to use for glyph lookup.
352
351
  * @param text The text string to filter.
353
352
  * @param fontData An optional fontData object, when provided, we use the font table to determine glyphs that aren't provided and additionally strip these out also.
354
353
  * @returns A new string representing the passed string with unsupported characters removed.
355
354
  */
356
355
  filterUnsupportedCharacters: (text: string, fontData?: FontData) => string;
356
+ getProcessedInput(input: string, stepData: _TextStepData1, customiseAllText: boolean): string;
357
357
  updateInputText(input: string, elements: _TextboxElement1[], step: _Step1<_TextStepData1>, workflowManager: WorkflowManager): TextUpdateResult;
358
358
  selectVariant(step: _Step1<_TextStepData1>, variant: _VariantResource1, workflowManager: WorkflowManager, setError: (status: boolean) => void, setHelperText: (text: string) => void): void;
359
359
  textAlign: (stepData: _TextStepData1) => string;
@@ -1111,6 +1111,7 @@ export abstract class StepHandle<T extends _AnyStepData1> {
1111
1111
  * @returns The name of the step
1112
1112
  */
1113
1113
  getName(): string;
1114
+ getId(): string;
1114
1115
  /**
1115
1116
  * @returns The type of the step handle.
1116
1117
  */
@@ -1181,6 +1182,17 @@ export class TextStepHandle extends StepHandle<_TextStepData1> {
1181
1182
  * Gets the text currently applied to the elements of this step.
1182
1183
  */
1183
1184
  getText(): string;
1185
+ isReplaceable(): boolean;
1186
+ /**
1187
+ * Inform the step that now is the time to
1188
+ * clear default text if it should do so.
1189
+ * Returns a text change rwsult if a clear occurred.
1190
+ */
1191
+ clearDefaultTextIfNecessary(): TextChangeResult | undefined;
1192
+ hasVaryingText(): boolean;
1193
+ hasVaryingColor(): boolean;
1194
+ hasVaryingSelection(): boolean;
1195
+ getRegions(): import("@spiffcommerce/papyrus").Region[];
1184
1196
  }
1185
1197
  /**
1186
1198
  * A Workflow experience encapsulates the workflow manager and command context. It
@@ -1227,7 +1239,7 @@ export interface WorkflowExperience {
1227
1239
  /**
1228
1240
  * Creates a data URL preview for the current design.
1229
1241
  */
1230
- createPreviewImage(): Promise<string>;
1242
+ createPreviewImage(resolution?: number): Promise<string>;
1231
1243
  /**
1232
1244
  * To be called when the workflow experience is considered completed by the user.
1233
1245
  * @param product
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@spiffcommerce/core",
3
- "version": "0.10.25",
3
+ "version": "0.10.27",
4
4
  "description": "Core client API for interacting with the Spiff Commerce backend.",
5
5
  "source": "src/index.ts",
6
6
  "main": "dist/main.js",