@getflip/swirl-components 0.37.0 → 0.38.1

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 (54) hide show
  1. package/components.json +234 -22
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/swirl-app-layout_7.cjs.entry.js +16 -0
  4. package/dist/cjs/swirl-components.cjs.js +1 -1
  5. package/dist/cjs/swirl-console-layout.cjs.entry.js +1 -1
  6. package/dist/cjs/swirl-icon-check-small_4.cjs.entry.js +2 -1
  7. package/dist/cjs/swirl-pagination.cjs.entry.js +20 -9
  8. package/dist/cjs/swirl-search.cjs.entry.js +3 -2
  9. package/dist/cjs/swirl-table.cjs.entry.js +6 -1
  10. package/dist/collection/assets/pdfjs/pdf.worker.min.js +1 -1
  11. package/dist/collection/collection-manifest.json +1 -1
  12. package/dist/collection/components/swirl-box/swirl-box.js +104 -0
  13. package/dist/collection/components/swirl-console-layout/swirl-console-layout.css +1 -1
  14. package/dist/collection/components/swirl-option-list/swirl-option-list.js +9 -4
  15. package/dist/collection/components/swirl-option-list/swirl-option-list.stories.js +1 -1
  16. package/dist/collection/components/swirl-pagination/swirl-pagination.css +20 -10
  17. package/dist/collection/components/swirl-pagination/swirl-pagination.js +61 -50
  18. package/dist/collection/components/swirl-search/swirl-search.css +8 -2
  19. package/dist/collection/components/swirl-search/swirl-search.js +25 -1
  20. package/dist/collection/components/swirl-table/swirl-table.js +6 -1
  21. package/dist/components/assets/pdfjs/pdf.worker.min.js +1 -1
  22. package/dist/components/swirl-box2.js +21 -1
  23. package/dist/components/swirl-console-layout.js +1 -1
  24. package/dist/components/swirl-option-list2.js +2 -1
  25. package/dist/components/swirl-pagination.js +27 -22
  26. package/dist/components/swirl-search.js +5 -3
  27. package/dist/components/swirl-table.js +6 -1
  28. package/dist/esm/loader.js +1 -1
  29. package/dist/esm/swirl-app-layout_7.entry.js +16 -0
  30. package/dist/esm/swirl-components.js +1 -1
  31. package/dist/esm/swirl-console-layout.entry.js +1 -1
  32. package/dist/esm/swirl-icon-check-small_4.entry.js +2 -1
  33. package/dist/esm/swirl-pagination.entry.js +20 -9
  34. package/dist/esm/swirl-search.entry.js +3 -2
  35. package/dist/esm/swirl-table.entry.js +6 -1
  36. package/dist/swirl-components/{p-428a2076.entry.js → p-30e7d460.entry.js} +1 -1
  37. package/dist/swirl-components/p-3c2325ba.entry.js +1 -0
  38. package/dist/swirl-components/p-4c3c8ce8.entry.js +8 -0
  39. package/dist/swirl-components/p-b5bcf47f.entry.js +1 -0
  40. package/dist/swirl-components/{p-16864f08.entry.js → p-d5032332.entry.js} +1 -1
  41. package/dist/swirl-components/p-dbe4ee1a.entry.js +1 -0
  42. package/dist/swirl-components/swirl-components.esm.js +1 -1
  43. package/dist/types/components/swirl-box/swirl-box.d.ts +4 -0
  44. package/dist/types/components/swirl-option-list/swirl-option-list.d.ts +1 -0
  45. package/dist/types/components/swirl-pagination/swirl-pagination.d.ts +7 -5
  46. package/dist/types/components/swirl-search/swirl-search.d.ts +2 -0
  47. package/dist/types/components/swirl-table/swirl-table.d.ts +1 -0
  48. package/dist/types/components.d.ts +21 -5
  49. package/package.json +1 -1
  50. package/vscode-data.json +147 -3
  51. package/dist/swirl-components/p-100b503e.entry.js +0 -8
  52. package/dist/swirl-components/p-3c7eb982.entry.js +0 -1
  53. package/dist/swirl-components/p-774483bc.entry.js +0 -1
  54. package/dist/swirl-components/p-968773d7.entry.js +0 -1
package/vscode-data.json CHANGED
@@ -624,6 +624,138 @@
624
624
  "name": "8"
625
625
  }
626
626
  ]
627
+ },
628
+ {
629
+ "name": "padding-block-end",
630
+ "description": "",
631
+ "values": [
632
+ {
633
+ "name": "0"
634
+ },
635
+ {
636
+ "name": "12"
637
+ },
638
+ {
639
+ "name": "16"
640
+ },
641
+ {
642
+ "name": "2"
643
+ },
644
+ {
645
+ "name": "20"
646
+ },
647
+ {
648
+ "name": "24"
649
+ },
650
+ {
651
+ "name": "32"
652
+ },
653
+ {
654
+ "name": "4"
655
+ },
656
+ {
657
+ "name": "8"
658
+ }
659
+ ]
660
+ },
661
+ {
662
+ "name": "padding-block-start",
663
+ "description": "",
664
+ "values": [
665
+ {
666
+ "name": "0"
667
+ },
668
+ {
669
+ "name": "12"
670
+ },
671
+ {
672
+ "name": "16"
673
+ },
674
+ {
675
+ "name": "2"
676
+ },
677
+ {
678
+ "name": "20"
679
+ },
680
+ {
681
+ "name": "24"
682
+ },
683
+ {
684
+ "name": "32"
685
+ },
686
+ {
687
+ "name": "4"
688
+ },
689
+ {
690
+ "name": "8"
691
+ }
692
+ ]
693
+ },
694
+ {
695
+ "name": "padding-inline-end",
696
+ "description": "",
697
+ "values": [
698
+ {
699
+ "name": "0"
700
+ },
701
+ {
702
+ "name": "12"
703
+ },
704
+ {
705
+ "name": "16"
706
+ },
707
+ {
708
+ "name": "2"
709
+ },
710
+ {
711
+ "name": "20"
712
+ },
713
+ {
714
+ "name": "24"
715
+ },
716
+ {
717
+ "name": "32"
718
+ },
719
+ {
720
+ "name": "4"
721
+ },
722
+ {
723
+ "name": "8"
724
+ }
725
+ ]
726
+ },
727
+ {
728
+ "name": "padding-inline-start",
729
+ "description": "",
730
+ "values": [
731
+ {
732
+ "name": "0"
733
+ },
734
+ {
735
+ "name": "12"
736
+ },
737
+ {
738
+ "name": "16"
739
+ },
740
+ {
741
+ "name": "2"
742
+ },
743
+ {
744
+ "name": "20"
745
+ },
746
+ {
747
+ "name": "24"
748
+ },
749
+ {
750
+ "name": "32"
751
+ },
752
+ {
753
+ "name": "4"
754
+ },
755
+ {
756
+ "name": "8"
757
+ }
758
+ ]
627
759
  }
628
760
  ]
629
761
  },
@@ -3462,15 +3594,15 @@
3462
3594
  },
3463
3595
  "attributes": [
3464
3596
  {
3465
- "name": "accessible-next-button-label",
3597
+ "name": "first-page-button-label",
3466
3598
  "description": ""
3467
3599
  },
3468
3600
  {
3469
- "name": "accessible-prev-button-label",
3601
+ "name": "label",
3470
3602
  "description": ""
3471
3603
  },
3472
3604
  {
3473
- "name": "label",
3605
+ "name": "last-page-button-label",
3474
3606
  "description": ""
3475
3607
  },
3476
3608
  {
@@ -3926,6 +4058,18 @@
3926
4058
  {
3927
4059
  "name": "value",
3928
4060
  "description": ""
4061
+ },
4062
+ {
4063
+ "name": "variant",
4064
+ "description": "",
4065
+ "values": [
4066
+ {
4067
+ "name": "filled"
4068
+ },
4069
+ {
4070
+ "name": "outline"
4071
+ }
4072
+ ]
3929
4073
  }
3930
4074
  ]
3931
4075
  },
@@ -1,8 +0,0 @@
1
- import{r as t,h as i,F as o,c as e,H as n,g as r}from"./p-05c15d47.js";import{c as s}from"./p-b7898321.js";import{c as l,q as a,g as h}from"./p-438b3941.js";const c=class{constructor(i){t(this,i),this.size=24}render(){const t=20===this.size?24:this.size,e=s("swirl-icon",`swirl-icon--size-${this.size}`);return i("svg",{class:e,fill:"none",height:this.size,part:"icon",viewBox:`0 0 ${t} ${t}`,width:this.size,xmlns:"http://www.w3.org/2000/svg"},16===this.size&&i(o,null,i("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M12.4142 4.91924C12.8047 5.30976 12.8047 5.94293 12.4142 6.33345L7.08086 11.6667C6.69033 12.0572 6.05717 12.0572 5.66664 11.6667L3.70711 9.70707C3.31658 9.31655 3.31658 8.68338 3.70711 8.29286C4.09763 7.90233 4.7308 7.90233 5.12132 8.29286L6.37375 9.54539L11 4.91924C11.3905 4.52871 12.0237 4.52871 12.4142 4.91924Z",fill:"currentColor"})),(20===this.size||24===this.size)&&i(o,null,i("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M18.6213 7.37879C19.2071 7.96458 19.2071 8.91433 18.6213 9.50011L10.6213 17.5C10.0355 18.0858 9.08577 18.0858 8.49998 17.5L5.56068 14.5605C4.97489 13.9748 4.97489 13.025 5.56068 12.4392C6.14646 11.8534 7.09621 11.8534 7.682 12.4392L9.56064 14.318L16.5 7.37879C17.0858 6.79301 18.0355 6.79301 18.6213 7.37879Z",fill:"currentColor"})),28===this.size&&i(o,null,i("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M21.7248 8.60863C22.4083 9.29205 22.4083 10.4001 21.7248 11.0835L12.3915 20.4167C11.7081 21.1001 10.6001 21.1001 9.91663 20.4167L6.48744 16.9873C5.80403 16.3039 5.80403 15.1959 6.48744 14.5125C7.17086 13.8291 8.2789 13.8291 8.96232 14.5125L11.1541 16.7044L19.25 8.60863C19.9334 7.92521 21.0414 7.92521 21.7248 8.60863Z",fill:"currentColor"})))}};c.style=":host{display:inline-flex}";const u=class{constructor(i){t(this,i),this.size=24}render(){const t=20===this.size?24:this.size,e=s("swirl-icon",`swirl-icon--size-${this.size}`);return i("svg",{class:e,fill:"none",height:this.size,part:"icon",viewBox:`0 0 ${t} ${t}`,width:this.size,xmlns:"http://www.w3.org/2000/svg"},16===this.size&&i(o,null,i("rect",{x:"9",y:"3",width:"2",height:"2",rx:"1",fill:"currentColor"}),i("rect",{x:"9",y:"7",width:"2",height:"2",rx:"1",fill:"currentColor"}),i("rect",{x:"9",y:"11",width:"2",height:"2",rx:"1",fill:"currentColor"}),i("rect",{x:"5",y:"3",width:"2",height:"2",rx:"1",fill:"currentColor"}),i("rect",{x:"5",y:"7",width:"2",height:"2",rx:"1",fill:"currentColor"}),i("rect",{x:"5",y:"11",width:"2",height:"2",rx:"1",fill:"currentColor"})),(20===this.size||24===this.size)&&i(o,null,i("rect",{x:"13.5",y:"4.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"}),i("rect",{x:"13.5",y:"10.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"}),i("rect",{x:"13.5",y:"16.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"}),i("rect",{x:"7.5",y:"4.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"}),i("rect",{x:"7.5",y:"10.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"}),i("rect",{x:"7.5",y:"16.5",width:"3",height:"3",rx:"1.5",fill:"currentColor"})),28===this.size&&i(o,null,i("rect",{x:"15.75",y:"5.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"}),i("rect",{x:"15.75",y:"12.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"}),i("rect",{x:"15.75",y:"19.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"}),i("rect",{x:"8.75",y:"5.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"}),i("rect",{x:"8.75",y:"12.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"}),i("rect",{x:"8.75",y:"19.25",width:"3.5",height:"3.5",rx:"1.75",fill:"currentColor"})))}};
2
- /**!
3
- * Sortable 1.15.0
4
- * @author RubaXa <trash@rubaxa.org>
5
- * @author owenm <owen23355@gmail.com>
6
- * @license MIT
7
- */
8
- function d(t,i){var o=Object.keys(t);if(Object.getOwnPropertySymbols){var e=Object.getOwnPropertySymbols(t);i&&(e=e.filter((function(i){return Object.getOwnPropertyDescriptor(t,i).enumerable}))),o.push.apply(o,e)}return o}function f(t){for(var i=1;i<arguments.length;i++){var o=null!=arguments[i]?arguments[i]:{};i%2?d(Object(o),!0).forEach((function(i){v(t,i,o[i])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):d(Object(o)).forEach((function(i){Object.defineProperty(t,i,Object.getOwnPropertyDescriptor(o,i))}))}return t}function m(t){return m="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},m(t)}function v(t,i,o){return i in t?Object.defineProperty(t,i,{value:o,enumerable:!0,configurable:!0,writable:!0}):t[i]=o,t}function p(){return p=Object.assign||function(t){for(var i=1;i<arguments.length;i++){var o=arguments[i];for(var e in o)Object.prototype.hasOwnProperty.call(o,e)&&(t[e]=o[e])}return t},p.apply(this,arguments)}function g(t,i){if(null==t)return{};var o,e,n=function(t,i){if(null==t)return{};var o,e,n={},r=Object.keys(t);for(e=0;e<r.length;e++)i.indexOf(o=r[e])>=0||(n[o]=t[o]);return n}(t,i);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(e=0;e<r.length;e++)i.indexOf(o=r[e])>=0||Object.prototype.propertyIsEnumerable.call(t,o)&&(n[o]=t[o])}return n}function w(t){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(t)}u.style=":host{display:inline-flex}";var b=w(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),x=w(/Edge/i),y=w(/firefox/i),_=w(/safari/i)&&!w(/chrome/i)&&!w(/android/i),E=w(/iP(ad|od|hone)/i),I=w(/chrome/i)&&w(/android/i),C={capture:!1,passive:!1};function S(t,i,o){t.addEventListener(i,o,!b&&C)}function k(t,i,o){t.removeEventListener(i,o,!b&&C)}function D(t,i){if(i){if(">"===i[0]&&(i=i.substring(1)),t)try{if(t.matches)return t.matches(i);if(t.msMatchesSelector)return t.msMatchesSelector(i);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(i)}catch(t){return!1}return!1}}function M(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function T(t,i,o,e){if(t){o=o||document;do{if(null!=i&&(">"===i[0]?t.parentNode===o&&D(t,i):D(t,i))||e&&t===o)return t;if(t===o)break}while(t=M(t))}return null}var O,z=/\s+/g;function A(t,i,o){if(t&&i)if(t.classList)t.classList[o?"add":"remove"](i);else{var e=(" "+t.className+" ").replace(z," ").replace(" "+i+" "," ");t.className=(e+(o?" "+i:"")).replace(z," ")}}function j(t,i,o){var e=t&&t.style;if(e){if(void 0===o)return document.defaultView&&document.defaultView.getComputedStyle?o=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(o=t.currentStyle),void 0===i?o:o[i];i in e||-1!==i.indexOf("webkit")||(i="-webkit-"+i),e[i]=o+("string"==typeof o?"":"px")}}function B(t,i){var o="";if("string"==typeof t)o=t;else do{var e=j(t,"transform");e&&"none"!==e&&(o=e+" "+o)}while(!i&&(t=t.parentNode));var n=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return n&&new n(o)}function L(t,i,o){if(t){var e=t.getElementsByTagName(i),n=0,r=e.length;if(o)for(;n<r;n++)o(e[n],n);return e}return[]}function $(){return document.scrollingElement||document.documentElement}function N(t,i,o,e,n){if(t.getBoundingClientRect||t===window){var r,s,l,a,h,c,u;if(t!==window&&t.parentNode&&t!==$()?(s=(r=t.getBoundingClientRect()).top,l=r.left,a=r.bottom,h=r.right,c=r.height,u=r.width):(s=0,l=0,a=window.innerHeight,h=window.innerWidth,c=window.innerHeight,u=window.innerWidth),(i||o)&&t!==window&&(n=n||t.parentNode,!b))do{if(n&&n.getBoundingClientRect&&("none"!==j(n,"transform")||o&&"static"!==j(n,"position"))){var d=n.getBoundingClientRect();s-=d.top+parseInt(j(n,"border-top-width")),l-=d.left+parseInt(j(n,"border-left-width")),a=s+r.height,h=l+r.width;break}}while(n=n.parentNode);if(e&&t!==window){var f=B(n||t),m=f&&f.a,v=f&&f.d;f&&(a=(s/=v)+(c/=v),h=(l/=m)+(u/=m))}return{top:s,left:l,bottom:a,right:h,width:u,height:c}}}function P(t,i,o){for(var e=G(t,!0),n=N(t)[i];e;){var r=N(e)[o];if(!("top"===o||"left"===o?n>=r:n<=r))return e;if(e===$())break;e=G(e,!1)}return!1}function F(t,i,o,e){for(var n=0,r=0,s=t.children;r<s.length;){if("none"!==s[r].style.display&&s[r]!==Kt.ghost&&(e||s[r]!==Kt.dragged)&&T(s[r],o.draggable,t,!1)){if(n===i)return s[r];n++}r++}return null}function H(t,i){for(var o=t.lastElementChild;o&&(o===Kt.ghost||"none"===j(o,"display")||i&&!D(o,i));)o=o.previousElementSibling;return o||null}function U(t,i){var o=0;if(!t||!t.parentNode)return-1;for(;t=t.previousElementSibling;)"TEMPLATE"===t.nodeName.toUpperCase()||t===Kt.clone||i&&!D(t,i)||o++;return o}function V(t){var i=0,o=0,e=$();if(t)do{var n=B(t);i+=t.scrollLeft*n.a,o+=t.scrollTop*n.d}while(t!==e&&(t=t.parentNode));return[i,o]}function G(t,i){if(!t||!t.getBoundingClientRect)return $();var o=t,e=!1;do{if(o.clientWidth<o.scrollWidth||o.clientHeight<o.scrollHeight){var n=j(o);if(o.clientWidth<o.scrollWidth&&("auto"==n.overflowX||"scroll"==n.overflowX)||o.clientHeight<o.scrollHeight&&("auto"==n.overflowY||"scroll"==n.overflowY)){if(!o.getBoundingClientRect||o===document.body)return $();if(e||i)return o;e=!0}}}while(o=o.parentNode);return $()}function Z(t,i){return Math.round(t.top)===Math.round(i.top)&&Math.round(t.left)===Math.round(i.left)&&Math.round(t.height)===Math.round(i.height)&&Math.round(t.width)===Math.round(i.width)}function K(t,i){return function(){if(!O){var o=arguments,e=this;1===o.length?t.call(e,o[0]):t.apply(e,o),O=setTimeout((function(){O=void 0}),i)}}}function W(t,i,o){t.scrollLeft+=i,t.scrollTop+=o}function Y(t){var i=window.Polymer,o=window.jQuery||window.Zepto;return i&&i.dom?i.dom(t).cloneNode(!0):o?o(t).clone(!0)[0]:t.cloneNode(!0)}var R="Sortable"+(new Date).getTime();var X=[],q={initializeByDefault:!0},J={mount:function(t){for(var i in q)q.hasOwnProperty(i)&&!(i in t)&&(t[i]=q[i]);X.forEach((function(i){if(i.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")})),X.push(t)},pluginEvent:function(t,i,o){var e=this;this.eventCanceled=!1,o.cancel=function(){e.eventCanceled=!0};var n=t+"Global";X.forEach((function(e){i[e.pluginName]&&(i[e.pluginName][n]&&i[e.pluginName][n](f({sortable:i},o)),i.options[e.pluginName]&&i[e.pluginName][t]&&i[e.pluginName][t](f({sortable:i},o)))}))},initializePlugins:function(t,i,o){for(var e in X.forEach((function(e){var n=e.pluginName;if(t.options[n]||e.initializeByDefault){var r=new e(t,i,t.options);r.sortable=t,r.options=t.options,t[n]=r,p(o,r.defaults)}})),t.options)if(t.options.hasOwnProperty(e)){var n=this.modifyOption(t,e,t.options[e]);void 0!==n&&(t.options[e]=n)}},getEventProperties:function(t,i){var o={};return X.forEach((function(e){"function"==typeof e.eventProperties&&p(o,e.eventProperties.call(i[e.pluginName],t))})),o},modifyOption:function(t,i,o){var e;return X.forEach((function(n){t[n.pluginName]&&n.optionListeners&&"function"==typeof n.optionListeners[i]&&(e=n.optionListeners[i].call(t[n.pluginName],o))})),e}},Q=["evt"],tt=function(t,i){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},e=o.evt,n=g(o,Q);J.pluginEvent.bind(Kt)(t,i,f({dragEl:ot,parentEl:et,ghostEl:nt,rootEl:rt,nextEl:st,lastDownEl:lt,cloneEl:at,cloneHidden:ht,dragStarted:_t,putSortable:vt,activeSortable:Kt.active,originalEvent:e,oldIndex:ct,oldDraggableIndex:dt,newIndex:ut,newDraggableIndex:ft,hideGhostForTarget:Ut,unhideGhostForTarget:Vt,cloneNowHidden:function(){ht=!0},cloneNowShown:function(){ht=!1},dispatchSortableEvent:function(t){it({sortable:i,name:t,originalEvent:e})}},n))};function it(t){!function(t){var i=t.sortable,o=t.rootEl,e=t.name,n=t.targetEl,r=t.cloneEl,s=t.toEl,l=t.fromEl,a=t.oldIndex,h=t.newIndex,c=t.oldDraggableIndex,u=t.newDraggableIndex,d=t.originalEvent,m=t.putSortable,v=t.extraEventProperties;if(i=i||o&&o[R]){var p,g=i.options,w="on"+e.charAt(0).toUpperCase()+e.substr(1);!window.CustomEvent||b||x?(p=document.createEvent("Event")).initEvent(e,!0,!0):p=new CustomEvent(e,{bubbles:!0,cancelable:!0}),p.to=s||o,p.from=l||o,p.item=n||o,p.clone=r,p.oldIndex=a,p.newIndex=h,p.oldDraggableIndex=c,p.newDraggableIndex=u,p.originalEvent=d,p.pullMode=m?m.lastPutMode:void 0;var y=f(f({},v),J.getEventProperties(e,i));for(var _ in y)p[_]=y[_];o&&o.dispatchEvent(p),g[w]&&g[w].call(i,p)}}(f({putSortable:vt,cloneEl:at,targetEl:ot,rootEl:rt,oldIndex:ct,oldDraggableIndex:dt,newIndex:ut,newDraggableIndex:ft},t))}var ot,et,nt,rt,st,lt,at,ht,ct,ut,dt,ft,mt,vt,pt,gt,wt,bt,xt,yt,_t,Et,It,Ct,St,kt=!1,Dt=!1,Mt=[],Tt=!1,Ot=!1,zt=[],At=!1,jt=[],Bt="undefined"!=typeof document,Lt=E,$t=x||b?"cssFloat":"float",Nt=Bt&&!I&&!E&&"draggable"in document.createElement("div"),Pt=function(){if(Bt){if(b)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto","auto"===t.style.pointerEvents}}(),Ft=function(t,i){var o=j(t),e=parseInt(o.width)-parseInt(o.paddingLeft)-parseInt(o.paddingRight)-parseInt(o.borderLeftWidth)-parseInt(o.borderRightWidth),n=F(t,0,i),r=F(t,1,i),s=n&&j(n),l=r&&j(r),a=s&&parseInt(s.marginLeft)+parseInt(s.marginRight)+N(n).width,h=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+N(r).width;return"flex"===o.display?"column"===o.flexDirection||"column-reverse"===o.flexDirection?"vertical":"horizontal":"grid"===o.display?o.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal":n&&s.float&&"none"!==s.float?!r||"both"!==l.clear&&l.clear!==("left"===s.float?"left":"right")?"horizontal":"vertical":n&&("block"===s.display||"flex"===s.display||"table"===s.display||"grid"===s.display||a>=e&&"none"===o[$t]||r&&"none"===o[$t]&&a+h>e)?"vertical":"horizontal"},Ht=function(t){function i(t,o){return function(e,n,r,s){if(null==t&&(o||e.options.group.name&&n.options.group.name&&e.options.group.name===n.options.group.name))return!0;if(null==t||!1===t)return!1;if(o&&"clone"===t)return t;if("function"==typeof t)return i(t(e,n,r,s),o)(e,n,r,s);var l=(o?e:n).options.group.name;return!0===t||"string"==typeof t&&t===l||t.join&&t.indexOf(l)>-1}}var o={},e=t.group;e&&"object"==m(e)||(e={name:e}),o.name=e.name,o.checkPull=i(e.pull,!0),o.checkPut=i(e.put),o.revertClone=e.revertClone,t.group=o},Ut=function(){!Pt&&nt&&j(nt,"display","none")},Vt=function(){!Pt&&nt&&j(nt,"display","")};Bt&&!I&&document.addEventListener("click",(function(t){if(Dt)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),Dt=!1,!1}),!0);var Gt=function(t){if(ot){var i=(n=(t=t.touches?t.touches[0]:t).clientX,r=t.clientY,Mt.some((function(t){var i=t[R].options.emptyInsertThreshold;if(i&&!H(t)){var o=N(t);return n>=o.left-i&&n<=o.right+i&&r>=o.top-i&&r<=o.bottom+i?s=t:void 0}})),s);if(i){var o={};for(var e in t)t.hasOwnProperty(e)&&(o[e]=t[e]);o.target=o.rootEl=i,o.preventDefault=void 0,o.stopPropagation=void 0,i[R]._onDragOver(o)}}var n,r,s},Zt=function(t){ot&&ot.parentNode[R]._isOutsideThisEl(t.target)};function Kt(t,i){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=i=p({},i),t[R]=this;var o,e,n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Ft(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,i){t.setData("Text",i.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!==Kt.supportPointer&&"PointerEvent"in window&&!_,emptyInsertThreshold:5};for(var r in J.initializePlugins(this,t,n),n)!(r in i)&&(i[r]=n[r]);for(var s in Ht(i),this)"_"===s.charAt(0)&&"function"==typeof this[s]&&(this[s]=this[s].bind(this));this.nativeDraggable=!i.forceFallback&&Nt,this.nativeDraggable&&(this.options.touchStartThreshold=1),i.supportPointer?S(t,"pointerdown",this._onTapStart):(S(t,"mousedown",this._onTapStart),S(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(S(t,"dragover",this),S(t,"dragenter",this)),Mt.push(this.el),i.store&&i.store.get&&this.sort(i.store.get(this)||[]),p(this,(e=[],{captureAnimationState:function(){e=[],this.options.animation&&[].slice.call(this.el.children).forEach((function(t){if("none"!==j(t,"display")&&t!==Kt.ghost){e.push({target:t,rect:N(t)});var i=f({},e[e.length-1].rect);if(t.thisAnimationDuration){var o=B(t,!0);o&&(i.top-=o.f,i.left-=o.e)}t.fromRect=i}}))},addAnimationState:function(t){e.push(t)},removeAnimationState:function(t){e.splice(function(t,i){for(var o in t)if(t.hasOwnProperty(o))for(var e in i)if(i.hasOwnProperty(e)&&i[e]===t[o][e])return Number(o);return-1}(e,{target:t}),1)},animateAll:function(t){var i=this;if(!this.options.animation)return clearTimeout(o),void("function"==typeof t&&t());var n=!1,r=0;e.forEach((function(t){var o=0,e=t.target,s=e.fromRect,l=N(e),a=e.prevFromRect,h=e.prevToRect,c=t.rect,u=B(e,!0);u&&(l.top-=u.f,l.left-=u.e),e.toRect=l,e.thisAnimationDuration&&Z(a,l)&&!Z(s,l)&&(c.top-l.top)/(c.left-l.left)==(s.top-l.top)/(s.left-l.left)&&(o=function(t,i,o,e){return Math.sqrt(Math.pow(i.top-t.top,2)+Math.pow(i.left-t.left,2))/Math.sqrt(Math.pow(i.top-o.top,2)+Math.pow(i.left-o.left,2))*e.animation}(c,a,h,i.options)),Z(l,s)||(e.prevFromRect=s,e.prevToRect=l,o||(o=i.options.animation),i.animate(e,c,l,o)),o&&(n=!0,r=Math.max(r,o),clearTimeout(e.animationResetTimer),e.animationResetTimer=setTimeout((function(){e.animationTime=0,e.prevFromRect=null,e.fromRect=null,e.prevToRect=null,e.thisAnimationDuration=null}),o),e.thisAnimationDuration=o)})),clearTimeout(o),n?o=setTimeout((function(){"function"==typeof t&&t()}),r):"function"==typeof t&&t(),e=[]},animate:function(t,i,o,e){if(e){j(t,"transition",""),j(t,"transform","");var n=B(this.el),r=(i.left-o.left)/(n&&n.a||1),s=(i.top-o.top)/(n&&n.d||1);t.animatingX=!!r,t.animatingY=!!s,j(t,"transform","translate3d("+r+"px,"+s+"px,0)"),this.forRepaintDummy=function(t){return t.offsetWidth}(t),j(t,"transition","transform "+e+"ms"+(this.options.easing?" "+this.options.easing:"")),j(t,"transform","translate3d(0,0,0)"),"number"==typeof t.animated&&clearTimeout(t.animated),t.animated=setTimeout((function(){j(t,"transition",""),j(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1}),e)}}}))}function Wt(t,i,o,e,n,r,s,l){var a,h,c=t[R],u=c.options.onMove;return!window.CustomEvent||b||x?(a=document.createEvent("Event")).initEvent("move",!0,!0):a=new CustomEvent("move",{bubbles:!0,cancelable:!0}),a.to=i,a.from=t,a.dragged=o,a.draggedRect=e,a.related=n||i,a.relatedRect=r||N(i),a.willInsertAfter=l,a.originalEvent=s,t.dispatchEvent(a),u&&(h=u.call(c,a,s)),h}function Yt(t){t.draggable=!1}function Rt(){At=!1}function Xt(t){for(var i=t.tagName+t.className+t.src+t.href+t.textContent,o=i.length,e=0;o--;)e+=i.charCodeAt(o);return e.toString(36)}function qt(t){return setTimeout(t,0)}function Jt(t){return clearTimeout(t)}Kt.prototype={constructor:Kt,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(Et=null)},_getDirection:function(t,i){return"function"==typeof this.options.direction?this.options.direction.call(this,t,i,ot):this.options.direction},_onTapStart:function(t){if(t.cancelable){var i=this,o=this.el,e=this.options,n=e.preventOnFilter,r=t.type,s=t.touches&&t.touches[0]||t.pointerType&&"touch"===t.pointerType&&t,l=(s||t).target,a=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||l,h=e.filter;if(function(t){jt.length=0;for(var i=t.getElementsByTagName("input"),o=i.length;o--;){var e=i[o];e.checked&&jt.push(e)}}(o),!ot&&!(/mousedown|pointerdown/.test(r)&&0!==t.button||e.disabled)&&!a.isContentEditable&&(this.nativeDraggable||!_||!l||"SELECT"!==l.tagName.toUpperCase())&&!((l=T(l,e.draggable,o,!1))&&l.animated||lt===l)){if(ct=U(l),dt=U(l,e.draggable),"function"==typeof h){if(h.call(this,t,l,this))return it({sortable:i,rootEl:a,name:"filter",targetEl:l,toEl:o,fromEl:o}),tt("filter",i,{evt:t}),void(n&&t.cancelable&&t.preventDefault())}else if(h&&(h=h.split(",").some((function(e){if(e=T(a,e.trim(),o,!1))return it({sortable:i,rootEl:e,name:"filter",targetEl:l,fromEl:o,toEl:o}),tt("filter",i,{evt:t}),!0}))))return void(n&&t.cancelable&&t.preventDefault());e.handle&&!T(a,e.handle,o,!1)||this._prepareDragStart(t,s,l)}}},_prepareDragStart:function(t,i,o){var e,n=this,r=n.el,s=n.options,l=r.ownerDocument;if(o&&!ot&&o.parentNode===r){var a=N(o);if(rt=r,et=(ot=o).parentNode,st=ot.nextSibling,lt=o,mt=s.group,Kt.dragged=ot,xt=(pt={target:ot,clientX:(i||t).clientX,clientY:(i||t).clientY}).clientX-a.left,yt=pt.clientY-a.top,this._lastX=(i||t).clientX,this._lastY=(i||t).clientY,ot.style["will-change"]="all",e=function(){tt("delayEnded",n,{evt:t}),Kt.eventCanceled?n._onDrop():(n._disableDelayedDragEvents(),!y&&n.nativeDraggable&&(ot.draggable=!0),n._triggerDragStart(t,i),it({sortable:n,name:"choose",originalEvent:t}),A(ot,s.chosenClass,!0))},s.ignore.split(",").forEach((function(t){L(ot,t.trim(),Yt)})),S(l,"dragover",Gt),S(l,"mousemove",Gt),S(l,"touchmove",Gt),S(l,"mouseup",n._onDrop),S(l,"touchend",n._onDrop),S(l,"touchcancel",n._onDrop),y&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ot.draggable=!0),tt("delayStart",this,{evt:t}),!s.delay||s.delayOnTouchOnly&&!i||this.nativeDraggable&&(x||b))e();else{if(Kt.eventCanceled)return void this._onDrop();S(l,"mouseup",n._disableDelayedDrag),S(l,"touchend",n._disableDelayedDrag),S(l,"touchcancel",n._disableDelayedDrag),S(l,"mousemove",n._delayedDragTouchMoveHandler),S(l,"touchmove",n._delayedDragTouchMoveHandler),s.supportPointer&&S(l,"pointermove",n._delayedDragTouchMoveHandler),n._dragStartTimer=setTimeout(e,s.delay)}}},_delayedDragTouchMoveHandler:function(t){var i=t.touches?t.touches[0]:t;Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ot&&Yt(ot),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;k(t,"mouseup",this._disableDelayedDrag),k(t,"touchend",this._disableDelayedDrag),k(t,"touchcancel",this._disableDelayedDrag),k(t,"mousemove",this._delayedDragTouchMoveHandler),k(t,"touchmove",this._delayedDragTouchMoveHandler),k(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,i){i=i||"touch"==t.pointerType&&t,!this.nativeDraggable||i?S(document,this.options.supportPointer?"pointermove":i?"touchmove":"mousemove",this._onTouchMove):(S(ot,"dragend",this),S(rt,"dragstart",this._onDragStart));try{document.selection?qt((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(t){}},_dragStarted:function(t,i){if(kt=!1,rt&&ot){tt("dragStarted",this,{evt:i}),this.nativeDraggable&&S(document,"dragover",Zt);var o=this.options;!t&&A(ot,o.dragClass,!1),A(ot,o.ghostClass,!0),Kt.active=this,t&&this._appendGhost(),it({sortable:this,name:"start",originalEvent:i})}else this._nulling()},_emulateDragOver:function(){if(gt){this._lastX=gt.clientX,this._lastY=gt.clientY,Ut();for(var t=document.elementFromPoint(gt.clientX,gt.clientY),i=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(gt.clientX,gt.clientY))!==i;)i=t;if(ot.parentNode[R]._isOutsideThisEl(t),i)do{if(i[R]&&i[R]._onDragOver({clientX:gt.clientX,clientY:gt.clientY,target:t,rootEl:i})&&!this.options.dragoverBubble)break;t=i}while(i=i.parentNode);Vt()}},_onTouchMove:function(t){if(pt){var i=this.options,o=i.fallbackTolerance,e=i.fallbackOffset,n=t.touches?t.touches[0]:t,r=nt&&B(nt,!0),s=nt&&r&&r.a,l=nt&&r&&r.d,a=Lt&&St&&V(St),h=(n.clientX-pt.clientX+e.x)/(s||1)+(a?a[0]-zt[0]:0)/(s||1),c=(n.clientY-pt.clientY+e.y)/(l||1)+(a?a[1]-zt[1]:0)/(l||1);if(!Kt.active&&!kt){if(o&&Math.max(Math.abs(n.clientX-this._lastX),Math.abs(n.clientY-this._lastY))<o)return;this._onDragStart(t,!0)}if(nt){r?(r.e+=h-(wt||0),r.f+=c-(bt||0)):r={a:1,b:0,c:0,d:1,e:h,f:c};var u="matrix(".concat(r.a,",").concat(r.b,",").concat(r.c,",").concat(r.d,",").concat(r.e,",").concat(r.f,")");j(nt,"webkitTransform",u),j(nt,"mozTransform",u),j(nt,"msTransform",u),j(nt,"transform",u),wt=h,bt=c,gt=n}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!nt){var t=this.options.fallbackOnBody?document.body:rt,i=N(ot,!0,Lt,!0,t),o=this.options;if(Lt){for(St=t;"static"===j(St,"position")&&"none"===j(St,"transform")&&St!==document;)St=St.parentNode;St!==document.body&&St!==document.documentElement?(St===document&&(St=$()),i.top+=St.scrollTop,i.left+=St.scrollLeft):St=$(),zt=V(St)}A(nt=ot.cloneNode(!0),o.ghostClass,!1),A(nt,o.fallbackClass,!0),A(nt,o.dragClass,!0),j(nt,"transition",""),j(nt,"transform",""),j(nt,"box-sizing","border-box"),j(nt,"margin",0),j(nt,"top",i.top),j(nt,"left",i.left),j(nt,"width",i.width),j(nt,"height",i.height),j(nt,"opacity","0.8"),j(nt,"position",Lt?"absolute":"fixed"),j(nt,"zIndex","100000"),j(nt,"pointerEvents","none"),Kt.ghost=nt,t.appendChild(nt),j(nt,"transform-origin",xt/parseInt(nt.style.width)*100+"% "+yt/parseInt(nt.style.height)*100+"%")}},_onDragStart:function(t,i){var o=this,e=t.dataTransfer,n=o.options;tt("dragStart",this,{evt:t}),Kt.eventCanceled?this._onDrop():(tt("setupClone",this),Kt.eventCanceled||((at=Y(ot)).removeAttribute("id"),at.draggable=!1,at.style["will-change"]="",this._hideClone(),A(at,this.options.chosenClass,!1),Kt.clone=at),o.cloneId=qt((function(){tt("clone",o),Kt.eventCanceled||(o.options.removeCloneOnHide||rt.insertBefore(at,ot),o._hideClone(),it({sortable:o,name:"clone"}))})),!i&&A(ot,n.dragClass,!0),i?(Dt=!0,o._loopId=setInterval(o._emulateDragOver,50)):(k(document,"mouseup",o._onDrop),k(document,"touchend",o._onDrop),k(document,"touchcancel",o._onDrop),e&&(e.effectAllowed="move",n.setData&&n.setData.call(o,e,ot)),S(document,"drop",o),j(ot,"transform","translateZ(0)")),kt=!0,o._dragStartId=qt(o._dragStarted.bind(o,i,t)),S(document,"selectstart",o),_t=!0,_&&j(document.body,"user-select","none"))},_onDragOver:function(t){var i,o,e,n,r=this.el,s=t.target,l=this.options,a=l.group,h=Kt.active,c=mt===a,u=l.sort,d=vt||h,m=this,v=!1;if(!At){if(void 0!==t.preventDefault&&t.cancelable&&t.preventDefault(),s=T(s,l.draggable,r,!0),O("dragOver"),Kt.eventCanceled)return v;if(ot.contains(t.target)||s.animated&&s.animatingX&&s.animatingY||m._ignoreWhileAnimating===s)return B(!1);if(Dt=!1,h&&!l.disabled&&(c?u||(e=et!==rt):vt===this||(this.lastPutMode=mt.checkPull(this,h,ot,t))&&a.checkPut(this,h,ot,t))){if(n="vertical"===this._getDirection(t,s),i=N(ot),O("dragOverValid"),Kt.eventCanceled)return v;if(e)return et=rt,z(),this._hideClone(),O("revert"),Kt.eventCanceled||(st?rt.insertBefore(ot,st):rt.appendChild(ot)),B(!0);var p=H(r,l.draggable);if(!p||function(t,i,o){var e=N(H(o.el,o.options.draggable));return i?t.clientX>e.right+10||t.clientX<=e.right&&t.clientY>e.bottom&&t.clientX>=e.left:t.clientX>e.right&&t.clientY>e.top||t.clientX<=e.right&&t.clientY>e.bottom+10}(t,n,this)&&!p.animated){if(p===ot)return B(!1);if(p&&r===t.target&&(s=p),s&&(o=N(s)),!1!==Wt(rt,r,ot,i,s,o,t,!!s))return z(),p&&p.nextSibling?r.insertBefore(ot,p.nextSibling):r.appendChild(ot),et=r,L(),B(!0)}else if(p&&function(t,i,o){var e=N(F(o.el,0,o.options,!0));return i?t.clientX<e.left-10||t.clientY<e.top&&t.clientX<e.right:t.clientY<e.top-10||t.clientY<e.bottom&&t.clientX<e.left}(t,n,this)){var g=F(r,0,l,!0);if(g===ot)return B(!1);if(o=N(s=g),!1!==Wt(rt,r,ot,i,s,o,t,!1))return z(),r.insertBefore(ot,g),et=r,L(),B(!0)}else if(s.parentNode===r){o=N(s);var w,b,x,y=ot.parentNode!==r,_=!function(t,i,o){var e=o?t.left:t.top,n=o?i.left:i.top;return e===n||(o?t.right:t.bottom)===(o?i.right:i.bottom)||e+(o?t.width:t.height)/2===n+(o?i.width:i.height)/2}(ot.animated&&ot.toRect||i,s.animated&&s.toRect||o,n),E=n?"top":"left",I=P(s,"top","top")||P(ot,"top","top"),C=I?I.scrollTop:void 0;if(Et!==s&&(b=o[E],Tt=!1,Ot=!_&&l.invertSwap||y),w=function(t,i,o,e,n,r,s,l){var a=e?t.clientY:t.clientX,h=e?o.height:o.width,c=e?o.top:o.left,u=e?o.bottom:o.right,d=!1;if(!s)if(l&&Ct<h*n){if(!Tt&&(1===It?a>c+h*r/2:a<u-h*r/2)&&(Tt=!0),Tt)d=!0;else if(1===It?a<c+Ct:a>u-Ct)return-It}else if(a>c+h*(1-n)/2&&a<u-h*(1-n)/2)return function(t){return U(ot)<U(t)?1:-1}(i);return(d=d||s)&&(a<c+h*r/2||a>u-h*r/2)?a>c+h/2?1:-1:0}(t,s,o,n,_?1:l.swapThreshold,null==l.invertedSwapThreshold?l.swapThreshold:l.invertedSwapThreshold,Ot,Et===s),0!==w){var S=U(ot);do{x=et.children[S-=w]}while(x&&("none"===j(x,"display")||x===nt))}if(0===w||x===s)return B(!1);Et=s,It=w;var k=s.nextElementSibling,D=!1,M=Wt(rt,r,ot,i,s,o,t,D=1===w);if(!1!==M)return 1!==M&&-1!==M||(D=1===M),At=!0,setTimeout(Rt,30),z(),D&&!k?r.appendChild(ot):s.parentNode.insertBefore(ot,D?k:s),I&&W(I,0,C-I.scrollTop),et=ot.parentNode,void 0===b||Ot||(Ct=Math.abs(b-N(s)[E])),L(),B(!0)}if(r.contains(ot))return B(!1)}return!1}function O(l,a){tt(l,m,f({evt:t,isOwner:c,axis:n?"vertical":"horizontal",revert:e,dragRect:i,targetRect:o,canSort:u,fromSortable:d,target:s,completed:B,onMove:function(o,e){return Wt(rt,r,ot,i,o,N(o),t,e)},changed:L},a))}function z(){O("dragOverAnimationCapture"),m.captureAnimationState(),m!==d&&d.captureAnimationState()}function B(i){return O("dragOverCompleted",{insertion:i}),i&&(c?h._hideClone():h._showClone(m),m!==d&&(A(ot,vt?vt.options.ghostClass:h.options.ghostClass,!1),A(ot,l.ghostClass,!0)),vt!==m&&m!==Kt.active?vt=m:m===Kt.active&&vt&&(vt=null),d===m&&(m._ignoreWhileAnimating=s),m.animateAll((function(){O("dragOverAnimationComplete"),m._ignoreWhileAnimating=null})),m!==d&&(d.animateAll(),d._ignoreWhileAnimating=null)),(s===ot&&!ot.animated||s===r&&!s.animated)&&(Et=null),l.dragoverBubble||t.rootEl||s===document||(ot.parentNode[R]._isOutsideThisEl(t.target),!i&&Gt(t)),!l.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),v=!0}function L(){ut=U(ot),ft=U(ot,l.draggable),it({sortable:m,name:"change",toEl:r,newIndex:ut,newDraggableIndex:ft,originalEvent:t})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){k(document,"mousemove",this._onTouchMove),k(document,"touchmove",this._onTouchMove),k(document,"pointermove",this._onTouchMove),k(document,"dragover",Gt),k(document,"mousemove",Gt),k(document,"touchmove",Gt)},_offUpEvents:function(){var t=this.el.ownerDocument;k(t,"mouseup",this._onDrop),k(t,"touchend",this._onDrop),k(t,"pointerup",this._onDrop),k(t,"touchcancel",this._onDrop),k(document,"selectstart",this)},_onDrop:function(t){var i=this.el,o=this.options;ut=U(ot),ft=U(ot,o.draggable),tt("drop",this,{evt:t}),et=ot&&ot.parentNode,ut=U(ot),ft=U(ot,o.draggable),Kt.eventCanceled||(kt=!1,Ot=!1,Tt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Jt(this.cloneId),Jt(this._dragStartId),this.nativeDraggable&&(k(document,"drop",this),k(i,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),_&&j(document.body,"user-select",""),j(ot,"transform",""),t&&(_t&&(t.cancelable&&t.preventDefault(),!o.dropBubble&&t.stopPropagation()),nt&&nt.parentNode&&nt.parentNode.removeChild(nt),(rt===et||vt&&"clone"!==vt.lastPutMode)&&at&&at.parentNode&&at.parentNode.removeChild(at),ot&&(this.nativeDraggable&&k(ot,"dragend",this),Yt(ot),ot.style["will-change"]="",_t&&!kt&&A(ot,vt?vt.options.ghostClass:this.options.ghostClass,!1),A(ot,this.options.chosenClass,!1),it({sortable:this,name:"unchoose",toEl:et,newIndex:null,newDraggableIndex:null,originalEvent:t}),rt!==et?(ut>=0&&(it({rootEl:et,name:"add",toEl:et,fromEl:rt,originalEvent:t}),it({sortable:this,name:"remove",toEl:et,originalEvent:t}),it({rootEl:et,name:"sort",toEl:et,fromEl:rt,originalEvent:t}),it({sortable:this,name:"sort",toEl:et,originalEvent:t})),vt&&vt.save()):ut!==ct&&ut>=0&&(it({sortable:this,name:"update",toEl:et,originalEvent:t}),it({sortable:this,name:"sort",toEl:et,originalEvent:t})),Kt.active&&(null!=ut&&-1!==ut||(ut=ct,ft=dt),it({sortable:this,name:"end",toEl:et,originalEvent:t}),this.save())))),this._nulling()},_nulling:function(){tt("nulling",this),rt=ot=et=nt=st=at=lt=ht=pt=gt=_t=ut=ft=ct=dt=Et=It=vt=mt=Kt.dragged=Kt.ghost=Kt.clone=Kt.active=null,jt.forEach((function(t){t.checked=!0})),jt.length=wt=bt=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":ot&&(this._onDragOver(t),function(t){t.dataTransfer&&(t.dataTransfer.dropEffect="move"),t.cancelable&&t.preventDefault()}(t));break;case"selectstart":t.preventDefault()}},toArray:function(){for(var t,i=[],o=this.el.children,e=0,n=o.length,r=this.options;e<n;e++)T(t=o[e],r.draggable,this.el,!1)&&i.push(t.getAttribute(r.dataIdAttr)||Xt(t));return i},sort:function(t,i){var o={},e=this.el;this.toArray().forEach((function(t,i){var n=e.children[i];T(n,this.options.draggable,e,!1)&&(o[t]=n)}),this),i&&this.captureAnimationState(),t.forEach((function(t){o[t]&&(e.removeChild(o[t]),e.appendChild(o[t]))})),i&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,i){return T(t,i||this.options.draggable,this.el,!1)},option:function(t,i){var o=this.options;if(void 0===i)return o[t];var e=J.modifyOption(this,t,i);o[t]=void 0!==e?e:i,"group"===t&&Ht(o)},destroy:function(){tt("destroy",this);var t=this.el;t[R]=null,k(t,"mousedown",this._onTapStart),k(t,"touchstart",this._onTapStart),k(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(k(t,"dragover",this),k(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),(function(t){t.removeAttribute("draggable")})),this._onDrop(),this._disableDelayedDragEvents(),Mt.splice(Mt.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!ht){if(tt("hideClone",this),Kt.eventCanceled)return;j(at,"display","none"),this.options.removeCloneOnHide&&at.parentNode&&at.parentNode.removeChild(at),ht=!0}},_showClone:function(t){if("clone"===t.lastPutMode){if(ht){if(tt("showClone",this),Kt.eventCanceled)return;ot.parentNode!=rt||this.options.group.revertClone?st?rt.insertBefore(at,st):rt.appendChild(at):rt.insertBefore(at,ot),this.options.group.revertClone&&this.animate(ot,at),j(at,"display",""),ht=!1}}else this._hideClone()}},Bt&&S(document,"touchmove",(function(t){(Kt.active||kt)&&t.cancelable&&t.preventDefault()})),Kt.utils={on:S,off:k,css:j,find:L,is:function(t,i){return!!T(t,i,t,!1)},extend:function(t,i){if(t&&i)for(var o in i)i.hasOwnProperty(o)&&(t[o]=i[o]);return t},throttle:K,closest:T,toggleClass:A,clone:Y,index:U,nextTick:qt,cancelNextTick:Jt,detectDirection:Ft,getChild:F},Kt.get=function(t){return t[R]},Kt.mount=function(){for(var t=arguments.length,i=new Array(t),o=0;o<t;o++)i[o]=arguments[o];i[0].constructor===Array&&(i=i[0]),i.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&&(Kt.utils=f(f({},Kt.utils),t.utils)),J.mount(t)}))},Kt.create=function(t,i){return new Kt(t,i)},Kt.version="1.15.0";var Qt,ti,ii,oi,ei,ni,ri=[],si=!1;function li(){ri.forEach((function(t){clearInterval(t.pid)})),ri=[]}function ai(){clearInterval(ni)}var hi=K((function(t,i,o,e){if(i.scroll){var n,r=(t.touches?t.touches[0]:t).clientX,s=(t.touches?t.touches[0]:t).clientY,l=i.scrollSensitivity,a=i.scrollSpeed,h=$(),c=!1;ti!==o&&(ti=o,li(),n=i.scrollFn,!0===(Qt=i.scroll)&&(Qt=G(o,!0)));var u=0,d=Qt;do{var f=d,m=N(f),v=m.top,p=m.bottom,g=m.left,w=m.right,b=m.width,x=m.height,y=void 0,_=void 0,E=f.scrollWidth,I=f.scrollHeight,C=j(f),S=f.scrollLeft,k=f.scrollTop;f===h?(y=b<E&&("auto"===C.overflowX||"scroll"===C.overflowX||"visible"===C.overflowX),_=x<I&&("auto"===C.overflowY||"scroll"===C.overflowY||"visible"===C.overflowY)):(y=b<E&&("auto"===C.overflowX||"scroll"===C.overflowX),_=x<I&&("auto"===C.overflowY||"scroll"===C.overflowY));var D=y&&(Math.abs(w-r)<=l&&S+b<E)-(Math.abs(g-r)<=l&&!!S),M=_&&(Math.abs(p-s)<=l&&k+x<I)-(Math.abs(v-s)<=l&&!!k);if(!ri[u])for(var T=0;T<=u;T++)ri[T]||(ri[T]={});ri[u].vx==D&&ri[u].vy==M&&ri[u].el===f||(ri[u].el=f,ri[u].vx=D,ri[u].vy=M,clearInterval(ri[u].pid),0==D&&0==M||(c=!0,ri[u].pid=setInterval(function(){e&&0===this.layer&&Kt.active._onTouchMove(ei);var i=ri[this.layer].vy?ri[this.layer].vy*a:0,o=ri[this.layer].vx?ri[this.layer].vx*a:0;"function"==typeof n&&"continue"!==n.call(Kt.dragged.parentNode[R],o,i,t,ei,ri[this.layer].el)||W(ri[this.layer].el,o,i)}.bind({layer:u}),24))),u++}while(i.bubbleScroll&&d!==h&&(d=G(d,!1)));si=c}}),30),ci=function(t){var i=t.originalEvent,o=t.putSortable,e=t.dragEl,n=t.dispatchSortableEvent,r=t.unhideGhostForTarget;if(i){var s=o||t.activeSortable;(0,t.hideGhostForTarget)();var l=i.changedTouches&&i.changedTouches.length?i.changedTouches[0]:i,a=document.elementFromPoint(l.clientX,l.clientY);r(),s&&!s.el.contains(a)&&(n("spill"),this.onSpill({dragEl:e,putSortable:o}))}};function ui(){}function di(){}ui.prototype={startIndex:null,dragStart:function(t){this.startIndex=t.oldDraggableIndex},onSpill:function(t){var i=t.dragEl,o=t.putSortable;this.sortable.captureAnimationState(),o&&o.captureAnimationState();var e=F(this.sortable.el,this.startIndex,this.options);e?this.sortable.el.insertBefore(i,e):this.sortable.el.appendChild(i),this.sortable.animateAll(),o&&o.animateAll()},drop:ci},p(ui,{pluginName:"revertOnSpill"}),di.prototype={onSpill:function(t){var i=t.dragEl,o=t.putSortable||this.sortable;o.captureAnimationState(),i.parentNode&&i.parentNode.removeChild(i),o.animateAll()},drop:ci},p(di,{pluginName:"removeOnSpill"}),Kt.mount(new function(){function t(){for(var t in this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)"_"===t.charAt(0)&&"function"==typeof this[t]&&(this[t]=this[t].bind(this))}return t.prototype={dragStarted:function(t){var i=t.originalEvent;this.sortable.nativeDraggable?S(document,"dragover",this._handleAutoScroll):S(document,this.options.supportPointer?"pointermove":i.touches?"touchmove":"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var i=t.originalEvent;this.options.dragOverBubble||i.rootEl||this._handleAutoScroll(i)},drop:function(){this.sortable.nativeDraggable?k(document,"dragover",this._handleAutoScroll):(k(document,"pointermove",this._handleFallbackAutoScroll),k(document,"touchmove",this._handleFallbackAutoScroll),k(document,"mousemove",this._handleFallbackAutoScroll)),ai(),li(),clearTimeout(O),O=void 0},nulling:function(){ei=ti=Qt=si=ni=ii=oi=null,ri.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(t,i){var o=this,e=(t.touches?t.touches[0]:t).clientX,n=(t.touches?t.touches[0]:t).clientY,r=document.elementFromPoint(e,n);if(ei=t,i||this.options.forceAutoScrollFallback||x||b||_){hi(t,this.options,r,i);var s=G(r,!0);!si||ni&&e===ii&&n===oi||(ni&&ai(),ni=setInterval((function(){var r=G(document.elementFromPoint(e,n),!0);r!==s&&(s=r,li()),hi(t,o.options,r,i)}),10),ii=e,oi=n)}else{if(!this.options.bubbleScroll||G(r,!0)===$())return void li();hi(t,this.options,G(r,!1),!1)}}},p(t,{pluginName:"scroll",initializeByDefault:!0})}),Kt.mount(di,ui);const fi=class{constructor(i){t(this,i),this.itemDrop=e(this,"itemDrop",7),this.valueChange=e(this,"valueChange",7),this.onFocus=async()=>{await new Promise((t=>setTimeout(t))),Boolean(this.focusedItem)?this.focusItem(this.getActiveItemIndex()):this.focusItem(0)},this.onClick=t=>{t.preventDefault();const i=t.target,o=null==i?void 0:i.closest("swirl-option-list-item"),e=t.composedPath()[0],n=Boolean(l(e,'[role="option"]'));Boolean(o)&&n?this.selectItem(this.items.findIndex((t=>t.value===o.value))):t.preventDefault()},this.onKeyDown=t=>{if("ArrowDown"===t.code)t.preventDefault(),Boolean(this.dragging)?this.moveDraggedItemDown():this.focusNextItem();else if("ArrowUp"===t.code)t.preventDefault(),Boolean(this.dragging)?this.moveDraggedItemUp():this.focusPreviousItem();else if("Space"===t.code||"Enter"===t.code){const i=t.composedPath()[0];if(!Boolean(l(i,'[role="option"]')))return;t.preventDefault(),Boolean(this.dragging)?this.stopDrag(this.dragging):this.selectFocusedItem()}else"Home"===t.code?(t.preventDefault(),this.focusItem(0)):"End"===t.code?(t.preventDefault(),this.focusItem(this.items.length-1)):"KeyA"===t.code&&(t.metaKey||t.ctrlKey)&&this.multiSelect?(t.preventDefault(),this.selectAllItems()):"Tab"===t.code&&Boolean(this.dragging)&&t.preventDefault()},this.toggleDrag=t=>{const i=t.detail;Boolean(this.dragging)?this.stopDrag(i):this.startDrag(i)},this.startDrag=t=>{this.dragging=t,this.draggingStartIndex=this.getItemIndex(this.dragging),t.setAttribute("dragging","true");const i=this.getItemIndex(this.dragging);this.focusItem(i),this.assistiveText=this.assistiveTextItemGrabbed},this.stopDrag=t=>{this.dragging=void 0,t.removeAttribute("dragging");const i=this.getActiveItemIndex();this.assistiveText=`${this.assistiveTextItemMoved} ${i+1}`,this.itemDrop.emit({oldIndex:this.draggingStartIndex,newIndex:i}),this.draggingStartIndex=void 0},this.allowDrag=void 0,this.assistiveTextItemGrabbed="Item grabbed. Use arrow keys to move item up or down. Use spacebar to save position.",this.assistiveTextItemMoving="Current position:",this.assistiveTextItemMoved="Item moved. New position:",this.disabled=void 0,this.label=void 0,this.optionListId=void 0,this.multiSelect=void 0,this.value=[],this.assistiveText=void 0}componentDidLoad(){this.updateItems(),this.observeSlotChanges(),this.setItemAllowDragState(),this.setItemDisabledState(),this.setItemContext(),this.syncItemsWithValue(),this.setupDragDrop()}disconnectedCallback(){var t,i;null===(t=this.observer)||void 0===t||t.disconnect(),null===(i=this.sortable)||void 0===i||i.destroy()}watchAllowDrag(){this.setItemAllowDragState(),this.setupDragDrop()}watchDisabled(){this.setItemDisabledState()}watchMultiSelect(){this.setItemContext()}watchValue(){this.syncItemsWithValue()}observeSlotChanges(){this.observer=new MutationObserver((()=>{this.updateItems()})),this.observer.observe(this.listboxEl,{childList:!0})}updateItems(){this.items=a(this.el,"swirl-option-list-item")}setItemDisabledState(){this.items.forEach((t=>t.disabled=this.disabled))}setItemContext(){this.multiSelect?this.items.forEach((t=>t.context="multi-select")):(this.items.forEach((t=>t.context="single-select")),this.value.length>1&&this.updateValue([this.value[0]]))}setupDragDrop(){Boolean(this.sortable)&&this.sortable.destroy(),this.allowDrag&&(this.sortable=Kt.create(this.listboxEl,{animation:150,draggable:"swirl-option-list-item",handle:".option-list-item__drag-handle",onEnd:t=>{this.itemDrop.emit({oldIndex:t.oldIndex,newIndex:t.newIndex})}}))}setItemAllowDragState(){if(this.allowDrag&&!this.multiSelect)return void console.error("[SwirlOptionList] Drag can only be allowed for multi select lists.");const t=a(this.el,"swirl-option-list-section");this.allowDrag&&t.length>0?console.error("[SwirlOptionList] Drag can only be allowed for lists without sections."):this.items.forEach(this.allowDrag?t=>{t.setAttribute("allow-drag","true"),t.addEventListener("toggleDrag",this.toggleDrag)}:t=>{t.removeAttribute("allow-drag"),t.removeEventListener("toggleDrag",this.toggleDrag)})}selectItem(t){if(this.disabled)return;const i=this.items[t];if(i.disabled)return;const o=this.value.includes(i.value);this.multiSelect||(this.value=[]),this.updateValue(o?this.value.filter((t=>t!==i.value)):[...this.value,i.value])}updateValue(t){this.value=t,this.valueChange.emit(this.value)}selectFocusedItem(){this.disabled||-1===this.getActiveItemIndex()||this.selectItem(this.getActiveItemIndex())}selectAllItems(){if(this.disabled)return;const t=this.items.every((t=>this.value.includes(t.value)));this.updateValue(t?[]:this.items.map((t=>t.value)))}syncItemsWithValue(){this.items.forEach((t=>t.selected=this.value.includes(t.value)))}focusItem(t){var i;if(this.disabled)return;this.items.forEach((t=>t.querySelector('[role="option"]').removeAttribute("tabIndex")));const o=null===(i=this.items[t])||void 0===i?void 0:i.querySelector('[role="option"]');Boolean(o)&&(o.setAttribute("tabIndex","0"),o.focus(),this.focusedItem=o)}focusNextItem(){if(this.disabled)return;const t=this.getActiveItemIndex(),i=Math.min(t+1,this.items.length-1);this.focusItem(i)}focusPreviousItem(){const t=this.getActiveItemIndex(),i=Math.max(t-1,0);this.focusItem(i)}getActiveItemIndex(){return this.items.map((t=>t.querySelector('[role="option"]'))).findIndex((t=>t===this.focusedItem))}getItemIndex(t){return this.items.map((t=>t)).findIndex((i=>i===t))}moveDraggedItemDown(){const t=this.dragging.nextElementSibling;Boolean(t)&&(t.after(this.dragging),this.updateItems(),this.listboxEl.focus(),this.assistiveText=`${this.assistiveTextItemMoving} ${this.getActiveItemIndex()+1}`)}moveDraggedItemUp(){const t=this.dragging.previousElementSibling;Boolean(t)&&(t.before(this.dragging),this.updateItems(),this.listboxEl.focus(),this.assistiveText=`${this.assistiveTextItemMoving} ${this.getItemIndex(this.dragging)+1}`)}render(){const t=this.multiSelect?"true":void 0,o=this.disabled?-1:0;return i(n,null,i("swirl-visually-hidden",{role:"alert"},this.assistiveText),i("div",{"aria-label":this.label,"aria-multiselectable":t,class:"option-list",id:this.optionListId,onClick:this.onClick,onFocus:this.onFocus,onKeyDown:this.onKeyDown,ref:t=>this.listboxEl=t,role:"listbox",tabIndex:o},i("slot",null)))}get el(){return r(this)}static get watchers(){return{allowDrag:["watchAllowDrag"],disabled:["watchDisabled"],multiSelect:["watchMultiSelect"],value:["watchValue"]}}};fi.style=".sc-swirl-option-list-h{display:block}.sc-swirl-option-list-h *.sc-swirl-option-list{box-sizing:border-box}";const mi=class{constructor(i){t(this,i),this.toggleDrag=e(this,"toggleDrag",7),this.desktopMediaQuery=h(),this.desktopMediaQueryHandler=t=>{this.forceIconProps(t.matches),this.updateIconSize(t.matches)},this.onDragHandleKeyDown=t=>{"Space"!==t.code&&"Enter"!==t.code||(t.preventDefault(),this.toggleDrag.emit(this.el))},this.allowDrag=void 0,this.context="single-select",this.disabled=void 0,this.dragging=void 0,this.dragHandleDescription="Press spacebar to toggle grab",this.dragHandleLabel="Move option",this.icon=void 0,this.label=void 0,this.selected=!1,this.value=void 0,this.iconSize=24}componentDidLoad(){var t,i;this.forceIconProps(this.desktopMediaQuery.matches),this.updateIconSize(this.desktopMediaQuery.matches),null===(i=(t=this.desktopMediaQuery).addEventListener)||void 0===i||i.call(t,"change",this.desktopMediaQueryHandler)}disconnectedCallback(){var t,i;null===(i=(t=this.desktopMediaQuery).removeEventListener)||void 0===i||i.call(t,"change",this.desktopMediaQueryHandler)}forceIconProps(t){var i;const o=null===(i=this.iconEl)||void 0===i?void 0:i.children[0];null==o||o.setAttribute("size",t?"20":"24")}updateIconSize(t){this.iconSize=t?20:24}render(){const t=this.disabled?"true":void 0,o=String(this.selected),e="multi-select"===this.context,r=Boolean(this.icon)&&"single-select"===this.context,l=this.selected&&"single-select"===this.context,a=s("option-list-item",`option-list-item--context-${this.context}`,{"option-list-item--disabled":this.disabled,"option-list-item--draggable":this.allowDrag,"option-list-item--dragging":this.dragging,"option-list-item--selected":this.selected});return i(n,null,i("div",{"aria-disabled":t,"aria-selected":o,class:a,part:"option-list-item",role:"option"},r&&i("span",{class:"option-list-item__icon",innerHTML:this.icon,ref:t=>this.iconEl=t}),e&&i("span",{class:"option-list-item__checkbox"},i("span",{class:"option-list-item__checkbox-box"},this.selected&&i("swirl-icon-check-strong",{class:"option-list-item__checkbox-icon",size:16}))),i("span",{class:"option-list-item__label",part:"option-list-item__label"},this.label),l&&i("span",{class:"option-list-item__selection-icon"},i("swirl-icon-check-small",{size:this.iconSize}))),this.allowDrag&&i("button",{"aria-describedby":this.dragHandleDescription,"aria-label":`${this.dragHandleLabel} "${this.label}"`,class:"option-list-item__drag-handle",onKeyDown:this.onDragHandleKeyDown,type:"button"},i("swirl-icon-drag-handle",{size:this.iconSize})))}get el(){return r(this)}};mi.style=".sc-swirl-option-list-item-h{position:relative;display:inline-flex;width:100%}.sc-swirl-option-list-item-h *.sc-swirl-option-list-item{box-sizing:border-box}.option-list-item.sc-swirl-option-list-item{display:inline-flex;width:100%;min-height:3rem;padding:var(--s-space-12) var(--s-space-16);align-items:center;background-color:var(--s-surface-overlay-default);cursor:pointer;gap:var(--s-space-12)}.option-list-item.sc-swirl-option-list-item:hover:not(.option-list-item--disabled){background-color:var(--s-surface-overlay-hovered)}.option-list-item.sc-swirl-option-list-item:active:not(.option-list-item--disabled){background-color:var(--s-surface-overlay-pressed)}.option-list-item.sc-swirl-option-list-item:focus{outline:none}.option-list-item.sc-swirl-option-list-item:focus-visible{background-color:var(--s-surface-overlay-hovered)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.option-list-item.sc-swirl-option-list-item{min-height:0;padding:var(--s-space-12);gap:var(--s-space-8)}}.option-list-item--draggable.sc-swirl-option-list-item .option-list-item__label.sc-swirl-option-list-item{padding-right:calc(var(--s-space-16) + 1.5rem)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.option-list-item--draggable.sc-swirl-option-list-item .option-list-item__label.sc-swirl-option-list-item{padding-right:calc(var(--s-space-16) + 1rem)}}.option-list-item--dragging.sc-swirl-option-list-item{z-index:1;border-radius:var(--s-border-radius-s);background-color:var(--s-surface-overlay-pressed);box-shadow:0 0.0625rem 0.125rem rgba(25, 26, 28, 0.08),\n 0 0.25rem 2rem rgba(25, 26, 28, 0.16)}.option-list-item--dragging.sc-swirl-option-list-item:hover:not(.option-list-item--disabled){background-color:var(--s-surface-overlay-pressed)}.option-list-item--selected.sc-swirl-option-list-item .option-list-item__label.sc-swirl-option-list-item{color:var(--s-text-highlight)}.option-list-item--selected.sc-swirl-option-list-item .option-list-item__icon.sc-swirl-option-list-item{color:var(--s-icon-highlight)}.option-list-item--selected.sc-swirl-option-list-item .option-list-item__checkbox-box.sc-swirl-option-list-item{border-color:var(--s-icon-highlight);color:var(--s-text-on-status);background-color:var(--s-icon-highlight)}.option-list-item--disabled.sc-swirl-option-list-item{cursor:default}.option-list-item--disabled.option-list-item--selected.sc-swirl-option-list-item .option-list-item__checkbox-box.sc-swirl-option-list-item{background-color:var(--s-icon-disabled)}.option-list-item--disabled.option-list-item--selected.sc-swirl-option-list-item .option-list-item__checkbox-icon.sc-swirl-option-list-item{color:var(--s-text-on-status)}.option-list-item--disabled.sc-swirl-option-list-item .option-list-item__label.sc-swirl-option-list-item{color:var(--s-text-disabled)}.option-list-item--disabled.sc-swirl-option-list-item .option-list-item__icon.sc-swirl-option-list-item,.option-list-item--disabled.sc-swirl-option-list-item .option-list-item__selection-icon.sc-swirl-option-list-item,.option-list-item--disabled.sc-swirl-option-list-item .option-list-item__checkbox-icon.sc-swirl-option-list-item{color:var(--s-icon-disabled)}.option-list-item--disabled.sc-swirl-option-list-item .option-list-item__checkbox-box.sc-swirl-option-list-item{border-color:var(--s-icon-disabled);background-color:var(--s-surface-overlay-default)}.option-list-item__label.sc-swirl-option-list-item{flex-grow:1;color:var(--s-text-default);font-size:var(--s-font-size-base);font-weight:var(--s-font-weight-medium);line-height:var(--s-line-height-base);text-align:left}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.option-list-item__label.sc-swirl-option-list-item{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}}.option-list-item__icon.sc-swirl-option-list-item{display:inline-flex;flex-shrink:0;color:var(--s-icon-default)}.option-list-item__selection-icon.sc-swirl-option-list-item{display:inline-flex;flex-shrink:0;color:var(--s-icon-highlight)}.option-list-item__checkbox.sc-swirl-option-list-item{display:inline-flex;width:1.5rem;height:1.5rem;padding:var(--s-space-2)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.option-list-item__checkbox.sc-swirl-option-list-item{width:1.375rem;height:1.375rem}}.option-list-item__checkbox-box.sc-swirl-option-list-item{display:inline-flex;width:100%;height:100%;justify-content:center;align-items:center;border:0.125rem solid var(--s-icon-default);border-radius:var(--s-border-radius-s)}.option-list-item__checkbox-icon.sc-swirl-option-list-item{display:inline-flex}.option-list-item__drag-handle.sc-swirl-option-list-item{position:absolute;z-index:1;top:50%;right:var(--s-space-4);display:inline-flex;margin:0;padding:0;padding:var(--s-space-8);flex-shrink:0;border:none;color:var(--s-icon-default);background-color:transparent;cursor:-webkit-grab;cursor:grab;transform:translateY(-50%)}.option-list-item__drag-handle.sc-swirl-option-list-item:active{cursor:-webkit-grabbing;cursor:grabbing}.option-list-item__drag-handle.sc-swirl-option-list-item:focus:not(:focus-visible){outline:none}.option-list-item__drag-handle.sc-swirl-option-list-item:focus-visible{outline-color:var(--s-focus-default)}";export{c as swirl_icon_check_small,u as swirl_icon_drag_handle,fi as swirl_option_list,mi as swirl_option_list_item}
@@ -1 +0,0 @@
1
- import{r as t,h as e,H as a,g as s}from"./p-05c15d47.js";import{i}from"./p-438b3941.js";function o(t){return"function"==typeof t?t():t}function r(){var t={};return t.promise=new Promise((function(e,a){t.resolve=e,t.reject=a})),t}const l=class{constructor(e){t(this,e),this.updateLayout=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},s=void 0,i=void 0,l=void 0,n=[];return function(){var h=o(e),c=(new Date).getTime(),b=!s||c-s>h;s=c;for(var w=arguments.length,u=Array(w),m=0;m<w;m++)u[m]=arguments[m];if(b&&a.leading)return a.accumulate?Promise.resolve(t.call(this,[u])).then((function(t){return t[0]})):Promise.resolve(t.call.apply(t,[this].concat(u)));if(i?clearTimeout(l):i=r(),n.push(u),l=setTimeout(d.bind(this),h),a.accumulate){var v=n.length-1;return i.promise.then((function(t){return t[v]}))}return i.promise};function d(){var e=i;clearTimeout(l),Promise.resolve(a.accumulate?t.call(this,n):t.apply(this,n[n.length-1])).then(e.resolve,e.reject),n=[],i=null}}((async()=>{await this.resetEmptyRowStyles(),await this.resetRowGroupStyles(),await this.resetCellStyles(),await this.resetColumnStyles(),await this.layoutEmptyRow(),await this.layoutRowGroups(),await this.layOutColumns(),this.layOutCells()}),100),this.onScroll=()=>{this.updateScrolledState()},this.caption=void 0,this.emptyStateLabel="No results found.",this.label=void 0,this.empty=void 0,this.scrollable=void 0,this.scrolled=void 0,this.scrolledToEnd=void 0}async componentDidRender(){await this.updateLayout(),this.updateScrolledState(),this.updateEmptyState()}async onWindowResize(){await this.updateLayout(),this.updateScrolledState()}updateScrolledState(){const t=i(),e=this.container.scrollWidth>this.container.clientWidth,a=this.container.scrollLeft>0,s=Math.ceil(this.container.clientWidth+this.container.scrollLeft)>=Math.floor(this.container.scrollWidth);e!==this.scrollable&&(e&&!t?this.container.classList.add("table__container--scrollable"):this.container.classList.remove("table__container--scrollable")),a!==this.scrolled&&(a&&!t?this.container.classList.add("table__container--scrolled"):this.container.classList.remove("table__container--scrolled")),s!==this.scrolledToEnd&&(s&&!t?this.container.classList.add("table__container--scrolled-to-end"):this.container.classList.remove("table__container--scrolled-to-end"))}getColumns(){return Array.from(this.el.querySelectorAll("swirl-table-column"))}getCells(){return Array.from(this.el.querySelectorAll("swirl-table-cell"))}async resetEmptyRowStyles(){const t=this.el.shadowRoot.querySelector(".table__empty-row");Boolean(t)&&(t.style.width="",await new Promise((t=>setTimeout(t))))}async resetRowGroupStyles(){Array.from(this.el.querySelectorAll("swirl-table-row-group")).forEach((t=>{t.shadowRoot.querySelector(".table-row-group__header-row").style.width=""})),await new Promise((t=>setTimeout(t)))}async resetColumnStyles(){this.getColumns().forEach((t=>{t.classList.remove("table-column--has-shadow"),t.style.right="",t.style.left="",t.style.position="",t.style.zIndex=""})),await new Promise((t=>setTimeout(t)))}async resetCellStyles(){this.getCells().forEach((t=>{t.classList.remove("table-cell--has-shadow"),t.style.flex="",t.style.left="",t.style.right="",t.style.position="",t.style.zIndex=""})),await new Promise((t=>setTimeout(t)))}async layoutEmptyRow(){const t=this.el.shadowRoot.querySelector(".table__empty-row");if(!Boolean(t))return;const e=`${this.el.shadowRoot.querySelector(".table__container").scrollWidth}px`;t.style.width=e}async layoutRowGroups(){const t=Array.from(this.el.querySelectorAll("swirl-table-row-group")),e=`${this.el.shadowRoot.querySelector(".table__container").scrollWidth}px`;t.forEach((t=>{t.shadowRoot.querySelector(".table-row-group__header-row").style.width=e}))}async layOutColumns(){const t=this.getColumns(),e=this.container.clientWidth;t.forEach(((a,s)=>{var o,r;if(!a.sticky||i())return;const l=s<=Math.floor(t.length/2),n=null===(o=t[s+1])||void 0===o?void 0:o.sticky,d=null===(r=t[s-1])||void 0===r?void 0:r.sticky;a.style.zIndex=l&&n?"1":"",l&&!n||!l&&!d?a.classList.add(l?"table-column--has-shadow-right":"table-column--has-shadow-left"):(a.classList.remove("table-column--has-shadow-right"),a.classList.remove("table-column--has-shadow-left"));const h=l?a.offsetLeft:Math.max(0,e-(a.offsetLeft+a.getBoundingClientRect().width));a.style.position="sticky",l?a.style.left=`${h}px`:a.style.right=`${h}px`})),await new Promise((t=>setTimeout(t)))}layOutCells(){const t=this.getColumns(),e=this.getCells();t.forEach(((a,s)=>{var o,r;const l=e.filter(((e,a)=>(s-a)%t.length==0)),n=s<=Math.floor(t.length/2),d=n?window.getComputedStyle(a).left:window.getComputedStyle(a).right,h=null===(o=t[s+1])||void 0===o?void 0:o.sticky,c=null===(r=t[s-1])||void 0===r?void 0:r.sticky,b=a.sticky,w=a.width||`${a.getBoundingClientRect().width}px`;l.forEach((t=>{const e=b&&n,a=b&&!n,s=n&&h;if(t.style.flex=Boolean(w)?`0 0 ${w}`:"",i())return t.classList.remove("table-cell--has-shadow"),t.style.left="",t.style.right="",t.style.position="",void(t.style.zIndex="");t.style.left=e?d:"",t.style.right=a?d:"",t.style.position=b?"sticky":"",t.style.zIndex=s?"1":"",b&&(n&&!h||!n&&!c)?t.classList.add(n?"table-cell--has-shadow-right":"table-cell--has-shadow-left"):(t.classList.remove("table-cell--has-shadow-right"),t.classList.remove("table-cell--has-shadow-left"))}))}))}updateEmptyState(){const t=this.el.querySelector('[slot="rows"]');this.empty=!Boolean(t)||0===t.children.length}render(){return e(a,null,e("div",{class:"table"},e("div",{class:"table__container",onScroll:this.onScroll,ref:t=>this.container=t},e("div",{"aria-describedby":Boolean(this.caption)?"caption":void 0,"aria-label":this.label,role:"table",class:"table__table"},this.caption&&e("swirl-visually-hidden",null,e("div",{id:"caption"},this.caption)),e("div",{role:"rowgroup"},e("div",{class:"table__header",role:"row"},e("slot",{name:"columns"}))),e("div",{class:"table__body"},e("slot",{name:"rows"}),this.empty&&e("div",{class:"table__empty-row",role:"row"},e("div",{"aria-colspan":this.getColumns().length,class:"table__empty-row-cell",role:"cell"},e("swirl-text",{align:"center",size:"sm"},this.emptyStateLabel))))))))}get el(){return s(this)}};l.style=":host{position:relative;display:block}:host *{box-sizing:border-box}.table__container{position:relative;overflow:auto;width:100%}.table__container--scrolled{--swirl-table-sticky-right-shadow:0.0625rem 0 0 0 var(--s-border-default),\n -0.0625rem 0 0 0 var(--s-border-default),\n 0 0.25rem 1rem rgba(25, 26, 28, 0.04),\n 0 0.0625rem 0.25rem rgba(25, 26, 28, 0.16)}.table__container--scrollable:not(.table__container--scrolled-to-end){--swirl-table-sticky-left-shadow:0.0625rem 0 0 0 var(--s-border-default),\n -0.0625rem 0 0 0 var(--s-border-default),\n 0 0.25rem 1rem rgba(25, 26, 28, 0.04),\n 0 0.0625rem 0.25rem rgba(25, 26, 28, 0.16)}.table__table{width:-webkit-max-content;width:-moz-max-content;width:max-content;min-width:max(20rem, 100%)}.table__header ::slotted(*){display:flex}.table__empty-row{display:flex}.table__empty-row-cell{display:flex;overflow:auto;padding-top:var(--s-space-8);padding-right:var(--s-space-16);padding-bottom:var(--s-space-8);padding-left:var(--s-space-16);flex-basis:0;flex-grow:1;flex-shrink:1;align-items:center;border-right:var(--s-border-width-default) solid var(--s-border-default);border-bottom:var(--s-border-width-default) solid var(--s-border-default);border-left:var(--s-border-width-default) solid var(--s-border-default);background-color:var(--s-background-default)}.table__empty-row-cell>*{flex-grow:1}";export{l as swirl_table}
@@ -1 +0,0 @@
1
- import{r as s,c as e,h as r,H as a}from"./p-05c15d47.js";import{c as i}from"./p-b7898321.js";import{g as c}from"./p-438b3941.js";const t=class{constructor(r){s(this,r),this.inputBlur=e(this,"inputBlur",7),this.inputFocus=e(this,"inputFocus",7),this.valueChange=e(this,"valueChange",7),this.desktopMediaQuery=c(),this.desktopMediaQueryHandler=s=>{this.forceIconProps(s.matches)},this.clear=()=>{this.input.value="",this.input.focus(),this.valueChange.emit("")},this.onBlur=s=>{this.inputBlur.emit(s)},this.onChange=s=>{this.valueChange.emit(s.target.value)},this.onFocus=s=>{this.inputFocus.emit(s)},this.autoFocus=void 0,this.clearButtonLabel="Clear search term",this.disabled=void 0,this.inputName=void 0,this.inputId=void 0,this.label=void 0,this.placeholder="Search …",this.value=void 0}componentDidLoad(){var s,e;this.forceIconProps(this.desktopMediaQuery.matches),null===(e=(s=this.desktopMediaQuery).addEventListener)||void 0===e||e.call(s,"change",this.desktopMediaQueryHandler)}disconnectedCallback(){var s,e;null===(e=(s=this.desktopMediaQuery).removeEventListener)||void 0===e||e.call(s,"change",this.desktopMediaQueryHandler)}forceIconProps(s){if(!Boolean(this.iconEl))return;const e=this.iconEl.children[0];null==e||e.setAttribute("size",s?"20":"24")}onKeyDown(s){"KeyK"!==s.code&&"Slash"!==s.code||!s.ctrlKey&&!s.metaKey||this.input.focus()}render(){const s=i("search",{"search--disabled":this.disabled});return r(a,null,r("span",{class:s,ref:s=>this.iconEl=s},r("swirl-icon-search",{class:"search__icon"}),r("input",{"aria-disabled":this.disabled?"true":void 0,"aria-label":this.label,autoComplete:"off",autoFocus:this.autoFocus,class:"search__input",disabled:this.disabled,id:this.inputId,inputMode:"search",name:this.inputName,onBlur:this.onBlur,onChange:this.onChange,onFocus:this.onFocus,placeholder:this.placeholder,ref:s=>this.input=s,type:"search",value:this.value}),!this.disabled&&r("button",{"aria-label":this.clearButtonLabel,class:"search__clear-button",onClick:this.clear,type:"button"},r("swirl-icon-cancel",null))))}};t.style=".sc-swirl-search-h{display:flex;width:100%}.sc-swirl-search-h *.sc-swirl-search{box-sizing:border-box}.search.sc-swirl-search{position:relative;display:flex;width:100%}.search--disabled.sc-swirl-search .search__icon.sc-swirl-search{color:var(--s-icon-disabled)}.search--disabled.sc-swirl-search .search__input.sc-swirl-search{color:var(--s-text-disabled)}.search--disabled.sc-swirl-search .search__input.sc-swirl-search::-moz-placeholder{color:var(--s-text-disabled)}.search--disabled.sc-swirl-search .search__input.sc-swirl-search::placeholder{color:var(--s-text-disabled)}.search__icon.sc-swirl-search{position:absolute;top:50%;left:var(--s-space-12);display:inline-flex;color:var(--s-icon-default);transform:translateY(-50%)}.search__input.sc-swirl-search{width:100%;height:2.5rem;padding-top:var(--s-space-8);padding-right:calc(var(--s-space-12) + 1.5rem + var(--s-space-8));padding-bottom:var(--s-space-8);padding-left:calc(var(--s-space-12) + 1.5rem + var(--s-space-8));border:none;border-radius:var(--s-border-radius-base);color:var(--s-text-default);background-color:var(--s-surface-raised-default);font:inherit;line-height:var(--s-line-height-base);caret-color:var(--s-border-highlight)}.search__input.sc-swirl-search:focus:not(:focus-visible){outline:none}.search__input.sc-swirl-search:focus-visible{outline-color:var(--s-focus-default)}.search__input.sc-swirl-search::-moz-placeholder{color:var(--s-text-subdued)}.search__input.sc-swirl-search::placeholder{color:var(--s-text-subdued)}.search__input.sc-swirl-search::-webkit-search-decoration,.search__input.sc-swirl-search::-webkit-search-cancel-button,.search__input.sc-swirl-search::-webkit-search-results-button,.search__input.sc-swirl-search::-webkit-search-results-decoration{-webkit-appearance:none;appearance:none}.search__input.sc-swirl-search:not(:-moz-placeholder-shown)+.search__clear-button.sc-swirl-search{display:inline-flex}.search__input.sc-swirl-search:not(:placeholder-shown)+.search__clear-button.sc-swirl-search{display:inline-flex}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.search__input.sc-swirl-search{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm);padding-left:calc(var(--s-space-8) + 1.5rem + var(--s-space-8))}}.search__clear-button.sc-swirl-search{position:absolute;top:50%;right:var(--s-space-12);display:none;padding:0;border:none;color:var(--s-icon-default);background-color:transparent;cursor:pointer;transform:translateY(-50%)}";export{t as swirl_search}
@@ -1 +0,0 @@
1
- import{r as i,c as a,h as t,H as s}from"./p-05c15d47.js";import{c as n}from"./p-b7898321.js";const e=class{constructor(t){i(this,t),this.setPage=a(this,"setPage",7),this.onPrevButtonClick=()=>{const i=Math.max(this.page-1,1);this.page!==i&&this.setPage.emit(i)},this.onNextButtonClick=()=>{const i=Math.min(this.page+1,this.pages);this.page!==i&&this.setPage.emit(i)},this.onSelect=i=>{const a=+i.target.value;this.page!==a&&this.setPage.emit(a)},this.accessibleNextButtonLabel="Next page",this.accessiblePrevButtonLabel="Previous page",this.nextButtonLabel="Next",this.pageLabel="out of",this.prevButtonLabel="Prev",this.label=void 0,this.page=void 0,this.pages=void 0,this.pageSelectLabel="Select a page",this.variant="default"}render(){const i="advanced"!==this.variant,a="simple"!==this.variant,e="advanced"===this.variant,o=`${this.page} ${this.pageLabel} ${this.pages}`,l=n("pagination",`pagination--variant-${this.variant}`);return t(s,null,t("nav",{"aria-label":this.label,class:l},t("ul",{class:"pagination__list",part:"pagination__list"},t("li",{class:"pagination__list-item"},t("swirl-button",{class:"pagination__prev-button",disabled:this.page<=1,swirlAriaLabel:this.accessiblePrevButtonLabel,hideLabel:i,icon:"<swirl-icon-chevron-left></swirl-icon-chevron-left>",intent:"primary",label:this.prevButtonLabel,onClick:this.onPrevButtonClick})),t("li",{class:"pagination__list-item"},a?t("span",null,e?t("span",{"aria-current":"page",class:"pagination__advanced-label"},t("span",{class:"pagination__page-select-container"},t("select",{"aria-label":this.pageSelectLabel,class:"pagination__page-select",onChange:this.onSelect},new Array(this.pages).fill(void 0).map(((i,a)=>a+1)).map((i=>t("option",{selected:this.page===i,value:String(i)},i)))),t("swirl-icon-expand-more",{"aria-hidden":"true",class:"pagination__page-select-icon",size:16})),t("span",{"aria-hidden":"true"},this.pageLabel," ",this.pages)):t("span",{"aria-current":"page"},o)):t("swirl-visually-hidden",null,t("span",{"aria-current":"page"},o))),t("li",{class:"pagination__list-item"},t("swirl-button",{class:"pagination__next-button",disabled:this.page>=this.pages,swirlAriaLabel:this.accessibleNextButtonLabel,hideLabel:i,icon:"<swirl-icon-chevron-right></swirl-icon-chevron-right>",iconPosition:"end",intent:"primary",label:this.nextButtonLabel,onClick:this.onNextButtonClick})))))}};e.style=":host{display:block;width:100%}:host *{box-sizing:border-box}.pagination{display:block;width:100%}.pagination--variant-simple .pagination__list{gap:0}.pagination__list{display:flex;margin:0;padding:0;justify-content:flex-start;align-items:center;line-height:var(--s-line-height-base);list-style:none;gap:var(--s-space-16)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.pagination__list{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm);gap:var(--s-space-8)}}.pagination__advanced-label{display:flex;align-items:center;white-space:nowrap;gap:var(--s-space-8)}.pagination__page-select-container{position:relative}.pagination__page-select{display:inline-flex;padding-right:var(--s-space-16);border:none;background-color:transparent;font:inherit;line-height:var(--s-line-height-base);text-align:center;cursor:pointer;-webkit-appearance:none;-moz-appearance:none;appearance:none}.pagination__page-select:focus:not(:focus-visible){outline:none}.pagination__page-select:focus-visible{outline-color:var(--s-focus-default)}.pagination__page-select-icon{position:absolute;top:50%;right:0;transform:translateY(-50%);pointer-events:none}";export{e as swirl_pagination}