@dsivd/prestations-ng 15.5.4 → 15.5.5-beta1
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/CHANGELOG.md +8 -0
- package/dsivd-prestations-ng-v15.5.5-beta1.tgz +0 -0
- package/esm2020/foehn-checkables/foehn-select.component.mjs +6 -3
- package/fesm2015/dsivd-prestations-ng.mjs +5 -2
- package/fesm2015/dsivd-prestations-ng.mjs.map +1 -1
- package/fesm2020/dsivd-prestations-ng.mjs +5 -2
- package/fesm2020/dsivd-prestations-ng.mjs.map +1 -1
- package/foehn-checkables/foehn-select.component.d.ts +1 -0
- package/package.json +1 -1
- package/dsivd-prestations-ng-v15.5.4.tgz +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -26,6 +26,14 @@ A change is considered **breaking** if you have to change your code or update yo
|
|
|
26
26
|
|
|
27
27
|
---
|
|
28
28
|
|
|
29
|
+
## [15.5.5]
|
|
30
|
+
|
|
31
|
+
### Updated
|
|
32
|
+
|
|
33
|
+
- [foehn-select.component.ts](projects/prestations-ng/src/foehn-checkables/foehn-select.component.ts)
|
|
34
|
+
- an empty option is displayed if `[required]="true"` as long as no choice has been made
|
|
35
|
+
- fixes bug https://github.com/angular/angular/issues/14505
|
|
36
|
+
|
|
29
37
|
## [15.5.4]
|
|
30
38
|
|
|
31
39
|
### Updated
|
|
Binary file
|
|
@@ -27,6 +27,9 @@ export class FoehnSelectComponent extends FoehnCheckableGroupComponent {
|
|
|
27
27
|
compareFn(value1, value2) {
|
|
28
28
|
return this.areValuesEquals(value1, value2);
|
|
29
29
|
}
|
|
30
|
+
showEmptyOption() {
|
|
31
|
+
return this.required && this.isEmpty(this.model);
|
|
32
|
+
}
|
|
30
33
|
}
|
|
31
34
|
FoehnSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FoehnSelectComponent, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
32
35
|
FoehnSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: FoehnSelectComponent, selector: "foehn-select", inputs: { multiple: "multiple", noSelectionLabel: "noSelectionLabel" }, providers: [
|
|
@@ -35,7 +38,7 @@ FoehnSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
35
38
|
useExisting: forwardRef(() => FoehnSelectComponent),
|
|
36
39
|
multi: true
|
|
37
40
|
}
|
|
38
|
-
], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option
|
|
41
|
+
], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option *ngIf=\"showEmptyOption()\" [ngValue]=\"null\">\n <!-- empty option displayed even if required=true as long as there's no model to fix https://github.com/angular/angular/issues/14505 -->\n </option>\n <option *ngIf=\"!required\" [ngValue]=\"null\">\n {{ noSelectionLabel | fromDictionary }}\n </option>\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.disabled]=\"getDisabled(element) ? 'disabled' : null\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n <select\n *ngIf=\"multiple\"\n multiple\n [attr.aria-multiselectable]=\"true\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.aria-selected]=\"isElementSelected(element)\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n</div>\n", components: [{ type: i1.FoehnHelpModalComponent, selector: "foehn-help-modal", inputs: ["modalContent"] }, { type: i2.FoehnValidationAlertsComponent, selector: "foehn-validation-alerts", inputs: ["component", "shouldErrorsBeLive"] }], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i4.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i4.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i4.SelectMultipleControlValueAccessor, selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]", inputs: ["compareWith"] }], pipes: { "fromDictionary": i5.SdkDictionaryPipe } });
|
|
39
42
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FoehnSelectComponent, decorators: [{
|
|
40
43
|
type: Component,
|
|
41
44
|
args: [{ selector: 'foehn-select', providers: [
|
|
@@ -44,10 +47,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
44
47
|
useExisting: forwardRef(() => FoehnSelectComponent),
|
|
45
48
|
multi: true
|
|
46
49
|
}
|
|
47
|
-
], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option
|
|
50
|
+
], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option *ngIf=\"showEmptyOption()\" [ngValue]=\"null\">\n <!-- empty option displayed even if required=true as long as there's no model to fix https://github.com/angular/angular/issues/14505 -->\n </option>\n <option *ngIf=\"!required\" [ngValue]=\"null\">\n {{ noSelectionLabel | fromDictionary }}\n </option>\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.disabled]=\"getDisabled(element) ? 'disabled' : null\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n <select\n *ngIf=\"multiple\"\n multiple\n [attr.aria-multiselectable]=\"true\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.aria-selected]=\"isElementSelected(element)\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n</div>\n" }]
|
|
48
51
|
}], ctorParameters: function () { return [{ type: i0.NgZone }]; }, propDecorators: { multiple: [{
|
|
49
52
|
type: Input
|
|
50
53
|
}], noSelectionLabel: [{
|
|
51
54
|
type: Input
|
|
52
55
|
}] } });
|
|
53
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
56
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZm9laG4tc2VsZWN0LmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL3ByZXN0YXRpb25zLW5nL3NyYy9mb2Vobi1jaGVja2FibGVzL2ZvZWhuLXNlbGVjdC5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi9wcm9qZWN0cy9wcmVzdGF0aW9ucy1uZy9zcmMvZm9laG4tY2hlY2thYmxlcy9mb2Vobi1zZWxlY3QuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFFLFNBQVMsRUFBRSxVQUFVLEVBQUUsS0FBSyxFQUFrQixNQUFNLGVBQWUsQ0FBQztBQUM3RSxPQUFPLEVBQUUsNEJBQTRCLEVBQUUsTUFBTSxtQ0FBbUMsQ0FBQztBQUNqRixPQUFPLEVBQUUsbUJBQW1CLEVBQUU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KT1cInVwZGF0ZU5nTW9kZWwoJGV2ZW50KVwiXG4gICAgICAgIFtjb21wYXJlV2l0aF09XCJjb21wYXJlRm4uYmluZCh0aGlzKVwiXG4gICAgICAgIChjaGFuZ2UpPVwiaGFuZGxlQ2hhbmdlKG1vZGVsKVwiXG4gICAgICAgICNlbnRyeUNvbXBvbmVudFxuICAgICAgICBuZ0RlZmF1bHRDb250cm9sXG4gICAgPlxuICAgICAgICA8b3B0aW9uXG4gICAgICAgICAgICAqbmdGb3I9XCJsZXQgZWxlbWVudCBvZiBlbGVtZW50c1wiXG4gICAgICAgICAgICBbbmdWYWx1ZV09XCJnZXRWYWx1ZShlbGVtZW50KVwiXG4gICAgICAgICAgICBbYXR0ci5zZWxlY3RlZF09XCJpc0VsZW1lbnRTZWxlY3RlZChlbGVtZW50KSA/ICdzZWxlY3RlZCcgOiBudWxsXCJcbiAgICAgICAgICAgIFthdHRyLmFyaWEtc2VsZWN0ZWRdPVwiaXNFbGVtZW50U2VsZWN0ZWQoZWxlbWVudClcIlxuICAgICAgICA+XG4gICAgICAgICAgICB7eyBnZXRMYWJlbChlbGVtZW50KSB9fVxuICAgICAgICA8L29wdGlvbj5cbiAgICA8L3NlbGVjdD5cbjwvZGl2PlxuIl19
|
|
@@ -4628,6 +4628,9 @@ class FoehnSelectComponent extends FoehnCheckableGroupComponent {
|
|
|
4628
4628
|
compareFn(value1, value2) {
|
|
4629
4629
|
return this.areValuesEquals(value1, value2);
|
|
4630
4630
|
}
|
|
4631
|
+
showEmptyOption() {
|
|
4632
|
+
return this.required && this.isEmpty(this.model);
|
|
4633
|
+
}
|
|
4631
4634
|
}
|
|
4632
4635
|
FoehnSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FoehnSelectComponent, deps: [{ token: i0.NgZone }], target: i0.ɵɵFactoryTarget.Component });
|
|
4633
4636
|
FoehnSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: FoehnSelectComponent, selector: "foehn-select", inputs: { multiple: "multiple", noSelectionLabel: "noSelectionLabel" }, providers: [
|
|
@@ -4636,7 +4639,7 @@ FoehnSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", v
|
|
|
4636
4639
|
useExisting: forwardRef(() => FoehnSelectComponent),
|
|
4637
4640
|
multi: true
|
|
4638
4641
|
}
|
|
4639
|
-
], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option
|
|
4642
|
+
], usesInheritance: true, ngImport: i0, template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option *ngIf=\"showEmptyOption()\" [ngValue]=\"null\">\n <!-- empty option displayed even if required=true as long as there's no model to fix https://github.com/angular/angular/issues/14505 -->\n </option>\n <option *ngIf=\"!required\" [ngValue]=\"null\">\n {{ noSelectionLabel | fromDictionary }}\n </option>\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.disabled]=\"getDisabled(element) ? 'disabled' : null\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n <select\n *ngIf=\"multiple\"\n multiple\n [attr.aria-multiselectable]=\"true\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.aria-selected]=\"isElementSelected(element)\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n</div>\n", components: [{ type: FoehnHelpModalComponent, selector: "foehn-help-modal", inputs: ["modalContent"] }, { type: FoehnValidationAlertsComponent, selector: "foehn-validation-alerts", inputs: ["component", "shouldErrorsBeLive"] }], directives: [{ type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { type: i5.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i5.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i5.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i5.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { type: i3.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i5.SelectMultipleControlValueAccessor, selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]", inputs: ["compareWith"] }], pipes: { "fromDictionary": SdkDictionaryPipe } });
|
|
4640
4643
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: FoehnSelectComponent, decorators: [{
|
|
4641
4644
|
type: Component,
|
|
4642
4645
|
args: [{ selector: 'foehn-select', providers: [
|
|
@@ -4645,7 +4648,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
|
|
|
4645
4648
|
useExisting: forwardRef(() => FoehnSelectComponent),
|
|
4646
4649
|
multi: true
|
|
4647
4650
|
}
|
|
4648
|
-
], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option
|
|
4651
|
+
], template: "<div\n class=\"form-group\"\n [class.has-danger]=\"hasErrorsToDisplay()\"\n [class.vd-form-group-danger]=\"hasErrorsToDisplay()\"\n [attr.id]=\"buildId('Container')\"\n tabindex=\"-1\"\n>\n <div class=\"d-flex justify-content-between\">\n <label\n [attr.for]=\"buildChildId()\"\n *ngIf=\"!!label\"\n [ngClass]=\"isLabelSrOnly ? 'sr-only' : labelStyleModifier\"\n >\n <span [innerHTML]=\"label\"></span>\n <span\n *ngIf=\"!required && !hideNotRequiredExtraLabel\"\n aria-hidden=\"true\"\n >\n {{ 'foehn-input.optional' | fromDictionary }}\n </span>\n </label>\n <foehn-help-modal\n class=\"removePaddingButton\"\n *ngIf=\"!!helpModal\"\n [modalContent]=\"helpModal\"\n ></foehn-help-modal>\n </div>\n\n <foehn-validation-alerts [component]=\"this\"></foehn-validation-alerts>\n\n <div *ngIf=\"!elements\">Chargement...</div>\n\n <small\n *ngIf=\"helpText\"\n [attr.id]=\"buildChildId() + 'Help'\"\n class=\"form-text text-secondary\"\n [innerHTML]=\"helpText\"\n ></small>\n\n <ng-content></ng-content>\n\n <select\n *ngIf=\"!multiple\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [attr.autocomplete]=\"getAutoComplete()\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option *ngIf=\"showEmptyOption()\" [ngValue]=\"null\">\n <!-- empty option displayed even if required=true as long as there's no model to fix https://github.com/angular/angular/issues/14505 -->\n </option>\n <option *ngIf=\"!required\" [ngValue]=\"null\">\n {{ noSelectionLabel | fromDictionary }}\n </option>\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.disabled]=\"getDisabled(element) ? 'disabled' : null\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n <select\n *ngIf=\"multiple\"\n multiple\n [attr.aria-multiselectable]=\"true\"\n [class.is-invalid]=\"hasErrorsToDisplay() || hasInheritErrorFromParent()\"\n class=\"form-control\"\n [name]=\"name || label\"\n [attr.id]=\"buildChildId()\"\n [attr.disabled]=\"disabled ? 'disabled' : null\"\n [attr.aria-describedby]=\"getDescribedBy()\"\n [attr.aria-invalid]=\"hasErrorsToDisplay() || null\"\n [attr.aria-required]=\"required || null\"\n [ngModel]=\"model\"\n (ngModelChange)=\"updateNgModel($event)\"\n [compareWith]=\"compareFn.bind(this)\"\n (change)=\"handleChange(model)\"\n #entryComponent\n ngDefaultControl\n >\n <option\n *ngFor=\"let element of elements\"\n [ngValue]=\"getValue(element)\"\n [attr.selected]=\"isElementSelected(element) ? 'selected' : null\"\n [attr.aria-selected]=\"isElementSelected(element)\"\n >\n {{ getLabel(element) }}\n </option>\n </select>\n</div>\n" }]
|
|
4649
4652
|
}], ctorParameters: function () { return [{ type: i0.NgZone }]; }, propDecorators: { multiple: [{
|
|
4650
4653
|
type: Input
|
|
4651
4654
|
}], noSelectionLabel: [{
|