iking-web-ui-pro 0.2.19 → 0.2.21
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/IKExpandCollapse/ik.index.es.js +66 -69
- package/dist/IKExpandCollapse/ik.index.umd.js +1 -1
- package/dist/IKExpandCollapse/style.css +1 -1
- package/dist/IKPreviewFile/ik.index.es.js +100 -103
- package/dist/IKPreviewFile/ik.index.umd.js +1 -1
- package/dist/IKPreviewFile/style.css +1 -1
- package/dist/IKVerticalStepBar/ik.index.es.js +117 -120
- package/dist/IKVerticalStepBar/ik.index.umd.js +3 -3
- package/dist/IKVerticalStepBar/style.css +1 -1
- package/dist/IkApprovalProcessDetail/ik.index.es.js +98 -101
- package/dist/IkApprovalProcessDetail/ik.index.umd.js +1 -1
- package/dist/IkApprovalProcessDetail/style.css +1 -1
- package/dist/IkBaseDialog/ik.index.es.js +106 -109
- package/dist/IkBaseDialog/ik.index.umd.js +1 -1
- package/dist/IkBaseDialog/style.css +1 -1
- package/dist/IkBtnSetting/ik.index.es.js +239 -242
- package/dist/IkBtnSetting/ik.index.umd.js +1 -1
- package/dist/IkBtnSetting/style.css +1 -1
- package/dist/IkCollapseCard/ik.index.es.js +73 -76
- package/dist/IkCollapseCard/ik.index.umd.js +1 -1
- package/dist/IkCollapseCard/style.css +1 -1
- package/dist/IkDescription/ik.index.es.js +103 -106
- package/dist/IkDescription/ik.index.umd.js +1 -1
- package/dist/IkDescription/style.css +1 -1
- package/dist/IkDetailPreviewFiles/ik.index.es.js +87 -90
- package/dist/IkDetailPreviewFiles/ik.index.umd.js +1 -1
- package/dist/IkDetailPreviewFiles/style.css +1 -1
- package/dist/IkIconPicker/ik.index.es.js +138 -141
- package/dist/IkIconPicker/ik.index.umd.js +1 -1
- package/dist/IkIconPicker/style.css +1 -1
- package/dist/IkMonacoEditor/ik.index.es.js +312 -315
- package/dist/IkMonacoEditor/ik.index.umd.js +3 -3
- package/dist/IkMonacoEditor/style.css +1 -1
- package/dist/IkPageFull/ik.index.es.js +1051 -1054
- package/dist/IkPageFull/ik.index.umd.js +2 -2
- package/dist/IkPageFull/style.css +1 -1
- package/dist/IkPreviewFileDialog/ik.index.es.js +87 -90
- package/dist/IkPreviewFileDialog/ik.index.umd.js +1 -1
- package/dist/IkPreviewFileDialog/style.css +1 -1
- package/dist/IkSchedule/ik.index.es.js +2948 -2951
- package/dist/IkSchedule/ik.index.umd.js +1 -1
- package/dist/IkSchedule/style.css +1 -1
- package/dist/IkSideText/ik.index.es.js +91 -94
- package/dist/IkSideText/ik.index.umd.js +1 -1
- package/dist/IkSideText/style.css +1 -1
- package/dist/IkSvgIcon/ik.index.es.js +66 -69
- package/dist/IkSvgIcon/ik.index.umd.js +1 -1
- package/dist/IkSvgIcon/style.css +1 -1
- package/dist/IkUploadFile/ik.index.es.js +98 -101
- package/dist/IkUploadFile/ik.index.umd.js +1 -1
- package/dist/IkUploadFile/style.css +1 -1
- package/dist/IkUploadImage/ik.index.es.js +248 -237
- package/dist/IkUploadImage/ik.index.umd.js +1 -1
- package/dist/IkUploadImage/style.css +1 -1
- package/dist/Provider/ik.index.es.js +10 -14
- package/dist/Provider/ik.index.umd.js +1 -1
- package/dist/index.es.js +14465 -14458
- package/dist/index.umd.js +88 -88
- package/dist/src/components/IkUploadImage/index.d.ts +38 -0
- package/dist/src/components/IkUploadImage/src/index.vue.d.ts +18 -0
- package/dist/src/components/Provider/ProviderConfig.vue.d.ts +0 -9
- package/dist/src/components/Provider/index.d.ts +0 -19
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(_,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("iking-utils-pro"),require("vuedraggable")):typeof define=="function"&&define.amd?define(["exports","vue","iking-utils-pro","vuedraggable"],e):(_=typeof globalThis<"u"?globalThis:_||self,e(_.index={},_.vue,_["iking-utils-pro"],_.vuedraggable))})(this,function(_,e,g,T){"use strict";const v=(l,h)=>{if(l.install=o=>{for(const t of[l,...Object.values(h??{})])o.component(t.name,t)},h)for(const[o,t]of Object.entries(h))l[o]=t;return l};/*! Element Plus Icons Vue v2.3.1 */var j=e.defineComponent({name:"DCaret",__name:"d-caret",setup(l){return(h,o)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"m512 128 288 320H224zM224 576h576L512 896z"})]))}}),L=j;const x=(l,h)=>{const o=l.__vccOpts||l;for(const[t,u]of h)o[t]=u;return o},O={key:0,class:"ik-svg-icon ik-icon-span inline-block inline-flex justify-center box-content line-height-[0]"},M={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},F=["xlink:href"],A=["src"],q={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},W=["xlink:href"],H=["src"],X=e.defineComponent({name:"IkSvgIcon",__name:"index",props:{active:{type:Boolean,default:!1},bg:{type:Boolean,default:!1},color:{},colorLight:{},disabled:{type:Boolean,default:!1},error:{type:Boolean},flip:{},name:{},notip:{type:Boolean,default:!1},opacity:{default:.5},padding:{default:"6px"},primary:{type:Boolean},rotate:{},showBg:{type:Boolean,default:!1},size:{default:""},success:{type:Boolean},tableIconType:{},title:{},type:{},warning:{type:Boolean},width:{}},setup(l){const h=l,o=e.inject("iconConfig"),t=e.computed(()=>({...(o==null?void 0:o.value)||{},...h})),u=e.computed(()=>{const{name:a}=t.value;return/^http?:\/\//.test(a)?"img":/i-[^:]+:[^:]+/.test(a)?"unocss":a!=null&&a.startsWith("iksig")?"iksig":a!=null&&a.includes(":")?"iconify":a!=null&&a.startsWith("iksvg")?"svg":"i"}),i=e.computed(()=>{const a=[];if(t.value.flip)switch(t.value.flip){case"horizontal":a.push("rotateY(180deg)");break;case"vertical":a.push("rotateX(180deg)");break;case"both":a.push("rotateX(180deg)"),a.push("rotateY(180deg)");break}t.value.rotate&&a.push(`rotate(${t.value.rotate%360}deg)`);const B={...t.value.color&&{color:t.value.color},...t.value.size&&{fontSize:typeof t.value.size=="number"?`${t.value.size}px`:t.value.size},...a.length&&{transform:a.join(" ")},padding:t.value.showBg||t.value.bg?t.value.padding:0,...t.value.color&&u.value!=="iksig"?{"--ik-color-icon-dark":t.value.color,"--ik-color-icon-light":t.value.colorLight||g.ikColor.setOpacity(t.value.color,t.value.opacity)}:{}};return t.value.width&&(B.width=B.height=typeof t.value.width=="number"?`${t.value.width}px`:t.value.width),B});return(a,B)=>{const S=e.resolveComponent("el-tooltip"),p=e.resolveComponent("el-button");return t.value.tableIconType==="icon"||!t.value.tableIconType?(e.openBlock(),e.createElementBlock("span",O,[t.value.notip||!t.value.title?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[a.name]:u.value==="unocss","show-bg":t.value.showBg||t.value.bg,default:t.value.size==="default",small:t.value.size==="small",big:t.value.size==="big",warning:t.value.warning||t.value.type==="warning",primary:t.value.primary||t.value.type==="primary",success:a.success||t.value.type==="success",error:t.value.error||t.value.type==="error",active:t.value.active,disabled:t.value.disabled}]),style:e.normalizeStyle(i.value)},[e.createCommentVNode(` <Icon v-if="outputType === 'iconify'" :icon="name" /> `),u.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${t.value.name}`),style:e.normalizeStyle(i.value)},null,6)):u.value==="svg"?(e.openBlock(),e.createElementBlock("svg",M,[e.createElementVNode("use",{"xlink:href":`#${t.value.name}`},null,8,F)])):u.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.name,class:"h-[1em] w-[1em]"},null,8,A)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(t.value.name),style:e.normalizeStyle(i.value)},null,6))],6)):(e.openBlock(),e.createBlock(S,{key:1,content:t.value.title,placement:"top"},{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[a.name]:u.value==="unocss","show-bg":t.value.showBg||t.value.bg,default:t.value.size==="default",small:t.value.size==="small",big:t.value.size==="big",warning:t.value.warning||t.value.type==="warning",primary:a.primary||t.value.type==="primary",success:a.success||t.value.type==="success",error:t.value.error||t.value.type==="error",active:t.value.active}]),style:e.normalizeStyle(i.value)},[u.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${t.value.name}`),style:e.normalizeStyle(i.value)},null,6)):u.value==="svg"?(e.openBlock(),e.createElementBlock("svg",q,[e.createElementVNode("use",{"xlink:href":`#${t.value.name}`},null,8,W)])):u.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.name,class:"h-[1em] w-[1em]"},null,8,H)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(t.value.name),style:e.normalizeStyle(i.value)},null,6))],6)]),_:1},8,["content"]))])):(e.openBlock(),e.createBlock(p,{key:1,type:["warning","error"].includes(t.value.type)?"danger":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.value.title),1)]),_:1},8,["type"]))}}}),oe="",Y=v(x(X,[["__scopeId","data-v-ec9fdc8a"]])),E={animation:200,group:"gl",disabled:!1,ghostClass:"ghost",sort:!0,delay:100,showIcon:!0,itemStyle:{radius:4,bottom:8,background:"var(--ik-sub-sidebar-menu-bg)"}},R={list:{required:!0,type:Array,default:[]},group:{type:String,default:"draggable"},sort:{type:Boolean,default:!0},showIcon:{type:Boolean,default:!0},delay:{type:Number,default:0},touchStartThreshold:{type:Number,default:0},disabled:{type:Boolean,default:!1},animation:{type:Number,default:200},handle:{type:String,default:".mover"},filter:{type:String,default:".unmover"},draggable:{type:String,default:".item"},ghostClass:{type:String,default:"ghost"},chosenClass:{type:String,default:"chosen"},dragClass:{type:String,default:"drag"},forceFallback:{type:Boolean,default:!1},fallbackClass:{type:String,default:"fallback"},fallbackOnBody:{type:Boolean,default:!1},fallbackTolerance:{type:Number,default:8},scroll:{type:Boolean,default:!0},scrollFn:{type:Function,default:()=>{}},scrollFensitivity:{type:Number,default:30},scrollSpeed:{type:Number,default:30},itemClass:{type:String,default:""},groupClass:{type:String,default:""},itemStyle:{type:Object,default:()=>({radius:{type:Number,default:30},bottom:{type:Number,default:8},background:{type:String,default:"var(--ik-sub-sidebar-menu-bg)"}})}},G=e.defineComponent({__name:"IkDragList",props:R,emits:["change"],setup(l,{emit:h}){const o=l,t=h,u=e.ref([]);e.watch(()=>o.list,p=>{u.value=g._.cloneDeep(p)},{immediate:!0,deep:!0});const i=e.computed(()=>({...E,...o,itemStyle:{...E.itemStyle,...o.itemStyle}})),a=e.ref(!1),B=()=>{a.value=!0},S=p=>{a.value=!1;const w=o.list[p.oldIndex];t("change",u.value,{...w,oldIndex:p.oldIndex,newIndex:p.newIndex})};return(p,w)=>{const f=e.resolveComponent("el-icon");return e.openBlock(),e.createBlock(e.unref(T),{modelValue:u.value,"onUpdate:modelValue":w[0]||(w[0]=r=>u.value=r),class:e.normalizeClass(["list-group",[i.value.groupClass]]),tag:"ul",attrs:i.value,animation:i.value.animation,group:i.value.group,disabled:i.value.disabled,"ghost-class":i.value.ghostClass,"force-fallback":i.value.ghostClass,"item-key":"order",onStart:B,onEnd:S},{item:e.withCtx(({element:r})=>[e.createVNode(e.Transition,{type:"transition",name:"flip-list"},{default:e.withCtx(()=>[p.$slots.item?e.renderSlot(p.$slots,"item",{key:0,item:r},void 0,!0):(e.openBlock(),e.createElementBlock("li",{key:1,class:e.normalizeClass(["list-group-item",[i.value.itemClass]]),style:e.normalizeStyle({borderRadius:`${i.value.itemStyle.radius}px`,marginBottom:`${i.value.itemStyle.bottom}px`,backgroundColor:`${i.value.itemStyle.background}`})},[i.value.showIcon&&!p.$slots.icon?(e.openBlock(),e.createBlock(f,{key:0},{default:e.withCtx(()=>[e.createVNode(e.unref(L))]),_:1})):e.renderSlot(p.$slots,"icon",{key:1},void 0,!0),e.createTextVNode(" "+e.toDisplayString(r.label),1)],6))]),_:2},1024)]),_:3},8,["modelValue","class","attrs","animation","group","disabled","ghost-class","force-fallback"])}}}),se="",J=v(x(G,[["__scopeId","data-v-3716c05e"]])),K=(l=>(e.pushScopeId("data-v-b5ed17ed"),l=l(),e.popScopeId(),l))(()=>e.createElementVNode("i",{class:"ik ik-shezhi"},null,-1)),Q={class:"check-right"},Z={class:"dialog-footer"},U=e.defineComponent({__name:"IkBtnSetting",props:e.mergeModels({list:{type:Array,default:()=>[]},tab:{type:[String,Number],default:""},type:{type:String,default:"primary"},btnType:{type:String,default:"icon"},circle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},role:{type:String,default:""},config:{type:Object,default:()=>({t:l=>l,dialog:{l:"700px",sl:"600px"},path:"user_0",user:{id:"111"}})}},{modelValue:{type:Array,default:()=>[]},modelModifiers:{}}),emits:e.mergeModels(["sort"],["update:modelValue"]),setup(l,{emit:h}){const o=l,t=h,u=e.useModel(l,"modelValue"),{t:i,dialog:a,path:B,user:S}=o.config,p=e.computed(()=>`${S==null?void 0:S.id}_${B}${o.tab!==""?`_${o.tab}`:""}`),w=e.ref([]),f=e.ref([]),r=e.ref([]),V=new Map,I=e.ref(!1),P=e.computed(()=>{const c=f.value.length&&f.value.length!==o.list.length;return!c&&f.value.length&&(I.value=!0),!!c}),N=c=>{var d;const n=g._.cloneDeep(r.value);n==null||n.forEach(s=>{var b;if(!f.value.length)r.value=[];else if(!f.value.includes(s==null?void 0:s.key)){const k=(b=r.value)==null?void 0:b.findIndex(m=>m.key===s.key);k!==-1&&r.value.splice(k,1),s.show=!1,V.set(s.key,s)}}),f.value.forEach(s=>{var k;if(((k=r.value)==null?void 0:k.findIndex(m=>(m==null?void 0:m.key)===s))===-1){const m=V.get(s);m&&(m.show=!0,r.value.push(m))}}),(d=r.value)!=null&&d.length||(r.value=g._.cloneDeep(o.list)),c===!0&&(t("sort",g._.cloneDeep(r.value)),u.value=g._.cloneDeep(r.value))},ee=c=>{if(c)f.value=o.list.map(n=>n.key);else{const n=o.list.find(d=>!d.key||d.label==="操作");f.value=n?[n.key]:[]}N()},z=()=>{const c=g.ikStore.local.getItem(p.value);try{const n=g._.cloneDeep(o==null?void 0:o.list);if((!c||!(c!=null&&c.length))&&g.ikStore.local.setItem(p.value,n.map(({show:d,type:s,key:b,label:k,width:m,minWidth:y,align:ae})=>({show:d,key:b,type:s,label:k,width:m,minWidth:y,align:ae}))),w.value=[...(n==null?void 0:n.map(d=>(V.set(d.key,d),{...d,show:d.show||!1})))||[]],c){const d=c.filter(s=>s.show).map(s=>s.key);f.value=[...d]}else{const d=w.value.filter(s=>s.show);f.value=d.map(s=>s.key)}N(!0)}catch(n){console.info("error: ",n)}};z(),e.watch(()=>o.list,()=>{z()},{deep:!0});const C=e.ref(!1),D=()=>{C.value=!0},te=c=>{r.value=c},le=()=>{C.value=!1,g.ikStore.local.setItem(p.value,r.value.map(({show:c,key:n,label:d,value:s,width:b,minWidth:k,align:m})=>({show:c,key:n,label:d,value:s,width:b,minWidth:k,align:m}))),t("sort",g._.cloneDeep(r.value)),u.value=g._.cloneDeep(r.value)};return(c,n)=>{const d=e.resolveComponent("el-button"),s=e.resolveComponent("el-checkbox"),b=e.resolveComponent("el-checkbox-group"),k=e.resolveComponent("el-dialog"),m=e.resolveDirective("role");return e.openBlock(),e.createElementBlock(e.Fragment,null,[l.btnType==="button"?e.withDirectives((e.openBlock(),e.createBlock(d,e.mergeProps({key:0},c.$attrs,{circle:l.circle,type:l.type,style:{minWidth:l.circle?"40px":"",minHeight:l.circle?"40px":""},onClick:D}),e.createSlots({icon:e.withCtx(()=>[K]),_:2},[l.circle?void 0:{name:"default",fn:e.withCtx(()=>[e.createCommentVNode(' {{ t("action.setting") }} '),e.createTextVNode(" "+e.toDisplayString(e.unref(i)("设置")),1)]),key:"0"}]),1040,["circle","type","style"])),[[m,c.$props.role]]):e.createCommentVNode("v-if",!0),l.btnType==="icon"?e.withDirectives((e.openBlock(),e.createBlock(e.unref(Y),e.mergeProps({key:1,name:"iksvg_shezhi-daohang","show-bg":"",size:"default"},c.$attrs,{onClick:D}),null,16)),[[m,c.$props.role]]):e.createCommentVNode("v-if",!0),e.createVNode(k,{modelValue:C.value,"onUpdate:modelValue":n[3]||(n[3]=y=>C.value=y),draggable:"",width:l.inline?e.unref(a).l:e.unref(a).sl,"close-on-click-modal":!1,"close-on-press-escape":!1,title:"显示字段","append-to-body":"",onOpen:z},{footer:e.withCtx(()=>[e.createElementVNode("div",Z,[e.createVNode(d,{onClick:n[2]||(n[2]=y=>C.value=!1)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(i)("关闭"))+" ",1),e.createCommentVNode(' {{ t("action.close") }} ')]),_:1}),e.createVNode(d,{type:"primary",disabled:r.value.length<2,onClick:le},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(r.value.length<2?"至少选择一个字段":e.unref(i)("确定")),1)]),_:1},8,["disabled"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["view-fields",[l.inline?null:"un-inline"]])},[e.createElementVNode("div",{style:e.normalizeStyle({flex:l.inline?2:1})},[e.createVNode(s,{modelValue:I.value,"onUpdate:modelValue":n[0]||(n[0]=y=>I.value=y),class:"single-line",indeterminate:P.value,onChange:ee},{default:e.withCtx(()=>[e.createTextVNode(" 全选 ")]),_:1},8,["modelValue","indeterminate"]),e.createVNode(b,{modelValue:f.value,"onUpdate:modelValue":n[1]||(n[1]=y=>f.value=y),onChange:N},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,y=>(e.openBlock(),e.createBlock(s,{key:y.key,disabled:!y.key,label:y.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(y.label),1)]),_:2},1032,["disabled","label"]))),128))]),_:1},8,["modelValue"])],4),e.createElementVNode("div",Q,[e.createVNode(e.unref(J),{list:r.value,"item-style":{bottom:4},onChange:te},null,8,["list"])])],2)]),_:1},8,["modelValue","width"])],64)}}}),ce="",$=v(x(U,[["__scopeId","data-v-b5ed17ed"]]));_.IkBtnSetting=$,_.default=$,Object.defineProperties(_,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
1
|
+
(function(k,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("iking-utils-pro"),require("vuedraggable")):typeof define=="function"&&define.amd?define(["exports","vue","iking-utils-pro","vuedraggable"],e):(k=typeof globalThis<"u"?globalThis:k||self,e(k.index={},k.vue,k["iking-utils-pro"],k.vuedraggable))})(this,function(k,e,y,T){"use strict";const v=(a,g)=>{if(a.install=t=>{for(const c of[a,...Object.values(g??{})])t.component(c.name,c)},g)for(const[t,c]of Object.entries(g))a[t]=c;return a};/*! Element Plus Icons Vue v2.3.1 */var j=e.defineComponent({name:"DCaret",__name:"d-caret",setup(a){return(g,t)=>(e.openBlock(),e.createElementBlock("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 1024 1024"},[e.createElementVNode("path",{fill:"currentColor",d:"m512 128 288 320H224zM224 576h576L512 896z"})]))}}),L=j;const x=(a,g)=>{const t=a.__vccOpts||a;for(const[c,d]of g)t[c]=d;return t},O={key:0,class:"ik-svg-icon ik-icon-span inline-block inline-flex justify-center box-content line-height-[0]"},M={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},F=["xlink:href"],A=["src"],q={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},W=["xlink:href"],H=["src"],X=e.defineComponent({name:"IkSvgIcon",__name:"index",props:{active:{type:Boolean,default:!1},bg:{type:Boolean,default:!1},color:{},colorLight:{},disabled:{type:Boolean,default:!1},error:{type:Boolean},flip:{},name:{},notip:{type:Boolean,default:!1},opacity:{default:.5},padding:{default:"6px"},primary:{type:Boolean},rotate:{},showBg:{type:Boolean,default:!1},size:{default:""},success:{type:Boolean},tableIconType:{},title:{},type:{},warning:{type:Boolean},width:{}},setup(a){const g=a,t=e.computed(()=>g),c=e.computed(()=>{const{name:l}=t.value;return/^http?:\/\//.test(l)?"img":/i-[^:]+:[^:]+/.test(l)?"unocss":l!=null&&l.startsWith("iksig")?"iksig":l!=null&&l.includes(":")?"iconify":l!=null&&l.startsWith("iksvg")?"svg":"i"}),d=e.computed(()=>{const l=[];if(t.value.flip)switch(t.value.flip){case"horizontal":l.push("rotateY(180deg)");break;case"vertical":l.push("rotateX(180deg)");break;case"both":l.push("rotateX(180deg)"),l.push("rotateY(180deg)");break}t.value.rotate&&l.push(`rotate(${t.value.rotate%360}deg)`);const _={...t.value.color&&{color:t.value.color},...t.value.size&&{fontSize:typeof t.value.size=="number"?`${t.value.size}px`:t.value.size},...l.length&&{transform:l.join(" ")},padding:t.value.showBg||t.value.bg?t.value.padding:0,...t.value.color&&c.value!=="iksig"?{"--ik-color-icon-dark":t.value.color,"--ik-color-icon-light":t.value.colorLight||y.ikColor.setOpacity(t.value.color,t.value.opacity)}:{}};return t.value.width&&(_.width=_.height=typeof t.value.width=="number"?`${t.value.width}px`:t.value.width),_});return(l,_)=>{const S=e.resolveComponent("el-tooltip"),w=e.resolveComponent("el-button");return t.value.tableIconType==="icon"||!t.value.tableIconType?(e.openBlock(),e.createElementBlock("span",O,[t.value.notip||!t.value.title?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[l.name]:c.value==="unocss","show-bg":t.value.showBg||t.value.bg,default:t.value.size==="default",small:t.value.size==="small",big:t.value.size==="big",warning:t.value.warning||t.value.type==="warning",primary:t.value.primary||t.value.type==="primary",success:l.success||t.value.type==="success",error:t.value.error||t.value.type==="error",active:t.value.active,disabled:t.value.disabled}]),style:e.normalizeStyle(d.value)},[e.createCommentVNode(` <Icon v-if="outputType === 'iconify'" :icon="name" /> `),c.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${t.value.name}`),style:e.normalizeStyle(d.value)},null,6)):c.value==="svg"?(e.openBlock(),e.createElementBlock("svg",M,[e.createElementVNode("use",{"xlink:href":`#${t.value.name}`},null,8,F)])):c.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.name,class:"h-[1em] w-[1em]"},null,8,A)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(t.value.name),style:e.normalizeStyle(d.value)},null,6))],6)):(e.openBlock(),e.createBlock(S,{key:1,content:t.value.title,placement:"top"},{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[l.name]:c.value==="unocss","show-bg":t.value.showBg||t.value.bg,default:t.value.size==="default",small:t.value.size==="small",big:t.value.size==="big",warning:t.value.warning||t.value.type==="warning",primary:l.primary||t.value.type==="primary",success:l.success||t.value.type==="success",error:t.value.error||t.value.type==="error",active:t.value.active}]),style:e.normalizeStyle(d.value)},[c.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${t.value.name}`),style:e.normalizeStyle(d.value)},null,6)):c.value==="svg"?(e.openBlock(),e.createElementBlock("svg",q,[e.createElementVNode("use",{"xlink:href":`#${t.value.name}`},null,8,W)])):c.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:t.value.name,class:"h-[1em] w-[1em]"},null,8,H)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(t.value.name),style:e.normalizeStyle(d.value)},null,6))],6)]),_:1},8,["content"]))])):(e.openBlock(),e.createBlock(w,{key:1,type:["warning","error"].includes(t.value.type)?"danger":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(t.value.title),1)]),_:1},8,["type"]))}}}),oe="",Y=v(x(X,[["__scopeId","data-v-a7ec508a"]])),E={animation:200,group:"gl",disabled:!1,ghostClass:"ghost",sort:!0,delay:100,showIcon:!0,itemStyle:{radius:4,bottom:8,background:"var(--ik-sub-sidebar-menu-bg)"}},R={list:{required:!0,type:Array,default:[]},group:{type:String,default:"draggable"},sort:{type:Boolean,default:!0},showIcon:{type:Boolean,default:!0},delay:{type:Number,default:0},touchStartThreshold:{type:Number,default:0},disabled:{type:Boolean,default:!1},animation:{type:Number,default:200},handle:{type:String,default:".mover"},filter:{type:String,default:".unmover"},draggable:{type:String,default:".item"},ghostClass:{type:String,default:"ghost"},chosenClass:{type:String,default:"chosen"},dragClass:{type:String,default:"drag"},forceFallback:{type:Boolean,default:!1},fallbackClass:{type:String,default:"fallback"},fallbackOnBody:{type:Boolean,default:!1},fallbackTolerance:{type:Number,default:8},scroll:{type:Boolean,default:!0},scrollFn:{type:Function,default:()=>{}},scrollFensitivity:{type:Number,default:30},scrollSpeed:{type:Number,default:30},itemClass:{type:String,default:""},groupClass:{type:String,default:""},itemStyle:{type:Object,default:()=>({radius:{type:Number,default:30},bottom:{type:Number,default:8},background:{type:String,default:"var(--ik-sub-sidebar-menu-bg)"}})}},G=e.defineComponent({__name:"IkDragList",props:R,emits:["change"],setup(a,{emit:g}){const t=a,c=g,d=e.ref([]);e.watch(()=>t.list,p=>{d.value=y._.cloneDeep(p)},{immediate:!0,deep:!0});const l=e.computed(()=>({...E,...t,itemStyle:{...E.itemStyle,...t.itemStyle}})),_=e.ref(!1),S=()=>{_.value=!0},w=p=>{_.value=!1;const B=t.list[p.oldIndex];c("change",d.value,{...B,oldIndex:p.oldIndex,newIndex:p.newIndex})};return(p,B)=>{const m=e.resolveComponent("el-icon");return e.openBlock(),e.createBlock(e.unref(T),{modelValue:d.value,"onUpdate:modelValue":B[0]||(B[0]=s=>d.value=s),class:e.normalizeClass(["list-group",[l.value.groupClass]]),tag:"ul",attrs:l.value,animation:l.value.animation,group:l.value.group,disabled:l.value.disabled,"ghost-class":l.value.ghostClass,"force-fallback":l.value.ghostClass,"item-key":"order",onStart:S,onEnd:w},{item:e.withCtx(({element:s})=>[e.createVNode(e.Transition,{type:"transition",name:"flip-list"},{default:e.withCtx(()=>[p.$slots.item?e.renderSlot(p.$slots,"item",{key:0,item:s},void 0,!0):(e.openBlock(),e.createElementBlock("li",{key:1,class:e.normalizeClass(["list-group-item",[l.value.itemClass]]),style:e.normalizeStyle({borderRadius:`${l.value.itemStyle.radius}px`,marginBottom:`${l.value.itemStyle.bottom}px`,backgroundColor:`${l.value.itemStyle.background}`})},[l.value.showIcon&&!p.$slots.icon?(e.openBlock(),e.createBlock(m,{key:0},{default:e.withCtx(()=>[e.createVNode(e.unref(L))]),_:1})):e.renderSlot(p.$slots,"icon",{key:1},void 0,!0),e.createTextVNode(" "+e.toDisplayString(s.label),1)],6))]),_:2},1024)]),_:3},8,["modelValue","class","attrs","animation","group","disabled","ghost-class","force-fallback"])}}}),se="",J=v(x(G,[["__scopeId","data-v-3716c05e"]])),K=(a=>(e.pushScopeId("data-v-b5ed17ed"),a=a(),e.popScopeId(),a))(()=>e.createElementVNode("i",{class:"ik ik-shezhi"},null,-1)),Q={class:"check-right"},Z={class:"dialog-footer"},U=e.defineComponent({__name:"IkBtnSetting",props:e.mergeModels({list:{type:Array,default:()=>[]},tab:{type:[String,Number],default:""},type:{type:String,default:"primary"},btnType:{type:String,default:"icon"},circle:{type:Boolean,default:!0},inline:{type:Boolean,default:!1},role:{type:String,default:""},config:{type:Object,default:()=>({t:a=>a,dialog:{l:"700px",sl:"600px"},path:"user_0",user:{id:"111"}})}},{modelValue:{type:Array,default:()=>[]},modelModifiers:{}}),emits:e.mergeModels(["sort"],["update:modelValue"]),setup(a,{emit:g}){const t=a,c=g,d=e.useModel(a,"modelValue"),{t:l,dialog:_,path:S,user:w}=t.config,p=e.computed(()=>`${w==null?void 0:w.id}_${S}${t.tab!==""?`_${t.tab}`:""}`),B=e.ref([]),m=e.ref([]),s=e.ref([]),V=new Map,I=e.ref(!1),P=e.computed(()=>{const i=m.value.length&&m.value.length!==t.list.length;return!i&&m.value.length&&(I.value=!0),!!i}),N=i=>{var r;const o=y._.cloneDeep(s.value);o==null||o.forEach(n=>{var b;if(!m.value.length)s.value=[];else if(!m.value.includes(n==null?void 0:n.key)){const h=(b=s.value)==null?void 0:b.findIndex(u=>u.key===n.key);h!==-1&&s.value.splice(h,1),n.show=!1,V.set(n.key,n)}}),m.value.forEach(n=>{var h;if(((h=s.value)==null?void 0:h.findIndex(u=>(u==null?void 0:u.key)===n))===-1){const u=V.get(n);u&&(u.show=!0,s.value.push(u))}}),(r=s.value)!=null&&r.length||(s.value=y._.cloneDeep(t.list)),i===!0&&(c("sort",y._.cloneDeep(s.value)),d.value=y._.cloneDeep(s.value))},ee=i=>{if(i)m.value=t.list.map(o=>o.key);else{const o=t.list.find(r=>!r.key||r.label==="操作");m.value=o?[o.key]:[]}N()},z=()=>{const i=y.ikStore.local.getItem(p.value);try{const o=y._.cloneDeep(t==null?void 0:t.list);if((!i||!(i!=null&&i.length))&&y.ikStore.local.setItem(p.value,o.map(({show:r,type:n,key:b,label:h,width:u,minWidth:f,align:ae})=>({show:r,key:b,type:n,label:h,width:u,minWidth:f,align:ae}))),B.value=[...(o==null?void 0:o.map(r=>(V.set(r.key,r),{...r,show:r.show||!1})))||[]],i){const r=i.filter(n=>n.show).map(n=>n.key);m.value=[...r]}else{const r=B.value.filter(n=>n.show);m.value=r.map(n=>n.key)}N(!0)}catch(o){console.info("error: ",o)}};z(),e.watch(()=>t.list,()=>{z()},{deep:!0});const C=e.ref(!1),D=()=>{C.value=!0},te=i=>{s.value=i},le=()=>{C.value=!1,y.ikStore.local.setItem(p.value,s.value.map(({show:i,key:o,label:r,value:n,width:b,minWidth:h,align:u})=>({show:i,key:o,label:r,value:n,width:b,minWidth:h,align:u}))),c("sort",y._.cloneDeep(s.value)),d.value=y._.cloneDeep(s.value)};return(i,o)=>{const r=e.resolveComponent("el-button"),n=e.resolveComponent("el-checkbox"),b=e.resolveComponent("el-checkbox-group"),h=e.resolveComponent("el-dialog"),u=e.resolveDirective("role");return e.openBlock(),e.createElementBlock(e.Fragment,null,[a.btnType==="button"?e.withDirectives((e.openBlock(),e.createBlock(r,e.mergeProps({key:0},i.$attrs,{circle:a.circle,type:a.type,style:{minWidth:a.circle?"40px":"",minHeight:a.circle?"40px":""},onClick:D}),e.createSlots({icon:e.withCtx(()=>[K]),_:2},[a.circle?void 0:{name:"default",fn:e.withCtx(()=>[e.createCommentVNode(' {{ t("action.setting") }} '),e.createTextVNode(" "+e.toDisplayString(e.unref(l)("设置")),1)]),key:"0"}]),1040,["circle","type","style"])),[[u,i.$props.role]]):e.createCommentVNode("v-if",!0),a.btnType==="icon"?e.withDirectives((e.openBlock(),e.createBlock(e.unref(Y),e.mergeProps({key:1,name:"iksvg_shezhi-daohang","show-bg":"",size:"default"},i.$attrs,{onClick:D}),null,16)),[[u,i.$props.role]]):e.createCommentVNode("v-if",!0),e.createVNode(h,{modelValue:C.value,"onUpdate:modelValue":o[3]||(o[3]=f=>C.value=f),draggable:"",width:a.inline?e.unref(_).l:e.unref(_).sl,"close-on-click-modal":!1,"close-on-press-escape":!1,title:"显示字段","append-to-body":"",onOpen:z},{footer:e.withCtx(()=>[e.createElementVNode("div",Z,[e.createVNode(r,{onClick:o[2]||(o[2]=f=>C.value=!1)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(l)("关闭"))+" ",1),e.createCommentVNode(' {{ t("action.close") }} ')]),_:1}),e.createVNode(r,{type:"primary",disabled:s.value.length<2,onClick:le},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(s.value.length<2?"至少选择一个字段":e.unref(l)("确定")),1)]),_:1},8,["disabled"])])]),default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["view-fields",[a.inline?null:"un-inline"]])},[e.createElementVNode("div",{style:e.normalizeStyle({flex:a.inline?2:1})},[e.createVNode(n,{modelValue:I.value,"onUpdate:modelValue":o[0]||(o[0]=f=>I.value=f),class:"single-line",indeterminate:P.value,onChange:ee},{default:e.withCtx(()=>[e.createTextVNode(" 全选 ")]),_:1},8,["modelValue","indeterminate"]),e.createVNode(b,{modelValue:m.value,"onUpdate:modelValue":o[1]||(o[1]=f=>m.value=f),onChange:N},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,f=>(e.openBlock(),e.createBlock(n,{key:f.key,disabled:!f.key,label:f.key},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(f.label),1)]),_:2},1032,["disabled","label"]))),128))]),_:1},8,["modelValue"])],4),e.createElementVNode("div",Q,[e.createVNode(e.unref(J),{list:s.value,"item-style":{bottom:4},onChange:te},null,8,["list"])])],2)]),_:1},8,["modelValue","width"])],64)}}}),ce="",$=v(x(U,[["__scopeId","data-v-b5ed17ed"]]));k.IkBtnSetting=$,k.default=$,Object.defineProperties(k,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.row-title[data-v-
|
|
1
|
+
.row-title[data-v-a7ec508a]{display:flex}.ik-svg-icon.ik-icon-span[data-v-a7ec508a]:not(:first-child){margin-left:var(--ik-margin-s-12)}.ghost[data-v-3716c05e]{opacity:.9;background:var(--el-color-primary)!important;color:var(--el-color-white)}.list-group[data-v-3716c05e]{height:100%;width:100%;color:var(--el-text-color-regular);transition:all .25s}.list-group-item[data-v-3716c05e]{cursor:move;border-radius:4px;background:var(--el-color-primary-light-9);margin-bottom:var(--base-m);padding:var(--base-p);-webkit-user-select:none;user-select:none;display:flex;align-items:center}.list-group-item[data-v-3716c05e]:hover{background:var(--el-color-primary-light-7)!important}.list-group-item i[data-v-3716c05e]{margin-right:calc(var(--base-m) / 2);cursor:pointer}.view-fields.un-inline .el-checkbox[data-v-b5ed17ed]{width:100%;background:var(--ik-sub-sidebar-menu-bg);margin:2px 0;padding:8px;border-radius:4px;height:37px}.view-fields[data-v-b5ed17ed]{display:flex;justify-content:space-between;max-height:55vh;overflow-y:auto;overflow-x:hidden}.view-fields .check-right[data-v-b5ed17ed]{margin-top:37px}.view-fields .single-line[data-v-b5ed17ed]{background-color:transparent!important}.view-fields>div[data-v-b5ed17ed]:nth-child(1){padding-right:8px;flex:2;border-right:1px solid var(--el-border-color)}.view-fields>div[data-v-b5ed17ed]:nth-child(2){flex:1;margin-left:8px}.view-fields>div:nth-child(2) .field-sort[data-v-b5ed17ed]{cursor:move;padding:calc(var(--base-p) / 2);color:var(--el-text-color-regular)}.view-fields .el-checkbox[data-v-b5ed17ed]{width:195px;margin-right:0}
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
import { defineComponent as _,
|
|
2
|
-
import { ikColor as
|
|
1
|
+
import { defineComponent as _, computed as y, resolveComponent as f, openBlock as a, createElementBlock as i, normalizeClass as u, normalizeStyle as c, createCommentVNode as d, createElementVNode as v, createBlock as g, withCtx as p, createTextVNode as k, toDisplayString as b, mergeModels as z, useModel as $, renderSlot as m, createVNode as I, unref as C } from "vue";
|
|
2
|
+
import { ikColor as T } from "iking-utils-pro";
|
|
3
3
|
const w = (s, o) => {
|
|
4
|
-
if (s.install = (
|
|
5
|
-
for (const
|
|
6
|
-
|
|
4
|
+
if (s.install = (e) => {
|
|
5
|
+
for (const t of [s, ...Object.values(o ?? {})])
|
|
6
|
+
e.component(t.name, t);
|
|
7
7
|
}, o)
|
|
8
|
-
for (const [
|
|
9
|
-
s[
|
|
8
|
+
for (const [e, t] of Object.entries(o))
|
|
9
|
+
s[e] = t;
|
|
10
10
|
return s;
|
|
11
11
|
}, B = (s, o) => {
|
|
12
|
-
const
|
|
13
|
-
for (const [
|
|
14
|
-
|
|
15
|
-
return
|
|
16
|
-
},
|
|
12
|
+
const e = s.__vccOpts || s;
|
|
13
|
+
for (const [t, n] of o)
|
|
14
|
+
e[t] = n;
|
|
15
|
+
return e;
|
|
16
|
+
}, j = {
|
|
17
17
|
key: 0,
|
|
18
18
|
class: "ik-svg-icon ik-icon-span inline-block inline-flex justify-center box-content line-height-[0]"
|
|
19
|
-
},
|
|
19
|
+
}, S = {
|
|
20
20
|
key: 1,
|
|
21
21
|
class: "h-[1em] w-[1em]",
|
|
22
22
|
"aria-hidden": "true"
|
|
23
|
-
},
|
|
23
|
+
}, V = ["xlink:href"], N = ["src"], O = {
|
|
24
24
|
key: 1,
|
|
25
25
|
class: "h-[1em] w-[1em]",
|
|
26
26
|
"aria-hidden": "true"
|
|
27
|
-
},
|
|
27
|
+
}, M = ["xlink:href"], E = ["src"], L = /* @__PURE__ */ _({
|
|
28
28
|
name: "IkSvgIcon",
|
|
29
29
|
__name: "index",
|
|
30
30
|
props: {
|
|
@@ -51,13 +51,10 @@ const w = (s, o) => {
|
|
|
51
51
|
width: {}
|
|
52
52
|
},
|
|
53
53
|
setup(s) {
|
|
54
|
-
const o = s,
|
|
55
|
-
...(n == null ? void 0 : n.value) || {},
|
|
56
|
-
...o
|
|
57
|
-
})), t = m(() => {
|
|
54
|
+
const o = s, e = y(() => o), t = y(() => {
|
|
58
55
|
const { name: l } = e.value;
|
|
59
56
|
return /^http?:\/\//.test(l) ? "img" : /i-[^:]+:[^:]+/.test(l) ? "unocss" : l != null && l.startsWith("iksig") ? "iksig" : l != null && l.includes(":") ? "iconify" : l != null && l.startsWith("iksvg") ? "svg" : "i";
|
|
60
|
-
}),
|
|
57
|
+
}), n = y(() => {
|
|
61
58
|
const l = [];
|
|
62
59
|
if (e.value.flip)
|
|
63
60
|
switch (e.value.flip) {
|
|
@@ -72,26 +69,26 @@ const w = (s, o) => {
|
|
|
72
69
|
break;
|
|
73
70
|
}
|
|
74
71
|
e.value.rotate && l.push(`rotate(${e.value.rotate % 360}deg)`);
|
|
75
|
-
const
|
|
72
|
+
const r = {
|
|
76
73
|
...e.value.color && { color: e.value.color },
|
|
77
74
|
...e.value.size && { fontSize: typeof e.value.size == "number" ? `${e.value.size}px` : e.value.size },
|
|
78
75
|
...l.length && { transform: l.join(" ") },
|
|
79
76
|
padding: e.value.showBg || e.value.bg ? e.value.padding : 0,
|
|
80
77
|
...e.value.color && t.value !== "iksig" ? {
|
|
81
78
|
"--ik-color-icon-dark": e.value.color,
|
|
82
|
-
"--ik-color-icon-light": e.value.colorLight ||
|
|
79
|
+
"--ik-color-icon-light": e.value.colorLight || T.setOpacity(e.value.color, e.value.opacity)
|
|
83
80
|
} : {}
|
|
84
81
|
};
|
|
85
|
-
return e.value.width && (
|
|
82
|
+
return e.value.width && (r.width = r.height = typeof e.value.width == "number" ? `${e.value.width}px` : e.value.width), r;
|
|
86
83
|
});
|
|
87
|
-
return (l,
|
|
88
|
-
const
|
|
89
|
-
return e.value.tableIconType === "icon" || !e.value.tableIconType ? (a(), i("span",
|
|
84
|
+
return (l, r) => {
|
|
85
|
+
const h = f("el-tooltip"), x = f("el-button");
|
|
86
|
+
return e.value.tableIconType === "icon" || !e.value.tableIconType ? (a(), i("span", j, [
|
|
90
87
|
e.value.notip || !e.value.title ? (a(), i(
|
|
91
88
|
"i",
|
|
92
89
|
{
|
|
93
90
|
key: 0,
|
|
94
|
-
class:
|
|
91
|
+
class: u(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition", {
|
|
95
92
|
[l.name]: t.value === "unocss",
|
|
96
93
|
"show-bg": e.value.showBg || e.value.bg,
|
|
97
94
|
default: e.value.size === "default",
|
|
@@ -104,34 +101,34 @@ const w = (s, o) => {
|
|
|
104
101
|
active: e.value.active,
|
|
105
102
|
disabled: e.value.disabled
|
|
106
103
|
}]),
|
|
107
|
-
style: c(
|
|
104
|
+
style: c(n.value)
|
|
108
105
|
},
|
|
109
106
|
[
|
|
110
|
-
|
|
107
|
+
d(` <Icon v-if="outputType === 'iconify'" :icon="name" /> `),
|
|
111
108
|
t.value === "iksig" ? (a(), i(
|
|
112
109
|
"i",
|
|
113
110
|
{
|
|
114
111
|
key: 0,
|
|
115
|
-
class:
|
|
116
|
-
style: c(
|
|
112
|
+
class: u(`iksig ${e.value.name}`),
|
|
113
|
+
style: c(n.value)
|
|
117
114
|
},
|
|
118
115
|
null,
|
|
119
116
|
6
|
|
120
117
|
/* CLASS, STYLE */
|
|
121
|
-
)) : t.value === "svg" ? (a(), i("svg",
|
|
118
|
+
)) : t.value === "svg" ? (a(), i("svg", S, [
|
|
122
119
|
v("use", {
|
|
123
120
|
"xlink:href": `#${e.value.name}`
|
|
124
|
-
}, null, 8,
|
|
121
|
+
}, null, 8, V)
|
|
125
122
|
])) : t.value === "img" ? (a(), i("img", {
|
|
126
123
|
key: 2,
|
|
127
124
|
src: e.value.name,
|
|
128
125
|
class: "h-[1em] w-[1em]"
|
|
129
|
-
}, null, 8,
|
|
126
|
+
}, null, 8, N)) : (a(), i(
|
|
130
127
|
"i",
|
|
131
128
|
{
|
|
132
129
|
key: 3,
|
|
133
|
-
class:
|
|
134
|
-
style: c(
|
|
130
|
+
class: u(e.value.name),
|
|
131
|
+
style: c(n.value)
|
|
135
132
|
},
|
|
136
133
|
null,
|
|
137
134
|
6
|
|
@@ -140,16 +137,16 @@ const w = (s, o) => {
|
|
|
140
137
|
],
|
|
141
138
|
6
|
|
142
139
|
/* CLASS, STYLE */
|
|
143
|
-
)) : (a(),
|
|
140
|
+
)) : (a(), g(h, {
|
|
144
141
|
key: 1,
|
|
145
142
|
content: e.value.title,
|
|
146
143
|
placement: "top"
|
|
147
144
|
}, {
|
|
148
|
-
default:
|
|
145
|
+
default: p(() => [
|
|
149
146
|
v(
|
|
150
147
|
"i",
|
|
151
148
|
{
|
|
152
|
-
class:
|
|
149
|
+
class: u(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition", {
|
|
153
150
|
[l.name]: t.value === "unocss",
|
|
154
151
|
"show-bg": e.value.showBg || e.value.bg,
|
|
155
152
|
default: e.value.size === "default",
|
|
@@ -161,33 +158,33 @@ const w = (s, o) => {
|
|
|
161
158
|
error: e.value.error || e.value.type === "error",
|
|
162
159
|
active: e.value.active
|
|
163
160
|
}]),
|
|
164
|
-
style: c(
|
|
161
|
+
style: c(n.value)
|
|
165
162
|
},
|
|
166
163
|
[
|
|
167
164
|
t.value === "iksig" ? (a(), i(
|
|
168
165
|
"i",
|
|
169
166
|
{
|
|
170
167
|
key: 0,
|
|
171
|
-
class:
|
|
172
|
-
style: c(
|
|
168
|
+
class: u(`iksig ${e.value.name}`),
|
|
169
|
+
style: c(n.value)
|
|
173
170
|
},
|
|
174
171
|
null,
|
|
175
172
|
6
|
|
176
173
|
/* CLASS, STYLE */
|
|
177
|
-
)) : t.value === "svg" ? (a(), i("svg",
|
|
174
|
+
)) : t.value === "svg" ? (a(), i("svg", O, [
|
|
178
175
|
v("use", {
|
|
179
176
|
"xlink:href": `#${e.value.name}`
|
|
180
|
-
}, null, 8,
|
|
177
|
+
}, null, 8, M)
|
|
181
178
|
])) : t.value === "img" ? (a(), i("img", {
|
|
182
179
|
key: 2,
|
|
183
180
|
src: e.value.name,
|
|
184
181
|
class: "h-[1em] w-[1em]"
|
|
185
|
-
}, null, 8,
|
|
182
|
+
}, null, 8, E)) : (a(), i(
|
|
186
183
|
"i",
|
|
187
184
|
{
|
|
188
185
|
key: 3,
|
|
189
|
-
class:
|
|
190
|
-
style: c(
|
|
186
|
+
class: u(e.value.name),
|
|
187
|
+
style: c(n.value)
|
|
191
188
|
},
|
|
192
189
|
null,
|
|
193
190
|
6
|
|
@@ -201,11 +198,11 @@ const w = (s, o) => {
|
|
|
201
198
|
_: 1
|
|
202
199
|
/* STABLE */
|
|
203
200
|
}, 8, ["content"]))
|
|
204
|
-
])) : (a(),
|
|
201
|
+
])) : (a(), g(x, {
|
|
205
202
|
key: 1,
|
|
206
203
|
type: ["warning", "error"].includes(e.value.type) ? "danger" : ""
|
|
207
204
|
}, {
|
|
208
|
-
default:
|
|
205
|
+
default: p(() => [
|
|
209
206
|
k(
|
|
210
207
|
b(e.value.title),
|
|
211
208
|
1
|
|
@@ -218,9 +215,9 @@ const w = (s, o) => {
|
|
|
218
215
|
};
|
|
219
216
|
}
|
|
220
217
|
});
|
|
221
|
-
const
|
|
218
|
+
const W = /* @__PURE__ */ B(L, [["__scopeId", "data-v-a7ec508a"]]), X = w(W), Y = { class: "align-center flex justify-between" }, q = { class: "align-center flex" }, D = { style: { overflow: "hidden" } }, A = /* @__PURE__ */ _({
|
|
222
219
|
__name: "index",
|
|
223
|
-
props: /* @__PURE__ */
|
|
220
|
+
props: /* @__PURE__ */ z({
|
|
224
221
|
showToggle: {
|
|
225
222
|
type: Boolean,
|
|
226
223
|
default: !0
|
|
@@ -234,50 +231,50 @@ const Y = /* @__PURE__ */ B(X, [["__scopeId", "data-v-ec9fdc8a"]]), q = w(Y), D
|
|
|
234
231
|
}),
|
|
235
232
|
emits: ["update:modelValue"],
|
|
236
233
|
setup(s) {
|
|
237
|
-
const o =
|
|
234
|
+
const o = $(s, "modelValue"), e = () => {
|
|
238
235
|
o.value = !o.value;
|
|
239
236
|
};
|
|
240
|
-
return (
|
|
241
|
-
const
|
|
242
|
-
return a(),
|
|
243
|
-
class:
|
|
237
|
+
return (t, n) => {
|
|
238
|
+
const l = f("el-button"), r = f("el-card");
|
|
239
|
+
return a(), g(r, {
|
|
240
|
+
class: u(["ik-collapse-box-card", o.value ? "hiddened" : ""]),
|
|
244
241
|
shadow: "hover"
|
|
245
242
|
}, {
|
|
246
|
-
header:
|
|
247
|
-
v("div",
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
v("div",
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
s.showToggle ? (a(),
|
|
243
|
+
header: p(() => [
|
|
244
|
+
v("div", Y, [
|
|
245
|
+
d(" card header左侧内容 "),
|
|
246
|
+
m(t.$slots, "header-leaft", {}, void 0, !0),
|
|
247
|
+
v("div", q, [
|
|
248
|
+
d(" card header右侧内容 "),
|
|
249
|
+
m(t.$slots, "header-right", {}, void 0, !0),
|
|
250
|
+
d(" 展开、收起按钮 "),
|
|
251
|
+
s.showToggle ? (a(), g(l, {
|
|
255
252
|
key: 0,
|
|
256
253
|
link: "",
|
|
257
254
|
class: "ml-[8px]",
|
|
258
|
-
onClick:
|
|
255
|
+
onClick: n[0] || (n[0] = (h) => e())
|
|
259
256
|
}, {
|
|
260
|
-
default:
|
|
257
|
+
default: p(() => [
|
|
261
258
|
k(
|
|
262
259
|
b(o.value ? "展开" : "收起") + " ",
|
|
263
260
|
1
|
|
264
261
|
/* TEXT */
|
|
265
262
|
),
|
|
266
|
-
|
|
263
|
+
I(C(X), {
|
|
267
264
|
name: "iksvg_shouqi",
|
|
268
265
|
size: 16,
|
|
269
|
-
class:
|
|
266
|
+
class: u(o.value ? "toogle" : null)
|
|
270
267
|
}, null, 8, ["class"])
|
|
271
268
|
]),
|
|
272
269
|
_: 1
|
|
273
270
|
/* STABLE */
|
|
274
|
-
})) :
|
|
271
|
+
})) : d("v-if", !0)
|
|
275
272
|
])
|
|
276
273
|
])
|
|
277
274
|
]),
|
|
278
|
-
default:
|
|
279
|
-
v("div",
|
|
280
|
-
|
|
275
|
+
default: p(() => [
|
|
276
|
+
v("div", D, [
|
|
277
|
+
m(t.$slots, "default", {}, void 0, !0)
|
|
281
278
|
])
|
|
282
279
|
]),
|
|
283
280
|
_: 3
|
|
@@ -286,8 +283,8 @@ const Y = /* @__PURE__ */ B(X, [["__scopeId", "data-v-ec9fdc8a"]]), q = w(Y), D
|
|
|
286
283
|
};
|
|
287
284
|
}
|
|
288
285
|
});
|
|
289
|
-
const
|
|
286
|
+
const F = /* @__PURE__ */ B(A, [["__scopeId", "data-v-eab56bfd"]]), J = w(F);
|
|
290
287
|
export {
|
|
291
|
-
|
|
292
|
-
|
|
288
|
+
J as IkCollapseCard,
|
|
289
|
+
J as default
|
|
293
290
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(i,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("iking-utils-pro")):typeof define=="function"&&define.amd?define(["exports","vue","iking-utils-pro"],e):(i=typeof globalThis<"u"?globalThis:i||self,e(i.index={},i.vue,i["iking-utils-pro"]))})(this,function(i,e,m){"use strict";const
|
|
1
|
+
(function(i,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue"),require("iking-utils-pro")):typeof define=="function"&&define.amd?define(["exports","vue","iking-utils-pro"],e):(i=typeof globalThis<"u"?globalThis:i||self,e(i.index={},i.vue,i["iking-utils-pro"]))})(this,function(i,e,m){"use strict";const c=(n,a)=>{if(n.install=l=>{for(const o of[n,...Object.values(a??{})])l.component(o.name,o)},a)for(const[l,o]of Object.entries(a))n[l]=o;return n},d=(n,a)=>{const l=n.__vccOpts||n;for(const[o,s]of a)l[o]=s;return l},f={key:0,class:"ik-svg-icon ik-icon-span inline-block inline-flex justify-center box-content line-height-[0]"},y={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},g=["xlink:href"],k=["src"],h={key:1,class:"h-[1em] w-[1em]","aria-hidden":"true"},_=["xlink:href"],v=["src"],B=e.defineComponent({name:"IkSvgIcon",__name:"index",props:{active:{type:Boolean,default:!1},bg:{type:Boolean,default:!1},color:{},colorLight:{},disabled:{type:Boolean,default:!1},error:{type:Boolean},flip:{},name:{},notip:{type:Boolean,default:!1},opacity:{default:.5},padding:{default:"6px"},primary:{type:Boolean},rotate:{},showBg:{type:Boolean,default:!1},size:{default:""},success:{type:Boolean},tableIconType:{},title:{},type:{},warning:{type:Boolean},width:{}},setup(n){const a=n,l=e.computed(()=>a),o=e.computed(()=>{const{name:t}=l.value;return/^http?:\/\//.test(t)?"img":/i-[^:]+:[^:]+/.test(t)?"unocss":t!=null&&t.startsWith("iksig")?"iksig":t!=null&&t.includes(":")?"iconify":t!=null&&t.startsWith("iksvg")?"svg":"i"}),s=e.computed(()=>{const t=[];if(l.value.flip)switch(l.value.flip){case"horizontal":t.push("rotateY(180deg)");break;case"vertical":t.push("rotateX(180deg)");break;case"both":t.push("rotateX(180deg)"),t.push("rotateY(180deg)");break}l.value.rotate&&t.push(`rotate(${l.value.rotate%360}deg)`);const r={...l.value.color&&{color:l.value.color},...l.value.size&&{fontSize:typeof l.value.size=="number"?`${l.value.size}px`:l.value.size},...t.length&&{transform:t.join(" ")},padding:l.value.showBg||l.value.bg?l.value.padding:0,...l.value.color&&o.value!=="iksig"?{"--ik-color-icon-dark":l.value.color,"--ik-color-icon-light":l.value.colorLight||m.ikColor.setOpacity(l.value.color,l.value.opacity)}:{}};return l.value.width&&(r.width=r.height=typeof l.value.width=="number"?`${l.value.width}px`:l.value.width),r});return(t,r)=>{const p=e.resolveComponent("el-tooltip"),S=e.resolveComponent("el-button");return l.value.tableIconType==="icon"||!l.value.tableIconType?(e.openBlock(),e.createElementBlock("span",f,[l.value.notip||!l.value.title?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[t.name]:o.value==="unocss","show-bg":l.value.showBg||l.value.bg,default:l.value.size==="default",small:l.value.size==="small",big:l.value.size==="big",warning:l.value.warning||l.value.type==="warning",primary:l.value.primary||l.value.type==="primary",success:t.success||l.value.type==="success",error:l.value.error||l.value.type==="error",active:l.value.active,disabled:l.value.disabled}]),style:e.normalizeStyle(s.value)},[e.createCommentVNode(` <Icon v-if="outputType === 'iconify'" :icon="name" /> `),o.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${l.value.name}`),style:e.normalizeStyle(s.value)},null,6)):o.value==="svg"?(e.openBlock(),e.createElementBlock("svg",y,[e.createElementVNode("use",{"xlink:href":`#${l.value.name}`},null,8,g)])):o.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:l.value.name,class:"h-[1em] w-[1em]"},null,8,k)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(l.value.name),style:e.normalizeStyle(s.value)},null,6))],6)):(e.openBlock(),e.createBlock(p,{key:1,content:l.value.title,placement:"top"},{default:e.withCtx(()=>[e.createElementVNode("i",{class:e.normalizeClass(["ik-svg-icon ik-icon relative h-[1em] w-[1em] inline-flex items-center justify-center fill-current leading-[1em] transition",{[t.name]:o.value==="unocss","show-bg":l.value.showBg||l.value.bg,default:l.value.size==="default",small:l.value.size==="small",big:l.value.size==="big",warning:l.value.warning||l.value.type==="warning",primary:t.primary||l.value.type==="primary",success:t.success||l.value.type==="success",error:l.value.error||l.value.type==="error",active:l.value.active}]),style:e.normalizeStyle(s.value)},[o.value==="iksig"?(e.openBlock(),e.createElementBlock("i",{key:0,class:e.normalizeClass(`iksig ${l.value.name}`),style:e.normalizeStyle(s.value)},null,6)):o.value==="svg"?(e.openBlock(),e.createElementBlock("svg",h,[e.createElementVNode("use",{"xlink:href":`#${l.value.name}`},null,8,_)])):o.value==="img"?(e.openBlock(),e.createElementBlock("img",{key:2,src:l.value.name,class:"h-[1em] w-[1em]"},null,8,v)):(e.openBlock(),e.createElementBlock("i",{key:3,class:e.normalizeClass(l.value.name),style:e.normalizeStyle(s.value)},null,6))],6)]),_:1},8,["content"]))])):(e.openBlock(),e.createBlock(S,{key:1,type:["warning","error"].includes(l.value.type)?"danger":""},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(l.value.title),1)]),_:1},8,["type"]))}}}),V="",w=c(d(B,[["__scopeId","data-v-a7ec508a"]])),b={class:"align-center flex justify-between"},C={class:"align-center flex"},z={style:{overflow:"hidden"}},x=e.defineComponent({__name:"index",props:e.mergeModels({showToggle:{type:Boolean,default:!0}},{modelValue:{type:Boolean,default:!1},modelModifiers:{}}),emits:["update:modelValue"],setup(n){const a=e.useModel(n,"modelValue"),l=()=>{a.value=!a.value};return(o,s)=>{const t=e.resolveComponent("el-button"),r=e.resolveComponent("el-card");return e.openBlock(),e.createBlock(r,{class:e.normalizeClass(["ik-collapse-box-card",a.value?"hiddened":""]),shadow:"hover"},{header:e.withCtx(()=>[e.createElementVNode("div",b,[e.createCommentVNode(" card header左侧内容 "),e.renderSlot(o.$slots,"header-leaft",{},void 0,!0),e.createElementVNode("div",C,[e.createCommentVNode(" card header右侧内容 "),e.renderSlot(o.$slots,"header-right",{},void 0,!0),e.createCommentVNode(" 展开、收起按钮 "),n.showToggle?(e.openBlock(),e.createBlock(t,{key:0,link:"",class:"ml-[8px]",onClick:s[0]||(s[0]=p=>l())},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(a.value?"展开":"收起")+" ",1),e.createVNode(e.unref(w),{name:"iksvg_shouqi",size:16,class:e.normalizeClass(a.value?"toogle":null)},null,8,["class"])]),_:1})):e.createCommentVNode("v-if",!0)])])]),default:e.withCtx(()=>[e.createElementVNode("div",z,[e.renderSlot(o.$slots,"default",{},void 0,!0)])]),_:3},8,["class"])}}}),I="",u=c(d(x,[["__scopeId","data-v-eab56bfd"]]));i.IkCollapseCard=u,i.default=u,Object.defineProperties(i,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.row-title[data-v-
|
|
1
|
+
.row-title[data-v-a7ec508a]{display:flex}.ik-svg-icon.ik-icon-span[data-v-a7ec508a]:not(:first-child){margin-left:var(--ik-margin-s-12)}.ik-collapse-box-card[data-v-eab56bfd]{flex:1;margin-bottom:20px;--el-card-border-radius: 0}.ik-collapse-box-card[data-v-eab56bfd] .el-card__header{padding-right:0;color:var(--el-text-color-regular);background-color:var(--el-bg-color-page);border-bottom:none}.ik-collapse-box-card[data-v-eab56bfd] .el-card__header .el-button.is-link:hover{--ik-color-icon-dark: var(--ik-color-tag-primary);--ik-color-icon-light: var(--ik-color-icon-light-hover)}.ik-collapse-box-card[data-v-eab56bfd] .ik-svg-icon{transition:all .25s}.ik-collapse-box-card[data-v-eab56bfd] .ik-svg-icon.toogle{transform:rotate(-90deg)}.ik-collapse-box-card.hiddened[data-v-eab56bfd] .el-card__body{grid-template-rows:0fr;padding-top:0!important;padding-bottom:0!important;overflow:hidden;opacity:0}.ik-collapse-box-card[data-v-eab56bfd] .el-card__body{display:grid;grid-template-rows:1fr;padding:0;overflow:hidden!important;opacity:1;transition:all .25s ease}.ik-collapse-box-card[data-v-eab56bfd] .el-card__body table>tbody>tr>td>.cell .cell-icon{font-size:14px}.ik-collapse-box-card[data-v-eab56bfd] .el-card__body table>tbody>tr>td>.cell .el-button span{margin-left:3px}
|