@spiffcommerce/core 0.8.8 → 0.8.9
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/main.js +9 -9
- package/dist/module.js +9 -9
- package/dist/types.d.ts +8 -3
- package/package.json +9 -4
package/dist/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Workflow as _Workflow1, StepAspect as _StepAspect1, Step as _Step1, AnyStepData as _AnyStepData1, FrameOffsets, PatternImageData, IServerModel, Asset as _Asset1, MaterialResource, AssetType as _AssetType1, ColorDefinition as _ColorDefinition1, IllustrationStepData as _IllustrationStepData1, Region, ILayout as _ILayout1, CreateElementCommand as _CreateElementCommand1, IllustrationElement as _IllustrationElement1, LayoutsState as _LayoutsState1, VariantResource as _VariantResource1, CanvasCommand as _CanvasCommand1, LayoutData as _LayoutData1, DigitalContentStepData as _DigitalContentStepData1, FrameStepData as _FrameStepData1, FrameElement as _FrameElement1, MaterialStepData as _MaterialStepData1, ModelStepData as _ModelStepData1, ModuleStepData as _ModuleStepData1, PatchworkStepData as _PatchworkStepData1, PatchworkOffsets as _PatchworkOffsets1, PictureStepData as _PictureStepData1, QuestionStepData as _QuestionStepData1, ShapeStepData as _ShapeStepData1, FontData, GroupCommand as _GroupCommand1, TextboxElement as _TextboxElement1, TextStepData as _TextStepData1, StepStorage as _StepStorage1, SerializableStep, CommandState as _CommandState1,
|
|
1
|
+
import { Workflow as _Workflow1, StepAspect as _StepAspect1, Step as _Step1, AnyStepData as _AnyStepData1, FrameOffsets, PatternImageData, IServerModel, Asset as _Asset1, MaterialResource, AssetType as _AssetType1, ColorDefinition as _ColorDefinition1, IllustrationStepData as _IllustrationStepData1, Region, ILayout as _ILayout1, CreateElementCommand as _CreateElementCommand1, IllustrationElement as _IllustrationElement1, LayoutsState as _LayoutsState1, VariantResource as _VariantResource1, CanvasCommand as _CanvasCommand1, LayoutData as _LayoutData1, DigitalContentStepData as _DigitalContentStepData1, FrameStepData as _FrameStepData1, FrameElement as _FrameElement1, MaterialStepData as _MaterialStepData1, ModelStepData as _ModelStepData1, ModuleStepData as _ModuleStepData1, PatchworkStepData as _PatchworkStepData1, PatchworkOffsets as _PatchworkOffsets1, PictureStepData as _PictureStepData1, QuestionStepData as _QuestionStepData1, ShapeStepData as _ShapeStepData1, FontData, GroupCommand as _GroupCommand1, OptionResource as _OptionResource1, TextboxElement as _TextboxElement1, TextStepData as _TextStepData1, StepStorage as _StepStorage1, SerializableStep, CommandState as _CommandState1, CommandContext as _CommandContext1, Point, ScaleAxis, UnitOfMeasurement as _UnitOfMeasurement1, StepType as _StepType1, Animatable, AnyStepData, Asset, AssetType, BringForwardCommand, BulkStepData, CanvasCommand, ColorDefinition, CommandContext, CommandState, CreateElementCommand, DeleteElementCommand, DigitalContentStepData, FontAlignmentCommand, FontColorCommand, FontSizeCommand, FontSourceCommand, FrameElement, FrameStepData, GroupCommand, ILayout, IllustrationElement, IllustrationStepData, ImageElement, LayoutData, LayoutElement, LayoutElementFactory, LayoutElementType, LayoutsState, MaterialStepData, ModelStepData, ModuleStepData, MoveCommand, OptionResource, PatchworkElement, PatchworkOffsets, PatchworkStepData, PictureStepData, QuestionStepData, ResizeCommand, RotateCommand, SendBackwardsCommand, ShapeStepData, Step, StepAspect, StepAspectType, StepStorage, StepType, TextChangeCommand, TextStepData, TextboxElement, UnitOfMeasurement, VariantResource, Workflow, dataUrlFromExternalUrl, findElement, frameDataCache, generate, generateSVGWithUnknownColors, getAttributesFromArrayBuffer, getFrameData, getSvgString, loadFontFromDataUrl, loadFontFromExternalUrl, patternImageDataCache, CreateLayoutCommand, rehydrateSerializedLayout, ColorProfileProps, WorkflowPanel, determineCorrectFontSizeAndLines, registerJSDOM } from "@spiffcommerce/papyrus";
|
|
2
2
|
import { ApolloClient } from "@apollo/client";
|
|
3
3
|
import { ReactNode, Dispatch, FunctionComponent, RefObject, PointerEvent, KeyboardEvent, MouseEvent } from "react";
|
|
4
4
|
export const gatherVaryingStepAspects: (workflow: _Workflow1) => _StepAspect1[];
|
|
@@ -279,6 +279,10 @@ declare class Toast {
|
|
|
279
279
|
setLatestToast(errorMessage: null | string, errorType: InformationMessageType | null): void;
|
|
280
280
|
}
|
|
281
281
|
export const toast: Toast;
|
|
282
|
+
interface TextFillSpotColor {
|
|
283
|
+
profileName: string;
|
|
284
|
+
namedColor: string;
|
|
285
|
+
}
|
|
282
286
|
interface TextUpdateResult {
|
|
283
287
|
command?: _GroupCommand1;
|
|
284
288
|
helperText: string;
|
|
@@ -300,6 +304,7 @@ declare class TextStepService implements StepService<_TextStepData1> {
|
|
|
300
304
|
* @returns A list of color objects containg fill, stroke and variant if available.
|
|
301
305
|
*/
|
|
302
306
|
availableColors(stepData: _Step1<_TextStepData1>): ColorOption[];
|
|
307
|
+
createTextFillSpotColor(colorOption: IServerModel<_OptionResource1>, variant: _VariantResource1): TextFillSpotColor | undefined;
|
|
303
308
|
changeColor(stepData: _Step1<_TextStepData1>, newColor: ColorOption, elements: RegionElement[], workflowManager: WorkflowManager): Promise<void>;
|
|
304
309
|
/**
|
|
305
310
|
* Given an element and a string, filters any characters from the string that are
|
|
@@ -1236,7 +1241,7 @@ export class MockWorkflowManager implements WorkflowManager {
|
|
|
1236
1241
|
updateStorage(_stepName: string, _update: _StepStorage1): Promise<void>;
|
|
1237
1242
|
}
|
|
1238
1243
|
export { CommandContext };
|
|
1239
|
-
export { AssetType, BringForwardCommand, CanvasCommand, CreateElementCommand, CreateLayoutCommand, DeleteElementCommand, FontAlignmentCommand, FontColorCommand, FontSizeCommand, FontSourceCommand, GroupCommand, LayoutElementFactory, LayoutElementType, MoveCommand, ResizeCommand, RotateCommand, SendBackwardsCommand, StepAspectType, StepType, TextChangeCommand, UnitOfMeasurement, dataUrlFromExternalUrl, findElement, frameDataCache, generate, generateSVGWithUnknownColors, getAttributesFromArrayBuffer, rehydrateSerializedLayout, getFrameData, getSvgString, loadFontFromDataUrl, loadFontFromExternalUrl, determineCorrectFontSizeAndLines, patternImageDataCache };
|
|
1240
|
-
export {
|
|
1244
|
+
export { AssetType, BringForwardCommand, CanvasCommand, CreateElementCommand, CreateLayoutCommand, DeleteElementCommand, FontAlignmentCommand, FontColorCommand, FontSizeCommand, FontSourceCommand, GroupCommand, LayoutElementFactory, LayoutElementType, MoveCommand, ResizeCommand, RotateCommand, SendBackwardsCommand, StepAspectType, StepType, TextChangeCommand, UnitOfMeasurement, dataUrlFromExternalUrl, findElement, frameDataCache, generate, generateSVGWithUnknownColors, getAttributesFromArrayBuffer, rehydrateSerializedLayout, getFrameData, getSvgString, loadFontFromDataUrl, loadFontFromExternalUrl, determineCorrectFontSizeAndLines, patternImageDataCache, registerJSDOM };
|
|
1245
|
+
export { Animatable, AnyStepData, Asset, BulkStepData, ColorProfileProps, ColorDefinition, CommandState, WorkflowPanel, DigitalContentStepData, FrameElement, FrameStepData, ILayout, IllustrationElement, IllustrationStepData, ImageElement, LayoutData, LayoutElement, LayoutsState, MaterialStepData, ModelStepData, ModuleStepData, OptionResource, PatchworkElement, PatchworkOffsets, PatchworkStepData, PictureStepData, QuestionStepData, ShapeStepData, Step, StepAspect, StepStorage, TextStepData, TextboxElement, VariantResource, Workflow };
|
|
1241
1246
|
|
|
1242
1247
|
//# sourceMappingURL=types.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@spiffcommerce/core",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.9",
|
|
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",
|
|
@@ -9,12 +9,15 @@
|
|
|
9
9
|
"scripts": {
|
|
10
10
|
"build": "parcel build",
|
|
11
11
|
"watch": "parcel watch",
|
|
12
|
-
"test": "jest",
|
|
12
|
+
"test": "jest && tsc --noEmit --isolatedModules",
|
|
13
13
|
"prepare": "yarn run build"
|
|
14
14
|
},
|
|
15
15
|
"targets": {
|
|
16
16
|
"main": {
|
|
17
|
-
"optimize": true
|
|
17
|
+
"optimize": true,
|
|
18
|
+
"includeNodeModules": [
|
|
19
|
+
"@spiffcommerce/papyrus"
|
|
20
|
+
]
|
|
18
21
|
},
|
|
19
22
|
"module": {
|
|
20
23
|
"optimize": true
|
|
@@ -37,10 +40,12 @@
|
|
|
37
40
|
"@parcel/packager-ts": "2.7.0",
|
|
38
41
|
"@parcel/transformer-typescript-tsc": "^2.7.0",
|
|
39
42
|
"@parcel/transformer-typescript-types": "^2.7.0",
|
|
43
|
+
"@parcel/validator-typescript": "^2.7.0",
|
|
40
44
|
"@types/jest": "^29.0.3",
|
|
41
45
|
"@types/lodash.clonedeep": "^4.5.7",
|
|
42
46
|
"@types/lodash.debounce": "^4.0.7",
|
|
43
47
|
"@types/lodash.isequal": "^4.5.6",
|
|
48
|
+
"@types/offscreencanvas": "^2019.7.0",
|
|
44
49
|
"@types/opentype.js": "^0.7.2",
|
|
45
50
|
"@types/qrcode": "^1.3.5",
|
|
46
51
|
"@types/react": "^17.0.9",
|
|
@@ -62,7 +67,7 @@
|
|
|
62
67
|
},
|
|
63
68
|
"dependencies": {
|
|
64
69
|
"@apollo/client": "^3.7.0",
|
|
65
|
-
"@spiffcommerce/papyrus": "^1.4.
|
|
70
|
+
"@spiffcommerce/papyrus": "^1.4.9",
|
|
66
71
|
"canvg": "https://github.com/spiffdev/canvg.git#03bcd151b12441e88ecb552bb658356f5bbe92c4",
|
|
67
72
|
"cross-fetch": "^3.1.5",
|
|
68
73
|
"graphql": "^16.6.0",
|