ng-miam 4.7.3 → 4.7.5
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 +377 -114
- package/bundles/ng-miam.umd.js.map +1 -1
- package/bundles/ng-miam.umd.min.js +2 -2
- package/bundles/ng-miam.umd.min.js.map +1 -1
- package/esm2015/lib/_components/abstracts/abstract-recipe-card.component.js +2 -1
- package/esm2015/lib/_components/components.module.js +1 -1
- package/esm2015/lib/_components/list-input/list-input.component.js +140 -57
- package/esm2015/lib/_models/ingredient.js +3 -2
- package/esm2015/lib/_models/tag.js +2 -5
- package/esm2015/lib/_services/ingredients.service.js +5 -4
- package/esm2015/lib/_web-components/index.js +2 -1
- package/esm2015/lib/_web-components/loader/loader.component.js +3 -3
- package/esm2015/lib/_web-components/recipe-catalog/recipe-catalog.component.js +2 -2
- package/esm2015/lib/_web-components/recipe-details/recipe-details.component.js +1 -1
- package/esm2015/lib/_web-components/recipe-form/recipe-form.component.js +7 -1
- package/esm2015/lib/_web-components/recipe-stepper/recipe-stepper.component.js +6 -6
- package/esm2015/lib/_web-components/recipe-tags/recipe-tags.component.js +2 -5
- package/esm2015/lib/_web-components/tags-creator/tags-creator.component.js +81 -0
- package/esm2015/lib/_web-components/tags-selector/tags-selector.component.js +104 -36
- package/esm2015/lib/_web-components/web-components.module.js +12 -7
- package/fesm2015/ng-miam.js +344 -116
- package/fesm2015/ng-miam.js.map +1 -1
- package/lib/_components/list-input/list-input.component.d.ts +12 -1
- package/lib/_models/ingredient.d.ts +2 -1
- package/lib/_models/tag.d.ts +1 -5
- package/lib/_web-components/index.d.ts +1 -0
- package/lib/_web-components/recipe-catalog/recipe-catalog.component.d.ts +15 -1
- package/lib/_web-components/recipe-tags/recipe-tags.component.d.ts +2 -3
- package/lib/_web-components/tags-creator/tags-creator.component.d.ts +21 -0
- package/lib/_web-components/tags-selector/tags-selector.component.d.ts +12 -4
- package/lib/_web-components/web-components.module.d.ts +15 -14
- package/package.json +1 -1
package/bundles/ng-miam.umd.js
CHANGED
|
@@ -2669,6 +2669,7 @@
|
|
|
2669
2669
|
name: '',
|
|
2670
2670
|
quantity: '',
|
|
2671
2671
|
unit: '',
|
|
2672
|
+
importance: '',
|
|
2672
2673
|
active: true,
|
|
2673
2674
|
'forced-eans': [],
|
|
2674
2675
|
'picture-url': ''
|
|
@@ -2816,9 +2817,6 @@
|
|
|
2816
2817
|
'icon-url': '',
|
|
2817
2818
|
'picture-url': ''
|
|
2818
2819
|
};
|
|
2819
|
-
_this.relationships = {
|
|
2820
|
-
recipe: new i1.DocumentResource()
|
|
2821
|
-
};
|
|
2822
2820
|
return _this;
|
|
2823
2821
|
}
|
|
2824
2822
|
Object.defineProperty(Tag.prototype, "tagType", {
|
|
@@ -3768,16 +3766,17 @@
|
|
|
3768
3766
|
var oldIngredientAttribute = oldIngredients[oldIndex].attributes;
|
|
3769
3767
|
var hasChange = oldIngredientAttribute.name !== ing.attributes.name ||
|
|
3770
3768
|
oldIngredientAttribute.unit !== ing.attributes.unit ||
|
|
3771
|
-
oldIngredientAttribute.quantity !== ing.attributes.quantity
|
|
3769
|
+
oldIngredientAttribute.quantity !== ing.attributes.quantity ||
|
|
3770
|
+
oldIngredientAttribute.importance !== ing.attributes.importance;
|
|
3772
3771
|
if (hasChange) {
|
|
3773
|
-
oldIngredients[oldIndex].attributes = Object.assign(Object.assign({}, oldIngredients[oldIndex].attributes), { name: ing.attributes.name, unit: ing.attributes.unit, quantity: ing.attributes.quantity, 'picture-url': ing.attributes['picture-url'] });
|
|
3772
|
+
oldIngredients[oldIndex].attributes = Object.assign(Object.assign({}, oldIngredients[oldIndex].attributes), { name: ing.attributes.name, unit: ing.attributes.unit, quantity: ing.attributes.quantity, importance: ing.attributes.importance, 'picture-url': ing.attributes['picture-url'] });
|
|
3774
3773
|
ingredientsToSave.push(oldIngredients[oldIndex]);
|
|
3775
3774
|
}
|
|
3776
3775
|
}
|
|
3777
3776
|
else {
|
|
3778
3777
|
var newIng = _this.new();
|
|
3779
3778
|
delete newIng.id;
|
|
3780
|
-
newIng.attributes = Object.assign(Object.assign({}, newIng.attributes), { name: ing.attributes.name, unit: ing.attributes.unit, quantity: '' + ing.attributes.quantity, 'picture-url': ing.attributes['picture-url'] });
|
|
3779
|
+
newIng.attributes = Object.assign(Object.assign({}, newIng.attributes), { name: ing.attributes.name, unit: ing.attributes.unit, quantity: '' + ing.attributes.quantity, importance: ing.attributes.importance, 'picture-url': ing.attributes['picture-url'] });
|
|
3781
3780
|
newIng.addRelationship(recipe, 'recipe');
|
|
3782
3781
|
ingredientsToSave.push(newIng);
|
|
3783
3782
|
}
|
|
@@ -6682,67 +6681,139 @@
|
|
|
6682
6681
|
}
|
|
6683
6682
|
function ListInputComponent_ul_4_ng_template_2_li_0_option_9_Template(rf, ctx) {
|
|
6684
6683
|
if (rf & 1) {
|
|
6685
|
-
i0.ɵɵelement(0, "option",
|
|
6684
|
+
i0.ɵɵelement(0, "option", 38);
|
|
6686
6685
|
i0.ɵɵpipe(1, "capitalizeFirstLetter");
|
|
6687
6686
|
}
|
|
6688
6687
|
if (rf & 2) {
|
|
6689
|
-
var
|
|
6690
|
-
i0.ɵɵproperty("value", i0.ɵɵpipeBind1(1, 1,
|
|
6688
|
+
var ing_r27 = ctx.$implicit;
|
|
6689
|
+
i0.ɵɵproperty("value", i0.ɵɵpipeBind1(1, 1, ing_r27));
|
|
6691
6690
|
}
|
|
6692
6691
|
}
|
|
6693
6692
|
function ListInputComponent_ul_4_ng_template_2_li_0_option_14_Template(rf, ctx) {
|
|
6694
6693
|
if (rf & 1) {
|
|
6695
|
-
i0.ɵɵelement(0, "option",
|
|
6694
|
+
i0.ɵɵelement(0, "option", 38);
|
|
6695
|
+
}
|
|
6696
|
+
if (rf & 2) {
|
|
6697
|
+
var unit_r28 = ctx.$implicit;
|
|
6698
|
+
i0.ɵɵproperty("value", unit_r28);
|
|
6699
|
+
}
|
|
6700
|
+
}
|
|
6701
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_2_Template(rf, ctx) {
|
|
6702
|
+
if (rf & 1) {
|
|
6703
|
+
i0.ɵɵelementStart(0, "label", 43);
|
|
6704
|
+
i0.ɵɵtext(1, "Primordial");
|
|
6705
|
+
i0.ɵɵelementEnd();
|
|
6696
6706
|
}
|
|
6697
6707
|
if (rf & 2) {
|
|
6698
|
-
var
|
|
6699
|
-
i0.ɵɵ
|
|
6708
|
+
var i_r19 = i0.ɵɵnextContext(3).index;
|
|
6709
|
+
i0.ɵɵpropertyInterpolate("for", "importance-id-primary" + i_r19);
|
|
6710
|
+
}
|
|
6711
|
+
}
|
|
6712
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_3_Template(rf, ctx) {
|
|
6713
|
+
if (rf & 1) {
|
|
6714
|
+
i0.ɵɵelementStart(0, "label", 43);
|
|
6715
|
+
i0.ɵɵtext(1, "Secondaire");
|
|
6716
|
+
i0.ɵɵelementEnd();
|
|
6717
|
+
}
|
|
6718
|
+
if (rf & 2) {
|
|
6719
|
+
var i_r19 = i0.ɵɵnextContext(3).index;
|
|
6720
|
+
i0.ɵɵpropertyInterpolate("for", "importance-id-secondary" + i_r19);
|
|
6721
|
+
}
|
|
6722
|
+
}
|
|
6723
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_4_Template(rf, ctx) {
|
|
6724
|
+
if (rf & 1) {
|
|
6725
|
+
i0.ɵɵelementStart(0, "label", 43);
|
|
6726
|
+
i0.ɵɵtext(1, "Facultatif");
|
|
6727
|
+
i0.ɵɵelementEnd();
|
|
6728
|
+
}
|
|
6729
|
+
if (rf & 2) {
|
|
6730
|
+
var i_r19 = i0.ɵɵnextContext(3).index;
|
|
6731
|
+
i0.ɵɵpropertyInterpolate("for", "importance-id-tertiary" + i_r19);
|
|
6732
|
+
}
|
|
6733
|
+
}
|
|
6734
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_Template(rf, ctx) {
|
|
6735
|
+
if (rf & 1) {
|
|
6736
|
+
var _r39_1 = i0.ɵɵgetCurrentView();
|
|
6737
|
+
i0.ɵɵelementStart(0, "div", 41);
|
|
6738
|
+
i0.ɵɵelementStart(1, "input", 42);
|
|
6739
|
+
i0.ɵɵlistener("click", function ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_Template_input_click_1_listener() { i0.ɵɵrestoreView(_r39_1); var importance_r30 = ctx.$implicit; var i_r19 = i0.ɵɵnextContext(2).index; var ctx_r37 = i0.ɵɵnextContext(3); return ctx_r37.updateImportance(importance_r30, i_r19); });
|
|
6740
|
+
i0.ɵɵelementEnd();
|
|
6741
|
+
i0.ɵɵtemplate(2, ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_2_Template, 2, 1, "label", 36);
|
|
6742
|
+
i0.ɵɵtemplate(3, ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_3_Template, 2, 1, "label", 36);
|
|
6743
|
+
i0.ɵɵtemplate(4, ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_label_4_Template, 2, 1, "label", 36);
|
|
6744
|
+
i0.ɵɵelementEnd();
|
|
6745
|
+
}
|
|
6746
|
+
if (rf & 2) {
|
|
6747
|
+
var importance_r30 = ctx.$implicit;
|
|
6748
|
+
var ctx_r40 = i0.ɵɵnextContext(2);
|
|
6749
|
+
var i_r19 = ctx_r40.index;
|
|
6750
|
+
var row_r18 = ctx_r40.$implicit;
|
|
6751
|
+
i0.ɵɵadvance(1);
|
|
6752
|
+
i0.ɵɵproperty("name", "importance" + i_r19)("id", "importance-id-" + importance_r30 + i_r19)("value", importance_r30)("formControl", row_r18["controls"]["attributes"]["controls"]["importance"]);
|
|
6753
|
+
i0.ɵɵadvance(1);
|
|
6754
|
+
i0.ɵɵproperty("ngIf", importance_r30 === "primary");
|
|
6755
|
+
i0.ɵɵadvance(1);
|
|
6756
|
+
i0.ɵɵproperty("ngIf", importance_r30 === "secondary");
|
|
6757
|
+
i0.ɵɵadvance(1);
|
|
6758
|
+
i0.ɵɵproperty("ngIf", importance_r30 === "tertiary");
|
|
6759
|
+
}
|
|
6760
|
+
}
|
|
6761
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_15_Template(rf, ctx) {
|
|
6762
|
+
if (rf & 1) {
|
|
6763
|
+
i0.ɵɵelementStart(0, "div", 39);
|
|
6764
|
+
i0.ɵɵtemplate(1, ListInputComponent_ul_4_ng_template_2_li_0_div_15_div_1_Template, 5, 7, "div", 40);
|
|
6765
|
+
i0.ɵɵelementEnd();
|
|
6766
|
+
}
|
|
6767
|
+
if (rf & 2) {
|
|
6768
|
+
var ctx_r22 = i0.ɵɵnextContext(4);
|
|
6769
|
+
i0.ɵɵadvance(1);
|
|
6770
|
+
i0.ɵɵproperty("ngForOf", ctx_r22.getImportances());
|
|
6700
6771
|
}
|
|
6701
6772
|
}
|
|
6702
6773
|
var _c0$1 = function (a0) { return { clickable: a0 }; };
|
|
6703
|
-
function
|
|
6774
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_label_17_img_1_Template(rf, ctx) {
|
|
6704
6775
|
if (rf & 1) {
|
|
6705
|
-
i0.ɵɵelement(0, "img",
|
|
6776
|
+
i0.ɵɵelement(0, "img", 46);
|
|
6706
6777
|
}
|
|
6707
6778
|
if (rf & 2) {
|
|
6708
6779
|
var row_r18 = i0.ɵɵnextContext(2).$implicit;
|
|
6709
|
-
var
|
|
6710
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(2, _c0$1,
|
|
6780
|
+
var ctx_r41 = i0.ɵɵnextContext(3);
|
|
6781
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(2, _c0$1, ctx_r41.ingredientsPictures.editable))("src", row_r18.controls.attributes.controls["picture-url"].value, i0.ɵɵsanitizeUrl);
|
|
6711
6782
|
}
|
|
6712
6783
|
}
|
|
6713
|
-
function
|
|
6784
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_label_17_ng_miam_icon_2_Template(rf, ctx) {
|
|
6714
6785
|
if (rf & 1) {
|
|
6715
|
-
i0.ɵɵelement(0, "ng-miam-icon",
|
|
6786
|
+
i0.ɵɵelement(0, "ng-miam-icon", 47);
|
|
6716
6787
|
}
|
|
6717
6788
|
if (rf & 2) {
|
|
6718
|
-
var
|
|
6719
|
-
i0.ɵɵproperty("iconName",
|
|
6789
|
+
var ctx_r42 = i0.ɵɵnextContext(5);
|
|
6790
|
+
i0.ɵɵproperty("iconName", ctx_r42.icon.Picture);
|
|
6720
6791
|
}
|
|
6721
6792
|
}
|
|
6722
|
-
function
|
|
6793
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_label_17_Template(rf, ctx) {
|
|
6723
6794
|
if (rf & 1) {
|
|
6724
|
-
i0.ɵɵelementStart(0, "label",
|
|
6725
|
-
i0.ɵɵtemplate(1,
|
|
6726
|
-
i0.ɵɵtemplate(2,
|
|
6795
|
+
i0.ɵɵelementStart(0, "label", 43);
|
|
6796
|
+
i0.ɵɵtemplate(1, ListInputComponent_ul_4_ng_template_2_li_0_label_17_img_1_Template, 1, 4, "img", 44);
|
|
6797
|
+
i0.ɵɵtemplate(2, ListInputComponent_ul_4_ng_template_2_li_0_label_17_ng_miam_icon_2_Template, 1, 1, "ng-miam-icon", 45);
|
|
6727
6798
|
i0.ɵɵelementEnd();
|
|
6728
6799
|
}
|
|
6729
6800
|
if (rf & 2) {
|
|
6730
|
-
var
|
|
6731
|
-
var i_r19 =
|
|
6732
|
-
var row_r18 =
|
|
6733
|
-
var
|
|
6801
|
+
var ctx_r44 = i0.ɵɵnextContext();
|
|
6802
|
+
var i_r19 = ctx_r44.index;
|
|
6803
|
+
var row_r18 = ctx_r44.$implicit;
|
|
6804
|
+
var ctx_r23 = i0.ɵɵnextContext(3);
|
|
6734
6805
|
i0.ɵɵpropertyInterpolate1("for", "ing-picture-", i_r19, "");
|
|
6735
6806
|
i0.ɵɵadvance(1);
|
|
6736
6807
|
i0.ɵɵproperty("ngIf", row_r18.controls.attributes.controls["picture-url"] == null ? null : row_r18.controls.attributes.controls["picture-url"].value);
|
|
6737
6808
|
i0.ɵɵadvance(1);
|
|
6738
|
-
i0.ɵɵproperty("ngIf", !(row_r18.controls.attributes.controls["picture-url"] == null ? null : row_r18.controls.attributes.controls["picture-url"].value) &&
|
|
6809
|
+
i0.ɵɵproperty("ngIf", !(row_r18.controls.attributes.controls["picture-url"] == null ? null : row_r18.controls.attributes.controls["picture-url"].value) && ctx_r23.ingredientsPictures.editable);
|
|
6739
6810
|
}
|
|
6740
6811
|
}
|
|
6741
|
-
function
|
|
6812
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_input_18_Template(rf, ctx) {
|
|
6742
6813
|
if (rf & 1) {
|
|
6743
|
-
var
|
|
6744
|
-
i0.ɵɵelementStart(0, "input",
|
|
6745
|
-
i0.ɵɵlistener("change", function
|
|
6814
|
+
var _r46_1 = i0.ɵɵgetCurrentView();
|
|
6815
|
+
i0.ɵɵelementStart(0, "input", 48);
|
|
6816
|
+
i0.ɵɵlistener("change", function ListInputComponent_ul_4_ng_template_2_li_0_input_18_Template_input_change_0_listener($event) { i0.ɵɵrestoreView(_r46_1); var row_r18 = i0.ɵɵnextContext().$implicit; var ctx_r45 = i0.ɵɵnextContext(3); return ctx_r45.uploadIngredientPicture($event.target.files, row_r18.controls.attributes.controls["picture-url"]); });
|
|
6746
6817
|
i0.ɵɵelementEnd();
|
|
6747
6818
|
}
|
|
6748
6819
|
if (rf & 2) {
|
|
@@ -6750,35 +6821,35 @@
|
|
|
6750
6821
|
i0.ɵɵpropertyInterpolate1("id", "ing-picture-", i_r19, "");
|
|
6751
6822
|
}
|
|
6752
6823
|
}
|
|
6753
|
-
function
|
|
6824
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_20_Template(rf, ctx) {
|
|
6754
6825
|
if (rf & 1) {
|
|
6755
6826
|
i0.ɵɵelement(0, "div", 23);
|
|
6756
6827
|
}
|
|
6757
6828
|
}
|
|
6758
|
-
function
|
|
6829
|
+
function ListInputComponent_ul_4_ng_template_2_li_0_div_21_Template(rf, ctx) {
|
|
6759
6830
|
if (rf & 1) {
|
|
6760
6831
|
i0.ɵɵelementStart(0, "div", 24);
|
|
6761
|
-
i0.ɵɵelement(1, "ng-miam-icon",
|
|
6762
|
-
i0.ɵɵelementStart(2, "span",
|
|
6832
|
+
i0.ɵɵelement(1, "ng-miam-icon", 49);
|
|
6833
|
+
i0.ɵɵelementStart(2, "span", 50);
|
|
6763
6834
|
i0.ɵɵtext(3);
|
|
6764
6835
|
i0.ɵɵpipe(4, "capitalizeFirstLetter");
|
|
6765
6836
|
i0.ɵɵelementEnd();
|
|
6766
|
-
i0.ɵɵelementStart(5, "span",
|
|
6837
|
+
i0.ɵɵelementStart(5, "span", 50);
|
|
6767
6838
|
i0.ɵɵtext(6);
|
|
6768
6839
|
i0.ɵɵelementEnd();
|
|
6769
|
-
i0.ɵɵelementStart(7, "span",
|
|
6840
|
+
i0.ɵɵelementStart(7, "span", 50);
|
|
6770
6841
|
i0.ɵɵtext(8);
|
|
6771
6842
|
i0.ɵɵelementEnd();
|
|
6772
6843
|
i0.ɵɵelementEnd();
|
|
6773
6844
|
}
|
|
6774
6845
|
if (rf & 2) {
|
|
6775
6846
|
var row_r18 = i0.ɵɵnextContext().$implicit;
|
|
6776
|
-
var
|
|
6847
|
+
var ctx_r26 = i0.ɵɵnextContext(3);
|
|
6777
6848
|
var tmp_1_0 = null;
|
|
6778
6849
|
var tmp_2_0 = null;
|
|
6779
6850
|
var tmp_3_0 = null;
|
|
6780
6851
|
i0.ɵɵadvance(1);
|
|
6781
|
-
i0.ɵɵproperty("iconName",
|
|
6852
|
+
i0.ɵɵproperty("iconName", ctx_r26.icon.Grip);
|
|
6782
6853
|
i0.ɵɵadvance(2);
|
|
6783
6854
|
i0.ɵɵtextInterpolate(i0.ɵɵpipeBind1(4, 4, row_r18 == null ? null : (tmp_1_0 = row_r18.get("attributes")) == null ? null : tmp_1_0.get("name").value));
|
|
6784
6855
|
i0.ɵɵadvance(3);
|
|
@@ -6789,7 +6860,7 @@
|
|
|
6789
6860
|
}
|
|
6790
6861
|
function ListInputComponent_ul_4_ng_template_2_li_0_Template(rf, ctx) {
|
|
6791
6862
|
if (rf & 1) {
|
|
6792
|
-
var
|
|
6863
|
+
var _r51_1 = i0.ɵɵgetCurrentView();
|
|
6793
6864
|
i0.ɵɵelementStart(0, "li", 14);
|
|
6794
6865
|
i0.ɵɵelementStart(1, "div", 27);
|
|
6795
6866
|
i0.ɵɵelementStart(2, "div", 28);
|
|
@@ -6803,23 +6874,24 @@
|
|
|
6803
6874
|
i0.ɵɵtemplate(9, ListInputComponent_ul_4_ng_template_2_li_0_option_9_Template, 2, 3, "option", 31);
|
|
6804
6875
|
i0.ɵɵelementEnd();
|
|
6805
6876
|
i0.ɵɵelementStart(10, "input", 32);
|
|
6806
|
-
i0.ɵɵlistener("ngModelChange", function ListInputComponent_ul_4_ng_template_2_li_0_Template_input_ngModelChange_10_listener($event) { i0.ɵɵrestoreView(
|
|
6877
|
+
i0.ɵɵlistener("ngModelChange", function ListInputComponent_ul_4_ng_template_2_li_0_Template_input_ngModelChange_10_listener($event) { i0.ɵɵrestoreView(_r51_1); var i_r19 = ctx.index; var ctx_r50 = i0.ɵɵnextContext(3); return ctx_r50.updateQuantityValue($event, i_r19); });
|
|
6807
6878
|
i0.ɵɵelementEnd();
|
|
6808
6879
|
i0.ɵɵelement(11, "input", 33);
|
|
6809
6880
|
i0.ɵɵpipe(12, "async");
|
|
6810
6881
|
i0.ɵɵelementStart(13, "datalist");
|
|
6811
6882
|
i0.ɵɵtemplate(14, ListInputComponent_ul_4_ng_template_2_li_0_option_14_Template, 1, 1, "option", 31);
|
|
6812
6883
|
i0.ɵɵelementEnd();
|
|
6884
|
+
i0.ɵɵtemplate(15, ListInputComponent_ul_4_ng_template_2_li_0_div_15_Template, 2, 1, "div", 34);
|
|
6813
6885
|
i0.ɵɵelementEnd();
|
|
6814
6886
|
i0.ɵɵelementEnd();
|
|
6815
|
-
i0.ɵɵelementStart(
|
|
6816
|
-
i0.ɵɵtemplate(
|
|
6817
|
-
i0.ɵɵtemplate(
|
|
6818
|
-
i0.ɵɵelementStart(
|
|
6819
|
-
i0.ɵɵlistener("click", function
|
|
6887
|
+
i0.ɵɵelementStart(16, "div", 35);
|
|
6888
|
+
i0.ɵɵtemplate(17, ListInputComponent_ul_4_ng_template_2_li_0_label_17_Template, 3, 3, "label", 36);
|
|
6889
|
+
i0.ɵɵtemplate(18, ListInputComponent_ul_4_ng_template_2_li_0_input_18_Template, 1, 1, "input", 37);
|
|
6890
|
+
i0.ɵɵelementStart(19, "ng-miam-icon", 20);
|
|
6891
|
+
i0.ɵɵlistener("click", function ListInputComponent_ul_4_ng_template_2_li_0_Template_ng_miam_icon_click_19_listener() { i0.ɵɵrestoreView(_r51_1); var i_r19 = ctx.index; var ctx_r52 = i0.ɵɵnextContext(3); return ctx_r52.delete(i_r19); });
|
|
6820
6892
|
i0.ɵɵelementEnd();
|
|
6821
|
-
i0.ɵɵtemplate(
|
|
6822
|
-
i0.ɵɵtemplate(
|
|
6893
|
+
i0.ɵɵtemplate(20, ListInputComponent_ul_4_ng_template_2_li_0_div_20_Template, 1, 0, "div", 21);
|
|
6894
|
+
i0.ɵɵtemplate(21, ListInputComponent_ul_4_ng_template_2_li_0_div_21_Template, 9, 6, "div", 22);
|
|
6823
6895
|
i0.ɵɵelementEnd();
|
|
6824
6896
|
i0.ɵɵelementEnd();
|
|
6825
6897
|
}
|
|
@@ -6832,7 +6904,7 @@
|
|
|
6832
6904
|
i0.ɵɵadvance(2);
|
|
6833
6905
|
i0.ɵɵproperty("iconName", ctx_r17.icon.Grip);
|
|
6834
6906
|
i0.ɵɵadvance(2);
|
|
6835
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpipeBind1(6,
|
|
6907
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpipeBind1(6, 19, ctx_r17.isIngredientReviewed(row_r18["controls"]["attributes"]["controls"]["name"].value)) ? "alert-success" : "alert-danger")("ngModel", i0.ɵɵpipeBind1(7, 21, row_r18["controls"]["attributes"]["controls"]["name"].value))("formControl", row_r18["controls"]["attributes"]["controls"]["name"]);
|
|
6836
6908
|
i0.ɵɵattribute("list", "miam-list-input-dropdown-ingredients-id" + i_r19);
|
|
6837
6909
|
i0.ɵɵadvance(3);
|
|
6838
6910
|
i0.ɵɵattribute("id", "miam-list-input-dropdown-ingredients-id" + i_r19);
|
|
@@ -6841,12 +6913,14 @@
|
|
|
6841
6913
|
i0.ɵɵadvance(1);
|
|
6842
6914
|
i0.ɵɵproperty("ngModel", row_r18["controls"]["attributes"]["controls"]["quantity"].value)("formControl", row_r18["controls"]["attributes"]["controls"]["quantity"]);
|
|
6843
6915
|
i0.ɵɵadvance(1);
|
|
6844
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpipeBind1(12,
|
|
6916
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpipeBind1(12, 23, ctx_r17.isQuantityReviewed(row_r18["controls"]["attributes"]["controls"]["unit"].value)) ? "alert-success" : "alert-danger")("formControl", row_r18["controls"]["attributes"]["controls"]["unit"]);
|
|
6845
6917
|
i0.ɵɵattribute("list", "miam-list-input-dropdown-units-id" + i_r19);
|
|
6846
6918
|
i0.ɵɵadvance(2);
|
|
6847
6919
|
i0.ɵɵattribute("id", "miam-list-input-dropdown-units-id" + i_r19);
|
|
6848
6920
|
i0.ɵɵadvance(1);
|
|
6849
6921
|
i0.ɵɵproperty("ngForOf", ctx_r17.getFilteredUnitsFromIndex(i_r19));
|
|
6922
|
+
i0.ɵɵadvance(1);
|
|
6923
|
+
i0.ɵɵproperty("ngIf", ctx_r17.getImportances().length > 0);
|
|
6850
6924
|
i0.ɵɵadvance(2);
|
|
6851
6925
|
i0.ɵɵproperty("ngIf", ctx_r17.ingredientsPictures.visible);
|
|
6852
6926
|
i0.ɵɵadvance(1);
|
|
@@ -6857,7 +6931,7 @@
|
|
|
6857
6931
|
}
|
|
6858
6932
|
function ListInputComponent_ul_4_ng_template_2_Template(rf, ctx) {
|
|
6859
6933
|
if (rf & 1) {
|
|
6860
|
-
i0.ɵɵtemplate(0, ListInputComponent_ul_4_ng_template_2_li_0_Template,
|
|
6934
|
+
i0.ɵɵtemplate(0, ListInputComponent_ul_4_ng_template_2_li_0_Template, 22, 25, "li", 13);
|
|
6861
6935
|
}
|
|
6862
6936
|
if (rf & 2) {
|
|
6863
6937
|
var ctx_r6 = i0.ɵɵnextContext(2);
|
|
@@ -6866,9 +6940,9 @@
|
|
|
6866
6940
|
}
|
|
6867
6941
|
function ListInputComponent_ul_4_Template(rf, ctx) {
|
|
6868
6942
|
if (rf & 1) {
|
|
6869
|
-
var
|
|
6943
|
+
var _r54_1 = i0.ɵɵgetCurrentView();
|
|
6870
6944
|
i0.ɵɵelementStart(0, "ul", 10);
|
|
6871
|
-
i0.ɵɵlistener("cdkDropListDropped", function ListInputComponent_ul_4_Template_ul_cdkDropListDropped_0_listener($event) { i0.ɵɵrestoreView(
|
|
6945
|
+
i0.ɵɵlistener("cdkDropListDropped", function ListInputComponent_ul_4_Template_ul_cdkDropListDropped_0_listener($event) { i0.ɵɵrestoreView(_r54_1); var ctx_r53 = i0.ɵɵnextContext(); return ctx_r53.drop($event); });
|
|
6872
6946
|
i0.ɵɵtemplate(1, ListInputComponent_ul_4_ng_container_1_Template, 2, 2, "ng-container", 11);
|
|
6873
6947
|
i0.ɵɵtemplate(2, ListInputComponent_ul_4_ng_template_2_Template, 1, 2, "ng-template", null, 12, i0.ɵɵtemplateRefExtractor);
|
|
6874
6948
|
i0.ɵɵelementEnd();
|
|
@@ -6882,9 +6956,9 @@
|
|
|
6882
6956
|
}
|
|
6883
6957
|
function ListInputComponent_ng_template_5_Template(rf, ctx) {
|
|
6884
6958
|
if (rf & 1) {
|
|
6885
|
-
i0.ɵɵelementStart(0, "div",
|
|
6886
|
-
i0.ɵɵelement(1, "ng-miam-icon",
|
|
6887
|
-
i0.ɵɵelementStart(2, "span",
|
|
6959
|
+
i0.ɵɵelementStart(0, "div", 51);
|
|
6960
|
+
i0.ɵɵelement(1, "ng-miam-icon", 52);
|
|
6961
|
+
i0.ɵɵelementStart(2, "span", 53);
|
|
6888
6962
|
i0.ɵɵtext(3);
|
|
6889
6963
|
i0.ɵɵelementEnd();
|
|
6890
6964
|
i0.ɵɵelementEnd();
|
|
@@ -6899,7 +6973,7 @@
|
|
|
6899
6973
|
}
|
|
6900
6974
|
function ListInputComponent_div_13_Template(rf, ctx) {
|
|
6901
6975
|
if (rf & 1) {
|
|
6902
|
-
i0.ɵɵelementStart(0, "div",
|
|
6976
|
+
i0.ɵɵelementStart(0, "div", 54);
|
|
6903
6977
|
i0.ɵɵtext(1);
|
|
6904
6978
|
i0.ɵɵelementEnd();
|
|
6905
6979
|
}
|
|
@@ -6915,6 +6989,7 @@
|
|
|
6915
6989
|
this.fb = fb;
|
|
6916
6990
|
this.cdr = cdr;
|
|
6917
6991
|
this.placeholder = '';
|
|
6992
|
+
this.isPersonal = false;
|
|
6918
6993
|
this.list = new i15.FormArray([]);
|
|
6919
6994
|
this.ingredientsPictures = { visible: false, editable: false };
|
|
6920
6995
|
this.icon = exports.Icon;
|
|
@@ -6947,7 +7022,11 @@
|
|
|
6947
7022
|
attributes: _this.fb.group({
|
|
6948
7023
|
quantity: new i15.FormControl(ing.attributes.quantity, i15.Validators.required),
|
|
6949
7024
|
unit: new i15.FormControl(ing.attributes.unit, i15.Validators.required),
|
|
6950
|
-
name: new i15.FormControl(ing.attributes.name, i15.Validators.required)
|
|
7025
|
+
name: new i15.FormControl(ing.attributes.name, i15.Validators.required),
|
|
7026
|
+
// importance: new FormControl(ing.attributes.importance,
|
|
7027
|
+
// this.isPersonal ? Validators.nullValidator : Validators.required),
|
|
7028
|
+
// Not mandatory for the moment, decomment above if mandatory later
|
|
7029
|
+
importance: new i15.FormControl(ing.attributes.importance, i15.Validators.nullValidator),
|
|
6951
7030
|
})
|
|
6952
7031
|
}));
|
|
6953
7032
|
_this.previousQuantities.push(ing.attributes.quantity);
|
|
@@ -7076,10 +7155,26 @@
|
|
|
7076
7155
|
}
|
|
7077
7156
|
return filteredSelection;
|
|
7078
7157
|
};
|
|
7158
|
+
/**
|
|
7159
|
+
* function that returns an Array of importances
|
|
7160
|
+
*/
|
|
7161
|
+
ListInputComponent.prototype.getImportances = function () {
|
|
7162
|
+
return ['primary', 'secondary', 'tertiary'];
|
|
7163
|
+
};
|
|
7164
|
+
/**
|
|
7165
|
+
* updates the importance of a given ingredient
|
|
7166
|
+
* @param value new value
|
|
7167
|
+
* @param index of the ingredient
|
|
7168
|
+
*/
|
|
7169
|
+
ListInputComponent.prototype.updateImportance = function (value, index) {
|
|
7170
|
+
this.list.controls[index]['controls']['attributes']['controls']['importance'].value = value;
|
|
7171
|
+
this.cdr.detectChanges();
|
|
7172
|
+
this.list.markAsDirty();
|
|
7173
|
+
};
|
|
7079
7174
|
return ListInputComponent;
|
|
7080
7175
|
}());
|
|
7081
7176
|
ListInputComponent.ɵfac = function ListInputComponent_Factory(t) { return new (t || ListInputComponent)(i0.ɵɵdirectiveInject(IngredientsService), i0.ɵɵdirectiveInject(i15.FormBuilder), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
7082
|
-
ListInputComponent.ɵcmp = i0.ɵɵdefineComponent({ type: ListInputComponent, selectors: [["ng-miam-list-input"]], inputs: { hint: "hint", placeholder: "placeholder", label: "label", instructions: "instructions", ingredientMode: "ingredientMode", list: "list", ingredientsPictures: "ingredientsPictures" }, outputs: { deleteId: "deleteId", orderHasChanged: "orderHasChanged" }, decls: 14, vars: 7, consts: [[1, "miam-list-input"], [1, "miam-list-input__list", 3, "formGroup"], [1, "miam-list-input__list__label"], ["class", "miam-list-input__container m-default-card", "cdkDropList", "", 3, "cdkDropListDropped", 4, "ngIf", "ngIfElse"], ["hintPlaceholder", ""], [1, "miam-list-input__actions"], ["matInput", "", "cdkTextareaAutosize", "", "cdkAutosizeMinRows", "4", "cdkAutosizeMaxRows", "4", 1, "m-input", 3, "formControl", "keydown.enter"], [1, "m-button-primary", 3, "mousedown", "mouseup"], [1, "miam-list-input__instructions__direction"], ["class", "miam-list-input__actions__instructions", 4, "ngIf"], ["cdkDropList", "", 1, "miam-list-input__container", "m-default-card", 3, "cdkDropListDropped"], [4, "ngIf", "ngIfElse"], ["ingredientRow", ""], ["cdkDrag", "", 4, "ngFor", "ngForOf", "ngForTrackBy"], ["cdkDrag", ""], [3, "formGroup"], [1, "miam-list-input__container__row", "m-default-card"], ["primaryColor", "var(--m-color-grey05)", "cdkDragHandle", "", 1, "miam-list-input__row__grip", 3, "iconName"], ["cdkTextareaAutosize", "true", "cdkAutosizeMinRows", "1", "cdkAutosizeMaxRows", "50", "formControlName", "description", 1, "m-input", 3, "blur"], ["autosize", "cdkTextareaAutosize"], ["primaryColor", "var(--m-color-grey05)", 1, "miam-list-input__row__trash", 3, "iconName", "click"], ["class", "miam-list-input__row__placeholder", 4, "cdkDragPlaceholder"], ["class", "miam-list-input__row__preview m-default-card", 4, "cdkDragPreview"], [1, "miam-list-input__row__placeholder"], [1, "miam-list-input__row__preview", "m-default-card"], ["primaryColor", "var(--m-color-grey05)", "cdkDragHandle", "", 3, "iconName"], [1, "miam-list-input__preview__text", "m-body-typo"], [1, "miam-list-input__container__row", "m-default-card", 3, "formGroupName"], [1, "miam-list-input__row__left"], [1, "miam-list-input__row__right"], [1, "m-input", 3, "ngClass", "ngModel", "formControl"], [3, "value", 4, "ngFor", "ngForOf"], ["maxSize", "4", "autoWidthInput", "", 1, "m-input", 3, "ngModel", "formControl", "ngModelChange"], ["maxSize", "8", "autoWidthInput", "", 1, "m-input", 3, "ngClass", "formControl"], [1, "miam-list-input__row__controls"], [3, "for", 4, "ngIf"], ["type", "file", "accept", "image/jpeg, image/png, image/webp", 3, "id", "change", 4, "ngIf"], [3, "value"], [3, "for"], ["class", "miam-list-input__row__picture", 3, "ngClass", "src", 4, "ngIf"], ["class", "miam-list-input__row__trash", "primaryColor", "var(--m-color-grey05)", 3, "iconName", 4, "ngIf"], [1, "miam-list-input__row__picture", 3, "ngClass", "src"], ["primaryColor", "var(--m-color-grey05)", 1, "miam-list-input__row__trash", 3, "iconName"], ["type", "file", "accept", "image/jpeg, image/png, image/webp", 3, "id", "change"], ["primaryColor", "var(--m-color-grey-text-dark)", "cdkDragHandle", "", 3, "iconName"], [1, "m-body-typo"], [1, "miam-list-input__placeholder", "miam-list-input__container", "m-default-card"], ["primaryColor", "var(--m-color-grey-text-dark)", 3, "width", "height", "iconName"], [1, "miam-list-input__placeholder__hint", "m-body-typo"], [1, "miam-list-input__actions__instructions"]], template: function ListInputComponent_Template(rf, ctx) {
|
|
7177
|
+
ListInputComponent.ɵcmp = i0.ɵɵdefineComponent({ type: ListInputComponent, selectors: [["ng-miam-list-input"]], inputs: { hint: "hint", placeholder: "placeholder", label: "label", instructions: "instructions", ingredientMode: "ingredientMode", isPersonal: "isPersonal", list: "list", ingredientsPictures: "ingredientsPictures" }, outputs: { deleteId: "deleteId", orderHasChanged: "orderHasChanged" }, decls: 14, vars: 7, consts: [[1, "miam-list-input"], [1, "miam-list-input__list", 3, "formGroup"], [1, "miam-list-input__list__label"], ["class", "miam-list-input__container m-default-card", "cdkDropList", "", 3, "cdkDropListDropped", 4, "ngIf", "ngIfElse"], ["hintPlaceholder", ""], [1, "miam-list-input__actions"], ["matInput", "", "cdkTextareaAutosize", "", "cdkAutosizeMinRows", "4", "cdkAutosizeMaxRows", "4", 1, "m-input", 3, "formControl", "keydown.enter"], [1, "m-button-primary", 3, "mousedown", "mouseup"], [1, "miam-list-input__instructions__direction"], ["class", "miam-list-input__actions__instructions", 4, "ngIf"], ["cdkDropList", "", 1, "miam-list-input__container", "m-default-card", 3, "cdkDropListDropped"], [4, "ngIf", "ngIfElse"], ["ingredientRow", ""], ["cdkDrag", "", 4, "ngFor", "ngForOf", "ngForTrackBy"], ["cdkDrag", ""], [3, "formGroup"], [1, "miam-list-input__container__row", "m-default-card"], ["primaryColor", "var(--m-color-grey05)", "cdkDragHandle", "", 1, "miam-list-input__row__grip", 3, "iconName"], ["cdkTextareaAutosize", "true", "cdkAutosizeMinRows", "1", "cdkAutosizeMaxRows", "50", "formControlName", "description", 1, "m-input", 3, "blur"], ["autosize", "cdkTextareaAutosize"], ["primaryColor", "var(--m-color-grey05)", 1, "miam-list-input__row__trash", 3, "iconName", "click"], ["class", "miam-list-input__row__placeholder", 4, "cdkDragPlaceholder"], ["class", "miam-list-input__row__preview m-default-card", 4, "cdkDragPreview"], [1, "miam-list-input__row__placeholder"], [1, "miam-list-input__row__preview", "m-default-card"], ["primaryColor", "var(--m-color-grey05)", "cdkDragHandle", "", 3, "iconName"], [1, "miam-list-input__preview__text", "m-body-typo"], [1, "miam-list-input__container__row", "m-default-card", 3, "formGroupName"], [1, "miam-list-input__row__left"], [1, "miam-list-input__row__right"], [1, "m-input", 3, "ngClass", "ngModel", "formControl"], [3, "value", 4, "ngFor", "ngForOf"], ["maxSize", "4", "autoWidthInput", "", 1, "m-input", 3, "ngModel", "formControl", "ngModelChange"], ["maxSize", "8", "autoWidthInput", "", 1, "m-input", 3, "ngClass", "formControl"], ["class", "miam-list-input__importance", 4, "ngIf"], [1, "miam-list-input__row__controls"], [3, "for", 4, "ngIf"], ["type", "file", "accept", "image/jpeg, image/png, image/webp", 3, "id", "change", 4, "ngIf"], [3, "value"], [1, "miam-list-input__importance"], ["class", "miam-list-input__importance__radio", 4, "ngFor", "ngForOf"], [1, "miam-list-input__importance__radio"], ["type", "radio", 3, "name", "id", "value", "formControl", "click"], [3, "for"], ["class", "miam-list-input__row__picture", 3, "ngClass", "src", 4, "ngIf"], ["class", "miam-list-input__row__trash", "primaryColor", "var(--m-color-grey05)", 3, "iconName", 4, "ngIf"], [1, "miam-list-input__row__picture", 3, "ngClass", "src"], ["primaryColor", "var(--m-color-grey05)", 1, "miam-list-input__row__trash", 3, "iconName"], ["type", "file", "accept", "image/jpeg, image/png, image/webp", 3, "id", "change"], ["primaryColor", "var(--m-color-grey-text-dark)", "cdkDragHandle", "", 3, "iconName"], [1, "m-body-typo"], [1, "miam-list-input__placeholder", "miam-list-input__container", "m-default-card"], ["primaryColor", "var(--m-color-grey-text-dark)", 3, "width", "height", "iconName"], [1, "miam-list-input__placeholder__hint", "m-body-typo"], [1, "miam-list-input__actions__instructions"]], template: function ListInputComponent_Template(rf, ctx) {
|
|
7083
7178
|
if (rf & 1) {
|
|
7084
7179
|
i0.ɵɵelementStart(0, "div", 0);
|
|
7085
7180
|
i0.ɵɵelementStart(1, "div", 1);
|
|
@@ -7118,7 +7213,7 @@
|
|
|
7118
7213
|
i0.ɵɵadvance(5);
|
|
7119
7214
|
i0.ɵɵproperty("ngIf", ctx.instructions);
|
|
7120
7215
|
}
|
|
7121
|
-
}, directives: [i15.NgControlStatusGroup, i15.FormGroupDirective, i4.NgIf, i4$1.CdkTextareaAutosize, i15.DefaultValueAccessor, i15.NgControlStatus, i15.FormControlDirective, i5.CdkDropList, i4.NgForOf, i5.CdkDrag, IconComponent, i5.CdkDragHandle, i15.FormControlName, i5.CdkDragPlaceholder, i5.CdkDragPreview, i15.FormGroupName, i4.NgClass, AutowidthInputDirective, i15.NgSelectOption, i15.ɵangular_packages_forms_forms_x], pipes: [i4.AsyncPipe, CapitalizeFirstLetterPipe], styles: [".miam-list-input[_ngcontent-%COMP%]{padding:8px}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%]{width:calc(100% - 16px)}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%]{margin-top:50px;position:relative}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%]{width:55%}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__list__label[_ngcontent-%COMP%]{background-color:var(--m-color-secondary-light);border-radius:8px 8px 0 0;color:var(--m-color-secondary);font-weight:700;left:0;padding:8px 24px;position:absolute;top:-33px;width:200px;z-index:0}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:400px;margin-bottom:32px;overflow-x:hidden;overflow-y:auto;position:inherit;z-index:1}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]{height:55vh;margin-bottom:16px;width:unset}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-button{height:20px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-track{background:var(--m-color-grey)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar{cursor:-webkit-grab;height:7px;width:5px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:var(--m-color-primary);border-radius:5px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{display:flex;justify-content:flex-start;row-gap:8px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{-moz-column-gap:16px;align-items:center;column-gap:16px;display:flex;list-style:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{-moz-column-gap:0;column-gap:0}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%]{-moz-user-select:none;-webkit-touch-callout:none;-webkit-user-select:none;align-items:center;display:flex;flex:1;flex-direction:row;gap:16px;user-select:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%]{margin-right:4px}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{max-width:unset;padding:inherit}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin:unset;max-width:unset;min-width:unset}@media (max-width:359px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{max-width:60vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%]{align-items:center;display:flex;flex-direction:row}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .miam-list-input__row__grip[_ngcontent-%COMP%]{cursor:move}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .miam-list-input__row__grip[_ngcontent-%COMP%]{margin-left:4px}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin-left:8px;margin-right:8px;width:200px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{align-items:center;display:flex;flex:1;flex-direction:row}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin-right:8px;width:80px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]:first-child{flex:1}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]:last-child{margin-right:0;text-align:right}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{flex-wrap:wrap}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{flex:1;margin-bottom:8px;margin-right:4px}}@media (max-width:359px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{max-width:60vw}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{max-width:58vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .alert-success[_ngcontent-%COMP%]{background:var(--m-color-white);border:1px solid var(--m-color-success);border-radius:8px;box-shadow:0 0 4px var(--m-color-success)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .alert-danger[_ngcontent-%COMP%]{background:var(--m-color-white);border:1px solid var(--m-color-danger);border-radius:8px;box-shadow:0 0 4px var(--m-color-danger)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%]{align-items:center;display:flex;gap:8px;justify-content:space-between}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;justify-content:center;width:50px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%] .miam-list-input__row__picture[_ngcontent-%COMP%]{-webkit-tap-highlight-color:transparent;width:50px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%] .miam-list-input__row__picture.clickable[_ngcontent-%COMP%]{cursor:pointer}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{display:none}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] .miam-list-input__row__trash[_ngcontent-%COMP%]{-webkit-tap-highlight-color:transparent;cursor:pointer}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{border-radius:var(--m-border-radius);flex:1;margin:0;max-width:none;outline:none;padding:5px;resize:none}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea.warnning[_ngcontent-%COMP%]{background-color:var(--m-color-secondary-light);color:var(--m-color-secondary)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea.error[_ngcontent-%COMP%]{background-color:var(--m-color-danger);color:var(--m-color-danger-text)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea[cdktextareaautosize][_ngcontent-%COMP%]{overflow:hidden}.miam-list-input[_ngcontent-%COMP%] .hint[_ngcontent-%COMP%]{border-radius:var(--m-border-radius);flex:1;font-size:12px;font-weight:600;padding-bottom:10px}.miam-list-input[_ngcontent-%COMP%] .hint.warnning[_ngcontent-%COMP%]{color:var(--m-color-secondary)}.miam-list-input[_ngcontent-%COMP%] .hint.error[_ngcontent-%COMP%]{color:var(--m-color-danger)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__placeholder[_ngcontent-%COMP%]{align-items:center;justify-content:center}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__placeholder[_ngcontent-%COMP%] .miam-list-input__placeholder__hint[_ngcontent-%COMP%]{color:var(--m-color-secondary);margin-top:40px;opacity:.5;text-align:center}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{-moz-column-gap:32px;column-gap:32px;display:flex;justify-content:space-between}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{width:calc(45% - 32px)}}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{flex-direction:column}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{flex:1;margin-top:0;outline:none;resize:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{width:90vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__actions__instructions[_ngcontent-%COMP%]{background-color:var(--m-color-info);border-radius:8px;color:var(--m-color-info-text);max-width:calc(98vw - 776px);padding:8px;position:absolute;top:315px;white-space:pre-line;width:400px}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__actions__instructions[_ngcontent-%COMP%]{margin-top:16px;max-width:unset;position:unset;width:unset}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__instructions__direction[_ngcontent-%COMP%]{margin-left:4px}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__instructions__direction[_ngcontent-%COMP%]{display:none}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.miam-list-input__row__preview[_ngcontent-%COMP%]{align-items:center;display:flex;width:530px}@media (max-width:1023px){.miam-list-input__row__preview[_ngcontent-%COMP%]{flex-wrap:wrap;width:80vw}}.miam-list-input__row__preview[_ngcontent-%COMP%] .miam-list-input__preview__text[_ngcontent-%COMP%]{padding:5px}.miam-list-input__row__preview[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:first-of-type{flex:1;flex-shrink:1;margin-left:8px}.miam-list-input__row__preview[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-of-type(2n){margin-right:8px}.miam-list-input__row__placeholder[_ngcontent-%COMP%]{-moz-user-select:none;-webkit-touch-callout:none;-webkit-user-select:none;background:var(--m-color-grey07);border-radius:8px;margin-right:24px;min-height:60px;user-select:none}.cdk-drag-animating[_ngcontent-%COMP%], .miam-list-input__row__placeholder[_ngcontent-%COMP%], ul.cdk-drop-list-dragging[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}"] });
|
|
7216
|
+
}, directives: [i15.NgControlStatusGroup, i15.FormGroupDirective, i4.NgIf, i4$1.CdkTextareaAutosize, i15.DefaultValueAccessor, i15.NgControlStatus, i15.FormControlDirective, i5.CdkDropList, i4.NgForOf, i5.CdkDrag, IconComponent, i5.CdkDragHandle, i15.FormControlName, i5.CdkDragPlaceholder, i5.CdkDragPreview, i15.FormGroupName, i4.NgClass, AutowidthInputDirective, i15.NgSelectOption, i15.ɵangular_packages_forms_forms_x, i15.RadioControlValueAccessor], pipes: [i4.AsyncPipe, CapitalizeFirstLetterPipe], styles: [".miam-list-input[_ngcontent-%COMP%]{padding:8px}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%]{width:calc(100% - 16px)}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%]{margin-top:50px;position:relative}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%]{width:55%}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__list__label[_ngcontent-%COMP%]{background-color:var(--m-color-secondary-light);border-radius:8px 8px 0 0;color:var(--m-color-secondary);font-weight:700;left:0;padding:8px 24px;position:absolute;top:-33px;width:200px;z-index:0}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:400px;margin-bottom:32px;overflow-x:hidden;overflow-y:auto;position:inherit;z-index:1}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]{height:55vh;margin-bottom:16px;width:unset}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-button{height:20px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-track{background:var(--m-color-grey)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar{cursor:-webkit-grab;height:7px;width:5px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] .miam-list-input__container[_ngcontent-%COMP%]::-webkit-scrollbar-thumb{background:var(--m-color-primary);border-radius:5px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%]{display:flex;justify-content:flex-start;row-gap:8px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{-moz-column-gap:16px;align-items:center;column-gap:16px;display:flex;list-style:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{-moz-column-gap:0;column-gap:0}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%]{-moz-user-select:none;-webkit-touch-callout:none;-webkit-user-select:none;align-items:center;display:flex;flex:1;flex-direction:row;gap:16px;user-select:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%]{margin-right:4px}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{max-width:unset;padding:inherit}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin:unset;max-width:unset;min-width:unset}@media (max-width:359px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{max-width:60vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%]{align-items:center;display:flex;flex-direction:row}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .miam-list-input__row__grip[_ngcontent-%COMP%]{cursor:move}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .miam-list-input__row__grip[_ngcontent-%COMP%]{margin-left:4px}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__left[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin-left:8px;margin-right:8px;width:200px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{align-items:center;display:flex;flex:1;flex-direction:row}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{margin-right:8px;width:80px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]:first-child{flex:1}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]:last-child{margin-right:0;text-align:right}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .miam-list-input__importance[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:4px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .miam-list-input__importance[_ngcontent-%COMP%] .miam-list-input__importance__radio[_ngcontent-%COMP%]{display:flex;flex-direction:row;line-height:24px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .miam-list-input__importance[_ngcontent-%COMP%] .miam-list-input__importance__radio[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{color:var(--m-color-slate);font-size:var(--m-font-size-medium);font-style:normal;font-weight:500}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .miam-list-input__importance[_ngcontent-%COMP%] .miam-list-input__importance__radio[_ngcontent-%COMP%] .ng-invalid[_ngcontent-%COMP%] + label[_ngcontent-%COMP%]{color:var(--m-color-danger)}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{flex-wrap:wrap}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{flex:1;margin-bottom:8px;margin-right:4px}}@media (max-width:359px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%]{max-width:60vw}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .m-input[_ngcontent-%COMP%]{max-width:58vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .alert-success[_ngcontent-%COMP%]{background:var(--m-color-white);border:1px solid var(--m-color-success);border-radius:8px;box-shadow:0 0 4px var(--m-color-success)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__container__row[_ngcontent-%COMP%] .miam-list-input__row__right[_ngcontent-%COMP%] .alert-danger[_ngcontent-%COMP%]{background:var(--m-color-white);border:1px solid var(--m-color-danger);border-radius:8px;box-shadow:0 0 4px var(--m-color-danger)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%]{align-items:center;display:flex;gap:8px;justify-content:space-between}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%]{display:flex;justify-content:center;width:50px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%] .miam-list-input__row__picture[_ngcontent-%COMP%]{-webkit-tap-highlight-color:transparent;width:50px}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] label[_ngcontent-%COMP%] .miam-list-input__row__picture.clickable[_ngcontent-%COMP%]{cursor:pointer}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] input[_ngcontent-%COMP%]{display:none}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] .miam-list-input__row__controls[_ngcontent-%COMP%] .miam-list-input__row__trash[_ngcontent-%COMP%]{-webkit-tap-highlight-color:transparent;cursor:pointer}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{border-radius:var(--m-border-radius);flex:1;margin:0;max-width:none;outline:none;padding:5px;resize:none}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea.warnning[_ngcontent-%COMP%]{background-color:var(--m-color-secondary-light);color:var(--m-color-secondary)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea.error[_ngcontent-%COMP%]{background-color:var(--m-color-danger);color:var(--m-color-danger-text)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__list[_ngcontent-%COMP%] ul[_ngcontent-%COMP%] li[_ngcontent-%COMP%] textarea[cdktextareaautosize][_ngcontent-%COMP%]{overflow:hidden}.miam-list-input[_ngcontent-%COMP%] .hint[_ngcontent-%COMP%]{border-radius:var(--m-border-radius);flex:1;font-size:12px;font-weight:600;padding-bottom:10px}.miam-list-input[_ngcontent-%COMP%] .hint.warnning[_ngcontent-%COMP%]{color:var(--m-color-secondary)}.miam-list-input[_ngcontent-%COMP%] .hint.error[_ngcontent-%COMP%]{color:var(--m-color-danger)}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__placeholder[_ngcontent-%COMP%]{align-items:center;justify-content:center}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__placeholder[_ngcontent-%COMP%] .miam-list-input__placeholder__hint[_ngcontent-%COMP%]{color:var(--m-color-secondary);margin-top:40px;opacity:.5;text-align:center}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{-moz-column-gap:32px;column-gap:32px;display:flex;justify-content:space-between}@media (min-width:1024px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{width:calc(45% - 32px)}}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%]{flex-direction:column}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{flex:1;margin-top:0;outline:none;resize:none}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{width:90vw}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__actions__instructions[_ngcontent-%COMP%]{background-color:var(--m-color-info);border-radius:8px;color:var(--m-color-info-text);max-width:calc(98vw - 776px);padding:8px;position:absolute;top:315px;white-space:pre-line;width:400px}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__actions__instructions[_ngcontent-%COMP%]{margin-top:16px;max-width:unset;position:unset;width:unset}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__instructions__direction[_ngcontent-%COMP%]{margin-left:4px}@media (max-width:1023px){.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] .miam-list-input__instructions__direction[_ngcontent-%COMP%]{display:none}}.miam-list-input[_ngcontent-%COMP%] .miam-list-input__actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}.miam-list-input__row__preview[_ngcontent-%COMP%]{align-items:center;display:flex;width:530px}@media (max-width:1023px){.miam-list-input__row__preview[_ngcontent-%COMP%]{flex-wrap:wrap;width:80vw}}.miam-list-input__row__preview[_ngcontent-%COMP%] .miam-list-input__preview__text[_ngcontent-%COMP%]{padding:5px}.miam-list-input__row__preview[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:first-of-type{flex:1;flex-shrink:1;margin-left:8px}.miam-list-input__row__preview[_ngcontent-%COMP%] span[_ngcontent-%COMP%]:nth-of-type(2n){margin-right:8px}.miam-list-input__row__placeholder[_ngcontent-%COMP%]{-moz-user-select:none;-webkit-touch-callout:none;-webkit-user-select:none;background:var(--m-color-grey07);border-radius:8px;margin-right:24px;min-height:60px;user-select:none}.cdk-drag-animating[_ngcontent-%COMP%], .miam-list-input__row__placeholder[_ngcontent-%COMP%], ul.cdk-drop-list-dragging[_ngcontent-%COMP%] li[_ngcontent-%COMP%]:not(.cdk-drag-placeholder){transition:transform .25s cubic-bezier(0,0,.2,1)}"] });
|
|
7122
7217
|
/*@__PURE__*/ (function () {
|
|
7123
7218
|
i0.ɵsetClassMetadata(ListInputComponent, [{
|
|
7124
7219
|
type: i0.Component,
|
|
@@ -7137,6 +7232,8 @@
|
|
|
7137
7232
|
type: i0.Input
|
|
7138
7233
|
}], ingredientMode: [{
|
|
7139
7234
|
type: i0.Input
|
|
7235
|
+
}], isPersonal: [{
|
|
7236
|
+
type: i0.Input
|
|
7140
7237
|
}], list: [{
|
|
7141
7238
|
type: i0.Input
|
|
7142
7239
|
}], ingredientsPictures: [{
|
|
@@ -9452,11 +9549,11 @@
|
|
|
9452
9549
|
return LoaderComponent;
|
|
9453
9550
|
}());
|
|
9454
9551
|
LoaderComponent.ɵfac = function LoaderComponent_Factory(t) { return new (t || LoaderComponent)(); };
|
|
9455
|
-
LoaderComponent.ɵcmp = i0.ɵɵdefineComponent({ type: LoaderComponent, selectors: [["ng-miam-loader"]], decls: 1, vars: 0, consts: [[1, "loader"]], template: function LoaderComponent_Template(rf, ctx) {
|
|
9552
|
+
LoaderComponent.ɵcmp = i0.ɵɵdefineComponent({ type: LoaderComponent, selectors: [["ng-miam-loader"]], decls: 1, vars: 0, consts: [[1, "miam-loader"]], template: function LoaderComponent_Template(rf, ctx) {
|
|
9456
9553
|
if (rf & 1) {
|
|
9457
9554
|
i0.ɵɵelement(0, "div", 0);
|
|
9458
9555
|
}
|
|
9459
|
-
}, styles: [".loader{-webkit-animation:spin .5s linear infinite;animation:spin .5s linear infinite;border:var(--m-loader-thickness) solid var(--m-color-grey);border-radius:var(--m-border-radius-circle);border-top:var(--m-loader-thickness) solid var(--m-color-ternary);height:var(--m-loader-size);width:var(--m-loader-size)}@-webkit-keyframes spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}@keyframes spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}"], encapsulation: 2 });
|
|
9556
|
+
}, styles: [".miam-loader{-webkit-animation:miam-loader-spin .5s linear infinite;animation:miam-loader-spin .5s linear infinite;border:var(--m-loader-thickness) solid var(--m-color-grey);border-radius:var(--m-border-radius-circle);border-top:var(--m-loader-thickness) solid var(--m-color-ternary);height:var(--m-loader-size);width:var(--m-loader-size)}@-webkit-keyframes miam-loader-spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}@keyframes miam-loader-spin{0%{transform:rotate(0deg)}to{transform:rotate(1turn)}}"], encapsulation: 2 });
|
|
9460
9557
|
/*@__PURE__*/ (function () {
|
|
9461
9558
|
i0.ɵsetClassMetadata(LoaderComponent, [{
|
|
9462
9559
|
type: i0.Component,
|
|
@@ -10956,8 +11053,10 @@
|
|
|
10956
11053
|
return { recipe_id: (_a = this.recipe) === null || _a === void 0 ? void 0 : _a.id };
|
|
10957
11054
|
};
|
|
10958
11055
|
AbstractRecipeCardComponent.prototype.ngAfterViewInit = function () {
|
|
11056
|
+
var _this = this;
|
|
10959
11057
|
this.sendShowEvent();
|
|
10960
11058
|
this.displayPrice();
|
|
11059
|
+
this.subscriptions.push(this.groceriesListsService.list$.subscribe(function () { return _this.cdr.detectChanges(); }));
|
|
10961
11060
|
};
|
|
10962
11061
|
AbstractRecipeCardComponent.prototype.ngOnDestroy = function () {
|
|
10963
11062
|
this.subscriptions.forEach(function (sub) { return sub.unsubscribe(); });
|
|
@@ -16137,7 +16236,7 @@
|
|
|
16137
16236
|
}
|
|
16138
16237
|
var selectedCategory = this.categories.find(function (cat) { return cat.key === paramsArray.get('catalogCategory'); });
|
|
16139
16238
|
if (selectedCategory) {
|
|
16140
|
-
return this.categoryTitleClicked(selectedCategory);
|
|
16239
|
+
return this.categoryTitleClicked({ title: selectedCategory.title, filters: selectedCategory.filters.additionalFilters.filters });
|
|
16141
16240
|
}
|
|
16142
16241
|
};
|
|
16143
16242
|
// Show feedback block only if user is logged and the children preference is unknown
|
|
@@ -17755,6 +17854,12 @@
|
|
|
17755
17854
|
quantity: new i15.FormControl(ingredient.attributes.quantity, i15.Validators.required),
|
|
17756
17855
|
unit: new i15.FormControl(ingredient.attributes.unit, i15.Validators.required),
|
|
17757
17856
|
name: new i15.FormControl(ingredient.attributes.name, i15.Validators.required),
|
|
17857
|
+
// importance: new FormControl(
|
|
17858
|
+
// ingredient.attributes.importance,
|
|
17859
|
+
// recipe.relationships?.[`recipe-provider`]?.data?.id === 'personal' ? Validators.nullValidator : Validators.required
|
|
17860
|
+
// ),
|
|
17861
|
+
// Not mandatory for the moment, decomment above if mandatory later
|
|
17862
|
+
importance: new i15.FormControl(ingredient.attributes.importance, i15.Validators.nullValidator),
|
|
17758
17863
|
'picture-url': new i15.FormControl(ingredient.attributes['picture-url'])
|
|
17759
17864
|
})
|
|
17760
17865
|
}));
|
|
@@ -18110,49 +18215,147 @@
|
|
|
18110
18215
|
}] });
|
|
18111
18216
|
})();
|
|
18112
18217
|
|
|
18218
|
+
function TagsCreatorComponent_ng_miam_modal_0_Template(rf, ctx) {
|
|
18219
|
+
if (rf & 1) {
|
|
18220
|
+
var _r2_1 = i0.ɵɵgetCurrentView();
|
|
18221
|
+
i0.ɵɵelementStart(0, "ng-miam-modal", 1);
|
|
18222
|
+
i0.ɵɵlistener("close", function TagsCreatorComponent_ng_miam_modal_0_Template_ng_miam_modal_close_0_listener() { i0.ɵɵrestoreView(_r2_1); var ctx_r1 = i0.ɵɵnextContext(); return ctx_r1.closeTagsCreator(); })("cancel", function TagsCreatorComponent_ng_miam_modal_0_Template_ng_miam_modal_cancel_0_listener() { i0.ɵɵrestoreView(_r2_1); var ctx_r3 = i0.ɵɵnextContext(); return ctx_r3.closeTagsCreator(); })("confirm", function TagsCreatorComponent_ng_miam_modal_0_Template_ng_miam_modal_confirm_0_listener() { i0.ɵɵrestoreView(_r2_1); var ctx_r4 = i0.ɵɵnextContext(); return ctx_r4.createTag(); });
|
|
18223
|
+
i0.ɵɵelementStart(1, "div", 2);
|
|
18224
|
+
i0.ɵɵelementStart(2, "label", 3);
|
|
18225
|
+
i0.ɵɵtext(3, "Nom du tag");
|
|
18226
|
+
i0.ɵɵelementEnd();
|
|
18227
|
+
i0.ɵɵelementStart(4, "input", 4);
|
|
18228
|
+
i0.ɵɵlistener("ngModelChange", function TagsCreatorComponent_ng_miam_modal_0_Template_input_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r2_1); var ctx_r5 = i0.ɵɵnextContext(); return ctx_r5.tagName = $event; });
|
|
18229
|
+
i0.ɵɵelementEnd();
|
|
18230
|
+
i0.ɵɵelementEnd();
|
|
18231
|
+
i0.ɵɵelementEnd();
|
|
18232
|
+
}
|
|
18233
|
+
if (rf & 2) {
|
|
18234
|
+
var ctx_r0 = i0.ɵɵnextContext();
|
|
18235
|
+
i0.ɵɵproperty("isAngularComponent", true)("noHeaderMode", false)("expanded", true)("confirmButtonIsLoading", ctx_r0.loading);
|
|
18236
|
+
i0.ɵɵadvance(4);
|
|
18237
|
+
i0.ɵɵproperty("ngModel", ctx_r0.tagName);
|
|
18238
|
+
}
|
|
18239
|
+
}
|
|
18240
|
+
var TagsCreatorComponent = /** @class */ (function () {
|
|
18241
|
+
function TagsCreatorComponent(tagsService, cdr) {
|
|
18242
|
+
this.tagsService = tagsService;
|
|
18243
|
+
this.cdr = cdr;
|
|
18244
|
+
this.display = false;
|
|
18245
|
+
this.close = new i0.EventEmitter();
|
|
18246
|
+
this.submit = new i0.EventEmitter();
|
|
18247
|
+
this.tagName = '';
|
|
18248
|
+
this.loading = false;
|
|
18249
|
+
}
|
|
18250
|
+
TagsCreatorComponent.prototype.closeTagsCreator = function () {
|
|
18251
|
+
this.close.emit();
|
|
18252
|
+
this.cdr.detectChanges();
|
|
18253
|
+
};
|
|
18254
|
+
TagsCreatorComponent.prototype.createTag = function () {
|
|
18255
|
+
var _this = this;
|
|
18256
|
+
this.loading = true;
|
|
18257
|
+
this.cdr.detectChanges();
|
|
18258
|
+
this.tag = this.tagsService.new();
|
|
18259
|
+
this.tag.attributes = Object.assign(Object.assign({}, this.tag.attributes), { 'tag-type-id': this.currentTagType, name: this.tagName });
|
|
18260
|
+
this.tag.save().subscribe(function (tag) {
|
|
18261
|
+
_this.tag.id = tag.data.id;
|
|
18262
|
+
_this.submit.emit(_this.tag);
|
|
18263
|
+
_this.loading = false;
|
|
18264
|
+
_this.cdr.detectChanges();
|
|
18265
|
+
});
|
|
18266
|
+
};
|
|
18267
|
+
return TagsCreatorComponent;
|
|
18268
|
+
}());
|
|
18269
|
+
TagsCreatorComponent.ɵfac = function TagsCreatorComponent_Factory(t) { return new (t || TagsCreatorComponent)(i0.ɵɵdirectiveInject(TagsService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
18270
|
+
TagsCreatorComponent.ɵcmp = i0.ɵɵdefineComponent({ type: TagsCreatorComponent, selectors: [["ng-miam-tags-creator"]], inputs: { currentRecipe: "currentRecipe", currentTagType: "currentTagType", display: "display" }, outputs: { close: "close", submit: "submit" }, decls: 1, vars: 1, consts: [["title", "Nouveau Tag", "cancelButtonText", "Annuler", "confirmButtonText", "Cr\u00E9er", 3, "isAngularComponent", "noHeaderMode", "expanded", "confirmButtonIsLoading", "close", "cancel", "confirm", 4, "ngIf"], ["title", "Nouveau Tag", "cancelButtonText", "Annuler", "confirmButtonText", "Cr\u00E9er", 3, "isAngularComponent", "noHeaderMode", "expanded", "confirmButtonIsLoading", "close", "cancel", "confirm"], [1, "tags-creator"], ["for", "tag-name"], ["type", "text", "id", "tag-name", "name", "tag-name", 3, "ngModel", "ngModelChange"]], template: function TagsCreatorComponent_Template(rf, ctx) {
|
|
18271
|
+
if (rf & 1) {
|
|
18272
|
+
i0.ɵɵtemplate(0, TagsCreatorComponent_ng_miam_modal_0_Template, 5, 5, "ng-miam-modal", 0);
|
|
18273
|
+
}
|
|
18274
|
+
if (rf & 2) {
|
|
18275
|
+
i0.ɵɵproperty("ngIf", ctx.display);
|
|
18276
|
+
}
|
|
18277
|
+
}, directives: [i4.NgIf, ModalComponent, i15.DefaultValueAccessor, i15.NgControlStatus, i15.NgModel], styles: [".tags-creator{display:flex;flex-direction:column;font-size:16px;margin:24px;padding:4px 12px}.tags-creator label{margin:0 0 8px 8px}.tags-creator input{border:1px solid var(--m-color-grey07);border-radius:var(--m-border-radius);height:32px;padding:5px;width:100%}.tags-creator input:focus{border:1px solid var(--miam-color-primary);outline:none}"], encapsulation: 2, changeDetection: 0 });
|
|
18278
|
+
/*@__PURE__*/ (function () {
|
|
18279
|
+
i0.ɵsetClassMetadata(TagsCreatorComponent, [{
|
|
18280
|
+
type: i0.Component,
|
|
18281
|
+
args: [{
|
|
18282
|
+
selector: 'ng-miam-tags-creator',
|
|
18283
|
+
templateUrl: './tags-creator.component.html',
|
|
18284
|
+
styleUrls: ['./tags-creator.component.scss'],
|
|
18285
|
+
encapsulation: i0.ViewEncapsulation.None,
|
|
18286
|
+
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
18287
|
+
}]
|
|
18288
|
+
}], function () { return [{ type: TagsService }, { type: i0.ChangeDetectorRef }]; }, { currentRecipe: [{
|
|
18289
|
+
type: i0.Input
|
|
18290
|
+
}], currentTagType: [{
|
|
18291
|
+
type: i0.Input
|
|
18292
|
+
}], display: [{
|
|
18293
|
+
type: i0.Input
|
|
18294
|
+
}], close: [{
|
|
18295
|
+
type: i0.Output
|
|
18296
|
+
}], submit: [{
|
|
18297
|
+
type: i0.Output
|
|
18298
|
+
}] });
|
|
18299
|
+
})();
|
|
18300
|
+
|
|
18113
18301
|
function TagsSelectorComponent_ng_miam_modal_0_div_12_Template(rf, ctx) {
|
|
18114
18302
|
if (rf & 1) {
|
|
18115
|
-
var
|
|
18116
|
-
i0.ɵɵelementStart(0, "div",
|
|
18117
|
-
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_div_12_Template_div_click_0_listener() { i0.ɵɵrestoreView(
|
|
18303
|
+
var _r7_1 = i0.ɵɵgetCurrentView();
|
|
18304
|
+
i0.ɵɵelementStart(0, "div", 9);
|
|
18305
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_div_12_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r7_1); var tag_r5 = ctx.$implicit; var ctx_r6 = i0.ɵɵnextContext(2); return ctx_r6.toggleTag(tag_r5); });
|
|
18118
18306
|
i0.ɵɵtext(1);
|
|
18119
18307
|
i0.ɵɵelementEnd();
|
|
18120
18308
|
}
|
|
18121
18309
|
if (rf & 2) {
|
|
18122
|
-
var
|
|
18123
|
-
var
|
|
18124
|
-
i0.ɵɵproperty("ngClass",
|
|
18310
|
+
var tag_r5 = ctx.$implicit;
|
|
18311
|
+
var ctx_r3 = i0.ɵɵnextContext(2);
|
|
18312
|
+
i0.ɵɵproperty("ngClass", ctx_r3.tagClass(tag_r5));
|
|
18313
|
+
i0.ɵɵadvance(1);
|
|
18314
|
+
i0.ɵɵtextInterpolate1(" ", tag_r5.attributes.name, " ");
|
|
18315
|
+
}
|
|
18316
|
+
}
|
|
18317
|
+
function TagsSelectorComponent_ng_miam_modal_0_div_13_Template(rf, ctx) {
|
|
18318
|
+
if (rf & 1) {
|
|
18319
|
+
var _r9_1 = i0.ɵɵgetCurrentView();
|
|
18320
|
+
i0.ɵɵelementStart(0, "div", 10);
|
|
18321
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_div_13_Template_div_click_0_listener() { i0.ɵɵrestoreView(_r9_1); var ctx_r8 = i0.ɵɵnextContext(2); return ctx_r8.displayTagsCreator(true); });
|
|
18322
|
+
i0.ɵɵelement(1, "ng-miam-icon", 11);
|
|
18323
|
+
i0.ɵɵelementEnd();
|
|
18324
|
+
}
|
|
18325
|
+
if (rf & 2) {
|
|
18326
|
+
var ctx_r4 = i0.ɵɵnextContext(2);
|
|
18125
18327
|
i0.ɵɵadvance(1);
|
|
18126
|
-
i0.ɵɵ
|
|
18328
|
+
i0.ɵɵproperty("iconName", ctx_r4.icon.Plus);
|
|
18127
18329
|
}
|
|
18128
18330
|
}
|
|
18129
18331
|
var _c0$v = function (a0) { return { "active": a0 }; };
|
|
18130
18332
|
function TagsSelectorComponent_ng_miam_modal_0_Template(rf, ctx) {
|
|
18131
18333
|
if (rf & 1) {
|
|
18132
|
-
var
|
|
18133
|
-
i0.ɵɵelementStart(0, "ng-miam-modal",
|
|
18134
|
-
i0.ɵɵlistener("close", function TagsSelectorComponent_ng_miam_modal_0_Template_ng_miam_modal_close_0_listener() { i0.ɵɵrestoreView(
|
|
18135
|
-
i0.ɵɵelementStart(1, "div",
|
|
18136
|
-
i0.ɵɵelementStart(2, "div",
|
|
18137
|
-
i0.ɵɵelementStart(3, "div",
|
|
18138
|
-
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_3_listener() { i0.ɵɵrestoreView(
|
|
18334
|
+
var _r11_1 = i0.ɵɵgetCurrentView();
|
|
18335
|
+
i0.ɵɵelementStart(0, "ng-miam-modal", 2);
|
|
18336
|
+
i0.ɵɵlistener("close", function TagsSelectorComponent_ng_miam_modal_0_Template_ng_miam_modal_close_0_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r10 = i0.ɵɵnextContext(); return ctx_r10.closeTagsSelector(); })("cancel", function TagsSelectorComponent_ng_miam_modal_0_Template_ng_miam_modal_cancel_0_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r12 = i0.ɵɵnextContext(); return ctx_r12.closeTagsSelector(); })("confirm", function TagsSelectorComponent_ng_miam_modal_0_Template_ng_miam_modal_confirm_0_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r13 = i0.ɵɵnextContext(); return ctx_r13.confirm(); });
|
|
18337
|
+
i0.ɵɵelementStart(1, "div", 3);
|
|
18338
|
+
i0.ɵɵelementStart(2, "div", 4);
|
|
18339
|
+
i0.ɵɵelementStart(3, "div", 5);
|
|
18340
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_3_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r14 = i0.ɵɵnextContext(); return ctx_r14.switchTab(ctx_r14.mealTypeTags); });
|
|
18139
18341
|
i0.ɵɵtext(4, " Type de plat ");
|
|
18140
18342
|
i0.ɵɵelementEnd();
|
|
18141
|
-
i0.ɵɵelementStart(5, "div",
|
|
18142
|
-
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_5_listener() { i0.ɵɵrestoreView(
|
|
18343
|
+
i0.ɵɵelementStart(5, "div", 5);
|
|
18344
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_5_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r15 = i0.ɵɵnextContext(); return ctx_r15.switchTab(ctx_r15.ingredientCategoryTags); });
|
|
18143
18345
|
i0.ɵɵtext(6, " Famille d'ingr\u00E9dients ");
|
|
18144
18346
|
i0.ɵɵelementEnd();
|
|
18145
|
-
i0.ɵɵelementStart(7, "div",
|
|
18146
|
-
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_7_listener() { i0.ɵɵrestoreView(
|
|
18347
|
+
i0.ɵɵelementStart(7, "div", 5);
|
|
18348
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_7_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r16 = i0.ɵɵnextContext(); return ctx_r16.switchTab(ctx_r16.equipmentTags); });
|
|
18147
18349
|
i0.ɵɵtext(8, " \u00C9quipements ");
|
|
18148
18350
|
i0.ɵɵelementEnd();
|
|
18149
|
-
i0.ɵɵelementStart(9, "div",
|
|
18150
|
-
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_9_listener() { i0.ɵɵrestoreView(
|
|
18351
|
+
i0.ɵɵelementStart(9, "div", 5);
|
|
18352
|
+
i0.ɵɵlistener("click", function TagsSelectorComponent_ng_miam_modal_0_Template_div_click_9_listener() { i0.ɵɵrestoreView(_r11_1); var ctx_r17 = i0.ɵɵnextContext(); return ctx_r17.switchTab(ctx_r17.dietTags); });
|
|
18151
18353
|
i0.ɵɵtext(10, " R\u00E9gimes alimentaires ");
|
|
18152
18354
|
i0.ɵɵelementEnd();
|
|
18153
18355
|
i0.ɵɵelementEnd();
|
|
18154
|
-
i0.ɵɵelementStart(11, "div",
|
|
18155
|
-
i0.ɵɵtemplate(12, TagsSelectorComponent_ng_miam_modal_0_div_12_Template, 2, 2, "div",
|
|
18356
|
+
i0.ɵɵelementStart(11, "div", 6);
|
|
18357
|
+
i0.ɵɵtemplate(12, TagsSelectorComponent_ng_miam_modal_0_div_12_Template, 2, 2, "div", 7);
|
|
18358
|
+
i0.ɵɵtemplate(13, TagsSelectorComponent_ng_miam_modal_0_div_13_Template, 2, 1, "div", 8);
|
|
18156
18359
|
i0.ɵɵelementEnd();
|
|
18157
18360
|
i0.ɵɵelementEnd();
|
|
18158
18361
|
i0.ɵɵelementEnd();
|
|
@@ -18161,20 +18364,44 @@
|
|
|
18161
18364
|
var ctx_r0 = i0.ɵɵnextContext();
|
|
18162
18365
|
i0.ɵɵproperty("isAngularComponent", true)("noHeaderMode", false)("expanded", true);
|
|
18163
18366
|
i0.ɵɵadvance(3);
|
|
18164
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
18367
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(9, _c0$v, (ctx_r0.selectedTabTags[0] == null ? null : ctx_r0.selectedTabTags[0].tagType) === "meal_type"));
|
|
18165
18368
|
i0.ɵɵadvance(2);
|
|
18166
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
18369
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(11, _c0$v, (ctx_r0.selectedTabTags[0] == null ? null : ctx_r0.selectedTabTags[0].tagType) === "ingredient_category"));
|
|
18167
18370
|
i0.ɵɵadvance(2);
|
|
18168
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
18371
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(13, _c0$v, (ctx_r0.selectedTabTags[0] == null ? null : ctx_r0.selectedTabTags[0].tagType) === "equipment"));
|
|
18169
18372
|
i0.ɵɵadvance(2);
|
|
18170
|
-
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(
|
|
18373
|
+
i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(15, _c0$v, (ctx_r0.selectedTabTags[0] == null ? null : ctx_r0.selectedTabTags[0].tagType) === "diet"));
|
|
18171
18374
|
i0.ɵɵadvance(3);
|
|
18172
18375
|
i0.ɵɵproperty("ngForOf", ctx_r0.selectedTabTags);
|
|
18376
|
+
i0.ɵɵadvance(1);
|
|
18377
|
+
i0.ɵɵproperty("ngIf", ctx_r0.isAdmin);
|
|
18378
|
+
}
|
|
18379
|
+
}
|
|
18380
|
+
function TagsSelectorComponent_ng_template_1_ng_miam_tags_creator_0_Template(rf, ctx) {
|
|
18381
|
+
if (rf & 1) {
|
|
18382
|
+
var _r20_1 = i0.ɵɵgetCurrentView();
|
|
18383
|
+
i0.ɵɵelementStart(0, "ng-miam-tags-creator", 13);
|
|
18384
|
+
i0.ɵɵlistener("close", function TagsSelectorComponent_ng_template_1_ng_miam_tags_creator_0_Template_ng_miam_tags_creator_close_0_listener() { i0.ɵɵrestoreView(_r20_1); var ctx_r19 = i0.ɵɵnextContext(2); return ctx_r19.displayTagsCreator(false); })("submit", function TagsSelectorComponent_ng_template_1_ng_miam_tags_creator_0_Template_ng_miam_tags_creator_submit_0_listener($event) { i0.ɵɵrestoreView(_r20_1); var ctx_r21 = i0.ɵɵnextContext(2); return ctx_r21.addCreatedTag($event); });
|
|
18385
|
+
i0.ɵɵelementEnd();
|
|
18386
|
+
}
|
|
18387
|
+
if (rf & 2) {
|
|
18388
|
+
var ctx_r18 = i0.ɵɵnextContext(2);
|
|
18389
|
+
i0.ɵɵproperty("display", ctx_r18.tagsCreatorDisplayed)("currentRecipe", ctx_r18.currentRecipe)("currentTagType", ctx_r18.selectedTabTags[0] == null ? null : ctx_r18.selectedTabTags[0].tagType);
|
|
18390
|
+
}
|
|
18391
|
+
}
|
|
18392
|
+
function TagsSelectorComponent_ng_template_1_Template(rf, ctx) {
|
|
18393
|
+
if (rf & 1) {
|
|
18394
|
+
i0.ɵɵtemplate(0, TagsSelectorComponent_ng_template_1_ng_miam_tags_creator_0_Template, 1, 3, "ng-miam-tags-creator", 12);
|
|
18395
|
+
}
|
|
18396
|
+
if (rf & 2) {
|
|
18397
|
+
var ctx_r2 = i0.ɵɵnextContext();
|
|
18398
|
+
i0.ɵɵproperty("ngIf", ctx_r2.display);
|
|
18173
18399
|
}
|
|
18174
18400
|
}
|
|
18175
18401
|
var TagsSelectorComponent = /** @class */ (function () {
|
|
18176
|
-
function TagsSelectorComponent(tagsService, cdr) {
|
|
18402
|
+
function TagsSelectorComponent(tagsService, userService, cdr) {
|
|
18177
18403
|
this.tagsService = tagsService;
|
|
18404
|
+
this.userService = userService;
|
|
18178
18405
|
this.cdr = cdr;
|
|
18179
18406
|
this.currentTags = [];
|
|
18180
18407
|
this.display = false;
|
|
@@ -18187,6 +18414,8 @@
|
|
|
18187
18414
|
this.selectedTags = [];
|
|
18188
18415
|
this.selectedTabTags = [];
|
|
18189
18416
|
this.tagsArefetched = false;
|
|
18417
|
+
this.icon = exports.Icon;
|
|
18418
|
+
this.tagsCreatorDisplayed = false;
|
|
18190
18419
|
this.subscriptions = [];
|
|
18191
18420
|
}
|
|
18192
18421
|
TagsSelectorComponent.prototype.ngOnInit = function () {
|
|
@@ -18206,6 +18435,10 @@
|
|
|
18206
18435
|
.pipe(operators.skipWhile(function (res) { return res.is_loading; }), operators.tap(function (tags) { _this.ingredientCategoryTags = tags.data; })),
|
|
18207
18436
|
])
|
|
18208
18437
|
.subscribe(function () { _this.tagsArefetched = true; }));
|
|
18438
|
+
this.subscriptions.push(this.userService.isAdmin.subscribe(function (isAdmin) {
|
|
18439
|
+
_this.isAdmin = isAdmin;
|
|
18440
|
+
_this.cdr.detectChanges();
|
|
18441
|
+
}));
|
|
18209
18442
|
};
|
|
18210
18443
|
TagsSelectorComponent.prototype.ngOnChanges = function (changes) {
|
|
18211
18444
|
this.selectedTabTags = __spread(this.mealTypeTags);
|
|
@@ -18242,28 +18475,56 @@
|
|
|
18242
18475
|
this.savedTags.emit(this.selectedTags);
|
|
18243
18476
|
this.closeTagsSelector();
|
|
18244
18477
|
};
|
|
18478
|
+
TagsSelectorComponent.prototype.displayTagsCreator = function (display) {
|
|
18479
|
+
this.tagsCreatorDisplayed = display;
|
|
18480
|
+
this.cdr.detectChanges();
|
|
18481
|
+
};
|
|
18482
|
+
TagsSelectorComponent.prototype.addCreatedTag = function (tag) {
|
|
18483
|
+
if (tag.tagType === 'meal_type') {
|
|
18484
|
+
this.mealTypeTags.push(tag);
|
|
18485
|
+
this.switchTab(this.mealTypeTags);
|
|
18486
|
+
}
|
|
18487
|
+
else if (tag.tagType === 'ingredient_category') {
|
|
18488
|
+
this.ingredientCategoryTags.push(tag);
|
|
18489
|
+
this.switchTab(this.ingredientCategoryTags);
|
|
18490
|
+
}
|
|
18491
|
+
else if (tag.tagType === 'equipment') {
|
|
18492
|
+
this.equipmentTags.push(tag);
|
|
18493
|
+
this.switchTab(this.equipmentTags);
|
|
18494
|
+
}
|
|
18495
|
+
else if (tag.tagType === 'diet') {
|
|
18496
|
+
this.dietTags.push(tag);
|
|
18497
|
+
this.switchTab(this.dietTags);
|
|
18498
|
+
}
|
|
18499
|
+
this.toggleTag(tag);
|
|
18500
|
+
this.displayTagsCreator(false);
|
|
18501
|
+
};
|
|
18245
18502
|
return TagsSelectorComponent;
|
|
18246
18503
|
}());
|
|
18247
|
-
TagsSelectorComponent.ɵfac = function TagsSelectorComponent_Factory(t) { return new (t || TagsSelectorComponent)(i0.ɵɵdirectiveInject(TagsService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
18248
|
-
TagsSelectorComponent.ɵcmp = i0.ɵɵdefineComponent({ type: TagsSelectorComponent, selectors: [["ng-miam-tags-selector"]], inputs: { currentTags: "currentTags", display: "display" }, outputs: { savedTags: "savedTags", close: "close" }, features: [i0.ɵɵNgOnChangesFeature], decls:
|
|
18504
|
+
TagsSelectorComponent.ɵfac = function TagsSelectorComponent_Factory(t) { return new (t || TagsSelectorComponent)(i0.ɵɵdirectiveInject(TagsService), i0.ɵɵdirectiveInject(UserService), i0.ɵɵdirectiveInject(i0.ChangeDetectorRef)); };
|
|
18505
|
+
TagsSelectorComponent.ɵcmp = i0.ɵɵdefineComponent({ type: TagsSelectorComponent, selectors: [["ng-miam-tags-selector"]], inputs: { currentRecipe: "currentRecipe", currentTags: "currentTags", display: "display" }, outputs: { savedTags: "savedTags", close: "close" }, features: [i0.ɵɵNgOnChangesFeature], decls: 3, vars: 2, consts: [["title", "Ajoutez des tags \u00E0 la recette", "cancelButtonText", "Annuler", "confirmButtonText", "Ajouter", 3, "isAngularComponent", "noHeaderMode", "expanded", "close", "cancel", "confirm", 4, "ngIf", "ngIfElse"], ["tagsCreator", ""], ["title", "Ajoutez des tags \u00E0 la recette", "cancelButtonText", "Annuler", "confirmButtonText", "Ajouter", 3, "isAngularComponent", "noHeaderMode", "expanded", "close", "cancel", "confirm"], [1, "tags-selector"], [1, "tags-selector__selectors"], [1, "tags-selector__selector", 3, "ngClass", "click"], [1, "tags-selector__tags"], ["class", "tags-selector__tag", 3, "ngClass", "click", 4, "ngFor", "ngForOf"], ["class", "tags-selector__tag", 3, "click", 4, "ngIf"], [1, "tags-selector__tag", 3, "ngClass", "click"], [1, "tags-selector__tag", 3, "click"], [3, "iconName"], [3, "display", "currentRecipe", "currentTagType", "close", "submit", 4, "ngIf"], [3, "display", "currentRecipe", "currentTagType", "close", "submit"]], template: function TagsSelectorComponent_Template(rf, ctx) {
|
|
18249
18506
|
if (rf & 1) {
|
|
18250
|
-
i0.ɵɵtemplate(0, TagsSelectorComponent_ng_miam_modal_0_Template,
|
|
18507
|
+
i0.ɵɵtemplate(0, TagsSelectorComponent_ng_miam_modal_0_Template, 14, 17, "ng-miam-modal", 0);
|
|
18508
|
+
i0.ɵɵtemplate(1, TagsSelectorComponent_ng_template_1_Template, 1, 1, "ng-template", null, 1, i0.ɵɵtemplateRefExtractor);
|
|
18251
18509
|
}
|
|
18252
18510
|
if (rf & 2) {
|
|
18253
|
-
i0.ɵɵ
|
|
18511
|
+
var _r1 = i0.ɵɵreference(2);
|
|
18512
|
+
i0.ɵɵproperty("ngIf", ctx.display && !ctx.tagsCreatorDisplayed)("ngIfElse", _r1);
|
|
18254
18513
|
}
|
|
18255
|
-
}, directives: [i4.NgIf, ModalComponent, i4.NgClass, i4.NgForOf], styles: [".tags-selector{margin:0 24px}.tags-selector .tags-selector__selectors{display:flex;flex-direction:row}.tags-selector .tags-selector__selectors .tags-selector__selector{border-bottom:1px solid var(--m-color-grey07);color:var(--m-color-grey03);cursor:pointer;font-size:16px;min-width:200px;padding:8px;text-align:center}.tags-selector .tags-selector__selectors .tags-selector__selector.active{border-bottom:2px solid var(--m-color-primary);color:var(--m-color-primary);font-weight:700}.tags-selector .tags-selector__tags{display:flex;flex-flow:row wrap;min-height:200px}.tags-selector .tags-selector__tags .tags-selector__tag{align-items:center;background-color:var(--m-color-white);border:1px solid var(--m-color-grey07);border-radius:var(--m-border-radius-pill);cursor:pointer;display:flex;font-size:16px;height:32px;margin:8px;padding:4px 12px}.tags-selector .tags-selector__tags .tags-selector__tag.active{background-color:var(--m-color-primary-light);border:none}.tags-selector .tags-selector__tags .tags-selector__tag.active.meal_type{background-color:var(--m-color-tag-meal-type)}.tags-selector .tags-selector__tags .tags-selector__tag.active.ingredient_category{background-color:var(--m-color-tag-ingredient-category)}.tags-selector .tags-selector__tags .tags-selector__tag.active.equipment{background-color:var(--m-color-tag-equipment)}.tags-selector .tags-selector__tags .tags-selector__tag.active.diet{background-color:var(--m-color-tag-diet)}"], encapsulation: 2, changeDetection: 0 });
|
|
18514
|
+
}, directives: [i4.NgIf, ModalComponent, i4.NgClass, i4.NgForOf, IconComponent, TagsCreatorComponent], styles: [".tags-selector{margin:0 24px}.tags-selector .tags-selector__selectors{display:flex;flex-direction:row}.tags-selector .tags-selector__selectors .tags-selector__selector{border-bottom:1px solid var(--m-color-grey07);color:var(--m-color-grey03);cursor:pointer;font-size:16px;min-width:200px;padding:8px;text-align:center}.tags-selector .tags-selector__selectors .tags-selector__selector.active{border-bottom:2px solid var(--m-color-primary);color:var(--m-color-primary);font-weight:700}.tags-selector .tags-selector__tags{display:flex;flex-flow:row wrap;min-height:200px}.tags-selector .tags-selector__tags .tags-selector__tag{align-items:center;background-color:var(--m-color-white);border:1px solid var(--m-color-grey07);border-radius:var(--m-border-radius-pill);cursor:pointer;display:flex;font-size:16px;height:32px;margin:8px;padding:4px 12px}.tags-selector .tags-selector__tags .tags-selector__tag.active{background-color:var(--m-color-primary-light);border:none}.tags-selector .tags-selector__tags .tags-selector__tag.active.meal_type{background-color:var(--m-color-tag-meal-type)}.tags-selector .tags-selector__tags .tags-selector__tag.active.ingredient_category{background-color:var(--m-color-tag-ingredient-category)}.tags-selector .tags-selector__tags .tags-selector__tag.active.equipment{background-color:var(--m-color-tag-equipment)}.tags-selector .tags-selector__tags .tags-selector__tag.active.diet{background-color:var(--m-color-tag-diet)}"], encapsulation: 2, changeDetection: 0 });
|
|
18256
18515
|
/*@__PURE__*/ (function () {
|
|
18257
18516
|
i0.ɵsetClassMetadata(TagsSelectorComponent, [{
|
|
18258
18517
|
type: i0.Component,
|
|
18259
18518
|
args: [{
|
|
18260
|
-
selector:
|
|
18519
|
+
selector: 'ng-miam-tags-selector',
|
|
18261
18520
|
templateUrl: './tags-selector.component.html',
|
|
18262
18521
|
styleUrls: ['./tags-selector.component.scss'],
|
|
18263
18522
|
encapsulation: i0.ViewEncapsulation.None,
|
|
18264
18523
|
changeDetection: i0.ChangeDetectionStrategy.OnPush
|
|
18265
18524
|
}]
|
|
18266
|
-
}], function () { return [{ type: TagsService }, { type: i0.ChangeDetectorRef }]; }, {
|
|
18525
|
+
}], function () { return [{ type: TagsService }, { type: UserService }, { type: i0.ChangeDetectorRef }]; }, { currentRecipe: [{
|
|
18526
|
+
type: i0.Input
|
|
18527
|
+
}], currentTags: [{
|
|
18267
18528
|
type: i0.Input
|
|
18268
18529
|
}], display: [{
|
|
18269
18530
|
type: i0.Input
|
|
@@ -18395,7 +18656,7 @@
|
|
|
18395
18656
|
}
|
|
18396
18657
|
if (rf & 2) {
|
|
18397
18658
|
var ctx_r13 = i0.ɵɵnextContext(2);
|
|
18398
|
-
i0.ɵɵproperty("placeholder", ctx_r13.INGREDIENT_PLACEHOLDER)("instructions", ctx_r13.INGREDIENT_INSTRUCTIONS)("list", ctx_r13.recipeForm.get("ingredients"))("ingredientMode", true)("ingredientsPictures", ctx_r13.ingredientsPictures);
|
|
18659
|
+
i0.ɵɵproperty("isPersonal", (ctx_r13.recipe.relationships["recipe-provider"] == null ? null : ctx_r13.recipe.relationships["recipe-provider"].data == null ? null : ctx_r13.recipe.relationships["recipe-provider"].data.id) === "personal")("placeholder", ctx_r13.INGREDIENT_PLACEHOLDER)("instructions", ctx_r13.INGREDIENT_INSTRUCTIONS)("list", ctx_r13.recipeForm.get("ingredients"))("ingredientMode", true)("ingredientsPictures", ctx_r13.ingredientsPictures);
|
|
18399
18660
|
}
|
|
18400
18661
|
}
|
|
18401
18662
|
function RecipeStepperComponent_ng_container_28_ng_miam_list_input_42_Template(rf, ctx) {
|
|
@@ -18472,7 +18733,7 @@
|
|
|
18472
18733
|
i0.ɵɵelementContainerEnd();
|
|
18473
18734
|
i0.ɵɵelementStart(38, "div", 19, 20);
|
|
18474
18735
|
i0.ɵɵtemplate(40, RecipeStepperComponent_ng_container_28_div_40_Template, 5, 6, "div", 40);
|
|
18475
|
-
i0.ɵɵtemplate(41, RecipeStepperComponent_ng_container_28_ng_miam_list_input_41_Template, 1,
|
|
18736
|
+
i0.ɵɵtemplate(41, RecipeStepperComponent_ng_container_28_ng_miam_list_input_41_Template, 1, 6, "ng-miam-list-input", 41);
|
|
18476
18737
|
i0.ɵɵtemplate(42, RecipeStepperComponent_ng_container_28_ng_miam_list_input_42_Template, 1, 3, "ng-miam-list-input", 42);
|
|
18477
18738
|
i0.ɵɵelementEnd();
|
|
18478
18739
|
i0.ɵɵelementContainerEnd();
|
|
@@ -18539,7 +18800,7 @@
|
|
|
18539
18800
|
}
|
|
18540
18801
|
if (rf & 2) {
|
|
18541
18802
|
var ctx_r5 = i0.ɵɵnextContext();
|
|
18542
|
-
i0.ɵɵproperty("display", ctx_r5.tagsSelectorDisplayed)("currentTags", ctx_r5.recipe.relationships.tags == null ? null : ctx_r5.recipe.relationships.tags.data);
|
|
18803
|
+
i0.ɵɵproperty("display", ctx_r5.tagsSelectorDisplayed)("currentRecipe", ctx_r5.recipe)("currentTags", ctx_r5.recipe.relationships.tags == null ? null : ctx_r5.recipe.relationships.tags.data);
|
|
18543
18804
|
}
|
|
18544
18805
|
}
|
|
18545
18806
|
var RecipeStepperComponent = /** @class */ (function (_super) {
|
|
@@ -18666,7 +18927,7 @@
|
|
|
18666
18927
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.stepperLinks = _t.first);
|
|
18667
18928
|
i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.steps = _t);
|
|
18668
18929
|
}
|
|
18669
|
-
}, inputs: { displayTags: "displayTags", ingredientsPictures: "ingredientsPictures" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 37, vars: 17, consts: [[1, "miam-recipe-stepper__anchor"], ["topAnchor", ""], [1, "miam-recipe-stepper"], [1, "miam-recipe-stepper__padding"], [1, "m-button-secondary", 3, "click"], ["primaryColor", "var(--m-color-primary)", 3, "iconName"], [1, "miam-recipe-stepper__links"], ["stepperLinks", ""], [1, "miam-recipe-stepper__link", 3, "ngClass", "click"], [1, "miam-recipe-stepper__link__number"], [1, "m-body-typo", "miam-recipe-stepper__link__name"], [1, "miam-recipe-stepper__link__divider"], [3, "formGroup", 4, "ngIf", "ngIfElse"], ["loading", ""], [1, "miam-recipe-stepper__footer"], [1, "m-button-secondary", 3, "disabled", "click"], [1, "m-button-primary", 3, "disabled", "click"], [3, "display", "currentTags", "close", "savedTags", 4, "ngIf"], [3, "formGroup"], [1, "miam-recipe-stepper__section"], ["step", ""], [1, "miam-recipe-stepper__mandatory"], ["ngDefaultControl", "", "placeholder", "Titre de la recette", 1, "m-title-text-input", 3, "formControl"], [1, "miam-recipe-stepper__type__label"], ["ngDefaultControl", "", 3, "formControl"], [1, "miam-recipe-stepper__section__guests", "m-default-card"], [1, "miam-recipe-stepper__guests__label"], ["ngDefaultControl", "", "formControlName", "number-of-guests", "minRange", "1", "maxRange", "999", 3, "counter", "counterChange"], ["class", "miam-recipe-stepper__tags", 4, "ngIf"], [1, "miam-recipe-stepper__section__row"], [1, "miam-recipe-stepper__picture"], ["ngDefaultControl", "", 3, "buttonText", "formControl", "imageUrl", "photoMode", "bigFileDropped", "onFileDropped"], ["class", "miam-recipe-stepper__picture__warning", 4, "ngIf"], [1, "miam-recipe-stepper__row__description"], [1, "m-h1-typo"], ["cdkTextareaAutosize", "", "cdkAutosizeMinRows", "20", "cdkAutosizeMaxRows", "50", "maxlength", "250", 1, "m-input", 3, "formControl"], [1, "miam-recipe-stepper__description__counter"], ["class", "miam-recipe-stepper__section__times", 4, "ngIf"], [1, "miam-recipe-stepper__attibutes__slider"], ["ngDefaultControl", "", 3, "steps", "formControl", "icons"], ["class", "miam-recipe-stepper__mobile__buttons", 4, "ngIf"], ["ngDefaultControl", "", "label", "Ingr\u00E9dients", "hint", "ingr\u00E9dients", "formArrayName", "ingredients", 3, "placeholder", "instructions", "list", "ingredientMode", "ingredientsPictures", "deleteId", "orderHasChanged", 4, "ngIf"], ["ngDefaultControl", "", "label", "\u00C9tapes", "formArrayName", "steps", "hint", "\u00E9tapes", 3, "placeholder", "list", "instructions", "deleteId", "orderHasChanged", 4, "ngIf"], [1, "miam-recipe-stepper__tags"], [1, "miam-recipe-stepper__tags__title"], [1, "miam-recipe-stepper__tags__recap"], ["class", "miam-recipe-stepper__tag", 3, "ngClass", 4, "ngFor", "ngForOf"], ["primaryColor", "var(--m-color-onyx)", 3, "iconName"], [1, "miam-recipe-stepper__tag", 3, "ngClass"], [1, "miam-recipe-stepper__tag__name"], ["primaryColor", "var(--m-color-grey01)", 1, "miam-recipe-stepper__tag__icon", 3, "iconName", "click"], [1, "miam-recipe-stepper__picture__warning"], ["primaryColor", "var(--m-color-warning-text)", 3, "iconName"], [1, "miam-recipe-stepper__picture__warning__background"], [1, "miam-recipe-stepper__section__times"], ["ngDefaultControl", "", "title", "Temps de pr\u00E9paration", 3, "formControl", "icon"], ["ngDefaultControl", "", "title", "Temps de cuisson", 3, "formControl", "icon"], ["ngDefaultControl", "", "title", "Temps de repos", 3, "formControl", "icon"], [1, "miam-recipe-stepper__mobile__buttons"], [1, "m-button-secondary", 3, "ngClass", "click"], ["ngDefaultControl", "", "label", "Ingr\u00E9dients", "hint", "ingr\u00E9dients", "formArrayName", "ingredients", 3, "placeholder", "instructions", "list", "ingredientMode", "ingredientsPictures", "deleteId", "orderHasChanged"], ["ngDefaultControl", "", "label", "\u00C9tapes", "formArrayName", "steps", "hint", "\u00E9tapes", 3, "placeholder", "list", "instructions", "deleteId", "orderHasChanged"], [3, "display", "currentTags", "close", "savedTags"]], template: function RecipeStepperComponent_Template(rf, ctx) {
|
|
18930
|
+
}, inputs: { displayTags: "displayTags", ingredientsPictures: "ingredientsPictures" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 37, vars: 17, consts: [[1, "miam-recipe-stepper__anchor"], ["topAnchor", ""], [1, "miam-recipe-stepper"], [1, "miam-recipe-stepper__padding"], [1, "m-button-secondary", 3, "click"], ["primaryColor", "var(--m-color-primary)", 3, "iconName"], [1, "miam-recipe-stepper__links"], ["stepperLinks", ""], [1, "miam-recipe-stepper__link", 3, "ngClass", "click"], [1, "miam-recipe-stepper__link__number"], [1, "m-body-typo", "miam-recipe-stepper__link__name"], [1, "miam-recipe-stepper__link__divider"], [3, "formGroup", 4, "ngIf", "ngIfElse"], ["loading", ""], [1, "miam-recipe-stepper__footer"], [1, "m-button-secondary", 3, "disabled", "click"], [1, "m-button-primary", 3, "disabled", "click"], [3, "display", "currentRecipe", "currentTags", "close", "savedTags", 4, "ngIf"], [3, "formGroup"], [1, "miam-recipe-stepper__section"], ["step", ""], [1, "miam-recipe-stepper__mandatory"], ["ngDefaultControl", "", "placeholder", "Titre de la recette", 1, "m-title-text-input", 3, "formControl"], [1, "miam-recipe-stepper__type__label"], ["ngDefaultControl", "", 3, "formControl"], [1, "miam-recipe-stepper__section__guests", "m-default-card"], [1, "miam-recipe-stepper__guests__label"], ["ngDefaultControl", "", "formControlName", "number-of-guests", "minRange", "1", "maxRange", "999", 3, "counter", "counterChange"], ["class", "miam-recipe-stepper__tags", 4, "ngIf"], [1, "miam-recipe-stepper__section__row"], [1, "miam-recipe-stepper__picture"], ["ngDefaultControl", "", 3, "buttonText", "formControl", "imageUrl", "photoMode", "bigFileDropped", "onFileDropped"], ["class", "miam-recipe-stepper__picture__warning", 4, "ngIf"], [1, "miam-recipe-stepper__row__description"], [1, "m-h1-typo"], ["cdkTextareaAutosize", "", "cdkAutosizeMinRows", "20", "cdkAutosizeMaxRows", "50", "maxlength", "250", 1, "m-input", 3, "formControl"], [1, "miam-recipe-stepper__description__counter"], ["class", "miam-recipe-stepper__section__times", 4, "ngIf"], [1, "miam-recipe-stepper__attibutes__slider"], ["ngDefaultControl", "", 3, "steps", "formControl", "icons"], ["class", "miam-recipe-stepper__mobile__buttons", 4, "ngIf"], ["ngDefaultControl", "", "label", "Ingr\u00E9dients", "hint", "ingr\u00E9dients", "formArrayName", "ingredients", 3, "isPersonal", "placeholder", "instructions", "list", "ingredientMode", "ingredientsPictures", "deleteId", "orderHasChanged", 4, "ngIf"], ["ngDefaultControl", "", "label", "\u00C9tapes", "formArrayName", "steps", "hint", "\u00E9tapes", 3, "placeholder", "list", "instructions", "deleteId", "orderHasChanged", 4, "ngIf"], [1, "miam-recipe-stepper__tags"], [1, "miam-recipe-stepper__tags__title"], [1, "miam-recipe-stepper__tags__recap"], ["class", "miam-recipe-stepper__tag", 3, "ngClass", 4, "ngFor", "ngForOf"], ["primaryColor", "var(--m-color-onyx)", 3, "iconName"], [1, "miam-recipe-stepper__tag", 3, "ngClass"], [1, "miam-recipe-stepper__tag__name"], ["primaryColor", "var(--m-color-grey01)", 1, "miam-recipe-stepper__tag__icon", 3, "iconName", "click"], [1, "miam-recipe-stepper__picture__warning"], ["primaryColor", "var(--m-color-warning-text)", 3, "iconName"], [1, "miam-recipe-stepper__picture__warning__background"], [1, "miam-recipe-stepper__section__times"], ["ngDefaultControl", "", "title", "Temps de pr\u00E9paration", 3, "formControl", "icon"], ["ngDefaultControl", "", "title", "Temps de cuisson", 3, "formControl", "icon"], ["ngDefaultControl", "", "title", "Temps de repos", 3, "formControl", "icon"], [1, "miam-recipe-stepper__mobile__buttons"], [1, "m-button-secondary", 3, "ngClass", "click"], ["ngDefaultControl", "", "label", "Ingr\u00E9dients", "hint", "ingr\u00E9dients", "formArrayName", "ingredients", 3, "isPersonal", "placeholder", "instructions", "list", "ingredientMode", "ingredientsPictures", "deleteId", "orderHasChanged"], ["ngDefaultControl", "", "label", "\u00C9tapes", "formArrayName", "steps", "hint", "\u00E9tapes", 3, "placeholder", "list", "instructions", "deleteId", "orderHasChanged"], [3, "display", "currentRecipe", "currentTags", "close", "savedTags"]], template: function RecipeStepperComponent_Template(rf, ctx) {
|
|
18670
18931
|
if (rf & 1) {
|
|
18671
18932
|
i0.ɵɵelement(0, "div", 0, 1);
|
|
18672
18933
|
i0.ɵɵelementStart(2, "div", 2);
|
|
@@ -18724,7 +18985,7 @@
|
|
|
18724
18985
|
i0.ɵɵelementEnd();
|
|
18725
18986
|
i0.ɵɵelementEnd();
|
|
18726
18987
|
i0.ɵɵelementEnd();
|
|
18727
|
-
i0.ɵɵtemplate(36, RecipeStepperComponent_ng_miam_tags_selector_36_Template, 1,
|
|
18988
|
+
i0.ɵɵtemplate(36, RecipeStepperComponent_ng_miam_tags_selector_36_Template, 1, 3, "ng-miam-tags-selector", 17);
|
|
18728
18989
|
}
|
|
18729
18990
|
if (rf & 2) {
|
|
18730
18991
|
var _r3 = i0.ɵɵreference(30);
|
|
@@ -18937,16 +19198,12 @@
|
|
|
18937
19198
|
return bpl.entries.found.find(function (entry) { return entry.selectedItem.attributes['ext-id'] === _this.extId; });
|
|
18938
19199
|
});
|
|
18939
19200
|
_this.cdr.detectChanges();
|
|
19201
|
+
_this.detectWrappedTags(_this.tags);
|
|
18940
19202
|
}
|
|
18941
19203
|
}));
|
|
18942
19204
|
}
|
|
18943
19205
|
this.cdr.detectChanges();
|
|
18944
19206
|
};
|
|
18945
|
-
RecipeTagsComponent.prototype.ngAfterViewInit = function () {
|
|
18946
|
-
var _this = this;
|
|
18947
|
-
// Call each time list of recipe-tags change
|
|
18948
|
-
this.subscriptions.push(this.tags.changes.subscribe(function (queryList) { return _this.detectWrappedTags(queryList); }));
|
|
18949
|
-
};
|
|
18950
19207
|
RecipeTagsComponent.prototype.ngOnDestroy = function () {
|
|
18951
19208
|
this.subscriptions.forEach(function (sub) { return sub.unsubscribe(); });
|
|
18952
19209
|
};
|
|
@@ -19704,7 +19961,8 @@
|
|
|
19704
19961
|
CatalogHeaderComponent,
|
|
19705
19962
|
RecipeStepperComponent,
|
|
19706
19963
|
CatalogArticleCardComponent,
|
|
19707
|
-
TagsSelectorComponent
|
|
19964
|
+
TagsSelectorComponent,
|
|
19965
|
+
TagsCreatorComponent
|
|
19708
19966
|
];
|
|
19709
19967
|
// Tag names as imported in client application
|
|
19710
19968
|
// Warning : do not use caps, use dashed case only
|
|
@@ -19731,7 +19989,8 @@
|
|
|
19731
19989
|
'catalog-header',
|
|
19732
19990
|
'recipe-stepper',
|
|
19733
19991
|
'catalog-article-card',
|
|
19734
|
-
'tags-selector'
|
|
19992
|
+
'tags-selector',
|
|
19993
|
+
'tags-creator'
|
|
19735
19994
|
];
|
|
19736
19995
|
var WEBC_MODULES = [
|
|
19737
19996
|
LoaderModule,
|
|
@@ -19785,7 +20044,8 @@
|
|
|
19785
20044
|
CatalogHeaderComponent,
|
|
19786
20045
|
RecipeStepperComponent,
|
|
19787
20046
|
CatalogArticleCardComponent,
|
|
19788
|
-
TagsSelectorComponent
|
|
20047
|
+
TagsSelectorComponent,
|
|
20048
|
+
TagsCreatorComponent], imports: [LoaderModule,
|
|
19789
20049
|
BasketPreviewModule,
|
|
19790
20050
|
ListScanModule,
|
|
19791
20051
|
RecipeDetailsModule,
|
|
@@ -19819,7 +20079,8 @@
|
|
|
19819
20079
|
CatalogHeaderComponent,
|
|
19820
20080
|
RecipeStepperComponent,
|
|
19821
20081
|
CatalogArticleCardComponent,
|
|
19822
|
-
TagsSelectorComponent
|
|
20082
|
+
TagsSelectorComponent,
|
|
20083
|
+
TagsCreatorComponent] });
|
|
19823
20084
|
})();
|
|
19824
20085
|
/*@__PURE__*/ (function () {
|
|
19825
20086
|
i0.ɵsetClassMetadata(WebComponentsModule, [{
|
|
@@ -19864,7 +20125,8 @@
|
|
|
19864
20125
|
CatalogHeaderComponent,
|
|
19865
20126
|
RecipeStepperComponent,
|
|
19866
20127
|
CatalogArticleCardComponent,
|
|
19867
|
-
TagsSelectorComponent
|
|
20128
|
+
TagsSelectorComponent,
|
|
20129
|
+
TagsCreatorComponent], [i4.AsyncPipe, i4.UpperCasePipe, i4.LowerCasePipe, i4.JsonPipe, i4.SlicePipe, i4.DecimalPipe, i4.PercentPipe, i4.TitleCasePipe, i4.CurrencyPipe, i4.DatePipe, i4.I18nPluralPipe, i4.I18nSelectPipe, i4.KeyValuePipe, i1$4.ɵi, i1$4.ɵj, i1$4.ɵk, ReadableFloatNumberPipe, EllipsisPipe, SafePipe, CapitalizeFirstLetterPipe, ExtendedDatePipe]);
|
|
19868
20130
|
|
|
19869
20131
|
var MiamInterceptor = /** @class */ (function () {
|
|
19870
20132
|
function MiamInterceptor(injector) {
|
|
@@ -20139,6 +20401,7 @@
|
|
|
20139
20401
|
exports.TabLabelComponent = TabLabelComponent;
|
|
20140
20402
|
exports.TabsComponent = TabsComponent;
|
|
20141
20403
|
exports.Tag = Tag;
|
|
20404
|
+
exports.TagsCreatorComponent = TagsCreatorComponent;
|
|
20142
20405
|
exports.TagsSelectorComponent = TagsSelectorComponent;
|
|
20143
20406
|
exports.TagsService = TagsService;
|
|
20144
20407
|
exports.TextInputComponent = TextInputComponent;
|