@infrab4a/connect 3.14.3 → 3.15.0-beta.1
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/bundles/infrab4a-connect.umd.js +148 -119
- package/bundles/infrab4a-connect.umd.js.map +1 -1
- package/domain/catalog/models/category-filter.d.ts +0 -2
- package/domain/catalog/models/category.d.ts +0 -2
- package/domain/shop-settings/enums/index.d.ts +1 -0
- package/domain/shop-settings/enums/shop-page-name.enum.d.ts +19 -0
- package/domain/shop-settings/models/campaign-banner.d.ts +11 -0
- package/domain/shop-settings/models/campaign.d.ts +10 -0
- package/domain/shop-settings/models/index.d.ts +2 -0
- package/domain/shop-settings/models/shop-settings.d.ts +2 -1
- package/domain/shop-settings/models/types/campaign-page.d.ts +17 -0
- package/domain/shop-settings/models/types/index.d.ts +4 -0
- package/domain/shop-settings/models/types/sections.type.d.ts +17 -0
- package/domain/shop-settings/models/types/shop-gift.type.d.ts +8 -0
- package/domain/shop-settings/models/types/shop-post.type.d.ts +7 -0
- package/domain/shop-settings/models/types/shop-section.type.d.ts +3 -0
- package/domain/shop-settings/repositories/campaign-banner.repository.d.ts +4 -0
- package/domain/shop-settings/repositories/campaign.repository.d.ts +4 -0
- package/domain/shop-settings/repositories/index.d.ts +2 -0
- package/esm2015/domain/catalog/models/category-filter.js +1 -6
- package/esm2015/domain/catalog/models/category.js +1 -6
- package/esm2015/domain/shop-settings/enums/index.js +2 -1
- package/esm2015/domain/shop-settings/enums/shop-page-name.enum.js +21 -0
- package/esm2015/domain/shop-settings/models/campaign-banner.js +7 -0
- package/esm2015/domain/shop-settings/models/campaign.js +7 -0
- package/esm2015/domain/shop-settings/models/index.js +3 -1
- package/esm2015/domain/shop-settings/models/shop-settings.js +1 -1
- package/esm2015/domain/shop-settings/models/types/campaign-page.js +2 -0
- package/esm2015/domain/shop-settings/models/types/index.js +5 -1
- package/esm2015/domain/shop-settings/models/types/sections.type.js +2 -0
- package/esm2015/domain/shop-settings/models/types/shop-gift.type.js +2 -0
- package/esm2015/domain/shop-settings/models/types/shop-post.type.js +2 -0
- package/esm2015/domain/shop-settings/models/types/shop-section.type.js +1 -1
- package/esm2015/domain/shop-settings/repositories/campaign-banner.repository.js +2 -0
- package/esm2015/domain/shop-settings/repositories/campaign.repository.js +2 -0
- package/esm2015/domain/shop-settings/repositories/index.js +3 -1
- package/esm2015/infra/firebase/firestore/repositories/shop-settings/campaign-banner-firestore.repository.js +12 -0
- package/esm2015/infra/firebase/firestore/repositories/shop-settings/campaign-firestore.repository.js +12 -0
- package/esm2015/infra/firebase/firestore/repositories/shop-settings/index.js +3 -1
- package/esm2015/infra/hasura-graphql/mixins/helpers/bind-filter-query.helper.js +2 -2
- package/esm2015/infra/hasura-graphql/repositories/catalog/category-filter-hasura-graphql.repository.js +1 -43
- package/fesm2015/infrab4a-connect.js +99 -98
- package/fesm2015/infrab4a-connect.js.map +1 -1
- package/infra/firebase/firestore/repositories/shop-settings/campaign-banner-firestore.repository.d.ts +8 -0
- package/infra/firebase/firestore/repositories/shop-settings/campaign-firestore.repository.d.ts +8 -0
- package/infra/firebase/firestore/repositories/shop-settings/index.d.ts +2 -0
- package/package.json +1 -1
|
@@ -39,48 +39,6 @@ export class CategoryFilterHasuraGraphQLRepository extends withCrudHasuraGraphQL
|
|
|
39
39
|
],
|
|
40
40
|
},
|
|
41
41
|
},
|
|
42
|
-
{
|
|
43
|
-
category: {
|
|
44
|
-
columnName: 'category',
|
|
45
|
-
foreignKeyColumn: { id: 'categoryId' },
|
|
46
|
-
fields: [
|
|
47
|
-
'id',
|
|
48
|
-
'description',
|
|
49
|
-
{
|
|
50
|
-
products: {
|
|
51
|
-
columnName: 'products',
|
|
52
|
-
fields: ['product_id'],
|
|
53
|
-
from: (value) => value.map((product) => product.product_id.toString()),
|
|
54
|
-
to: (productIds) => productIds.map((productId) => ({
|
|
55
|
-
product_id: +productId,
|
|
56
|
-
})),
|
|
57
|
-
},
|
|
58
|
-
},
|
|
59
|
-
{
|
|
60
|
-
childrenProducts: {
|
|
61
|
-
columnName: 'children_products',
|
|
62
|
-
foreignKeyColumn: { category_id: 'id' },
|
|
63
|
-
fields: [
|
|
64
|
-
'id',
|
|
65
|
-
'name',
|
|
66
|
-
'slug',
|
|
67
|
-
{
|
|
68
|
-
categories: {
|
|
69
|
-
columnName: 'categories',
|
|
70
|
-
fields: ['category_id'],
|
|
71
|
-
bindPersistData: (value) => ({
|
|
72
|
-
categories: { data: value.map((category) => ({ category_id: +category })) },
|
|
73
|
-
}),
|
|
74
|
-
to: (categories) => categories.map((categoryId) => +categoryId),
|
|
75
|
-
from: (categories) => (categories === null || categories === void 0 ? void 0 : categories.map((category) => { var _a; return (_a = category === null || category === void 0 ? void 0 : category.category_id) === null || _a === void 0 ? void 0 : _a.toString(); })) || [],
|
|
76
|
-
},
|
|
77
|
-
},
|
|
78
|
-
],
|
|
79
|
-
},
|
|
80
|
-
},
|
|
81
|
-
],
|
|
82
|
-
},
|
|
83
|
-
},
|
|
84
42
|
],
|
|
85
43
|
});
|
|
86
44
|
}
|
|
@@ -94,4 +52,4 @@ export class CategoryFilterHasuraGraphQLRepository extends withCrudHasuraGraphQL
|
|
|
94
52
|
});
|
|
95
53
|
}
|
|
96
54
|
}
|
|
97
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
55
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY2F0ZWdvcnktZmlsdGVyLWhhc3VyYS1ncmFwaHFsLnJlcG9zaXRvcnkuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9jb25uZWN0L3NyYy9pbmZyYS9oYXN1cmEtZ3JhcGhxbC9yZXBvc2l0b3JpZXMvY2F0YWxvZy9jYXRlZ29yeS1maWx0ZXItaGFzdXJhLWdyYXBocWwucmVwb3NpdG9yeS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdz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bignZGVsZXRlX2NhdGVnb3J5X2ZpbHRlcicsIFsnYWZmZWN0ZWRfcm93cyddLCB7XG4gICAgICB3aGVyZToge1xuICAgICAgICB0eXBlOiAnY2F0ZWdvcnlfZmlsdGVyX2Jvb2xfZXhwJyxcbiAgICAgICAgcmVxdWlyZWQ6IHRydWUsXG4gICAgICAgIHZhbHVlOiB7IGNhdGVnb3J5X2lkOiB7IF9lcTogY2F0ZWdvcnlJZCB9LCBmaWx0ZXJfaWQ6IHsgX2VxOiBmaWx0ZXJJZCB9IH0sXG4gICAgICB9LFxuICAgIH0pXG4gIH1cbn1cbiJdfQ==
|
|
@@ -1193,52 +1193,6 @@ class Filter extends BaseModel {
|
|
|
1193
1193
|
}
|
|
1194
1194
|
}
|
|
1195
1195
|
|
|
1196
|
-
class KitProduct extends BaseModel {
|
|
1197
|
-
static get identifiersFields() {
|
|
1198
|
-
return ['productId', 'kitProductId'];
|
|
1199
|
-
}
|
|
1200
|
-
}
|
|
1201
|
-
__decorate([
|
|
1202
|
-
Type(() => Product),
|
|
1203
|
-
__metadata("design:type", Product)
|
|
1204
|
-
], KitProduct.prototype, "kit", void 0);
|
|
1205
|
-
__decorate([
|
|
1206
|
-
Type(() => Product),
|
|
1207
|
-
__metadata("design:type", Product)
|
|
1208
|
-
], KitProduct.prototype, "product", void 0);
|
|
1209
|
-
|
|
1210
|
-
class Product extends BaseModel {
|
|
1211
|
-
get evaluation() {
|
|
1212
|
-
return {
|
|
1213
|
-
reviews: this.reviews,
|
|
1214
|
-
count: this.reviewsTotal,
|
|
1215
|
-
rating: this.rate,
|
|
1216
|
-
};
|
|
1217
|
-
}
|
|
1218
|
-
set evaluation(evaluation) {
|
|
1219
|
-
if (!evaluation) {
|
|
1220
|
-
this.reviews = null;
|
|
1221
|
-
this.reviewsTotal = null;
|
|
1222
|
-
this.rate = null;
|
|
1223
|
-
return;
|
|
1224
|
-
}
|
|
1225
|
-
this.reviews = evaluation.reviews || this.reviews;
|
|
1226
|
-
this.reviewsTotal = evaluation.count || this.reviewsTotal;
|
|
1227
|
-
this.rate = evaluation.rating || this.rate;
|
|
1228
|
-
}
|
|
1229
|
-
static get identifiersFields() {
|
|
1230
|
-
return ['id'];
|
|
1231
|
-
}
|
|
1232
|
-
}
|
|
1233
|
-
__decorate([
|
|
1234
|
-
Type(() => Category),
|
|
1235
|
-
__metadata("design:type", Category)
|
|
1236
|
-
], Product.prototype, "category", void 0);
|
|
1237
|
-
__decorate([
|
|
1238
|
-
Type(() => KitProduct),
|
|
1239
|
-
__metadata("design:type", Array)
|
|
1240
|
-
], Product.prototype, "kitProducts", void 0);
|
|
1241
|
-
|
|
1242
1196
|
class Category extends BaseModel {
|
|
1243
1197
|
static get identifiersFields() {
|
|
1244
1198
|
return ['id'];
|
|
@@ -1252,10 +1206,6 @@ __decorate([
|
|
|
1252
1206
|
Type(() => Filter),
|
|
1253
1207
|
__metadata("design:type", Array)
|
|
1254
1208
|
], Category.prototype, "filters", void 0);
|
|
1255
|
-
__decorate([
|
|
1256
|
-
Type(() => Product),
|
|
1257
|
-
__metadata("design:type", Array)
|
|
1258
|
-
], Category.prototype, "childrenProducts", void 0);
|
|
1259
1209
|
|
|
1260
1210
|
class CategoryCollectionChildren extends BaseModel {
|
|
1261
1211
|
static get identifiersFields() {
|
|
@@ -1276,10 +1226,6 @@ __decorate([
|
|
|
1276
1226
|
Type(() => Filter),
|
|
1277
1227
|
__metadata("design:type", Filter)
|
|
1278
1228
|
], CategoryFilter.prototype, "filter", void 0);
|
|
1279
|
-
__decorate([
|
|
1280
|
-
Type(() => Category),
|
|
1281
|
-
__metadata("design:type", Category)
|
|
1282
|
-
], CategoryFilter.prototype, "category", void 0);
|
|
1283
1229
|
|
|
1284
1230
|
var GenderDestination;
|
|
1285
1231
|
(function (GenderDestination) {
|
|
@@ -1302,6 +1248,52 @@ class FilterOption extends BaseModel {
|
|
|
1302
1248
|
}
|
|
1303
1249
|
}
|
|
1304
1250
|
|
|
1251
|
+
class Product extends BaseModel {
|
|
1252
|
+
get evaluation() {
|
|
1253
|
+
return {
|
|
1254
|
+
reviews: this.reviews,
|
|
1255
|
+
count: this.reviewsTotal,
|
|
1256
|
+
rating: this.rate,
|
|
1257
|
+
};
|
|
1258
|
+
}
|
|
1259
|
+
set evaluation(evaluation) {
|
|
1260
|
+
if (!evaluation) {
|
|
1261
|
+
this.reviews = null;
|
|
1262
|
+
this.reviewsTotal = null;
|
|
1263
|
+
this.rate = null;
|
|
1264
|
+
return;
|
|
1265
|
+
}
|
|
1266
|
+
this.reviews = evaluation.reviews || this.reviews;
|
|
1267
|
+
this.reviewsTotal = evaluation.count || this.reviewsTotal;
|
|
1268
|
+
this.rate = evaluation.rating || this.rate;
|
|
1269
|
+
}
|
|
1270
|
+
static get identifiersFields() {
|
|
1271
|
+
return ['id'];
|
|
1272
|
+
}
|
|
1273
|
+
}
|
|
1274
|
+
__decorate([
|
|
1275
|
+
Type(() => Category),
|
|
1276
|
+
__metadata("design:type", Category)
|
|
1277
|
+
], Product.prototype, "category", void 0);
|
|
1278
|
+
__decorate([
|
|
1279
|
+
Type(() => KitProduct),
|
|
1280
|
+
__metadata("design:type", Array)
|
|
1281
|
+
], Product.prototype, "kitProducts", void 0);
|
|
1282
|
+
|
|
1283
|
+
class KitProduct extends BaseModel {
|
|
1284
|
+
static get identifiersFields() {
|
|
1285
|
+
return ['productId', 'kitProductId'];
|
|
1286
|
+
}
|
|
1287
|
+
}
|
|
1288
|
+
__decorate([
|
|
1289
|
+
Type(() => Product),
|
|
1290
|
+
__metadata("design:type", Product)
|
|
1291
|
+
], KitProduct.prototype, "kit", void 0);
|
|
1292
|
+
__decorate([
|
|
1293
|
+
Type(() => Product),
|
|
1294
|
+
__metadata("design:type", Product)
|
|
1295
|
+
], KitProduct.prototype, "product", void 0);
|
|
1296
|
+
|
|
1305
1297
|
class Variant extends BaseModel {
|
|
1306
1298
|
static get identifiersFields() {
|
|
1307
1299
|
return ['id', 'productId'];
|
|
@@ -1466,6 +1458,27 @@ var QuestionsFilters;
|
|
|
1466
1458
|
QuestionsFilters["PRODUCT_SPENT"] = "Qual \u00E9 o seu nivel de gasto mensal em produtos de beleza e cuidados pessoais?";
|
|
1467
1459
|
})(QuestionsFilters || (QuestionsFilters = {}));
|
|
1468
1460
|
|
|
1461
|
+
var ShopPageName;
|
|
1462
|
+
(function (ShopPageName) {
|
|
1463
|
+
ShopPageName["LP_CLUB"] = "LP_CLUBE";
|
|
1464
|
+
ShopPageName["SUBSCRIBER_PANEL"] = "SUBSCRIBER_PANEL";
|
|
1465
|
+
ShopPageName["INVITE_FRIENDS"] = "INVITE_FRIENDS";
|
|
1466
|
+
ShopPageName["INVITE_AND_WIN"] = "INVITE_AND_WIN";
|
|
1467
|
+
ShopPageName["WIN_GLAMPOINTS"] = "WIN_GLAMPOINTS";
|
|
1468
|
+
ShopPageName["POSTS"] = "POSTS";
|
|
1469
|
+
ShopPageName["GLAMPOINTS_SHOWCASE"] = "GLAMPOINTS_SHOWCASE";
|
|
1470
|
+
ShopPageName["LP_EDITIONS"] = "LP_EDITIONS";
|
|
1471
|
+
ShopPageName["LP_GLAMBOX_EDITION"] = "LP_GLAMBOX_EDITION";
|
|
1472
|
+
ShopPageName["LP_GLAMBOX_PROMOTION"] = "LP_GLAMBOX_PROMOTION";
|
|
1473
|
+
ShopPageName["LP_GLAMBAG_PROMOTION"] = "LP_GLAMBAG_PROMOTION";
|
|
1474
|
+
ShopPageName["LP_GLAMPASS_PROMOTION"] = "LP_GLAMPASS_PROMOTION";
|
|
1475
|
+
ShopPageName["LP_SUBSCRIPTION_PROMOTION"] = "LP_SUBSCRIPTION_PROMOTION";
|
|
1476
|
+
ShopPageName["LP_GLAMPARTNER_PROMOTION"] = "LP_GLAMPARTNER_PROMOTION";
|
|
1477
|
+
ShopPageName["LP_GLAMQUEENS"] = "LP_GLAMQUEENS";
|
|
1478
|
+
ShopPageName["LP_INVITE"] = "LP_INVITE";
|
|
1479
|
+
ShopPageName["LP_LIVELO"] = "LP_LIVELO";
|
|
1480
|
+
})(ShopPageName || (ShopPageName = {}));
|
|
1481
|
+
|
|
1469
1482
|
class BeautyQuestionsHelper {
|
|
1470
1483
|
static getAnswers(filter) {
|
|
1471
1484
|
switch (filter) {
|
|
@@ -1510,6 +1523,18 @@ class BeautyQuestionsHelper {
|
|
|
1510
1523
|
}
|
|
1511
1524
|
}
|
|
1512
1525
|
|
|
1526
|
+
class Campaign extends BaseModel {
|
|
1527
|
+
static get identifiersFields() {
|
|
1528
|
+
return ['id'];
|
|
1529
|
+
}
|
|
1530
|
+
}
|
|
1531
|
+
|
|
1532
|
+
class CampaignBanner extends BaseModel {
|
|
1533
|
+
static get identifiersFields() {
|
|
1534
|
+
return ['id'];
|
|
1535
|
+
}
|
|
1536
|
+
}
|
|
1537
|
+
|
|
1513
1538
|
class Home extends BaseModel {
|
|
1514
1539
|
static get identifiersFields() {
|
|
1515
1540
|
return ['id'];
|
|
@@ -2471,6 +2496,24 @@ class SubscriptionPlanFirestoreRepository extends withCrudFirestore(withHelpers(
|
|
|
2471
2496
|
}
|
|
2472
2497
|
}
|
|
2473
2498
|
|
|
2499
|
+
class CampaignBannerFirestoreRepository extends withCrudFirestore(withHelpers(withFirestore(Base))) {
|
|
2500
|
+
constructor(firestore) {
|
|
2501
|
+
super();
|
|
2502
|
+
this.firestore = firestore;
|
|
2503
|
+
this.collectionName = 'banners';
|
|
2504
|
+
this.model = CampaignBanner;
|
|
2505
|
+
}
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2508
|
+
class CampaignFirestoreRepository extends withCrudFirestore(withHelpers(withFirestore(Base))) {
|
|
2509
|
+
constructor(firestore) {
|
|
2510
|
+
super();
|
|
2511
|
+
this.firestore = firestore;
|
|
2512
|
+
this.collectionName = 'campaigns';
|
|
2513
|
+
this.model = Campaign;
|
|
2514
|
+
}
|
|
2515
|
+
}
|
|
2516
|
+
|
|
2474
2517
|
class HomeFirestoreRepository extends withCrudFirestore(withHelpers(withFirestore(Base))) {
|
|
2475
2518
|
constructor(firestore) {
|
|
2476
2519
|
super();
|
|
@@ -2716,7 +2759,7 @@ BindFilterQueryHelper.BuildWhereSentence = (field, options, fields) => {
|
|
|
2716
2759
|
const fieldOptions = AttributeOptionHelper.FindByAttribute(key, (fieldSentenceOptions === null || fieldSentenceOptions === void 0 ? void 0 : fieldSentenceOptions.fields) || fields);
|
|
2717
2760
|
const columnName = fieldOptions.columnName;
|
|
2718
2761
|
const columnFields = fieldOptions.fields;
|
|
2719
|
-
return Object.assign(Object.assign({}, variables), { [columnName]: BindFilterQueryHelper.BuildWhereSentence(key, options[key],
|
|
2762
|
+
return Object.assign(Object.assign({}, variables), { [columnName]: BindFilterQueryHelper.BuildWhereSentence(key, options[key], columnFields || []) });
|
|
2720
2763
|
}, {});
|
|
2721
2764
|
if (!Array.isArray(options) && !isNil(fieldSentenceOptions.fields))
|
|
2722
2765
|
return {
|
|
@@ -3315,48 +3358,6 @@ class CategoryFilterHasuraGraphQLRepository extends withCrudHasuraGraphQL(withHa
|
|
|
3315
3358
|
],
|
|
3316
3359
|
},
|
|
3317
3360
|
},
|
|
3318
|
-
{
|
|
3319
|
-
category: {
|
|
3320
|
-
columnName: 'category',
|
|
3321
|
-
foreignKeyColumn: { id: 'categoryId' },
|
|
3322
|
-
fields: [
|
|
3323
|
-
'id',
|
|
3324
|
-
'description',
|
|
3325
|
-
{
|
|
3326
|
-
products: {
|
|
3327
|
-
columnName: 'products',
|
|
3328
|
-
fields: ['product_id'],
|
|
3329
|
-
from: (value) => value.map((product) => product.product_id.toString()),
|
|
3330
|
-
to: (productIds) => productIds.map((productId) => ({
|
|
3331
|
-
product_id: +productId,
|
|
3332
|
-
})),
|
|
3333
|
-
},
|
|
3334
|
-
},
|
|
3335
|
-
{
|
|
3336
|
-
childrenProducts: {
|
|
3337
|
-
columnName: 'children_products',
|
|
3338
|
-
foreignKeyColumn: { category_id: 'id' },
|
|
3339
|
-
fields: [
|
|
3340
|
-
'id',
|
|
3341
|
-
'name',
|
|
3342
|
-
'slug',
|
|
3343
|
-
{
|
|
3344
|
-
categories: {
|
|
3345
|
-
columnName: 'categories',
|
|
3346
|
-
fields: ['category_id'],
|
|
3347
|
-
bindPersistData: (value) => ({
|
|
3348
|
-
categories: { data: value.map((category) => ({ category_id: +category })) },
|
|
3349
|
-
}),
|
|
3350
|
-
to: (categories) => categories.map((categoryId) => +categoryId),
|
|
3351
|
-
from: (categories) => (categories === null || categories === void 0 ? void 0 : categories.map((category) => { var _a; return (_a = category === null || category === void 0 ? void 0 : category.category_id) === null || _a === void 0 ? void 0 : _a.toString(); })) || [],
|
|
3352
|
-
},
|
|
3353
|
-
},
|
|
3354
|
-
],
|
|
3355
|
-
},
|
|
3356
|
-
},
|
|
3357
|
-
],
|
|
3358
|
-
},
|
|
3359
|
-
},
|
|
3360
3361
|
],
|
|
3361
3362
|
});
|
|
3362
3363
|
}
|
|
@@ -4492,5 +4493,5 @@ class VariantHasuraGraphQLRepository extends withCrudHasuraGraphQL(withHasuraGra
|
|
|
4492
4493
|
* Generated bundle index. Do not edit.
|
|
4493
4494
|
*/
|
|
4494
4495
|
|
|
4495
|
-
export { AccessoryImportances, Address, Area, Authentication, AuthenticationFirebaseAuthService, AxiosAdapter, Base, BaseModel, BeardProblems, BeardSizes, BeautyProductImportances, BeautyProfile, BeautyQuestionsHelper, BillingStatus, BodyProblems, BodyShapes, BodyTattoos, Buy2Win, Buy2WinFirestoreRepository, CampaignDashboard, CampaignDashboardFirestoreRepository, CampaignHashtag, CampaignHashtagFirestoreRepository, Category, CategoryCollectionChildren, CategoryCollectionChildrenHasuraGraphQLRepository, CategoryFilter, CategoryFilterHasuraGraphQLRepository, CategoryFirestoreRepository, CategoryHasuraGraphQL, CategoryHasuraGraphQLRepository, Checkout, CheckoutFirestoreRepository, CheckoutSubscription, CheckoutSubscriptionFirestoreRepository, CheckoutTypes, ClassNameHelper, Coupon, CouponFirestoreRepository, CouponSubtypes, CouponTypes, Debug, DebugDecoratorHelper, DebugHelper, DebugNamespaces, DuplicatedResultsError, Edition, EditionStatus, Exclusivities, FaceSkinOilinesses, FaceSkinProblems, FaceSkinTones, FamilyIncomes, Filter, FilterHasuraGraphQLRepository, FilterOption, FilterOptionHasuraGraphQLRepository, FilterType, FragranceImportances, GenderDestination, HairColors, HairProblems, HairStrands, HairTypes, Home, HomeFirestoreRepository, InvalidArgumentError, KitProduct, KitProductHasuraGraphQL, Lead, LeadFirestoreRepository, LegacyOrderFirestoreRepository, LineItem, Log, Logger, NotFoundError, OfficePosition, Order, OrderFirestoreRepository, OrderStatus, Payment, PaymentFirestoreRepository, PaymentType, Product, ProductFirestoreRepository, ProductHasuraGraphQL, ProductHasuraGraphQLRepository, ProductSpents, ProductVariantFirestoreRepository, ProductsIndex, QuestionsFilters, RecoveryPassword, ReflectHelper, Register, RegisterFirebaseAuthService, RequiredArgumentError, RoundProductPricesHelper, ShippingMethod, ShopMenu, ShopMenuFirestoreRepository, ShopSettings, ShopSettingsFirestoreRepository, Shops, SignInMethods, SignOut, Status, Subscription, SubscriptionEditionFirestoreRepository, SubscriptionFirestoreRepository, SubscriptionPayment, SubscriptionPaymentFirestoreRepository, SubscriptionPlan, SubscriptionPlanFirestoreRepository, SubscriptionProductFirestoreRepository, Trace, UnauthorizedError, UpdateOptionActions, User, UserAddress, UserAddressFirestoreRepository, UserAlreadyRegisteredError, UserBeautyProfileFirestoreRepository, UserFirestoreRepository, UserPaymentMethod, UserPaymentMethodFirestoreRepository, UserType, Variant, VariantHasuraGraphQL, VariantHasuraGraphQLRepository, WeakPasswordError, Where, isDebuggable, isUUID, parseDateTime, withCreateFirestore, withCreateHasuraGraphQL, withCrudFirestore, withCrudHasuraGraphQL, withDeleteFirestore, withDeleteHasuraGraphQL, withFindFirestore, withFindHasuraGraphQL, withFirestore, withGetFirestore, withGetHasuraGraphQL, withHasuraGraphQL, withHelpers, withSubCollection, withUpdateFirestore, withUpdateHasuraGraphQL };
|
|
4496
|
+
export { AccessoryImportances, Address, Area, Authentication, AuthenticationFirebaseAuthService, AxiosAdapter, Base, BaseModel, BeardProblems, BeardSizes, BeautyProductImportances, BeautyProfile, BeautyQuestionsHelper, BillingStatus, BodyProblems, BodyShapes, BodyTattoos, Buy2Win, Buy2WinFirestoreRepository, Campaign, CampaignBanner, CampaignBannerFirestoreRepository, CampaignDashboard, CampaignDashboardFirestoreRepository, CampaignFirestoreRepository, CampaignHashtag, CampaignHashtagFirestoreRepository, Category, CategoryCollectionChildren, CategoryCollectionChildrenHasuraGraphQLRepository, CategoryFilter, CategoryFilterHasuraGraphQLRepository, CategoryFirestoreRepository, CategoryHasuraGraphQL, CategoryHasuraGraphQLRepository, Checkout, CheckoutFirestoreRepository, CheckoutSubscription, CheckoutSubscriptionFirestoreRepository, CheckoutTypes, ClassNameHelper, Coupon, CouponFirestoreRepository, CouponSubtypes, CouponTypes, Debug, DebugDecoratorHelper, DebugHelper, DebugNamespaces, DuplicatedResultsError, Edition, EditionStatus, Exclusivities, FaceSkinOilinesses, FaceSkinProblems, FaceSkinTones, FamilyIncomes, Filter, FilterHasuraGraphQLRepository, FilterOption, FilterOptionHasuraGraphQLRepository, FilterType, FragranceImportances, GenderDestination, HairColors, HairProblems, HairStrands, HairTypes, Home, HomeFirestoreRepository, InvalidArgumentError, KitProduct, KitProductHasuraGraphQL, Lead, LeadFirestoreRepository, LegacyOrderFirestoreRepository, LineItem, Log, Logger, NotFoundError, OfficePosition, Order, OrderFirestoreRepository, OrderStatus, Payment, PaymentFirestoreRepository, PaymentType, Product, ProductFirestoreRepository, ProductHasuraGraphQL, ProductHasuraGraphQLRepository, ProductSpents, ProductVariantFirestoreRepository, ProductsIndex, QuestionsFilters, RecoveryPassword, ReflectHelper, Register, RegisterFirebaseAuthService, RequiredArgumentError, RoundProductPricesHelper, ShippingMethod, ShopMenu, ShopMenuFirestoreRepository, ShopPageName, ShopSettings, ShopSettingsFirestoreRepository, Shops, SignInMethods, SignOut, Status, Subscription, SubscriptionEditionFirestoreRepository, SubscriptionFirestoreRepository, SubscriptionPayment, SubscriptionPaymentFirestoreRepository, SubscriptionPlan, SubscriptionPlanFirestoreRepository, SubscriptionProductFirestoreRepository, Trace, UnauthorizedError, UpdateOptionActions, User, UserAddress, UserAddressFirestoreRepository, UserAlreadyRegisteredError, UserBeautyProfileFirestoreRepository, UserFirestoreRepository, UserPaymentMethod, UserPaymentMethodFirestoreRepository, UserType, Variant, VariantHasuraGraphQL, VariantHasuraGraphQLRepository, WeakPasswordError, Where, isDebuggable, isUUID, parseDateTime, withCreateFirestore, withCreateHasuraGraphQL, withCrudFirestore, withCrudHasuraGraphQL, withDeleteFirestore, withDeleteHasuraGraphQL, withFindFirestore, withFindHasuraGraphQL, withFirestore, withGetFirestore, withGetHasuraGraphQL, withHasuraGraphQL, withHelpers, withSubCollection, withUpdateFirestore, withUpdateHasuraGraphQL };
|
|
4496
4497
|
//# sourceMappingURL=infrab4a-connect.js.map
|