Your Name 1912bcd25b
Some checks failed
Lint / build (20) (push) Has been cancelled
Playwright Tests / test (push) Has been cancelled
chore: sync all remaining local workspace changes
2026-05-08 11:26:57 +08:00

132 lines
4.4 KiB
JavaScript

/*
* Extracted from browser-delivered Turbopack chunk: 5d5b47876e53e564.da1ba52a93.js
* Module id: 73920
* For reading/searching only; this factory depends on the original Turbopack runtime.
*/
const moduleFactory = (e, t, r) => {
e.e,
(t.exports = (function () {
"use strict";
var e = { year: 0, month: 1, day: 2, hour: 3, minute: 4, second: 5 },
t = {};
return function (r, n, o) {
var a,
i = function (e, r, n) {
void 0 === n && (n = {});
var o,
a,
i,
l,
s = new Date(e);
return (void 0 === (o = n) && (o = {}),
(l = t[(i = r + "|" + (a = o.timeZoneName || "short"))]) ||
((l = new Intl.DateTimeFormat("en-US", {
hour12: !1,
timeZone: r,
year: "numeric",
month: "2-digit",
day: "2-digit",
hour: "2-digit",
minute: "2-digit",
second: "2-digit",
timeZoneName: a,
})),
(t[i] = l)),
l).formatToParts(s);
},
l = function (t, r) {
for (var n = i(t, r), a = [], l = 0; l < n.length; l += 1) {
var s = n[l],
c = s.type,
u = s.value,
d = e[c];
d >= 0 && (a[d] = parseInt(u, 10));
}
var f = a[3],
m =
a[0] +
"-" +
a[1] +
"-" +
a[2] +
" " +
(24 === f ? 0 : f) +
":" +
a[4] +
":" +
a[5] +
":000",
p = +t;
return (o.utc(m).valueOf() - (p -= p % 1e3)) / 6e4;
},
s = n.prototype;
(s.tz = function (e, t) {
void 0 === e && (e = a);
var r,
n = this.utcOffset(),
i = this.toDate(),
l = i.toLocaleString("en-US", { timeZone: e }),
s = Math.round((i - new Date(l)) / 1e3 / 60),
c = -(15 * Math.round(i.getTimezoneOffset() / 15)) - s;
if (Number(c)) {
if (
((r = o(l, { locale: this.$L })
.$set("millisecond", this.$ms)
.utcOffset(c, !0)),
t)
) {
var u = r.utcOffset();
r = r.add(n - u, "minute");
}
} else r = this.utcOffset(0, t);
return (r.$x.$timezone = e), r;
}),
(s.offsetName = function (e) {
var t = this.$x.$timezone || o.tz.guess(),
r = i(this.valueOf(), t, { timeZoneName: e }).find(
function (e) {
return "timezonename" === e.type.toLowerCase();
},
);
return r && r.value;
});
var c = s.startOf;
(s.startOf = function (e, t) {
if (!this.$x || !this.$x.$timezone) return c.call(this, e, t);
var r = o(this.format("YYYY-MM-DD HH:mm:ss:SSS"), {
locale: this.$L,
});
return c.call(r, e, t).tz(this.$x.$timezone, !0);
}),
(o.tz = function (e, t, r) {
var n = r && t,
i = r || t || a,
s = l(+o(), i);
if ("string" != typeof e) return o(e).tz(i);
var c = (function (e, t, r) {
var n = e - 60 * t * 1e3,
o = l(n, r);
if (t === o) return [n, t];
var a = l((n -= 60 * (o - t) * 1e3), r);
return o === a
? [n, o]
: [e - 60 * Math.min(o, a) * 1e3, Math.max(o, a)];
})(o.utc(e, n).valueOf(), s, i),
u = c[0],
d = c[1],
f = o(u).utcOffset(d);
return (f.$x.$timezone = i), f;
}),
(o.tz.guess = function () {
return Intl.DateTimeFormat().resolvedOptions().timeZone;
}),
(o.tz.setDefault = function (e) {
a = e;
});
};
})());
};
export default moduleFactory;