@webitel/ui-sdk 26.8.99 → 26.8.100
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/{clients-DenpsPyu.js → clients-ClR-VL_c.js} +24 -28
- package/dist/{components-CMBVRgca.js → components-CB2t5ag8.js} +2876 -1068
- package/dist/convertDuration-CGW5IDMW.js +89 -0
- package/dist/{enums-B_9ZBu01.js → enums-Bd-8yrmg.js} +30 -30
- package/dist/ui-sdk.js +15 -15
- package/dist/ui-sdk.umd.cjs +380 -380
- package/dist/{useValidation-Dmm2xos_.js → useValidation-CtEfmUkB.js} +1 -1
- package/dist/utils-B_8uwL9P.js +4 -0
- package/dist/{wt-action-bar-BpuER6TA.js → wt-action-bar-B4rcG26w.js} +2 -2
- package/dist/{wt-badge-tosjsmJU.js → wt-badge-lFnfK2an.js} +1 -1
- package/dist/{wt-button-CNQAK85M.js → wt-button-BzYDkfhK.js} +17 -17
- package/dist/{wt-chat-emoji-DGnuASX3.js → wt-chat-emoji-DwGl685x.js} +4 -4
- package/dist/{wt-datepicker-BS3przUJ.js → wt-datepicker-D_O49-Ab.js} +43 -43
- package/dist/{wt-display-chip-items-DVE5aPNw.js → wt-display-chip-items-_VHRHB6L.js} +2 -2
- package/dist/{wt-dual-panel-Cs_Yzfxt.js → wt-dual-panel-B0inNxRm.js} +1 -1
- package/dist/{wt-expansion-card-8YzHs8F1.js → wt-expansion-card-CJjtuFDk.js} +1 -1
- package/dist/{wt-expansion-panel-kZmHSvPU.js → wt-expansion-panel-tqCCM3go.js} +1 -1
- package/dist/{wt-icon-ClDNfV5I.js → wt-icon-DFtSR4bO.js} +1 -1
- package/dist/{wt-icon-action-B8vuj9cC.js → wt-icon-action-DUAnoMrj.js} +1 -1
- package/dist/{wt-icon-btn-DDElLZil.js → wt-icon-btn-CeGGT2PO.js} +1 -1
- package/dist/{wt-notifications-bar-DZidZ2VZ.js → wt-notifications-bar-DWME3pmb.js} +2 -2
- package/dist/{wt-player-CxMTs3eF.js → wt-player-DXCQLKch.js} +3 -3
- package/dist/{wt-screen-recordings-action-BTtZq2BR.js → wt-screen-recordings-action-Cx7-2gDE.js} +1 -1
- package/dist/{wt-search-bar-CE4WhuJ6.js → wt-search-bar-BkopW1qp.js} +1 -1
- package/dist/{wt-send-message-popup-DNRwANy-.js → wt-send-message-popup-Dl-FeGOx.js} +13 -12
- package/dist/{wt-status-select-CDt8sZr9.js → wt-status-select-DnaJ04Gw.js} +12 -12
- package/dist/{wt-table-DHpnLu_f.js → wt-table-xmGhfp4p.js} +3 -3
- package/dist/{wt-timepicker-D-tnO-gX.js → wt-timepicker-C0DHJSeR.js} +2 -2
- package/dist/{wt-toast-DKjRJFE2.js → wt-toast-Lge1Y6IO.js} +10 -10
- package/dist/{wt-tree-table-DDH6vMh7.js → wt-tree-table-BTHxl_MY.js} +1 -1
- package/dist/{wt-type-extension-value-input-CUx43R8o.js → wt-type-extension-value-input-Cd0towde.js} +17 -17
- package/dist/{wt-vidstack-player-_x_GEpy4.js → wt-vidstack-player-IfN1Nbyd.js} +5 -4
- package/package.json +1 -1
- package/src/enums/FormatDateMode/FormatDateMode.ts +1 -10
- package/src/scripts/convertDuration.js +1 -13
- package/src/utils/formatDate.ts +1 -37
- package/types/.tsbuildinfo +1 -1
- package/types/enums/FormatDateMode/FormatDateMode.d.ts +1 -8
- package/types/scripts/convertDuration.d.ts +1 -1
- package/types/utils/formatDate.d.ts +1 -4
- package/dist/convertDuration-1K7fuEpO.js +0 -8
- package/dist/utils-DReAiJBV.js +0 -1902
package/dist/{wt-type-extension-value-input-CUx43R8o.js → wt-type-extension-value-input-Cd0towde.js}
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { t as a } from "./enums-
|
|
1
|
+
import { a as e, o as t, r as n, s as r } from "./components-CB2t5ag8.js";
|
|
2
|
+
import { t as i } from "./clients-ClR-VL_c.js";
|
|
3
|
+
import { t as a } from "./enums-Bd-8yrmg.js";
|
|
4
4
|
import { t as o } from "./vue-i18n-B88GcHzn.js";
|
|
5
5
|
import { computed as s, createBlock as c, createCommentVNode as l, createVNode as u, defineComponent as d, mergeModels as f, mergeProps as p, openBlock as m, renderSlot as h, resolveComponent as g, unref as _, useModel as v } from "vue";
|
|
6
6
|
//#endregion
|
|
@@ -34,11 +34,11 @@ var y = /* @__PURE__ */ d({
|
|
|
34
34
|
searchMethod: O(y.field.lookup)
|
|
35
35
|
})), E = s(() => ({ ...T.value })), D = (e) => {
|
|
36
36
|
f.value = e;
|
|
37
|
-
}, O = ({ path:
|
|
38
|
-
...
|
|
39
|
-
path:
|
|
40
|
-
display:
|
|
41
|
-
primary:
|
|
37
|
+
}, O = ({ path: e = "", display: t = "", primary: n = "" } = {}) => (r) => i.getLookup({
|
|
38
|
+
...r,
|
|
39
|
+
path: e,
|
|
40
|
+
display: t,
|
|
41
|
+
primary: n
|
|
42
42
|
}), k = (e) => {
|
|
43
43
|
let t = e ?? {};
|
|
44
44
|
if (Object.values(t).length === 0) return D(null);
|
|
@@ -52,7 +52,7 @@ var y = /* @__PURE__ */ d({
|
|
|
52
52
|
name: e.name
|
|
53
53
|
})));
|
|
54
54
|
};
|
|
55
|
-
return (
|
|
55
|
+
return (i, o) => {
|
|
56
56
|
let s = g("wt-input-text"), f = g("wt-input-number");
|
|
57
57
|
return d.field.kind === _(a).Text ? (m(), c(s, p({ key: 0 }, w.value, {
|
|
58
58
|
"model-value": C.value,
|
|
@@ -60,44 +60,44 @@ var y = /* @__PURE__ */ d({
|
|
|
60
60
|
}), null, 16, ["model-value"])) : d.field.kind === _(a).Number ? (m(), c(f, p({ key: 1 }, w.value, {
|
|
61
61
|
"model-value": C.value,
|
|
62
62
|
"onUpdate:modelValue": D
|
|
63
|
-
}), null, 16, ["model-value"])) : d.field.kind === _(a).Boolean ? h(
|
|
63
|
+
}), null, 16, ["model-value"])) : d.field.kind === _(a).Boolean ? h(i.$slots, _(a).Boolean, {
|
|
64
64
|
key: 2,
|
|
65
65
|
defaultProps: { ...w.value }
|
|
66
|
-
}, () => [u(_(
|
|
66
|
+
}, () => [u(_(e), p(w.value, {
|
|
67
67
|
"model-value": C.value,
|
|
68
68
|
"onUpdate:modelValue": D
|
|
69
|
-
}), null, 16, ["model-value"])]) : d.field.kind === _(a).Select ? h(
|
|
69
|
+
}), null, 16, ["model-value"])]) : d.field.kind === _(a).Select ? h(i.$slots, _(a).Select, {
|
|
70
70
|
key: 3,
|
|
71
71
|
defaultProps: {
|
|
72
72
|
...w.value,
|
|
73
73
|
...T.value,
|
|
74
74
|
value: C.value
|
|
75
75
|
}
|
|
76
|
-
}, () => [u(_(
|
|
76
|
+
}, () => [u(_(t), p(w.value, {
|
|
77
77
|
"model-value": C.value,
|
|
78
78
|
"search-method": O(d.field.lookup),
|
|
79
79
|
"data-key": "id",
|
|
80
80
|
"onUpdate:modelValue": k
|
|
81
|
-
}), null, 16, ["model-value", "search-method"])]) : d.field.kind === _(a).Multiselect ? h(
|
|
81
|
+
}), null, 16, ["model-value", "search-method"])]) : d.field.kind === _(a).Multiselect ? h(i.$slots, _(a).Multiselect, {
|
|
82
82
|
key: 4,
|
|
83
83
|
defaultProps: {
|
|
84
84
|
...w.value,
|
|
85
85
|
...E.value,
|
|
86
86
|
value: C.value
|
|
87
87
|
}
|
|
88
|
-
}, () => [u(_(
|
|
88
|
+
}, () => [u(_(r), p({
|
|
89
89
|
...w.value,
|
|
90
90
|
...E.value
|
|
91
91
|
}, {
|
|
92
92
|
"model-value": C.value,
|
|
93
93
|
"onUpdate:modelValue": A
|
|
94
|
-
}), null, 16, ["model-value"])]) : d.field.kind === _(a).Calendar ? h(
|
|
94
|
+
}), null, 16, ["model-value"])]) : d.field.kind === _(a).Calendar ? h(i.$slots, _(a).Calendar, {
|
|
95
95
|
key: 5,
|
|
96
96
|
defaultProps: {
|
|
97
97
|
...w.value,
|
|
98
98
|
value: C.value
|
|
99
99
|
}
|
|
100
|
-
}, () => [u(_(
|
|
100
|
+
}, () => [u(_(n), p(w.value, {
|
|
101
101
|
"model-value": C.value,
|
|
102
102
|
"show-time": "",
|
|
103
103
|
"onUpdate:modelValue": D
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { w as e } from "./components-CB2t5ag8.js";
|
|
2
|
+
import "./convertDuration-CGW5IDMW.js";
|
|
2
3
|
import { t } from "./_plugin-vue_export-helper-B3ysoDQm.js";
|
|
3
|
-
import {
|
|
4
|
-
import "./wt-button-
|
|
5
|
-
import { t as r } from "./wt-icon-btn-
|
|
4
|
+
import { c as n } from "./enums-Bd-8yrmg.js";
|
|
5
|
+
import "./wt-button-BzYDkfhK.js";
|
|
6
|
+
import { t as r } from "./wt-icon-btn-CeGGT2PO.js";
|
|
6
7
|
import { $ as i, C as a, D as o, F as s, G as c, H as l, I as u, J as d, K as f, L as p, M as m, N as h, O as g, P as ee, Q as _, R as te, S as v, U as ne, V as y, W as b, X as x, Y as re, Z as S, _ as C, a as ie, b as ae, c as oe, d as se, et as ce, f as le, g as ue, h as de, i as w, it as fe, j as pe, k as me, l as T, m as he, n as E, nt as D, o as O, ot as ge, p as k, q as A, r as j, rt as _e, t as ve, tt as ye, u as be, v as M, w as xe, y as Se, z as Ce } from "./vidstack-D9mvYVIz-DesuYgKV.js";
|
|
7
8
|
import { _ as N, a as we, c as Te, d as Ee, f as De, g as Oe, h as ke, i as Ae, l as je, m as Me, n as Ne, o as Pe, p as Fe, r as Ie, s as Le, t as P, u as Re } from "./vidstack-CgfrU1hS-CNTJkyzm.js";
|
|
8
9
|
import { _ as ze, a as Be, c as Ve, f as He, g as Ue, h as We, i as Ge, l as Ke, n as qe, r as Je, s as Ye, t as Xe, u as Ze, v as Qe, x as $e, y as et } from "./useVidstackSrc-aQcqC_v0.js";
|
package/package.json
CHANGED
|
@@ -1,10 +1 @@
|
|
|
1
|
-
export
|
|
2
|
-
DATE: 'date',
|
|
3
|
-
TIME: 'time',
|
|
4
|
-
TIME_SEC: 'timeSec',
|
|
5
|
-
DATETIME: 'datetime',
|
|
6
|
-
DATETIME_SHORT: 'datetimeShort',
|
|
7
|
-
} as const;
|
|
8
|
-
|
|
9
|
-
export type FormatDateMode =
|
|
10
|
-
(typeof FormatDateMode)[keyof typeof FormatDateMode];
|
|
1
|
+
export { FormatDateMode } from '@webitel/api-services/enums';
|
|
@@ -1,15 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
if (!duration) return '00:00:00';
|
|
3
|
-
|
|
4
|
-
let hour = `${Math.floor(duration / 3600)}`;
|
|
5
|
-
let min = `${Math.floor((duration % 3600) / 60)}`;
|
|
6
|
-
let sec = `${Math.floor((duration % 3600) % 60)}`;
|
|
7
|
-
|
|
8
|
-
if (hour.length === 1) hour = `0${hour}`;
|
|
9
|
-
if (min.length === 1) min = `0${min}`;
|
|
10
|
-
if (sec.length === 1) sec = `0${sec}`;
|
|
11
|
-
|
|
12
|
-
return `${hour}:${min}:${sec}`;
|
|
13
|
-
};
|
|
1
|
+
import { convertDuration } from '@webitel/api-services/scripts';
|
|
14
2
|
|
|
15
3
|
export default convertDuration;
|
package/src/utils/formatDate.ts
CHANGED
|
@@ -1,37 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { formatInTimeZone } from 'date-fns-tz';
|
|
3
|
-
|
|
4
|
-
import type { FormatDateMode } from '../enums';
|
|
5
|
-
import { TIMEZONE_STORAGE_KEY } from '../modules/Userinfo/constants/UserSettingsConstants';
|
|
6
|
-
|
|
7
|
-
function getUserTimeZone(): string {
|
|
8
|
-
return (
|
|
9
|
-
localStorage.getItem(TIMEZONE_STORAGE_KEY) ||
|
|
10
|
-
Intl.DateTimeFormat().resolvedOptions().timeZone
|
|
11
|
-
);
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
// https://date-fns.org/v4.1.0/docs/format
|
|
15
|
-
const formatStringMap = {
|
|
16
|
-
date: 'P', // dd.MM.yyyy (13.11.2025)
|
|
17
|
-
time: 'p', // HH:mm (15:53)
|
|
18
|
-
timeSec: 'pp', // HH:mm:ss (15:53:00)
|
|
19
|
-
datetime: 'Ppp', // dd.MM.yyyy, HH:mm:ss (13.11.2025, 15:53:00)
|
|
20
|
-
datetimeShort: 'Pp', // dd.MM.yyyy, HH:mm (13.11.2025, 15:53)
|
|
21
|
-
};
|
|
22
|
-
|
|
23
|
-
export function formatDate(
|
|
24
|
-
date: string | number | Date,
|
|
25
|
-
to: (typeof FormatDateMode)[keyof typeof FormatDateMode],
|
|
26
|
-
{
|
|
27
|
-
timezone = undefined,
|
|
28
|
-
}: {
|
|
29
|
-
timezone?: string;
|
|
30
|
-
} = {},
|
|
31
|
-
): string {
|
|
32
|
-
const timeZone = timezone ?? getUserTimeZone();
|
|
33
|
-
|
|
34
|
-
return formatInTimeZone(date, timeZone, formatStringMap[to], {
|
|
35
|
-
locale: uk,
|
|
36
|
-
});
|
|
37
|
-
}
|
|
1
|
+
export { formatDate } from '@webitel/api-services/utils';
|