@fewangsit/wangsvue-fats 1.0.1-rc.0 → 1.0.1-rc.11
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/animation/index.es.js +50 -0
- package/approverinfo/index.es.js +6 -6
- package/assetinfo/index.es.js +160 -2
- package/backgroundimagecropper/{BackgroundImageCropper.es.js → index.es.js} +1 -1
- package/badge/index.es.js +7 -7
- package/badgegroup/index.es.js +7 -7
- package/basecalendar/{BaseCalendar.es.js → index.es.js} +6 -6
- package/basetree/index.es.js +14 -14
- package/breadcrumb/index.es.js +6 -6
- package/button/index.es.js +118 -2
- package/buttonaddbyscan/index.es.js +13 -13
- package/buttonbulkaction/index.es.js +184 -2
- package/buttoncopy/index.es.js +6 -6
- package/buttondownload/index.es.js +15 -15
- package/buttonfilter/index.es.js +6 -6
- package/buttonradio/index.es.js +2 -2
- package/buttonscan/index.es.js +414 -2
- package/buttonsearch/index.es.js +9 -9
- package/buttonsearchbyscan/index.es.js +7 -7
- package/buttonselecttree/index.es.js +22 -22
- package/buttonselectuser/index.es.js +25 -25
- package/buttonsync/index.es.js +12 -12
- package/buttontoggle/index.es.js +6 -6
- package/buttonviewlog/index.es.js +2 -2
- package/calendar/index.es.js +4 -4
- package/card/index.es.js +4 -4
- package/carousel/index.es.js +7 -7
- package/checkbox/index.es.js +2 -2
- package/codesnippet/{CodeSnippet.es.js → index.es.js} +1 -1
- package/codesnippetadapter/{CodeSnippetAdapter.es.js → index.es.js} +1 -1
- package/columnlist/{ColumnList.es.js → index.es.js} +8 -8
- package/config/defaultProps.es.js +133 -0
- package/config/index.es.js +10 -218
- package/config/locale.es.js +85 -0
- package/customcolumn/index.es.js +8 -8
- package/datatable/index.es.js +108 -107
- package/datepicker/index.es.js +138 -2
- package/daypicker/index.es.js +6 -6
- package/dialog/index.es.js +4 -4
- package/dialogassetnamedetail/index.es.js +11 -11
- package/dialogbasictransferlog/{DialogBasicTransferLog.es.js → index.es.js} +17 -17
- package/dialogconfirm/index.es.js +17 -17
- package/dialogdamagelog/index.es.js +14 -14
- package/dialogform/index.es.js +32 -32
- package/dialogfulltransferlog/{DialogFullTransferLog.es.js → index.es.js} +16 -16
- package/dialoglinkedasset/index.es.js +9 -9
- package/dialogprintqr/index.es.js +332 -2
- package/dialogreportdamage/index.es.js +12 -12
- package/dialogreportmissing/index.es.js +12 -12
- package/dialogreporttag/index.es.js +8 -8
- package/dialogselecttree/index.es.js +13 -13
- package/dialogselectuser/index.d.ts +2 -2
- package/dialogselectuser/index.es.js +18 -18
- package/dialogselectuserfilter/{DialogSelectUserFilter.es.js → index.es.js} +2 -2
- package/dialogtransferlog/index.es.js +9 -9
- package/directives/{focus/index.es.js → focus.es.js} +2 -2
- package/directives/index.es.js +2 -0
- package/directives/tooltip.es.js +1 -0
- package/disposalreport/index.es.js +8 -8
- package/disposalreportbulkaction/{DisposalReportBulkAction.es.js → index.es.js} +9 -8
- package/disposalreporttable/{DisposalReportTable.es.js → index.es.js} +16 -16
- package/disposalreporttablefilter/{DisposalReportTableFilter.es.js → index.es.js} +5 -5
- package/dropdown/index.es.js +37 -37
- package/editor/{Editor.es.js → index.es.js} +57 -57
- package/editorbutton/{EditorButton.es.js → index.es.js} +1 -1
- package/event-bus/index.es.js +4 -3
- package/event-bus/mitt.es.js +53 -0
- package/fieldwrapper/{FieldWrapper.es.js → index.es.js} +2 -2
- package/fileupload/index.es.js +13 -13
- package/filtercontainer/index.es.js +34 -34
- package/form/index.es.js +23 -23
- package/hardwaresync/{HardwareSync.es.js → index.es.js} +42 -42
- package/icon/index.es.js +4 -4
- package/image/index.es.js +14 -14
- package/imagecompressor/index.es.js +14 -14
- package/imageinputinfo/{ImageInputInfo.es.js → index.es.js} +2 -2
- package/inlinemessage/index.es.js +7 -7
- package/inputbadge/index.es.js +14 -14
- package/inputcurrency/index.es.js +147 -2
- package/inputemail/index.es.js +4 -4
- package/inputnumber/index.es.js +6 -6
- package/inputotp/index.es.js +1 -1
- package/inputpassword/index.es.js +10 -10
- package/inputphonenumber/index.es.js +28 -28
- package/inputrangenumber/index.es.js +9 -9
- package/inputsearch/index.es.js +2 -2
- package/inputtext/index.es.js +11 -11
- package/inputurl/index.es.js +5 -5
- package/invisiblefield/index.es.js +8 -8
- package/languagedropdownoption/{LanguageDropdownOption.es.js → index.es.js} +3 -3
- package/languageswitcher/index.es.js +7 -7
- package/litedropdown/index.es.js +10 -10
- package/loading/index.es.js +8 -8
- package/mentionlist/{MentionList.es.js → index.es.js} +4 -4
- package/menu/index.es.js +20 -19
- package/menuitem/{MenuItem.es.js → index.es.js} +1 -1
- package/multiselect/index.es.js +27 -27
- package/overlaypanel/index.es.js +6 -6
- package/package.json +1 -5
- package/paginator/index.es.js +11 -11
- package/plugins/VueHtmlToPaper.es.js +40 -0
- package/{animation/Animation.es.js → plugins/WangsVue.es.js} +38 -83
- package/plugins/basei18n.d.ts +103 -0
- package/plugins/basei18n.es.js +88 -0
- package/plugins/{formValidation/index.es.js → formValidation.es.js} +4 -4
- package/plugins/i18n.d.ts +5 -102
- package/plugins/i18n.es.js +6 -0
- package/stats.html +1 -1
- package/steps/index.es.js +4 -4
- package/tabmenu/index.es.js +1 -1
- package/tagtype/index.es.js +6 -6
- package/textarea/index.es.js +5 -5
- package/timeline/index.es.js +5 -5
- package/timelinecontentbytype/{TimelineContentByType.es.js → index.es.js} +9 -9
- package/toast/index.es.js +3 -3
- package/toggleswitch/index.es.js +2 -2
- package/transactionroles/index.es.js +2 -2
- package/tree/index.es.js +117 -107
- package/treenode/{TreeNode.es.js → index.es.js} +4 -4
- package/treesearchinput/{TreeSearchInput.es.js → index.es.js} +4 -4
- package/username/index.es.js +20 -20
- package/userwithicon/index.es.js +4 -4
- package/utils/baseToast.util.es.js +1 -1
- package/utils/date.util.es.js +2 -2
- package/utils/index.es.js +3 -36
- package/utils/role.util.es.js +2 -2
- package/validatormessage/index.es.js +4 -4
- package/vendor/highlight.js/es/core.es.js +1 -1
- package/vendor/lodash/_freeGlobal.es.js +1 -1
- package/vendor/simplebar-core/dist/index.es.js +1 -1
- package/wangsvue-fats.d.ts +1 -2
- package/wangsvue-fats.es.js +219 -256
- package/wangsvue-fats.system.js +56 -56
- package/approverinfo/package.json +0 -4
- package/assetinfo/AssetInfo.es.js +0 -179
- package/assetinfo/package.json +0 -4
- package/badge/package.json +0 -4
- package/badgegroup/package.json +0 -4
- package/basetree/package.json +0 -4
- package/breadcrumb/package.json +0 -4
- package/button/Button.es.js +0 -120
- package/button/package.json +0 -4
- package/buttonaddbyscan/package.json +0 -4
- package/buttonbulkaction/ButtonBulkAction.es.js +0 -238
- package/buttonbulkaction/package.json +0 -4
- package/buttoncopy/package.json +0 -4
- package/buttondownload/package.json +0 -4
- package/buttonfilter/package.json +0 -4
- package/buttonradio/package.json +0 -4
- package/buttonscan/ButtonScan.es.js +0 -416
- package/buttonscan/package.json +0 -4
- package/buttonsearch/package.json +0 -4
- package/buttonsearchbyscan/package.json +0 -4
- package/buttonselecttree/package.json +0 -4
- package/buttonselectuser/package.json +0 -4
- package/buttonsync/package.json +0 -4
- package/buttontoggle/package.json +0 -4
- package/buttonviewlog/package.json +0 -4
- package/calendar/package.json +0 -4
- package/card/package.json +0 -4
- package/carousel/package.json +0 -4
- package/checkbox/package.json +0 -4
- package/config/package.json +0 -4
- package/customcolumn/package.json +0 -4
- package/datatable/package.json +0 -4
- package/datepicker/DatePicker.es.js +0 -224
- package/datepicker/package.json +0 -4
- package/daypicker/package.json +0 -4
- package/dialog/package.json +0 -4
- package/dialogassetnamedetail/package.json +0 -4
- package/dialogconfirm/package.json +0 -4
- package/dialogdamagelog/package.json +0 -4
- package/dialogform/package.json +0 -4
- package/dialoglinkedasset/package.json +0 -4
- package/dialogprintqr/DialogPrintQR.es.js +0 -334
- package/dialogprintqr/package.json +0 -4
- package/dialogreportdamage/package.json +0 -4
- package/dialogreportmissing/package.json +0 -4
- package/dialogreporttag/package.json +0 -4
- package/dialogselecttree/package.json +0 -4
- package/dialogselectuser/package.json +0 -4
- package/dialogtransferlog/package.json +0 -4
- package/directives/focus/package.json +0 -4
- package/directives/tooltip/index.es.js +0 -4
- package/directives/tooltip/package.json +0 -4
- package/disposalreport/package.json +0 -4
- package/dropdown/package.json +0 -4
- package/event-bus/package.json +0 -4
- package/fileupload/package.json +0 -4
- package/filtercontainer/package.json +0 -4
- package/form/package.json +0 -4
- package/icon/package.json +0 -4
- package/image/package.json +0 -4
- package/imagecompressor/package.json +0 -4
- package/index.d.ts +0 -2
- package/inlinemessage/package.json +0 -4
- package/inputbadge/package.json +0 -4
- package/inputcurrency/InputCurrency.es.js +0 -150
- package/inputcurrency/helpers/index.es.js +0 -5
- package/inputcurrency/helpers/package.json +0 -4
- package/inputcurrency/package.json +0 -4
- package/inputemail/package.json +0 -4
- package/inputnumber/package.json +0 -4
- package/inputotp/package.json +0 -4
- package/inputpassword/package.json +0 -4
- package/inputphonenumber/package.json +0 -4
- package/inputrangenumber/package.json +0 -4
- package/inputsearch/package.json +0 -4
- package/inputtext/package.json +0 -4
- package/inputurl/package.json +0 -4
- package/invisiblefield/package.json +0 -4
- package/languageswitcher/package.json +0 -4
- package/litedropdown/package.json +0 -4
- package/loading/package.json +0 -4
- package/loading/store/index.es.js +0 -5
- package/loading/store/package.json +0 -4
- package/menu/package.json +0 -4
- package/multiselect/package.json +0 -4
- package/overlaypanel/package.json +0 -4
- package/paginator/package.json +0 -4
- package/plugins/formValidation/package.json +0 -4
- package/plugins/i18n/index.es.js +0 -8
- package/plugins/i18n/package.json +0 -4
- package/plugins/i18n-extension.d.ts +0 -4
- package/steps/package.json +0 -4
- package/tabmenu/package.json +0 -4
- package/tagtype/package.json +0 -4
- package/textarea/package.json +0 -4
- package/timeline/package.json +0 -4
- package/toast/package.json +0 -4
- package/toast/service/index.es.js +0 -5
- package/toast/service/package.json +0 -4
- package/toggleswitch/package.json +0 -4
- package/transactionroles/package.json +0 -4
- package/tree/package.json +0 -4
- package/username/package.json +0 -4
- package/userwithicon/package.json +0 -4
- package/utils/package.json +0 -4
- package/validatormessage/package.json +0 -4
- /package/inputgroup/{InputGroup.es.js → index.es.js} +0 -0
- /package/mentionsection/{MentionSection.es.js → index.es.js} +0 -0
- /package/multirow/{MultiRow.es.js → index.es.js} +0 -0
package/multiselect/index.es.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { defineComponent as z, onMounted as E, onUnmounted as T, inject as U, shallowRef as A, ref as R, reactive as D, computed as h, watch as v, createBlock as V, openBlock as w, withCtx as t, createVNode as i, normalizeClass as F, renderSlot as H, unref as
|
|
1
|
+
import { defineComponent as z, onMounted as E, onUnmounted as T, inject as U, shallowRef as A, ref as R, reactive as D, computed as h, watch as v, createBlock as V, openBlock as w, withCtx as t, createVNode as i, normalizeClass as F, renderSlot as H, unref as r, mergeProps as k, createSlots as W, normalizeProps as p, guardReactiveProps as f, withModifiers as q, createElementVNode as G, toDisplayString as J, createCommentVNode as K } from "vue";
|
|
2
2
|
import { u as Q } from "../vendor/vee-validate/dist/vee-validate.esm.es.js";
|
|
3
|
-
import { e as S } from "../
|
|
4
|
-
import { u as X } from "../
|
|
3
|
+
import { e as S } from "../event-bus/index.es.js";
|
|
4
|
+
import { u as X } from "../plugins/WangsVue.es.js";
|
|
5
5
|
import { f as Y } from "../utils/filterOptions.util.es.js";
|
|
6
6
|
import { a as Z } from "../utils/textFormatter.util.es.js";
|
|
7
7
|
import { s as ee } from "../vendor/primevue/multiselect/multiselect.esm.es.js";
|
|
8
|
-
import { _ as M } from "../button/
|
|
9
|
-
import { _ as le } from "../fieldwrapper/
|
|
10
|
-
import c from "../icon/index.es.js";
|
|
11
|
-
import { _ as oe } from "../inputgroup/
|
|
12
|
-
import ae from "../validatormessage/index.es.js";
|
|
8
|
+
import { _ as M } from "../button/index.es.js";
|
|
9
|
+
import { _ as le } from "../fieldwrapper/index.es.js";
|
|
10
|
+
import { _ as c } from "../icon/index.es.js";
|
|
11
|
+
import { _ as oe } from "../inputgroup/index.es.js";
|
|
12
|
+
import { _ as ae } from "../validatormessage/index.es.js";
|
|
13
13
|
const he = /* @__PURE__ */ z({
|
|
14
14
|
__name: "MultiSelect",
|
|
15
15
|
props: {
|
|
@@ -45,20 +45,20 @@ const he = /* @__PURE__ */ z({
|
|
|
45
45
|
});
|
|
46
46
|
const { locale: m } = X("MultiSelect"), n = U("preset", {}).multiselect, u = A(!1), d = R(), a = D({
|
|
47
47
|
value: e.initialValue ? e.initialValue : e.modelValue
|
|
48
|
-
}),
|
|
48
|
+
}), _ = h(() => Y(e.options)), $ = h(() => {
|
|
49
49
|
var l;
|
|
50
50
|
return m.emptySelectionErrorMessage.replace("{label}", e.label).replace(
|
|
51
51
|
"{formattedLabel}",
|
|
52
52
|
(l = Z(e.label)) == null ? void 0 : l.toLowerCase()
|
|
53
53
|
);
|
|
54
|
-
}),
|
|
54
|
+
}), O = h(() => {
|
|
55
55
|
var l;
|
|
56
56
|
return e.loading ? m.loadingPlaceholder : e.placeholder ?? ((l = m.inputPlaceholder) == null ? void 0 : l.replace("{label}", e.label ?? "").replace("{lowercaseLabel}", (e.label ?? "").toLowerCase()));
|
|
57
57
|
}), x = () => {
|
|
58
58
|
var l;
|
|
59
59
|
e.useValidator && (Object.assign(
|
|
60
60
|
a,
|
|
61
|
-
Q(e.fieldName ?? "multiSelect", (o) => !(Array.isArray(o) && o.length) && e.mandatory ? typeof e.validatorMessage == "object" && "empty" in e.validatorMessage ? e.validatorMessage.empty : e.validatorMessage ??
|
|
61
|
+
Q(e.fieldName ?? "multiSelect", (o) => !(Array.isArray(o) && o.length) && e.mandatory ? typeof e.validatorMessage == "object" && "empty" in e.validatorMessage ? e.validatorMessage.empty : e.validatorMessage ?? $.value : !0)
|
|
62
62
|
), (l = e.initialValue) != null && l.length && (a.value = e.initialValue));
|
|
63
63
|
}, g = () => {
|
|
64
64
|
d.value && d.value.show();
|
|
@@ -103,11 +103,11 @@ const he = /* @__PURE__ */ z({
|
|
|
103
103
|
default: t(() => {
|
|
104
104
|
var b;
|
|
105
105
|
return [
|
|
106
|
-
i(
|
|
106
|
+
i(r(ee), k(e, {
|
|
107
107
|
ref_key: "multiselect",
|
|
108
108
|
ref: d,
|
|
109
109
|
modelValue: a.value,
|
|
110
|
-
"onUpdate:modelValue": o[0] || (o[0] = (
|
|
110
|
+
"onUpdate:modelValue": o[0] || (o[0] = (s) => a.value = s),
|
|
111
111
|
"aria-describedby": e.label + "error",
|
|
112
112
|
class: [
|
|
113
113
|
{
|
|
@@ -115,18 +115,18 @@ const he = /* @__PURE__ */ z({
|
|
|
115
115
|
}
|
|
116
116
|
],
|
|
117
117
|
display: e.display,
|
|
118
|
-
"filter-placeholder": e.filterPlaceholder ||
|
|
118
|
+
"filter-placeholder": e.filterPlaceholder || r(m).filterPlaceholder,
|
|
119
119
|
"max-selected-labels": e.maxSelectedLabels,
|
|
120
|
-
options:
|
|
121
|
-
placeholder:
|
|
120
|
+
options: _.value,
|
|
121
|
+
placeholder: O.value,
|
|
122
122
|
"selected-items-label": e.selectedItemsLabel,
|
|
123
123
|
"show-toggle-all": e.filter,
|
|
124
124
|
"virtual-scroller-options": (((b = l.options) == null ? void 0 : b.length) ?? 0) > 10 ? { itemSize: 32 } : void 0,
|
|
125
|
-
onHide: o[1] || (o[1] = (
|
|
126
|
-
onShow: o[2] || (o[2] = (
|
|
125
|
+
onHide: o[1] || (o[1] = (s) => (u.value = !1, l.$emit("hide"))),
|
|
126
|
+
onShow: o[2] || (o[2] = (s) => (l.$emit("show"), u.value = !0))
|
|
127
127
|
}), W({
|
|
128
128
|
dropdownicon: t(() => [
|
|
129
|
-
i(c, p(f(
|
|
129
|
+
i(c, p(f(r(n).dropdownicon({ state: { isShowOverlay: u.value } }))), null, 16)
|
|
130
130
|
]),
|
|
131
131
|
headercheckboxicon: t(() => [
|
|
132
132
|
i(c, { icon: "check" })
|
|
@@ -135,12 +135,12 @@ const he = /* @__PURE__ */ z({
|
|
|
135
135
|
i(c, { icon: "check" })
|
|
136
136
|
]),
|
|
137
137
|
filtericon: t(() => [
|
|
138
|
-
i(c, p(f(
|
|
138
|
+
i(c, p(f(r(n).filtericon)), null, 16)
|
|
139
139
|
]),
|
|
140
|
-
removetokenicon: t(({ removeCallback:
|
|
140
|
+
removetokenicon: t(({ removeCallback: s, item: N }) => [
|
|
141
141
|
i(M, k({
|
|
142
|
-
onClick: q((j) =>
|
|
143
|
-
},
|
|
142
|
+
onClick: q((j) => s(j, N), ["stop"])
|
|
143
|
+
}, r(n).removeTokenIcon, {
|
|
144
144
|
icon: "close",
|
|
145
145
|
rounded: "",
|
|
146
146
|
severity: "dark",
|
|
@@ -148,14 +148,14 @@ const he = /* @__PURE__ */ z({
|
|
|
148
148
|
}), null, 16, ["onClick"])
|
|
149
149
|
]),
|
|
150
150
|
loadingicon: t(() => [
|
|
151
|
-
i(c, p(f(
|
|
151
|
+
i(c, p(f(r(n).loadingicon)), null, 16)
|
|
152
152
|
]),
|
|
153
153
|
_: 2
|
|
154
154
|
}, [
|
|
155
155
|
l.loading ? {
|
|
156
156
|
name: "value",
|
|
157
|
-
fn: t(({ placeholder:
|
|
158
|
-
G("span", p(f(
|
|
157
|
+
fn: t(({ placeholder: s }) => [
|
|
158
|
+
G("span", p(f(r(n).loadingplaceholder)), J(s), 17)
|
|
159
159
|
]),
|
|
160
160
|
key: "0"
|
|
161
161
|
} : void 0
|
|
@@ -185,5 +185,5 @@ const he = /* @__PURE__ */ z({
|
|
|
185
185
|
}
|
|
186
186
|
});
|
|
187
187
|
export {
|
|
188
|
-
he as
|
|
188
|
+
he as _
|
|
189
189
|
};
|
package/overlaypanel/index.es.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { e as s } from "../
|
|
1
|
+
import { defineComponent as i, ref as u, createBlock as f, openBlock as c, unref as y, mergeProps as v, withCtx as h, renderSlot as m } from "vue";
|
|
2
|
+
import { e as s } from "../event-bus/index.es.js";
|
|
3
3
|
import { s as w } from "../vendor/primevue/overlaypanel/overlaypanel.esm.es.js";
|
|
4
|
-
const x = /* @__PURE__ */
|
|
4
|
+
const x = /* @__PURE__ */ i({
|
|
5
5
|
__name: "OverlayPanel",
|
|
6
6
|
props: {
|
|
7
7
|
dismissable: { type: Boolean, default: !0 },
|
|
@@ -17,7 +17,7 @@ const x = /* @__PURE__ */ u({
|
|
|
17
17
|
closeOnEscape: { type: Boolean, default: !0 }
|
|
18
18
|
},
|
|
19
19
|
setup(l, { expose: n }) {
|
|
20
|
-
const t = +/* @__PURE__ */ new Date(), o =
|
|
20
|
+
const t = +/* @__PURE__ */ new Date(), o = u(), r = l, p = () => {
|
|
21
21
|
s.off("overlay:show", a);
|
|
22
22
|
}, a = (e) => {
|
|
23
23
|
o.value && e.overlayId !== t && r.dismissableOverlay && o.value.hide();
|
|
@@ -30,7 +30,7 @@ const x = /* @__PURE__ */ u({
|
|
|
30
30
|
o.value.hide();
|
|
31
31
|
}, show: (e) => {
|
|
32
32
|
o.value.show(e);
|
|
33
|
-
} }), (e,
|
|
33
|
+
} }), (e, _) => (c(), f(y(w), v(e.$props, {
|
|
34
34
|
id: t,
|
|
35
35
|
ref_key: "op",
|
|
36
36
|
ref: o,
|
|
@@ -45,5 +45,5 @@ const x = /* @__PURE__ */ u({
|
|
|
45
45
|
}
|
|
46
46
|
});
|
|
47
47
|
export {
|
|
48
|
-
x as
|
|
48
|
+
x as _
|
|
49
49
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fewangsit/wangsvue-fats",
|
|
3
|
-
"version": "1.0.1-rc.
|
|
3
|
+
"version": "1.0.1-rc.11",
|
|
4
4
|
"author": "Wangsit FE Developer",
|
|
5
5
|
"description": "Fixed Asset Tagsamurai VueJS Component Library",
|
|
6
6
|
"type": "module",
|
|
@@ -12,10 +12,6 @@
|
|
|
12
12
|
"types": "./wangsvue-fats.d.ts",
|
|
13
13
|
"import": "./wangsvue-fats.es.js"
|
|
14
14
|
},
|
|
15
|
-
"./**/*": {
|
|
16
|
-
"types": "./*/index.d.ts",
|
|
17
|
-
"import": "./*/index.es.js"
|
|
18
|
-
},
|
|
19
15
|
"./style.css": "./style.css"
|
|
20
16
|
},
|
|
21
17
|
"dependencies": {
|
package/paginator/index.es.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as m, mergeModels as i, useModel as c, inject as w, createBlock as
|
|
1
|
+
import { defineComponent as m, mergeModels as i, useModel as c, inject as w, createBlock as g, openBlock as u, unref as p, mergeProps as f, withCtx as r, createVNode as t } from "vue";
|
|
2
2
|
import { s as k } from "../vendor/primevue/paginator/paginator.esm.es.js";
|
|
3
|
-
import a from "../icon/index.es.js";
|
|
3
|
+
import { _ as a } from "../icon/index.es.js";
|
|
4
4
|
const R = /* @__PURE__ */ m({
|
|
5
5
|
__name: "Paginator",
|
|
6
6
|
props: /* @__PURE__ */ i({
|
|
@@ -20,14 +20,14 @@ const R = /* @__PURE__ */ m({
|
|
|
20
20
|
}),
|
|
21
21
|
emits: /* @__PURE__ */ i(["page", "update:rows"], ["update:rows"]),
|
|
22
22
|
setup(l) {
|
|
23
|
-
const
|
|
24
|
-
return (
|
|
25
|
-
rows:
|
|
26
|
-
"onUpdate:rows":
|
|
27
|
-
}, p(d).paginator({ context: { totalRecords:
|
|
28
|
-
template:
|
|
29
|
-
"total-records":
|
|
30
|
-
onPage:
|
|
23
|
+
const n = c(l, "rows"), d = w("preset", {}).datatable;
|
|
24
|
+
return (o, e) => (u(), g(p(k), f({
|
|
25
|
+
rows: n.value,
|
|
26
|
+
"onUpdate:rows": e[0] || (e[0] = (s) => n.value = s)
|
|
27
|
+
}, p(d).paginator({ context: { totalRecords: o.totalRecords } }), {
|
|
28
|
+
template: o.template,
|
|
29
|
+
"total-records": o.totalRecords,
|
|
30
|
+
onPage: e[1] || (e[1] = (s) => o.$emit("page", s))
|
|
31
31
|
}), {
|
|
32
32
|
firstpagelinkicon: r(() => [
|
|
33
33
|
t(a, { icon: "round-keyboard-double-arrow-left" })
|
|
@@ -46,5 +46,5 @@ const R = /* @__PURE__ */ m({
|
|
|
46
46
|
}
|
|
47
47
|
});
|
|
48
48
|
export {
|
|
49
|
-
R as
|
|
49
|
+
R as _
|
|
50
50
|
};
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
const u = (s, l) => {
|
|
2
|
+
l.forEach((n) => {
|
|
3
|
+
const t = s.document.createElement("link");
|
|
4
|
+
t.setAttribute("rel", "stylesheet"), t.setAttribute("type", "text/css"), t.setAttribute("href", n), s.document.head.appendChild(t);
|
|
5
|
+
});
|
|
6
|
+
}, y = {
|
|
7
|
+
install(s, l = {}) {
|
|
8
|
+
s.config.globalProperties.$htmlToPaper = (n, t, a = () => {
|
|
9
|
+
}) => {
|
|
10
|
+
var r;
|
|
11
|
+
const o = {
|
|
12
|
+
name: "_blank",
|
|
13
|
+
specs: ["fullscreen=yes", "titlebar=yes", "scrollbars=yes"],
|
|
14
|
+
styles: [],
|
|
15
|
+
...l,
|
|
16
|
+
...t
|
|
17
|
+
}, d = ((r = o.specs) == null ? void 0 : r.join(",")) || "", c = document.getElementById(n);
|
|
18
|
+
if (!c) {
|
|
19
|
+
alert(`Element to print #${n} not found!`);
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
const e = window.open("", o.name, d);
|
|
23
|
+
return e && (e.document.write(`
|
|
24
|
+
<html>
|
|
25
|
+
<head>
|
|
26
|
+
<title>${document.title}</title>
|
|
27
|
+
</head>
|
|
28
|
+
<body>
|
|
29
|
+
${c.innerHTML}
|
|
30
|
+
</body>
|
|
31
|
+
</html>
|
|
32
|
+
`), u(e, o.styles || []), setTimeout(() => {
|
|
33
|
+
e.document.close(), e.focus(), e.print(), e.close(), a();
|
|
34
|
+
}, 1e3)), !0;
|
|
35
|
+
};
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
export {
|
|
39
|
+
y as V
|
|
40
|
+
};
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { inject as c
|
|
2
|
-
import { x as
|
|
3
|
-
import { d as
|
|
4
|
-
import { P as
|
|
5
|
-
|
|
6
|
-
const w = {
|
|
1
|
+
import { inject as c } from "vue";
|
|
2
|
+
import { x as m } from "../vendor/@wangs-ui/vue/dist/index.es.js";
|
|
3
|
+
import { d as g } from "../utils/object.util.es.js";
|
|
4
|
+
import { P as p } from "../vendor/primevue/config/config.esm.es.js";
|
|
5
|
+
const h = {
|
|
7
6
|
startsWith: "Starts with",
|
|
8
7
|
contains: "Contains",
|
|
9
8
|
notContains: "Not contains",
|
|
@@ -150,7 +149,7 @@ const w = {
|
|
|
150
149
|
}
|
|
151
150
|
}, u = {
|
|
152
151
|
locale: {
|
|
153
|
-
global:
|
|
152
|
+
global: h,
|
|
154
153
|
components: {
|
|
155
154
|
FieldWrapper: {
|
|
156
155
|
labelOptional: "(opsional)",
|
|
@@ -295,96 +294,52 @@ const w = {
|
|
|
295
294
|
formatUserName: !0
|
|
296
295
|
}
|
|
297
296
|
}
|
|
298
|
-
}, d = Symbol("WangsVue"),
|
|
299
|
-
const
|
|
300
|
-
if (!
|
|
297
|
+
}, d = Symbol("WangsVue"), x = (t) => {
|
|
298
|
+
const l = c(d);
|
|
299
|
+
if (!l)
|
|
301
300
|
throw new Error("WangsVue is not installed!");
|
|
302
|
-
return
|
|
303
|
-
},
|
|
304
|
-
const
|
|
301
|
+
return t ? l.getComponentConfig(t) : l.config;
|
|
302
|
+
}, b = (t, l) => g(t, l), P = (t = u, l = !0) => {
|
|
303
|
+
const r = l ? b(u, t) : t;
|
|
305
304
|
return {
|
|
306
|
-
install: (o,
|
|
307
|
-
var
|
|
308
|
-
const
|
|
309
|
-
...
|
|
310
|
-
...
|
|
311
|
-
preset:
|
|
305
|
+
install: (o, e) => {
|
|
306
|
+
var s;
|
|
307
|
+
const a = {
|
|
308
|
+
...r,
|
|
309
|
+
...e,
|
|
310
|
+
preset: e.preset ?? e.pt,
|
|
312
311
|
locale: {
|
|
313
|
-
...
|
|
314
|
-
...
|
|
312
|
+
...r.locale,
|
|
313
|
+
...e == null ? void 0 : e.locale,
|
|
315
314
|
components: {
|
|
316
|
-
...
|
|
317
|
-
...((
|
|
315
|
+
...r.locale.components,
|
|
316
|
+
...((s = e == null ? void 0 : e.locale) == null ? void 0 : s.components) || {}
|
|
318
317
|
}
|
|
319
318
|
},
|
|
320
319
|
defaultProps: {
|
|
321
|
-
...
|
|
322
|
-
...(
|
|
320
|
+
...r.defaultProps,
|
|
321
|
+
...(e == null ? void 0 : e.defaultProps) || {}
|
|
323
322
|
},
|
|
324
|
-
useToastConfig:
|
|
325
|
-
},
|
|
326
|
-
config:
|
|
327
|
-
getComponentConfig: (
|
|
328
|
-
defaultProps:
|
|
323
|
+
useToastConfig: r.useToastConfig
|
|
324
|
+
}, n = {
|
|
325
|
+
config: a,
|
|
326
|
+
getComponentConfig: (i) => ({
|
|
327
|
+
defaultProps: a.defaultProps[i] || {},
|
|
329
328
|
locale: {
|
|
330
|
-
...
|
|
331
|
-
global:
|
|
329
|
+
...a.locale.components[i] || {},
|
|
330
|
+
global: a.locale.global
|
|
332
331
|
}
|
|
333
332
|
})
|
|
334
333
|
};
|
|
335
|
-
o.config.globalProperties.$wangsvue =
|
|
334
|
+
o.config.globalProperties.$wangsvue = n, o.config.globalProperties.$preset = n.config.preset, o.provide(d, n), o.provide("preset", a.preset), o.provide("useToastConfig", a.useToastConfig), o.use(p, {
|
|
336
335
|
unstyled: !0,
|
|
337
|
-
pt:
|
|
338
|
-
locale:
|
|
339
|
-
}), o.use(
|
|
336
|
+
pt: a.preset,
|
|
337
|
+
locale: a.locale.global
|
|
338
|
+
}), o.use(m);
|
|
340
339
|
}
|
|
341
340
|
};
|
|
342
|
-
}
|
|
343
|
-
const o = r[a];
|
|
344
|
-
return o ? typeof o == "function" ? o() : Promise.resolve(o) : new Promise((t, l) => {
|
|
345
|
-
(typeof queueMicrotask == "function" ? queueMicrotask : setTimeout)(
|
|
346
|
-
l.bind(
|
|
347
|
-
null,
|
|
348
|
-
new Error(
|
|
349
|
-
"Unknown variable dynamic import: " + a + (a.split("/").length !== n ? ". Note that variables only represent file names one level deep." : "")
|
|
350
|
-
)
|
|
351
|
-
)
|
|
352
|
-
);
|
|
353
|
-
});
|
|
354
|
-
}, D = /* @__PURE__ */ p({
|
|
355
|
-
__name: "Animation",
|
|
356
|
-
props: {
|
|
357
|
-
animation: {},
|
|
358
|
-
autoplay: { type: Boolean, default: !0 },
|
|
359
|
-
loop: { type: Boolean, default: !0 }
|
|
360
|
-
},
|
|
361
|
-
setup(r) {
|
|
362
|
-
const a = r, { defaultProps: n } = L("Animation"), o = m(() => y(a, n)), t = g(null);
|
|
363
|
-
h(async () => {
|
|
364
|
-
const s = await S(/* @__PURE__ */ Object.assign({ "../../assets/lottie/admin/loading-page.lottie": () => import("../assets/lottiejs/loading-page.es.js").then((e) => e.l), "../../assets/lottie/admin/loading-table.lottie": () => import("../assets/lottiejs/loading-table.es.js").then((e) => e.l), "../../assets/lottie/admin/no-data.lottie": () => import("../assets/lottiejs/no-data.es.js").then((e) => e.n), "../../assets/lottie/supplyasset/loading-page.lottie": () => import("../assets/lottiejs/loading-page.es.js").then((e) => e.a), "../../assets/lottie/supplyasset/loading-table.lottie": () => import("../assets/lottiejs/loading-table.es.js").then((e) => e.a), "../../assets/lottie/supplyasset/no-data.lottie": () => import("../assets/lottiejs/no-data.es.js").then((e) => e.a), "../../assets/lottie/workspace/loading-page.lottie": () => import("../assets/lottiejs/loading-page.es.js").then((e) => e.b), "../../assets/lottie/workspace/loading-plane.lottie": () => import("../assets/lottiejs/loading-plane.es.js"), "../../assets/lottie/workspace/loading-table.lottie": () => import("../assets/lottiejs/loading-table.es.js").then((e) => e.b), "../../assets/lottie/workspace/no-data.lottie": () => import("../assets/lottiejs/no-data.es.js").then((e) => e.b) }), `../../assets/lottie/${o.value.libPath}/${a.animation}.lottie`, 6), { DotLottie: i } = await l();
|
|
365
|
-
t.value && new i({
|
|
366
|
-
canvas: t.value,
|
|
367
|
-
src: s.default,
|
|
368
|
-
autoplay: a.autoplay,
|
|
369
|
-
loop: a.loop
|
|
370
|
-
});
|
|
371
|
-
});
|
|
372
|
-
const l = () => import(
|
|
373
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
374
|
-
// @ts-ignore
|
|
375
|
-
"https://cdn.jsdelivr.net/npm/@lottiefiles/dotlottie-web@0.38.2/+esm"
|
|
376
|
-
);
|
|
377
|
-
return (s, i) => (f(), b("div", v({ "data-wv-name": "animation" }, s.$attrs), [
|
|
378
|
-
M("canvas", {
|
|
379
|
-
ref_key: "canvasRef",
|
|
380
|
-
ref: t,
|
|
381
|
-
style: { width: "100%", height: "100%" }
|
|
382
|
-
}, null, 512)
|
|
383
|
-
], 16));
|
|
384
|
-
}
|
|
385
|
-
});
|
|
341
|
+
};
|
|
386
342
|
export {
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
L as u
|
|
343
|
+
P as c,
|
|
344
|
+
x as u
|
|
390
345
|
};
|
|
@@ -0,0 +1,103 @@
|
|
|
1
|
+
import { AxiosResponse } from 'axios';
|
|
2
|
+
import { App, Ref } from 'vue';
|
|
3
|
+
export type Locale = string;
|
|
4
|
+
export interface LanguageOption {
|
|
5
|
+
/**
|
|
6
|
+
* ISO 639-1 language code (e.g., "en" for English, "fr" for French).
|
|
7
|
+
*/
|
|
8
|
+
isoCode?: string;
|
|
9
|
+
/**
|
|
10
|
+
* The name of the language in English (e.g., "English", "Français").
|
|
11
|
+
*/
|
|
12
|
+
name: string;
|
|
13
|
+
/**
|
|
14
|
+
* The URL of the country's flag image.
|
|
15
|
+
* Flags are sourced from https://flagcdn.com and are typically in SVG format for high-quality resolution.
|
|
16
|
+
*/
|
|
17
|
+
flag?: string;
|
|
18
|
+
}
|
|
19
|
+
export interface I18n {
|
|
20
|
+
/**
|
|
21
|
+
* Locale message translation
|
|
22
|
+
*
|
|
23
|
+
* @param key - The translation key
|
|
24
|
+
* @param params - A values of named interpolation
|
|
25
|
+
* @param args - Positional interpolation values
|
|
26
|
+
*
|
|
27
|
+
* @returns translation message
|
|
28
|
+
* @example `t('Hello {user}!', { user: 'John Doe' })` - returns: 'Hello John Doe!'
|
|
29
|
+
* @example `t('Hello %s! I am %s.', "John Doe", "Peter Smith")` - returns: 'Hello John Doe! I am Peter Smith.'
|
|
30
|
+
*/
|
|
31
|
+
t: {
|
|
32
|
+
(key: string, params: Record<string, any>): string;
|
|
33
|
+
(key: string, ...args: (string | number | boolean)[]): string;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Change the locale dynamically
|
|
37
|
+
*
|
|
38
|
+
* @param newLocale - The locale to switch to
|
|
39
|
+
*/
|
|
40
|
+
setLocale: (newLocale: Locale) => Promise<void>;
|
|
41
|
+
/**
|
|
42
|
+
* Get the current locale
|
|
43
|
+
*
|
|
44
|
+
* @returns Current locale
|
|
45
|
+
*/
|
|
46
|
+
locale: Ref<Locale>;
|
|
47
|
+
/**
|
|
48
|
+
* Service methods handle fetch requests
|
|
49
|
+
*/
|
|
50
|
+
service?: I18nService;
|
|
51
|
+
}
|
|
52
|
+
type MessageMap = Record<string, string>;
|
|
53
|
+
export interface I18nService {
|
|
54
|
+
/**
|
|
55
|
+
* Fetch all translation messages for a specific locale.
|
|
56
|
+
* @param locale The locale code (e.g., 'en', 'id').
|
|
57
|
+
* @returns A promise resolving to a key-value record of messages.
|
|
58
|
+
*/
|
|
59
|
+
getMessages(locale: string): Promise<
|
|
60
|
+
AxiosResponse<{
|
|
61
|
+
data: MessageMap;
|
|
62
|
+
}>
|
|
63
|
+
>;
|
|
64
|
+
/**
|
|
65
|
+
* Fetch all available lang options for LanguageDropdown and LanguageSwitcher
|
|
66
|
+
*
|
|
67
|
+
* @returns Promise Array of options
|
|
68
|
+
*/
|
|
69
|
+
getLanguageOptions(): Promise<LanguageOption[]>;
|
|
70
|
+
/**
|
|
71
|
+
* Fetch single lang option meta data
|
|
72
|
+
*
|
|
73
|
+
* @param locale The locale code (e.g., 'en', 'id').
|
|
74
|
+
* @returns Promise LanguageMeta
|
|
75
|
+
*/
|
|
76
|
+
getLanguageOptionMeta(locale: string): Promise<LanguageOption>;
|
|
77
|
+
/**
|
|
78
|
+
* Translate a specific text to the target locale.
|
|
79
|
+
* @param key Unique translation key.
|
|
80
|
+
* @param locale Target locale code.
|
|
81
|
+
* @returns A promise resolving to the translated string.
|
|
82
|
+
*/
|
|
83
|
+
translateText(key: string, locale: string): Promise<string>;
|
|
84
|
+
}
|
|
85
|
+
export declare const useI18n: () => I18n;
|
|
86
|
+
declare const i18n: {
|
|
87
|
+
install: (app: App) => void;
|
|
88
|
+
};
|
|
89
|
+
export declare const createI18nWithExtension: (
|
|
90
|
+
service: I18nService,
|
|
91
|
+
) => typeof i18n;
|
|
92
|
+
export default i18n;
|
|
93
|
+
declare module 'vue' {
|
|
94
|
+
interface ComponentCustomProperties {
|
|
95
|
+
$i18n: I18n;
|
|
96
|
+
$t: I18n['t'];
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
declare global {
|
|
100
|
+
interface Window {
|
|
101
|
+
i18n: I18n;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
import { shallowRef as P, shallowReactive as I, inject as M } from "vue";
|
|
2
|
+
import { u as b } from "../assetinfo/index.es.js";
|
|
3
|
+
const n = P(), u = "messages";
|
|
4
|
+
let r;
|
|
5
|
+
const f = () => {
|
|
6
|
+
try {
|
|
7
|
+
const t = localStorage.getItem(u);
|
|
8
|
+
return t ? JSON.parse(t) : {};
|
|
9
|
+
} catch {
|
|
10
|
+
return {};
|
|
11
|
+
}
|
|
12
|
+
}, g = I(f()), a = new Proxy(g, {
|
|
13
|
+
get: (t, e) => {
|
|
14
|
+
const l = f()[e];
|
|
15
|
+
return g[e] = l, l;
|
|
16
|
+
},
|
|
17
|
+
set: (t, e, s) => (g[e] = s, m(g), !0)
|
|
18
|
+
}), m = (t) => {
|
|
19
|
+
localStorage.setItem(u, JSON.stringify(t));
|
|
20
|
+
}, y = async (t) => {
|
|
21
|
+
var e;
|
|
22
|
+
if (!(t in a)) {
|
|
23
|
+
const { setLoading: s } = b();
|
|
24
|
+
s(!0, "Loading language package...");
|
|
25
|
+
let l = {};
|
|
26
|
+
try {
|
|
27
|
+
const { data: c } = await (((e = r == null ? void 0 : r.getMessages) == null ? void 0 : e.call(r, t)) ?? {});
|
|
28
|
+
l = c.data;
|
|
29
|
+
} catch {
|
|
30
|
+
} finally {
|
|
31
|
+
s(!1);
|
|
32
|
+
}
|
|
33
|
+
return l;
|
|
34
|
+
}
|
|
35
|
+
return a[t];
|
|
36
|
+
}, d = (t, ...e) => {
|
|
37
|
+
var c;
|
|
38
|
+
if (!n.value && !localStorage.lang) return t;
|
|
39
|
+
let s = (c = a[n.value]) == null ? void 0 : c[t];
|
|
40
|
+
const l = s === t && n.value !== "en";
|
|
41
|
+
if ((!s || l) && (s = t, r == null || r.translateText(t, n.value).then((o) => {
|
|
42
|
+
a[n.value] ? a[n.value] = {
|
|
43
|
+
...a[n.value],
|
|
44
|
+
[t]: o
|
|
45
|
+
} : a[n.value] = {
|
|
46
|
+
[t]: o
|
|
47
|
+
};
|
|
48
|
+
}).catch((o) => {
|
|
49
|
+
console.error("Translation error:", o);
|
|
50
|
+
})), e.length === 1 && typeof e[0] == "object" && !Array.isArray(e[0])) {
|
|
51
|
+
const o = e[0];
|
|
52
|
+
return Object.keys(o).reduce(
|
|
53
|
+
(h, i) => h.replaceAll(`{${i}}`, o[i]),
|
|
54
|
+
s
|
|
55
|
+
);
|
|
56
|
+
}
|
|
57
|
+
if (e.length > 0) {
|
|
58
|
+
let o = 0;
|
|
59
|
+
return s.replace(/%s/g, () => String(e[o++] ?? ""));
|
|
60
|
+
}
|
|
61
|
+
return s;
|
|
62
|
+
}, v = async (t) => {
|
|
63
|
+
if (n.value !== t) {
|
|
64
|
+
const e = await y(t);
|
|
65
|
+
n.value = t, a[t] = e, localStorage.lang = t;
|
|
66
|
+
}
|
|
67
|
+
}, O = () => (M("i18n") || console.error("I18n Plugin not installed!"), {
|
|
68
|
+
t: d,
|
|
69
|
+
locale: n,
|
|
70
|
+
setLocale: v,
|
|
71
|
+
service: r
|
|
72
|
+
}), S = () => {
|
|
73
|
+
const t = {
|
|
74
|
+
t: d,
|
|
75
|
+
locale: n,
|
|
76
|
+
setLocale: v,
|
|
77
|
+
service: r
|
|
78
|
+
};
|
|
79
|
+
return {
|
|
80
|
+
install(e) {
|
|
81
|
+
e.config.globalProperties.$i18n = t, e.config.globalProperties.$t = t.t, e.provide("i18n", t);
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
}, T = (t) => (r = t, S());
|
|
85
|
+
export {
|
|
86
|
+
T as c,
|
|
87
|
+
O as u
|
|
88
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as u, u as
|
|
1
|
+
import { a as u, u as a } from "../vendor/vee-validate/dist/vee-validate.esm.es.js";
|
|
2
2
|
const l = () => {
|
|
3
3
|
const { values: e, handleSubmit: s, setValues: t, setFieldValue: o, errors: r } = u();
|
|
4
4
|
return {
|
|
@@ -8,8 +8,8 @@ const l = () => {
|
|
|
8
8
|
setFieldValue: o,
|
|
9
9
|
errors: r
|
|
10
10
|
};
|
|
11
|
-
}, c = (e, s, t) =>
|
|
11
|
+
}, c = (e, s, t) => a(e, s, t);
|
|
12
12
|
export {
|
|
13
|
-
c as
|
|
14
|
-
l as
|
|
13
|
+
c as a,
|
|
14
|
+
l as u
|
|
15
15
|
};
|