import{_ as e}from"./index-a61b437d.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import{d as t,R as n,r as o,_ as i,o as l,l as r,w as a,c as s,F as u,z as c,J as d,aO as h,a5 as p,m as v,p as f,y as m,C as g,e as b,a as y,f as w,bd as x,b as _,be as S,I,A as E,t as A,ap as C,a7 as D,bf as k,aD as T,a3 as O,a4 as M,L as N,ac as P,ad as j,bb as V,U as F,Z as R,av as X,aw as Y}from"./index-31fd0fad.js";import{_ as L}from"./index-6c574ac2.js";/* empty css *//* empty css */import B from"./generateLink-d3dd082c.js";import{b as $,c as U,d as H}from"./index-bc68c1d6.js";/* empty css *//* empty css */import"./http-81caf32c.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./index-3266ac9f.js";import"./index-26a8f9ef.js"; /*! * vue-draggable-next v2.2.0 * (c) 2023 Anish George * @license MIT */ /**! * Sortable 1.14.0 * @author RubaXa * @author owenm * @license MIT */function W(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function z(e){for(var t=1;t=0||(i[n]=e[n]);return i}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(o=0;o=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function Z(e){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(e)}var K=Z(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),ee=Z(/Edge/i),te=Z(/firefox/i),ne=Z(/safari/i)&&!Z(/chrome/i)&&!Z(/android/i),oe=Z(/iP(ad|od|hone)/i),ie=Z(/chrome/i)&&Z(/android/i),le={capture:!1,passive:!1};function re(e,t,n){e.addEventListener(t,n,!K&&le)}function ae(e,t,n){e.removeEventListener(t,n,!K&&le)}function se(e,t){if(t){if(">"===t[0]&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch(n){return!1}return!1}}function ue(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function ce(e,t,n,o){if(e){n=n||document;do{if(null!=t&&(">"===t[0]?e.parentNode===n&&se(e,t):se(e,t))||o&&e===n)return e;if(e===n)break}while(e=ue(e))}return null}var de,he=/\s+/g;function pe(e,t,n){if(e&&t)if(e.classList)e.classList[n?"add":"remove"](t);else{var o=(" "+e.className+" ").replace(he," ").replace(" "+t+" "," ");e.className=(o+(n?" "+t:"")).replace(he," ")}}function ve(e,t,n){var o=e&&e.style;if(o){if(void 0===n)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),void 0===t?n:n[t];t in o||-1!==t.indexOf("webkit")||(t="-webkit-"+t),o[t]=n+("string"==typeof n?"":"px")}}function fe(e,t){var n="";if("string"==typeof e)n=e;else do{var o=ve(e,"transform");o&&"none"!==o&&(n=o+" "+n)}while(!t&&(e=e.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function me(e,t,n){if(e){var o=e.getElementsByTagName(t),i=0,l=o.length;if(n)for(;i=l:i<=l))return o;if(o===ge())break;o=Ie(o,!1)}return!1}function we(e,t,n,o){for(var i=0,l=0,r=e.children;l2&&void 0!==arguments[2]?arguments[2]:{},o=n.evt,i=Q(n,Pe);Ne.pluginEvent.bind(Ct)(e,t,z({dragEl:Fe,parentEl:Re,ghostEl:Xe,rootEl:Ye,nextEl:Le,lastDownEl:Be,cloneEl:$e,cloneHidden:Ue,dragStarted:ot,putSortable:Je,activeSortable:Ct.active,originalEvent:o,oldIndex:He,oldDraggableIndex:ze,newIndex:We,newDraggableIndex:qe,hideGhostForTarget:St,unhideGhostForTarget:It,cloneNowHidden:function(){Ue=!0},cloneNowShown:function(){Ue=!1},dispatchSortableEvent:function(e){Ve({sortable:t,name:e,originalEvent:o})}},i))};function Ve(e){!function(e){var t=e.sortable,n=e.rootEl,o=e.name,i=e.targetEl,l=e.cloneEl,r=e.toEl,a=e.fromEl,s=e.oldIndex,u=e.newIndex,c=e.oldDraggableIndex,d=e.newDraggableIndex,h=e.originalEvent,p=e.putSortable,v=e.extraEventProperties;if(t=t||n&&n[ke]){var f,m=t.options,g="on"+o.charAt(0).toUpperCase()+o.substr(1);!window.CustomEvent||K||ee?(f=document.createEvent("Event")).initEvent(o,!0,!0):f=new CustomEvent(o,{bubbles:!0,cancelable:!0}),f.to=r||n,f.from=a||n,f.item=i||n,f.clone=l,f.oldIndex=s,f.newIndex=u,f.oldDraggableIndex=c,f.newDraggableIndex=d,f.originalEvent=h,f.pullMode=p?p.lastPutMode:void 0;var b=z(z({},v),Ne.getEventProperties(o,t));for(var y in b)f[y]=b[y];n&&n.dispatchEvent(f),m[g]&&m[g].call(t,f)}}(z({putSortable:Je,cloneEl:$e,targetEl:Fe,rootEl:Ye,oldIndex:He,oldDraggableIndex:ze,newIndex:We,newDraggableIndex:qe},e))}var Fe,Re,Xe,Ye,Le,Be,$e,Ue,He,We,ze,qe,Ge,Je,Qe,Ze,Ke,et,tt,nt,ot,it,lt,rt,at,st=!1,ut=!1,ct=[],dt=!1,ht=!1,pt=[],vt=!1,ft=[],mt="undefined"!=typeof document,gt=oe,bt=ee||K?"cssFloat":"float",yt=mt&&!ie&&!oe&&"draggable"in document.createElement("div"),wt=function(){if(mt){if(K)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto","auto"===e.style.pointerEvents}}(),xt=function(e,t){var n=ve(e),o=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),i=we(e,0,t),l=we(e,1,t),r=i&&ve(i),a=l&&ve(l),s=r&&parseInt(r.marginLeft)+parseInt(r.marginRight)+be(i).width,u=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+be(l).width;if("flex"===n.display)return"column"===n.flexDirection||"column-reverse"===n.flexDirection?"vertical":"horizontal";if("grid"===n.display)return n.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(i&&r.float&&"none"!==r.float){var c="left"===r.float?"left":"right";return!l||"both"!==a.clear&&a.clear!==c?"horizontal":"vertical"}return i&&("block"===r.display||"flex"===r.display||"table"===r.display||"grid"===r.display||s>=o&&"none"===n[bt]||l&&"none"===n[bt]&&s+u>o)?"vertical":"horizontal"},_t=function(e){function t(e,n){return function(o,i,l,r){var a=o.options.group.name&&i.options.group.name&&o.options.group.name===i.options.group.name;if(null==e&&(n||a))return!0;if(null==e||!1===e)return!1;if(n&&"clone"===e)return e;if("function"==typeof e)return t(e(o,i,l,r),n)(o,i,l,r);var s=(n?o:i).options.group.name;return!0===e||"string"==typeof e&&e===s||e.join&&e.indexOf(s)>-1}}var n={},o=e.group;o&&"object"==q(o)||(o={name:o}),n.name=o.name,n.checkPull=t(o.pull,!0),n.checkPut=t(o.put),n.revertClone=o.revertClone,e.group=n},St=function(){!wt&&Xe&&ve(Xe,"display","none")},It=function(){!wt&&Xe&&ve(Xe,"display","")};mt&&document.addEventListener("click",(function(e){if(ut)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),ut=!1,!1}),!0);var Et=function(e){if(Fe){e=e.touches?e.touches[0]:e;var t=(i=e.clientX,l=e.clientY,ct.some((function(e){var t=e[ke].options.emptyInsertThreshold;if(t&&!xe(e)){var n=be(e),o=i>=n.left-t&&i<=n.right+t,a=l>=n.top-t&&l<=n.bottom+t;return o&&a?r=e:void 0}})),r);if(t){var n={};for(var o in e)e.hasOwnProperty(o)&&(n[o]=e[o]);n.target=n.rootEl=t,n.preventDefault=void 0,n.stopPropagation=void 0,t[ke]._onDragOver(n)}}var i,l,r},At=function(e){Fe&&Fe.parentNode[ke]._isOutsideThisEl(e.target)};function Ct(e,t){if(!e||!e.nodeType||1!==e.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=J({},t),e[ke]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return xt(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(e,t){e.setData("Text",t.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==Ct.supportPointer&&"PointerEvent"in window&&!ne,emptyInsertThreshold:5};for(var o in Ne.initializePlugins(this,e,n),n)!(o in t)&&(t[o]=n[o]);for(var i in _t(t),this)"_"===i.charAt(0)&&"function"==typeof this[i]&&(this[i]=this[i].bind(this));this.nativeDraggable=!t.forceFallback&&yt,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?re(e,"pointerdown",this._onTapStart):(re(e,"mousedown",this._onTapStart),re(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(re(e,"dragover",this),re(e,"dragenter",this)),ct.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),J(this,Te())}function Dt(e,t,n,o,i,l,r,a){var s,u,c=e[ke],d=c.options.onMove;return!window.CustomEvent||K||ee?(s=document.createEvent("Event")).initEvent("move",!0,!0):s=new CustomEvent("move",{bubbles:!0,cancelable:!0}),s.to=t,s.from=e,s.dragged=n,s.draggedRect=o,s.related=i||t,s.relatedRect=l||be(t),s.willInsertAfter=a,s.originalEvent=r,e.dispatchEvent(s),d&&(u=d.call(c,s,r)),u}function kt(e){e.draggable=!1}function Tt(){vt=!1}function Ot(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,n=t.length,o=0;n--;)o+=t.charCodeAt(n);return o.toString(36)}function Mt(e){return setTimeout(e,0)}function Nt(e){return clearTimeout(e)}Ct.prototype={constructor:Ct,_isOutsideThisEl:function(e){this.el.contains(e)||e===this.el||(it=null)},_getDirection:function(e,t){return"function"==typeof this.options.direction?this.options.direction.call(this,e,t,Fe):this.options.direction},_onTapStart:function(e){if(e.cancelable){var t=this,n=this.el,o=this.options,i=o.preventOnFilter,l=e.type,r=e.touches&&e.touches[0]||e.pointerType&&"touch"===e.pointerType&&e,a=(r||e).target,s=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||a,u=o.filter;if(function(e){ft.length=0;var t=e.getElementsByTagName("input"),n=t.length;for(;n--;){var o=t[n];o.checked&&ft.push(o)}}(n),!Fe&&!(/mousedown|pointerdown/.test(l)&&0!==e.button||o.disabled)&&!s.isContentEditable&&(this.nativeDraggable||!ne||!a||"SELECT"!==a.tagName.toUpperCase())&&!((a=ce(a,o.draggable,n,!1))&&a.animated||Be===a)){if(He=_e(a),ze=_e(a,o.draggable),"function"==typeof u){if(u.call(this,e,a,this))return Ve({sortable:t,rootEl:s,name:"filter",targetEl:a,toEl:n,fromEl:n}),je("filter",t,{evt:e}),void(i&&e.cancelable&&e.preventDefault())}else if(u&&(u=u.split(",").some((function(o){if(o=ce(s,o.trim(),n,!1))return Ve({sortable:t,rootEl:o,name:"filter",targetEl:a,fromEl:n,toEl:n}),je("filter",t,{evt:e}),!0}))))return void(i&&e.cancelable&&e.preventDefault());o.handle&&!ce(s,o.handle,n,!1)||this._prepareDragStart(e,r,a)}}},_prepareDragStart:function(e,t,n){var o,i=this,l=i.el,r=i.options,a=l.ownerDocument;if(n&&!Fe&&n.parentNode===l){var s=be(n);if(Ye=l,Re=(Fe=n).parentNode,Le=Fe.nextSibling,Be=n,Ge=r.group,Ct.dragged=Fe,Qe={target:Fe,clientX:(t||e).clientX,clientY:(t||e).clientY},tt=Qe.clientX-s.left,nt=Qe.clientY-s.top,this._lastX=(t||e).clientX,this._lastY=(t||e).clientY,Fe.style["will-change"]="all",o=function(){je("delayEnded",i,{evt:e}),Ct.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!te&&i.nativeDraggable&&(Fe.draggable=!0),i._triggerDragStart(e,t),Ve({sortable:i,name:"choose",originalEvent:e}),pe(Fe,r.chosenClass,!0))},r.ignore.split(",").forEach((function(e){me(Fe,e.trim(),kt)})),re(a,"dragover",Et),re(a,"mousemove",Et),re(a,"touchmove",Et),re(a,"mouseup",i._onDrop),re(a,"touchend",i._onDrop),re(a,"touchcancel",i._onDrop),te&&this.nativeDraggable&&(this.options.touchStartThreshold=4,Fe.draggable=!0),je("delayStart",this,{evt:e}),!r.delay||r.delayOnTouchOnly&&!t||this.nativeDraggable&&(ee||K))o();else{if(Ct.eventCanceled)return void this._onDrop();re(a,"mouseup",i._disableDelayedDrag),re(a,"touchend",i._disableDelayedDrag),re(a,"touchcancel",i._disableDelayedDrag),re(a,"mousemove",i._delayedDragTouchMoveHandler),re(a,"touchmove",i._delayedDragTouchMoveHandler),r.supportPointer&&re(a,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(o,r.delay)}}},_delayedDragTouchMoveHandler:function(e){var t=e.touches?e.touches[0]:e;Math.max(Math.abs(t.clientX-this._lastX),Math.abs(t.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){Fe&&kt(Fe),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;ae(e,"mouseup",this._disableDelayedDrag),ae(e,"touchend",this._disableDelayedDrag),ae(e,"touchcancel",this._disableDelayedDrag),ae(e,"mousemove",this._delayedDragTouchMoveHandler),ae(e,"touchmove",this._delayedDragTouchMoveHandler),ae(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,t){t=t||"touch"==e.pointerType&&e,!this.nativeDraggable||t?this.options.supportPointer?re(document,"pointermove",this._onTouchMove):re(document,t?"touchmove":"mousemove",this._onTouchMove):(re(Fe,"dragend",this),re(Ye,"dragstart",this._onDragStart));try{document.selection?Mt((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(n){}},_dragStarted:function(e,t){if(st=!1,Ye&&Fe){je("dragStarted",this,{evt:t}),this.nativeDraggable&&re(document,"dragover",At);var n=this.options;!e&&pe(Fe,n.dragClass,!1),pe(Fe,n.ghostClass,!0),Ct.active=this,e&&this._appendGhost(),Ve({sortable:this,name:"start",originalEvent:t})}else this._nulling()},_emulateDragOver:function(){if(Ze){this._lastX=Ze.clientX,this._lastY=Ze.clientY,St();for(var e=document.elementFromPoint(Ze.clientX,Ze.clientY),t=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(Ze.clientX,Ze.clientY))!==t;)t=e;if(Fe.parentNode[ke]._isOutsideThisEl(e),t)do{if(t[ke]){if(t[ke]._onDragOver({clientX:Ze.clientX,clientY:Ze.clientY,target:e,rootEl:t})&&!this.options.dragoverBubble)break}e=t}while(t=t.parentNode);It()}},_onTouchMove:function(e){if(Qe){var t=this.options,n=t.fallbackTolerance,o=t.fallbackOffset,i=e.touches?e.touches[0]:e,l=Xe&&fe(Xe,!0),r=Xe&&l&&l.a,a=Xe&&l&&l.d,s=gt&&at&&Se(at),u=(i.clientX-Qe.clientX+o.x)/(r||1)+(s?s[0]-pt[0]:0)/(r||1),c=(i.clientY-Qe.clientY+o.y)/(a||1)+(s?s[1]-pt[1]:0)/(a||1);if(!Ct.active&&!st){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))o.right+i||e.clientX<=o.right&&e.clientY>o.bottom&&e.clientX>=o.left:e.clientX>o.right&&e.clientY>o.top||e.clientX<=o.right&&e.clientY>o.bottom+i}(e,i,this)&&!f.animated){if(f===Fe)return O(!1);if(f&&l===e.target&&(r=f),r&&(n=be(r)),!1!==Dt(Ye,l,Fe,t,r,n,e,!!r))return T(),l.appendChild(Fe),Re=l,M(),O(!0)}else if(f&&function(e,t,n){var o=be(we(n.el,0,n.options,!0)),i=10;return t?e.clientXc+u*l/2:sd-rt)return-lt}else if(s>c+u*(1-i)/2&&sd-u*l/2))return s>c+u/2?1:-1;return 0}(e,r,n,i,x?1:a.swapThreshold,null==a.invertedSwapThreshold?a.swapThreshold:a.invertedSwapThreshold,ht,it===r),0!==g){var E=_e(Fe);do{E-=g,y=Re.children[E]}while(y&&("none"===ve(y,"display")||y===Xe))}if(0===g||y===r)return O(!1);it=r,lt=g;var A=r.nextElementSibling,C=!1,D=Dt(Ye,l,Fe,t,r,n,e,C=1===g);if(!1!==D)return 1!==D&&-1!==D||(C=1===D),vt=!0,setTimeout(Tt,30),T(),C&&!A?l.appendChild(Fe):r.parentNode.insertBefore(Fe,C?A:r),S&&Ce(S,0,I-S.scrollTop),Re=Fe.parentNode,void 0===b||ht||(rt=Math.abs(b-be(r)[_])),M(),O(!0)}if(l.contains(Fe))return O(!1)}return!1}function k(a,s){je(a,p,z({evt:e,isOwner:c,axis:i?"vertical":"horizontal",revert:o,dragRect:t,targetRect:n,canSort:d,fromSortable:h,target:r,completed:O,onMove:function(n,o){return Dt(Ye,l,Fe,t,n,be(n),e,o)},changed:M},s))}function T(){k("dragOverAnimationCapture"),p.captureAnimationState(),p!==h&&h.captureAnimationState()}function O(t){return k("dragOverCompleted",{insertion:t}),t&&(c?u._hideClone():u._showClone(p),p!==h&&(pe(Fe,Je?Je.options.ghostClass:u.options.ghostClass,!1),pe(Fe,a.ghostClass,!0)),Je!==p&&p!==Ct.active?Je=p:p===Ct.active&&Je&&(Je=null),h===p&&(p._ignoreWhileAnimating=r),p.animateAll((function(){k("dragOverAnimationComplete"),p._ignoreWhileAnimating=null})),p!==h&&(h.animateAll(),h._ignoreWhileAnimating=null)),(r===Fe&&!Fe.animated||r===l&&!r.animated)&&(it=null),a.dragoverBubble||e.rootEl||r===document||(Fe.parentNode[ke]._isOutsideThisEl(e.target),!t&&Et(e)),!a.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),v=!0}function M(){We=_e(Fe),qe=_e(Fe,a.draggable),Ve({sortable:p,name:"change",toEl:l,newIndex:We,newDraggableIndex:qe,originalEvent:e})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){ae(document,"mousemove",this._onTouchMove),ae(document,"touchmove",this._onTouchMove),ae(document,"pointermove",this._onTouchMove),ae(document,"dragover",Et),ae(document,"mousemove",Et),ae(document,"touchmove",Et)},_offUpEvents:function(){var e=this.el.ownerDocument;ae(e,"mouseup",this._onDrop),ae(e,"touchend",this._onDrop),ae(e,"pointerup",this._onDrop),ae(e,"touchcancel",this._onDrop),ae(document,"selectstart",this)},_onDrop:function(e){var t=this.el,n=this.options;We=_e(Fe),qe=_e(Fe,n.draggable),je("drop",this,{evt:e}),Re=Fe&&Fe.parentNode,We=_e(Fe),qe=_e(Fe,n.draggable),Ct.eventCanceled||(st=!1,ht=!1,dt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Nt(this.cloneId),Nt(this._dragStartId),this.nativeDraggable&&(ae(document,"drop",this),ae(t,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),ne&&ve(document.body,"user-select",""),ve(Fe,"transform",""),e&&(ot&&(e.cancelable&&e.preventDefault(),!n.dropBubble&&e.stopPropagation()),Xe&&Xe.parentNode&&Xe.parentNode.removeChild(Xe),(Ye===Re||Je&&"clone"!==Je.lastPutMode)&&$e&&$e.parentNode&&$e.parentNode.removeChild($e),Fe&&(this.nativeDraggable&&ae(Fe,"dragend",this),kt(Fe),Fe.style["will-change"]="",ot&&!st&&pe(Fe,Je?Je.options.ghostClass:this.options.ghostClass,!1),pe(Fe,this.options.chosenClass,!1),Ve({sortable:this,name:"unchoose",toEl:Re,newIndex:null,newDraggableIndex:null,originalEvent:e}),Ye!==Re?(We>=0&&(Ve({rootEl:Re,name:"add",toEl:Re,fromEl:Ye,originalEvent:e}),Ve({sortable:this,name:"remove",toEl:Re,originalEvent:e}),Ve({rootEl:Re,name:"sort",toEl:Re,fromEl:Ye,originalEvent:e}),Ve({sortable:this,name:"sort",toEl:Re,originalEvent:e})),Je&&Je.save()):We!==He&&We>=0&&(Ve({sortable:this,name:"update",toEl:Re,originalEvent:e}),Ve({sortable:this,name:"sort",toEl:Re,originalEvent:e})),Ct.active&&(null!=We&&-1!==We||(We=He,qe=ze),Ve({sortable:this,name:"end",toEl:Re,originalEvent:e}),this.save())))),this._nulling()},_nulling:function(){je("nulling",this),Ye=Fe=Re=Xe=Le=$e=Be=Ue=Qe=Ze=ot=We=qe=He=ze=it=lt=Je=Ge=Ct.dragged=Ct.ghost=Ct.clone=Ct.active=null,ft.forEach((function(e){e.checked=!0})),ft.length=Ke=et=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":Fe&&(this._onDragOver(e),function(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move");e.cancelable&&e.preventDefault()}(e));break;case"selectstart":e.preventDefault()}},toArray:function(){for(var e,t=[],n=this.el.children,o=0,i=n.length,l=this.options;oe.replace(Gt,((e,t)=>t?t.toUpperCase():""))));function Qt(e){null!==e.parentElement&&e.parentElement.removeChild(e)}function Zt(e,t,n){const o=0===n?e.children[0]:e.children[n-1].nextSibling;e.insertBefore(t,o)}function Kt(e,t){this.$nextTick((()=>this.$emit(e.toLowerCase(),t)))}function en(e){return t=>{null!==this.realList&&this["onDrag"+e](t),Kt.call(this,e,t)}}const tn=["Start","Add","Remove","Update","End"],nn=["Choose","Unchoose","Sort","Filter","Clone"],on=["Move",...tn,...nn].map((e=>"on"+e));let ln=null;const rn={options:Object,list:{type:Array,required:!1,default:null},noTransitionOnDrag:{type:Boolean,default:!1},clone:{type:Function,default:e=>e},tag:{type:String,default:"div"},move:{type:Function,default:null},componentData:{type:Object,required:!1,default:null},component:{type:String,default:null},modelValue:{type:Array,required:!1,default:null}},an=t({name:"VueDraggableNext",inheritAttrs:!1,emits:["update:modelValue","move","change",...tn.map((e=>e.toLowerCase())),...nn.map((e=>e.toLowerCase()))],props:rn,data:()=>({transitionMode:!1,noneFunctionalComponentMode:!1,headerOffset:0,footerOffset:0,_sortable:{},visibleIndexes:[],context:{}}),render(){const e=this.$slots.default?this.$slots.default():null,t=(o=this.$attrs,(i=this.componentData)?{...i.props,...i.attrs}:o);var o,i;return e?(this.transitionMode=function(e){if(!e||1!==e.length)return!1;const[{type:t}]=e;return!!t&&(n=t.name,["transition-group","TransitionGroup"].includes(n));var n}(e),n(this.getTag(),t,e)):n(this.getTag(),t,[])},created(){null!==this.list&&null!==this.modelValue&&qt.error("list props are mutually exclusive! Please set one.")},mounted(){const e={};tn.forEach((t=>{e["on"+t]=en.call(this,t)})),nn.forEach((t=>{e["on"+t]=Kt.bind(this,t)}));const t=Object.keys(this.$attrs).reduce(((e,t)=>(e[Jt(t)]=this.$attrs[t],e)),{}),n=Object.assign({},t,e,{onMove:(e,t)=>this.onDragMove(e,t)});!("draggable"in n)&&(n.draggable=">*");const o=1===this.$el.nodeType?this.$el:this.$el.parentElement;this._sortable=new Ct(o,n),o.__draggable_component__=this,this.computeIndexes()},beforeUnmount(){try{void 0!==this._sortable&&this._sortable.destroy()}catch(e){}},computed:{realList(){return this.list?this.list:this.modelValue}},watch:{$attrs:{handler(e){this.updateOptions(e)},deep:!0},realList(){this.computeIndexes()}},methods:{getTag(){return this.component?o(this.component):this.tag},updateOptions(e){for(var t in e){const n=Jt(t);-1===on.indexOf(n)&&this._sortable.option(n,e[t])}},getChildrenNodes(){return this.$el.children},computeIndexes(){this.$nextTick((()=>{this.visibleIndexes=function(e,t,n,o){if(!e)return[];const i=Object.values(e),l=t.length-o;return[...t].map(((e,t)=>t>=l?i.length:i.indexOf(e)))}(this.getChildrenNodes(),this.$el.children,this.transitionMode,this.footerOffset)}))},getUnderlyingVm(e){const t=function(e,t){return Object.values(e).indexOf(t)}(this.getChildrenNodes()||[],e);if(-1===t)return null;return{index:t,element:this.realList[t]}},emitChanges(e){this.$nextTick((()=>{this.$emit("change",e)}))},alterList(e){if(this.list)return void e(this.list);const t=[...this.modelValue];e(t),this.$emit("update:modelValue",t)},spliceList(){this.alterList((e=>e.splice(...arguments)))},updatePosition(e,t){this.alterList((n=>n.splice(t,0,n.splice(e,1)[0])))},getVmIndex(e){const t=this.visibleIndexes,n=t.length;return e>n-1?n:t[e]},getComponent(){return this.$slots.default?this.$slots.default()[0].componentInstance:null},resetTransitionData(e){if(!this.noTransitionOnDrag||!this.transitionMode)return;this.getChildrenNodes()[e].data=null;const t=this.getComponent();t.children=[],t.kept=void 0},onDragStart(e){this.computeIndexes(),this.context=this.getUnderlyingVm(e.item),this.context&&(e.item._underlying_vm_=this.clone(this.context.element),ln=e.item)},onDragAdd(e){const t=e.item._underlying_vm_;if(void 0===t)return;Qt(e.item);const n=this.getVmIndex(e.newIndex);this.spliceList(n,0,t),this.computeIndexes();const o={element:t,newIndex:n};this.emitChanges({added:o})},onDragRemove(e){if(Zt(this.$el,e.item,e.oldIndex),"clone"===e.pullMode)return void Qt(e.clone);if(!this.context)return;const t=this.context.index;this.spliceList(t,1);const n={element:this.context.element,oldIndex:t};this.resetTransitionData(t),this.emitChanges({removed:n})},onDragUpdate(e){Qt(e.item),Zt(e.from,e.item,e.oldIndex);const t=this.context.index,n=this.getVmIndex(e.newIndex);this.updatePosition(t,n);const o={element:this.context.element,oldIndex:t,newIndex:n};this.emitChanges({moved:o})},updateProperty(e,t){e.hasOwnProperty(t)&&(e[t]+=this.headerOffset)},onDragMove(e,t){const n=this.move;if(!n||!this.realList)return!0;const o=this.getRelatedContextFromMoveEvent(e),i=this.context,l=this.computeFutureIndex(o,e);Object.assign(i,{futureIndex:l});return n(Object.assign({},e,{relatedContext:o,draggedContext:i}),t)},onDragEnd(){this.computeIndexes(),ln=null},getTrargetedComponent:e=>e.__draggable_component__,getRelatedContextFromMoveEvent({to:e,related:t}){const n=this.getTrargetedComponent(e);if(!n)return{component:n};const o=n.realList,i={list:o,component:n};if(e!==t&&o&&n.getUnderlyingVm){const e=n.getUnderlyingVm(t);if(e)return Object.assign(e,i)}return i},computeFutureIndex(e,t){const n=[...t.to.children].filter((e=>"none"!==e.style.display));if(0===n.length)return 0;const o=n.indexOf(t.related),i=e.component.getVmIndex(o);return-1!==n.indexOf(ln)||!t.willInsertAfter?i:i+1}}});const sn=i(t({components:{draggable:an},props:{headerText:{type:String,default:"header"},list:{type:Array,default:()=>[]},classString:{type:String,default:"board-column-content"},disabled:{type:Boolean,default:!1},options:{type:Object,default:()=>null}},setup:(e,{emit:t})=>({onEnd:e=>{t("end",e)}})}),[["render",function(e,t,n,i,p,v){const f=o("draggable");return l(),r(f,h({list:e.list},e.$attrs,{class:e.classString,disabled:e.disabled,onEnd:e.onEnd}),{default:a((()=>[(l(!0),s(u,null,c(e.list,((t,n)=>d(e.$slots,"default",{key:t.id,item:t,index:n},void 0,!0))),128))])),_:3},16,["list","class","disabled","onEnd"])}],["__scopeId","data-v-1b54743e"]]);function un(e){return/^(http|https):\/\/[^ "]+$/.test(e)}const cn=e=>(X("data-v-3e938df0"),e=e(),Y(),e),dn={class:"wrapper"},hn={class:"custom-menu"},pn={class:"menu-container"},vn={class:"device-wrap"},fn={class:"device device-iphone-x"},mn={class:"device-frame"},gn={class:"device-content"},bn={class:"wechat-header"},yn={class:"header-inner"},wn={class:"wechat-menu"},xn=["onClick"],_n={key:0,class:"children-menu-items"},Sn=["onClick"],In=k('
',5),En={key:0,class:"mt-5"},An={class:"edit-wrap"},Cn={key:0},Dn={class:"edit-content-wrap"},kn={class:"edit-title"},Tn={key:0,class:"notice-text"},On={class:"edit-form"},Mn={key:0},Nn={key:2},Pn={class:"withdraw-popup-warn"},jn=cn((()=>b("span",null,"需先",-1))),Vn=cn((()=>b("span",null,",已关联的小程序可被使用在自定义菜单、模板消息和附近的小程序等场景中",-1))),Fn={key:3},Rn={key:4},Xn={key:1},Yn={key:0},Ln={key:0},Bn={class:"withdraw-popup-warn"},$n=cn((()=>b("span",null,"需先",-1))),Un=cn((()=>b("span",null,",已关联的小程序可被使用在自定义菜单、模板消息和附近的小程序等场景中",-1))),Hn={key:1},Wn={key:2},zn={key:1},qn=[cn((()=>b("p",{class:"no-init"},"点击左侧菜单进行编辑操作",-1)))],Gn={class:"flex justify-start m-9"},Jn=i(t({__name:"customMenu",props:{primary:null|Object,type:String},emits:["close","success"],setup(t,{emit:n}){const o=t,i=v(3),c=v(!1),d=v({}),h=v({curActiveIndex:null,curSubActiveIndex:null,clickSubMenu:!1,init:!1,buttons:[]}),k=e=>{c.value=!0},X=e=>{h.value.clickSubMenu?h.value.buttons[h.value.curActiveIndex].sub_button[h.value.curSubActiveIndex].key=e:h.value.buttons[h.value.curActiveIndex].url=e},Y=e=>{h.value.clickSubMenu?h.value.buttons[h.value.curActiveIndex].sub_button[h.value.curSubActiveIndex].url="":h.value.buttons[h.value.curActiveIndex].url=""},W=e=>{c.value=!1,h.value.clickSubMenu?h.value.buttons[h.value.curActiveIndex].sub_button[h.value.curSubActiveIndex].url=e.data.url:h.value.buttons[h.value.curActiveIndex].url=e.data.url,h.value},z=()=>{n("close")},q=()=>{var e,t,i,l,r;if(!(null==(e=d.value)?void 0:e.title))return p.error("模板名称不能为空");if(!(e=>{try{return e.forEach((e=>{if(e.sub_button.length<=0&&!e.name)throw new Error(`(${e.name}) 菜单名称不能为空`);if(["view","miniprogram"].includes(e.type)&&e.sub_button.length<=0&&!e.url)throw new Error(`(${e.name}) 链接不能为空`);if(["view"].includes(e.type)&&e.sub_button.length<=0&&!un(e.url))throw new Error(`(${e.name}) 链接不合法`);if(e.sub_button.length<=0&&"click"==e.type&&!e.content)throw new Error(`${e.name} 文本内容不能为空`);e.sub_button&&e.sub_button.length>0&&e.sub_button.forEach((e=>{if(!e.name)throw new Error(`子菜单 (${e.name}) 菜单名称不能为空`);if(["view","miniprogram"].includes(e.type)&&!e.url)throw new Error(`子菜单 (${e.name}) 链接不能为空`);if(["view"].includes(e.type)&&!un(e.url))throw new Error(`(${e.name}) 链接不合法`);if("click"==e.type&&!e.content)throw new Error(`子菜单 (${e.name}) 文本内容不能为空`)}))})),!0}catch(t){return p.error(t.message),console.error(t.message),!1}})(h.value.buttons))return;let a={title:null==(t=d.value)?void 0:t.title,type:o.type,miniprogram_id:null==(i=d.value)?void 0:i.miniprogram_id,content:null==(l=h.value.buttons)?void 0:l.map((e=>{const{showChildMenu:t,hasChild:n,...o}=e;return o}))};(null==(r=o.primary)?void 0:r.id)?($(o.primary.id,a).then((e=>{p.success(e.message),n("close")})),n("success",a)):(U(a).then((e=>{p.success(e.message),n("close")})),n("success",a))},G=f((()=>{var e,t,n,o,i,l,r,a,s,u;return(null==(i=null==(o=null==(t=h.value)?void 0:t.buttons[null==(e=h.value)?void 0:e.curActiveIndex])?void 0:o.sub_button[null==(n=h.value)?void 0:n.curSubActiveIndex])?void 0:i.name)||(null==(u=null==(s=null==(r=h.value)?void 0:r.buttons[null==(l=h.value)?void 0:l.curActiveIndex])?void 0:s.sub_button[null==(a=h.value)?void 0:a.curSubActiveIndex])?void 0:u.type)})),J=v(!0),Q=e=>{h.value.init=!0,h.value.clickSubMenu=!1,h.value.curSubActiveIndex=null,h.value.curActiveIndex=e.newDraggableIndex,h.value.buttons.forEach((e=>e.showChildMenu=!1)),h.value.buttons[e.newDraggableIndex].showChildMenu=!0},Z=e=>{h.value.curSubActiveIndex=e.newDraggableIndex},K=()=>{h.value.init=!0,h.value.clickSubMenu=!0;let e=h.value.curActiveIndex;h.value.buttons[e].sub_button.push({name:"子菜单名称",url:"",key:"子菜单名称",content:"",type:"miniprogram"}),h.value.curSubActiveIndex=h.value.buttons[e].sub_button.length-1,h.value.buttons[e].hasChild=!0},ee=()=>{h.value.curActiveIndex=null,h.value.curSubActiveIndex=null,h.value.init=!1};var te;return o.primary&&(o.primary,te=o.primary.id,H(te).then((e=>{d.value=e.data,h.value.buttons=e.data.content,e.data,h.value}))),m((()=>{var e,t;(null==(e=JSON.parse(g.get("nav_data")))?void 0:e.app.id)&&(d.value.miniprogram_id=null==(t=JSON.parse(g.get("nav_data")))?void 0:t.app.id),h.value={curActiveIndex:0,curSubActiveIndex:null,clickSubMenu:!1,init:!0,buttons:[{name:"首页",hasChild:!1,showChildMenu:!0,content:"",type:"miniprogram",url:"/pages/index/index",key:"首页",sub_button:[]},{name:"我的",hasChild:!1,showChildMenu:!1,content:"",type:"miniprogram",url:"/pages/member/index",key:"我的",sub_button:[]},{name:"菜单名称3",hasChild:!0,showChildMenu:!1,content:"",type:"miniprogram",url:"",key:"菜单名称3",sub_button:[{key:"子菜单名称",type:"view",name:"子菜单名称",content:"",url:""}]}]}})),(t,n)=>{var p,v,f,m,g,$,U,H,te,ne,oe,ie,le,re,ae,se,ue;const ce=O,de=M,he=N,pe=L,ve=sn,fe=P,me=j,ge=V,be=F,ye=R,we=e;return l(),s(u,null,[b("div",dn,[b("div",hn,[y(de,{label:"模板名称",class:"m-5",style:{width:"300px"},prop:"title",rules:[{required:!1,message:"模板名称必须填写"}]},{default:a((()=>{var e;return[y(ce,{modelValue:w(d).title,"onUpdate:modelValue":n[0]||(n[0]=e=>w(d).title=e),disabled:null==(e=o.primary)?void 0:e.look,name:"title",clearable:""},null,8,["modelValue","disabled"])]})),_:1}),b("div",pn,[b("div",vn,[b("div",fn,[b("div",mn,[b("div",gn,[b("div",bn,[b("div",yn,[y(he,{class:"ml-3"},{default:a((()=>[y(w(x))])),_:1}),_(" 公众号 "),y(he,{class:"mr-3"},{default:a((()=>[y(w(S))])),_:1})])]),b("div",wn,[y(ve,{disabled:null==(p=o.primary)?void 0:p.look,list:w(h).buttons,classString:"flex-warpper",onEnd:Q},{default:a((({item:e,index:t})=>{var n,u,c;return[(l(),s("div",{class:"flex items-center justify-start wechat-menu-item",key:t},[b("p",{class:I(["menu-name",{"cur-menu":t===w(h).curActiveIndex}]),onClick:e=>(e=>{h.value.init=!0,h.value.clickSubMenu=!1,h.value.curSubActiveIndex=null;let t=h.value.buttons;if(e===h.value.curActiveIndex)return;if(null!==h.value.curActiveIndex&&h.value.buttons[h.value.curActiveIndex]&&(h.value.buttons[h.value.curActiveIndex].showChildMenu=!1),h.value.curActiveIndex=e,t[e])return void(h.value.buttons[h.value.curActiveIndex]&&(h.value.buttons[h.value.curActiveIndex].showChildMenu=!0));if(t.length>=i.value)return;h.value.buttons.push({name:"菜单名称",hasChild:!1,showChildMenu:!0,type:"miniprogram",url:"",key:"菜单名称",content:"",sub_button:[]})})(t)},[e.sub_button.length>0?(l(),r(he,{key:0},{default:a((()=>[y(pe,{name:"bars-3",class:"text-sm"})])),_:1})):E("",!0),b("span",null,A(e.name),1)],10,xn),t===w(h).curActiveIndex?(l(),s("div",_n,[y(ve,{disabled:null==(n=o.primary)?void 0:n.look,list:e.sub_button,onEnd:Z},{default:a((({item:e,index:t})=>[(l(),s("div",{class:"children-menu-item",key:t,onClick:e=>{var n;(n=t)!==h.value.curSubActiveIndex&&(h.value.init=!0,h.value.clickSubMenu=!0,h.value.curSubActiveIndex=n)}},[b("p",{class:I(["menu-name",{"cur-name":w(h).curSubActiveIndex===t}])},A(e.name),3)],8,Sn))])),_:2},1032,["disabled","list"]),(null==(u=null==e?void 0:e.sub_button)?void 0:u.length)<5&&!(null==(c=o.primary)?void 0:c.look)?(l(),s("div",{key:0,class:"children-menu-item",onClick:K},[y(he,null,{default:a((()=>[y(w(C))])),_:1})])):E("",!0)])):E("",!0)]))]})),_:1},8,["disabled","list"])])])]),In]),(null==(v=o.primary)?void 0:v.look)?E("",!0):(l(),s("div",En,"可直接拖动菜单排序"))]),b("div",An,[w(h).init?(l(),s("div",Cn,[b("div",Dn,[b("p",kn,[_(A(w(h).clickSubMenu?null==(g=null==(m=null==(f=w(h))?void 0:f.buttons[w(h).curActiveIndex])?void 0:m.sub_button[w(h).curSubActiveIndex])?void 0:g.name:null==(U=null==($=w(h))?void 0:$.buttons[w(h).curActiveIndex])?void 0:U.name)+" ",1),(null==(H=o.primary)?void 0:H.look)?E("",!0):(l(),s("span",{key:0,class:"del-menu",onClick:n[1]||(n[1]=e=>(e=>{let t=h.value.curActiveIndex,n=h.value.curSubActiveIndex;T.confirm(e?"删除后“子菜单名称”菜单下设置的内容将被删除":"删除后“菜单名称”菜单下设置的内容将被删除","温馨提示",{confirmButtonText:"确定",cancelButtonText:"取消",type:"warning"}).then((()=>{e?(h.value.buttons[t].sub_button.splice(n,1),h.value.buttons[t].hasChild=h.value.buttons[t].sub_button.length>0,h.value.curSubActiveIndex=null,h.value.init=!1):(h.value.buttons.splice(t,1),h.value.buttons.length||(J.value=!0),ee())})).catch((()=>{}))})(w(h).clickSubMenu))}," 删除"+A(w(h).clickSubMenu?"子菜单":"菜单"),1))]),(null==(oe=null==(ne=w(h))?void 0:ne.buttons[null==(te=w(h))?void 0:te.curActiveIndex])?void 0:oe.hasChild)&&!w(h).clickSubMenu?(l(),s("p",Tn," 已添加子菜单,仅可设置菜单名称。 ")):E("",!0),b("div",On,[w(h).clickSubMenu?(l(),s("div",Mn,[y(ye,{model:null==(ie=w(h).buttons[w(h).curActiveIndex])?void 0:ie.sub_button[w(h).curSubActiveIndex],disabled:null==(le=o.primary)?void 0:le.look,"label-width":"100px","label-position":"left"},{default:a((()=>{var e,t,o,i,u,c,d,p,v,f,m,g,x,S,I;return[w(G)?(l(),r(de,{key:0,label:"子菜单名称",prop:"title"},{default:a((()=>[y(ce,{onChange:X,modelValue:w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].name,"onUpdate:modelValue":n[2]||(n[2]=e=>w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].name=e),style:{width:"260px"}},null,8,["modelValue"])])),_:1})):E("",!0),w(G)?(l(),r(de,{key:1,label:"子菜单内容"},{default:a((()=>[y(me,{onChange:Y,modelValue:w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].type,"onUpdate:modelValue":n[3]||(n[3]=e=>w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].type=e)},{default:a((()=>[y(fe,{class:"radio",label:"miniprogram"},{default:a((()=>[_("跳转小程序链接")])),_:1}),y(fe,{class:"radio",label:"view"},{default:a((()=>[_("跳转网页")])),_:1}),y(fe,{class:"radio",label:"click"},{default:a((()=>[_("纯文本")])),_:1})])),_:1},8,["modelValue"])])),_:1})):E("",!0),"miniprogram"==(null==(u=null==(i=null==(t=w(h))?void 0:t.buttons[null==(e=w(h))?void 0:e.curActiveIndex])?void 0:i.sub_button[null==(o=w(h))?void 0:o.curSubActiveIndex])?void 0:u.type)?(l(),s("div",Nn,[b("div",Pn,[jn,y(ge,{class:"text-lg font-bold text-blue-400 cursor-pointer",type:"primary",href:"https://docs.qq.com/doc/DUWlNb0RsTXFQelFF",target:"_blank"},{default:a((()=>[_("关联小程序")])),_:1}),Vn]),y(de,{label:"链接"},{default:a((()=>[y(ce,{style:{width:"300px"},modelValue:w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].url,"onUpdate:modelValue":n[4]||(n[4]=e=>w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].url=e),"auto-complete":"off",placeholder:"请输入链接"},null,8,["modelValue"]),y(be,{type:"primary",link:"",icon:w(C),onClick:n[5]||(n[5]=e=>k()),class:"mr-6"},{default:a((()=>[_("插入链接")])),_:1},8,["icon"])])),_:1})])):E("",!0),"view"==(null==(f=null==(v=null==(d=w(h))?void 0:d.buttons[null==(c=w(h))?void 0:c.curActiveIndex])?void 0:v.sub_button[null==(p=w(h))?void 0:p.curSubActiveIndex])?void 0:f.type)?(l(),s("div",Fn,[y(de,{label:"网页链接"},{default:a((()=>[y(ce,{style:{width:"300px"},type:"url",modelValue:w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].url,"onUpdate:modelValue":n[6]||(n[6]=e=>w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].url=e),"auto-complete":"off",placeholder:"请输入网页链接"},null,8,["modelValue"])])),_:1})])):E("",!0),"click"==(null==(I=null==(S=null==(g=w(h))?void 0:g.buttons[null==(m=w(h))?void 0:m.curActiveIndex])?void 0:S.sub_button[null==(x=w(h))?void 0:x.curSubActiveIndex])?void 0:I.type)?(l(),s("div",Rn,[y(de,{label:"文本内容"},{default:a((()=>[y(ce,{style:{width:"300px"},type:"textarea",modelValue:w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].content,"onUpdate:modelValue":n[7]||(n[7]=e=>w(h).buttons[w(h).curActiveIndex].sub_button[w(h).curSubActiveIndex].content=e),"auto-complete":"off",placeholder:"请输入文本内容"},null,8,["modelValue"])])),_:1})])):E("",!0)]})),_:1},8,["model","disabled"])])):(l(),s("div",Xn,[y(ye,{disabled:null==(re=o.primary)?void 0:re.look,model:null==(se=w(h))?void 0:se.buttons[null==(ae=w(h))?void 0:ae.curActiveIndex],"label-width":"100px","label-position":"left"},{default:a((()=>{var e,t,o,i,r,u,c,d,p;return[y(de,{label:"菜单名称",prop:"title"},{default:a((()=>[y(ce,{modelValue:w(h).buttons[w(h).curActiveIndex].name,"onUpdate:modelValue":n[8]||(n[8]=e=>w(h).buttons[w(h).curActiveIndex].name=e),onChange:X,style:{width:"260px"},maxlength:10,placeholder:"请输入菜单名称(最多10个字符)"},null,8,["modelValue"])])),_:1}),w(h).buttons[w(h).curActiveIndex].sub_button.length?E("",!0):(l(),s("div",Yn,[y(de,{label:"菜单内容"},{default:a((()=>[y(me,{onChange:Y,modelValue:w(h).buttons[w(h).curActiveIndex].type,"onUpdate:modelValue":n[9]||(n[9]=e=>w(h).buttons[w(h).curActiveIndex].type=e)},{default:a((()=>[y(fe,{class:"radio",label:"miniprogram"},{default:a((()=>[_("跳转小程序链接")])),_:1}),y(fe,{class:"radio",label:"view"},{default:a((()=>[_("跳转网页")])),_:1}),y(fe,{class:"radio",label:"click"},{default:a((()=>[_("纯文本")])),_:1})])),_:1},8,["modelValue"])])),_:1}),"miniprogram"==(null==(o=null==(t=w(h))?void 0:t.buttons[null==(e=w(h))?void 0:e.curActiveIndex])?void 0:o.type)?(l(),s("div",Ln,[b("div",Bn,[$n,y(ge,{class:"text-lg font-bold text-blue-400 cursor-pointer",type:"primary",href:"https://docs.qq.com/doc/DUWlNb0RsTXFQelFF",target:"_blank"},{default:a((()=>[_("关联小程序")])),_:1}),Un]),y(de,{label:"链接"},{default:a((()=>[y(ce,{style:{width:"300px"},modelValue:w(h).buttons[w(h).curActiveIndex].url,"onUpdate:modelValue":n[10]||(n[10]=e=>w(h).buttons[w(h).curActiveIndex].url=e),"auto-complete":"off",placeholder:"请输入链接"},null,8,["modelValue"]),y(be,{type:"primary",link:"",icon:w(C),onClick:n[11]||(n[11]=e=>k()),class:"mr-6"},{default:a((()=>[_("插入链接")])),_:1},8,["icon"])])),_:1})])):E("",!0),"view"==(null==(u=null==(r=w(h))?void 0:r.buttons[null==(i=w(h))?void 0:i.curActiveIndex])?void 0:u.type)?(l(),s("div",Hn,[y(de,{label:"网页链接"},{default:a((()=>[y(ce,{style:{width:"300px"},type:"url",modelValue:w(h).buttons[w(h).curActiveIndex].url,"onUpdate:modelValue":n[12]||(n[12]=e=>w(h).buttons[w(h).curActiveIndex].url=e),"auto-complete":"off",placeholder:"请输入网页链接"},null,8,["modelValue"])])),_:1})])):E("",!0),"click"==(null==(p=null==(d=w(h))?void 0:d.buttons[null==(c=w(h))?void 0:c.curActiveIndex])?void 0:p.type)?(l(),s("div",Wn,[y(de,{label:"文本内容"},{default:a((()=>[y(ce,{style:{width:"300px"},type:"textarea",modelValue:w(h).buttons[w(h).curActiveIndex].content,"onUpdate:modelValue":n[13]||(n[13]=e=>w(h).buttons[w(h).curActiveIndex].content=e),"auto-complete":"off",placeholder:"请输入文本内容"},null,8,["modelValue"])])),_:1})])):E("",!0)]))]})),_:1},8,["disabled","model"])]))])])])):(l(),s("div",zn,qn))])]),b("div",Gn,[y(be,{size:"default",onClick:z},{default:a((()=>[_("取消")])),_:1}),(null==(ue=o.primary)?void 0:ue.look)?E("",!0):(l(),r(be,{key:0,type:"primary",onClick:q},{default:a((()=>[_("确认")])),_:1}))])])]),y(we,{modelValue:w(c),"onUpdate:modelValue":n[14]||(n[14]=e=>D(c)?c.value=e:null),title:"选择链接","destroy-on-close":""},{default:a((()=>[y(B,{onSuccess:W})])),_:1},8,["modelValue"])],64)}}}),[["__scopeId","data-v-3e938df0"]]);export{Jn as default};