@web-utils/form-ui 1.0.0-beta97 → 1.0.0-beta99

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 (84) hide show
  1. package/api/index.d.ts +4 -0
  2. package/api/index.mjs +9 -9
  3. package/basic-container/index.d.ts +16 -0
  4. package/basic-container/index.mjs +21 -0
  5. package/basic-container/style.css +1 -0
  6. package/biz-loading-view/index.d.ts +18 -0
  7. package/biz-loading-view/index.mjs +27 -0
  8. package/biz-loading-view/style.css +1 -0
  9. package/chunks/{D9IZqJJJ.mjs → B24kbvxB.mjs} +2 -1
  10. package/chunks/{BZb2YlPT.mjs → BcDeI1ZH.mjs} +1 -1
  11. package/chunks/{CcucCSvi.mjs → Bglnw37E.mjs} +2 -2
  12. package/chunks/{BFAXW-0d.mjs → BwPq7wF-.mjs} +3 -3
  13. package/chunks/{WjZeOWAM.mjs → CP0tXU4m.mjs} +1 -1
  14. package/chunks/{DYw3AWS9.mjs → CPGrGc4W.mjs} +3 -3
  15. package/chunks/{CCjeJzFN.mjs → CcW1bkgt.mjs} +1 -1
  16. package/chunks/{bPnQPTY0.mjs → CdLdGxlD.mjs} +2 -2
  17. package/chunks/{iNFexWJG.mjs → DQVIughS.mjs} +1 -1
  18. package/chunks/DptiCPnc.mjs +92 -0
  19. package/chunks/{BSOrm2U4.mjs → fJ2ezOVH.mjs} +1 -1
  20. package/data-table-picker/index.mjs +1 -1
  21. package/dialog-form/index.mjs +2 -2
  22. package/editable-tree/index.mjs +1 -1
  23. package/element-dialog/index.mjs +1 -1
  24. package/flow-designer/index.mjs +1 -1
  25. package/form-cascader/index.d.ts +1 -1
  26. package/form-checkbox/index.d.ts +1 -1
  27. package/form-checkbox-group/index.d.ts +1 -1
  28. package/form-date-picker/index.d.ts +1 -1
  29. package/form-image/index.d.ts +1 -1
  30. package/form-input/index.d.ts +1 -1
  31. package/form-input-cron-expression/index.d.ts +1 -1
  32. package/form-input-email/index.d.ts +1 -1
  33. package/form-input-id-card/index.d.ts +1 -1
  34. package/form-input-number/index.d.ts +1 -1
  35. package/form-input-phone-number/index.d.ts +1 -1
  36. package/form-input-tag/index.d.ts +1 -1
  37. package/form-input-time/index.d.ts +1 -1
  38. package/form-item/index.d.ts +1 -1
  39. package/form-item-group/index.d.ts +1 -1
  40. package/form-radio-group/index.d.ts +1 -1
  41. package/form-rate/index.d.ts +1 -1
  42. package/form-select/index.d.ts +1 -1
  43. package/form-slider/index.d.ts +1 -1
  44. package/form-switch/index.d.ts +1 -1
  45. package/form-table/index.d.ts +1 -1
  46. package/form-table-plus/index.d.ts +1 -1
  47. package/form-text/index.d.ts +1 -1
  48. package/form-textarea/index.d.ts +1 -1
  49. package/form-time-select/index.d.ts +1 -1
  50. package/form-tree-select/index.d.ts +1 -1
  51. package/form-tree-select-multiple/index.d.ts +1 -1
  52. package/fy-avatar/index.d.ts +40 -0
  53. package/fy-avatar/index.mjs +58 -0
  54. package/fy-avatar/style.css +1 -0
  55. package/fy-curd/index.mjs +1 -1
  56. package/fy-dynamic/index.mjs +1 -1
  57. package/fy-form/index.mjs +1 -1
  58. package/fy-input-icon/index.mjs +1 -1
  59. package/fy-input-map/index.mjs +1 -1
  60. package/fy-input-table/index.mjs +2 -2
  61. package/fy-tree/index.mjs +2 -2
  62. package/iframe-window/index.mjs +1 -1
  63. package/image-cropper/index.mjs +1 -1
  64. package/index.css +1 -1
  65. package/index.d.ts +5 -1
  66. package/index.mjs +149 -145
  67. package/nav-tab-panel/index.d.ts +30 -0
  68. package/nav-tab-panel/index.mjs +2 -0
  69. package/nav-tab-panel/style.css +1 -0
  70. package/package.json +1 -1
  71. package/photo-swipe/index.mjs +1 -1
  72. package/resolver/components.mjs +1 -1
  73. package/split-pane/index.mjs +1 -1
  74. package/table-view/index.mjs +9 -9
  75. package/watermark/index.mjs +1 -1
  76. package/web-types.json +1 -1
  77. /package/chunks/{CZnwC17w.mjs → B-BmACqv.mjs} +0 -0
  78. /package/chunks/{CHqxWrj7.mjs → BTDWXFoi.mjs} +0 -0
  79. /package/chunks/{rkP6k8kb.mjs → BWNDImpw.mjs} +0 -0
  80. /package/chunks/{BCYFaOiB.mjs → C2bqaC-E.mjs} +0 -0
  81. /package/chunks/{Cp1olyWc.mjs → D1wwXnEw.mjs} +0 -0
  82. /package/chunks/{D99-kE8j.mjs → D5twDi0x.mjs} +0 -0
  83. /package/chunks/{TaNkWyiK.mjs → DG4q844M.mjs} +0 -0
  84. /package/chunks/{BjccroM8.mjs → tJ_t87kJ.mjs} +0 -0
package/api/index.d.ts CHANGED
@@ -45,7 +45,11 @@ export interface ConfigOptions {
45
45
  toolbar?: {
46
46
  goBack?: (path: string) => void;
47
47
  };
48
+ defaultAvatar?: string;
49
+ logo?: string;
48
50
  }
51
+ export declare const getDefaultAvatar: () => string | undefined;
52
+ export declare const getLogo: () => string | undefined;
49
53
  export declare const processButtons: (buttons: Array<string | Record<string, string>>) => (string | Record<string, boolean>)[] | undefined;
50
54
  export declare const hasAuthority: (str: string) => boolean | undefined;
51
55
  export declare const goBack: (path: string) => void | undefined;
package/api/index.mjs CHANGED
@@ -6,7 +6,7 @@ var r = { privilege: {
6
6
  return n.map((n) => {
7
7
  if (e(n)) {
8
8
  let e = n, r = {};
9
- for (let n in e) t(e[n]) && (r[n] = a(e[n]) ?? !0);
9
+ for (let n in e) t(e[n]) && (r[n] = s(e[n]) ?? !0);
10
10
  return r;
11
11
  }
12
12
  return n;
@@ -15,28 +15,28 @@ var r = { privilege: {
15
15
  hasAuthority(e) {
16
16
  return !0;
17
17
  }
18
- } }, i = (e) => {
18
+ } }, i = () => r.defaultAvatar, a = () => r.logo, o = (e) => {
19
19
  var t, n;
20
20
  return (t = r.privilege) == null || (n = t.processButtons) == null ? void 0 : n.call(t, e);
21
- }, a = (e) => {
21
+ }, s = (e) => {
22
22
  var t, n;
23
23
  return (t = r.privilege) == null || (n = t.hasAuthority) == null ? void 0 : n.call(t, e);
24
- }, o = (e) => {
24
+ }, c = (e) => {
25
25
  var t, n;
26
26
  return (t = r.toolbar) == null || (n = t.goBack) == null ? void 0 : n.call(t, e);
27
- }, s = () => {
27
+ }, l = () => {
28
28
  var e, t;
29
29
  return (e = r.tableView) == null || (t = e.reload) == null ? void 0 : t.call(e);
30
- }, c = (e, t) => {
30
+ }, u = (e, t) => {
31
31
  var n, i;
32
32
  return (n = r.dict) == null || (i = n.getDictTreeByType) == null ? void 0 : i.call(n, e, t);
33
- }, l = (e) => {
33
+ }, d = (e) => {
34
34
  var t, n;
35
35
  return (t = r.dict) == null || (n = t.remote) == null ? void 0 : n.call(t, e);
36
- }, u = (e) => {
36
+ }, f = (e) => {
37
37
  n(r, e, (e, t) => {
38
38
  if (typeof t == "function") return t;
39
39
  });
40
40
  };
41
41
  //#endregion
42
- export { u as config, c as getDictTreeByType, o as goBack, a as hasAuthority, i as processButtons, s as reloadTable, l as remote };
42
+ export { f as config, i as getDefaultAvatar, u as getDictTreeByType, a as getLogo, c as goBack, s as hasAuthority, o as processButtons, l as reloadTable, d as remote };
@@ -0,0 +1,16 @@
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ declare const __VLS_export: __VLS_WithSlots<typeof __VLS_base, __VLS_Slots>;
4
+ type __VLS_WithSlots<T, S> = T & (new () => {
5
+ $slots: S;
6
+ });
7
+ declare const __VLS_base: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
8
+ block: BooleanConstructor;
9
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
10
+ block: BooleanConstructor;
11
+ }>> & Readonly<{}>, {
12
+ block: boolean;
13
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
14
+ type __VLS_Slots = {
15
+ default?: ((props: {}) => any) | undefined;
16
+ };
@@ -0,0 +1,21 @@
1
+ import { ElCard as e } from "element-plus/es";
2
+ import "element-plus/es/components/base/style/css";
3
+ import { createElementBlock as t, createVNode as n, normalizeClass as r, openBlock as i, renderSlot as a, withCtx as o } from "vue";
4
+ import "element-plus/es/components/card/style/css";
5
+ import "./style.css";
6
+ //#region src/components/BasicContainer.vue
7
+ var s = /* @__PURE__ */ Object.assign({ name: "BasicContainer" }, {
8
+ __name: "BasicContainer",
9
+ props: { block: Boolean },
10
+ setup(s) {
11
+ return (c, l) => {
12
+ let u = e;
13
+ return i(), t("div", { class: r([{ "basic-container--block": s.block }, "basic-container"]) }, [n(u, null, {
14
+ default: o(() => [a(c.$slots, "default")]),
15
+ _: 3
16
+ })], 2);
17
+ };
18
+ }
19
+ });
20
+ //#endregion
21
+ export { s as default };
@@ -0,0 +1 @@
1
+ .basic-container{box-sizing:border-box;border-radius:10px;height:100%;padding:8px 10px;overflow:auto}.basic-container .el-card{width:100%}.basic-container--block .el-card,.basic-container--block .el-card__body{height:100%}
@@ -0,0 +1,18 @@
1
+ declare const _default: typeof __VLS_export;
2
+ export default _default;
3
+ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractPropTypes<{
4
+ backdrop: BooleanConstructor;
5
+ tips: {
6
+ type: StringConstructor;
7
+ default: string;
8
+ };
9
+ }>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<globalThis.ExtractPropTypes<{
10
+ backdrop: BooleanConstructor;
11
+ tips: {
12
+ type: StringConstructor;
13
+ default: string;
14
+ };
15
+ }>> & Readonly<{}>, {
16
+ backdrop: boolean;
17
+ tips: string;
18
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
@@ -0,0 +1,27 @@
1
+ import { getLogo as e } from "../api/index.mjs";
2
+ import { createElementBlock as t, createElementVNode as n, normalizeStyle as r, openBlock as i, toDisplayString as a, unref as o } from "vue";
3
+ import "./style.css";
4
+ //#region src/components/BizLoadingView.vue
5
+ var s = { class: "cu-load load-modal" }, c = ["src"], l = { class: "gray-text" }, u = {
6
+ __name: "BizLoadingView",
7
+ props: {
8
+ backdrop: Boolean,
9
+ tips: {
10
+ type: String,
11
+ default: "加载中..."
12
+ }
13
+ },
14
+ setup(u) {
15
+ let d = e();
16
+ return (e, f) => (i(), t("div", {
17
+ class: "loading",
18
+ style: r({ backgroundColor: u.backdrop ? "rgba(0, 0, 0, 0.2)" : "#eff2f7" })
19
+ }, [n("div", s, [n("img", {
20
+ class: "image",
21
+ src: o(d),
22
+ alt: ""
23
+ }, null, 8, c), n("div", l, a(u.tips), 1)])], 4));
24
+ }
25
+ };
26
+ //#endregion
27
+ export { u as default };
@@ -0,0 +1 @@
1
+ .loading{z-index:100;justify-content:center;align-items:center;display:flex;position:absolute;top:0;bottom:0;left:0;right:0}@keyframes cuIcon-spin{0%{transform:rotate(0)}to{transform:rotate(359deg)}}.cu-load{text-align:center;line-height:3em;display:block}.cu-load:before{margin-right:6rpx;font-family:cuIcon,serif;display:inline-block}.cu-load.loading:before{content:"";animation:2s linear infinite cuIcon-spin}.cu-load.loading:after{content:"加载中..."}.cu-load.over:before{content:""}.cu-load.over:after{content:"没有更多了"}.cu-load.erro:before{content:""}.cu-load.erro:after{content:"加载失败"}.cu-load.load-icon:before{font-size:32rpx}.cu-load.load-icon:after,.cu-load.load-icon.over{display:none}.cu-load.load-modal{z-index:9999;background-color:#fff;border-radius:.3125rem;flex-direction:column;justify-content:center;align-items:center;width:8.125rem;height:8.125rem;margin:auto;font-size:.875rem;line-height:2.4em;display:flex;bottom:4.375rem}.cu-load.load-modal [class*=cuIcon-]{font-size:60rpx}.cu-load.load-modal .image{width:2.1875rem;height:2.1875rem}.cu-load.load-modal:after{z-index:-1;content:"";background-color:#fff;border:.1875rem solid #0000000d;border-left-color:#f37b1d;border-radius:50%;width:6.25rem;height:6.25rem;font-size:.625rem;animation:1s linear infinite cuIcon-spin;position:absolute}.load-progress{z-index:2000;pointer-events:none;width:100%;position:fixed;top:0;left:0}.load-progress.hide{display:none}.load-progress .load-progress-bar{width:100%;height:4rpx;transition:all .2s;position:relative;overflow:hidden}.load-progress .load-progress-spinner{top:10rpx;right:10rpx;z-index:2000;display:block;position:absolute}.load-progress .load-progress-spinner:after{box-sizing:border-box;width:24rpx;height:24rpx;border:solid 4rpx transparent;border-top-color:inherit;border-left-color:inherit;content:"";border-radius:50%;animation:.4s linear infinite load-progress-spinner;display:block}@keyframes load-progress-spinner{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
@@ -108,6 +108,7 @@ var S = {
108
108
  showFullScreen: !0,
109
109
  fullscreen: !0,
110
110
  showClose: !0,
111
+ customClass: !0,
111
112
  bodyPadding: !0
112
113
  }, w = (e) => C[e] !== !0, T = { class: "dialog-title" }, E = { class: "dialog-header-buttons" }, D = /* @__PURE__ */ Object.assign({
113
114
  name: "ElementDialog",
@@ -142,7 +143,7 @@ var S = {
142
143
  "onUpdate:modelValue": n[0] || (n[0] = (e) => D.value = e),
143
144
  class: "element-dialog"
144
145
  }, _(A), {
145
- class: e.$attrs.class,
146
+ class: [e.$attrs.class, O.customClass],
146
147
  "show-close": !1,
147
148
  fullscreen: _(N),
148
149
  "body-class": `${e.bodyClass || ""}${e.bodyPadding ? "" : " no-padding"}`,
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
4
  import { ElCheckbox as r, ElForm as i, ElFormItem as a, ElInput as o, ElMessage as s, ElOption as c, ElSelect as l } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
4
  import r from "../highlight-j-s/index.mjs";
5
5
  import { ElButtonGroup as i, ElCollapse as a, ElCollapseItem as o, ElMessage as s, ElMessageBox as c, ElTabPane as l, ElTabs as u, ElTooltip as d } from "element-plus/es";
@@ -422,7 +422,7 @@ var Ae = [
422
422
  "task",
423
423
  "form",
424
424
  "multiInstance"
425
- ], je = y(() => import("./DYw3AWS9.mjs")), Me = y(() => import("./iNFexWJG.mjs")), Ne = y(() => import("./WjZeOWAM.mjs")), Pe = y(() => import("./BFAXW-0d.mjs")), Fe = y(() => import("./CCjeJzFN.mjs")), Ie = y(() => import("./CHqxWrj7.mjs")), Le = y(() => import("./rkP6k8kb.mjs")), Re = y(() => import("./BZb2YlPT.mjs")), ze = y(() => import("./BCYFaOiB.mjs")), Be = y(() => import("./BSOrm2U4.mjs")), Ve = {
425
+ ], je = y(() => import("./CPGrGc4W.mjs")), Me = y(() => import("./DQVIughS.mjs")), Ne = y(() => import("./CP0tXU4m.mjs")), Pe = y(() => import("./BwPq7wF-.mjs")), Fe = y(() => import("./CcW1bkgt.mjs")), Ie = y(() => import("./BTDWXFoi.mjs")), Le = y(() => import("./BWNDImpw.mjs")), Re = y(() => import("./BcDeI1ZH.mjs")), ze = y(() => import("./C2bqaC-E.mjs")), Be = y(() => import("./fJ2ezOVH.mjs")), Ve = {
426
426
  name: "PropertiesPanel",
427
427
  componentName: "MyPropertiesPanel",
428
428
  props: {
@@ -1,8 +1,8 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
- import { r, t as i } from "./CZnwC17w.mjs";
5
- import { a, i as o, n as s, r as c } from "./Cp1olyWc.mjs";
4
+ import { r, t as i } from "./B-BmACqv.mjs";
5
+ import { a, i as o, n as s, r as c } from "./D1wwXnEw.mjs";
6
6
  import { ElDivider as l, ElDrawer as u, ElForm as d, ElFormItem as f, ElInput as p, ElMessageBox as m, ElOption as h, ElSelect as g, ElTable as _, ElTableColumn as v } from "element-plus/es";
7
7
  import "element-plus/es/components/base/style/css";
8
8
  import "element-plus/es/components/input/style/css";
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
4
  import { ElDivider as r, ElForm as i, ElFormItem as a, ElInput as o, ElMessageBox as s, ElTable as c, ElTableColumn as l } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
@@ -1,8 +1,8 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
- import { r, t as i } from "./CZnwC17w.mjs";
5
- import { a, i as o, n as s, r as c, t as l } from "./Cp1olyWc.mjs";
4
+ import { r, t as i } from "./B-BmACqv.mjs";
5
+ import { a, i as o, n as s, r as c, t as l } from "./D1wwXnEw.mjs";
6
6
  import { ElDivider as u, ElDrawer as d, ElForm as f, ElFormItem as p, ElInput as m, ElMessageBox as h, ElOption as g, ElSelect as _, ElTable as v, ElTableColumn as y } from "element-plus/es";
7
7
  import "element-plus/es/components/base/style/css";
8
8
  import "element-plus/es/components/input/style/css";
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
4
  import { ElForm as r, ElFormItem as i, ElInput as a, ElMessage as o, ElTable as s, ElTableColumn as c } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
@@ -1,6 +1,6 @@
1
1
  import { u as e } from "./ClVh1Lek.mjs";
2
2
  import { t } from "./B1MSrc6f.mjs";
3
- import { t as n } from "./D9IZqJJJ.mjs";
3
+ import { t as n } from "./B24kbvxB.mjs";
4
4
  import { avueConfigContextKey as r } from "../constants/index.mjs";
5
5
  import { t as i } from "./DTeHffqJ.mjs";
6
6
  import { C as a, T as o, _ as s, a as c, b as l, c as u, d, g as f, h as p, l as m, m as h, n as g, p as ee, t as te, v as _, x as ne, y as re } from "./CXHJqvbJ.mjs";
@@ -29,6 +29,7 @@ import { ElButtonGroup as Fe, ElCard as Ie, ElCheckbox as Le, ElCol as x, ElColl
29
29
  import "element-plus/es/components/base/style/css";
30
30
  import { Fragment as T, createBlock as E, createCommentVNode as D, createElementBlock as O, createElementVNode as k, createSlots as A, createTextVNode as j, createVNode as M, defineAsyncComponent as et, guardReactiveProps as N, mergeProps as P, normalizeClass as F, normalizeProps as I, normalizeStyle as L, openBlock as R, renderList as z, renderSlot as B, resolveComponent as tt, resolveDirective as V, resolveDynamicComponent as H, toDisplayString as U, toHandlers as nt, vShow as rt, withCtx as W, withDirectives as G, withKeys as it, withModifiers as K } from "vue";
31
31
  import { isBlank as q } from "@web-utils/core";
32
+ import "element-plus/es/components/card/style/css";
32
33
  import "element-plus/es/components/row/style/css";
33
34
  import "element-plus/es/components/col/style/css";
34
35
  import "element-plus/es/components/loading/style/css";
@@ -46,7 +47,6 @@ import "element-plus/es/components/form-item/style/css";
46
47
  import "element-plus/es/components/link/style/css";
47
48
  import "element-plus/es/components/button-group/style/css";
48
49
  import { formatDate as J } from "@web-utils/integrations/dayjs";
49
- import "element-plus/es/components/card/style/css";
50
50
  import "element-plus/es/components/dropdown/style/css";
51
51
  import "element-plus/es/components/dropdown-menu/style/css";
52
52
  import "element-plus/es/components/dropdown-item/style/css";
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { t } from "./D9IZqJJJ.mjs";
2
+ import { t } from "./B24kbvxB.mjs";
3
3
  import { t as n } from "./DTeHffqJ.mjs";
4
4
  import { ElDivider as r, ElDrawer as i, ElForm as a, ElFormItem as o, ElInput as s, ElOption as c, ElSelect as l, ElTable as u, ElTableColumn as d } from "element-plus/es";
5
5
  import "element-plus/es/components/base/style/css";
@@ -0,0 +1,92 @@
1
+ import { ElTabPane as e, ElTabs as t } from "element-plus/es";
2
+ import "element-plus/es/components/base/style/css";
3
+ import { createVNode as n, isVNode as r } from "vue";
4
+ import "element-plus/es/components/tabs/style/css";
5
+ import "element-plus/es/components/tab-pane/style/css";
6
+ import "../nav-tab-panel/style.css";
7
+ //#region src/components/NavTabPanel.vue?vue&type=script&lang.jsx
8
+ function i(e) {
9
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !r(e);
10
+ }
11
+ var a = (e, t, n = {
12
+ topOffset: 0,
13
+ bottomOffset: 0,
14
+ rightOffset: 0,
15
+ leftOffset: 0
16
+ }) => {
17
+ if (!e || !t) return !1;
18
+ let r = e.getBoundingClientRect(), i;
19
+ return i = [
20
+ window,
21
+ document,
22
+ document.documentElement,
23
+ null,
24
+ void 0
25
+ ].includes(t) ? {
26
+ top: 0,
27
+ right: window.innerWidth,
28
+ bottom: window.innerHeight,
29
+ left: 0
30
+ } : t.getBoundingClientRect(), (n.topOffset ? r.top - n.topOffset : r.top) < i.bottom && (n.bottomOffset ? r.bottom - n.bottomOffset : r.bottom) > i.top && (n.rightOffset ? r.right - n.rightOffset : r.right) > i.left && (n.leftOffset ? r.left - n.leftOffset : r.left) < i.right;
31
+ }, o = {
32
+ name: "NavTabPanel",
33
+ provide() {
34
+ return { store: this.store };
35
+ },
36
+ props: {
37
+ cascade: Boolean,
38
+ padding: {
39
+ type: String,
40
+ default: "0"
41
+ }
42
+ },
43
+ data() {
44
+ return {
45
+ activeIndex: "0",
46
+ store: { tabs: [] }
47
+ };
48
+ },
49
+ methods: {
50
+ tabClick(e) {
51
+ this.$emit("handleTabChange", e), this.$refs.scroller !== void 0 && (this.$refs.scroller.scrollTop = this.$refs.scroller.children[e.index].offsetTop);
52
+ },
53
+ tryActive() {
54
+ for (let e = 0; e < this.$refs.scroller.children.length; e++) if (a(this.$refs.scroller.children[e], this.$refs.scroller, 0)) {
55
+ this.activeIndex = `${e}`;
56
+ break;
57
+ }
58
+ }
59
+ },
60
+ render() {
61
+ let r;
62
+ return this.cascade ? n("div", { class: "nav-tab-panel" }, [n("div", {
63
+ class: "flex-not-shrink",
64
+ style: "min-width: 100px;height: 100%;"
65
+ }, [n(t, {
66
+ "tab-position": "left",
67
+ class: "nav-tab-panel-tabs",
68
+ style: "height: 100%;",
69
+ modelValue: this.activeIndex,
70
+ "onUpdate:modelValue": (e) => this.activeIndex = e,
71
+ "on-tab-click": this.tabClick
72
+ }, i(r = this.store.tabs.map((t, r) => n(e, {
73
+ label: t.title,
74
+ name: `${r}`,
75
+ key: t.title
76
+ }, null))) ? r : { default: () => [r] })]), n("div", {
77
+ class: "cascade-content",
78
+ "on-scroll": this.tryActive,
79
+ ref: "scroller",
80
+ style: { padding: this.padding }
81
+ }, [this.$slots.default || "请添加内容"])]) : n(t, {
82
+ "tab-position": "left",
83
+ class: "nav-tab-panel-tabs",
84
+ style: "height: 100%;",
85
+ modelValue: this.activeIndex,
86
+ "onUpdate:modelValue": (e) => this.activeIndex = e,
87
+ "on-tab-click": this.tabClick
88
+ }, { default: () => [this.$slots.default] });
89
+ }
90
+ };
91
+ //#endregion
92
+ export { o as t };
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "./B1MSrc6f.mjs";
2
- import { i as t, n } from "./CZnwC17w.mjs";
2
+ import { i as t, n } from "./B-BmACqv.mjs";
3
3
  import { ElForm as r, ElFormItem as i, ElInput as a, ElOption as o, ElSelect as s, ElSwitch as c } from "element-plus/es";
4
4
  import "element-plus/es/components/base/style/css";
5
5
  import "element-plus/es/components/input/style/css";
@@ -1,5 +1,5 @@
1
1
  import { t as e } from "../chunks/B1MSrc6f.mjs";
2
- import { t } from "../chunks/D9IZqJJJ.mjs";
2
+ import { t } from "../chunks/B24kbvxB.mjs";
3
3
  import { t as n } from "../chunks/DTeHffqJ.mjs";
4
4
  import { t as r } from "../chunks/sl7eKGeX.mjs";
5
5
  import { ElMessage as i } from "element-plus/es";
@@ -1,9 +1,9 @@
1
1
  import { def as e } from "../helper/avue.mjs";
2
2
  import { t } from "../chunks/B1MSrc6f.mjs";
3
- import { t as n } from "../chunks/D9IZqJJJ.mjs";
3
+ import { t as n } from "../chunks/B24kbvxB.mjs";
4
4
  import { avueConfigContextKey as r } from "../constants/index.mjs";
5
5
  import { t as i } from "../chunks/DTeHffqJ.mjs";
6
- import { t as a } from "../chunks/bPnQPTY0.mjs";
6
+ import { t as a } from "../chunks/CdLdGxlD.mjs";
7
7
  import { a as o } from "../chunks/CXHJqvbJ.mjs";
8
8
  import { ElDrawer as s } from "element-plus/es";
9
9
  import "element-plus/es/components/base/style/css";
@@ -8,8 +8,8 @@ import "element-plus/es/components/input/style/css";
8
8
  import { Fragment as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createTextVNode as g, createVNode as _, mergeProps as v, normalizeClass as y, normalizeStyle as b, openBlock as x, renderSlot as S, toDisplayString as C, toHandlers as w, vShow as T, withCtx as E, withDirectives as D, withModifiers as O } from "vue";
9
9
  import { computePosition as k, delay as A, fastClone as j, findTreeChildren as M, isFunction as N, isNotEmpty as P, isPlainObject as F, isUndefined as I, isVerticalScrollbarVisible as L, patch as R, scrollbarWidth as z } from "@web-utils/core";
10
10
  import "element-plus/es/components/message/style/css";
11
- import "element-plus/es/components/message-box/style/css";
12
11
  import { cloneDeep as B } from "@web-utils/integrations/lodash";
12
+ import "element-plus/es/components/message-box/style/css";
13
13
  import "element-plus/es/components/tree/style/css";
14
14
  import "element-plus/es/components/popconfirm/style/css";
15
15
  import { addResizeListener as V, removeResizeListener as H } from "@web-utils/integrations/resize";
@@ -1,2 +1,2 @@
1
- import { t as e } from "../chunks/D9IZqJJJ.mjs";
1
+ import { t as e } from "../chunks/B24kbvxB.mjs";
2
2
  export { e as default };
@@ -1,2 +1,2 @@
1
- import { t as e } from "../chunks/CcucCSvi.mjs";
1
+ import { t as e } from "../chunks/Bglnw37E.mjs";
2
2
  export { e as default };
@@ -437,9 +437,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
437
437
  placement: string;
438
438
  col: boolean;
439
439
  span: number;
440
+ block: boolean;
440
441
  tag: string;
441
442
  required: boolean;
442
- block: boolean;
443
443
  pull: number;
444
444
  treeDict: boolean;
445
445
  idAsValue: boolean;
@@ -290,10 +290,10 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
290
290
  offset: number;
291
291
  col: boolean;
292
292
  span: number;
293
+ block: boolean;
293
294
  tag: string;
294
295
  required: boolean;
295
296
  border: boolean;
296
- block: boolean;
297
297
  pull: number;
298
298
  wrapCol: boolean;
299
299
  unwrap: boolean;
@@ -346,10 +346,10 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
346
346
  col: boolean;
347
347
  span: number;
348
348
  split: boolean;
349
+ block: boolean;
349
350
  confirm: boolean;
350
351
  tag: string;
351
352
  required: boolean;
352
- block: boolean;
353
353
  pull: number;
354
354
  wrapCol: boolean;
355
355
  unwrap: boolean;
@@ -440,9 +440,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
440
440
  col: boolean;
441
441
  span: number;
442
442
  split: boolean;
443
+ block: boolean;
443
444
  tag: string;
444
445
  required: boolean;
445
- block: boolean;
446
446
  pull: number;
447
447
  dates: boolean;
448
448
  week: boolean;
@@ -204,9 +204,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
204
204
  offset: number;
205
205
  col: boolean;
206
206
  span: number;
207
+ block: boolean;
207
208
  tag: string;
208
209
  required: boolean;
209
- block: boolean;
210
210
  pull: number;
211
211
  wrapCol: boolean;
212
212
  unwrap: boolean;
@@ -352,9 +352,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
352
352
  autofocus: boolean;
353
353
  col: boolean;
354
354
  span: number;
355
+ block: boolean;
355
356
  tag: string;
356
357
  required: boolean;
357
- block: boolean;
358
358
  pull: number;
359
359
  readonly: boolean;
360
360
  wrapCol: boolean;
@@ -208,9 +208,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
208
208
  offset: number;
209
209
  col: boolean;
210
210
  span: number;
211
+ block: boolean;
211
212
  tag: string;
212
213
  required: boolean;
213
- block: boolean;
214
214
  pull: number;
215
215
  wrapCol: boolean;
216
216
  unwrap: boolean;
@@ -350,9 +350,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
350
350
  autofocus: boolean;
351
351
  col: boolean;
352
352
  span: number;
353
+ block: boolean;
353
354
  tag: string;
354
355
  required: boolean;
355
- block: boolean;
356
356
  pull: number;
357
357
  readonly: boolean;
358
358
  wrapCol: boolean;
@@ -350,9 +350,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
350
350
  autofocus: boolean;
351
351
  col: boolean;
352
352
  span: number;
353
+ block: boolean;
353
354
  tag: string;
354
355
  required: boolean;
355
- block: boolean;
356
356
  pull: number;
357
357
  readonly: boolean;
358
358
  wrapCol: boolean;
@@ -305,9 +305,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
305
305
  size: string;
306
306
  col: boolean;
307
307
  span: number;
308
+ block: boolean;
308
309
  tag: string;
309
310
  required: boolean;
310
- block: boolean;
311
311
  align: string;
312
312
  pull: number;
313
313
  step: number;
@@ -350,9 +350,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
350
350
  autofocus: boolean;
351
351
  col: boolean;
352
352
  span: number;
353
+ block: boolean;
353
354
  tag: string;
354
355
  required: boolean;
355
- block: boolean;
356
356
  pull: number;
357
357
  readonly: boolean;
358
358
  wrapCol: boolean;
@@ -251,9 +251,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
251
251
  offset: number;
252
252
  col: boolean;
253
253
  span: number;
254
+ block: boolean;
254
255
  tag: string;
255
256
  required: boolean;
256
- block: boolean;
257
257
  pull: number;
258
258
  wrapCol: boolean;
259
259
  unwrap: boolean;
@@ -406,9 +406,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
406
406
  placement: string;
407
407
  col: boolean;
408
408
  span: number;
409
+ block: boolean;
409
410
  tag: string;
410
411
  required: boolean;
411
- block: boolean;
412
412
  start: string;
413
413
  end: string;
414
414
  pull: number;
@@ -176,9 +176,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
176
176
  push: number;
177
177
  offset: number;
178
178
  span: number;
179
+ block: boolean;
179
180
  tag: string;
180
181
  required: boolean;
181
- block: boolean;
182
182
  pull: number;
183
183
  wrapCol: boolean;
184
184
  unwrap: boolean;
@@ -81,10 +81,10 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
81
81
  }>> & Readonly<{}>, {
82
82
  disabled: boolean;
83
83
  span: number;
84
+ block: boolean;
84
85
  active: boolean;
85
86
  gutter: number;
86
87
  tag: string;
87
- block: boolean;
88
88
  enabled: boolean;
89
89
  wrapRow: boolean;
90
90
  collapse: boolean;
@@ -341,11 +341,11 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
341
341
  size: string;
342
342
  col: boolean;
343
343
  span: number;
344
+ block: boolean;
344
345
  confirm: boolean;
345
346
  tag: string;
346
347
  required: boolean;
347
348
  border: boolean;
348
- block: boolean;
349
349
  pull: number;
350
350
  wrapCol: boolean;
351
351
  unwrap: boolean;
@@ -300,9 +300,9 @@ declare const __VLS_export: import('vue').DefineComponent<globalThis.ExtractProp
300
300
  offset: number;
301
301
  col: boolean;
302
302
  span: number;
303
+ block: boolean;
303
304
  tag: string;
304
305
  required: boolean;
305
- block: boolean;
306
306
  pull: number;
307
307
  max: number;
308
308
  wrapCol: boolean;