@duxweb/dvha-pro 1.0.18 → 1.0.20

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.
Files changed (147) hide show
  1. package/dist/cjs/component.cjs +1 -1
  2. package/dist/cjs/components/card/card.cjs +1 -1
  3. package/dist/cjs/components/chart/echart.cjs +1 -1
  4. package/dist/cjs/components/code/code.cjs +1 -0
  5. package/dist/cjs/components/crop/imageCrop.cjs +1 -1
  6. package/dist/cjs/components/data/dynamicSelect.cjs +1 -1
  7. package/dist/cjs/components/data/selectModal.cjs +1 -1
  8. package/dist/cjs/components/drawer/drawer.cjs +1 -1
  9. package/dist/cjs/components/drawer/drawerPage.cjs +1 -1
  10. package/dist/cjs/components/form/formItem.cjs +1 -1
  11. package/dist/cjs/components/form/formLayout.cjs +1 -1
  12. package/dist/cjs/components/form/modalForm.cjs +1 -1
  13. package/dist/cjs/components/form/pageForm.cjs +1 -1
  14. package/dist/cjs/components/form/settingForm.cjs +1 -1
  15. package/dist/cjs/components/icon/icon.cjs +1 -1
  16. package/dist/cjs/components/layout/filter.cjs +1 -1
  17. package/dist/cjs/components/layout/filterLayout.cjs +1 -0
  18. package/dist/cjs/components/layout/list.cjs +1 -1
  19. package/dist/cjs/components/layout/table.cjs +1 -1
  20. package/dist/cjs/components/level/level.cjs +1 -1
  21. package/dist/cjs/components/modal/modal.cjs +1 -1
  22. package/dist/cjs/components/modal/modalPage.cjs +1 -1
  23. package/dist/cjs/components/panel/collapse.cjs +1 -0
  24. package/dist/cjs/components/panel/setting.cjs +1 -1
  25. package/dist/cjs/components/status/listEmpty.cjs +1 -0
  26. package/dist/cjs/components/table/table.cjs +1 -0
  27. package/dist/cjs/components/table/tablePage.cjs +1 -1
  28. package/dist/cjs/components/tree/treeFilter.cjs +1 -1
  29. package/dist/cjs/components/upload/config.cjs +1 -0
  30. package/dist/cjs/components/upload/file.cjs +1 -1
  31. package/dist/cjs/components/upload/image.cjs +1 -1
  32. package/dist/cjs/components/upload/manage/item.cjs +1 -1
  33. package/dist/cjs/components/upload/manager.cjs +1 -1
  34. package/dist/cjs/dvha-pro.css +1 -1
  35. package/dist/cjs/hooks/action.cjs +1 -1
  36. package/dist/cjs/hooks/dialog.cjs +1 -1
  37. package/dist/cjs/hooks/drawer.cjs +1 -1
  38. package/dist/cjs/hooks/modal.cjs +1 -1
  39. package/dist/cjs/hooks/table/image.cjs +1 -1
  40. package/dist/cjs/hooks/table/media.cjs +1 -1
  41. package/dist/cjs/hooks/table.cjs +1 -1
  42. package/dist/cjs/index.cjs +1 -1
  43. package/dist/cjs/langs/en-US.json.cjs +1 -1
  44. package/dist/cjs/langs/zh-CN.json.cjs +1 -1
  45. package/dist/cjs/pages/authLayout.cjs +1 -1
  46. package/dist/cjs/pages/layout/page.cjs +1 -1
  47. package/dist/cjs/pages/login.cjs +1 -1
  48. package/dist/cjs/pages/menu/avatar.cjs +1 -1
  49. package/dist/cjs/pages/menu/button.cjs +1 -1
  50. package/dist/cjs/pages/menu/cmd.cjs +1 -1
  51. package/dist/cjs/pages/menu/main.cjs +1 -1
  52. package/dist/cjs/pages/menu/mobile.cjs +1 -1
  53. package/dist/cjs/pages/page.cjs +1 -1
  54. package/dist/cjs/pages/page404.cjs +1 -1
  55. package/dist/cjs/pages/pageStatus.cjs +1 -1
  56. package/dist/cjs/theme/naiveTheme.cjs +1 -1
  57. package/dist/cjs/theme/uno.css.cjs +23 -7
  58. package/dist/esm/component.js +36 -34
  59. package/dist/esm/components/card/card.js +6 -6
  60. package/dist/esm/components/chart/echart.js +17 -6
  61. package/dist/esm/components/code/code.js +53 -0
  62. package/dist/esm/components/crop/imageCrop.js +37 -26
  63. package/dist/esm/components/data/dynamicSelect.js +29 -18
  64. package/dist/esm/components/data/selectModal.js +49 -38
  65. package/dist/esm/components/drawer/drawer.js +17 -28
  66. package/dist/esm/components/drawer/drawerPage.js +54 -17
  67. package/dist/esm/components/form/formItem.js +17 -17
  68. package/dist/esm/components/form/formLayout.js +8 -8
  69. package/dist/esm/components/form/modalForm.js +44 -35
  70. package/dist/esm/components/form/pageForm.js +81 -43
  71. package/dist/esm/components/form/settingForm.js +28 -17
  72. package/dist/esm/components/icon/icon.js +23 -12
  73. package/dist/esm/components/layout/filter.js +15 -11
  74. package/dist/esm/components/layout/filterLayout.js +34 -0
  75. package/dist/esm/components/layout/list.js +211 -161
  76. package/dist/esm/components/layout/table.js +217 -186
  77. package/dist/esm/components/level/level.js +28 -17
  78. package/dist/esm/components/modal/modal.js +9 -9
  79. package/dist/esm/components/modal/modalPage.js +2 -2
  80. package/dist/esm/components/panel/collapse.js +49 -0
  81. package/dist/esm/components/panel/setting.js +3 -3
  82. package/dist/esm/components/status/listEmpty.js +26 -0
  83. package/dist/esm/components/table/table.js +110 -0
  84. package/dist/esm/components/table/tablePage.js +24 -18
  85. package/dist/esm/components/tree/treeFilter.js +44 -39
  86. package/dist/esm/components/upload/config.js +32 -0
  87. package/dist/esm/components/upload/file.js +142 -116
  88. package/dist/esm/components/upload/image.js +95 -66
  89. package/dist/esm/components/upload/manage/item.js +17 -6
  90. package/dist/esm/components/upload/manager.js +202 -164
  91. package/dist/esm/dvha-pro.css +1 -1
  92. package/dist/esm/hooks/action.js +77 -75
  93. package/dist/esm/hooks/dialog.js +13 -2
  94. package/dist/esm/hooks/drawer.js +13 -2
  95. package/dist/esm/hooks/modal.js +13 -2
  96. package/dist/esm/hooks/table/image.js +21 -10
  97. package/dist/esm/hooks/table/media.js +20 -9
  98. package/dist/esm/hooks/table.js +16 -16
  99. package/dist/esm/index.js +174 -164
  100. package/dist/esm/langs/en-US.json.js +5 -3
  101. package/dist/esm/langs/zh-CN.json.js +5 -3
  102. package/dist/esm/pages/authLayout.js +19 -8
  103. package/dist/esm/pages/layout/page.js +17 -6
  104. package/dist/esm/pages/login.js +40 -29
  105. package/dist/esm/pages/menu/avatar.js +97 -86
  106. package/dist/esm/pages/menu/button.js +23 -12
  107. package/dist/esm/pages/menu/cmd.js +45 -34
  108. package/dist/esm/pages/menu/main.js +40 -27
  109. package/dist/esm/pages/menu/mobile.js +13 -2
  110. package/dist/esm/pages/page.js +1 -1
  111. package/dist/esm/pages/page404.js +20 -9
  112. package/dist/esm/pages/pageStatus.js +31 -15
  113. package/dist/esm/theme/naiveTheme.js +6 -6
  114. package/dist/esm/theme/uno.css.js +23 -7
  115. package/dist/types/components/code/code.d.ts +44 -0
  116. package/dist/types/components/code/index.d.ts +1 -0
  117. package/dist/types/components/drawer/drawer.d.ts +2 -0
  118. package/dist/types/components/drawer/drawerPage.d.ts +20 -1
  119. package/dist/types/components/form/formItem.d.ts +2 -2
  120. package/dist/types/components/form/formLayout.d.ts +3 -3
  121. package/dist/types/components/form/modalForm.d.ts +3 -3
  122. package/dist/types/components/form/pageForm.d.ts +12 -0
  123. package/dist/types/components/index.d.ts +1 -0
  124. package/dist/types/components/layout/filterLayout.d.ts +32 -0
  125. package/dist/types/components/layout/index.d.ts +1 -0
  126. package/dist/types/components/layout/list.d.ts +7 -1
  127. package/dist/types/components/layout/table.d.ts +10 -1
  128. package/dist/types/components/list/card.d.ts +6 -0
  129. package/dist/types/components/list/list.d.ts +6 -0
  130. package/dist/types/components/panel/collapse.d.ts +14 -0
  131. package/dist/types/components/panel/index.d.ts +1 -0
  132. package/dist/types/components/select/cardSelect.d.ts +1 -1
  133. package/dist/types/components/status/index.d.ts +1 -0
  134. package/dist/types/components/status/listEmpty.d.ts +11 -0
  135. package/dist/types/components/table/index.d.ts +1 -0
  136. package/dist/types/components/table/table.d.ts +6552 -0
  137. package/dist/types/components/table/tablePage.d.ts +9 -0
  138. package/dist/types/components/tree/treeFilter.d.ts +13 -12
  139. package/dist/types/components/upload/config.d.ts +13 -0
  140. package/dist/types/components/upload/file.d.ts +4 -0
  141. package/dist/types/components/upload/image.d.ts +30 -2
  142. package/dist/types/components/upload/manager.d.ts +4 -0
  143. package/dist/types/hooks/drawer.d.ts +1 -0
  144. package/dist/types/hooks/table/types.d.ts +1 -0
  145. package/dist/types/main.d.ts +6 -0
  146. package/dist/types/pages/pageStatus.d.ts +11 -1
  147. package/package.json +7 -5
@@ -1,17 +1,20 @@
1
- import { defineComponent as $, toRef as j, ref as D, computed as m, reactive as ee, watch as te, onMounted as ie, createVNode as e, h as U, mergeProps as ae } from "vue";
2
- import { useI18n as ne, useExtendList as le, useJsonSchema as E } from "@duxweb/dvha-core";
3
- import { useWindowSize as re } from "@vueuse/core";
4
- import { NTooltip as f, NCheckbox as q, NTabs as ce, NTab as ue, NButton as d, NPopover as oe, NSpin as de, NProgress as pe, NPagination as me } from "naive-ui";
5
- import { useAction as fe } from "../../hooks/action.js";
1
+ import { defineComponent as ie, toRef as U, ref as T, computed as m, reactive as S, watch as le, onMounted as ne, createVNode as e, h as O, mergeProps as re, isVNode as oe } from "vue";
2
+ import { useI18n as ue, useExtendList as ce, useJsonSchema as E } from "@duxweb/dvha-core";
3
+ import { useWindowSize as de } from "@vueuse/core";
4
+ import { NTooltip as s, NCheckbox as q, NTabs as pe, NTab as me, NButton as d, NSpin as fe, NProgress as ge, NPagination as he, NModal as ve, NDrawer as I } from "naive-ui";
5
+ import { useAction as se } from "../../hooks/action.js";
6
6
  import "@overlastic/vue";
7
7
  import "clsx";
8
8
  import "vue-echarts";
9
9
  import "vue-cropper";
10
+ import be from "../modal/modalPage.js";
10
11
  import "jinrishici";
11
12
  import "lodash-es";
12
13
  import "vue-draggable-plus";
14
+ import { DuxDrawerPage as M } from "../drawer/drawerPage.js";
13
15
  import "aieditor";
14
16
  import "vee-validate";
17
+ import "vue-router";
15
18
  import "@vee-validate/i18n";
16
19
  import "colorizr";
17
20
  import "echarts";
@@ -21,21 +24,34 @@ import "@unocss/preset-typography";
21
24
  import "unocss/preset-wind4";
22
25
  import "@vee-validate/i18n/dist/locale/en.json";
23
26
  import "@vee-validate/i18n/dist/locale/zh_CN.json";
24
- import "vue-router";
25
27
  import "vue-command-palette";
26
28
  import "@duxweb/dvha-naiveui";
27
- import { DuxPage as ge } from "../../pages/page.js";
29
+ import { DuxPage as xe } from "../../pages/page.js";
28
30
  import "../../pages/page404.js";
29
- import { DuxPageEmpty as ve } from "../../pages/pageEmpty.js";
31
+ import { DuxPageEmpty as we } from "../../pages/pageEmpty.js";
30
32
  import "@iconify-json/tabler/icons.json";
31
- import { DuxTableFilter as he } from "./filter.js";
32
- import { DuxTableTools as be } from "./tools.js";
33
+ import { DuxTableFilter as ye } from "./filter.js";
34
+ import { DuxFilterLayout as Se } from "./filterLayout.js";
35
+ import { DuxTableTools as ke } from "./tools.js";
33
36
  import "mime";
37
+ import "vue3-ace-editor";
38
+ import "ace-builds/src-noconflict/mode-vue";
39
+ import "ace-builds/src-noconflict/mode-javascript";
40
+ import "ace-builds/src-noconflict/mode-html";
41
+ import "ace-builds/src-noconflict/mode-json";
42
+ import "ace-builds/src-noconflict/mode-json5";
43
+ import "ace-builds/src-noconflict/theme-tomorrow_night";
44
+ import "ace-builds/src-noconflict/theme-tomorrow";
45
+ import "ace-builds/src-noconflict/ext-searchbox";
46
+ import "ace-builds/src-noconflict/ext-language_tools";
47
+ import "ace-builds/src-noconflict/mode-snippets";
34
48
  import "dayjs";
35
- import { useDrawer as xe } from "../../hooks/drawer.js";
36
49
  import "@tanstack/vue-query";
37
50
  import "pinia";
38
- const it = /* @__PURE__ */ $({
51
+ function Ce(i) {
52
+ return typeof i == "function" || Object.prototype.toString.call(i) === "[object Object]" && !oe(i);
53
+ }
54
+ const yt = /* @__PURE__ */ ie({
39
55
  name: "DuxListLayout",
40
56
  props: {
41
57
  rowKey: {
@@ -76,111 +92,116 @@ const it = /* @__PURE__ */ $({
76
92
  sideRightTitle: {
77
93
  type: String,
78
94
  default: ""
95
+ },
96
+ hookListProps: {
97
+ type: Object
79
98
  }
80
99
  },
81
100
  setup(i, {
82
101
  slots: t
83
102
  }) {
84
- var P;
85
- const I = j(i.filter || {}), {
103
+ var F;
104
+ const V = U(i.filter || {}), {
86
105
  t: r
87
- } = ne(), {
88
- renderAction: O
89
- } = fe(), W = j(i.pagination && typeof i.pagination == "object" ? i.pagination : {
106
+ } = ue(), {
107
+ renderAction: W
108
+ } = se(), B = U(i.pagination && typeof i.pagination == "object" ? i.pagination : {
90
109
  page: 1,
91
110
  pageSize: 20
92
- }), g = D({}), B = () => {
93
- Object.assign(g.value, I.value);
94
- }, a = le({
111
+ }), b = T({}), J = () => {
112
+ Object.assign(b.value, V.value);
113
+ }, l = ce({
95
114
  path: i.path,
96
- filters: g.value,
97
- pagination: W.value
115
+ filters: b.value,
116
+ pagination: B.value,
117
+ ...i.hookListProps
98
118
  }), {
99
- meta: h,
100
- list: y,
101
- isLoading: s,
102
- autoRefetch: V,
103
- autoCountdown: w,
104
- onAutoRefetch: J,
105
- isExporting: b,
106
- isExportingRows: M,
107
- isImporting: S,
108
- onExport: K,
109
- onExportRows: Q,
110
- onImport: G
111
- } = a, H = m(() => ({
112
- page: a.page.value,
113
- pageSize: a.pageSize.value,
114
- pageCount: a.pageCount.value,
115
- pageSizes: a.pageSizes,
119
+ meta: w,
120
+ list: k,
121
+ isLoading: C,
122
+ autoRefetch: _,
123
+ autoCountdown: L,
124
+ onAutoRefetch: K,
125
+ isExporting: Q,
126
+ isExportingRows: G,
127
+ isImporting: z,
128
+ onExport: H,
129
+ onExportRows: X,
130
+ onImport: Y
131
+ } = l, Z = m(() => ({
132
+ page: l.page.value,
133
+ pageSize: l.pageSize.value,
134
+ pageCount: l.pageCount.value,
135
+ pageSizes: l.pageSizes,
116
136
  pageSlot: 5,
117
- onUpdatePage: a.onUpdatePage,
118
- onUpdatePageSize: a.onUpdatePageSize,
137
+ onUpdatePage: l.onUpdatePage,
138
+ onUpdatePageSize: l.onUpdatePageSize,
119
139
  showSizePicker: !0,
120
140
  showQuickJumper: !0
121
- })), k = ee({
122
- show: !1,
123
- collapse: !1
124
- }), v = D(((P = i.filterSchema) == null ? void 0 : P.length) || 0), {
141
+ })), g = S({
142
+ show: !1
143
+ }), h = S({
144
+ show: !1
145
+ }), v = S({
146
+ show: !1
147
+ }), x = T(((F = i.filterSchema) == null ? void 0 : F.length) || 0), {
125
148
  width: u
126
- } = re(), C = () => {
149
+ } = de(), P = () => {
127
150
  var p;
128
151
  if (!((p = i.filterSchema) != null && p.length)) return 0;
129
- const l = i.filterSchema.length;
130
- if (l <= 3)
131
- return l;
132
- const o = u.value || 1024;
133
- let c = 3;
134
- return o >= 1280 ? c = 4 : o >= 1024 ? c = 3 : o >= 768 ? c = 2 : c = 1, Math.min(l, c);
152
+ const n = i.filterSchema.length;
153
+ if (n <= 3)
154
+ return n;
155
+ const c = u.value || 1024;
156
+ let o = 3;
157
+ return c >= 1280 ? o = 4 : c >= 1024 ? o = 3 : c >= 768 ? o = 2 : o = 1, Math.min(n, o);
135
158
  };
136
- te(u, () => {
137
- v.value = C();
138
- }), ie(() => {
139
- v.value = C();
159
+ le(u, () => {
160
+ x.value = P();
161
+ }), ne(() => {
162
+ x.value = P();
140
163
  });
141
- const X = m(() => (i.filterSchema || []).slice(0, v.value)), z = m(() => (i.filterSchema || []).slice(v.value)), Y = m(() => z.value.length > 0), R = (l) => l.map((o) => {
164
+ const $ = m(() => (i.filterSchema || []).slice(0, x.value)), R = m(() => (i.filterSchema || []).slice(x.value)), ee = m(() => R.value.length > 0), A = (n) => n.map((c) => {
142
165
  const {
143
- title: c,
166
+ title: o,
144
167
  ...p
145
- } = o;
168
+ } = c;
146
169
  return {
147
- tag: he,
170
+ tag: ye,
148
171
  attrs: {
149
- label: c,
172
+ label: o,
150
173
  class: "flex-1 min-w-0"
151
174
  },
152
175
  children: p
153
176
  };
154
177
  }), {
155
- render: Z
178
+ render: te
156
179
  } = E({
157
- data: m(() => R(X.value))
180
+ data: m(() => A($.value))
158
181
  }), {
159
- render: _
182
+ render: ae
160
183
  } = E({
161
- data: m(() => R(z.value))
162
- }), x = m(() => ({
163
- import: !0,
184
+ data: m(() => A(R.value))
185
+ }), y = m(() => ({
186
+ import: !1,
164
187
  export: !0,
165
188
  refresh: !0,
166
189
  ...i.tools
167
- })), {
168
- show: A
169
- } = xe();
170
- return () => e(ge, {
190
+ }));
191
+ return () => e(xe, {
171
192
  padding: !1,
172
193
  scrollbar: !1
173
194
  }, {
174
195
  sideLeft: () => {
175
- var l;
176
- return t != null && t.sideLeft && u.value >= 1024 ? (l = t == null ? void 0 : t.sideLeft) == null ? void 0 : l.call(t) : void 0;
196
+ var n;
197
+ return t != null && t.sideLeft && u.value >= 1024 ? (n = t == null ? void 0 : t.sideLeft) == null ? void 0 : n.call(t) : void 0;
177
198
  },
178
199
  sideRight: () => {
179
- var l;
180
- return t != null && t.sideRight && u.value >= 1024 ? (l = t == null ? void 0 : t.sideRight) == null ? void 0 : l.call(t) : void 0;
200
+ var n;
201
+ return t != null && t.sideRight && u.value >= 1024 ? (n = t == null ? void 0 : t.sideRight) == null ? void 0 : n.call(t) : void 0;
181
202
  },
182
203
  default: () => {
183
- var l, o, c, p, L, F, N;
204
+ var n, c, o, p, j, N, D;
184
205
  return e("div", {
185
206
  class: "flex flex-col h-full relative"
186
207
  }, [e("div", {
@@ -189,32 +210,32 @@ const it = /* @__PURE__ */ $({
189
210
  class: "flex flex-col lg:flex-row lg:items-center gap-2"
190
211
  }, [i.checkable && e("div", {
191
212
  class: "hidden lg:flex items-center pl-2"
192
- }, [e(f, null, {
213
+ }, [e(s, null, {
193
214
  trigger: () => e("div", {
194
215
  class: "flex items-center"
195
216
  }, [e(q, {
196
- checked: a.isAllChecked.value,
197
- indeterminate: a.isIndeterminate.value,
198
- onUpdateChecked: a.toggleSelectAll
217
+ checked: l.isAllChecked.value,
218
+ indeterminate: l.isIndeterminate.value,
219
+ onUpdateChecked: l.toggleSelectAll
199
220
  }, null)]),
200
221
  default: () => r("components.list.selectAll")
201
- })]), i.tabs && e("div", null, [e(ce, {
222
+ })]), i.tabs && e("div", null, [e(pe, {
202
223
  type: "segment",
203
224
  size: "small",
204
225
  style: {
205
226
  "--n-tab-padding": "4px 10px"
206
227
  },
207
- "default-value": (o = (l = i.tabs) == null ? void 0 : l[0]) == null ? void 0 : o.value,
208
- value: (c = g.value) == null ? void 0 : c.tab,
209
- onUpdateValue: (n) => {
210
- g.value.tab = n;
228
+ "default-value": (c = (n = i.tabs) == null ? void 0 : n[0]) == null ? void 0 : c.value,
229
+ value: (o = b.value) == null ? void 0 : o.tab,
230
+ onUpdateValue: (a) => {
231
+ b.value.tab = a;
211
232
  }
212
233
  }, {
213
234
  default: () => {
214
- var n;
215
- return [(n = i.tabs) == null ? void 0 : n.map((T) => e(ue, {
216
- name: T.value,
217
- tab: T.label
235
+ var a;
236
+ return [(a = i.tabs) == null ? void 0 : a.map((f) => e(me, {
237
+ name: f.value,
238
+ tab: f.label
218
239
  }, null))];
219
240
  }
220
241
  })]), e("div", {
@@ -222,17 +243,8 @@ const it = /* @__PURE__ */ $({
222
243
  }, [(t == null ? void 0 : t.sideLeft) && u.value < 1024 && e(d, {
223
244
  class: "flex-none",
224
245
  secondary: !0,
225
- loading: b.value,
226
246
  onClick: () => {
227
- A({
228
- title: i.sideLeftTitle,
229
- component: () => {
230
- var n;
231
- return e("div", null, [(n = t == null ? void 0 : t.sideLeft) == null ? void 0 : n.call(t)]);
232
- },
233
- width: 300,
234
- placement: "left"
235
- });
247
+ h.show = !h.show;
236
248
  }
237
249
  }, {
238
250
  icon: () => e("div", {
@@ -240,10 +252,10 @@ const it = /* @__PURE__ */ $({
240
252
  }, null)
241
253
  }), e("div", {
242
254
  class: "flex flex-wrap gap-2 items-center flex-1 lg:flex-none"
243
- }, [U(Z)]), e(d, {
255
+ }, [O(te)]), e(d, {
244
256
  type: "primary",
245
257
  secondary: !0,
246
- onClick: B
258
+ onClick: J
247
259
  }, {
248
260
  icon: () => e("div", {
249
261
  class: "i-tabler:search size-4"
@@ -252,80 +264,63 @@ const it = /* @__PURE__ */ $({
252
264
  }), (t == null ? void 0 : t.sideRight) && u.value < 1024 && e(d, {
253
265
  class: "flex-none",
254
266
  secondary: !0,
255
- loading: b.value,
256
267
  onClick: () => {
257
- A({
258
- title: i.sideRightTitle,
259
- component: () => {
260
- var n;
261
- return e("div", null, [(n = t == null ? void 0 : t.sideRight) == null ? void 0 : n.call(t)]);
262
- },
263
- width: 300,
264
- placement: "right"
265
- });
268
+ v.show = !v.show;
266
269
  }
267
270
  }, {
268
271
  icon: () => e("div", {
269
272
  class: "i-tabler:layout-sidebar-right-inactive size-4"
270
273
  }, null)
271
- }), Y.value && e(oe, {
272
- trigger: "click",
273
- displayDirective: "show"
274
+ }), ee.value && e(d, {
275
+ iconPlacement: "right",
276
+ onClick: () => {
277
+ g.show = !g.show;
278
+ }
274
279
  }, {
275
- trigger: () => e(d, {
276
- iconPlacement: "right",
277
- onClick: () => {
278
- k.collapse = !k.collapse;
279
- }
280
- }, {
281
- default: () => r("components.button.advanced"),
282
- icon: () => e("div", {
283
- class: ["i-tabler:chevrons-down size-4 transition-all"]
284
- }, null)
285
- }),
286
- default: () => e("div", {
287
- class: "flex flex-col gap-2 py-1"
288
- }, [U(_)])
280
+ default: () => r("components.button.advanced"),
281
+ icon: () => e("div", {
282
+ class: ["i-tabler:chevrons-down size-4 transition-all"]
283
+ }, null)
289
284
  })])]), e("div", {
290
285
  class: "flex gap-2"
291
- }, [(p = t.actions) == null ? void 0 : p.call(t), ((L = i.actions) == null ? void 0 : L.length) > 0 && O({
286
+ }, [(p = t.actions) == null ? void 0 : p.call(t), ((j = i.actions) == null ? void 0 : j.length) > 0 && W({
292
287
  type: u.value < 1024 ? "dropdown" : "button",
293
288
  text: u.value < 1024,
294
289
  items: i.actions
295
- })])]), e(de, {
296
- show: s.value,
290
+ })])]), e(fe, {
291
+ show: C.value,
297
292
  class: "flex-1 min-h-0",
298
293
  contentClass: "h-full"
299
294
  }, {
300
295
  default: () => {
301
- var n;
296
+ var a;
302
297
  return [e("div", {
303
298
  class: ["h-full overflow-auto rounded-lg px-3"]
304
- }, [!s.value && y.value.length === 0 && e("div", {
299
+ }, [!C.value && k.value.length === 0 && e("div", {
305
300
  class: "flex justify-center items-center h-full"
306
- }, [e(ve, null, null)]), y.value.length > 0 && ((n = t == null ? void 0 : t.default) == null ? void 0 : n.call(t, a))])];
301
+ }, [e(we, null, null)]), k.value.length > 0 && ((a = t == null ? void 0 : t.default) == null ? void 0 : a.call(t, l))])];
307
302
  }
308
303
  }), e("div", {
309
304
  class: "flex justify-between px-3 py-2 gap-2"
310
305
  }, [e("div", null, [e("div", {
311
306
  class: "flex gap-1 items-center"
312
- }, [i.checkable && e(f, null, {
307
+ }, [i.checkable && e(s, null, {
313
308
  trigger: () => e(d, {
314
- loading: S.value,
309
+ loading: z.value,
315
310
  circle: !0,
316
311
  quaternary: !0
317
312
  }, {
318
313
  default: () => [e(q, {
319
- checked: a.isAllChecked.value,
320
- indeterminate: a.isIndeterminate.value,
321
- onUpdateChecked: a.toggleSelectAll
314
+ checked: l.isAllChecked.value,
315
+ indeterminate: l.isIndeterminate.value,
316
+ onUpdateChecked: l.toggleSelectAll
322
317
  }, null)]
323
318
  }),
324
319
  default: () => r("components.list.selectAll")
325
- }), (F = t == null ? void 0 : t.tools) == null ? void 0 : F.call(t), x.value.export && e(f, null, {
320
+ }), (N = t == null ? void 0 : t.tools) == null ? void 0 : N.call(t), y.value.export && e(s, null, {
326
321
  trigger: () => e(d, {
327
- loading: b.value,
328
- onClick: K,
322
+ loading: Q.value,
323
+ onClick: H,
329
324
  circle: !0,
330
325
  quaternary: !0
331
326
  }, {
@@ -334,10 +329,10 @@ const it = /* @__PURE__ */ $({
334
329
  }, null)
335
330
  }),
336
331
  default: () => r("components.button.export")
337
- }), x.value.import && e(f, null, {
332
+ }), y.value.import && e(s, null, {
338
333
  trigger: () => e(d, {
339
- loading: S.value,
340
- onClick: G,
334
+ loading: z.value,
335
+ onClick: Y,
341
336
  circle: !0,
342
337
  quaternary: !0
343
338
  }, {
@@ -346,22 +341,22 @@ const it = /* @__PURE__ */ $({
346
341
  }, null)
347
342
  }),
348
343
  default: () => r("components.button.import")
349
- }), x.value.refresh && e(f, null, {
344
+ }), y.value.refresh && e(s, null, {
350
345
  trigger: () => e(d, {
351
- onClick: J,
346
+ onClick: K,
352
347
  circle: !0,
353
348
  quaternary: !0
354
349
  }, {
355
- icon: () => V.value ? e(pe, {
350
+ icon: () => _.value ? e(ge, {
356
351
  class: "size-4",
357
352
  type: "circle",
358
- percentage: w.value * 10,
353
+ percentage: L.value * 10,
359
354
  strokeWidth: 20,
360
355
  color: "rgba(var(--ui-color-primary))"
361
356
  }, {
362
357
  default: () => [e("span", {
363
358
  class: "text-8px"
364
- }, [w.value])]
359
+ }, [L.value])]
365
360
  }) : e("div", {
366
361
  class: "i-tabler:refresh size-4"
367
362
  }, null)
@@ -369,38 +364,93 @@ const it = /* @__PURE__ */ $({
369
364
  default: () => r("components.button.autoRefresh")
370
365
  })])]), e("div", {
371
366
  class: "flex items-center gap-2"
372
- }, [(N = t == null ? void 0 : t.bottom) == null ? void 0 : N.call(t), i.pagination && e(me, ae(H.value, {
367
+ }, [(D = t == null ? void 0 : t.bottom) == null ? void 0 : D.call(t), i.pagination && e(he, re(Z.value, {
373
368
  simple: u.value < 768
374
369
  }), {
375
370
  prefix: () => {
376
- var n;
371
+ var a;
377
372
  return e("div", null, [r("components.list.total", {
378
- total: ((n = h == null ? void 0 : h.value) == null ? void 0 : n.total) || 0
373
+ total: ((a = w == null ? void 0 : w.value) == null ? void 0 : a.total) || 0
379
374
  })]);
380
375
  }
381
- })])]), e(be, {
382
- number: a.checkeds.value.length,
376
+ })])]), e(ke, {
377
+ number: l.checkeds.value.length,
383
378
  group: [[{
384
379
  icon: "i-tabler:x",
385
380
  onClick: () => {
386
- var n;
387
- a.checkeds.value = [], (n = a.onUpdateChecked) == null || n.call(a, []);
381
+ var a;
382
+ l.checkeds.value = [], (a = l.onUpdateChecked) == null || a.call(l, []);
388
383
  }
389
384
  }], [{
390
385
  label: r("components.button.export"),
391
386
  icon: "i-tabler:file-export",
392
- loading: M.value,
393
- onClick: Q
387
+ loading: G.value,
388
+ onClick: X
394
389
  }, {
395
390
  label: r("components.button.delete"),
396
391
  type: "error",
397
392
  icon: "i-tabler:trash"
398
393
  }]]
399
- }, null)]);
394
+ }, null), e(ve, {
395
+ draggable: !0,
396
+ class: "bg-white rounded dark:shadow-gray-950/80 dark:bg-gray-800/60 backdrop-blur",
397
+ show: g.show,
398
+ onUpdateShow: (a) => g.show = a
399
+ }, {
400
+ default: ({
401
+ draggableClass: a
402
+ }) => {
403
+ let f;
404
+ return e(be, {
405
+ title: r("components.button.filter"),
406
+ handle: a,
407
+ onClose: () => g.show = !1
408
+ }, {
409
+ default: () => [e(Se, {
410
+ showLabel: !0,
411
+ labelPlacement: "top"
412
+ }, Ce(f = O(ae)) ? f : {
413
+ default: () => [f]
414
+ })]
415
+ });
416
+ }
417
+ }), e(I, {
418
+ show: h.show,
419
+ onUpdateShow: (a) => h.show = a,
420
+ autoFocus: !1,
421
+ placement: "left"
422
+ }, {
423
+ default: () => [e(M, {
424
+ title: i.sideLeftTitle || r("components.button.sideLeft"),
425
+ onClose: () => h.show = !1,
426
+ scrollbar: !1
427
+ }, {
428
+ default: () => {
429
+ var a;
430
+ return [(a = t == null ? void 0 : t.sideLeft) == null ? void 0 : a.call(t)];
431
+ }
432
+ })]
433
+ }), e(I, {
434
+ show: v.show,
435
+ onUpdateShow: (a) => v.show = a,
436
+ autoFocus: !1,
437
+ placement: "right"
438
+ }, {
439
+ default: () => [e(M, {
440
+ title: i.sideRightTitle || r("components.button.sideRight"),
441
+ onClose: () => v.show = !1,
442
+ scrollbar: !1
443
+ }, {
444
+ default: () => {
445
+ var a;
446
+ return [(a = t == null ? void 0 : t.sideRight) == null ? void 0 : a.call(t)];
447
+ }
448
+ })]
449
+ })]);
400
450
  }
401
451
  });
402
452
  }
403
453
  });
404
454
  export {
405
- it as DuxListLayout
455
+ yt as DuxListLayout
406
456
  };