@sumaris-net/ngx-components 1.4.1 → 1.4.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/sumaris-net.ngx-components.umd.js +6 -17
- package/bundles/sumaris-net.ngx-components.umd.js.map +1 -1
- package/bundles/sumaris-net.ngx-components.umd.min.js +1 -1
- package/bundles/sumaris-net.ngx-components.umd.min.js.map +1 -1
- package/esm2015/src/app/shared/material/boolean/material.boolean.js +4 -15
- package/esm2015/src/app/shared/material/datetime/material.datetime.js +5 -4
- package/fesm2015/sumaris-net.ngx-components.js +6 -16
- package/fesm2015/sumaris-net.ngx-components.js.map +1 -1
- package/package.json +1 -1
- package/src/app/shared/material/boolean/material.boolean.d.ts +2 -4
- package/src/app/shared/material/datetime/material.datetime.d.ts +3 -3
- package/sumaris-net.ngx-components.metadata.json +1 -1
|
@@ -5312,6 +5312,7 @@
|
|
|
5312
5312
|
this.compact = false;
|
|
5313
5313
|
this.placeholderChar = DEFAULT_PLACEHOLDER_CHAR;
|
|
5314
5314
|
this.autofocus = false;
|
|
5315
|
+
this.startDate = null;
|
|
5315
5316
|
this.clearable = false;
|
|
5316
5317
|
this.locale = (translate.currentLang || translate.defaultLang).substr(0, 2);
|
|
5317
5318
|
}
|
|
@@ -5679,19 +5680,19 @@
|
|
|
5679
5680
|
{ type: i1.FormGroupDirective, decorators: [{ type: i0.Optional }] }
|
|
5680
5681
|
]; };
|
|
5681
5682
|
MatDateTime.propDecorators = {
|
|
5682
|
-
mobile: [{ type: i0.Input }],
|
|
5683
5683
|
formControl: [{ type: i0.Input }],
|
|
5684
5684
|
formControlName: [{ type: i0.Input }],
|
|
5685
5685
|
placeholder: [{ type: i0.Input }],
|
|
5686
5686
|
floatLabel: [{ type: i0.Input }],
|
|
5687
5687
|
required: [{ type: i0.Input }],
|
|
5688
|
+
mobile: [{ type: i0.Input }],
|
|
5688
5689
|
compact: [{ type: i0.Input }],
|
|
5689
5690
|
placeholderChar: [{ type: i0.Input }],
|
|
5690
5691
|
autofocus: [{ type: i0.Input }],
|
|
5691
|
-
readonly: [{ type: i0.Input }],
|
|
5692
|
-
tabindex: [{ type: i0.Input }],
|
|
5693
5692
|
startDate: [{ type: i0.Input }],
|
|
5694
5693
|
clearable: [{ type: i0.Input }],
|
|
5694
|
+
readonly: [{ type: i0.Input }],
|
|
5695
|
+
tabindex: [{ type: i0.Input }],
|
|
5695
5696
|
datePicker: [{ type: i0.ViewChild, args: ['datePicker',] }],
|
|
5696
5697
|
timePicker: [{ type: i0.ViewChild, args: ['timePicker',] }],
|
|
5697
5698
|
matInputs: [{ type: i0.ViewChildren, args: ['matInput',] }]
|
|
@@ -6411,17 +6412,6 @@
|
|
|
6411
6412
|
this.showRadio = this.showRadio || this.floatLabel === 'always';
|
|
6412
6413
|
this.updateTabIndex();
|
|
6413
6414
|
};
|
|
6414
|
-
MatBooleanField.prototype.ngAfterViewInit = function () {
|
|
6415
|
-
var _this = this;
|
|
6416
|
-
// Inject suffix elements, into the first injection point found
|
|
6417
|
-
if (this.suffixDiv) {
|
|
6418
|
-
this.suffixInjections.find(function (item) {
|
|
6419
|
-
item.nativeElement.append(_this.suffixDiv.nativeElement);
|
|
6420
|
-
_this.suffixDiv.nativeElement.classList.remove('cdk-visually-hidden');
|
|
6421
|
-
return true; // take only the first injection point
|
|
6422
|
-
});
|
|
6423
|
-
}
|
|
6424
|
-
};
|
|
6425
6415
|
MatBooleanField.prototype.writeValue = function (value, event) {
|
|
6426
6416
|
var _this = this;
|
|
6427
6417
|
if (this._writing)
|
|
@@ -6540,7 +6530,7 @@
|
|
|
6540
6530
|
MatBooleanField.decorators = [
|
|
6541
6531
|
{ type: i0.Component, args: [{
|
|
6542
6532
|
selector: 'mat-boolean-field',
|
|
6543
|
-
template: "<mat-form-field *ngIf=\"readonly; else writable\"\n [floatLabel]=\"floatLabel\"\n class=\"mat-form-field-disabled {{classList}}\">\n <input matInput hidden type=\"text\" readonly\n [placeholder]=\"placeholder\"\n [formControl]=\"formControl\">\n <ion-text>{{(formControl.value == null && 'COMMON.EMPTY_OPTION' || (formControl.value === true && yesLabel) || noLabel) | translate }}</ion-text>\n</mat-form-field>\n\n<ng-template #writable>\n <ng-container [ngSwitch]=\"style\">\n\n <!-- Radio -->\n <mat-form-field *ngSwitchCase=\"'radio'\"\n [floatLabel]=\"showRadio && (!floatLabel || floatLabel === 'auto') ? 'always': floatLabel\"\n class=\"mat-boolean-field mat-boolean-field-radio {{classList}}\">\n <mat-label *ngIf=\"placeholder && floatLabel!=='never'\">\n {{placeholder}}\n <span [hidden]=\"showRadio\">({{yesLabel|translate}}/{{'COMMON.NO'|translate}})</span>\n </mat-label>\n\n <input matInput #fakeInput type=\"text\" readonly=\"true\"\n [formControl]=\"formControl\"\n (focus)=\"_onFocusFakeInput($event)\"\n [required]=\"required\"\n [class.cdk-visually-hidden]=\"showRadio\"\n [tabindex]=\"tabindex\">\n\n <!-- radio button -->\n <mat-radio-group [hidden]=\"!showRadio\"\n [formControl]=\"formControl\"\n (change)=\"onRadioValueChanged($event)\">\n <mat-radio-button #yesButton [value]=\"true\">\n <span>{{yesLabel|translate}}</span>\n </mat-radio-button> \n <mat-radio-button #noButton [value]=\"false\">\n <span>{{noLabel|translate}}</span>\n </mat-radio-button>\n </mat-radio-group>\n\n <
|
|
6533
|
+
template: "<mat-form-field *ngIf=\"readonly; else writable\"\n [floatLabel]=\"floatLabel\"\n class=\"mat-form-field-disabled {{classList}}\">\n <div matPrefix>\n <ng-container *ngTemplateOutlet=\"matPrefixTemplate\"></ng-container>\n </div>\n <input matInput hidden type=\"text\" readonly\n [placeholder]=\"placeholder\"\n [formControl]=\"formControl\">\n <ion-text>{{(formControl.value == null && 'COMMON.EMPTY_OPTION' || (formControl.value === true && yesLabel) || noLabel) | translate }}</ion-text>\n <div matSuffix>\n <ng-container *ngTemplateOutlet=\"matSuffixTemplate\"></ng-container>\n </div>\n</mat-form-field>\n\n<ng-template #writable>\n <ng-container [ngSwitch]=\"style\">\n\n <!-- Radio -->\n <mat-form-field *ngSwitchCase=\"'radio'\"\n [floatLabel]=\"showRadio && (!floatLabel || floatLabel === 'auto') ? 'always': floatLabel\"\n class=\"mat-boolean-field mat-boolean-field-radio {{classList}}\">\n <mat-label *ngIf=\"placeholder && floatLabel!=='never'\">\n {{placeholder}}\n <span [hidden]=\"showRadio\">({{yesLabel|translate}}/{{'COMMON.NO'|translate}})</span>\n </mat-label>\n <div matPrefix>\n <ng-container *ngTemplateOutlet=\"matPrefixTemplate\"></ng-container>\n </div>\n <input matInput #fakeInput type=\"text\" readonly=\"true\"\n [formControl]=\"formControl\"\n (focus)=\"_onFocusFakeInput($event)\"\n [required]=\"required\"\n [class.cdk-visually-hidden]=\"showRadio\"\n [tabindex]=\"tabindex\">\n\n <!-- radio button -->\n <mat-radio-group [hidden]=\"!showRadio\"\n [formControl]=\"formControl\"\n (change)=\"onRadioValueChanged($event)\">\n <mat-radio-button #yesButton [value]=\"true\">\n <span>{{yesLabel|translate}}</span>\n </mat-radio-button> \n <mat-radio-button #noButton [value]=\"false\">\n <span>{{noLabel|translate}}</span>\n </mat-radio-button>\n </mat-radio-group>\n\n <mat-error *ngIf=\"formControl.hasError('required')\" translate>ERROR.FIELD_REQUIRED</mat-error>\n\n <div matSuffix>\n <ng-container *ngTemplateOutlet=\"matSuffixTemplate\"></ng-container>\n </div>\n </mat-form-field>\n\n <!-- Checkbox -->\n <mat-form-field *ngSwitchCase=\"'checkbox'\"\n [floatLabel]=\"floatLabel\"\n class=\"mat-boolean-field mat-boolean-field-checkbox {{classList}}\">\n <mat-label *ngIf=\"placeholder && !showRadio\">\n {{placeholder}}\n </mat-label>\n <div matPrefix>\n <ng-container *ngTemplateOutlet=\"matPrefixTemplate\"></ng-container>\n </div>\n <input matInput #matInput\n [formControl]=\"formControl\"\n (focus)=\"_onFocusFakeInput($event)\"\n [required]=\"required\"\n [class.cdk-visually-hidden]=\"showRadio\"\n [tabindex]=\"tabindex\">\n\n <ion-label> </ion-label>\n\n <!-- checkbox, when compact -->\n <mat-checkbox #checkboxButton\n [formControl]=\"formControl\"\n (change)=\"onCheckboxValueChanged($event)\"\n [indeterminate]=\"value===undefined\"\n [hidden]=\"!showRadio\"\n [tabindex]=\"tabindex\">\n </mat-checkbox>\n\n <mat-error *ngIf=\"formControl.hasError('required')\" translate>ERROR.FIELD_REQUIRED</mat-error>\n\n <div matSuffix>\n <ng-container *ngTemplateOutlet=\"matSuffixTemplate\"></ng-container>\n </div>\n </mat-form-field>\n\n <!-- Buttons -->\n <mat-form-field *ngSwitchCase=\"'button'\"\n [floatLabel]=\"floatLabel === 'never' ? 'never' : 'always'\"\n class=\"mat-boolean-field mat-boolean-field-button {{classList}}\">\n <div matPrefix>\n <ng-container *ngTemplateOutlet=\"matPrefixTemplate\"></ng-container>\n </div>\n <input matInput type=\"text\" hidden\n [formControl]=\"formControl\"\n [placeholder]=\"placeholder\"\n [required]=\"required\">\n <div class=\"mat-form-field-buttons\"\n [style.--buttons-col-count]=\"buttonsColCount\"\n *ngIf=\"!formControl.disabled; else disabledLabel\">\n <!-- yes -->\n <ion-button class=\"mat-form-field-button\"\n [tabindex]=\"_tabindex\"\n (click)=\"writeValue(true, $event)\"\n (keyup.enter)=\"writeValue(true, $event)\"\n [color]=\"_value == null ? 'tertiary' : (_value === true) ? 'accent' : 'light'\">\n <ion-icon *ngIf=\"showButtonIcons && yesIcon; let icon\" slot=\"start\" [name]=\"icon\"></ion-icon>\n {{yesLabel|translate}}\n </ion-button>\n\n <!-- No button -->\n <ion-button class=\"mat-form-field-button\"\n [tabindex]=\"_tabindex !== undefined ? (_tabindex + 1) : undefined\"\n (click)=\"writeValue(false, $event)\"\n (keyup.enter)=\"writeValue(false, $event)\"\n [color]=\"_value == null ? 'tertiary' : (_value === false) ? 'accent' : 'light'\">\n <ion-icon *ngIf=\"showButtonIcons && noIcon; let icon\" slot=\"start\" [name]=\"icon\"></ion-icon>\n {{noLabel|translate}}\n </ion-button>\n </div>\n <ng-template #disabledLabel>\n <ion-label><i translate>COMMON.EMPTY_OPTION</i></ion-label>\n </ng-template>\n\n <mat-error *ngIf=\"formControl.hasError('required')\" translate>ERROR.FIELD_REQUIRED</mat-error>\n <div matSuffix>\n <ng-container *ngTemplateOutlet=\"matSuffixTemplate\"></ng-container>\n </div>\n\n </mat-form-field>\n </ng-container>\n\n <div class=\"cdk-visually-hidden\">\n <div #suffix><ng-content select=\"[matSuffix]\"></ng-content></div>\n </div>\n\n</ng-template>\n\n\n<ng-template #matPrefixTemplate>\n <ng-content select=\"[matPrefix]\"></ng-content>\n</ng-template>\n<ng-template #matSuffixTemplate>\n <ng-content select=\"[matSuffix]\"></ng-content>\n</ng-template>\n",
|
|
6544
6534
|
providers: [
|
|
6545
6535
|
DEFAULT_VALUE_ACCESSOR$1
|
|
6546
6536
|
],
|
|
@@ -6579,8 +6569,7 @@
|
|
|
6579
6569
|
noButton: [{ type: i0.ViewChild, args: ['noButton',] }],
|
|
6580
6570
|
checkboxButton: [{ type: i0.ViewChild, args: ['checkboxButton',] }],
|
|
6581
6571
|
fakeInput: [{ type: i0.ViewChild, args: ['fakeInput',] }],
|
|
6582
|
-
suffixDiv: [{ type: i0.ViewChild, args: ['suffix', { static: false },] }]
|
|
6583
|
-
suffixInjections: [{ type: i0.ViewChildren, args: ['injectMatSuffix',] }]
|
|
6572
|
+
suffixDiv: [{ type: i0.ViewChild, args: ['suffix', { static: false },] }]
|
|
6584
6573
|
};
|
|
6585
6574
|
|
|
6586
6575
|
var SharedMatBooleanModule = /** @class */ (function () {
|