@seniorsistemas/angular-components 16.3.2 → 16.3.4
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/seniorsistemas-angular-components.umd.js +25 -9
- package/bundles/seniorsistemas-angular-components.umd.js.map +1 -1
- package/bundles/seniorsistemas-angular-components.umd.min.js +2 -2
- package/bundles/seniorsistemas-angular-components.umd.min.js.map +1 -1
- package/components/dynamic-form/configurations/fields/bignumber-field.d.ts +2 -0
- package/esm2015/components/bignumber-input/number-input.directive.js +3 -2
- package/esm2015/components/dynamic-form/components/fields/bignumber/number-field.component.js +17 -8
- package/esm2015/components/dynamic-form/components/lookup/lookup.component.js +7 -2
- package/esm2015/components/dynamic-form/configurations/fields/bignumber-field.js +2 -1
- package/esm5/components/bignumber-input/number-input.directive.js +3 -2
- package/esm5/components/dynamic-form/components/fields/bignumber/number-field.component.js +17 -8
- package/esm5/components/dynamic-form/components/lookup/lookup.component.js +7 -2
- package/esm5/components/dynamic-form/configurations/fields/bignumber-field.js +2 -1
- package/fesm2015/seniorsistemas-angular-components.js +25 -9
- package/fesm2015/seniorsistemas-angular-components.js.map +1 -1
- package/fesm5/seniorsistemas-angular-components.js +25 -9
- package/fesm5/seniorsistemas-angular-components.js.map +1 -1
- package/package.json +1 -1
- package/seniorsistemas-angular-components.metadata.json +1 -1
|
@@ -1484,6 +1484,7 @@ var BignumberField = /** @class */ (function (_super) {
|
|
|
1484
1484
|
function BignumberField(config) {
|
|
1485
1485
|
var _a;
|
|
1486
1486
|
var _this = _super.call(this, config) || this;
|
|
1487
|
+
_this.allowNegative = config.allowNegative;
|
|
1487
1488
|
_this.numberLocaleOptions = config.numberLocaleOptions || new NumberLocaleOptions();
|
|
1488
1489
|
_this.browserAutocomplete = config.browserAutocomplete;
|
|
1489
1490
|
_this.precision = config.precision;
|
|
@@ -2051,7 +2052,12 @@ var LookupComponent = /** @class */ (function () {
|
|
|
2051
2052
|
this.onSearchRequest.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () { return (_this.loading = true); });
|
|
2052
2053
|
this.onSelect.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () { return _this.onChange(_this.value); });
|
|
2053
2054
|
this.onUnselect.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () { return _this.onChange(_this.value); });
|
|
2054
|
-
this.onClear.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
2055
|
+
this.onClear.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
2056
|
+
if (_this.multiple || !_this.value) {
|
|
2057
|
+
return;
|
|
2058
|
+
}
|
|
2059
|
+
_this.onChange(null);
|
|
2060
|
+
});
|
|
2055
2061
|
this.onFocus.pipe(takeUntil(this.ngUnsubscribe)).subscribe(function () {
|
|
2056
2062
|
_this.onTouched();
|
|
2057
2063
|
});
|
|
@@ -3789,8 +3795,9 @@ var BignumberInputDirective = /** @class */ (function (_super) {
|
|
|
3789
3795
|
};
|
|
3790
3796
|
BignumberInputDirective.prototype.ngOnChanges = function (changes) {
|
|
3791
3797
|
var placeholderChange = changes.placeholder && changes.placeholder.currentValue;
|
|
3792
|
-
if (!placeholderChange && this.scale)
|
|
3798
|
+
if (!placeholderChange && this.scale) {
|
|
3793
3799
|
this.placeholder = "0" + this.decimalSeparator + "".padEnd(this.scale, "0");
|
|
3800
|
+
}
|
|
3794
3801
|
if (changes.scale ||
|
|
3795
3802
|
changes.decimalSeparator ||
|
|
3796
3803
|
changes.thousandsSeparator ||
|
|
@@ -5543,17 +5550,26 @@ var BignumberFieldComponent = /** @class */ (function (_super) {
|
|
|
5543
5550
|
}
|
|
5544
5551
|
BignumberFieldComponent.prototype.ngOnInit = function () {
|
|
5545
5552
|
var _this = this;
|
|
5546
|
-
this.onFocus
|
|
5547
|
-
|
|
5553
|
+
this.onFocus
|
|
5554
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
5555
|
+
.subscribe(function (event) {
|
|
5556
|
+
if (_this.field.onFocus) {
|
|
5548
5557
|
_this.field.onFocus(event);
|
|
5558
|
+
}
|
|
5549
5559
|
});
|
|
5550
|
-
this.onInput
|
|
5551
|
-
|
|
5560
|
+
this.onInput
|
|
5561
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
5562
|
+
.subscribe(function (event) {
|
|
5563
|
+
if (_this.field.onInput) {
|
|
5552
5564
|
_this.field.onInput(event);
|
|
5565
|
+
}
|
|
5553
5566
|
});
|
|
5554
|
-
this.onComplete
|
|
5555
|
-
|
|
5567
|
+
this.onComplete
|
|
5568
|
+
.pipe(takeUntil(this.ngUnsubscribe))
|
|
5569
|
+
.subscribe(function (event) {
|
|
5570
|
+
if (_this.field.onComplete) {
|
|
5556
5571
|
_this.field.onComplete(event);
|
|
5572
|
+
}
|
|
5557
5573
|
});
|
|
5558
5574
|
};
|
|
5559
5575
|
BignumberFieldComponent.prototype.ngOnDestroy = function () {
|
|
@@ -5584,7 +5600,7 @@ var BignumberFieldComponent = /** @class */ (function (_super) {
|
|
|
5584
5600
|
], BignumberFieldComponent.prototype, "onComplete", void 0);
|
|
5585
5601
|
BignumberFieldComponent = __decorate([
|
|
5586
5602
|
Component({
|
|
5587
|
-
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\"
|
|
5603
|
+
template: "<p-inputMask\n *ngIf=\"field.mask; else noMask\"\n type=\"text\"\n [inputId]=\"(field.id || field.name)\"\n [name]=\"field.name\"\n [mask]=\"isFunction(field.mask) ? field.mask() : field.mask\"\n [placeholder]=\"field.placeholder\"\n slotChar=\"_\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [showDelay]=\"500\"\n styleClass=\"mousetrap\"\n (onBlur)=\"field.onBlur ? field.onBlur($event) : null\"\n (onFocus)=\"onFocus.next($event)\"\n (onComplete)=\"onComplete.next($event)\"\n (onInput)=\"onInput.next($event)\"\n [formControl]=\"formControl\">\n</p-inputMask>\n\n<ng-template #noMask>\n <ng-container>\n <div class=\"ui-inputgroup\">\n <ng-container *ngIf=\"field.leftAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.leftAddon.label\">{{field.leftAddon.label}}</span>\n <span *ngIf=\"!field.leftAddon.label\" [ngClass]=\"field.leftAddon.icon\"></span>\n </span>\n </ng-container>\n\n <input\n [id]=\"(field.id || field.name)\"\n type=\"text\"\n [name]=\"field.name\"\n sBignumberInput\n [allowNegative]=\"field.allowNegative\"\n [precision]=\"isFunction(field.precision) ? trigger(field.precision) : field.precision\"\n [scale]=\"isFunction(field.scale) ? trigger(field.scale) : field.scale\"\n [decimalSeparator]=\"field.numberLocaleOptions.decimalSeparator\"\n [thousandsSeparator]=\"field.numberLocaleOptions.thousandsSeparator\"\n [alignTo]=\"field.alignTo\"\n [sTooltip]=\"field.tooltip\"\n tooltipPosition=\"top\"\n [placeholder]=\"field.placeholder\"\n [showDelay]=\"500\"\n pInputText\n [autocomplete]=\"field.browserAutocomplete ? 'on' : 'off'\"\n [ngClass]=\"'mousetrap'\"\n (blur)=\"field.onBlur ? field.onBlur($event) : null\"\n (focus)=\"onFocus.next($event)\"\n [formControl]=\"formControl\" />\n <ng-container *ngIf=\"field.rightAddon\">\n <span class=\"ui-inputgroup-addon\">\n <span *ngIf=\"field.rightAddon.label\">{{field.rightAddon.label}}</span>\n <span *ngIf=\"!field.rightAddon.label\" [ngClass]=\"field.rightAddon.icon\"></span>\n </span>\n </ng-container>\n </div>\n </ng-container>\n</ng-template>",
|
|
5588
5604
|
encapsulation: ViewEncapsulation.None,
|
|
5589
5605
|
styles: ["s-number-field.ng-dirty.ng-invalid .ui-inputtext{border-color:#c13018}s-number-field.ng-dirty.ng-invalid .ui-inputtext:hover{border-color:#e44328}"]
|
|
5590
5606
|
})
|