ng-miam 8.3.0 → 8.3.2
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/ng-miam.umd.js +45 -24
- package/bundles/ng-miam.umd.js.map +1 -1
- package/bundles/ng-miam.umd.min.js +1 -1
- package/bundles/ng-miam.umd.min.js.map +1 -1
- package/esm2015/lib/_components/product-card/product-card.component.js +5 -2
- package/esm2015/lib/_services/baskets-synchronizing/baskets-comparator.service.js +4 -1
- package/esm2015/lib/_services/baskets-synchronizing/baskets-synchronizer.service.js +5 -1
- package/esm2015/lib/_services/context.service.js +20 -7
- package/esm2015/lib/_services/interceptor.service.js +2 -2
- package/esm2015/lib/_services/recipes.service.js +5 -5
- package/esm2015/lib/_web-components/preferences/preferences.component.js +7 -9
- package/esm2015/lib/_web-components/recipe-catalog/recipe-catalog.component.js +5 -5
- package/fesm2015/ng-miam.js +44 -24
- package/fesm2015/ng-miam.js.map +1 -1
- package/lib/_components/product-card/product-card.component.d.ts.map +1 -1
- package/lib/_services/baskets-synchronizing/baskets-comparator.service.d.ts +1 -0
- package/lib/_services/baskets-synchronizing/baskets-comparator.service.d.ts.map +1 -1
- package/lib/_services/baskets-synchronizing/baskets-synchronizer.service.d.ts +1 -0
- package/lib/_services/baskets-synchronizing/baskets-synchronizer.service.d.ts.map +1 -1
- package/lib/_services/context.service.d.ts +1 -0
- package/lib/_services/context.service.d.ts.map +1 -1
- package/lib/_services/recipes.service.d.ts +1 -1
- package/lib/_services/recipes.service.d.ts.map +1 -1
- package/lib/_web-components/preferences/preferences.component.d.ts +3 -1
- package/lib/_web-components/preferences/preferences.component.d.ts.map +1 -1
- package/package.json +1 -1
package/bundles/ng-miam.umd.js
CHANGED
|
@@ -3575,14 +3575,15 @@
|
|
|
3575
3575
|
}), operators.map(function () { return recipes; }));
|
|
3576
3576
|
};
|
|
3577
3577
|
// Fetches recipes corresponding to filters, and return total recipes count
|
|
3578
|
-
RecipesService.prototype.filterCount = function (filters, guests, excludedRecipesIds) {
|
|
3578
|
+
RecipesService.prototype.filterCount = function (filters, guests, excludedRecipesIds, fromPreference) {
|
|
3579
3579
|
if (guests === void 0) { guests = null; }
|
|
3580
3580
|
if (excludedRecipesIds === void 0) { excludedRecipesIds = []; }
|
|
3581
|
-
|
|
3582
|
-
|
|
3581
|
+
if (fromPreference === void 0) { fromPreference = false; }
|
|
3582
|
+
var f = this.preferencesService.addPreferencesToRemoteFilters(this.buildRemoteFilters(filters, guests), fromPreference);
|
|
3583
|
+
return this.all({ remotefilter: f, page: { number: 1, size: 1 }, fields: { recipes: ['id'] } }).pipe(operators.skipWhile(function (result) { return result.is_loading; }), operators.map(function (result) {
|
|
3583
3584
|
var _a;
|
|
3584
3585
|
// Apparently total_resource = 1 even if no result was found so we have to check
|
|
3585
|
-
var recipesNumber =
|
|
3586
|
+
var recipesNumber = result.data.length ? (_a = result.page) === null || _a === void 0 ? void 0 : _a.total_resources : 0;
|
|
3586
3587
|
recipesNumber -= result.data.filter(function (r) { return excludedRecipesIds.includes(r.id); }).length;
|
|
3587
3588
|
return recipesNumber;
|
|
3588
3589
|
}));
|
|
@@ -4978,6 +4979,9 @@
|
|
|
4978
4979
|
_this.extIdToItemsComparator[extId].updatePreviousQuantity();
|
|
4979
4980
|
});
|
|
4980
4981
|
};
|
|
4982
|
+
BasketsComparatorService.prototype.reset = function () {
|
|
4983
|
+
this.extIdToItemsComparator = undefined;
|
|
4984
|
+
};
|
|
4981
4985
|
return BasketsComparatorService;
|
|
4982
4986
|
}());
|
|
4983
4987
|
BasketsComparatorService.ɵfac = function BasketsComparatorService_Factory(t) { return new (t || BasketsComparatorService)(); };
|
|
@@ -5089,6 +5093,10 @@
|
|
|
5089
5093
|
BasketsSynchronizerService.prototype.isReady = function () {
|
|
5090
5094
|
return !!this.firstMiamBasket && !!this.firstRetailerBasket;
|
|
5091
5095
|
};
|
|
5096
|
+
BasketsSynchronizerService.prototype.resetMiam = function () {
|
|
5097
|
+
this.firstMiamBasket = undefined;
|
|
5098
|
+
this.comparatorService.reset();
|
|
5099
|
+
};
|
|
5092
5100
|
/**
|
|
5093
5101
|
* Calls pushProductsToBasket if there are changes that need to be notified to the retailer
|
|
5094
5102
|
*/
|
|
@@ -5227,6 +5235,7 @@
|
|
|
5227
5235
|
this.displayIngredientPicturesOnRecipeCards = false;
|
|
5228
5236
|
this.guestsInputOnMyMeals = false;
|
|
5229
5237
|
this.noSupplier = false;
|
|
5238
|
+
this.loggedOnSession = false;
|
|
5230
5239
|
this.enablePersonalRecipes$ = new rxjs.BehaviorSubject(false);
|
|
5231
5240
|
this.enableMealsPlanner$ = new rxjs.BehaviorSubject(false);
|
|
5232
5241
|
this.addAllProductsWasClicked = new i0.EventEmitter();
|
|
@@ -5376,6 +5385,9 @@
|
|
|
5376
5385
|
load: function (supplierId) {
|
|
5377
5386
|
if (_this.origin.value) {
|
|
5378
5387
|
_this.suppliersService.loadSupplier(supplierId.toString()).subscribe();
|
|
5388
|
+
if (!_this.loggedOnSession) {
|
|
5389
|
+
localStorage.removeItem('_miam/userId');
|
|
5390
|
+
}
|
|
5379
5391
|
_this.generateAuthlessIdIfNecessary().subscribe();
|
|
5380
5392
|
}
|
|
5381
5393
|
else {
|
|
@@ -5393,7 +5405,6 @@
|
|
|
5393
5405
|
_this.loadStoreLocatorPackage();
|
|
5394
5406
|
_this.noSupplier = true;
|
|
5395
5407
|
_this.miam.user.reset();
|
|
5396
|
-
_this.generateAuthlessIdIfNecessary().subscribe();
|
|
5397
5408
|
_this.posService.posFromStorage();
|
|
5398
5409
|
}
|
|
5399
5410
|
else {
|
|
@@ -5405,17 +5416,23 @@
|
|
|
5405
5416
|
loadWithExternalId: function (id, forbidProfiling, initBasket) {
|
|
5406
5417
|
if (forbidProfiling === void 0) { forbidProfiling = false; }
|
|
5407
5418
|
if (initBasket === void 0) { initBasket = false; }
|
|
5419
|
+
_this.loggedOnSession = true;
|
|
5408
5420
|
localStorage.setItem('_miam/userId', id);
|
|
5409
5421
|
localStorage.removeItem('_miam/userToken');
|
|
5410
5422
|
return _this.logUser(id, forbidProfiling, initBasket);
|
|
5411
5423
|
},
|
|
5412
5424
|
reset: function () {
|
|
5425
|
+
_this.loggedOnSession = false;
|
|
5413
5426
|
localStorage.removeItem('_miam/userToken');
|
|
5414
5427
|
localStorage.removeItem('_miam/userId');
|
|
5428
|
+
localStorage.removeItem('_miam/basketId');
|
|
5415
5429
|
_this.userService.toggleIsLogged(false);
|
|
5416
|
-
|
|
5417
|
-
_this.
|
|
5418
|
-
|
|
5430
|
+
_this.basketHandler.resetMiam();
|
|
5431
|
+
_this.generateAuthlessIdIfNecessary().pipe(operators.switchMap(function () {
|
|
5432
|
+
_this.userService.resetUserInfo();
|
|
5433
|
+
console.log('[Miam] will refresh list after reset');
|
|
5434
|
+
return _this.basketsService.refreshCurrentBasket();
|
|
5435
|
+
}), operators.take(1)).subscribe();
|
|
5419
5436
|
},
|
|
5420
5437
|
setFavoriteItems: function (favoriteProductIds) { return _this.userService.setFavoriteItems(favoriteProductIds); },
|
|
5421
5438
|
setLocation: function (coords) { return _this.userService.userCoordinates$.next(coords); }
|
|
@@ -5506,7 +5523,7 @@
|
|
|
5506
5523
|
if (initBasket) {
|
|
5507
5524
|
this.basketsService.initBasket();
|
|
5508
5525
|
}
|
|
5509
|
-
return this.userService.generatingAuthlessId$.pipe(operators.skipWhile(function (generating) { return generating; }), operators.switchMap(function () {
|
|
5526
|
+
return this.userService.generatingAuthlessId$.pipe(operators.skipWhile(function (generating) { return generating; }), operators.take(1), operators.switchMap(function () {
|
|
5510
5527
|
if (!!localStorage.getItem('_miam/authlessId') && !!localStorage.getItem('_miam/basketId')) {
|
|
5511
5528
|
return _this.basketsService.reloadBasket();
|
|
5512
5529
|
}
|
|
@@ -5527,7 +5544,11 @@
|
|
|
5527
5544
|
};
|
|
5528
5545
|
ContextService.prototype.generateAuthlessIdIfNecessary = function () {
|
|
5529
5546
|
var _this = this;
|
|
5530
|
-
return this.userService.generatingAuthlessId$.pipe(operators.take(1), operators.switchMap(function (isGenerating) { return isGenerating
|
|
5547
|
+
return this.userService.generatingAuthlessId$.pipe(operators.take(1), operators.switchMap(function (isGenerating) { return isGenerating
|
|
5548
|
+
|| _this.loggedOnSession
|
|
5549
|
+
|| !!localStorage.getItem('_miam/authlessId')
|
|
5550
|
+
? rxjs.of(null)
|
|
5551
|
+
: _this.userService.generateAnonymousUserId(); }));
|
|
5531
5552
|
};
|
|
5532
5553
|
return ContextService;
|
|
5533
5554
|
}());
|
|
@@ -8953,7 +8974,7 @@
|
|
|
8953
8974
|
request = request.clone({
|
|
8954
8975
|
setHeaders: {
|
|
8955
8976
|
'miam-origin': this.context.origin.value,
|
|
8956
|
-
'miam-front-version': '8.3.
|
|
8977
|
+
'miam-front-version': '8.3.1',
|
|
8957
8978
|
'miam-front-type': 'web',
|
|
8958
8979
|
'miam-api-version': '4.7.0',
|
|
8959
8980
|
'language-id': environment$1.lang
|
|
@@ -13437,6 +13458,9 @@
|
|
|
13437
13458
|
this.subscriptions.push(this.recipeDetailsService.productsByCategory$.subscribe(function () { return _this.isProductSponsored(); }), this.executeActionFromStorage(), this.loadOnRecipesActions(), this.loadOnIngredientsRemoval(), this.updateIngredientQuantityOnRecipeChange());
|
|
13438
13459
|
};
|
|
13439
13460
|
ProductCardComponent.prototype.ngOnChanges = function (changes) {
|
|
13461
|
+
if (changes.originTrace) {
|
|
13462
|
+
return;
|
|
13463
|
+
}
|
|
13440
13464
|
this.recipesIncludingIngredient = this.isInXRecipes();
|
|
13441
13465
|
this.loadingAddToBasket = false;
|
|
13442
13466
|
if (changes.ingredient) {
|
|
@@ -13631,7 +13655,7 @@
|
|
|
13631
13655
|
if (rf & 2) {
|
|
13632
13656
|
i0__namespace.ɵɵproperty("ngIf", ctx.product.basketEntry);
|
|
13633
13657
|
}
|
|
13634
|
-
}, directives: [i2__namespace$1.NgIf, i2__namespace$1.NgClass, PriceComponent, CounterInputComponent], pipes: [CapitalizeFirstLetterPipe, i2__namespace$1.DecimalPipe, i2__namespace$1.CurrencyPipe, i2__namespace$1.AsyncPipe], styles: [".miam-product-card__container{display:flex;flex-direction:column;box-sizing:border-box;height:100%;border-radius:8px;overflow:hidden;border:1px solid var(--miam-ds-color-primary-100,#e4eaec);background:var(--miam-ds-color-primary-text,#fff);transition:all .3s}.miam-product-card__container.added{border:1px solid var(--miam-ds-color-primary,#24748f);background:var(--miam-ds-color-primary-text,#fff)}.miam-product-card__container .miam-product-card__header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:8px;padding:8px;color:var(--miam-ds-color-neutral-black,#1f3543);background:var(--miam-ds-color-primary-100,#e4eaec);transition:all .3s}.miam-product-card__container .miam-product-card__header.added{background:var(--miam-ds-color-primary,#24748f);color:var(--core-background-background-primary,#fff)}.miam-product-card__container .miam-product-card__header.disabled{background:var(--miam-ds-color-neutral-200,#d9dde1)}.miam-product-card__container .miam-product-card__header .miam-product-card__header-quantity{text-align:right}.miam-product-card__container .miam-product-card__content{padding:8px 12px;height:100%;display:flex;flex-direction:column;gap:12px;background-color:var(--miam-ds-color-neutral-white,#fff);transition:background-color .3s}.miam-product-card__container .miam-product-card__content.disabled{justify-content:center;align-items:center;gap:12px;padding:12px;text-align:center;background-color:var(--miam-ds-color-neutral-200,#d9dde1)}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content{padding:12px}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content{padding:12px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{display:flex;align-items:center;justify-content:center;flex-direction:column;height:100%}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{flex-direction:row;justify-content:flex-start;align-items:flex-start;gap:16px}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{flex-direction:row;justify-content:flex-start;align-items:flex-start;gap:16px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__picture{height:72px;width:72px}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{display:flex;flex-direction:column;align-items:center;justify-content:center}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{align-items:flex-start}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{align-items:flex-start}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details{font-size:12px!important;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;color:var(--miam-ds-color-neutral-black,#1f3543)}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details.product-brand{text-transform:uppercase}@media screen{.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details.product-fullname{height:36px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__link{font-size:14px}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__badges{display:flex;gap:8px;margin:8px 0}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__badges .miam-product-card__badge-text{color:var(--miam-ds-color-neutral-black,#1f3543);font-size:12px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action{display:flex;align-items:center;justify-content:space-between;gap:8px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta{display:flex;align-items:center;gap:12px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-ds-button.square{padding:8px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-product-card__loading-button{padding:14px}@media (max-width:1024px){.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-ds-button.primary:hover{background-color:var(--miam-ds-color-primary)}}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__price{color:var(--miam-ds-color-primary,#24748f)}.miam-product-card__container .miam-product-card__disabled-text{color:var(--miam-ds-color-neutral-black,#1f3543);opacity:.65}.miam-product-card__container .miam-product-card__footer{display:flex;flex-direction:column;align-items:center;background:var(--miam-ds-color-primary-50,#f0f3f4);padding:8px}.miam-product-card__container .miam-product-card__footer .light-text{color:var(--miam-ds-color-neutral-black,#1f3543);opacity:.5}"], encapsulation: 2, changeDetection: 0 });
|
|
13658
|
+
}, directives: [i2__namespace$1.NgIf, i2__namespace$1.NgClass, PriceComponent, CounterInputComponent], pipes: [CapitalizeFirstLetterPipe, i2__namespace$1.DecimalPipe, i2__namespace$1.CurrencyPipe, i2__namespace$1.AsyncPipe], styles: [".miam-product-card__container{display:flex;flex-direction:column;box-sizing:border-box;height:100%;border-radius:8px;overflow:hidden;border:1px solid var(--miam-ds-color-primary-100,#e4eaec);background:var(--miam-ds-color-primary-text,#fff);transition:all .3s}.miam-product-card__container.added{border:1px solid var(--miam-ds-color-primary,#24748f);background:var(--miam-ds-color-primary-text,#fff)}.miam-product-card__container .miam-product-card__header{display:flex;flex-direction:row;align-items:center;justify-content:space-between;gap:8px;padding:8px;color:var(--miam-ds-color-neutral-black,#1f3543);background:var(--miam-ds-color-primary-100,#e4eaec);transition:all .3s}.miam-product-card__container .miam-product-card__header.added{background:var(--miam-ds-color-primary,#24748f);color:var(--core-background-background-primary,#fff)}.miam-product-card__container .miam-product-card__header.disabled{background:var(--miam-ds-color-neutral-200,#d9dde1)}.miam-product-card__container .miam-product-card__header .miam-product-card__header-quantity{text-align:right}.miam-product-card__container .miam-product-card__content{padding:8px 12px;height:100%;display:flex;flex-direction:column;gap:12px;background-color:var(--miam-ds-color-neutral-white,#fff);transition:background-color .3s}.miam-product-card__container .miam-product-card__content.disabled{justify-content:center;align-items:center;gap:12px;padding:12px;text-align:center;background-color:var(--miam-ds-color-neutral-200,#d9dde1)}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content{padding:12px}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content{padding:12px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{display:flex;align-items:center;justify-content:center;flex-direction:column;height:100%}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{flex-direction:row;justify-content:flex-start;align-items:flex-start;gap:16px}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product{flex-direction:row;justify-content:flex-start;align-items:flex-start;gap:16px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__picture{height:72px;width:72px}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{display:flex;flex-direction:column;align-items:center;justify-content:center}@media (max-width:1023px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{align-items:flex-start}}@media (min-width:1023px) and (max-height:800px){.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column{align-items:flex-start}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details{font-size:12px!important;overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;color:var(--miam-ds-color-neutral-black,#1f3543)}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details.product-brand{text-transform:uppercase}@media screen{.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__details.product-fullname{height:36px}}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__info-column .miam-product-card__link{font-size:14px}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__badges{display:flex;gap:8px;margin:8px 0}.miam-product-card__container .miam-product-card__content .miam-product-card__selected-product .miam-product-card__badges .miam-product-card__badge-text{color:var(--miam-ds-color-neutral-black,#1f3543);font-size:12px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action{display:flex;align-items:center;justify-content:space-between;gap:8px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta{display:flex;align-items:center;gap:12px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-ds-button.square{padding:8px;height:40px;width:40px}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-product-card__loading-button{padding:14px}@media (max-width:1024px){.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__cta .miam-ds-button.primary:hover{background-color:var(--miam-ds-color-primary)}}.miam-product-card__container .miam-product-card__content .miam-product-card__lower-action .miam-product-card__price{color:var(--miam-ds-color-primary,#24748f)}.miam-product-card__container .miam-product-card__disabled-text{color:var(--miam-ds-color-neutral-black,#1f3543);opacity:.65}.miam-product-card__container .miam-product-card__footer{display:flex;flex-direction:column;align-items:center;background:var(--miam-ds-color-primary-50,#f0f3f4);padding:8px}.miam-product-card__container .miam-product-card__footer .light-text{color:var(--miam-ds-color-neutral-black,#1f3543);opacity:.5}"], encapsulation: 2, changeDetection: 0 });
|
|
13635
13659
|
(function () {
|
|
13636
13660
|
(typeof ngDevMode === "undefined" || ngDevMode) && i0__namespace.ɵsetClassMetadata(ProductCardComponent, [{
|
|
13637
13661
|
type: i0.Component,
|
|
@@ -23139,13 +23163,8 @@
|
|
|
23139
23163
|
};
|
|
23140
23164
|
PreferencesComponent.prototype.updateRecipesCount = function () {
|
|
23141
23165
|
var _this = this;
|
|
23142
|
-
this.subscriptions.push(this.recipesService.
|
|
23143
|
-
|
|
23144
|
-
}).pipe(operators.skipWhile(function (result) { return result.is_loading; }))
|
|
23145
|
-
.subscribe(function (result) {
|
|
23146
|
-
var _a;
|
|
23147
|
-
// Apparently total_resource = 1 even if no result was found so we have to check
|
|
23148
|
-
_this.recipesFound = result.data.length ? (_a = result === null || result === void 0 ? void 0 : result.page) === null || _a === void 0 ? void 0 : _a.total_resources : 0;
|
|
23166
|
+
this.subscriptions.push(this.recipesService.filterCount(this.filters, this.preferencesService.guests$.value, [], true).pipe().subscribe(function (result) {
|
|
23167
|
+
_this.recipesFound = result;
|
|
23149
23168
|
_this.cdr.detectChanges();
|
|
23150
23169
|
}));
|
|
23151
23170
|
};
|
|
@@ -23172,7 +23191,7 @@
|
|
|
23172
23191
|
return PreferencesComponent;
|
|
23173
23192
|
}());
|
|
23174
23193
|
PreferencesComponent.ɵfac = function PreferencesComponent_Factory(t) { return new (t || PreferencesComponent)(i0__namespace.ɵɵdirectiveInject(TagsService), i0__namespace.ɵɵdirectiveInject(i0__namespace.ChangeDetectorRef), i0__namespace.ɵɵdirectiveInject(PreferencesService), i0__namespace.ɵɵdirectiveInject(RecipesService)); };
|
|
23175
|
-
PreferencesComponent.ɵcmp = i0__namespace.ɵɵdefineComponent({ type: PreferencesComponent, selectors: [["ng-miam-preferences"]], inputs: { isOpen: "isOpen" }, outputs: { isOpenChange: "isOpenChange", preferencesChanged: "preferencesChanged" }, decls: 7, vars: 6, consts: function () {
|
|
23194
|
+
PreferencesComponent.ɵcmp = i0__namespace.ɵɵdefineComponent({ type: PreferencesComponent, selectors: [["ng-miam-preferences"]], inputs: { filters: "filters", isOpen: "isOpen" }, outputs: { isOpenChange: "isOpenChange", preferencesChanged: "preferencesChanged" }, decls: 7, vars: 6, consts: function () {
|
|
23176
23195
|
var i18n_0;
|
|
23177
23196
|
if (typeof ngI18nClosureMode !== "undefined" && ngI18nClosureMode) {
|
|
23178
23197
|
var MSG_EXTERNAL_5401047837790415175$$LIB__WEB_COMPONENTS_PREFERENCES_PREFERENCES_COMPONENT_TS__1 = goog.getMsg("Mes pr\u00E9f\u00E9rences");
|
|
@@ -23294,6 +23313,8 @@
|
|
|
23294
23313
|
type: i0.Output
|
|
23295
23314
|
}], preferencesChanged: [{
|
|
23296
23315
|
type: i0.Output
|
|
23316
|
+
}], filters: [{
|
|
23317
|
+
type: i0.Input
|
|
23297
23318
|
}], isOpen: [{
|
|
23298
23319
|
type: i0.Input
|
|
23299
23320
|
}] });
|
|
@@ -25369,7 +25390,7 @@
|
|
|
25369
25390
|
i0__namespace.ɵɵlistener("filterChanged", function RecipeCatalogComponent_div_2_Template_ng_miam_recipe_filters_filterChanged_7_listener($event) { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r56 = i0__namespace.ɵɵnextContext(); return ctx_r56.updateFilters($event); })("filterCollapsed", function RecipeCatalogComponent_div_2_Template_ng_miam_recipe_filters_filterCollapsed_7_listener() { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r57 = i0__namespace.ɵɵnextContext(); return ctx_r57.onFilterCollapsed(); })("preferencesChanged", function RecipeCatalogComponent_div_2_Template_ng_miam_recipe_filters_preferencesChanged_7_listener() { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r58 = i0__namespace.ɵɵnextContext(); return ctx_r58.reloadPackages(); });
|
|
25370
25391
|
i0__namespace.ɵɵelementEnd();
|
|
25371
25392
|
i0__namespace.ɵɵelementStart(8, "ng-miam-preferences", 12);
|
|
25372
|
-
i0__namespace.ɵɵlistener("isOpenChange", function RecipeCatalogComponent_div_2_Template_ng_miam_preferences_isOpenChange_8_listener($event) { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r59 = i0__namespace.ɵɵnextContext(); return ctx_r59.isPreferenceModalOpen = $event; })("preferencesChanged", function RecipeCatalogComponent_div_2_Template_ng_miam_preferences_preferencesChanged_8_listener() { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r60 = i0__namespace.ɵɵnextContext(); return ctx_r60.reloadPackages(); });
|
|
25393
|
+
i0__namespace.ɵɵlistener("isOpenChange", function RecipeCatalogComponent_div_2_Template_ng_miam_preferences_isOpenChange_8_listener($event) { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r59 = i0__namespace.ɵɵnextContext(); return ctx_r59.isPreferenceModalOpen = $event; })("preferencesChanged", function RecipeCatalogComponent_div_2_Template_ng_miam_preferences_preferencesChanged_8_listener() { i0__namespace.ɵɵrestoreView(_r55_1); var ctx_r60 = i0__namespace.ɵɵnextContext(); ctx_r60.updateFilters(ctx_r60.filters); return ctx_r60.reloadPackages(); });
|
|
25373
25394
|
i0__namespace.ɵɵelementEnd();
|
|
25374
25395
|
i0__namespace.ɵɵtemplate(9, RecipeCatalogComponent_div_2_ng_template_9_Template, 1, 1, "ng-template", null, 13, i0__namespace.ɵɵtemplateRefExtractor);
|
|
25375
25396
|
i0__namespace.ɵɵelementEnd();
|
|
@@ -25390,7 +25411,7 @@
|
|
|
25390
25411
|
i0__namespace.ɵɵadvance(1);
|
|
25391
25412
|
i0__namespace.ɵɵproperty("filters", ctx_r1.filters)("isFilterCollapsed", ctx_r1.isFilterCollapsed)("filterToRemove", ctx_r1.filterToRemove)("position", ctx_r1.filtersPosition)("originTrace", ctx_r1.eventTrace());
|
|
25392
25413
|
i0__namespace.ɵɵadvance(1);
|
|
25393
|
-
i0__namespace.ɵɵproperty("isOpen", ctx_r1.isPreferenceModalOpen);
|
|
25414
|
+
i0__namespace.ɵɵproperty("isOpen", ctx_r1.isPreferenceModalOpen)("filters", ctx_r1.filters);
|
|
25394
25415
|
}
|
|
25395
25416
|
}
|
|
25396
25417
|
function RecipeCatalogComponent_ng_template_3_ng_miam_recipe_stepper_0_Template(rf, ctx) {
|
|
@@ -25862,11 +25883,11 @@
|
|
|
25862
25883
|
else {
|
|
25863
25884
|
i18n_12 = $localize(templateObject_6$2 || (templateObject_6$2 = __makeTemplateObject([":\u241F3b0b12b85604af610c07cfbd5d4f74662b9a881a\u241F1931799427977453728:Ajouter une id\u00E9e repas"], [":\u241F3b0b12b85604af610c07cfbd5d4f74662b9a881a\u241F1931799427977453728:Ajouter une id\u00E9e repas"])));
|
|
25864
25885
|
}
|
|
25865
|
-
return [[1, "miam-catalog-anchor"], ["miamCatalogTopAnchor", ""], ["class", "miam-recipe-catalog", 4, "ngIf", "ngIfElse"], ["creationPage", ""], [1, "miam-recipe-catalog"], [1, "miam-recipe-catalog__content"], [3, "home", "searchTerm", "additionalFiltersTitle", "homeLabel", "pictureUrl", "catalogSetting", "returnButtonPressed"], ["class", "miam-recipe-catalog__toolbar-container-anchor", 4, "ngIf"], ["class", "miam-recipe-catalog__toolbar-container", 4, "ngIf"], ["class", "miam-recipe-catalog__content__myMeal__button", 3, "click", 4, "ngIf"], ["class", "miam-recipe-catalog__list", 4, "ngIf", "ngIfElse"], [3, "filters", "isFilterCollapsed", "filterToRemove", "position", "originTrace", "filterChanged", "filterCollapsed", "preferencesChanged"], [3, "isOpen", "isOpenChange", "preferencesChanged"], ["categoriesComponents", ""], [1, "miam-recipe-catalog__toolbar-container-anchor"], [1, "miam-recipe-catalog__toolbar-container"], ["stickyToolbar", ""], [3, "home", "searchTerm", "additionalFiltersTitle", "favoritesButtonHidden", "personalButtonHidden", "filterBadgeCount", "reduced", "filterButtonPressed", "preferencesButtonPressed", "searchStringChanged", "personalButtonPressed", "favoritesButtonPressed", "returnHomePressed"], [1, "miam-recipe-catalog__content__myMeal__button", 3, "click"], ["src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/cutlery-white.svg", "alt", "Cutlery", 1, "miam-recipe-catalog__myMeal__first__icon"], [1, "miam-recipe-catalog__myMeal__button__text", "miam-ds-text", "weight-xl"], i18n_2, ["src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/chevron-down-white.svg", "alt", "Caret", 1, "miam-recipe-catalog__myMeal__second__icon"], [1, "miam-recipe-catalog__list"], [1, "miam-recipe-catalog__content__title"], [1, "miam-recipe-catalog__content__title-icon", "miam-ds-button", "primary", "square", 3, "click"], ["alt", "return", "src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/ArrowLeft_white.svg"], ["class", "miam-recipe-catalog__content__title__search__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__favorites__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__personal__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__category", 4, "ngIf"], ["class", "miam-recipe-catalog__content__default__text", 4, "ngIf"], ["stickyToolbarCollection", ""], ["class", "miam-recipe-catalog__list__create___button", 3, "click", 4, "ngIf"], [3, "ngClass", "filters", "originTrace", "displayPricing", "displayInfos", "modifiedGuests", "filterRemoved", "recipeActionTriggered"], [1, "miam-recipe-catalog__content__title__search__text"], i18n_4, [1, "miam-recipe-catalog__content__title__favorites__text"], i18n_6, [1, "miam-recipe-catalog__content__title__personal__text"], i18n_8, [1, "miam-recipe-catalog__content__title__category"], [1, "miam-ds-text", "size-l", "weight-xxl"], ["class", "miam-ds-text size-s weight-l", 4, "ngIf"], [1, "miam-ds-text", "size-s", "weight-l"], [1, "miam-recipe-catalog__content__default__text"], i18n_10, [1, "miam-recipe-catalog__list__create___button", 3, "click"], ["width", "24", "height", "24", "primaryColor", "var(--m-color-primary)", 3, "iconName"], i18n_12, ["class", "miam-recipe-catalog__categories", 4, "ngIf"], [1, "miam-recipe-catalog__categories"], [4, "ngFor", "ngForOf"], [4, "ngIf", "ngIfElse"], ["firstCategory", ""], [3, "title", "subtitle", "filters", "displayInfos", "displayPricing", "originTrace", "modifiedGuests", "displayList"], [1, "miam-recipe-catalog__first-category"], [4, "ngIf"], [3, "title", "subtitle", "filters", "displayInfos", "displayPricing", "modifiedGuests", "originTrace", "displayList"], [3, "recipeToUpdate", "originTrace", "recipeChange", "canceled", 4, "ngIf"], [3, "recipeToUpdate", "originTrace", "recipeChange", "canceled"]];
|
|
25886
|
+
return [[1, "miam-catalog-anchor"], ["miamCatalogTopAnchor", ""], ["class", "miam-recipe-catalog", 4, "ngIf", "ngIfElse"], ["creationPage", ""], [1, "miam-recipe-catalog"], [1, "miam-recipe-catalog__content"], [3, "home", "searchTerm", "additionalFiltersTitle", "homeLabel", "pictureUrl", "catalogSetting", "returnButtonPressed"], ["class", "miam-recipe-catalog__toolbar-container-anchor", 4, "ngIf"], ["class", "miam-recipe-catalog__toolbar-container", 4, "ngIf"], ["class", "miam-recipe-catalog__content__myMeal__button", 3, "click", 4, "ngIf"], ["class", "miam-recipe-catalog__list", 4, "ngIf", "ngIfElse"], [3, "filters", "isFilterCollapsed", "filterToRemove", "position", "originTrace", "filterChanged", "filterCollapsed", "preferencesChanged"], [3, "isOpen", "filters", "isOpenChange", "preferencesChanged"], ["categoriesComponents", ""], [1, "miam-recipe-catalog__toolbar-container-anchor"], [1, "miam-recipe-catalog__toolbar-container"], ["stickyToolbar", ""], [3, "home", "searchTerm", "additionalFiltersTitle", "favoritesButtonHidden", "personalButtonHidden", "filterBadgeCount", "reduced", "filterButtonPressed", "preferencesButtonPressed", "searchStringChanged", "personalButtonPressed", "favoritesButtonPressed", "returnHomePressed"], [1, "miam-recipe-catalog__content__myMeal__button", 3, "click"], ["src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/cutlery-white.svg", "alt", "Cutlery", 1, "miam-recipe-catalog__myMeal__first__icon"], [1, "miam-recipe-catalog__myMeal__button__text", "miam-ds-text", "weight-xl"], i18n_2, ["src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/chevron-down-white.svg", "alt", "Caret", 1, "miam-recipe-catalog__myMeal__second__icon"], [1, "miam-recipe-catalog__list"], [1, "miam-recipe-catalog__content__title"], [1, "miam-recipe-catalog__content__title-icon", "miam-ds-button", "primary", "square", 3, "click"], ["alt", "return", "src", "https://storage.googleapis.com/assets.miam.tech/generic/icons/ArrowLeft_white.svg"], ["class", "miam-recipe-catalog__content__title__search__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__favorites__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__personal__text", 4, "ngIf"], ["class", "miam-recipe-catalog__content__title__category", 4, "ngIf"], ["class", "miam-recipe-catalog__content__default__text", 4, "ngIf"], ["stickyToolbarCollection", ""], ["class", "miam-recipe-catalog__list__create___button", 3, "click", 4, "ngIf"], [3, "ngClass", "filters", "originTrace", "displayPricing", "displayInfos", "modifiedGuests", "filterRemoved", "recipeActionTriggered"], [1, "miam-recipe-catalog__content__title__search__text"], i18n_4, [1, "miam-recipe-catalog__content__title__favorites__text"], i18n_6, [1, "miam-recipe-catalog__content__title__personal__text"], i18n_8, [1, "miam-recipe-catalog__content__title__category"], [1, "miam-ds-text", "size-l", "weight-xxl"], ["class", "miam-ds-text size-s weight-l", 4, "ngIf"], [1, "miam-ds-text", "size-s", "weight-l"], [1, "miam-recipe-catalog__content__default__text"], i18n_10, [1, "miam-recipe-catalog__list__create___button", 3, "click"], ["width", "24", "height", "24", "primaryColor", "var(--m-color-primary)", 3, "iconName"], i18n_12, ["class", "miam-recipe-catalog__categories", 4, "ngIf"], [1, "miam-recipe-catalog__categories"], [4, "ngFor", "ngForOf"], [4, "ngIf", "ngIfElse"], ["firstCategory", ""], [3, "title", "subtitle", "filters", "displayInfos", "displayPricing", "originTrace", "modifiedGuests", "displayList"], [1, "miam-recipe-catalog__first-category"], [4, "ngIf"], [3, "title", "subtitle", "filters", "displayInfos", "displayPricing", "modifiedGuests", "originTrace", "displayList"], [3, "recipeToUpdate", "originTrace", "recipeChange", "canceled", 4, "ngIf"], [3, "recipeToUpdate", "originTrace", "recipeChange", "canceled"]];
|
|
25866
25887
|
}, template: function RecipeCatalogComponent_Template(rf, ctx) {
|
|
25867
25888
|
if (rf & 1) {
|
|
25868
25889
|
i0__namespace.ɵɵelement(0, "div", 0, 1);
|
|
25869
|
-
i0__namespace.ɵɵtemplate(2, RecipeCatalogComponent_div_2_Template, 11,
|
|
25890
|
+
i0__namespace.ɵɵtemplate(2, RecipeCatalogComponent_div_2_Template, 11, 18, "div", 2);
|
|
25870
25891
|
i0__namespace.ɵɵtemplate(3, RecipeCatalogComponent_ng_template_3_Template, 1, 1, "ng-template", null, 3, i0__namespace.ɵɵtemplateRefExtractor);
|
|
25871
25892
|
}
|
|
25872
25893
|
if (rf & 2) {
|