All checks were successful
CI / PHP 8.4 / mariadb:10.6 (pull_request) Successful in 2m30s
CI / PHP 8.3 / mariadb:10.6 (pull_request) Successful in 2m34s
CI / PHP 8.4 / mariadb:11.4 (pull_request) Successful in 2m41s
CI / PHP 8.3 / mariadb:11.4 (pull_request) Successful in 2m45s
CI / PHP 8.3 / mysql:8.0 (pull_request) Successful in 3m35s
CI / PHP 8.4 / mysql:8.0 (pull_request) Successful in 3m42s
CI / PHP 8.3 / mysql:8.4 (pull_request) Successful in 3m7s
CI / PHP 8.4 / mysql:8.4 (pull_request) Successful in 3m15s
CI / Build-Artefakte aktuell (pull_request) Successful in 1m8s
- Organigramm: grafischer Baum (Linien, Zoom, Verschieben) und Fokus-Ansicht mit Vorgesetzten, Team und direkt Unterstellten - Dokumente: Übersicht mit Bereichen und „Zuletzt aktualisiert“, sortierbare Dateiliste oder Kacheln (Wahl wird gemerkt) Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
1 line
No EOL
42 KiB
JavaScript
1 line
No EOL
42 KiB
JavaScript
import{B as e,Ht as t,L as n,On as r,Tn as i,ct as a,ft as o,g as s,gn as c,k as l,tt as u,un as d,vn as f}from"./runtime-core.esm-bundler-B8D2lM98.js";import{j as p}from"./dist-CleIz2GP.js";var m=p({name:`copy`,size:24,node:[[`rect`,{width:`14`,height:`14`,x:`8`,y:`8`,rx:`2`,ry:`2`,key:`17jyea`}],[`path`,{d:`M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2`,key:`zix9uf`}]]}),h=p({name:`grip-vertical`,size:24,node:[[`circle`,{cx:`9`,cy:`12`,r:`1`,key:`1vctgf`}],[`circle`,{cx:`9`,cy:`5`,r:`1`,key:`hp0tcf`}],[`circle`,{cx:`9`,cy:`19`,r:`1`,key:`fkjjf6`}],[`circle`,{cx:`15`,cy:`12`,r:`1`,key:`1tmaij`}],[`circle`,{cx:`15`,cy:`5`,r:`1`,key:`19l28e`}],[`circle`,{cx:`15`,cy:`19`,r:`1`,key:`f4zoj3`}]]}),g=p({name:`heading`,size:24,node:[[`path`,{d:`M6 12h12`,key:`8npq4p`}],[`path`,{d:`M6 20V4`,key:`1w1bmo`}],[`path`,{d:`M18 20V4`,key:`o2hl4u`}]]}),_=p({name:`list-checks`,size:24,node:[[`path`,{d:`M13 5h8`,key:`a7qcls`}],[`path`,{d:`M13 12h8`,key:`h98zly`}],[`path`,{d:`M13 19h8`,key:`c3s6r1`}],[`path`,{d:`m3 17 2 2 4-4`,key:`1jhpwq`}],[`path`,{d:`m3 7 2 2 4-4`,key:`1obspn`}]]}),v=p({name:`settings-2`,size:24,node:[[`path`,{d:`M14 17H5`,key:`gfn3mx`}],[`path`,{d:`M19 7h-9`,key:`6i9tg`}],[`circle`,{cx:`17`,cy:`17`,r:`3`,key:`18b49y`}],[`circle`,{cx:`7`,cy:`7`,r:`3`,key:`dfmy0x`}]]}),y=p({name:`text-align-start`,size:24,node:[[`path`,{d:`M21 5H3`,key:`1fi0y6`}],[`path`,{d:`M15 12H3`,key:`6jk70r`}],[`path`,{d:`M17 19H3`,key:`z6ezky`}]],aliases:[`text`,`align-left`]}),ee=Object.defineProperty,b=Object.getOwnPropertySymbols,x=Object.prototype.hasOwnProperty,te=Object.prototype.propertyIsEnumerable,S=(e,t,n)=>t in e?ee(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,C=(e,t)=>{for(var n in t||={})x.call(t,n)&&S(e,n,t[n]);if(b)for(var n of b(t))te.call(t,n)&&S(e,n,t[n]);return e},w=(e,t)=>{var n={};for(var r in e)x.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&b)for(var r of b(e))t.indexOf(r)<0&&te.call(e,r)&&(n[r]=e[r]);return n},ne=`[vue-draggable-plus]: `;function T(e){console.warn(ne+e)}function re(e){console.error(ne+e)}function E(e,t,n){return n>=0&&n<e.length&&e.splice(n,0,e.splice(t,1)[0]),e}function ie(e){return e.replace(/-(\w)/g,(e,t)=>t?t.toUpperCase():``)}function ae(e){return Object.keys(e).reduce((t,n)=>(e[n]!==void 0&&(t[ie(n)]=e[n]),t),{})}function oe(e,t){return Array.isArray(e)&&e.splice(t,1),e}function se(e,t,n){return Array.isArray(e)&&e.splice(t,0,n),e}function ce(e){return e===void 0}function le(e){return typeof e==`string`}function ue(e,t,n){let r=e.children[n];e.insertBefore(t,r)}function de(e){e.parentNode&&e.parentNode.removeChild(e)}function fe(e,t=document){let n=null;return n=typeof t?.querySelector==`function`?(t?.querySelector)?.call(t,e):document.querySelector(e),n||T(`Element not found: ${e}`),n}function pe(e,t,n=null){return function(...r){return e.apply(n,r),t.apply(n,r)}}function me(e,t){let n=C({},e);return Object.keys(t).forEach(r=>{n[r]?n[r]=pe(e[r],t[r]):n[r]=t[r]}),n}function he(e){return e instanceof HTMLElement}function ge(e,t){Object.keys(e).forEach(n=>{t(n,e[n])})}function _e(e){return e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97)}var ve=Object.assign;function ye(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]==null?{}:arguments[t];t%2?ye(Object(n),!0).forEach(function(t){xe(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ye(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function be(e){"@babel/helpers - typeof";return be=typeof Symbol==`function`&&typeof Symbol.iterator==`symbol`?function(e){return typeof e}:function(e){return e&&typeof Symbol==`function`&&e.constructor===Symbol&&e!==Symbol.prototype?`symbol`:typeof e},be(e)}function xe(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function O(){return O=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},O.apply(this,arguments)}function Se(e,t){if(e==null)return{};for(var n={},r=Object.keys(e),i,a=0;a<r.length;a++)i=r[a],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}function Ce(e,t){if(e==null)return{};var n=Se(e,t),r,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)r=a[i],!(t.indexOf(r)>=0)&&Object.prototype.propertyIsEnumerable.call(e,r)&&(n[r]=e[r])}return n}var we=`1.15.2`;function k(e){if(typeof window<`u`&&window.navigator)return!!navigator.userAgent.match(e)}var A=k(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Te=k(/Edge/i),Ee=k(/firefox/i),De=k(/safari/i)&&!k(/chrome/i)&&!k(/android/i),Oe=k(/iP(ad|od|hone)/i),ke=k(/chrome/i)&&k(/android/i),Ae={capture:!1,passive:!1};function j(e,t,n){e.addEventListener(t,n,!A&&Ae)}function M(e,t,n){e.removeEventListener(t,n,!A&&Ae)}function je(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{return!1}return!1}}function Me(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function N(e,t,n,r){if(e){n||=document;do{if(t!=null&&(t[0]===`>`?e.parentNode===n&&je(e,t):je(e,t))||r&&e===n)return e;if(e===n)break}while(e=Me(e))}return null}var Ne=/\s+/g;function P(e,t,n){e&&t&&(e.classList?e.classList[n?`add`:`remove`](t):e.className=((` `+e.className+` `).replace(Ne,` `).replace(` `+t+` `,` `)+(n?` `+t:``)).replace(Ne,` `))}function F(e,t,n){var r=e&&e.style;if(r){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,``):e.currentStyle&&(n=e.currentStyle),t===void 0?n:n[t];!(t in r)&&t.indexOf(`webkit`)===-1&&(t=`-webkit-`+t),r[t]=n+(typeof n==`string`?``:`px`)}}function Pe(e,t){var n=``;if(typeof e==`string`)n=e;else do{var r=F(e,`transform`);r&&r!==`none`&&(n=r+` `+n)}while(!t&&(e=e.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function Fe(e,t,n){if(e){var r=e.getElementsByTagName(t),i=0,a=r.length;if(n)for(;i<a;i++)n(r[i],i);return r}return[]}function I(){return document.scrollingElement||document.documentElement}function L(e,t,n,r,i){if(e.getBoundingClientRect||e===window){var a,o,s,c,l,u,d;if(e!==window&&e.parentNode&&e!==I()?(a=e.getBoundingClientRect(),o=a.top,s=a.left,c=a.bottom,l=a.right,u=a.height,d=a.width):(o=0,s=0,c=window.innerHeight,l=window.innerWidth,u=window.innerHeight,d=window.innerWidth),(t||n)&&e!==window&&(i||=e.parentNode,!A))do if(i&&i.getBoundingClientRect&&(F(i,`transform`)!==`none`||n&&F(i,`position`)!==`static`)){var f=i.getBoundingClientRect();o-=f.top+parseInt(F(i,`border-top-width`)),s-=f.left+parseInt(F(i,`border-left-width`)),c=o+a.height,l=s+a.width;break}while(i=i.parentNode);if(r&&e!==window){var p=Pe(i||e),m=p&&p.a,h=p&&p.d;p&&(o/=h,s/=m,d/=m,u/=h,c=o+u,l=s+d)}return{top:o,left:s,bottom:c,right:l,width:d,height:u}}}function Ie(e,t,n){for(var r=z(e,!0),i=L(e)[t];r;){var a=L(r)[n],o=void 0;if(o=i>=a,!o)return r;if(r===I())break;r=z(r,!1)}return!1}function Le(e,t,n,r){for(var i=0,a=0,o=e.children;a<o.length;){if(o[a].style.display!==`none`&&o[a]!==Q.ghost&&(r||o[a]!==Q.dragged)&&N(o[a],n.draggable,e,!1)){if(i===t)return o[a];i++}a++}return null}function Re(e,t){for(var n=e.lastElementChild;n&&(n===Q.ghost||F(n,`display`)===`none`||t&&!je(n,t));)n=n.previousElementSibling;return n||null}function R(e,t){var n=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)e.nodeName.toUpperCase()!==`TEMPLATE`&&e!==Q.clone&&(!t||je(e,t))&&n++;return n}function ze(e){var t=0,n=0,r=I();if(e)do{var i=Pe(e),a=i.a,o=i.d;t+=e.scrollLeft*a,n+=e.scrollTop*o}while(e!==r&&(e=e.parentNode));return[t,n]}function Be(e,t){for(var n in e)if(e.hasOwnProperty(n)){for(var r in t)if(t.hasOwnProperty(r)&&t[r]===e[n][r])return Number(n)}return-1}function z(e,t){if(!e||!e.getBoundingClientRect)return I();var n=e,r=!1;do if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var i=F(n);if(n.clientWidth<n.scrollWidth&&(i.overflowX==`auto`||i.overflowX==`scroll`)||n.clientHeight<n.scrollHeight&&(i.overflowY==`auto`||i.overflowY==`scroll`)){if(!n.getBoundingClientRect||n===document.body)return I();if(r||t)return n;r=!0}}while(n=n.parentNode);return I()}function Ve(e,t){if(e&&t)for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function He(e,t){return Math.round(e.top)===Math.round(t.top)&&Math.round(e.left)===Math.round(t.left)&&Math.round(e.height)===Math.round(t.height)&&Math.round(e.width)===Math.round(t.width)}var Ue;function We(e,t){return function(){if(!Ue){var n=arguments,r=this;n.length===1?e.call(r,n[0]):e.apply(r,n),Ue=setTimeout(function(){Ue=void 0},t)}}}function Ge(){clearTimeout(Ue),Ue=void 0}function Ke(e,t,n){e.scrollLeft+=t,e.scrollTop+=n}function qe(e){var t=window.Polymer,n=window.jQuery||window.Zepto;return t&&t.dom?t.dom(e).cloneNode(!0):n?n(e).clone(!0)[0]:e.cloneNode(!0)}function Je(e,t,n){var r={};return Array.from(e.children).forEach(function(i){if(N(i,t.draggable,e,!1)&&!i.animated&&i!==n){var a=L(i);r.left=Math.min(r.left??1/0,a.left),r.top=Math.min(r.top??1/0,a.top),r.right=Math.max(r.right??-1/0,a.right),r.bottom=Math.max(r.bottom??-1/0,a.bottom)}}),r.width=r.right-r.left,r.height=r.bottom-r.top,r.x=r.left,r.y=r.top,r}var B=`Sortable`+new Date().getTime();function Ye(){var e=[],t;return{captureAnimationState:function(){e=[],this.options.animation&&[].slice.call(this.el.children).forEach(function(t){if(F(t,`display`)!==`none`&&t!==Q.ghost){e.push({target:t,rect:L(t)});var n=D({},e[e.length-1].rect);if(t.thisAnimationDuration){var r=Pe(t,!0);r&&(n.top-=r.f,n.left-=r.e)}t.fromRect=n}})},addAnimationState:function(t){e.push(t)},removeAnimationState:function(t){e.splice(Be(e,{target:t}),1)},animateAll:function(n){var r=this;if(!this.options.animation){clearTimeout(t),typeof n==`function`&&n();return}var i=!1,a=0;e.forEach(function(e){var t=0,n=e.target,o=n.fromRect,s=L(n),c=n.prevFromRect,l=n.prevToRect,u=e.rect,d=Pe(n,!0);d&&(s.top-=d.f,s.left-=d.e),n.toRect=s,n.thisAnimationDuration&&He(c,s)&&!He(o,s)&&(u.top-s.top)/(u.left-s.left)===(o.top-s.top)/(o.left-s.left)&&(t=Ze(u,c,l,r.options)),He(s,o)||(n.prevFromRect=o,n.prevToRect=s,t||=r.options.animation,r.animate(n,u,s,t)),t&&(i=!0,a=Math.max(a,t),clearTimeout(n.animationResetTimer),n.animationResetTimer=setTimeout(function(){n.animationTime=0,n.prevFromRect=null,n.fromRect=null,n.prevToRect=null,n.thisAnimationDuration=null},t),n.thisAnimationDuration=t)}),clearTimeout(t),i?t=setTimeout(function(){typeof n==`function`&&n()},a):typeof n==`function`&&n(),e=[]},animate:function(e,t,n,r){if(r){F(e,`transition`,``),F(e,`transform`,``);var i=Pe(this.el),a=i&&i.a,o=i&&i.d,s=(t.left-n.left)/(a||1),c=(t.top-n.top)/(o||1);e.animatingX=!!s,e.animatingY=!!c,F(e,`transform`,`translate3d(`+s+`px,`+c+`px,0)`),this.forRepaintDummy=Xe(e),F(e,`transition`,`transform `+r+`ms`+(this.options.easing?` `+this.options.easing:``)),F(e,`transform`,`translate3d(0,0,0)`),typeof e.animated==`number`&&clearTimeout(e.animated),e.animated=setTimeout(function(){F(e,`transition`,``),F(e,`transform`,``),e.animated=!1,e.animatingX=!1,e.animatingY=!1},r)}}}}function Xe(e){return e.offsetWidth}function Ze(e,t,n,r){return Math.sqrt((t.top-e.top)**2+(t.left-e.left)**2)/Math.sqrt((t.top-n.top)**2+(t.left-n.left)**2)*r.animation}var Qe=[],$e={initializeByDefault:!0},et={mount:function(e){for(var t in $e)$e.hasOwnProperty(t)&&!(t in e)&&(e[t]=$e[t]);Qe.forEach(function(t){if(t.pluginName===e.pluginName)throw`Sortable: Cannot mount plugin ${e.pluginName} more than once`}),Qe.push(e)},pluginEvent:function(e,t,n){var r=this;this.eventCanceled=!1,n.cancel=function(){r.eventCanceled=!0};var i=e+`Global`;Qe.forEach(function(r){t[r.pluginName]&&(t[r.pluginName][i]&&t[r.pluginName][i](D({sortable:t},n)),t.options[r.pluginName]&&t[r.pluginName][e]&&t[r.pluginName][e](D({sortable:t},n)))})},initializePlugins:function(e,t,n,r){for(var i in Qe.forEach(function(r){var i=r.pluginName;if(e.options[i]||r.initializeByDefault){var a=new r(e,t,e.options);a.sortable=e,a.options=e.options,e[i]=a,O(n,a.defaults)}}),e.options)if(e.options.hasOwnProperty(i)){var a=this.modifyOption(e,i,e.options[i]);a!==void 0&&(e.options[i]=a)}},getEventProperties:function(e,t){var n={};return Qe.forEach(function(r){typeof r.eventProperties==`function`&&O(n,r.eventProperties.call(t[r.pluginName],e))}),n},modifyOption:function(e,t,n){var r;return Qe.forEach(function(i){e[i.pluginName]&&i.optionListeners&&typeof i.optionListeners[t]==`function`&&(r=i.optionListeners[t].call(e[i.pluginName],n))}),r}};function tt(e){var t=e.sortable,n=e.rootEl,r=e.name,i=e.targetEl,a=e.cloneEl,o=e.toEl,s=e.fromEl,c=e.oldIndex,l=e.newIndex,u=e.oldDraggableIndex,d=e.newDraggableIndex,f=e.originalEvent,p=e.putSortable,m=e.extraEventProperties;if(t||=n&&n[B],t){var h,g=t.options,_=`on`+r.charAt(0).toUpperCase()+r.substr(1);window.CustomEvent&&!A&&!Te?h=new CustomEvent(r,{bubbles:!0,cancelable:!0}):(h=document.createEvent(`Event`),h.initEvent(r,!0,!0)),h.to=o||n,h.from=s||n,h.item=i||n,h.clone=a,h.oldIndex=c,h.newIndex=l,h.oldDraggableIndex=u,h.newDraggableIndex=d,h.originalEvent=f,h.pullMode=p?p.lastPutMode:void 0;var v=D(D({},m),et.getEventProperties(r,t));for(var y in v)h[y]=v[y];n&&n.dispatchEvent(h),g[_]&&g[_].call(t,h)}}var nt=[`evt`],V=function(e,t){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=n.evt,i=Ce(n,nt);et.pluginEvent.bind(Q)(e,t,D({dragEl:U,parentEl:W,ghostEl:G,rootEl:K,nextEl:rt,lastDownEl:it,cloneEl:q,cloneHidden:at,dragStarted:vt,putSortable:Y,activeSortable:Q.active,originalEvent:r,oldIndex:ot,oldDraggableIndex:st,newIndex:J,newDraggableIndex:ct,hideGhostForTarget:It,unhideGhostForTarget:Lt,cloneNowHidden:function(){at=!0},cloneNowShown:function(){at=!1},dispatchSortableEvent:function(e){H({sortable:t,name:e,originalEvent:r})}},i))};function H(e){tt(D({putSortable:Y,cloneEl:q,targetEl:U,rootEl:K,oldIndex:ot,oldDraggableIndex:st,newIndex:J,newDraggableIndex:ct},e))}var U,W,G,K,rt,it,q,at,ot,J,st,ct,lt,Y,ut=!1,dt=!1,ft=[],pt,X,mt,ht,gt,_t,vt,yt,bt,xt=!1,St=!1,Ct,Z,wt=[],Tt=!1,Et=[],Dt=typeof document<`u`,Ot=Oe,kt=Te||A?`cssFloat`:`float`,At=Dt&&!ke&&!Oe&&`draggable`in document.createElement(`div`),jt=function(){if(Dt){if(A)return!1;var e=document.createElement(`x`);return e.style.cssText=`pointer-events:auto`,e.style.pointerEvents===`auto`}}(),Mt=function(e,t){var n=F(e),r=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),i=Le(e,0,t),a=Le(e,1,t),o=i&&F(i),s=a&&F(a),c=o&&parseInt(o.marginLeft)+parseInt(o.marginRight)+L(i).width,l=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+L(a).width;if(n.display===`flex`)return n.flexDirection===`column`||n.flexDirection===`column-reverse`?`vertical`:`horizontal`;if(n.display===`grid`)return n.gridTemplateColumns.split(` `).length<=1?`vertical`:`horizontal`;if(i&&o.float&&o.float!==`none`){var u=o.float===`left`?`left`:`right`;return a&&(s.clear===`both`||s.clear===u)?`vertical`:`horizontal`}return i&&(o.display===`block`||o.display===`flex`||o.display===`table`||o.display===`grid`||c>=r&&n[kt]===`none`||a&&n[kt]===`none`&&c+l>r)?`vertical`:`horizontal`},Nt=function(e,t,n){var r=n?e.left:e.top,i=n?e.right:e.bottom,a=n?e.width:e.height,o=n?t.left:t.top,s=n?t.right:t.bottom,c=n?t.width:t.height;return r===o||i===s||r+a/2===o+c/2},Pt=function(e,t){var n;return ft.some(function(r){var i=r[B].options.emptyInsertThreshold;if(i&&!Re(r)){var a=L(r),o=e>=a.left-i&&e<=a.right+i,s=t>=a.top-i&&t<=a.bottom+i;if(o&&s)return n=r}}),n},Ft=function(e){function t(e,n){return function(r,i,a,o){var s=r.options.group.name&&i.options.group.name&&r.options.group.name===i.options.group.name;if(e==null&&(n||s))return!0;if(e==null||e===!1)return!1;if(n&&e===`clone`)return e;if(typeof e==`function`)return t(e(r,i,a,o),n)(r,i,a,o);var c=(n?r:i).options.group.name;return e===!0||typeof e==`string`&&e===c||e.join&&e.indexOf(c)>-1}}var n={},r=e.group;(!r||be(r)!=`object`)&&(r={name:r}),n.name=r.name,n.checkPull=t(r.pull,!0),n.checkPut=t(r.put),n.revertClone=r.revertClone,e.group=n},It=function(){!jt&&G&&F(G,`display`,`none`)},Lt=function(){!jt&&G&&F(G,`display`,``)};Dt&&!ke&&document.addEventListener(`click`,function(e){if(dt)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),dt=!1,!1},!0);var Rt=function(e){if(U){e=e.touches?e.touches[0]:e;var t=Pt(e.clientX,e.clientY);if(t){var n={};for(var r in e)e.hasOwnProperty(r)&&(n[r]=e[r]);n.target=n.rootEl=t,n.preventDefault=void 0,n.stopPropagation=void 0,t[B]._onDragOver(n)}}},zt=function(e){U&&U.parentNode[B]._isOutsideThisEl(e.target)};function Q(e,t){if(!(e&&e.nodeType&&e.nodeType===1))throw`Sortable: \`el\` must be an HTMLElement, not ${{}.toString.call(e)}`;this.el=e,this.options=t=O({},t),e[B]=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 Mt(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:Q.supportPointer!==!1&&`PointerEvent`in window&&!De,emptyInsertThreshold:5};for(var r in et.initializePlugins(this,e,n),n)!(r in t)&&(t[r]=n[r]);for(var i in Ft(t),this)i.charAt(0)===`_`&&typeof this[i]==`function`&&(this[i]=this[i].bind(this));this.nativeDraggable=!t.forceFallback&&At,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?j(e,`pointerdown`,this._onTapStart):(j(e,`mousedown`,this._onTapStart),j(e,`touchstart`,this._onTapStart)),this.nativeDraggable&&(j(e,`dragover`,this),j(e,`dragenter`,this)),ft.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),O(this,Ye())}Q.prototype={constructor:Q,_isOutsideThisEl:function(e){!this.el.contains(e)&&e!==this.el&&(yt=null)},_getDirection:function(e,t){return typeof this.options.direction==`function`?this.options.direction.call(this,e,t,U):this.options.direction},_onTapStart:function(e){if(e.cancelable){var t=this,n=this.el,r=this.options,i=r.preventOnFilter,a=e.type,o=e.touches&&e.touches[0]||e.pointerType&&e.pointerType===`touch`&&e,s=(o||e).target,c=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||s,l=r.filter;if(Yt(n),!U&&!(/mousedown|pointerdown/.test(a)&&e.button!==0||r.disabled)&&!c.isContentEditable&&!(!this.nativeDraggable&&De&&s&&s.tagName.toUpperCase()===`SELECT`)&&(s=N(s,r.draggable,n,!1),!(s&&s.animated)&&it!==s)){if(ot=R(s),st=R(s,r.draggable),typeof l==`function`){if(l.call(this,e,s,this)){H({sortable:t,rootEl:c,name:`filter`,targetEl:s,toEl:n,fromEl:n}),V(`filter`,t,{evt:e}),i&&e.cancelable&&e.preventDefault();return}}else if(l&&(l=l.split(`,`).some(function(r){if(r=N(c,r.trim(),n,!1),r)return H({sortable:t,rootEl:r,name:`filter`,targetEl:s,fromEl:n,toEl:n}),V(`filter`,t,{evt:e}),!0}),l)){i&&e.cancelable&&e.preventDefault();return}r.handle&&!N(c,r.handle,n,!1)||this._prepareDragStart(e,o,s)}}},_prepareDragStart:function(e,t,n){var r=this,i=r.el,a=r.options,o=i.ownerDocument,s;if(n&&!U&&n.parentNode===i){var c=L(n);if(K=i,U=n,W=U.parentNode,rt=U.nextSibling,it=n,lt=a.group,Q.dragged=U,pt={target:U,clientX:(t||e).clientX,clientY:(t||e).clientY},gt=pt.clientX-c.left,_t=pt.clientY-c.top,this._lastX=(t||e).clientX,this._lastY=(t||e).clientY,U.style[`will-change`]=`all`,s=function(){if(V(`delayEnded`,r,{evt:e}),Q.eventCanceled){r._onDrop();return}r._disableDelayedDragEvents(),!Ee&&r.nativeDraggable&&(U.draggable=!0),r._triggerDragStart(e,t),H({sortable:r,name:`choose`,originalEvent:e}),P(U,a.chosenClass,!0)},a.ignore.split(`,`).forEach(function(e){Fe(U,e.trim(),Ht)}),j(o,`dragover`,Rt),j(o,`mousemove`,Rt),j(o,`touchmove`,Rt),j(o,`mouseup`,r._onDrop),j(o,`touchend`,r._onDrop),j(o,`touchcancel`,r._onDrop),Ee&&this.nativeDraggable&&(this.options.touchStartThreshold=4,U.draggable=!0),V(`delayStart`,this,{evt:e}),a.delay&&(!a.delayOnTouchOnly||t)&&(!this.nativeDraggable||!(Te||A))){if(Q.eventCanceled){this._onDrop();return}j(o,`mouseup`,r._disableDelayedDrag),j(o,`touchend`,r._disableDelayedDrag),j(o,`touchcancel`,r._disableDelayedDrag),j(o,`mousemove`,r._delayedDragTouchMoveHandler),j(o,`touchmove`,r._delayedDragTouchMoveHandler),a.supportPointer&&j(o,`pointermove`,r._delayedDragTouchMoveHandler),r._dragStartTimer=setTimeout(s,a.delay)}else s()}},_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(){U&&Ht(U),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;M(e,`mouseup`,this._disableDelayedDrag),M(e,`touchend`,this._disableDelayedDrag),M(e,`touchcancel`,this._disableDelayedDrag),M(e,`mousemove`,this._delayedDragTouchMoveHandler),M(e,`touchmove`,this._delayedDragTouchMoveHandler),M(e,`pointermove`,this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,t){t||=e.pointerType==`touch`&&e,!this.nativeDraggable||t?this.options.supportPointer?j(document,`pointermove`,this._onTouchMove):t?j(document,`touchmove`,this._onTouchMove):j(document,`mousemove`,this._onTouchMove):(j(U,`dragend`,this),j(K,`dragstart`,this._onDragStart));try{document.selection?Xt(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(e,t){if(ut=!1,K&&U){V(`dragStarted`,this,{evt:t}),this.nativeDraggable&&j(document,`dragover`,zt);var n=this.options;!e&&P(U,n.dragClass,!1),P(U,n.ghostClass,!0),Q.active=this,e&&this._appendGhost(),H({sortable:this,name:`start`,originalEvent:t})}else this._nulling()},_emulateDragOver:function(){if(X){this._lastX=X.clientX,this._lastY=X.clientY,It();for(var e=document.elementFromPoint(X.clientX,X.clientY),t=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(X.clientX,X.clientY),e!==t);)t=e;if(U.parentNode[B]._isOutsideThisEl(e),t)do{if(t[B]){var n=void 0;if(n=t[B]._onDragOver({clientX:X.clientX,clientY:X.clientY,target:e,rootEl:t}),n&&!this.options.dragoverBubble)break}e=t}while(t=t.parentNode);Lt()}},_onTouchMove:function(e){if(pt){var t=this.options,n=t.fallbackTolerance,r=t.fallbackOffset,i=e.touches?e.touches[0]:e,a=G&&Pe(G,!0),o=G&&a&&a.a,s=G&&a&&a.d,c=Ot&&Z&&ze(Z),l=(i.clientX-pt.clientX+r.x)/(o||1)+(c?c[0]-wt[0]:0)/(o||1),u=(i.clientY-pt.clientY+r.y)/(s||1)+(c?c[1]-wt[1]:0)/(s||1);if(!Q.active&&!ut){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))<n)return;this._onDragStart(e,!0)}if(G){a?(a.e+=l-(mt||0),a.f+=u-(ht||0)):a={a:1,b:0,c:0,d:1,e:l,f:u};var d=`matrix(${a.a},${a.b},${a.c},${a.d},${a.e},${a.f})`;F(G,`webkitTransform`,d),F(G,`mozTransform`,d),F(G,`msTransform`,d),F(G,`transform`,d),mt=l,ht=u,X=i}e.cancelable&&e.preventDefault()}},_appendGhost:function(){if(!G){var e=this.options.fallbackOnBody?document.body:K,t=L(U,!0,Ot,!0,e),n=this.options;if(Ot){for(Z=e;F(Z,`position`)===`static`&&F(Z,`transform`)===`none`&&Z!==document;)Z=Z.parentNode;Z!==document.body&&Z!==document.documentElement?(Z===document&&(Z=I()),t.top+=Z.scrollTop,t.left+=Z.scrollLeft):Z=I(),wt=ze(Z)}G=U.cloneNode(!0),P(G,n.ghostClass,!1),P(G,n.fallbackClass,!0),P(G,n.dragClass,!0),F(G,`transition`,``),F(G,`transform`,``),F(G,`box-sizing`,`border-box`),F(G,`margin`,0),F(G,`top`,t.top),F(G,`left`,t.left),F(G,`width`,t.width),F(G,`height`,t.height),F(G,`opacity`,`0.8`),F(G,`position`,Ot?`absolute`:`fixed`),F(G,`zIndex`,`100000`),F(G,`pointerEvents`,`none`),Q.ghost=G,e.appendChild(G),F(G,`transform-origin`,gt/parseInt(G.style.width)*100+`% `+_t/parseInt(G.style.height)*100+`%`)}},_onDragStart:function(e,t){var n=this,r=e.dataTransfer,i=n.options;if(V(`dragStart`,this,{evt:e}),Q.eventCanceled){this._onDrop();return}V(`setupClone`,this),Q.eventCanceled||(q=qe(U),q.removeAttribute(`id`),q.draggable=!1,q.style[`will-change`]=``,this._hideClone(),P(q,this.options.chosenClass,!1),Q.clone=q),n.cloneId=Xt(function(){V(`clone`,n),!Q.eventCanceled&&(n.options.removeCloneOnHide||K.insertBefore(q,U),n._hideClone(),H({sortable:n,name:`clone`}))}),!t&&P(U,i.dragClass,!0),t?(dt=!0,n._loopId=setInterval(n._emulateDragOver,50)):(M(document,`mouseup`,n._onDrop),M(document,`touchend`,n._onDrop),M(document,`touchcancel`,n._onDrop),r&&(r.effectAllowed=`move`,i.setData&&i.setData.call(n,r,U)),j(document,`drop`,n),F(U,`transform`,`translateZ(0)`)),ut=!0,n._dragStartId=Xt(n._dragStarted.bind(n,t,e)),j(document,`selectstart`,n),vt=!0,De&&F(document.body,`user-select`,`none`)},_onDragOver:function(e){var t=this.el,n=e.target,r,i,a,o=this.options,s=o.group,c=Q.active,l=lt===s,u=o.sort,d=Y||c,f,p=this,m=!1;if(Tt)return;function h(o,s){V(o,p,D({evt:e,isOwner:l,axis:f?`vertical`:`horizontal`,revert:a,dragRect:r,targetRect:i,canSort:u,fromSortable:d,target:n,completed:_,onMove:function(n,i){return Vt(K,t,U,r,n,L(n),e,i)},changed:v},s))}function g(){h(`dragOverAnimationCapture`),p.captureAnimationState(),p!==d&&d.captureAnimationState()}function _(r){return h(`dragOverCompleted`,{insertion:r}),r&&(l?c._hideClone():c._showClone(p),p!==d&&(P(U,Y?Y.options.ghostClass:c.options.ghostClass,!1),P(U,o.ghostClass,!0)),Y!==p&&p!==Q.active?Y=p:p===Q.active&&Y&&(Y=null),d===p&&(p._ignoreWhileAnimating=n),p.animateAll(function(){h(`dragOverAnimationComplete`),p._ignoreWhileAnimating=null}),p!==d&&(d.animateAll(),d._ignoreWhileAnimating=null)),(n===U&&!U.animated||n===t&&!n.animated)&&(yt=null),!o.dragoverBubble&&!e.rootEl&&n!==document&&(U.parentNode[B]._isOutsideThisEl(e.target),!r&&Rt(e)),!o.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),m=!0}function v(){J=R(U),ct=R(U,o.draggable),H({sortable:p,name:`change`,toEl:t,newIndex:J,newDraggableIndex:ct,originalEvent:e})}if(e.preventDefault!==void 0&&e.cancelable&&e.preventDefault(),n=N(n,o.draggable,t,!0),h(`dragOver`),Q.eventCanceled)return m;if(U.contains(e.target)||n.animated&&n.animatingX&&n.animatingY||p._ignoreWhileAnimating===n)return _(!1);if(dt=!1,c&&!o.disabled&&(l?u||(a=W!==K):Y===this||(this.lastPutMode=lt.checkPull(this,c,U,e))&&s.checkPut(this,c,U,e))){if(f=this._getDirection(e,n)===`vertical`,r=L(U),h(`dragOverValid`),Q.eventCanceled)return m;if(a)return W=K,g(),this._hideClone(),h(`revert`),Q.eventCanceled||(rt?K.insertBefore(U,rt):K.appendChild(U)),_(!0);var y=Re(t,o.draggable);if(!y||Gt(e,f,this)&&!y.animated){if(y===U)return _(!1);if(y&&t===e.target&&(n=y),n&&(i=L(n)),Vt(K,t,U,r,n,i,e,!!n)!==!1)return g(),y&&y.nextSibling?t.insertBefore(U,y.nextSibling):t.appendChild(U),W=t,v(),_(!0)}else if(y&&Wt(e,f,this)){var ee=Le(t,0,o,!0);if(ee===U)return _(!1);if(n=ee,i=L(n),Vt(K,t,U,r,n,i,e,!1)!==!1)return g(),t.insertBefore(U,ee),W=t,v(),_(!0)}else if(n.parentNode===t){i=L(n);var b=0,x,te=U.parentNode!==t,S=!Nt(U.animated&&U.toRect||r,n.animated&&n.toRect||i,f),C=f?`top`:`left`,w=Ie(n,`top`,`top`)||Ie(U,`top`,`top`),ne=w?w.scrollTop:void 0;yt!==n&&(x=i[C],xt=!1,St=!S&&o.invertSwap||te),b=Kt(e,n,i,f,S?1:o.swapThreshold,o.invertedSwapThreshold==null?o.swapThreshold:o.invertedSwapThreshold,St,yt===n);var T;if(b!==0){var re=R(U);do re-=b,T=W.children[re];while(T&&(F(T,`display`)===`none`||T===G))}if(b===0||T===n)return _(!1);yt=n,bt=b;var E=n.nextElementSibling,ie=!1;ie=b===1;var ae=Vt(K,t,U,r,n,i,e,ie);if(ae!==!1)return(ae===1||ae===-1)&&(ie=ae===1),Tt=!0,setTimeout(Ut,30),g(),ie&&!E?t.appendChild(U):n.parentNode.insertBefore(U,ie?E:n),w&&Ke(w,0,ne-w.scrollTop),W=U.parentNode,x!==void 0&&!St&&(Ct=Math.abs(x-L(n)[C])),v(),_(!0)}if(t.contains(U))return _(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){M(document,`mousemove`,this._onTouchMove),M(document,`touchmove`,this._onTouchMove),M(document,`pointermove`,this._onTouchMove),M(document,`dragover`,Rt),M(document,`mousemove`,Rt),M(document,`touchmove`,Rt)},_offUpEvents:function(){var e=this.el.ownerDocument;M(e,`mouseup`,this._onDrop),M(e,`touchend`,this._onDrop),M(e,`pointerup`,this._onDrop),M(e,`touchcancel`,this._onDrop),M(document,`selectstart`,this)},_onDrop:function(e){var t=this.el,n=this.options;if(J=R(U),ct=R(U,n.draggable),V(`drop`,this,{evt:e}),W=U&&U.parentNode,J=R(U),ct=R(U,n.draggable),Q.eventCanceled){this._nulling();return}ut=!1,St=!1,xt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Zt(this.cloneId),Zt(this._dragStartId),this.nativeDraggable&&(M(document,`drop`,this),M(t,`dragstart`,this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),De&&F(document.body,`user-select`,``),F(U,`transform`,``),e&&(vt&&(e.cancelable&&e.preventDefault(),!n.dropBubble&&e.stopPropagation()),G&&G.parentNode&&G.parentNode.removeChild(G),(K===W||Y&&Y.lastPutMode!==`clone`)&&q&&q.parentNode&&q.parentNode.removeChild(q),U&&(this.nativeDraggable&&M(U,`dragend`,this),Ht(U),U.style[`will-change`]=``,vt&&!ut&&P(U,Y?Y.options.ghostClass:this.options.ghostClass,!1),P(U,this.options.chosenClass,!1),H({sortable:this,name:`unchoose`,toEl:W,newIndex:null,newDraggableIndex:null,originalEvent:e}),K===W?J!==ot&&J>=0&&(H({sortable:this,name:`update`,toEl:W,originalEvent:e}),H({sortable:this,name:`sort`,toEl:W,originalEvent:e})):(J>=0&&(H({rootEl:W,name:`add`,toEl:W,fromEl:K,originalEvent:e}),H({sortable:this,name:`remove`,toEl:W,originalEvent:e}),H({rootEl:W,name:`sort`,toEl:W,fromEl:K,originalEvent:e}),H({sortable:this,name:`sort`,toEl:W,originalEvent:e})),Y&&Y.save()),Q.active&&((J==null||J===-1)&&(J=ot,ct=st),H({sortable:this,name:`end`,toEl:W,originalEvent:e}),this.save()))),this._nulling()},_nulling:function(){V(`nulling`,this),K=U=W=G=rt=q=it=at=pt=X=vt=J=ct=ot=st=yt=bt=Y=lt=Q.dragged=Q.ghost=Q.clone=Q.active=null,Et.forEach(function(e){e.checked=!0}),Et.length=mt=ht=0},handleEvent:function(e){switch(e.type){case`drop`:case`dragend`:this._onDrop(e);break;case`dragenter`:case`dragover`:U&&(this._onDragOver(e),Bt(e));break;case`selectstart`:e.preventDefault()}},toArray:function(){for(var e=[],t,n=this.el.children,r=0,i=n.length,a=this.options;r<i;r++)t=n[r],N(t,a.draggable,this.el,!1)&&e.push(t.getAttribute(a.dataIdAttr)||Jt(t));return e},sort:function(e,t){var n={},r=this.el;this.toArray().forEach(function(e,t){var i=r.children[t];N(i,this.options.draggable,r,!1)&&(n[e]=i)},this),t&&this.captureAnimationState(),e.forEach(function(e){n[e]&&(r.removeChild(n[e]),r.appendChild(n[e]))}),t&&this.animateAll()},save:function(){var e=this.options.store;e&&e.set&&e.set(this)},closest:function(e,t){return N(e,t||this.options.draggable,this.el,!1)},option:function(e,t){var n=this.options;if(t===void 0)return n[e];var r=et.modifyOption(this,e,t);n[e]=r===void 0?t:r,e===`group`&&Ft(n)},destroy:function(){V(`destroy`,this);var e=this.el;e[B]=null,M(e,`mousedown`,this._onTapStart),M(e,`touchstart`,this._onTapStart),M(e,`pointerdown`,this._onTapStart),this.nativeDraggable&&(M(e,`dragover`,this),M(e,`dragenter`,this)),Array.prototype.forEach.call(e.querySelectorAll(`[draggable]`),function(e){e.removeAttribute(`draggable`)}),this._onDrop(),this._disableDelayedDragEvents(),ft.splice(ft.indexOf(this.el),1),this.el=e=null},_hideClone:function(){if(!at){if(V(`hideClone`,this),Q.eventCanceled)return;F(q,`display`,`none`),this.options.removeCloneOnHide&&q.parentNode&&q.parentNode.removeChild(q),at=!0}},_showClone:function(e){if(e.lastPutMode!==`clone`){this._hideClone();return}if(at){if(V(`showClone`,this),Q.eventCanceled)return;U.parentNode==K&&!this.options.group.revertClone?K.insertBefore(q,U):rt?K.insertBefore(q,rt):K.appendChild(q),this.options.group.revertClone&&this.animate(U,q),F(q,`display`,``),at=!1}}};function Bt(e){e.dataTransfer&&(e.dataTransfer.dropEffect=`move`),e.cancelable&&e.preventDefault()}function Vt(e,t,n,r,i,a,o,s){var c,l=e[B],u=l.options.onMove,d;return window.CustomEvent&&!A&&!Te?c=new CustomEvent(`move`,{bubbles:!0,cancelable:!0}):(c=document.createEvent(`Event`),c.initEvent(`move`,!0,!0)),c.to=t,c.from=e,c.dragged=n,c.draggedRect=r,c.related=i||t,c.relatedRect=a||L(t),c.willInsertAfter=s,c.originalEvent=o,e.dispatchEvent(c),u&&(d=u.call(l,c,o)),d}function Ht(e){e.draggable=!1}function Ut(){Tt=!1}function Wt(e,t,n){var r=L(Le(n.el,0,n.options,!0)),i=Je(n.el,n.options,G),a=10;return t?e.clientX<i.left-a||e.clientY<r.top&&e.clientX<r.right:e.clientY<i.top-a||e.clientY<r.bottom&&e.clientX<r.left}function Gt(e,t,n){var r=L(Re(n.el,n.options.draggable)),i=Je(n.el,n.options,G),a=10;return t?e.clientX>i.right+a||e.clientY>r.bottom&&e.clientX>r.left:e.clientY>i.bottom+a||e.clientX>r.right&&e.clientY>r.top}function Kt(e,t,n,r,i,a,o,s){var c=r?e.clientY:e.clientX,l=r?n.height:n.width,u=r?n.top:n.left,d=r?n.bottom:n.right,f=!1;if(!o){if(s&&Ct<l*i){if(!xt&&(bt===1?c>u+l*a/2:c<d-l*a/2)&&(xt=!0),xt)f=!0;else if(bt===1?c<u+Ct:c>d-Ct)return-bt}else if(c>u+l*(1-i)/2&&c<d-l*(1-i)/2)return qt(t)}return f||=o,f&&(c<u+l*a/2||c>d-l*a/2)?c>u+l/2?1:-1:0}function qt(e){return R(U)<R(e)?1:-1}function Jt(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,n=t.length,r=0;n--;)r+=t.charCodeAt(n);return r.toString(36)}function Yt(e){Et.length=0;for(var t=e.getElementsByTagName(`input`),n=t.length;n--;){var r=t[n];r.checked&&Et.push(r)}}function Xt(e){return setTimeout(e,0)}function Zt(e){return clearTimeout(e)}Dt&&j(document,`touchmove`,function(e){(Q.active||ut)&&e.cancelable&&e.preventDefault()}),Q.utils={on:j,off:M,css:F,find:Fe,is:function(e,t){return!!N(e,t,e,!1)},extend:Ve,throttle:We,closest:N,toggleClass:P,clone:qe,index:R,nextTick:Xt,cancelNextTick:Zt,detectDirection:Mt,getChild:Le},Q.get=function(e){return e[B]},Q.mount=function(){var e=[...arguments];e[0].constructor===Array&&(e=e[0]),e.forEach(function(e){if(!e.prototype||!e.prototype.constructor)throw`Sortable: Mounted plugin must be a constructor function, not ${{}.toString.call(e)}`;e.utils&&(Q.utils=D(D({},Q.utils),e.utils)),et.mount(e)})},Q.create=function(e,t){return new Q(e,t)},Q.version=we;var $=[],Qt,$t,en=!1,tn,nn,rn,an;function on(){function e(){for(var e in this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)e.charAt(0)===`_`&&typeof this[e]==`function`&&(this[e]=this[e].bind(this))}return e.prototype={dragStarted:function(e){var t=e.originalEvent;this.sortable.nativeDraggable?j(document,`dragover`,this._handleAutoScroll):this.options.supportPointer?j(document,`pointermove`,this._handleFallbackAutoScroll):t.touches?j(document,`touchmove`,this._handleFallbackAutoScroll):j(document,`mousemove`,this._handleFallbackAutoScroll)},dragOverCompleted:function(e){var t=e.originalEvent;!this.options.dragOverBubble&&!t.rootEl&&this._handleAutoScroll(t)},drop:function(){this.sortable.nativeDraggable?M(document,`dragover`,this._handleAutoScroll):(M(document,`pointermove`,this._handleFallbackAutoScroll),M(document,`touchmove`,this._handleFallbackAutoScroll),M(document,`mousemove`,this._handleFallbackAutoScroll)),cn(),sn(),Ge()},nulling:function(){rn=$t=Qt=en=an=tn=nn=null,$.length=0},_handleFallbackAutoScroll:function(e){this._handleAutoScroll(e,!0)},_handleAutoScroll:function(e,t){var n=this,r=(e.touches?e.touches[0]:e).clientX,i=(e.touches?e.touches[0]:e).clientY,a=document.elementFromPoint(r,i);if(rn=e,t||this.options.forceAutoScrollFallback||Te||A||De){ln(e,this.options,a,t);var o=z(a,!0);en&&(!an||r!==tn||i!==nn)&&(an&&cn(),an=setInterval(function(){var a=z(document.elementFromPoint(r,i),!0);a!==o&&(o=a,sn()),ln(e,n.options,a,t)},10),tn=r,nn=i)}else{if(!this.options.bubbleScroll||z(a,!0)===I()){sn();return}ln(e,this.options,z(a,!1),!1)}}},O(e,{pluginName:`scroll`,initializeByDefault:!0})}function sn(){$.forEach(function(e){clearInterval(e.pid)}),$=[]}function cn(){clearInterval(an)}var ln=We(function(e,t,n,r){if(t.scroll){var i=(e.touches?e.touches[0]:e).clientX,a=(e.touches?e.touches[0]:e).clientY,o=t.scrollSensitivity,s=t.scrollSpeed,c=I(),l=!1,u;$t!==n&&($t=n,sn(),Qt=t.scroll,u=t.scrollFn,Qt===!0&&(Qt=z(n,!0)));var d=0,f=Qt;do{var p=f,m=L(p),h=m.top,g=m.bottom,_=m.left,v=m.right,y=m.width,ee=m.height,b=void 0,x=void 0,te=p.scrollWidth,S=p.scrollHeight,C=F(p),w=p.scrollLeft,ne=p.scrollTop;p===c?(b=y<te&&(C.overflowX===`auto`||C.overflowX===`scroll`||C.overflowX===`visible`),x=ee<S&&(C.overflowY===`auto`||C.overflowY===`scroll`||C.overflowY===`visible`)):(b=y<te&&(C.overflowX===`auto`||C.overflowX===`scroll`),x=ee<S&&(C.overflowY===`auto`||C.overflowY===`scroll`));var T=b&&(Math.abs(v-i)<=o&&w+y<te)-(Math.abs(_-i)<=o&&!!w),re=x&&(Math.abs(g-a)<=o&&ne+ee<S)-(Math.abs(h-a)<=o&&!!ne);if(!$[d])for(var E=0;E<=d;E++)$[E]||($[E]={});($[d].vx!=T||$[d].vy!=re||$[d].el!==p)&&($[d].el=p,$[d].vx=T,$[d].vy=re,clearInterval($[d].pid),(T!=0||re!=0)&&(l=!0,$[d].pid=setInterval(function(){r&&this.layer===0&&Q.active._onTouchMove(rn);var t=$[this.layer].vy?$[this.layer].vy*s:0,n=$[this.layer].vx?$[this.layer].vx*s:0;typeof u==`function`&&u.call(Q.dragged.parentNode[B],n,t,e,rn,$[this.layer].el)!==`continue`||Ke($[this.layer].el,n,t)}.bind({layer:d}),24))),d++}while(t.bubbleScroll&&f!==c&&(f=z(f,!1)));en=l}},30),un=function(e){var t=e.originalEvent,n=e.putSortable,r=e.dragEl,i=e.activeSortable,a=e.dispatchSortableEvent,o=e.hideGhostForTarget,s=e.unhideGhostForTarget;if(t){var c=n||i;o();var l=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:t,u=document.elementFromPoint(l.clientX,l.clientY);s(),c&&!c.el.contains(u)&&(a(`spill`),this.onSpill({dragEl:r,putSortable:n}))}};function dn(){}dn.prototype={startIndex:null,dragStart:function(e){var t=e.oldDraggableIndex;this.startIndex=t},onSpill:function(e){var t=e.dragEl,n=e.putSortable;this.sortable.captureAnimationState(),n&&n.captureAnimationState();var r=Le(this.sortable.el,this.startIndex,this.options);r?this.sortable.el.insertBefore(t,r):this.sortable.el.appendChild(t),this.sortable.animateAll(),n&&n.animateAll()},drop:un},O(dn,{pluginName:`revertOnSpill`});function fn(){}fn.prototype={onSpill:function(e){var t=e.dragEl,n=e.putSortable||this.sortable;n.captureAnimationState(),t.parentNode&&t.parentNode.removeChild(t),n.animateAll()},drop:un},O(fn,{pluginName:`removeOnSpill`}),Q.mount(new on),Q.mount(fn,dn);function pn(e){return e==null?e:JSON.parse(JSON.stringify(e))}function mn(e){n()&&o(e)}function hn(e){n()?a(e):u(e)}var gn=null,_n=null;function vn(e=null,t=null){gn=e,_n=t}function yn(){return{data:gn,clonedData:_n}}var bn=Symbol(`cloneElement`);function xn(...e){let i=n()?.proxy,a=null,o=e[0],[,s,c]=e;Array.isArray(r(s))||(c=s,s=null);let l=null,{immediate:f=!0,clone:p=pn,forceFallback:m,fallbackOnBody:h,customUpdate:g}=r(c)??{};function _(e){let{from:t,oldIndex:n,item:i}=e,o=Array.from(t.childNodes);a=m&&!h?o.slice(0,-1):o;let c=r(r(s)?.[n]),l=p(c);vn(c,l),i[bn]=l}function v(e){let t=e.item[bn];if(!ce(t)){if(de(e.item),d(s)){let n=[...r(s)];s.value=se(n,e.newDraggableIndex,t);return}se(r(s),e.newDraggableIndex,t)}}function y(e){let{from:t,item:n,oldIndex:i,oldDraggableIndex:a,pullMode:o,clone:c}=e;if(ue(t,n,i),o===`clone`){de(c);return}if(d(s)){let e=[...r(s)];s.value=oe(e,a);return}oe(r(s),a)}function ee(e){if(g){g(e);return}let{from:t,item:n,oldIndex:i,oldDraggableIndex:a,newDraggableIndex:o}=e;if(de(n),ue(t,n,i),d(s)){let e=[...r(s)];s.value=E(e,a,o);return}E(r(s),a,o)}function b(e){let{newIndex:t,oldIndex:n,from:r,to:i}=e,o=null,s=t===n&&r===i;try{if(s){let e=null;a?.some((t,n)=>{if(e&&a?.length!==i.childNodes.length)return r.insertBefore(e,t.nextSibling),!0;let o=i.childNodes[n];e=i?.replaceChild(t,o)})}}catch(e){o=e}finally{a=null}u(()=>{if(vn(),o)throw o})}let x={onUpdate:ee,onStart:_,onAdd:v,onRemove:y,onEnd:b};function te(e){let t=r(o);return e||=le(t)?fe(t,i?.$el):t,e&&!he(e)&&(e=e.$el),e||re(`Root element not found`),e}function S(){let e=r(c)??{},{immediate:t,clone:n}=e,i=w(e,[`immediate`,`clone`]);return ge(i,(e,t)=>{_e(e)&&(i[e]=(e,...n)=>(ve(e,yn()),t(e,...n)))}),me(s===null?{}:x,i)}let ne=e=>{e=te(e),l&&T.destroy(),l=new Q(e,S())};t(()=>c,()=>{l&&ge(S(),(e,t)=>{l?.option(e,t)})},{deep:!0});let T={option:(e,t)=>l?.option(e,t),destroy:()=>{l?.destroy(),l=null},save:()=>l?.save(),toArray:()=>l?.toArray(),closest:(...e)=>l?.closest(...e)};return hn(()=>{f&&ne()}),mn(T.destroy),C({start:ne,pause:()=>T?.option(`disabled`,!0),resume:()=>T?.option(`disabled`,!1)},T)}var Sn=[`update`,`start`,`add`,`remove`,`choose`,`unchoose`,`end`,`sort`,`filter`,`clone`,`move`,`change`],Cn=[`clone`,`animation`,`ghostClass`,`group`,`sort`,`disabled`,`store`,`handle`,`draggable`,`swapThreshold`,`invertSwap`,`invertedSwapThreshold`,`removeCloneOnHide`,`direction`,`chosenClass`,`dragClass`,`ignore`,`filter`,`preventOnFilter`,`easing`,`setData`,`dropBubble`,`dragoverBubble`,`dataIdAttr`,`delay`,`delayOnTouchOnly`,`touchStartThreshold`,`forceFallback`,`fallbackClass`,`fallbackOnBody`,`fallbackTolerance`,`fallbackOffset`,`supportPointer`,`emptyInsertThreshold`,`scroll`,`forceAutoScrollFallback`,`scrollSensitivity`,`scrollSpeed`,`bubbleScroll`,`modelValue`,`tag`,`target`,`customUpdate`,...Sn.map(e=>`on${e.replace(/^\S/,e=>e.toUpperCase())}`)],wn=l({name:`VueDraggable`,model:{prop:`modelValue`,event:`update:modelValue`},props:Cn,emits:[`update:modelValue`,...Sn],setup(t,{slots:n,emit:a,expose:o,attrs:l}){let u=Sn.reduce((e,t)=>{let n=`on${t.replace(/^\S/,e=>e.toUpperCase())}`;return e[n]=(...e)=>a(t,...e),e},{}),d=s(()=>{let e=i(t),{modelValue:n}=e,a=w(e,[`modelValue`]),o=Object.entries(a).reduce((e,[t,n])=>{let i=r(n);return i!==void 0&&(e[t]=i),e},{});return C(C({},u),ae(C(C({},l),o)))}),p=s({get:()=>t.modelValue,set:e=>a(`update:modelValue`,e)}),m=f(),h=c(xn(t.target||m,p,d));return o(h),()=>e(t.tag||`div`,{ref:m},(n?.default)?.call(n,h))}}),Tn={mounted:`mounted`,unmounted:`unmounted`};Tn.mounted,Tn.unmounted;export{g as a,_ as i,y as n,h as o,v as r,m as s,wn as t}; |