web-mojo 2.1.278 → 2.1.279
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/admin.cjs.js +1 -1
- package/dist/admin.cjs.js.map +1 -1
- package/dist/admin.es.js +48 -22
- package/dist/admin.es.js.map +1 -1
- package/dist/auth.cjs.js +1 -1
- package/dist/auth.cjs.js.map +1 -1
- package/dist/auth.es.js +4 -4
- package/dist/auth.es.js.map +1 -1
- package/dist/charts.cjs.js +1 -1
- package/dist/charts.es.js +2 -2
- package/dist/chunks/{ContextMenu-BGyC31Bb.js → ContextMenu-CbLtzdQ3.js} +2 -2
- package/dist/chunks/{ContextMenu-BGyC31Bb.js.map → ContextMenu-CbLtzdQ3.js.map} +1 -1
- package/dist/chunks/{ContextMenu-B5-M-xk4.js → ContextMenu-D_mMcMoZ.js} +2 -2
- package/dist/chunks/{ContextMenu-B5-M-xk4.js.map → ContextMenu-D_mMcMoZ.js.map} +1 -1
- package/dist/chunks/{DataView-D5GAnAwy.js → DataView-DRWkmcdf.js} +2 -2
- package/dist/chunks/{DataView-D5GAnAwy.js.map → DataView-DRWkmcdf.js.map} +1 -1
- package/dist/chunks/{DataView-b_MvCVHp.js → DataView-Dp_IkmIs.js} +2 -2
- package/dist/chunks/{DataView-b_MvCVHp.js.map → DataView-Dp_IkmIs.js.map} +1 -1
- package/dist/chunks/{Dialog-Cb3hStew.js → Dialog-B2kdxPq7.js} +2 -2
- package/dist/chunks/{Dialog-Cb3hStew.js.map → Dialog-B2kdxPq7.js.map} +1 -1
- package/dist/chunks/{Dialog-DL2qXPTj.js → Dialog-Q_eKMZbf.js} +5 -5
- package/dist/chunks/{Dialog-DL2qXPTj.js.map → Dialog-Q_eKMZbf.js.map} +1 -1
- package/dist/chunks/{FilePreviewView-DfSMNOwF.js → FilePreviewView-8xmoaPcu.js} +2 -2
- package/dist/chunks/{FilePreviewView-DfSMNOwF.js.map → FilePreviewView-8xmoaPcu.js.map} +1 -1
- package/dist/chunks/{FilePreviewView-BrrJorTn.js → FilePreviewView-Coo_gKQT.js} +6 -6
- package/dist/chunks/{FilePreviewView-BrrJorTn.js.map → FilePreviewView-Coo_gKQT.js.map} +1 -1
- package/dist/chunks/{FormView-BCnSXvaY.js → FormView-RlEnZXGW.js} +2 -2
- package/dist/chunks/{FormView-BCnSXvaY.js.map → FormView-RlEnZXGW.js.map} +1 -1
- package/dist/chunks/{FormView-FTVjKzXh.js → FormView-aK77Cu5o.js} +2 -2
- package/dist/chunks/{FormView-FTVjKzXh.js.map → FormView-aK77Cu5o.js.map} +1 -1
- package/dist/chunks/{MetricsChart-DFNBNWw7.js → MetricsChart-Cg6GIfxF.js} +2 -2
- package/dist/chunks/{MetricsChart-DFNBNWw7.js.map → MetricsChart-Cg6GIfxF.js.map} +1 -1
- package/dist/chunks/{MetricsChart-B0YqU0CD.js → MetricsChart-DbuVz9pZ.js} +3 -3
- package/dist/chunks/{MetricsChart-B0YqU0CD.js.map → MetricsChart-DbuVz9pZ.js.map} +1 -1
- package/dist/chunks/{PDFViewer-uSCAzgto.js → PDFViewer-CTDvtmnX.js} +2 -2
- package/dist/chunks/{PDFViewer-uSCAzgto.js.map → PDFViewer-CTDvtmnX.js.map} +1 -1
- package/dist/chunks/{PDFViewer-B9OppITV.js → PDFViewer-DEWeWa6M.js} +3 -3
- package/dist/chunks/{PDFViewer-B9OppITV.js.map → PDFViewer-DEWeWa6M.js.map} +1 -1
- package/dist/chunks/{Page-lvFkx9ma.js → Page-CkaWP9y0.js} +2 -2
- package/dist/chunks/{Page-lvFkx9ma.js.map → Page-CkaWP9y0.js.map} +1 -1
- package/dist/chunks/{Page-BnWHjjZe.js → Page-DrsZyMrK.js} +2 -2
- package/dist/chunks/{Page-BnWHjjZe.js.map → Page-DrsZyMrK.js.map} +1 -1
- package/dist/chunks/{TokenManager-gp1JKXNd.js → TokenManager-Bv9T1Pxb.js} +2 -2
- package/dist/chunks/TokenManager-Bv9T1Pxb.js.map +1 -0
- package/dist/chunks/{TokenManager-5HHjYzTo.js → TokenManager-Fjt083wv.js} +1 -2
- package/dist/chunks/TokenManager-Fjt083wv.js.map +1 -0
- package/dist/chunks/{TopNav-8K9q8FgL.js → TopNav-Cecaj4dy.js} +2 -2
- package/dist/chunks/{TopNav-8K9q8FgL.js.map → TopNav-Cecaj4dy.js.map} +1 -1
- package/dist/chunks/{TopNav-C86aDfet.js → TopNav-Cq0OynVD.js} +2 -2
- package/dist/chunks/{TopNav-C86aDfet.js.map → TopNav-Cq0OynVD.js.map} +1 -1
- package/dist/chunks/{User-DbeMvd6x.js → User-BYYBLpBL.js} +2 -2
- package/dist/chunks/{User-DbeMvd6x.js.map → User-BYYBLpBL.js.map} +1 -1
- package/dist/chunks/{User-DIhA4ryO.js → User-C7tiEixC.js} +2 -2
- package/dist/chunks/{User-DIhA4ryO.js.map → User-C7tiEixC.js.map} +1 -1
- package/dist/chunks/{WebApp-_cIASgB0.js → WebApp-C5OPtxUH.js} +136 -13
- package/dist/chunks/WebApp-C5OPtxUH.js.map +1 -0
- package/dist/chunks/WebApp-CpH1rYkM.js +2 -0
- package/dist/chunks/WebApp-CpH1rYkM.js.map +1 -0
- package/dist/docit.cjs.js +1 -1
- package/dist/docit.es.js +7 -7
- package/dist/index.cjs.js +1 -1
- package/dist/index.es.js +12 -12
- package/dist/lightbox.cjs.js +1 -1
- package/dist/lightbox.es.js +4 -4
- package/package.json +1 -1
- package/dist/chunks/TokenManager-5HHjYzTo.js.map +0 -1
- package/dist/chunks/TokenManager-gp1JKXNd.js.map +0 -1
- package/dist/chunks/WebApp-BIxs8_cJ.js +0 -2
- package/dist/chunks/WebApp-BIxs8_cJ.js.map +0 -1
- package/dist/chunks/WebApp-_cIASgB0.js.map +0 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
const VERSION = "2.1.
|
|
1
|
+
const VERSION = "2.1.279";
|
|
2
2
|
const VERSION_MAJOR = 2;
|
|
3
3
|
const VERSION_MINOR = 1;
|
|
4
|
-
const VERSION_REVISION =
|
|
5
|
-
const BUILD_TIME = "2025-09-
|
|
4
|
+
const VERSION_REVISION = 279;
|
|
5
|
+
const BUILD_TIME = "2025-09-26T05:51:27.778Z";
|
|
6
6
|
const VERSION_INFO = {
|
|
7
7
|
full: VERSION,
|
|
8
8
|
major: VERSION_MAJOR,
|
|
@@ -510,6 +510,8 @@ class DataFormatter {
|
|
|
510
510
|
this.register("date", this.date.bind(this));
|
|
511
511
|
this.register("time", this.time.bind(this));
|
|
512
512
|
this.register("datetime", this.datetime.bind(this));
|
|
513
|
+
this.register("datetime_tz", this.datetime_tz.bind(this));
|
|
514
|
+
this.register("datatime_tz", this.datetime_tz.bind(this));
|
|
513
515
|
this.register("relative", this.relative.bind(this));
|
|
514
516
|
this.register("fromNow", this.relative.bind(this));
|
|
515
517
|
this.register("iso", this.iso.bind(this));
|
|
@@ -786,12 +788,133 @@ class DataFormatter {
|
|
|
786
788
|
* @param {string} timeFormat - Time format
|
|
787
789
|
* @returns {string} Formatted datetime
|
|
788
790
|
*/
|
|
789
|
-
datetime(value, dateFormat = "MM/DD/YYYY", timeFormat = "HH:mm") {
|
|
791
|
+
datetime(value, dateFormat = "MM/DD/YYYY", timeFormat = "HH:mm:ss") {
|
|
790
792
|
value = this.normalizeEpoch(value);
|
|
791
793
|
const dateStr = this.date(value, dateFormat);
|
|
792
794
|
const timeStr = this.time(value, timeFormat);
|
|
793
795
|
return dateStr && timeStr ? `${dateStr} ${timeStr}` : "";
|
|
794
796
|
}
|
|
797
|
+
/**
|
|
798
|
+
* Format date and time with short timezone abbreviation (e.g., EST, PDT)
|
|
799
|
+
* @param {*} value - DateTime value
|
|
800
|
+
* @param {string} dateFormat - Date format
|
|
801
|
+
* @param {string} timeFormat - Time format
|
|
802
|
+
* @param {Object} options - Options: { timeZone?: string, locale?: string }
|
|
803
|
+
* @returns {string} Formatted datetime with timezone abbreviation
|
|
804
|
+
*/
|
|
805
|
+
datetime_tz(value, dateFormat = "MM/DD/YYYY", timeFormat = "HH:mm:ss", options = {}) {
|
|
806
|
+
if (!value) return "";
|
|
807
|
+
value = this.normalizeEpoch(value);
|
|
808
|
+
const date = value instanceof Date ? value : new Date(value);
|
|
809
|
+
if (isNaN(date.getTime())) return String(value);
|
|
810
|
+
const locale = options && options.locale || "en-US";
|
|
811
|
+
const timeZone = options && options.timeZone ? options.timeZone : void 0;
|
|
812
|
+
const getTzAbbr = () => {
|
|
813
|
+
let abbr2 = "";
|
|
814
|
+
try {
|
|
815
|
+
const parts2 = new Intl.DateTimeFormat(locale, {
|
|
816
|
+
hour: "2-digit",
|
|
817
|
+
minute: "2-digit",
|
|
818
|
+
timeZoneName: "short",
|
|
819
|
+
...timeZone ? { timeZone } : {}
|
|
820
|
+
}).formatToParts(date);
|
|
821
|
+
const tzPart = parts2.find((p) => p.type === "timeZoneName");
|
|
822
|
+
abbr2 = tzPart ? tzPart.value : "";
|
|
823
|
+
if (abbr2 && /^GMT[+-]/i.test(abbr2)) {
|
|
824
|
+
try {
|
|
825
|
+
const parts22 = new Intl.DateTimeFormat(locale, {
|
|
826
|
+
timeStyle: "short",
|
|
827
|
+
timeZoneName: "short",
|
|
828
|
+
...timeZone ? { timeZone } : {}
|
|
829
|
+
}).formatToParts(date);
|
|
830
|
+
const tz2 = parts22.find((p) => p.type === "timeZoneName");
|
|
831
|
+
if (tz2 && tz2.value && !/^GMT[+-]/i.test(tz2.value)) {
|
|
832
|
+
abbr2 = tz2.value;
|
|
833
|
+
}
|
|
834
|
+
} catch (e) {
|
|
835
|
+
}
|
|
836
|
+
}
|
|
837
|
+
if (abbr2 && /\s/.test(abbr2)) {
|
|
838
|
+
const initials = abbr2.split(/\s+/).map((w) => w[0]).join("").toUpperCase();
|
|
839
|
+
if (initials.length >= 2 && initials.length <= 4) {
|
|
840
|
+
abbr2 = initials;
|
|
841
|
+
}
|
|
842
|
+
}
|
|
843
|
+
} catch (e) {
|
|
844
|
+
abbr2 = "";
|
|
845
|
+
}
|
|
846
|
+
return abbr2;
|
|
847
|
+
};
|
|
848
|
+
if (!timeZone) {
|
|
849
|
+
const dateStr2 = this.date(date, dateFormat);
|
|
850
|
+
const timeStr2 = this.time(date, timeFormat);
|
|
851
|
+
const abbr2 = getTzAbbr();
|
|
852
|
+
return dateStr2 && timeStr2 ? `${dateStr2} ${timeStr2} ${abbr2}`.trim() : "";
|
|
853
|
+
}
|
|
854
|
+
const parts = new Intl.DateTimeFormat(locale, {
|
|
855
|
+
timeZone,
|
|
856
|
+
year: "numeric",
|
|
857
|
+
month: "2-digit",
|
|
858
|
+
day: "2-digit",
|
|
859
|
+
hour: "2-digit",
|
|
860
|
+
minute: "2-digit",
|
|
861
|
+
second: "2-digit",
|
|
862
|
+
hourCycle: "h23"
|
|
863
|
+
}).formatToParts(date);
|
|
864
|
+
const get = (type) => {
|
|
865
|
+
const p = parts.find((pt) => pt.type === type);
|
|
866
|
+
return p ? p.value : "";
|
|
867
|
+
};
|
|
868
|
+
const y4 = get("year");
|
|
869
|
+
const M2 = get("month");
|
|
870
|
+
const D2 = get("day");
|
|
871
|
+
const H2 = get("hour");
|
|
872
|
+
const m2 = get("minute");
|
|
873
|
+
const s2 = get("second");
|
|
874
|
+
const M = M2 ? String(parseInt(M2, 10)) : "";
|
|
875
|
+
const D = D2 ? String(parseInt(D2, 10)) : "";
|
|
876
|
+
const H = H2 ? String(parseInt(H2, 10)) : "";
|
|
877
|
+
const hNum = H2 ? parseInt(H2, 10) % 12 || 12 : "";
|
|
878
|
+
const A = H2 ? parseInt(H2, 10) >= 12 ? "PM" : "AM" : "";
|
|
879
|
+
const a = A ? A.toLowerCase() : "";
|
|
880
|
+
const monthLong = new Intl.DateTimeFormat(locale, { timeZone, month: "long" }).format(date);
|
|
881
|
+
const monthShort = new Intl.DateTimeFormat(locale, { timeZone, month: "short" }).format(date);
|
|
882
|
+
const weekdayLong = new Intl.DateTimeFormat(locale, { timeZone, weekday: "long" }).format(date);
|
|
883
|
+
const weekdayShort = new Intl.DateTimeFormat(locale, { timeZone, weekday: "short" }).format(date);
|
|
884
|
+
const dateTokens = {
|
|
885
|
+
"YYYY": y4,
|
|
886
|
+
"YY": y4 ? y4.slice(-2) : "",
|
|
887
|
+
"MMMM": monthLong,
|
|
888
|
+
"MMM": monthShort,
|
|
889
|
+
"MM": M2,
|
|
890
|
+
"M": M,
|
|
891
|
+
"dddd": weekdayLong,
|
|
892
|
+
"ddd": weekdayShort,
|
|
893
|
+
"DD": D2,
|
|
894
|
+
"D": D
|
|
895
|
+
};
|
|
896
|
+
const timeTokens = {
|
|
897
|
+
"HH": H2,
|
|
898
|
+
"H": H,
|
|
899
|
+
"hh": hNum !== "" ? String(hNum).padStart(2, "0") : "",
|
|
900
|
+
"h": hNum !== "" ? String(hNum) : "",
|
|
901
|
+
"mm": m2,
|
|
902
|
+
"m": m2 ? String(parseInt(m2, 10)) : "",
|
|
903
|
+
"ss": s2,
|
|
904
|
+
"s": s2 ? String(parseInt(s2, 10)) : "",
|
|
905
|
+
"A": A,
|
|
906
|
+
"a": a
|
|
907
|
+
};
|
|
908
|
+
const replaceTokens = (fmt, tokens) => {
|
|
909
|
+
if (!fmt) return "";
|
|
910
|
+
const pattern = new RegExp(`(${Object.keys(tokens).sort((a2, b) => b.length - a2.length).join("|")})`, "g");
|
|
911
|
+
return fmt.replace(pattern, (match) => tokens[match] ?? match);
|
|
912
|
+
};
|
|
913
|
+
const dateStr = replaceTokens(dateFormat, dateTokens);
|
|
914
|
+
const timeStr = replaceTokens(timeFormat, timeTokens);
|
|
915
|
+
const abbr = getTzAbbr();
|
|
916
|
+
return dateStr && timeStr ? `${dateStr} ${timeStr} ${abbr}`.trim() : "";
|
|
917
|
+
}
|
|
795
918
|
normalizeEpoch(value) {
|
|
796
919
|
if (typeof value !== "number") value = Number(value);
|
|
797
920
|
if (isNaN(value)) return "";
|
|
@@ -4606,7 +4729,7 @@ class WebApp {
|
|
|
4606
4729
|
*/
|
|
4607
4730
|
async showError(message) {
|
|
4608
4731
|
try {
|
|
4609
|
-
const Dialog = (await import("./Dialog-
|
|
4732
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4610
4733
|
await Dialog.alert(message, "Error", { size: "md", class: "text-danger" });
|
|
4611
4734
|
} catch (e) {
|
|
4612
4735
|
this.events.emit("notification", { message, type: "error" });
|
|
@@ -4623,7 +4746,7 @@ class WebApp {
|
|
|
4623
4746
|
*/
|
|
4624
4747
|
async showSuccess(message) {
|
|
4625
4748
|
try {
|
|
4626
|
-
const Dialog = (await import("./Dialog-
|
|
4749
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4627
4750
|
await Dialog.alert(message, "Success", { size: "md", class: "text-success" });
|
|
4628
4751
|
} catch (e) {
|
|
4629
4752
|
this.events.emit("notification", { message, type: "success" });
|
|
@@ -4640,7 +4763,7 @@ class WebApp {
|
|
|
4640
4763
|
*/
|
|
4641
4764
|
async showInfo(message) {
|
|
4642
4765
|
try {
|
|
4643
|
-
const Dialog = (await import("./Dialog-
|
|
4766
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4644
4767
|
await Dialog.alert(message, "Information", { size: "md", class: "text-info" });
|
|
4645
4768
|
} catch (e) {
|
|
4646
4769
|
this.events.emit("notification", { message, type: "info" });
|
|
@@ -4657,7 +4780,7 @@ class WebApp {
|
|
|
4657
4780
|
*/
|
|
4658
4781
|
async showWarning(message) {
|
|
4659
4782
|
try {
|
|
4660
|
-
const Dialog = (await import("./Dialog-
|
|
4783
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4661
4784
|
await Dialog.alert(message, "Warning", { size: "md", class: "text-warning" });
|
|
4662
4785
|
} catch (e) {
|
|
4663
4786
|
this.events.emit("notification", { message, type: "warning" });
|
|
@@ -4683,7 +4806,7 @@ class WebApp {
|
|
|
4683
4806
|
opts = { message: opts };
|
|
4684
4807
|
}
|
|
4685
4808
|
try {
|
|
4686
|
-
const Dialog = (await import("./Dialog-
|
|
4809
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4687
4810
|
Dialog.showBusy(opts);
|
|
4688
4811
|
} catch (e) {
|
|
4689
4812
|
if (typeof window !== "undefined" && window?.console) {
|
|
@@ -4697,7 +4820,7 @@ class WebApp {
|
|
|
4697
4820
|
*/
|
|
4698
4821
|
async hideLoading() {
|
|
4699
4822
|
try {
|
|
4700
|
-
const Dialog = (await import("./Dialog-
|
|
4823
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4701
4824
|
Dialog.hideBusy();
|
|
4702
4825
|
} catch (e) {
|
|
4703
4826
|
if (typeof window !== "undefined" && window?.console) {
|
|
@@ -4707,7 +4830,7 @@ class WebApp {
|
|
|
4707
4830
|
}
|
|
4708
4831
|
async showModelForm(options = {}) {
|
|
4709
4832
|
try {
|
|
4710
|
-
const Dialog = (await import("./Dialog-
|
|
4833
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4711
4834
|
return await Dialog.showModelForm(options);
|
|
4712
4835
|
} catch (e) {
|
|
4713
4836
|
if (typeof window !== "undefined" && window?.console) {
|
|
@@ -4718,7 +4841,7 @@ class WebApp {
|
|
|
4718
4841
|
}
|
|
4719
4842
|
async showForm(options = {}) {
|
|
4720
4843
|
try {
|
|
4721
|
-
const Dialog = (await import("./Dialog-
|
|
4844
|
+
const Dialog = (await import("./Dialog-Q_eKMZbf.js")).default;
|
|
4722
4845
|
return await Dialog.showForm(options);
|
|
4723
4846
|
} catch (e) {
|
|
4724
4847
|
if (typeof window !== "undefined" && window?.console) {
|
|
@@ -4981,4 +5104,4 @@ export {
|
|
|
4981
5104
|
EventEmitter as i,
|
|
4982
5105
|
rest as r
|
|
4983
5106
|
};
|
|
4984
|
-
//# sourceMappingURL=WebApp-
|
|
5107
|
+
//# sourceMappingURL=WebApp-C5OPtxUH.js.map
|