hasting-swatchcart-module 1.0.30 → 1.0.31

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 (121) hide show
  1. package/dist/assets/index.css +1 -0
  2. package/dist/cdn/lib/components/SwatchesModule.d.ts +11 -0
  3. package/dist/cdn/lib/main.d.ts +9 -0
  4. package/dist/cdn/lib/store/LibraryProvider.d.ts +4 -0
  5. package/dist/cdn/lib/store/rootReducer.d.ts +11 -0
  6. package/dist/cdn/lib/store/store.d.ts +25 -0
  7. package/dist/cdn/lib/store/withStore.d.ts +2 -0
  8. package/dist/cdn/lib/vite-env.d.ts +1 -0
  9. package/dist/cdn/main.css +1 -0
  10. package/dist/cdn/main.js +31572 -0
  11. package/dist/cdn/src/app/App.d.ts +2 -0
  12. package/dist/cdn/src/app/assets/svg/ArrowIconSVG.d.ts +3 -0
  13. package/dist/cdn/src/app/assets/svg/CheckMarkIconSVG.d.ts +3 -0
  14. package/dist/cdn/src/app/assets/svg/ChevronSVGIcon.d.ts +3 -0
  15. package/dist/cdn/src/app/assets/svg/CloseIconSVG.d.ts +3 -0
  16. package/dist/cdn/src/app/assets/svg/DarkWhiteIconSVG.d.ts +1 -0
  17. package/dist/cdn/src/app/assets/svg/MinusIconSVG.d.ts +3 -0
  18. package/dist/cdn/src/app/assets/svg/PlusIconSVG.d.ts +3 -0
  19. package/dist/cdn/src/app/assets/svg/SearchIconSVG.d.ts +3 -0
  20. package/dist/cdn/src/app/assets/svg/TrashIconSVG.d.ts +3 -0
  21. package/dist/cdn/src/app/assets/svg/WhiteWhiteIconSVG.d.ts +1 -0
  22. package/dist/cdn/src/app/main.d.ts +0 -0
  23. package/dist/cdn/src/app/providers/StoreProvider.d.ts +6 -0
  24. package/dist/cdn/src/app/store/rootReducer.d.ts +11 -0
  25. package/dist/cdn/src/app/store/store.d.ts +24 -0
  26. package/dist/cdn/src/features/Cart/lib/CartCervices.d.ts +5 -0
  27. package/dist/cdn/src/features/Cart/model/cartSlice.d.ts +3 -0
  28. package/dist/cdn/src/features/Cart/model/selectors.d.ts +223 -0
  29. package/dist/cdn/src/features/Cart/model/types.d.ts +7 -0
  30. package/dist/cdn/src/features/Cart/ui/CartHeader/CartHeader.d.ts +7 -0
  31. package/dist/cdn/src/features/Cart/ui/CartList/CartList.d.ts +1 -0
  32. package/dist/cdn/src/features/Cart/ui/CartListItem/CartListItem.d.ts +10 -0
  33. package/dist/cdn/src/features/Cart/ui/CartWrapper/CartWrapper.d.ts +9 -0
  34. package/dist/cdn/src/features/Cart/ui/Counter/Counter.d.ts +9 -0
  35. package/dist/cdn/src/features/DataAdapter/lib/DataAdapterServices.d.ts +14 -0
  36. package/dist/cdn/src/features/DataAdapter/utils/types.d.ts +11 -0
  37. package/dist/cdn/src/features/MultiProduct/lib/MultiProductCartServices.d.ts +13 -0
  38. package/dist/cdn/src/features/MultiProduct/model/API/api.d.ts +4 -0
  39. package/dist/cdn/src/features/MultiProduct/model/API/routes.d.ts +4 -0
  40. package/dist/cdn/src/features/MultiProduct/model/multiProductCartSlice.d.ts +9 -0
  41. package/dist/cdn/src/features/MultiProduct/model/selectors.d.ts +38 -0
  42. package/dist/cdn/src/features/MultiProduct/model/thunk.d.ts +11 -0
  43. package/dist/cdn/src/features/MultiProduct/model/types.d.ts +63 -0
  44. package/dist/cdn/src/features/MultiProduct/ui/CartSelectedProductList/CartSelectedProductList.d.ts +1 -0
  45. package/dist/cdn/src/features/MultiProduct/ui/FiltersSelectedProductItem/FiltersSelectedProductItem.d.ts +1 -0
  46. package/dist/cdn/src/features/MultiProduct/ui/MaterialMultiProductList/MaterialMultiProductList.d.ts +42 -0
  47. package/dist/cdn/src/features/MultiProduct/ui/MultiProductCartHeader/MultiProductCartHeader.d.ts +5 -0
  48. package/dist/cdn/src/features/MultiProduct/ui/MultiProductItemCart/MultiProductItemCart.d.ts +5 -0
  49. package/dist/cdn/src/features/MultiProduct/ui/MultiProductWrapper/MultiProductWrapper.d.ts +6 -0
  50. package/dist/cdn/src/features/MultiProduct/ui/ProductList/ProductList.d.ts +1 -0
  51. package/dist/cdn/src/features/MultiProduct/ui/ProductListItem/ProductListItem.d.ts +6 -0
  52. package/dist/cdn/src/features/MultiProduct/ui/SelectedProductItem/SelectedProductItem.d.ts +1 -0
  53. package/dist/cdn/src/features/MultiProduct/ui/SwatchContentContainer/SwatchContentContainer.d.ts +15 -0
  54. package/dist/cdn/src/features/MultiProduct/ui/SwatchListItem/SwatchListItem.d.ts +41 -0
  55. package/dist/cdn/src/features/MultiProduct/ui/SwatchesMultiProductList/SwatchesMultiProductList.d.ts +29 -0
  56. package/dist/cdn/src/features/MultiProduct/utils/constants.d.ts +6 -0
  57. package/dist/cdn/src/features/MultiProduct/utils/randomList.d.ts +2 -0
  58. package/dist/cdn/src/features/SwatchModule/SwatchModule/ui/SwatchModule.d.ts +2 -0
  59. package/dist/cdn/src/features/swatches/lib/AttributeHelper.d.ts +7 -0
  60. package/dist/cdn/src/features/swatches/lib/SwatchesServices.d.ts +11 -0
  61. package/dist/cdn/src/features/swatches/model/selectors.d.ts +10 -0
  62. package/dist/cdn/src/features/swatches/model/swatchesSlice.d.ts +54 -0
  63. package/dist/cdn/src/features/swatches/model/thunks.d.ts +12 -0
  64. package/dist/cdn/src/features/swatches/model/types.d.ts +148 -0
  65. package/dist/cdn/src/features/swatches/ui/Filters/ColorsFilter.d.ts +1 -0
  66. package/dist/cdn/src/features/swatches/ui/Filters/LooksFilter.d.ts +1 -0
  67. package/dist/cdn/src/features/swatches/ui/Filters/MaterialsFilter.d.ts +1 -0
  68. package/dist/cdn/src/features/swatches/ui/Filters/index.d.ts +1 -0
  69. package/dist/cdn/src/features/swatches/ui/HexGridZoom/HexGridZoom.d.ts +3 -0
  70. package/dist/cdn/src/features/swatches/ui/ImageGridZoom/ImageGridZoom.d.ts +3 -0
  71. package/dist/cdn/src/features/swatches/ui/MaterialSingleProductList/MaterialSingleProductList.d.ts +7 -0
  72. package/dist/cdn/src/features/swatches/ui/ProductElement/index.d.ts +6 -0
  73. package/dist/cdn/src/features/swatches/ui/SwatchWrapper/SwatchWrapper.d.ts +8 -0
  74. package/dist/cdn/src/features/swatches/ui/Swatches.d.ts +2 -0
  75. package/dist/cdn/src/features/swatches/ui/SwatchesList/SwatchesList.d.ts +7 -0
  76. package/dist/cdn/src/features/swatches/ui/SwatchesListWrapper/SwatchesListWrapper.d.ts +1 -0
  77. package/dist/cdn/src/features/swatches/utils/constants.d.ts +3 -0
  78. package/dist/cdn/src/features/swatches/utils/types.d.ts +22 -0
  79. package/dist/cdn/src/shared/constants/constants.d.ts +1 -0
  80. package/dist/cdn/src/shared/constants/props.d.ts +1058 -0
  81. package/dist/cdn/src/shared/constants/select.d.ts +4 -0
  82. package/dist/cdn/src/shared/constants/selectedMaterials.d.ts +1 -0
  83. package/dist/cdn/src/shared/types/activeTab.d.ts +5 -0
  84. package/dist/cdn/src/shared/types/fetchData.d.ts +41 -0
  85. package/dist/cdn/src/shared/types/svg.d.ts +3 -0
  86. package/dist/cdn/src/shared/ui/CartPrice/CartPrice.d.ts +7 -0
  87. package/dist/cdn/src/shared/ui/Checkbox/Checkbox.d.ts +4 -0
  88. package/dist/cdn/src/shared/ui/CustomButton/CustomButton.d.ts +6 -0
  89. package/dist/cdn/src/shared/ui/CustomModal/CustomModal.d.ts +11 -0
  90. package/dist/cdn/src/shared/ui/CustomSidebar/CustomSidebar.d.ts +8 -0
  91. package/dist/cdn/src/shared/ui/Dialog/Dialog.d.ts +19 -0
  92. package/dist/cdn/src/shared/ui/Hint/Hint.d.ts +60 -0
  93. package/dist/cdn/src/shared/ui/Label/Label.d.ts +7 -0
  94. package/dist/cdn/src/shared/ui/Loader/Loader.d.ts +10 -0
  95. package/dist/cdn/src/shared/ui/Markdown/MDWithAccordion.d.ts +10 -0
  96. package/dist/cdn/src/shared/ui/MaterialItem/MaterialItem.d.ts +8 -0
  97. package/dist/cdn/src/shared/ui/MaterialListItem/MaterialListItem.d.ts +7 -0
  98. package/dist/cdn/src/shared/ui/MultiSelect/MultiSelect.d.ts +20 -0
  99. package/dist/cdn/src/shared/ui/PopoverTooltip/InfoIcon.d.ts +1 -0
  100. package/dist/cdn/src/shared/ui/PopoverTooltip/PopoverTooltip.d.ts +11 -0
  101. package/dist/cdn/src/shared/ui/SingleSelect/SingleSelect.d.ts +18 -0
  102. package/dist/cdn/src/shared/ui/Slider/Slider.d.ts +11 -0
  103. package/dist/cdn/src/shared/ui/SwatchLimitModal/SwatchLimitModal.d.ts +6 -0
  104. package/dist/cdn/src/shared/ui/popover.d.ts +9 -0
  105. package/dist/cdn/src/shared/utils/cn.d.ts +2 -0
  106. package/dist/cdn/src/shared/utils/uniqueList.d.ts +1 -0
  107. package/dist/components/SwatchesModule.d.ts +11 -0
  108. package/dist/main.cjs +150 -0
  109. package/dist/main.cjs.map +1 -0
  110. package/dist/main.d.ts +9 -0
  111. package/dist/main.js +24396 -0
  112. package/dist/main.js.map +1 -0
  113. package/dist/store/LibraryProvider.d.ts +4 -0
  114. package/dist/store/rootReducer.d.ts +11 -0
  115. package/dist/store/store.d.ts +25 -0
  116. package/dist/store/withStore.d.ts +2 -0
  117. package/package.json +1 -1
  118. package/dist/assets/index-BxOF0-6c.js +0 -156
  119. package/dist/assets/index-WOZaSyBx.css +0 -1
  120. package/dist/index.html +0 -14
  121. /package/dist/{vite.svg → cdn/vite.svg} +0 -0
package/dist/main.cjs ADDED
@@ -0,0 +1,150 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./assets/index.css');const D=require("react"),Vt=require("react-dom"),m=require("react/jsx-runtime"),Ze=require("@reduxjs/toolkit"),Tn=require("react-redux");function Au(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const n in e)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:()=>e[n]})}}return t.default=e,Object.freeze(t)}const y=Au(D),Su=Au(Vt);function Nu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Jt={},wi;function vf(){if(wi)return Jt;wi=1;var e=Vt;if(process.env.NODE_ENV==="production")Jt.createRoot=e.createRoot,Jt.hydrateRoot=e.hydrateRoot;else{var t=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;Jt.createRoot=function(n,r){t.usingClientEntryPoint=!0;try{return e.createRoot(n,r)}finally{t.usingClientEntryPoint=!1}},Jt.hydrateRoot=function(n,r,a){t.usingClientEntryPoint=!0;try{return e.hydrateRoot(n,r,a)}finally{t.usingClientEntryPoint=!1}}}return Jt}var wf=vf();const tt={UI:"UI",FETCH_DATA_PRODUCT:"FETCH_DATA_PRODUCT",FETCH_DATA_ALL:"FETCH_DATA_ALL"},kf={Finish:"Material",Color:"Color",Look:"Look"},Of=(e,t)=>e.toLowerCase()===t.toLowerCase();class Fr{static getMaterialsValuesFromOptions(t){if(t?.length)return t.reduce((n,r)=>{const a=Array.isArray(r.values)&&r.values.length?r.values:Array.isArray(r.valuesArray)&&r.valuesArray.length?r.valuesArray:void 0;if(!a)return n;const s=r.metadata?.Name??r.metadata?.Label??r.value??r.label??"without_name",i=a.map(o=>({...o,parentName:s}));return n.push(...i),n},[]).sort((n,r)=>(n.name?.toLowerCase()??"").localeCompare(r.name?.toLowerCase()??""))}static getUniqueByAssetId(t){const n=new Set;return t.filter(r=>n.has(r.assetId)?!1:(n.add(r.assetId),!0))}static normalizeToArray(t,n=!0){return t?Array.isArray(t)?t.map(r=>r.trim()).filter(Boolean):(n?t.split(","):[t]).map(r=>r.trim()).filter(Boolean):[]}static mapFiltersFromValues(t,n){return Object.keys(n).map(r=>{const a=kf[r],i=n[r].map(o=>{let l=0;for(const c of t){const d=Array.isArray(c.values)?c.values:[];for(const f of d){const p=this.normalizeToArray(f.metadata?.[a]);l+=p.filter(h=>Of(h,o)).length}}return{filterKey:o,filterCount:l}});return{filterType:r,filters:i}})}static getPositiveSelectedFilers(t){return t.map(n=>({filterName:n.filterType,filterKeys:n.filters.filter(r=>r.filterCount!==0).map(r=>r.filterKey)})).filter(n=>n.filterKeys.length>0)}}const Iu=e=>Array.from(new Set(e)),vu={GET_PRODUCT_LIST:()=>"products",GET_PRODUCT_DETAILS:e=>`products/${e}`},Rf={VITE_SWATH_CART_PRODUCTION_URL:"https://hbswatchcart.vivid3d.tech"},{VITE_SWATH_CART_PRODUCTION_URL:wu}=Rf,Lf=async()=>{try{const e=`${wu}/${vu.GET_PRODUCT_LIST()}?pageSize=500`,t=await fetch(e,{method:"GET",headers:{"Content-Type":"application/json"}});if(!t.ok)throw new Error(`Request failed with status ${t.status}`);const n=await t.json();if(Array.isArray(n))throw new Error("API returned an array, expected IProductListResponse object");return n}catch(e){throw console.error("❌ Fetch error:",e),e}},Pf=async({assetId:e})=>{try{const t=`${wu}/${vu.GET_PRODUCT_DETAILS(e)}`,n=await fetch(t,{method:"GET",headers:{"Content-Type":"application/json"}});if(!n.ok)throw new Error(`Request failed with status ${n.status}`);return await n.json()}catch(t){throw console.error("❌ Fetch error:",t),t}};function ku(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var a=e.length;for(t=0;t<a;t++)e[t]&&(n=ku(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function yt(){for(var e,t,n=0,r="",a=arguments.length;n<a;n++)(e=arguments[n])&&(t=ku(e))&&(r&&(r+=" "),r+=t);return r}function Df(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.firstChild?t.insertBefore(n,t.firstChild):t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}Df(`:root{--toastify-color-light: #fff;--toastify-color-dark: #121212;--toastify-color-info: #3498db;--toastify-color-success: #07bc0c;--toastify-color-warning: #f1c40f;--toastify-color-error: hsl(6, 78%, 57%);--toastify-color-transparent: rgba(255, 255, 255, .7);--toastify-icon-color-info: var(--toastify-color-info);--toastify-icon-color-success: var(--toastify-color-success);--toastify-icon-color-warning: var(--toastify-color-warning);--toastify-icon-color-error: var(--toastify-color-error);--toastify-container-width: fit-content;--toastify-toast-width: 320px;--toastify-toast-offset: 16px;--toastify-toast-top: max(var(--toastify-toast-offset), env(safe-area-inset-top));--toastify-toast-right: max(var(--toastify-toast-offset), env(safe-area-inset-right));--toastify-toast-left: max(var(--toastify-toast-offset), env(safe-area-inset-left));--toastify-toast-bottom: max(var(--toastify-toast-offset), env(safe-area-inset-bottom));--toastify-toast-background: #fff;--toastify-toast-padding: 14px;--toastify-toast-min-height: 64px;--toastify-toast-max-height: 800px;--toastify-toast-bd-radius: 6px;--toastify-toast-shadow: 0px 4px 12px rgba(0, 0, 0, .1);--toastify-font-family: sans-serif;--toastify-z-index: 9999;--toastify-text-color-light: #757575;--toastify-text-color-dark: #fff;--toastify-text-color-info: #fff;--toastify-text-color-success: #fff;--toastify-text-color-warning: #fff;--toastify-text-color-error: #fff;--toastify-spinner-color: #616161;--toastify-spinner-color-empty-area: #e0e0e0;--toastify-color-progress-light: linear-gradient(to right, #4cd964, #5ac8fa, #007aff, #34aadc, #5856d6, #ff2d55);--toastify-color-progress-dark: #bb86fc;--toastify-color-progress-info: var(--toastify-color-info);--toastify-color-progress-success: var(--toastify-color-success);--toastify-color-progress-warning: var(--toastify-color-warning);--toastify-color-progress-error: var(--toastify-color-error);--toastify-color-progress-bgo: .2}.Toastify__toast-container{z-index:var(--toastify-z-index);-webkit-transform:translate3d(0,0,var(--toastify-z-index));position:fixed;width:var(--toastify-container-width);box-sizing:border-box;color:#fff;display:flex;flex-direction:column}.Toastify__toast-container--top-left{top:var(--toastify-toast-top);left:var(--toastify-toast-left)}.Toastify__toast-container--top-center{top:var(--toastify-toast-top);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--top-right{top:var(--toastify-toast-top);right:var(--toastify-toast-right);align-items:end}.Toastify__toast-container--bottom-left{bottom:var(--toastify-toast-bottom);left:var(--toastify-toast-left)}.Toastify__toast-container--bottom-center{bottom:var(--toastify-toast-bottom);left:50%;transform:translate(-50%);align-items:center}.Toastify__toast-container--bottom-right{bottom:var(--toastify-toast-bottom);right:var(--toastify-toast-right);align-items:end}.Toastify__toast{--y: 0;position:relative;touch-action:none;width:var(--toastify-toast-width);min-height:var(--toastify-toast-min-height);box-sizing:border-box;margin-bottom:1rem;padding:var(--toastify-toast-padding);border-radius:var(--toastify-toast-bd-radius);box-shadow:var(--toastify-toast-shadow);max-height:var(--toastify-toast-max-height);font-family:var(--toastify-font-family);z-index:0;display:flex;flex:1 auto;align-items:center;word-break:break-word}@media only screen and (max-width: 480px){.Toastify__toast-container{width:100vw;left:env(safe-area-inset-left);margin:0}.Toastify__toast-container--top-left,.Toastify__toast-container--top-center,.Toastify__toast-container--top-right{top:env(safe-area-inset-top);transform:translate(0)}.Toastify__toast-container--bottom-left,.Toastify__toast-container--bottom-center,.Toastify__toast-container--bottom-right{bottom:env(safe-area-inset-bottom);transform:translate(0)}.Toastify__toast-container--rtl{right:env(safe-area-inset-right);left:initial}.Toastify__toast{--toastify-toast-width: 100%;margin-bottom:0;border-radius:0}}.Toastify__toast-container[data-stacked=true]{width:var(--toastify-toast-width)}.Toastify__toast--stacked{position:absolute;width:100%;transform:translate3d(0,var(--y),0) scale(var(--s));transition:transform .3s}.Toastify__toast--stacked[data-collapsed] .Toastify__toast-body,.Toastify__toast--stacked[data-collapsed] .Toastify__close-button{transition:opacity .1s}.Toastify__toast--stacked[data-collapsed=false]{overflow:visible}.Toastify__toast--stacked[data-collapsed=true]:not(:last-child)>*{opacity:0}.Toastify__toast--stacked:after{content:"";position:absolute;left:0;right:0;height:calc(var(--g) * 1px);bottom:100%}.Toastify__toast--stacked[data-pos=top]{top:0}.Toastify__toast--stacked[data-pos=bot]{bottom:0}.Toastify__toast--stacked[data-pos=bot].Toastify__toast--stacked:before{transform-origin:top}.Toastify__toast--stacked[data-pos=top].Toastify__toast--stacked:before{transform-origin:bottom}.Toastify__toast--stacked:before{content:"";position:absolute;left:0;right:0;bottom:0;height:100%;transform:scaleY(3);z-index:-1}.Toastify__toast--rtl{direction:rtl}.Toastify__toast--close-on-click{cursor:pointer}.Toastify__toast-icon{margin-inline-end:10px;width:22px;flex-shrink:0;display:flex}.Toastify--animate{animation-fill-mode:both;animation-duration:.5s}.Toastify--animate-icon{animation-fill-mode:both;animation-duration:.3s}.Toastify__toast-theme--dark{background:var(--toastify-color-dark);color:var(--toastify-text-color-dark)}.Toastify__toast-theme--light,.Toastify__toast-theme--colored.Toastify__toast--default{background:var(--toastify-color-light);color:var(--toastify-text-color-light)}.Toastify__toast-theme--colored.Toastify__toast--info{color:var(--toastify-text-color-info);background:var(--toastify-color-info)}.Toastify__toast-theme--colored.Toastify__toast--success{color:var(--toastify-text-color-success);background:var(--toastify-color-success)}.Toastify__toast-theme--colored.Toastify__toast--warning{color:var(--toastify-text-color-warning);background:var(--toastify-color-warning)}.Toastify__toast-theme--colored.Toastify__toast--error{color:var(--toastify-text-color-error);background:var(--toastify-color-error)}.Toastify__progress-bar-theme--light{background:var(--toastify-color-progress-light)}.Toastify__progress-bar-theme--dark{background:var(--toastify-color-progress-dark)}.Toastify__progress-bar--info{background:var(--toastify-color-progress-info)}.Toastify__progress-bar--success{background:var(--toastify-color-progress-success)}.Toastify__progress-bar--warning{background:var(--toastify-color-progress-warning)}.Toastify__progress-bar--error{background:var(--toastify-color-progress-error)}.Toastify__progress-bar-theme--colored.Toastify__progress-bar--info,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--success,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--warning,.Toastify__progress-bar-theme--colored.Toastify__progress-bar--error{background:var(--toastify-color-transparent)}.Toastify__close-button{color:#fff;position:absolute;top:6px;right:6px;background:transparent;outline:none;border:none;padding:0;cursor:pointer;opacity:.7;transition:.3s ease;z-index:1}.Toastify__toast--rtl .Toastify__close-button{left:6px;right:unset}.Toastify__close-button--light{color:#000;opacity:.3}.Toastify__close-button>svg{fill:currentColor;height:16px;width:14px}.Toastify__close-button:hover,.Toastify__close-button:focus{opacity:1}@keyframes Toastify__trackProgress{0%{transform:scaleX(1)}to{transform:scaleX(0)}}.Toastify__progress-bar{position:absolute;bottom:0;left:0;width:100%;height:100%;z-index:1;opacity:.7;transform-origin:left}.Toastify__progress-bar--animated{animation:Toastify__trackProgress linear 1 forwards}.Toastify__progress-bar--controlled{transition:transform .2s}.Toastify__progress-bar--rtl{right:0;left:initial;transform-origin:right;border-bottom-left-radius:initial}.Toastify__progress-bar--wrp{position:absolute;overflow:hidden;bottom:0;left:0;width:100%;height:5px;border-bottom-left-radius:var(--toastify-toast-bd-radius);border-bottom-right-radius:var(--toastify-toast-bd-radius)}.Toastify__progress-bar--wrp[data-hidden=true]{opacity:0}.Toastify__progress-bar--bg{opacity:var(--toastify-color-progress-bgo);width:100%;height:100%}.Toastify__spinner{width:20px;height:20px;box-sizing:border-box;border:2px solid;border-radius:100%;border-color:var(--toastify-spinner-color-empty-area);border-right-color:var(--toastify-spinner-color);animation:Toastify__spin .65s linear infinite}@keyframes Toastify__bounceInRight{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(3000px,0,0)}60%{opacity:1;transform:translate3d(-25px,0,0)}75%{transform:translate3d(10px,0,0)}90%{transform:translate3d(-5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutRight{20%{opacity:1;transform:translate3d(-20px,var(--y),0)}to{opacity:0;transform:translate3d(2000px,var(--y),0)}}@keyframes Toastify__bounceInLeft{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(-3000px,0,0)}60%{opacity:1;transform:translate3d(25px,0,0)}75%{transform:translate3d(-10px,0,0)}90%{transform:translate3d(5px,0,0)}to{transform:none}}@keyframes Toastify__bounceOutLeft{20%{opacity:1;transform:translate3d(20px,var(--y),0)}to{opacity:0;transform:translate3d(-2000px,var(--y),0)}}@keyframes Toastify__bounceInUp{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,3000px,0)}60%{opacity:1;transform:translate3d(0,-20px,0)}75%{transform:translate3d(0,10px,0)}90%{transform:translate3d(0,-5px,0)}to{transform:translateZ(0)}}@keyframes Toastify__bounceOutUp{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,-2000px,0)}}@keyframes Toastify__bounceInDown{0%,60%,75%,90%,to{animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;transform:translate3d(0,-3000px,0)}60%{opacity:1;transform:translate3d(0,25px,0)}75%{transform:translate3d(0,-10px,0)}90%{transform:translate3d(0,5px,0)}to{transform:none}}@keyframes Toastify__bounceOutDown{20%{transform:translate3d(0,calc(var(--y) - 10px),0)}40%,45%{opacity:1;transform:translate3d(0,calc(var(--y) + 20px),0)}to{opacity:0;transform:translate3d(0,2000px,0)}}.Toastify__bounce-enter--top-left,.Toastify__bounce-enter--bottom-left{animation-name:Toastify__bounceInLeft}.Toastify__bounce-enter--top-right,.Toastify__bounce-enter--bottom-right{animation-name:Toastify__bounceInRight}.Toastify__bounce-enter--top-center{animation-name:Toastify__bounceInDown}.Toastify__bounce-enter--bottom-center{animation-name:Toastify__bounceInUp}.Toastify__bounce-exit--top-left,.Toastify__bounce-exit--bottom-left{animation-name:Toastify__bounceOutLeft}.Toastify__bounce-exit--top-right,.Toastify__bounce-exit--bottom-right{animation-name:Toastify__bounceOutRight}.Toastify__bounce-exit--top-center{animation-name:Toastify__bounceOutUp}.Toastify__bounce-exit--bottom-center{animation-name:Toastify__bounceOutDown}@keyframes Toastify__zoomIn{0%{opacity:0;transform:scale3d(.3,.3,.3)}50%{opacity:1}}@keyframes Toastify__zoomOut{0%{opacity:1}50%{opacity:0;transform:translate3d(0,var(--y),0) scale3d(.3,.3,.3)}to{opacity:0}}.Toastify__zoom-enter{animation-name:Toastify__zoomIn}.Toastify__zoom-exit{animation-name:Toastify__zoomOut}@keyframes Toastify__flipIn{0%{transform:perspective(400px) rotateX(90deg);animation-timing-function:ease-in;opacity:0}40%{transform:perspective(400px) rotateX(-20deg);animation-timing-function:ease-in}60%{transform:perspective(400px) rotateX(10deg);opacity:1}80%{transform:perspective(400px) rotateX(-5deg)}to{transform:perspective(400px)}}@keyframes Toastify__flipOut{0%{transform:translate3d(0,var(--y),0) perspective(400px)}30%{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(-20deg);opacity:1}to{transform:translate3d(0,var(--y),0) perspective(400px) rotateX(90deg);opacity:0}}.Toastify__flip-enter{animation-name:Toastify__flipIn}.Toastify__flip-exit{animation-name:Toastify__flipOut}@keyframes Toastify__slideInRight{0%{transform:translate3d(110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInLeft{0%{transform:translate3d(-110%,0,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInUp{0%{transform:translate3d(0,110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideInDown{0%{transform:translate3d(0,-110%,0);visibility:visible}to{transform:translate3d(0,var(--y),0)}}@keyframes Toastify__slideOutRight{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(110%,var(--y),0)}}@keyframes Toastify__slideOutLeft{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(-110%,var(--y),0)}}@keyframes Toastify__slideOutDown{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,500px,0)}}@keyframes Toastify__slideOutUp{0%{transform:translate3d(0,var(--y),0)}to{visibility:hidden;transform:translate3d(0,-500px,0)}}.Toastify__slide-enter--top-left,.Toastify__slide-enter--bottom-left{animation-name:Toastify__slideInLeft}.Toastify__slide-enter--top-right,.Toastify__slide-enter--bottom-right{animation-name:Toastify__slideInRight}.Toastify__slide-enter--top-center{animation-name:Toastify__slideInDown}.Toastify__slide-enter--bottom-center{animation-name:Toastify__slideInUp}.Toastify__slide-exit--top-left,.Toastify__slide-exit--bottom-left{animation-name:Toastify__slideOutLeft;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-right,.Toastify__slide-exit--bottom-right{animation-name:Toastify__slideOutRight;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--top-center{animation-name:Toastify__slideOutUp;animation-timing-function:ease-in;animation-duration:.3s}.Toastify__slide-exit--bottom-center{animation-name:Toastify__slideOutDown;animation-timing-function:ease-in;animation-duration:.3s}@keyframes Toastify__spin{0%{transform:rotate(0)}to{transform:rotate(360deg)}}
2
+ `);var or=e=>typeof e=="number"&&!isNaN(e),jt=e=>typeof e=="string",_t=e=>typeof e=="function",Mf=e=>jt(e)||or(e),Za=e=>jt(e)||_t(e)?e:null,Bf=(e,t)=>e===!1||or(e)&&e>0?e:t,Ja=e=>D.isValidElement(e)||jt(e)||_t(e)||or(e);function Ff(e,t,n=300){let{scrollHeight:r,style:a}=e;requestAnimationFrame(()=>{a.minHeight="initial",a.height=r+"px",a.transition=`all ${n}ms`,requestAnimationFrame(()=>{a.height="0",a.padding="0",a.margin="0",setTimeout(t,n)})})}function Hf({enter:e,exit:t,appendPosition:n=!1,collapse:r=!0,collapseDuration:a=300}){return function({children:s,position:i,preventExitTransition:o,done:l,nodeRef:c,isIn:d,playToast:f}){let p=n?`${e}--${i}`:e,h=n?`${t}--${i}`:t,x=D.useRef(0);return D.useLayoutEffect(()=>{let g=c.current,A=p.split(" "),E=_=>{_.target===c.current&&(f(),g.removeEventListener("animationend",E),g.removeEventListener("animationcancel",E),x.current===0&&_.type!=="animationcancel"&&g.classList.remove(...A))};g.classList.add(...A),g.addEventListener("animationend",E),g.addEventListener("animationcancel",E)},[]),D.useEffect(()=>{let g=c.current,A=()=>{g.removeEventListener("animationend",A),r?Ff(g,l,a):l()};d||(o?A():(x.current=1,g.className+=` ${h}`,g.addEventListener("animationend",A)))},[d]),D.createElement(D.Fragment,null,s)}}function ki(e,t){return{content:Ou(e.content,e.props),containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,reason:e.removalReason,status:t}}function Ou(e,t,n=!1){return D.isValidElement(e)&&!jt(e.type)?D.cloneElement(e,{closeToast:t.closeToast,toastProps:t,data:t.data,isPaused:n}):_t(e)?e({closeToast:t.closeToast,toastProps:t,data:t.data,isPaused:n}):e}function Uf({closeToast:e,theme:t,ariaLabel:n="close"}){return D.createElement("button",{className:`Toastify__close-button Toastify__close-button--${t}`,type:"button",onClick:r=>{r.stopPropagation(),e(!0)},"aria-label":n},D.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},D.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function jf({delay:e,isRunning:t,closeToast:n,type:r="default",hide:a,className:s,controlledProgress:i,progress:o,rtl:l,isIn:c,theme:d}){let f=a||i&&o===0,p={animationDuration:`${e}ms`,animationPlayState:t?"running":"paused"};i&&(p.transform=`scaleX(${o})`);let h=yt("Toastify__progress-bar",i?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${d}`,`Toastify__progress-bar--${r}`,{"Toastify__progress-bar--rtl":l}),x=_t(s)?s({rtl:l,type:r,defaultClassName:h}):yt(h,s),g={[i&&o>=1?"onTransitionEnd":"onAnimationEnd"]:i&&o<1?null:()=>{c&&n()}};return D.createElement("div",{className:"Toastify__progress-bar--wrp","data-hidden":f},D.createElement("div",{className:`Toastify__progress-bar--bg Toastify__progress-bar-theme--${d} Toastify__progress-bar--${r}`}),D.createElement("div",{role:"progressbar","aria-hidden":f?"true":"false","aria-label":"notification timer",className:x,style:p,...g}))}var zf=1,Ru=()=>`${zf++}`;function Yf(e,t,n){let r=1,a=0,s=[],i=[],o=t,l=new Map,c=new Set,d=_=>(c.add(_),()=>c.delete(_)),f=()=>{i=Array.from(l.values()),c.forEach(_=>_())},p=({containerId:_,toastId:N,updateId:k})=>{let L=_?_!==e:e!==1,v=l.has(N)&&k==null;return L||v},h=(_,N)=>{l.forEach(k=>{var L;(N==null||N===k.props.toastId)&&((L=k.toggle)==null||L.call(k,_))})},x=_=>{var N,k;(k=(N=_.props)==null?void 0:N.onClose)==null||k.call(N,_.removalReason),_.isActive=!1},g=_=>{if(_==null)l.forEach(x);else{let N=l.get(_);N&&x(N)}f()},A=()=>{a-=s.length,s=[]},E=_=>{var N,k;let{toastId:L,updateId:v}=_.props,R=v==null;_.staleId&&l.delete(_.staleId),_.isActive=!0,l.set(L,_),f(),n(ki(_,R?"added":"updated")),R&&((k=(N=_.props).onOpen)==null||k.call(N))};return{id:e,props:o,observe:d,toggle:h,removeToast:g,toasts:l,clearQueue:A,buildToast:(_,N)=>{if(p(N))return;let{toastId:k,updateId:L,data:v,staleId:R,delay:P}=N,q=L==null;q&&a++;let K={...o,style:o.toastStyle,key:r++,...Object.fromEntries(Object.entries(N).filter(([z,$])=>$!=null)),toastId:k,updateId:L,data:v,isIn:!1,className:Za(N.className||o.toastClassName),progressClassName:Za(N.progressClassName||o.progressClassName),autoClose:N.isLoading?!1:Bf(N.autoClose,o.autoClose),closeToast(z){l.get(k).removalReason=z,g(k)},deleteToast(){let z=l.get(k);if(z!=null){if(n(ki(z,"removed")),l.delete(k),a--,a<0&&(a=0),s.length>0){E(s.shift());return}f()}}};K.closeButton=o.closeButton,N.closeButton===!1||Ja(N.closeButton)?K.closeButton=N.closeButton:N.closeButton===!0&&(K.closeButton=Ja(o.closeButton)?o.closeButton:!0);let U={content:_,props:K,staleId:R};o.limit&&o.limit>0&&a>o.limit&&q?s.push(U):or(P)?setTimeout(()=>{E(U)},P):E(U)},setProps(_){o=_},setToggle:(_,N)=>{let k=l.get(_);k&&(k.toggle=N)},isToastActive:_=>{var N;return(N=l.get(_))==null?void 0:N.isActive},getSnapshot:()=>i}}var Oe=new Map,tr=[],es=new Set,Wf=e=>es.forEach(t=>t(e)),Lu=()=>Oe.size>0;function Vf(){tr.forEach(e=>Du(e.content,e.options)),tr=[]}var $f=(e,{containerId:t})=>{var n;return(n=Oe.get(t||1))==null?void 0:n.toasts.get(e)};function Pu(e,t){var n;if(t)return!!((n=Oe.get(t))!=null&&n.isToastActive(e));let r=!1;return Oe.forEach(a=>{a.isToastActive(e)&&(r=!0)}),r}function qf(e){if(!Lu()){tr=tr.filter(t=>e!=null&&t.options.toastId!==e);return}if(e==null||Mf(e))Oe.forEach(t=>{t.removeToast(e)});else if(e&&("containerId"in e||"id"in e)){let t=Oe.get(e.containerId);t?t.removeToast(e.id):Oe.forEach(n=>{n.removeToast(e.id)})}}var Gf=(e={})=>{Oe.forEach(t=>{t.props.limit&&(!e.containerId||t.id===e.containerId)&&t.clearQueue()})};function Du(e,t){Ja(e)&&(Lu()||tr.push({content:e,options:t}),Oe.forEach(n=>{n.buildToast(e,t)}))}function Xf(e){var t;(t=Oe.get(e.containerId||1))==null||t.setToggle(e.id,e.fn)}function Mu(e,t){Oe.forEach(n=>{(t==null||!(t!=null&&t.containerId)||t?.containerId===n.id)&&n.toggle(e,t?.id)})}function Kf(e){let t=e.containerId||1;return{subscribe(n){let r=Yf(t,e,Wf);Oe.set(t,r);let a=r.observe(n);return Vf(),()=>{a(),Oe.delete(t)}},setProps(n){var r;(r=Oe.get(t))==null||r.setProps(n)},getSnapshot(){var n;return(n=Oe.get(t))==null?void 0:n.getSnapshot()}}}function Qf(e){return es.add(e),()=>{es.delete(e)}}function Zf(e){return e&&(jt(e.toastId)||or(e.toastId))?e.toastId:Ru()}function ur(e,t){return Du(e,t),t.toastId}function Qr(e,t){return{...t,type:t&&t.type||e,toastId:Zf(t)}}function Zr(e){return(t,n)=>ur(t,Qr(e,n))}function de(e,t){return ur(e,Qr("default",t))}de.loading=(e,t)=>ur(e,Qr("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t}));function Jf(e,{pending:t,error:n,success:r},a){let s;t&&(s=jt(t)?de.loading(t,a):de.loading(t.render,{...a,...t}));let i={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},o=(c,d,f)=>{if(d==null){de.dismiss(s);return}let p={type:c,...i,...a,data:f},h=jt(d)?{render:d}:d;return s?de.update(s,{...p,...h}):de(h.render,{...p,...h}),f},l=_t(e)?e():e;return l.then(c=>o("success",r,c)).catch(c=>o("error",n,c)),l}de.promise=Jf;de.success=Zr("success");de.info=Zr("info");de.error=Zr("error");de.warning=Zr("warning");de.warn=de.warning;de.dark=(e,t)=>ur(e,Qr("default",{theme:"dark",...t}));function eh(e){qf(e)}de.dismiss=eh;de.clearWaitingQueue=Gf;de.isActive=Pu;de.update=(e,t={})=>{let n=$f(e,t);if(n){let{props:r,content:a}=n,s={delay:100,...r,...t,toastId:t.toastId||e,updateId:Ru()};s.toastId!==e&&(s.staleId=e);let i=s.render||a;delete s.render,ur(i,s)}};de.done=e=>{de.update(e,{progress:1})};de.onChange=Qf;de.play=e=>Mu(!0,e);de.pause=e=>Mu(!1,e);function th(e){var t;let{subscribe:n,getSnapshot:r,setProps:a}=D.useRef(Kf(e)).current;a(e);let s=(t=D.useSyncExternalStore(n,r,r))==null?void 0:t.slice();function i(o){if(!s)return[];let l=new Map;return e.newestOnTop&&s.reverse(),s.forEach(c=>{let{position:d}=c.props;l.has(d)||l.set(d,[]),l.get(d).push(c)}),Array.from(l,c=>o(c[0],c[1]))}return{getToastToRender:i,isToastActive:Pu,count:s?.length}}function nh(e){let[t,n]=D.useState(!1),[r,a]=D.useState(!1),s=D.useRef(null),i=D.useRef({start:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,didMove:!1}).current,{autoClose:o,pauseOnHover:l,closeToast:c,onClick:d,closeOnClick:f}=e;Xf({id:e.toastId,containerId:e.containerId,fn:n}),D.useEffect(()=>{if(e.pauseOnFocusLoss)return p(),()=>{h()}},[e.pauseOnFocusLoss]);function p(){document.hasFocus()||E(),window.addEventListener("focus",A),window.addEventListener("blur",E)}function h(){window.removeEventListener("focus",A),window.removeEventListener("blur",E)}function x(R){if(e.draggable===!0||e.draggable===R.pointerType){_();let P=s.current;i.canCloseOnClick=!0,i.canDrag=!0,P.style.transition="none",e.draggableDirection==="x"?(i.start=R.clientX,i.removalDistance=P.offsetWidth*(e.draggablePercent/100)):(i.start=R.clientY,i.removalDistance=P.offsetHeight*(e.draggablePercent===80?e.draggablePercent*1.5:e.draggablePercent)/100)}}function g(R){let{top:P,bottom:q,left:K,right:U}=s.current.getBoundingClientRect();R.nativeEvent.type!=="touchend"&&e.pauseOnHover&&R.clientX>=K&&R.clientX<=U&&R.clientY>=P&&R.clientY<=q?E():A()}function A(){n(!0)}function E(){n(!1)}function _(){i.didMove=!1,document.addEventListener("pointermove",k),document.addEventListener("pointerup",L)}function N(){document.removeEventListener("pointermove",k),document.removeEventListener("pointerup",L)}function k(R){let P=s.current;if(i.canDrag&&P){i.didMove=!0,t&&E(),e.draggableDirection==="x"?i.delta=R.clientX-i.start:i.delta=R.clientY-i.start,i.start!==R.clientX&&(i.canCloseOnClick=!1);let q=e.draggableDirection==="x"?`${i.delta}px, var(--y)`:`0, calc(${i.delta}px + var(--y))`;P.style.transform=`translate3d(${q},0)`,P.style.opacity=`${1-Math.abs(i.delta/i.removalDistance)}`}}function L(){N();let R=s.current;if(i.canDrag&&i.didMove&&R){if(i.canDrag=!1,Math.abs(i.delta)>i.removalDistance){a(!0),e.closeToast(!0),e.collapseAll();return}R.style.transition="transform 0.2s, opacity 0.2s",R.style.removeProperty("transform"),R.style.removeProperty("opacity")}}let v={onPointerDown:x,onPointerUp:g};return o&&l&&(v.onMouseEnter=E,e.stacked||(v.onMouseLeave=A)),f&&(v.onClick=R=>{d&&d(R),i.canCloseOnClick&&c(!0)}),{playToast:A,pauseToast:E,isRunning:t,preventExitTransition:r,toastRef:s,eventHandlers:v}}var rh=typeof window<"u"?D.useLayoutEffect:D.useEffect,Jr=({theme:e,type:t,isLoading:n,...r})=>D.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:e==="colored"?"currentColor":`var(--toastify-icon-color-${t})`,...r});function ah(e){return D.createElement(Jr,{...e},D.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))}function sh(e){return D.createElement(Jr,{...e},D.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))}function ih(e){return D.createElement(Jr,{...e},D.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))}function oh(e){return D.createElement(Jr,{...e},D.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))}function uh(){return D.createElement("div",{className:"Toastify__spinner"})}var ts={info:sh,warning:ah,success:ih,error:oh,spinner:uh},lh=e=>e in ts;function ch({theme:e,type:t,isLoading:n,icon:r}){let a=null,s={theme:e,type:t};return r===!1||(_t(r)?a=r({...s,isLoading:n}):D.isValidElement(r)?a=D.cloneElement(r,s):n?a=ts.spinner():lh(t)&&(a=ts[t](s))),a}var dh=e=>{let{isRunning:t,preventExitTransition:n,toastRef:r,eventHandlers:a,playToast:s}=nh(e),{closeButton:i,children:o,autoClose:l,onClick:c,type:d,hideProgressBar:f,closeToast:p,transition:h,position:x,className:g,style:A,progressClassName:E,updateId:_,role:N,progress:k,rtl:L,toastId:v,deleteToast:R,isIn:P,isLoading:q,closeOnClick:K,theme:U,ariaLabel:z}=e,$=yt("Toastify__toast",`Toastify__toast-theme--${U}`,`Toastify__toast--${d}`,{"Toastify__toast--rtl":L},{"Toastify__toast--close-on-click":K}),Y=_t(g)?g({rtl:L,position:x,type:d,defaultClassName:$}):yt($,g),F=ch(e),X=!!k||!l,Q={closeToast:p,type:d,theme:U},B=null;return i===!1||(_t(i)?B=i(Q):D.isValidElement(i)?B=D.cloneElement(i,Q):B=Uf(Q)),D.createElement(h,{isIn:P,done:R,position:x,preventExitTransition:n,nodeRef:r,playToast:s},D.createElement("div",{id:v,tabIndex:0,onClick:c,"data-in":P,className:Y,...a,style:A,ref:r,...P&&{role:N,"aria-label":z}},F!=null&&D.createElement("div",{className:yt("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!q})},F),Ou(o,e,!t),B,!e.customProgressBar&&D.createElement(jf,{..._&&!X?{key:`p-${_}`}:{},rtl:L,theme:U,delay:l,isRunning:t,isIn:P,closeToast:p,hide:f,type:d,className:E,controlledProgress:X,progress:k||0})))},fh=(e,t=!1)=>({enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}),Bu=Hf(fh("bounce",!0)),hh={position:"top-right",transition:Bu,autoClose:5e3,closeButton:!0,pauseOnHover:!0,pauseOnFocusLoss:!0,draggable:"touch",draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light","aria-label":"Notifications Alt+T",hotKeys:e=>e.altKey&&e.code==="KeyT"};function mh(e){let t={...hh,...e},n=e.stacked,[r,a]=D.useState(!0),s=D.useRef(null),{getToastToRender:i,isToastActive:o,count:l}=th(t),{className:c,style:d,rtl:f,containerId:p,hotKeys:h}=t;function x(A){let E=yt("Toastify__toast-container",`Toastify__toast-container--${A}`,{"Toastify__toast-container--rtl":f});return _t(c)?c({position:A,rtl:f,defaultClassName:E}):yt(E,Za(c))}function g(){n&&(a(!0),de.play())}return rh(()=>{var A;if(n){let E=s.current.querySelectorAll('[data-in="true"]'),_=12,N=(A=t.position)==null?void 0:A.includes("top"),k=0,L=0;Array.from(E).reverse().forEach((v,R)=>{let P=v;P.classList.add("Toastify__toast--stacked"),R>0&&(P.dataset.collapsed=`${r}`),P.dataset.pos||(P.dataset.pos=N?"top":"bot");let q=k*(r?.2:1)+(r?0:_*R);P.style.setProperty("--y",`${N?q:q*-1}px`),P.style.setProperty("--g",`${_}`),P.style.setProperty("--s",`${1-(r?L:0)}`),k+=P.offsetHeight,L+=.025})}},[r,l,n]),D.useEffect(()=>{function A(E){var _;let N=s.current;h(E)&&((_=N.querySelector('[tabIndex="0"]'))==null||_.focus(),a(!1),de.pause()),E.key==="Escape"&&(document.activeElement===N||N!=null&&N.contains(document.activeElement))&&(a(!0),de.play())}return document.addEventListener("keydown",A),()=>{document.removeEventListener("keydown",A)}},[h]),D.createElement("section",{ref:s,className:"Toastify",id:p,onMouseEnter:()=>{n&&(a(!1),de.pause())},onMouseLeave:g,"aria-live":"polite","aria-atomic":"false","aria-relevant":"additions text","aria-label":t["aria-label"]},i((A,E)=>{let _=E.length?{...d}:{...d,pointerEvents:"none"};return D.createElement("div",{tabIndex:-1,className:x(A),"data-stacked":n,style:_,key:`c-${A}`},E.map(({content:N,props:k})=>D.createElement(dh,{...k,stacked:n,collapseAll:g,isIn:o(k.toastId,k.containerId),key:`t-${k.key}`},N)))}))}const Vn=Ze.createAsyncThunk("swatches/getSelectedProductThunk",async({assetId:e},{rejectWithValue:t})=>{try{return await Pf({assetId:e})}catch(n){return console.error(n.message),de("Failed to load product"),t(n.message)}}),Re=5,ph={listAttributes:[],productElementOptions:[],materialSelectState:{Finish:[],Color:[],Look:[]},allMaterialsValues:[],selectedMaterials:[],selectedProduct:null,isLoadingSelectedProduct:!1,isOpenMultiProductCart:!1},gh=e=>e.reduce((t,n)=>t+n.count,0),Fu=Ze.createSlice({name:"swatches",initialState:ph,reducers:{setMaterialSelect(e,t){const{filterName:n,values:r}=t.payload;if(r.length===0){e.materialSelectState[n]=[];return}e.materialSelectState[n]=Iu(r)},setPanelFilter(e,t){const n=t.payload.attributes;if(n.length){const r=Fr.getMaterialsValuesFromOptions(n);r?.length&&(e.allMaterialsValues=r)}},clearMaterialFilter:(e,t)=>{e.materialSelectState[t.payload]=[]},clearAllMaterialFilters:e=>{e.materialSelectState={Finish:[],Color:[],Look:[]}},setAllMaterialsOptions:(e,t)=>{const{allMaterialValues:n,productElementOptions:r}=t.payload;n?.length&&(e.allMaterialsValues=n),r?.length&&(e.productElementOptions=r)},setSelectedMaterial(e,t){const{materialCount:n,selectedMaterial:r,selectedMaterials:a,limitCb:s}=t.payload;if(!r)return;const i=l=>l.metadata?.label===r.metadata?.label&&l.parentName===r.parentName,o=a?.some(i);!o&&n>=5&&s&&s(),o?e.selectedMaterials=a.filter(l=>!i(l)):n<5&&(e.selectedMaterials=[...a,r])},resetSelectedMaterials(e){e.selectedMaterials=[]},setSelectedProduct(e,t){e.selectedProduct=t.payload},deleteSelectedProduct(e){e.selectedProduct=null},setIsOpenMultiProductCart(e,t){e.isOpenMultiProductCart=t.payload},removeItem(e,t){const{metadata:n,parentName:r}=t.payload.selectedMaterial;e.selectedMaterials=e.selectedMaterials.filter(a=>!(a.metadata?.label===n?.label&&a.parentName===r))},increment(e,t){const{metadata:n,parentName:r}=t.payload.selectedMaterial,a=e.selectedMaterials.find(s=>s.metadata?.label===n?.label&&s.parentName===r);a&&gh(e.selectedMaterials)<Re&&(a.count+=1)},decrement(e,t){const{metadata:n,parentName:r}=t.payload.selectedMaterial,a=e.selectedMaterials.find(s=>s.metadata?.label===n?.label&&s.parentName===r);a&&a.count>1&&(a.count-=1)},setCount(e,t){const{metadata:n,parentName:r}=t.payload.selectedMaterial,{next:a}=t.payload,s=e.selectedMaterials.find(c=>c.metadata?.label===n?.label&&c.parentName===r);if(!s)return;const i=Math.max(1,Math.floor(a)),o=e.selectedMaterials.filter(c=>!(c.metadata?.label===n?.label&&c.parentName===r)).reduce((c,d)=>c+d.count,0),l=Math.max(1,Re-o);s.count=Math.min(i,l)}},extraReducers:e=>{e.addCase(Vn.pending,t=>{t.isLoadingSelectedProduct=!0}).addCase(Vn.fulfilled,t=>{t.isLoadingSelectedProduct=!1}).addCase(Vn.rejected,t=>{t.isLoadingSelectedProduct=!1})}}),Hu=Fu.reducer,{setMaterialSelect:ea,setAllMaterialsOptions:ns,setPanelFilter:_a,setSelectedMaterial:ta,clearMaterialFilter:sA,clearAllMaterialFilters:bh,setSelectedProduct:Eh,deleteSelectedProduct:Th,setIsOpenMultiProductCart:Uu,resetSelectedMaterials:iA,removeItem:xh,increment:yh,decrement:_h,setCount:oA}=Fu.actions,Ch={items:[]},ju=Ze.createSlice({name:"cart",initialState:Ch,reducers:{setCartItems(e,t){e.items=t.payload},clear(e){e.items=[]}}}),{setCartItems:Ah,clear:uA}=ju.actions,zu=ju.reducer,$n=Ze.createAsyncThunk("multiProducts/getProductListThunk",async(e,{rejectWithValue:t})=>{try{return await Lf()}catch(n){return console.error(n?.message??n),t(n?.message??"Unknown error")}}),Sh={items:[],productList:[],isLoadingProductList:!1,selectedProduct:null,activeMultiCartProduct:null,totalCount:0};function Nh(e,t,n){let r=e.items.find(a=>a.assetId===t);return r?n&&!r.name&&(r.name=n):(r={assetId:t,name:n??"",items:[]},e.items.push(r)),r}const Ca=(e,t)=>e.items.findIndex(n=>n.assetId===t),Oi=(e,t,n,r)=>t===-1?-1:e.items[t].items.findIndex(a=>a.metadata?.label===n&&a.parentName===r),Yu=Ze.createSlice({name:"multiProduct",initialState:Sh,reducers:{setCartForProduct(e,t){const{assetId:n}=t.payload,r=e.items.findIndex(a=>a.assetId===n);r>=0?e.items[r]=t.payload:e.items.push(t.payload)},setActiveMultiCartProduct(e,t){e.activeMultiCartProduct=t.payload},setMultiCartItems(e,t){const{assetId:n,items:r,name:a}=t.payload;if(!r||r.length===0){const i=e.items.findIndex(o=>o.assetId===n);i!==-1&&e.items.splice(i,1);return}const s=Nh(e,n,a);s.items=r},incrementMultiProductItem(e,t){const{assetId:n,label:r,parentName:a}=t.payload,s=Ca(e,n),i=Oi(e,s,r,a);i!==-1&&(e.items[s].items[i].count+=1)},decrementMultiProductItem(e,t){const{assetId:n,label:r,parentName:a}=t.payload,s=Ca(e,n),i=Oi(e,s,r,a);if(i!==-1){const o=e.items[s].items[i];o.count>1&&(o.count-=1)}},removeMultiProductItem(e,t){const{assetId:n,label:r,parentName:a}=t.payload,s=Ca(e,n);if(s===-1)return;const i=e.items[s].items.filter(o=>!(o.metadata?.label===r&&o.parentName===a));e.items[s].items=i},clear(e){e.items=[]}},extraReducers:e=>{e.addCase($n.pending,t=>{t.isLoadingProductList=!0}).addCase($n.fulfilled,(t,n)=>{t.productList=n.payload.rows,t.isLoadingProductList=!1}).addCase($n.rejected,t=>{t.isLoadingProductList=!1})}}),{setCartForProduct:lA,setMultiCartItems:rs,incrementMultiProductItem:Ih,decrementMultiProductItem:vh,removeMultiProductItem:wh,clear:cA,setActiveMultiCartProduct:as}=Yu.actions,Wu=Yu.reducer,kh=Ze.combineReducers({swatches:Hu,cart:zu,multiProductCart:Wu}),Oh={},{NODE_ENV:Rh}=Oh;Ze.configureStore({reducer:kh,middleware:e=>e({thunk:!0,serializableCheck:{ignoredActionPaths:["meta.limitCb","payload.limitCb"],ignoredPaths:[]}}),devTools:Rh!=="production"});const Pe=Tn.useDispatch.withTypes(),oe=Tn.useSelector.withTypes(),lr=e=>e.swatches.allMaterialsValues,xn=e=>e.swatches.materialSelectState,Lh=e=>e.swatches.productElementOptions,$t=e=>e.swatches.selectedMaterials,Vu=e=>e.swatches.isLoadingSelectedProduct,Ph=e=>e.swatches.isOpenMultiProductCart,na=e=>e.swatches.selectedProduct,$u=6.5,qu=({materials:e,containerStyles:t="flex flex-col gap-[8px] text-xs/snug p-[var(--sm-padding)] border-t border-solid border-[var(--border)] sm:gap-[12px] shadow-[0_-2px_10px_rgba(40,40,40,0.10)]"})=>{const n="flex flex-row justify-between items-center",r=D.useMemo(()=>e.reduce((a,s)=>a+(s.count??0),0)*$u,[e]);return m.jsxs("div",{className:t,children:[m.jsxs("div",{className:n,children:[m.jsx("span",{children:"Subtotal"}),m.jsxs("span",{children:["$",r]})]}),m.jsxs("div",{className:`${n} text-[var(--main-accent-color)]`,children:[m.jsx("span",{children:"Savings"}),m.jsxs("span",{children:["-$",r]})]}),m.jsxs("div",{className:`${n} text-sm font-medium`,children:[m.jsx("span",{children:"Total"}),m.jsx("span",{children:"$0"})]})]})},Gu=({children:e,disabled:t,...n})=>m.jsx("button",{className:`w-full bg-[var(--main-accent-color)] text-white py-3 rounded-full font-bold transition-colors duration-300 ${t?"bg-gray-400 text-gray-200 cursor-not-allowed opacity-70":"cursor-pointer hover:opacity-90"}`,...n,children:e}),yn=e=>e.multiProductCart.items,Dh=e=>e.multiProductCart.productList,Mh=e=>e.multiProductCart.isLoadingProductList;class zt{static getImage(t){const n=t?.metadata?.Image||t?.metadata?.image;return n?`https://preview.threekit.com${n}`:void 0}static getValueLabel(t){return t?.metadata?.label||t?.metadata?.Label||t?.name||"Unnamed"}static getZoomIconColor(t){return t?.metadata?.zoomIconColor||t?.metadata?.zoomIconColor||null}static getHexColor(t){return t?.metadata?.hex||t?.metadata?.Hex||null}static getAttributeLabel(t){return t?.metadata?.label||t?.metadata?.Label||t?.name||"Unnamed"}}function Le(e,t,{checkForDefaultPrevented:n=!0}={}){return function(a){if(e?.(a),n===!1||!a.defaultPrevented)return t?.(a)}}function Ri(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ra(...e){return t=>{let n=!1;const r=e.map(a=>{const s=Ri(a,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let a=0;a<r.length;a++){const s=r[a];typeof s=="function"?s():Ri(e[a],null)}}}}function Xe(...e){return y.useCallback(ra(...e),e)}function Bh(e,t){const n=y.createContext(t),r=s=>{const{children:i,...o}=s,l=y.useMemo(()=>o,Object.values(o));return m.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function a(s){const i=y.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,a]}function aa(e,t=[]){let n=[];function r(s,i){const o=y.createContext(i),l=n.length;n=[...n,i];const c=f=>{const{scope:p,children:h,...x}=f,g=p?.[e]?.[l]||o,A=y.useMemo(()=>x,Object.values(x));return m.jsx(g.Provider,{value:A,children:h})};c.displayName=s+"Provider";function d(f,p){const h=p?.[e]?.[l]||o,x=y.useContext(h);if(x)return x;if(i!==void 0)return i;throw new Error(`\`${f}\` must be used within \`${s}\``)}return[c,d]}const a=()=>{const s=n.map(i=>y.createContext(i));return function(o){const l=o?.[e]||s;return y.useMemo(()=>({[`__scope${e}`]:{...o,[e]:l}}),[o,l])}};return a.scopeName=e,[r,Fh(a,...t)]}function Fh(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(a=>({useScope:a(),scopeName:a.scopeName}));return function(s){const i=r.reduce((o,{useScope:l,scopeName:c})=>{const f=l(s)[`__scope${c}`];return{...o,...f}},{});return y.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}var Lt=globalThis?.document?y.useLayoutEffect:()=>{},Hh=y[" useId ".trim().toString()]||(()=>{}),Uh=0;function Or(e){const[t,n]=y.useState(Hh());return Lt(()=>{n(r=>r??String(Uh++))},[e]),e||(t?`radix-${t}`:"")}var jh=y[" useInsertionEffect ".trim().toString()]||Lt;function ws({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[a,s,i]=zh({defaultProp:t,onChange:n}),o=e!==void 0,l=o?e:a;{const d=y.useRef(e!==void 0);y.useEffect(()=>{const f=d.current;f!==o&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${o?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=o},[o,r])}const c=y.useCallback(d=>{if(o){const f=Yh(d)?d(e):d;f!==e&&i.current?.(f)}else s(d)},[o,e,s,i]);return[l,c]}function zh({defaultProp:e,onChange:t}){const[n,r]=y.useState(e),a=y.useRef(n),s=y.useRef(t);return jh(()=>{s.current=t},[t]),y.useEffect(()=>{a.current!==n&&(s.current?.(n),a.current=n)},[n,a]),[n,r,s]}function Yh(e){return typeof e=="function"}function Wh(e){const t=Vh(e),n=y.forwardRef((r,a)=>{const{children:s,...i}=r,o=y.Children.toArray(s),l=o.find(qh);if(l){const c=l.props.children,d=o.map(f=>f===l?y.Children.count(c)>1?y.Children.only(null):y.isValidElement(c)?c.props.children:null:f);return m.jsx(t,{...i,ref:a,children:y.isValidElement(c)?y.cloneElement(c,void 0,d):null})}return m.jsx(t,{...i,ref:a,children:s})});return n.displayName=`${e}.Slot`,n}function Vh(e){const t=y.forwardRef((n,r)=>{const{children:a,...s}=n;if(y.isValidElement(a)){const i=Xh(a),o=Gh(s,a.props);return a.type!==y.Fragment&&(o.ref=r?ra(r,i):i),y.cloneElement(a,o)}return y.Children.count(a)>1?y.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var $h=Symbol("radix.slottable");function qh(e){return y.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===$h}function Gh(e,t){const n={...t};for(const r in t){const a=e[r],s=t[r];/^on[A-Z]/.test(r)?a&&s?n[r]=(...o)=>{const l=s(...o);return a(...o),l}:a&&(n[r]=a):r==="style"?n[r]={...a,...s}:r==="className"&&(n[r]=[a,s].filter(Boolean).join(" "))}return{...e,...n}}function Xh(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Kh=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Ne=Kh.reduce((e,t)=>{const n=Wh(`Primitive.${t}`),r=y.forwardRef((a,s)=>{const{asChild:i,...o}=a,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),m.jsx(l,{...o,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Qh(e,t){e&&Su.flushSync(()=>e.dispatchEvent(t))}function mn(e){const t=y.useRef(e);return y.useEffect(()=>{t.current=e}),y.useMemo(()=>(...n)=>t.current?.(...n),[])}function Zh(e,t=globalThis?.document){const n=mn(e);y.useEffect(()=>{const r=a=>{a.key==="Escape"&&n(a)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var Jh="DismissableLayer",ss="dismissableLayer.update",e0="dismissableLayer.pointerDownOutside",t0="dismissableLayer.focusOutside",Li,Xu=y.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),ks=y.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:a,onFocusOutside:s,onInteractOutside:i,onDismiss:o,...l}=e,c=y.useContext(Xu),[d,f]=y.useState(null),p=d?.ownerDocument??globalThis?.document,[,h]=y.useState({}),x=Xe(t,R=>f(R)),g=Array.from(c.layers),[A]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),E=g.indexOf(A),_=d?g.indexOf(d):-1,N=c.layersWithOutsidePointerEventsDisabled.size>0,k=_>=E,L=a0(R=>{const P=R.target,q=[...c.branches].some(K=>K.contains(P));!k||q||(a?.(R),i?.(R),R.defaultPrevented||o?.())},p),v=s0(R=>{const P=R.target;[...c.branches].some(K=>K.contains(P))||(s?.(R),i?.(R),R.defaultPrevented||o?.())},p);return Zh(R=>{_===c.layers.size-1&&(r?.(R),!R.defaultPrevented&&o&&(R.preventDefault(),o()))},p),y.useEffect(()=>{if(d)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(Li=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(d)),c.layers.add(d),Pi(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=Li)}},[d,p,n,c]),y.useEffect(()=>()=>{d&&(c.layers.delete(d),c.layersWithOutsidePointerEventsDisabled.delete(d),Pi())},[d,c]),y.useEffect(()=>{const R=()=>h({});return document.addEventListener(ss,R),()=>document.removeEventListener(ss,R)},[]),m.jsx(Ne.div,{...l,ref:x,style:{pointerEvents:N?k?"auto":"none":void 0,...e.style},onFocusCapture:Le(e.onFocusCapture,v.onFocusCapture),onBlurCapture:Le(e.onBlurCapture,v.onBlurCapture),onPointerDownCapture:Le(e.onPointerDownCapture,L.onPointerDownCapture)})});ks.displayName=Jh;var n0="DismissableLayerBranch",r0=y.forwardRef((e,t)=>{const n=y.useContext(Xu),r=y.useRef(null),a=Xe(t,r);return y.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),m.jsx(Ne.div,{...e,ref:a})});r0.displayName=n0;function a0(e,t=globalThis?.document){const n=mn(e),r=y.useRef(!1),a=y.useRef(()=>{});return y.useEffect(()=>{const s=o=>{if(o.target&&!r.current){let l=function(){Ku(e0,n,c,{discrete:!0})};const c={originalEvent:o};o.pointerType==="touch"?(t.removeEventListener("click",a.current),a.current=l,t.addEventListener("click",a.current,{once:!0})):l()}else t.removeEventListener("click",a.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",s),t.removeEventListener("click",a.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function s0(e,t=globalThis?.document){const n=mn(e),r=y.useRef(!1);return y.useEffect(()=>{const a=s=>{s.target&&!r.current&&Ku(t0,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",a),()=>t.removeEventListener("focusin",a)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function Pi(){const e=new CustomEvent(ss);document.dispatchEvent(e)}function Ku(e,t,n,{discrete:r}){const a=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&a.addEventListener(e,t,{once:!0}),r?Qh(a,s):a.dispatchEvent(s)}var Aa="focusScope.autoFocusOnMount",Sa="focusScope.autoFocusOnUnmount",Di={bubbles:!1,cancelable:!0},i0="FocusScope",Os=y.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:a,onUnmountAutoFocus:s,...i}=e,[o,l]=y.useState(null),c=mn(a),d=mn(s),f=y.useRef(null),p=Xe(t,g=>l(g)),h=y.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;y.useEffect(()=>{if(r){let g=function(N){if(h.paused||!o)return;const k=N.target;o.contains(k)?f.current=k:vt(f.current,{select:!0})},A=function(N){if(h.paused||!o)return;const k=N.relatedTarget;k!==null&&(o.contains(k)||vt(f.current,{select:!0}))},E=function(N){if(document.activeElement===document.body)for(const L of N)L.removedNodes.length>0&&vt(o)};document.addEventListener("focusin",g),document.addEventListener("focusout",A);const _=new MutationObserver(E);return o&&_.observe(o,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",A),_.disconnect()}}},[r,o,h.paused]),y.useEffect(()=>{if(o){Bi.add(h);const g=document.activeElement;if(!o.contains(g)){const E=new CustomEvent(Aa,Di);o.addEventListener(Aa,c),o.dispatchEvent(E),E.defaultPrevented||(o0(f0(Qu(o)),{select:!0}),document.activeElement===g&&vt(o))}return()=>{o.removeEventListener(Aa,c),setTimeout(()=>{const E=new CustomEvent(Sa,Di);o.addEventListener(Sa,d),o.dispatchEvent(E),E.defaultPrevented||vt(g??document.body,{select:!0}),o.removeEventListener(Sa,d),Bi.remove(h)},0)}}},[o,c,d,h]);const x=y.useCallback(g=>{if(!n&&!r||h.paused)return;const A=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,E=document.activeElement;if(A&&E){const _=g.currentTarget,[N,k]=u0(_);N&&k?!g.shiftKey&&E===k?(g.preventDefault(),n&&vt(N,{select:!0})):g.shiftKey&&E===N&&(g.preventDefault(),n&&vt(k,{select:!0})):E===_&&g.preventDefault()}},[n,r,h.paused]);return m.jsx(Ne.div,{tabIndex:-1,...i,ref:p,onKeyDown:x})});Os.displayName=i0;function o0(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(vt(r,{select:t}),document.activeElement!==n)return}function u0(e){const t=Qu(e),n=Mi(t,e),r=Mi(t.reverse(),e);return[n,r]}function Qu(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const a=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||a?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Mi(e,t){for(const n of e)if(!l0(n,{upTo:t}))return n}function l0(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function c0(e){return e instanceof HTMLInputElement&&"select"in e}function vt(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&c0(e)&&t&&e.select()}}var Bi=d0();function d0(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=Fi(e,t),e.unshift(t)},remove(t){e=Fi(e,t),e[0]?.resume()}}}function Fi(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function f0(e){return e.filter(t=>t.tagName!=="A")}var h0="Portal",Zu=y.forwardRef((e,t)=>{const{container:n,...r}=e,[a,s]=y.useState(!1);Lt(()=>s(!0),[]);const i=n||a&&globalThis?.document?.body;return i?Vt.createPortal(m.jsx(Ne.div,{...r,ref:t}),i):null});Zu.displayName=h0;function m0(e,t){return y.useReducer((n,r)=>t[n][r]??n,e)}var _n=e=>{const{present:t,children:n}=e,r=p0(t),a=typeof n=="function"?n({present:r.isPresent}):y.Children.only(n),s=Xe(r.ref,g0(a));return typeof n=="function"||r.isPresent?y.cloneElement(a,{ref:s}):null};_n.displayName="Presence";function p0(e){const[t,n]=y.useState(),r=y.useRef(null),a=y.useRef(e),s=y.useRef("none"),i=e?"mounted":"unmounted",[o,l]=m0(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return y.useEffect(()=>{const c=Tr(r.current);s.current=o==="mounted"?c:"none"},[o]),Lt(()=>{const c=r.current,d=a.current;if(d!==e){const p=s.current,h=Tr(c);e?l("MOUNT"):h==="none"||c?.display==="none"?l("UNMOUNT"):l(d&&p!==h?"ANIMATION_OUT":"UNMOUNT"),a.current=e}},[e,l]),Lt(()=>{if(t){let c;const d=t.ownerDocument.defaultView??window,f=h=>{const g=Tr(r.current).includes(CSS.escape(h.animationName));if(h.target===t&&g&&(l("ANIMATION_END"),!a.current)){const A=t.style.animationFillMode;t.style.animationFillMode="forwards",c=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=A)})}},p=h=>{h.target===t&&(s.current=Tr(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(c),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(o),ref:y.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function Tr(e){return e?.animationName||"none"}function g0(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var Na=0;function Ju(){y.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Hi()),document.body.insertAdjacentElement("beforeend",e[1]??Hi()),Na++,()=>{Na===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Na--}},[])}function Hi(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var lt=function(){return lt=Object.assign||function(t){for(var n,r=1,a=arguments.length;r<a;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},lt.apply(this,arguments)};function el(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var a=0,r=Object.getOwnPropertySymbols(e);a<r.length;a++)t.indexOf(r[a])<0&&Object.prototype.propertyIsEnumerable.call(e,r[a])&&(n[r[a]]=e[r[a]]);return n}function b0(e,t,n){if(n||arguments.length===2)for(var r=0,a=t.length,s;r<a;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var Rr="right-scroll-bar-position",Lr="width-before-scroll-bar",E0="with-scroll-bars-hidden",T0="--removed-body-scroll-bar-size";function Ia(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function x0(e,t){var n=D.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var a=n.value;a!==r&&(n.value=r,n.callback(r,a))}}}})[0];return n.callback=t,n.facade}var y0=typeof window<"u"?y.useLayoutEffect:y.useEffect,Ui=new WeakMap;function _0(e,t){var n=x0(null,function(r){return e.forEach(function(a){return Ia(a,r)})});return y0(function(){var r=Ui.get(n);if(r){var a=new Set(r),s=new Set(e),i=n.current;a.forEach(function(o){s.has(o)||Ia(o,null)}),s.forEach(function(o){a.has(o)||Ia(o,i)})}Ui.set(n,e)},[e]),n}function C0(e){return e}function A0(e,t){t===void 0&&(t=C0);var n=[],r=!1,a={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(s){var i=t(s,r);return n.push(i),function(){n=n.filter(function(o){return o!==i})}},assignSyncMedium:function(s){for(r=!0;n.length;){var i=n;n=[],i.forEach(s)}n={push:function(o){return s(o)},filter:function(){return n}}},assignMedium:function(s){r=!0;var i=[];if(n.length){var o=n;n=[],o.forEach(s),i=n}var l=function(){var d=i;i=[],d.forEach(s)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(d){i.push(d),c()},filter:function(d){return i=i.filter(d),n}}}};return a}function S0(e){e===void 0&&(e={});var t=A0(null);return t.options=lt({async:!0,ssr:!1},e),t}var tl=function(e){var t=e.sideCar,n=el(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return y.createElement(r,lt({},n))};tl.isSideCarExport=!0;function N0(e,t){return e.useMedium(t),tl}var nl=S0(),va=function(){},sa=y.forwardRef(function(e,t){var n=y.useRef(null),r=y.useState({onScrollCapture:va,onWheelCapture:va,onTouchMoveCapture:va}),a=r[0],s=r[1],i=e.forwardProps,o=e.children,l=e.className,c=e.removeScrollBar,d=e.enabled,f=e.shards,p=e.sideCar,h=e.noRelative,x=e.noIsolation,g=e.inert,A=e.allowPinchZoom,E=e.as,_=E===void 0?"div":E,N=e.gapMode,k=el(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),L=p,v=_0([n,t]),R=lt(lt({},k),a);return y.createElement(y.Fragment,null,d&&y.createElement(L,{sideCar:nl,removeScrollBar:c,shards:f,noRelative:h,noIsolation:x,inert:g,setCallbacks:s,allowPinchZoom:!!A,lockRef:n,gapMode:N}),i?y.cloneElement(y.Children.only(o),lt(lt({},R),{ref:v})):y.createElement(_,lt({},R,{className:l,ref:v}),o))});sa.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};sa.classNames={fullWidth:Lr,zeroRight:Rr};var I0=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function v0(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=I0();return t&&e.setAttribute("nonce",t),e}function w0(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function k0(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var O0=function(){var e=0,t=null;return{add:function(n){e==0&&(t=v0())&&(w0(t,n),k0(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},R0=function(){var e=O0();return function(t,n){y.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},rl=function(){var e=R0(),t=function(n){var r=n.styles,a=n.dynamic;return e(r,a),null};return t},L0={left:0,top:0,right:0,gap:0},wa=function(e){return parseInt(e||"",10)||0},P0=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],a=t[e==="padding"?"paddingRight":"marginRight"];return[wa(n),wa(r),wa(a)]},D0=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return L0;var t=P0(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},M0=rl(),ln="data-scroll-locked",B0=function(e,t,n,r){var a=e.left,s=e.top,i=e.right,o=e.gap;return n===void 0&&(n="margin"),`
3
+ .`.concat(E0,` {
4
+ overflow: hidden `).concat(r,`;
5
+ padding-right: `).concat(o,"px ").concat(r,`;
6
+ }
7
+ body[`).concat(ln,`] {
8
+ overflow: hidden `).concat(r,`;
9
+ overscroll-behavior: contain;
10
+ `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
11
+ padding-left: `.concat(a,`px;
12
+ padding-top: `).concat(s,`px;
13
+ padding-right: `).concat(i,`px;
14
+ margin-left:0;
15
+ margin-top:0;
16
+ margin-right: `).concat(o,"px ").concat(r,`;
17
+ `),n==="padding"&&"padding-right: ".concat(o,"px ").concat(r,";")].filter(Boolean).join(""),`
18
+ }
19
+
20
+ .`).concat(Rr,` {
21
+ right: `).concat(o,"px ").concat(r,`;
22
+ }
23
+
24
+ .`).concat(Lr,` {
25
+ margin-right: `).concat(o,"px ").concat(r,`;
26
+ }
27
+
28
+ .`).concat(Rr," .").concat(Rr,` {
29
+ right: 0 `).concat(r,`;
30
+ }
31
+
32
+ .`).concat(Lr," .").concat(Lr,` {
33
+ margin-right: 0 `).concat(r,`;
34
+ }
35
+
36
+ body[`).concat(ln,`] {
37
+ `).concat(T0,": ").concat(o,`px;
38
+ }
39
+ `)},ji=function(){var e=parseInt(document.body.getAttribute(ln)||"0",10);return isFinite(e)?e:0},F0=function(){y.useEffect(function(){return document.body.setAttribute(ln,(ji()+1).toString()),function(){var e=ji()-1;e<=0?document.body.removeAttribute(ln):document.body.setAttribute(ln,e.toString())}},[])},H0=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,a=r===void 0?"margin":r;F0();var s=y.useMemo(function(){return D0(a)},[a]);return y.createElement(M0,{styles:B0(s,!t,a,n?"":"!important")})},is=!1;if(typeof window<"u")try{var xr=Object.defineProperty({},"passive",{get:function(){return is=!0,!0}});window.addEventListener("test",xr,xr),window.removeEventListener("test",xr,xr)}catch{is=!1}var en=is?{passive:!1}:!1,U0=function(e){return e.tagName==="TEXTAREA"},al=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!U0(e)&&n[t]==="visible")},j0=function(e){return al(e,"overflowY")},z0=function(e){return al(e,"overflowX")},zi=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var a=sl(e,r);if(a){var s=il(e,r),i=s[1],o=s[2];if(i>o)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},Y0=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},W0=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},sl=function(e,t){return e==="v"?j0(t):z0(t)},il=function(e,t){return e==="v"?Y0(t):W0(t)},V0=function(e,t){return e==="h"&&t==="rtl"?-1:1},$0=function(e,t,n,r,a){var s=V0(e,window.getComputedStyle(t).direction),i=s*r,o=n.target,l=t.contains(o),c=!1,d=i>0,f=0,p=0;do{if(!o)break;var h=il(e,o),x=h[0],g=h[1],A=h[2],E=g-A-s*x;(x||E)&&sl(e,o)&&(f+=E,p+=x);var _=o.parentNode;o=_&&_.nodeType===Node.DOCUMENT_FRAGMENT_NODE?_.host:_}while(!l&&o!==document.body||l&&(t.contains(o)||t===o));return(d&&Math.abs(f)<1||!d&&Math.abs(p)<1)&&(c=!0),c},yr=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Yi=function(e){return[e.deltaX,e.deltaY]},Wi=function(e){return e&&"current"in e?e.current:e},q0=function(e,t){return e[0]===t[0]&&e[1]===t[1]},G0=function(e){return`
40
+ .block-interactivity-`.concat(e,` {pointer-events: none;}
41
+ .allow-interactivity-`).concat(e,` {pointer-events: all;}
42
+ `)},X0=0,tn=[];function K0(e){var t=y.useRef([]),n=y.useRef([0,0]),r=y.useRef(),a=y.useState(X0++)[0],s=y.useState(rl)[0],i=y.useRef(e);y.useEffect(function(){i.current=e},[e]),y.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(a));var g=b0([e.lockRef.current],(e.shards||[]).map(Wi),!0).filter(Boolean);return g.forEach(function(A){return A.classList.add("allow-interactivity-".concat(a))}),function(){document.body.classList.remove("block-interactivity-".concat(a)),g.forEach(function(A){return A.classList.remove("allow-interactivity-".concat(a))})}}},[e.inert,e.lockRef.current,e.shards]);var o=y.useCallback(function(g,A){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!i.current.allowPinchZoom;var E=yr(g),_=n.current,N="deltaX"in g?g.deltaX:_[0]-E[0],k="deltaY"in g?g.deltaY:_[1]-E[1],L,v=g.target,R=Math.abs(N)>Math.abs(k)?"h":"v";if("touches"in g&&R==="h"&&v.type==="range")return!1;var P=zi(R,v);if(!P)return!0;if(P?L=R:(L=R==="v"?"h":"v",P=zi(R,v)),!P)return!1;if(!r.current&&"changedTouches"in g&&(N||k)&&(r.current=L),!L)return!0;var q=r.current||L;return $0(q,A,g,q==="h"?N:k)},[]),l=y.useCallback(function(g){var A=g;if(!(!tn.length||tn[tn.length-1]!==s)){var E="deltaY"in A?Yi(A):yr(A),_=t.current.filter(function(L){return L.name===A.type&&(L.target===A.target||A.target===L.shadowParent)&&q0(L.delta,E)})[0];if(_&&_.should){A.cancelable&&A.preventDefault();return}if(!_){var N=(i.current.shards||[]).map(Wi).filter(Boolean).filter(function(L){return L.contains(A.target)}),k=N.length>0?o(A,N[0]):!i.current.noIsolation;k&&A.cancelable&&A.preventDefault()}}},[]),c=y.useCallback(function(g,A,E,_){var N={name:g,delta:A,target:E,should:_,shadowParent:Q0(E)};t.current.push(N),setTimeout(function(){t.current=t.current.filter(function(k){return k!==N})},1)},[]),d=y.useCallback(function(g){n.current=yr(g),r.current=void 0},[]),f=y.useCallback(function(g){c(g.type,Yi(g),g.target,o(g,e.lockRef.current))},[]),p=y.useCallback(function(g){c(g.type,yr(g),g.target,o(g,e.lockRef.current))},[]);y.useEffect(function(){return tn.push(s),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:p}),document.addEventListener("wheel",l,en),document.addEventListener("touchmove",l,en),document.addEventListener("touchstart",d,en),function(){tn=tn.filter(function(g){return g!==s}),document.removeEventListener("wheel",l,en),document.removeEventListener("touchmove",l,en),document.removeEventListener("touchstart",d,en)}},[]);var h=e.removeScrollBar,x=e.inert;return y.createElement(y.Fragment,null,x?y.createElement(s,{styles:G0(a)}):null,h?y.createElement(H0,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function Q0(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const Z0=N0(nl,K0);var Rs=y.forwardRef(function(e,t){return y.createElement(sa,lt({},e,{ref:t,sideCar:Z0}))});Rs.classNames=sa.classNames;var J0=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},nn=new WeakMap,_r=new WeakMap,Cr={},ka=0,ol=function(e){return e&&(e.host||ol(e.parentNode))},em=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=ol(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},tm=function(e,t,n,r){var a=em(t,Array.isArray(e)?e:[e]);Cr[n]||(Cr[n]=new WeakMap);var s=Cr[n],i=[],o=new Set,l=new Set(a),c=function(f){!f||o.has(f)||(o.add(f),c(f.parentNode))};a.forEach(c);var d=function(f){!f||l.has(f)||Array.prototype.forEach.call(f.children,function(p){if(o.has(p))d(p);else try{var h=p.getAttribute(r),x=h!==null&&h!=="false",g=(nn.get(p)||0)+1,A=(s.get(p)||0)+1;nn.set(p,g),s.set(p,A),i.push(p),g===1&&x&&_r.set(p,!0),A===1&&p.setAttribute(n,"true"),x||p.setAttribute(r,"true")}catch(E){console.error("aria-hidden: cannot operate on ",p,E)}})};return d(t),o.clear(),ka++,function(){i.forEach(function(f){var p=nn.get(f)-1,h=s.get(f)-1;nn.set(f,p),s.set(f,h),p||(_r.has(f)||f.removeAttribute(r),_r.delete(f)),h||f.removeAttribute(n)}),ka--,ka||(nn=new WeakMap,nn=new WeakMap,_r=new WeakMap,Cr={})}},ul=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),a=J0(e);return a?(r.push.apply(r,Array.from(a.querySelectorAll("[aria-live], script"))),tm(r,a,n,"aria-hidden")):function(){return null}};function nm(e){const t=rm(e),n=y.forwardRef((r,a)=>{const{children:s,...i}=r,o=y.Children.toArray(s),l=o.find(sm);if(l){const c=l.props.children,d=o.map(f=>f===l?y.Children.count(c)>1?y.Children.only(null):y.isValidElement(c)?c.props.children:null:f);return m.jsx(t,{...i,ref:a,children:y.isValidElement(c)?y.cloneElement(c,void 0,d):null})}return m.jsx(t,{...i,ref:a,children:s})});return n.displayName=`${e}.Slot`,n}function rm(e){const t=y.forwardRef((n,r)=>{const{children:a,...s}=n;if(y.isValidElement(a)){const i=om(a),o=im(s,a.props);return a.type!==y.Fragment&&(o.ref=r?ra(r,i):i),y.cloneElement(a,o)}return y.Children.count(a)>1?y.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var am=Symbol("radix.slottable");function sm(e){return y.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===am}function im(e,t){const n={...t};for(const r in t){const a=e[r],s=t[r];/^on[A-Z]/.test(r)?a&&s?n[r]=(...o)=>{const l=s(...o);return a(...o),l}:a&&(n[r]=a):r==="style"?n[r]={...a,...s}:r==="className"&&(n[r]=[a,s].filter(Boolean).join(" "))}return{...e,...n}}function om(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var ia="Dialog",[ll]=aa(ia),[um,at]=ll(ia),cl=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:a,onOpenChange:s,modal:i=!0}=e,o=y.useRef(null),l=y.useRef(null),[c,d]=ws({prop:r,defaultProp:a??!1,onChange:s,caller:ia});return m.jsx(um,{scope:t,triggerRef:o,contentRef:l,contentId:Or(),titleId:Or(),descriptionId:Or(),open:c,onOpenChange:d,onOpenToggle:y.useCallback(()=>d(f=>!f),[d]),modal:i,children:n})};cl.displayName=ia;var dl="DialogTrigger",lm=y.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,a=at(dl,n),s=Xe(t,a.triggerRef);return m.jsx(Ne.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":Ds(a.open),...r,ref:s,onClick:Le(e.onClick,a.onOpenToggle)})});lm.displayName=dl;var Ls="DialogPortal",[cm,fl]=ll(Ls,{forceMount:void 0}),hl=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:a}=e,s=at(Ls,t);return m.jsx(cm,{scope:t,forceMount:n,children:y.Children.map(r,i=>m.jsx(_n,{present:n||s.open,children:m.jsx(Zu,{asChild:!0,container:a,children:i})}))})};hl.displayName=Ls;var Hr="DialogOverlay",ml=y.forwardRef((e,t)=>{const n=fl(Hr,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,s=at(Hr,e.__scopeDialog);return s.modal?m.jsx(_n,{present:r||s.open,children:m.jsx(fm,{...a,ref:t})}):null});ml.displayName=Hr;var dm=nm("DialogOverlay.RemoveScroll"),fm=y.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,a=at(Hr,n);return m.jsx(Rs,{as:dm,allowPinchZoom:!0,shards:[a.contentRef],children:m.jsx(Ne.div,{"data-state":Ds(a.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Yt="DialogContent",pl=y.forwardRef((e,t)=>{const n=fl(Yt,e.__scopeDialog),{forceMount:r=n.forceMount,...a}=e,s=at(Yt,e.__scopeDialog);return m.jsx(_n,{present:r||s.open,children:s.modal?m.jsx(hm,{...a,ref:t}):m.jsx(mm,{...a,ref:t})})});pl.displayName=Yt;var hm=y.forwardRef((e,t)=>{const n=at(Yt,e.__scopeDialog),r=y.useRef(null),a=Xe(t,n.contentRef,r);return y.useEffect(()=>{const s=r.current;if(s)return ul(s)},[]),m.jsx(gl,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Le(e.onCloseAutoFocus,s=>{s.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:Le(e.onPointerDownOutside,s=>{const i=s.detail.originalEvent,o=i.button===0&&i.ctrlKey===!0;(i.button===2||o)&&s.preventDefault()}),onFocusOutside:Le(e.onFocusOutside,s=>s.preventDefault())})}),mm=y.forwardRef((e,t)=>{const n=at(Yt,e.__scopeDialog),r=y.useRef(!1),a=y.useRef(!1);return m.jsx(gl,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(r.current||n.triggerRef.current?.focus(),s.preventDefault()),r.current=!1,a.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(a.current=!0));const i=s.target;n.triggerRef.current?.contains(i)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&a.current&&s.preventDefault()}})}),gl=y.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:s,...i}=e,o=at(Yt,n),l=y.useRef(null),c=Xe(t,l);return Ju(),m.jsxs(m.Fragment,{children:[m.jsx(Os,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:s,children:m.jsx(ks,{role:"dialog",id:o.contentId,"aria-describedby":o.descriptionId,"aria-labelledby":o.titleId,"data-state":Ds(o.open),...i,ref:c,onDismiss:()=>o.onOpenChange(!1)})}),m.jsxs(m.Fragment,{children:[m.jsx(pm,{titleId:o.titleId}),m.jsx(bm,{contentRef:l,descriptionId:o.descriptionId})]})]})}),Ps="DialogTitle",bl=y.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,a=at(Ps,n);return m.jsx(Ne.h2,{id:a.titleId,...r,ref:t})});bl.displayName=Ps;var El="DialogDescription",Tl=y.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,a=at(El,n);return m.jsx(Ne.p,{id:a.descriptionId,...r,ref:t})});Tl.displayName=El;var xl="DialogClose",yl=y.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,a=at(xl,n);return m.jsx(Ne.button,{type:"button",...r,ref:t,onClick:Le(e.onClick,()=>a.onOpenChange(!1))})});yl.displayName=xl;function Ds(e){return e?"open":"closed"}var _l="DialogTitleWarning",[dA,Cl]=Bh(_l,{contentName:Yt,titleName:Ps,docsSlug:"dialog"}),pm=({titleId:e})=>{const t=Cl(_l),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
43
+
44
+ If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
45
+
46
+ For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return y.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},gm="DialogDescriptionWarning",bm=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${Cl(gm).contentName}}.`;return y.useEffect(()=>{const a=e.current?.getAttribute("aria-describedby");t&&a&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},Em=cl,Tm=hl,Al=ml,Sl=pl,Nl=bl,Il=Tl,xm=yl;const ym=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),_m=e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,(t,n,r)=>r?r.toUpperCase():n.toLowerCase()),Vi=e=>{const t=_m(e);return t.charAt(0).toUpperCase()+t.slice(1)},vl=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();var Cm={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const Am=D.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:a="",children:s,iconNode:i,...o},l)=>D.createElement("svg",{ref:l,...Cm,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:vl("lucide",a),...o},[...i.map(([c,d])=>D.createElement(c,d)),...Array.isArray(s)?s:[s]]));const Ms=(e,t)=>{const n=D.forwardRef(({className:r,...a},s)=>D.createElement(Am,{ref:s,iconNode:t,className:vl(`lucide-${ym(Vi(e))}`,`lucide-${e}`,r),...a}));return n.displayName=Vi(e),n};const Sm=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],wl=Ms("check",Sm);const Nm=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],kl=Ms("chevron-down",Nm);const Im=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],Bs=Ms("x",Im),vm=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},wm=(e,t)=>({classGroupId:e,validator:t}),Ol=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),Ur="-",$i=[],km="arbitrary..",Om=e=>{const t=Lm(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{if(i.startsWith("[")&&i.endsWith("]"))return Rm(i);const o=i.split(Ur),l=o[0]===""&&o.length>1?1:0;return Rl(o,l,t)},getConflictingClassGroupIds:(i,o)=>{if(o){const l=r[i],c=n[i];return l?c?vm(c,l):l:c||$i}return n[i]||$i}}},Rl=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const a=e[t],s=n.nextPart.get(a);if(s){const c=Rl(e,t+1,s);if(c)return c}const i=n.validators;if(i===null)return;const o=t===0?e.join(Ur):e.slice(t).join(Ur),l=i.length;for(let c=0;c<l;c++){const d=i[c];if(d.validator(o))return d.classGroupId}},Rm=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?km+r:void 0})(),Lm=e=>{const{theme:t,classGroups:n}=e;return Pm(n,t)},Pm=(e,t)=>{const n=Ol();for(const r in e){const a=e[r];Fs(a,n,r,t)}return n},Fs=(e,t,n,r)=>{const a=e.length;for(let s=0;s<a;s++){const i=e[s];Dm(i,t,n,r)}},Dm=(e,t,n,r)=>{if(typeof e=="string"){Mm(e,t,n);return}if(typeof e=="function"){Bm(e,t,n,r);return}Fm(e,t,n,r)},Mm=(e,t,n)=>{const r=e===""?t:Ll(t,e);r.classGroupId=n},Bm=(e,t,n,r)=>{if(Hm(e)){Fs(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(wm(n,e))},Fm=(e,t,n,r)=>{const a=Object.entries(e),s=a.length;for(let i=0;i<s;i++){const[o,l]=a[i];Fs(l,Ll(t,o),n,r)}},Ll=(e,t)=>{let n=e;const r=t.split(Ur),a=r.length;for(let s=0;s<a;s++){const i=r[s];let o=n.nextPart.get(i);o||(o=Ol(),n.nextPart.set(i,o)),n=o}return n},Hm=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,Um=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const a=(s,i)=>{n[s]=i,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(s){let i=n[s];if(i!==void 0)return i;if((i=r[s])!==void 0)return a(s,i),i},set(s,i){s in n?n[s]=i:a(s,i)}}},os="!",qi=":",jm=[],Gi=(e,t,n,r,a)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:a}),zm=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=a=>{const s=[];let i=0,o=0,l=0,c;const d=a.length;for(let g=0;g<d;g++){const A=a[g];if(i===0&&o===0){if(A===qi){s.push(a.slice(l,g)),l=g+1;continue}if(A==="/"){c=g;continue}}A==="["?i++:A==="]"?i--:A==="("?o++:A===")"&&o--}const f=s.length===0?a:a.slice(l);let p=f,h=!1;f.endsWith(os)?(p=f.slice(0,-1),h=!0):f.startsWith(os)&&(p=f.slice(1),h=!0);const x=c&&c>l?c-l:void 0;return Gi(s,h,p,x)};if(t){const a=t+qi,s=r;r=i=>i.startsWith(a)?s(i.slice(a.length)):Gi(jm,!1,i,void 0,!0)}if(n){const a=r;r=s=>n({className:s,parseClassName:a})}return r},Ym=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let a=[];for(let s=0;s<n.length;s++){const i=n[s],o=i[0]==="[",l=t.has(i);o||l?(a.length>0&&(a.sort(),r.push(...a),a=[]),r.push(i)):a.push(i)}return a.length>0&&(a.sort(),r.push(...a)),r}},Wm=e=>({cache:Um(e.cacheSize),parseClassName:zm(e),sortModifiers:Ym(e),...Om(e)}),Vm=/\s+/,$m=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:a,sortModifiers:s}=t,i=[],o=e.trim().split(Vm);let l="";for(let c=o.length-1;c>=0;c-=1){const d=o[c],{isExternal:f,modifiers:p,hasImportantModifier:h,baseClassName:x,maybePostfixModifierPosition:g}=n(d);if(f){l=d+(l.length>0?" "+l:l);continue}let A=!!g,E=r(A?x.substring(0,g):x);if(!E){if(!A){l=d+(l.length>0?" "+l:l);continue}if(E=r(x),!E){l=d+(l.length>0?" "+l:l);continue}A=!1}const _=p.length===0?"":p.length===1?p[0]:s(p).join(":"),N=h?_+os:_,k=N+E;if(i.indexOf(k)>-1)continue;i.push(k);const L=a(E,A);for(let v=0;v<L.length;++v){const R=L[v];i.push(N+R)}l=d+(l.length>0?" "+l:l)}return l},qm=(...e)=>{let t=0,n,r,a="";for(;t<e.length;)(n=e[t++])&&(r=Pl(n))&&(a&&(a+=" "),a+=r);return a},Pl=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Pl(e[r]))&&(n&&(n+=" "),n+=t);return n},Gm=(e,...t)=>{let n,r,a,s;const i=l=>{const c=t.reduce((d,f)=>f(d),e());return n=Wm(c),r=n.cache.get,a=n.cache.set,s=o,o(l)},o=l=>{const c=r(l);if(c)return c;const d=$m(l,n);return a(l,d),d};return s=i,(...l)=>s(qm(...l))},Xm=[],Ce=e=>{const t=n=>n[e]||Xm;return t.isThemeGetter=!0,t},Dl=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Ml=/^\((?:(\w[\w-]*):)?(.+)\)$/i,Km=/^\d+\/\d+$/,Qm=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Zm=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Jm=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,ep=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,tp=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,rn=e=>Km.test(e),ae=e=>!!e&&!Number.isNaN(Number(e)),Nt=e=>!!e&&Number.isInteger(Number(e)),Oa=e=>e.endsWith("%")&&ae(e.slice(0,-1)),Tt=e=>Qm.test(e),np=()=>!0,rp=e=>Zm.test(e)&&!Jm.test(e),Bl=()=>!1,ap=e=>ep.test(e),sp=e=>tp.test(e),ip=e=>!Z(e)&&!J(e),op=e=>Cn(e,Ul,Bl),Z=e=>Dl.test(e),Ft=e=>Cn(e,jl,rp),Ra=e=>Cn(e,fp,ae),Xi=e=>Cn(e,Fl,Bl),up=e=>Cn(e,Hl,sp),Ar=e=>Cn(e,zl,ap),J=e=>Ml.test(e),Mn=e=>An(e,jl),lp=e=>An(e,hp),Ki=e=>An(e,Fl),cp=e=>An(e,Ul),dp=e=>An(e,Hl),Sr=e=>An(e,zl,!0),Cn=(e,t,n)=>{const r=Dl.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},An=(e,t,n=!1)=>{const r=Ml.exec(e);return r?r[1]?t(r[1]):n:!1},Fl=e=>e==="position"||e==="percentage",Hl=e=>e==="image"||e==="url",Ul=e=>e==="length"||e==="size"||e==="bg-size",jl=e=>e==="length",fp=e=>e==="number",hp=e=>e==="family-name",zl=e=>e==="shadow",mp=()=>{const e=Ce("color"),t=Ce("font"),n=Ce("text"),r=Ce("font-weight"),a=Ce("tracking"),s=Ce("leading"),i=Ce("breakpoint"),o=Ce("container"),l=Ce("spacing"),c=Ce("radius"),d=Ce("shadow"),f=Ce("inset-shadow"),p=Ce("text-shadow"),h=Ce("drop-shadow"),x=Ce("blur"),g=Ce("perspective"),A=Ce("aspect"),E=Ce("ease"),_=Ce("animate"),N=()=>["auto","avoid","all","avoid-page","page","left","right","column"],k=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],L=()=>[...k(),J,Z],v=()=>["auto","hidden","clip","visible","scroll"],R=()=>["auto","contain","none"],P=()=>[J,Z,l],q=()=>[rn,"full","auto",...P()],K=()=>[Nt,"none","subgrid",J,Z],U=()=>["auto",{span:["full",Nt,J,Z]},Nt,J,Z],z=()=>[Nt,"auto",J,Z],$=()=>["auto","min","max","fr",J,Z],Y=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],F=()=>["start","end","center","stretch","center-safe","end-safe"],X=()=>["auto",...P()],Q=()=>[rn,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...P()],B=()=>[e,J,Z],ie=()=>[...k(),Ki,Xi,{position:[J,Z]}],S=()=>["no-repeat",{repeat:["","x","y","space","round"]}],xe=()=>["auto","cover","contain",cp,op,{size:[J,Z]}],we=()=>[Oa,Mn,Ft],I=()=>["","none","full",c,J,Z],fe=()=>["",ae,Mn,Ft],De=()=>["solid","dashed","dotted","double"],Ee=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],ce=()=>[ae,Oa,Ki,Xi],Me=()=>["","none",x,J,Z],je=()=>["none",ae,J,Z],ze=()=>["none",ae,J,Z],it=()=>[ae,J,Z],St=()=>[rn,"full",...P()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Tt],breakpoint:[Tt],color:[np],container:[Tt],"drop-shadow":[Tt],ease:["in","out","in-out"],font:[ip],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Tt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Tt],shadow:[Tt],spacing:["px",ae],text:[Tt],"text-shadow":[Tt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",rn,Z,J,A]}],container:["container"],columns:[{columns:[ae,Z,J,o]}],"break-after":[{"break-after":N()}],"break-before":[{"break-before":N()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:L()}],overflow:[{overflow:v()}],"overflow-x":[{"overflow-x":v()}],"overflow-y":[{"overflow-y":v()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:q()}],"inset-x":[{"inset-x":q()}],"inset-y":[{"inset-y":q()}],start:[{start:q()}],end:[{end:q()}],top:[{top:q()}],right:[{right:q()}],bottom:[{bottom:q()}],left:[{left:q()}],visibility:["visible","invisible","collapse"],z:[{z:[Nt,"auto",J,Z]}],basis:[{basis:[rn,"full","auto",o,...P()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ae,rn,"auto","initial","none",Z]}],grow:[{grow:["",ae,J,Z]}],shrink:[{shrink:["",ae,J,Z]}],order:[{order:[Nt,"first","last","none",J,Z]}],"grid-cols":[{"grid-cols":K()}],"col-start-end":[{col:U()}],"col-start":[{"col-start":z()}],"col-end":[{"col-end":z()}],"grid-rows":[{"grid-rows":K()}],"row-start-end":[{row:U()}],"row-start":[{"row-start":z()}],"row-end":[{"row-end":z()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":$()}],"auto-rows":[{"auto-rows":$()}],gap:[{gap:P()}],"gap-x":[{"gap-x":P()}],"gap-y":[{"gap-y":P()}],"justify-content":[{justify:[...Y(),"normal"]}],"justify-items":[{"justify-items":[...F(),"normal"]}],"justify-self":[{"justify-self":["auto",...F()]}],"align-content":[{content:["normal",...Y()]}],"align-items":[{items:[...F(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...F(),{baseline:["","last"]}]}],"place-content":[{"place-content":Y()}],"place-items":[{"place-items":[...F(),"baseline"]}],"place-self":[{"place-self":["auto",...F()]}],p:[{p:P()}],px:[{px:P()}],py:[{py:P()}],ps:[{ps:P()}],pe:[{pe:P()}],pt:[{pt:P()}],pr:[{pr:P()}],pb:[{pb:P()}],pl:[{pl:P()}],m:[{m:X()}],mx:[{mx:X()}],my:[{my:X()}],ms:[{ms:X()}],me:[{me:X()}],mt:[{mt:X()}],mr:[{mr:X()}],mb:[{mb:X()}],ml:[{ml:X()}],"space-x":[{"space-x":P()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":P()}],"space-y-reverse":["space-y-reverse"],size:[{size:Q()}],w:[{w:[o,"screen",...Q()]}],"min-w":[{"min-w":[o,"screen","none",...Q()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[i]},...Q()]}],h:[{h:["screen","lh",...Q()]}],"min-h":[{"min-h":["screen","lh","none",...Q()]}],"max-h":[{"max-h":["screen","lh",...Q()]}],"font-size":[{text:["base",n,Mn,Ft]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,J,Ra]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Oa,Z]}],"font-family":[{font:[lp,Z,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[a,J,Z]}],"line-clamp":[{"line-clamp":[ae,"none",J,Ra]}],leading:[{leading:[s,...P()]}],"list-image":[{"list-image":["none",J,Z]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",J,Z]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:B()}],"text-color":[{text:B()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...De(),"wavy"]}],"text-decoration-thickness":[{decoration:[ae,"from-font","auto",J,Ft]}],"text-decoration-color":[{decoration:B()}],"underline-offset":[{"underline-offset":[ae,"auto",J,Z]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:P()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",J,Z]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",J,Z]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:ie()}],"bg-repeat":[{bg:S()}],"bg-size":[{bg:xe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Nt,J,Z],radial:["",J,Z],conic:[Nt,J,Z]},dp,up]}],"bg-color":[{bg:B()}],"gradient-from-pos":[{from:we()}],"gradient-via-pos":[{via:we()}],"gradient-to-pos":[{to:we()}],"gradient-from":[{from:B()}],"gradient-via":[{via:B()}],"gradient-to":[{to:B()}],rounded:[{rounded:I()}],"rounded-s":[{"rounded-s":I()}],"rounded-e":[{"rounded-e":I()}],"rounded-t":[{"rounded-t":I()}],"rounded-r":[{"rounded-r":I()}],"rounded-b":[{"rounded-b":I()}],"rounded-l":[{"rounded-l":I()}],"rounded-ss":[{"rounded-ss":I()}],"rounded-se":[{"rounded-se":I()}],"rounded-ee":[{"rounded-ee":I()}],"rounded-es":[{"rounded-es":I()}],"rounded-tl":[{"rounded-tl":I()}],"rounded-tr":[{"rounded-tr":I()}],"rounded-br":[{"rounded-br":I()}],"rounded-bl":[{"rounded-bl":I()}],"border-w":[{border:fe()}],"border-w-x":[{"border-x":fe()}],"border-w-y":[{"border-y":fe()}],"border-w-s":[{"border-s":fe()}],"border-w-e":[{"border-e":fe()}],"border-w-t":[{"border-t":fe()}],"border-w-r":[{"border-r":fe()}],"border-w-b":[{"border-b":fe()}],"border-w-l":[{"border-l":fe()}],"divide-x":[{"divide-x":fe()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":fe()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...De(),"hidden","none"]}],"divide-style":[{divide:[...De(),"hidden","none"]}],"border-color":[{border:B()}],"border-color-x":[{"border-x":B()}],"border-color-y":[{"border-y":B()}],"border-color-s":[{"border-s":B()}],"border-color-e":[{"border-e":B()}],"border-color-t":[{"border-t":B()}],"border-color-r":[{"border-r":B()}],"border-color-b":[{"border-b":B()}],"border-color-l":[{"border-l":B()}],"divide-color":[{divide:B()}],"outline-style":[{outline:[...De(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ae,J,Z]}],"outline-w":[{outline:["",ae,Mn,Ft]}],"outline-color":[{outline:B()}],shadow:[{shadow:["","none",d,Sr,Ar]}],"shadow-color":[{shadow:B()}],"inset-shadow":[{"inset-shadow":["none",f,Sr,Ar]}],"inset-shadow-color":[{"inset-shadow":B()}],"ring-w":[{ring:fe()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:B()}],"ring-offset-w":[{"ring-offset":[ae,Ft]}],"ring-offset-color":[{"ring-offset":B()}],"inset-ring-w":[{"inset-ring":fe()}],"inset-ring-color":[{"inset-ring":B()}],"text-shadow":[{"text-shadow":["none",p,Sr,Ar]}],"text-shadow-color":[{"text-shadow":B()}],opacity:[{opacity:[ae,J,Z]}],"mix-blend":[{"mix-blend":[...Ee(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Ee()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[ae]}],"mask-image-linear-from-pos":[{"mask-linear-from":ce()}],"mask-image-linear-to-pos":[{"mask-linear-to":ce()}],"mask-image-linear-from-color":[{"mask-linear-from":B()}],"mask-image-linear-to-color":[{"mask-linear-to":B()}],"mask-image-t-from-pos":[{"mask-t-from":ce()}],"mask-image-t-to-pos":[{"mask-t-to":ce()}],"mask-image-t-from-color":[{"mask-t-from":B()}],"mask-image-t-to-color":[{"mask-t-to":B()}],"mask-image-r-from-pos":[{"mask-r-from":ce()}],"mask-image-r-to-pos":[{"mask-r-to":ce()}],"mask-image-r-from-color":[{"mask-r-from":B()}],"mask-image-r-to-color":[{"mask-r-to":B()}],"mask-image-b-from-pos":[{"mask-b-from":ce()}],"mask-image-b-to-pos":[{"mask-b-to":ce()}],"mask-image-b-from-color":[{"mask-b-from":B()}],"mask-image-b-to-color":[{"mask-b-to":B()}],"mask-image-l-from-pos":[{"mask-l-from":ce()}],"mask-image-l-to-pos":[{"mask-l-to":ce()}],"mask-image-l-from-color":[{"mask-l-from":B()}],"mask-image-l-to-color":[{"mask-l-to":B()}],"mask-image-x-from-pos":[{"mask-x-from":ce()}],"mask-image-x-to-pos":[{"mask-x-to":ce()}],"mask-image-x-from-color":[{"mask-x-from":B()}],"mask-image-x-to-color":[{"mask-x-to":B()}],"mask-image-y-from-pos":[{"mask-y-from":ce()}],"mask-image-y-to-pos":[{"mask-y-to":ce()}],"mask-image-y-from-color":[{"mask-y-from":B()}],"mask-image-y-to-color":[{"mask-y-to":B()}],"mask-image-radial":[{"mask-radial":[J,Z]}],"mask-image-radial-from-pos":[{"mask-radial-from":ce()}],"mask-image-radial-to-pos":[{"mask-radial-to":ce()}],"mask-image-radial-from-color":[{"mask-radial-from":B()}],"mask-image-radial-to-color":[{"mask-radial-to":B()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":k()}],"mask-image-conic-pos":[{"mask-conic":[ae]}],"mask-image-conic-from-pos":[{"mask-conic-from":ce()}],"mask-image-conic-to-pos":[{"mask-conic-to":ce()}],"mask-image-conic-from-color":[{"mask-conic-from":B()}],"mask-image-conic-to-color":[{"mask-conic-to":B()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:ie()}],"mask-repeat":[{mask:S()}],"mask-size":[{mask:xe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",J,Z]}],filter:[{filter:["","none",J,Z]}],blur:[{blur:Me()}],brightness:[{brightness:[ae,J,Z]}],contrast:[{contrast:[ae,J,Z]}],"drop-shadow":[{"drop-shadow":["","none",h,Sr,Ar]}],"drop-shadow-color":[{"drop-shadow":B()}],grayscale:[{grayscale:["",ae,J,Z]}],"hue-rotate":[{"hue-rotate":[ae,J,Z]}],invert:[{invert:["",ae,J,Z]}],saturate:[{saturate:[ae,J,Z]}],sepia:[{sepia:["",ae,J,Z]}],"backdrop-filter":[{"backdrop-filter":["","none",J,Z]}],"backdrop-blur":[{"backdrop-blur":Me()}],"backdrop-brightness":[{"backdrop-brightness":[ae,J,Z]}],"backdrop-contrast":[{"backdrop-contrast":[ae,J,Z]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ae,J,Z]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ae,J,Z]}],"backdrop-invert":[{"backdrop-invert":["",ae,J,Z]}],"backdrop-opacity":[{"backdrop-opacity":[ae,J,Z]}],"backdrop-saturate":[{"backdrop-saturate":[ae,J,Z]}],"backdrop-sepia":[{"backdrop-sepia":["",ae,J,Z]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":P()}],"border-spacing-x":[{"border-spacing-x":P()}],"border-spacing-y":[{"border-spacing-y":P()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",J,Z]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[ae,"initial",J,Z]}],ease:[{ease:["linear","initial",E,J,Z]}],delay:[{delay:[ae,J,Z]}],animate:[{animate:["none",_,J,Z]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[g,J,Z]}],"perspective-origin":[{"perspective-origin":L()}],rotate:[{rotate:je()}],"rotate-x":[{"rotate-x":je()}],"rotate-y":[{"rotate-y":je()}],"rotate-z":[{"rotate-z":je()}],scale:[{scale:ze()}],"scale-x":[{"scale-x":ze()}],"scale-y":[{"scale-y":ze()}],"scale-z":[{"scale-z":ze()}],"scale-3d":["scale-3d"],skew:[{skew:it()}],"skew-x":[{"skew-x":it()}],"skew-y":[{"skew-y":it()}],transform:[{transform:[J,Z,"","none","gpu","cpu"]}],"transform-origin":[{origin:L()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:St()}],"translate-x":[{"translate-x":St()}],"translate-y":[{"translate-y":St()}],"translate-z":[{"translate-z":St()}],"translate-none":["translate-none"],accent:[{accent:B()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:B()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",J,Z]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":P()}],"scroll-mx":[{"scroll-mx":P()}],"scroll-my":[{"scroll-my":P()}],"scroll-ms":[{"scroll-ms":P()}],"scroll-me":[{"scroll-me":P()}],"scroll-mt":[{"scroll-mt":P()}],"scroll-mr":[{"scroll-mr":P()}],"scroll-mb":[{"scroll-mb":P()}],"scroll-ml":[{"scroll-ml":P()}],"scroll-p":[{"scroll-p":P()}],"scroll-px":[{"scroll-px":P()}],"scroll-py":[{"scroll-py":P()}],"scroll-ps":[{"scroll-ps":P()}],"scroll-pe":[{"scroll-pe":P()}],"scroll-pt":[{"scroll-pt":P()}],"scroll-pr":[{"scroll-pr":P()}],"scroll-pb":[{"scroll-pb":P()}],"scroll-pl":[{"scroll-pl":P()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",J,Z]}],fill:[{fill:["none",...B()]}],"stroke-w":[{stroke:[ae,Mn,Ft,Ra]}],stroke:[{stroke:["none",...B()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},pp=Gm(mp);function ke(...e){return pp(yt(e))}const Yl=Em,gp=Tm,Wl=y.forwardRef(({className:e,...t},n)=>m.jsx(Al,{ref:n,className:ke("fixed inset-0 z-10000 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,onClick:r=>r.stopPropagation()}));Wl.displayName=Al.displayName;const Hs=y.forwardRef(({className:e,children:t,...n},r)=>m.jsxs(gp,{container:document.querySelector(".root-app"),children:[m.jsx(Wl,{}),m.jsxs(Sl,{ref:r,className:ke("z-10001 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] w-full max-w-[calc(100%-2rem)] max-h-[80vh] translate-x-[-50%] translate-y-[-50%] duration-200 overflow-y-auto",e),...n,children:[t,m.jsxs(xm,{className:"absolute right-4 top-4 cursor-pointer rounded-full bg-gray-200 transition-background hover:bg-gray-300 disabled:pointer-events-none duration-200 p-2",children:[m.jsx(Bs,{className:"h-8 w-8"}),m.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));Hs.displayName=Sl.displayName;const Us=({className:e,...t})=>m.jsx("div",{className:ke("flex flex-col space-y-1.5 text-left",e),...t});Us.displayName="DialogHeader";const js=y.forwardRef(({className:e,...t},n)=>m.jsx(Nl,{ref:n,className:ke("text-3xl font-semibold leading-none tracking-tight",e),...t}));js.displayName=Nl.displayName;const bp=y.forwardRef(({className:e,...t},n)=>m.jsx(Il,{ref:n,className:ke("text-muted-foreground",e),...t}));bp.displayName=Il.displayName;const zs=({item:e})=>{const[t,n]=D.useState(""),[r,a]=D.useState(!1),s=zt.getImage(e),i=zt.getValueLabel(e);return m.jsxs(m.Fragment,{children:[m.jsx("div",{className:"group relative w-full h-full! aspect-video overflow-hidden shadow-sm group cursor-pointer rounded-sm",children:s&&m.jsx("img",{src:s,alt:i,className:"w-full h-full! object-cover",loading:"lazy"})}),m.jsx(Yl,{open:!!r,onOpenChange:()=>{a(!1)},children:m.jsxs(Hs,{className:"sm:max-w-5xl",onClick:o=>o.stopPropagation(),children:[m.jsx(Us,{children:m.jsx(js,{className:"sr-only",children:"Image Zoom"})}),m.jsx("img",{src:t,alt:"Zoomed",className:"w-full h-auto"}),m.jsxs("span",{className:"text-white mt-2 block",children:[(e?.metadata?.Finish||e?.metadata?.Material)&&`${e.metadata?.Finish||e.metadata?.Material} | `,i]})]})})]})},cr=e=>m.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M11 1L1 11M1 1L11 11",stroke:"current",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Ys=({item:e})=>{const[t,n]=D.useState(null),[r,a]=D.useState(!1),s="#f2f1f1",i=zt.getHexColor(e);return m.jsxs(m.Fragment,{children:[m.jsx("div",{className:"group relative w-full h-full! aspect-video overflow-hidden shadow-sm group cursor-pointer rounded-sm",style:{backgroundColor:i||s}}),m.jsx(Yl,{open:!!r,onOpenChange:()=>{a(!1)},children:m.jsxs(Hs,{className:"sm:max-w-5xl",onClick:o=>o.stopPropagation(),children:[m.jsx(Us,{children:m.jsx(js,{className:"sr-only",children:"Hex Color"})}),m.jsx("div",{className:"w-full aspect-video rounded",style:{backgroundColor:t||"transparent"}}),i&&m.jsxs("span",{className:"text-white mt-2 block",children:[" ",(e?.metadata?.Material||e?.metadata?.Material)&&`${e.metadata?.Material} | `,zt.getAttributeLabel(e)]})]})})]})},Ep="w-[64px] h-[64px] bg-[var(--sidebar-b)] border border-solid border-[var(--border)] rounded-sm aspect-square overflow-hidden transition",Tp=({val:e,className:t,isShowDeleteIcon:n=!1,handleSelect:r})=>m.jsxs("button",{onClick:()=>{r&&r(e)},className:`relative ${t||Ep}`,"aria-label":`Selected swatch ${e.name??e.assetId}`,title:"Click to remove",children:[zt.getImage(e)?m.jsx(zs,{item:e}):m.jsx(Ys,{item:e}),n?m.jsx("div",{className:`absolute top-0 right-0 m-2 w-[16px] h-[16px] flex flex-row justify-center items-center
47
+ bg-[var(--background-grey)] rounded-2xl border-none pointer-events-none`,children:m.jsx(cr,{className:"w-[8px] h-2 stroke-[var(--svg-dark)]"})}):null]},e.assetId),xp=e=>m.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M2.5 6H9.5",stroke:"current",strokeLinecap:"round",strokeLinejoin:"round"})}),yp=e=>m.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M2.5 6H9.5M6 2.5V9.5",stroke:"current",strokeLinecap:"round",strokeLinejoin:"round"})}),_p=e=>m.jsx("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M5 5.5V8.5M7 5.5V8.5M9.5 3V10C9.5 10.2652 9.39464 10.5196 9.20711 10.7071C9.01957 10.8946 8.76522 11 8.5 11H3.5C3.23478 11 2.98043 10.8946 2.79289 10.7071C2.60536 10.5196 2.5 10.2652 2.5 10V3M1.5 3H10.5M4 3V2C4 1.73478 4.10536 1.48043 4.29289 1.29289C4.48043 1.10536 4.73478 1 5 1H7C7.26522 1 7.51957 1.10536 7.70711 1.29289C7.89464 1.48043 8 1.73478 8 2V3",stroke:"current",strokeLinecap:"round",strokeLinejoin:"round"})}),Cp=({value:e,canIncrement:t,onIncrement:n,onDecrement:r,onDelete:a})=>{const s=e<=1;return m.jsxs("div",{className:"flex flex-row items-center gap-[8px] text-sm",children:[s?m.jsx("button",{"aria-label":"Remove item",onClick:a,className:"[&_svg_path]:stroke-[var(--main-accent-color)]",children:m.jsx(_p,{})}):m.jsx("button",{"aria-label":"Decrease",onClick:r,className:"[&_svg_path]:stroke-[var(--svg-dark)]",children:m.jsx(xp,{})}),m.jsx("span",{className:"min-w-[16px] text-center select-none",children:e}),m.jsx("button",{"aria-label":"Increase",onClick:n,disabled:!t,className:"[&_svg_path]:stroke-[var(--svg-dark)] disabled:opacity-40",children:m.jsx(yp,{})})]})},Vl=({item:e,canInc:t,onDelete:n,onIncrement:r,onDecrement:a})=>m.jsx("li",{className:`
48
+ border-b border-[var(--border)]
49
+ px-[var(--sm-padding)] p-[var(--sm-padding)]
50
+ last:border-b-0`,children:m.jsxs("div",{className:"relative flex flex-row gap-[16px]",children:[m.jsx("div",{children:m.jsx(Tp,{val:e})}),m.jsxs("div",{className:"flex flex-col justify-between",children:[m.jsxs("div",{className:"flex flex-col",children:[m.jsx("span",{className:"mb-[4px] font-semibold text-xs",children:e.metadata?.label}),m.jsx("span",{className:"mb-[4px] font-bold text-[1rem]",children:e.parentName})]}),m.jsx(Cp,{value:e.count,canIncrement:t,onIncrement:r,onDecrement:a,onDelete:n})]}),m.jsxs("div",{className:" absolute text-xs top-0 right-0 font-bold",children:["$",e.count*$u]})]})},e.assetId),Ws=e=>m.jsx("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M9.99984 15.8333L4.1665 9.99996M4.1665 9.99996L9.99984 4.16663M4.1665 9.99996H15.8332",stroke:"current",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Ap=({totalCount:e})=>{const t=Pe(),n=()=>{t(Uu(!1))};return m.jsx("header",{className:"flex flex-row p-[var(--sm-padding)] justify-between items-center border-b border-solid border-[var(--border)]",children:m.jsxs("div",{className:"flex items-center flex-row gap-[4px]",children:[m.jsxs("div",{className:"flex flex-row items-center gap-[8px]",children:[m.jsx("button",{className:"[&_svg_path]:stroke-[var(--main-accent-color)] cursor-pointer",onClick:n,children:m.jsx(Ws,{})}),m.jsx("h2",{className:"m-0! text-base leading-[1.6] font-medium ",children:"Your cart"})]}),e>=Re?m.jsxs(m.Fragment,{children:[m.jsxs("span",{className:"text-[var(--main-accent-color)] hidden text-xs sm:block",children:["(",Re,") You reached maximum amount of swatches"]}),m.jsxs("span",{className:"text-[var(--main-accent-color)] block sm:hidden",children:["(",Re,") Max"]})]}):null]})})},Sp=({onSendData:e})=>{const t=Pe(),n=oe(yn),r=oe($t),a=D.useMemo(()=>n.flatMap(c=>c.items),[n]),s=({item:c,assetId:d})=>{const{parentName:f,metadata:p}=c,h=p?.label;d&&h&&f&&(t(wh({assetId:d,label:h,parentName:f})),t(ta({selectedMaterial:c,materialCount:1,selectedMaterials:r})))},i=({item:c,assetId:d})=>{const{parentName:f,metadata:p}=c,h=p?.label;d&&h&&f&&t(Ih({assetId:d,label:h,parentName:f}))},o=({item:c,assetId:d})=>{const{parentName:f,metadata:p}=c,h=p?.label;d&&h&&f&&t(vh({assetId:d,label:h,parentName:f}))},l=D.useMemo(()=>a.reduce((c,d)=>c+(d.count??0),0),[a]);return m.jsxs("div",{className:"flex flex-col h-full",children:[m.jsx(Ap,{totalCount:l}),m.jsxs("div",{className:"flex flex-col h-full min-h-0",children:[m.jsx("ul",{className:"flex flex-col flex-1 min-h-0 overflow-y-auto",children:n.map(c=>{const{items:d,name:f,assetId:p}=c;return d.length?m.jsxs(m.Fragment,{children:[m.jsx("div",{className:` p-[var(--sm-padding)] border-b border-[var(--border)]
51
+ sm:px-[var(--sm-padding)]`,children:f},c.value),m.jsx("ul",{children:d?.map(h=>m.jsx(Vl,{item:h,canInc:l<Re,onDelete:()=>{p&&s({item:h,assetId:p})},onIncrement:()=>{p&&i({item:h,assetId:p})},onDecrement:()=>{p&&o({item:h,assetId:p})}},`${h.value}/${h.parentName}`))})]}):null})}),m.jsxs("div",{className:`flex flex-col
52
+ sm:flex-row sm:w-full sm:justify-between sm:items-center
53
+ sm:border-t sm:border-[var(--border)] shadow-[0_-2px_10px_rgba(40,40,40,0.10)]
54
+ `,children:[m.jsx("div",{className:"sm:w-[50%] sm:border-r sm:border-solid sm:border-[var(--border)]",children:m.jsx(qu,{materials:a,containerStyles:"flex flex-col gap-[8px] text-xs/snug p-[var(--sm-padding)] border-t border-solid border-[var(--border)] sm:gap-[12px] sm:border-none s"})}),m.jsx("div",{className:"p-[var(--sm-padding)] border-t border-solid border-[var(--border)] shrink-0 sm:w-[50%] sm:border-none sm:flex flex-row sm:justify-end sm:items-end sm:h-full",children:m.jsx("div",{className:"sm:w-[50%]",children:m.jsx(Gu,{onClick:()=>e&&e(n),disabled:a.length>Re+1,children:"GO TO SHIPPING"})})})]})]})]})},Np=e=>m.jsxs("svg",{width:"20",height:"20",viewBox:"0 0 20 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:[m.jsx("path",{d:"M17.5 17.5L13.8833 13.8834",stroke:"current",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round"}),m.jsx("path",{d:"M9.16667 15.8333C12.8486 15.8333 15.8333 12.8486 15.8333 9.16667C15.8333 5.48477 12.8486 2.5 9.16667 2.5C5.48477 2.5 2.5 5.48477 2.5 9.16667C2.5 12.8486 5.48477 15.8333 9.16667 15.8333Z",stroke:"current",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),Qi={MATERIAL:"material"},Ip="UIGrouping";class us{static getTransformedData({dataType:t,data:n}){switch(t){case tt.UI:return this.getMapUIData(n);case tt.FETCH_DATA_PRODUCT:return this.getTransformedFetchProductData(n);default:throw new Error("Unsupported format")}}static getGroupingValue(t){if(t)return t.find(n=>n.name===Ip)}static getAllMaterialValuesKeys(t){if(t)return t.flatMap(n=>n.groups.flatMap(r=>r.options.filter(a=>a.typeComponent===Qi.MATERIAL)).map(r=>r.optionName))}static getAllMaterialOptions(t){const n=JSON.parse(this.getGroupingValue(t).value);if(n){const r=this.getAllMaterialValuesKeys(n);if(r?.length){const a=t.filter(s=>r.includes(s.name));if(a?.length){const s=Fr.getMaterialsValuesFromOptions(a);if(s?.length)return{allMaterialValues:s,productElementOptions:a}}}}}static getMapUIData(t){return this.getAllMaterialOptions(t)}static getTransformedFetchProductData(t){const{materials:n=[],structure:r=[]}=t,a=new Map;for(const d of r)for(const f of d.groups??[])for(const p of f.options??[])p?.typeComponent===Qi.MATERIAL&&p?.optionName&&a.set(p.optionName,f.groupName);const i=n.filter(d=>d.optionName&&a.has(d.optionName)).map(d=>({...d,groupName:d.optionName?a.get(d.optionName):void 0})),o=i.flatMap(d=>{const{label:f,groupName:p}=d,h=(f.toLocaleLowerCase()==="color"?p:f)||"without_name";return(d.valuesArray??[]).map(x=>({...x,parentName:h}))}),l=new Set,c=i.map(({label:d,groupName:f,valuesArray:p})=>{const h=d?.toLowerCase()==="color"?f??d:d;return{id:h,value:h,label:h,valuesArray:p}}).filter(d=>d.label&&(l.has(d.label)?!1:(l.add(d.label),!0))).sort((d,f)=>d.label.localeCompare(f.label));return{allMaterialValues:o,productElementOptions:c}}}const vp=({productListItem:e})=>{const t=Pe(),{name:n,img:r}=e,a=r?`https://admin-fts.threekit.com${r}`:"https://clownfish-app-cvxrz.ondigitalocean.app/assets/product_thumb-Bn1S8z9K.png",s=async()=>{const{assetId:i,name:o}=e;if(i&&o){const l=await t(Vn({assetId:i})).unwrap();if(l){t(Eh(e));const c=us.getTransformedData({dataType:tt.FETCH_DATA_PRODUCT,data:l});t(ns(c))}}};return m.jsxs("li",{className:"min-w-0 cursor-pointer",tabIndex:0,onClick:s,children:[m.jsx("div",{className:"mb-[12px] w-full aspect-square relative overflow-hidden rounded-sm",children:m.jsx("img",{src:a,alt:"product-list-item",className:"absolute inset-0 w-full h-full! object-cover"})}),n]})},$l={name:"All",value:"",productId:0,items:[]};class wp{static getCartTotalCount({cartItems:t}){return t.reduce((n,r)=>n+r.count,0)}static getUniqueCategories(t){const n=["All","Vanities","Storage & Shelving","Countertops","Basins","Vessels","Pedestals & Consoles","Tubs","Mirrors","Toilets","Bathroom Accessories"],a=Array.from(new Set(t.map(o=>o.collection).filter(Boolean))).map(o=>({name:o,value:o,productId:0,items:[]}));return[$l,...a].sort((o,l)=>{const c=n.indexOf(o.name),d=n.indexOf(l.name),f=c===-1?Number.MAX_SAFE_INTEGER:c,p=d===-1?Number.MAX_SAFE_INTEGER:d;return f!==p?f-p:o.name.localeCompare(l.name)}).map((o,l)=>({...o,productId:l}))}static getCartPreparedOption(t,n){if(!t?.length)return[];const r=n.flatMap(a=>a.items||[]);return t.map(a=>{const s=r.find(i=>i.parentName===a.parentName&&i.metadata?.label===a.metadata?.label);return{...a,count:s?s.count:1}})}}const kp=({text:e,isActive:t=!1,onClick:n})=>{const r=()=>{n&&n()},a=s=>{(s.key==="Enter"||s.key===" ")&&(s.preventDefault(),r())};return m.jsx("div",{role:"button",tabIndex:0,onClick:r,onKeyDown:a,className:`
55
+ flex flex-row justify-center items-center max-w-max px-4 py-2 capitalize rounded-full
56
+ font-medium text-sm cursor-pointer transition-all duration-[400ms] ease-in-out
57
+ outline-none focus:ring-2 focus:ring-[var(--main-accent-color)] focus:ring-offset-2
58
+ ${t?"bg-[var(--main-accent-color)] text-white hover:brightness-90":"bg-[var(--label-bg)] hover:brightness-95"}
59
+ `,children:e})},Zi=e=>m.jsx("svg",{width:"7",height:"12",viewBox:"0 0 7 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",stroke:"currentColor",...e,children:m.jsx("path",{d:"M5.75 0.75L0.75 5.75L5.75 10.75",stroke:"current",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Ji=({items:e,activeId:t,onSelect:n,className:r="",stepRatio:a=.8})=>{const s=D.useRef(null),i=D.useRef(null),o=D.useRef(null),[l,c]=D.useState(!1),[d,f]=D.useState(!1),p=D.useCallback(()=>{const x=s.current;if(!x)return;const g=x.scrollWidth-x.clientWidth-x.scrollLeft,A=.5;c(x.scrollLeft>A),f(g>A)},[]);D.useLayoutEffect(()=>(o.current=requestAnimationFrame(p),()=>{o.current&&cancelAnimationFrame(o.current)}),[e.length,p]),D.useEffect(()=>{const x=s.current,g=i.current;if(!x||!g)return;p();const A=new ResizeObserver(()=>p()),E=new ResizeObserver(()=>p());A.observe(x),E.observe(g);const _=()=>p();return x.addEventListener("scroll",_,{passive:!0}),"fonts"in document&&document.fonts?.ready?.then(()=>p()),()=>{A.disconnect(),E.disconnect(),x.removeEventListener("scroll",_)}},[p]);const h=x=>{const g=s.current;if(!g)return;const A=g.clientWidth*a*(x==="left"?-1:1);g.scrollBy({left:A,behavior:"smooth"})};return m.jsxs("div",{className:`flex flex-row items-center gap-[8px] lg:w-[50%] xl:max-w-[68%] xl:w-full ${r}`,role:"region","aria-label":"Category slider",children:[m.jsxs("button",{type:"button","aria-label":"Scroll left",disabled:!l,onClick:()=>h("left"),className:`flex-shrink-0 h-8 w-8 rounded-full flex flex-row items-center justify-center shadow
60
+ ${l?"bg-black text-white hover:brightness-110":"bg-gray-200 text-gray-500 opacity-60 cursor-not-allowed"}`,children:[m.jsx(Zi,{className:"w-[16px] h-4 rotate-360"})," "]}),m.jsx("div",{ref:s,className:"no-scrollbar flex-1 overflow-hidden scroll-smooth",style:{WebkitOverflowScrolling:"touch"},children:m.jsx("div",{ref:i,className:"flex flex-row gap-[12px] sm:gap-[16px] py-2",children:e.map(x=>{const g=x.productId,A=t===g;return m.jsx("div",{className:"shrink-0",children:m.jsx(kp,{text:x.name,isActive:A,onClick:()=>n(x)})},g)})})}),m.jsxs("button",{type:"button","aria-label":"Scroll right",disabled:!d,onClick:()=>h("right"),className:`flex-shrink-0 h-8 w-8 rounded-full flex flex-row items-center justify-center shadow
61
+ ${d?"bg-black text-white hover:brightness-110":"bg-gray-200 text-gray-400 opacity-60 cursor-not-allowed"}`,children:[m.jsx(Zi,{className:"w-[16px] h-4 rotate-180"})," "]})]})},Op=["top","right","bottom","left"],Pt=Math.min,$e=Math.max,jr=Math.round,Nr=Math.floor,ft=e=>({x:e,y:e}),Rp={left:"right",right:"left",bottom:"top",top:"bottom"},Lp={start:"end",end:"start"};function ls(e,t,n){return $e(e,Pt(t,n))}function Ct(e,t){return typeof e=="function"?e(t):e}function At(e){return e.split("-")[0]}function Sn(e){return e.split("-")[1]}function Vs(e){return e==="x"?"y":"x"}function $s(e){return e==="y"?"height":"width"}const Pp=new Set(["top","bottom"]);function dt(e){return Pp.has(At(e))?"y":"x"}function qs(e){return Vs(dt(e))}function Dp(e,t,n){n===void 0&&(n=!1);const r=Sn(e),a=qs(e),s=$s(a);let i=a==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(i=zr(i)),[i,zr(i)]}function Mp(e){const t=zr(e);return[cs(e),t,cs(t)]}function cs(e){return e.replace(/start|end/g,t=>Lp[t])}const eo=["left","right"],to=["right","left"],Bp=["top","bottom"],Fp=["bottom","top"];function Hp(e,t,n){switch(e){case"top":case"bottom":return n?t?to:eo:t?eo:to;case"left":case"right":return t?Bp:Fp;default:return[]}}function Up(e,t,n,r){const a=Sn(e);let s=Hp(At(e),n==="start",r);return a&&(s=s.map(i=>i+"-"+a),t&&(s=s.concat(s.map(cs)))),s}function zr(e){return e.replace(/left|right|bottom|top/g,t=>Rp[t])}function jp(e){return{top:0,right:0,bottom:0,left:0,...e}}function ql(e){return typeof e!="number"?jp(e):{top:e,right:e,bottom:e,left:e}}function Yr(e){const{x:t,y:n,width:r,height:a}=e;return{width:r,height:a,top:n,left:t,right:t+r,bottom:n+a,x:t,y:n}}function no(e,t,n){let{reference:r,floating:a}=e;const s=dt(t),i=qs(t),o=$s(i),l=At(t),c=s==="y",d=r.x+r.width/2-a.width/2,f=r.y+r.height/2-a.height/2,p=r[o]/2-a[o]/2;let h;switch(l){case"top":h={x:d,y:r.y-a.height};break;case"bottom":h={x:d,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:f};break;case"left":h={x:r.x-a.width,y:f};break;default:h={x:r.x,y:r.y}}switch(Sn(t)){case"start":h[i]-=p*(n&&c?-1:1);break;case"end":h[i]+=p*(n&&c?-1:1);break}return h}const zp=async(e,t,n)=>{const{placement:r="bottom",strategy:a="absolute",middleware:s=[],platform:i}=n,o=s.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:a}),{x:d,y:f}=no(c,r,l),p=r,h={},x=0;for(let g=0;g<o.length;g++){const{name:A,fn:E}=o[g],{x:_,y:N,data:k,reset:L}=await E({x:d,y:f,initialPlacement:r,placement:p,strategy:a,middlewareData:h,rects:c,platform:i,elements:{reference:e,floating:t}});d=_??d,f=N??f,h={...h,[A]:{...h[A],...k}},L&&x<=50&&(x++,typeof L=="object"&&(L.placement&&(p=L.placement),L.rects&&(c=L.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:a}):L.rects),{x:d,y:f}=no(c,p,l)),g=-1)}return{x:d,y:f,placement:p,strategy:a,middlewareData:h}};async function nr(e,t){var n;t===void 0&&(t={});const{x:r,y:a,platform:s,rects:i,elements:o,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:p=!1,padding:h=0}=Ct(t,e),x=ql(h),A=o[p?f==="floating"?"reference":"floating":f],E=Yr(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(A)))==null||n?A:A.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(o.floating)),boundary:c,rootBoundary:d,strategy:l})),_=f==="floating"?{x:r,y:a,width:i.floating.width,height:i.floating.height}:i.reference,N=await(s.getOffsetParent==null?void 0:s.getOffsetParent(o.floating)),k=await(s.isElement==null?void 0:s.isElement(N))?await(s.getScale==null?void 0:s.getScale(N))||{x:1,y:1}:{x:1,y:1},L=Yr(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:o,rect:_,offsetParent:N,strategy:l}):_);return{top:(E.top-L.top+x.top)/k.y,bottom:(L.bottom-E.bottom+x.bottom)/k.y,left:(E.left-L.left+x.left)/k.x,right:(L.right-E.right+x.right)/k.x}}const Yp=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:a,rects:s,platform:i,elements:o,middlewareData:l}=t,{element:c,padding:d=0}=Ct(e,t)||{};if(c==null)return{};const f=ql(d),p={x:n,y:r},h=qs(a),x=$s(h),g=await i.getDimensions(c),A=h==="y",E=A?"top":"left",_=A?"bottom":"right",N=A?"clientHeight":"clientWidth",k=s.reference[x]+s.reference[h]-p[h]-s.floating[x],L=p[h]-s.reference[h],v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(c));let R=v?v[N]:0;(!R||!await(i.isElement==null?void 0:i.isElement(v)))&&(R=o.floating[N]||s.floating[x]);const P=k/2-L/2,q=R/2-g[x]/2-1,K=Pt(f[E],q),U=Pt(f[_],q),z=K,$=R-g[x]-U,Y=R/2-g[x]/2+P,F=ls(z,Y,$),X=!l.arrow&&Sn(a)!=null&&Y!==F&&s.reference[x]/2-(Y<z?K:U)-g[x]/2<0,Q=X?Y<z?Y-z:Y-$:0;return{[h]:p[h]+Q,data:{[h]:F,centerOffset:Y-F-Q,...X&&{alignmentOffset:Q}},reset:X}}}),Wp=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:a,middlewareData:s,rects:i,initialPlacement:o,platform:l,elements:c}=t,{mainAxis:d=!0,crossAxis:f=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:g=!0,...A}=Ct(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const E=At(a),_=dt(o),N=At(o)===o,k=await(l.isRTL==null?void 0:l.isRTL(c.floating)),L=p||(N||!g?[zr(o)]:Mp(o)),v=x!=="none";!p&&v&&L.push(...Up(o,g,x,k));const R=[o,...L],P=await nr(t,A),q=[];let K=((r=s.flip)==null?void 0:r.overflows)||[];if(d&&q.push(P[E]),f){const Y=Dp(a,i,k);q.push(P[Y[0]],P[Y[1]])}if(K=[...K,{placement:a,overflows:q}],!q.every(Y=>Y<=0)){var U,z;const Y=(((U=s.flip)==null?void 0:U.index)||0)+1,F=R[Y];if(F&&(!(f==="alignment"?_!==dt(F):!1)||K.every(B=>dt(B.placement)===_?B.overflows[0]>0:!0)))return{data:{index:Y,overflows:K},reset:{placement:F}};let X=(z=K.filter(Q=>Q.overflows[0]<=0).sort((Q,B)=>Q.overflows[1]-B.overflows[1])[0])==null?void 0:z.placement;if(!X)switch(h){case"bestFit":{var $;const Q=($=K.filter(B=>{if(v){const ie=dt(B.placement);return ie===_||ie==="y"}return!0}).map(B=>[B.placement,B.overflows.filter(ie=>ie>0).reduce((ie,S)=>ie+S,0)]).sort((B,ie)=>B[1]-ie[1])[0])==null?void 0:$[0];Q&&(X=Q);break}case"initialPlacement":X=o;break}if(a!==X)return{reset:{placement:X}}}return{}}}};function ro(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function ao(e){return Op.some(t=>e[t]>=0)}const Vp=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...a}=Ct(e,t);switch(r){case"referenceHidden":{const s=await nr(t,{...a,elementContext:"reference"}),i=ro(s,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:ao(i)}}}case"escaped":{const s=await nr(t,{...a,altBoundary:!0}),i=ro(s,n.floating);return{data:{escapedOffsets:i,escaped:ao(i)}}}default:return{}}}}},Gl=new Set(["left","top"]);async function $p(e,t){const{placement:n,platform:r,elements:a}=e,s=await(r.isRTL==null?void 0:r.isRTL(a.floating)),i=At(n),o=Sn(n),l=dt(n)==="y",c=Gl.has(i)?-1:1,d=s&&l?-1:1,f=Ct(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:x}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return o&&typeof x=="number"&&(h=o==="end"?x*-1:x),l?{x:h*d,y:p*c}:{x:p*c,y:h*d}}const qp=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:a,y:s,placement:i,middlewareData:o}=t,l=await $p(t,e);return i===((n=o.offset)==null?void 0:n.placement)&&(r=o.arrow)!=null&&r.alignmentOffset?{}:{x:a+l.x,y:s+l.y,data:{...l,placement:i}}}}},Gp=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:a}=t,{mainAxis:s=!0,crossAxis:i=!1,limiter:o={fn:A=>{let{x:E,y:_}=A;return{x:E,y:_}}},...l}=Ct(e,t),c={x:n,y:r},d=await nr(t,l),f=dt(At(a)),p=Vs(f);let h=c[p],x=c[f];if(s){const A=p==="y"?"top":"left",E=p==="y"?"bottom":"right",_=h+d[A],N=h-d[E];h=ls(_,h,N)}if(i){const A=f==="y"?"top":"left",E=f==="y"?"bottom":"right",_=x+d[A],N=x-d[E];x=ls(_,x,N)}const g=o.fn({...t,[p]:h,[f]:x});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[p]:s,[f]:i}}}}}},Xp=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:a,rects:s,middlewareData:i}=t,{offset:o=0,mainAxis:l=!0,crossAxis:c=!0}=Ct(e,t),d={x:n,y:r},f=dt(a),p=Vs(f);let h=d[p],x=d[f];const g=Ct(o,t),A=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const N=p==="y"?"height":"width",k=s.reference[p]-s.floating[N]+A.mainAxis,L=s.reference[p]+s.reference[N]-A.mainAxis;h<k?h=k:h>L&&(h=L)}if(c){var E,_;const N=p==="y"?"width":"height",k=Gl.has(At(a)),L=s.reference[f]-s.floating[N]+(k&&((E=i.offset)==null?void 0:E[f])||0)+(k?0:A.crossAxis),v=s.reference[f]+s.reference[N]+(k?0:((_=i.offset)==null?void 0:_[f])||0)-(k?A.crossAxis:0);x<L?x=L:x>v&&(x=v)}return{[p]:h,[f]:x}}}},Kp=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:a,rects:s,platform:i,elements:o}=t,{apply:l=()=>{},...c}=Ct(e,t),d=await nr(t,c),f=At(a),p=Sn(a),h=dt(a)==="y",{width:x,height:g}=s.floating;let A,E;f==="top"||f==="bottom"?(A=f,E=p===(await(i.isRTL==null?void 0:i.isRTL(o.floating))?"start":"end")?"left":"right"):(E=f,A=p==="end"?"top":"bottom");const _=g-d.top-d.bottom,N=x-d.left-d.right,k=Pt(g-d[A],_),L=Pt(x-d[E],N),v=!t.middlewareData.shift;let R=k,P=L;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(P=N),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(R=_),v&&!p){const K=$e(d.left,0),U=$e(d.right,0),z=$e(d.top,0),$=$e(d.bottom,0);h?P=x-2*(K!==0||U!==0?K+U:$e(d.left,d.right)):R=g-2*(z!==0||$!==0?z+$:$e(d.top,d.bottom))}await l({...t,availableWidth:P,availableHeight:R});const q=await i.getDimensions(o.floating);return x!==q.width||g!==q.height?{reset:{rects:!0}}:{}}}};function oa(){return typeof window<"u"}function Nn(e){return Xl(e)?(e.nodeName||"").toLowerCase():"#document"}function Ge(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function pt(e){var t;return(t=(Xl(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Xl(e){return oa()?e instanceof Node||e instanceof Ge(e).Node:!1}function nt(e){return oa()?e instanceof Element||e instanceof Ge(e).Element:!1}function ht(e){return oa()?e instanceof HTMLElement||e instanceof Ge(e).HTMLElement:!1}function so(e){return!oa()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ge(e).ShadowRoot}const Qp=new Set(["inline","contents"]);function dr(e){const{overflow:t,overflowX:n,overflowY:r,display:a}=rt(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Qp.has(a)}const Zp=new Set(["table","td","th"]);function Jp(e){return Zp.has(Nn(e))}const eg=[":popover-open",":modal"];function ua(e){return eg.some(t=>{try{return e.matches(t)}catch{return!1}})}const tg=["transform","translate","scale","rotate","perspective"],ng=["transform","translate","scale","rotate","perspective","filter"],rg=["paint","layout","strict","content"];function Gs(e){const t=Xs(),n=nt(e)?rt(e):e;return tg.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||ng.some(r=>(n.willChange||"").includes(r))||rg.some(r=>(n.contain||"").includes(r))}function ag(e){let t=Dt(e);for(;ht(t)&&!pn(t);){if(Gs(t))return t;if(ua(t))return null;t=Dt(t)}return null}function Xs(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const sg=new Set(["html","body","#document"]);function pn(e){return sg.has(Nn(e))}function rt(e){return Ge(e).getComputedStyle(e)}function la(e){return nt(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Dt(e){if(Nn(e)==="html")return e;const t=e.assignedSlot||e.parentNode||so(e)&&e.host||pt(e);return so(t)?t.host:t}function Kl(e){const t=Dt(e);return pn(t)?e.ownerDocument?e.ownerDocument.body:e.body:ht(t)&&dr(t)?t:Kl(t)}function rr(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const a=Kl(e),s=a===((r=e.ownerDocument)==null?void 0:r.body),i=Ge(a);if(s){const o=ds(i);return t.concat(i,i.visualViewport||[],dr(a)?a:[],o&&n?rr(o):[])}return t.concat(a,rr(a,[],n))}function ds(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Ql(e){const t=rt(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const a=ht(e),s=a?e.offsetWidth:n,i=a?e.offsetHeight:r,o=jr(n)!==s||jr(r)!==i;return o&&(n=s,r=i),{width:n,height:r,$:o}}function Ks(e){return nt(e)?e:e.contextElement}function cn(e){const t=Ks(e);if(!ht(t))return ft(1);const n=t.getBoundingClientRect(),{width:r,height:a,$:s}=Ql(t);let i=(s?jr(n.width):n.width)/r,o=(s?jr(n.height):n.height)/a;return(!i||!Number.isFinite(i))&&(i=1),(!o||!Number.isFinite(o))&&(o=1),{x:i,y:o}}const ig=ft(0);function Zl(e){const t=Ge(e);return!Xs()||!t.visualViewport?ig:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function og(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ge(e)?!1:t}function Wt(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const a=e.getBoundingClientRect(),s=Ks(e);let i=ft(1);t&&(r?nt(r)&&(i=cn(r)):i=cn(e));const o=og(s,n,r)?Zl(s):ft(0);let l=(a.left+o.x)/i.x,c=(a.top+o.y)/i.y,d=a.width/i.x,f=a.height/i.y;if(s){const p=Ge(s),h=r&&nt(r)?Ge(r):r;let x=p,g=ds(x);for(;g&&r&&h!==x;){const A=cn(g),E=g.getBoundingClientRect(),_=rt(g),N=E.left+(g.clientLeft+parseFloat(_.paddingLeft))*A.x,k=E.top+(g.clientTop+parseFloat(_.paddingTop))*A.y;l*=A.x,c*=A.y,d*=A.x,f*=A.y,l+=N,c+=k,x=Ge(g),g=ds(x)}}return Yr({width:d,height:f,x:l,y:c})}function ca(e,t){const n=la(e).scrollLeft;return t?t.left+n:Wt(pt(e)).left+n}function Jl(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-ca(e,n),a=n.top+t.scrollTop;return{x:r,y:a}}function ug(e){let{elements:t,rect:n,offsetParent:r,strategy:a}=e;const s=a==="fixed",i=pt(r),o=t?ua(t.floating):!1;if(r===i||o&&s)return n;let l={scrollLeft:0,scrollTop:0},c=ft(1);const d=ft(0),f=ht(r);if((f||!f&&!s)&&((Nn(r)!=="body"||dr(i))&&(l=la(r)),ht(r))){const h=Wt(r);c=cn(r),d.x=h.x+r.clientLeft,d.y=h.y+r.clientTop}const p=i&&!f&&!s?Jl(i,l):ft(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+d.x+p.x,y:n.y*c.y-l.scrollTop*c.y+d.y+p.y}}function lg(e){return Array.from(e.getClientRects())}function cg(e){const t=pt(e),n=la(e),r=e.ownerDocument.body,a=$e(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=$e(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+ca(e);const o=-n.scrollTop;return rt(r).direction==="rtl"&&(i+=$e(t.clientWidth,r.clientWidth)-a),{width:a,height:s,x:i,y:o}}const io=25;function dg(e,t){const n=Ge(e),r=pt(e),a=n.visualViewport;let s=r.clientWidth,i=r.clientHeight,o=0,l=0;if(a){s=a.width,i=a.height;const d=Xs();(!d||d&&t==="fixed")&&(o=a.offsetLeft,l=a.offsetTop)}const c=ca(r);if(c<=0){const d=r.ownerDocument,f=d.body,p=getComputedStyle(f),h=d.compatMode==="CSS1Compat"&&parseFloat(p.marginLeft)+parseFloat(p.marginRight)||0,x=Math.abs(r.clientWidth-f.clientWidth-h);x<=io&&(s-=x)}else c<=io&&(s+=c);return{width:s,height:i,x:o,y:l}}const fg=new Set(["absolute","fixed"]);function hg(e,t){const n=Wt(e,!0,t==="fixed"),r=n.top+e.clientTop,a=n.left+e.clientLeft,s=ht(e)?cn(e):ft(1),i=e.clientWidth*s.x,o=e.clientHeight*s.y,l=a*s.x,c=r*s.y;return{width:i,height:o,x:l,y:c}}function oo(e,t,n){let r;if(t==="viewport")r=dg(e,n);else if(t==="document")r=cg(pt(e));else if(nt(t))r=hg(t,n);else{const a=Zl(e);r={x:t.x-a.x,y:t.y-a.y,width:t.width,height:t.height}}return Yr(r)}function ec(e,t){const n=Dt(e);return n===t||!nt(n)||pn(n)?!1:rt(n).position==="fixed"||ec(n,t)}function mg(e,t){const n=t.get(e);if(n)return n;let r=rr(e,[],!1).filter(o=>nt(o)&&Nn(o)!=="body"),a=null;const s=rt(e).position==="fixed";let i=s?Dt(e):e;for(;nt(i)&&!pn(i);){const o=rt(i),l=Gs(i);!l&&o.position==="fixed"&&(a=null),(s?!l&&!a:!l&&o.position==="static"&&!!a&&fg.has(a.position)||dr(i)&&!l&&ec(e,i))?r=r.filter(d=>d!==i):a=o,i=Dt(i)}return t.set(e,r),r}function pg(e){let{element:t,boundary:n,rootBoundary:r,strategy:a}=e;const i=[...n==="clippingAncestors"?ua(t)?[]:mg(t,this._c):[].concat(n),r],o=i[0],l=i.reduce((c,d)=>{const f=oo(t,d,a);return c.top=$e(f.top,c.top),c.right=Pt(f.right,c.right),c.bottom=Pt(f.bottom,c.bottom),c.left=$e(f.left,c.left),c},oo(t,o,a));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function gg(e){const{width:t,height:n}=Ql(e);return{width:t,height:n}}function bg(e,t,n){const r=ht(t),a=pt(t),s=n==="fixed",i=Wt(e,!0,s,t);let o={scrollLeft:0,scrollTop:0};const l=ft(0);function c(){l.x=ca(a)}if(r||!r&&!s)if((Nn(t)!=="body"||dr(a))&&(o=la(t)),r){const h=Wt(t,!0,s,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else a&&c();s&&!r&&a&&c();const d=a&&!r&&!s?Jl(a,o):ft(0),f=i.left+o.scrollLeft-l.x-d.x,p=i.top+o.scrollTop-l.y-d.y;return{x:f,y:p,width:i.width,height:i.height}}function La(e){return rt(e).position==="static"}function uo(e,t){if(!ht(e)||rt(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return pt(e)===n&&(n=n.ownerDocument.body),n}function tc(e,t){const n=Ge(e);if(ua(e))return n;if(!ht(e)){let a=Dt(e);for(;a&&!pn(a);){if(nt(a)&&!La(a))return a;a=Dt(a)}return n}let r=uo(e,t);for(;r&&Jp(r)&&La(r);)r=uo(r,t);return r&&pn(r)&&La(r)&&!Gs(r)?n:r||ag(e)||n}const Eg=async function(e){const t=this.getOffsetParent||tc,n=this.getDimensions,r=await n(e.floating);return{reference:bg(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Tg(e){return rt(e).direction==="rtl"}const xg={convertOffsetParentRelativeRectToViewportRelativeRect:ug,getDocumentElement:pt,getClippingRect:pg,getOffsetParent:tc,getElementRects:Eg,getClientRects:lg,getDimensions:gg,getScale:cn,isElement:nt,isRTL:Tg};function nc(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function yg(e,t){let n=null,r;const a=pt(e);function s(){var o;clearTimeout(r),(o=n)==null||o.disconnect(),n=null}function i(o,l){o===void 0&&(o=!1),l===void 0&&(l=1),s();const c=e.getBoundingClientRect(),{left:d,top:f,width:p,height:h}=c;if(o||t(),!p||!h)return;const x=Nr(f),g=Nr(a.clientWidth-(d+p)),A=Nr(a.clientHeight-(f+h)),E=Nr(d),N={rootMargin:-x+"px "+-g+"px "+-A+"px "+-E+"px",threshold:$e(0,Pt(1,l))||1};let k=!0;function L(v){const R=v[0].intersectionRatio;if(R!==l){if(!k)return i();R?i(!1,R):r=setTimeout(()=>{i(!1,1e-7)},1e3)}R===1&&!nc(c,e.getBoundingClientRect())&&i(),k=!1}try{n=new IntersectionObserver(L,{...N,root:a.ownerDocument})}catch{n=new IntersectionObserver(L,N)}n.observe(e)}return i(!0),s}function _g(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:a=!0,ancestorResize:s=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:o=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=Ks(e),d=a||s?[...c?rr(c):[],...rr(t)]:[];d.forEach(E=>{a&&E.addEventListener("scroll",n,{passive:!0}),s&&E.addEventListener("resize",n)});const f=c&&o?yg(c,n):null;let p=-1,h=null;i&&(h=new ResizeObserver(E=>{let[_]=E;_&&_.target===c&&h&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var N;(N=h)==null||N.observe(t)})),n()}),c&&!l&&h.observe(c),h.observe(t));let x,g=l?Wt(e):null;l&&A();function A(){const E=Wt(e);g&&!nc(g,E)&&n(),g=E,x=requestAnimationFrame(A)}return n(),()=>{var E;d.forEach(_=>{a&&_.removeEventListener("scroll",n),s&&_.removeEventListener("resize",n)}),f?.(),(E=h)==null||E.disconnect(),h=null,l&&cancelAnimationFrame(x)}}const Cg=qp,Ag=Gp,Sg=Wp,Ng=Kp,Ig=Vp,lo=Yp,vg=Xp,wg=(e,t,n)=>{const r=new Map,a={platform:xg,...n},s={...a.platform,_c:r};return zp(e,t,{...a,platform:s})};var kg=typeof document<"u",Og=function(){},Pr=kg?D.useLayoutEffect:Og;function Wr(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,a;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Wr(e[r],t[r]))return!1;return!0}if(a=Object.keys(e),n=a.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,a[r]))return!1;for(r=n;r--!==0;){const s=a[r];if(!(s==="_owner"&&e.$$typeof)&&!Wr(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function rc(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function co(e,t){const n=rc(e);return Math.round(t*n)/n}function Pa(e){const t=y.useRef(e);return Pr(()=>{t.current=e}),t}function Rg(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:a,elements:{reference:s,floating:i}={},transform:o=!0,whileElementsMounted:l,open:c}=e,[d,f]=y.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=y.useState(r);Wr(p,r)||h(r);const[x,g]=y.useState(null),[A,E]=y.useState(null),_=y.useCallback(B=>{B!==v.current&&(v.current=B,g(B))},[]),N=y.useCallback(B=>{B!==R.current&&(R.current=B,E(B))},[]),k=s||x,L=i||A,v=y.useRef(null),R=y.useRef(null),P=y.useRef(d),q=l!=null,K=Pa(l),U=Pa(a),z=Pa(c),$=y.useCallback(()=>{if(!v.current||!R.current)return;const B={placement:t,strategy:n,middleware:p};U.current&&(B.platform=U.current),wg(v.current,R.current,B).then(ie=>{const S={...ie,isPositioned:z.current!==!1};Y.current&&!Wr(P.current,S)&&(P.current=S,Su.flushSync(()=>{f(S)}))})},[p,t,n,U,z]);Pr(()=>{c===!1&&P.current.isPositioned&&(P.current.isPositioned=!1,f(B=>({...B,isPositioned:!1})))},[c]);const Y=y.useRef(!1);Pr(()=>(Y.current=!0,()=>{Y.current=!1}),[]),Pr(()=>{if(k&&(v.current=k),L&&(R.current=L),k&&L){if(K.current)return K.current(k,L,$);$()}},[k,L,$,K,q]);const F=y.useMemo(()=>({reference:v,floating:R,setReference:_,setFloating:N}),[_,N]),X=y.useMemo(()=>({reference:k,floating:L}),[k,L]),Q=y.useMemo(()=>{const B={position:n,left:0,top:0};if(!X.floating)return B;const ie=co(X.floating,d.x),S=co(X.floating,d.y);return o?{...B,transform:"translate("+ie+"px, "+S+"px)",...rc(X.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:ie,top:S}},[n,o,X.floating,d.x,d.y]);return y.useMemo(()=>({...d,update:$,refs:F,elements:X,floatingStyles:Q}),[d,$,F,X,Q])}const Lg=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:a}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?lo({element:r.current,padding:a}).fn(n):{}:r?lo({element:r,padding:a}).fn(n):{}}}},Pg=(e,t)=>({...Cg(e),options:[e,t]}),Dg=(e,t)=>({...Ag(e),options:[e,t]}),Mg=(e,t)=>({...vg(e),options:[e,t]}),Bg=(e,t)=>({...Sg(e),options:[e,t]}),Fg=(e,t)=>({...Ng(e),options:[e,t]}),Hg=(e,t)=>({...Ig(e),options:[e,t]}),Ug=(e,t)=>({...Lg(e),options:[e,t]});var jg="Arrow",ac=y.forwardRef((e,t)=>{const{children:n,width:r=10,height:a=5,...s}=e;return m.jsx(Ne.svg,{...s,ref:t,width:r,height:a,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:m.jsx("polygon",{points:"0,0 30,0 15,10"})})});ac.displayName=jg;var zg=ac;function sc(e){const[t,n]=y.useState(void 0);return Lt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(a=>{if(!Array.isArray(a)||!a.length)return;const s=a[0];let i,o;if("borderBoxSize"in s){const l=s.borderBoxSize,c=Array.isArray(l)?l[0]:l;i=c.inlineSize,o=c.blockSize}else i=e.offsetWidth,o=e.offsetHeight;n({width:i,height:o})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Qs="Popper",[ic,oc]=aa(Qs),[Yg,uc]=ic(Qs),lc=e=>{const{__scopePopper:t,children:n}=e,[r,a]=y.useState(null);return m.jsx(Yg,{scope:t,anchor:r,onAnchorChange:a,children:n})};lc.displayName=Qs;var cc="PopperAnchor",dc=y.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...a}=e,s=uc(cc,n),i=y.useRef(null),o=Xe(t,i),l=y.useRef(null);return y.useEffect(()=>{const c=l.current;l.current=r?.current||i.current,c!==l.current&&s.onAnchorChange(l.current)}),r?null:m.jsx(Ne.div,{...a,ref:o})});dc.displayName=cc;var Zs="PopperContent",[Wg,Vg]=ic(Zs),fc=y.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:a=0,align:s="center",alignOffset:i=0,arrowPadding:o=0,avoidCollisions:l=!0,collisionBoundary:c=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:p=!1,updatePositionStrategy:h="optimized",onPlaced:x,...g}=e,A=uc(Zs,n),[E,_]=y.useState(null),N=Xe(t,ce=>_(ce)),[k,L]=y.useState(null),v=sc(k),R=v?.width??0,P=v?.height??0,q=r+(s!=="center"?"-"+s:""),K=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},U=Array.isArray(c)?c:[c],z=U.length>0,$={padding:K,boundary:U.filter(qg),altBoundary:z},{refs:Y,floatingStyles:F,placement:X,isPositioned:Q,middlewareData:B}=Rg({strategy:"fixed",placement:q,whileElementsMounted:(...ce)=>_g(...ce,{animationFrame:h==="always"}),elements:{reference:A.anchor},middleware:[Pg({mainAxis:a+P,alignmentAxis:i}),l&&Dg({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?Mg():void 0,...$}),l&&Bg({...$}),Fg({...$,apply:({elements:ce,rects:Me,availableWidth:je,availableHeight:ze})=>{const{width:it,height:St}=Me.reference,Qt=ce.floating.style;Qt.setProperty("--radix-popper-available-width",`${je}px`),Qt.setProperty("--radix-popper-available-height",`${ze}px`),Qt.setProperty("--radix-popper-anchor-width",`${it}px`),Qt.setProperty("--radix-popper-anchor-height",`${St}px`)}}),k&&Ug({element:k,padding:o}),Gg({arrowWidth:R,arrowHeight:P}),p&&Hg({strategy:"referenceHidden",...$})]}),[ie,S]=pc(X),xe=mn(x);Lt(()=>{Q&&xe?.()},[Q,xe]);const we=B.arrow?.x,I=B.arrow?.y,fe=B.arrow?.centerOffset!==0,[De,Ee]=y.useState();return Lt(()=>{E&&Ee(window.getComputedStyle(E).zIndex)},[E]),m.jsx("div",{ref:Y.setFloating,"data-radix-popper-content-wrapper":"",style:{...F,transform:Q?F.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:De,"--radix-popper-transform-origin":[B.transformOrigin?.x,B.transformOrigin?.y].join(" "),...B.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:m.jsx(Wg,{scope:n,placedSide:ie,onArrowChange:L,arrowX:we,arrowY:I,shouldHideArrow:fe,children:m.jsx(Ne.div,{"data-side":ie,"data-align":S,...g,ref:N,style:{...g.style,animation:Q?void 0:"none"}})})})});fc.displayName=Zs;var hc="PopperArrow",$g={top:"bottom",right:"left",bottom:"top",left:"right"},mc=y.forwardRef(function(t,n){const{__scopePopper:r,...a}=t,s=Vg(hc,r),i=$g[s.placedSide];return m.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[i]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:m.jsx(zg,{...a,ref:n,style:{...a.style,display:"block"}})})});mc.displayName=hc;function qg(e){return e!==null}var Gg=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:a}=t,i=a.arrow?.centerOffset!==0,o=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[c,d]=pc(n),f={start:"0%",center:"50%",end:"100%"}[d],p=(a.arrow?.x??0)+o/2,h=(a.arrow?.y??0)+l/2;let x="",g="";return c==="bottom"?(x=i?f:`${p}px`,g=`${-l}px`):c==="top"?(x=i?f:`${p}px`,g=`${r.floating.height+l}px`):c==="right"?(x=`${-l}px`,g=i?f:`${h}px`):c==="left"&&(x=`${r.floating.width+l}px`,g=i?f:`${h}px`),{data:{x,y:g}}}});function pc(e){const[t,n="center"]=e.split("-");return[t,n]}var Xg=lc,gc=dc,Kg=fc,Qg=mc;function Zg(e){const t=Jg(e),n=y.forwardRef((r,a)=>{const{children:s,...i}=r,o=y.Children.toArray(s),l=o.find(t1);if(l){const c=l.props.children,d=o.map(f=>f===l?y.Children.count(c)>1?y.Children.only(null):y.isValidElement(c)?c.props.children:null:f);return m.jsx(t,{...i,ref:a,children:y.isValidElement(c)?y.cloneElement(c,void 0,d):null})}return m.jsx(t,{...i,ref:a,children:s})});return n.displayName=`${e}.Slot`,n}function Jg(e){const t=y.forwardRef((n,r)=>{const{children:a,...s}=n;if(y.isValidElement(a)){const i=r1(a),o=n1(s,a.props);return a.type!==y.Fragment&&(o.ref=r?ra(r,i):i),y.cloneElement(a,o)}return y.Children.count(a)>1?y.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var e1=Symbol("radix.slottable");function t1(e){return y.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===e1}function n1(e,t){const n={...t};for(const r in t){const a=e[r],s=t[r];/^on[A-Z]/.test(r)?a&&s?n[r]=(...o)=>{const l=s(...o);return a(...o),l}:a&&(n[r]=a):r==="style"?n[r]={...a,...s}:r==="className"&&(n[r]=[a,s].filter(Boolean).join(" "))}return{...e,...n}}function r1(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var da="Popover",[bc]=aa(da,[oc]),fr=oc(),[a1,qt]=bc(da),Js=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:a,onOpenChange:s,modal:i=!1}=e,o=fr(t),l=y.useRef(null),[c,d]=y.useState(!1),[f,p]=ws({prop:r,defaultProp:a??!1,onChange:s,caller:da});return m.jsx(Xg,{...o,children:m.jsx(a1,{scope:t,contentId:Or(),triggerRef:l,open:f,onOpenChange:p,onOpenToggle:y.useCallback(()=>p(h=>!h),[p]),hasCustomAnchor:c,onCustomAnchorAdd:y.useCallback(()=>d(!0),[]),onCustomAnchorRemove:y.useCallback(()=>d(!1),[]),modal:i,children:n})})};Js.displayName=da;var Ec="PopoverAnchor",s1=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,a=qt(Ec,n),s=fr(n),{onCustomAnchorAdd:i,onCustomAnchorRemove:o}=a;return y.useEffect(()=>(i(),()=>o()),[i,o]),m.jsx(gc,{...s,...r,ref:t})});s1.displayName=Ec;var Tc="PopoverTrigger",ei=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,a=qt(Tc,n),s=fr(n),i=Xe(t,a.triggerRef),o=m.jsx(Ne.button,{type:"button","aria-haspopup":"dialog","aria-expanded":a.open,"aria-controls":a.contentId,"data-state":_c(a.open),...r,ref:i,onClick:Le(e.onClick,a.onOpenToggle)});return a.hasCustomAnchor?o:m.jsx(gc,{asChild:!0,...s,children:o})});ei.displayName=Tc;var i1="PopoverPortal",[fA,o1]=bc(i1,{forceMount:void 0}),gn="PopoverContent",ti=y.forwardRef((e,t)=>{const n=o1(gn,e.__scopePopover),{forceMount:r=n.forceMount,...a}=e,s=qt(gn,e.__scopePopover);return m.jsx(_n,{present:r||s.open,children:s.modal?m.jsx(l1,{...a,ref:t}):m.jsx(c1,{...a,ref:t})})});ti.displayName=gn;var u1=Zg("PopoverContent.RemoveScroll"),l1=y.forwardRef((e,t)=>{const n=qt(gn,e.__scopePopover),r=y.useRef(null),a=Xe(t,r),s=y.useRef(!1);return y.useEffect(()=>{const i=r.current;if(i)return ul(i)},[]),m.jsx(Rs,{as:u1,allowPinchZoom:!0,children:m.jsx(xc,{...e,ref:a,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Le(e.onCloseAutoFocus,i=>{i.preventDefault(),s.current||n.triggerRef.current?.focus()}),onPointerDownOutside:Le(e.onPointerDownOutside,i=>{const o=i.detail.originalEvent,l=o.button===0&&o.ctrlKey===!0,c=o.button===2||l;s.current=c},{checkForDefaultPrevented:!1}),onFocusOutside:Le(e.onFocusOutside,i=>i.preventDefault(),{checkForDefaultPrevented:!1})})})}),c1=y.forwardRef((e,t)=>{const n=qt(gn,e.__scopePopover),r=y.useRef(!1),a=y.useRef(!1);return m.jsx(xc,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(r.current||n.triggerRef.current?.focus(),s.preventDefault()),r.current=!1,a.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(a.current=!0));const i=s.target;n.triggerRef.current?.contains(i)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&a.current&&s.preventDefault()}})}),xc=y.forwardRef((e,t)=>{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:s,disableOutsidePointerEvents:i,onEscapeKeyDown:o,onPointerDownOutside:l,onFocusOutside:c,onInteractOutside:d,...f}=e,p=qt(gn,n),h=fr(n);return Ju(),m.jsx(Os,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:s,children:m.jsx(ks,{asChild:!0,disableOutsidePointerEvents:i,onInteractOutside:d,onEscapeKeyDown:o,onPointerDownOutside:l,onFocusOutside:c,onDismiss:()=>p.onOpenChange(!1),children:m.jsx(Kg,{"data-state":_c(p.open),role:"dialog",id:p.contentId,...h,...f,ref:t,style:{...f.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),yc="PopoverClose",d1=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,a=qt(yc,n);return m.jsx(Ne.button,{type:"button",...r,ref:t,onClick:Le(e.onClick,()=>a.onOpenChange(!1))})});d1.displayName=yc;var f1="PopoverArrow",h1=y.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,a=fr(n);return m.jsx(Qg,{...a,...r,ref:t})});h1.displayName=f1;function _c(e){return e?"open":"closed"}var Cc=Js,Ac=ei,Sc=ti;function fo(e){const t=[],n=String(e||"");let r=n.indexOf(","),a=0,s=!1;for(;!s;){r===-1&&(r=n.length,s=!0);const i=n.slice(a,r).trim();(i||!s)&&t.push(i),a=r+1,r=n.indexOf(",",a)}return t}function Nc(e,t){const n={};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const m1=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,p1=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,g1={};function ho(e,t){return(g1.jsx?p1:m1).test(e)}const b1=/[ \t\n\f\r]/g;function E1(e){return typeof e=="object"?e.type==="text"?mo(e.value):!1:mo(e)}function mo(e){return e.replace(b1,"")===""}let hr=class{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}};hr.prototype.normal={};hr.prototype.property={};hr.prototype.space=void 0;function Ic(e,t){const n={},r={};for(const a of e)Object.assign(n,a.property),Object.assign(r,a.normal);return new hr(n,r,t)}function ar(e){return e.toLowerCase()}let Ue=class{constructor(t,n){this.attribute=n,this.property=t}};Ue.prototype.attribute="";Ue.prototype.booleanish=!1;Ue.prototype.boolean=!1;Ue.prototype.commaOrSpaceSeparated=!1;Ue.prototype.commaSeparated=!1;Ue.prototype.defined=!1;Ue.prototype.mustUseProperty=!1;Ue.prototype.number=!1;Ue.prototype.overloadedBoolean=!1;Ue.prototype.property="";Ue.prototype.spaceSeparated=!1;Ue.prototype.space=void 0;let T1=0;const re=Gt(),ye=Gt(),fs=Gt(),W=Gt(),me=Gt(),dn=Gt(),We=Gt();function Gt(){return 2**++T1}const hs=Object.freeze(Object.defineProperty({__proto__:null,boolean:re,booleanish:ye,commaOrSpaceSeparated:We,commaSeparated:dn,number:W,overloadedBoolean:fs,spaceSeparated:me},Symbol.toStringTag,{value:"Module"})),Da=Object.keys(hs);let ni=class extends Ue{constructor(t,n,r,a){let s=-1;if(super(t,n),po(this,"space",a),typeof r=="number")for(;++s<Da.length;){const i=Da[s];po(this,Da[s],(r&hs[i])===hs[i])}}};ni.prototype.defined=!0;function po(e,t,n){n&&(e[t]=n)}function In(e){const t={},n={};for(const[r,a]of Object.entries(e.properties)){const s=new ni(r,e.transform(e.attributes||{},r),a,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(s.mustUseProperty=!0),t[r]=s,n[ar(r)]=r,n[ar(s.attribute)]=r}return new hr(t,n,e.space)}const vc=In({properties:{ariaActiveDescendant:null,ariaAtomic:ye,ariaAutoComplete:null,ariaBusy:ye,ariaChecked:ye,ariaColCount:W,ariaColIndex:W,ariaColSpan:W,ariaControls:me,ariaCurrent:null,ariaDescribedBy:me,ariaDetails:null,ariaDisabled:ye,ariaDropEffect:me,ariaErrorMessage:null,ariaExpanded:ye,ariaFlowTo:me,ariaGrabbed:ye,ariaHasPopup:null,ariaHidden:ye,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:me,ariaLevel:W,ariaLive:null,ariaModal:ye,ariaMultiLine:ye,ariaMultiSelectable:ye,ariaOrientation:null,ariaOwns:me,ariaPlaceholder:null,ariaPosInSet:W,ariaPressed:ye,ariaReadOnly:ye,ariaRelevant:null,ariaRequired:ye,ariaRoleDescription:me,ariaRowCount:W,ariaRowIndex:W,ariaRowSpan:W,ariaSelected:ye,ariaSetSize:W,ariaSort:null,ariaValueMax:W,ariaValueMin:W,ariaValueNow:W,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function wc(e,t){return t in e?e[t]:t}function kc(e,t){return wc(e,t.toLowerCase())}const x1=In({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:dn,acceptCharset:me,accessKey:me,action:null,allow:null,allowFullScreen:re,allowPaymentRequest:re,allowUserMedia:re,alt:null,as:null,async:re,autoCapitalize:null,autoComplete:me,autoFocus:re,autoPlay:re,blocking:me,capture:null,charSet:null,checked:re,cite:null,className:me,cols:W,colSpan:null,content:null,contentEditable:ye,controls:re,controlsList:me,coords:W|dn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:re,defer:re,dir:null,dirName:null,disabled:re,download:fs,draggable:ye,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:re,formTarget:null,headers:me,height:W,hidden:fs,high:W,href:null,hrefLang:null,htmlFor:me,httpEquiv:me,id:null,imageSizes:null,imageSrcSet:null,inert:re,inputMode:null,integrity:null,is:null,isMap:re,itemId:null,itemProp:me,itemRef:me,itemScope:re,itemType:me,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:re,low:W,manifest:null,max:null,maxLength:W,media:null,method:null,min:null,minLength:W,multiple:re,muted:re,name:null,nonce:null,noModule:re,noValidate:re,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:re,optimum:W,pattern:null,ping:me,placeholder:null,playsInline:re,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:re,referrerPolicy:null,rel:me,required:re,reversed:re,rows:W,rowSpan:W,sandbox:me,scope:null,scoped:re,seamless:re,selected:re,shadowRootClonable:re,shadowRootDelegatesFocus:re,shadowRootMode:null,shape:null,size:W,sizes:null,slot:null,span:W,spellCheck:ye,src:null,srcDoc:null,srcLang:null,srcSet:null,start:W,step:null,style:null,tabIndex:W,target:null,title:null,translate:null,type:null,typeMustMatch:re,useMap:null,value:ye,width:W,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:me,axis:null,background:null,bgColor:null,border:W,borderColor:null,bottomMargin:W,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:re,declare:re,event:null,face:null,frame:null,frameBorder:null,hSpace:W,leftMargin:W,link:null,longDesc:null,lowSrc:null,marginHeight:W,marginWidth:W,noResize:re,noHref:re,noShade:re,noWrap:re,object:null,profile:null,prompt:null,rev:null,rightMargin:W,rules:null,scheme:null,scrolling:ye,standby:null,summary:null,text:null,topMargin:W,valueType:null,version:null,vAlign:null,vLink:null,vSpace:W,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:re,disableRemotePlayback:re,prefix:null,property:null,results:W,security:null,unselectable:null},space:"html",transform:kc}),y1=In({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:We,accentHeight:W,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:W,amplitude:W,arabicForm:null,ascent:W,attributeName:null,attributeType:null,azimuth:W,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:W,by:null,calcMode:null,capHeight:W,className:me,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:W,diffuseConstant:W,direction:null,display:null,dur:null,divisor:W,dominantBaseline:null,download:re,dx:null,dy:null,edgeMode:null,editable:null,elevation:W,enableBackground:null,end:null,event:null,exponent:W,externalResourcesRequired:null,fill:null,fillOpacity:W,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:dn,g2:dn,glyphName:dn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:W,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:W,horizOriginX:W,horizOriginY:W,id:null,ideographic:W,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:W,k:W,k1:W,k2:W,k3:W,k4:W,kernelMatrix:We,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:W,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:W,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:W,overlineThickness:W,paintOrder:null,panose1:null,path:null,pathLength:W,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:me,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:W,pointsAtY:W,pointsAtZ:W,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:We,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:We,rev:We,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:We,requiredFeatures:We,requiredFonts:We,requiredFormats:We,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:W,specularExponent:W,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:W,strikethroughThickness:W,string:null,stroke:null,strokeDashArray:We,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:W,strokeOpacity:W,strokeWidth:null,style:null,surfaceScale:W,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:We,tabIndex:W,tableValues:null,target:null,targetX:W,targetY:W,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:We,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:W,underlineThickness:W,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:W,values:null,vAlphabetic:W,vMathematical:W,vectorEffect:null,vHanging:W,vIdeographic:W,version:null,vertAdvY:W,vertOriginX:W,vertOriginY:W,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:W,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:wc}),Oc=In({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),Rc=In({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:kc}),Lc=In({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),_1={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},C1=/[A-Z]/g,go=/-[a-z]/g,A1=/^data[-\w.:]+$/i;function ri(e,t){const n=ar(t);let r=t,a=Ue;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&A1.test(t)){if(t.charAt(4)==="-"){const s=t.slice(5).replace(go,N1);r="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=t.slice(4);if(!go.test(s)){let i=s.replace(C1,S1);i.charAt(0)!=="-"&&(i="-"+i),t="data"+i}}a=ni}return new a(r,t)}function S1(e){return"-"+e.toLowerCase()}function N1(e){return e.charAt(1).toUpperCase()}const fa=Ic([vc,x1,Oc,Rc,Lc],"html"),vn=Ic([vc,y1,Oc,Rc,Lc],"svg");function bo(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function Pc(e){return e.join(" ").trim()}var an={},Ma,Eo;function I1(){if(Eo)return Ma;Eo=1;var e=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,t=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,a=/^:\s*/,s=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,i=/^[;\s]*/,o=/^\s+|\s+$/g,l=`
62
+ `,c="/",d="*",f="",p="comment",h="declaration";function x(A,E){if(typeof A!="string")throw new TypeError("First argument must be a string");if(!A)return[];E=E||{};var _=1,N=1;function k(Y){var F=Y.match(t);F&&(_+=F.length);var X=Y.lastIndexOf(l);N=~X?Y.length-X:N+Y.length}function L(){var Y={line:_,column:N};return function(F){return F.position=new v(Y),q(),F}}function v(Y){this.start=Y,this.end={line:_,column:N},this.source=E.source}v.prototype.content=A;function R(Y){var F=new Error(E.source+":"+_+":"+N+": "+Y);if(F.reason=Y,F.filename=E.source,F.line=_,F.column=N,F.source=A,!E.silent)throw F}function P(Y){var F=Y.exec(A);if(F){var X=F[0];return k(X),A=A.slice(X.length),F}}function q(){P(n)}function K(Y){var F;for(Y=Y||[];F=U();)F!==!1&&Y.push(F);return Y}function U(){var Y=L();if(!(c!=A.charAt(0)||d!=A.charAt(1))){for(var F=2;f!=A.charAt(F)&&(d!=A.charAt(F)||c!=A.charAt(F+1));)++F;if(F+=2,f===A.charAt(F-1))return R("End of comment missing");var X=A.slice(2,F-2);return N+=2,k(X),A=A.slice(F),N+=2,Y({type:p,comment:X})}}function z(){var Y=L(),F=P(r);if(F){if(U(),!P(a))return R("property missing ':'");var X=P(s),Q=Y({type:h,property:g(F[0].replace(e,f)),value:X?g(X[0].replace(e,f)):f});return P(i),Q}}function $(){var Y=[];K(Y);for(var F;F=z();)F!==!1&&(Y.push(F),K(Y));return Y}return q(),$()}function g(A){return A?A.replace(o,f):f}return Ma=x,Ma}var To;function v1(){if(To)return an;To=1;var e=an&&an.__importDefault||function(r){return r&&r.__esModule?r:{default:r}};Object.defineProperty(an,"__esModule",{value:!0}),an.default=n;const t=e(I1());function n(r,a){let s=null;if(!r||typeof r!="string")return s;const i=(0,t.default)(r),o=typeof a=="function";return i.forEach(l=>{if(l.type!=="declaration")return;const{property:c,value:d}=l;o?a(c,d,l):d&&(s=s||{},s[c]=d)}),s}return an}var Bn={},xo;function w1(){if(xo)return Bn;xo=1,Object.defineProperty(Bn,"__esModule",{value:!0}),Bn.camelCase=void 0;var e=/^--[a-zA-Z0-9_-]+$/,t=/-([a-z])/g,n=/^[^-]+$/,r=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,s=function(c){return!c||n.test(c)||e.test(c)},i=function(c,d){return d.toUpperCase()},o=function(c,d){return"".concat(d,"-")},l=function(c,d){return d===void 0&&(d={}),s(c)?c:(c=c.toLowerCase(),d.reactCompat?c=c.replace(a,o):c=c.replace(r,o),c.replace(t,i))};return Bn.camelCase=l,Bn}var Fn,yo;function k1(){if(yo)return Fn;yo=1;var e=Fn&&Fn.__importDefault||function(a){return a&&a.__esModule?a:{default:a}},t=e(v1()),n=w1();function r(a,s){var i={};return!a||typeof a!="string"||(0,t.default)(a,function(o,l){o&&l&&(i[(0,n.camelCase)(o,s)]=l)}),i}return r.default=r,Fn=r,Fn}var O1=k1();const R1=Nu(O1),ha=Dc("end"),gt=Dc("start");function Dc(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function L1(e){const t=gt(e),n=ha(e);if(t&&n)return{start:t,end:n}}function qn(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?_o(e.position):"start"in e||"end"in e?_o(e):"line"in e||"column"in e?ms(e):""}function ms(e){return Co(e&&e.line)+":"+Co(e&&e.column)}function _o(e){return ms(e&&e.start)+"-"+ms(e&&e.end)}function Co(e){return e&&typeof e=="number"?e:1}class Ie extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let a="",s={},i=!1;if(n&&("line"in n&&"column"in n?s={place:n}:"start"in n&&"end"in n?s={place:n}:"type"in n?s={ancestors:[n],place:n.position}:s={...n}),typeof t=="string"?a=t:!s.cause&&t&&(i=!0,a=t.message,s.cause=t),!s.ruleId&&!s.source&&typeof r=="string"){const l=r.indexOf(":");l===-1?s.ruleId=r:(s.source=r.slice(0,l),s.ruleId=r.slice(l+1))}if(!s.place&&s.ancestors&&s.ancestors){const l=s.ancestors[s.ancestors.length-1];l&&(s.place=l.position)}const o=s.place&&"start"in s.place?s.place.start:s.place;this.ancestors=s.ancestors||void 0,this.cause=s.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file="",this.message=a,this.line=o?o.line:void 0,this.name=qn(s.place)||"1:1",this.place=s.place||void 0,this.reason=this.message,this.ruleId=s.ruleId||void 0,this.source=s.source||void 0,this.stack=i&&s.cause&&typeof s.cause.stack=="string"?s.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Ie.prototype.file="";Ie.prototype.name="";Ie.prototype.reason="";Ie.prototype.message="";Ie.prototype.stack="";Ie.prototype.column=void 0;Ie.prototype.line=void 0;Ie.prototype.ancestors=void 0;Ie.prototype.cause=void 0;Ie.prototype.fatal=void 0;Ie.prototype.place=void 0;Ie.prototype.ruleId=void 0;Ie.prototype.source=void 0;const ai={}.hasOwnProperty,P1=new Map,D1=/[A-Z]/g,M1=new Set(["table","tbody","thead","tfoot","tr"]),B1=new Set(["td","th"]),Mc="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function F1(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=$1(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=V1(n,t.jsx,t.jsxs)}const a={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?vn:fa,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},s=Bc(a,e,void 0);return s&&typeof s!="string"?s:a.create(e,a.Fragment,{children:s||void 0},void 0)}function Bc(e,t,n){if(t.type==="element")return H1(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return U1(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return z1(e,t,n);if(t.type==="mdxjsEsm")return j1(e,t);if(t.type==="root")return Y1(e,t,n);if(t.type==="text")return W1(e,t)}function H1(e,t,n){const r=e.schema;let a=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(a=vn,e.schema=a),e.ancestors.push(t);const s=Hc(e,t.tagName,!1),i=q1(e,t);let o=ii(e,t);return M1.has(t.tagName)&&(o=o.filter(function(l){return typeof l=="string"?!E1(l):!0})),Fc(e,i,s,t),si(i,o),e.ancestors.pop(),e.schema=r,e.create(t,s,i,n)}function U1(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return r.type,e.evaluater.evaluateExpression(r.expression)}sr(e,t.position)}function j1(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);sr(e,t.position)}function z1(e,t,n){const r=e.schema;let a=r;t.name==="svg"&&r.space==="html"&&(a=vn,e.schema=a),e.ancestors.push(t);const s=t.name===null?e.Fragment:Hc(e,t.name,!0),i=G1(e,t),o=ii(e,t);return Fc(e,i,s,t),si(i,o),e.ancestors.pop(),e.schema=r,e.create(t,s,i,n)}function Y1(e,t,n){const r={};return si(r,ii(e,t)),e.create(t,e.Fragment,r,n)}function W1(e,t){return t.value}function Fc(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function si(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function V1(e,t,n){return r;function r(a,s,i,o){const c=Array.isArray(i.children)?n:t;return o?c(s,i,o):c(s,i)}}function $1(e,t){return n;function n(r,a,s,i){const o=Array.isArray(s.children),l=gt(r);return t(a,s,i,o,{columnNumber:l?l.column-1:void 0,fileName:e,lineNumber:l?l.line:void 0},void 0)}}function q1(e,t){const n={};let r,a;for(a in t.properties)if(a!=="children"&&ai.call(t.properties,a)){const s=X1(e,a,t.properties[a]);if(s){const[i,o]=s;e.tableCellAlignToStyle&&i==="align"&&typeof o=="string"&&B1.has(t.tagName)?r=o:n[i]=o}}if(r){const s=n.style||(n.style={});s[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function G1(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const s=r.data.estree.body[0];s.type;const i=s.expression;i.type;const o=i.properties[0];o.type,Object.assign(n,e.evaluater.evaluateExpression(o.argument))}else sr(e,t.position);else{const a=r.name;let s;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const o=r.value.data.estree.body[0];o.type,s=e.evaluater.evaluateExpression(o.expression)}else sr(e,t.position);else s=r.value===null?!0:r.value;n[a]=s}return n}function ii(e,t){const n=[];let r=-1;const a=e.passKeys?new Map:P1;for(;++r<t.children.length;){const s=t.children[r];let i;if(e.passKeys){const l=s.type==="element"?s.tagName:s.type==="mdxJsxFlowElement"||s.type==="mdxJsxTextElement"?s.name:void 0;if(l){const c=a.get(l)||0;i=l+"-"+c,a.set(l,c+1)}}const o=Bc(e,s,i);o!==void 0&&n.push(o)}return n}function X1(e,t,n){const r=ri(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Nc(n):Pc(n)),r.property==="style"){let a=typeof n=="object"?n:K1(e,String(n));return e.stylePropertyNameCase==="css"&&(a=Q1(a)),["style",a]}return[e.elementAttributeNameCase==="react"&&r.space?_1[r.property]||r.property:r.attribute,n]}}function K1(e,t){try{return R1(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,a=new Ie("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw a.file=e.filePath||void 0,a.url=Mc+"#cannot-parse-style-attribute",a}}function Hc(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const a=t.split(".");let s=-1,i;for(;++s<a.length;){const o=ho(a[s])?{type:"Identifier",name:a[s]}:{type:"Literal",value:a[s]};i=i?{type:"MemberExpression",object:i,property:o,computed:!!(s&&o.type==="Literal"),optional:!1}:o}r=i}else r=ho(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const a=r.value;return ai.call(e.components,a)?e.components[a]:a}if(e.evaluater)return e.evaluater.evaluateExpression(r);sr(e)}function sr(e,t){const n=new Ie("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=Mc+"#cannot-handle-mdx-estrees-without-createevaluater",n}function Q1(e){const t={};let n;for(n in e)ai.call(e,n)&&(t[Z1(n)]=e[n]);return t}function Z1(e){let t=e.replace(D1,J1);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function J1(e){return"-"+e.toLowerCase()}const Ba={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},eb={};function tb(e,t){const n=eb,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,a=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return Uc(e,r,a)}function Uc(e,t,n){if(nb(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return Ao(e.children,t,n)}return Array.isArray(e)?Ao(e,t,n):""}function Ao(e,t,n){const r=[];let a=-1;for(;++a<e.length;)r[a]=Uc(e[a],t,n);return r.join("")}function nb(e){return!!(e&&typeof e=="object")}const So=document.createElement("i");function oi(e){const t="&"+e+";";So.innerHTML=t;const n=So.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function mt(e,t,n,r){const a=e.length;let s=0,i;if(t<0?t=-t>a?0:a+t:t=t>a?a:t,n=n>0?n:0,r.length<1e4)i=Array.from(r),i.unshift(t,n),e.splice(...i);else for(n&&e.splice(t,n);s<r.length;)i=r.slice(s,s+1e4),i.unshift(t,0),e.splice(...i),s+=1e4,t+=1e4}function Ke(e,t){return e.length>0?(mt(e,e.length,0,t),e):t}const No={}.hasOwnProperty;function rb(e){const t={};let n=-1;for(;++n<e.length;)ab(t,e[n]);return t}function ab(e,t){let n;for(n in t){const a=(No.call(e,n)?e[n]:void 0)||(e[n]={}),s=t[n];let i;if(s)for(i in s){No.call(a,i)||(a[i]=[]);const o=s[i];sb(a[i],Array.isArray(o)?o:o?[o]:[])}}}function sb(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);mt(e,0,0,r)}function jc(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}function fn(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}const ct=Mt(/[A-Za-z]/),qe=Mt(/[\dA-Za-z]/),ib=Mt(/[#-'*+\--9=?A-Z^-~]/);function ps(e){return e!==null&&(e<32||e===127)}const gs=Mt(/\d/),ob=Mt(/[\dA-Fa-f]/),ub=Mt(/[!-/:-@[-`{-~]/);function ee(e){return e!==null&&e<-2}function He(e){return e!==null&&(e<0||e===32)}function le(e){return e===-2||e===-1||e===32}const lb=Mt(new RegExp("\\p{P}|\\p{S}","u")),cb=Mt(/\s/);function Mt(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function wn(e){const t=[];let n=-1,r=0,a=0;for(;++n<e.length;){const s=e.charCodeAt(n);let i="";if(s===37&&qe(e.charCodeAt(n+1))&&qe(e.charCodeAt(n+2)))a=2;else if(s<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(s))||(i=String.fromCharCode(s));else if(s>55295&&s<57344){const o=e.charCodeAt(n+1);s<56320&&o>56319&&o<57344?(i=String.fromCharCode(s,o),a=1):i="�"}else i=String.fromCharCode(s);i&&(t.push(e.slice(r,n),encodeURIComponent(i)),r=n+a+1,i=""),a&&(n+=a,a=0)}return t.join("")+e.slice(r)}function ge(e,t,n,r){const a=r?r-1:Number.POSITIVE_INFINITY;let s=0;return i;function i(l){return le(l)?(e.enter(n),o(l)):t(l)}function o(l){return le(l)&&s++<a?(e.consume(l),o):(e.exit(n),t(l))}}const db={tokenize:fb};function fb(e){const t=e.attempt(this.parser.constructs.contentInitial,r,a);let n;return t;function r(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),ge(e,t,"linePrefix")}function a(o){return e.enter("paragraph"),s(o)}function s(o){const l=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=l),n=l,i(o)}function i(o){if(o===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(o);return}return ee(o)?(e.consume(o),e.exit("chunkText"),s):(e.consume(o),i)}}const hb={tokenize:mb},Io={tokenize:pb};function mb(e){const t=this,n=[];let r=0,a,s,i;return o;function o(N){if(r<n.length){const k=n[r];return t.containerState=k[1],e.attempt(k[0].continuation,l,c)(N)}return c(N)}function l(N){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,a&&_();const k=t.events.length;let L=k,v;for(;L--;)if(t.events[L][0]==="exit"&&t.events[L][1].type==="chunkFlow"){v=t.events[L][1].end;break}E(r);let R=k;for(;R<t.events.length;)t.events[R][1].end={...v},R++;return mt(t.events,L+1,0,t.events.slice(k)),t.events.length=R,c(N)}return o(N)}function c(N){if(r===n.length){if(!a)return p(N);if(a.currentConstruct&&a.currentConstruct.concrete)return x(N);t.interrupt=!!(a.currentConstruct&&!a._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Io,d,f)(N)}function d(N){return a&&_(),E(r),p(N)}function f(N){return t.parser.lazy[t.now().line]=r!==n.length,i=t.now().offset,x(N)}function p(N){return t.containerState={},e.attempt(Io,h,x)(N)}function h(N){return r++,n.push([t.currentConstruct,t.containerState]),p(N)}function x(N){if(N===null){a&&_(),E(0),e.consume(N);return}return a=a||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:a,contentType:"flow",previous:s}),g(N)}function g(N){if(N===null){A(e.exit("chunkFlow"),!0),E(0),e.consume(N);return}return ee(N)?(e.consume(N),A(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(N),g)}function A(N,k){const L=t.sliceStream(N);if(k&&L.push(null),N.previous=s,s&&(s.next=N),s=N,a.defineSkip(N.start),a.write(L),t.parser.lazy[N.start.line]){let v=a.events.length;for(;v--;)if(a.events[v][1].start.offset<i&&(!a.events[v][1].end||a.events[v][1].end.offset>i))return;const R=t.events.length;let P=R,q,K;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){if(q){K=t.events[P][1].end;break}q=!0}for(E(r),v=R;v<t.events.length;)t.events[v][1].end={...K},v++;mt(t.events,P+1,0,t.events.slice(R)),t.events.length=v}}function E(N){let k=n.length;for(;k-- >N;){const L=n[k];t.containerState=L[1],L[0].exit.call(t,e)}n.length=N}function _(){a.write([null]),s=void 0,a=void 0,t.containerState._closeFlow=void 0}}function pb(e,t,n){return ge(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}function vo(e){if(e===null||He(e)||cb(e))return 1;if(lb(e))return 2}function ui(e,t,n){const r=[];let a=-1;for(;++a<e.length;){const s=e[a].resolveAll;s&&!r.includes(s)&&(t=s(t,n),r.push(s))}return t}const bs={name:"attention",resolveAll:gb,tokenize:bb};function gb(e,t){let n=-1,r,a,s,i,o,l,c,d;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;l=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const f={...e[r][1].end},p={...e[n][1].start};wo(f,-l),wo(p,l),i={type:l>1?"strongSequence":"emphasisSequence",start:f,end:{...e[r][1].end}},o={type:l>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:p},s={type:l>1?"strongText":"emphasisText",start:{...e[r][1].end},end:{...e[n][1].start}},a={type:l>1?"strong":"emphasis",start:{...i.start},end:{...o.end}},e[r][1].end={...i.start},e[n][1].start={...o.end},c=[],e[r][1].end.offset-e[r][1].start.offset&&(c=Ke(c,[["enter",e[r][1],t],["exit",e[r][1],t]])),c=Ke(c,[["enter",a,t],["enter",i,t],["exit",i,t],["enter",s,t]]),c=Ke(c,ui(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),c=Ke(c,[["exit",s,t],["enter",o,t],["exit",o,t],["exit",a,t]]),e[n][1].end.offset-e[n][1].start.offset?(d=2,c=Ke(c,[["enter",e[n][1],t],["exit",e[n][1],t]])):d=0,mt(e,r-1,n-r+3,c),n=r+c.length-d-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function bb(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,a=vo(r);let s;return i;function i(l){return s=l,e.enter("attentionSequence"),o(l)}function o(l){if(l===s)return e.consume(l),o;const c=e.exit("attentionSequence"),d=vo(l),f=!d||d===2&&a||n.includes(l),p=!a||a===2&&d||n.includes(r);return c._open=!!(s===42?f:f&&(a||!p)),c._close=!!(s===42?p:p&&(d||!f)),t(l)}}function wo(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const Eb={name:"autolink",tokenize:Tb};function Tb(e,t,n){let r=0;return a;function a(h){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),s}function s(h){return ct(h)?(e.consume(h),i):h===64?n(h):c(h)}function i(h){return h===43||h===45||h===46||qe(h)?(r=1,o(h)):c(h)}function o(h){return h===58?(e.consume(h),r=0,l):(h===43||h===45||h===46||qe(h))&&r++<32?(e.consume(h),o):(r=0,c(h))}function l(h){return h===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.exit("autolink"),t):h===null||h===32||h===60||ps(h)?n(h):(e.consume(h),l)}function c(h){return h===64?(e.consume(h),d):ib(h)?(e.consume(h),c):n(h)}function d(h){return qe(h)?f(h):n(h)}function f(h){return h===46?(e.consume(h),r=0,d):h===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(h),e.exit("autolinkMarker"),e.exit("autolink"),t):p(h)}function p(h){if((h===45||qe(h))&&r++<63){const x=h===45?p:f;return e.consume(h),x}return n(h)}}const ma={partial:!0,tokenize:xb};function xb(e,t,n){return r;function r(s){return le(s)?ge(e,a,"linePrefix")(s):a(s)}function a(s){return s===null||ee(s)?t(s):n(s)}}const zc={continuation:{tokenize:_b},exit:Cb,name:"blockQuote",tokenize:yb};function yb(e,t,n){const r=this;return a;function a(i){if(i===62){const o=r.containerState;return o.open||(e.enter("blockQuote",{_container:!0}),o.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(i),e.exit("blockQuoteMarker"),s}return n(i)}function s(i){return le(i)?(e.enter("blockQuotePrefixWhitespace"),e.consume(i),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(i))}}function _b(e,t,n){const r=this;return a;function a(i){return le(i)?ge(e,s,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(i):s(i)}function s(i){return e.attempt(zc,t,n)(i)}}function Cb(e){e.exit("blockQuote")}const Yc={name:"characterEscape",tokenize:Ab};function Ab(e,t,n){return r;function r(s){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(s),e.exit("escapeMarker"),a}function a(s){return ub(s)?(e.enter("characterEscapeValue"),e.consume(s),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(s)}}const Wc={name:"characterReference",tokenize:Sb};function Sb(e,t,n){const r=this;let a=0,s,i;return o;function o(f){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(f),e.exit("characterReferenceMarker"),l}function l(f){return f===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(f),e.exit("characterReferenceMarkerNumeric"),c):(e.enter("characterReferenceValue"),s=31,i=qe,d(f))}function c(f){return f===88||f===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(f),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),s=6,i=ob,d):(e.enter("characterReferenceValue"),s=7,i=gs,d(f))}function d(f){if(f===59&&a){const p=e.exit("characterReferenceValue");return i===qe&&!oi(r.sliceSerialize(p))?n(f):(e.enter("characterReferenceMarker"),e.consume(f),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return i(f)&&a++<s?(e.consume(f),d):n(f)}}const ko={partial:!0,tokenize:Ib},Oo={concrete:!0,name:"codeFenced",tokenize:Nb};function Nb(e,t,n){const r=this,a={partial:!0,tokenize:L};let s=0,i=0,o;return l;function l(v){return c(v)}function c(v){const R=r.events[r.events.length-1];return s=R&&R[1].type==="linePrefix"?R[2].sliceSerialize(R[1],!0).length:0,o=v,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),d(v)}function d(v){return v===o?(i++,e.consume(v),d):i<3?n(v):(e.exit("codeFencedFenceSequence"),le(v)?ge(e,f,"whitespace")(v):f(v))}function f(v){return v===null||ee(v)?(e.exit("codeFencedFence"),r.interrupt?t(v):e.check(ko,g,k)(v)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),p(v))}function p(v){return v===null||ee(v)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),f(v)):le(v)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),ge(e,h,"whitespace")(v)):v===96&&v===o?n(v):(e.consume(v),p)}function h(v){return v===null||ee(v)?f(v):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),x(v))}function x(v){return v===null||ee(v)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),f(v)):v===96&&v===o?n(v):(e.consume(v),x)}function g(v){return e.attempt(a,k,A)(v)}function A(v){return e.enter("lineEnding"),e.consume(v),e.exit("lineEnding"),E}function E(v){return s>0&&le(v)?ge(e,_,"linePrefix",s+1)(v):_(v)}function _(v){return v===null||ee(v)?e.check(ko,g,k)(v):(e.enter("codeFlowValue"),N(v))}function N(v){return v===null||ee(v)?(e.exit("codeFlowValue"),_(v)):(e.consume(v),N)}function k(v){return e.exit("codeFenced"),t(v)}function L(v,R,P){let q=0;return K;function K(F){return v.enter("lineEnding"),v.consume(F),v.exit("lineEnding"),U}function U(F){return v.enter("codeFencedFence"),le(F)?ge(v,z,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(F):z(F)}function z(F){return F===o?(v.enter("codeFencedFenceSequence"),$(F)):P(F)}function $(F){return F===o?(q++,v.consume(F),$):q>=i?(v.exit("codeFencedFenceSequence"),le(F)?ge(v,Y,"whitespace")(F):Y(F)):P(F)}function Y(F){return F===null||ee(F)?(v.exit("codeFencedFence"),R(F)):P(F)}}}function Ib(e,t,n){const r=this;return a;function a(i){return i===null?n(i):(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),s)}function s(i){return r.parser.lazy[r.now().line]?n(i):t(i)}}const Fa={name:"codeIndented",tokenize:wb},vb={partial:!0,tokenize:kb};function wb(e,t,n){const r=this;return a;function a(c){return e.enter("codeIndented"),ge(e,s,"linePrefix",5)(c)}function s(c){const d=r.events[r.events.length-1];return d&&d[1].type==="linePrefix"&&d[2].sliceSerialize(d[1],!0).length>=4?i(c):n(c)}function i(c){return c===null?l(c):ee(c)?e.attempt(vb,i,l)(c):(e.enter("codeFlowValue"),o(c))}function o(c){return c===null||ee(c)?(e.exit("codeFlowValue"),i(c)):(e.consume(c),o)}function l(c){return e.exit("codeIndented"),t(c)}}function kb(e,t,n){const r=this;return a;function a(i){return r.parser.lazy[r.now().line]?n(i):ee(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),a):ge(e,s,"linePrefix",5)(i)}function s(i){const o=r.events[r.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(i):ee(i)?a(i):n(i)}}const Ob={name:"codeText",previous:Lb,resolve:Rb,tokenize:Pb};function Rb(e){let t=e.length-4,n=3,r,a;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)a===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(a=r):(r===t||e[r][1].type==="lineEnding")&&(e[a][1].type="codeTextData",r!==a+2&&(e[a][1].end=e[r-1][1].end,e.splice(a+2,r-a-2),t-=r-a-2,r=a+2),a=void 0);return e}function Lb(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function Pb(e,t,n){let r=0,a,s;return i;function i(f){return e.enter("codeText"),e.enter("codeTextSequence"),o(f)}function o(f){return f===96?(e.consume(f),r++,o):(e.exit("codeTextSequence"),l(f))}function l(f){return f===null?n(f):f===32?(e.enter("space"),e.consume(f),e.exit("space"),l):f===96?(s=e.enter("codeTextSequence"),a=0,d(f)):ee(f)?(e.enter("lineEnding"),e.consume(f),e.exit("lineEnding"),l):(e.enter("codeTextData"),c(f))}function c(f){return f===null||f===32||f===96||ee(f)?(e.exit("codeTextData"),l(f)):(e.consume(f),c)}function d(f){return f===96?(e.consume(f),a++,d):a===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(f)):(s.type="codeTextData",c(f))}}class Db{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const a=n||0;this.setCursor(Math.trunc(t));const s=this.right.splice(this.right.length-a,Number.POSITIVE_INFINITY);return r&&Hn(this.left,r),s.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),Hn(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),Hn(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);Hn(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);Hn(this.left,n.reverse())}}}function Hn(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Vc(e){const t={};let n=-1,r,a,s,i,o,l,c;const d=new Db(e);for(;++n<d.length;){for(;n in t;)n=t[n];if(r=d.get(n),n&&r[1].type==="chunkFlow"&&d.get(n-1)[1].type==="listItemPrefix"&&(l=r[1]._tokenizer.events,s=0,s<l.length&&l[s][1].type==="lineEndingBlank"&&(s+=2),s<l.length&&l[s][1].type==="content"))for(;++s<l.length&&l[s][1].type!=="content";)l[s][1].type==="chunkText"&&(l[s][1]._isInFirstContentOfListItem=!0,s++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,Mb(d,n)),n=t[n],c=!0);else if(r[1]._container){for(s=n,a=void 0;s--;)if(i=d.get(s),i[1].type==="lineEnding"||i[1].type==="lineEndingBlank")i[0]==="enter"&&(a&&(d.get(a)[1].type="lineEndingBlank"),i[1].type="lineEnding",a=s);else if(!(i[1].type==="linePrefix"||i[1].type==="listItemIndent"))break;a&&(r[1].end={...d.get(a)[1].start},o=d.slice(a,n),o.unshift(r),d.splice(a,n-a+1,o))}}return mt(e,0,Number.POSITIVE_INFINITY,d.slice(0)),!c}function Mb(e,t){const n=e.get(t)[1],r=e.get(t)[2];let a=t-1;const s=[];let i=n._tokenizer;i||(i=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(i._contentTypeTextTrailing=!0));const o=i.events,l=[],c={};let d,f,p=-1,h=n,x=0,g=0;const A=[g];for(;h;){for(;e.get(++a)[1]!==h;);s.push(a),h._tokenizer||(d=r.sliceStream(h),h.next||d.push(null),f&&i.defineSkip(h.start),h._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=!0),i.write(d),h._isInFirstContentOfListItem&&(i._gfmTasklistFirstContentOfListItem=void 0)),f=h,h=h.next}for(h=n;++p<o.length;)o[p][0]==="exit"&&o[p-1][0]==="enter"&&o[p][1].type===o[p-1][1].type&&o[p][1].start.line!==o[p][1].end.line&&(g=p+1,A.push(g),h._tokenizer=void 0,h.previous=void 0,h=h.next);for(i.events=[],h?(h._tokenizer=void 0,h.previous=void 0):A.pop(),p=A.length;p--;){const E=o.slice(A[p],A[p+1]),_=s.pop();l.push([_,_+E.length-1]),e.splice(_,2,E)}for(l.reverse(),p=-1;++p<l.length;)c[x+l[p][0]]=x+l[p][1],x+=l[p][1]-l[p][0]-1;return c}const Bb={resolve:Hb,tokenize:Ub},Fb={partial:!0,tokenize:jb};function Hb(e){return Vc(e),e}function Ub(e,t){let n;return r;function r(o){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),a(o)}function a(o){return o===null?s(o):ee(o)?e.check(Fb,i,s)(o):(e.consume(o),a)}function s(o){return e.exit("chunkContent"),e.exit("content"),t(o)}function i(o){return e.consume(o),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,a}}function jb(e,t,n){const r=this;return a;function a(i){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),ge(e,s,"linePrefix")}function s(i){if(i===null||ee(i))return n(i);const o=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(i):e.interrupt(r.parser.constructs.flow,n,t)(i)}}function $c(e,t,n,r,a,s,i,o,l){const c=l||Number.POSITIVE_INFINITY;let d=0;return f;function f(E){return E===60?(e.enter(r),e.enter(a),e.enter(s),e.consume(E),e.exit(s),p):E===null||E===32||E===41||ps(E)?n(E):(e.enter(r),e.enter(i),e.enter(o),e.enter("chunkString",{contentType:"string"}),g(E))}function p(E){return E===62?(e.enter(s),e.consume(E),e.exit(s),e.exit(a),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),h(E))}function h(E){return E===62?(e.exit("chunkString"),e.exit(o),p(E)):E===null||E===60||ee(E)?n(E):(e.consume(E),E===92?x:h)}function x(E){return E===60||E===62||E===92?(e.consume(E),h):h(E)}function g(E){return!d&&(E===null||E===41||He(E))?(e.exit("chunkString"),e.exit(o),e.exit(i),e.exit(r),t(E)):d<c&&E===40?(e.consume(E),d++,g):E===41?(e.consume(E),d--,g):E===null||E===32||E===40||ps(E)?n(E):(e.consume(E),E===92?A:g)}function A(E){return E===40||E===41||E===92?(e.consume(E),g):g(E)}}function qc(e,t,n,r,a,s){const i=this;let o=0,l;return c;function c(h){return e.enter(r),e.enter(a),e.consume(h),e.exit(a),e.enter(s),d}function d(h){return o>999||h===null||h===91||h===93&&!l||h===94&&!o&&"_hiddenFootnoteSupport"in i.parser.constructs?n(h):h===93?(e.exit(s),e.enter(a),e.consume(h),e.exit(a),e.exit(r),t):ee(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),d):(e.enter("chunkString",{contentType:"string"}),f(h))}function f(h){return h===null||h===91||h===93||ee(h)||o++>999?(e.exit("chunkString"),d(h)):(e.consume(h),l||(l=!le(h)),h===92?p:f)}function p(h){return h===91||h===92||h===93?(e.consume(h),o++,f):f(h)}}function Gc(e,t,n,r,a,s){let i;return o;function o(p){return p===34||p===39||p===40?(e.enter(r),e.enter(a),e.consume(p),e.exit(a),i=p===40?41:p,l):n(p)}function l(p){return p===i?(e.enter(a),e.consume(p),e.exit(a),e.exit(r),t):(e.enter(s),c(p))}function c(p){return p===i?(e.exit(s),l(i)):p===null?n(p):ee(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),ge(e,c,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===i||p===null||ee(p)?(e.exit("chunkString"),c(p)):(e.consume(p),p===92?f:d)}function f(p){return p===i||p===92?(e.consume(p),d):d(p)}}function Gn(e,t){let n;return r;function r(a){return ee(a)?(e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),n=!0,r):le(a)?ge(e,r,n?"linePrefix":"lineSuffix")(a):t(a)}}const zb={name:"definition",tokenize:Wb},Yb={partial:!0,tokenize:Vb};function Wb(e,t,n){const r=this;let a;return s;function s(h){return e.enter("definition"),i(h)}function i(h){return qc.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(h)}function o(h){return a=fn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),h===58?(e.enter("definitionMarker"),e.consume(h),e.exit("definitionMarker"),l):n(h)}function l(h){return He(h)?Gn(e,c)(h):c(h)}function c(h){return $c(e,d,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(h)}function d(h){return e.attempt(Yb,f,f)(h)}function f(h){return le(h)?ge(e,p,"whitespace")(h):p(h)}function p(h){return h===null||ee(h)?(e.exit("definition"),r.parser.defined.push(a),t(h)):n(h)}}function Vb(e,t,n){return r;function r(o){return He(o)?Gn(e,a)(o):n(o)}function a(o){return Gc(e,s,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function s(o){return le(o)?ge(e,i,"whitespace")(o):i(o)}function i(o){return o===null||ee(o)?t(o):n(o)}}const $b={name:"hardBreakEscape",tokenize:qb};function qb(e,t,n){return r;function r(s){return e.enter("hardBreakEscape"),e.consume(s),a}function a(s){return ee(s)?(e.exit("hardBreakEscape"),t(s)):n(s)}}const Gb={name:"headingAtx",resolve:Xb,tokenize:Kb};function Xb(e,t){let n=e.length-2,r=3,a,s;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(a={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},s={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},mt(e,r,n-r+1,[["enter",a,t],["enter",s,t],["exit",s,t],["exit",a,t]])),e}function Kb(e,t,n){let r=0;return a;function a(d){return e.enter("atxHeading"),s(d)}function s(d){return e.enter("atxHeadingSequence"),i(d)}function i(d){return d===35&&r++<6?(e.consume(d),i):d===null||He(d)?(e.exit("atxHeadingSequence"),o(d)):n(d)}function o(d){return d===35?(e.enter("atxHeadingSequence"),l(d)):d===null||ee(d)?(e.exit("atxHeading"),t(d)):le(d)?ge(e,o,"whitespace")(d):(e.enter("atxHeadingText"),c(d))}function l(d){return d===35?(e.consume(d),l):(e.exit("atxHeadingSequence"),o(d))}function c(d){return d===null||d===35||He(d)?(e.exit("atxHeadingText"),o(d)):(e.consume(d),c)}}const Qb=["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],Ro=["pre","script","style","textarea"],Zb={concrete:!0,name:"htmlFlow",resolveTo:tE,tokenize:nE},Jb={partial:!0,tokenize:aE},eE={partial:!0,tokenize:rE};function tE(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function nE(e,t,n){const r=this;let a,s,i,o,l;return c;function c(I){return d(I)}function d(I){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(I),f}function f(I){return I===33?(e.consume(I),p):I===47?(e.consume(I),s=!0,g):I===63?(e.consume(I),a=3,r.interrupt?t:S):ct(I)?(e.consume(I),i=String.fromCharCode(I),A):n(I)}function p(I){return I===45?(e.consume(I),a=2,h):I===91?(e.consume(I),a=5,o=0,x):ct(I)?(e.consume(I),a=4,r.interrupt?t:S):n(I)}function h(I){return I===45?(e.consume(I),r.interrupt?t:S):n(I)}function x(I){const fe="CDATA[";return I===fe.charCodeAt(o++)?(e.consume(I),o===fe.length?r.interrupt?t:z:x):n(I)}function g(I){return ct(I)?(e.consume(I),i=String.fromCharCode(I),A):n(I)}function A(I){if(I===null||I===47||I===62||He(I)){const fe=I===47,De=i.toLowerCase();return!fe&&!s&&Ro.includes(De)?(a=1,r.interrupt?t(I):z(I)):Qb.includes(i.toLowerCase())?(a=6,fe?(e.consume(I),E):r.interrupt?t(I):z(I)):(a=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(I):s?_(I):N(I))}return I===45||qe(I)?(e.consume(I),i+=String.fromCharCode(I),A):n(I)}function E(I){return I===62?(e.consume(I),r.interrupt?t:z):n(I)}function _(I){return le(I)?(e.consume(I),_):K(I)}function N(I){return I===47?(e.consume(I),K):I===58||I===95||ct(I)?(e.consume(I),k):le(I)?(e.consume(I),N):K(I)}function k(I){return I===45||I===46||I===58||I===95||qe(I)?(e.consume(I),k):L(I)}function L(I){return I===61?(e.consume(I),v):le(I)?(e.consume(I),L):N(I)}function v(I){return I===null||I===60||I===61||I===62||I===96?n(I):I===34||I===39?(e.consume(I),l=I,R):le(I)?(e.consume(I),v):P(I)}function R(I){return I===l?(e.consume(I),l=null,q):I===null||ee(I)?n(I):(e.consume(I),R)}function P(I){return I===null||I===34||I===39||I===47||I===60||I===61||I===62||I===96||He(I)?L(I):(e.consume(I),P)}function q(I){return I===47||I===62||le(I)?N(I):n(I)}function K(I){return I===62?(e.consume(I),U):n(I)}function U(I){return I===null||ee(I)?z(I):le(I)?(e.consume(I),U):n(I)}function z(I){return I===45&&a===2?(e.consume(I),X):I===60&&a===1?(e.consume(I),Q):I===62&&a===4?(e.consume(I),xe):I===63&&a===3?(e.consume(I),S):I===93&&a===5?(e.consume(I),ie):ee(I)&&(a===6||a===7)?(e.exit("htmlFlowData"),e.check(Jb,we,$)(I)):I===null||ee(I)?(e.exit("htmlFlowData"),$(I)):(e.consume(I),z)}function $(I){return e.check(eE,Y,we)(I)}function Y(I){return e.enter("lineEnding"),e.consume(I),e.exit("lineEnding"),F}function F(I){return I===null||ee(I)?$(I):(e.enter("htmlFlowData"),z(I))}function X(I){return I===45?(e.consume(I),S):z(I)}function Q(I){return I===47?(e.consume(I),i="",B):z(I)}function B(I){if(I===62){const fe=i.toLowerCase();return Ro.includes(fe)?(e.consume(I),xe):z(I)}return ct(I)&&i.length<8?(e.consume(I),i+=String.fromCharCode(I),B):z(I)}function ie(I){return I===93?(e.consume(I),S):z(I)}function S(I){return I===62?(e.consume(I),xe):I===45&&a===2?(e.consume(I),S):z(I)}function xe(I){return I===null||ee(I)?(e.exit("htmlFlowData"),we(I)):(e.consume(I),xe)}function we(I){return e.exit("htmlFlow"),t(I)}}function rE(e,t,n){const r=this;return a;function a(i){return ee(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),s):n(i)}function s(i){return r.parser.lazy[r.now().line]?n(i):t(i)}}function aE(e,t,n){return r;function r(a){return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),e.attempt(ma,t,n)}}const sE={name:"htmlText",tokenize:iE};function iE(e,t,n){const r=this;let a,s,i;return o;function o(S){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(S),l}function l(S){return S===33?(e.consume(S),c):S===47?(e.consume(S),L):S===63?(e.consume(S),N):ct(S)?(e.consume(S),P):n(S)}function c(S){return S===45?(e.consume(S),d):S===91?(e.consume(S),s=0,x):ct(S)?(e.consume(S),_):n(S)}function d(S){return S===45?(e.consume(S),h):n(S)}function f(S){return S===null?n(S):S===45?(e.consume(S),p):ee(S)?(i=f,Q(S)):(e.consume(S),f)}function p(S){return S===45?(e.consume(S),h):f(S)}function h(S){return S===62?X(S):S===45?p(S):f(S)}function x(S){const xe="CDATA[";return S===xe.charCodeAt(s++)?(e.consume(S),s===xe.length?g:x):n(S)}function g(S){return S===null?n(S):S===93?(e.consume(S),A):ee(S)?(i=g,Q(S)):(e.consume(S),g)}function A(S){return S===93?(e.consume(S),E):g(S)}function E(S){return S===62?X(S):S===93?(e.consume(S),E):g(S)}function _(S){return S===null||S===62?X(S):ee(S)?(i=_,Q(S)):(e.consume(S),_)}function N(S){return S===null?n(S):S===63?(e.consume(S),k):ee(S)?(i=N,Q(S)):(e.consume(S),N)}function k(S){return S===62?X(S):N(S)}function L(S){return ct(S)?(e.consume(S),v):n(S)}function v(S){return S===45||qe(S)?(e.consume(S),v):R(S)}function R(S){return ee(S)?(i=R,Q(S)):le(S)?(e.consume(S),R):X(S)}function P(S){return S===45||qe(S)?(e.consume(S),P):S===47||S===62||He(S)?q(S):n(S)}function q(S){return S===47?(e.consume(S),X):S===58||S===95||ct(S)?(e.consume(S),K):ee(S)?(i=q,Q(S)):le(S)?(e.consume(S),q):X(S)}function K(S){return S===45||S===46||S===58||S===95||qe(S)?(e.consume(S),K):U(S)}function U(S){return S===61?(e.consume(S),z):ee(S)?(i=U,Q(S)):le(S)?(e.consume(S),U):q(S)}function z(S){return S===null||S===60||S===61||S===62||S===96?n(S):S===34||S===39?(e.consume(S),a=S,$):ee(S)?(i=z,Q(S)):le(S)?(e.consume(S),z):(e.consume(S),Y)}function $(S){return S===a?(e.consume(S),a=void 0,F):S===null?n(S):ee(S)?(i=$,Q(S)):(e.consume(S),$)}function Y(S){return S===null||S===34||S===39||S===60||S===61||S===96?n(S):S===47||S===62||He(S)?q(S):(e.consume(S),Y)}function F(S){return S===47||S===62||He(S)?q(S):n(S)}function X(S){return S===62?(e.consume(S),e.exit("htmlTextData"),e.exit("htmlText"),t):n(S)}function Q(S){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(S),e.exit("lineEnding"),B}function B(S){return le(S)?ge(e,ie,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(S):ie(S)}function ie(S){return e.enter("htmlTextData"),i(S)}}const li={name:"labelEnd",resolveAll:cE,resolveTo:dE,tokenize:fE},oE={tokenize:hE},uE={tokenize:mE},lE={tokenize:pE};function cE(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const a=r.type==="labelImage"?4:2;r.type="data",t+=a}}return e.length!==n.length&&mt(e,0,e.length,n),e}function dE(e,t){let n=e.length,r=0,a,s,i,o;for(;n--;)if(a=e[n][1],s){if(a.type==="link"||a.type==="labelLink"&&a._inactive)break;e[n][0]==="enter"&&a.type==="labelLink"&&(a._inactive=!0)}else if(i){if(e[n][0]==="enter"&&(a.type==="labelImage"||a.type==="labelLink")&&!a._balanced&&(s=n,a.type!=="labelLink")){r=2;break}}else a.type==="labelEnd"&&(i=n);const l={type:e[s][1].type==="labelLink"?"link":"image",start:{...e[s][1].start},end:{...e[e.length-1][1].end}},c={type:"label",start:{...e[s][1].start},end:{...e[i][1].end}},d={type:"labelText",start:{...e[s+r+2][1].end},end:{...e[i-2][1].start}};return o=[["enter",l,t],["enter",c,t]],o=Ke(o,e.slice(s+1,s+r+3)),o=Ke(o,[["enter",d,t]]),o=Ke(o,ui(t.parser.constructs.insideSpan.null,e.slice(s+r+4,i-3),t)),o=Ke(o,[["exit",d,t],e[i-2],e[i-1],["exit",c,t]]),o=Ke(o,e.slice(i+1)),o=Ke(o,[["exit",l,t]]),mt(e,s,e.length,o),e}function fE(e,t,n){const r=this;let a=r.events.length,s,i;for(;a--;)if((r.events[a][1].type==="labelImage"||r.events[a][1].type==="labelLink")&&!r.events[a][1]._balanced){s=r.events[a][1];break}return o;function o(p){return s?s._inactive?f(p):(i=r.parser.defined.includes(fn(r.sliceSerialize({start:s.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(p),e.exit("labelMarker"),e.exit("labelEnd"),l):n(p)}function l(p){return p===40?e.attempt(oE,d,i?d:f)(p):p===91?e.attempt(uE,d,i?c:f)(p):i?d(p):f(p)}function c(p){return e.attempt(lE,d,f)(p)}function d(p){return t(p)}function f(p){return s._balanced=!0,n(p)}}function hE(e,t,n){return r;function r(f){return e.enter("resource"),e.enter("resourceMarker"),e.consume(f),e.exit("resourceMarker"),a}function a(f){return He(f)?Gn(e,s)(f):s(f)}function s(f){return f===41?d(f):$c(e,i,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(f)}function i(f){return He(f)?Gn(e,l)(f):d(f)}function o(f){return n(f)}function l(f){return f===34||f===39||f===40?Gc(e,c,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(f):d(f)}function c(f){return He(f)?Gn(e,d)(f):d(f)}function d(f){return f===41?(e.enter("resourceMarker"),e.consume(f),e.exit("resourceMarker"),e.exit("resource"),t):n(f)}}function mE(e,t,n){const r=this;return a;function a(o){return qc.call(r,e,s,i,"reference","referenceMarker","referenceString")(o)}function s(o){return r.parser.defined.includes(fn(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function i(o){return n(o)}}function pE(e,t,n){return r;function r(s){return e.enter("reference"),e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),a}function a(s){return s===93?(e.enter("referenceMarker"),e.consume(s),e.exit("referenceMarker"),e.exit("reference"),t):n(s)}}const gE={name:"labelStartImage",resolveAll:li.resolveAll,tokenize:bE};function bE(e,t,n){const r=this;return a;function a(o){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(o),e.exit("labelImageMarker"),s}function s(o){return o===91?(e.enter("labelMarker"),e.consume(o),e.exit("labelMarker"),e.exit("labelImage"),i):n(o)}function i(o){return o===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(o):t(o)}}const EE={name:"labelStartLink",resolveAll:li.resolveAll,tokenize:TE};function TE(e,t,n){const r=this;return a;function a(i){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(i),e.exit("labelMarker"),e.exit("labelLink"),s}function s(i){return i===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(i):t(i)}}const Ha={name:"lineEnding",tokenize:xE};function xE(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),ge(e,t,"linePrefix")}}const Dr={name:"thematicBreak",tokenize:yE};function yE(e,t,n){let r=0,a;return s;function s(c){return e.enter("thematicBreak"),i(c)}function i(c){return a=c,o(c)}function o(c){return c===a?(e.enter("thematicBreakSequence"),l(c)):r>=3&&(c===null||ee(c))?(e.exit("thematicBreak"),t(c)):n(c)}function l(c){return c===a?(e.consume(c),r++,l):(e.exit("thematicBreakSequence"),le(c)?ge(e,o,"whitespace")(c):o(c))}}const Fe={continuation:{tokenize:SE},exit:IE,name:"list",tokenize:AE},_E={partial:!0,tokenize:vE},CE={partial:!0,tokenize:NE};function AE(e,t,n){const r=this,a=r.events[r.events.length-1];let s=a&&a[1].type==="linePrefix"?a[2].sliceSerialize(a[1],!0).length:0,i=0;return o;function o(h){const x=r.containerState.type||(h===42||h===43||h===45?"listUnordered":"listOrdered");if(x==="listUnordered"?!r.containerState.marker||h===r.containerState.marker:gs(h)){if(r.containerState.type||(r.containerState.type=x,e.enter(x,{_container:!0})),x==="listUnordered")return e.enter("listItemPrefix"),h===42||h===45?e.check(Dr,n,c)(h):c(h);if(!r.interrupt||h===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),l(h)}return n(h)}function l(h){return gs(h)&&++i<10?(e.consume(h),l):(!r.interrupt||i<2)&&(r.containerState.marker?h===r.containerState.marker:h===41||h===46)?(e.exit("listItemValue"),c(h)):n(h)}function c(h){return e.enter("listItemMarker"),e.consume(h),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||h,e.check(ma,r.interrupt?n:d,e.attempt(_E,p,f))}function d(h){return r.containerState.initialBlankLine=!0,s++,p(h)}function f(h){return le(h)?(e.enter("listItemPrefixWhitespace"),e.consume(h),e.exit("listItemPrefixWhitespace"),p):n(h)}function p(h){return r.containerState.size=s+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(h)}}function SE(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(ma,a,s);function a(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,ge(e,t,"listItemIndent",r.containerState.size+1)(o)}function s(o){return r.containerState.furtherBlankLines||!le(o)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,i(o)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(CE,t,i)(o))}function i(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,ge(e,e.attempt(Fe,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function NE(e,t,n){const r=this;return ge(e,a,"listItemIndent",r.containerState.size+1);function a(s){const i=r.events[r.events.length-1];return i&&i[1].type==="listItemIndent"&&i[2].sliceSerialize(i[1],!0).length===r.containerState.size?t(s):n(s)}}function IE(e){e.exit(this.containerState.type)}function vE(e,t,n){const r=this;return ge(e,a,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:5);function a(s){const i=r.events[r.events.length-1];return!le(s)&&i&&i[1].type==="listItemPrefixWhitespace"?t(s):n(s)}}const Lo={name:"setextUnderline",resolveTo:wE,tokenize:kE};function wE(e,t){let n=e.length,r,a,s;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(a=n)}else e[n][1].type==="content"&&e.splice(n,1),!s&&e[n][1].type==="definition"&&(s=n);const i={type:"setextHeading",start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[a][1].type="setextHeadingText",s?(e.splice(a,0,["enter",i,t]),e.splice(s+1,0,["exit",e[r][1],t]),e[r][1].end={...e[s][1].end}):e[r][1]=i,e.push(["exit",i,t]),e}function kE(e,t,n){const r=this;let a;return s;function s(c){let d=r.events.length,f;for(;d--;)if(r.events[d][1].type!=="lineEnding"&&r.events[d][1].type!=="linePrefix"&&r.events[d][1].type!=="content"){f=r.events[d][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||f)?(e.enter("setextHeadingLine"),a=c,i(c)):n(c)}function i(c){return e.enter("setextHeadingLineSequence"),o(c)}function o(c){return c===a?(e.consume(c),o):(e.exit("setextHeadingLineSequence"),le(c)?ge(e,l,"lineSuffix")(c):l(c))}function l(c){return c===null||ee(c)?(e.exit("setextHeadingLine"),t(c)):n(c)}}const OE={tokenize:RE};function RE(e){const t=this,n=e.attempt(ma,r,e.attempt(this.parser.constructs.flowInitial,a,ge(e,e.attempt(this.parser.constructs.flow,a,e.attempt(Bb,a)),"linePrefix")));return n;function r(s){if(s===null){e.consume(s);return}return e.enter("lineEndingBlank"),e.consume(s),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function a(s){if(s===null){e.consume(s);return}return e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const LE={resolveAll:Kc()},PE=Xc("string"),DE=Xc("text");function Xc(e){return{resolveAll:Kc(e==="text"?ME:void 0),tokenize:t};function t(n){const r=this,a=this.parser.constructs[e],s=n.attempt(a,i,o);return i;function i(d){return c(d)?s(d):o(d)}function o(d){if(d===null){n.consume(d);return}return n.enter("data"),n.consume(d),l}function l(d){return c(d)?(n.exit("data"),s(d)):(n.consume(d),l)}function c(d){if(d===null)return!0;const f=a[d];let p=-1;if(f)for(;++p<f.length;){const h=f[p];if(!h.previous||h.previous.call(r,r.previous))return!0}return!1}}}function Kc(e){return t;function t(n,r){let a=-1,s;for(;++a<=n.length;)s===void 0?n[a]&&n[a][1].type==="data"&&(s=a,a++):(!n[a]||n[a][1].type!=="data")&&(a!==s+2&&(n[s][1].end=n[a-1][1].end,n.splice(s+2,a-s-2),a=s+2),s=void 0);return e?e(n,r):n}}function ME(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],a=t.sliceStream(r);let s=a.length,i=-1,o=0,l;for(;s--;){const c=a[s];if(typeof c=="string"){for(i=c.length;c.charCodeAt(i-1)===32;)o++,i--;if(i)break;i=-1}else if(c===-2)l=!0,o++;else if(c!==-1){s++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const c={type:n===e.length||l||o<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:s?i:r.start._bufferIndex+i,_index:r.start._index+s,line:r.end.line,column:r.end.column-o,offset:r.end.offset-o},end:{...r.end}};r.end={...c.start},r.start.offset===r.end.offset?Object.assign(r,c):(e.splice(n,0,["enter",c,t],["exit",c,t]),n+=2)}n++}return e}const BE={42:Fe,43:Fe,45:Fe,48:Fe,49:Fe,50:Fe,51:Fe,52:Fe,53:Fe,54:Fe,55:Fe,56:Fe,57:Fe,62:zc},FE={91:zb},HE={[-2]:Fa,[-1]:Fa,32:Fa},UE={35:Gb,42:Dr,45:[Lo,Dr],60:Zb,61:Lo,95:Dr,96:Oo,126:Oo},jE={38:Wc,92:Yc},zE={[-5]:Ha,[-4]:Ha,[-3]:Ha,33:gE,38:Wc,42:bs,60:[Eb,sE],91:EE,92:[$b,Yc],93:li,95:bs,96:Ob},YE={null:[bs,LE]},WE={null:[42,95]},VE={null:[]},$E=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:WE,contentInitial:FE,disable:VE,document:BE,flow:UE,flowInitial:HE,insideSpan:YE,string:jE,text:zE},Symbol.toStringTag,{value:"Module"}));function qE(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const a={},s=[];let i=[],o=[];const l={attempt:R(L),check:R(v),consume:_,enter:N,exit:k,interrupt:R(v,{interrupt:!0})},c={code:null,containerState:{},defineSkip:g,events:[],now:x,parser:e,previous:null,sliceSerialize:p,sliceStream:h,write:f};let d=t.tokenize.call(c,l);return t.resolveAll&&s.push(t),c;function f(U){return i=Ke(i,U),A(),i[i.length-1]!==null?[]:(P(t,0),c.events=ui(s,c.events,c),c.events)}function p(U,z){return XE(h(U),z)}function h(U){return GE(i,U)}function x(){const{_bufferIndex:U,_index:z,line:$,column:Y,offset:F}=r;return{_bufferIndex:U,_index:z,line:$,column:Y,offset:F}}function g(U){a[U.line]=U.column,K()}function A(){let U;for(;r._index<i.length;){const z=i[r._index];if(typeof z=="string")for(U=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===U&&r._bufferIndex<z.length;)E(z.charCodeAt(r._bufferIndex));else E(z)}}function E(U){d=d(U)}function _(U){ee(U)?(r.line++,r.column=1,r.offset+=U===-3?2:1,K()):U!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===i[r._index].length&&(r._bufferIndex=-1,r._index++)),c.previous=U}function N(U,z){const $=z||{};return $.type=U,$.start=x(),c.events.push(["enter",$,c]),o.push($),$}function k(U){const z=o.pop();return z.end=x(),c.events.push(["exit",z,c]),z}function L(U,z){P(U,z.from)}function v(U,z){z.restore()}function R(U,z){return $;function $(Y,F,X){let Q,B,ie,S;return Array.isArray(Y)?we(Y):"tokenize"in Y?we([Y]):xe(Y);function xe(Ee){return ce;function ce(Me){const je=Me!==null&&Ee[Me],ze=Me!==null&&Ee.null,it=[...Array.isArray(je)?je:je?[je]:[],...Array.isArray(ze)?ze:ze?[ze]:[]];return we(it)(Me)}}function we(Ee){return Q=Ee,B=0,Ee.length===0?X:I(Ee[B])}function I(Ee){return ce;function ce(Me){return S=q(),ie=Ee,Ee.partial||(c.currentConstruct=Ee),Ee.name&&c.parser.constructs.disable.null.includes(Ee.name)?De():Ee.tokenize.call(z?Object.assign(Object.create(c),z):c,l,fe,De)(Me)}}function fe(Ee){return U(ie,S),F}function De(Ee){return S.restore(),++B<Q.length?I(Q[B]):X}}}function P(U,z){U.resolveAll&&!s.includes(U)&&s.push(U),U.resolve&&mt(c.events,z,c.events.length-z,U.resolve(c.events.slice(z),c)),U.resolveTo&&(c.events=U.resolveTo(c.events,c))}function q(){const U=x(),z=c.previous,$=c.currentConstruct,Y=c.events.length,F=Array.from(o);return{from:Y,restore:X};function X(){r=U,c.previous=z,c.currentConstruct=$,c.events.length=Y,o=F,K()}}function K(){r.line in a&&r.column<2&&(r.column=a[r.line],r.offset+=a[r.line]-1)}}function GE(e,t){const n=t.start._index,r=t.start._bufferIndex,a=t.end._index,s=t.end._bufferIndex;let i;if(n===a)i=[e[n].slice(r,s)];else{if(i=e.slice(n,a),r>-1){const o=i[0];typeof o=="string"?i[0]=o.slice(r):i.shift()}s>0&&i.push(e[a].slice(0,s))}return i}function XE(e,t){let n=-1;const r=[];let a;for(;++n<e.length;){const s=e[n];let i;if(typeof s=="string")i=s;else switch(s){case-5:{i="\r";break}case-4:{i=`
63
+ `;break}case-3:{i=`\r
64
+ `;break}case-2:{i=t?" ":" ";break}case-1:{if(!t&&a)continue;i=" ";break}default:i=String.fromCharCode(s)}a=s===-2,r.push(i)}return r.join("")}function KE(e){const r={constructs:rb([$E,...(e||{}).extensions||[]]),content:a(db),defined:[],document:a(hb),flow:a(OE),lazy:{},string:a(PE),text:a(DE)};return r;function a(s){return i;function i(o){return qE(r,s,o)}}}function QE(e){for(;!Vc(e););return e}const Po=/[\0\t\n\r]/g;function ZE(){let e=1,t="",n=!0,r;return a;function a(s,i,o){const l=[];let c,d,f,p,h;for(s=t+(typeof s=="string"?s.toString():new TextDecoder(i||void 0).decode(s)),f=0,t="",n&&(s.charCodeAt(0)===65279&&f++,n=void 0);f<s.length;){if(Po.lastIndex=f,c=Po.exec(s),p=c&&c.index!==void 0?c.index:s.length,h=s.charCodeAt(p),!c){t=s.slice(f);break}if(h===10&&f===p&&r)l.push(-3),r=void 0;else switch(r&&(l.push(-5),r=void 0),f<p&&(l.push(s.slice(f,p)),e+=p-f),h){case 0:{l.push(65533),e++;break}case 9:{for(d=Math.ceil(e/4)*4,l.push(-2);e++<d;)l.push(-1);break}case 10:{l.push(-4),e=1;break}default:r=!0,e=1}f=p+1}return o&&(r&&l.push(-5),t&&l.push(t),l.push(null)),l}}const JE=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function eT(e){return e.replace(JE,tT)}function tT(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const a=n.charCodeAt(1),s=a===120||a===88;return jc(n.slice(s?2:1),s?16:10)}return oi(n)||e}const Qc={}.hasOwnProperty;function nT(e,t,n){return typeof t!="string"&&(n=t,t=void 0),rT(n)(QE(KE(n).document().write(ZE()(e,t,!0))))}function rT(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:s(Ii),autolinkProtocol:q,autolinkEmail:q,atxHeading:s(Ai),blockQuote:s(ze),characterEscape:q,characterReference:q,codeFenced:s(it),codeFencedFenceInfo:i,codeFencedFenceMeta:i,codeIndented:s(it,i),codeText:s(St,i),codeTextData:q,data:q,codeFlowValue:q,definition:s(Qt),definitionDestinationString:i,definitionLabelString:i,definitionTitleString:i,emphasis:s(yf),hardBreakEscape:s(Si),hardBreakTrailing:s(Si),htmlFlow:s(Ni,i),htmlFlowData:q,htmlText:s(Ni,i),htmlTextData:q,image:s(_f),label:i,link:s(Ii),listItem:s(Cf),listItemValue:p,listOrdered:s(vi,f),listUnordered:s(vi),paragraph:s(Af),reference:I,referenceString:i,resourceDestinationString:i,resourceTitleString:i,setextHeading:s(Ai),strong:s(Sf),thematicBreak:s(If)},exit:{atxHeading:l(),atxHeadingSequence:L,autolink:l(),autolinkEmail:je,autolinkProtocol:Me,blockQuote:l(),characterEscapeValue:K,characterReferenceMarkerHexadecimal:De,characterReferenceMarkerNumeric:De,characterReferenceValue:Ee,characterReference:ce,codeFenced:l(A),codeFencedFence:g,codeFencedFenceInfo:h,codeFencedFenceMeta:x,codeFlowValue:K,codeIndented:l(E),codeText:l(F),codeTextData:K,data:K,definition:l(),definitionDestinationString:k,definitionLabelString:_,definitionTitleString:N,emphasis:l(),hardBreakEscape:l(z),hardBreakTrailing:l(z),htmlFlow:l($),htmlFlowData:K,htmlText:l(Y),htmlTextData:K,image:l(Q),label:ie,labelText:B,lineEnding:U,link:l(X),listItem:l(),listOrdered:l(),listUnordered:l(),paragraph:l(),referenceString:fe,resourceDestinationString:S,resourceTitleString:xe,resource:we,setextHeading:l(P),setextHeadingLineSequence:R,setextHeadingText:v,strong:l(),thematicBreak:l()}};Zc(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(M){let G={type:"root",children:[]};const te={stack:[G],tokenStack:[],config:t,enter:o,exit:c,buffer:i,resume:d,data:n},ue=[];let he=-1;for(;++he<M.length;)if(M[he][1].type==="listOrdered"||M[he][1].type==="listUnordered")if(M[he][0]==="enter")ue.push(he);else{const et=ue.pop();he=a(M,et,he)}for(he=-1;++he<M.length;){const et=t[M[he][0]];Qc.call(et,M[he][1].type)&&et[M[he][1].type].call(Object.assign({sliceSerialize:M[he][2].sliceSerialize},te),M[he][1])}if(te.tokenStack.length>0){const et=te.tokenStack[te.tokenStack.length-1];(et[1]||Do).call(te,void 0,et[0])}for(G.position={start:It(M.length>0?M[0][1].start:{line:1,column:1,offset:0}),end:It(M.length>0?M[M.length-2][1].end:{line:1,column:1,offset:0})},he=-1;++he<t.transforms.length;)G=t.transforms[he](G)||G;return G}function a(M,G,te){let ue=G-1,he=-1,et=!1,Bt,bt,Pn,Dn;for(;++ue<=te;){const Ye=M[ue];switch(Ye[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{Ye[0]==="enter"?he++:he--,Dn=void 0;break}case"lineEndingBlank":{Ye[0]==="enter"&&(Bt&&!Dn&&!he&&!Pn&&(Pn=ue),Dn=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Dn=void 0}if(!he&&Ye[0]==="enter"&&Ye[1].type==="listItemPrefix"||he===-1&&Ye[0]==="exit"&&(Ye[1].type==="listUnordered"||Ye[1].type==="listOrdered")){if(Bt){let Zt=ue;for(bt=void 0;Zt--;){const Et=M[Zt];if(Et[1].type==="lineEnding"||Et[1].type==="lineEndingBlank"){if(Et[0]==="exit")continue;bt&&(M[bt][1].type="lineEndingBlank",et=!0),Et[1].type="lineEnding",bt=Zt}else if(!(Et[1].type==="linePrefix"||Et[1].type==="blockQuotePrefix"||Et[1].type==="blockQuotePrefixWhitespace"||Et[1].type==="blockQuoteMarker"||Et[1].type==="listItemIndent"))break}Pn&&(!bt||Pn<bt)&&(Bt._spread=!0),Bt.end=Object.assign({},bt?M[bt][1].start:Ye[1].end),M.splice(bt||ue,0,["exit",Bt,Ye[2]]),ue++,te++}if(Ye[1].type==="listItemPrefix"){const Zt={type:"listItem",_spread:!1,start:Object.assign({},Ye[1].start),end:void 0};Bt=Zt,M.splice(ue,0,["enter",Zt,Ye[2]]),ue++,te++,Pn=void 0,Dn=!0}}}return M[G][1]._spread=et,te}function s(M,G){return te;function te(ue){o.call(this,M(ue),ue),G&&G.call(this,ue)}}function i(){this.stack.push({type:"fragment",children:[]})}function o(M,G,te){this.stack[this.stack.length-1].children.push(M),this.stack.push(M),this.tokenStack.push([G,te||void 0]),M.position={start:It(G.start),end:void 0}}function l(M){return G;function G(te){M&&M.call(this,te),c.call(this,te)}}function c(M,G){const te=this.stack.pop(),ue=this.tokenStack.pop();if(ue)ue[0].type!==M.type&&(G?G.call(this,M,ue[0]):(ue[1]||Do).call(this,M,ue[0]));else throw new Error("Cannot close `"+M.type+"` ("+qn({start:M.start,end:M.end})+"): it’s not open");te.position.end=It(M.end)}function d(){return tb(this.stack.pop())}function f(){this.data.expectingFirstListItemValue=!0}function p(M){if(this.data.expectingFirstListItemValue){const G=this.stack[this.stack.length-2];G.start=Number.parseInt(this.sliceSerialize(M),10),this.data.expectingFirstListItemValue=void 0}}function h(){const M=this.resume(),G=this.stack[this.stack.length-1];G.lang=M}function x(){const M=this.resume(),G=this.stack[this.stack.length-1];G.meta=M}function g(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function A(){const M=this.resume(),G=this.stack[this.stack.length-1];G.value=M.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function E(){const M=this.resume(),G=this.stack[this.stack.length-1];G.value=M.replace(/(\r?\n|\r)$/g,"")}function _(M){const G=this.resume(),te=this.stack[this.stack.length-1];te.label=G,te.identifier=fn(this.sliceSerialize(M)).toLowerCase()}function N(){const M=this.resume(),G=this.stack[this.stack.length-1];G.title=M}function k(){const M=this.resume(),G=this.stack[this.stack.length-1];G.url=M}function L(M){const G=this.stack[this.stack.length-1];if(!G.depth){const te=this.sliceSerialize(M).length;G.depth=te}}function v(){this.data.setextHeadingSlurpLineEnding=!0}function R(M){const G=this.stack[this.stack.length-1];G.depth=this.sliceSerialize(M).codePointAt(0)===61?1:2}function P(){this.data.setextHeadingSlurpLineEnding=void 0}function q(M){const te=this.stack[this.stack.length-1].children;let ue=te[te.length-1];(!ue||ue.type!=="text")&&(ue=Nf(),ue.position={start:It(M.start),end:void 0},te.push(ue)),this.stack.push(ue)}function K(M){const G=this.stack.pop();G.value+=this.sliceSerialize(M),G.position.end=It(M.end)}function U(M){const G=this.stack[this.stack.length-1];if(this.data.atHardBreak){const te=G.children[G.children.length-1];te.position.end=It(M.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(G.type)&&(q.call(this,M),K.call(this,M))}function z(){this.data.atHardBreak=!0}function $(){const M=this.resume(),G=this.stack[this.stack.length-1];G.value=M}function Y(){const M=this.resume(),G=this.stack[this.stack.length-1];G.value=M}function F(){const M=this.resume(),G=this.stack[this.stack.length-1];G.value=M}function X(){const M=this.stack[this.stack.length-1];if(this.data.inReference){const G=this.data.referenceType||"shortcut";M.type+="Reference",M.referenceType=G,delete M.url,delete M.title}else delete M.identifier,delete M.label;this.data.referenceType=void 0}function Q(){const M=this.stack[this.stack.length-1];if(this.data.inReference){const G=this.data.referenceType||"shortcut";M.type+="Reference",M.referenceType=G,delete M.url,delete M.title}else delete M.identifier,delete M.label;this.data.referenceType=void 0}function B(M){const G=this.sliceSerialize(M),te=this.stack[this.stack.length-2];te.label=eT(G),te.identifier=fn(G).toLowerCase()}function ie(){const M=this.stack[this.stack.length-1],G=this.resume(),te=this.stack[this.stack.length-1];if(this.data.inReference=!0,te.type==="link"){const ue=M.children;te.children=ue}else te.alt=G}function S(){const M=this.resume(),G=this.stack[this.stack.length-1];G.url=M}function xe(){const M=this.resume(),G=this.stack[this.stack.length-1];G.title=M}function we(){this.data.inReference=void 0}function I(){this.data.referenceType="collapsed"}function fe(M){const G=this.resume(),te=this.stack[this.stack.length-1];te.label=G,te.identifier=fn(this.sliceSerialize(M)).toLowerCase(),this.data.referenceType="full"}function De(M){this.data.characterReferenceType=M.type}function Ee(M){const G=this.sliceSerialize(M),te=this.data.characterReferenceType;let ue;te?(ue=jc(G,te==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):ue=oi(G);const he=this.stack[this.stack.length-1];he.value+=ue}function ce(M){const G=this.stack.pop();G.position.end=It(M.end)}function Me(M){K.call(this,M);const G=this.stack[this.stack.length-1];G.url=this.sliceSerialize(M)}function je(M){K.call(this,M);const G=this.stack[this.stack.length-1];G.url="mailto:"+this.sliceSerialize(M)}function ze(){return{type:"blockquote",children:[]}}function it(){return{type:"code",lang:null,meta:null,value:""}}function St(){return{type:"inlineCode",value:""}}function Qt(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function yf(){return{type:"emphasis",children:[]}}function Ai(){return{type:"heading",depth:0,children:[]}}function Si(){return{type:"break"}}function Ni(){return{type:"html",value:""}}function _f(){return{type:"image",title:null,url:"",alt:null}}function Ii(){return{type:"link",title:null,url:"",children:[]}}function vi(M){return{type:"list",ordered:M.type==="listOrdered",start:null,spread:M._spread,children:[]}}function Cf(M){return{type:"listItem",spread:M._spread,checked:null,children:[]}}function Af(){return{type:"paragraph",children:[]}}function Sf(){return{type:"strong",children:[]}}function Nf(){return{type:"text",value:""}}function If(){return{type:"thematicBreak"}}}function It(e){return{line:e.line,column:e.column,offset:e.offset}}function Zc(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Zc(e,r):aT(e,r)}}function aT(e,t){let n;for(n in t)if(Qc.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function Do(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+qn({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+qn({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+qn({start:t.start,end:t.end})+") is still open")}function sT(e){const t=this;t.parser=n;function n(r){return nT(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function iT(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function oT(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
65
+ `}]}function uT(e,t){const n=t.value?t.value+`
66
+ `:"",r={};t.lang&&(r.className=["language-"+t.lang]);let a={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:"element",tagName:"pre",properties:{},children:[a]},e.patch(t,a),a}function lT(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function cT(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function dT(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),a=wn(r.toLowerCase()),s=e.footnoteOrder.indexOf(r);let i,o=e.footnoteCounts.get(r);o===void 0?(o=0,e.footnoteOrder.push(r),i=e.footnoteOrder.length):i=s+1,o+=1,e.footnoteCounts.set(r,o);const l={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+a,id:n+"fnref-"+a+(o>1?"-"+o:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(i)}]};e.patch(t,l);const c={type:"element",tagName:"sup",properties:{},children:[l]};return e.patch(t,c),e.applyData(t,c)}function fT(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function hT(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function Jc(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const a=e.all(t),s=a[0];s&&s.type==="text"?s.value="["+s.value:a.unshift({type:"text",value:"["});const i=a[a.length-1];return i&&i.type==="text"?i.value+=r:a.push({type:"text",value:r}),a}function mT(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Jc(e,t);const a={src:wn(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(a.title=r.title);const s={type:"element",tagName:"img",properties:a,children:[]};return e.patch(t,s),e.applyData(t,s)}function pT(e,t){const n={src:wn(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function gT(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function bT(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return Jc(e,t);const a={href:wn(r.url||"")};r.title!==null&&r.title!==void 0&&(a.title=r.title);const s={type:"element",tagName:"a",properties:a,children:e.all(t)};return e.patch(t,s),e.applyData(t,s)}function ET(e,t){const n={href:wn(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function TT(e,t,n){const r=e.all(t),a=n?xT(n):ed(t),s={},i=[];if(typeof t.checked=="boolean"){const d=r[0];let f;d&&d.type==="element"&&d.tagName==="p"?f=d:(f={type:"element",tagName:"p",properties:{},children:[]},r.unshift(f)),f.children.length>0&&f.children.unshift({type:"text",value:" "}),f.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),s.className=["task-list-item"]}let o=-1;for(;++o<r.length;){const d=r[o];(a||o!==0||d.type!=="element"||d.tagName!=="p")&&i.push({type:"text",value:`
67
+ `}),d.type==="element"&&d.tagName==="p"&&!a?i.push(...d.children):i.push(d)}const l=r[r.length-1];l&&(a||l.type!=="element"||l.tagName!=="p")&&i.push({type:"text",value:`
68
+ `});const c={type:"element",tagName:"li",properties:s,children:i};return e.patch(t,c),e.applyData(t,c)}function xT(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=ed(n[r])}return t}function ed(e){const t=e.spread;return t??e.children.length>1}function yT(e,t){const n={},r=e.all(t);let a=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++a<r.length;){const i=r[a];if(i.type==="element"&&i.tagName==="li"&&i.properties&&Array.isArray(i.properties.className)&&i.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const s={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,s),e.applyData(t,s)}function _T(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function CT(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function AT(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function ST(e,t){const n=e.all(t),r=n.shift(),a=[];if(r){const i={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],i),a.push(i)}if(n.length>0){const i={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},o=gt(t.children[1]),l=ha(t.children[t.children.length-1]);o&&l&&(i.position={start:o,end:l}),a.push(i)}const s={type:"element",tagName:"table",properties:{},children:e.wrap(a,!0)};return e.patch(t,s),e.applyData(t,s)}function NT(e,t,n){const r=n?n.children:void 0,s=(r?r.indexOf(t):1)===0?"th":"td",i=n&&n.type==="table"?n.align:void 0,o=i?i.length:t.children.length;let l=-1;const c=[];for(;++l<o;){const f=t.children[l],p={},h=i?i[l]:void 0;h&&(p.align=h);let x={type:"element",tagName:s,properties:p,children:[]};f&&(x.children=e.all(f),e.patch(f,x),x=e.applyData(f,x)),c.push(x)}const d={type:"element",tagName:"tr",properties:{},children:e.wrap(c,!0)};return e.patch(t,d),e.applyData(t,d)}function IT(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const Mo=9,Bo=32;function vT(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),a=0;const s=[];for(;r;)s.push(Fo(t.slice(a,r.index),a>0,!0),r[0]),a=r.index+r[0].length,r=n.exec(t);return s.push(Fo(t.slice(a),a>0,!1)),s.join("")}function Fo(e,t,n){let r=0,a=e.length;if(t){let s=e.codePointAt(r);for(;s===Mo||s===Bo;)r++,s=e.codePointAt(r)}if(n){let s=e.codePointAt(a-1);for(;s===Mo||s===Bo;)a--,s=e.codePointAt(a-1)}return a>r?e.slice(r,a):""}function wT(e,t){const n={type:"text",value:vT(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function kT(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const OT={blockquote:iT,break:oT,code:uT,delete:lT,emphasis:cT,footnoteReference:dT,heading:fT,html:hT,imageReference:mT,image:pT,inlineCode:gT,linkReference:bT,link:ET,listItem:TT,list:yT,paragraph:_T,root:CT,strong:AT,table:ST,tableCell:IT,tableRow:NT,text:wT,thematicBreak:kT,toml:Ir,yaml:Ir,definition:Ir,footnoteDefinition:Ir};function Ir(){}const td=-1,pa=0,Xn=1,Vr=2,ci=3,di=4,fi=5,hi=6,nd=7,rd=8,Ho=typeof self=="object"?self:globalThis,RT=(e,t)=>{const n=(a,s)=>(e.set(s,a),a),r=a=>{if(e.has(a))return e.get(a);const[s,i]=t[a];switch(s){case pa:case td:return n(i,a);case Xn:{const o=n([],a);for(const l of i)o.push(r(l));return o}case Vr:{const o=n({},a);for(const[l,c]of i)o[r(l)]=r(c);return o}case ci:return n(new Date(i),a);case di:{const{source:o,flags:l}=i;return n(new RegExp(o,l),a)}case fi:{const o=n(new Map,a);for(const[l,c]of i)o.set(r(l),r(c));return o}case hi:{const o=n(new Set,a);for(const l of i)o.add(r(l));return o}case nd:{const{name:o,message:l}=i;return n(new Ho[o](l),a)}case rd:return n(BigInt(i),a);case"BigInt":return n(Object(BigInt(i)),a);case"ArrayBuffer":return n(new Uint8Array(i).buffer,i);case"DataView":{const{buffer:o}=new Uint8Array(i);return n(new DataView(o),i)}}return n(new Ho[s](i),a)};return r},Uo=e=>RT(new Map,e)(0),sn="",{toString:LT}={},{keys:PT}=Object,Un=e=>{const t=typeof e;if(t!=="object"||!e)return[pa,t];const n=LT.call(e).slice(8,-1);switch(n){case"Array":return[Xn,sn];case"Object":return[Vr,sn];case"Date":return[ci,sn];case"RegExp":return[di,sn];case"Map":return[fi,sn];case"Set":return[hi,sn];case"DataView":return[Xn,n]}return n.includes("Array")?[Xn,n]:n.includes("Error")?[nd,n]:[Vr,n]},vr=([e,t])=>e===pa&&(t==="function"||t==="symbol"),DT=(e,t,n,r)=>{const a=(i,o)=>{const l=r.push(i)-1;return n.set(o,l),l},s=i=>{if(n.has(i))return n.get(i);let[o,l]=Un(i);switch(o){case pa:{let d=i;switch(l){case"bigint":o=rd,d=i.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+l);d=null;break;case"undefined":return a([td],i)}return a([o,d],i)}case Xn:{if(l){let p=i;return l==="DataView"?p=new Uint8Array(i.buffer):l==="ArrayBuffer"&&(p=new Uint8Array(i)),a([l,[...p]],i)}const d=[],f=a([o,d],i);for(const p of i)d.push(s(p));return f}case Vr:{if(l)switch(l){case"BigInt":return a([l,i.toString()],i);case"Boolean":case"Number":case"String":return a([l,i.valueOf()],i)}if(t&&"toJSON"in i)return s(i.toJSON());const d=[],f=a([o,d],i);for(const p of PT(i))(e||!vr(Un(i[p])))&&d.push([s(p),s(i[p])]);return f}case ci:return a([o,i.toISOString()],i);case di:{const{source:d,flags:f}=i;return a([o,{source:d,flags:f}],i)}case fi:{const d=[],f=a([o,d],i);for(const[p,h]of i)(e||!(vr(Un(p))||vr(Un(h))))&&d.push([s(p),s(h)]);return f}case hi:{const d=[],f=a([o,d],i);for(const p of i)(e||!vr(Un(p)))&&d.push(s(p));return f}}const{message:c}=i;return a([o,{name:l,message:c}],i)};return s},jo=(e,{json:t,lossy:n}={})=>{const r=[];return DT(!(t||n),!!t,new Map,r)(e),r},bn=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Uo(jo(e,t)):structuredClone(e):(e,t)=>Uo(jo(e,t));function MT(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function BT(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function FT(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||MT,r=e.options.footnoteBackLabel||BT,a=e.options.footnoteLabel||"Footnotes",s=e.options.footnoteLabelTagName||"h2",i=e.options.footnoteLabelProperties||{className:["sr-only"]},o=[];let l=-1;for(;++l<e.footnoteOrder.length;){const c=e.footnoteById.get(e.footnoteOrder[l]);if(!c)continue;const d=e.all(c),f=String(c.identifier).toUpperCase(),p=wn(f.toLowerCase());let h=0;const x=[],g=e.footnoteCounts.get(f);for(;g!==void 0&&++h<=g;){x.length>0&&x.push({type:"text",value:" "});let _=typeof n=="string"?n:n(l,h);typeof _=="string"&&(_={type:"text",value:_}),x.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+p+(h>1?"-"+h:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(l,h),className:["data-footnote-backref"]},children:Array.isArray(_)?_:[_]})}const A=d[d.length-1];if(A&&A.type==="element"&&A.tagName==="p"){const _=A.children[A.children.length-1];_&&_.type==="text"?_.value+=" ":A.children.push({type:"text",value:" "}),A.children.push(...x)}else d.push(...x);const E={type:"element",tagName:"li",properties:{id:t+"fn-"+p},children:e.wrap(d,!0)};e.patch(c,E),o.push(E)}if(o.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:s,properties:{...bn(i),id:"footnote-label"},children:[{type:"text",value:a}]},{type:"text",value:`
69
+ `},{type:"element",tagName:"ol",properties:{},children:e.wrap(o,!0)},{type:"text",value:`
70
+ `}]}}const ad=(function(e){if(e==null)return zT;if(typeof e=="function")return ga(e);if(typeof e=="object")return Array.isArray(e)?HT(e):UT(e);if(typeof e=="string")return jT(e);throw new Error("Expected function, string, or object as test")});function HT(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=ad(e[n]);return ga(r);function r(...a){let s=-1;for(;++s<t.length;)if(t[s].apply(this,a))return!0;return!1}}function UT(e){const t=e;return ga(n);function n(r){const a=r;let s;for(s in e)if(a[s]!==t[s])return!1;return!0}}function jT(e){return ga(t);function t(n){return n&&n.type===e}}function ga(e){return t;function t(n,r,a){return!!(YT(n)&&e.call(this,n,typeof r=="number"?r:void 0,a||void 0))}}function zT(){return!0}function YT(e){return e!==null&&typeof e=="object"&&"type"in e}const sd=[],WT=!0,zo=!1,VT="skip";function $T(e,t,n,r){let a;typeof t=="function"&&typeof n!="function"?(r=n,n=t):a=t;const s=ad(a),i=r?-1:1;o(e,void 0,[])();function o(l,c,d){const f=l&&typeof l=="object"?l:{};if(typeof f.type=="string"){const h=typeof f.tagName=="string"?f.tagName:typeof f.name=="string"?f.name:void 0;Object.defineProperty(p,"name",{value:"node ("+(l.type+(h?"<"+h+">":""))+")"})}return p;function p(){let h=sd,x,g,A;if((!t||s(l,c,d[d.length-1]||void 0))&&(h=qT(n(l,d)),h[0]===zo))return h;if("children"in l&&l.children){const E=l;if(E.children&&h[0]!==VT)for(g=(r?E.children.length:-1)+i,A=d.concat(E);g>-1&&g<E.children.length;){const _=E.children[g];if(x=o(_,g,A)(),x[0]===zo)return x;g=typeof x[1]=="number"?x[1]:g+i}}return h}}}function qT(e){return Array.isArray(e)?e:typeof e=="number"?[WT,e]:e==null?sd:[e]}function mi(e,t,n,r){let a,s,i;typeof t=="function"&&typeof n!="function"?(s=void 0,i=t,a=n):(s=t,i=n,a=r),$T(e,s,o,a);function o(l,c){const d=c[c.length-1],f=d?d.children.indexOf(l):void 0;return i(l,f,d)}}const Es={}.hasOwnProperty,GT={};function XT(e,t){const n=t||GT,r=new Map,a=new Map,s=new Map,i={...OT,...n.handlers},o={all:c,applyData:QT,definitionById:r,footnoteById:a,footnoteCounts:s,footnoteOrder:[],handlers:i,one:l,options:n,patch:KT,wrap:JT};return mi(e,function(d){if(d.type==="definition"||d.type==="footnoteDefinition"){const f=d.type==="definition"?r:a,p=String(d.identifier).toUpperCase();f.has(p)||f.set(p,d)}}),o;function l(d,f){const p=d.type,h=o.handlers[p];if(Es.call(o.handlers,p)&&h)return h(o,d,f);if(o.options.passThrough&&o.options.passThrough.includes(p)){if("children"in d){const{children:g,...A}=d,E=bn(A);return E.children=o.all(d),E}return bn(d)}return(o.options.unknownHandler||ZT)(o,d,f)}function c(d){const f=[];if("children"in d){const p=d.children;let h=-1;for(;++h<p.length;){const x=o.one(p[h],d);if(x){if(h&&p[h-1].type==="break"&&(!Array.isArray(x)&&x.type==="text"&&(x.value=Yo(x.value)),!Array.isArray(x)&&x.type==="element")){const g=x.children[0];g&&g.type==="text"&&(g.value=Yo(g.value))}Array.isArray(x)?f.push(...x):f.push(x)}}}return f}}function KT(e,t){e.position&&(t.position=L1(e))}function QT(e,t){let n=t;if(e&&e.data){const r=e.data.hName,a=e.data.hChildren,s=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const i="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:i}}n.type==="element"&&s&&Object.assign(n.properties,bn(s)),"children"in n&&n.children&&a!==null&&a!==void 0&&(n.children=a)}return n}function ZT(e,t){const n=t.data||{},r="value"in t&&!(Es.call(n,"hProperties")||Es.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function JT(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
71
+ `});++r<e.length;)r&&n.push({type:"text",value:`
72
+ `}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
73
+ `}),n}function Yo(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function Wo(e,t){const n=XT(e,t),r=n.one(e,void 0),a=FT(n),s=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return a&&s.children.push({type:"text",value:`
74
+ `},a),s}function ex(e,t){return e&&"run"in e?async function(n,r){const a=Wo(n,{file:r,...t});await e.run(a,r)}:function(n,r){return Wo(n,{file:r,...e||t})}}function Vo(e){if(e)throw e}var Ua,$o;function tx(){if($o)return Ua;$o=1;var e=Object.prototype.hasOwnProperty,t=Object.prototype.toString,n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,a=function(c){return typeof Array.isArray=="function"?Array.isArray(c):t.call(c)==="[object Array]"},s=function(c){if(!c||t.call(c)!=="[object Object]")return!1;var d=e.call(c,"constructor"),f=c.constructor&&c.constructor.prototype&&e.call(c.constructor.prototype,"isPrototypeOf");if(c.constructor&&!d&&!f)return!1;var p;for(p in c);return typeof p>"u"||e.call(c,p)},i=function(c,d){n&&d.name==="__proto__"?n(c,d.name,{enumerable:!0,configurable:!0,value:d.newValue,writable:!0}):c[d.name]=d.newValue},o=function(c,d){if(d==="__proto__")if(e.call(c,d)){if(r)return r(c,d).value}else return;return c[d]};return Ua=function l(){var c,d,f,p,h,x,g=arguments[0],A=1,E=arguments.length,_=!1;for(typeof g=="boolean"&&(_=g,g=arguments[1]||{},A=2),(g==null||typeof g!="object"&&typeof g!="function")&&(g={});A<E;++A)if(c=arguments[A],c!=null)for(d in c)f=o(g,d),p=o(c,d),g!==p&&(_&&p&&(s(p)||(h=a(p)))?(h?(h=!1,x=f&&a(f)?f:[]):x=f&&s(f)?f:{},i(g,{name:d,newValue:l(_,x,p)})):typeof p<"u"&&i(g,{name:d,newValue:p}));return g},Ua}var nx=tx();const ja=Nu(nx);function Ts(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function rx(){const e=[],t={run:n,use:r};return t;function n(...a){let s=-1;const i=a.pop();if(typeof i!="function")throw new TypeError("Expected function as last argument, not "+i);o(null,...a);function o(l,...c){const d=e[++s];let f=-1;if(l){i(l);return}for(;++f<a.length;)(c[f]===null||c[f]===void 0)&&(c[f]=a[f]);a=c,d?ax(d,o)(...c):i(null,...c)}}function r(a){if(typeof a!="function")throw new TypeError("Expected `middelware` to be a function, not "+a);return e.push(a),t}}function ax(e,t){let n;return r;function r(...i){const o=e.length>i.length;let l;o&&i.push(a);try{l=e.apply(this,i)}catch(c){const d=c;if(o&&n)throw d;return a(d)}o||(l&&l.then&&typeof l.then=="function"?l.then(s,a):l instanceof Error?a(l):s(l))}function a(i,...o){n||(n=!0,t(i,...o))}function s(i){a(null,i)}}const ot={basename:sx,dirname:ix,extname:ox,join:ux,sep:"/"};function sx(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');mr(e);let n=0,r=-1,a=e.length,s;if(t===void 0||t.length===0||t.length>e.length){for(;a--;)if(e.codePointAt(a)===47){if(s){n=a+1;break}}else r<0&&(s=!0,r=a+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let i=-1,o=t.length-1;for(;a--;)if(e.codePointAt(a)===47){if(s){n=a+1;break}}else i<0&&(s=!0,i=a+1),o>-1&&(e.codePointAt(a)===t.codePointAt(o--)?o<0&&(r=a):(o=-1,r=i));return n===r?r=i:r<0&&(r=e.length),e.slice(n,r)}function ix(e){if(mr(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function ox(e){mr(e);let t=e.length,n=-1,r=0,a=-1,s=0,i;for(;t--;){const o=e.codePointAt(t);if(o===47){if(i){r=t+1;break}continue}n<0&&(i=!0,n=t+1),o===46?a<0?a=t:s!==1&&(s=1):a>-1&&(s=-1)}return a<0||n<0||s===0||s===1&&a===n-1&&a===r+1?"":e.slice(a,n)}function ux(...e){let t=-1,n;for(;++t<e.length;)mr(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":lx(n)}function lx(e){mr(e);const t=e.codePointAt(0)===47;let n=cx(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function cx(e,t){let n="",r=0,a=-1,s=0,i=-1,o,l;for(;++i<=e.length;){if(i<e.length)o=e.codePointAt(i);else{if(o===47)break;o=47}if(o===47){if(!(a===i-1||s===1))if(a!==i-1&&s===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(l=n.lastIndexOf("/"),l!==n.length-1){l<0?(n="",r=0):(n=n.slice(0,l),r=n.length-1-n.lastIndexOf("/")),a=i,s=0;continue}}else if(n.length>0){n="",r=0,a=i,s=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(a+1,i):n=e.slice(a+1,i),r=i-a-1;a=i,s=0}else o===46&&s>-1?s++:s=-1}return n}function mr(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const dx={cwd:fx};function fx(){return"/"}function xs(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function hx(e){if(typeof e=="string")e=new URL(e);else if(!xs(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return mx(e)}function mx(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const a=new TypeError("File URL path must not include encoded / characters");throw a.code="ERR_INVALID_FILE_URL_PATH",a}}return decodeURIComponent(t)}const za=["history","path","basename","stem","extname","dirname"];class id{constructor(t){let n;t?xs(t)?n={path:t}:typeof t=="string"||px(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":dx.cwd(),this.data={},this.history=[],this.messages=[],this.value,this.map,this.result,this.stored;let r=-1;for(;++r<za.length;){const s=za[r];s in n&&n[s]!==void 0&&n[s]!==null&&(this[s]=s==="history"?[...n[s]]:n[s])}let a;for(a in n)za.includes(a)||(this[a]=n[a])}get basename(){return typeof this.path=="string"?ot.basename(this.path):void 0}set basename(t){Wa(t,"basename"),Ya(t,"basename"),this.path=ot.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?ot.dirname(this.path):void 0}set dirname(t){qo(this.basename,"dirname"),this.path=ot.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?ot.extname(this.path):void 0}set extname(t){if(Ya(t,"extname"),qo(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=ot.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){xs(t)&&(t=hx(t)),Wa(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?ot.basename(this.path,this.extname):void 0}set stem(t){Wa(t,"stem"),Ya(t,"stem"),this.path=ot.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const a=this.message(t,n,r);throw a.fatal=!0,a}info(t,n,r){const a=this.message(t,n,r);return a.fatal=void 0,a}message(t,n,r){const a=new Ie(t,n,r);return this.path&&(a.name=this.path+":"+a.name,a.file=this.path),a.fatal=!1,this.messages.push(a),a}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function Ya(e,t){if(e&&e.includes(ot.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+ot.sep+"`")}function Wa(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function qo(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function px(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const gx=(function(e){const r=this.constructor.prototype,a=r[e],s=function(){return a.apply(s,arguments)};return Object.setPrototypeOf(s,r),s}),bx={}.hasOwnProperty;class pi extends gx{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=rx()}copy(){const t=new pi;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(ja(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(qa("data",this.frozen),this.namespace[t]=n,this):bx.call(this.namespace,t)&&this.namespace[t]||void 0:t?(qa("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const a=n.call(t,...r);typeof a=="function"&&this.transformers.use(a)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=wr(t),r=this.parser||this.Parser;return Va("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Va("process",this.parser||this.Parser),$a("process",this.compiler||this.Compiler),n?a(void 0,n):new Promise(a);function a(s,i){const o=wr(t),l=r.parse(o);r.run(l,o,function(d,f,p){if(d||!f||!p)return c(d);const h=f,x=r.stringify(h,p);xx(x)?p.value=x:p.result=x,c(d,p)});function c(d,f){d||!f?i(d):s?s(f):n(void 0,f)}}}processSync(t){let n=!1,r;return this.freeze(),Va("processSync",this.parser||this.Parser),$a("processSync",this.compiler||this.Compiler),this.process(t,a),Xo("processSync","process",n),r;function a(s,i){n=!0,Vo(s),r=i}}run(t,n,r){Go(t),this.freeze();const a=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?s(void 0,r):new Promise(s);function s(i,o){const l=wr(n);a.run(t,l,c);function c(d,f,p){const h=f||t;d?o(d):i?i(h):r(void 0,h,p)}}}runSync(t,n){let r=!1,a;return this.run(t,n,s),Xo("runSync","run",r),a;function s(i,o){Vo(i),a=o,r=!0}}stringify(t,n){this.freeze();const r=wr(n),a=this.compiler||this.Compiler;return $a("stringify",a),Go(t),a(t,r)}use(t,...n){const r=this.attachers,a=this.namespace;if(qa("use",this.frozen),t!=null)if(typeof t=="function")l(t,n);else if(typeof t=="object")Array.isArray(t)?o(t):i(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function s(c){if(typeof c=="function")l(c,[]);else if(typeof c=="object")if(Array.isArray(c)){const[d,...f]=c;l(d,f)}else i(c);else throw new TypeError("Expected usable value, not `"+c+"`")}function i(c){if(!("plugins"in c)&&!("settings"in c))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(c.plugins),c.settings&&(a.settings=ja(!0,a.settings,c.settings))}function o(c){let d=-1;if(c!=null)if(Array.isArray(c))for(;++d<c.length;){const f=c[d];s(f)}else throw new TypeError("Expected a list of plugins, not `"+c+"`")}function l(c,d){let f=-1,p=-1;for(;++f<r.length;)if(r[f][0]===c){p=f;break}if(p===-1)r.push([c,...d]);else if(d.length>0){let[h,...x]=d;const g=r[p][1];Ts(g)&&Ts(h)&&(h=ja(!0,g,h)),r[p]=[c,h,...x]}}}}const Ex=new pi().freeze();function Va(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function $a(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function qa(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Go(e){if(!Ts(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function Xo(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function wr(e){return Tx(e)?e:new id(e)}function Tx(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function xx(e){return typeof e=="string"||yx(e)}function yx(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const _x="https://github.com/remarkjs/react-markdown/blob/main/changelog.md",Ko=[],Qo={allowDangerousHtml:!0},Cx=/^(https?|ircs?|mailto|xmpp)$/i,Ax=[{from:"astPlugins",id:"remove-buggy-html-in-markdown-parser"},{from:"allowDangerousHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"allowNode",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowElement"},{from:"allowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"allowedElements"},{from:"className",id:"remove-classname"},{from:"disallowedTypes",id:"replace-allownode-allowedtypes-and-disallowedtypes",to:"disallowedElements"},{from:"escapeHtml",id:"remove-buggy-html-in-markdown-parser"},{from:"includeElementIndex",id:"#remove-includeelementindex"},{from:"includeNodeIndex",id:"change-includenodeindex-to-includeelementindex"},{from:"linkTarget",id:"remove-linktarget"},{from:"plugins",id:"change-plugins-to-remarkplugins",to:"remarkPlugins"},{from:"rawSourcePos",id:"#remove-rawsourcepos"},{from:"renderers",id:"change-renderers-to-components",to:"components"},{from:"source",id:"change-source-to-children",to:"children"},{from:"sourcePos",id:"#remove-sourcepos"},{from:"transformImageUri",id:"#add-urltransform",to:"urlTransform"},{from:"transformLinkUri",id:"#add-urltransform",to:"urlTransform"}];function Sx(e){const t=Nx(e),n=Ix(e);return vx(t.runSync(t.parse(n),n),e)}function Nx(e){const t=e.rehypePlugins||Ko,n=e.remarkPlugins||Ko,r=e.remarkRehypeOptions?{...e.remarkRehypeOptions,...Qo}:Qo;return Ex().use(sT).use(n).use(ex,r).use(t)}function Ix(e){const t=e.children||"",n=new id;return typeof t=="string"&&(n.value=t),n}function vx(e,t){const n=t.allowedElements,r=t.allowElement,a=t.components,s=t.disallowedElements,i=t.skipHtml,o=t.unwrapDisallowed,l=t.urlTransform||wx;for(const d of Ax)Object.hasOwn(t,d.from)&&(""+d.from+(d.to?"use `"+d.to+"` instead":"remove it")+_x+d.id,void 0);return mi(e,c),F1(e,{Fragment:m.Fragment,components:a,ignoreInvalidStyle:!0,jsx:m.jsx,jsxs:m.jsxs,passKeys:!0,passNode:!0});function c(d,f,p){if(d.type==="raw"&&p&&typeof f=="number")return i?p.children.splice(f,1):p.children[f]={type:"text",value:d.value},f;if(d.type==="element"){let h;for(h in Ba)if(Object.hasOwn(Ba,h)&&Object.hasOwn(d.properties,h)){const x=d.properties[h],g=Ba[h];(g===null||g.includes(d.tagName))&&(d.properties[h]=l(String(x||""),h,d))}}if(d.type==="element"){let h=n?!n.includes(d.tagName):s?s.includes(d.tagName):!1;if(!h&&r&&typeof f=="number"&&(h=!r(d,f,p)),h&&p&&typeof f=="number")return o&&d.children?p.children.splice(f,1,...d.children):p.children.splice(f,1),f}}}function wx(e){const t=e.indexOf(":"),n=e.indexOf("?"),r=e.indexOf("#"),a=e.indexOf("/");return t===-1||a!==-1&&t>a||n!==-1&&t>n||r!==-1&&t>r||Cx.test(e.slice(0,t))?e:""}const Zo=/[#.]/g;function kx(e,t){const n=e||"",r={};let a=0,s,i;for(;a<n.length;){Zo.lastIndex=a;const o=Zo.exec(n),l=n.slice(a,o?o.index:n.length);l&&(s?s==="#"?r.id=l:Array.isArray(r.className)?r.className.push(l):r.className=[l]:i=l,a+=l.length),o&&(s=o[0],a++)}return{type:"element",tagName:i||t||"div",properties:r,children:[]}}function od(e,t,n){const r=n?Px(n):void 0;function a(s,i,...o){let l;if(s==null){l={type:"root",children:[]};const c=i;o.unshift(c)}else{l=kx(s,t);const c=l.tagName.toLowerCase(),d=r?r.get(c):void 0;if(l.tagName=d||c,Ox(i))o.unshift(i);else for(const[f,p]of Object.entries(i))Rx(e,l.properties,f,p)}for(const c of o)ys(l.children,c);return l.type==="element"&&l.tagName==="template"&&(l.content={type:"root",children:l.children},l.children=[]),l}return a}function Ox(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const a=t[r];if(a&&typeof a=="object"){if(!Array.isArray(a))return!0;const s=a;for(const i of s)if(typeof i!="number"&&typeof i!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function Rx(e,t,n,r){const a=ri(e,n);let s;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;s=r}else typeof r=="boolean"?s=r:typeof r=="string"?a.spaceSeparated?s=bo(r):a.commaSeparated?s=fo(r):a.commaOrSpaceSeparated?s=bo(fo(r).join(" ")):s=Jo(a,a.property,r):Array.isArray(r)?s=[...r]:s=a.property==="style"?Lx(r):String(r);if(Array.isArray(s)){const i=[];for(const o of s)i.push(Jo(a,a.property,o));s=i}a.property==="className"&&Array.isArray(t.className)&&(s=t.className.concat(s)),t[a.property]=s}}function ys(e,t){if(t!=null)if(typeof t=="number"||typeof t=="string")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(const n of t)ys(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?ys(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Jo(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||ar(n)===ar(t)))return!0}return n}function Lx(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function Px(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const Dx=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],Mx=od(fa,"div"),Bx=od(vn,"g",Dx);function Fx(e){const t=String(e),n=[];return{toOffset:a,toPoint:r};function r(s){if(typeof s=="number"&&s>-1&&s<=t.length){let i=0;for(;;){let o=n[i];if(o===void 0){const l=eu(t,n[i-1]);o=l===-1?t.length+1:l+1,n[i]=o}if(o>s)return{line:i+1,column:s-(i>0?n[i-1]:0)+1,offset:s};i++}}}function a(s){if(s&&typeof s.line=="number"&&typeof s.column=="number"&&!Number.isNaN(s.line)&&!Number.isNaN(s.column)){for(;n.length<s.line;){const o=n[n.length-1],l=eu(t,o),c=l===-1?t.length+1:l+1;if(o===c)break;n.push(c)}const i=(s.line>1?n[s.line-2]:0)+s.column-1;if(i<n[s.line-1])return i}}}function eu(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
75
+ `,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Ht={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},ud={}.hasOwnProperty,Hx=Object.prototype;function Ux(e,t){const n=t||{};return gi({file:n.file||void 0,location:!1,schema:n.space==="svg"?vn:fa,verbose:n.verbose||!1},e)}function gi(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Mr(e,r,n),n}case"#document":case"#document-fragment":{const r=t,a="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:ld(e,t.childNodes),data:{quirksMode:a}},e.file&&e.location){const s=String(e.file),i=Fx(s),o=i.toPoint(0),l=i.toPoint(s.length);n.position={start:o,end:l}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Mr(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Mr(e,r,n),n}default:return n=jx(e,t),n}}function ld(e,t){let n=-1;const r=[];for(;++n<t.length;){const a=gi(e,t[n]);r.push(a)}return r}function jx(e,t){const n=e.schema;e.schema=t.namespaceURI===Ht.svg?vn:fa;let r=-1;const a={};for(;++r<t.attrs.length;){const o=t.attrs[r],l=(o.prefix?o.prefix+":":"")+o.name;ud.call(Hx,l)||(a[l]=o.value)}const i=(e.schema.space==="svg"?Bx:Mx)(t.tagName,a,ld(e,t.childNodes));if(Mr(e,t,i),i.tagName==="template"){const o=t,l=o.sourceCodeLocation,c=l&&l.startTag&&un(l.startTag),d=l&&l.endTag&&un(l.endTag),f=gi(e,o.content);c&&d&&e.file&&(f.position={start:c.end,end:d.start}),i.content=f}return e.schema=n,i}function Mr(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=zx(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function zx(e,t,n){const r=un(n);if(t.type==="element"){const a=t.children[t.children.length-1];if(r&&!n.endTag&&a&&a.position&&a.position.end&&(r.end=Object.assign({},a.position.end)),e.verbose){const s={};let i;if(n.attrs)for(i in n.attrs)ud.call(n.attrs,i)&&(s[ri(e.schema,i).property]=un(n.attrs[i]));n.startTag;const o=un(n.startTag),l=n.endTag?un(n.endTag):void 0,c={opening:o};l&&(c.closing=l),c.properties=s,t.data={position:c}}}return r}function un(e){const t=tu({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=tu({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function tu(e){return e.line&&e.column?e:void 0}class pr{constructor(t,n,r){this.property=t,this.normal=n,r&&(this.space=r)}}pr.prototype.property={};pr.prototype.normal={};pr.prototype.space=null;function cd(e,t){const n={},r={};let a=-1;for(;++a<e.length;)Object.assign(n,e[a].property),Object.assign(r,e[a].normal);return new pr(n,r,t)}function _s(e){return e.toLowerCase()}class Je{constructor(t,n){this.property=t,this.attribute=n}}Je.prototype.space=null;Je.prototype.boolean=!1;Je.prototype.booleanish=!1;Je.prototype.overloadedBoolean=!1;Je.prototype.number=!1;Je.prototype.commaSeparated=!1;Je.prototype.spaceSeparated=!1;Je.prototype.commaOrSpaceSeparated=!1;Je.prototype.mustUseProperty=!1;Je.prototype.defined=!1;let Yx=0;const ne=Xt(),_e=Xt(),dd=Xt(),V=Xt(),pe=Xt(),hn=Xt(),Ve=Xt();function Xt(){return 2**++Yx}const Cs=Object.freeze(Object.defineProperty({__proto__:null,boolean:ne,booleanish:_e,commaOrSpaceSeparated:Ve,commaSeparated:hn,number:V,overloadedBoolean:dd,spaceSeparated:pe},Symbol.toStringTag,{value:"Module"})),Ga=Object.keys(Cs);class bi extends Je{constructor(t,n,r,a){let s=-1;if(super(t,n),nu(this,"space",a),typeof r=="number")for(;++s<Ga.length;){const i=Ga[s];nu(this,Ga[s],(r&Cs[i])===Cs[i])}}}bi.prototype.defined=!0;function nu(e,t,n){n&&(e[t]=n)}const Wx={}.hasOwnProperty;function kn(e){const t={},n={};let r;for(r in e.properties)if(Wx.call(e.properties,r)){const a=e.properties[r],s=new bi(r,e.transform(e.attributes||{},r),a,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(s.mustUseProperty=!0),t[r]=s,n[_s(r)]=r,n[_s(s.attribute)]=r}return new pr(t,n,e.space)}const fd=kn({space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()},properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null}}),hd=kn({space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()},properties:{xmlLang:null,xmlBase:null,xmlSpace:null}});function md(e,t){return t in e?e[t]:t}function pd(e,t){return md(e,t.toLowerCase())}const gd=kn({space:"xmlns",attributes:{xmlnsxlink:"xmlns:xlink"},transform:pd,properties:{xmlns:null,xmlnsXLink:null}}),bd=kn({transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()},properties:{ariaActiveDescendant:null,ariaAtomic:_e,ariaAutoComplete:null,ariaBusy:_e,ariaChecked:_e,ariaColCount:V,ariaColIndex:V,ariaColSpan:V,ariaControls:pe,ariaCurrent:null,ariaDescribedBy:pe,ariaDetails:null,ariaDisabled:_e,ariaDropEffect:pe,ariaErrorMessage:null,ariaExpanded:_e,ariaFlowTo:pe,ariaGrabbed:_e,ariaHasPopup:null,ariaHidden:_e,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:pe,ariaLevel:V,ariaLive:null,ariaModal:_e,ariaMultiLine:_e,ariaMultiSelectable:_e,ariaOrientation:null,ariaOwns:pe,ariaPlaceholder:null,ariaPosInSet:V,ariaPressed:_e,ariaReadOnly:_e,ariaRelevant:null,ariaRequired:_e,ariaRoleDescription:pe,ariaRowCount:V,ariaRowIndex:V,ariaRowSpan:V,ariaSelected:_e,ariaSetSize:V,ariaSort:null,ariaValueMax:V,ariaValueMin:V,ariaValueNow:V,ariaValueText:null,role:null}}),Vx=kn({space:"html",attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},transform:pd,mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:hn,acceptCharset:pe,accessKey:pe,action:null,allow:null,allowFullScreen:ne,allowPaymentRequest:ne,allowUserMedia:ne,alt:null,as:null,async:ne,autoCapitalize:null,autoComplete:pe,autoFocus:ne,autoPlay:ne,blocking:pe,capture:null,charSet:null,checked:ne,cite:null,className:pe,cols:V,colSpan:null,content:null,contentEditable:_e,controls:ne,controlsList:pe,coords:V|hn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:ne,defer:ne,dir:null,dirName:null,disabled:ne,download:dd,draggable:_e,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:ne,formTarget:null,headers:pe,height:V,hidden:ne,high:V,href:null,hrefLang:null,htmlFor:pe,httpEquiv:pe,id:null,imageSizes:null,imageSrcSet:null,inert:ne,inputMode:null,integrity:null,is:null,isMap:ne,itemId:null,itemProp:pe,itemRef:pe,itemScope:ne,itemType:pe,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:ne,low:V,manifest:null,max:null,maxLength:V,media:null,method:null,min:null,minLength:V,multiple:ne,muted:ne,name:null,nonce:null,noModule:ne,noValidate:ne,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:ne,optimum:V,pattern:null,ping:pe,placeholder:null,playsInline:ne,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:ne,referrerPolicy:null,rel:pe,required:ne,reversed:ne,rows:V,rowSpan:V,sandbox:pe,scope:null,scoped:ne,seamless:ne,selected:ne,shadowRootClonable:ne,shadowRootDelegatesFocus:ne,shadowRootMode:null,shape:null,size:V,sizes:null,slot:null,span:V,spellCheck:_e,src:null,srcDoc:null,srcLang:null,srcSet:null,start:V,step:null,style:null,tabIndex:V,target:null,title:null,translate:null,type:null,typeMustMatch:ne,useMap:null,value:_e,width:V,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:pe,axis:null,background:null,bgColor:null,border:V,borderColor:null,bottomMargin:V,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:ne,declare:ne,event:null,face:null,frame:null,frameBorder:null,hSpace:V,leftMargin:V,link:null,longDesc:null,lowSrc:null,marginHeight:V,marginWidth:V,noResize:ne,noHref:ne,noShade:ne,noWrap:ne,object:null,profile:null,prompt:null,rev:null,rightMargin:V,rules:null,scheme:null,scrolling:_e,standby:null,summary:null,text:null,topMargin:V,valueType:null,version:null,vAlign:null,vLink:null,vSpace:V,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:ne,disableRemotePlayback:ne,prefix:null,property:null,results:V,security:null,unselectable:null}}),$x=kn({space:"svg",attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},transform:md,properties:{about:Ve,accentHeight:V,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:V,amplitude:V,arabicForm:null,ascent:V,attributeName:null,attributeType:null,azimuth:V,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:V,by:null,calcMode:null,capHeight:V,className:pe,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:V,diffuseConstant:V,direction:null,display:null,dur:null,divisor:V,dominantBaseline:null,download:ne,dx:null,dy:null,edgeMode:null,editable:null,elevation:V,enableBackground:null,end:null,event:null,exponent:V,externalResourcesRequired:null,fill:null,fillOpacity:V,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:hn,g2:hn,glyphName:hn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:V,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:V,horizOriginX:V,horizOriginY:V,id:null,ideographic:V,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:V,k:V,k1:V,k2:V,k3:V,k4:V,kernelMatrix:Ve,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:V,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:V,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:V,overlineThickness:V,paintOrder:null,panose1:null,path:null,pathLength:V,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:pe,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:V,pointsAtY:V,pointsAtZ:V,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Ve,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Ve,rev:Ve,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Ve,requiredFeatures:Ve,requiredFonts:Ve,requiredFormats:Ve,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:V,specularExponent:V,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:V,strikethroughThickness:V,string:null,stroke:null,strokeDashArray:Ve,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:V,strokeOpacity:V,strokeWidth:null,style:null,surfaceScale:V,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Ve,tabIndex:V,tableValues:null,target:null,targetX:V,targetY:V,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Ve,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:V,underlineThickness:V,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:V,values:null,vAlphabetic:V,vMathematical:V,vectorEffect:null,vHanging:V,vIdeographic:V,version:null,vertAdvY:V,vertOriginX:V,vertOriginY:V,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:V,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null}}),qx=/^data[-\w.:]+$/i,ru=/-[a-z]/g,Gx=/[A-Z]/g;function Xx(e,t){const n=_s(t);let r=t,a=Je;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&qx.test(t)){if(t.charAt(4)==="-"){const s=t.slice(5).replace(ru,Qx);r="data"+s.charAt(0).toUpperCase()+s.slice(1)}else{const s=t.slice(4);if(!ru.test(s)){let i=s.replace(Gx,Kx);i.charAt(0)!=="-"&&(i="-"+i),t="data"+i}}a=bi}return new a(r,t)}function Kx(e){return"-"+e.toLowerCase()}function Qx(e){return e.charAt(1).toUpperCase()}const Zx=cd([hd,fd,gd,bd,Vx],"html"),Ed=cd([hd,fd,gd,bd,$x],"svg"),au={}.hasOwnProperty;function Td(e,t){const n=t||{};function r(a,...s){let i=r.invalid;const o=r.handlers;if(a&&au.call(a,e)){const l=String(a[e]);i=au.call(o,l)?o[l]:r.unknown}if(i)return i.call(this,a,...s)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const Jx={},ey={}.hasOwnProperty,xd=Td("type",{handlers:{root:ny,element:oy,text:sy,comment:iy,doctype:ay}});function ty(e,t){const r=(t||Jx).space;return xd(e,r==="svg"?Ed:Zx)}function ny(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=Ei(e.children,n,t),On(e,n),n}function ry(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=Ei(e.children,n,t),On(e,n),n}function ay(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return On(e,t),t}function sy(e){const t={nodeName:"#text",value:e.value,parentNode:null};return On(e,t),t}function iy(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return On(e,t),t}function oy(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=Ed);const a=[];let s;if(e.properties){for(s in e.properties)if(s!=="children"&&ey.call(e.properties,s)){const l=uy(r,s,e.properties[s]);l&&a.push(l)}}const i=r.space,o={nodeName:e.tagName,tagName:e.tagName,attrs:a,namespaceURI:Ht[i],childNodes:[],parentNode:null};return o.childNodes=Ei(e.children,o,r),On(e,o),e.tagName==="template"&&e.content&&(o.content=ry(e.content,r)),o}function uy(e,t,n){const r=Xx(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?Nc(n):Pc(n));const a={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const s=a.name.indexOf(":");s<0?a.prefix="":(a.name=a.name.slice(s+1),a.prefix=r.attribute.slice(0,s)),a.namespace=Ht[r.space]}return a}function Ei(e,t,n){let r=-1;const a=[];if(e)for(;++r<e.length;){const s=xd(e[r],n);s.parentNode=t,a.push(s)}return a}function On(e,t){const n=e.position;n&&n.start&&n.end&&(n.start.offset,n.end.offset,t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const ly=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],cy=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),be="�";var b;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(b||(b={}));const Be={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function yd(e){return e>=55296&&e<=57343}function dy(e){return e>=56320&&e<=57343}function fy(e,t){return(e-55296)*1024+9216+t}function _d(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function Cd(e){return e>=64976&&e<=65007||cy.has(e)}var O;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(O||(O={}));const hy=65536;class my{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=hy,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:a,offset:s}=this,i=a+n,o=s+n;return{code:t,startLine:r,endLine:r,startCol:i,endCol:i,startOffset:o,endOffset:o}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(dy(n))return this.pos++,this._addGap(),fy(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,b.EOF;return this._err(O.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,b.EOF;const r=this.html.charCodeAt(n);return r===b.CARRIAGE_RETURN?b.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,b.EOF;let t=this.html.charCodeAt(this.pos);return t===b.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,b.LINE_FEED):t===b.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,yd(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===b.LINE_FEED||t===b.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){_d(t)?this._err(O.controlCharacterInInputStream):Cd(t)&&this._err(O.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var se;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(se||(se={}));function Ad(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const py=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏ੊ઑඡ๭༉༦჊ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ὾⁠↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms„‹•˜¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲ΂ϏϢϸontourIntegraìȹoɴ͹\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՗՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲ׌y;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱cò׋؀JTabcdfgorstר׬ׯ׺؀ؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d׷׸䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇܎ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ޷޼߂ߐĀiyޱ޵rc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄΀HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶߻dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣ঳সে্਷ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗ࡜ࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४Ānrࢃ࢏gleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpw৔ਖਛgȀLRlr৞৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼੝੠੷੼અઋ઎p;椅y;䐜Ādl੥੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑ඗ඞcy;䐊cute;䅃ƀaey઴હાron;䅇dil;䅅;䐝ƀgswે૰଎ativeƀMTV૓૟૨ediumSpace;怋hiĀcn૦૘ë૙eryThiî૙tedĀGL૸ଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷ଺reak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪୼஡௫ఄ౞಄ದ೘ൡඅ櫬Āou୛୤ngruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊ஛ement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater΀;EFGLSTஶஷ஽௉௓௘௥扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲௽ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ೒拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨೹setĀ;E೰ೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂ෉෕ෛ෠෧෼ขภยา฿ไlig;䅒cute耻Ó䃓Āiy෎ීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲ෶cr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬื฼de耻Õ䃕es;樷ml耻Ö䃖erĀBP๋๠Āar๐๓r;怾acĀek๚๜;揞et;掴arenthesis;揜Ҁacfhilors๿ງຊຏຒດຝະ໼rtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ໠໤檻cedesȀ;EST່້໏໚扺qual;檯lantEqual;扼ilde;找me;怳Ādp໩໮uct;戏ortionĀ;aȥ໹l;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬؀BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁࿫࿳ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL࿜࿝࿡憒ar;懥eftArrow;懄eiling;按oǵ࿹\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»࿝pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄ቉ቕ቞ቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHc቎ቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗Āeiቻ኉Dzኀ\0ኇefore;戴a;䎘Ācn኎ኘkSpace;쀀  Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0᏿ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0጖y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻፿on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtè૙a;䎖r;愨pf;愤cr;쀀𝒵௡ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚΀;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒΀;Eaeiop዁ᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;e዁ᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;e዁ᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰ᜼ᝃᝈ᝸᝽០៦ᠹᡐᜍ᤽᥈ᥰot;櫭Ācrᛶ᜞kȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e᜚᜛戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;t፜᜷brk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓ᝛ᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯ᝱ᝳ;䎲;愶een;扬r;쀀𝔟g΀costuvwឍឝឳេ៕៛៞ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀako៭ᠦᠵĀcn៲ᠣkƀlst៺֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘᠝斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈؀DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬ᣿ᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教΀;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ᣷᣹᣻᣽;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ᤟;敛;敘;攘;攔΀;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģ᥂bar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;e᜚᜜lƀ;bhᥨᥩᥫ䁜;槅sub;柈Ŭᥴ᥾lĀ;e᥹᥺怢t»᥺pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭍᭒\0᯽\0ᰌƀcpr᦭ᦲ᧝ute;䄇̀;abcdsᦿᧀᧄ᧊᧕᧙戩nd;橄rcup;橉Āau᧏᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r΀;Ecefms᩟᩠ᩢᩫ᪤᪪᪮旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖᪚᪟»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇᫔᫺\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ᫙\0\0᫢aĀ;t᫞᫟䀬;䁀ƀ;fl᫨᫩᫫戁îᅠeĀmx᫱᫶ent»᫩eóɍǧ᫾\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯΀delprvw᭠᭬᭷ᮂᮬᯔ᯹arrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;p᭿ᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰸᰻᰿ᱝᱩᱵᲊᲞᲬᲷ᳻᳿ᴍᵻᶑᶫᶻ᷆᷍rò΁ar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂͸᳖᳜᳠mƀ;oș᳊᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄ὎὚ĀDoḆᴴoôᲉĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»Ṻƀaeiἒ἖Ἒls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙ῜ῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao‌⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧‪‬\0‮耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₟₥₰₴⃰⃵⃺⃿℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕ₝ute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽⃉ƀ;qsؾٌ⃄lanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqr׮ⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0↎proø₞r;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢␧␭␱␵␻ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀஀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼rò৆òΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonó྘quigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d྘➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ᠛旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐௏쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop඄⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roø඄urĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓΀;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨í஘istĀ;s஠டr;쀀𝔫ȀEest௅⩦⩹⩼ƀ;qs஼⩭௡ƀ;qs஼௅⩴lanô௢ií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚΀AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs఻⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs఻⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast୻⭕⭚⭟lleì୻l;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖ΀chimpqu⮽⯍⯙⬄୸⯤⯯Ȁ;cerല⯆ഷ⯉uå൅;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭å೸åഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñ೗Ā;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰⳴ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥ⵲ⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;c᪞ⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācr⵩⵭ir;榿;쀀𝔬ͯ⵹\0\0⵼\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕ⶘ⶥⶨrò᪀Āir⶝ⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔ⷗ǒr;榷rp;榹΀;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ⹞\0⹽\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ⹧⹲຅脀¶;l⹭⹮䂶leìЃɩ⹸\0\0⹻m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳⻴ᤈ⻹⻽⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp໬⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t໻⾴ï໻rel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⿚⋢⿟⿥⿫⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei⿾々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔઀ABHabcdefhilmnoprstux぀けさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤΀cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstw࿜ガクシスゼゾダッデナp;極Ā;f࿠ゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes㄂㄄;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ì࿲âヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘㇤㇮rrowĀ;t࿜ㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowó࿪arpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓rò࿪aòՑ;怏oustĀ;a㈞㈟掱che»㈟mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦΀Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼਴t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì⹯耻­䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;q኱ኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫ਩war;椪lig耻ß䃟௡㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rë๟ƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproø዁im»ኬsðኞĀas㚺㚮ð዁rn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈ΀adempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xô᝷headĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜΀eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roð໻tré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚΀cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜ៟tré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),gy=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function by(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=gy.get(e))!==null&&t!==void 0?t:e}var Se;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(Se||(Se={}));const Ey=32;var Ot;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Ot||(Ot={}));function As(e){return e>=Se.ZERO&&e<=Se.NINE}function Ty(e){return e>=Se.UPPER_A&&e<=Se.UPPER_F||e>=Se.LOWER_A&&e<=Se.LOWER_F}function xy(e){return e>=Se.UPPER_A&&e<=Se.UPPER_Z||e>=Se.LOWER_A&&e<=Se.LOWER_Z||As(e)}function yy(e){return e===Se.EQUALS||xy(e)}var Ae;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(Ae||(Ae={}));var xt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(xt||(xt={}));class _y{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Ae.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=xt.Strict}startEntity(t){this.decodeMode=t,this.state=Ae.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Ae.EntityStart:return t.charCodeAt(n)===Se.NUM?(this.state=Ae.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Ae.NamedEntity,this.stateNamedEntity(t,n));case Ae.NumericStart:return this.stateNumericStart(t,n);case Ae.NumericDecimal:return this.stateNumericDecimal(t,n);case Ae.NumericHex:return this.stateNumericHex(t,n);case Ae.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|Ey)===Se.LOWER_X?(this.state=Ae.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Ae.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,a){if(n!==r){const s=r-n;this.result=this.result*Math.pow(a,s)+Number.parseInt(t.substr(n,s),a),this.consumed+=s}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const a=t.charCodeAt(n);if(As(a)||Ty(a))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(a,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const a=t.charCodeAt(n);if(As(a))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(a,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===Se.SEMI)this.consumed+=1;else if(this.decodeMode===xt.Strict)return 0;return this.emitCodePoint(by(this.result),this.consumed),this.errors&&(t!==Se.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let a=r[this.treeIndex],s=(a&Ot.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const i=t.charCodeAt(n);if(this.treeIndex=Cy(r,a,this.treeIndex+Math.max(1,s),i),this.treeIndex<0)return this.result===0||this.decodeMode===xt.Attribute&&(s===0||yy(i))?0:this.emitNotTerminatedNamedEntity();if(a=r[this.treeIndex],s=(a&Ot.VALUE_LENGTH)>>14,s!==0){if(i===Se.SEMI)return this.emitNamedEntityData(this.treeIndex,s,this.consumed+this.excess);this.decodeMode!==xt.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,a=(r[n]&Ot.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,a,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:a}=this;return this.emitCodePoint(n===1?a[t]&~Ot.VALUE_LENGTH:a[t+1],r),n===3&&this.emitCodePoint(a[t+2],r),r}end(){var t;switch(this.state){case Ae.NamedEntity:return this.result!==0&&(this.decodeMode!==xt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Ae.NumericDecimal:return this.emitNumericEntity(0,2);case Ae.NumericHex:return this.emitNumericEntity(0,3);case Ae.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Ae.EntityStart:return 0}}}function Cy(e,t,n,r){const a=(t&Ot.BRANCH_LENGTH)>>7,s=t&Ot.JUMP_TABLE;if(a===0)return s!==0&&r===s?n:-1;if(s){const l=r-s;return l<0||l>=a?-1:e[n+l]-1}let i=n,o=i+a-1;for(;i<=o;){const l=i+o>>>1,c=e[l];if(c<r)i=l+1;else if(c>r)o=l-1;else return e[l+a]}return-1}var H;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(H||(H={}));var Ut;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Ut||(Ut={}));var Qe;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(Qe||(Qe={}));var w;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(w||(w={}));var u;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(u||(u={}));const Ay=new Map([[w.A,u.A],[w.ADDRESS,u.ADDRESS],[w.ANNOTATION_XML,u.ANNOTATION_XML],[w.APPLET,u.APPLET],[w.AREA,u.AREA],[w.ARTICLE,u.ARTICLE],[w.ASIDE,u.ASIDE],[w.B,u.B],[w.BASE,u.BASE],[w.BASEFONT,u.BASEFONT],[w.BGSOUND,u.BGSOUND],[w.BIG,u.BIG],[w.BLOCKQUOTE,u.BLOCKQUOTE],[w.BODY,u.BODY],[w.BR,u.BR],[w.BUTTON,u.BUTTON],[w.CAPTION,u.CAPTION],[w.CENTER,u.CENTER],[w.CODE,u.CODE],[w.COL,u.COL],[w.COLGROUP,u.COLGROUP],[w.DD,u.DD],[w.DESC,u.DESC],[w.DETAILS,u.DETAILS],[w.DIALOG,u.DIALOG],[w.DIR,u.DIR],[w.DIV,u.DIV],[w.DL,u.DL],[w.DT,u.DT],[w.EM,u.EM],[w.EMBED,u.EMBED],[w.FIELDSET,u.FIELDSET],[w.FIGCAPTION,u.FIGCAPTION],[w.FIGURE,u.FIGURE],[w.FONT,u.FONT],[w.FOOTER,u.FOOTER],[w.FOREIGN_OBJECT,u.FOREIGN_OBJECT],[w.FORM,u.FORM],[w.FRAME,u.FRAME],[w.FRAMESET,u.FRAMESET],[w.H1,u.H1],[w.H2,u.H2],[w.H3,u.H3],[w.H4,u.H4],[w.H5,u.H5],[w.H6,u.H6],[w.HEAD,u.HEAD],[w.HEADER,u.HEADER],[w.HGROUP,u.HGROUP],[w.HR,u.HR],[w.HTML,u.HTML],[w.I,u.I],[w.IMG,u.IMG],[w.IMAGE,u.IMAGE],[w.INPUT,u.INPUT],[w.IFRAME,u.IFRAME],[w.KEYGEN,u.KEYGEN],[w.LABEL,u.LABEL],[w.LI,u.LI],[w.LINK,u.LINK],[w.LISTING,u.LISTING],[w.MAIN,u.MAIN],[w.MALIGNMARK,u.MALIGNMARK],[w.MARQUEE,u.MARQUEE],[w.MATH,u.MATH],[w.MENU,u.MENU],[w.META,u.META],[w.MGLYPH,u.MGLYPH],[w.MI,u.MI],[w.MO,u.MO],[w.MN,u.MN],[w.MS,u.MS],[w.MTEXT,u.MTEXT],[w.NAV,u.NAV],[w.NOBR,u.NOBR],[w.NOFRAMES,u.NOFRAMES],[w.NOEMBED,u.NOEMBED],[w.NOSCRIPT,u.NOSCRIPT],[w.OBJECT,u.OBJECT],[w.OL,u.OL],[w.OPTGROUP,u.OPTGROUP],[w.OPTION,u.OPTION],[w.P,u.P],[w.PARAM,u.PARAM],[w.PLAINTEXT,u.PLAINTEXT],[w.PRE,u.PRE],[w.RB,u.RB],[w.RP,u.RP],[w.RT,u.RT],[w.RTC,u.RTC],[w.RUBY,u.RUBY],[w.S,u.S],[w.SCRIPT,u.SCRIPT],[w.SEARCH,u.SEARCH],[w.SECTION,u.SECTION],[w.SELECT,u.SELECT],[w.SOURCE,u.SOURCE],[w.SMALL,u.SMALL],[w.SPAN,u.SPAN],[w.STRIKE,u.STRIKE],[w.STRONG,u.STRONG],[w.STYLE,u.STYLE],[w.SUB,u.SUB],[w.SUMMARY,u.SUMMARY],[w.SUP,u.SUP],[w.TABLE,u.TABLE],[w.TBODY,u.TBODY],[w.TEMPLATE,u.TEMPLATE],[w.TEXTAREA,u.TEXTAREA],[w.TFOOT,u.TFOOT],[w.TD,u.TD],[w.TH,u.TH],[w.THEAD,u.THEAD],[w.TITLE,u.TITLE],[w.TR,u.TR],[w.TRACK,u.TRACK],[w.TT,u.TT],[w.U,u.U],[w.UL,u.UL],[w.SVG,u.SVG],[w.VAR,u.VAR],[w.WBR,u.WBR],[w.XMP,u.XMP]]);function Rn(e){var t;return(t=Ay.get(e))!==null&&t!==void 0?t:u.UNKNOWN}const j=u,Sy={[H.HTML]:new Set([j.ADDRESS,j.APPLET,j.AREA,j.ARTICLE,j.ASIDE,j.BASE,j.BASEFONT,j.BGSOUND,j.BLOCKQUOTE,j.BODY,j.BR,j.BUTTON,j.CAPTION,j.CENTER,j.COL,j.COLGROUP,j.DD,j.DETAILS,j.DIR,j.DIV,j.DL,j.DT,j.EMBED,j.FIELDSET,j.FIGCAPTION,j.FIGURE,j.FOOTER,j.FORM,j.FRAME,j.FRAMESET,j.H1,j.H2,j.H3,j.H4,j.H5,j.H6,j.HEAD,j.HEADER,j.HGROUP,j.HR,j.HTML,j.IFRAME,j.IMG,j.INPUT,j.LI,j.LINK,j.LISTING,j.MAIN,j.MARQUEE,j.MENU,j.META,j.NAV,j.NOEMBED,j.NOFRAMES,j.NOSCRIPT,j.OBJECT,j.OL,j.P,j.PARAM,j.PLAINTEXT,j.PRE,j.SCRIPT,j.SECTION,j.SELECT,j.SOURCE,j.STYLE,j.SUMMARY,j.TABLE,j.TBODY,j.TD,j.TEMPLATE,j.TEXTAREA,j.TFOOT,j.TH,j.THEAD,j.TITLE,j.TR,j.TRACK,j.UL,j.WBR,j.XMP]),[H.MATHML]:new Set([j.MI,j.MO,j.MN,j.MS,j.MTEXT,j.ANNOTATION_XML]),[H.SVG]:new Set([j.TITLE,j.FOREIGN_OBJECT,j.DESC]),[H.XLINK]:new Set,[H.XML]:new Set,[H.XMLNS]:new Set},Ss=new Set([j.H1,j.H2,j.H3,j.H4,j.H5,j.H6]);w.STYLE,w.SCRIPT,w.XMP,w.IFRAME,w.NOEMBED,w.NOFRAMES,w.PLAINTEXT;var T;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(T||(T={}));const Te={DATA:T.DATA,RCDATA:T.RCDATA,RAWTEXT:T.RAWTEXT,SCRIPT_DATA:T.SCRIPT_DATA,PLAINTEXT:T.PLAINTEXT,CDATA_SECTION:T.CDATA_SECTION};function Ny(e){return e>=b.DIGIT_0&&e<=b.DIGIT_9}function Wn(e){return e>=b.LATIN_CAPITAL_A&&e<=b.LATIN_CAPITAL_Z}function Iy(e){return e>=b.LATIN_SMALL_A&&e<=b.LATIN_SMALL_Z}function wt(e){return Iy(e)||Wn(e)}function su(e){return wt(e)||Ny(e)}function kr(e){return e+32}function Sd(e){return e===b.SPACE||e===b.LINE_FEED||e===b.TABULATION||e===b.FORM_FEED}function iu(e){return Sd(e)||e===b.SOLIDUS||e===b.GREATER_THAN_SIGN}function vy(e){return e===b.NULL?O.nullCharacterReference:e>1114111?O.characterReferenceOutsideUnicodeRange:yd(e)?O.surrogateCharacterReference:Cd(e)?O.noncharacterCharacterReference:_d(e)||e===b.CARRIAGE_RETURN?O.controlCharacterReference:null}class wy{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=T.DATA,this.returnState=T.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new my(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new _y(py,(r,a)=>{this.preprocessor.pos=this.entityStartPos+a-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(O.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(O.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const a=vy(r);a&&this._err(a,1)}}:void 0)}_err(t,n=0){var r,a;(a=(r=this.handler).onParseError)===null||a===void 0||a.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t?.())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r?.()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:se.START_TAG,tagName:"",tagID:u.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:se.END_TAG,tagName:"",tagID:u.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:se.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:se.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(Ad(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const a=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);a[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(O.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=Rn(t.tagName),t.type===se.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(O.endTagWithAttributes),t.selfClosing&&this._err(O.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case se.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case se.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case se.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:se.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=Sd(t)?se.WHITESPACE_CHARACTER:t===b.NULL?se.NULL_CHARACTER:se.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(se.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=T.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?xt.Attribute:xt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===T.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===T.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case T.DATA:{this._stateData(t);break}case T.RCDATA:{this._stateRcdata(t);break}case T.RAWTEXT:{this._stateRawtext(t);break}case T.SCRIPT_DATA:{this._stateScriptData(t);break}case T.PLAINTEXT:{this._statePlaintext(t);break}case T.TAG_OPEN:{this._stateTagOpen(t);break}case T.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case T.TAG_NAME:{this._stateTagName(t);break}case T.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case T.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case T.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case T.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case T.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case T.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case T.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case T.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case T.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case T.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case T.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case T.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case T.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case T.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case T.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case T.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case T.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case T.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case T.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case T.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case T.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case T.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case T.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case T.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case T.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case T.BOGUS_COMMENT:{this._stateBogusComment(t);break}case T.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case T.COMMENT_START:{this._stateCommentStart(t);break}case T.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case T.COMMENT:{this._stateComment(t);break}case T.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case T.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case T.COMMENT_END:{this._stateCommentEnd(t);break}case T.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case T.DOCTYPE:{this._stateDoctype(t);break}case T.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case T.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case T.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case T.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case T.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case T.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case T.CDATA_SECTION:{this._stateCdataSection(t);break}case T.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case T.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case T.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case T.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.TAG_OPEN;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitCodePoint(t);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case b.AMPERSAND:{this._startCharacterReference();break}case b.LESS_THAN_SIGN:{this.state=T.RCDATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.RAWTEXT_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(wt(t))this._createStartTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.EXCLAMATION_MARK:{this.state=T.MARKUP_DECLARATION_OPEN;break}case b.SOLIDUS:{this.state=T.END_TAG_OPEN;break}case b.QUESTION_MARK:{this._err(O.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t);break}case b.EOF:{this._err(O.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(O.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=T.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(wt(t))this._createEndTagToken(),this.state=T.TAG_NAME,this._stateTagName(t);else switch(t){case b.GREATER_THAN_SIGN:{this._err(O.missingEndTagName),this.state=T.DATA;break}case b.EOF:{this._err(O.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(O.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.tagName+=be;break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Wn(t)?kr(t):t)}}_stateRcdataLessThanSign(t){t===b.SOLIDUS?this.state=T.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){wt(t)?(this.state=T.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=T.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=T.BEFORE_ATTRIBUTE_NAME,!1;case b.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=T.SELF_CLOSING_START_TAG,!1;case b.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=T.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===b.SOLIDUS?this.state=T.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){wt(t)?(this.state=T.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case b.SOLIDUS:{this.state=T.SCRIPT_DATA_END_TAG_OPEN;break}case b.EXCLAMATION_MARK:{this.state=T.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=T.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){wt(t)?(this.state=T.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===b.HYPHEN_MINUS?(this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=T.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_ESCAPED,this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===b.SOLIDUS?this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:wt(t)?(this._emitChars("<"),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){wt(t)?(this.state=T.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(Be.SCRIPT,!1)&&iu(this.preprocessor.peek(Be.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Be.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(O.unexpectedNullCharacter),this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case b.HYPHEN_MINUS:{this._emitChars("-");break}case b.LESS_THAN_SIGN:{this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case b.GREATER_THAN_SIGN:{this.state=T.SCRIPT_DATA,this._emitChars(">");break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(be);break}case b.EOF:{this._err(O.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===b.SOLIDUS?(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(Be.SCRIPT,!1)&&iu(this.preprocessor.peek(Be.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<Be.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=T.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=T.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._err(O.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=T.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:case b.SOLIDUS:case b.GREATER_THAN_SIGN:case b.EOF:{this._leaveAttrName(),this.state=T.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case b.EQUALS_SIGN:{this._leaveAttrName(),this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:{this._err(O.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.currentAttr.name+=be;break}default:this.currentAttr.name+=String.fromCodePoint(Wn(t)?kr(t):t)}}_stateAfterAttributeName(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.SOLIDUS:{this.state=T.SELF_CLOSING_START_TAG;break}case b.EQUALS_SIGN:{this.state=T.BEFORE_ATTRIBUTE_VALUE;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=T.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{this.state=T.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this.state=T.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(O.missingAttributeValue),this.state=T.DATA,this.emitCurrentTagToken();break}default:this.state=T.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.currentAttr.value+=be;break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case b.APOSTROPHE:{this.state=T.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.currentAttr.value+=be;break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.AMPERSAND:{this._startCharacterReference();break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.NULL:{this._err(O.unexpectedNullCharacter),this.currentAttr.value+=be;break}case b.QUOTATION_MARK:case b.APOSTROPHE:case b.LESS_THAN_SIGN:case b.EQUALS_SIGN:case b.GRAVE_ACCENT:{this._err(O.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this._leaveAttrValue(),this.state=T.BEFORE_ATTRIBUTE_NAME;break}case b.SOLIDUS:{this._leaveAttrValue(),this.state=T.SELF_CLOSING_START_TAG;break}case b.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this._err(O.missingWhitespaceBetweenAttributes),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case b.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=T.DATA,this.emitCurrentTagToken();break}case b.EOF:{this._err(O.eofInTag),this._emitEOFToken();break}default:this._err(O.unexpectedSolidusInTag),this.state=T.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.data+=be;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(Be.DASH_DASH,!0)?(this._createCommentToken(Be.DASH_DASH.length+1),this.state=T.COMMENT_START):this._consumeSequenceIfMatch(Be.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(Be.DOCTYPE.length+1),this.state=T.DOCTYPE):this._consumeSequenceIfMatch(Be.CDATA_START,!0)?this.inForeignNode?this.state=T.CDATA_SECTION:(this._err(O.cdataInHtmlContent),this._createCommentToken(Be.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=T.BOGUS_COMMENT):this._ensureHibernation()||(this._err(O.incorrectlyOpenedComment),this._createCommentToken(2),this.state=T.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_START_DASH;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptClosingOfEmptyComment),this.state=T.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptClosingOfEmptyComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(O.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END_DASH;break}case b.LESS_THAN_SIGN:{n.data+="<",this.state=T.COMMENT_LESS_THAN_SIGN;break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.data+=be;break}case b.EOF:{this._err(O.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case b.EXCLAMATION_MARK:{n.data+="!",this.state=T.COMMENT_LESS_THAN_SIGN_BANG;break}case b.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=T.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=T.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===b.HYPHEN_MINUS?this.state=T.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=T.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==b.GREATER_THAN_SIGN&&t!==b.EOF&&this._err(O.nestedComment),this.state=T.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{this.state=T.COMMENT_END;break}case b.EOF:{this._err(O.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentComment(n);break}case b.EXCLAMATION_MARK:{this.state=T.COMMENT_END_BANG;break}case b.HYPHEN_MINUS:{n.data+="-";break}case b.EOF:{this._err(O.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=T.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case b.HYPHEN_MINUS:{n.data+="--!",this.state=T.COMMENT_END_DASH;break}case b.GREATER_THAN_SIGN:{this._err(O.incorrectlyClosedComment),this.state=T.DATA,this.emitCurrentComment(n);break}case b.EOF:{this._err(O.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=T.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case b.EOF:{this._err(O.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingWhitespaceBeforeDoctypeName),this.state=T.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Wn(t))this._createDoctypeToken(String.fromCharCode(kr(t))),this.state=T.DOCTYPE_NAME;else switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.NULL:{this._err(O.unexpectedNullCharacter),this._createDoctypeToken(be),this.state=T.DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this._err(O.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=T.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.AFTER_DOCTYPE_NAME;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.name+=be;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Wn(t)?kr(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(Be.PUBLIC,!1)?this.state=T.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(Be.SYSTEM,!1)?this.state=T.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(O.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(O.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(O.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(O.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.publicId="",this.state=T.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(O.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.publicId+=be;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.publicId+=be;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case b.GREATER_THAN_SIGN:{this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.QUOTATION_MARK:{this._err(O.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(O.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:{this.state=T.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.QUOTATION_MARK:{this._err(O.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{this._err(O.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(O.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.QUOTATION_MARK:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case b.APOSTROPHE:{n.systemId="",this.state=T.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case b.GREATER_THAN_SIGN:{this._err(O.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.DATA,this.emitCurrentDoctype(n);break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case b.QUOTATION_MARK:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.systemId+=be;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case b.APOSTROPHE:{this.state=T.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case b.NULL:{this._err(O.unexpectedNullCharacter),n.systemId+=be;break}case b.GREATER_THAN_SIGN:{this._err(O.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case b.SPACE:case b.LINE_FEED:case b.TABULATION:case b.FORM_FEED:break;case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.EOF:{this._err(O.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(O.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=T.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case b.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=T.DATA;break}case b.NULL:{this._err(O.unexpectedNullCharacter);break}case b.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case b.RIGHT_SQUARE_BRACKET:{this.state=T.CDATA_SECTION_BRACKET;break}case b.EOF:{this._err(O.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===b.RIGHT_SQUARE_BRACKET?this.state=T.CDATA_SECTION_END:(this._emitChars("]"),this.state=T.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case b.GREATER_THAN_SIGN:{this.state=T.DATA;break}case b.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=T.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(b.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&su(this.preprocessor.peek(1))?T.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){su(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===b.SEMICOLON&&this._err(O.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const Nd=new Set([u.DD,u.DT,u.LI,u.OPTGROUP,u.OPTION,u.P,u.RB,u.RP,u.RT,u.RTC]),ou=new Set([...Nd,u.CAPTION,u.COLGROUP,u.TBODY,u.TD,u.TFOOT,u.TH,u.THEAD,u.TR]),$r=new Set([u.APPLET,u.CAPTION,u.HTML,u.MARQUEE,u.OBJECT,u.TABLE,u.TD,u.TEMPLATE,u.TH]),ky=new Set([...$r,u.OL,u.UL]),Oy=new Set([...$r,u.BUTTON]),uu=new Set([u.ANNOTATION_XML,u.MI,u.MN,u.MO,u.MS,u.MTEXT]),lu=new Set([u.DESC,u.FOREIGN_OBJECT,u.TITLE]),Ry=new Set([u.TR,u.TEMPLATE,u.HTML]),Ly=new Set([u.TBODY,u.TFOOT,u.THEAD,u.TEMPLATE,u.HTML]),Py=new Set([u.TABLE,u.TEMPLATE,u.HTML]),Dy=new Set([u.TD,u.TH]);class My{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=u.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===u.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===H.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const a=this._indexOf(t)+1;this.items.splice(a,0,n),this.tagIDs.splice(a,0,r),this.stackTop++,a===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,a===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==H.HTML);this.shortenToLength(Math.max(n,0))}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(Math.max(n,0))}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(Math.max(r,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(Ss,H.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Dy,H.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(Py,H.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Ly,H.HTML)}clearBackToTableRowContext(){this.clearBackTo(Ry,H.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===u.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===u.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const a=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case H.HTML:{if(a===t)return!0;if(n.has(a))return!1;break}case H.SVG:{if(lu.has(a))return!1;break}case H.MATHML:{if(uu.has(a))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,$r)}hasInListItemScope(t){return this.hasInDynamicScope(t,ky)}hasInButtonScope(t){return this.hasInDynamicScope(t,Oy)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case H.HTML:{if(Ss.has(n))return!0;if($r.has(n))return!1;break}case H.SVG:{if(lu.has(n))return!1;break}case H.MATHML:{if(uu.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===H.HTML)switch(this.tagIDs[n]){case t:return!0;case u.TABLE:case u.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===H.HTML)switch(this.tagIDs[t]){case u.TBODY:case u.THEAD:case u.TFOOT:return!0;case u.TABLE:case u.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===H.HTML)switch(this.tagIDs[n]){case t:return!0;case u.OPTION:case u.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&Nd.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&ou.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&ou.has(this.currentTagId);)this.pop()}}const Xa=3;var ut;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(ut||(ut={}));const cu={type:ut.Marker};class By{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],a=n.length,s=this.treeAdapter.getTagName(t),i=this.treeAdapter.getNamespaceURI(t);for(let o=0;o<this.entries.length;o++){const l=this.entries[o];if(l.type===ut.Marker)break;const{element:c}=l;if(this.treeAdapter.getTagName(c)===s&&this.treeAdapter.getNamespaceURI(c)===i){const d=this.treeAdapter.getAttrList(c);d.length===a&&r.push({idx:o,attrs:d})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<Xa)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<Xa)return;const a=new Map(n.map(i=>[i.name,i.value]));let s=0;for(let i=0;i<r.length;i++){const o=r[i];o.attrs.every(l=>a.get(l.name)===l.value)&&(s+=1,s>=Xa&&this.entries.splice(o.idx,1))}}insertMarker(){this.entries.unshift(cu)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:ut.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:ut.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(cu);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===ut.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===ut.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===ut.Element&&n.element===t)}}const kt={createDocument(){return{nodeName:"#document",mode:Qe.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const a=e.childNodes.find(s=>s.nodeName==="#documentType");if(a)a.name=t,a.publicId=n,a.systemId=r;else{const s={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};kt.appendChild(e,s)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(kt.isTextNode(n)){n.value+=t;return}}kt.appendChild(e,kt.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&kt.isTextNode(r)?r.value+=t:kt.insertBefore(e,kt.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},Id="html",Fy="about:legacy-compat",Hy="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",vd=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],Uy=[...vd,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],jy=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),wd=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],zy=[...wd,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function du(e,t){return t.some(n=>e.startsWith(n))}function Yy(e){return e.name===Id&&e.publicId===null&&(e.systemId===null||e.systemId===Fy)}function Wy(e){if(e.name!==Id)return Qe.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Hy)return Qe.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),jy.has(n))return Qe.QUIRKS;let r=t===null?Uy:vd;if(du(n,r))return Qe.QUIRKS;if(r=t===null?wd:zy,du(n,r))return Qe.LIMITED_QUIRKS}return Qe.NO_QUIRKS}const fu={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Vy="definitionurl",$y="definitionURL",qy=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),Gy=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:H.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:H.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:H.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:H.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:H.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:H.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:H.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:H.XML}],["xml:space",{prefix:"xml",name:"space",namespace:H.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:H.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:H.XMLNS}]]),Xy=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),Ky=new Set([u.B,u.BIG,u.BLOCKQUOTE,u.BODY,u.BR,u.CENTER,u.CODE,u.DD,u.DIV,u.DL,u.DT,u.EM,u.EMBED,u.H1,u.H2,u.H3,u.H4,u.H5,u.H6,u.HEAD,u.HR,u.I,u.IMG,u.LI,u.LISTING,u.MENU,u.META,u.NOBR,u.OL,u.P,u.PRE,u.RUBY,u.S,u.SMALL,u.SPAN,u.STRONG,u.STRIKE,u.SUB,u.SUP,u.TABLE,u.TT,u.U,u.UL,u.VAR]);function Qy(e){const t=e.tagID;return t===u.FONT&&e.attrs.some(({name:r})=>r===Ut.COLOR||r===Ut.SIZE||r===Ut.FACE)||Ky.has(t)}function kd(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Vy){e.attrs[t].name=$y;break}}function Od(e){for(let t=0;t<e.attrs.length;t++){const n=qy.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function Ti(e){for(let t=0;t<e.attrs.length;t++){const n=Gy.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function Zy(e){const t=Xy.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=Rn(e.tagName))}function Jy(e,t){return t===H.MATHML&&(e===u.MI||e===u.MO||e===u.MN||e===u.MS||e===u.MTEXT)}function e2(e,t,n){if(t===H.MATHML&&e===u.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Ut.ENCODING){const a=n[r].value.toLowerCase();return a===fu.TEXT_HTML||a===fu.APPLICATION_XML}}return t===H.SVG&&(e===u.FOREIGN_OBJECT||e===u.DESC||e===u.TITLE)}function t2(e,t,n,r){return(!r||r===H.HTML)&&e2(e,t,n)||(!r||r===H.MATHML)&&Jy(e,t)}const n2="hidden",r2=8,a2=3;var C;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(C||(C={}));const s2={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},Rd=new Set([u.TABLE,u.TBODY,u.TFOOT,u.THEAD,u.TR]),hu={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:kt,onParseError:null};class mu{constructor(t,n,r=null,a=null){this.fragmentContext=r,this.scriptHandler=a,this.currentToken=null,this.stopped=!1,this.insertionMode=C.INITIAL,this.originalInsertionMode=C.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...hu,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new wy(this.options,this),this.activeFormattingElements=new By(this.treeAdapter),this.fragmentContextID=r?Rn(this.treeAdapter.getTagName(r)):u.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new My(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={...hu,...n};t??(t=r.treeAdapter.createElement(w.TEMPLATE,H.HTML,[]));const a=r.treeAdapter.createElement("documentmock",H.HTML,[]),s=new this(r,a,t);return s.fragmentContextID===u.TEMPLATE&&s.tmplInsertionModeStack.unshift(C.IN_TEMPLATE),s._initTokenizerForFragmentParsing(),s._insertFakeRootElement(),s._resetInsertionMode(),s._findFormInFragmentContext(),s}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var a;if(!this.onParseError)return;const s=(a=t.location)!==null&&a!==void 0?a:s2,i={code:n,startLine:s.startLine,startCol:s.startCol,startOffset:s.startOffset,endLine:r?s.startLine:s.endLine,endCol:r?s.startCol:s.endCol,endOffset:r?s.startOffset:s.endOffset};this.onParseError(i)}onItemPush(t,n,r){var a,s;(s=(a=this.treeAdapter).onItemPush)===null||s===void 0||s.call(a,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,a;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(a=(r=this.treeAdapter).onItemPop)===null||a===void 0||a.call(r,t,this.openElements.current),n){let s,i;this.openElements.stackTop===0&&this.fragmentContext?(s=this.fragmentContext,i=this.fragmentContextID):{current:s,currentTagId:i}=this.openElements,this._setContextModes(s,i)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===H.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,H.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=C.TEXT}switchToPlaintextParsing(){this.insertionMode=C.TEXT,this.originalInsertionMode=C.IN_BODY,this.tokenizer.state=Te.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===w.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==H.HTML))switch(this.fragmentContextID){case u.TITLE:case u.TEXTAREA:{this.tokenizer.state=Te.RCDATA;break}case u.STYLE:case u.XMP:case u.IFRAME:case u.NOEMBED:case u.NOFRAMES:case u.NOSCRIPT:{this.tokenizer.state=Te.RAWTEXT;break}case u.SCRIPT:{this.tokenizer.state=Te.SCRIPT_DATA;break}case u.PLAINTEXT:{this.tokenizer.state=Te.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",a=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,a),t.location){const i=this.treeAdapter.getChildNodes(this.document).find(o=>this.treeAdapter.isDocumentTypeNode(o));i&&this.treeAdapter.setNodeSourceCodeLocation(i,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r??this.document,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,H.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,H.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(w.HTML,H.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,u.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const a=this.treeAdapter.getChildNodes(n),s=r?a.lastIndexOf(r):a.length,i=a[s-1];if(this.treeAdapter.getNodeSourceCodeLocation(i)){const{endLine:l,endCol:c,endOffset:d}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(i,{endLine:l,endCol:c,endOffset:d})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(i,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,a=this.treeAdapter.getTagName(t),s=n.type===se.END_TAG&&a===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,s)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===u.SVG&&this.treeAdapter.getTagName(n)===w.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===H.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===u.MGLYPH||t.tagID===u.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,H.HTML)}_processToken(t){switch(t.type){case se.CHARACTER:{this.onCharacter(t);break}case se.NULL_CHARACTER:{this.onNullCharacter(t);break}case se.COMMENT:{this.onComment(t);break}case se.DOCTYPE:{this.onDoctype(t);break}case se.START_TAG:{this._processStartTag(t);break}case se.END_TAG:{this.onEndTag(t);break}case se.EOF:{this.onEof(t);break}case se.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const a=this.treeAdapter.getNamespaceURI(n),s=this.treeAdapter.getAttrList(n);return t2(t,a,s,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(a=>a.type===ut.Marker||this.openElements.contains(a.element)),r=n===-1?t-1:n-1;for(let a=r;a>=0;a--){const s=this.activeFormattingElements.entries[a];this._insertElement(s.token,this.treeAdapter.getNamespaceURI(s.element)),s.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=C.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(u.P),this.openElements.popUntilTagNamePopped(u.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case u.TR:{this.insertionMode=C.IN_ROW;return}case u.TBODY:case u.THEAD:case u.TFOOT:{this.insertionMode=C.IN_TABLE_BODY;return}case u.CAPTION:{this.insertionMode=C.IN_CAPTION;return}case u.COLGROUP:{this.insertionMode=C.IN_COLUMN_GROUP;return}case u.TABLE:{this.insertionMode=C.IN_TABLE;return}case u.BODY:{this.insertionMode=C.IN_BODY;return}case u.FRAMESET:{this.insertionMode=C.IN_FRAMESET;return}case u.SELECT:{this._resetInsertionModeForSelect(t);return}case u.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case u.HTML:{this.insertionMode=this.headElement?C.AFTER_HEAD:C.BEFORE_HEAD;return}case u.TD:case u.TH:{if(t>0){this.insertionMode=C.IN_CELL;return}break}case u.HEAD:{if(t>0){this.insertionMode=C.IN_HEAD;return}break}}this.insertionMode=C.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===u.TEMPLATE)break;if(r===u.TABLE){this.insertionMode=C.IN_SELECT_IN_TABLE;return}}this.insertionMode=C.IN_SELECT}_isElementCausesFosterParenting(t){return Rd.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case u.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===H.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case u.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return Sy[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){D_(this,t);return}switch(this.insertionMode){case C.INITIAL:{jn(this,t);break}case C.BEFORE_HTML:{Kn(this,t);break}case C.BEFORE_HEAD:{Qn(this,t);break}case C.IN_HEAD:{Zn(this,t);break}case C.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case C.AFTER_HEAD:{er(this,t);break}case C.IN_BODY:case C.IN_CAPTION:case C.IN_CELL:case C.IN_TEMPLATE:{Pd(this,t);break}case C.TEXT:case C.IN_SELECT:case C.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case C.IN_TABLE:case C.IN_TABLE_BODY:case C.IN_ROW:{Ka(this,t);break}case C.IN_TABLE_TEXT:{Ud(this,t);break}case C.IN_COLUMN_GROUP:{qr(this,t);break}case C.AFTER_BODY:{Gr(this,t);break}case C.AFTER_AFTER_BODY:{Br(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){P_(this,t);return}switch(this.insertionMode){case C.INITIAL:{jn(this,t);break}case C.BEFORE_HTML:{Kn(this,t);break}case C.BEFORE_HEAD:{Qn(this,t);break}case C.IN_HEAD:{Zn(this,t);break}case C.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case C.AFTER_HEAD:{er(this,t);break}case C.TEXT:{this._insertCharacters(t);break}case C.IN_TABLE:case C.IN_TABLE_BODY:case C.IN_ROW:{Ka(this,t);break}case C.IN_COLUMN_GROUP:{qr(this,t);break}case C.AFTER_BODY:{Gr(this,t);break}case C.AFTER_AFTER_BODY:{Br(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){Ns(this,t);return}switch(this.insertionMode){case C.INITIAL:case C.BEFORE_HTML:case C.BEFORE_HEAD:case C.IN_HEAD:case C.IN_HEAD_NO_SCRIPT:case C.AFTER_HEAD:case C.IN_BODY:case C.IN_TABLE:case C.IN_CAPTION:case C.IN_COLUMN_GROUP:case C.IN_TABLE_BODY:case C.IN_ROW:case C.IN_CELL:case C.IN_SELECT:case C.IN_SELECT_IN_TABLE:case C.IN_TEMPLATE:case C.IN_FRAMESET:case C.AFTER_FRAMESET:{Ns(this,t);break}case C.IN_TABLE_TEXT:{zn(this,t);break}case C.AFTER_BODY:{f2(this,t);break}case C.AFTER_AFTER_BODY:case C.AFTER_AFTER_FRAMESET:{h2(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case C.INITIAL:{m2(this,t);break}case C.BEFORE_HEAD:case C.IN_HEAD:case C.IN_HEAD_NO_SCRIPT:case C.AFTER_HEAD:{this._err(t,O.misplacedDoctype);break}case C.IN_TABLE_TEXT:{zn(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,O.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?M_(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case C.INITIAL:{jn(this,t);break}case C.BEFORE_HTML:{p2(this,t);break}case C.BEFORE_HEAD:{b2(this,t);break}case C.IN_HEAD:{st(this,t);break}case C.IN_HEAD_NO_SCRIPT:{x2(this,t);break}case C.AFTER_HEAD:{_2(this,t);break}case C.IN_BODY:{ve(this,t);break}case C.IN_TABLE:{En(this,t);break}case C.IN_TABLE_TEXT:{zn(this,t);break}case C.IN_CAPTION:{E_(this,t);break}case C.IN_COLUMN_GROUP:{_i(this,t);break}case C.IN_TABLE_BODY:{Ta(this,t);break}case C.IN_ROW:{xa(this,t);break}case C.IN_CELL:{y_(this,t);break}case C.IN_SELECT:{Yd(this,t);break}case C.IN_SELECT_IN_TABLE:{C_(this,t);break}case C.IN_TEMPLATE:{S_(this,t);break}case C.AFTER_BODY:{I_(this,t);break}case C.IN_FRAMESET:{v_(this,t);break}case C.AFTER_FRAMESET:{k_(this,t);break}case C.AFTER_AFTER_BODY:{R_(this,t);break}case C.AFTER_AFTER_FRAMESET:{L_(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?B_(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case C.INITIAL:{jn(this,t);break}case C.BEFORE_HTML:{g2(this,t);break}case C.BEFORE_HEAD:{E2(this,t);break}case C.IN_HEAD:{T2(this,t);break}case C.IN_HEAD_NO_SCRIPT:{y2(this,t);break}case C.AFTER_HEAD:{C2(this,t);break}case C.IN_BODY:{Ea(this,t);break}case C.TEXT:{u_(this,t);break}case C.IN_TABLE:{ir(this,t);break}case C.IN_TABLE_TEXT:{zn(this,t);break}case C.IN_CAPTION:{T_(this,t);break}case C.IN_COLUMN_GROUP:{x_(this,t);break}case C.IN_TABLE_BODY:{Is(this,t);break}case C.IN_ROW:{zd(this,t);break}case C.IN_CELL:{__(this,t);break}case C.IN_SELECT:{Wd(this,t);break}case C.IN_SELECT_IN_TABLE:{A_(this,t);break}case C.IN_TEMPLATE:{N_(this,t);break}case C.AFTER_BODY:{$d(this,t);break}case C.IN_FRAMESET:{w_(this,t);break}case C.AFTER_FRAMESET:{O_(this,t);break}case C.AFTER_AFTER_BODY:{Br(this,t);break}}}onEof(t){switch(this.insertionMode){case C.INITIAL:{jn(this,t);break}case C.BEFORE_HTML:{Kn(this,t);break}case C.BEFORE_HEAD:{Qn(this,t);break}case C.IN_HEAD:{Zn(this,t);break}case C.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case C.AFTER_HEAD:{er(this,t);break}case C.IN_BODY:case C.IN_TABLE:case C.IN_CAPTION:case C.IN_COLUMN_GROUP:case C.IN_TABLE_BODY:case C.IN_ROW:case C.IN_CELL:case C.IN_SELECT:case C.IN_SELECT_IN_TABLE:{Fd(this,t);break}case C.TEXT:{l_(this,t);break}case C.IN_TABLE_TEXT:{zn(this,t);break}case C.IN_TEMPLATE:{Vd(this,t);break}case C.AFTER_BODY:case C.IN_FRAMESET:case C.AFTER_FRAMESET:case C.AFTER_AFTER_BODY:case C.AFTER_AFTER_FRAMESET:{yi(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===b.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case C.IN_HEAD:case C.IN_HEAD_NO_SCRIPT:case C.AFTER_HEAD:case C.TEXT:case C.IN_COLUMN_GROUP:case C.IN_SELECT:case C.IN_SELECT_IN_TABLE:case C.IN_FRAMESET:case C.AFTER_FRAMESET:{this._insertCharacters(t);break}case C.IN_BODY:case C.IN_CAPTION:case C.IN_CELL:case C.IN_TEMPLATE:case C.AFTER_BODY:case C.AFTER_AFTER_BODY:case C.AFTER_AFTER_FRAMESET:{Ld(this,t);break}case C.IN_TABLE:case C.IN_TABLE_BODY:case C.IN_ROW:{Ka(this,t);break}case C.IN_TABLE_TEXT:{Hd(this,t);break}}}}function i2(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):Bd(e,t),n}function o2(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const a=e.openElements.items[r];if(a===t.element)break;e._isSpecialElement(a,e.openElements.tagIDs[r])&&(n=a)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function u2(e,t,n){let r=t,a=e.openElements.getCommonAncestor(t);for(let s=0,i=a;i!==n;s++,i=a){a=e.openElements.getCommonAncestor(i);const o=e.activeFormattingElements.getElementEntry(i),l=o&&s>=a2;!o||l?(l&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(i)):(i=l2(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(i,r),r=i)}return r}function l2(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function c2(e,t,n){const r=e.treeAdapter.getTagName(t),a=Rn(r);if(e._isElementCausesFosterParenting(a))e._fosterParentElement(n);else{const s=e.treeAdapter.getNamespaceURI(t);a===u.TEMPLATE&&s===H.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function d2(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:a}=n,s=e.treeAdapter.createElement(a.tagName,r,a.attrs);e._adoptNodes(t,s),e.treeAdapter.appendChild(t,s),e.activeFormattingElements.insertElementAfterBookmark(s,a),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,s,a.tagID)}function xi(e,t){for(let n=0;n<r2;n++){const r=i2(e,t);if(!r)break;const a=o2(e,r);if(!a)break;e.activeFormattingElements.bookmark=r;const s=u2(e,a,r.element),i=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(s),i&&c2(e,i,s),d2(e,a,r)}}function Ns(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function f2(e,t){e._appendCommentNode(t,e.openElements.items[0])}function h2(e,t){e._appendCommentNode(t,e.document)}function yi(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],a=e.treeAdapter.getNodeSourceCodeLocation(r);if(a&&!a.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const s=e.openElements.items[1],i=e.treeAdapter.getNodeSourceCodeLocation(s);i&&!i.endTag&&e._setEndLocation(s,t)}}}}function m2(e,t){e._setDocumentType(t);const n=t.forceQuirks?Qe.QUIRKS:Wy(t);Yy(t)||e._err(t,O.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=C.BEFORE_HTML}function jn(e,t){e._err(t,O.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,Qe.QUIRKS),e.insertionMode=C.BEFORE_HTML,e._processToken(t)}function p2(e,t){t.tagID===u.HTML?(e._insertElement(t,H.HTML),e.insertionMode=C.BEFORE_HEAD):Kn(e,t)}function g2(e,t){const n=t.tagID;(n===u.HTML||n===u.HEAD||n===u.BODY||n===u.BR)&&Kn(e,t)}function Kn(e,t){e._insertFakeRootElement(),e.insertionMode=C.BEFORE_HEAD,e._processToken(t)}function b2(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.HEAD:{e._insertElement(t,H.HTML),e.headElement=e.openElements.current,e.insertionMode=C.IN_HEAD;break}default:Qn(e,t)}}function E2(e,t){const n=t.tagID;n===u.HEAD||n===u.BODY||n===u.HTML||n===u.BR?Qn(e,t):e._err(t,O.endTagWithoutMatchingOpenElement)}function Qn(e,t){e._insertFakeElement(w.HEAD,u.HEAD),e.headElement=e.openElements.current,e.insertionMode=C.IN_HEAD,e._processToken(t)}function st(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.BASE:case u.BASEFONT:case u.BGSOUND:case u.LINK:case u.META:{e._appendElement(t,H.HTML),t.ackSelfClosing=!0;break}case u.TITLE:{e._switchToTextParsing(t,Te.RCDATA);break}case u.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Te.RAWTEXT):(e._insertElement(t,H.HTML),e.insertionMode=C.IN_HEAD_NO_SCRIPT);break}case u.NOFRAMES:case u.STYLE:{e._switchToTextParsing(t,Te.RAWTEXT);break}case u.SCRIPT:{e._switchToTextParsing(t,Te.SCRIPT_DATA);break}case u.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=C.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(C.IN_TEMPLATE);break}case u.HEAD:{e._err(t,O.misplacedStartTagForHeadElement);break}default:Zn(e,t)}}function T2(e,t){switch(t.tagID){case u.HEAD:{e.openElements.pop(),e.insertionMode=C.AFTER_HEAD;break}case u.BODY:case u.BR:case u.HTML:{Zn(e,t);break}case u.TEMPLATE:{Kt(e,t);break}default:e._err(t,O.endTagWithoutMatchingOpenElement)}}function Kt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==u.TEMPLATE&&e._err(t,O.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(u.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,O.endTagWithoutMatchingOpenElement)}function Zn(e,t){e.openElements.pop(),e.insertionMode=C.AFTER_HEAD,e._processToken(t)}function x2(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.BASEFONT:case u.BGSOUND:case u.HEAD:case u.LINK:case u.META:case u.NOFRAMES:case u.STYLE:{st(e,t);break}case u.NOSCRIPT:{e._err(t,O.nestedNoscriptInHead);break}default:Jn(e,t)}}function y2(e,t){switch(t.tagID){case u.NOSCRIPT:{e.openElements.pop(),e.insertionMode=C.IN_HEAD;break}case u.BR:{Jn(e,t);break}default:e._err(t,O.endTagWithoutMatchingOpenElement)}}function Jn(e,t){const n=t.type===se.EOF?O.openElementsLeftAfterEof:O.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=C.IN_HEAD,e._processToken(t)}function _2(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.BODY:{e._insertElement(t,H.HTML),e.framesetOk=!1,e.insertionMode=C.IN_BODY;break}case u.FRAMESET:{e._insertElement(t,H.HTML),e.insertionMode=C.IN_FRAMESET;break}case u.BASE:case u.BASEFONT:case u.BGSOUND:case u.LINK:case u.META:case u.NOFRAMES:case u.SCRIPT:case u.STYLE:case u.TEMPLATE:case u.TITLE:{e._err(t,O.abandonedHeadElementChild),e.openElements.push(e.headElement,u.HEAD),st(e,t),e.openElements.remove(e.headElement);break}case u.HEAD:{e._err(t,O.misplacedStartTagForHeadElement);break}default:er(e,t)}}function C2(e,t){switch(t.tagID){case u.BODY:case u.HTML:case u.BR:{er(e,t);break}case u.TEMPLATE:{Kt(e,t);break}default:e._err(t,O.endTagWithoutMatchingOpenElement)}}function er(e,t){e._insertFakeElement(w.BODY,u.BODY),e.insertionMode=C.IN_BODY,ba(e,t)}function ba(e,t){switch(t.type){case se.CHARACTER:{Pd(e,t);break}case se.WHITESPACE_CHARACTER:{Ld(e,t);break}case se.COMMENT:{Ns(e,t);break}case se.START_TAG:{ve(e,t);break}case se.END_TAG:{Ea(e,t);break}case se.EOF:{Fd(e,t);break}}}function Ld(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function Pd(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function A2(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function S2(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function N2(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_FRAMESET)}function I2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML)}function v2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&Ss.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,H.HTML)}function w2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function k2(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML),n||(e.formElement=e.openElements.current))}function O2(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const a=e.openElements.tagIDs[r];if(n===u.LI&&a===u.LI||(n===u.DD||n===u.DT)&&(a===u.DD||a===u.DT)){e.openElements.generateImpliedEndTagsWithExclusion(a),e.openElements.popUntilTagNamePopped(a);break}if(a!==u.ADDRESS&&a!==u.DIV&&a!==u.P&&e._isSpecialElement(e.openElements.items[r],a))break}e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML)}function R2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML),e.tokenizer.state=Te.PLAINTEXT}function L2(e,t){e.openElements.hasInScope(u.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(u.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML),e.framesetOk=!1}function P2(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(w.A);n&&(xi(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function D2(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function M2(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(u.NOBR)&&(xi(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,H.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function B2(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function F2(e,t){e.treeAdapter.getDocumentMode(e.document)!==Qe.QUIRKS&&e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._insertElement(t,H.HTML),e.framesetOk=!1,e.insertionMode=C.IN_TABLE}function Dd(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,H.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Md(e){const t=Ad(e,Ut.TYPE);return t!=null&&t.toLowerCase()===n2}function H2(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,H.HTML),Md(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function U2(e,t){e._appendElement(t,H.HTML),t.ackSelfClosing=!0}function j2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._appendElement(t,H.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function z2(e,t){t.tagName=w.IMG,t.tagID=u.IMG,Dd(e,t)}function Y2(e,t){e._insertElement(t,H.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Te.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=C.TEXT}function W2(e,t){e.openElements.hasInButtonScope(u.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Te.RAWTEXT)}function V2(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Te.RAWTEXT)}function pu(e,t){e._switchToTextParsing(t,Te.RAWTEXT)}function $2(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===C.IN_TABLE||e.insertionMode===C.IN_CAPTION||e.insertionMode===C.IN_TABLE_BODY||e.insertionMode===C.IN_ROW||e.insertionMode===C.IN_CELL?C.IN_SELECT_IN_TABLE:C.IN_SELECT}function q2(e,t){e.openElements.currentTagId===u.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML)}function G2(e,t){e.openElements.hasInScope(u.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,H.HTML)}function X2(e,t){e.openElements.hasInScope(u.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(u.RTC),e._insertElement(t,H.HTML)}function K2(e,t){e._reconstructActiveFormattingElements(),kd(t),Ti(t),t.selfClosing?e._appendElement(t,H.MATHML):e._insertElement(t,H.MATHML),t.ackSelfClosing=!0}function Q2(e,t){e._reconstructActiveFormattingElements(),Od(t),Ti(t),t.selfClosing?e._appendElement(t,H.SVG):e._insertElement(t,H.SVG),t.ackSelfClosing=!0}function gu(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,H.HTML)}function ve(e,t){switch(t.tagID){case u.I:case u.S:case u.B:case u.U:case u.EM:case u.TT:case u.BIG:case u.CODE:case u.FONT:case u.SMALL:case u.STRIKE:case u.STRONG:{D2(e,t);break}case u.A:{P2(e,t);break}case u.H1:case u.H2:case u.H3:case u.H4:case u.H5:case u.H6:{v2(e,t);break}case u.P:case u.DL:case u.OL:case u.UL:case u.DIV:case u.DIR:case u.NAV:case u.MAIN:case u.MENU:case u.ASIDE:case u.CENTER:case u.FIGURE:case u.FOOTER:case u.HEADER:case u.HGROUP:case u.DIALOG:case u.DETAILS:case u.ADDRESS:case u.ARTICLE:case u.SEARCH:case u.SECTION:case u.SUMMARY:case u.FIELDSET:case u.BLOCKQUOTE:case u.FIGCAPTION:{I2(e,t);break}case u.LI:case u.DD:case u.DT:{O2(e,t);break}case u.BR:case u.IMG:case u.WBR:case u.AREA:case u.EMBED:case u.KEYGEN:{Dd(e,t);break}case u.HR:{j2(e,t);break}case u.RB:case u.RTC:{G2(e,t);break}case u.RT:case u.RP:{X2(e,t);break}case u.PRE:case u.LISTING:{w2(e,t);break}case u.XMP:{W2(e,t);break}case u.SVG:{Q2(e,t);break}case u.HTML:{A2(e,t);break}case u.BASE:case u.LINK:case u.META:case u.STYLE:case u.TITLE:case u.SCRIPT:case u.BGSOUND:case u.BASEFONT:case u.TEMPLATE:{st(e,t);break}case u.BODY:{S2(e,t);break}case u.FORM:{k2(e,t);break}case u.NOBR:{M2(e,t);break}case u.MATH:{K2(e,t);break}case u.TABLE:{F2(e,t);break}case u.INPUT:{H2(e,t);break}case u.PARAM:case u.TRACK:case u.SOURCE:{U2(e,t);break}case u.IMAGE:{z2(e,t);break}case u.BUTTON:{L2(e,t);break}case u.APPLET:case u.OBJECT:case u.MARQUEE:{B2(e,t);break}case u.IFRAME:{V2(e,t);break}case u.SELECT:{$2(e,t);break}case u.OPTION:case u.OPTGROUP:{q2(e,t);break}case u.NOEMBED:case u.NOFRAMES:{pu(e,t);break}case u.FRAMESET:{N2(e,t);break}case u.TEXTAREA:{Y2(e,t);break}case u.NOSCRIPT:{e.options.scriptingEnabled?pu(e,t):gu(e,t);break}case u.PLAINTEXT:{R2(e,t);break}case u.COL:case u.TH:case u.TD:case u.TR:case u.HEAD:case u.FRAME:case u.TBODY:case u.TFOOT:case u.THEAD:case u.CAPTION:case u.COLGROUP:break;default:gu(e,t)}}function Z2(e,t){if(e.openElements.hasInScope(u.BODY)&&(e.insertionMode=C.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function J2(e,t){e.openElements.hasInScope(u.BODY)&&(e.insertionMode=C.AFTER_BODY,$d(e,t))}function e_(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function t_(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(u.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(u.FORM):n&&e.openElements.remove(n))}function n_(e){e.openElements.hasInButtonScope(u.P)||e._insertFakeElement(w.P,u.P),e._closePElement()}function r_(e){e.openElements.hasInListItemScope(u.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(u.LI),e.openElements.popUntilTagNamePopped(u.LI))}function a_(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function s_(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function i_(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function o_(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(w.BR,u.BR),e.openElements.pop(),e.framesetOk=!1}function Bd(e,t){const n=t.tagName,r=t.tagID;for(let a=e.openElements.stackTop;a>0;a--){const s=e.openElements.items[a],i=e.openElements.tagIDs[a];if(r===i&&(r!==u.UNKNOWN||e.treeAdapter.getTagName(s)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=a&&e.openElements.shortenToLength(a);break}if(e._isSpecialElement(s,i))break}}function Ea(e,t){switch(t.tagID){case u.A:case u.B:case u.I:case u.S:case u.U:case u.EM:case u.TT:case u.BIG:case u.CODE:case u.FONT:case u.NOBR:case u.SMALL:case u.STRIKE:case u.STRONG:{xi(e,t);break}case u.P:{n_(e);break}case u.DL:case u.UL:case u.OL:case u.DIR:case u.DIV:case u.NAV:case u.PRE:case u.MAIN:case u.MENU:case u.ASIDE:case u.BUTTON:case u.CENTER:case u.FIGURE:case u.FOOTER:case u.HEADER:case u.HGROUP:case u.DIALOG:case u.ADDRESS:case u.ARTICLE:case u.DETAILS:case u.SEARCH:case u.SECTION:case u.SUMMARY:case u.LISTING:case u.FIELDSET:case u.BLOCKQUOTE:case u.FIGCAPTION:{e_(e,t);break}case u.LI:{r_(e);break}case u.DD:case u.DT:{a_(e,t);break}case u.H1:case u.H2:case u.H3:case u.H4:case u.H5:case u.H6:{s_(e);break}case u.BR:{o_(e);break}case u.BODY:{Z2(e,t);break}case u.HTML:{J2(e,t);break}case u.FORM:{t_(e);break}case u.APPLET:case u.OBJECT:case u.MARQUEE:{i_(e,t);break}case u.TEMPLATE:{Kt(e,t);break}default:Bd(e,t)}}function Fd(e,t){e.tmplInsertionModeStack.length>0?Vd(e,t):yi(e,t)}function u_(e,t){var n;t.tagID===u.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function l_(e,t){e._err(t,O.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Ka(e,t){if(e.openElements.currentTagId!==void 0&&Rd.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=C.IN_TABLE_TEXT,t.type){case se.CHARACTER:{Ud(e,t);break}case se.WHITESPACE_CHARACTER:{Hd(e,t);break}}else gr(e,t)}function c_(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_CAPTION}function d_(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_COLUMN_GROUP}function f_(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(w.COLGROUP,u.COLGROUP),e.insertionMode=C.IN_COLUMN_GROUP,_i(e,t)}function h_(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_TABLE_BODY}function m_(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(w.TBODY,u.TBODY),e.insertionMode=C.IN_TABLE_BODY,Ta(e,t)}function p_(e,t){e.openElements.hasInTableScope(u.TABLE)&&(e.openElements.popUntilTagNamePopped(u.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function g_(e,t){Md(t)?e._appendElement(t,H.HTML):gr(e,t),t.ackSelfClosing=!0}function b_(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,H.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function En(e,t){switch(t.tagID){case u.TD:case u.TH:case u.TR:{m_(e,t);break}case u.STYLE:case u.SCRIPT:case u.TEMPLATE:{st(e,t);break}case u.COL:{f_(e,t);break}case u.FORM:{b_(e,t);break}case u.TABLE:{p_(e,t);break}case u.TBODY:case u.TFOOT:case u.THEAD:{h_(e,t);break}case u.INPUT:{g_(e,t);break}case u.CAPTION:{c_(e,t);break}case u.COLGROUP:{d_(e,t);break}default:gr(e,t)}}function ir(e,t){switch(t.tagID){case u.TABLE:{e.openElements.hasInTableScope(u.TABLE)&&(e.openElements.popUntilTagNamePopped(u.TABLE),e._resetInsertionMode());break}case u.TEMPLATE:{Kt(e,t);break}case u.BODY:case u.CAPTION:case u.COL:case u.COLGROUP:case u.HTML:case u.TBODY:case u.TD:case u.TFOOT:case u.TH:case u.THEAD:case u.TR:break;default:gr(e,t)}}function gr(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,ba(e,t),e.fosterParentingEnabled=n}function Hd(e,t){e.pendingCharacterTokens.push(t)}function Ud(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function zn(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)gr(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const jd=new Set([u.CAPTION,u.COL,u.COLGROUP,u.TBODY,u.TD,u.TFOOT,u.TH,u.THEAD,u.TR]);function E_(e,t){const n=t.tagID;jd.has(n)?e.openElements.hasInTableScope(u.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(u.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=C.IN_TABLE,En(e,t)):ve(e,t)}function T_(e,t){const n=t.tagID;switch(n){case u.CAPTION:case u.TABLE:{e.openElements.hasInTableScope(u.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(u.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=C.IN_TABLE,n===u.TABLE&&ir(e,t));break}case u.BODY:case u.COL:case u.COLGROUP:case u.HTML:case u.TBODY:case u.TD:case u.TFOOT:case u.TH:case u.THEAD:case u.TR:break;default:Ea(e,t)}}function _i(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.COL:{e._appendElement(t,H.HTML),t.ackSelfClosing=!0;break}case u.TEMPLATE:{st(e,t);break}default:qr(e,t)}}function x_(e,t){switch(t.tagID){case u.COLGROUP:{e.openElements.currentTagId===u.COLGROUP&&(e.openElements.pop(),e.insertionMode=C.IN_TABLE);break}case u.TEMPLATE:{Kt(e,t);break}case u.COL:break;default:qr(e,t)}}function qr(e,t){e.openElements.currentTagId===u.COLGROUP&&(e.openElements.pop(),e.insertionMode=C.IN_TABLE,e._processToken(t))}function Ta(e,t){switch(t.tagID){case u.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_ROW;break}case u.TH:case u.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(w.TR,u.TR),e.insertionMode=C.IN_ROW,xa(e,t);break}case u.CAPTION:case u.COL:case u.COLGROUP:case u.TBODY:case u.TFOOT:case u.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE,En(e,t));break}default:En(e,t)}}function Is(e,t){const n=t.tagID;switch(t.tagID){case u.TBODY:case u.TFOOT:case u.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE);break}case u.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE,ir(e,t));break}case u.BODY:case u.CAPTION:case u.COL:case u.COLGROUP:case u.HTML:case u.TD:case u.TH:case u.TR:break;default:ir(e,t)}}function xa(e,t){switch(t.tagID){case u.TH:case u.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,H.HTML),e.insertionMode=C.IN_CELL,e.activeFormattingElements.insertMarker();break}case u.CAPTION:case u.COL:case u.COLGROUP:case u.TBODY:case u.TFOOT:case u.THEAD:case u.TR:{e.openElements.hasInTableScope(u.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE_BODY,Ta(e,t));break}default:En(e,t)}}function zd(e,t){switch(t.tagID){case u.TR:{e.openElements.hasInTableScope(u.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE_BODY);break}case u.TABLE:{e.openElements.hasInTableScope(u.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE_BODY,Is(e,t));break}case u.TBODY:case u.TFOOT:case u.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(u.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=C.IN_TABLE_BODY,Is(e,t));break}case u.BODY:case u.CAPTION:case u.COL:case u.COLGROUP:case u.HTML:case u.TD:case u.TH:break;default:ir(e,t)}}function y_(e,t){const n=t.tagID;jd.has(n)?(e.openElements.hasInTableScope(u.TD)||e.openElements.hasInTableScope(u.TH))&&(e._closeTableCell(),xa(e,t)):ve(e,t)}function __(e,t){const n=t.tagID;switch(n){case u.TD:case u.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=C.IN_ROW);break}case u.TABLE:case u.TBODY:case u.TFOOT:case u.THEAD:case u.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),zd(e,t));break}case u.BODY:case u.CAPTION:case u.COL:case u.COLGROUP:case u.HTML:break;default:Ea(e,t)}}function Yd(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.OPTION:{e.openElements.currentTagId===u.OPTION&&e.openElements.pop(),e._insertElement(t,H.HTML);break}case u.OPTGROUP:{e.openElements.currentTagId===u.OPTION&&e.openElements.pop(),e.openElements.currentTagId===u.OPTGROUP&&e.openElements.pop(),e._insertElement(t,H.HTML);break}case u.HR:{e.openElements.currentTagId===u.OPTION&&e.openElements.pop(),e.openElements.currentTagId===u.OPTGROUP&&e.openElements.pop(),e._appendElement(t,H.HTML),t.ackSelfClosing=!0;break}case u.INPUT:case u.KEYGEN:case u.TEXTAREA:case u.SELECT:{e.openElements.hasInSelectScope(u.SELECT)&&(e.openElements.popUntilTagNamePopped(u.SELECT),e._resetInsertionMode(),t.tagID!==u.SELECT&&e._processStartTag(t));break}case u.SCRIPT:case u.TEMPLATE:{st(e,t);break}}}function Wd(e,t){switch(t.tagID){case u.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===u.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===u.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===u.OPTGROUP&&e.openElements.pop();break}case u.OPTION:{e.openElements.currentTagId===u.OPTION&&e.openElements.pop();break}case u.SELECT:{e.openElements.hasInSelectScope(u.SELECT)&&(e.openElements.popUntilTagNamePopped(u.SELECT),e._resetInsertionMode());break}case u.TEMPLATE:{Kt(e,t);break}}}function C_(e,t){const n=t.tagID;n===u.CAPTION||n===u.TABLE||n===u.TBODY||n===u.TFOOT||n===u.THEAD||n===u.TR||n===u.TD||n===u.TH?(e.openElements.popUntilTagNamePopped(u.SELECT),e._resetInsertionMode(),e._processStartTag(t)):Yd(e,t)}function A_(e,t){const n=t.tagID;n===u.CAPTION||n===u.TABLE||n===u.TBODY||n===u.TFOOT||n===u.THEAD||n===u.TR||n===u.TD||n===u.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(u.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Wd(e,t)}function S_(e,t){switch(t.tagID){case u.BASE:case u.BASEFONT:case u.BGSOUND:case u.LINK:case u.META:case u.NOFRAMES:case u.SCRIPT:case u.STYLE:case u.TEMPLATE:case u.TITLE:{st(e,t);break}case u.CAPTION:case u.COLGROUP:case u.TBODY:case u.TFOOT:case u.THEAD:{e.tmplInsertionModeStack[0]=C.IN_TABLE,e.insertionMode=C.IN_TABLE,En(e,t);break}case u.COL:{e.tmplInsertionModeStack[0]=C.IN_COLUMN_GROUP,e.insertionMode=C.IN_COLUMN_GROUP,_i(e,t);break}case u.TR:{e.tmplInsertionModeStack[0]=C.IN_TABLE_BODY,e.insertionMode=C.IN_TABLE_BODY,Ta(e,t);break}case u.TD:case u.TH:{e.tmplInsertionModeStack[0]=C.IN_ROW,e.insertionMode=C.IN_ROW,xa(e,t);break}default:e.tmplInsertionModeStack[0]=C.IN_BODY,e.insertionMode=C.IN_BODY,ve(e,t)}}function N_(e,t){t.tagID===u.TEMPLATE&&Kt(e,t)}function Vd(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(u.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):yi(e,t)}function I_(e,t){t.tagID===u.HTML?ve(e,t):Gr(e,t)}function $d(e,t){var n;if(t.tagID===u.HTML){if(e.fragmentContext||(e.insertionMode=C.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===u.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Gr(e,t)}function Gr(e,t){e.insertionMode=C.IN_BODY,ba(e,t)}function v_(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.FRAMESET:{e._insertElement(t,H.HTML);break}case u.FRAME:{e._appendElement(t,H.HTML),t.ackSelfClosing=!0;break}case u.NOFRAMES:{st(e,t);break}}}function w_(e,t){t.tagID===u.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==u.FRAMESET&&(e.insertionMode=C.AFTER_FRAMESET))}function k_(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.NOFRAMES:{st(e,t);break}}}function O_(e,t){t.tagID===u.HTML&&(e.insertionMode=C.AFTER_AFTER_FRAMESET)}function R_(e,t){t.tagID===u.HTML?ve(e,t):Br(e,t)}function Br(e,t){e.insertionMode=C.IN_BODY,ba(e,t)}function L_(e,t){switch(t.tagID){case u.HTML:{ve(e,t);break}case u.NOFRAMES:{st(e,t);break}}}function P_(e,t){t.chars=be,e._insertCharacters(t)}function D_(e,t){e._insertCharacters(t),e.framesetOk=!1}function qd(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==H.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function M_(e,t){if(Qy(t))qd(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===H.MATHML?kd(t):r===H.SVG&&(Zy(t),Od(t)),Ti(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function B_(e,t){if(t.tagID===u.P||t.tagID===u.BR){qd(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===H.HTML){e._endTagOutsideForeignContent(t);break}const a=e.treeAdapter.getTagName(r);if(a.toLowerCase()===t.tagName){t.tagName=a,e.openElements.shortenToLength(n);break}}}w.AREA,w.BASE,w.BASEFONT,w.BGSOUND,w.BR,w.COL,w.EMBED,w.FRAME,w.HR,w.IMG,w.INPUT,w.KEYGEN,w.LINK,w.META,w.PARAM,w.SOURCE,w.TRACK,w.WBR;const F_=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,H_=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),bu={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function Gd(e,t){const n=X_(e),r=Td("type",{handlers:{root:U_,element:j_,text:z_,comment:Kd,doctype:Y_,raw:V_},unknown:$_}),a={parser:n?new mu(bu):mu.getFragmentParser(void 0,bu),handle(o){r(o,a)},stitches:!1,options:t||{}};r(e,a),Ln(a,gt());const s=n?a.parser.document:a.parser.getFragment(),i=Ux(s,{file:a.options.file});return a.stitches&&mi(i,"comment",function(o,l,c){const d=o;if(d.value.stitch&&c&&l!==void 0){const f=c.children;return f[l]=d.value.stitch,l}}),i.type==="root"&&i.children.length===1&&i.children[0].type===e.type?i.children[0]:i}function Xd(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function U_(e,t){Xd(e.children,t)}function j_(e,t){q_(e,t),Xd(e.children,t),G_(e,t)}function z_(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:se.CHARACTER,chars:e.value,location:br(e)};Ln(t,gt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function Y_(e,t){const n={type:se.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:br(e)};Ln(t,gt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function W_(e,t){t.stitches=!0;const n=K_(e);if("children"in e&&"children"in n){const r=Gd({type:"root",children:e.children},t.options);n.children=r.children}Kd({type:"comment",value:{stitch:n}},t)}function Kd(e,t){const n=e.value,r={type:se.COMMENT,data:n,location:br(e)};Ln(t,gt(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function V_(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,Qd(t,gt(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(F_,"&lt;$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function $_(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))W_(n,t);else{let r="";throw H_.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function Ln(e,t){Qd(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=Te.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function Qd(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function q_(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Te.PLAINTEXT)return;Ln(t,gt(e));const r=t.parser.openElements.current;let a="namespaceURI"in r?r.namespaceURI:Ht.html;a===Ht.html&&n==="svg"&&(a=Ht.svg);const s=ty({...e,children:[]},{space:a===Ht.svg?"svg":"html"}),i={type:se.START_TAG,tagName:n,tagID:Rn(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in s?s.attrs:[],location:br(e)};t.parser.currentToken=i,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function G_(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&ly.includes(n)||t.parser.tokenizer.state===Te.PLAINTEXT)return;Ln(t,ha(e));const r={type:se.END_TAG,tagName:n,tagID:Rn(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:br(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Te.RCDATA||t.parser.tokenizer.state===Te.RAWTEXT||t.parser.tokenizer.state===Te.SCRIPT_DATA)&&(t.parser.tokenizer.state=Te.DATA)}function X_(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function br(e){const t=gt(e)||{line:void 0,column:void 0,offset:void 0},n=ha(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function K_(e){return"children"in e?bn({...e,children:[]}):bn(e)}function Q_(e){return function(t,n){return Gd(t,{...e,file:n})}}const Z_="_prose_1l8lv_1",J_="_mdAccordion_1l8lv_16",Zd={prose:Z_,mdAccordion:J_};function eC(e,{openFirst:t=!1}={}){if(!e)return"";const n=/~H~~([\s\S]*?)~~\s*~M~~([\s\S]*?)~~/g;let r=0;return e.replace(n,(a,s,i)=>{const o=t&&r===0?" open":"";return r+=1,`
76
+ <details class="${Zd.mdAccordion}"${o}>
77
+ <summary>${String(s).trim()}</summary>
78
+ <div class="p-4">
79
+ ${String(i).trim()}
80
+ </div>
81
+ </details>`})}function tC({children:e,className:t="",openFirst:n=!1}){const a=eC(typeof e=="string"?e:"",{openFirst:n});return m.jsx("div",{className:["prose",Zd.prose,t].filter(Boolean).join(" "),children:m.jsx(Sx,{rehypePlugins:[Q_],children:a})})}function nC(e){return m.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg","aria-hidden":!0,className:"size-5",...e,children:[m.jsx("rect",{x:"0.666667",y:"0.666667",width:"10.6667",height:"10.6667",rx:"5.33333",stroke:"#B1B1B1",strokeWidth:"1.33333"}),m.jsx("circle",{cx:"6.00065",cy:"3.33268",r:"0.666667",fill:"#B1B1B1"}),m.jsx("rect",{x:"5.33398",y:"5.33398",width:"1.33333",height:"4",fill:"#B1B1B1"})]})}const Eu={},Jd=({tooltipData:e,openFirst:t=!1,trigger:n})=>{if(!e?.trim())return null;const r=a=>{a.stopPropagation()};return m.jsxs(Js,{children:[m.jsx(ei,{asChild:!0,children:n??m.jsx("button",{className:Eu.iconBtn,"aria-label":"Open tooltip",onClick:r,children:m.jsx(nC,{className:Eu.iconSvg})})}),m.jsx(ti,{className:"bg-[#000] text-white text-[1.1rem] leading-[1.45] w-auto max-w-[300px]",side:"top",children:m.jsx(tC,{openFirst:t,children:e})})]})},ef=y.forwardRef(({values:e,value:t,onValueChange:n,placeholder:r="Sort by",title:a,className:s,dropdownWidth:i,align:o="start",showClear:l=!1,getTooltipByMaterialAndSection:c,sectionName:d},f)=>{const[p,h]=y.useState(!1),x=y.useRef(null);y.useEffect(()=>{if(!p)return;const _=k=>{const L=k.target,v=x.current;v&&(v.contains(L)||L===v)||h(!1)},N=k=>k.key==="Escape"&&h(!1);return window.addEventListener("scroll",_,!0),window.addEventListener("resize",_),document.addEventListener("keydown",N),()=>{window.removeEventListener("scroll",_,!0),window.removeEventListener("resize",_),document.removeEventListener("keydown",N)}},[p]);const g=t?e.find(_=>_.value===t):void 0,A=_=>{n(_),h(!1)},E=()=>n(null);return m.jsxs(Cc,{open:p,onOpenChange:h,children:[m.jsxs(Ac,{ref:f,"aria-haspopup":"listbox","aria-expanded":p,className:ke("inline-flex flex-row items-center justify-between gap-[8px] rounded-full bg-[var(--label-bg, #f5f5f5)] px-[8px] py-[8px] text-xs font-medium h-[36px] text-blackborder border-transparent hover:bg-gray-100 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--main-accent-color)]sm:w-[102px]",s),children:[m.jsx("span",{className:ke(!g&&"text-xs text-gray-700 ms:text-sm"),children:g?.label??r}),m.jsx(kl,{className:ke("h-4 w-[16px] transition-transform",p&&"rotate-180")})]}),m.jsxs(Sc,{ref:x,align:o,sideOffset:6,className:ke("bg-white border border-gray-200 rounded-xl shadow-lg z-50 max-h-80 overflow-y-auto p-0",i||"w-[var(--radix-popover-trigger-width)]"),style:{WebkitOverflowScrolling:"touch",overscrollBehavior:"contain"},onTouchStart:_=>_.stopPropagation(),onTouchMove:_=>_.stopPropagation(),onWheel:_=>_.stopPropagation(),children:[(a??r)&&m.jsx("div",{className:"px-4 pt-3 pb-2 text-[1rem] font-regular",children:a??r}),l&&t!==null&&m.jsx("div",{className:"px-4 py-2 border-b",children:m.jsxs("button",{onClick:E,className:"inline-flex flex-row items-center gap-[4px] text-[0.95rem] text-black hover:text-[var(--main-accent-color)] transition-colors",children:[m.jsx(Bs,{className:"h-3.5 w-[12px].5"}),"Clear"]})}),m.jsx("div",{role:"listbox","aria-activedescendant":g?`option-${g.value}`:void 0,className:"py-1",children:e.map(_=>{const N=t===_.value;return m.jsxs("div",{id:`option-${_.value}`,role:"option","aria-selected":N,tabIndex:0,className:ke("flex flex-row items-start justify-between gap-[8px] px-4 py-2 cursor-pointer","hover:bg-gray-50 focus:bg-gray-50 focus:outline-none"),onClick:()=>A(_.value),onKeyDown:k=>{(k.key==="Enter"||k.key===" ")&&(k.preventDefault(),A(_.value))},children:[m.jsxs("div",{className:"flex flex-row items-center gap-[8px]",children:[m.jsx("span",{className:"text-[1.05rem]",children:_.label}),(()=>{if(!c||!d)return null;const k=c(_.value,d);return k?.Description?m.jsx(Jd,{tooltipData:k.Description}):null})()]}),N?m.jsx(wl,{className:"h-4 w-[16px]"}):null]},_.value)})})]})]})});ef.displayName="SingleSelect";const tf=({size:e=80,trackClassName:t="text-white",accentClassName:n="text-amber-700",className:r="",isOverlay:a=!0})=>m.jsx("div",{className:a?"absolute inset-0 flex flex-row items-center justify-center backdrop-blur bg-black/30 z-150":"inline-flex flex-row items-center justify-center",children:m.jsxs("span",{role:"status","aria-label":"Loading",className:r,style:{width:e,height:e},children:[m.jsxs("svg",{viewBox:"0 0 80 80",className:"animate-spin",width:"100%",height:"100%",xmlns:"http://www.w3.org/2000/svg",children:[m.jsx("path",{d:"M40.0003 6.66675V20.0001M54.0003 26.0001L63.667 16.3334M60.0003 40.0001H73.3337M54.0003 54.0001L63.667 63.6667M40.0003 60.0001V73.3334M16.3337 63.6667L26.0003 54.0001M6.66699 40.0001H20.0003M16.3337 16.3334L26.0003 26.0001",stroke:"currentColor",className:t,strokeWidth:4,strokeLinecap:"round",strokeLinejoin:"round"}),m.jsx("path",{d:"M54 25.9999L63.6667 16.3333",stroke:"currentColor",className:n,strokeWidth:4,strokeLinecap:"round",strokeLinejoin:"round"})]}),m.jsx("span",{className:"sr-only",children:"Loading…"})]})}),rC=({open:e,target:t,children:n,offset:r=12,maxWidthPx:a=420,forceOverflowVisible:s=!0})=>{const i=D.useRef(null),[o,l]=D.useState({top:0,left:0,arrowLeft:16});return D.useEffect(()=>{if(!e||!t||!s)return;const c=t.style.position;getComputedStyle(t).position==="static"&&(t.style.position="relative");const f=t.style.overflow;return t.style.overflow="visible",()=>{t.style.position=c,t.style.overflow=f}},[e,t,s]),D.useLayoutEffect(()=>{if(!e||!t)return;const c=10,d=8,f=()=>{const g=i.current;if(!g)return;const A={vis:g.style.visibility,top:g.style.top,left:g.style.left,maxW:g.style.maxWidth,transform:g.style.transform};g.style.visibility="hidden",g.style.top="0px",g.style.left="0px",g.style.transform="none",g.style.maxWidth=`min(${a}px, calc(100vw - ${d*2}px))`;const E=g.getBoundingClientRect(),_=E.width,N=E.height,k=t.getBoundingClientRect(),L=k.left,v=Math.max(d,Math.min(L,window.innerWidth-d-_)),R=Math.max(d,k.top-(N+r+c)),P=L-v+16,q=Math.max(8,Math.min(P,_-8));g.style.visibility=A.vis,g.style.top=A.top,g.style.left=A.left,g.style.maxWidth=A.maxW,g.style.transform=A.transform,l({top:R,left:v,arrowLeft:q})};f();const p=()=>f(),h=()=>f();window.addEventListener("scroll",p,{passive:!0}),window.addEventListener("resize",h);const x=new ResizeObserver(()=>f());return x.observe(t),()=>{window.removeEventListener("scroll",p),window.removeEventListener("resize",h),x.disconnect()}},[e,t,r,a]),!e||!t?null:Vt.createPortal(m.jsx("div",{className:"fixed inset-0 z-[60000] pointer-events-none",children:m.jsxs("div",{ref:i,role:"tooltip",className:`
82
+ absolute
83
+ rounded-2xl
84
+ text-white text-sm leading-6 font-medium
85
+ pointer-events-auto
86
+ `,style:{top:o.top,left:o.left,maxWidth:`min(${a}px, calc(100vw - 16px))`,backgroundColor:"rgba(40,40,40,0.8)"},children:[m.jsx("div",{className:"px-4 py-3",children:n}),m.jsx("span",{className:`
87
+ absolute -bottom-[10px] h-0 w-0
88
+ border-l-[10px] border-l-transparent
89
+ border-r-[10px] border-r-transparent
90
+ border-t-[10px]
91
+ `,style:{left:o.arrowLeft,borderTopColor:"rgba(40,40,40,0.8)"}})]})}),document.querySelector("#root-container"))},nf=({val:e,onDelete:t})=>{const[n,r]=D.useState(null),[a,s]=D.useState(!1),[i,o]=D.useState({materialName:"",parentName:"",productName:""}),l=e.metadata,c=d=>{d.stopPropagation(),t(e)};return m.jsxs(m.Fragment,{children:[m.jsxs("div",{tabIndex:0,onKeyDown:d=>{(d.key==="Enter"||d.key===" ")&&d.preventDefault()},className:`
92
+ bg-[var(--background-grey)] relative w-[40px] h-[40px] border border-solid border-[var(--border)]
93
+ rounded-sm aspect-square overflow-hidden transition sm:w-[64px] sm:h-[64px]
94
+ select-none
95
+ `,"aria-label":`Selected swatch ${e.name??e.assetId}`,title:"Click to remove",onMouseEnter:d=>{r(d.currentTarget),o({materialName:l?.label||e?.name||"empty_materialName",parentName:e.parentName,productName:e.productName||"empty_product_name"}),s(!0)},onMouseLeave:()=>s(!1),children:[zt.getImage(e)?m.jsx(zs,{item:e}):m.jsx(Ys,{item:e}),m.jsx("div",{onClick:c,className:`absolute top-0 right-0 m-2 w-[16px] h-[16px] flex flex-row justify-center items-center
96
+ bg-[var(--background-grey)] rounded-2xl border-none z-[100] cursor-pointer`,children:m.jsx(cr,{className:"w-[8px] h-2 stroke-[var(--svg-dark)]"})})]}),m.jsx(rC,{open:a,target:n,offset:8,children:m.jsxs(m.Fragment,{children:[i.materialName," | ",i.parentName]})})]})},aC=()=>m.jsx("div",{className:["relative w-[40px] h-[40px] rounded-sm aspect-square overflow-hidden","border border-solid border-[var(--border)] bg-[var(--sidebar-b)] sm:w-[64px] sm:h-[64px]"].join(" "),"aria-hidden":!0}),sC=({selectedMaterials:e,containerStyles:t="p-[var(--padding)] border-t border-solid border-[var(--border)] shrink-0 sm:p-[var(--sm-padding)]"})=>{const n=Pe(),r=oe(na),a=oe(yn),s=o=>{if(!r)return;const l=f=>f.metadata?.label===o.metadata?.label&&f.parentName===o.parentName,c=a.find(f=>f.items.some(l)),d=c?.items.filter(f=>!l(f));if(c){const f={assetId:c.assetId||"empty_assetId",name:c.name,items:d||[]};n(rs(f)),n(as(f))}},i=Math.max(0,Re-e.length);return m.jsxs("div",{className:t,children:[m.jsxs("div",{className:"flex flex-row justify-between items-center mb-[12px]",children:[m.jsxs("div",{className:"relative",children:[m.jsx("div",{className:"",children:"Swatches list"}),m.jsx("span",{className:"absolute top-0 right-[-20px] font-medium text-[var(--main-accent-color)] text-[8px] leading-none",children:"Free"})]}),m.jsxs("div",{children:[e.length,"/",Re," Selected"]})]}),m.jsxs("div",{className:"flex flex-row flex-wrap gap-[8px]",children:[e.map((o,l)=>{const c=o.metadata;return m.jsx(nf,{val:o,onDelete:s},`${c?.label||l}/${o.parentName}`)}),Array.from({length:i}).map((o,l)=>m.jsx(aC,{},`mock-${l}`))]})]})},rf=()=>{const e=Pe(),t=oe(yn),n=D.useMemo(()=>t.flatMap(a=>a.items.map(s=>({...s,productName:a.name}))),[t]),r=()=>{n.length&&e(Uu(!0))};return m.jsxs("div",{className:`flex flex-col border-t border-[var(--border)] shrink-0 shadow-[0_-2px_10px_rgba(40,40,40,0.10)]
97
+ sm:flex-row
98
+ `,children:[m.jsx(sC,{selectedMaterials:n,containerStyles:"flex flex-col p-[var(--sm-padding)] shrink-0 sm:w-[50%] sm:border-r sm:border-[var(--border)]"}),m.jsx("div",{className:"flex flex-row w-full p-[var(--sm-padding)] border-t border-[var(--border)] sm:border-none lg:w-[50%] sm:justify-center sm:items-center lg:justify-end lg:items-end",children:m.jsx("div",{className:"w-full lg:w-[50%]",children:m.jsx(Gu,{onClick:r,children:"ADD SWATCHES TO CART"})})})]})},iC=[{label:"Clear All",value:""},{label:"A-Z",value:"asc"},{label:"Z-A",value:"dsc"}],oC=()=>{const e=Pe(),t=oe(Mh),n=oe(Vu),r=oe(Dh),a=oe(yn),[s,i]=D.useState($l),[o,l]=D.useState(""),[c,d]=D.useState(""),[f,p]=D.useState(null);D.useEffect(()=>{const E=setTimeout(()=>{d(o.trim().toLowerCase())},300);return()=>clearTimeout(E)},[o]),D.useEffect(()=>{e($n())},[e]);const h=D.useMemo(()=>wp.getUniqueCategories(r),[r]),x=E=>E.toLowerCase(),g=D.useMemo(()=>new Intl.Collator(void 0,{sensitivity:"base",numeric:!1}),[]),A=D.useMemo(()=>{let E=r;if(s?.value){const _=x(s.value);E=E.filter(N=>x(N.collection??"")===_)}return c&&(E=E.filter(_=>x(_.name).includes(c))),f==="asc"?E=[...E].sort((_,N)=>g.compare(_.name,N.name)):f==="dsc"?E=[...E].sort((_,N)=>g.compare(N.name,_.name)):E=[...E],E},[r,s,c,f,g]);return m.jsxs("div",{className:"relative flex flex-col h-full min-h-0 w-full",children:[m.jsxs("div",{className:"flex-shrink-0",children:[m.jsx("div",{className:"h-40 overflow-hidden",children:m.jsx("img",{src:"https://clownfish-app-cvxrz.ondigitalocean.app/assets/header_image-BZoSlAHj.png",className:"object-cover w-full h-full"})}),m.jsxs("header",{className:"flex flex-col border-b border-[var(--border)] lg:flex-row lg:justify-between",children:[m.jsx("h1",{className:"m-0! p-[var(--sm-padding)] text-base font-medium",children:"Swatches store"}),m.jsx("div",{className:"flex flex-row justify-center items-center border-t border-[var(--border)] p-[var(--sm-padding)] text-xs font-medium leading-[24px] lg:border-none",children:m.jsxs("span",{children:["Choose 5 free swatches to curate your perfect design. Plus get"," ",m.jsx("span",{className:"text-[var(--main-accent-color)] underline",children:"free design advice"})," ","from our experts"]})})]})]}),m.jsxs("div",{className:"flex flex-col flex-1 min-h-0",children:[(t||n)&&m.jsx(tf,{}),m.jsxs("div",{className:"flex flex-row w-full items-center justify-between gap-[16px] border-b border-[var(--border)] p-[var(--sm-padding)]",children:[m.jsxs("div",{className:"flex flex-row h-[36px] w-full items-center justify-between gap-[16px] shrink-0 lg:max-w-[382px]",children:[m.jsxs("div",{className:"relative h-[36px] flex-1 min-w-0 lg:max-w-[240px]",children:[m.jsx("input",{type:"text",placeholder:"Search",value:o,onChange:E=>l(E.target.value),className:`
99
+ h-full w-full rounded-2xl border border-[var(--border)] bg-[var(--background)]
100
+ px-4 pr-8 text-sm text-black placeholder-[var(--text-muted)]
101
+ transition focus:border-[var(--main-accent-color)] focus:outline-none
102
+ `}),m.jsx("div",{className:`
103
+ pointer-events-none absolute right-3 top-1/2 -translate-y-1/2 sm:right-4
104
+ [&_svg_path]:stroke-[var(--svg-dark)]
105
+ `,children:m.jsx(Np,{width:20,height:20})})]}),m.jsx(ef,{title:"Sort by",placeholder:"Sort by",values:iC,value:f,onValueChange:p,className:"shrink-0 w-[90px] xxs:w-[100px] bg-[var(--label-bg)] sm:py-8px sm:px-16px sm:w-[102px]",dropdownWidth:"w-64"})]}),m.jsx(Ji,{items:h,activeId:s.productId,onSelect:E=>i(E),className:"hidden lg:flex flex-row shrink-0 overflow-x-auto"})]}),m.jsx(Ji,{items:h,activeId:s.productId,onSelect:E=>i(E),className:"h-[64px] p-[var(--sm-padding)] border-b border-[var(--border)] lg:hidden"}),m.jsxs("div",{className:"flex-1 min-h-0 overflow-y-auto overscroll-contain p-[var(--sm-padding)]",children:[m.jsx("div",{className:"mb-4",children:"Select Product"}),A.length?m.jsx("ul",{className:"grid grid-cols-2 gap-[16px] sm:grid-cols-4 lg:grid-cols-6 xl:grid-cols-8 2xl:grid-cols-9",children:A.map(E=>m.jsx(vp,{productListItem:E},E.name))}):m.jsx("div",{className:"flex flex-row h-full items-center justify-center",children:"No products were found"})]}),a.length?m.jsx(rf,{}):null]})]})};function uC(e){const t=y.useRef({value:e,previous:e});return y.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var ya="Checkbox",[lC]=aa(ya),[cC,Ci]=lC(ya);function dC(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:a,disabled:s,form:i,name:o,onCheckedChange:l,required:c,value:d="on",internal_do_not_use_render:f}=e,[p,h]=ws({prop:n,defaultProp:a??!1,onChange:l,caller:ya}),[x,g]=y.useState(null),[A,E]=y.useState(null),_=y.useRef(!1),N=x?!!i||!!x.closest("form"):!0,k={checked:p,disabled:s,setChecked:h,control:x,setControl:g,name:o,form:i,value:d,hasConsumerStoppedPropagationRef:_,required:c,defaultChecked:Rt(a)?!1:a,isFormControl:N,bubbleInput:A,setBubbleInput:E};return m.jsx(cC,{scope:t,...k,children:fC(f)?f(k):r})}var af="CheckboxTrigger",sf=y.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},a)=>{const{control:s,value:i,disabled:o,checked:l,required:c,setControl:d,setChecked:f,hasConsumerStoppedPropagationRef:p,isFormControl:h,bubbleInput:x}=Ci(af,e),g=Xe(a,d),A=y.useRef(l);return y.useEffect(()=>{const E=s?.form;if(E){const _=()=>f(A.current);return E.addEventListener("reset",_),()=>E.removeEventListener("reset",_)}},[s,f]),m.jsx(Ne.button,{type:"button",role:"checkbox","aria-checked":Rt(l)?"mixed":l,"aria-required":c,"data-state":ff(l),"data-disabled":o?"":void 0,disabled:o,value:i,...r,ref:g,onKeyDown:Le(t,E=>{E.key==="Enter"&&E.preventDefault()}),onClick:Le(n,E=>{f(_=>Rt(_)?!0:!_),x&&h&&(p.current=E.isPropagationStopped(),p.current||E.stopPropagation())})})});sf.displayName=af;var of=y.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:a,defaultChecked:s,required:i,disabled:o,value:l,onCheckedChange:c,form:d,...f}=e;return m.jsx(dC,{__scopeCheckbox:n,checked:a,defaultChecked:s,disabled:o,required:i,onCheckedChange:c,name:r,form:d,value:l,internal_do_not_use_render:({isFormControl:p})=>m.jsxs(m.Fragment,{children:[m.jsx(sf,{...f,ref:t,__scopeCheckbox:n}),p&&m.jsx(df,{__scopeCheckbox:n})]})})});of.displayName=ya;var uf="CheckboxIndicator",lf=y.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...a}=e,s=Ci(uf,n);return m.jsx(_n,{present:r||Rt(s.checked)||s.checked===!0,children:m.jsx(Ne.span,{"data-state":ff(s.checked),"data-disabled":s.disabled?"":void 0,...a,ref:t,style:{pointerEvents:"none",...e.style}})})});lf.displayName=uf;var cf="CheckboxBubbleInput",df=y.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:a,checked:s,defaultChecked:i,required:o,disabled:l,name:c,value:d,form:f,bubbleInput:p,setBubbleInput:h}=Ci(cf,e),x=Xe(n,h),g=uC(s),A=sc(r);y.useEffect(()=>{const _=p;if(!_)return;const N=window.HTMLInputElement.prototype,L=Object.getOwnPropertyDescriptor(N,"checked").set,v=!a.current;if(g!==s&&L){const R=new Event("click",{bubbles:v});_.indeterminate=Rt(s),L.call(_,Rt(s)?!1:s),_.dispatchEvent(R)}},[p,g,s,a]);const E=y.useRef(Rt(s)?!1:s);return m.jsx(Ne.input,{type:"checkbox","aria-hidden":!0,defaultChecked:i??E.current,required:o,disabled:l,name:c,value:d,form:f,...t,tabIndex:-1,ref:x,style:{...t.style,...A,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});df.displayName=cf;function fC(e){return typeof e=="function"}function Rt(e){return e==="indeterminate"}function ff(e){return Rt(e)?"indeterminate":e?"checked":"unchecked"}function hC({className:e,...t}){return m.jsx(of,{"data-slot":"checkbox",className:ke(`
106
+ bg-white peer border-input dark:bg-input/30
107
+ data-[state=checked]:bg-transparent
108
+ data-[state=checked]:text-black
109
+ focus-visible:border-ring focus-visible:ring-ring/50
110
+ aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40
111
+ aria-invalid:border-destructive
112
+ size-4 shrink-0 rounded-[4px] border shadow-xs
113
+ transition-shadow outline-none focus-visible:ring-[3px]
114
+ disabled:cursor-not-allowed disabled:opacity-50
115
+ `,e),...t,children:m.jsx(lf,{"data-slot":"checkbox-indicator",className:"flex flex-row items-center justify-center text-current transition-none",children:m.jsx(wl,{className:"size-3"})})})}const Er=y.forwardRef(({options:e,values:t,onValueChange:n,placeholder:r="Select options...",className:a="w-full min-w-[80px] 2xs:min-w-[100px] xs:min-w-[110px] sm:max-w-[auto] sm:min-w-[130px] lg:min-w-[160px]",dropdownWidth:s,align:i="start",getTooltipByMaterialAndSection:o,sectionName:l},c)=>{const[d,f]=y.useState(!1),p=y.useRef(null);y.useEffect(()=>{if(!d)return;const E=N=>{const k=N.target,L=p.current;L&&(L.contains(k)||k===L)||f(!1)},_=N=>{N.key==="Escape"&&f(!1)};return window.addEventListener("scroll",E,!0),window.addEventListener("resize",E),document.addEventListener("keydown",_),()=>{window.removeEventListener("scroll",E,!0),window.removeEventListener("resize",E),document.removeEventListener("keydown",_)}},[d]);const h=(E,_)=>{n(_?[...t,E]:t.filter(N=>N!==E))},x=()=>{n([])},g=t.length,A=g===0?r:g===1?e.find(E=>E.value===t[0])?.label||`${r} selected`:m.jsxs("div",{className:"flex flex-row items-center w-full",children:[m.jsx("span",{className:"truncate mr-1",children:r}),m.jsx("span",{className:`
116
+ flex-none flex flex-row justify-center items-center
117
+ w-[20px] h-5 rounded-full
118
+ bg-[var(--main-accent-color)] text-white
119
+ text-[1rem] leading-none
120
+ select-none pointer-events-none
121
+ overflow-hidden
122
+ `,children:g})]});if(e.length)return m.jsxs(Cc,{open:d,onOpenChange:f,children:[m.jsxs(Ac,{ref:c,className:ke("flex flex-row items-center justify-between rounded-full border border-[var(--main-accent-color)] px-2 sm:px-4 py-2 bg-white cursor-pointer hover:bg-gray-50 data-[state=open]:border-primary hover:border-primary focus:border-primary min-h-9",a),children:[m.jsx("div",{className:"w-full text-xs truncate text-left leading-[20px] sm:text-sm",children:A}),m.jsx(kl,{className:ke("h-4 w-[16px] transition-transform",d&&"rotate-180")})]}),m.jsxs(Sc,{ref:p,className:ke("bg-white border rounded-lg shadow-lg z-50 max-h-75 text-sm overflow-y-auto overscroll-behavior-y-contain touch-pan-y p-2",s||"w-[var(--radix-popover-trigger-width)]"),align:i,sideOffset:4,style:{WebkitOverflowScrolling:"touch",overscrollBehavior:"contain"},onTouchStart:E=>{E.stopPropagation()},onTouchMove:E=>{E.stopPropagation()},onWheel:E=>{E.stopPropagation()},children:[g>0&&m.jsx("div",{className:"flex flex-row gap-[8px] items-center justify-between px-2 py-1 mb-2 border-b",children:m.jsxs("button",{onClick:x,className:"text-sm text-black hover:text-primary transition-color cursor-pointer duration-200 flex flex-row items-center gap-[4px]",children:[m.jsx(Bs,{className:"h-3 w-[12px]"}),"Clear all"]})}),m.jsx("div",{className:"flex flex-col gap-[4px]",children:e.map(E=>{const _=t.includes(E.value);return m.jsxs("div",{className:"flex flex-row items-start gap-[8px] px-2 py-1 hover:bg-gray-50 rounded transition-background duration-300 cursor-pointer",onClick:()=>h(E.value,!_),children:[m.jsx(hC,{checked:_,className:"size-6",onCheckedChange:N=>h(E.value,N)}),m.jsxs("div",{className:"flex-1 flex flex-row items-center justify-between",children:[m.jsxs("div",{className:"flex flex-row items-center gap-[8px]",children:[m.jsx("span",{className:"text-sm",children:E.label}),(()=>{if(!o||!l)return null;const N=o(E.value,l);return N&&N.Description?m.jsx(Jd,{tooltipData:N?.Description}):null})()]}),E.count!==void 0&&m.jsx("span",{className:"text-sm text-gray-800 bg-gray-100 px-2 py-0.5 ml-2 rounded-full whitespace-nowrap",children:E.count})]})]},E.value)})})]})]})});Er.displayName="MultiSelect";const hf=({containerStyles:e,selectStyles:t})=>{const n=Pe(),r=oe(Lh),a=oe(xn),[s,i]=D.useState([]),[o,l]=D.useState([]);D.useEffect(()=>{if(!r?.length)return;const d=r.map(f=>{if(f.metadata){const{Name:p,Label:h}=f.metadata||{};return{value:p,label:h,id:p}}else{const{label:p,value:h}=f||{};return{value:h,label:p,id:h}}});i(d)},[r]);const c=(d,f)=>{if(f.length){const p=Iu(f);if(p.length){const h=r.filter(A=>A.metadata?p.includes(A.metadata?.Label):p.includes(A.value));l(p);const x=Fr.mapFiltersFromValues(h,a),g=Fr.getPositiveSelectedFilers(x);g.length&&g.forEach(A=>{const{filterName:E,filterKeys:_}=A;n(ea({filterName:E,values:_}))}),n(_a({attributes:h}))}else n(_a({attributes:r}))}else l([]),n(_a({attributes:r}))};return m.jsxs("div",{className:e,children:[m.jsx("span",{children:"Product element"}),m.jsx(Er,{options:s,values:o,onValueChange:d=>c("PanelElement",d),placeholder:"All product elements",className:t,dropdownWidth:"w-80"})]})},mC=()=>{const e=Pe(),t=oe(xn),n=oe(lr),[r,a]=D.useState([]);D.useEffect(()=>{if(n?.length){const i=[...new Set(n.map(o=>o.metadata?.Finish||o.metadata?.Material))].filter(Boolean).map(o=>{const l=n.filter(c=>c.metadata?.Finish===o||c.metadata?.Material===o).length;return{value:o,label:o,count:l}});i?.length&&a(i)}},[n]);const s=(i,o)=>{e(ea({filterName:i,values:o}))};return m.jsx(Er,{options:r,values:t.Finish,onValueChange:i=>s("Finish",i),placeholder:"Material",dropdownWidth:"w-80"})},pC=()=>{const e=Pe(),t=oe(xn),n=oe(lr),[r,a]=D.useState([]);D.useEffect(()=>{if(n?.length){const i=[...new Set(n.map(o=>o?.metadata?.Color).filter(Boolean).map(o=>o.split(",").map(l=>l.trim())).flat())].map(o=>{const l=n.filter(c=>c.metadata?.Color&&c.metadata?.Color.split(",").map(d=>d.trim()).includes(o)).length;return{value:o,label:o,count:l}});i?.length&&a(i)}},[n]);const s=(i,o)=>{e(ea({filterName:i,values:o}))};return m.jsx(Er,{options:r,values:t.Color,onValueChange:i=>s("Color",i),placeholder:"Color",dropdownWidth:"w-80"})},gC=()=>{const e=Pe(),t=oe(xn),n=oe(lr),[r,a]=D.useState([]);D.useEffect(()=>{if(n?.length){const i=[...new Set(n.map(o=>o?.metadata?.Look).filter(Boolean).map(o=>o.split(",").map(l=>l.trim())).flat())].map(o=>{const l=n.filter(c=>c.metadata?.Look&&c.metadata?.Look.split(",").map(d=>d.trim()).includes(o)).length;return{value:o,label:o,count:l}});i?.length&&a(i)}},[n]);const s=(i,o)=>{e(ea({filterName:i,values:o}))};return m.jsx(Er,{options:r,values:t.Look,onValueChange:i=>s("Look",i),placeholder:"Look",dropdownWidth:"w-80"})},mf=()=>m.jsxs("div",{className:"flex flex-row items-center gap-[16px] p-[var(--sm-padding)]",children:[m.jsx(mC,{}),m.jsx(pC,{}),m.jsx(gC,{})]}),bC=()=>m.jsxs("div",{className:`flex flex-col justify-between border-b border-[var(--border)]
123
+ sm:flex-row
124
+ `,children:[m.jsx(hf,{containerStyles:`flex flex-row justify-between items-center gap-[8px] p-[var(--sm-padding)] w-full text-xs
125
+ border-b border-[var(--border)]
126
+ sm:max-w-[360px] sm:text-sm sm:border-none
127
+ `,selectStyles:"min-w-[auto] max-w-[154px] sm:max-w-[auto] sm:min-w-[180px] font-normal"}),m.jsx(mf,{})]});function on(e,t,n){let r=n.initialDeps??[],a;function s(){var i,o,l,c;let d;n.key&&((i=n.debug)!=null&&i.call(n))&&(d=Date.now());const f=e();if(!(f.length!==r.length||f.some((x,g)=>r[g]!==x)))return a;r=f;let h;if(n.key&&((o=n.debug)!=null&&o.call(n))&&(h=Date.now()),a=t(...f),n.key&&((l=n.debug)!=null&&l.call(n))){const x=Math.round((Date.now()-d)*100)/100,g=Math.round((Date.now()-h)*100)/100,A=g/16,E=(_,N)=>{for(_=String(_);_.length<N;)_=" "+_;return _};console.info(`%c⏱ ${E(g,5)} /${E(x,5)} ms`,`
128
+ font-size: .6rem;
129
+ font-weight: bold;
130
+ color: hsl(${Math.max(0,Math.min(120-120*A,120))}deg 100% 31%);`,n?.key)}return(c=n?.onChange)==null||c.call(n,a),a}return s.updateDeps=i=>{r=i},s}function Tu(e,t){if(e===void 0)throw new Error("Unexpected undefined");return e}const EC=(e,t)=>Math.abs(e-t)<1.01,TC=(e,t,n)=>{let r;return function(...a){e.clearTimeout(r),r=e.setTimeout(()=>t.apply(this,a),n)}},xu=e=>{const{offsetWidth:t,offsetHeight:n}=e;return{width:t,height:n}},xC=e=>e,yC=e=>{const t=Math.max(e.startIndex-e.overscan,0),n=Math.min(e.endIndex+e.overscan,e.count-1),r=[];for(let a=t;a<=n;a++)r.push(a);return r},_C=(e,t)=>{const n=e.scrollElement;if(!n)return;const r=e.targetWindow;if(!r)return;const a=i=>{const{width:o,height:l}=i;t({width:Math.round(o),height:Math.round(l)})};if(a(xu(n)),!r.ResizeObserver)return()=>{};const s=new r.ResizeObserver(i=>{const o=()=>{const l=i[0];if(l?.borderBoxSize){const c=l.borderBoxSize[0];if(c){a({width:c.inlineSize,height:c.blockSize});return}}a(xu(n))};e.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(o):o()});return s.observe(n,{box:"border-box"}),()=>{s.unobserve(n)}},yu={passive:!0},_u=typeof window>"u"?!0:"onscrollend"in window,CC=(e,t)=>{const n=e.scrollElement;if(!n)return;const r=e.targetWindow;if(!r)return;let a=0;const s=e.options.useScrollendEvent&&_u?()=>{}:TC(r,()=>{t(a,!1)},e.options.isScrollingResetDelay),i=d=>()=>{const{horizontal:f,isRtl:p}=e.options;a=f?n.scrollLeft*(p&&-1||1):n.scrollTop,s(),t(a,d)},o=i(!0),l=i(!1);l(),n.addEventListener("scroll",o,yu);const c=e.options.useScrollendEvent&&_u;return c&&n.addEventListener("scrollend",l,yu),()=>{n.removeEventListener("scroll",o),c&&n.removeEventListener("scrollend",l)}},AC=(e,t,n)=>{if(t?.borderBoxSize){const r=t.borderBoxSize[0];if(r)return Math.round(r[n.options.horizontal?"inlineSize":"blockSize"])}return e[n.options.horizontal?"offsetWidth":"offsetHeight"]},SC=(e,{adjustments:t=0,behavior:n},r)=>{var a,s;const i=e+t;(s=(a=r.scrollElement)==null?void 0:a.scrollTo)==null||s.call(a,{[r.options.horizontal?"left":"top"]:i,behavior:n})};class NC{constructor(t){this.unsubs=[],this.scrollElement=null,this.targetWindow=null,this.isScrolling=!1,this.measurementsCache=[],this.itemSizeCache=new Map,this.pendingMeasuredCacheIndexes=[],this.scrollRect=null,this.scrollOffset=null,this.scrollDirection=null,this.scrollAdjustments=0,this.elementsCache=new Map,this.observer=(()=>{let n=null;const r=()=>n||(!this.targetWindow||!this.targetWindow.ResizeObserver?null:n=new this.targetWindow.ResizeObserver(a=>{a.forEach(s=>{const i=()=>{this._measureElement(s.target,s)};this.options.useAnimationFrameWithResizeObserver?requestAnimationFrame(i):i()})}));return{disconnect:()=>{var a;(a=r())==null||a.disconnect(),n=null},observe:a=>{var s;return(s=r())==null?void 0:s.observe(a,{box:"border-box"})},unobserve:a=>{var s;return(s=r())==null?void 0:s.unobserve(a)}}})(),this.range=null,this.setOptions=n=>{Object.entries(n).forEach(([r,a])=>{typeof a>"u"&&delete n[r]}),this.options={debug:!1,initialOffset:0,overscan:1,paddingStart:0,paddingEnd:0,scrollPaddingStart:0,scrollPaddingEnd:0,horizontal:!1,getItemKey:xC,rangeExtractor:yC,onChange:()=>{},measureElement:AC,initialRect:{width:0,height:0},scrollMargin:0,gap:0,indexAttribute:"data-index",initialMeasurementsCache:[],lanes:1,isScrollingResetDelay:150,enabled:!0,isRtl:!1,useScrollendEvent:!1,useAnimationFrameWithResizeObserver:!1,...n}},this.notify=n=>{var r,a;(a=(r=this.options).onChange)==null||a.call(r,this,n)},this.maybeNotify=on(()=>(this.calculateRange(),[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]),n=>{this.notify(n)},{key:process.env.NODE_ENV!=="production"&&"maybeNotify",debug:()=>this.options.debug,initialDeps:[this.isScrolling,this.range?this.range.startIndex:null,this.range?this.range.endIndex:null]}),this.cleanup=()=>{this.unsubs.filter(Boolean).forEach(n=>n()),this.unsubs=[],this.observer.disconnect(),this.scrollElement=null,this.targetWindow=null},this._didMount=()=>()=>{this.cleanup()},this._willUpdate=()=>{var n;const r=this.options.enabled?this.options.getScrollElement():null;if(this.scrollElement!==r){if(this.cleanup(),!r){this.maybeNotify();return}this.scrollElement=r,this.scrollElement&&"ownerDocument"in this.scrollElement?this.targetWindow=this.scrollElement.ownerDocument.defaultView:this.targetWindow=((n=this.scrollElement)==null?void 0:n.window)??null,this.elementsCache.forEach(a=>{this.observer.observe(a)}),this._scrollToOffset(this.getScrollOffset(),{adjustments:void 0,behavior:void 0}),this.unsubs.push(this.options.observeElementRect(this,a=>{this.scrollRect=a,this.maybeNotify()})),this.unsubs.push(this.options.observeElementOffset(this,(a,s)=>{this.scrollAdjustments=0,this.scrollDirection=s?this.getScrollOffset()<a?"forward":"backward":null,this.scrollOffset=a,this.isScrolling=s,this.maybeNotify()}))}},this.getSize=()=>this.options.enabled?(this.scrollRect=this.scrollRect??this.options.initialRect,this.scrollRect[this.options.horizontal?"width":"height"]):(this.scrollRect=null,0),this.getScrollOffset=()=>this.options.enabled?(this.scrollOffset=this.scrollOffset??(typeof this.options.initialOffset=="function"?this.options.initialOffset():this.options.initialOffset),this.scrollOffset):(this.scrollOffset=null,0),this.getFurthestMeasurement=(n,r)=>{const a=new Map,s=new Map;for(let i=r-1;i>=0;i--){const o=n[i];if(a.has(o.lane))continue;const l=s.get(o.lane);if(l==null||o.end>l.end?s.set(o.lane,o):o.end<l.end&&a.set(o.lane,!0),a.size===this.options.lanes)break}return s.size===this.options.lanes?Array.from(s.values()).sort((i,o)=>i.end===o.end?i.index-o.index:i.end-o.end)[0]:void 0},this.getMeasurementOptions=on(()=>[this.options.count,this.options.paddingStart,this.options.scrollMargin,this.options.getItemKey,this.options.enabled],(n,r,a,s,i)=>(this.pendingMeasuredCacheIndexes=[],{count:n,paddingStart:r,scrollMargin:a,getItemKey:s,enabled:i}),{key:!1}),this.getMeasurements=on(()=>[this.getMeasurementOptions(),this.itemSizeCache],({count:n,paddingStart:r,scrollMargin:a,getItemKey:s,enabled:i},o)=>{if(!i)return this.measurementsCache=[],this.itemSizeCache.clear(),[];this.measurementsCache.length===0&&(this.measurementsCache=this.options.initialMeasurementsCache,this.measurementsCache.forEach(d=>{this.itemSizeCache.set(d.key,d.size)}));const l=this.pendingMeasuredCacheIndexes.length>0?Math.min(...this.pendingMeasuredCacheIndexes):0;this.pendingMeasuredCacheIndexes=[];const c=this.measurementsCache.slice(0,l);for(let d=l;d<n;d++){const f=s(d),p=this.options.lanes===1?c[d-1]:this.getFurthestMeasurement(c,d),h=p?p.end+this.options.gap:r+a,x=o.get(f),g=typeof x=="number"?x:this.options.estimateSize(d),A=h+g,E=p?p.lane:d%this.options.lanes;c[d]={index:d,start:h,size:g,end:A,key:f,lane:E}}return this.measurementsCache=c,c},{key:process.env.NODE_ENV!=="production"&&"getMeasurements",debug:()=>this.options.debug}),this.calculateRange=on(()=>[this.getMeasurements(),this.getSize(),this.getScrollOffset(),this.options.lanes],(n,r,a,s)=>this.range=n.length>0&&r>0?IC({measurements:n,outerSize:r,scrollOffset:a,lanes:s}):null,{key:process.env.NODE_ENV!=="production"&&"calculateRange",debug:()=>this.options.debug}),this.getVirtualIndexes=on(()=>{let n=null,r=null;const a=this.calculateRange();return a&&(n=a.startIndex,r=a.endIndex),this.maybeNotify.updateDeps([this.isScrolling,n,r]),[this.options.rangeExtractor,this.options.overscan,this.options.count,n,r]},(n,r,a,s,i)=>s===null||i===null?[]:n({startIndex:s,endIndex:i,overscan:r,count:a}),{key:process.env.NODE_ENV!=="production"&&"getVirtualIndexes",debug:()=>this.options.debug}),this.indexFromElement=n=>{const r=this.options.indexAttribute,a=n.getAttribute(r);return a?parseInt(a,10):(console.warn(`Missing attribute name '${r}={index}' on measured element.`),-1)},this._measureElement=(n,r)=>{const a=this.indexFromElement(n),s=this.measurementsCache[a];if(!s)return;const i=s.key,o=this.elementsCache.get(i);o!==n&&(o&&this.observer.unobserve(o),this.observer.observe(n),this.elementsCache.set(i,n)),n.isConnected&&this.resizeItem(a,this.options.measureElement(n,r,this))},this.resizeItem=(n,r)=>{const a=this.measurementsCache[n];if(!a)return;const s=this.itemSizeCache.get(a.key)??a.size,i=r-s;i!==0&&((this.shouldAdjustScrollPositionOnItemSizeChange!==void 0?this.shouldAdjustScrollPositionOnItemSizeChange(a,i,this):a.start<this.getScrollOffset()+this.scrollAdjustments)&&(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("correction",i),this._scrollToOffset(this.getScrollOffset(),{adjustments:this.scrollAdjustments+=i,behavior:void 0})),this.pendingMeasuredCacheIndexes.push(a.index),this.itemSizeCache=new Map(this.itemSizeCache.set(a.key,r)),this.notify(!1))},this.measureElement=n=>{if(!n){this.elementsCache.forEach((r,a)=>{r.isConnected||(this.observer.unobserve(r),this.elementsCache.delete(a))});return}this._measureElement(n,void 0)},this.getVirtualItems=on(()=>[this.getVirtualIndexes(),this.getMeasurements()],(n,r)=>{const a=[];for(let s=0,i=n.length;s<i;s++){const o=n[s],l=r[o];a.push(l)}return a},{key:process.env.NODE_ENV!=="production"&&"getVirtualItems",debug:()=>this.options.debug}),this.getVirtualItemForOffset=n=>{const r=this.getMeasurements();if(r.length!==0)return Tu(r[pf(0,r.length-1,a=>Tu(r[a]).start,n)])},this.getOffsetForAlignment=(n,r,a=0)=>{const s=this.getSize(),i=this.getScrollOffset();r==="auto"&&(r=n>=i+s?"end":"start"),r==="center"?n+=(a-s)/2:r==="end"&&(n-=s);const o=this.getTotalSize()+this.options.scrollMargin-s;return Math.max(Math.min(o,n),0)},this.getOffsetForIndex=(n,r="auto")=>{n=Math.max(0,Math.min(n,this.options.count-1));const a=this.measurementsCache[n];if(!a)return;const s=this.getSize(),i=this.getScrollOffset();if(r==="auto")if(a.end>=i+s-this.options.scrollPaddingEnd)r="end";else if(a.start<=i+this.options.scrollPaddingStart)r="start";else return[i,r];const o=r==="end"?a.end+this.options.scrollPaddingEnd:a.start-this.options.scrollPaddingStart;return[this.getOffsetForAlignment(o,r,a.size),r]},this.isDynamicMode=()=>this.elementsCache.size>0,this.scrollToOffset=(n,{align:r="start",behavior:a}={})=>{a==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getOffsetForAlignment(n,r),{adjustments:void 0,behavior:a})},this.scrollToIndex=(n,{align:r="auto",behavior:a}={})=>{a==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),n=Math.max(0,Math.min(n,this.options.count-1));let s=0;const i=10,o=c=>{if(!this.targetWindow)return;const d=this.getOffsetForIndex(n,c);if(!d){console.warn("Failed to get offset for index:",n);return}const[f,p]=d;this._scrollToOffset(f,{adjustments:void 0,behavior:a}),this.targetWindow.requestAnimationFrame(()=>{const h=this.getScrollOffset(),x=this.getOffsetForIndex(n,p);if(!x){console.warn("Failed to get offset for index:",n);return}EC(x[0],h)||l(p)})},l=c=>{this.targetWindow&&(s++,s<i?(process.env.NODE_ENV!=="production"&&this.options.debug&&console.info("Schedule retry",s,i),this.targetWindow.requestAnimationFrame(()=>o(c))):console.warn(`Failed to scroll to index ${n} after ${i} attempts.`))};o(r)},this.scrollBy=(n,{behavior:r}={})=>{r==="smooth"&&this.isDynamicMode()&&console.warn("The `smooth` scroll behavior is not fully supported with dynamic size."),this._scrollToOffset(this.getScrollOffset()+n,{adjustments:void 0,behavior:r})},this.getTotalSize=()=>{var n;const r=this.getMeasurements();let a;if(r.length===0)a=this.options.paddingStart;else if(this.options.lanes===1)a=((n=r[r.length-1])==null?void 0:n.end)??0;else{const s=Array(this.options.lanes).fill(null);let i=r.length-1;for(;i>=0&&s.some(o=>o===null);){const o=r[i];s[o.lane]===null&&(s[o.lane]=o.end),i--}a=Math.max(...s.filter(o=>o!==null))}return Math.max(a-this.options.scrollMargin+this.options.paddingEnd,0)},this._scrollToOffset=(n,{adjustments:r,behavior:a})=>{this.options.scrollToFn(n,{behavior:a,adjustments:r},this)},this.measure=()=>{this.itemSizeCache=new Map,this.notify(!1)},this.setOptions(t)}}const pf=(e,t,n,r)=>{for(;e<=t;){const a=(e+t)/2|0,s=n(a);if(s<r)e=a+1;else if(s>r)t=a-1;else return a}return e>0?e-1:0};function IC({measurements:e,outerSize:t,scrollOffset:n,lanes:r}){const a=e.length-1,s=l=>e[l].start;if(e.length<=r)return{startIndex:0,endIndex:a};let i=pf(0,a,s,n),o=i;if(r===1)for(;o<a&&e[o].end<n+t;)o++;else if(r>1){const l=Array(r).fill(0);for(;o<a&&l.some(d=>d<n+t);){const d=e[o];l[d.lane]=d.end,o++}const c=Array(r).fill(n+t);for(;i>=0&&c.some(d=>d>=n);){const d=e[i];c[d.lane]=d.start,i--}i=Math.max(0,i-i%r),o=Math.min(a,o+(r-1-o%r))}return{startIndex:i,endIndex:o}}const Cu=typeof document<"u"?y.useLayoutEffect:y.useEffect;function vC(e){const t=y.useReducer(()=>({}),{})[1],n={...e,onChange:(a,s)=>{var i;s?Vt.flushSync(t):t(),(i=e.onChange)==null||i.call(e,a,s)}},[r]=y.useState(()=>new NC(n));return r.setOptions(n),Cu(()=>r._didMount(),[]),Cu(()=>r._willUpdate()),r}function gf(e){return vC({observeElementRect:_C,observeElementOffset:CC,scrollToFn:SC,...e})}const wC=e=>m.jsx("svg",{width:"16",height:"11",viewBox:"0 0 16 11",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:m.jsx("path",{d:"M14.6668 1L5.50016 10.1667L1.3335 6",stroke:"white",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})}),Xr=({val:e,onClick:t})=>{const n=oe($t),r=oe(yn),a=D.useMemo(()=>r.flatMap(c=>c.items),[r]),s=a.length?a:n,i=c=>{t(c)},o=e&&e.metadata?.value,l=s.find(c=>c.metadata?.value===o&&c.parentName===e.parentName);return m.jsxs("div",{className:"flex flex-col gap-[8px]",children:[m.jsxs("button",{onClick:()=>i(e),className:`
131
+ relative w-full aspect-square overflow-hidden rounded
132
+ border transition
133
+ ${l?"border-amber-700":"border-transparent"}
134
+ `,children:[m.jsx("div",{className:"absolute inset-0",children:zt.getImage(e)?m.jsx(zs,{item:e}):m.jsx(Ys,{item:e})}),m.jsx("div",{className:`
135
+ absolute top-0 right-0 m-2 h-[30px] w-[30px]
136
+ flex flex-row items-center justify-center rounded-2xl border-none
137
+ bg-[var(--background-grey)] pointer-events-none
138
+ ${l?"bg-[var(--main-accent-color)]":""}
139
+ `,children:m.jsx(wC,{})})]},e.assetId),m.jsxs("div",{className:"mb-[12px] flex flex-col",children:[m.jsxs("span",{className:"mb-[4px] text-sm font-semibold leading-[16px]",children:[e.metadata?.label||e.label," "]}),m.jsxs("span",{className:"text-xs font-medium leading-[14px]",children:[e.parentName," "]})]})]})},kC=({isOpen:e,onClose:t,title:n="Message",width:r,height:a,children:s})=>{const i=D.useRef(null);return D.useEffect(()=>{const o=l=>{i.current&&!i.current.contains(l.target)&&t()};return e&&document.addEventListener("mousedown",o),()=>{document.removeEventListener("mousedown",o)}},[e,t]),e?Vt.createPortal(m.jsx("div",{className:"fixed inset-0 z-99999999999999 flex flex-row items-center justify-center bg-black/40 p-4",children:m.jsxs("div",{ref:i,className:`
140
+ bg-white rounded-2xl shadow-xl flex flex-col overflow-hidden
141
+ max-w-[90vw] max-h-[90vh]
142
+ `,style:{width:r||"auto",height:a||"auto"},children:[m.jsxs("div",{className:"flex flex-row items-center justify-between p-[var(--sm-padding)] border-b border-[var(--border)]",children:[m.jsx("span",{className:"text-base font-semibold text-[var(--text)]",children:n}),m.jsx("button",{onClick:t,className:"flex flex-row justify-center items-center p-1 rounded-full bg-[var(--border)] hover:bg-gray-100 transition [&_svg_path]:stroke-[var(--svg-dark)] w-[30px] h-[30px]",children:m.jsx(cr,{className:"text-[var(--text)] ",width:10,hanging:10})})]}),m.jsx("div",{className:"flex flex-col gap-[12px] text-[var(--text-muted)]",children:s})]})}),document.querySelector("#root-container")):null},bf=({isOpen:e,onClose:t})=>m.jsx(kC,{isOpen:e,onClose:t,width:320,title:"Swatch Limit",children:m.jsxs("div",{children:[m.jsxs("div",{className:"text-sm font-medium p-[var(--sm-padding)] border-b border-[var(--border)] leading-[20px]",children:[m.jsx("p",{className:"mb-4",children:"You've reached your maximum number of swatches!"}),m.jsx("p",{children:"If you'd like to add another swatch please remove an existing swatch from your cart"})]}),m.jsx("div",{className:"p-[var(--sm-padding)] w-full",children:m.jsx("button",{className:`
143
+ w-full block py-3 rounded-full
144
+ bg-[var(--main-accent-color)] text-white font-bold capitalize
145
+ `,onClick:t,children:"OK"})})]})}),OC=({containerStyles:e="flex-1 min-h-0 overflow-y-auto p-[var(--padding)] sm:p-[var(--sm-padding)] ",gridStyles:t="grid grid-cols-1 gap-[8px] sm:grid-cols-3",desktopColumnsCount:n=3})=>{const r=Pe(),a=D.useRef(null),s=oe(lr),i=oe(xn),o=oe(na),l=oe(yn),[c,d]=D.useState(!1),f=D.useMemo(()=>l.flatMap($=>$.items),[l]),p=D.useMemo(()=>l.flatMap($=>$.items).reduce(($,Y)=>$+(Y.count??0),0),[l]),h=D.useMemo(()=>s.filter($=>{const Y=i.Finish.length===0||i.Finish.some(B=>$.metadata?.Finish===B||$.metadata?.Material===B),F=i.Color.length===0||$.metadata?.Color&&i.Color.some(B=>$.metadata?.Color?.split(",").map(ie=>ie.trim()).includes(B)),X=$.metadata?.Look,Q=!i.Look||i.Look.length===0||i.Look.some(B=>X&&X.includes(B));return Y&&F&&Q}),[i,s]),x=typeof window<"u"?window.matchMedia("(min-width: 640px)").matches:!1,g=x?n:1,A=Math.ceil(h.length/g),E=x?300:200,_=gf({count:A,getScrollElement:()=>a.current,estimateSize:()=>E,overscan:24,measureElement:$=>$?.getBoundingClientRect().height}),N=_.getVirtualItems(),k=_.getTotalSize(),L=N[0]?.index??0,v=N[N.length-1]?.index??-1,R=L*g,P=Math.min((v+1)*g,h.length),q=h.slice(R,P),K=N[0]?.start??0,U=k-(N[N.length-1]?.end??0),z=$=>{if(!o)return;const Y=l.find(Q=>o.assetId===Q.assetId),F=Q=>Q.metadata?.label===$.metadata?.label&&Q.parentName===$.parentName,X=f.some(F);if(!X&&p>=5){d(!0);return}if(X){const Q=f.filter(S=>!F(S)),ie={assetId:l.find(S=>S.items.some(xe=>xe.metadata?.label===$.metadata?.label&&xe.parentName===$.parentName))?.assetId||o.assetId,name:o.name,items:Q};r(rs(ie)),r(as(ie))}else if(f.length<5){const Q={...$,count:1},B=Y?[...Y.items,Q]:[Q],ie={assetId:o.assetId,name:o.name,items:B};r(rs(ie)),r(as(ie))}};return m.jsxs("div",{ref:a,className:e,children:[m.jsx(bf,{isOpen:c,onClose:()=>d(!1)}),m.jsx("div",{style:{height:K},"aria-hidden":!0}),m.jsx("div",{className:t,children:q.map(($,Y)=>{const F=R+Y,X=`${$.metadata?.label||F}/${$.parentName}`;return(F+1)%g===0||F===h.length-1?m.jsx("div",{ref:_.measureElement,children:m.jsx(Xr,{val:$,onClick:z})},X):m.jsx(Xr,{val:$,onClick:z},X)})}),m.jsx("div",{style:{height:U},"aria-hidden":!0})]})},RC=()=>{const e=Pe(),t=oe(na);D.useEffect(()=>()=>{e(bh())},[]);const n=()=>{e(Th())};return m.jsxs("div",{className:"flex flex-col h-full ",children:[m.jsx("header",{className:"flex flex-row shrink-0 items-center justify-between border-b border-[var(--border)] p-[var(--sm-padding)]",children:m.jsxs("div",{className:"flex flex-row items-center gap-[8px]",children:[m.jsx("button",{className:"[&_svg_path]:stroke-[var(--main-accent-color)] cursor-pointer",onClick:n,children:m.jsx(Ws,{})}),m.jsx("h2",{className:"m-0! text-base font-medium leading-[1.6]",children:t?.name})]})}),m.jsxs("div",{className:"flex flex-col min-h-0 flex-1 ",children:[m.jsx("div",{className:"shrink-0",children:m.jsx(bC,{})}),m.jsx(OC,{containerStyles:"flex-1 min-h-0 overflow-y-auto overscroll-contain p-[var(--sm-padding)]",gridStyles:"grid grid-cols-2 gap-[16px] sm:grid-cols-4 lg:grid-cols-5 xl:grid-cols-7 2xl:grid-cols-9",desktopColumnsCount:6}),m.jsx(rf,{})]})]})},LC=({onSendData:e})=>{const t=oe(Ph),n=oe(na);return m.jsx(m.Fragment,{children:t?m.jsx(Sp,{onSendData:e}):n?m.jsx(RC,{}):m.jsx(oC,{})})},Kr={SWATCH:"swatch",CART:"cart"},PC="_overlay_1aet8_1",DC="_panel_1aet8_10",MC="_enter_1aet8_38",BC="_exit_1aet8_42",Yn={overlay:PC,panel:DC,enter:MC,exit:BC},Ef=({children:e,isOpen:t,setIsOpen:n})=>{const r=D.useRef(null),a=D.useRef(null),s=()=>n(!1);return D.useLayoutEffect(()=>{t&&typeof document<"u"&&(a.current=document.activeElement)},[t]),D.useEffect(()=>{t?r.current?.focus():a.current?.focus?.()},[t]),D.useEffect(()=>{if(!t)return;const i=o=>{o.key==="Escape"&&s()};return window.addEventListener("keydown",i),()=>window.removeEventListener("keydown",i)},[t]),D.useEffect(()=>{if(!t)return;const i=document.documentElement,o=document.body,l=i.style.overflow,c=o.style.overflow;return i.style.overflow="hidden",o.style.overflow="hidden",()=>{i.style.overflow=l,o.style.overflow=c}},[t]),t?Vt.createPortal(m.jsx("div",{className:yt(Yn.overlay),onMouseDown:s,onTouchStart:s,children:m.jsx("div",{ref:r,tabIndex:-1,className:ke(Yn.panel,Yn.right,t?Yn.enter:Yn.exit,"bg-[var(--sidebar-bg)]"),onMouseDown:i=>i.stopPropagation(),onTouchStart:i=>i.stopPropagation(),children:e})}),document.querySelector("#root-container")):null};class FC{static getCartPreparedOption(t){return t?.length?t.map(n=>({...n,count:1})):[]}}const HC=()=>m.jsx("div",{className:["relative w-[40px] h-[40px] rounded-sm aspect-square overflow-hidden","border border-solid border-[var(--border)] bg-[var(--sidebar-b)] sm:w-[64px] sm:h-[64px]"].join(" "),"aria-hidden":!0}),UC=({selectedMaterials:e,containerStyles:t="p-[var(--sm-padding)] border-t border-solid border-[var(--border)] shrink-0 shadow-[0_-2px_10px_rgba(40,40,40,0.10)]"})=>{const n=Pe(),r=s=>{n(ta({selectedMaterial:s,materialCount:1,selectedMaterials:e}))},a=Math.max(0,Re-e.length);return m.jsxs("div",{className:t,children:[m.jsxs("div",{className:"flex flex-row justify-between items-center mb-[12px]",children:[m.jsxs("div",{className:"relative",children:[m.jsx("div",{className:"",children:"Swatches list"}),m.jsx("span",{className:"absolute top-0 right-[-20px] font-medium text-[var(--main-accent-color)] text-[8px] leading-none",children:"Free"})]}),m.jsxs("div",{children:[e.length,"/",Re," Selected"]})]}),m.jsxs("div",{className:"flex flex-row flex-wrap gap-[8px]",children:[e.map((s,i)=>{const o=s.metadata;return m.jsx(nf,{val:s,onDelete:r},`${o?.label||i}/${s.parentName}`)}),Array.from({length:a}).map((s,i)=>m.jsx(HC,{},`mock-${i}`))]})]})},jC=()=>{const e=oe($t)??[];return m.jsx(UC,{selectedMaterials:e})},zC=({containerStyles:e="flex-1 min-h-0 overflow-y-auto p-[var(--sm-padding)]",gridStyles:t="grid grid-cols-2 gap-[var(--sm-padding)] sm:grid-cols-3 ",desktopColumnsCount:n=3})=>{const r=Tn.useDispatch(),a=D.useRef(null),s=oe(lr),i=oe($t),o=oe(xn),[l,c]=D.useState(!1),d=D.useMemo(()=>i.reduce((U,z)=>U+(z.count??0),0),[i]),f=D.useMemo(()=>s.filter(U=>{const z=o.Finish.length===0||o.Finish.some(X=>U.metadata?.Finish===X||U.metadata?.Material===X),$=o.Color.length===0||U.metadata?.Color&&o.Color.some(X=>U.metadata?.Color?.split(",").map(Q=>Q.trim()).includes(X)),Y=U.metadata?.Look,F=!o.Look||o.Look.length===0||o.Look.some(X=>Y&&Y.includes(X));return z&&$&&F}),[o,s]),p=typeof window<"u"?window.matchMedia("(min-width: 640px)").matches:!1,h=p?n:1,x=Math.ceil(f.length/h),g=p?300:200,A=gf({count:x,getScrollElement:()=>a.current,estimateSize:()=>g,overscan:24,measureElement:U=>U?.getBoundingClientRect().height}),E=A.getVirtualItems(),_=A.getTotalSize(),N=E[0]?.index??0,k=E[E.length-1]?.index??-1,L=N*h,v=Math.min((k+1)*h,f.length),R=f.slice(L,v),P=E[0]?.start??0,q=_-(E[E.length-1]?.end??0),K=U=>{r(ta({materialCount:d,selectedMaterials:i,selectedMaterial:{...U,count:1},limitCb:()=>c(!0)}))};return m.jsxs("div",{ref:a,className:e,children:[m.jsx(bf,{isOpen:l,onClose:()=>c(!1)}),m.jsx("div",{style:{height:P},"aria-hidden":!0}),m.jsx("div",{className:t,children:R.map((U,z)=>{const $=L+z,Y=`${U.metadata?.label||$}/${U.parentName}`;return($+1)%h===0||$===f.length-1?m.jsx("div",{ref:A.measureElement,children:m.jsx(Xr,{val:U,onClick:K})},Y):m.jsx(Xr,{val:U,onClick:K},Y)})}),m.jsx("div",{style:{height:q},"aria-hidden":!0})]})},YC=({isOpen:e,onToggleSidebar:t,onSetActiveTab:n})=>{const r=Pe(),a=oe($t)??[],s=oe(Vu),i=()=>{const o=FC.getCartPreparedOption(a);o&&r(Ah(o)),n(Kr.CART)};return m.jsxs(Ef,{isOpen:e,setIsOpen:t,children:[m.jsxs("header",{className:"flex flex-row p-[var(--sm-padding)] justify-between items-center border-b border-solid border-[var(--border)]",children:[m.jsx("h2",{className:"m-0! text-[16px] leading-[1.6] font-medium",children:"Order free swatches"}),m.jsx("button",{className:`flex flex-row justify-center items-center w-[30px] h-[30px] bg-[var(--background-grey)]
146
+ border-none cursor-pointer rounded-full
147
+ [&_svg_path]:stroke-[var(--svg-dark)]`,onClick:t,children:m.jsx(cr,{width:10,height:10})})]}),m.jsxs("div",{className:"flex flex-col h-full min-h-0 relative",children:[s&&m.jsx(tf,{}),m.jsx(hf,{containerStyles:"flex flex-row justify-between items-center shrink-0 p-[var(--sm-padding)] border-b border-solid border-[var(--border)]",selectStyles:"min-w-[auto] max-w-[154px] sm:max-w-[auto] sm:min-w-[250px]"}),m.jsx("div",{className:"w-full border-b border-b-border",children:m.jsx(mf,{})}),m.jsx(zC,{}),m.jsx(jC,{}),m.jsx("div",{className:"p-[var(--sm-padding)] border-t border-solid border-[var(--border)] shrink-0",children:m.jsx("button",{className:"w-full bg-[var(--main-accent-color)] text-white py-3 rounded-full font-bold cursor-pointer",onClick:i,children:"ADD SWATCHES TO CART"})})]})]})},WC=({onSetActiveTab:e,onToggleSidebar:t})=>{const n=oe($t),r=D.useMemo(()=>n.reduce((a,s)=>a+(s.count??0),0),[n]);return m.jsxs("header",{className:"flex flex-row MaterialMultiProductList justify-between items-center border-b border-solid border-[var(--border)] p-[var(--sm-padding)]",children:[m.jsxs("div",{className:"flex flex-row items-center gap-[4px]",children:[m.jsxs("div",{className:"flex flex-row items-center gap-[8px]",children:[m.jsx("button",{className:"[&_svg_path]:stroke-[var(--main-accent-color)] cursor-pointer",onClick:()=>e&&e(Kr.SWATCH),children:m.jsx(Ws,{})}),m.jsx("h2",{className:"m-0! text-base leading-[1.6] font-medium ",children:"Your cart"})]}),r>=Re?m.jsxs(m.Fragment,{children:[m.jsxs("span",{className:"text-[var(--main-accent-color)] hidden text-xs sm:block",children:["(",Re,") You reached maximum amount of swatches"]}),m.jsxs("span",{className:"text-[var(--main-accent-color)] block sm:hidden",children:["(",Re,") Max"]})]}):null]}),m.jsx("button",{className:`flex flex-row justify-center items-center w-[30px] h-[30px] bg-[var(--background-grey)]
148
+ border-none cursor-pointer rounded-full
149
+ [&_svg_path]:stroke-[var(--svg-dark)]`,onClick:t,children:m.jsx(cr,{width:10,height:10})})]})},vs=e=>e.cart.items,VC=Ze.createSelector(vs,e=>e.reduce((t,n)=>t+n.count,0)),$C=Ze.createSelector(VC,e=>Math.max(0,Re-e)),qC=Ze.createSelector($C,e=>e>0),GC=()=>{const e=Pe(),t=oe($t)??[],n=oe(qC),r=i=>{e(xh({selectedMaterial:i})),e(ta({selectedMaterial:i,materialCount:1,selectedMaterials:t}))},a=i=>{e(yh({selectedMaterial:i}))},s=i=>{e(_h({selectedMaterial:i}))};return m.jsx("ul",{className:"flex flex-col flex-1 min-h-0 overflow-y-auto",children:t?.map(i=>m.jsx(Vl,{item:i,canInc:n,onDelete:()=>r(i),onIncrement:()=>a(i),onDecrement:()=>s(i)},`${i.assetId}/${i.parentName}`))})},XC=({isOpen:e,onToggleSidebar:t,onSetActiveTab:n,onSendData:r})=>{const a=oe(vs),s=oe(vs)??[];return m.jsxs(Ef,{isOpen:e,setIsOpen:t,children:[m.jsx(WC,{onSetActiveTab:n,onToggleSidebar:t}),m.jsxs("div",{className:"flex flex-col h-full min-h-0",children:[m.jsx(GC,{}),m.jsx(qu,{materials:s}),m.jsx("div",{className:"p-[var(--sm-padding)] border-t border-solid border-[var(--border)] shrink-0",children:m.jsx("button",{className:"w-full bg-[var(--main-accent-color)] text-white py-3 rounded-full font-bold cursor-pointer",onClick:()=>r(a),children:"GO TO SHIPPING"})})]})]})},KC=({isOpen:e,onToggleSidebar:t,onSendData:n})=>{const[r,a]=D.useState(Kr.SWATCH),s=i=>{a(i)};return m.jsx(m.Fragment,{children:r===Kr.SWATCH?m.jsx(YC,{isOpen:e,onToggleSidebar:t,onSetActiveTab:s}):m.jsx(XC,{isOpen:e,onToggleSidebar:t,onSetActiveTab:s,onSendData:n})})},QC=Ze.combineReducers({swatches:Hu,cart:zu,multiProductCart:Wu});let Qa=null;function ZC(){return Ze.configureStore({reducer:QC,devTools:!1,middleware:e=>e({thunk:!0})})}const JC=()=>(Qa||(Qa=ZC()),Qa),eA=Tn.useDispatch.withTypes();Tn.useSelector.withTypes();function Tf({children:e}){return m.jsx(Tn.Provider,{store:JC(),children:e})}const tA=({isOpen:e,uiDataType:t,data:n,assetId:r,onToggleSidebar:a,onSendData:s})=>{const o=[tt.UI,tt.FETCH_DATA_PRODUCT].includes(t),l=eA();return D.useEffect(()=>{if(t===tt.UI){if(!n)throw new Error("SwatchCart-module: Attributes are important");const c=us.getTransformedData({dataType:tt.UI,data:n});c&&l(ns(c))}else t===tt.FETCH_DATA_PRODUCT&&r?(async()=>{try{const d=await l(Vn({assetId:r})).unwrap(),f=us.getTransformedData({dataType:tt.FETCH_DATA_PRODUCT,data:d});l(ns(f))}catch(d){console.error("Failed to load product",d)}})():t===tt.FETCH_DATA_ALL&&(async()=>{try{l($n()).unwrap()}catch(d){console.error("Failed to load product",d)}})()},[t,n,r]),m.jsx("div",{id:"root-container",className:"relative flex flex-col h-full min-h-0 w-full",children:m.jsxs(Tf,{children:[m.jsx(mh,{position:"top-center",autoClose:5e3,hideProgressBar:!0,newestOnTop:!1,closeOnClick:!1,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,theme:"dark",transition:Bu}),e?m.jsxs(m.Fragment,{children:[o?null:m.jsx(LC,{onSendData:s,onToggleSidebar:a}),o?m.jsx(KC,{isOpen:e,uiDataType:t,data:n,assetId:r,onToggleSidebar:a,onSendData:s}):null]}):null]})})};function nA(e){const t=n=>m.jsx(Tf,{children:m.jsx(e,{...n})});return t.displayName=`withStore(${e.displayName||e.name||"Component"})`,t}const xf=nA(tA),rA=tt;function aA(e,t){const n=wf.createRoot(e);return n.render(D.createElement(xf,t)),()=>n.unmount()}exports.EDataInputType=rA;exports.SwatchModule=xf;exports.mountSwatchModule=aA;
150
+ //# sourceMappingURL=main.cjs.map