@daffodil/driver 0.38.6
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/README.md +3 -0
- package/bundles/daffodil-driver-hubspot.umd.js +384 -0
- package/bundles/daffodil-driver-hubspot.umd.js.map +1 -0
- package/bundles/daffodil-driver-hubspot.umd.min.js +16 -0
- package/bundles/daffodil-driver-hubspot.umd.min.js.map +1 -0
- package/bundles/daffodil-driver-magento-testing.umd.js +386 -0
- package/bundles/daffodil-driver-magento-testing.umd.js.map +1 -0
- package/bundles/daffodil-driver-magento-testing.umd.min.js +16 -0
- package/bundles/daffodil-driver-magento-testing.umd.min.js.map +1 -0
- package/bundles/daffodil-driver-magento.umd.js +199 -0
- package/bundles/daffodil-driver-magento.umd.js.map +1 -0
- package/bundles/daffodil-driver-magento.umd.min.js +2 -0
- package/bundles/daffodil-driver-magento.umd.min.js.map +1 -0
- package/bundles/daffodil-driver.umd.js +345 -0
- package/bundles/daffodil-driver.umd.js.map +1 -0
- package/bundles/daffodil-driver.umd.min.js +16 -0
- package/bundles/daffodil-driver.umd.min.js.map +1 -0
- package/daffodil-driver.d.ts +4 -0
- package/daffodil-driver.metadata.json +1 -0
- package/errors/bad-input.d.ts +6 -0
- package/errors/public_api.d.ts +1 -0
- package/esm2015/daffodil-driver.js +5 -0
- package/esm2015/errors/bad-input.js +9 -0
- package/esm2015/errors/public_api.js +2 -0
- package/esm2015/hubspot/daffodil-driver-hubspot.js +5 -0
- package/esm2015/hubspot/hubspot-forms.provider.js +3 -0
- package/esm2015/hubspot/hubspot-forms.service.js +47 -0
- package/esm2015/hubspot/index.js +3 -0
- package/esm2015/hubspot/models/config.js +1 -0
- package/esm2015/hubspot/models/hubspot-request.js +1 -0
- package/esm2015/hubspot/models/hubspot-response.js +1 -0
- package/esm2015/hubspot/transformers/json-builder.js +2 -0
- package/esm2015/index.js +2 -0
- package/esm2015/magento/daffodil-driver-magento.js +5 -0
- package/esm2015/magento/errors/public_api.js +2 -0
- package/esm2015/magento/errors/transform.js +22 -0
- package/esm2015/magento/graphql/cacheable-operations/apollo-cacheable-operations-link-generator.js +33 -0
- package/esm2015/magento/graphql/cacheable-operations/cacheable-operations-token.js +29 -0
- package/esm2015/magento/graphql/public_api.js +3 -0
- package/esm2015/magento/index.js +5 -0
- package/esm2015/magento/models/public_api.js +2 -0
- package/esm2015/magento/models/responses/discount.js +1 -0
- package/esm2015/magento/models/responses/money.js +1 -0
- package/esm2015/magento/models/responses/public_api.js +1 -0
- package/esm2015/magento/schema/introspection.json +90 -0
- package/esm2015/magento/schema/schema.js +3 -0
- package/esm2015/magento/testing/daffodil-driver-magento-testing.js +5 -0
- package/esm2015/magento/testing/factories/discount.factory.js +29 -0
- package/esm2015/magento/testing/factories/money.factory.js +25 -0
- package/esm2015/magento/testing/factories/public_api.js +3 -0
- package/esm2015/magento/testing/index.js +2 -0
- package/fesm2015/daffodil-driver-hubspot.js +56 -0
- package/fesm2015/daffodil-driver-hubspot.js.map +1 -0
- package/fesm2015/daffodil-driver-magento-testing.js +55 -0
- package/fesm2015/daffodil-driver-magento-testing.js.map +1 -0
- package/fesm2015/daffodil-driver-magento.js +181 -0
- package/fesm2015/daffodil-driver-magento.js.map +1 -0
- package/fesm2015/daffodil-driver.js +16 -0
- package/fesm2015/daffodil-driver.js.map +1 -0
- package/hubspot/daffodil-driver-hubspot.d.ts +4 -0
- package/hubspot/daffodil-driver-hubspot.metadata.json +1 -0
- package/hubspot/hubspot-forms.provider.d.ts +6 -0
- package/hubspot/hubspot-forms.service.d.ts +19 -0
- package/hubspot/index.d.ts +4 -0
- package/hubspot/models/config.d.ts +5 -0
- package/hubspot/models/hubspot-request.d.ts +15 -0
- package/hubspot/models/hubspot-response.d.ts +9 -0
- package/hubspot/package.json +11 -0
- package/hubspot/transformers/json-builder.d.ts +2 -0
- package/index.d.ts +1 -0
- package/magento/daffodil-driver-magento.d.ts +4 -0
- package/magento/daffodil-driver-magento.metadata.json +1 -0
- package/magento/errors/public_api.d.ts +1 -0
- package/magento/errors/transform.d.ts +5 -0
- package/magento/graphql/cacheable-operations/apollo-cacheable-operations-link-generator.d.ts +12 -0
- package/magento/graphql/cacheable-operations/cacheable-operations-token.d.ts +24 -0
- package/magento/graphql/public_api.d.ts +2 -0
- package/magento/index.d.ts +4 -0
- package/magento/models/public_api.d.ts +1 -0
- package/magento/models/responses/discount.d.ts +6 -0
- package/magento/models/responses/money.d.ts +5 -0
- package/magento/models/responses/public_api.d.ts +2 -0
- package/magento/package.json +11 -0
- package/magento/schema/schema.d.ts +21 -0
- package/magento/testing/daffodil-driver-magento-testing.d.ts +4 -0
- package/magento/testing/daffodil-driver-magento-testing.metadata.json +1 -0
- package/magento/testing/factories/discount.factory.d.ts +11 -0
- package/magento/testing/factories/money.factory.d.ts +10 -0
- package/magento/testing/factories/public_api.d.ts +2 -0
- package/magento/testing/index.d.ts +1 -0
- package/magento/testing/package.json +11 -0
- package/package.json +31 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ApolloLink } from '@apollo/client/core';
|
|
2
|
+
import { DaffApolloCacheableOperationLinkGenerator } from '@daffodil/core/graphql';
|
|
3
|
+
/**
|
|
4
|
+
* A service that will convert cacheable apollo operations into a format that Magento will understand as cacheable.
|
|
5
|
+
*
|
|
6
|
+
* @inheritdoc
|
|
7
|
+
*/
|
|
8
|
+
export declare class DaffMagentoApolloCacheableOperationsLinkGenerator implements DaffApolloCacheableOperationLinkGenerator {
|
|
9
|
+
private apolloGetRequests;
|
|
10
|
+
constructor(apolloGetRequests: string[]);
|
|
11
|
+
getLink(): ApolloLink;
|
|
12
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { InjectionToken } from '@angular/core';
|
|
2
|
+
/**
|
|
3
|
+
* A multi-provider injection token of the operation names of magento queries that should
|
|
4
|
+
* be cached. This is needed because queries need to be converted into GET queries in order for Magento
|
|
5
|
+
* to cache them. This token should be used by daffodil driver platform modules to register operation names that are cacheable, and is
|
|
6
|
+
* intended for internal daffodil use only.
|
|
7
|
+
*/
|
|
8
|
+
export declare const DAFF_MAGENTO_CACHEABLE_OPERATIONS: InjectionToken<string[]>;
|
|
9
|
+
/**
|
|
10
|
+
* Adds an operation name to the list of cacheable Magento operations. Use only with Angular 9+.
|
|
11
|
+
*/
|
|
12
|
+
export declare function provideDaffMagentoCacheableOperation(operationName: string): {
|
|
13
|
+
provide: InjectionToken<string[]>;
|
|
14
|
+
useValue: string;
|
|
15
|
+
multi: boolean;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Adds many operation names to the list of cacheable Magento operations. Use only with Angular 9+.
|
|
19
|
+
*/
|
|
20
|
+
export declare function provideManyDaffMagentoCacheableOperations(...operationNames: string[]): {
|
|
21
|
+
provide: InjectionToken<string[]>;
|
|
22
|
+
useValue: string;
|
|
23
|
+
multi: boolean;
|
|
24
|
+
}[];
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './responses/public_api';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@daffodil/driver/magento",
|
|
3
|
+
"main": "../bundles/daffodil-driver-magento.umd.js",
|
|
4
|
+
"module": "../fesm2015/daffodil-driver-magento.js",
|
|
5
|
+
"es2015": "../fesm2015/daffodil-driver-magento.js",
|
|
6
|
+
"esm2015": "../esm2015/magento/daffodil-driver-magento.js",
|
|
7
|
+
"fesm2015": "../fesm2015/daffodil-driver-magento.js",
|
|
8
|
+
"typings": "daffodil-driver-magento.d.ts",
|
|
9
|
+
"metadata": "daffodil-driver-magento.metadata.json",
|
|
10
|
+
"sideEffects": false
|
|
11
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export declare const schema: {
|
|
2
|
+
possibleTypes: {
|
|
3
|
+
CartAddressInterface: string[];
|
|
4
|
+
CartItemInterface: string[];
|
|
5
|
+
ProductInterface: string[];
|
|
6
|
+
CategoryInterface: string[];
|
|
7
|
+
MediaGalleryInterface: string[];
|
|
8
|
+
ProductLinksInterface: string[];
|
|
9
|
+
CreditMemoItemInterface: string[];
|
|
10
|
+
OrderItemInterface: string[];
|
|
11
|
+
InvoiceItemInterface: string[];
|
|
12
|
+
ShipmentItemInterface: string[];
|
|
13
|
+
AggregationOptionInterface: string[];
|
|
14
|
+
LayerFilterItemInterface: string[];
|
|
15
|
+
PhysicalProductInterface: string[];
|
|
16
|
+
CustomizableOptionInterface: string[];
|
|
17
|
+
CustomizableProductInterface: string[];
|
|
18
|
+
SwatchDataInterface: string[];
|
|
19
|
+
SwatchLayerFilterItemInterface: string[];
|
|
20
|
+
};
|
|
21
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"__symbolic":"module","version":4,"metadata":{"MagentoMoneyFactory":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@daffodil/core/testing","name":"DaffModelFactory","line":15,"character":41},"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":12,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor"}]},"statics":{"ɵprov":{}}},"MagentoDiscountFactory":{"__symbolic":"class","extends":{"__symbolic":"reference","module":"@daffodil/core/testing","name":"DaffModelFactory","line":24,"character":44},"decorators":[{"__symbolic":"call","expression":{"__symbolic":"reference","module":"@angular/core","name":"Injectable","line":21,"character":1},"arguments":[{"providedIn":"root"}]}],"members":{"__ctor__":[{"__symbolic":"constructor"}]},"statics":{"ɵprov":{}}}},"origins":{"MagentoMoneyFactory":"./factories/money.factory","MagentoDiscountFactory":"./factories/discount.factory"},"importAs":"@daffodil/driver/magento/testing"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { DaffModelFactory } from '@daffodil/core/testing';
|
|
2
|
+
import { MagentoDiscount, MagentoMoney } from '@daffodil/driver/magento';
|
|
3
|
+
export declare class MockMagentoDiscount implements MagentoDiscount {
|
|
4
|
+
__typename: string;
|
|
5
|
+
amount: MagentoMoney;
|
|
6
|
+
label: any;
|
|
7
|
+
private money;
|
|
8
|
+
}
|
|
9
|
+
export declare class MagentoDiscountFactory extends DaffModelFactory<MagentoDiscount> {
|
|
10
|
+
constructor();
|
|
11
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { DaffModelFactory } from '@daffodil/core/testing';
|
|
2
|
+
import { MagentoMoney } from '@daffodil/driver/magento';
|
|
3
|
+
export declare class MockMagentoMoney implements MagentoMoney {
|
|
4
|
+
__typename: string;
|
|
5
|
+
value: any;
|
|
6
|
+
currency: any;
|
|
7
|
+
}
|
|
8
|
+
export declare class MagentoMoneyFactory extends DaffModelFactory<MagentoMoney> {
|
|
9
|
+
constructor();
|
|
10
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './factories/public_api';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@daffodil/driver/magento/testing",
|
|
3
|
+
"main": "../../bundles/daffodil-driver-magento-testing.umd.js",
|
|
4
|
+
"module": "../../fesm2015/daffodil-driver-magento-testing.js",
|
|
5
|
+
"es2015": "../../fesm2015/daffodil-driver-magento-testing.js",
|
|
6
|
+
"esm2015": "../../esm2015/magento/testing/daffodil-driver-magento-testing.js",
|
|
7
|
+
"fesm2015": "../../fesm2015/daffodil-driver-magento-testing.js",
|
|
8
|
+
"typings": "daffodil-driver-magento-testing.d.ts",
|
|
9
|
+
"metadata": "daffodil-driver-magento-testing.metadata.json",
|
|
10
|
+
"sideEffects": false
|
|
11
|
+
}
|
package/package.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@daffodil/driver",
|
|
3
|
+
"version": "0.38.6",
|
|
4
|
+
"description": "A consistent, sane api driver that works with different ecommerce systems.",
|
|
5
|
+
"repository": {
|
|
6
|
+
"type": "git",
|
|
7
|
+
"url": "https://github.com/graycoreio/daffodil"
|
|
8
|
+
},
|
|
9
|
+
"author": "Graycore LLC",
|
|
10
|
+
"license": "MIT",
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/graycoreio/daffodil/issues"
|
|
13
|
+
},
|
|
14
|
+
"homepage": "https://github.com/graycoreio/daffodil",
|
|
15
|
+
"peerDependencies": {
|
|
16
|
+
"@angular/common": "^11.0.0",
|
|
17
|
+
"@angular/core": "^11.0.0",
|
|
18
|
+
"rxjs": "6.6.3"
|
|
19
|
+
},
|
|
20
|
+
"main": "bundles/daffodil-driver.umd.js",
|
|
21
|
+
"module": "fesm2015/daffodil-driver.js",
|
|
22
|
+
"es2015": "fesm2015/daffodil-driver.js",
|
|
23
|
+
"esm2015": "esm2015/daffodil-driver.js",
|
|
24
|
+
"fesm2015": "fesm2015/daffodil-driver.js",
|
|
25
|
+
"typings": "daffodil-driver.d.ts",
|
|
26
|
+
"metadata": "daffodil-driver.metadata.json",
|
|
27
|
+
"sideEffects": false,
|
|
28
|
+
"dependencies": {
|
|
29
|
+
"tslib": "^2.0.0"
|
|
30
|
+
}
|
|
31
|
+
}
|