dform-designer 1.5.1 → 1.5.2
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
(function(t,s){typeof exports=="object"&&typeof module<"u"?module.exports=s(require("vue")):typeof define=="function"&&define.amd?define(["vue"],s):(t=typeof globalThis<"u"?globalThis:t||self,t.SetpPlug=s(t.Vue))})(this,function(t){"use strict";var P=Object.defineProperty;var A=(t,s,
|
|
1
|
+
(function(t,s){typeof exports=="object"&&typeof module<"u"?module.exports=s(require("vue")):typeof define=="function"&&define.amd?define(["vue"],s):(t=typeof globalThis<"u"?globalThis:t||self,t.SetpPlug=s(t.Vue))})(this,function(t){"use strict";var P=Object.defineProperty;var A=(t,s,p)=>s in t?P(t,s,{enumerable:!0,configurable:!0,writable:!0,value:p}):t[s]=p;var u=(t,s,p)=>A(t,typeof s!="symbol"?s+"":s,p);const s=(r,n)=>(r.install=l=>{for(const i of[r,...Object.values({})])l.component(i.name,i)},r),p=BigInt(16224768e5),g=5n,_=5n,f=12n,x=-1n^-1n<<g,B=-1n^-1n<<_,y=f+g+_,E=f+_,I=f,N=-1n^-1n<<f;class S{constructor(n,l){u(this,"dataCenterId");u(this,"workerId");u(this,"lastTimestamp");u(this,"sequence");if(n<0n||n>x)throw new Error("data center id is out of range");if(l<0n||l>B)throw new Error("worker id is out of range");this.dataCenterId=n,this.workerId=l,this.lastTimestamp=-1n,this.sequence=0n}nextId(){let n=BigInt(Date.now());if(n<this.lastTimestamp)throw new Error("clock moved backwards");return n===this.lastTimestamp?(this.sequence=this.sequence+1n&N,this.sequence===0n&&(n=this.waitNextMillisecond(n))):this.sequence=0n,this.lastTimestamp=n,(n-p<<y)+(this.dataCenterId<<E)+(this.workerId<<I)+this.sequence}waitNextMillisecond(n){for(;n<=this.lastTimestamp;)n=BigInt(Date.now());return n}}new S(1n,1n);const q={class:"setp-box"},C={class:"item-box"},V={class:"title-txt"},b={class:"item-content"},T={key:0,class:"link-box"},k=s(((r,n)=>{const l=r.__vccOpts||r;for(const[i,h]of n)l[i]=h;return l})(t.defineComponent({name:"SetpPlug",__name:"index",props:{attr:{},data:{}},setup(r){const n=r,l=t.computed(()=>{var e,o;return((o=(e=n.attr)==null?void 0:e.props)==null?void 0:o.title)||"title"}),i=t.computed(()=>{var e,o;return((o=(e=n.attr)==null?void 0:e.props)==null?void 0:o.state)||"status"}),h=t.computed(()=>{var o,c,d;const e=(c=(o=n.attr)==null?void 0:o.columns)==null?void 0:c.find(a=>a.prop===i.value);return new Map(((d=e==null?void 0:e.enum)==null?void 0:d.map(a=>[a.value,a.color]))||[])}),D=t.computed(()=>{var e,o;return((o=(e=n.attr)==null?void 0:e.columns)==null?void 0:o.filter(c=>{const d=c.columnName??c.prop;return d&&d!==l.value&&d!==i.value}))||[]}),M=e=>{const o=c=>c.includes("_")?c.split("_")[0]:c;if(e){if(typeof e=="string"&&e.startsWith("[")&&(e=JSON.parse(e)),Array.isArray(e))return e.map(c=>o(c)).join("、");if(e!=null)return o(e)}return e};return(e,o)=>{const c=t.resolveComponent("ArrowRight"),d=t.resolveComponent("el-icon");return t.openBlock(),t.createElementBlock("div",q,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.data,(a,w)=>(t.openBlock(),t.createElementBlock(t.Fragment,{key:a.id||w},[t.createElementVNode("div",C,[t.createElementVNode("div",{class:"title-box",style:t.normalizeStyle({background:h.value.get(a[i.value])})},[t.createElementVNode("span",V,t.toDisplayString(a[l.value]),1)],4),t.createElementVNode("div",{class:"item-state mg",style:t.normalizeStyle({color:h.value.get(a[i.value])})},t.toDisplayString(a[i.value]),5),t.createElementVNode("div",b,[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(D.value,m=>(t.openBlock(),t.createElementBlock("div",{key:m.prop,class:"mg"},t.toDisplayString(m.type==="User"?M(a[m.prop||m.columnName]):a[m.prop||m.columnName]),1))),128))])]),w<r.data.length-1?(t.openBlock(),t.createElementBlock("div",T,[t.renderSlot(e.$slots,"link-icon",{},()=>[t.createVNode(d,{size:"16"},{default:t.withCtx(()=>[t.createVNode(c)]),_:1})],!0)])):t.createCommentVNode("",!0)],64))),128))])}}}),[["__scopeId","data-v-180ca0bb"]]));return{install:r=>{r.component(k.name,k)},SetpPlug:k}});
|