@spiffcommerce/core 16.0.3-0 → 16.2.0
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/index.d.ts +53 -12
- package/dist/index.js +670 -620
- package/dist/index.umd.cjs +52 -42
- package/package.json +1 -2
package/dist/index.d.ts
CHANGED
|
@@ -943,8 +943,16 @@ type ProductCollectionResource = {
|
|
|
943
943
|
id: string;
|
|
944
944
|
globalPropertyConfiguration?: GlobalPropertyConfiguration;
|
|
945
945
|
name: string;
|
|
946
|
-
|
|
947
|
-
transformCollection?: TransformCollection;
|
|
946
|
+
productCollectionProducts: ProductCollectionProductResource[];
|
|
947
|
+
transformCollection?: TransformCollection$1;
|
|
948
|
+
};
|
|
949
|
+
type ProductCollectionProductResource = {
|
|
950
|
+
id: string;
|
|
951
|
+
productCollection?: ProductCollectionResource;
|
|
952
|
+
productCollectionId?: string;
|
|
953
|
+
product: Product;
|
|
954
|
+
productId: string;
|
|
955
|
+
workflowId?: string;
|
|
948
956
|
};
|
|
949
957
|
type GlobalPropertyState = {
|
|
950
958
|
id: string;
|
|
@@ -964,7 +972,7 @@ interface Vector3 {
|
|
|
964
972
|
y: number;
|
|
965
973
|
z: number;
|
|
966
974
|
}
|
|
967
|
-
interface TransformCollection {
|
|
975
|
+
interface TransformCollection$1 {
|
|
968
976
|
id: string;
|
|
969
977
|
name: string;
|
|
970
978
|
transforms: TransformCollectionTransform[];
|
|
@@ -1560,6 +1568,7 @@ declare class ProductCollection {
|
|
|
1560
1568
|
* A list of products in this collections with useful helpers for interacting with them.
|
|
1561
1569
|
*/
|
|
1562
1570
|
getProducts(): CollectionProduct[];
|
|
1571
|
+
getTransformCollection(): TransformCollection | undefined;
|
|
1563
1572
|
/**
|
|
1564
1573
|
* The raw collection resource. This is generally not needed and should be avoided.
|
|
1565
1574
|
*/
|
|
@@ -1570,7 +1579,8 @@ declare class ProductCollection {
|
|
|
1570
1579
|
*/
|
|
1571
1580
|
declare class CollectionProduct {
|
|
1572
1581
|
private readonly product;
|
|
1573
|
-
|
|
1582
|
+
private readonly productResource;
|
|
1583
|
+
constructor(productCollectionProduct: ProductCollectionProductResource);
|
|
1574
1584
|
/**
|
|
1575
1585
|
* The ID of the product in SpiffCommerce.
|
|
1576
1586
|
* @returns
|
|
@@ -1619,6 +1629,44 @@ declare class ProductWorkflow {
|
|
|
1619
1629
|
*/
|
|
1620
1630
|
getThumbnail(): string;
|
|
1621
1631
|
}
|
|
1632
|
+
/**
|
|
1633
|
+
* Represents a collection of transforms that can be applied inside a product collection.
|
|
1634
|
+
*/
|
|
1635
|
+
declare class TransformCollection {
|
|
1636
|
+
private readonly collection;
|
|
1637
|
+
constructor(collection: TransformCollection$1);
|
|
1638
|
+
/**
|
|
1639
|
+
* @returns The ID of the transform collection.
|
|
1640
|
+
*/
|
|
1641
|
+
getId(): string;
|
|
1642
|
+
/**
|
|
1643
|
+
* @returns The name of the transform collection.
|
|
1644
|
+
*/
|
|
1645
|
+
getName(): string;
|
|
1646
|
+
/**
|
|
1647
|
+
* @returns The transforms in this collection.
|
|
1648
|
+
*/
|
|
1649
|
+
getTransforms(): Transform[];
|
|
1650
|
+
}
|
|
1651
|
+
/**
|
|
1652
|
+
* Represents the translations, rotation & scale of a product in 3D space.
|
|
1653
|
+
*/
|
|
1654
|
+
declare class Transform {
|
|
1655
|
+
private readonly transform;
|
|
1656
|
+
constructor(position: TransformCollectionTransform);
|
|
1657
|
+
/**
|
|
1658
|
+
* @returns The ID of the transform.
|
|
1659
|
+
*/
|
|
1660
|
+
getId(): string;
|
|
1661
|
+
/**
|
|
1662
|
+
* @returns The name of the transform.
|
|
1663
|
+
*/
|
|
1664
|
+
getName(): string;
|
|
1665
|
+
/**
|
|
1666
|
+
* @returns The transformation to be used to place the object.
|
|
1667
|
+
*/
|
|
1668
|
+
get(): BundleStateTransform;
|
|
1669
|
+
}
|
|
1622
1670
|
|
|
1623
1671
|
/**
|
|
1624
1672
|
* A bundle serves as a container for a set of workflow experience.
|
|
@@ -1995,13 +2043,6 @@ interface ClientOptions {
|
|
|
1995
2043
|
* authenticate with the SpiffCommerce API.
|
|
1996
2044
|
*/
|
|
1997
2045
|
applicationKey?: string;
|
|
1998
|
-
/**
|
|
1999
|
-
* When set to true, the client will instantiate a service for tracking internal errors. This allows
|
|
2000
|
-
* us to track errors that occur within the client, and improve the experience for our users.
|
|
2001
|
-
*
|
|
2002
|
-
* NOTE: True by default, you may disable if you have privacy requirements.
|
|
2003
|
-
*/
|
|
2004
|
-
internalAnalytics?: boolean;
|
|
2005
2046
|
}
|
|
2006
2047
|
interface GetWorkflowGraphqlAssetsOptions {
|
|
2007
2048
|
metadata?: boolean;
|
|
@@ -2797,4 +2838,4 @@ interface StepAspectValue {
|
|
|
2797
2838
|
declare const stepAspectValuesToDesignInputSteps: (stepAspectValues: StepAspectValue[], workflow: Workflow) => DesignInputStep[];
|
|
2798
2839
|
declare const generateStateFromDesignInputSteps: (designInputSteps: DesignInputStep[], workflow: Workflow, layouts: ILayout[], productOverlayImageUrl?: string) => Promise<LayoutsState>;
|
|
2799
2840
|
|
|
2800
|
-
export { AssetNotFoundError, BulkPriceCalculationStrategy, BulkStepHandle, Bundle, CollectionProduct, ColorOption, ConversionConfiguration, ConversionData, ConversionDataType, ConversionLocation, Customer, CustomerDetailsInput, DesignCreationMessage, DesignCreationProgressUpdate, DesignInputStep, EditedSteps, FlowExecutionNodeResult, FlowExecutionResult, FlowService, FrameService, FrameStep, FrameStepHandle, GetWorkflowOptions, GlobalPropertyHandle, IllustrationStepHandle, InformationMessageType, InformationResult, InformationStepHandle, LayoutNotFoundError, MandatorySteps, MaterialStepHandle, MisconfigurationError, MockWorkflowManager, ModelStepHandle, NodeType, ObjectInput, ObjectInputType, OptionNotFoundError, ParseError, PictureStepHandle, Product, ProductCameraRig, ProductCollection, ProductWorkflow, PromiseQueue, QuestionStepHandle, QueueablePromise, RegionElement, RenderableScene, ResourceNotFoundError, SavedDesign, SelectionStorage, ShapeStepHandle, SilentIllustrationStepData, SpiffCommerceClient, Stakeholder, StakeholderType, StateMutationFunc, StepElements, StepHandle, TextStepHandle, TextStepStorage, Transaction, UnhandledBehaviorError, Variant, VariationRecord, WorkflowExperience, WorkflowExperienceImpl, WorkflowManager, WorkflowMetadata, WorkflowScene, WorkflowSelections, WorkflowStorage, assetService, createDesign, designService, digitalContentStepService, frameStepService, gatherVaryingStepAspects, generateCommands, generateStateFromDesignInputSteps, getBoundedOffsets, getWorkflow, getWorkflows, graphQlManager, illustrationStepService, materialStepService, modelStepService, moduleStepService, optionService, persistenceService, pictureStepService, questionStepService, shapeStepService, shortenUrl, spiffCoreConfiguration, stepAspectValuesToDesignInputSteps, textStepService, toast };
|
|
2841
|
+
export { AssetNotFoundError, BulkPriceCalculationStrategy, BulkStepHandle, Bundle, CollectionProduct, ColorOption, ConversionConfiguration, ConversionData, ConversionDataType, ConversionLocation, Customer, CustomerDetailsInput, DesignCreationMessage, DesignCreationProgressUpdate, DesignInputStep, EditedSteps, FlowExecutionNodeResult, FlowExecutionResult, FlowService, FrameService, FrameStep, FrameStepHandle, GetWorkflowOptions, GlobalPropertyHandle, IllustrationStepHandle, InformationMessageType, InformationResult, InformationStepHandle, LayoutNotFoundError, MandatorySteps, MaterialStepHandle, MisconfigurationError, MockWorkflowManager, ModelStepHandle, NodeType, ObjectInput, ObjectInputType, OptionNotFoundError, ParseError, PictureStepHandle, Product, ProductCameraRig, ProductCollection, ProductWorkflow, PromiseQueue, QuestionStepHandle, QueueablePromise, RegionElement, RenderableScene, ResourceNotFoundError, SavedDesign, SelectionStorage, ShapeStepHandle, SilentIllustrationStepData, SpiffCommerceClient, Stakeholder, StakeholderType, StateMutationFunc, StepElements, StepHandle, TextStepHandle, TextStepStorage, Transaction, Transform, TransformCollection, UnhandledBehaviorError, Variant, VariationRecord, Vector3, WorkflowExperience, WorkflowExperienceImpl, WorkflowManager, WorkflowMetadata, WorkflowScene, WorkflowSelections, WorkflowStorage, assetService, createDesign, designService, digitalContentStepService, frameStepService, gatherVaryingStepAspects, generateCommands, generateStateFromDesignInputSteps, getBoundedOffsets, getWorkflow, getWorkflows, graphQlManager, illustrationStepService, materialStepService, modelStepService, moduleStepService, optionService, persistenceService, pictureStepService, questionStepService, shapeStepService, shortenUrl, spiffCoreConfiguration, stepAspectValuesToDesignInputSteps, textStepService, toast };
|