@ditari/bsui 1.0.68 → 1.0.70
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/components.cjs.js +1 -1
- package/dist/cjs/components/form/DQueryForm.cjs.js +1 -0
- package/dist/cjs/components/form/index.cjs.js +1 -1
- package/dist/cjs/components/index.cjs.js +1 -1
- package/dist/cjs/components/layout/List.vue.cjs.js +1 -1
- package/dist/cjs/components/menu/Menu.cjs.js +1 -1
- package/dist/cjs/components/table/Table.cjs.js +1 -1
- package/dist/cjs/store/modules/NavTab.cjs.js +1 -1
- package/dist/esm/components/components.esm.js +22 -21
- package/dist/esm/components/form/DQueryForm.esm.js +18 -0
- package/dist/esm/components/form/index.esm.js +4 -6
- package/dist/esm/components/index.esm.js +21 -20
- package/dist/esm/components/layout/List.vue.esm.js +62 -56
- package/dist/esm/components/menu/Menu.esm.js +9 -9
- package/dist/esm/components/table/Table.esm.js +122 -129
- package/dist/esm/store/modules/NavTab.esm.js +3 -3
- package/package.json +1 -1
- package/src/components/components.ts +1 -0
- package/src/components/dic/replace.worker.js +20 -0
- package/src/components/form/DQueryForm.tsx +19 -0
- package/src/components/form/index.ts +3 -5
- package/src/components/index.ts +1 -1
- package/src/components/layout/List.vue +24 -7
- package/src/components/menu/{Menu.jsx → Menu.tsx} +14 -21
- package/src/components/select/dic.worker.js +27 -0
- package/src/components/table/Table.tsx +3 -9
- package/src/store/modules/NavTab.ts +3 -1
- package/src/tsconfig.json +5 -5
- package/dist/cjs/_virtual/_plugin-vue_export-helper.cjs.js +0 -1
- package/dist/cjs/components/components.d.ts +0 -8
- package/dist/cjs/components/desensitize/Desensitize.d.ts +0 -39
- package/dist/cjs/components/desensitize/index.d.ts +0 -39
- package/dist/cjs/components/dic/DicReplace.d.ts +0 -23
- package/dist/cjs/components/dic/index.d.ts +0 -23
- package/dist/cjs/components/form/Form.vue.cjs.js +0 -1
- package/dist/cjs/components/form/Form.vue.cjs2.js +0 -1
- package/dist/cjs/components/form/Form.vue.d.ts +0 -4
- package/dist/cjs/components/form/grid-form/GridForm.cjs.js +0 -1
- package/dist/cjs/components/form/grid-form/GridForm.d.ts +0 -2
- package/dist/cjs/components/form/index.d.ts +0 -11
- package/dist/cjs/components/grid/Grid.d.ts +0 -32
- package/dist/cjs/components/grid/GridItem.d.ts +0 -2
- package/dist/cjs/components/grid/index.d.ts +0 -32
- package/dist/cjs/components/index.d.ts +0 -15
- package/dist/cjs/components/layout/Breadcrumb.vue.d.ts +0 -2
- package/dist/cjs/components/layout/FuckMain.vue.d.ts +0 -20
- package/dist/cjs/components/layout/List.vue.d.ts +0 -4
- package/dist/cjs/components/layout/Main.vue.d.ts +0 -28
- package/dist/cjs/components/layout/NavTabs.vue.d.ts +0 -2
- package/dist/cjs/components/layout/Show.vue.d.ts +0 -30
- package/dist/cjs/components/menu/Menu.d.ts +0 -2
- package/dist/cjs/components/modal/Modal.d.ts +0 -43
- package/dist/cjs/components/modal/index.d.ts +0 -43
- package/dist/cjs/components/select/Select.vue.d.ts +0 -65
- package/dist/cjs/components/select/index.d.ts +0 -64
- package/dist/cjs/components/table/interface/table.d.ts +0 -36
- package/dist/cjs/components/theme/index.d.ts +0 -1
- package/dist/cjs/components/worker-pool.d.ts +0 -11
- package/dist/cjs/directive/trim.d.ts +0 -5
- package/dist/cjs/hooks/http/index.d.ts +0 -27
- package/dist/cjs/hooks/index.d.ts +0 -2
- package/dist/cjs/hooks/route/index.d.ts +0 -8
- package/dist/cjs/store/index.d.ts +0 -7
- package/dist/cjs/store/modules/Breadcrumb.d.ts +0 -10
- package/dist/cjs/store/modules/DataDictionary.d.ts +0 -33
- package/dist/cjs/store/modules/KeepAlive.d.ts +0 -21
- package/dist/cjs/store/modules/Menu.d.ts +0 -17
- package/dist/cjs/store/modules/NavTab.d.ts +0 -64
- package/dist/cjs/store/modules/Settings.d.ts +0 -43
- package/dist/cjs/store/modules/User.d.ts +0 -21
- package/dist/cjs/store/types.d.ts +0 -7
- package/dist/cjs/utils/get.d.ts +0 -1
- package/dist/cjs/utils/html.d.ts +0 -1
- package/dist/cjs/utils/index.d.ts +0 -3
- package/dist/cjs/utils/install.d.ts +0 -4
- package/dist/esm/_virtual/_plugin-vue_export-helper.esm.js +0 -9
- package/dist/esm/components/components.d.ts +0 -8
- package/dist/esm/components/desensitize/Desensitize.d.ts +0 -39
- package/dist/esm/components/desensitize/index.d.ts +0 -39
- package/dist/esm/components/dic/DicReplace.d.ts +0 -23
- package/dist/esm/components/dic/index.d.ts +0 -23
- package/dist/esm/components/form/Form.vue.d.ts +0 -4
- package/dist/esm/components/form/Form.vue.esm.js +0 -20
- package/dist/esm/components/form/Form.vue.esm2.js +0 -6
- package/dist/esm/components/form/grid-form/GridForm.d.ts +0 -2
- package/dist/esm/components/form/grid-form/GridForm.esm.js +0 -9
- package/dist/esm/components/form/index.d.ts +0 -11
- package/dist/esm/components/grid/Grid.d.ts +0 -32
- package/dist/esm/components/grid/GridItem.d.ts +0 -2
- package/dist/esm/components/grid/index.d.ts +0 -32
- package/dist/esm/components/index.d.ts +0 -15
- package/dist/esm/components/layout/Breadcrumb.vue.d.ts +0 -2
- package/dist/esm/components/layout/FuckMain.vue.d.ts +0 -20
- package/dist/esm/components/layout/List.vue.d.ts +0 -4
- package/dist/esm/components/layout/Main.vue.d.ts +0 -28
- package/dist/esm/components/layout/NavTabs.vue.d.ts +0 -2
- package/dist/esm/components/layout/Show.vue.d.ts +0 -30
- package/dist/esm/components/menu/Menu.d.ts +0 -2
- package/dist/esm/components/modal/Modal.d.ts +0 -43
- package/dist/esm/components/modal/index.d.ts +0 -43
- package/dist/esm/components/select/Select.vue.d.ts +0 -65
- package/dist/esm/components/select/index.d.ts +0 -64
- package/dist/esm/components/table/interface/table.d.ts +0 -36
- package/dist/esm/components/theme/index.d.ts +0 -1
- package/dist/esm/components/worker-pool.d.ts +0 -11
- package/dist/esm/directive/trim.d.ts +0 -5
- package/dist/esm/hooks/http/index.d.ts +0 -27
- package/dist/esm/hooks/index.d.ts +0 -2
- package/dist/esm/hooks/route/index.d.ts +0 -8
- package/dist/esm/store/index.d.ts +0 -7
- package/dist/esm/store/modules/Breadcrumb.d.ts +0 -10
- package/dist/esm/store/modules/DataDictionary.d.ts +0 -33
- package/dist/esm/store/modules/KeepAlive.d.ts +0 -21
- package/dist/esm/store/modules/Menu.d.ts +0 -17
- package/dist/esm/store/modules/NavTab.d.ts +0 -64
- package/dist/esm/store/modules/Settings.d.ts +0 -43
- package/dist/esm/store/modules/User.d.ts +0 -21
- package/dist/esm/store/types.d.ts +0 -7
- package/dist/esm/utils/get.d.ts +0 -1
- package/dist/esm/utils/html.d.ts +0 -1
- package/dist/esm/utils/index.d.ts +0 -3
- package/dist/esm/utils/install.d.ts +0 -4
- package/src/components/form/Form.vue +0 -10
- package/src/components/form/grid-form/GridForm.jsx +0 -10
- package/src/components/layout/Layout.jsx +0 -24
- package/src/components/table/Table.jsx +0 -338
- package/src/components/table/index.js +0 -4
- package/src/components/worker-pool.js +0 -39
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./form/index.cjs.js"),e=require("./layout/index.cjs.js"),r=require("./table/index.cjs.js"),D=require("./grid/index.cjs.js"),n=require("./select/index.cjs.js"),t=require("./desensitize/index.cjs.js"),o=require("./dic/index.cjs.js"),c=require("./modal/index.cjs.js");exports.DForm=i.default;exports.DQueryForm=i.DQueryForm;exports.DFuckMain=e.DFuckMain;exports.DList=e.DList;exports.DMain=e.DMain;exports.DNavTabs=e.DNavTabs;exports.DShow=e.DShow;exports.DTable=r.DTable;exports.DGrid=D.DGrid;exports.DGridItem=D.DGridItem;exports.DSelect=n.DSelect;exports.DDesensitize=t.DDesensitize;exports.DicReplace=o.DDicReplace;exports.DModal=c.DModal;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),r=e.defineComponent({name:"DQueryForm",props:{scheme:{type:Object,default:()=>({})}},setup(u,{slots:t}){return()=>e.createVNode(e.Fragment,null,[t.default&&t.default()])}});exports.default=r;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const r=require("../../utils/install.cjs.js"),t=require("./DQueryForm.cjs.js"),e=r.default(t.default),u={DQueryForm:e};exports.DQueryForm=e;exports.default=u;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const D=require("pinia"),d=require("pinia-plugin-persistedstate"),l=require("./components.cjs.js"),m=require("../directive/trim.cjs.js"),q=require("./table/index.cjs.js"),x=require("./select/index.cjs.js"),$=require("./desensitize/index.cjs.js"),M=require("./dic/index.cjs.js"),S=require("./modal/index.cjs.js"),s=require("./form/index.cjs.js"),o=require("./grid/index.cjs.js"),e=require("./layout/index.cjs.js"),r=l,c=function(i,u){Object.keys(r).forEach(a=>{const n=r[a];n.install&&i.use(n)});const t=D.createPinia();t.use(d.createPersistedState({storage:sessionStorage})),i.use(t),i.directive("trim",m.default),i.provide("menuIcon",u.menuIcon||{})},b={install:c};exports.DTable=q.DTable;exports.DSelect=x.DSelect;exports.DDesensitize=$.DDesensitize;exports.DicReplace=M.DDicReplace;exports.DModal=S.DModal;exports.DForm=s.default;exports.DQueryForm=s.DQueryForm;exports.DGrid=o.DGrid;exports.DGridItem=o.DGridItem;exports.DFuckMain=e.DFuckMain;exports.DList=e.DList;exports.DMain=e.DMain;exports.DNavTabs=e.DNavTabs;exports.DShow=e.DShow;exports.default=b;exports.install=c;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),w=require("@vueuse/core"),N=require("../../store/modules/Settings.cjs.js"),V=require("pinia"),C=require("vue-router"),E={class:"ditari-list-layout"},R={ref:"contentRef",class:"wrapper"},b={style:{height:"100%"}},k={class:"ditari-content-extra"},q={name:"DListLayout"},x=e.defineComponent({...q,emits:["refresh"],setup(z,{emit:u}){const n=e.useSlots(),h=N.useSettingsStore(),_=C.useRoute(),a=e.inject("configProvider"),{refresh:i}=V.storeToRefs(h),p=e.ref(),o=e.ref(),f=16,r=e.ref(!1),c=e.ref(0);let l;e.watch(()=>a==null?void 0:a.componentSize,t=>{r.value=!1,setTimeout(()=>{var s;c.value=(s=o==null?void 0:o.value)==null?void 0:s.offsetHeight,r.value=!0},100)}),S();function S(){_.name?(e.onActivated(()=>{i.value&&(i.value=!1,u("refresh")),l=d()}),e.onDeactivated(()=>{l()})):(l=d(),e.onUnmounted(()=>{l()}))}function d(){return e.watch(()=>i.value,t=>{t&&u("refresh")})}const m=e.ref(null),{height:g}=w.useElementSize(m);return e.watch(()=>g.value,t=>{r.value=!1,setTimeout(()=>{var s;c.value=(s=o==null?void 0:o.value)==null?void 0:s.offsetHeight,r.value=!0},10)}),(t,s)=>{const v=e.resolveComponent("a-card"),y=e.resolveComponent("a-space");return e.openBlock(),e.createElementBlock("div",E,[e.createElementVNode("div",R,[e.createVNode(v,{ref_key:"formRef",ref:m,bordered:!1,class:e.normalizeClass({"ditari-list-form":e.unref(n).form}),style:e.normalizeStyle({"margin-bottom":e.unref(n).form?f+"px":0})},{default:e.withCtx(()=>[e.renderSlot(t.$slots,"form")]),_:3},8,["class","style"]),e.createVNode(v,{class:"ditari-list-table",bordered:!1},{default:e.withCtx(()=>[e.createElementVNode("div",{ref_key:"toolsRef",ref:p,class:"xi-tools",style:e.normalizeStyle({"margin-bottom":e.unref(n).tools?f+"px":0})},[e.createVNode(y,null,{default:e.withCtx(()=>[e.renderSlot(t.$slots,"tools")]),_:3})],4),e.createElementVNode("div",{ref_key:"tableRef",ref:o,style:{flex:"1"}},[e.withDirectives(e.createElementVNode("div",b,[e.renderSlot(t.$slots,"table",{height:c.value})],512),[[e.vShow,r.value]])],512)]),_:3})],512),e.createElementVNode("div",k,[e.renderSlot(t.$slots,"default")])])}}});exports.default=x;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),h=require("vue-router"),f=require("pinia"),K=require("../../store/modules/Menu.cjs.js"),U=require("../../store/modules/Settings.cjs.js");function j(o){return typeof o=="function"||Object.prototype.toString.call(o)==="[object Object]"&&!t.isVNode(o)}const q=t.defineComponent({name:"DMenu",setup(){const o=h.useRouter(),g=h.useRoute(),{componentName:c,prop:
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),h=require("vue-router"),f=require("pinia"),K=require("../../store/modules/Menu.cjs.js"),U=require("../../store/modules/Settings.cjs.js");function j(o){return typeof o=="function"||Object.prototype.toString.call(o)==="[object Object]"&&!t.isVNode(o)}const q=t.defineComponent({name:"DMenu",setup(){const o=h.useRouter(),g=h.useRoute(),{componentName:c,prop:S}=t.inject("menuIcon"),N=K.useMenuStore(),{list:s,openMenusKeys:u,selectedMenuKeys:l}=f.storeToRefs(N),V=U.useSettingsStore(),{getCollapsed:a}=f.storeToRefs(V);t.watchEffect(()=>{if(a.value)return;const e=l.value.length>0?l.value[0]:"",n=i(s.value,e);u.value=n||[]});function i(e,n){for(let r=0;r<e.length;r++){if(e[r].url===n||n.startsWith(e[r].url))return[e[r].url];if(e[r].children&&e[r].children.length>0){const v=i(e[r].children,n);if(v)return[e[r].url,...v]}}return null}const m=({key:e,keyPath:n})=>{u.value=n,l.value=[e],g.path!==e&&o.push(e).then(r=>r?console.warn(r):null)},M=e=>t.createVNode(t.Fragment,null,[t.createVNode(t.resolveComponent("a-menu-item"),{key:e.url},{icon:()=>d(e),default:()=>e.title})]),y=["anticon","anticon-menu","ant-menu-item-icon"],d=e=>t.createVNode(t.Fragment,null,[e.icon?C(e.icon):t.withDirectives(t.createVNode("div",{class:y},[e.title.substring(0,1)]),[[t.vShow,a.value]])]),C=e=>c==="nativeHtml"?t.createVNode("span",{innerHTML:e},null):t.h(t.resolveComponent(c),{[`${S}`]:e}),p=e=>t.createVNode(t.Fragment,null,[t.createVNode(t.resolveComponent("a-sub-menu"),{key:e.url},{title:()=>e.title,icon:()=>d(e),default:()=>e.children.map(n=>!n.children||n.children.length===0?b(n):p(n))})]),b=e=>t.createVNode(t.Fragment,null,[t.createVNode(t.resolveComponent("a-menu-item"),{key:e.url},{default:()=>e.title})]);return()=>{let e;return t.createVNode(t.Fragment,null,[t.createVNode(t.resolveComponent("a-menu"),{mode:"inline",theme:"dark",openKeys:u.value,"onUpdate:openKeys":n=>u.value=n,selectedKeys:l.value,"onUpdate:selectedKeys":n=>l.value=n,onClick:m},j(e=s.value.map(n=>{var r;return!n.children||((r=n.children)==null?void 0:r.length)===0?M(n):p(n)}))?e:{default:()=>[e]})])}}});exports.default=q;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const t=require("vue"),R=require("ant-design-vue"),T=require("../../utils/html.cjs.js"),M=require("../theme/index.cjs.js"),Q=()=>({data:{type:Object,required:!0},height:{type:Number,default:300},keys:Array,rowKey:{type:String,default:"id"},loading:{type:Boolean,default:!1},pagination:{type:Object,default:()=>({})},config:{type:Object,default:()=>({})},expandedRowKeys:{type:Object,default:()=>[]},defaultExpandAllRows:Boolean,default:()=>!0}),b={defaultPageSize:20,hideOnSinglePage:!1,pageSizeOptions:["10","20","30","40"],responsive:!0,showQuickJumper:!0,showLessItems:!0,showTotal:a=>`总共 ${a} 条`},P=`${M.prefixName}-pagination`,I=t.defineComponent({name:"DTable",props:Q(),emits:["update:keys"],setup:function(a,{emit:p,slots:d}){const n=t.ref(a.keys||[]),E=t.computed(()=>a.data),z=t.computed(()=>{var e;return((e=a.config)==null?void 0:e.columns)??[]}),m=t.computed(()=>{var e;return((e=a.config)==null?void 0:e.pagination)??{}}),S=t.ref(a.expandedRowKeys);t.watchEffect(()=>{const{expandedRowKeys:e}=a;S.value=e});const{tableRef:K,tableRootRef:O,tableHeight:B,onPageChange:V,onRowClassName:H}=j();function j(){const{rowClassName:e,keepSelected:l,onPageChange:i}=a.config,f=a.config.selection??"N",r=t.ref(),u=t.ref(null),o=t.ref(),c=t.ref(null),g=s=>{var h,x;try{const y=(h=u==null?void 0:u.value)==null?void 0:h.$el,$=T.useEleHeight(y.getElementsByClassName("ant-table-header")[0]);let N=0;if(a.config.pagination){const J=(x=r.value)==null?void 0:x.getElementsByClassName(P)[0];N=T.useEleHeight(J)??0}o.value=s-($+N),y.getElementsByClassName("ant-table-body")[0].style.height=o.value+"px",c.value=y.getElementsByClassName("ant-table-body")[0]}catch(y){console.warn(y)}};return t.watchEffect(()=>{a.height!==0&&t.nextTick(()=>{setTimeout(()=>{g(a.height)},10)})}),{tableRef:u,tableRootRef:r,tableHeight:o,onPageChange:(s,h)=>{i&&i({page:s,size:h}),c.value.scrollTop=0,(f==="S"||!l)&&(n.value=[],p("update:keys",n.value))},onRowClassName:(s,h)=>e?e(s,h):void 0}}const q=D();function D(){const{rowKey:e,config:{getCheckboxProps:l}}=a;let i=a.config.selection??"N";const f=(o,c)=>{i==="S"?(n.value=[],n.value=c?[o[e]]:[]):n.value=c?n.value.concat(o[e]):n.value.filter(g=>g!==o[e]),p("update:keys",n.value)},r=(o,c,g)=>{const v=g.map(w=>w[e]);n.value=o?n.value.concat(v):n.value.filter(w=>!v.includes(w)),p("update:keys",n.value)};t.watch(()=>a.keys,o=>{n.value=o});const u=t.ref(void 0);return t.watchEffect(()=>{const{selection:o}=a.config;i=o,i!=="N"?u.value={selectedRowKeys:n,onSelect:f,onSelectAll:r,fixed:!0,columnTitle:i==="S"?"选择":null,columnWidth:i==="S"?60:40,getCheckboxProps:l}:u.value=void 0}),u}const A=F();function F(){return e=>{let l;const{rowKey:i,config:{click:f,dbClick:r,selection:u,getCheckboxProps:o}}=a,c=e[i],g=()=>{const v=o===void 0?!1:o(e).disabled;if(u==="N"||v)return;n.value.some(s=>s===c)?n.value=n.value.filter(s=>s!==c):(u==="S"&&(n.value=[]),n.value.push(c)),p("update:keys",n.value)};return{onClick:()=>{clearTimeout(l),l=setTimeout(()=>{g(),f&&f(e)},200)},onDblclick:()=>{clearTimeout(l),r&&r(e)}}}}const C=e=>{e.stopPropagation()},U=t.computed(()=>{const{selection:e}=a.config;return e==="N"}),k={};d.expandedRowRender&&(k.expandedRowRender=e=>t.createVNode(t.Fragment,null,[d.expandedRowRender&&d.expandedRowRender(e)]));const _=()=>t.createVNode(t.Fragment,null,[d.summary&&d.summary()]);return()=>{var e;return t.createVNode("div",{ref:O,style:{height:"100%"}},[t.createVNode(R.Table,{ref:K,"row-key":a.rowKey,bordered:a.config.bordered,columns:z.value,dataSource:E.value,loading:a.loading,size:((e=a.config)==null?void 0:e.size)??"small",scroll:{scrollToFirstRowOnChange:!0,x:"100%",y:B.value+"px"},expandedRowKeys:S.value,"onUpdate:expandedRowKeys":l=>S.value=l,expandRowByClick:U.value,defaultExpandAllRows:a.defaultExpandAllRows,pagination:!1,customRow:A,rowSelection:q.value,rowClassName:H},{bodyCell:({column:l,record:i})=>{if(l.slot==="action")return t.createVNode("div",{onClick:C,onDblclick:C},[t.createVNode(R.Space,null,{default:()=>[d.action&&d.action(i)]})])},...k,summary:_}),t.withDirectives(t.createVNode(R.Pagination,{class:[P],current:m.value.current,"onUpdate:current":l=>m.value.current=l,pageSize:m.value.pageSize,"onUpdate:pageSize":l=>m.value.pageSize=l,disabled:a.loading,"show-size-changer":!0,size:"default","hide-on-single-page":b.hideOnSinglePage,"show-quick-jumper":b.showQuickJumper,"default-page-size":b.defaultPageSize,"page-size-options":b.pageSizeOptions,"show-total":b.showTotal,total:m.value.total,onChange:V},null),[[t.vShow,a.config.pagination]])])}}});exports.default=I;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("pinia"),l=require("../types.cjs.js"),r=a.defineStore(l.NAV_TAB_ID,{state:()=>({list:[],activeKey:""}),getters:{getList:t=>t.list,getActiveKey:t=>t.activeKey},actions:{setActiveKey(t){this.activeKey=t},save(t){if(!t.meta.title||this.list.some(i=>i.
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("pinia"),l=require("../types.cjs.js"),r=a.defineStore(l.NAV_TAB_ID,{state:()=>({list:[],activeKey:""}),getters:{getList:t=>t.list,getActiveKey:t=>t.activeKey},actions:{setActiveKey(t){this.activeKey=t},save(t){if(!t.meta.title||this.list.some(i=>i.fullPath===t.fullPath))return;const e={path:t.path,fullPath:t.fullPath,query:t.query,params:t.params,meta:t.meta,name:t.name||""};this.list.push(e)},deleteTabs(t){this.list.splice(this.list.findIndex(s=>s.fullPath===t),1)},setNavTitle(t,s){for(let e=0;e<this.list.length;e++)if(this.list[e].fullPath===s){this.list[e].meta.title=t;break}}},persist:!0});exports.useNavTabsStore=r;
|
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
import { default as
|
|
2
|
-
import { DFuckMain as
|
|
3
|
-
import { DTable as
|
|
4
|
-
import { DGrid as
|
|
5
|
-
import { DSelect as
|
|
6
|
-
import { DDesensitize as
|
|
7
|
-
import { DDicReplace as
|
|
8
|
-
import { DModal as
|
|
1
|
+
import { default as o, DQueryForm as D } from "./form/index.esm.js";
|
|
2
|
+
import { DFuckMain as a, DList as m, DMain as p, DNavTabs as f, DShow as i } from "./layout/index.esm.js";
|
|
3
|
+
import { DTable as c } from "./table/index.esm.js";
|
|
4
|
+
import { DGrid as s, DGridItem as d } from "./grid/index.esm.js";
|
|
5
|
+
import { DSelect as u } from "./select/index.esm.js";
|
|
6
|
+
import { DDesensitize as M } from "./desensitize/index.esm.js";
|
|
7
|
+
import { DDicReplace as G } from "./dic/index.esm.js";
|
|
8
|
+
import { DModal as S } from "./modal/index.esm.js";
|
|
9
9
|
export {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
10
|
+
M as DDesensitize,
|
|
11
|
+
o as DForm,
|
|
12
|
+
a as DFuckMain,
|
|
13
|
+
s as DGrid,
|
|
14
|
+
d as DGridItem,
|
|
15
|
+
m as DList,
|
|
16
|
+
p as DMain,
|
|
17
|
+
S as DModal,
|
|
18
|
+
f as DNavTabs,
|
|
19
|
+
D as DQueryForm,
|
|
20
|
+
u as DSelect,
|
|
21
|
+
i as DShow,
|
|
22
|
+
c as DTable,
|
|
23
|
+
G as DicReplace
|
|
23
24
|
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { defineComponent as r, createVNode as t, Fragment as o } from "vue";
|
|
2
|
+
const a = /* @__PURE__ */ r({
|
|
3
|
+
name: "DQueryForm",
|
|
4
|
+
props: {
|
|
5
|
+
scheme: {
|
|
6
|
+
type: Object,
|
|
7
|
+
default: () => ({})
|
|
8
|
+
}
|
|
9
|
+
},
|
|
10
|
+
setup(p, {
|
|
11
|
+
slots: e
|
|
12
|
+
}) {
|
|
13
|
+
return () => t(o, null, [e.default && e.default()]);
|
|
14
|
+
}
|
|
15
|
+
});
|
|
16
|
+
export {
|
|
17
|
+
a as default
|
|
18
|
+
};
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import o from "../../utils/install.esm.js";
|
|
2
|
-
import r from "./
|
|
3
|
-
|
|
4
|
-
const t = o(r), i = o(m), f = { DForm: t, DGridForm: i };
|
|
2
|
+
import r from "./DQueryForm.esm.js";
|
|
3
|
+
const t = o(r), i = { DQueryForm: t };
|
|
5
4
|
export {
|
|
6
|
-
t as
|
|
7
|
-
i as
|
|
8
|
-
f as default
|
|
5
|
+
t as DQueryForm,
|
|
6
|
+
i as default
|
|
9
7
|
};
|
|
@@ -4,16 +4,16 @@ import * as c from "./components.esm.js";
|
|
|
4
4
|
import a from "../directive/trim.esm.js";
|
|
5
5
|
import { DTable as v } from "./table/index.esm.js";
|
|
6
6
|
import { DSelect as b } from "./select/index.esm.js";
|
|
7
|
-
import { DDesensitize as
|
|
8
|
-
import { DDicReplace as
|
|
9
|
-
import { DModal as
|
|
10
|
-
import { default as G } from "./form/index.esm.js";
|
|
7
|
+
import { DDesensitize as I } from "./desensitize/index.esm.js";
|
|
8
|
+
import { DDicReplace as T } from "./dic/index.esm.js";
|
|
9
|
+
import { DModal as h } from "./modal/index.esm.js";
|
|
10
|
+
import { default as y, DQueryForm as G } from "./form/index.esm.js";
|
|
11
11
|
import { DGrid as R, DGridItem as j } from "./grid/index.esm.js";
|
|
12
|
-
import { DFuckMain as
|
|
13
|
-
const
|
|
14
|
-
Object.keys(
|
|
15
|
-
const
|
|
16
|
-
|
|
12
|
+
import { DFuckMain as z, DList as E, DMain as L, DNavTabs as N, DShow as O } from "./layout/index.esm.js";
|
|
13
|
+
const t = c, f = function(e, i) {
|
|
14
|
+
Object.keys(t).forEach((s) => {
|
|
15
|
+
const r = t[s];
|
|
16
|
+
r.install && e.use(r);
|
|
17
17
|
});
|
|
18
18
|
const o = m();
|
|
19
19
|
o.use(
|
|
@@ -21,23 +21,24 @@ const r = c, f = function(e, i) {
|
|
|
21
21
|
storage: sessionStorage
|
|
22
22
|
})
|
|
23
23
|
), e.use(o), e.directive("trim", a), e.provide("menuIcon", i.menuIcon || {});
|
|
24
|
-
},
|
|
24
|
+
}, u = {
|
|
25
25
|
install: f
|
|
26
26
|
};
|
|
27
27
|
export {
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
28
|
+
I as DDesensitize,
|
|
29
|
+
y as DForm,
|
|
30
|
+
z as DFuckMain,
|
|
31
31
|
R as DGrid,
|
|
32
32
|
j as DGridItem,
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
33
|
+
E as DList,
|
|
34
|
+
L as DMain,
|
|
35
|
+
h as DModal,
|
|
36
|
+
N as DNavTabs,
|
|
37
|
+
G as DQueryForm,
|
|
37
38
|
b as DSelect,
|
|
38
|
-
|
|
39
|
+
O as DShow,
|
|
39
40
|
v as DTable,
|
|
40
|
-
|
|
41
|
-
|
|
41
|
+
T as DicReplace,
|
|
42
|
+
u as default,
|
|
42
43
|
f as install
|
|
43
44
|
};
|
|
@@ -1,104 +1,110 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
1
|
+
import { defineComponent as $, useSlots as B, inject as D, ref as l, watch as m, onUnmounted as E, onActivated as T, onDeactivated as L, resolveComponent as w, openBlock as N, createElementBlock as V, createElementVNode as a, createVNode as d, normalizeClass as W, unref as h, normalizeStyle as R, withCtx as v, renderSlot as n, withDirectives as j, vShow as A } from "vue";
|
|
2
|
+
import { useElementSize as U } from "@vueuse/core";
|
|
3
|
+
import { useSettingsStore as q } from "../../store/modules/Settings.esm.js";
|
|
4
|
+
import { storeToRefs as F } from "pinia";
|
|
5
|
+
import { useRoute as G } from "vue-router";
|
|
6
|
+
const I = { class: "ditari-list-layout" }, J = {
|
|
6
7
|
ref: "contentRef",
|
|
7
8
|
class: "wrapper"
|
|
8
|
-
},
|
|
9
|
+
}, K = { style: { height: "100%" } }, M = { class: "ditari-content-extra" }, O = {
|
|
9
10
|
name: "DListLayout"
|
|
10
|
-
},
|
|
11
|
-
...
|
|
11
|
+
}, te = /* @__PURE__ */ $({
|
|
12
|
+
...O,
|
|
12
13
|
emits: ["refresh"],
|
|
13
|
-
setup(
|
|
14
|
-
const
|
|
15
|
-
let
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
var e;
|
|
19
|
-
f.value = (e = t == null ? void 0 : t.value) == null ? void 0 : e.offsetHeight, s.value = !0;
|
|
20
|
-
}, 1);
|
|
21
|
-
}), g(
|
|
22
|
-
() => i == null ? void 0 : i.componentSize,
|
|
14
|
+
setup(P, { emit: _ }) {
|
|
15
|
+
const i = B(), k = q(), b = G(), f = D("configProvider"), { refresh: c } = F(k), x = l(), t = l(), p = 16, s = l(!1), u = l(0);
|
|
16
|
+
let r;
|
|
17
|
+
m(
|
|
18
|
+
() => f == null ? void 0 : f.componentSize,
|
|
23
19
|
(e) => {
|
|
24
20
|
s.value = !1, setTimeout(() => {
|
|
25
|
-
var
|
|
26
|
-
|
|
21
|
+
var o;
|
|
22
|
+
u.value = (o = t == null ? void 0 : t.value) == null ? void 0 : o.offsetHeight, s.value = !0;
|
|
27
23
|
}, 100);
|
|
28
24
|
}
|
|
29
|
-
),
|
|
30
|
-
function
|
|
31
|
-
|
|
32
|
-
c.value && (c.value = !1,
|
|
33
|
-
}),
|
|
34
|
-
|
|
35
|
-
})) : (
|
|
36
|
-
|
|
25
|
+
), z();
|
|
26
|
+
function z() {
|
|
27
|
+
b.name ? (T(() => {
|
|
28
|
+
c.value && (c.value = !1, _("refresh")), r = g();
|
|
29
|
+
}), L(() => {
|
|
30
|
+
r();
|
|
31
|
+
})) : (r = g(), E(() => {
|
|
32
|
+
r();
|
|
37
33
|
}));
|
|
38
34
|
}
|
|
39
|
-
function
|
|
40
|
-
return
|
|
35
|
+
function g() {
|
|
36
|
+
return m(
|
|
41
37
|
() => c.value,
|
|
42
38
|
(e) => {
|
|
43
|
-
e &&
|
|
39
|
+
e && _("refresh");
|
|
44
40
|
}
|
|
45
41
|
);
|
|
46
42
|
}
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
43
|
+
const y = l(null), { height: C } = U(y);
|
|
44
|
+
return m(
|
|
45
|
+
() => C.value,
|
|
46
|
+
(e) => {
|
|
47
|
+
s.value = !1, setTimeout(() => {
|
|
48
|
+
var o;
|
|
49
|
+
u.value = (o = t == null ? void 0 : t.value) == null ? void 0 : o.offsetHeight, s.value = !0;
|
|
50
|
+
}, 10);
|
|
51
|
+
}
|
|
52
|
+
), (e, o) => {
|
|
53
|
+
const S = w("a-card"), H = w("a-space");
|
|
54
|
+
return N(), V("div", I, [
|
|
55
|
+
a("div", J, [
|
|
56
|
+
d(S, {
|
|
57
|
+
ref_key: "formRef",
|
|
58
|
+
ref: y,
|
|
53
59
|
bordered: !1,
|
|
54
|
-
class:
|
|
55
|
-
style:
|
|
60
|
+
class: W({ "ditari-list-form": h(i).form }),
|
|
61
|
+
style: R({ "margin-bottom": h(i).form ? p + "px" : 0 })
|
|
56
62
|
}, {
|
|
57
|
-
default:
|
|
58
|
-
|
|
63
|
+
default: v(() => [
|
|
64
|
+
n(e.$slots, "form")
|
|
59
65
|
]),
|
|
60
66
|
_: 3
|
|
61
67
|
}, 8, ["class", "style"]),
|
|
62
|
-
d(
|
|
68
|
+
d(S, {
|
|
63
69
|
class: "ditari-list-table",
|
|
64
70
|
bordered: !1
|
|
65
71
|
}, {
|
|
66
|
-
default:
|
|
67
|
-
|
|
72
|
+
default: v(() => [
|
|
73
|
+
a("div", {
|
|
68
74
|
ref_key: "toolsRef",
|
|
69
|
-
ref:
|
|
75
|
+
ref: x,
|
|
70
76
|
class: "xi-tools",
|
|
71
|
-
style:
|
|
77
|
+
style: R({ "margin-bottom": h(i).tools ? p + "px" : 0 })
|
|
72
78
|
}, [
|
|
73
|
-
d(
|
|
74
|
-
default:
|
|
75
|
-
|
|
79
|
+
d(H, null, {
|
|
80
|
+
default: v(() => [
|
|
81
|
+
n(e.$slots, "tools")
|
|
76
82
|
]),
|
|
77
83
|
_: 3
|
|
78
84
|
})
|
|
79
85
|
], 4),
|
|
80
|
-
|
|
86
|
+
a("div", {
|
|
81
87
|
ref_key: "tableRef",
|
|
82
88
|
ref: t,
|
|
83
89
|
style: { flex: "1" }
|
|
84
90
|
}, [
|
|
85
|
-
|
|
86
|
-
|
|
91
|
+
j(a("div", K, [
|
|
92
|
+
n(e.$slots, "table", { height: u.value })
|
|
87
93
|
], 512), [
|
|
88
|
-
[
|
|
94
|
+
[A, s.value]
|
|
89
95
|
])
|
|
90
96
|
], 512)
|
|
91
97
|
]),
|
|
92
98
|
_: 3
|
|
93
99
|
})
|
|
94
100
|
], 512),
|
|
95
|
-
|
|
96
|
-
|
|
101
|
+
a("div", M, [
|
|
102
|
+
n(e.$slots, "default")
|
|
97
103
|
])
|
|
98
104
|
]);
|
|
99
105
|
};
|
|
100
106
|
}
|
|
101
107
|
});
|
|
102
108
|
export {
|
|
103
|
-
|
|
109
|
+
te as default
|
|
104
110
|
};
|
|
@@ -1,25 +1,25 @@
|
|
|
1
|
-
import { defineComponent as j, inject as k, watchEffect as
|
|
1
|
+
import { defineComponent as j, inject as k, watchEffect as I, createVNode as r, Fragment as u, resolveComponent as c, isVNode as N, withDirectives as R, vShow as D, h as H } from "vue";
|
|
2
2
|
import { useRouter as O, useRoute as P } from "vue-router";
|
|
3
|
-
import { storeToRefs as
|
|
3
|
+
import { storeToRefs as g } from "pinia";
|
|
4
4
|
import { useMenuStore as T } from "../../store/modules/Menu.esm.js";
|
|
5
5
|
import { useSettingsStore as V } from "../../store/modules/Settings.esm.js";
|
|
6
6
|
function _(l) {
|
|
7
|
-
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !
|
|
7
|
+
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !N(l);
|
|
8
8
|
}
|
|
9
9
|
const $ = /* @__PURE__ */ j({
|
|
10
10
|
name: "DMenu",
|
|
11
11
|
setup() {
|
|
12
|
-
const l = O(),
|
|
12
|
+
const l = O(), m = P(), {
|
|
13
13
|
componentName: s,
|
|
14
14
|
prop: S
|
|
15
15
|
} = k("menuIcon"), y = T(), {
|
|
16
16
|
list: a,
|
|
17
17
|
openMenusKeys: i,
|
|
18
18
|
selectedMenuKeys: o
|
|
19
|
-
} =
|
|
19
|
+
} = g(y), M = V(), {
|
|
20
20
|
getCollapsed: d
|
|
21
|
-
} =
|
|
22
|
-
|
|
21
|
+
} = g(M);
|
|
22
|
+
I(() => {
|
|
23
23
|
if (d.value)
|
|
24
24
|
return;
|
|
25
25
|
const e = o.value.length > 0 ? o.value[0] : "", t = p(a.value, e);
|
|
@@ -41,14 +41,14 @@ const $ = /* @__PURE__ */ j({
|
|
|
41
41
|
key: e,
|
|
42
42
|
keyPath: t
|
|
43
43
|
}) => {
|
|
44
|
-
i.value = t, o.value = [e],
|
|
44
|
+
i.value = t, o.value = [e], m.path !== e && l.push(e).then((n) => n ? console.warn(n) : null);
|
|
45
45
|
}, C = (e) => r(u, null, [r(c("a-menu-item"), {
|
|
46
46
|
key: e.url
|
|
47
47
|
}, {
|
|
48
48
|
icon: () => f(e),
|
|
49
49
|
default: () => e.title
|
|
50
50
|
})]), K = ["anticon", "anticon-menu", "ant-menu-item-icon"], f = (e) => r(u, null, [e.icon ? U(e.icon) : R(r("div", {
|
|
51
|
-
|
|
51
|
+
class: K
|
|
52
52
|
}, [e.title.substring(0, 1)]), [[D, d.value]])]), U = (e) => s === "nativeHtml" ? r("span", {
|
|
53
53
|
innerHTML: e
|
|
54
54
|
}, null) : H(c(s), {
|