@ianicdev/datatables2 0.10.8 → 0.11.0

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.
Files changed (53) hide show
  1. package/dist/{Comparison-ClrNRg-V.js → Comparison-C2hZMBq4.js} +3 -3
  2. package/dist/{Comparison-DCWQz5X9.cjs → Comparison-tLPSEm-Q.cjs} +1 -1
  3. package/dist/Datepicker-BA4mQx6C.cjs +2 -0
  4. package/dist/{Datepicker-Du8AggGn.js → Datepicker-BO2Ixl4r.js} +463 -459
  5. package/dist/Options-C7EAVB8f.cjs +1 -0
  6. package/dist/Options-DrhE_fto.js +108 -0
  7. package/dist/RefreshTable-BNy_MWZg.js +21 -0
  8. package/dist/RefreshTable-C-AgoC97.cjs +1 -0
  9. package/dist/{Search-BHVyo0uz.js → Search-CdHQz2KW.js} +8 -8
  10. package/dist/{Search-CVhqyw6f.cjs → Search-D_zU2pXl.cjs} +1 -1
  11. package/dist/{Table-C2P9cYl_.cjs → Table-B2iOe4P0.cjs} +1 -1
  12. package/dist/{Table-DoG07zNZ.js → Table-DHHVRPoA.js} +3 -3
  13. package/dist/{TableServer-BDcY2nQz.js → TableServer-D4Q_9dET.js} +3 -3
  14. package/dist/{TableServer-CeJMxSCa.cjs → TableServer-k8aRa4f5.cjs} +1 -1
  15. package/dist/{cellRender-DZ5qL5RV.cjs → cellRender-DuBdvYbh.cjs} +1 -1
  16. package/dist/{cellRender-BRFdMQzg.js → cellRender-LGC_k50e.js} +57 -57
  17. package/dist/dataTables-DV00l1p8.cjs +4 -0
  18. package/dist/{dataTables-DRiNyKEv.js → dataTables-j8j4naMl.js} +380 -374
  19. package/dist/datatables.cjs +1 -1
  20. package/dist/datatables.js +1 -1
  21. package/dist/datatables2.css +1 -1
  22. package/dist/{index-DqBI0sCe.js → index-BU9rb0Q-.js} +2 -2
  23. package/dist/index-BjbhnehN.js +4477 -0
  24. package/dist/index-CEe--P_C.cjs +1 -0
  25. package/dist/{index-DD_T-n8-.cjs → index-CU-Eak9-.cjs} +1 -1
  26. package/dist/index-CXUreMkK.cjs +1 -0
  27. package/dist/index-DzyBRRkM.js +30 -0
  28. package/dist/index-_cYryjRU.cjs +1 -0
  29. package/dist/index-zhSEiNN0.js +61 -0
  30. package/dist/{index.es-BtDW7HTQ.cjs → index.es-BCJd8pS0.cjs} +1 -1
  31. package/dist/{index.es-Bv6Mb9BC.js → index.es-CtLP1GTc.js} +1 -1
  32. package/dist/{jspdf-D9i2dan7.js → jspdf-3qJBK9tP.js} +6 -6
  33. package/dist/{jspdf-BsORS480.cjs → jspdf-DyYqWhF9.cjs} +4 -4
  34. package/dist/useColumns-CCJ04VF-.cjs +1 -0
  35. package/dist/useColumns-Dfrb9p8A.js +1473 -0
  36. package/dist/useDownload-CL90ZIqP.cjs +1 -0
  37. package/dist/{Download-CIp1YVEq.js → useDownload-DgATsbOV.js} +105 -132
  38. package/dist/useRefreshTable-BhEgI00Z.cjs +1 -0
  39. package/dist/useRefreshTable-Cf0gpIuT.js +18 -0
  40. package/package.json +16 -16
  41. package/dist/Columns-Dd9SfqmJ.cjs +0 -1
  42. package/dist/Columns-QO7YU0eZ.js +0 -28
  43. package/dist/Datepicker-BHbZnWHu.cjs +0 -2
  44. package/dist/Download-B2JKkFCz.cjs +0 -1
  45. package/dist/Options-BPCUGErN.js +0 -82
  46. package/dist/Options-DiRnomZy.cjs +0 -1
  47. package/dist/RefreshTable-B13C6sLc.js +0 -26
  48. package/dist/RefreshTable-CwHf3COZ.cjs +0 -1
  49. package/dist/dataTables-CmM1RF0K.cjs +0 -4
  50. package/dist/escapeKeyString-CngwDxKW.js +0 -17
  51. package/dist/escapeKeyString-nS7kXLwu.cjs +0 -1
  52. package/dist/index-Bz4Guf4c.cjs +0 -1
  53. package/dist/index-D9tMlHlC.js +0 -5891
@@ -0,0 +1 @@
1
+ "use strict";const h=require("vue"),Ne=require("@vueuse/core"),N=require("./index-CEe--P_C.cjs"),V=require("./dataTables-DV00l1p8.cjs"),Rt=require("vue-i18n"),Bt=V.propsFactory({...V.omit(N.makeVInputProps(),["direction"]),...V.omit(N.makeVCheckboxBtnProps(),["inline"])},"VCheckbox"),Xt=V.genericComponent()({name:"VCheckbox",inheritAttrs:!1,props:Bt(),emits:{"update:modelValue":n=>!0,"update:focused":n=>!0},setup(n,e){let{attrs:o,slots:t}=e;const i=V.useProxiedModel(n,"modelValue"),{isFocused:r,focus:a,blur:l}=N.useFocus(n),s=h.ref(),u=h.useId();return V.useRender(()=>{const[d,f]=V.filterInputAttrs(o),y=N.VInput.filterProps(n),_=N.VCheckboxBtn.filterProps(n);return h.createVNode(N.VInput,h.mergeProps({ref:s,class:["v-checkbox",n.class]},d,y,{modelValue:i.value,"onUpdate:modelValue":v=>i.value=v,id:n.id||`checkbox-${u}`,focused:r.value,style:n.style}),{...t,default:v=>{let{id:b,messagesId:S,isDisabled:O,isReadonly:P,isValid:M}=v;return h.createVNode(N.VCheckboxBtn,h.mergeProps(_,{id:b.value,"aria-describedby":S.value,disabled:O.value,readonly:P.value},f,{error:M.value===!1,modelValue:i.value,"onUpdate:modelValue":F=>i.value=F,onFocus:a,onBlur:l}),t)}})}),V.forwardRefs({},s)}});function ft(n,e){var o=Object.keys(n);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(n);e&&(t=t.filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable})),o.push.apply(o,t)}return o}function q(n){for(var e=1;e<arguments.length;e++){var o=arguments[e]!=null?arguments[e]:{};e%2?ft(Object(o),!0).forEach(function(t){Yt(n,t,o[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):ft(Object(o)).forEach(function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(o,t))})}return n}function Re(n){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Re=function(e){return typeof e}:Re=function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Re(n)}function Yt(n,e,o){return e in n?Object.defineProperty(n,e,{value:o,enumerable:!0,configurable:!0,writable:!0}):n[e]=o,n}function Z(){return Z=Object.assign||function(n){for(var e=1;e<arguments.length;e++){var o=arguments[e];for(var t in o)Object.prototype.hasOwnProperty.call(o,t)&&(n[t]=o[t])}return n},Z.apply(this,arguments)}function Lt(n,e){if(n==null)return{};var o={},t=Object.keys(n),i,r;for(r=0;r<t.length;r++)i=t[r],!(e.indexOf(i)>=0)&&(o[i]=n[i]);return o}function Ht(n,e){if(n==null)return{};var o=Lt(n,e),t,i;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);for(i=0;i<r.length;i++)t=r[i],!(e.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}var $t="1.15.6";function K(n){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(n)}var Q=K(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),Oe=K(/Edge/i),ht=K(/firefox/i),Se=K(/safari/i)&&!K(/chrome/i)&&!K(/android/i),lt=K(/iP(ad|od|hone)/i),Et=K(/chrome/i)&&K(/android/i),_t={capture:!1,passive:!1};function E(n,e,o){n.addEventListener(e,o,!Q&&_t)}function w(n,e,o){n.removeEventListener(e,o,!Q&&_t)}function He(n,e){if(e){if(e[0]===">"&&(e=e.substring(1)),n)try{if(n.matches)return n.matches(e);if(n.msMatchesSelector)return n.msMatchesSelector(e);if(n.webkitMatchesSelector)return n.webkitMatchesSelector(e)}catch{return!1}return!1}}function Dt(n){return n.host&&n!==document&&n.host.nodeType?n.host:n.parentNode}function j(n,e,o,t){if(n){o=o||document;do{if(e!=null&&(e[0]===">"?n.parentNode===o&&He(n,e):He(n,e))||t&&n===o)return n;if(n===o)break}while(n=Dt(n))}return null}var pt=/\s+/g;function L(n,e,o){if(n&&e)if(n.classList)n.classList[o?"add":"remove"](e);else{var t=(" "+n.className+" ").replace(pt," ").replace(" "+e+" "," ");n.className=(t+(o?" "+e:"")).replace(pt," ")}}function p(n,e,o){var t=n&&n.style;if(t){if(o===void 0)return document.defaultView&&document.defaultView.getComputedStyle?o=document.defaultView.getComputedStyle(n,""):n.currentStyle&&(o=n.currentStyle),e===void 0?o:o[e];!(e in t)&&e.indexOf("webkit")===-1&&(e="-webkit-"+e),t[e]=o+(typeof o=="string"?"":"px")}}function pe(n,e){var o="";if(typeof n=="string")o=n;else do{var t=p(n,"transform");t&&t!=="none"&&(o=t+" "+o)}while(!e&&(n=n.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(o)}function St(n,e,o){if(n){var t=n.getElementsByTagName(e),i=0,r=t.length;if(o)for(;i<r;i++)o(t[i],i);return t}return[]}function z(){var n=document.scrollingElement;return n||document.documentElement}function x(n,e,o,t,i){if(!(!n.getBoundingClientRect&&n!==window)){var r,a,l,s,u,d,f;if(n!==window&&n.parentNode&&n!==z()?(r=n.getBoundingClientRect(),a=r.top,l=r.left,s=r.bottom,u=r.right,d=r.height,f=r.width):(a=0,l=0,s=window.innerHeight,u=window.innerWidth,d=window.innerHeight,f=window.innerWidth),(e||o)&&n!==window&&(i=i||n.parentNode,!Q))do if(i&&i.getBoundingClientRect&&(p(i,"transform")!=="none"||o&&p(i,"position")!=="static")){var y=i.getBoundingClientRect();a-=y.top+parseInt(p(i,"border-top-width")),l-=y.left+parseInt(p(i,"border-left-width")),s=a+r.height,u=l+r.width;break}while(i=i.parentNode);if(t&&n!==window){var _=pe(i||n),v=_&&_.a,b=_&&_.d;_&&(a/=b,l/=v,f/=v,d/=b,s=a+d,u=l+f)}return{top:a,left:l,bottom:s,right:u,width:f,height:d}}}function gt(n,e,o){for(var t=oe(n,!0),i=x(n)[e];t;){var r=x(t)[o],a=void 0;if(a=i>=r,!a)return t;if(t===z())break;t=oe(t,!1)}return!1}function ge(n,e,o,t){for(var i=0,r=0,a=n.children;r<a.length;){if(a[r].style.display!=="none"&&a[r]!==g.ghost&&(t||a[r]!==g.dragged)&&j(a[r],o.draggable,n,!1)){if(i===e)return a[r];i++}r++}return null}function st(n,e){for(var o=n.lastElementChild;o&&(o===g.ghost||p(o,"display")==="none"||e&&!He(o,e));)o=o.previousElementSibling;return o||null}function $(n,e){var o=0;if(!n||!n.parentNode)return-1;for(;n=n.previousElementSibling;)n.nodeName.toUpperCase()!=="TEMPLATE"&&n!==g.clone&&(!e||He(n,e))&&o++;return o}function mt(n){var e=0,o=0,t=z();if(n)do{var i=pe(n),r=i.a,a=i.d;e+=n.scrollLeft*r,o+=n.scrollTop*a}while(n!==t&&(n=n.parentNode));return[e,o]}function Wt(n,e){for(var o in n)if(n.hasOwnProperty(o)){for(var t in e)if(e.hasOwnProperty(t)&&e[t]===n[o][t])return Number(o)}return-1}function oe(n,e){if(!n||!n.getBoundingClientRect)return z();var o=n,t=!1;do if(o.clientWidth<o.scrollWidth||o.clientHeight<o.scrollHeight){var i=p(o);if(o.clientWidth<o.scrollWidth&&(i.overflowX=="auto"||i.overflowX=="scroll")||o.clientHeight<o.scrollHeight&&(i.overflowY=="auto"||i.overflowY=="scroll")){if(!o.getBoundingClientRect||o===document.body)return z();if(t||e)return o;t=!0}}while(o=o.parentNode);return z()}function jt(n,e){if(n&&e)for(var o in e)e.hasOwnProperty(o)&&(n[o]=e[o]);return n}function qe(n,e){return Math.round(n.top)===Math.round(e.top)&&Math.round(n.left)===Math.round(e.left)&&Math.round(n.height)===Math.round(e.height)&&Math.round(n.width)===Math.round(e.width)}var Ce;function Ct(n,e){return function(){if(!Ce){var o=arguments,t=this;o.length===1?n.call(t,o[0]):n.apply(t,o),Ce=setTimeout(function(){Ce=void 0},e)}}}function Gt(){clearTimeout(Ce),Ce=void 0}function Tt(n,e,o){n.scrollLeft+=e,n.scrollTop+=o}function It(n){var e=window.Polymer,o=window.jQuery||window.Zepto;return e&&e.dom?e.dom(n).cloneNode(!0):o?o(n).clone(!0)[0]:n.cloneNode(!0)}function xt(n,e,o){var t={};return Array.from(n.children).forEach(function(i){var r,a,l,s;if(!(!j(i,e.draggable,n,!1)||i.animated||i===o)){var u=x(i);t.left=Math.min((r=t.left)!==null&&r!==void 0?r:1/0,u.left),t.top=Math.min((a=t.top)!==null&&a!==void 0?a:1/0,u.top),t.right=Math.max((l=t.right)!==null&&l!==void 0?l:-1/0,u.right),t.bottom=Math.max((s=t.bottom)!==null&&s!==void 0?s:-1/0,u.bottom)}}),t.width=t.right-t.left,t.height=t.bottom-t.top,t.x=t.left,t.y=t.top,t}var X="Sortable"+new Date().getTime();function zt(){var n=[],e;return{captureAnimationState:function(){if(n=[],!!this.options.animation){var t=[].slice.call(this.el.children);t.forEach(function(i){if(!(p(i,"display")==="none"||i===g.ghost)){n.push({target:i,rect:x(i)});var r=q({},n[n.length-1].rect);if(i.thisAnimationDuration){var a=pe(i,!0);a&&(r.top-=a.f,r.left-=a.e)}i.fromRect=r}})}},addAnimationState:function(t){n.push(t)},removeAnimationState:function(t){n.splice(Wt(n,{target:t}),1)},animateAll:function(t){var i=this;if(!this.options.animation){clearTimeout(e),typeof t=="function"&&t();return}var r=!1,a=0;n.forEach(function(l){var s=0,u=l.target,d=u.fromRect,f=x(u),y=u.prevFromRect,_=u.prevToRect,v=l.rect,b=pe(u,!0);b&&(f.top-=b.f,f.left-=b.e),u.toRect=f,u.thisAnimationDuration&&qe(y,f)&&!qe(d,f)&&(v.top-f.top)/(v.left-f.left)===(d.top-f.top)/(d.left-f.left)&&(s=Ut(v,y,_,i.options)),qe(f,d)||(u.prevFromRect=d,u.prevToRect=f,s||(s=i.options.animation),i.animate(u,v,f,s)),s&&(r=!0,a=Math.max(a,s),clearTimeout(u.animationResetTimer),u.animationResetTimer=setTimeout(function(){u.animationTime=0,u.prevFromRect=null,u.fromRect=null,u.prevToRect=null,u.thisAnimationDuration=null},s),u.thisAnimationDuration=s)}),clearTimeout(e),r?e=setTimeout(function(){typeof t=="function"&&t()},a):typeof t=="function"&&t(),n=[]},animate:function(t,i,r,a){if(a){p(t,"transition",""),p(t,"transform","");var l=pe(this.el),s=l&&l.a,u=l&&l.d,d=(i.left-r.left)/(s||1),f=(i.top-r.top)/(u||1);t.animatingX=!!d,t.animatingY=!!f,p(t,"transform","translate3d("+d+"px,"+f+"px,0)"),this.forRepaintDummy=qt(t),p(t,"transition","transform "+a+"ms"+(this.options.easing?" "+this.options.easing:"")),p(t,"transform","translate3d(0,0,0)"),typeof t.animated=="number"&&clearTimeout(t.animated),t.animated=setTimeout(function(){p(t,"transition",""),p(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1},a)}}}}function qt(n){return n.offsetWidth}function Ut(n,e,o,t){return Math.sqrt(Math.pow(e.top-n.top,2)+Math.pow(e.left-n.left,2))/Math.sqrt(Math.pow(e.top-o.top,2)+Math.pow(e.left-o.left,2))*t.animation}var ce=[],Ue={initializeByDefault:!0},Pe={mount:function(e){for(var o in Ue)Ue.hasOwnProperty(o)&&!(o in e)&&(e[o]=Ue[o]);ce.forEach(function(t){if(t.pluginName===e.pluginName)throw"Sortable: Cannot mount plugin ".concat(e.pluginName," more than once")}),ce.push(e)},pluginEvent:function(e,o,t){var i=this;this.eventCanceled=!1,t.cancel=function(){i.eventCanceled=!0};var r=e+"Global";ce.forEach(function(a){o[a.pluginName]&&(o[a.pluginName][r]&&o[a.pluginName][r](q({sortable:o},t)),o.options[a.pluginName]&&o[a.pluginName][e]&&o[a.pluginName][e](q({sortable:o},t)))})},initializePlugins:function(e,o,t,i){ce.forEach(function(l){var s=l.pluginName;if(!(!e.options[s]&&!l.initializeByDefault)){var u=new l(e,o,e.options);u.sortable=e,u.options=e.options,e[s]=u,Z(t,u.defaults)}});for(var r in e.options)if(e.options.hasOwnProperty(r)){var a=this.modifyOption(e,r,e.options[r]);typeof a<"u"&&(e.options[r]=a)}},getEventProperties:function(e,o){var t={};return ce.forEach(function(i){typeof i.eventProperties=="function"&&Z(t,i.eventProperties.call(o[i.pluginName],e))}),t},modifyOption:function(e,o,t){var i;return ce.forEach(function(r){e[r.pluginName]&&r.optionListeners&&typeof r.optionListeners[o]=="function"&&(i=r.optionListeners[o].call(e[r.pluginName],t))}),i}};function Kt(n){var e=n.sortable,o=n.rootEl,t=n.name,i=n.targetEl,r=n.cloneEl,a=n.toEl,l=n.fromEl,s=n.oldIndex,u=n.newIndex,d=n.oldDraggableIndex,f=n.newDraggableIndex,y=n.originalEvent,_=n.putSortable,v=n.extraEventProperties;if(e=e||o&&o[X],!!e){var b,S=e.options,O="on"+t.charAt(0).toUpperCase()+t.substr(1);window.CustomEvent&&!Q&&!Oe?b=new CustomEvent(t,{bubbles:!0,cancelable:!0}):(b=document.createEvent("Event"),b.initEvent(t,!0,!0)),b.to=a||o,b.from=l||o,b.item=i||o,b.clone=r,b.oldIndex=s,b.newIndex=u,b.oldDraggableIndex=d,b.newDraggableIndex=f,b.originalEvent=y,b.pullMode=_?_.lastPutMode:void 0;var P=q(q({},v),Pe.getEventProperties(t,e));for(var M in P)b[M]=P[M];o&&o.dispatchEvent(b),S[O]&&S[O].call(e,b)}}var Zt=["evt"],B=function(e,o){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=t.evt,r=Ht(t,Zt);Pe.pluginEvent.bind(g)(e,o,q({dragEl:c,parentEl:T,ghostEl:m,rootEl:D,nextEl:ue,lastDownEl:Be,cloneEl:C,cloneHidden:ne,dragStarted:Ee,putSortable:A,activeSortable:g.active,originalEvent:i,oldIndex:he,oldDraggableIndex:Te,newIndex:H,newDraggableIndex:te,hideGhostForTarget:Nt,unhideGhostForTarget:kt,cloneNowHidden:function(){ne=!0},cloneNowShown:function(){ne=!1},dispatchSortableEvent:function(l){R({sortable:o,name:l,originalEvent:i})}},r))};function R(n){Kt(q({putSortable:A,cloneEl:C,targetEl:c,rootEl:D,oldIndex:he,oldDraggableIndex:Te,newIndex:H,newDraggableIndex:te},n))}var c,T,m,D,ue,Be,C,ne,he,H,Te,te,ke,A,fe=!1,$e=!1,We=[],le,W,Ke,Ze,vt,bt,Ee,de,Ie,xe=!1,Ve=!1,Xe,k,Qe=[],ot=!1,je=[],ze=typeof document<"u",Me=lt,yt=Oe||Q?"cssFloat":"float",Qt=ze&&!Et&&!lt&&"draggable"in document.createElement("div"),Ot=(function(){if(ze){if(Q)return!1;var n=document.createElement("x");return n.style.cssText="pointer-events:auto",n.style.pointerEvents==="auto"}})(),Pt=function(e,o){var t=p(e),i=parseInt(t.width)-parseInt(t.paddingLeft)-parseInt(t.paddingRight)-parseInt(t.borderLeftWidth)-parseInt(t.borderRightWidth),r=ge(e,0,o),a=ge(e,1,o),l=r&&p(r),s=a&&p(a),u=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+x(r).width,d=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+x(a).width;if(t.display==="flex")return t.flexDirection==="column"||t.flexDirection==="column-reverse"?"vertical":"horizontal";if(t.display==="grid")return t.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(r&&l.float&&l.float!=="none"){var f=l.float==="left"?"left":"right";return a&&(s.clear==="both"||s.clear===f)?"vertical":"horizontal"}return r&&(l.display==="block"||l.display==="flex"||l.display==="table"||l.display==="grid"||u>=i&&t[yt]==="none"||a&&t[yt]==="none"&&u+d>i)?"vertical":"horizontal"},Jt=function(e,o,t){var i=t?e.left:e.top,r=t?e.right:e.bottom,a=t?e.width:e.height,l=t?o.left:o.top,s=t?o.right:o.bottom,u=t?o.width:o.height;return i===l||r===s||i+a/2===l+u/2},en=function(e,o){var t;return We.some(function(i){var r=i[X].options.emptyInsertThreshold;if(!(!r||st(i))){var a=x(i),l=e>=a.left-r&&e<=a.right+r,s=o>=a.top-r&&o<=a.bottom+r;if(l&&s)return t=i}}),t},At=function(e){function o(r,a){return function(l,s,u,d){var f=l.options.group.name&&s.options.group.name&&l.options.group.name===s.options.group.name;if(r==null&&(a||f))return!0;if(r==null||r===!1)return!1;if(a&&r==="clone")return r;if(typeof r=="function")return o(r(l,s,u,d),a)(l,s,u,d);var y=(a?l:s).options.group.name;return r===!0||typeof r=="string"&&r===y||r.join&&r.indexOf(y)>-1}}var t={},i=e.group;(!i||Re(i)!="object")&&(i={name:i}),t.name=i.name,t.checkPull=o(i.pull,!0),t.checkPut=o(i.put),t.revertClone=i.revertClone,e.group=t},Nt=function(){!Ot&&m&&p(m,"display","none")},kt=function(){!Ot&&m&&p(m,"display","")};ze&&!Et&&document.addEventListener("click",function(n){if($e)return n.preventDefault(),n.stopPropagation&&n.stopPropagation(),n.stopImmediatePropagation&&n.stopImmediatePropagation(),$e=!1,!1},!0);var se=function(e){if(c){e=e.touches?e.touches[0]:e;var o=en(e.clientX,e.clientY);if(o){var t={};for(var i in e)e.hasOwnProperty(i)&&(t[i]=e[i]);t.target=t.rootEl=o,t.preventDefault=void 0,t.stopPropagation=void 0,o[X]._onDragOver(t)}}},tn=function(e){c&&c.parentNode[X]._isOutsideThisEl(e.target)};function g(n,e){if(!(n&&n.nodeType&&n.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(n));this.el=n,this.options=e=Z({},e),n[X]=this;var o={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(n.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Pt(n,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(a,l){a.setData("Text",l.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:g.supportPointer!==!1&&"PointerEvent"in window&&(!Se||lt),emptyInsertThreshold:5};Pe.initializePlugins(this,n,o);for(var t in o)!(t in e)&&(e[t]=o[t]);At(e);for(var i in this)i.charAt(0)==="_"&&typeof this[i]=="function"&&(this[i]=this[i].bind(this));this.nativeDraggable=e.forceFallback?!1:Qt,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?E(n,"pointerdown",this._onTapStart):(E(n,"mousedown",this._onTapStart),E(n,"touchstart",this._onTapStart)),this.nativeDraggable&&(E(n,"dragover",this),E(n,"dragenter",this)),We.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),Z(this,zt())}g.prototype={constructor:g,_isOutsideThisEl:function(e){!this.el.contains(e)&&e!==this.el&&(de=null)},_getDirection:function(e,o){return typeof this.options.direction=="function"?this.options.direction.call(this,e,o,c):this.options.direction},_onTapStart:function(e){if(e.cancelable){var o=this,t=this.el,i=this.options,r=i.preventOnFilter,a=e.type,l=e.touches&&e.touches[0]||e.pointerType&&e.pointerType==="touch"&&e,s=(l||e).target,u=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||s,d=i.filter;if(cn(t),!c&&!(/mousedown|pointerdown/.test(a)&&e.button!==0||i.disabled)&&!u.isContentEditable&&!(!this.nativeDraggable&&Se&&s&&s.tagName.toUpperCase()==="SELECT")&&(s=j(s,i.draggable,t,!1),!(s&&s.animated)&&Be!==s)){if(he=$(s),Te=$(s,i.draggable),typeof d=="function"){if(d.call(this,e,s,this)){R({sortable:o,rootEl:u,name:"filter",targetEl:s,toEl:t,fromEl:t}),B("filter",o,{evt:e}),r&&e.preventDefault();return}}else if(d&&(d=d.split(",").some(function(f){if(f=j(u,f.trim(),t,!1),f)return R({sortable:o,rootEl:f,name:"filter",targetEl:s,fromEl:t,toEl:t}),B("filter",o,{evt:e}),!0}),d)){r&&e.preventDefault();return}i.handle&&!j(u,i.handle,t,!1)||this._prepareDragStart(e,l,s)}}},_prepareDragStart:function(e,o,t){var i=this,r=i.el,a=i.options,l=r.ownerDocument,s;if(t&&!c&&t.parentNode===r){var u=x(t);if(D=r,c=t,T=c.parentNode,ue=c.nextSibling,Be=t,ke=a.group,g.dragged=c,le={target:c,clientX:(o||e).clientX,clientY:(o||e).clientY},vt=le.clientX-u.left,bt=le.clientY-u.top,this._lastX=(o||e).clientX,this._lastY=(o||e).clientY,c.style["will-change"]="all",s=function(){if(B("delayEnded",i,{evt:e}),g.eventCanceled){i._onDrop();return}i._disableDelayedDragEvents(),!ht&&i.nativeDraggable&&(c.draggable=!0),i._triggerDragStart(e,o),R({sortable:i,name:"choose",originalEvent:e}),L(c,a.chosenClass,!0)},a.ignore.split(",").forEach(function(d){St(c,d.trim(),Je)}),E(l,"dragover",se),E(l,"mousemove",se),E(l,"touchmove",se),a.supportPointer?(E(l,"pointerup",i._onDrop),!this.nativeDraggable&&E(l,"pointercancel",i._onDrop)):(E(l,"mouseup",i._onDrop),E(l,"touchend",i._onDrop),E(l,"touchcancel",i._onDrop)),ht&&this.nativeDraggable&&(this.options.touchStartThreshold=4,c.draggable=!0),B("delayStart",this,{evt:e}),a.delay&&(!a.delayOnTouchOnly||o)&&(!this.nativeDraggable||!(Oe||Q))){if(g.eventCanceled){this._onDrop();return}a.supportPointer?(E(l,"pointerup",i._disableDelayedDrag),E(l,"pointercancel",i._disableDelayedDrag)):(E(l,"mouseup",i._disableDelayedDrag),E(l,"touchend",i._disableDelayedDrag),E(l,"touchcancel",i._disableDelayedDrag)),E(l,"mousemove",i._delayedDragTouchMoveHandler),E(l,"touchmove",i._delayedDragTouchMoveHandler),a.supportPointer&&E(l,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(s,a.delay)}else s()}},_delayedDragTouchMoveHandler:function(e){var o=e.touches?e.touches[0]:e;Math.max(Math.abs(o.clientX-this._lastX),Math.abs(o.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){c&&Je(c),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;w(e,"mouseup",this._disableDelayedDrag),w(e,"touchend",this._disableDelayedDrag),w(e,"touchcancel",this._disableDelayedDrag),w(e,"pointerup",this._disableDelayedDrag),w(e,"pointercancel",this._disableDelayedDrag),w(e,"mousemove",this._delayedDragTouchMoveHandler),w(e,"touchmove",this._delayedDragTouchMoveHandler),w(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,o){o=o||e.pointerType=="touch"&&e,!this.nativeDraggable||o?this.options.supportPointer?E(document,"pointermove",this._onTouchMove):o?E(document,"touchmove",this._onTouchMove):E(document,"mousemove",this._onTouchMove):(E(c,"dragend",this),E(D,"dragstart",this._onDragStart));try{document.selection?Ye(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(e,o){if(fe=!1,D&&c){B("dragStarted",this,{evt:o}),this.nativeDraggable&&E(document,"dragover",tn);var t=this.options;!e&&L(c,t.dragClass,!1),L(c,t.ghostClass,!0),g.active=this,e&&this._appendGhost(),R({sortable:this,name:"start",originalEvent:o})}else this._nulling()},_emulateDragOver:function(){if(W){this._lastX=W.clientX,this._lastY=W.clientY,Nt();for(var e=document.elementFromPoint(W.clientX,W.clientY),o=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(W.clientX,W.clientY),e!==o);)o=e;if(c.parentNode[X]._isOutsideThisEl(e),o)do{if(o[X]){var t=void 0;if(t=o[X]._onDragOver({clientX:W.clientX,clientY:W.clientY,target:e,rootEl:o}),t&&!this.options.dragoverBubble)break}e=o}while(o=Dt(o));kt()}},_onTouchMove:function(e){if(le){var o=this.options,t=o.fallbackTolerance,i=o.fallbackOffset,r=e.touches?e.touches[0]:e,a=m&&pe(m,!0),l=m&&a&&a.a,s=m&&a&&a.d,u=Me&&k&&mt(k),d=(r.clientX-le.clientX+i.x)/(l||1)+(u?u[0]-Qe[0]:0)/(l||1),f=(r.clientY-le.clientY+i.y)/(s||1)+(u?u[1]-Qe[1]:0)/(s||1);if(!g.active&&!fe){if(t&&Math.max(Math.abs(r.clientX-this._lastX),Math.abs(r.clientY-this._lastY))<t)return;this._onDragStart(e,!0)}if(m){a?(a.e+=d-(Ke||0),a.f+=f-(Ze||0)):a={a:1,b:0,c:0,d:1,e:d,f};var y="matrix(".concat(a.a,",").concat(a.b,",").concat(a.c,",").concat(a.d,",").concat(a.e,",").concat(a.f,")");p(m,"webkitTransform",y),p(m,"mozTransform",y),p(m,"msTransform",y),p(m,"transform",y),Ke=d,Ze=f,W=r}e.cancelable&&e.preventDefault()}},_appendGhost:function(){if(!m){var e=this.options.fallbackOnBody?document.body:D,o=x(c,!0,Me,!0,e),t=this.options;if(Me){for(k=e;p(k,"position")==="static"&&p(k,"transform")==="none"&&k!==document;)k=k.parentNode;k!==document.body&&k!==document.documentElement?(k===document&&(k=z()),o.top+=k.scrollTop,o.left+=k.scrollLeft):k=z(),Qe=mt(k)}m=c.cloneNode(!0),L(m,t.ghostClass,!1),L(m,t.fallbackClass,!0),L(m,t.dragClass,!0),p(m,"transition",""),p(m,"transform",""),p(m,"box-sizing","border-box"),p(m,"margin",0),p(m,"top",o.top),p(m,"left",o.left),p(m,"width",o.width),p(m,"height",o.height),p(m,"opacity","0.8"),p(m,"position",Me?"absolute":"fixed"),p(m,"zIndex","100000"),p(m,"pointerEvents","none"),g.ghost=m,e.appendChild(m),p(m,"transform-origin",vt/parseInt(m.style.width)*100+"% "+bt/parseInt(m.style.height)*100+"%")}},_onDragStart:function(e,o){var t=this,i=e.dataTransfer,r=t.options;if(B("dragStart",this,{evt:e}),g.eventCanceled){this._onDrop();return}B("setupClone",this),g.eventCanceled||(C=It(c),C.removeAttribute("id"),C.draggable=!1,C.style["will-change"]="",this._hideClone(),L(C,this.options.chosenClass,!1),g.clone=C),t.cloneId=Ye(function(){B("clone",t),!g.eventCanceled&&(t.options.removeCloneOnHide||D.insertBefore(C,c),t._hideClone(),R({sortable:t,name:"clone"}))}),!o&&L(c,r.dragClass,!0),o?($e=!0,t._loopId=setInterval(t._emulateDragOver,50)):(w(document,"mouseup",t._onDrop),w(document,"touchend",t._onDrop),w(document,"touchcancel",t._onDrop),i&&(i.effectAllowed="move",r.setData&&r.setData.call(t,i,c)),E(document,"drop",t),p(c,"transform","translateZ(0)")),fe=!0,t._dragStartId=Ye(t._dragStarted.bind(t,o,e)),E(document,"selectstart",t),Ee=!0,window.getSelection().removeAllRanges(),Se&&p(document.body,"user-select","none")},_onDragOver:function(e){var o=this.el,t=e.target,i,r,a,l=this.options,s=l.group,u=g.active,d=ke===s,f=l.sort,y=A||u,_,v=this,b=!1;if(ot)return;function S(we,Mt){B(we,v,q({evt:e,isOwner:d,axis:_?"vertical":"horizontal",revert:a,dragRect:i,targetRect:r,canSort:f,fromSortable:y,target:t,completed:P,onMove:function(dt,Ft){return Fe(D,o,c,i,dt,x(dt),e,Ft)},changed:M},Mt))}function O(){S("dragOverAnimationCapture"),v.captureAnimationState(),v!==y&&y.captureAnimationState()}function P(we){return S("dragOverCompleted",{insertion:we}),we&&(d?u._hideClone():u._showClone(v),v!==y&&(L(c,A?A.options.ghostClass:u.options.ghostClass,!1),L(c,l.ghostClass,!0)),A!==v&&v!==g.active?A=v:v===g.active&&A&&(A=null),y===v&&(v._ignoreWhileAnimating=t),v.animateAll(function(){S("dragOverAnimationComplete"),v._ignoreWhileAnimating=null}),v!==y&&(y.animateAll(),y._ignoreWhileAnimating=null)),(t===c&&!c.animated||t===o&&!t.animated)&&(de=null),!l.dragoverBubble&&!e.rootEl&&t!==document&&(c.parentNode[X]._isOutsideThisEl(e.target),!we&&se(e)),!l.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),b=!0}function M(){H=$(c),te=$(c,l.draggable),R({sortable:v,name:"change",toEl:o,newIndex:H,newDraggableIndex:te,originalEvent:e})}if(e.preventDefault!==void 0&&e.cancelable&&e.preventDefault(),t=j(t,l.draggable,o,!0),S("dragOver"),g.eventCanceled)return b;if(c.contains(e.target)||t.animated&&t.animatingX&&t.animatingY||v._ignoreWhileAnimating===t)return P(!1);if($e=!1,u&&!l.disabled&&(d?f||(a=T!==D):A===this||(this.lastPutMode=ke.checkPull(this,u,c,e))&&s.checkPut(this,u,c,e))){if(_=this._getDirection(e,t)==="vertical",i=x(c),S("dragOverValid"),g.eventCanceled)return b;if(a)return T=D,O(),this._hideClone(),S("revert"),g.eventCanceled||(ue?D.insertBefore(c,ue):D.appendChild(c)),P(!0);var F=st(o,l.draggable);if(!F||an(e,_,this)&&!F.animated){if(F===c)return P(!1);if(F&&o===e.target&&(t=F),t&&(r=x(t)),Fe(D,o,c,i,t,r,e,!!t)!==!1)return O(),F&&F.nextSibling?o.insertBefore(c,F.nextSibling):o.appendChild(c),T=o,M(),P(!0)}else if(F&&rn(e,_,this)){var ie=ge(o,0,l,!0);if(ie===c)return P(!1);if(t=ie,r=x(t),Fe(D,o,c,i,t,r,e,!1)!==!1)return O(),o.insertBefore(c,ie),T=o,M(),P(!0)}else if(t.parentNode===o){r=x(t);var G=0,re,me=c.parentNode!==o,Y=!Jt(c.animated&&c.toRect||i,t.animated&&t.toRect||r,_),ve=_?"top":"left",J=gt(t,"top","top")||gt(c,"top","top"),be=J?J.scrollTop:void 0;de!==t&&(re=r[ve],xe=!1,Ve=!Y&&l.invertSwap||me),G=ln(e,t,r,_,Y?1:l.swapThreshold,l.invertedSwapThreshold==null?l.swapThreshold:l.invertedSwapThreshold,Ve,de===t);var U;if(G!==0){var ae=$(c);do ae-=G,U=T.children[ae];while(U&&(p(U,"display")==="none"||U===m))}if(G===0||U===t)return P(!1);de=t,Ie=G;var ye=t.nextElementSibling,ee=!1;ee=G===1;var Ae=Fe(D,o,c,i,t,r,e,ee);if(Ae!==!1)return(Ae===1||Ae===-1)&&(ee=Ae===1),ot=!0,setTimeout(on,30),O(),ee&&!ye?o.appendChild(c):t.parentNode.insertBefore(c,ee?ye:t),J&&Tt(J,0,be-J.scrollTop),T=c.parentNode,re!==void 0&&!Ve&&(Xe=Math.abs(re-x(t)[ve])),M(),P(!0)}if(o.contains(c))return P(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){w(document,"mousemove",this._onTouchMove),w(document,"touchmove",this._onTouchMove),w(document,"pointermove",this._onTouchMove),w(document,"dragover",se),w(document,"mousemove",se),w(document,"touchmove",se)},_offUpEvents:function(){var e=this.el.ownerDocument;w(e,"mouseup",this._onDrop),w(e,"touchend",this._onDrop),w(e,"pointerup",this._onDrop),w(e,"pointercancel",this._onDrop),w(e,"touchcancel",this._onDrop),w(document,"selectstart",this)},_onDrop:function(e){var o=this.el,t=this.options;if(H=$(c),te=$(c,t.draggable),B("drop",this,{evt:e}),T=c&&c.parentNode,H=$(c),te=$(c,t.draggable),g.eventCanceled){this._nulling();return}fe=!1,Ve=!1,xe=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),it(this.cloneId),it(this._dragStartId),this.nativeDraggable&&(w(document,"drop",this),w(o,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),Se&&p(document.body,"user-select",""),p(c,"transform",""),e&&(Ee&&(e.cancelable&&e.preventDefault(),!t.dropBubble&&e.stopPropagation()),m&&m.parentNode&&m.parentNode.removeChild(m),(D===T||A&&A.lastPutMode!=="clone")&&C&&C.parentNode&&C.parentNode.removeChild(C),c&&(this.nativeDraggable&&w(c,"dragend",this),Je(c),c.style["will-change"]="",Ee&&!fe&&L(c,A?A.options.ghostClass:this.options.ghostClass,!1),L(c,this.options.chosenClass,!1),R({sortable:this,name:"unchoose",toEl:T,newIndex:null,newDraggableIndex:null,originalEvent:e}),D!==T?(H>=0&&(R({rootEl:T,name:"add",toEl:T,fromEl:D,originalEvent:e}),R({sortable:this,name:"remove",toEl:T,originalEvent:e}),R({rootEl:T,name:"sort",toEl:T,fromEl:D,originalEvent:e}),R({sortable:this,name:"sort",toEl:T,originalEvent:e})),A&&A.save()):H!==he&&H>=0&&(R({sortable:this,name:"update",toEl:T,originalEvent:e}),R({sortable:this,name:"sort",toEl:T,originalEvent:e})),g.active&&((H==null||H===-1)&&(H=he,te=Te),R({sortable:this,name:"end",toEl:T,originalEvent:e}),this.save()))),this._nulling()},_nulling:function(){B("nulling",this),D=c=T=m=ue=C=Be=ne=le=W=Ee=H=te=he=Te=de=Ie=A=ke=g.dragged=g.ghost=g.clone=g.active=null,je.forEach(function(e){e.checked=!0}),je.length=Ke=Ze=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":c&&(this._onDragOver(e),nn(e));break;case"selectstart":e.preventDefault();break}},toArray:function(){for(var e=[],o,t=this.el.children,i=0,r=t.length,a=this.options;i<r;i++)o=t[i],j(o,a.draggable,this.el,!1)&&e.push(o.getAttribute(a.dataIdAttr)||un(o));return e},sort:function(e,o){var t={},i=this.el;this.toArray().forEach(function(r,a){var l=i.children[a];j(l,this.options.draggable,i,!1)&&(t[r]=l)},this),o&&this.captureAnimationState(),e.forEach(function(r){t[r]&&(i.removeChild(t[r]),i.appendChild(t[r]))}),o&&this.animateAll()},save:function(){var e=this.options.store;e&&e.set&&e.set(this)},closest:function(e,o){return j(e,o||this.options.draggable,this.el,!1)},option:function(e,o){var t=this.options;if(o===void 0)return t[e];var i=Pe.modifyOption(this,e,o);typeof i<"u"?t[e]=i:t[e]=o,e==="group"&&At(t)},destroy:function(){B("destroy",this);var e=this.el;e[X]=null,w(e,"mousedown",this._onTapStart),w(e,"touchstart",this._onTapStart),w(e,"pointerdown",this._onTapStart),this.nativeDraggable&&(w(e,"dragover",this),w(e,"dragenter",this)),Array.prototype.forEach.call(e.querySelectorAll("[draggable]"),function(o){o.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),We.splice(We.indexOf(this.el),1),this.el=e=null},_hideClone:function(){if(!ne){if(B("hideClone",this),g.eventCanceled)return;p(C,"display","none"),this.options.removeCloneOnHide&&C.parentNode&&C.parentNode.removeChild(C),ne=!0}},_showClone:function(e){if(e.lastPutMode!=="clone"){this._hideClone();return}if(ne){if(B("showClone",this),g.eventCanceled)return;c.parentNode==D&&!this.options.group.revertClone?D.insertBefore(C,c):ue?D.insertBefore(C,ue):D.appendChild(C),this.options.group.revertClone&&this.animate(c,C),p(C,"display",""),ne=!1}}};function nn(n){n.dataTransfer&&(n.dataTransfer.dropEffect="move"),n.cancelable&&n.preventDefault()}function Fe(n,e,o,t,i,r,a,l){var s,u=n[X],d=u.options.onMove,f;return window.CustomEvent&&!Q&&!Oe?s=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(s=document.createEvent("Event"),s.initEvent("move",!0,!0)),s.to=e,s.from=n,s.dragged=o,s.draggedRect=t,s.related=i||e,s.relatedRect=r||x(e),s.willInsertAfter=l,s.originalEvent=a,n.dispatchEvent(s),d&&(f=d.call(u,s,a)),f}function Je(n){n.draggable=!1}function on(){ot=!1}function rn(n,e,o){var t=x(ge(o.el,0,o.options,!0)),i=xt(o.el,o.options,m),r=10;return e?n.clientX<i.left-r||n.clientY<t.top&&n.clientX<t.right:n.clientY<i.top-r||n.clientY<t.bottom&&n.clientX<t.left}function an(n,e,o){var t=x(st(o.el,o.options.draggable)),i=xt(o.el,o.options,m),r=10;return e?n.clientX>i.right+r||n.clientY>t.bottom&&n.clientX>t.left:n.clientY>i.bottom+r||n.clientX>t.right&&n.clientY>t.top}function ln(n,e,o,t,i,r,a,l){var s=t?n.clientY:n.clientX,u=t?o.height:o.width,d=t?o.top:o.left,f=t?o.bottom:o.right,y=!1;if(!a){if(l&&Xe<u*i){if(!xe&&(Ie===1?s>d+u*r/2:s<f-u*r/2)&&(xe=!0),xe)y=!0;else if(Ie===1?s<d+Xe:s>f-Xe)return-Ie}else if(s>d+u*(1-i)/2&&s<f-u*(1-i)/2)return sn(e)}return y=y||a,y&&(s<d+u*r/2||s>f-u*r/2)?s>d+u/2?1:-1:0}function sn(n){return $(c)<$(n)?1:-1}function un(n){for(var e=n.tagName+n.className+n.src+n.href+n.textContent,o=e.length,t=0;o--;)t+=e.charCodeAt(o);return t.toString(36)}function cn(n){je.length=0;for(var e=n.getElementsByTagName("input"),o=e.length;o--;){var t=e[o];t.checked&&je.push(t)}}function Ye(n){return setTimeout(n,0)}function it(n){return clearTimeout(n)}ze&&E(document,"touchmove",function(n){(g.active||fe)&&n.cancelable&&n.preventDefault()});g.utils={on:E,off:w,css:p,find:St,is:function(e,o){return!!j(e,o,e,!1)},extend:jt,throttle:Ct,closest:j,toggleClass:L,clone:It,index:$,nextTick:Ye,cancelNextTick:it,detectDirection:Pt,getChild:ge,expando:X};g.get=function(n){return n[X]};g.mount=function(){for(var n=arguments.length,e=new Array(n),o=0;o<n;o++)e[o]=arguments[o];e[0].constructor===Array&&(e=e[0]),e.forEach(function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(g.utils=q(q({},g.utils),t.utils)),Pe.mount(t)})};g.create=function(n,e){return new g(n,e)};g.version=$t;var I=[],_e,rt,at=!1,et,tt,Ge,De;function dn(){function n(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var e in this)e.charAt(0)==="_"&&typeof this[e]=="function"&&(this[e]=this[e].bind(this))}return n.prototype={dragStarted:function(o){var t=o.originalEvent;this.sortable.nativeDraggable?E(document,"dragover",this._handleAutoScroll):this.options.supportPointer?E(document,"pointermove",this._handleFallbackAutoScroll):t.touches?E(document,"touchmove",this._handleFallbackAutoScroll):E(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(o){var t=o.originalEvent;!this.options.dragOverBubble&&!t.rootEl&&this._handleAutoScroll(t)},drop:function(){this.sortable.nativeDraggable?w(document,"dragover",this._handleAutoScroll):(w(document,"pointermove",this._handleFallbackAutoScroll),w(document,"touchmove",this._handleFallbackAutoScroll),w(document,"mousemove",this._handleFallbackAutoScroll)),wt(),Le(),Gt()},nulling:function(){Ge=rt=_e=at=De=et=tt=null,I.length=0},_handleFallbackAutoScroll:function(o){this._handleAutoScroll(o,!0)},_handleAutoScroll:function(o,t){var i=this,r=(o.touches?o.touches[0]:o).clientX,a=(o.touches?o.touches[0]:o).clientY,l=document.elementFromPoint(r,a);if(Ge=o,t||this.options.forceAutoScrollFallback||Oe||Q||Se){nt(o,this.options,l,t);var s=oe(l,!0);at&&(!De||r!==et||a!==tt)&&(De&&wt(),De=setInterval(function(){var u=oe(document.elementFromPoint(r,a),!0);u!==s&&(s=u,Le()),nt(o,i.options,u,t)},10),et=r,tt=a)}else{if(!this.options.bubbleScroll||oe(l,!0)===z()){Le();return}nt(o,this.options,oe(l,!1),!1)}}},Z(n,{pluginName:"scroll",initializeByDefault:!0})}function Le(){I.forEach(function(n){clearInterval(n.pid)}),I=[]}function wt(){clearInterval(De)}var nt=Ct(function(n,e,o,t){if(e.scroll){var i=(n.touches?n.touches[0]:n).clientX,r=(n.touches?n.touches[0]:n).clientY,a=e.scrollSensitivity,l=e.scrollSpeed,s=z(),u=!1,d;rt!==o&&(rt=o,Le(),_e=e.scroll,d=e.scrollFn,_e===!0&&(_e=oe(o,!0)));var f=0,y=_e;do{var _=y,v=x(_),b=v.top,S=v.bottom,O=v.left,P=v.right,M=v.width,F=v.height,ie=void 0,G=void 0,re=_.scrollWidth,me=_.scrollHeight,Y=p(_),ve=_.scrollLeft,J=_.scrollTop;_===s?(ie=M<re&&(Y.overflowX==="auto"||Y.overflowX==="scroll"||Y.overflowX==="visible"),G=F<me&&(Y.overflowY==="auto"||Y.overflowY==="scroll"||Y.overflowY==="visible")):(ie=M<re&&(Y.overflowX==="auto"||Y.overflowX==="scroll"),G=F<me&&(Y.overflowY==="auto"||Y.overflowY==="scroll"));var be=ie&&(Math.abs(P-i)<=a&&ve+M<re)-(Math.abs(O-i)<=a&&!!ve),U=G&&(Math.abs(S-r)<=a&&J+F<me)-(Math.abs(b-r)<=a&&!!J);if(!I[f])for(var ae=0;ae<=f;ae++)I[ae]||(I[ae]={});(I[f].vx!=be||I[f].vy!=U||I[f].el!==_)&&(I[f].el=_,I[f].vx=be,I[f].vy=U,clearInterval(I[f].pid),(be!=0||U!=0)&&(u=!0,I[f].pid=setInterval((function(){t&&this.layer===0&&g.active._onTouchMove(Ge);var ye=I[this.layer].vy?I[this.layer].vy*l:0,ee=I[this.layer].vx?I[this.layer].vx*l:0;typeof d=="function"&&d.call(g.dragged.parentNode[X],ee,ye,n,Ge,I[this.layer].el)!=="continue"||Tt(I[this.layer].el,ee,ye)}).bind({layer:f}),24))),f++}while(e.bubbleScroll&&y!==s&&(y=oe(y,!1)));at=u}},30),Vt=function(e){var o=e.originalEvent,t=e.putSortable,i=e.dragEl,r=e.activeSortable,a=e.dispatchSortableEvent,l=e.hideGhostForTarget,s=e.unhideGhostForTarget;if(o){var u=t||r;l();var d=o.changedTouches&&o.changedTouches.length?o.changedTouches[0]:o,f=document.elementFromPoint(d.clientX,d.clientY);s(),u&&!u.el.contains(f)&&(a("spill"),this.onSpill({dragEl:i,putSortable:t}))}};function ut(){}ut.prototype={startIndex:null,dragStart:function(e){var o=e.oldDraggableIndex;this.startIndex=o},onSpill:function(e){var o=e.dragEl,t=e.putSortable;this.sortable.captureAnimationState(),t&&t.captureAnimationState();var i=ge(this.sortable.el,this.startIndex,this.options);i?this.sortable.el.insertBefore(o,i):this.sortable.el.appendChild(o),this.sortable.animateAll(),t&&t.animateAll()},drop:Vt};Z(ut,{pluginName:"revertOnSpill"});function ct(){}ct.prototype={onSpill:function(e){var o=e.dragEl,t=e.putSortable,i=t||this.sortable;i.captureAnimationState(),o.parentNode&&o.parentNode.removeChild(o),i.animateAll()},drop:Vt};Z(ct,{pluginName:"removeOnSpill"});g.mount(new dn);g.mount(ct,ut);function fn(n,e,o={}){let t;const{document:i=Ne.defaultDocument,...r}=o,a={onUpdate:d=>{gn(e,d.oldIndex,d.newIndex,d)}},l=()=>{const d=typeof n=="string"?i?.querySelector(n):Ne.unrefElement(n);!d||t!==void 0||(t=new g(d,{...a,...r}))},s=()=>{t?.destroy(),t=void 0},u=(d,f)=>{if(f!==void 0)t?.option(d,f);else return t?.option(d)};return Ne.tryOnMounted(l),Ne.tryOnScopeDispose(s),{stop:s,start:l,option:u}}function hn(n,e,o){const t=n.children[o];n.insertBefore(e,t)}function pn(n){n.parentNode&&n.parentNode.removeChild(n)}function gn(n,e,o,t=null){t!=null&&(pn(t.item),hn(t.from,t.item,e));const i=h.isRef(n),r=i?[...h.toValue(n)]:h.toValue(n);if(o>=0&&o<r.length){const a=r.splice(e,1)[0];h.nextTick(()=>{r.splice(o,0,a),i&&(n.value=r)})}}const mn={class:"text-medium-emphasis ps-2"},vn={__name:"Dialog",setup(n,{expose:e}){const o=h.inject("table_props"),t=h.inject("datatablesPluginOptions"),{tableState:i}=N.useTableState(),{tableDataState:r}=N.useDatastate(o),a=h.ref(0),l=h.useTemplateRef("listRef"),s=h.ref(!1),u=h.ref([]),d=h.ref([]),f=h.ref([]),y=()=>{s.value=!0};h.onMounted(async()=>{d.value=i.value.options.columns?.selected,f.value=i.value.options.columns?.sorted,u.value=f.value.map(b=>o.headers.find(S=>S.key===b)),await h.nextTick();const{option:v}=fn(l,u,{onUpdate:async b=>{await h.nextTick();const S=Array.from(b.from.children).map(function(O){return O.getAttribute("header-keys")});N.deepEqual(S,f.value)||(f.value=S)}});v("animation",200)});const _=()=>{(!N.deepEqual(d.value,i.value.options.columns?.selected)||!N.deepEqual(f.value,i.value.options.columns?.sorted))&&(r.value.options.columns.selected=d.value,r.value.options.columns.sorted=f.value),s.value=!1};return e({openDialog:y}),(v,b)=>(h.openBlock(),h.createBlock(N.VDialog,{modelValue:h.unref(s),"onUpdate:modelValue":b[1]||(b[1]=S=>h.isRef(s)?s.value=S:null),"max-width":"500",eager:"","retain-focus":!1},{default:h.withCtx(({isActive:S})=>[h.createVNode(N.VCard,{rounded:"lg"},{default:h.withCtx(()=>[h.createVNode(N.VCardTitle,{class:"d-flex justify-space-between align-center"},{default:h.withCtx(()=>[h.createElementVNode("div",mn,h.toDisplayString(v.$t("$datatables.selectColumns")),1),h.createVNode(V.VBtn,{icon:h.unref(t).header.icons.close,variant:"text",onClick:O=>S.value=!1},null,8,["icon","onClick"])]),_:2},1024),h.createVNode(V.VDivider),h.createVNode(N.VCardText,{class:"overflow-auto pt-8"},{default:h.withCtx(()=>[h.createVNode(V.VList,{ref_key:"listRef",ref:l},{default:h.withCtx(()=>[(h.openBlock(!0),h.createElementBlock(h.Fragment,null,h.renderList(h.unref(u),(O,P)=>(h.openBlock(),h.createBlock(V.VListItem,{key:`${h.unref(a)}-${P}`,title:O?.title,"header-keys":O?.key,onClick:()=>{}},{prepend:h.withCtx(()=>[h.createVNode(Xt,{modelValue:h.unref(d),"onUpdate:modelValue":b[0]||(b[0]=M=>h.isRef(d)?d.value=M:null),value:O?.key,"hide-details":""},null,8,["modelValue","value"])]),append:h.withCtx(()=>[h.createVNode(V.VIcon,{icon:h.unref(t).header.icons.drag},null,8,["icon"])]),_:2},1032,["title","header-keys"]))),128))]),_:1},512)]),_:1}),h.createVNode(V.VDivider,{class:"mt-2"}),h.createVNode(N.VCardActions,{class:"my-2 d-flex justify-end"},{default:h.withCtx(()=>[h.createVNode(V.VBtn,{class:"text-none",text:v.$t("$datatables.cancel"),onClick:O=>S.value=!1},null,8,["text","onClick"]),h.createVNode(V.VBtn,{class:"text-none",color:"primary",text:v.$t("$datatables.submit"),variant:"flat",onClick:_},null,8,["text"])]),_:2},1024)]),_:2},1024)]),_:1},8,["modelValue"]))}};function bn(){const n=h.inject("datatablesPluginOptions"),{t:e}=Rt.useI18n(),o=h.ref();return{columnsItems:h.computed(()=>[{title:`${e("$datatables.columns")}`,onClick:o.value?.openDialog,prependIcon:n.header.icons.columns}]),columnsRef:o}}exports._sfc_main=vn;exports.useColumns=bn;