@stemy/ngx-utils 12.2.9 → 12.2.11
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/stemy-ngx-utils.umd.js +4 -3
- package/bundles/stemy-ngx-utils.umd.js.map +1 -1
- package/esm2015/ngx-utils/pipes/replace.pipe.js +3 -2
- package/esm2015/ngx-utils/services/formatter.service.js +4 -3
- package/esm2020/ngx-utils/common-types.mjs +2 -1
- package/esm2020/ngx-utils/ngx-utils.imports.mjs +5 -1
- package/esm2020/ngx-utils/ngx-utils.module.mjs +7 -2
- package/esm2020/ngx-utils/pipes/replace.pipe.mjs +3 -2
- package/esm2020/ngx-utils/services/base-http.service.mjs +9 -5
- package/esm2020/ngx-utils/services/local-http.service.mjs +47 -0
- package/esm2020/ngx-utils/services/state.service.mjs +2 -2
- package/esm2020/ngx-utils/services/universal.service.mjs +2 -2
- package/esm2020/ngx-utils/services/wasm.service.mjs +46 -0
- package/esm2020/ngx-utils/utils/date.utils.mjs +5 -4
- package/esm2020/ngx-utils/utils/jsonfn.mjs +45 -0
- package/esm2020/ngx-utils/utils/object.utils.mjs +3 -3
- package/esm2020/ngx-utils/utils/wasi.mjs +159 -0
- package/esm2020/ngx-utils/utils/wasm-worker-proxy.mjs +99 -0
- package/esm2020/public_api.mjs +5 -2
- package/fesm2015/stemy-ngx-utils.js +4 -3
- package/fesm2015/stemy-ngx-utils.js.map +1 -1
- package/fesm2015/stemy-ngx-utils.mjs +478 -81
- package/fesm2015/stemy-ngx-utils.mjs.map +1 -1
- package/fesm2020/stemy-ngx-utils.mjs +473 -79
- package/fesm2020/stemy-ngx-utils.mjs.map +1 -1
- package/ngx-utils/services/formatter.service.d.ts +1 -1
- package/ngx-utils/services/local-http.service.d.ts +14 -0
- package/ngx-utils/services/wasm.service.d.ts +25 -0
- package/ngx-utils/utils/jsonfn.d.ts +6 -0
- package/ngx-utils/utils/wasi.d.ts +26 -0
- package/ngx-utils/utils/wasm-worker-proxy.d.ts +17 -0
- package/package.json +1 -1
- package/stemy-ngx-utils.metadata.json +1 -1
|
@@ -3539,12 +3539,13 @@
|
|
|
3539
3539
|
FormatterService.prototype.roundNumber = function (value, precision, divider) {
|
|
3540
3540
|
return MathUtils.round(value, this.getPrecision(precision), divider || this.defaultDivider);
|
|
3541
3541
|
};
|
|
3542
|
-
FormatterService.prototype.formatNumber = function (value, format, precision, divider) {
|
|
3542
|
+
FormatterService.prototype.formatNumber = function (value, format, precision, divider, minDigits) {
|
|
3543
3543
|
precision = this.getPrecision(precision);
|
|
3544
|
+
minDigits = minDigits !== null && minDigits !== void 0 ? minDigits : precision;
|
|
3544
3545
|
divider = divider || this.defaultDivider;
|
|
3545
3546
|
var num = ObjectUtils.isNumber(value) ? value : parseFloat(value) || 0;
|
|
3546
3547
|
var str = (num / divider).toLocaleString(this.language.currentLanguage, {
|
|
3547
|
-
minimumFractionDigits:
|
|
3548
|
+
minimumFractionDigits: minDigits,
|
|
3548
3549
|
maximumFractionDigits: precision,
|
|
3549
3550
|
useGrouping: false
|
|
3550
3551
|
});
|
|
@@ -4736,7 +4737,7 @@
|
|
|
4736
4737
|
function ReplacePipe() {
|
|
4737
4738
|
}
|
|
4738
4739
|
ReplacePipe.prototype.transform = function (value, from, to) {
|
|
4739
|
-
return value ? value.replace(from, to) :
|
|
4740
|
+
return ObjectUtils.isDefined(value) ? ("" + value).replace(from, to) : "";
|
|
4740
4741
|
};
|
|
4741
4742
|
return ReplacePipe;
|
|
4742
4743
|
}());
|