@bluemarble/bm-components 0.0.59 → 0.0.60
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/dist/esm/index.js +6 -11
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/utils/DateFormat.d.ts +3 -130
- package/dist/index.d.ts +3 -130
- package/package.json +1 -1
package/dist/esm/index.js
CHANGED
|
@@ -15307,12 +15307,10 @@ function DateFormat(date) {
|
|
|
15307
15307
|
const data = {
|
|
15308
15308
|
utc: -3
|
|
15309
15309
|
};
|
|
15310
|
-
|
|
15311
|
-
|
|
15312
|
-
|
|
15313
|
-
|
|
15314
|
-
.toDate();
|
|
15315
|
-
}
|
|
15310
|
+
if (date) {
|
|
15311
|
+
date = moment(date)
|
|
15312
|
+
.add(data.utc + 3, 'hours')
|
|
15313
|
+
.toDate();
|
|
15316
15314
|
}
|
|
15317
15315
|
function momentWithDate(utc = false) {
|
|
15318
15316
|
const current = moment(date).utc(utc);
|
|
@@ -15323,7 +15321,7 @@ function DateFormat(date) {
|
|
|
15323
15321
|
let utc = forceUTC || true;
|
|
15324
15322
|
if (String(date).endsWith('Z'))
|
|
15325
15323
|
utc = false;
|
|
15326
|
-
return
|
|
15324
|
+
return momentWithDate(utc);
|
|
15327
15325
|
}
|
|
15328
15326
|
function now() {
|
|
15329
15327
|
if (process.env.NODE_ENV === 'development') {
|
|
@@ -15341,10 +15339,7 @@ function DateFormat(date) {
|
|
|
15341
15339
|
now,
|
|
15342
15340
|
utc: (newUTC) => {
|
|
15343
15341
|
data.utc = newUTC;
|
|
15344
|
-
return
|
|
15345
|
-
formateDateWithCurrentUTC(newDate);
|
|
15346
|
-
return methods;
|
|
15347
|
-
};
|
|
15342
|
+
return methods;
|
|
15348
15343
|
}
|
|
15349
15344
|
};
|
|
15350
15345
|
return methods;
|