monkey-front-core 0.0.65 → 0.0.70
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/esm2020/lib/core/pipes/monkeyecx-format-date-group.mjs +3 -2
- package/esm2020/lib/core/pipes/monkeyecx-format-date-timelapse.mjs +10 -6
- package/fesm2015/monkey-front-core.mjs +12 -7
- package/fesm2015/monkey-front-core.mjs.map +1 -1
- package/fesm2020/monkey-front-core.mjs +12 -7
- package/fesm2020/monkey-front-core.mjs.map +1 -1
- package/monkey-front-core-0.0.70.tgz +0 -0
- package/package.json +1 -1
- package/monkey-front-core-0.0.65.tgz +0 -0
|
@@ -6,7 +6,7 @@ import * as i2 from '@angular/common';
|
|
|
6
6
|
import { formatNumber, CurrencyPipe, CommonModule } from '@angular/common';
|
|
7
7
|
import * as i1$1 from '@ngx-translate/core';
|
|
8
8
|
import { TranslateService, TranslateModule } from '@ngx-translate/core';
|
|
9
|
-
import * as
|
|
9
|
+
import * as moment_ from 'moment';
|
|
10
10
|
import * as i1$2 from 'ngx-cookie-service';
|
|
11
11
|
import * as i1$3 from '@angular/router';
|
|
12
12
|
import { NavigationStart, NavigationEnd, NavigationError, NavigationCancel } from '@angular/router';
|
|
@@ -239,13 +239,17 @@ class MonkeyEcxUtils {
|
|
|
239
239
|
}
|
|
240
240
|
}
|
|
241
241
|
|
|
242
|
+
const moment$3 = moment_;
|
|
242
243
|
class MonkeyEcxFormatDateTimelapsePipe {
|
|
243
244
|
transform(date, showTime = false, useUtc = true, format = '- HH:mm') {
|
|
245
|
+
console.log('moment');
|
|
246
|
+
console.log('11');
|
|
247
|
+
console.log(moment$3);
|
|
244
248
|
if (!MonkeyEcxUtils.persistNullEmptyUndefined(date))
|
|
245
249
|
return '';
|
|
246
|
-
let stillUtc = moment$
|
|
250
|
+
let stillUtc = moment$3.default.utc(date).toDate();
|
|
247
251
|
if (!useUtc)
|
|
248
|
-
stillUtc = moment$
|
|
252
|
+
stillUtc = moment$3.default(date).toDate();
|
|
249
253
|
if (date.toString().indexOf(':') <= -1) {
|
|
250
254
|
if (typeof date === 'string') {
|
|
251
255
|
stillUtc = date;
|
|
@@ -254,7 +258,7 @@ class MonkeyEcxFormatDateTimelapsePipe {
|
|
|
254
258
|
}
|
|
255
259
|
const formatFrom = `YYYY/MM/DD${showTime ? ` ${format}` : ''}`;
|
|
256
260
|
const formatTo = `DD/MM/YYYY${showTime ? ` ${format}` : ''}`;
|
|
257
|
-
return `${moment$
|
|
261
|
+
return `${moment$3.default(stillUtc, formatFrom).format(formatTo)}`;
|
|
258
262
|
}
|
|
259
263
|
}
|
|
260
264
|
MonkeyEcxFormatDateTimelapsePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxFormatDateTimelapsePipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
@@ -262,7 +266,7 @@ MonkeyEcxFormatDateTimelapsePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12
|
|
|
262
266
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxFormatDateTimelapsePipe, decorators: [{
|
|
263
267
|
type: Pipe,
|
|
264
268
|
args: [{
|
|
265
|
-
name: 'monkeyecxFormatDateTimelapse'
|
|
269
|
+
name: 'monkeyecxFormatDateTimelapse',
|
|
266
270
|
}]
|
|
267
271
|
}] });
|
|
268
272
|
|
|
@@ -544,6 +548,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
544
548
|
}]
|
|
545
549
|
}] });
|
|
546
550
|
|
|
551
|
+
const moment$2 = moment_;
|
|
547
552
|
class MonkeyEcxFormatDateGroupPipe {
|
|
548
553
|
constructor(injector) {
|
|
549
554
|
this.injector = injector;
|
|
@@ -857,7 +862,7 @@ function MonkeyEcxCoreCharts(render = true) {
|
|
|
857
862
|
}
|
|
858
863
|
|
|
859
864
|
/* eslint-disable max-classes-per-file */
|
|
860
|
-
const moment$1 =
|
|
865
|
+
const moment$1 = moment_;
|
|
861
866
|
class DateValidator {
|
|
862
867
|
static do(control) {
|
|
863
868
|
if (!control.parent || !control)
|
|
@@ -1168,7 +1173,7 @@ var decoratorsUtils = /*#__PURE__*/Object.freeze({
|
|
|
1168
1173
|
hasMonkeyEcxServiceAndHandlingProperties: hasMonkeyEcxServiceAndHandlingProperties
|
|
1169
1174
|
});
|
|
1170
1175
|
|
|
1171
|
-
const moment =
|
|
1176
|
+
const moment = moment_;
|
|
1172
1177
|
const EMAIL_REGEXP = /^[\w-.]+@([\w-]+\.)+[\w-]{1,64}$/;
|
|
1173
1178
|
function isEmptyInputValue(value) {
|
|
1174
1179
|
return value == null || value.length === 0;
|