/*! For license information please see main.js.LICENSE.txt */ (()=>{var e,t,n={67:(e,t)=>{"use strict";t.YW=function(e,t={}){const{decode:f=decodeURIComponent,delimiter:p=n}=t,{regexp:h,keys:g}=function(e,t={}){const{delimiter:f=n,end:p=!0,sensitive:h=!1,trailing:g=!0}=t,y=[],v=[],b=h?"":"i",x=(Array.isArray(e)?e:[e]).map((e=>e instanceof u?e:function(e,t={}){const{encodePath:n=r}=t,l=new c(function*(e){const t=[...e];let n=0;function r(){let e="";if(o.test(t[++n]))for(e+=t[n];a.test(t[++n]);)e+=t[n];else if('"'===t[n]){let r=n;for(;n!1===f?r:"param"===e.type?f:e=>e.split(p).map(f)));return function(e){const t=h.exec(e);if(!t)return!1;const n=t[0],r=Object.create(null);for(let e=1;ee,o=/^[$_\p{ID_Start}]$/u,a=/^[$\u200c\u200d\p{ID_Continue}]$/u,i="https://git.new/pathToRegexpError",s={"{":"{","}":"}","(":"(",")":")","[":"[","]":"]","+":"+","?":"?","!":"!"};function l(e){return e.replace(/[.+*?^${}()[\]|/\\]/g,"\\$&")}class c{constructor(e){this.tokens=e}peek(){if(!this._peek){const e=this.tokens.next();this._peek=e.value}return this._peek}tryConsume(e){const t=this.peek();if(t.type===e)return this._peek=void 0,t.value}consume(e){const t=this.tryConsume(e);if(void 0!==t)return t;const{type:n,index:r}=this.peek();throw new TypeError(`Unexpected ${n} at ${r}, expected ${e}: ${i}`)}text(){let e,t="";for(;e=this.tryConsume("CHAR")||this.tryConsume("ESCAPED");)t+=e;return t}}class u{constructor(e){this.tokens=e}}function*d(e,t,n){if(t===e.length)return yield n;const r=e[t];if("group"===r.type){const o=n.slice();for(const n of d(r.tokens,0,o))yield*d(e,t+1,n)}else n.push(r);yield*d(e,t+1,n)}function m(e,t,n){let r="",o="",a=!0;for(let s=0;s{"use strict";var r=n(795);t.H=r.createRoot,r.hydrateRoot},795:e=>{"use strict";e.exports=window.ReactDOM},942:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e="",t=0;t{"use strict";var n=Object.prototype.hasOwnProperty;function r(e){try{return decodeURIComponent(e.replace(/\+/g," "))}catch(e){return null}}function o(e){try{return encodeURIComponent(e)}catch(e){return null}}t.stringify=function(e,t){t=t||"";var r,a,i=[];for(a in"string"!=typeof t&&(t="?"),e)if(n.call(e,a)){if((r=e[a])||null!=r&&!isNaN(r)||(r=""),a=o(a),r=o(r),null===a||null===r)continue;i.push(a+"="+r)}return i.length?t+i.join("&"):""},t.parse=function(e){for(var t,n=/([^=?#&]+)=?([^&]*)/g,o={};t=n.exec(e);){var a=r(t[1]),i=r(t[2]);null===a||null===i||a in o||(o[a]=i)}return o}}},r={};function o(e){var t=r[e];if(void 0!==t)return t.exports;var a=r[e]={exports:{}};return n[e](a,a.exports,o),a.exports}o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},t=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,o.t=function(n,r){if(1&r&&(n=this(n)),8&r)return n;if("object"==typeof n&&n){if(4&r&&n.__esModule)return n;if(16&r&&"function"==typeof n.then)return n}var a=Object.create(null);o.r(a);var i={};e=e||[null,t({}),t([]),t(t)];for(var s=2&r&&n;"object"==typeof s&&!~e.indexOf(s);s=t(s))Object.getOwnPropertyNames(s).forEach((e=>i[e]=()=>n[e]));return i.default=()=>n,o.d(a,i),a},o.d=(e,t)=>{for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{"use strict";var e=o(338);const t=window.wp.domReady;var n=o.n(t);function r(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n=0&&(t.hash=e.substr(n),e=e.substr(0,n));var r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}(e):e,{state:t,key:Math.random().toString(36).substr(2,8)})}function p(e,t){return[{usr:e.state,key:e.key,idx:t},m(e)]}function h(e,t,n){return!d.length||(d.call({action:e,location:t,retry:n}),!1)}function g(e){i=e;var t=o();l=t[0],c=t[1],u.call({action:i,location:c})}function v(e){r.go(e)}return null==l&&(l=0,r.replaceState(x({},r.state,{idx:l}),"")),{get action(){return i},get location(){return c},createHref:m,push:function e(t,o){var a=y.Push,i=f(t,o);if(h(a,i,(function(){e(t,o)}))){var s=p(i,l+1),c=s[0],u=s[1];try{r.pushState(c,"",u)}catch(e){n.location.assign(u)}g(a)}},replace:function e(t,n){var o=y.Replace,a=f(t,n);if(h(o,a,(function(){e(t,n)}))){var i=p(a,l),s=i[0],c=i[1];r.replaceState(s,"",c),g(o)}},go:v,back:function(){v(-1)},forward:function(){v(1)},listen:function(e){return u.push(e)},block:function(e){var t=d.push(e);return 1===d.length&&n.addEventListener(w,E),function(){t(),d.length||n.removeEventListener(w,E)}}}}(),S=wp.element.createContext({route:b(k.location)}),N=o(67),C=wp.element.useContext,P="";function T(e){var t=e.path,n=e.onRoute,r=e.children,o=C(S).route,a=(0,N.YW)("".concat(t))("".concat(o.hash.substr(1)));return a?(n&&(P!==a.path&&n(),P=a.path),React.createElement("div",null,wp.element.cloneElement(r,{route:a}))):null}var j=o(942),A=o.n(j);function R(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var F=wp.element.useContext;function D(e){var t=e.to,n=e.onClick,r=e.children,o=e.activeClassName,a=F(S).route,i=function(e){for(var t=1;t{const t=U(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:e=>{const n=e.split("-");return""===n[0]&&1!==n.length&&n.shift(),z(n,t)||V(e)},getConflictingClassGroupIds:(e,t)=>{const o=n[e]||[];return t&&r[e]?[...o,...r[e]]:o}}},z=(e,t)=>{if(0===e.length)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),o=r?z(e.slice(1),r):void 0;if(o)return o;if(0===t.validators.length)return;const a=e.join("-");return t.validators.find((({validator:e})=>e(a)))?.classGroupId},B=/^\[(.+)\]$/,V=e=>{if(B.test(e)){const t=B.exec(e)[1],n=t?.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},U=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return q(Object.entries(e.classGroups),n).forEach((([e,n])=>{W(n,r,e,t)})),r},W=(e,t,n,r)=>{e.forEach((e=>{if("string"!=typeof e){if("function"==typeof e)return $(e)?void W(e(r),t,n,r):void t.validators.push({validator:e,classGroupId:n});Object.entries(e).forEach((([e,o])=>{W(o,H(t,e),n,r)}))}else(""===e?t:H(t,e)).classGroupId=n}))},H=(e,t)=>{let n=e;return t.split("-").forEach((e=>{n.nextPart.has(e)||n.nextPart.set(e,{nextPart:new Map,validators:[]}),n=n.nextPart.get(e)})),n},$=e=>e.isThemeGetter,q=(e,t)=>t?e.map((([e,n])=>[e,n.map((e=>"string"==typeof e?t+e:"object"==typeof e?Object.fromEntries(Object.entries(e).map((([e,n])=>[t+e,n]))):e))])):e,Y=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const o=(o,a)=>{n.set(o,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(e){let t=n.get(e);return void 0!==t?t:void 0!==(t=r.get(e))?(o(e,t),t):void 0},set(e,t){n.has(e)?n.set(e,t):o(e,t)}}},G=e=>{const{separator:t,experimentalParseClassName:n}=e,r=1===t.length,o=t[0],a=t.length,i=e=>{const n=[];let i,s=0,l=0;for(let c=0;cl?i-l:void 0}};return n?e=>n({className:e,parseClassName:i}):i},X=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach((e=>{"["===e[0]?(t.push(...n.sort(),e),n=[]):n.push(e)})),t.push(...n.sort()),t},K=/\s+/;function J(){let e,t,n=0,r="";for(;n{if("string"==typeof e)return e;let t,n="";for(let r=0;rt(e)),e());return n=(e=>({cache:Y(e.cacheSize),parseClassName:G(e),...L(e)}))(l),r=n.cache.get,o=n.cache.set,a=i,i(s)};function i(e){const t=r(e);if(t)return t;const a=((e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=t,a=[],i=e.trim().split(K);let s="";for(let e=i.length-1;e>=0;e-=1){const t=i[e],{modifiers:l,hasImportantModifier:c,baseClassName:u,maybePostfixModifierPosition:d}=n(t);let m=Boolean(d),f=r(m?u.substring(0,d):u);if(!f){if(!m){s=t+(s.length>0?" "+s:s);continue}if(f=r(u),!f){s=t+(s.length>0?" "+s:s);continue}m=!1}const p=X(l).join(":"),h=c?p+"!":p,g=h+f;if(a.includes(g))continue;a.push(g);const y=o(f,m);for(let e=0;e0?" "+s:s)}return s})(e,n);return o(e,a),a}return function(){return a(J.apply(null,arguments))}}const ee=e=>{const t=t=>t[e]||[];return t.isThemeGetter=!0,t},te=/^\[(?:([a-z-]+):)?(.+)\]$/i,ne=/^\d+\/\d+$/,re=new Set(["px","full","screen"]),oe=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,ae=/\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$/,ie=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,se=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,le=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,ce=e=>de(e)||re.has(e)||ne.test(e),ue=e=>ke(e,"length",Se),de=e=>Boolean(e)&&!Number.isNaN(Number(e)),me=e=>ke(e,"number",de),fe=e=>Boolean(e)&&Number.isInteger(Number(e)),pe=e=>e.endsWith("%")&&de(e.slice(0,-1)),he=e=>te.test(e),ge=e=>oe.test(e),ye=new Set(["length","size","percentage"]),ve=e=>ke(e,ye,Ne),be=e=>ke(e,"position",Ne),xe=new Set(["image","url"]),we=e=>ke(e,xe,Pe),Ee=e=>ke(e,"",Ce),_e=()=>!0,ke=(e,t,n)=>{const r=te.exec(e);return!!r&&(r[1]?"string"==typeof t?r[1]===t:t.has(r[1]):n(r[2]))},Se=e=>ae.test(e)&&!ie.test(e),Ne=()=>!1,Ce=e=>se.test(e),Pe=e=>le.test(e),Te=(Symbol.toStringTag,()=>{const e=ee("colors"),t=ee("spacing"),n=ee("blur"),r=ee("brightness"),o=ee("borderColor"),a=ee("borderRadius"),i=ee("borderSpacing"),s=ee("borderWidth"),l=ee("contrast"),c=ee("grayscale"),u=ee("hueRotate"),d=ee("invert"),m=ee("gap"),f=ee("gradientColorStops"),p=ee("gradientColorStopPositions"),h=ee("inset"),g=ee("margin"),y=ee("opacity"),v=ee("padding"),b=ee("saturate"),x=ee("scale"),w=ee("sepia"),E=ee("skew"),_=ee("space"),k=ee("translate"),S=()=>["auto",he,t],N=()=>[he,t],C=()=>["",ce,ue],P=()=>["auto",de,he],T=()=>["","0",he],j=()=>[de,he];return{cacheSize:500,separator:":",theme:{colors:[_e],spacing:[ce,ue],blur:["none","",ge,he],brightness:j(),borderColor:[e],borderRadius:["none","","full",ge,he],borderSpacing:N(),borderWidth:C(),contrast:j(),grayscale:T(),hueRotate:j(),invert:T(),gap:N(),gradientColorStops:[e],gradientColorStopPositions:[pe,ue],inset:S(),margin:S(),opacity:j(),padding:N(),saturate:j(),scale:j(),sepia:T(),skew:j(),space:N(),translate:N()},classGroups:{aspect:[{aspect:["auto","square","video",he]}],container:["container"],columns:[{columns:[ge]}],"break-after":[{"break-after":["auto","avoid","all","avoid-page","page","left","right","column"]}],"break-before":[{"break-before":["auto","avoid","all","avoid-page","page","left","right","column"]}],"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"],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:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",he]}],overflow:[{overflow:["auto","hidden","clip","visible","scroll"]}],"overflow-x":[{"overflow-x":["auto","hidden","clip","visible","scroll"]}],"overflow-y":[{"overflow-y":["auto","hidden","clip","visible","scroll"]}],overscroll:[{overscroll:["auto","contain","none"]}],"overscroll-x":[{"overscroll-x":["auto","contain","none"]}],"overscroll-y":[{"overscroll-y":["auto","contain","none"]}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[h]}],"inset-x":[{"inset-x":[h]}],"inset-y":[{"inset-y":[h]}],start:[{start:[h]}],end:[{end:[h]}],top:[{top:[h]}],right:[{right:[h]}],bottom:[{bottom:[h]}],left:[{left:[h]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",fe,he]}],basis:[{basis:S()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",he]}],grow:[{grow:T()}],shrink:[{shrink:T()}],order:[{order:["first","last","none",fe,he]}],"grid-cols":[{"grid-cols":[_e]}],"col-start-end":[{col:["auto",{span:["full",fe,he]},he]}],"col-start":[{"col-start":P()}],"col-end":[{"col-end":P()}],"grid-rows":[{"grid-rows":[_e]}],"row-start-end":[{row:["auto",{span:[fe,he]},he]}],"row-start":[{"row-start":P()}],"row-end":[{"row-end":P()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",he]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",he]}],gap:[{gap:[m]}],"gap-x":[{"gap-x":[m]}],"gap-y":[{"gap-y":[m]}],"justify-content":[{justify:["normal","start","end","center","between","around","evenly","stretch"]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal","start","end","center","between","around","evenly","stretch","baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":["start","end","center","between","around","evenly","stretch","baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[_]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[_]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",he,t]}],"min-w":[{"min-w":[he,t,"min","max","fit"]}],"max-w":[{"max-w":[he,t,"none","full","min","max","fit","prose",{screen:[ge]},ge]}],h:[{h:[he,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[he,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[he,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[he,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ge,ue]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",me]}],"font-family":[{font:[_e]}],"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:["tighter","tight","normal","wide","wider","widest",he]}],"line-clamp":[{"line-clamp":["none",de,me]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",ce,he]}],"list-image":[{"list-image":["none",he]}],"list-style-type":[{list:["none","disc","decimal",he]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:["solid","dashed","dotted","double","none","wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",ce,ue]}],"underline-offset":[{"underline-offset":["auto",ce,he]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:N()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",he]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",he]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top",be]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",ve]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},we]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[p]}],"gradient-via-pos":[{via:[p]}],"gradient-to-pos":[{to:[p]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:["solid","dashed","dotted","double","none","hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}],"divide-style":[{divide:["solid","dashed","dotted","double","none"]}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["","solid","dashed","dotted","double","none"]}],"outline-offset":[{"outline-offset":[ce,he]}],"outline-w":[{outline:[ce,ue]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:C()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[ce,ue]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ge,Ee]}],"shadow-color":[{shadow:[_e]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity","plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"]}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",ge,he]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[b]}],sepia:[{sepia:[w]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[b]}],"backdrop-sepia":[{"backdrop-sepia":[w]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",he]}],duration:[{duration:j()}],ease:[{ease:["linear","in","out","in-out",he]}],delay:[{delay:j()}],animate:[{animate:["none","spin","ping","pulse","bounce",he]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[x]}],"scale-x":[{"scale-x":[x]}],"scale-y":[{"scale-y":[x]}],rotate:[{rotate:[fe,he]}],"translate-x":[{"translate-x":[k]}],"translate-y":[{"translate-y":[k]}],"skew-x":[{"skew-x":[E]}],"skew-y":[{"skew-y":[E]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",he]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],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",he]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":N()}],"scroll-mx":[{"scroll-mx":N()}],"scroll-my":[{"scroll-my":N()}],"scroll-ms":[{"scroll-ms":N()}],"scroll-me":[{"scroll-me":N()}],"scroll-mt":[{"scroll-mt":N()}],"scroll-mr":[{"scroll-mr":N()}],"scroll-mb":[{"scroll-mb":N()}],"scroll-ml":[{"scroll-ml":N()}],"scroll-p":[{"scroll-p":N()}],"scroll-px":[{"scroll-px":N()}],"scroll-py":[{"scroll-py":N()}],"scroll-ps":[{"scroll-ps":N()}],"scroll-pe":[{"scroll-pe":N()}],"scroll-pt":[{"scroll-pt":N()}],"scroll-pr":[{"scroll-pr":N()}],"scroll-pb":[{"scroll-pb":N()}],"scroll-pl":[{"scroll-pl":N()}],"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",he]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[ce,ue,me]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"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-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-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"],"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"]}}}),je=Q(Te);function Ae(e){var t,n,r="";if("string"==typeof e||"number"==typeof e)r+=e;else if("object"==typeof e)if(Array.isArray(e)){var o=e.length;for(t=0;tje(Re(...e)),De=(...e)=>(...t)=>e.forEach((e=>e?.(...t))),Me=e=>{const t={0:"gap-0",xxs:"gap-1",xs:"gap-2",sm:"gap-3",md:"gap-4",lg:"gap-5",xl:"gap-6","2xl":"gap-8"};return t[e]||t.md},Oe={sm:{1:"grid-cols-1",2:"grid-cols-2",3:"grid-cols-3",4:"grid-cols-4",5:"grid-cols-5",6:"grid-cols-6",7:"grid-cols-7",8:"grid-cols-8",9:"grid-cols-9",10:"grid-cols-10",11:"grid-cols-11",12:"grid-cols-12"},md:{1:"md:grid-cols-1",2:"md:grid-cols-2",3:"md:grid-cols-3",4:"md:grid-cols-4",5:"md:grid-cols-5",6:"md:grid-cols-6",7:"md:grid-cols-7",8:"md:grid-cols-8",9:"md:grid-cols-9",10:"md:grid-cols-10",11:"md:grid-cols-11",12:"md:grid-cols-12"},lg:{1:"lg:grid-cols-1",2:"lg:grid-cols-2",3:"lg:grid-cols-3",4:"lg:grid-cols-4",5:"lg:grid-cols-5",6:"lg:grid-cols-6",7:"lg:grid-cols-7",8:"lg:grid-cols-8",9:"lg:grid-cols-9",10:"lg:grid-cols-10",11:"lg:grid-cols-11",12:"lg:grid-cols-12"}},Ie={sm:{xs:"gap-2",sm:"gap-4",md:"gap-5",lg:"gap-6",xl:"gap-6","2xl":"gap-8"},md:{xs:"md:gap-2",sm:"md:gap-4",md:"md:gap-5",lg:"md:gap-6",xl:"md:gap-6","2xl":"md:gap-8"},lg:{xs:"lg:gap-2",sm:"lg:gap-4",md:"lg:gap-5",lg:"lg:gap-6",xl:"lg:gap-6","2xl":"lg:gap-8"}},Le={sm:{xs:"gap-x-2",sm:"gap-x-4",md:"gap-x-5",lg:"gap-x-6",xl:"gap-x-6","2xl":"gap-x-8"},md:{xs:"md:gap-x-2",sm:"md:gap-x-4",md:"md:gap-x-5",lg:"md:gap-x-6",xl:"md:gap-x-6","2xl":"md:gap-x-8"},lg:{xs:"lg:gap-x-2",sm:"lg:gap-x-4",md:"lg:gap-x-5",lg:"lg:gap-x-6",xl:"lg:gap-x-6","2xl":"lg:gap-x-8"}},ze={sm:{xs:"gap-y-2",sm:"gap-y-4",md:"gap-y-5",lg:"gap-y-6",xl:"gap-y-6","2xl":"gap-y-8"},md:{xs:"md:gap-y-2",sm:"md:gap-y-4",md:"md:gap-y-5",lg:"md:gap-y-6",xl:"md:gap-y-6","2xl":"md:gap-y-8"},lg:{xs:"lg:gap-y-2",sm:"lg:gap-y-4",md:"lg:gap-y-5",lg:"lg:gap-y-6",xl:"lg:gap-y-6","2xl":"lg:gap-y-8"}},Be={sm:{1:"col-span-1",2:"col-span-2",3:"col-span-3",4:"col-span-4",5:"col-span-5",6:"col-span-6",7:"col-span-7",8:"col-span-8",9:"col-span-9",10:"col-span-10",11:"col-span-11",12:"col-span-12"},md:{1:"md:col-span-1",2:"md:col-span-2",3:"md:col-span-3",4:"md:col-span-4",5:"md:col-span-5",6:"md:col-span-6",7:"md:col-span-7",8:"md:col-span-8",9:"md:col-span-9",10:"md:col-span-10",11:"md:col-span-11",12:"md:col-span-12"},lg:{1:"lg:col-span-1",2:"lg:col-span-2",3:"lg:col-span-3",4:"lg:col-span-4",5:"lg:col-span-5",6:"lg:col-span-6",7:"lg:col-span-7",8:"lg:col-span-8",9:"lg:col-span-9",10:"lg:col-span-10",11:"lg:col-span-11",12:"lg:col-span-12"}},Ve={sm:{1:"col-start-1",2:"col-start-2",3:"col-start-3",4:"col-start-4",5:"col-start-5",6:"col-start-6",7:"col-start-7",8:"col-start-8",9:"col-start-9",10:"col-start-10",11:"col-start-11",12:"col-start-12"},md:{1:"md:col-start-1",2:"md:col-start-2",3:"md:col-start-3",4:"md:col-start-4",5:"md:col-start-5",6:"md:col-start-6",7:"md:col-start-7",8:"md:col-start-8",9:"md:col-start-9",10:"md:col-start-10",11:"md:col-start-11",12:"md:col-start-12"},lg:{1:"lg:col-start-1",2:"lg:col-start-2",3:"lg:col-start-3",4:"lg:col-start-4",5:"lg:col-start-5",6:"lg:col-start-6",7:"lg:col-start-7",8:"lg:col-start-8",9:"lg:col-start-9",10:"lg:col-start-10",11:"lg:col-start-11",12:"lg:col-start-12"}},Ue={sm:{row:"grid-flow-row",column:"grid-flow-col","row-dense":"grid-flow-row-dense","column-dense":"grid-flow-col-dense"},md:{row:"md:grid-flow-row",column:"md:grid-flow-col","row-dense":"md:grid-flow-row-dense","column-dense":"md:grid-flow-col-dense"},lg:{row:"lg:grid-flow-row",column:"lg:grid-flow-col","row-dense":"lg:grid-flow-row-dense","column-dense":"lg:grid-flow-col-dense"}},We={sm:{normal:"justify-normal",start:"justify-start",end:"justify-end",center:"justify-center",between:"justify-between",around:"justify-around",evenly:"justify-evenly",stretch:"justify-stretch"},md:{normal:"md:justify-normal",start:"md:justify-start",end:"md:justify-end",center:"md:justify-center",between:"md:justify-between",around:"md:justify-around",evenly:"md:justify-evenly",stretch:"md:justify-stretch"},lg:{normal:"lg:justify-normal",start:"lg:justify-start",end:"lg:justify-end",center:"lg:justify-center",between:"lg:justify-between",around:"lg:justify-around",evenly:"lg:justify-evenly",stretch:"lg:justify-stretch"}},He={sm:{start:"items-start",end:"items-end",center:"items-center",baseline:"items-baseline",stretch:"items-stretch"},md:{start:"md:items-start",end:"md:items-end",center:"md:items-center",baseline:"md:items-baseline",stretch:"md:items-stretch"},lg:{start:"lg:items-start",end:"lg:items-end",center:"lg:items-center",baseline:"lg:items-baseline",stretch:"lg:items-stretch"}},$e={sm:{start:"self-start",end:"self-end",center:"self-center",baseline:"self-baseline",stretch:"self-stretch"},md:{start:"md:self-start",end:"md:self-end",center:"md:self-center",baseline:"md:self-baseline",stretch:"md:self-stretch"},lg:{start:"lg:self-start",end:"lg:self-end",center:"lg:self-center",baseline:"lg:self-baseline",stretch:"lg:self-stretch"}},qe={sm:{auto:"justify-self-auto",start:"justify-self-start",end:"justify-self-end",center:"justify-self-center",baseline:"justify-self-baseline",stretch:"justify-self-stretch"},md:{auto:"md:justify-self-auto",start:"md:justify-self-start",end:"md:justify-self-end",center:"md:justify-self-center",baseline:"md:justify-self-baseline",stretch:"md:justify-self-stretch"},lg:{auto:"lg:justify-self-auto",start:"lg:justify-self-start",end:"lg:justify-self-end",center:"lg:justify-self-center",baseline:"lg:justify-self-baseline",stretch:"lg:justify-self-stretch"}},Ye={sm:{row:"flex-row","row-reverse":"flex-row-reverse",column:"flex-col","column-reverse":"flex-col-reverse"},md:{row:"md:flex-row","row-reverse":"md:flex-row-reverse",column:"md:flex-col","column-reverse":"md:flex-col-reverse"},lg:{row:"lg:flex-row","row-reverse":"lg:flex-row-reverse",column:"lg:flex-col","column-reverse":"lg:flex-col-reverse"}},Ge={sm:{wrap:"flex-wrap","wrap-reverse":"flex-wrap-reverse",nowrap:"flex-nowrap"},md:{wrap:"md:flex-wrap","wrap-reverse":"md:flex-wrap-reverse",nowrap:"md:flex-nowrap"},lg:{wrap:"lg:flex-wrap","wrap-reverse":"lg:flex-wrap-reverse",nowrap:"lg:flex-nowrap"}},Xe={sm:{1:"w-full",2:"w-1/2",3:"w-1/3",4:"w-1/4",5:"w-1/5",6:"w-1/6",7:"w-1/7",8:"w-1/8",9:"w-1/9",10:"w-1/10",11:"w-1/11",12:"w-1/12"},md:{1:"md:w-full",2:"md:w-1/2",3:"md:w-1/3",4:"md:w-1/4",5:"md:w-1/5",6:"md:w-1/6",7:"md:w-1/7",8:"md:w-1/8",9:"md:w-1/9",10:"md:w-1/10",11:"md:w-1/11",12:"md:w-1/12"},lg:{1:"lg:w-full",2:"lg:w-1/2",3:"lg:w-1/3",4:"lg:w-1/4",5:"lg:w-1/5",6:"lg:w-1/6",7:"lg:w-1/7",8:"lg:w-1/8",9:"lg:w-1/9",10:"lg:w-1/10",11:"lg:w-1/11",12:"lg:w-1/12"}},Ke={sm:{1:"order-1",2:"order-2",3:"order-3",4:"order-4",5:"order-5",6:"order-6",7:"order-7",8:"order-8",9:"order-9",10:"order-10",11:"order-11",12:"order-12",first:"order-first",last:"order-last",none:"order-none"},md:{1:"md:order-1",2:"md:order-2",3:"md:order-3",4:"md:order-4",5:"md:order-5",6:"md:order-6",7:"md:order-7",8:"md:order-8",9:"md:order-9",10:"md:order-10",11:"md:order-11",12:"md:order-12",first:"md:order-first",last:"md:order-last",none:"md:order-none"},lg:{1:"lg:order-1",2:"lg:order-2",3:"lg:order-3",4:"lg:order-4",5:"lg:order-5",6:"lg:order-6",7:"lg:order-7",8:"lg:order-8",9:"lg:order-9",10:"lg:order-10",11:"lg:order-11",12:"lg:order-12",first:"lg:order-first",last:"lg:order-last",none:"lg:order-none"}},Je={sm:{0:"grow-0",1:"grow"},md:{0:"md:grow-0",1:"md:grow"},lg:{0:"lg:grow-0",1:"lg:grow"}},Ze={sm:{0:"shrink-0",1:"shrink"},md:{0:"md:shrink-0",1:"md:shrink"},lg:{0:"lg:shrink-0",1:"lg:shrink"}},Qe=(e,t,n,r="sm")=>{const o=[];switch(typeof e){case"object":for(const[r,a]of Object.entries(e))t[r]&&o.push(t?.[r]?.[a]??t?.[r]?.[n?.[r]]??"");break;case"string":case"number":const a=r;o.push(t?.[a]?.[e]??t?.[a]?.[n?.[a]]??"");break;default:if(void 0===e)break;o.push(t?.[r]?.[n]??"")}return o.join(" ")},et=({className:e,cols:t,gap:n,gapX:r,gapY:o,align:a,justify:i,gridFlow:s,colsSubGrid:l=!1,rowsSubGrid:c=!1,autoRows:u=!1,autoCols:d=!1,children:m,...f})=>{const p=Qe(t,Oe,1),h=Qe(n,Ie,"sm"),g=Qe(r,Le,""),y=Qe(o,ze,""),v=Qe(a,He,""),b=Qe(i,We,""),x=Qe(s,Ue,"");return(0,I.jsx)("div",{className:Fe("grid",{"grid-cols-subgrid":l,"grid-rows-subgrid":c,"auto-cols-auto":d,"auto-rows-auto":u},p,h,g,y,v,b,x,e),...f,children:m})};et.Item=({className:e,children:t,colSpan:n,colStart:r,alignSelf:o,justifySelf:a,...i})=>{const s=Qe(n,Be,0),l=Qe(r,Ve,0),c=Qe(o,$e,""),u=Qe(a,qe,"");return(0,I.jsx)("div",{className:Fe(s,l,c,u,e),...i,children:t})};const tt=(0,s.createContext)({}),nt=({containerType:e="flex",gap:t="sm",gapX:n,gapY:r,direction:o,justify:a,align:i,wrap:s,cols:l,className:c,children:u,...d})=>{if("grid"===e)return(0,I.jsx)(tt.Provider,{value:{containerType:e},children:(0,I.jsx)(et,{className:c,gap:t,gapX:n,gapY:r,cols:l,children:u,align:i,justify:a,...d})});const m=Qe(s,Ge,""),f=Qe(t,Ie,"sm"),p=Qe(n,Le,""),h=Qe(r,ze,""),g=Qe(o,Ye,""),y=Qe(a,We,""),v=Qe(i,He,""),b=Fe("flex",m,f,p,h,g,y,v,c);return(0,I.jsx)(tt.Provider,{value:{containerType:e,cols:l},children:"flex"===e?(0,I.jsx)("div",{className:b,children:u}):(0,I.jsx)(et,{className:c,gap:t,gapX:n,gapY:r,cols:l,children:u,align:i,justify:a,...d})})},rt=({grow:e,shrink:t,order:n,alignSelf:r,justifySelf:o,className:a,children:i,...l})=>{const{containerType:c,cols:u}=(0,s.useContext)(tt);if("grid"===c)return(0,I.jsx)(et.Item,{className:a,alignSelf:r,justifySelf:o,children:i,...l});const d=Qe(r,$e,""),m=Qe(o,qe,""),f=Qe(e,Je,0),p=Qe(t,Ze,0),h=Qe(n,Ke,0),g=Qe(u,Xe,1);return(0,I.jsx)("div",{className:Fe("box-border",f,p,h,d,m,g,a),children:i})};nt.Item=rt,nt.displayName="Container",rt.displayName="Container.Item";const ot=({children:e,gap:t="lg",className:n,...r})=>(0,I.jsx)("div",{className:Fe("w-full box-border flex items-center justify-between bg-background-primary p-5 min-h-16",Me(t),n),...r,children:e});ot.displayName="Topbar";const at=({gap:e="sm",children:t,className:n})=>(0,I.jsx)("div",{className:Fe("flex items-center",Me(e),n),children:t});at.displayName="Topbar.Left";const it=({gap:e="md",children:t,align:n="center",className:r})=>{const o={left:"justify-start",center:"justify-center",right:"justify-end"}[n];return(0,I.jsx)("div",{className:Fe("flex items-center grow",Me(e),o,r),children:t})};it.displayName="Topbar.Middle";const st=({gap:e="sm",children:t,className:n})=>(0,I.jsx)("div",{className:Fe("flex items-center",Me(e),n),children:t});st.displayName="Topbar.Right";const lt=({children:e,className:t})=>(0,I.jsx)("div",{className:Fe("flex items-center [&>svg]:block h-full",t),children:e});lt.displayName="Topbar.Item",ot.Left=at,ot.Middle=it,ot.Right=st,ot.Item=lt;const ct=(0,s.forwardRef)(((e,t)=>{const{variant:n="primary",size:r="md",type:o="button",tag:a="button",className:i,children:l,disabled:c=!1,destructive:u=!1,icon:d=null,iconPosition:m="left",loading:f=!1,...p}=e,h=u&&"focus:ring-focus-error",g=f?"opacity-50 disabled:cursor-not-allowed":"",y={primary:"text-text-on-color bg-button-primary hover:bg-button-primary-hover outline-button-primary hover:outline-button-primary-hover shadow-xs disabled:shadow-none focus:shadow-none disabled:bg-button-disabled disabled:outline-button-disabled",secondary:"text-text-on-color bg-button-secondary hover:bg-button-secondary-hover outline-button-secondary hover:outline-button-secondary-hover shadow-xs focus:shadow-none disabled:shadow-none disabled:bg-button-disabled disabled:outline-button-disabled",outline:"text-button-tertiary-color outline-border-subtle bg-button-tertiary shadow-sm focus:shadow-none hover:bg-button-tertiary-hover hover:outline-border-subtle disabled:bg-button-tertiary disabled:outline-border-disabled",ghost:"text-text-primary bg-transparent outline-transparent hover:bg-button-tertiary-hover",link:"outline-none text-link-primary bg-transparent hover:text-link-primary-hover hover:underline p-0 border-0 leading-none"}[n],v=u&&!c?{primary:"bg-button-danger hover:bg-button-danger-hover outline-button-danger hover:outline-button-danger-hover",secondary:"bg-button-danger hover:bg-button-danger-hover outline-button-danger hover:outline-button-danger-hover",outline:"text-button-danger outline outline-1 outline-button-danger hover:outline-button-danger bg-button-tertiary hover:bg-field-background-error",ghost:"text-button-danger hover:bg-field-background-error",link:"text-button-danger hover:text-button-danger-secondary"}[n]:"",b={xs:"p-1 rounded [&>svg]:size-4",sm:"p-2 rounded [&>svg]:size-4 gap-0.5",md:"p-2.5 rounded-md text-sm [&>svg]:size-5 gap-1",lg:"p-3 rounded-lg text-base [&>svg]:size-6 gap-1"}[r];let x,w=null,E="";return d&&(E="flex items-center justify-center","left"===m?x=d:w=d),(0,I.jsxs)(a,{ref:t,type:o,className:Fe(E,"outline outline-1 border-none cursor-pointer transition-colors duration-300 ease-in-out text-xs font-semibold focus:ring-2 focus:ring-toggle-on focus:ring-offset-2 disabled:text-text-disabled",b,y,v,h,g,{"cursor-default":c},i),disabled:c,...p,children:[(0,I.jsx)(s.Fragment,{children:x},"left-icon"),l?(0,I.jsx)("span",{className:"px-1",children:l}):null,(0,I.jsx)(s.Fragment,{children:w},"right-icon")]})}));function ut(){return"undefined"!=typeof window}function dt(e){return pt(e)?(e.nodeName||"").toLowerCase():"#document"}function mt(e){var t;return(null==e||null==(t=e.ownerDocument)?void 0:t.defaultView)||window}function ft(e){var t;return null==(t=(pt(e)?e.ownerDocument:e.document)||window.document)?void 0:t.documentElement}function pt(e){return!!ut()&&(e instanceof Node||e instanceof mt(e).Node)}function ht(e){return!!ut()&&(e instanceof Element||e instanceof mt(e).Element)}function gt(e){return!!ut()&&(e instanceof HTMLElement||e instanceof mt(e).HTMLElement)}function yt(e){return!(!ut()||"undefined"==typeof ShadowRoot)&&(e instanceof ShadowRoot||e instanceof mt(e).ShadowRoot)}function vt(e){const{overflow:t,overflowX:n,overflowY:r,display:o}=kt(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!["inline","contents"].includes(o)}function bt(e){return["table","td","th"].includes(dt(e))}function xt(e){return[":popover-open",":modal"].some((t=>{try{return e.matches(t)}catch(e){return!1}}))}function wt(e){const t=Et(),n=ht(e)?kt(e):e;return["transform","translate","scale","rotate","perspective"].some((e=>!!n[e]&&"none"!==n[e]))||!!n.containerType&&"normal"!==n.containerType||!t&&!!n.backdropFilter&&"none"!==n.backdropFilter||!t&&!!n.filter&&"none"!==n.filter||["transform","translate","scale","rotate","perspective","filter"].some((e=>(n.willChange||"").includes(e)))||["paint","layout","strict","content"].some((e=>(n.contain||"").includes(e)))}function Et(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function _t(e){return["html","body","#document"].includes(dt(e))}function kt(e){return mt(e).getComputedStyle(e)}function St(e){return ht(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Nt(e){if("html"===dt(e))return e;const t=e.assignedSlot||e.parentNode||yt(e)&&e.host||ft(e);return yt(t)?t.host:t}function Ct(e){const t=Nt(e);return _t(t)?e.ownerDocument?e.ownerDocument.body:e.body:gt(t)&&vt(t)?t:Ct(t)}function Pt(e,t,n){var r;void 0===t&&(t=[]),void 0===n&&(n=!0);const o=Ct(e),a=o===(null==(r=e.ownerDocument)?void 0:r.body),i=mt(o);if(a){const e=Tt(i);return t.concat(i,i.visualViewport||[],vt(o)?o:[],e&&n?Pt(e):[])}return t.concat(o,Pt(o,[],n))}function Tt(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function jt(e){let t=e.activeElement;for(;null!=(null==(n=t)||null==(n=n.shadowRoot)?void 0:n.activeElement);){var n;t=t.shadowRoot.activeElement}return t}function At(e,t){if(!e||!t)return!1;const n=null==t.getRootNode?void 0:t.getRootNode();if(e.contains(t))return!0;if(n&&yt(n)){let n=t;for(;n;){if(e===n)return!0;n=n.parentNode||n.host}}return!1}function Rt(){const e=navigator.userAgentData;return null!=e&&e.platform?e.platform:navigator.platform}function Ft(){const e=navigator.userAgentData;return e&&Array.isArray(e.brands)?e.brands.map((e=>{let{brand:t,version:n}=e;return t+"/"+n})).join(" "):navigator.userAgent}function Dt(){return/apple/i.test(navigator.vendor)}function Mt(){const e=/android/i;return e.test(Rt())||e.test(Ft())}function Ot(e,t){const n=["mouse","pen"];return t||n.push("",void 0),n.includes(e)}function It(e){return(null==e?void 0:e.ownerDocument)||document}function Lt(e,t){if(null==t)return!1;if("composedPath"in e)return e.composedPath().includes(t);const n=e;return null!=n.target&&t.contains(n.target)}function zt(e){return"composedPath"in e?e.composedPath()[0]:e.target}function Bt(e){return gt(e)&&e.matches("input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])")}ct.displayName="Button";var Vt=["input:not([inert])","select:not([inert])","textarea:not([inert])","a[href]:not([inert])","button:not([inert])","[tabindex]:not(slot):not([inert])","audio[controls]:not([inert])","video[controls]:not([inert])",'[contenteditable]:not([contenteditable="false"]):not([inert])',"details>summary:first-of-type:not([inert])","details:not([inert])"].join(","),Ut="undefined"==typeof Element,Wt=Ut?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector,Ht=!Ut&&Element.prototype.getRootNode?function(e){var t;return null==e||null===(t=e.getRootNode)||void 0===t?void 0:t.call(e)}:function(e){return null==e?void 0:e.ownerDocument},$t=function e(t,n){var r;void 0===n&&(n=!0);var o=null==t||null===(r=t.getAttribute)||void 0===r?void 0:r.call(t,"inert");return""===o||"true"===o||n&&t&&e(t.parentNode)},qt=function e(t,n,r){for(var o=[],a=Array.from(t);a.length;){var i=a.shift();if(!$t(i,!1))if("SLOT"===i.tagName){var s=i.assignedElements(),l=e(s.length?s:i.children,!0,r);r.flatten?o.push.apply(o,l):o.push({scopeParent:i,candidates:l})}else{Wt.call(i,Vt)&&r.filter(i)&&(n||!t.includes(i))&&o.push(i);var c=i.shadowRoot||"function"==typeof r.getShadowRoot&&r.getShadowRoot(i),u=!$t(c,!1)&&(!r.shadowRootFilter||r.shadowRootFilter(i));if(c&&u){var d=e(!0===c?i.children:c.children,!0,r);r.flatten?o.push.apply(o,d):o.push({scopeParent:i,candidates:d})}else a.unshift.apply(a,i.children)}}return o},Yt=function(e){return!isNaN(parseInt(e.getAttribute("tabindex"),10))},Gt=function(e){if(!e)throw new Error("No node provided");return e.tabIndex<0&&(/^(AUDIO|VIDEO|DETAILS)$/.test(e.tagName)||function(e){var t,n=null==e||null===(t=e.getAttribute)||void 0===t?void 0:t.call(e,"contenteditable");return""===n||"true"===n}(e))&&!Yt(e)?0:e.tabIndex},Xt=function(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex},Kt=function(e){return"INPUT"===e.tagName},Jt=function(e){var t=e.getBoundingClientRect(),n=t.width,r=t.height;return 0===n&&0===r},Zt=function(e,t){return!(t.disabled||$t(t)||function(e){return Kt(e)&&"hidden"===e.type}(t)||function(e,t){var n=t.displayCheck,r=t.getShadowRoot;if("hidden"===getComputedStyle(e).visibility)return!0;var o=Wt.call(e,"details>summary:first-of-type")?e.parentElement:e;if(Wt.call(o,"details:not([open]) *"))return!0;if(n&&"full"!==n&&"legacy-full"!==n){if("non-zero-area"===n)return Jt(e)}else{if("function"==typeof r){for(var a=e;e;){var i=e.parentElement,s=Ht(e);if(i&&!i.shadowRoot&&!0===r(i))return Jt(e);e=e.assignedSlot?e.assignedSlot:i||s===e.ownerDocument?i:s.host}e=a}if(function(e){var t,n,r,o,a=e&&Ht(e),i=null===(t=a)||void 0===t?void 0:t.host,s=!1;if(a&&a!==e)for(s=!!(null!==(n=i)&&void 0!==n&&null!==(r=n.ownerDocument)&&void 0!==r&&r.contains(i)||null!=e&&null!==(o=e.ownerDocument)&&void 0!==o&&o.contains(e));!s&&i;){var l,c,u;s=!(null===(c=i=null===(l=a=Ht(i))||void 0===l?void 0:l.host)||void 0===c||null===(u=c.ownerDocument)||void 0===u||!u.contains(i))}return s}(e))return!e.getClientRects().length;if("legacy-full"!==n)return!0}return!1}(t,e)||function(e){return"DETAILS"===e.tagName&&Array.prototype.slice.apply(e.children).some((function(e){return"SUMMARY"===e.tagName}))}(t)||function(e){if(/^(INPUT|BUTTON|SELECT|TEXTAREA)$/.test(e.tagName))for(var t=e.parentElement;t;){if("FIELDSET"===t.tagName&&t.disabled){for(var n=0;n=0)},tn=function e(t){var n=[],r=[];return t.forEach((function(t,o){var a=!!t.scopeParent,i=a?t.scopeParent:t,s=function(e,t){var n=Gt(e);return n<0&&t&&!Yt(e)?0:n}(i,a),l=a?e(t.candidates):i;0===s?a?n.push.apply(n,l):n.push(i):r.push({documentOrder:o,tabIndex:s,item:t,isScope:a,content:l})})),r.sort(Xt).reduce((function(e,t){return t.isScope?e.push.apply(e,t.content):e.push(t.content),e}),[]).concat(n)},nn=function(e,t){var n;return n=(t=t||{}).getShadowRoot?qt([e],t.includeContainer,{filter:Qt.bind(null,t),flatten:!1,getShadowRoot:t.getShadowRoot,shadowRootFilter:en}):function(e,t,n){if($t(e))return[];var r=Array.prototype.slice.apply(e.querySelectorAll(Vt));return t&&Wt.call(e,Vt)&&r.unshift(e),r.filter(n)}(e,t.includeContainer,Qt.bind(null,t)),tn(n)},rn=o(795);const on=Math.min,an=Math.max,sn=Math.round,ln=Math.floor,cn=e=>({x:e,y:e}),un={left:"right",right:"left",bottom:"top",top:"bottom"},dn={start:"end",end:"start"};function mn(e,t,n){return an(e,on(t,n))}function fn(e,t){return"function"==typeof e?e(t):e}function pn(e){return e.split("-")[0]}function hn(e){return e.split("-")[1]}function gn(e){return"x"===e?"y":"x"}function yn(e){return"y"===e?"height":"width"}function vn(e){return["top","bottom"].includes(pn(e))?"y":"x"}function bn(e){return gn(vn(e))}function xn(e){return e.replace(/start|end/g,(e=>dn[e]))}function wn(e){return e.replace(/left|right|bottom|top/g,(e=>un[e]))}function En(e){return"number"!=typeof e?function(e){return{top:0,right:0,bottom:0,left:0,...e}}(e):{top:e,right:e,bottom:e,left:e}}function _n(e){const{x:t,y:n,width:r,height:o}=e;return{width:r,height:o,top:n,left:t,right:t+r,bottom:n+o,x:t,y:n}}function kn(e,t,n){let{reference:r,floating:o}=e;const a=vn(t),i=bn(t),s=yn(i),l=pn(t),c="y"===a,u=r.x+r.width/2-o.width/2,d=r.y+r.height/2-o.height/2,m=r[s]/2-o[s]/2;let f;switch(l){case"top":f={x:u,y:r.y-o.height};break;case"bottom":f={x:u,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:d};break;case"left":f={x:r.x-o.width,y:d};break;default:f={x:r.x,y:r.y}}switch(hn(t)){case"start":f[i]-=m*(n&&c?-1:1);break;case"end":f[i]+=m*(n&&c?-1:1)}return f}async function Sn(e,t){var n;void 0===t&&(t={});const{x:r,y:o,platform:a,rects:i,elements:s,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:m=!1,padding:f=0}=fn(t,e),p=En(f),h=s[m?"floating"===d?"reference":"floating":d],g=_n(await a.getClippingRect({element:null==(n=await(null==a.isElement?void 0:a.isElement(h)))||n?h:h.contextElement||await(null==a.getDocumentElement?void 0:a.getDocumentElement(s.floating)),boundary:c,rootBoundary:u,strategy:l})),y="floating"===d?{x:r,y:o,width:i.floating.width,height:i.floating.height}:i.reference,v=await(null==a.getOffsetParent?void 0:a.getOffsetParent(s.floating)),b=await(null==a.isElement?void 0:a.isElement(v))&&await(null==a.getScale?void 0:a.getScale(v))||{x:1,y:1},x=_n(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:y,offsetParent:v,strategy:l}):y);return{top:(g.top-x.top+p.top)/b.y,bottom:(x.bottom-g.bottom+p.bottom)/b.y,left:(g.left-x.left+p.left)/b.x,right:(x.right-g.right+p.right)/b.x}}function Nn(e){const t=kt(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const o=gt(e),a=o?e.offsetWidth:n,i=o?e.offsetHeight:r,s=sn(n)!==a||sn(r)!==i;return s&&(n=a,r=i),{width:n,height:r,$:s}}function Cn(e){return ht(e)?e:e.contextElement}function Pn(e){const t=Cn(e);if(!gt(t))return cn(1);const n=t.getBoundingClientRect(),{width:r,height:o,$:a}=Nn(t);let i=(a?sn(n.width):n.width)/r,s=(a?sn(n.height):n.height)/o;return i&&Number.isFinite(i)||(i=1),s&&Number.isFinite(s)||(s=1),{x:i,y:s}}const Tn=cn(0);function jn(e){const t=mt(e);return Et()&&t.visualViewport?{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}:Tn}function An(e,t,n,r){void 0===t&&(t=!1),void 0===n&&(n=!1);const o=e.getBoundingClientRect(),a=Cn(e);let i=cn(1);t&&(r?ht(r)&&(i=Pn(r)):i=Pn(e));const s=function(e,t,n){return void 0===t&&(t=!1),!(!n||t&&n!==mt(e))&&t}(a,n,r)?jn(a):cn(0);let l=(o.left+s.x)/i.x,c=(o.top+s.y)/i.y,u=o.width/i.x,d=o.height/i.y;if(a){const e=mt(a),t=r&&ht(r)?mt(r):r;let n=e,o=Tt(n);for(;o&&r&&t!==n;){const e=Pn(o),t=o.getBoundingClientRect(),r=kt(o),a=t.left+(o.clientLeft+parseFloat(r.paddingLeft))*e.x,i=t.top+(o.clientTop+parseFloat(r.paddingTop))*e.y;l*=e.x,c*=e.y,u*=e.x,d*=e.y,l+=a,c+=i,n=mt(o),o=Tt(n)}}return _n({width:u,height:d,x:l,y:c})}function Rn(e,t){const n=St(e).scrollLeft;return t?t.left+n:An(ft(e)).left+n}function Fn(e,t,n){void 0===n&&(n=!1);const r=e.getBoundingClientRect();return{x:r.left+t.scrollLeft-(n?0:Rn(e,r)),y:r.top+t.scrollTop}}function Dn(e,t,n){let r;if("viewport"===t)r=function(e,t){const n=mt(e),r=ft(e),o=n.visualViewport;let a=r.clientWidth,i=r.clientHeight,s=0,l=0;if(o){a=o.width,i=o.height;const e=Et();(!e||e&&"fixed"===t)&&(s=o.offsetLeft,l=o.offsetTop)}return{width:a,height:i,x:s,y:l}}(e,n);else if("document"===t)r=function(e){const t=ft(e),n=St(e),r=e.ownerDocument.body,o=an(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),a=an(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Rn(e);const s=-n.scrollTop;return"rtl"===kt(r).direction&&(i+=an(t.clientWidth,r.clientWidth)-o),{width:o,height:a,x:i,y:s}}(ft(e));else if(ht(t))r=function(e,t){const n=An(e,!0,"fixed"===t),r=n.top+e.clientTop,o=n.left+e.clientLeft,a=gt(e)?Pn(e):cn(1);return{width:e.clientWidth*a.x,height:e.clientHeight*a.y,x:o*a.x,y:r*a.y}}(t,n);else{const n=jn(e);r={x:t.x-n.x,y:t.y-n.y,width:t.width,height:t.height}}return _n(r)}function Mn(e,t){const n=Nt(e);return!(n===t||!ht(n)||_t(n))&&("fixed"===kt(n).position||Mn(n,t))}function On(e,t,n){const r=gt(t),o=ft(t),a="fixed"===n,i=An(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=cn(0);function c(){l.x=Rn(o)}if(r||!r&&!a)if(("body"!==dt(t)||vt(o))&&(s=St(t)),r){const e=An(t,!0,a,t);l.x=e.x+t.clientLeft,l.y=e.y+t.clientTop}else o&&c();a&&!r&&o&&c();const u=!o||r||a?cn(0):Fn(o,s);return{x:i.left+s.scrollLeft-l.x-u.x,y:i.top+s.scrollTop-l.y-u.y,width:i.width,height:i.height}}function In(e){return"static"===kt(e).position}function Ln(e,t){if(!gt(e)||"fixed"===kt(e).position)return null;if(t)return t(e);let n=e.offsetParent;return ft(e)===n&&(n=n.ownerDocument.body),n}function zn(e,t){const n=mt(e);if(xt(e))return n;if(!gt(e)){let t=Nt(e);for(;t&&!_t(t);){if(ht(t)&&!In(t))return t;t=Nt(t)}return n}let r=Ln(e,t);for(;r&&bt(r)&&In(r);)r=Ln(r,t);return r&&_t(r)&&In(r)&&!wt(r)?n:r||function(e){let t=Nt(e);for(;gt(t)&&!_t(t);){if(wt(t))return t;if(xt(t))return null;t=Nt(t)}return null}(e)||n}const Bn={convertOffsetParentRelativeRectToViewportRelativeRect:function(e){let{elements:t,rect:n,offsetParent:r,strategy:o}=e;const a="fixed"===o,i=ft(r),s=!!t&&xt(t.floating);if(r===i||s&&a)return n;let l={scrollLeft:0,scrollTop:0},c=cn(1);const u=cn(0),d=gt(r);if((d||!d&&!a)&&(("body"!==dt(r)||vt(i))&&(l=St(r)),gt(r))){const e=An(r);c=Pn(r),u.x=e.x+r.clientLeft,u.y=e.y+r.clientTop}const m=!i||d||a?cn(0):Fn(i,l,!0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+m.x,y:n.y*c.y-l.scrollTop*c.y+u.y+m.y}},getDocumentElement:ft,getClippingRect:function(e){let{element:t,boundary:n,rootBoundary:r,strategy:o}=e;const a=[..."clippingAncestors"===n?xt(t)?[]:function(e,t){const n=t.get(e);if(n)return n;let r=Pt(e,[],!1).filter((e=>ht(e)&&"body"!==dt(e))),o=null;const a="fixed"===kt(e).position;let i=a?Nt(e):e;for(;ht(i)&&!_t(i);){const t=kt(i),n=wt(i);n||"fixed"!==t.position||(o=null),(a?!n&&!o:!n&&"static"===t.position&&o&&["absolute","fixed"].includes(o.position)||vt(i)&&!n&&Mn(e,i))?r=r.filter((e=>e!==i)):o=t,i=Nt(i)}return t.set(e,r),r}(t,this._c):[].concat(n),r],i=a[0],s=a.reduce(((e,n)=>{const r=Dn(t,n,o);return e.top=an(r.top,e.top),e.right=on(r.right,e.right),e.bottom=on(r.bottom,e.bottom),e.left=an(r.left,e.left),e}),Dn(t,i,o));return{width:s.right-s.left,height:s.bottom-s.top,x:s.left,y:s.top}},getOffsetParent:zn,getElementRects:async function(e){const t=this.getOffsetParent||zn,n=this.getDimensions,r=await n(e.floating);return{reference:On(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}},getClientRects:function(e){return Array.from(e.getClientRects())},getDimensions:function(e){const{width:t,height:n}=Nn(e);return{width:t,height:n}},getScale:Pn,isElement:ht,isRTL:function(e){return"rtl"===kt(e).direction}};function Vn(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function Un(e,t,n,r){void 0===r&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:i="function"==typeof ResizeObserver,layoutShift:s="function"==typeof IntersectionObserver,animationFrame:l=!1}=r,c=Cn(e),u=o||a?[...c?Pt(c):[],...Pt(t)]:[];u.forEach((e=>{o&&e.addEventListener("scroll",n,{passive:!0}),a&&e.addEventListener("resize",n)}));const d=c&&s?function(e,t){let n,r=null;const o=ft(e);function a(){var e;clearTimeout(n),null==(e=r)||e.disconnect(),r=null}return function i(s,l){void 0===s&&(s=!1),void 0===l&&(l=1),a();const c=e.getBoundingClientRect(),{left:u,top:d,width:m,height:f}=c;if(s||t(),!m||!f)return;const p={rootMargin:-ln(d)+"px "+-ln(o.clientWidth-(u+m))+"px "+-ln(o.clientHeight-(d+f))+"px "+-ln(u)+"px",threshold:an(0,on(1,l))||1};let h=!0;function g(t){const r=t[0].intersectionRatio;if(r!==l){if(!h)return i();r?i(!1,r):n=setTimeout((()=>{i(!1,1e-7)}),1e3)}1!==r||Vn(c,e.getBoundingClientRect())||i(),h=!1}try{r=new IntersectionObserver(g,{...p,root:o.ownerDocument})}catch(e){r=new IntersectionObserver(g,p)}r.observe(e)}(!0),a}(c,n):null;let m,f=-1,p=null;i&&(p=new ResizeObserver((e=>{let[r]=e;r&&r.target===c&&p&&(p.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame((()=>{var e;null==(e=p)||e.observe(t)}))),n()})),c&&!l&&p.observe(c),p.observe(t));let h=l?An(e):null;return l&&function t(){const r=An(e);h&&!Vn(h,r)&&n(),h=r,m=requestAnimationFrame(t)}(),n(),()=>{var e;u.forEach((e=>{o&&e.removeEventListener("scroll",n),a&&e.removeEventListener("resize",n)})),null==d||d(),null==(e=p)||e.disconnect(),p=null,l&&cancelAnimationFrame(m)}}const Wn=function(e){return void 0===e&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:o,y:a,placement:i,middlewareData:s}=t,l=await async function(e,t){const{placement:n,platform:r,elements:o}=e,a=await(null==r.isRTL?void 0:r.isRTL(o.floating)),i=pn(n),s=hn(n),l="y"===vn(n),c=["left","top"].includes(i)?-1:1,u=a&&l?-1:1,d=fn(t,e);let{mainAxis:m,crossAxis:f,alignmentAxis:p}="number"==typeof d?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return s&&"number"==typeof p&&(f="end"===s?-1*p:p),l?{x:f*u,y:m*c}:{x:m*c,y:f*u}}(t,e);return i===(null==(n=s.offset)?void 0:n.placement)&&null!=(r=s.arrow)&&r.alignmentOffset?{}:{x:o+l.x,y:a+l.y,data:{...l,placement:i}}}}},Hn=function(e){return void 0===e&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:o}=t,{mainAxis:a=!0,crossAxis:i=!1,limiter:s={fn:e=>{let{x:t,y:n}=e;return{x:t,y:n}}},...l}=fn(e,t),c={x:n,y:r},u=await Sn(t,l),d=vn(pn(o)),m=gn(d);let f=c[m],p=c[d];if(a){const e="y"===m?"bottom":"right";f=mn(f+u["y"===m?"top":"left"],f,f-u[e])}if(i){const e="y"===d?"bottom":"right";p=mn(p+u["y"===d?"top":"left"],p,p-u[e])}const h=s.fn({...t,[m]:f,[d]:p});return{...h,data:{x:h.x-n,y:h.y-r,enabled:{[m]:a,[d]:i}}}}}},$n=function(e){return void 0===e&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:o,middlewareData:a,rects:i,initialPlacement:s,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:m,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:p="none",flipAlignment:h=!0,...g}=fn(e,t);if(null!=(n=a.arrow)&&n.alignmentOffset)return{};const y=pn(o),v=vn(s),b=pn(s)===s,x=await(null==l.isRTL?void 0:l.isRTL(c.floating)),w=m||(b||!h?[wn(s)]:function(e){const t=wn(e);return[xn(e),t,xn(t)]}(s)),E="none"!==p;!m&&E&&w.push(...function(e,t,n,r){const o=hn(e);let a=function(e,t,n){const r=["left","right"],o=["right","left"],a=["top","bottom"],i=["bottom","top"];switch(e){case"top":case"bottom":return n?t?o:r:t?r:o;case"left":case"right":return t?a:i;default:return[]}}(pn(e),"start"===n,r);return o&&(a=a.map((e=>e+"-"+o)),t&&(a=a.concat(a.map(xn)))),a}(s,h,p,x));const _=[s,...w],k=await Sn(t,g),S=[];let N=(null==(r=a.flip)?void 0:r.overflows)||[];if(u&&S.push(k[y]),d){const e=function(e,t,n){void 0===n&&(n=!1);const r=hn(e),o=bn(e),a=yn(o);let i="x"===o?r===(n?"end":"start")?"right":"left":"start"===r?"bottom":"top";return t.reference[a]>t.floating[a]&&(i=wn(i)),[i,wn(i)]}(o,i,x);S.push(k[e[0]],k[e[1]])}if(N=[...N,{placement:o,overflows:S}],!S.every((e=>e<=0))){var C,P;const e=((null==(C=a.flip)?void 0:C.index)||0)+1,t=_[e];if(t){var T;const n="alignment"===d&&v!==vn(t),r=(null==(T=N[0])?void 0:T.overflows[0])>0;if(!n||r)return{data:{index:e,overflows:N},reset:{placement:t}}}let n=null==(P=N.filter((e=>e.overflows[0]<=0)).sort(((e,t)=>e.overflows[1]-t.overflows[1]))[0])?void 0:P.placement;if(!n)switch(f){case"bestFit":{var j;const e=null==(j=N.filter((e=>{if(E){const t=vn(e.placement);return t===v||"y"===t}return!0})).map((e=>[e.placement,e.overflows.filter((e=>e>0)).reduce(((e,t)=>e+t),0)])).sort(((e,t)=>e[1]-t[1]))[0])?void 0:j[0];e&&(n=e);break}case"initialPlacement":n=s}if(o!==n)return{reset:{placement:n}}}return{}}}},qn=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:o,rects:a,platform:i,elements:s,middlewareData:l}=t,{element:c,padding:u=0}=fn(e,t)||{};if(null==c)return{};const d=En(u),m={x:n,y:r},f=bn(o),p=yn(f),h=await i.getDimensions(c),g="y"===f,y=g?"top":"left",v=g?"bottom":"right",b=g?"clientHeight":"clientWidth",x=a.reference[p]+a.reference[f]-m[f]-a.floating[p],w=m[f]-a.reference[f],E=await(null==i.getOffsetParent?void 0:i.getOffsetParent(c));let _=E?E[b]:0;_&&await(null==i.isElement?void 0:i.isElement(E))||(_=s.floating[b]||a.floating[p]);const k=x/2-w/2,S=_/2-h[p]/2-1,N=on(d[y],S),C=on(d[v],S),P=N,T=_-h[p]-C,j=_/2-h[p]/2+k,A=mn(P,j,T),R=!l.arrow&&null!=hn(o)&&j!==A&&a.reference[p]/2-(j{const r=new Map,o={platform:Bn,...n},a={...o.platform,_c:r};return(async(e,t,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:i}=n,s=a.filter(Boolean),l=await(null==i.isRTL?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:o}),{x:u,y:d}=kn(c,r,l),m=r,f={},p=0;for(let n=0;n{t.current=e})),t}const Qn=e=>({name:"arrow",options:e,fn(t){const{element:n,padding:r}="function"==typeof e?e(t):e;return n&&(o=n,{}.hasOwnProperty.call(o,"current"))?null!=n.current?qn({element:n.current,padding:r}).fn(t):{}:n?qn({element:n,padding:r}).fn(t):{};var o}}),er=(e,t)=>({...Wn(e),options:[e,t]}),tr=(e,t)=>({...Hn(e),options:[e,t]}),nr=(e,t)=>({...$n(e),options:[e,t]}),rr={...l},or=rr.useInsertionEffect||(e=>e());function ar(e){const t=s.useRef((()=>{}));return or((()=>{t.current=e})),s.useCallback((function(){for(var e=arguments.length,n=new Array(e),r=0;r"floating-ui-"+Math.random().toString(36).slice(2,6)+cr++,dr=rr.useId||function(){const[e,t]=s.useState((()=>lr?ur():void 0));return ir((()=>{null==e&&t(ur())}),[]),s.useEffect((()=>{lr=!0}),[]),e},mr=s.forwardRef((function(e,t){const{context:{placement:n,elements:{floating:r},middlewareData:{arrow:o,shift:a}},width:i=14,height:l=7,tipRadius:c=0,strokeWidth:u=0,staticOffset:d,stroke:m,d:f,style:{transform:p,...h}={},...g}=e,y=dr(),[v,b]=s.useState(!1);if(ir((()=>{r&&"rtl"===kt(r).direction&&b(!0)}),[r]),!r)return null;const[x,w]=n.split("-"),E="top"===x||"bottom"===x;let _=d;(E&&null!=a&&a.x||!E&&null!=a&&a.y)&&(_=null);const k=2*u,S=k/2,N=i/2*(c/-8+1),C=l/2*c/4,P=!!f,T=_&&"end"===w?"bottom":"top";let j=_&&"end"===w?"right":"left";_&&v&&(j="end"===w?"left":"right");const A=null!=(null==o?void 0:o.x)?_||o.x:"",R=null!=(null==o?void 0:o.y)?_||o.y:"",F=f||"M0,0 H"+i+" L"+(i-N)+","+(l-C)+" Q"+i/2+","+l+" "+N+","+(l-C)+" Z",D={top:P?"rotate(180deg)":"",left:P?"rotate(90deg)":"rotate(-90deg)",bottom:P?"":"rotate(180deg)",right:P?"rotate(-90deg)":"rotate(90deg)"}[x];return s.createElement("svg",sr({},g,{"aria-hidden":!0,ref:t,width:P?i:i+k,height:i,viewBox:"0 0 "+i+" "+(l>i?l:i),style:{position:"absolute",pointerEvents:"none",[j]:A,[T]:R,[x]:E||P?"100%":"calc(100% - "+k/2+"px)",transform:[D,p].filter((e=>!!e)).join(" "),...h}}),k>0&&s.createElement("path",{clipPath:"url(#"+y+")",fill:"none",stroke:m,strokeWidth:k+(f?0:1),d:F}),s.createElement("path",{stroke:k&&!f?g.fill:"none",d:F}),s.createElement("clipPath",{id:y},s.createElement("rect",{x:-S,y:S*(P?-1:1),width:i+k,height:i})))}));const fr=s.createContext(null),pr=s.createContext(null),hr=()=>{var e;return(null==(e=s.useContext(fr))?void 0:e.id)||null},gr=()=>s.useContext(pr);function yr(e){return"data-floating-ui-"+e}function vr(e){const t=(0,s.useRef)(e);return ir((()=>{t.current=e})),t}const br=yr("safe-polygon");function xr(e,t,n){return n&&!Ot(n)?0:"number"==typeof e?e:null==e?void 0:e[t]}function wr(e,t){let n=e.filter((e=>{var n;return e.parentId===t&&(null==(n=e.context)?void 0:n.open)})),r=n;for(;r.length;)r=e.filter((e=>{var t;return null==(t=r)?void 0:t.some((t=>{var n;return e.parentId===t.id&&(null==(n=e.context)?void 0:n.open)}))})),n=n.concat(r);return n}const Er=()=>({getShadowRoot:!0,displayCheck:"function"==typeof ResizeObserver&&ResizeObserver.toString().includes("[native code]")?"full":"none"});function _r(e,t){const n=nn(e,Er());"prev"===t&&n.reverse();const r=n.indexOf(jt(It(e)));return n.slice(r+1)[0]}function kr(e,t){const n=t||e.currentTarget,r=e.relatedTarget;return!r||!At(n,r)}function Sr(e){nn(e,Er()).forEach((e=>{e.dataset.tabindex=e.getAttribute("tabindex")||"",e.setAttribute("tabindex","-1")}))}function Nr(e){e.querySelectorAll("[data-tabindex]").forEach((e=>{const t=e.dataset.tabindex;delete e.dataset.tabindex,t?e.setAttribute("tabindex",t):e.removeAttribute("tabindex")}))}const Cr={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"fixed",whiteSpace:"nowrap",width:"1px",top:0,left:0};function Pr(e){"Tab"===e.key&&(e.target,clearTimeout(void 0))}const Tr=s.forwardRef((function(e,t){const[n,r]=s.useState();ir((()=>(Dt()&&r("button"),document.addEventListener("keydown",Pr),()=>{document.removeEventListener("keydown",Pr)})),[]);const o={ref:t,tabIndex:0,role:n,"aria-hidden":!n||void 0,[yr("focus-guard")]:"",style:Cr};return s.createElement("span",sr({},e,o))})),jr=s.createContext(null),Ar=yr("portal");function Rr(e){const{children:t,id:n,root:r,preserveTabOrder:o=!0}=e,a=function(e){void 0===e&&(e={});const{id:t,root:n}=e,r=dr(),o=Fr(),[a,i]=s.useState(null),l=s.useRef(null);return ir((()=>()=>{null==a||a.remove(),queueMicrotask((()=>{l.current=null}))}),[a]),ir((()=>{if(!r)return;if(l.current)return;const e=t?document.getElementById(t):null;if(!e)return;const n=document.createElement("div");n.id=r,n.setAttribute(Ar,""),e.appendChild(n),l.current=n,i(n)}),[t,r]),ir((()=>{if(null===n)return;if(!r)return;if(l.current)return;let e=n||(null==o?void 0:o.portalNode);e&&!ht(e)&&(e=e.current),e=e||document.body;let a=null;t&&(a=document.createElement("div"),a.id=t,e.appendChild(a));const s=document.createElement("div");s.id=r,s.setAttribute(Ar,""),e=a||e,e.appendChild(s),l.current=s,i(s)}),[t,n,r,o]),a}({id:n,root:r}),[i,l]=s.useState(null),c=s.useRef(null),u=s.useRef(null),d=s.useRef(null),m=s.useRef(null),f=null==i?void 0:i.modal,p=null==i?void 0:i.open,h=!!i&&!i.modal&&i.open&&o&&!(!r&&!a);return s.useEffect((()=>{if(a&&o&&!f)return a.addEventListener("focusin",e,!0),a.addEventListener("focusout",e,!0),()=>{a.removeEventListener("focusin",e,!0),a.removeEventListener("focusout",e,!0)};function e(e){a&&kr(e)&&("focusin"===e.type?Nr:Sr)(a)}}),[a,o,f]),s.useEffect((()=>{a&&(p||Nr(a))}),[p,a]),s.createElement(jr.Provider,{value:s.useMemo((()=>({preserveTabOrder:o,beforeOutsideRef:c,afterOutsideRef:u,beforeInsideRef:d,afterInsideRef:m,portalNode:a,setFocusManagerState:l})),[o,a])},h&&a&&s.createElement(Tr,{"data-type":"outside",ref:c,onFocus:e=>{if(kr(e,a)){var t;null==(t=d.current)||t.focus()}else{const e=_r(document.body,"prev")||(null==i?void 0:i.refs.domReference.current);null==e||e.focus()}}}),h&&a&&s.createElement("span",{"aria-owns":a.id,style:Cr}),a&&rn.createPortal(t,a),h&&a&&s.createElement(Tr,{"data-type":"outside",ref:u,onFocus:e=>{if(kr(e,a)){var t;null==(t=m.current)||t.focus()}else{const t=_r(document.body,"next")||(null==i?void 0:i.refs.domReference.current);null==t||t.focus(),(null==i?void 0:i.closeOnFocusOut)&&(null==i||i.onOpenChange(!1,e.nativeEvent,"focus-out"))}}}))}const Fr=()=>s.useContext(jr),Dr="data-floating-ui-focusable";function Mr(e){return gt(e.target)&&"BUTTON"===e.target.tagName}function Or(e){return Bt(e)}function Ir(e,t){void 0===t&&(t={});const{open:n,onOpenChange:r,dataRef:o,elements:{domReference:a}}=e,{enabled:i=!0,event:l="click",toggle:c=!0,ignoreMouse:u=!1,keyboardHandlers:d=!0,stickIfOpen:m=!0}=t,f=s.useRef(),p=s.useRef(!1),h=s.useMemo((()=>({onPointerDown(e){f.current=e.pointerType},onMouseDown(e){const t=f.current;0===e.button&&"click"!==l&&(Ot(t,!0)&&u||(!n||!c||o.current.openEvent&&m&&"mousedown"!==o.current.openEvent.type?(e.preventDefault(),r(!0,e.nativeEvent,"click")):r(!1,e.nativeEvent,"click")))},onClick(e){const t=f.current;"mousedown"===l&&f.current?f.current=void 0:Ot(t,!0)&&u||(!n||!c||o.current.openEvent&&m&&"click"!==o.current.openEvent.type?r(!0,e.nativeEvent,"click"):r(!1,e.nativeEvent,"click"))},onKeyDown(e){f.current=void 0,e.defaultPrevented||!d||Mr(e)||(" "!==e.key||Or(a)||(e.preventDefault(),p.current=!0),"Enter"===e.key&&r(!n||!c,e.nativeEvent,"click"))},onKeyUp(e){e.defaultPrevented||!d||Mr(e)||Or(a)||" "===e.key&&p.current&&(p.current=!1,r(!n||!c,e.nativeEvent,"click"))}})),[o,a,l,u,d,r,n,m,c]);return s.useMemo((()=>i?{reference:h}:{}),[i,h])}const Lr={pointerdown:"onPointerDown",mousedown:"onMouseDown",click:"onClick"},zr={pointerdown:"onPointerDownCapture",mousedown:"onMouseDownCapture",click:"onClickCapture"},Br=e=>{var t,n;return{escapeKey:"boolean"==typeof e?e:null!=(t=null==e?void 0:e.escapeKey)&&t,outsidePress:"boolean"==typeof e?e:null==(n=null==e?void 0:e.outsidePress)||n}};function Vr(e,t){void 0===t&&(t={});const{open:n,onOpenChange:r,elements:o,dataRef:a}=e,{enabled:i=!0,escapeKey:l=!0,outsidePress:c=!0,outsidePressEvent:u="pointerdown",referencePress:d=!1,referencePressEvent:m="pointerdown",ancestorScroll:f=!1,bubbles:p,capture:h}=t,g=gr(),y=ar("function"==typeof c?c:()=>!1),v="function"==typeof c?y:c,b=s.useRef(!1),x=s.useRef(!1),{escapeKey:w,outsidePress:E}=Br(p),{escapeKey:_,outsidePress:k}=Br(h),S=s.useRef(!1),N=ar((e=>{var t;if(!n||!i||!l||"Escape"!==e.key)return;if(S.current)return;const o=null==(t=a.current.floatingContext)?void 0:t.nodeId,s=g?wr(g.nodesRef.current,o):[];if(!w&&(e.stopPropagation(),s.length>0)){let e=!0;if(s.forEach((t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__escapeKeyBubbles||(e=!1)})),!e)return}r(!1,function(e){return"nativeEvent"in e}(e)?e.nativeEvent:e,"escape-key")})),C=ar((e=>{var t;const n=()=>{var t;N(e),null==(t=zt(e))||t.removeEventListener("keydown",n)};null==(t=zt(e))||t.addEventListener("keydown",n)})),P=ar((e=>{var t;const n=b.current;b.current=!1;const i=x.current;if(x.current=!1,"click"===u&&i)return;if(n)return;if("function"==typeof v&&!v(e))return;const s=zt(e),l="["+yr("inert")+"]",c=It(o.floating).querySelectorAll(l);let d=ht(s)?s:null;for(;d&&!_t(d);){const e=Nt(d);if(_t(e)||!ht(e))break;d=e}if(c.length&&ht(s)&&!s.matches("html,body")&&!At(s,o.floating)&&Array.from(c).every((e=>!At(d,e))))return;if(gt(s)&&A){const t=s.clientWidth>0&&s.scrollWidth>s.clientWidth,n=s.clientHeight>0&&s.scrollHeight>s.clientHeight;let r=n&&e.offsetX>s.clientWidth;if(n&&"rtl"===kt(s).direction&&(r=e.offsetX<=s.offsetWidth-s.clientWidth),r||t&&e.offsetY>s.clientHeight)return}const m=null==(t=a.current.floatingContext)?void 0:t.nodeId,f=g&&wr(g.nodesRef.current,m).some((t=>{var n;return Lt(e,null==(n=t.context)?void 0:n.elements.floating)}));if(Lt(e,o.floating)||Lt(e,o.domReference)||f)return;const p=g?wr(g.nodesRef.current,m):[];if(p.length>0){let e=!0;if(p.forEach((t=>{var n;null==(n=t.context)||!n.open||t.context.dataRef.current.__outsidePressBubbles||(e=!1)})),!e)return}r(!1,e,"outside-press")})),T=ar((e=>{var t;const n=()=>{var t;P(e),null==(t=zt(e))||t.removeEventListener(u,n)};null==(t=zt(e))||t.addEventListener(u,n)}));s.useEffect((()=>{if(!n||!i)return;a.current.__escapeKeyBubbles=w,a.current.__outsidePressBubbles=E;let e=-1;function t(e){r(!1,e,"ancestor-scroll")}function s(){window.clearTimeout(e),S.current=!0}function c(){e=window.setTimeout((()=>{S.current=!1}),Et()?5:0)}const d=It(o.floating);l&&(d.addEventListener("keydown",_?C:N,_),d.addEventListener("compositionstart",s),d.addEventListener("compositionend",c)),v&&d.addEventListener(u,k?T:P,k);let m=[];return f&&(ht(o.domReference)&&(m=Pt(o.domReference)),ht(o.floating)&&(m=m.concat(Pt(o.floating))),!ht(o.reference)&&o.reference&&o.reference.contextElement&&(m=m.concat(Pt(o.reference.contextElement)))),m=m.filter((e=>{var t;return e!==(null==(t=d.defaultView)?void 0:t.visualViewport)})),m.forEach((e=>{e.addEventListener("scroll",t,{passive:!0})})),()=>{l&&(d.removeEventListener("keydown",_?C:N,_),d.removeEventListener("compositionstart",s),d.removeEventListener("compositionend",c)),v&&d.removeEventListener(u,k?T:P,k),m.forEach((e=>{e.removeEventListener("scroll",t)})),window.clearTimeout(e)}}),[a,o,l,v,u,n,r,f,i,w,E,N,_,C,P,k,T]),s.useEffect((()=>{b.current=!1}),[v,u]);const j=s.useMemo((()=>({onKeyDown:N,[Lr[m]]:e=>{d&&r(!1,e.nativeEvent,"reference-press")}})),[N,r,d,m]),A=s.useMemo((()=>({onKeyDown:N,onMouseDown(){x.current=!0},onMouseUp(){x.current=!0},[zr[u]]:()=>{b.current=!0}})),[N,u]);return s.useMemo((()=>i?{reference:j,floating:A}:{}),[i,j,A])}function Ur(e){void 0===e&&(e={});const{nodeId:t}=e,n=function(e){const{open:t=!1,onOpenChange:n,elements:r}=e,o=dr(),a=s.useRef({}),[i]=s.useState((()=>function(){const e=new Map;return{emit(t,n){var r;null==(r=e.get(t))||r.forEach((e=>e(n)))},on(t,n){e.set(t,[...e.get(t)||[],n])},off(t,n){var r;e.set(t,(null==(r=e.get(t))?void 0:r.filter((e=>e!==n)))||[])}}}())),l=null!=hr(),[c,u]=s.useState(r.reference),d=ar(((e,t,r)=>{a.current.openEvent=e?t:void 0,i.emit("openchange",{open:e,event:t,reason:r,nested:l}),null==n||n(e,t,r)})),m=s.useMemo((()=>({setPositionReference:u})),[]),f=s.useMemo((()=>({reference:c||r.reference||null,floating:r.floating||null,domReference:r.reference})),[c,r.reference,r.floating]);return s.useMemo((()=>({dataRef:a,open:t,onOpenChange:d,elements:f,events:i,floatingId:o,refs:m})),[t,d,f,i,o,m])}({...e,elements:{reference:null,floating:null,...e.elements}}),r=e.rootContext||n,o=r.elements,[a,i]=s.useState(null),[l,c]=s.useState(null),u=(null==o?void 0:o.domReference)||a,d=s.useRef(null),m=gr();ir((()=>{u&&(d.current=u)}),[u]);const f=function(e){void 0===e&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:i}={},transform:l=!0,whileElementsMounted:c,open:u}=e,[d,m]=s.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[f,p]=s.useState(r);Xn(f,r)||p(r);const[h,g]=s.useState(null),[y,v]=s.useState(null),b=s.useCallback((e=>{e!==_.current&&(_.current=e,g(e))}),[]),x=s.useCallback((e=>{e!==k.current&&(k.current=e,v(e))}),[]),w=a||h,E=i||y,_=s.useRef(null),k=s.useRef(null),S=s.useRef(d),N=null!=c,C=Zn(c),P=Zn(o),T=Zn(u),j=s.useCallback((()=>{if(!_.current||!k.current)return;const e={placement:t,strategy:n,middleware:f};P.current&&(e.platform=P.current),Yn(_.current,k.current,e).then((e=>{const t={...e,isPositioned:!1!==T.current};A.current&&!Xn(S.current,t)&&(S.current=t,rn.flushSync((()=>{m(t)})))}))}),[f,t,n,P,T]);Gn((()=>{!1===u&&S.current.isPositioned&&(S.current.isPositioned=!1,m((e=>({...e,isPositioned:!1}))))}),[u]);const A=s.useRef(!1);Gn((()=>(A.current=!0,()=>{A.current=!1})),[]),Gn((()=>{if(w&&(_.current=w),E&&(k.current=E),w&&E){if(C.current)return C.current(w,E,j);j()}}),[w,E,j,C,N]);const R=s.useMemo((()=>({reference:_,floating:k,setReference:b,setFloating:x})),[b,x]),F=s.useMemo((()=>({reference:w,floating:E})),[w,E]),D=s.useMemo((()=>{const e={position:n,left:0,top:0};if(!F.floating)return e;const t=Jn(F.floating,d.x),r=Jn(F.floating,d.y);return l?{...e,transform:"translate("+t+"px, "+r+"px)",...Kn(F.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:t,top:r}}),[n,l,F.floating,d.x,d.y]);return s.useMemo((()=>({...d,update:j,refs:R,elements:F,floatingStyles:D})),[d,j,R,F,D])}({...e,elements:{...o,...l&&{reference:l}}}),p=s.useCallback((e=>{const t=ht(e)?{getBoundingClientRect:()=>e.getBoundingClientRect(),contextElement:e}:e;c(t),f.refs.setReference(t)}),[f.refs]),h=s.useCallback((e=>{(ht(e)||null===e)&&(d.current=e,i(e)),(ht(f.refs.reference.current)||null===f.refs.reference.current||null!==e&&!ht(e))&&f.refs.setReference(e)}),[f.refs]),g=s.useMemo((()=>({...f.refs,setReference:h,setPositionReference:p,domReference:d})),[f.refs,h,p]),y=s.useMemo((()=>({...f.elements,domReference:u})),[f.elements,u]),v=s.useMemo((()=>({...f,...r,refs:g,elements:y,nodeId:t})),[f,g,y,t,r]);return ir((()=>{r.dataRef.current.floatingContext=v;const e=null==m?void 0:m.nodesRef.current.find((e=>e.id===t));e&&(e.context=v)})),s.useMemo((()=>({...f,context:v,refs:g,elements:y})),[f,g,y,v])}function Wr(e,t){void 0===t&&(t={});const{open:n,onOpenChange:r,events:o,dataRef:a,elements:i}=e,{enabled:l=!0,visibleOnly:c=!0}=t,u=s.useRef(!1),d=s.useRef(),m=s.useRef(!0);s.useEffect((()=>{if(!l)return;const e=mt(i.domReference);function t(){!n&>(i.domReference)&&i.domReference===jt(It(i.domReference))&&(u.current=!0)}function r(){m.current=!0}return e.addEventListener("blur",t),e.addEventListener("keydown",r,!0),()=>{e.removeEventListener("blur",t),e.removeEventListener("keydown",r,!0)}}),[i.domReference,n,l]),s.useEffect((()=>{if(l)return o.on("openchange",e),()=>{o.off("openchange",e)};function e(e){let{reason:t}=e;"reference-press"!==t&&"escape-key"!==t||(u.current=!0)}}),[o,l]),s.useEffect((()=>()=>{clearTimeout(d.current)}),[]);const f=s.useMemo((()=>({onPointerDown(e){(function(e){return!Ft().includes("jsdom/")&&(!Mt()&&0===e.width&&0===e.height||Mt()&&1===e.width&&1===e.height&&0===e.pressure&&0===e.detail&&"mouse"===e.pointerType||e.width<1&&e.height<1&&0===e.pressure&&0===e.detail&&"touch"===e.pointerType)})(e.nativeEvent)||(m.current=!1)},onMouseLeave(){u.current=!1},onFocus(e){if(u.current)return;const t=zt(e.nativeEvent);if(c&&ht(t))try{if(Dt()&&Rt().toLowerCase().startsWith("mac")&&!navigator.maxTouchPoints)throw Error();if(!t.matches(":focus-visible"))return}catch(e){if(!m.current&&!Bt(t))return}r(!0,e.nativeEvent,"focus")},onBlur(e){u.current=!1;const t=e.relatedTarget,n=e.nativeEvent,o=ht(t)&&t.hasAttribute(yr("focus-guard"))&&"outside"===t.getAttribute("data-type");d.current=window.setTimeout((()=>{var e;const s=jt(i.domReference?i.domReference.ownerDocument:document);(t||s!==i.domReference)&&(At(null==(e=a.current.floatingContext)?void 0:e.refs.floating.current,s)||At(i.domReference,s)||o||r(!1,n,"focus"))}))}})),[a,i.domReference,r,c]);return s.useMemo((()=>l?{reference:f}:{}),[l,f])}const Hr="active",$r="selected";function qr(e,t,n){const r=new Map,o="item"===n;let a=e;if(o&&e){const{[Hr]:t,[$r]:n,...r}=e;a=r}return{..."floating"===n&&{tabIndex:-1,[Dr]:""},...a,...t.map((t=>{const r=t?t[n]:null;return"function"==typeof r?e?r(e):null:r})).concat(e).reduce(((e,t)=>t?(Object.entries(t).forEach((t=>{let[n,a]=t;var i;o&&[Hr,$r].includes(n)||(0===n.indexOf("on")?(r.has(n)||r.set(n,[]),"function"==typeof a&&(null==(i=r.get(n))||i.push(a),e[n]=function(){for(var e,t=arguments.length,o=new Array(t),a=0;ae(...o))).find((e=>void 0!==e))})):e[n]=a)})),e):e),{})}}function Yr(e){void 0===e&&(e=[]);const t=e.map((e=>null==e?void 0:e.reference)),n=e.map((e=>null==e?void 0:e.floating)),r=e.map((e=>null==e?void 0:e.item)),o=s.useCallback((t=>qr(t,e,"reference")),t),a=s.useCallback((t=>qr(t,e,"floating")),n),i=s.useCallback((t=>qr(t,e,"item")),r);return s.useMemo((()=>({getReferenceProps:o,getFloatingProps:a,getItemProps:i})),[o,a,i])}const Gr=new Map([["select","listbox"],["combobox","listbox"],["label",!1]]);function Xr(e,t){var n;void 0===t&&(t={});const{open:r,floatingId:o}=e,{enabled:a=!0,role:i="dialog"}=t,l=null!=(n=Gr.get(i))?n:i,c=dr(),u=null!=hr(),d=s.useMemo((()=>"tooltip"===l||"label"===i?{["aria-"+("label"===i?"labelledby":"describedby")]:r?o:void 0}:{"aria-expanded":r?"true":"false","aria-haspopup":"alertdialog"===l?"dialog":l,"aria-controls":r?o:void 0,..."listbox"===l&&{role:"combobox"},..."menu"===l&&{id:c},..."menu"===l&&u&&{role:"menuitem"},..."select"===i&&{"aria-autocomplete":"none"},..."combobox"===i&&{"aria-autocomplete":"list"}}),[l,o,u,r,c,i]),m=s.useMemo((()=>{const e={id:o,...l&&{role:l}};return"tooltip"===l||"label"===i?e:{...e,..."menu"===l&&{"aria-labelledby":c}}}),[l,o,c,i]),f=s.useCallback((e=>{let{active:t,selected:n}=e;const r={role:"option",...t&&{id:o+"-option"}};switch(i){case"select":return{...r,"aria-selected":t&&n};case"combobox":return{...r,...t&&{"aria-selected":!0}}}return{}}),[o,i]);return s.useMemo((()=>a?{reference:d,floating:m,item:f}:{}),[a,d,m,f])}const Kr=e=>e.replace(/[A-Z]+(?![a-z])|[A-Z]/g,((e,t)=>(t?"-":"")+e.toLowerCase()));function Jr(e,t){return"function"==typeof e?e(t):e}function Zr(e,t){void 0===t&&(t={});const{initial:n={opacity:0},open:r,close:o,common:a,duration:i=250}=t,l=e.placement,c=l.split("-")[0],u=s.useMemo((()=>({side:c,placement:l})),[c,l]),d="number"==typeof i,m=(d?i:i.open)||0,f=(d?i:i.close)||0,[p,h]=s.useState((()=>({...Jr(a,u),...Jr(n,u)}))),{isMounted:g,status:y}=function(e,t){void 0===t&&(t={});const{open:n,elements:{floating:r}}=e,{duration:o=250}=t,a=("number"==typeof o?o:o.close)||0,[i,l]=s.useState("unmounted"),c=function(e,t){const[n,r]=s.useState(e);return e&&!n&&r(!0),s.useEffect((()=>{if(!e&&n){const e=setTimeout((()=>r(!1)),t);return()=>clearTimeout(e)}}),[e,n,t]),n}(n,a);return c||"close"!==i||l("unmounted"),ir((()=>{if(r){if(n){l("initial");const e=requestAnimationFrame((()=>{l("open")}));return()=>{cancelAnimationFrame(e)}}l("close")}}),[n,r]),{isMounted:c,status:i}}(e,{duration:i}),v=vr(n),b=vr(r),x=vr(o),w=vr(a);return ir((()=>{const e=Jr(v.current,u),t=Jr(x.current,u),n=Jr(w.current,u),r=Jr(b.current,u)||Object.keys(e).reduce(((e,t)=>(e[t]="",e)),{});if("initial"===y&&h((t=>({transitionProperty:t.transitionProperty,...n,...e}))),"open"===y&&h({transitionProperty:Object.keys(r).map(Kr).join(","),transitionDuration:m+"ms",...n,...r}),"close"===y){const r=t||e;h({transitionProperty:Object.keys(r).map(Kr).join(","),transitionDuration:f+"ms",...n,...r})}}),[f,x,v,b,w,m,y,u]),{isMounted:g,styles:p}}function Qr(e,t){const[n,r]=e;let o=!1;const a=t.length;for(let e=0,i=a-1;e=r!=c>=r&&n<=(l-a)*(r-s)/(c-s)+a&&(o=!o)}return o}function eo(e){void 0===e&&(e={});const{buffer:t=.5,blockPointerEvents:n=!1,requireIntent:r=!0}=e;let o,a=!1,i=null,s=null,l=performance.now();const c=e=>{let{x:n,y:c,placement:u,elements:d,onClose:m,nodeId:f,tree:p}=e;return function(e){function h(){clearTimeout(o),m()}if(clearTimeout(o),!d.domReference||!d.floating||null==u||null==n||null==c)return;const{clientX:g,clientY:y}=e,v=[g,y],b=zt(e),x="mouseleave"===e.type,w=At(d.floating,b),E=At(d.domReference,b),_=d.domReference.getBoundingClientRect(),k=d.floating.getBoundingClientRect(),S=u.split("-")[0],N=n>k.right-k.width/2,C=c>k.bottom-k.height/2,P=function(e,t){return e[0]>=t.x&&e[0]<=t.x+t.width&&e[1]>=t.y&&e[1]<=t.y+t.height}(v,_),T=k.width>_.width,j=k.height>_.height,A=(T?_:k).left,R=(T?_:k).right,F=(j?_:k).top,D=(j?_:k).bottom;if(w&&(a=!0,!x))return;if(E&&(a=!1),E&&!x)return void(a=!0);if(x&&ht(e.relatedTarget)&&At(d.floating,e.relatedTarget))return;if(p&&wr(p.nodesRef.current,f).some((e=>{let{context:t}=e;return null==t?void 0:t.open})))return;if("top"===S&&c>=_.bottom-1||"bottom"===S&&c<=_.top+1||"left"===S&&n>=_.right-1||"right"===S&&n<=_.left+1)return h();let M=[];switch(S){case"top":M=[[A,_.top+1],[A,k.bottom-1],[R,k.bottom-1],[R,_.top+1]];break;case"bottom":M=[[A,k.top+1],[A,_.bottom-1],[R,_.bottom-1],[R,k.top+1]];break;case"left":M=[[k.right-1,D],[k.right-1,F],[_.left+1,F],[_.left+1,D]];break;case"right":M=[[_.right-1,D],[_.right-1,F],[k.left+1,F],[k.left+1,D]]}if(!Qr([g,y],M)){if(a&&!P)return h();if(!x&&r){const t=function(e,t){const n=performance.now(),r=n-l;if(null===i||null===s||0===r)return i=e,s=t,l=n,null;const o=e-i,a=t-s,c=Math.sqrt(o*o+a*a);return i=e,s=t,l=n,c/r}(e.clientX,e.clientY);if(null!==t&&t<.1)return h()}Qr([g,y],function(e){let[n,r]=e;switch(S){case"top":return[[T?n+t/2:N?n+4*t:n-4*t,r+t+1],[T?n-t/2:N?n+4*t:n-4*t,r+t+1],[k.left,N||T?k.bottom-t:k.top],[k.right,N?T?k.bottom-t:k.top:k.bottom-t]];case"bottom":return[[T?n+t/2:N?n+4*t:n-4*t,r-t],[T?n-t/2:N?n+4*t:n-4*t,r-t],[k.left,N||T?k.top+t:k.bottom],[k.right,N?T?k.top+t:k.bottom:k.top+t]];case"left":{const e=[n+t+1,j?r+t/2:C?r+4*t:r-4*t],o=[n+t+1,j?r-t/2:C?r+4*t:r-4*t];return[[C||j?k.right-t:k.left,k.top],[C?j?k.right-t:k.left:k.right-t,k.bottom],e,o]}case"right":return[[n-t,j?r+t/2:C?r+4*t:r-4*t],[n-t,j?r-t/2:C?r+4*t:r-4*t],[C||j?k.left+t:k.right,k.top],[C?j?k.left+t:k.right:k.left+t,k.bottom]]}}([n,c]))?!a&&r&&(o=window.setTimeout(h,40)):h()}}};return c.__options={blockPointerEvents:n},c}function to(e){if("undefined"==typeof Proxy)return e;const t=new Map;return new Proxy(((...t)=>e(...t)),{get:(n,r)=>"create"===r?e:(t.has(r)||t.set(r,e(r)),t.get(r))})}function no(e){return null!==e&&"object"==typeof e&&"function"==typeof e.start}const ro=e=>Array.isArray(e);function oo(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r{t[0][n]=e.get(),t[1][n]=e.getVelocity()})),t}function so(e,t,n,r){if("function"==typeof t){const[o,a]=io(r);t=t(void 0!==n?n:e.custom,o,a)}if("string"==typeof t&&(t=e.variants&&e.variants[t]),"function"==typeof t){const[o,a]=io(r);t=t(void 0!==n?n:e.custom,o,a)}return t}function lo(e,t,n){const r=e.getProps();return so(r,t,void 0!==n?n:r.custom,e)}const co=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],uo=["initial",...co];function mo(e){let t;return()=>(void 0===t&&(t=e()),t)}const fo=mo((()=>void 0!==window.ScrollTimeline));class po{constructor(e){this.stop=()=>this.runAll("stop"),this.animations=e.filter(Boolean)}get finished(){return Promise.all(this.animations.map((e=>"finished"in e?e.finished:e)))}getAll(e){return this.animations[0][e]}setAll(e,t){for(let n=0;nfo()&&n.attachTimeline?n.attachTimeline(e):"function"==typeof t?t(n):void 0));return()=>{n.forEach(((e,t)=>{e&&e(),this.animations[t].stop()}))}}get time(){return this.getAll("time")}set time(e){this.setAll("time",e)}get speed(){return this.getAll("speed")}set speed(e){this.setAll("speed",e)}get startTime(){return this.getAll("startTime")}get duration(){let e=0;for(let t=0;tt[e]()))}flatten(){this.runAll("flatten")}play(){this.runAll("play")}pause(){this.runAll("pause")}cancel(){this.runAll("cancel")}complete(){this.runAll("complete")}}class ho extends po{then(e,t){return Promise.all(this.animations).then(e).catch(t)}}function go(e,t){return e?e[t]||e.default||e:void 0}const yo=2e4;function vo(e){let t=0,n=e.next(t);for(;!n.done&&t=yo?1/0:t}function bo(e){return"function"==typeof e}function xo(e,t){e.timeline=t,e.onfinish=null}const wo=e=>Array.isArray(e)&&"number"==typeof e[0],Eo={linearEasing:void 0};function _o(e,t){const n=mo(e);return()=>{var e;return null!==(e=Eo[t])&&void 0!==e?e:n()}}const ko=_o((()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch(e){return!1}return!0}),"linearEasing"),So=(e,t,n)=>{const r=t-e;return 0===r?1:(n-e)/r},No=(e,t,n=10)=>{let r="";const o=Math.max(Math.round(t/n),2);for(let t=0;t`cubic-bezier(${e}, ${t}, ${n}, ${r})`,To={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Po([0,.65,.55,1]),circOut:Po([.55,0,1,.45]),backIn:Po([.31,.01,.66,-.59]),backOut:Po([.33,1.53,.69,.99])};function jo(e,t){return e?"function"==typeof e&&ko()?No(e,t):wo(e)?Po(e):Array.isArray(e)?e.map((e=>jo(e,t)||To.easeOut)):To[e]:void 0}const Ao={x:!1,y:!1};function Ro(){return Ao.x||Ao.y}function Fo(e,t){const n=function(e){if(e instanceof Element)return[e];if("string"==typeof e){let t=document;const n=t.querySelectorAll(e);return n?Array.from(n):[]}return Array.from(e)}(e),r=new AbortController;return[n,{passive:!0,...t,signal:r.signal},()=>r.abort()]}function Do(e){return t=>{"touch"===t.pointerType||Ro()||e(t)}}const Mo=(e,t)=>!!t&&(e===t||Mo(e,t.parentElement)),Oo=e=>"mouse"===e.pointerType?"number"!=typeof e.button||e.button<=0:!1!==e.isPrimary,Io=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]),Lo=new WeakSet;function zo(e){return t=>{"Enter"===t.key&&e(t)}}function Bo(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}function Vo(e){return Oo(e)&&!Ro()}const Uo=e=>1e3*e,Wo=e=>e/1e3,Ho=e=>e,$o=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],qo=new Set($o),Yo=new Set(["width","height","top","left","right","bottom",...$o]),Go=e=>ro(e)?e[e.length-1]||0:e,Xo=["read","resolveKeyframes","update","preRender","render","postRender"];function Ko(e,t){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,i=Xo.reduce(((e,t)=>(e[t]=function(e){let t=new Set,n=new Set,r=!1,o=!1;const a=new WeakSet;let i={delta:0,timestamp:0,isProcessing:!1};function s(t){a.has(t)&&(l.schedule(t),e()),t(i)}const l={schedule:(e,o=!1,i=!1)=>{const s=i&&r?t:n;return o&&a.add(e),s.has(e)||s.add(e),e},cancel:e=>{n.delete(e),a.delete(e)},process:e=>{i=e,r?o=!0:(r=!0,[t,n]=[n,t],t.forEach(s),t.clear(),r=!1,o&&(o=!1,l.process(e)))}};return l}(a),e)),{}),{read:s,resolveKeyframes:l,update:c,preRender:u,render:d,postRender:m}=i,f=()=>{const a=performance.now();n=!1,o.delta=r?1e3/60:Math.max(Math.min(a-o.timestamp,40),1),o.timestamp=a,o.isProcessing=!0,s.process(o),l.process(o),c.process(o),u.process(o),d.process(o),m.process(o),o.isProcessing=!1,n&&t&&(r=!1,e(f))};return{schedule:Xo.reduce(((t,a)=>{const s=i[a];return t[a]=(t,a=!1,i=!1)=>(n||(n=!0,r=!0,o.isProcessing||e(f)),s.schedule(t,a,i)),t}),{}),cancel:e=>{for(let t=0;t(void 0===ta&&ra.set(Qo.isProcessing?Qo.timestamp:performance.now()),ta),set:e=>{ta=e,queueMicrotask(na)}};function oa(e,t){-1===e.indexOf(t)&&e.push(t)}function aa(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}class ia{constructor(){this.subscriptions=[]}add(e){return oa(this.subscriptions,e),()=>aa(this.subscriptions,e)}notify(e,t,n){const r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(let o=0;o{const n=ra.now();this.updatedAt!==n&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(e),this.current!==this.prev&&this.events.change&&this.events.change.notify(this.current),t&&this.events.renderRequest&&this.events.renderRequest.notify(this.current)},this.hasAnimated=!1,this.setCurrent(e),this.owner=t.owner}setCurrent(e){var t;this.current=e,this.updatedAt=ra.now(),null===this.canTrackVelocity&&void 0!==e&&(this.canTrackVelocity=(t=this.current,!isNaN(parseFloat(t))))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,t){this.events[e]||(this.events[e]=new ia);const n=this.events[e].add(t);return"change"===e?()=>{n(),Jo.read((()=>{this.events.change.getSize()||this.stop()}))}:n}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,t){this.passiveEffect=e,this.stopPassiveEffect=t}set(e,t=!0){t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)}setWithVelocity(e,t,n){this.set(t),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-n}jump(e,t=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,t&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}get(){return la.current&&la.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const e=ra.now();if(!this.canTrackVelocity||void 0===this.prevFrameValue||e-this.updatedAt>30)return 0;const t=Math.min(this.updatedAt-this.prevUpdatedAt,30);return sa(parseFloat(this.current)-parseFloat(this.prevFrameValue),t)}start(e){return this.stop(),new Promise((t=>{this.hasAnimated=!0,this.animation=e(t),this.events.animationStart&&this.events.animationStart.notify()})).then((()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()}))}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function ua(e,t){return new ca(e,t)}function da(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,ua(n))}const ma=e=>Boolean(e&&e.getVelocity);function fa(e,t){const n=e.getValue("willChange");if(r=n,Boolean(ma(r)&&r.add))return n.add(t);var r}const pa=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),ha="data-"+pa("framerAppearId");function ga(e){return e.props[ha]}const ya=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e;function va(e,t,n,r){if(e===t&&n===r)return Ho;return o=>0===o||1===o?o:ya(function(e,t,n,r,o){let a,i,s=0;do{i=t+(n-t)/2,a=ya(i,r,o)-e,a>0?n=i:t=i}while(Math.abs(a)>1e-7&&++s<12);return i}(o,0,1,e,n),t,r)}const ba=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,xa=e=>t=>1-e(1-t),wa=va(.33,1.53,.69,.99),Ea=xa(wa),_a=ba(Ea),ka=e=>(e*=2)<1?.5*Ea(e):.5*(2-Math.pow(2,-10*(e-1))),Sa=e=>1-Math.sin(Math.acos(e)),Na=xa(Sa),Ca=ba(Sa),Pa=e=>/^0[^.\s]+$/u.test(e),Ta=(e,t,n)=>n>t?t:n"number"==typeof e,parse:parseFloat,transform:e=>e},Aa={...ja,transform:e=>Ta(0,1,e)},Ra={...ja,default:1},Fa=e=>Math.round(1e5*e)/1e5,Da=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu,Ma=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Oa=(e,t)=>n=>Boolean("string"==typeof n&&Ma.test(n)&&n.startsWith(e)||t&&!function(e){return null==e}(n)&&Object.prototype.hasOwnProperty.call(n,t)),Ia=(e,t,n)=>r=>{if("string"!=typeof r)return r;const[o,a,i,s]=r.match(Da);return{[e]:parseFloat(o),[t]:parseFloat(a),[n]:parseFloat(i),alpha:void 0!==s?parseFloat(s):1}},La={...ja,transform:e=>Math.round((e=>Ta(0,255,e))(e))},za={test:Oa("rgb","red"),parse:Ia("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+La.transform(e)+", "+La.transform(t)+", "+La.transform(n)+", "+Fa(Aa.transform(r))+")"},Ba={test:Oa("#"),parse:function(e){let t="",n="",r="",o="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),o=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),o=e.substring(4,5),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}},transform:za.transform},Va=e=>({test:t=>"string"==typeof t&&t.endsWith(e)&&1===t.split(" ").length,parse:parseFloat,transform:t=>`${t}${e}`}),Ua=Va("deg"),Wa=Va("%"),Ha=Va("px"),$a=Va("vh"),qa=Va("vw"),Ya={...Wa,parse:e=>Wa.parse(e)/100,transform:e=>Wa.transform(100*e)},Ga={test:Oa("hsl","hue"),parse:Ia("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+Wa.transform(Fa(t))+", "+Wa.transform(Fa(n))+", "+Fa(Aa.transform(r))+")"},Xa={test:e=>za.test(e)||Ba.test(e)||Ga.test(e),parse:e=>za.test(e)?za.parse(e):Ga.test(e)?Ga.parse(e):Ba.parse(e),transform:e=>"string"==typeof e?e:e.hasOwnProperty("red")?za.transform(e):Ga.transform(e)},Ka=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu,Ja="number",Za="color",Qa=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function ei(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},o=[];let a=0;const i=t.replace(Qa,(e=>(Xa.test(e)?(r.color.push(a),o.push(Za),n.push(Xa.parse(e))):e.startsWith("var(")?(r.var.push(a),o.push("var"),n.push(e)):(r.number.push(a),o.push(Ja),n.push(parseFloat(e))),++a,"${}"))).split("${}");return{values:n,split:i,indexes:r,types:o}}function ti(e){return ei(e).values}function ni(e){const{split:t,types:n}=ei(e),r=t.length;return e=>{let o="";for(let a=0;a"number"==typeof e?0:e,oi={test:function(e){var t,n;return isNaN(e)&&"string"==typeof e&&((null===(t=e.match(Da))||void 0===t?void 0:t.length)||0)+((null===(n=e.match(Ka))||void 0===n?void 0:n.length)||0)>0},parse:ti,createTransformer:ni,getAnimatableNone:function(e){const t=ti(e);return ni(e)(t.map(ri))}},ai=new Set(["brightness","contrast","saturate","opacity"]);function ii(e){const[t,n]=e.slice(0,-1).split("(");if("drop-shadow"===t)return e;const[r]=n.match(Da)||[];if(!r)return e;const o=n.replace(r,"");let a=ai.has(t)?1:0;return r!==n&&(a*=100),t+"("+a+o+")"}const si=/\b([a-z-]*)\(.*?\)/gu,li={...oi,getAnimatableNone:e=>{const t=e.match(si);return t?t.map(ii).join(" "):e}},ci={borderWidth:Ha,borderTopWidth:Ha,borderRightWidth:Ha,borderBottomWidth:Ha,borderLeftWidth:Ha,borderRadius:Ha,radius:Ha,borderTopLeftRadius:Ha,borderTopRightRadius:Ha,borderBottomRightRadius:Ha,borderBottomLeftRadius:Ha,width:Ha,maxWidth:Ha,height:Ha,maxHeight:Ha,top:Ha,right:Ha,bottom:Ha,left:Ha,padding:Ha,paddingTop:Ha,paddingRight:Ha,paddingBottom:Ha,paddingLeft:Ha,margin:Ha,marginTop:Ha,marginRight:Ha,marginBottom:Ha,marginLeft:Ha,backgroundPositionX:Ha,backgroundPositionY:Ha},ui={rotate:Ua,rotateX:Ua,rotateY:Ua,rotateZ:Ua,scale:Ra,scaleX:Ra,scaleY:Ra,scaleZ:Ra,skew:Ua,skewX:Ua,skewY:Ua,distance:Ha,translateX:Ha,translateY:Ha,translateZ:Ha,x:Ha,y:Ha,z:Ha,perspective:Ha,transformPerspective:Ha,opacity:Aa,originX:Ya,originY:Ya,originZ:Ha},di={...ja,transform:Math.round},mi={...ci,...ui,zIndex:di,size:Ha,fillOpacity:Aa,strokeOpacity:Aa,numOctaves:di},fi={...mi,color:Xa,backgroundColor:Xa,outlineColor:Xa,fill:Xa,stroke:Xa,borderColor:Xa,borderTopColor:Xa,borderRightColor:Xa,borderBottomColor:Xa,borderLeftColor:Xa,filter:li,WebkitFilter:li},pi=e=>fi[e];function hi(e,t){let n=pi(e);return n!==li&&(n=oi),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const gi=new Set(["auto","none","0"]),yi=e=>e===ja||e===Ha,vi=(e,t)=>parseFloat(e.split(", ")[t]),bi=(e,t)=>(n,{transform:r})=>{if("none"===r||!r)return 0;const o=r.match(/^matrix3d\((.+)\)$/u);if(o)return vi(o[1],t);{const t=r.match(/^matrix\((.+)\)$/u);return t?vi(t[1],e):0}},xi=new Set(["x","y","z"]),wi=$o.filter((e=>!xi.has(e))),Ei={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:bi(4,13),y:bi(5,14)};Ei.translateX=Ei.x,Ei.translateY=Ei.y;const _i=new Set;let ki=!1,Si=!1;function Ni(){if(Si){const e=Array.from(_i).filter((e=>e.needsMeasurement)),t=new Set(e.map((e=>e.element))),n=new Map;t.forEach((e=>{const t=function(e){const t=[];return wi.forEach((n=>{const r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),t}(e);t.length&&(n.set(e,t),e.render())})),e.forEach((e=>e.measureInitialState())),t.forEach((e=>{e.render();const t=n.get(e);t&&t.forEach((([t,n])=>{var r;null===(r=e.getValue(t))||void 0===r||r.set(n)}))})),e.forEach((e=>e.measureEndState())),e.forEach((e=>{void 0!==e.suspendedScrollY&&window.scrollTo(0,e.suspendedScrollY)}))}Si=!1,ki=!1,_i.forEach((e=>e.complete())),_i.clear()}function Ci(){_i.forEach((e=>{e.readKeyframes(),e.needsMeasurement&&(Si=!0)}))}class Pi{constructor(e,t,n,r,o,a=!1){this.isComplete=!1,this.isAsync=!1,this.needsMeasurement=!1,this.isScheduled=!1,this.unresolvedKeyframes=[...e],this.onComplete=t,this.name=n,this.motionValue=r,this.element=o,this.isAsync=a}scheduleResolve(){this.isScheduled=!0,this.isAsync?(_i.add(this),ki||(ki=!0,Jo.read(Ci),Jo.resolveKeyframes(Ni))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:t,element:n,motionValue:r}=this;for(let o=0;o/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e),Ri=e=>t=>"string"==typeof t&&t.startsWith(e),Fi=Ri("--"),Di=Ri("var(--"),Mi=e=>!!Di(e)&&Oi.test(e.split("/*")[0].trim()),Oi=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,Ii=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function Li(e,t,n=1){ji(n<=4,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`);const[r,o]=function(e){const t=Ii.exec(e);if(!t)return[,];const[,n,r,o]=t;return[`--${null!=n?n:r}`,o]}(e);if(!r)return;const a=window.getComputedStyle(t).getPropertyValue(r);if(a){const e=a.trim();return Ai(e)?parseFloat(e):e}return Mi(o)?Li(o,t,n+1):o}const zi=e=>t=>t.test(e),Bi=[ja,Ha,Wa,Ua,qa,$a,{test:e=>"auto"===e,parse:e=>e}],Vi=e=>Bi.find(zi(e));class Ui extends Pi{constructor(e,t,n,r,o){super(e,t,n,r,o,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:t,name:n}=this;if(!t||!t.current)return;super.readKeyframes();for(let n=0;n{t.getValue(e).set(n)})),this.resolveNoneKeyframes()}}const Wi=(e,t)=>!("zIndex"===t||"number"!=typeof e&&!Array.isArray(e)&&("string"!=typeof e||!oi.test(e)&&"0"!==e||e.startsWith("url(")));function Hi(e,t,n,r){const o=e[0];if(null===o)return!1;if("display"===t||"visibility"===t)return!0;const a=e[e.length-1],i=Wi(o,t),s=Wi(a,t);return Ti(i===s,`You are trying to animate ${t} from "${o}" to "${a}". ${o} is not an animatable value - to enable this animation set ${o} to a value animatable to ${a} via the \`style\` property.`),!(!i||!s)&&(function(e){const t=e[0];if(1===e.length)return!0;for(let n=0;nnull!==e;function qi(e,{repeat:t,repeatType:n="loop"},r){const o=e.filter($i),a=t&&"loop"!==n&&t%2==1?0:o.length-1;return a&&void 0!==r?r:o[a]}class Yi{constructor({autoplay:e=!0,delay:t=0,type:n="keyframes",repeat:r=0,repeatDelay:o=0,repeatType:a="loop",...i}){this.isStopped=!1,this.hasAttemptedResolve=!1,this.createdAt=ra.now(),this.options={autoplay:e,delay:t,type:n,repeat:r,repeatDelay:o,repeatType:a,...i},this.updateFinishedPromise()}calcStartTime(){return this.resolvedAt&&this.resolvedAt-this.createdAt>40?this.resolvedAt:this.createdAt}get resolved(){return this._resolved||this.hasAttemptedResolve||(Ci(),Ni()),this._resolved}onKeyframesResolved(e,t){this.resolvedAt=ra.now(),this.hasAttemptedResolve=!0;const{name:n,type:r,velocity:o,delay:a,onComplete:i,onUpdate:s,isGenerator:l}=this.options;if(!l&&!Hi(e,n,r,o)){if(!a)return s&&s(qi(e,this.options,t)),i&&i(),void this.resolveFinishedPromise();this.options.duration=0}const c=this.initPlayback(e,t);!1!==c&&(this._resolved={keyframes:e,finalKeyframe:t,...c},this.onPostResolved())}onPostResolved(){}then(e,t){return this.currentFinishedPromise.then(e,t)}flatten(){this.options.type="keyframes",this.options.ease="linear"}updateFinishedPromise(){this.currentFinishedPromise=new Promise((e=>{this.resolveFinishedPromise=e}))}}const Gi=(e,t,n)=>e+(t-e)*n;function Xi(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+6*(t-e)*n:n<.5?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Ki(e,t){return n=>n>0?t:e}const Ji=(e,t,n)=>{const r=e*e,o=n*(t*t-r)+r;return o<0?0:Math.sqrt(o)},Zi=[Ba,za,Ga];function Qi(e){const t=(e=>Zi.find((t=>t.test(e))))(e);if(Ti(Boolean(t),`'${e}' is not an animatable color. Use the equivalent color code instead.`),!Boolean(t))return!1;let n=t.parse(e);return t===Ga&&(n=function({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,n/=100;let o=0,a=0,i=0;if(t/=100){const r=n<.5?n*(1+t):n+t-n*t,s=2*n-r;o=Xi(s,r,e+1/3),a=Xi(s,r,e),i=Xi(s,r,e-1/3)}else o=a=i=n;return{red:Math.round(255*o),green:Math.round(255*a),blue:Math.round(255*i),alpha:r}}(n)),n}const es=(e,t)=>{const n=Qi(e),r=Qi(t);if(!n||!r)return Ki(e,t);const o={...n};return e=>(o.red=Ji(n.red,r.red,e),o.green=Ji(n.green,r.green,e),o.blue=Ji(n.blue,r.blue,e),o.alpha=Gi(n.alpha,r.alpha,e),za.transform(o))},ts=(e,t)=>n=>t(e(n)),ns=(...e)=>e.reduce(ts),rs=new Set(["none","hidden"]);function os(e,t){return n=>Gi(e,t,n)}function as(e){return"number"==typeof e?os:"string"==typeof e?Mi(e)?Ki:Xa.test(e)?es:ls:Array.isArray(e)?is:"object"==typeof e?Xa.test(e)?es:ss:Ki}function is(e,t){const n=[...e],r=n.length,o=e.map(((e,n)=>as(e)(e,t[n])));return e=>{for(let t=0;t{for(const t in r)n[t]=r[t](e);return n}}const ls=(e,t)=>{const n=oi.createTransformer(t),r=ei(e),o=ei(t);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?rs.has(e)&&!o.values.length||rs.has(t)&&!r.values.length?function(e,t){return rs.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}(e,t):ns(is(function(e,t){var n;const r=[],o={color:0,var:0,number:0};for(let a=0;avoid 0!==e[t]))}function xs(e=.3,t=.3){const n="object"!=typeof e?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:o}=n;const a=n.keyframes[0],i=n.keyframes[n.keyframes.length-1],s={done:!1,value:a},{stiffness:l,damping:c,mass:u,duration:d,velocity:m,isResolvedFromDuration:f}=function(e){let t={velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1,...e};if(!bs(e,vs)&&bs(e,ys))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(1.2*n),o=r*r,a=2*Ta(.05,1,1-(e.bounce||0))*Math.sqrt(o);t={...t,mass:1,stiffness:o,damping:a}}else{const n=function({duration:e=800,bounce:t=.3,velocity:n=0,mass:r=1}){let o,a;Ti(e<=Uo(10),"Spring duration must be 10 seconds or less");let i=1-t;i=Ta(.05,1,i),e=Ta(.01,10,Wo(e)),i<1?(o=t=>{const r=t*i,o=r*e;return.001-(r-n)/gs(t,i)*Math.exp(-o)},a=t=>{const r=t*i*e,a=r*n+n,s=Math.pow(i,2)*Math.pow(t,2)*e,l=Math.exp(-r),c=gs(Math.pow(t,2),i);return(.001-o(t)>0?-1:1)*((a-s)*l)/c}):(o=t=>Math.exp(-t*e)*((t-n)*e+1)-.001,a=t=>Math.exp(-t*e)*(e*e*(n-t)));const s=function(e,t,n){let r=n;for(let n=1;n{const n=Math.exp(-h*y*t);return i-n*((p+h*y*g)/e*Math.sin(e*t)+g*Math.cos(e*t))}}else if(1===h)b=e=>i-Math.exp(-y*e)*(g+(p+y*g)*e);else{const e=y*Math.sqrt(h*h-1);b=t=>{const n=Math.exp(-h*y*t),r=Math.min(e*t,300);return i-n*((p+h*y*g)*Math.sinh(r)+e*g*Math.cosh(r))/e}}const x={calculatedDuration:f&&d||null,next:e=>{const t=b(e);if(f)s.done=e>=d;else{let n=0;h<1&&(n=0===e?Uo(p):us(b,e,t));const a=Math.abs(n)<=r,l=Math.abs(i-t)<=o;s.done=a&&l}return s.value=s.done?i:t,s},toString:()=>{const e=Math.min(vo(x),yo),t=No((t=>x.next(e*t).value),e,30);return e+"ms "+t}};return x}function ws({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:a=500,modifyTarget:i,min:s,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],m={done:!1,value:d},f=e=>void 0===s?l:void 0===l||Math.abs(s-e)-p*Math.exp(-e/r),v=e=>g+y(e),b=e=>{const t=y(e),n=v(e);m.done=Math.abs(t)<=c,m.value=m.done?g:n};let x,w;const E=e=>{(e=>void 0!==s&&el)(m.value)&&(x=e,w=xs({keyframes:[m.value,f(m.value)],velocity:us(v,e,m.value),damping:o,stiffness:a,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:e=>{let t=!1;return w||void 0!==x||(t=!0,b(e),E(e)),void 0!==x&&e>=x?w.next(e-x):(!t&&b(e),m)}}}const Es=va(.42,0,1,1),_s=va(0,0,.58,1),ks=va(.42,0,.58,1),Ss={linear:Ho,easeIn:Es,easeInOut:ks,easeOut:_s,circIn:Sa,circInOut:Ca,circOut:Na,backIn:Ea,backInOut:_a,backOut:wa,anticipate:ka},Ns=e=>{if(wo(e)){ji(4===e.length,"Cubic bezier arrays must contain four numerical values.");const[t,n,r,o]=e;return va(t,n,r,o)}return"string"==typeof e?(ji(void 0!==Ss[e],`Invalid easing type '${e}'`),Ss[e]):e};function Cs({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const o=(e=>Array.isArray(e)&&"number"!=typeof e[0])(r)?r.map(Ns):Ns(r),a={done:!1,value:t[0]},i=function(e,t){return e.map((e=>e*t))}(n&&n.length===t.length?n:function(e){const t=[0];return function(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const o=So(0,t,r);e.push(Gi(n,1,o))}}(t,e.length-1),t}(t),e),s=function(e,t,{clamp:n=!0,ease:r,mixer:o}={}){const a=e.length;if(ji(a===t.length,"Both input and output ranges must be the same length"),1===a)return()=>t[0];if(2===a&&t[0]===t[1])return()=>t[1];const i=e[0]===e[1];e[0]>e[a-1]&&(e=[...e].reverse(),t=[...t].reverse());const s=function(e,t,n){const r=[],o=n||cs,a=e.length-1;for(let n=0;n{if(i&&n1)for(;rc(Ta(e[0],e[a-1],t)):c}(i,t,{ease:Array.isArray(o)?o:(l=t,c=o,l.map((()=>c||ks)).splice(0,l.length-1))});var l,c;return{calculatedDuration:e,next:t=>(a.value=s(t),a.done=t>=e,a)}}const Ps=e=>{const t=({timestamp:t})=>e(t);return{start:()=>Jo.update(t,!0),stop:()=>Zo(t),now:()=>Qo.isProcessing?Qo.timestamp:ra.now()}},Ts={decay:ws,inertia:ws,tween:Cs,keyframes:Cs,spring:xs},js=e=>e/100;class As extends Yi{constructor(e){super(e),this.holdTime=null,this.cancelTime=null,this.currentTime=0,this.playbackSpeed=1,this.pendingPlayState="running",this.startTime=null,this.state="idle",this.stop=()=>{if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.teardown();const{onStop:e}=this.options;e&&e()};const{name:t,motionValue:n,element:r,keyframes:o}=this.options,a=(null==r?void 0:r.KeyframeResolver)||Pi;this.resolver=new a(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}flatten(){super.flatten(),this._resolved&&Object.assign(this._resolved,this.initPlayback(this._resolved.keyframes))}initPlayback(e){const{type:t="keyframes",repeat:n=0,repeatDelay:r=0,repeatType:o,velocity:a=0}=this.options,i=bo(t)?t:Ts[t]||Cs;let s,l;i!==Cs&&"number"!=typeof e[0]&&(s=ns(js,cs(e[0],e[1])),e=[0,100]);const c=i({...this.options,keyframes:e});"mirror"===o&&(l=i({...this.options,keyframes:[...e].reverse(),velocity:-a})),null===c.calculatedDuration&&(c.calculatedDuration=vo(c));const{calculatedDuration:u}=c,d=u+r;return{generator:c,mirroredGenerator:l,mapPercentToKeyframes:s,calculatedDuration:u,resolvedDuration:d,totalDuration:d*(n+1)-r}}onPostResolved(){const{autoplay:e=!0}=this.options;this.play(),"paused"!==this.pendingPlayState&&e?this.state=this.pendingPlayState:this.pause()}tick(e,t=!1){const{resolved:n}=this;if(!n){const{keyframes:e}=this.options;return{done:!0,value:e[e.length-1]}}const{finalKeyframe:r,generator:o,mirroredGenerator:a,mapPercentToKeyframes:i,keyframes:s,calculatedDuration:l,totalDuration:c,resolvedDuration:u}=n;if(null===this.startTime)return o.next(0);const{delay:d,repeat:m,repeatType:f,repeatDelay:p,onUpdate:h}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-c/this.speed,this.startTime)),t?this.currentTime=e:null!==this.holdTime?this.currentTime=this.holdTime:this.currentTime=Math.round(e-this.startTime)*this.speed;const g=this.currentTime-d*(this.speed>=0?1:-1),y=this.speed>=0?g<0:g>c;this.currentTime=Math.max(g,0),"finished"===this.state&&null===this.holdTime&&(this.currentTime=c);let v=this.currentTime,b=o;if(m){const e=Math.min(this.currentTime,c)/u;let t=Math.floor(e),n=e%1;!n&&e>=1&&(n=1),1===n&&t--,t=Math.min(t,m+1),Boolean(t%2)&&("reverse"===f?(n=1-n,p&&(n-=p/u)):"mirror"===f&&(b=a)),v=Ta(0,1,n)*u}const x=y?{done:!1,value:s[0]}:b.next(v);i&&(x.value=i(x.value));let{done:w}=x;y||null===l||(w=this.speed>=0?this.currentTime>=c:this.currentTime<=0);const E=null===this.holdTime&&("finished"===this.state||"running"===this.state&&w);return E&&void 0!==r&&(x.value=qi(s,this.options,r)),h&&h(x.value),E&&this.finish(),x}get duration(){const{resolved:e}=this;return e?Wo(e.calculatedDuration):0}get time(){return Wo(this.currentTime)}set time(e){e=Uo(e),this.currentTime=e,null!==this.holdTime||0===this.speed?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.speed)}get speed(){return this.playbackSpeed}set speed(e){const t=this.playbackSpeed!==e;this.playbackSpeed=e,t&&(this.time=Wo(this.currentTime))}play(){if(this.resolver.isScheduled||this.resolver.resume(),!this._resolved)return void(this.pendingPlayState="running");if(this.isStopped)return;const{driver:e=Ps,onPlay:t,startTime:n}=this.options;this.driver||(this.driver=e((e=>this.tick(e)))),t&&t();const r=this.driver.now();null!==this.holdTime?this.startTime=r-this.holdTime:this.startTime?"finished"===this.state&&(this.startTime=r):this.startTime=null!=n?n:this.calcStartTime(),"finished"===this.state&&this.updateFinishedPromise(),this.cancelTime=this.startTime,this.holdTime=null,this.state="running",this.driver.start()}pause(){var e;this._resolved?(this.state="paused",this.holdTime=null!==(e=this.currentTime)&&void 0!==e?e:0):this.pendingPlayState="paused"}complete(){"running"!==this.state&&this.play(),this.pendingPlayState=this.state="finished",this.holdTime=null}finish(){this.teardown(),this.state="finished";const{onComplete:e}=this.options;e&&e()}cancel(){null!==this.cancelTime&&this.tick(this.cancelTime),this.teardown(),this.updateFinishedPromise()}teardown(){this.state="idle",this.stopDriver(),this.resolveFinishedPromise(),this.updateFinishedPromise(),this.startTime=this.cancelTime=null,this.resolver.cancel()}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}}const Rs=new Set(["opacity","clipPath","filter","transform"]),Fs=mo((()=>Object.hasOwnProperty.call(Element.prototype,"animate"))),Ds={anticipate:ka,backInOut:_a,circInOut:Ca};class Ms extends Yi{constructor(e){super(e);const{name:t,motionValue:n,element:r,keyframes:o}=this.options;this.resolver=new Ui(o,((e,t)=>this.onKeyframesResolved(e,t)),t,n,r),this.resolver.scheduleResolve()}initPlayback(e,t){let{duration:n=300,times:r,ease:o,type:a,motionValue:i,name:s,startTime:l}=this.options;if(!i.owner||!i.owner.current)return!1;var c;if("string"==typeof o&&ko()&&o in Ds&&(o=Ds[o]),bo((c=this.options).type)||"spring"===c.type||!Co(c.ease)){const{onComplete:t,onUpdate:i,motionValue:s,element:l,...c}=this.options,u=function(e,t){const n=new As({...t,keyframes:e,repeat:0,delay:0,isGenerator:!0});let r={done:!1,value:e[0]};const o=[];let a=0;for(;!r.done&&a<2e4;)r=n.sample(a),o.push(r.value),a+=10;return{times:void 0,keyframes:o,duration:a-10,ease:"linear"}}(e,c);1===(e=u.keyframes).length&&(e[1]=e[0]),n=u.duration,r=u.times,o=u.ease,a="keyframes"}const u=function(e,t,n,{delay:r=0,duration:o=300,repeat:a=0,repeatType:i="loop",ease:s="easeInOut",times:l}={}){const c={[t]:n};l&&(c.offset=l);const u=jo(s,o);return Array.isArray(u)&&(c.easing=u),e.animate(c,{delay:r,duration:o,easing:Array.isArray(u)?"linear":u,fill:"both",iterations:a+1,direction:"reverse"===i?"alternate":"normal"})}(i.owner.current,s,e,{...this.options,duration:n,times:r,ease:o});return u.startTime=null!=l?l:this.calcStartTime(),this.pendingTimeline?(xo(u,this.pendingTimeline),this.pendingTimeline=void 0):u.onfinish=()=>{const{onComplete:n}=this.options;i.set(qi(e,this.options,t)),n&&n(),this.cancel(),this.resolveFinishedPromise()},{animation:u,duration:n,times:r,type:a,ease:o,keyframes:e}}get duration(){const{resolved:e}=this;if(!e)return 0;const{duration:t}=e;return Wo(t)}get time(){const{resolved:e}=this;if(!e)return 0;const{animation:t}=e;return Wo(t.currentTime||0)}set time(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.currentTime=Uo(e)}get speed(){const{resolved:e}=this;if(!e)return 1;const{animation:t}=e;return t.playbackRate}set speed(e){const{resolved:t}=this;if(!t)return;const{animation:n}=t;n.playbackRate=e}get state(){const{resolved:e}=this;if(!e)return"idle";const{animation:t}=e;return t.playState}get startTime(){const{resolved:e}=this;if(!e)return null;const{animation:t}=e;return t.startTime}attachTimeline(e){if(this._resolved){const{resolved:t}=this;if(!t)return Ho;const{animation:n}=t;xo(n,e)}else this.pendingTimeline=e;return Ho}play(){if(this.isStopped)return;const{resolved:e}=this;if(!e)return;const{animation:t}=e;"finished"===t.playState&&this.updateFinishedPromise(),t.play()}pause(){const{resolved:e}=this;if(!e)return;const{animation:t}=e;t.pause()}stop(){if(this.resolver.cancel(),this.isStopped=!0,"idle"===this.state)return;this.resolveFinishedPromise(),this.updateFinishedPromise();const{resolved:e}=this;if(!e)return;const{animation:t,keyframes:n,duration:r,type:o,ease:a,times:i}=e;if("idle"===t.playState||"finished"===t.playState)return;if(this.time){const{motionValue:e,onUpdate:t,onComplete:s,element:l,...c}=this.options,u=new As({...c,keyframes:n,duration:r,type:o,ease:a,times:i,isGenerator:!0}),d=Uo(this.time);e.setWithVelocity(u.sample(d-10).value,u.sample(d).value,10)}const{onStop:s}=this.options;s&&s(),this.cancel()}complete(){const{resolved:e}=this;e&&e.animation.finish()}cancel(){const{resolved:e}=this;e&&e.animation.cancel()}static supports(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:o,damping:a,type:i}=e;if(!(t&&t.owner&&t.owner.current instanceof HTMLElement))return!1;const{onUpdate:s,transformTemplate:l}=t.owner.getProps();return Fs()&&n&&Rs.has(n)&&!s&&!l&&!r&&"mirror"!==o&&0!==a&&"inertia"!==i}}const Os={type:"spring",stiffness:500,damping:25,restSpeed:10},Is={type:"keyframes",duration:.8},Ls={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},zs=(e,{keyframes:t})=>t.length>2?Is:qo.has(e)?e.startsWith("scale")?{type:"spring",stiffness:550,damping:0===t[1]?2*Math.sqrt(550):30,restSpeed:10}:Os:Ls,Bs=(e,t,n,r={},o,a)=>i=>{const s=go(r,e)||{},l=s.delay||r.delay||0;let{elapsed:c=0}=r;c-=Uo(l);let u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...s,delay:-c,onUpdate:e=>{t.set(e),s.onUpdate&&s.onUpdate(e)},onComplete:()=>{i(),s.onComplete&&s.onComplete()},name:e,motionValue:t,element:a?void 0:o};(function({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:o,repeat:a,repeatType:i,repeatDelay:s,from:l,elapsed:c,...u}){return!!Object.keys(u).length})(s)||(u={...u,...zs(e,u)}),u.duration&&(u.duration=Uo(u.duration)),u.repeatDelay&&(u.repeatDelay=Uo(u.repeatDelay)),void 0!==u.from&&(u.keyframes[0]=u.from);let d=!1;if((!1===u.type||0===u.duration&&!u.repeatDelay)&&(u.duration=0,0===u.delay&&(d=!0)),d&&!a&&void 0!==t.get()){const e=qi(u.keyframes,s);if(void 0!==e)return Jo.update((()=>{u.onUpdate(e),u.onComplete()})),new ho([])}return!a&&Ms.supports(u)?new Ms(u):new As(u)};function Vs({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&!0!==t[n];return t[n]=!1,r}function Us(e,t,{delay:n=0,transitionOverride:r,type:o}={}){var a;let{transition:i=e.getDefaultTransition(),transitionEnd:s,...l}=t;r&&(i=r);const c=[],u=o&&e.animationState&&e.animationState.getState()[o];for(const t in l){const r=e.getValue(t,null!==(a=e.latestValues[t])&&void 0!==a?a:null),o=l[t];if(void 0===o||u&&Vs(u,t))continue;const s={delay:n,...go(i||{},t)};let d=!1;if(window.MotionHandoffAnimation){const n=ga(e);if(n){const e=window.MotionHandoffAnimation(n,t,Jo);null!==e&&(s.startTime=e,d=!0)}}fa(e,t),r.start(Bs(t,r,o,e.shouldReduceMotion&&Yo.has(t)?{type:!1}:s,e,d));const m=r.animation;m&&c.push(m)}return s&&Promise.all(c).then((()=>{Jo.update((()=>{s&&function(e,t){const n=lo(e,t);let{transitionEnd:r={},transition:o={},...a}=n||{};a={...a,...r};for(const t in a)da(e,t,Go(a[t]))}(e,s)}))})),c}function Ws(e,t,n={}){var r;const o=lo(e,t,"exit"===n.type?null===(r=e.presenceContext)||void 0===r?void 0:r.custom:void 0);let{transition:a=e.getDefaultTransition()||{}}=o||{};n.transitionOverride&&(a=n.transitionOverride);const i=o?()=>Promise.all(Us(e,o,n)):()=>Promise.resolve(),s=e.variantChildren&&e.variantChildren.size?(r=0)=>{const{delayChildren:o=0,staggerChildren:i,staggerDirection:s}=a;return function(e,t,n=0,r=0,o=1,a){const i=[],s=(e.variantChildren.size-1)*r,l=1===o?(e=0)=>e*r:(e=0)=>s-e*r;return Array.from(e.variantChildren).sort(Hs).forEach(((e,r)=>{e.notify("AnimationStart",t),i.push(Ws(e,t,{...a,delay:n+l(r)}).then((()=>e.notify("AnimationComplete",t))))})),Promise.all(i)}(e,t,o+r,i,s,n)}:()=>Promise.resolve(),{when:l}=a;if(l){const[e,t]="beforeChildren"===l?[i,s]:[s,i];return e().then((()=>t()))}return Promise.all([i(),s(n.delay)])}function Hs(e,t){return e.sortNodePosition(t)}const $s=uo.length;function qs(e){if(!e)return;if(!e.isControllingVariants){const t=e.parent&&qs(e.parent)||{};return void 0!==e.props.initial&&(t.initial=e.props.initial),t}const t={};for(let n=0;n<$s;n++){const r=uo[n],o=e.props[r];(ao(o)||!1===o)&&(t[r]=o)}return t}const Ys=[...co].reverse(),Gs=co.length;function Xs(e){let t=function(e){return t=>Promise.all(t.map((({animation:t,options:n})=>function(e,t,n={}){let r;if(e.notify("AnimationStart",t),Array.isArray(t)){const o=t.map((t=>Ws(e,t,n)));r=Promise.all(o)}else if("string"==typeof t)r=Ws(e,t,n);else{const o="function"==typeof t?lo(e,t,n.custom):t;r=Promise.all(Us(e,o,n))}return r.then((()=>{e.notify("AnimationComplete",t)}))}(e,t,n))))}(e),n=Zs(),r=!0;const o=t=>(n,r)=>{var o;const a=lo(e,r,"exit"===t?null===(o=e.presenceContext)||void 0===o?void 0:o.custom:void 0);if(a){const{transition:e,transitionEnd:t,...r}=a;n={...n,...r,...t}}return n};function a(a){const{props:i}=e,s=qs(e.parent)||{},l=[],c=new Set;let u={},d=1/0;for(let t=0;td&&h,x=!1;const w=Array.isArray(p)?p:[p];let E=w.reduce(o(m),{});!1===g&&(E={});const{prevResolvedValues:_={}}=f,k={..._,...E},S=t=>{b=!0,c.has(t)&&(x=!0,c.delete(t)),f.needsAnimating[t]=!0;const n=e.getValue(t);n&&(n.liveStyle=!1)};for(const e in k){const t=E[e],n=_[e];if(u.hasOwnProperty(e))continue;let r=!1;r=ro(t)&&ro(n)?!oo(t,n):t!==n,r?null!=t?S(e):c.add(e):void 0!==t&&c.has(e)?S(e):f.protectedKeys[e]=!0}f.prevProp=p,f.prevResolvedValues=E,f.isActive&&(u={...u,...E}),r&&e.blockInitialAnimation&&(b=!1),b&&(!y||!v||x)&&l.push(...w.map((e=>({animation:e,options:{type:m}}))))}if(c.size){const t={};c.forEach((n=>{const r=e.getBaseTarget(n),o=e.getValue(n);o&&(o.liveStyle=!0),t[n]=null!=r?r:null})),l.push({animation:t})}let m=Boolean(l.length);return!r||!1!==i.initial&&i.initial!==i.animate||e.manuallyAnimateOnMount||(m=!1),r=!1,m?t(l):Promise.resolve()}return{animateChanges:a,setActive:function(t,r){var o;if(n[t].isActive===r)return Promise.resolve();null===(o=e.variantChildren)||void 0===o||o.forEach((e=>{var n;return null===(n=e.animationState)||void 0===n?void 0:n.setActive(t,r)})),n[t].isActive=r;const i=a(t);for(const e in n)n[e].protectedKeys={};return i},setAnimateFunction:function(n){t=n(e)},getState:()=>n,reset:()=>{n=Zs(),r=!0}}}function Ks(e,t){return"string"==typeof t?t!==e:!!Array.isArray(t)&&!oo(t,e)}function Js(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Zs(){return{animate:Js(!0),whileInView:Js(),whileHover:Js(),whileTap:Js(),whileDrag:Js(),whileFocus:Js(),exit:Js()}}class Qs{constructor(e){this.isMounted=!1,this.node=e}update(){}}let el=0;const tl={animation:{Feature:class extends Qs{constructor(e){super(e),e.animationState||(e.animationState=Xs(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();no(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:t}=this.node.prevProps||{};e!==t&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),null===(e=this.unmountControls)||void 0===e||e.call(this)}}},exit:{Feature:class extends Qs{constructor(){super(...arguments),this.id=el++}update(){if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:t}=this.node.presenceContext,{isPresent:n}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===n)return;const r=this.node.animationState.setActive("exit",!e);t&&!e&&r.then((()=>t(this.id)))}mount(){const{register:e}=this.node.presenceContext||{};e&&(this.unmount=e(this.id))}unmount(){}}}};function nl(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function rl(e){return{point:{x:e.pageX,y:e.pageY}}}function ol(e,t,n,r){return nl(e,t,(e=>t=>Oo(t)&&e(t,rl(t)))(n),r)}const al=(e,t)=>Math.abs(e-t);class il{constructor(e,t,{transformPagePoint:n,contextWindow:r,dragSnapToOrigin:o=!1}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!this.lastMoveEvent||!this.lastMoveEventInfo)return;const e=cl(this.lastMoveEventInfo,this.history),t=null!==this.startEvent,n=function(e,t){const n=al(e.x,t.x),r=al(e.y,t.y);return Math.sqrt(n**2+r**2)}(e.offset,{x:0,y:0})>=3;if(!t&&!n)return;const{point:r}=e,{timestamp:o}=Qo;this.history.push({...r,timestamp:o});const{onStart:a,onMove:i}=this.handlers;t||(a&&a(this.lastMoveEvent,e),this.startEvent=this.lastMoveEvent),i&&i(this.lastMoveEvent,e)},this.handlePointerMove=(e,t)=>{this.lastMoveEvent=e,this.lastMoveEventInfo=sl(t,this.transformPagePoint),Jo.update(this.updatePoint,!0)},this.handlePointerUp=(e,t)=>{this.end();const{onEnd:n,onSessionEnd:r,resumeAnimation:o}=this.handlers;if(this.dragSnapToOrigin&&o&&o(),!this.lastMoveEvent||!this.lastMoveEventInfo)return;const a=cl("pointercancel"===e.type?this.lastMoveEventInfo:sl(t,this.transformPagePoint),this.history);this.startEvent&&n&&n(e,a),r&&r(e,a)},!Oo(e))return;this.dragSnapToOrigin=o,this.handlers=t,this.transformPagePoint=n,this.contextWindow=r||window;const a=sl(rl(e),this.transformPagePoint),{point:i}=a,{timestamp:s}=Qo;this.history=[{...i,timestamp:s}];const{onSessionStart:l}=t;l&&l(e,cl(a,this.history)),this.removeListeners=ns(ol(this.contextWindow,"pointermove",this.handlePointerMove),ol(this.contextWindow,"pointerup",this.handlePointerUp),ol(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),Zo(this.updatePoint)}}function sl(e,t){return t?{point:t(e.point)}:e}function ll(e,t){return{x:e.x-t.x,y:e.y-t.y}}function cl({point:e},t){return{point:e,delta:ll(e,dl(t)),offset:ll(e,ul(t)),velocity:ml(t,.1)}}function ul(e){return e[0]}function dl(e){return e[e.length-1]}function ml(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const o=dl(e);for(;n>=0&&(r=e[n],!(o.timestamp-r.timestamp>Uo(t)));)n--;if(!r)return{x:0,y:0};const a=Wo(o.timestamp-r.timestamp);if(0===a)return{x:0,y:0};const i={x:(o.x-r.x)/a,y:(o.y-r.y)/a};return i.x===1/0&&(i.x=0),i.y===1/0&&(i.y=0),i}function fl(e){return e&&"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function pl(e){return e.max-e.min}function hl(e,t,n,r=.5){e.origin=r,e.originPoint=Gi(t.min,t.max,e.origin),e.scale=pl(n)/pl(t),e.translate=Gi(n.min,n.max,e.origin)-e.originPoint,(e.scale>=.9999&&e.scale<=1.0001||isNaN(e.scale))&&(e.scale=1),(e.translate>=-.01&&e.translate<=.01||isNaN(e.translate))&&(e.translate=0)}function gl(e,t,n,r){hl(e.x,t.x,n.x,r?r.originX:void 0),hl(e.y,t.y,n.y,r?r.originY:void 0)}function yl(e,t,n){e.min=n.min+t.min,e.max=e.min+pl(t)}function vl(e,t,n){e.min=t.min-n.min,e.max=e.min+pl(t)}function bl(e,t,n){vl(e.x,t.x,n.x),vl(e.y,t.y,n.y)}function xl(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function wl(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min({x:{min:0,max:0},y:{min:0,max:0}});function Nl(e){return[e("x"),e("y")]}function Cl({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function Pl(e){return void 0===e||1===e}function Tl({scale:e,scaleX:t,scaleY:n}){return!Pl(e)||!Pl(t)||!Pl(n)}function jl(e){return Tl(e)||Al(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Al(e){return Rl(e.x)||Rl(e.y)}function Rl(e){return e&&"0%"!==e}function Fl(e,t,n){return n+t*(e-n)}function Dl(e,t,n,r,o){return void 0!==o&&(e=Fl(e,o,r)),Fl(e,n,r)+t}function Ml(e,t=0,n=1,r,o){e.min=Dl(e.min,t,n,r,o),e.max=Dl(e.max,t,n,r,o)}function Ol(e,{x:t,y:n}){Ml(e.x,t.translate,t.scale,t.originPoint),Ml(e.y,n.translate,n.scale,n.originPoint)}const Il=.999999999999,Ll=1.0000000000001;function zl(e,t){e.min=e.min+t,e.max=e.max+t}function Bl(e,t,n,r,o=.5){Ml(e,t,n,Gi(e.min,e.max,o),r)}function Vl(e,t){Bl(e.x,t.x,t.scaleX,t.scale,t.originX),Bl(e.y,t.y,t.scaleY,t.scale,t.originY)}function Ul(e,t){return Cl(function(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}(e.getBoundingClientRect(),t))}const Wl=({current:e})=>e?e.ownerDocument.defaultView:null,Hl=new WeakMap;class $l{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic={x:{min:0,max:0},y:{min:0,max:0}},this.visualElement=e}start(e,{snapToCursor:t=!1}={}){const{presenceContext:n}=this.visualElement;if(n&&!1===n.isPresent)return;const{dragSnapToOrigin:r}=this.getProps();this.panSession=new il(e,{onSessionStart:e=>{const{dragSnapToOrigin:n}=this.getProps();n?this.pauseAnimation():this.stopAnimation(),t&&this.snapToCursor(rl(e).point)},onStart:(e,t)=>{const{drag:n,dragPropagation:r,onDragStart:o}=this.getProps();if(n&&!r&&(this.openDragLock&&this.openDragLock(),this.openDragLock="x"===(a=n)||"y"===a?Ao[a]?null:(Ao[a]=!0,()=>{Ao[a]=!1}):Ao.x||Ao.y?null:(Ao.x=Ao.y=!0,()=>{Ao.x=Ao.y=!1}),!this.openDragLock))return;var a;this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Nl((e=>{let t=this.getAxisMotionValue(e).get()||0;if(Wa.test(t)){const{projection:n}=this.visualElement;if(n&&n.layout){const r=n.layout.layoutBox[e];r&&(t=pl(r)*(parseFloat(t)/100))}}this.originPoint[e]=t})),o&&Jo.postRender((()=>o(e,t))),fa(this.visualElement,"transform");const{animationState:i}=this.visualElement;i&&i.setActive("whileDrag",!0)},onMove:(e,t)=>{const{dragPropagation:n,dragDirectionLock:r,onDirectionLock:o,onDrag:a}=this.getProps();if(!n&&!this.openDragLock)return;const{offset:i}=t;if(r&&null===this.currentDirection)return this.currentDirection=function(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}(i),void(null!==this.currentDirection&&o&&o(this.currentDirection));this.updateAxis("x",t.point,i),this.updateAxis("y",t.point,i),this.visualElement.render(),a&&a(e,t)},onSessionEnd:(e,t)=>this.stop(e,t),resumeAnimation:()=>Nl((e=>{var t;return"paused"===this.getAnimationState(e)&&(null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.play())}))},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:r,contextWindow:Wl(this.visualElement)})}stop(e,t){const n=this.isDragging;if(this.cancel(),!n)return;const{velocity:r}=t;this.startAnimation(r);const{onDragEnd:o}=this.getProps();o&&Jo.postRender((()=>o(e,t)))}cancel(){this.isDragging=!1;const{projection:e,animationState:t}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:n}=this.getProps();!n&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),t&&t.setActive("whileDrag",!1)}updateAxis(e,t,n){const{drag:r}=this.getProps();if(!n||!ql(e,r,this.currentDirection))return;const o=this.getAxisMotionValue(e);let a=this.originPoint[e]+n[e];this.constraints&&this.constraints[e]&&(a=function(e,{min:t,max:n},r){return void 0!==t&&en&&(e=r?Gi(n,e,r.max):Math.min(e,n)),e}(a,this.constraints[e],this.elastic[e])),o.set(a)}resolveConstraints(){var e;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):null===(e=this.visualElement.projection)||void 0===e?void 0:e.layout,o=this.constraints;t&&fl(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):this.constraints=!(!t||!r)&&function(e,{top:t,left:n,bottom:r,right:o}){return{x:xl(e.x,n,o),y:xl(e.y,t,r)}}(r.layoutBox,t),this.elastic=function(e=El){return!1===e?e=0:!0===e&&(e=El),{x:_l(e,"left","right"),y:_l(e,"top","bottom")}}(n),o!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Nl((e=>{!1!==this.constraints&&this.getAxisMotionValue(e)&&(this.constraints[e]=function(e,t){const n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(r.layoutBox[e],this.constraints[e]))}))}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:t}=this.getProps();if(!e||!fl(e))return!1;const n=e.current;ji(null!==n,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.");const{projection:r}=this.visualElement;if(!r||!r.layout)return!1;const o=function(e,t,n){const r=Ul(e,n),{scroll:o}=t;return o&&(zl(r.x,o.offset.x),zl(r.y,o.offset.y)),r}(n,r.root,this.visualElement.getTransformPagePoint());let a=function(e,t){return{x:wl(e.x,t.x),y:wl(e.y,t.y)}}(r.layout.layoutBox,o);if(t){const e=t(function({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}(a));this.hasMutatedConstraints=!!e,e&&(a=Cl(e))}return a}startAnimation(e){const{drag:t,dragMomentum:n,dragElastic:r,dragTransition:o,dragSnapToOrigin:a,onDragTransitionEnd:i}=this.getProps(),s=this.constraints||{},l=Nl((i=>{if(!ql(i,t,this.currentDirection))return;let l=s&&s[i]||{};a&&(l={min:0,max:0});const c=r?200:1e6,u=r?40:1e7,d={type:"inertia",velocity:n?e[i]:0,bounceStiffness:c,bounceDamping:u,timeConstant:750,restDelta:1,restSpeed:10,...o,...l};return this.startAxisValueAnimation(i,d)}));return Promise.all(l).then(i)}startAxisValueAnimation(e,t){const n=this.getAxisMotionValue(e);return fa(this.visualElement,e),n.start(Bs(e,n,0,t,this.visualElement,!1))}stopAnimation(){Nl((e=>this.getAxisMotionValue(e).stop()))}pauseAnimation(){Nl((e=>{var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.pause()}))}getAnimationState(e){var t;return null===(t=this.getAxisMotionValue(e).animation)||void 0===t?void 0:t.state}getAxisMotionValue(e){const t=`_drag${e.toUpperCase()}`,n=this.visualElement.getProps();return n[t]||this.visualElement.getValue(e,(n.initial?n.initial[e]:void 0)||0)}snapToCursor(e){Nl((t=>{const{drag:n}=this.getProps();if(!ql(t,n,this.currentDirection))return;const{projection:r}=this.visualElement,o=this.getAxisMotionValue(t);if(r&&r.layout){const{min:n,max:a}=r.layout.layoutBox[t];o.set(e[t]-Gi(n,a,.5))}}))}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:t}=this.getProps(),{projection:n}=this.visualElement;if(!fl(t)||!n||!this.constraints)return;this.stopAnimation();const r={x:0,y:0};Nl((e=>{const t=this.getAxisMotionValue(e);if(t&&!1!==this.constraints){const n=t.get();r[e]=function(e,t){let n=.5;const r=pl(e),o=pl(t);return o>r?n=So(t.min,t.max-r,e.min):r>o&&(n=So(e.min,e.max-o,t.min)),Ta(0,1,n)}({min:n,max:n},this.constraints[e])}}));const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",n.root&&n.root.updateScroll(),n.updateLayout(),this.resolveConstraints(),Nl((t=>{if(!ql(t,e,null))return;const n=this.getAxisMotionValue(t),{min:o,max:a}=this.constraints[t];n.set(Gi(o,a,r[t]))}))}addListeners(){if(!this.visualElement.current)return;Hl.set(this.visualElement,this);const e=ol(this.visualElement.current,"pointerdown",(e=>{const{drag:t,dragListener:n=!0}=this.getProps();t&&n&&this.start(e)})),t=()=>{const{dragConstraints:e}=this.getProps();fl(e)&&e.current&&(this.constraints=this.resolveRefConstraints())},{projection:n}=this.visualElement,r=n.addEventListener("measure",t);n&&!n.layout&&(n.root&&n.root.updateScroll(),n.updateLayout()),Jo.read(t);const o=nl(window,"resize",(()=>this.scalePositionWithinConstraints())),a=n.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t})=>{this.isDragging&&t&&(Nl((t=>{const n=this.getAxisMotionValue(t);n&&(this.originPoint[t]+=e[t].translate,n.set(n.get()+e[t].translate))})),this.visualElement.render())}));return()=>{o(),e(),r(),a&&a()}}getProps(){const e=this.visualElement.getProps(),{drag:t=!1,dragDirectionLock:n=!1,dragPropagation:r=!1,dragConstraints:o=!1,dragElastic:a=El,dragMomentum:i=!0}=e;return{...e,drag:t,dragDirectionLock:n,dragPropagation:r,dragConstraints:o,dragElastic:a,dragMomentum:i}}}function ql(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}const Yl=e=>(t,n)=>{e&&Jo.postRender((()=>e(t,n)))},Gl=(0,s.createContext)(null);function Xl(e=!0){const t=(0,s.useContext)(Gl);if(null===t)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=t,a=(0,s.useId)();(0,s.useEffect)((()=>{e&&o(a)}),[e]);const i=(0,s.useCallback)((()=>e&&r&&r(a)),[a,r,e]);return!n&&r?[!1,i]:[!0]}const Kl=(0,s.createContext)({}),Jl=(0,s.createContext)({}),Zl={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function Ql(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const ec={correct:(e,t)=>{if(!t.target)return e;if("string"==typeof e){if(!Ha.test(e))return e;e=parseFloat(e)}return`${Ql(e,t.target.x)}% ${Ql(e,t.target.y)}%`}},tc={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,o=oi.parse(e);if(o.length>5)return r;const a=oi.createTransformer(e),i="number"!=typeof o[0]?1:0,s=n.x.scale*t.x,l=n.y.scale*t.y;o[0+i]/=s,o[1+i]/=l;const c=Gi(s,l,.5);return"number"==typeof o[2+i]&&(o[2+i]/=c),"number"==typeof o[3+i]&&(o[3+i]/=c),a(o)}},nc={},{schedule:rc,cancel:oc}=Ko(queueMicrotask,!1);class ac extends s.Component{componentDidMount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n,layoutId:r}=this.props,{projection:o}=e;var a;a=sc,Object.assign(nc,a),o&&(t.group&&t.group.add(o),n&&n.register&&r&&n.register(o),o.root.didUpdate(),o.addEventListener("animationComplete",(()=>{this.safeToRemove()})),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),Zl.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:t,visualElement:n,drag:r,isPresent:o}=this.props,a=n.projection;return a?(a.isPresent=o,r||e.layoutDependency!==t||void 0===t?a.willUpdate():this.safeToRemove(),e.isPresent!==o&&(o?a.promote():a.relegate()||Jo.postRender((()=>{const e=a.getStack();e&&e.members.length||this.safeToRemove()}))),null):null}componentDidUpdate(){const{projection:e}=this.props.visualElement;e&&(e.root.didUpdate(),rc.postRender((()=>{!e.currentAnimation&&e.isLead()&&this.safeToRemove()})))}componentWillUnmount(){const{visualElement:e,layoutGroup:t,switchLayoutGroup:n}=this.props,{projection:r}=e;r&&(r.scheduleCheckAfterUnmount(),t&&t.group&&t.group.remove(r),n&&n.deregister&&n.deregister(r))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function ic(e){const[t,n]=Xl(),r=(0,s.useContext)(Kl);return(0,I.jsx)(ac,{...e,layoutGroup:r,switchLayoutGroup:(0,s.useContext)(Jl),isPresent:t,safeToRemove:n})}const sc={borderRadius:{...ec,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ec,borderTopRightRadius:ec,borderBottomLeftRadius:ec,borderBottomRightRadius:ec,boxShadow:tc},lc=(e,t)=>e.depth-t.depth;class cc{constructor(){this.children=[],this.isDirty=!1}add(e){oa(this.children,e),this.isDirty=!0}remove(e){aa(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(lc),this.isDirty=!1,this.children.forEach(e)}}function uc(e){const t=ma(e)?e.get():e;return(e=>Boolean(e&&"object"==typeof e&&e.mix&&e.toValue))(t)?t.toValue():t}const dc=["TopLeft","TopRight","BottomLeft","BottomRight"],mc=dc.length,fc=e=>"string"==typeof e?parseFloat(e):e,pc=e=>"number"==typeof e||Ha.test(e);function hc(e,t){return void 0!==e[t]?e[t]:e.borderRadius}const gc=vc(0,.5,Na),yc=vc(.5,.95,Ho);function vc(e,t,n){return r=>rt?1:n(So(e,t,r))}function bc(e,t){e.min=t.min,e.max=t.max}function xc(e,t){bc(e.x,t.x),bc(e.y,t.y)}function wc(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Ec(e,t,n,r,o){return e=Fl(e-=t,1/n,r),void 0!==o&&(e=Fl(e,1/o,r)),e}function _c(e,t,[n,r,o],a,i){!function(e,t=0,n=1,r=.5,o,a=e,i=e){if(Wa.test(t)&&(t=parseFloat(t),t=Gi(i.min,i.max,t/100)-i.min),"number"!=typeof t)return;let s=Gi(a.min,a.max,r);e===a&&(s-=t),e.min=Ec(e.min,t,n,s,o),e.max=Ec(e.max,t,n,s,o)}(e,t[n],t[r],t[o],t.scale,a,i)}const kc=["x","scaleX","originX"],Sc=["y","scaleY","originY"];function Nc(e,t,n,r){_c(e.x,t,kc,n?n.x:void 0,r?r.x:void 0),_c(e.y,t,Sc,n?n.y:void 0,r?r.y:void 0)}function Cc(e){return 0===e.translate&&1===e.scale}function Pc(e){return Cc(e.x)&&Cc(e.y)}function Tc(e,t){return e.min===t.min&&e.max===t.max}function jc(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function Ac(e,t){return jc(e.x,t.x)&&jc(e.y,t.y)}function Rc(e){return pl(e.x)/pl(e.y)}function Fc(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class Dc{constructor(){this.members=[]}add(e){oa(this.members,e),e.scheduleRender()}remove(e){if(aa(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const e=this.members[this.members.length-1];e&&this.promote(e)}}relegate(e){const t=this.members.findIndex((t=>e===t));if(0===t)return!1;let n;for(let e=t;e>=0;e--){const t=this.members[e];if(!1!==t.isPresent){n=t;break}}return!!n&&(this.promote(n),!0)}promote(e,t){const n=this.lead;if(e!==n&&(this.prevLead=n,this.lead=e,e.show(),n)){n.instance&&n.scheduleRender(),e.scheduleRender(),e.resumeFrom=n,t&&(e.resumeFrom.preserveOpacity=!0),n.snapshot&&(e.snapshot=n.snapshot,e.snapshot.latestValues=n.animationValues||n.latestValues),e.root&&e.root.isUpdating&&(e.isLayoutDirty=!0);const{crossfade:r}=e.options;!1===r&&n.hide()}}exitAnimationComplete(){this.members.forEach((e=>{const{options:t,resumingFrom:n}=e;t.onExitComplete&&t.onExitComplete(),n&&n.options.onExitComplete&&n.options.onExitComplete()}))}scheduleRender(){this.members.forEach((e=>{e.instance&&e.scheduleRender(!1)}))}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}const Mc={type:"projectionFrame",totalNodes:0,resolvedTargetDeltas:0,recalculatedProjection:0},Oc="undefined"!=typeof window&&void 0!==window.MotionDebug,Ic=["","X","Y","Z"],Lc={visibility:"hidden"};let zc=0;function Bc(e,t,n,r){const{latestValues:o}=t;o[e]&&(n[e]=o[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Vc(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=ga(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:t,layoutId:r}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Jo,!(t||r))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Vc(r)}function Uc({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(e={},n=(null==t?void 0:t())){this.id=zc++,this.animationId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,Oc&&(Mc.totalNodes=Mc.resolvedTargetDeltas=Mc.recalculatedProjection=0),this.nodes.forEach($c),this.nodes.forEach(Zc),this.nodes.forEach(Qc),this.nodes.forEach(qc),Oc&&window.MotionDebug.record(Mc)},this.resolvedRelativeTargetAt=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=e,this.root=n?n.root||n:this,this.path=n?[...n.path,n]:[],this.parent=n,this.depth=n?n.depth+1:0;for(let e=0;ethis.root.updateBlockedByResize=!1;e(t,(()=>{this.root.updateBlockedByResize=!0,n&&n(),n=function(e,t){const n=ra.now(),r=({timestamp:o})=>{const a=o-n;a>=t&&(Zo(r),e(a-t))};return Jo.read(r,!0),()=>Zo(r)}(r,250),Zl.hasAnimatedSinceResize&&(Zl.hasAnimatedSinceResize=!1,this.nodes.forEach(Jc))}))}o&&this.root.registerSharedNode(o,this),!1!==this.options.animate&&i&&(o||a)&&this.addEventListener("didUpdate",(({delta:e,hasLayoutChanged:t,hasRelativeTargetChanged:n,layout:r})=>{if(this.isTreeAnimationBlocked())return this.target=void 0,void(this.relativeTarget=void 0);const o=this.options.transition||i.getDefaultTransition()||au,{onLayoutAnimationStart:a,onLayoutAnimationComplete:s}=i.getProps(),l=!this.targetLayout||!Ac(this.targetLayout,r)||n,c=!t&&n;if(this.options.layoutRoot||this.resumeFrom&&this.resumeFrom.instance||c||t&&(l||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0),this.setAnimationOrigin(e,c);const t={...go(o,"layout"),onPlay:a,onComplete:s};(i.shouldReduceMotion||this.options.layoutRoot)&&(t.delay=0,t.type=!1),this.startAnimation(t)}else t||Jc(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=r}))}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const e=this.getStack();e&&e.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,Zo(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(eu),this.animationId++)}getTransformTemplate(){const{visualElement:e}=this.options;return e&&e.getProps().transformTemplate}willUpdate(e=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked())return void(this.options.onExitComplete&&this.options.onExitComplete());if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Vc(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let e=0;e{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()}))}updateSnapshot(){!this.snapshot&&this.instance&&(this.snapshot=this.measure())}updateLayout(){if(!this.instance)return;if(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead()||this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let e=0;eIl&&(t.x=1),t.yIl&&(t.y=1)}(this.layoutCorrected,this.treeScale,this.path,n),!t.layout||t.target||1===this.treeScale.x&&1===this.treeScale.y||(t.target=t.layout.layoutBox,t.targetWithTransforms={x:{min:0,max:0},y:{min:0,max:0}});const{target:l}=t;l?(this.projectionDelta&&this.prevProjectionDelta?(wc(this.prevProjectionDelta.x,this.projectionDelta.x),wc(this.prevProjectionDelta.y,this.projectionDelta.y)):this.createProjectionDeltas(),gl(this.projectionDelta,this.layoutCorrected,l,this.latestValues),this.treeScale.x===i&&this.treeScale.y===s&&Fc(this.projectionDelta.x,this.prevProjectionDelta.x)&&Fc(this.projectionDelta.y,this.prevProjectionDelta.y)||(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",l)),Oc&&Mc.recalculatedProjection++):this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender())}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(e=!0){var t;if(null===(t=this.options.visualElement)||void 0===t||t.scheduleRender(),e){const e=this.getStack();e&&e.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDelta={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}},this.projectionDeltaWithTransform={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}}}setAnimationOrigin(e,t=!1){const n=this.snapshot,r=n?n.latestValues:{},o={...this.latestValues},a={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};this.relativeParent&&this.relativeParent.options.layoutRoot||(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!t;const i={x:{min:0,max:0},y:{min:0,max:0}},s=(n?n.source:void 0)!==(this.layout?this.layout.source:void 0),l=this.getStack(),c=!l||l.members.length<=1,u=Boolean(s&&!c&&!0===this.options.crossfade&&!this.path.some(ou));let d;this.animationProgress=0,this.mixTargetDelta=t=>{const n=t/1e3;nu(a.x,e.x,n),nu(a.y,e.y,n),this.setTargetDelta(a),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(bl(i,this.layout.layoutBox,this.relativeParent.layout.layoutBox),function(e,t,n,r){ru(e.x,t.x,n.x,r),ru(e.y,t.y,n.y,r)}(this.relativeTarget,this.relativeTargetOrigin,i,n),d&&function(e,t){return Tc(e.x,t.x)&&Tc(e.y,t.y)}(this.relativeTarget,d)&&(this.isProjectionDirty=!1),d||(d={x:{min:0,max:0},y:{min:0,max:0}}),xc(d,this.relativeTarget)),s&&(this.animationValues=o,function(e,t,n,r,o,a){o?(e.opacity=Gi(0,void 0!==n.opacity?n.opacity:1,gc(r)),e.opacityExit=Gi(void 0!==t.opacity?t.opacity:1,0,yc(r))):a&&(e.opacity=Gi(void 0!==t.opacity?t.opacity:1,void 0!==n.opacity?n.opacity:1,r));for(let o=0;o{Zl.hasAnimatedSinceResize=!0,this.currentAnimation=function(e,t,n){const r=ma(0)?0:ua(0);return r.start(Bs("",r,1e3,n)),r.animation}(0,0,{...e,onUpdate:t=>{this.mixTargetDelta(t),e.onUpdate&&e.onUpdate(t)},onComplete:()=>{e.onComplete&&e.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0}))}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const e=this.getStack();e&&e.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(1e3),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const e=this.getLead();let{targetWithTransforms:t,target:n,layout:r,latestValues:o}=e;if(t&&n&&r){if(this!==e&&this.layout&&r&&cu(this.options.animationType,this.layout.layoutBox,r.layoutBox)){n=this.target||{x:{min:0,max:0},y:{min:0,max:0}};const t=pl(this.layout.layoutBox.x);n.x.min=e.target.x.min,n.x.max=n.x.min+t;const r=pl(this.layout.layoutBox.y);n.y.min=e.target.y.min,n.y.max=n.y.min+r}xc(t,n),Vl(t,o),gl(this.projectionDeltaWithTransform,this.layoutCorrected,t,o)}}registerSharedNode(e,t){this.sharedNodes.has(e)||this.sharedNodes.set(e,new Dc),this.sharedNodes.get(e).add(t);const n=t.options.initialPromotionConfig;t.promote({transition:n?n.transition:void 0,preserveFollowOpacity:n&&n.shouldPreserveFollowOpacity?n.shouldPreserveFollowOpacity(t):void 0})}isLead(){const e=this.getStack();return!e||e.lead===this}getLead(){var e;const{layoutId:t}=this.options;return t&&(null===(e=this.getStack())||void 0===e?void 0:e.lead)||this}getPrevLead(){var e;const{layoutId:t}=this.options;return t?null===(e=this.getStack())||void 0===e?void 0:e.prevLead:void 0}getStack(){const{layoutId:e}=this.options;if(e)return this.root.sharedNodes.get(e)}promote({needsReset:e,transition:t,preserveFollowOpacity:n}={}){const r=this.getStack();r&&r.promote(this,n),e&&(this.projectionDelta=void 0,this.needsReset=!0),t&&this.setOptions({transition:t})}relegate(){const e=this.getStack();return!!e&&e.relegate(this)}resetSkewAndRotation(){const{visualElement:e}=this.options;if(!e)return;let t=!1;const{latestValues:n}=e;if((n.z||n.rotate||n.rotateX||n.rotateY||n.rotateZ||n.skewX||n.skewY)&&(t=!0),!t)return;const r={};n.z&&Bc("z",e,r,this.animationValues);for(let t=0;t{var t;return null===(t=e.currentAnimation)||void 0===t?void 0:t.stop()})),this.root.nodes.forEach(Gc),this.root.sharedNodes.clear()}}}function Wc(e){e.updateLayout()}function Hc(e){var t;const n=(null===(t=e.resumeFrom)||void 0===t?void 0:t.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&n&&e.hasListeners("didUpdate")){const{layoutBox:t,measuredBox:r}=e.layout,{animationType:o}=e.options,a=n.source!==e.layout.source;"size"===o?Nl((e=>{const r=a?n.measuredBox[e]:n.layoutBox[e],o=pl(r);r.min=t[e].min,r.max=r.min+o})):cu(o,n.layoutBox,t)&&Nl((r=>{const o=a?n.measuredBox[r]:n.layoutBox[r],i=pl(t[r]);o.max=o.min+i,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[r].max=e.relativeTarget[r].min+i)}));const i={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};gl(i,t,n.layoutBox);const s={x:{translate:0,scale:1,origin:0,originPoint:0},y:{translate:0,scale:1,origin:0,originPoint:0}};a?gl(s,e.applyTransform(r,!0),n.measuredBox):gl(s,t,n.layoutBox);const l=!Pc(i);let c=!1;if(!e.resumeFrom){const r=e.getClosestProjectingParent();if(r&&!r.resumeFrom){const{snapshot:o,layout:a}=r;if(o&&a){const i={x:{min:0,max:0},y:{min:0,max:0}};bl(i,n.layoutBox,o.layoutBox);const s={x:{min:0,max:0},y:{min:0,max:0}};bl(s,t,a.layoutBox),Ac(i,s)||(c=!0),r.options.layoutRoot&&(e.relativeTarget=s,e.relativeTargetOrigin=i,e.relativeParent=r)}}}e.notifyListeners("didUpdate",{layout:t,snapshot:n,delta:s,layoutDelta:i,hasLayoutChanged:l,hasRelativeTargetChanged:c})}else if(e.isLead()){const{onExitComplete:t}=e.options;t&&t()}e.options.transition=void 0}function $c(e){Oc&&Mc.totalNodes++,e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=Boolean(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function qc(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function Yc(e){e.clearSnapshot()}function Gc(e){e.clearMeasurements()}function Xc(e){e.isLayoutDirty=!1}function Kc(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Jc(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function Zc(e){e.resolveTargetDelta()}function Qc(e){e.calcProjection()}function eu(e){e.resetSkewAndRotation()}function tu(e){e.removeLeadSnapshot()}function nu(e,t,n){e.translate=Gi(t.translate,0,n),e.scale=Gi(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function ru(e,t,n,r){e.min=Gi(t.min,n.min,r),e.max=Gi(t.max,n.max,r)}function ou(e){return e.animationValues&&void 0!==e.animationValues.opacityExit}const au={duration:.45,ease:[.4,0,.1,1]},iu=e=>"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),su=iu("applewebkit/")&&!iu("chrome/")?Math.round:Ho;function lu(e){e.min=su(e.min),e.max=su(e.max)}function cu(e,t,n){return"position"===e||"preserve-aspect"===e&&(r=Rc(t),o=Rc(n),!(Math.abs(r-o)<=.2));var r,o}function uu(e){var t;return e!==e.root&&(null===(t=e.scroll)||void 0===t?void 0:t.wasRoot)}const du=Uc({attachResizeListener:(e,t)=>nl(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),mu={current:void 0},fu=Uc({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!mu.current){const e=new du({});e.mount(window),e.setOptions({layoutScroll:!0}),mu.current=e}return mu.current},resetTransform:(e,t)=>{e.style.transform=void 0!==t?t:"none"},checkIsScrollRoot:e=>Boolean("fixed"===window.getComputedStyle(e).position)}),pu={pan:{Feature:class extends Qs{constructor(){super(...arguments),this.removePointerDownListener=Ho}onPointerDown(e){this.session=new il(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:Wl(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:t,onPan:n,onPanEnd:r}=this.node.getProps();return{onSessionStart:Yl(e),onStart:Yl(t),onMove:n,onEnd:(e,t)=>{delete this.session,r&&Jo.postRender((()=>r(e,t)))}}}mount(){this.removePointerDownListener=ol(this.node.current,"pointerdown",(e=>this.onPointerDown(e)))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}},drag:{Feature:class extends Qs{constructor(e){super(e),this.removeGroupControls=Ho,this.removeListeners=Ho,this.controls=new $l(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ho}unmount(){this.removeGroupControls(),this.removeListeners()}},ProjectionNode:fu,MeasureLayout:ic}};function hu(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover","Start"===n);const o=r["onHover"+n];o&&Jo.postRender((()=>o(t,rl(t))))}function gu(e,t,n){const{props:r}=e;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap","Start"===n);const o=r["onTap"+("End"===n?"":n)];o&&Jo.postRender((()=>o(t,rl(t))))}const yu=new WeakMap,vu=new WeakMap,bu=e=>{const t=yu.get(e.target);t&&t(e)},xu=e=>{e.forEach(bu)};const wu={some:0,all:1},Eu={inView:{Feature:class extends Qs{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:e={}}=this.node.getProps(),{root:t,margin:n,amount:r="some",once:o}=e,a={root:t?t.current:void 0,rootMargin:n,threshold:"number"==typeof r?r:wu[r]};return function(e,t,n){const r=function({root:e,...t}){const n=e||document;vu.has(n)||vu.set(n,{});const r=vu.get(n),o=JSON.stringify(t);return r[o]||(r[o]=new IntersectionObserver(xu,{root:e,...t})),r[o]}(t);return yu.set(e,n),r.observe(e),()=>{yu.delete(e),r.unobserve(e)}}(this.node.current,a,(e=>{const{isIntersecting:t}=e;if(this.isInView===t)return;if(this.isInView=t,o&&!t&&this.hasEnteredView)return;t&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",t);const{onViewportEnter:n,onViewportLeave:r}=this.node.getProps(),a=t?n:r;a&&a(e)}))}mount(){this.startObserver()}update(){if("undefined"==typeof IntersectionObserver)return;const{props:e,prevProps:t}=this.node;["amount","margin","root"].some(function({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}(e,t))&&this.startObserver()}unmount(){}}},tap:{Feature:class extends Qs{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[r,o,a]=Fo(e,n),i=e=>{const r=e.currentTarget;if(!Vo(e)||Lo.has(r))return;Lo.add(r);const a=t(e),i=(e,t)=>{window.removeEventListener("pointerup",s),window.removeEventListener("pointercancel",l),Vo(e)&&Lo.has(r)&&(Lo.delete(r),"function"==typeof a&&a(e,{success:t}))},s=e=>{i(e,n.useGlobalTarget||Mo(r,e.target))},l=e=>{i(e,!1)};window.addEventListener("pointerup",s,o),window.addEventListener("pointercancel",l,o)};return r.forEach((e=>{(function(e){return Io.has(e.tagName)||-1!==e.tabIndex})(e)||null!==e.getAttribute("tabindex")||(e.tabIndex=0),(n.useGlobalTarget?window:e).addEventListener("pointerdown",i,o),e.addEventListener("focus",(e=>((e,t)=>{const n=e.currentTarget;if(!n)return;const r=zo((()=>{if(Lo.has(n))return;Bo(n,"down");const e=zo((()=>{Bo(n,"up")}));n.addEventListener("keyup",e,t),n.addEventListener("blur",(()=>Bo(n,"cancel")),t)}));n.addEventListener("keydown",r,t),n.addEventListener("blur",(()=>n.removeEventListener("keydown",r)),t)})(e,o)),o)})),a}(e,(e=>(gu(this.node,e,"Start"),(e,{success:t})=>gu(this.node,e,t?"End":"Cancel"))),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}},focus:{Feature:class extends Qs{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch(t){e=!0}e&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){this.isActive&&this.node.animationState&&(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=ns(nl(this.node.current,"focus",(()=>this.onFocus())),nl(this.node.current,"blur",(()=>this.onBlur())))}unmount(){}}},hover:{Feature:class extends Qs{mount(){const{current:e}=this.node;e&&(this.unmount=function(e,t,n={}){const[r,o,a]=Fo(e,n),i=Do((e=>{const{target:n}=e,r=t(e);if("function"!=typeof r||!n)return;const a=Do((e=>{r(e),n.removeEventListener("pointerleave",a)}));n.addEventListener("pointerleave",a,o)}));return r.forEach((e=>{e.addEventListener("pointerenter",i,o)})),a}(e,(e=>(hu(this.node,e,"Start"),e=>hu(this.node,e,"End")))))}unmount(){}}}},_u={layout:{ProjectionNode:fu,MeasureLayout:ic}},ku=(0,s.createContext)({strict:!1}),Su=(0,s.createContext)({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"}),Nu=(0,s.createContext)({});function Cu(e){return no(e.animate)||uo.some((t=>ao(e[t])))}function Pu(e){return Boolean(Cu(e)||e.variants)}function Tu(e){return Array.isArray(e)?e.join(" "):e}const ju="undefined"!=typeof window,Au={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},Ru={};for(const e in Au)Ru[e]={isEnabled:t=>Au[e].some((e=>!!t[e]))};const Fu=Symbol.for("motionComponentSymbol");function Du(e,t,n){return(0,s.useCallback)((r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&("function"==typeof n?n(r):fl(n)&&(n.current=r))}),[t])}const Mu=ju?s.useLayoutEffect:s.useEffect;function Ou(e,t,n,r,o){var a,i;const{visualElement:l}=(0,s.useContext)(Nu),c=(0,s.useContext)(ku),u=(0,s.useContext)(Gl),d=(0,s.useContext)(Su).reducedMotion,m=(0,s.useRef)(null);r=r||c.renderer,!m.current&&r&&(m.current=r(e,{visualState:t,parent:l,props:n,presenceContext:u,blockInitialAnimation:!!u&&!1===u.initial,reducedMotionConfig:d}));const f=m.current,p=(0,s.useContext)(Jl);!f||f.projection||!o||"html"!==f.type&&"svg"!==f.type||function(e,t,n,r){const{layoutId:o,layout:a,drag:i,dragConstraints:s,layoutScroll:l,layoutRoot:c}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Iu(e.parent)),e.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:Boolean(i)||s&&fl(s),visualElement:e,animationType:"string"==typeof a?a:"both",initialPromotionConfig:r,layoutScroll:l,layoutRoot:c})}(m.current,n,o,p);const h=(0,s.useRef)(!1);(0,s.useInsertionEffect)((()=>{f&&h.current&&f.update(n,u)}));const g=n[ha],y=(0,s.useRef)(Boolean(g)&&!(null===(a=window.MotionHandoffIsComplete)||void 0===a?void 0:a.call(window,g))&&(null===(i=window.MotionHasOptimisedAnimation)||void 0===i?void 0:i.call(window,g)));return Mu((()=>{f&&(h.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),rc.render(f.render),y.current&&f.animationState&&f.animationState.animateChanges())})),(0,s.useEffect)((()=>{f&&(!y.current&&f.animationState&&f.animationState.animateChanges(),y.current&&(queueMicrotask((()=>{var e;null===(e=window.MotionHandoffMarkAsComplete)||void 0===e||e.call(window,g)})),y.current=!1))})),f}function Iu(e){if(e)return!1!==e.options.allowProjection?e.projection:Iu(e.parent)}function Lu({preloadedFeatures:e,createVisualElement:t,useRender:n,useVisualState:r,Component:o}){var a,i;function l(e,a){let i;const l={...(0,s.useContext)(Su),...e,layoutId:zu(e)},{isStatic:c}=l,u=function(e){const{initial:t,animate:n}=function(e,t){if(Cu(e)){const{initial:t,animate:n}=e;return{initial:!1===t||ao(t)?t:void 0,animate:ao(n)?n:void 0}}return!1!==e.inherit?t:{}}(e,(0,s.useContext)(Nu));return(0,s.useMemo)((()=>({initial:t,animate:n})),[Tu(t),Tu(n)])}(e),d=r(e,c);if(!c&&ju){(0,s.useContext)(ku).strict;const e=function(e){const{drag:t,layout:n}=Ru;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:(null==t?void 0:t.isEnabled(e))||(null==n?void 0:n.isEnabled(e))?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}(l);i=e.MeasureLayout,u.visualElement=Ou(o,d,l,t,e.ProjectionNode)}return(0,I.jsxs)(Nu.Provider,{value:u,children:[i&&u.visualElement?(0,I.jsx)(i,{visualElement:u.visualElement,...l}):null,n(o,e,Du(d,u.visualElement,a),d,c,u.visualElement)]})}e&&function(e){for(const t in e)Ru[t]={...Ru[t],...e[t]}}(e),l.displayName=`motion.${"string"==typeof o?o:`create(${null!==(i=null!==(a=o.displayName)&&void 0!==a?a:o.name)&&void 0!==i?i:""})`}`;const c=(0,s.forwardRef)(l);return c[Fu]=o,c}function zu({layoutId:e}){const t=(0,s.useContext)(Kl).id;return t&&void 0!==e?t+"-"+e:e}const Bu=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Vu(e){return"string"==typeof e&&!e.includes("-")&&!!(Bu.indexOf(e)>-1||/[A-Z]/u.test(e))}function Uu(e){const t=(0,s.useRef)(null);return null===t.current&&(t.current=e()),t.current}const Wu=e=>(t,n)=>{const r=(0,s.useContext)(Nu),o=(0,s.useContext)(Gl),a=()=>function({scrapeMotionValuesFromProps:e,createRenderState:t,onUpdate:n},r,o,a){const i={latestValues:Hu(r,o,a,e),renderState:t()};return n&&(i.onMount=e=>n({props:r,current:e,...i}),i.onUpdate=e=>n(e)),i}(e,t,r,o);return n?a():Uu(a)};function Hu(e,t,n,r){const o={},a=r(e,{});for(const e in a)o[e]=uc(a[e]);let{initial:i,animate:s}=e;const l=Cu(e),c=Pu(e);t&&c&&!l&&!1!==e.inherit&&(void 0===i&&(i=t.initial),void 0===s&&(s=t.animate));let u=!!n&&!1===n.initial;u=u||!1===i;const d=u?s:i;if(d&&"boolean"!=typeof d&&!no(d)){const t=Array.isArray(d)?d:[d];for(let n=0;nt&&"number"==typeof e?t.transform(e):e,qu={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},Yu=$o.length;function Gu(e,t,n){const{style:r,vars:o,transformOrigin:a}=e;let i=!1,s=!1;for(const e in t){const n=t[e];if(qo.has(e))i=!0;else if(Fi(e))o[e]=n;else{const t=$u(n,mi[e]);e.startsWith("origin")?(s=!0,a[e]=t):r[e]=t}}if(t.transform||(i||n?r.transform=function(e,t,n){let r="",o=!0;for(let a=0;a"string"==typeof e&&"svg"===e.toLowerCase();function ed(e,{style:t,vars:n},r,o){Object.assign(e.style,t,o&&o.getProjectionStyles(r));for(const t in n)e.style.setProperty(t,n[t])}const td=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function nd(e,t,n,r){ed(e,t,void 0,r);for(const n in t.attrs)e.setAttribute(td.has(n)?n:pa(n),t.attrs[n])}function rd(e,{layout:t,layoutId:n}){return qo.has(e)||e.startsWith("origin")||(t||void 0!==n)&&(!!nc[e]||"opacity"===e)}function od(e,t,n){var r;const{style:o}=e,a={};for(const i in o)(ma(o[i])||t.style&&ma(t.style[i])||rd(i,e)||void 0!==(null===(r=null==n?void 0:n.getValue(i))||void 0===r?void 0:r.liveStyle))&&(a[i]=o[i]);return a}function ad(e,t,n){const r=od(e,t,n);for(const n in e)(ma(e[n])||ma(t[n]))&&(r[-1!==$o.indexOf(n)?"attr"+n.charAt(0).toUpperCase()+n.substring(1):n]=e[n]);return r}const id=["x","y","width","height","cx","cy","r"],sd={useVisualState:Wu({scrapeMotionValuesFromProps:ad,createRenderState:()=>({style:{},transform:{},transformOrigin:{},vars:{},attrs:{}}),onUpdate:({props:e,prevProps:t,current:n,renderState:r,latestValues:o})=>{if(!n)return;let a=!!e.drag;if(!a)for(const e in o)if(qo.has(e)){a=!0;break}if(!a)return;let i=!t;if(t)for(let n=0;n{!function(e,t){try{t.dimensions="function"==typeof e.getBBox?e.getBBox():e.getBoundingClientRect()}catch(e){t.dimensions={x:0,y:0,width:0,height:0}}}(n,r),Jo.render((()=>{Zu(r,o,Qu(n.tagName),e.transformTemplate),nd(n,r)}))}))}})},ld={useVisualState:Wu({scrapeMotionValuesFromProps:od,createRenderState:()=>({style:{},transform:{},transformOrigin:{},vars:{}})})};function cd(e,t,n){for(const r in t)ma(t[r])||rd(r,n)||(e[r]=t[r])}function ud(e,t){const n={},r=function(e,t){const n={};return cd(n,e.style||{},e),Object.assign(n,function({transformTemplate:e},t){return(0,s.useMemo)((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{}};return Gu(n,t,e),Object.assign({},n.vars,n.style)}),[t])}(e,t)),n}(e,t);return e.drag&&!1!==e.dragListener&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),void 0===e.tabIndex&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const dd=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function md(e){return e.startsWith("while")||e.startsWith("drag")&&"draggable"!==e||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||dd.has(e)}let fd=e=>!md(e);try{(pd=require("@emotion/is-prop-valid").default)&&(fd=e=>e.startsWith("on")?!md(e):pd(e))}catch(e){}var pd;function hd(e,t,n,r){const o=(0,s.useMemo)((()=>{const n={style:{},transform:{},transformOrigin:{},vars:{},attrs:{}};return Zu(n,t,Qu(r),e.transformTemplate),{...n.attrs,style:{...n.style}}}),[t]);if(e.style){const t={};cd(t,e.style,e),o.style={...t,...o.style}}return o}function gd(e=!1){return(t,n,r,{latestValues:o},a)=>{const i=(Vu(t)?hd:ud)(n,o,a,t),l=function(e,t,n){const r={};for(const o in e)"values"===o&&"object"==typeof e.values||(fd(o)||!0===n&&md(o)||!t&&!md(o)||e.draggable&&o.startsWith("onDrag"))&&(r[o]=e[o]);return r}(n,"string"==typeof t,e),c=t!==s.Fragment?{...l,...i,ref:r}:{},{children:u}=n,d=(0,s.useMemo)((()=>ma(u)?u.get():u),[u]);return(0,s.createElement)(t,{...c,children:d})}}function yd(e,t){return function(n,{forwardMotionProps:r}={forwardMotionProps:!1}){return Lu({...Vu(n)?sd:ld,preloadedFeatures:e,useRender:gd(r),createVisualElement:t,Component:n})}}const vd={current:null},bd={current:!1},xd=[...Bi,Xa,oi],wd=new WeakMap,Ed=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class _d{scrapeMotionValuesFromProps(e,t,n){return{}}constructor({parent:e,props:t,presenceContext:n,reducedMotionConfig:r,blockInitialAnimation:o,visualState:a},i={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Pi,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const e=ra.now();this.renderScheduledAtthis.bindToMotionValue(t,e))),bd.current||function(){if(bd.current=!0,ju)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>vd.current=e.matches;e.addListener(t),t()}else vd.current=!1}(),this.shouldReduceMotion="never"!==this.reducedMotionConfig&&("always"===this.reducedMotionConfig||vd.current),this.parent&&this.parent.children.add(this),this.update(this.props,this.presenceContext)}unmount(){wd.delete(this.current),this.projection&&this.projection.unmount(),Zo(this.notifyUpdate),Zo(this.render),this.valueSubscriptions.forEach((e=>e())),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent&&this.parent.children.delete(this);for(const e in this.events)this.events[e].clear();for(const e in this.features){const t=this.features[e];t&&(t.unmount(),t.isMounted=!1)}this.current=null}bindToMotionValue(e,t){this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)();const n=qo.has(e),r=t.on("change",(t=>{this.latestValues[e]=t,this.props.onUpdate&&Jo.preRender(this.notifyUpdate),n&&this.projection&&(this.projection.isTransformDirty=!0)})),o=t.on("renderRequest",this.scheduleRender);let a;window.MotionCheckAppearSync&&(a=window.MotionCheckAppearSync(this,e,t)),this.valueSubscriptions.set(e,(()=>{r(),o(),a&&a(),t.owner&&t.stop()}))}sortNodePosition(e){return this.current&&this.sortInstanceNodePosition&&this.type===e.type?this.sortInstanceNodePosition(this.current,e.current):0}updateFeatures(){let e="animation";for(e in Ru){const t=Ru[e];if(!t)continue;const{isEnabled:n,Feature:r}=t;if(!this.features[e]&&r&&n(this.props)&&(this.features[e]=new r(this)),this.features[e]){const t=this.features[e];t.isMounted?t.update():(t.mount(),t.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):{x:{min:0,max:0},y:{min:0,max:0}}}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,t){this.latestValues[e]=t}update(e,t){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=t;for(let t=0;tt.variantChildren.delete(e)}addValue(e,t){const n=this.values.get(e);t!==n&&(n&&this.removeValue(e),this.bindToMotionValue(e,t),this.values.set(e,t),this.latestValues[e]=t.get())}removeValue(e){this.values.delete(e);const t=this.valueSubscriptions.get(e);t&&(t(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,t){if(this.props.values&&this.props.values[e])return this.props.values[e];let n=this.values.get(e);return void 0===n&&void 0!==t&&(n=ua(null===t?void 0:t,{owner:this}),this.addValue(e,n)),n}readValue(e,t){var n;let r=void 0===this.latestValues[e]&&this.current?null!==(n=this.getBaseTargetFromProps(this.props,e))&&void 0!==n?n:this.readValueFromInstance(this.current,e,this.options):this.latestValues[e];return null!=r&&("string"==typeof r&&(Ai(r)||Pa(r))?r=parseFloat(r):!(e=>xd.find(zi(e)))(r)&&oi.test(t)&&(r=hi(e,t)),this.setBaseTarget(e,ma(r)?r.get():r)),ma(r)?r.get():r}setBaseTarget(e,t){this.baseTarget[e]=t}getBaseTarget(e){var t;const{initial:n}=this.props;let r;if("string"==typeof n||"object"==typeof n){const o=so(this.props,n,null===(t=this.presenceContext)||void 0===t?void 0:t.custom);o&&(r=o[e])}if(n&&void 0!==r)return r;const o=this.getBaseTargetFromProps(this.props,e);return void 0===o||ma(o)?void 0!==this.initialValues[e]&&void 0===r?void 0:this.baseTarget[e]:o}on(e,t){return this.events[e]||(this.events[e]=new ia),this.events[e].add(t)}notify(e,...t){this.events[e]&&this.events[e].notify(...t)}}class kd extends _d{constructor(){super(...arguments),this.KeyframeResolver=Ui}sortInstanceNodePosition(e,t){return 2&e.compareDocumentPosition(t)?1:-1}getBaseTargetFromProps(e,t){return e.style?e.style[t]:void 0}removeValueFromRenderState(e,{vars:t,style:n}){delete t[e],delete n[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;ma(e)&&(this.childSubscription=e.on("change",(e=>{this.current&&(this.current.textContent=`${e}`)})))}}class Sd extends kd{constructor(){super(...arguments),this.type="html",this.renderInstance=ed}readValueFromInstance(e,t){if(qo.has(t)){const e=pi(t);return e&&e.default||0}{const r=(n=e,window.getComputedStyle(n)),o=(Fi(t)?r.getPropertyValue(t):r[t])||0;return"string"==typeof o?o.trim():o}var n}measureInstanceViewportBox(e,{transformPagePoint:t}){return Ul(e,t)}build(e,t,n){Gu(e,t,n.transformTemplate)}scrapeMotionValuesFromProps(e,t,n){return od(e,t,n)}}class Nd extends kd{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Sl}getBaseTargetFromProps(e,t){return e[t]}readValueFromInstance(e,t){if(qo.has(t)){const e=pi(t);return e&&e.default||0}return t=td.has(t)?t:pa(t),e.getAttribute(t)}scrapeMotionValuesFromProps(e,t,n){return ad(e,t,n)}build(e,t,n){Zu(e,t,this.isSVGTag,n.transformTemplate)}renderInstance(e,t,n,r){nd(e,t,0,r)}mount(e){this.isSVGTag=Qu(e.tagName),super.mount(e)}}const Cd=to(yd({...tl,...Eu,...pu,..._u},((e,t)=>Vu(e)?new Nd(t):new Sd(t,{allowProjection:e!==s.Fragment}))));class Pd extends s.Component{getSnapshotBeforeUpdate(e){const t=this.props.childRef.current;if(t&&e.isPresent&&!this.props.isPresent){const e=this.props.sizeRef.current;e.height=t.offsetHeight||0,e.width=t.offsetWidth||0,e.top=t.offsetTop,e.left=t.offsetLeft}return null}componentDidUpdate(){}render(){return this.props.children}}function Td({children:e,isPresent:t}){const n=(0,s.useId)(),r=(0,s.useRef)(null),o=(0,s.useRef)({width:0,height:0,top:0,left:0}),{nonce:a}=(0,s.useContext)(Su);return(0,s.useInsertionEffect)((()=>{const{width:e,height:i,top:s,left:l}=o.current;if(t||!r.current||!e||!i)return;r.current.dataset.motionPopId=n;const c=document.createElement("style");return a&&(c.nonce=a),document.head.appendChild(c),c.sheet&&c.sheet.insertRule(`\n [data-motion-pop-id="${n}"] {\n position: absolute !important;\n width: ${e}px !important;\n height: ${i}px !important;\n top: ${s}px !important;\n left: ${l}px !important;\n }\n `),()=>{document.head.removeChild(c)}}),[t]),(0,I.jsx)(Pd,{isPresent:t,childRef:r,sizeRef:o,children:s.cloneElement(e,{ref:r})})}const jd=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:o,presenceAffectsLayout:a,mode:i})=>{const l=Uu(Ad),c=(0,s.useId)(),u=(0,s.useCallback)((e=>{l.set(e,!0);for(const e of l.values())if(!e)return;r&&r()}),[l,r]),d=(0,s.useMemo)((()=>({id:c,initial:t,isPresent:n,custom:o,onExitComplete:u,register:e=>(l.set(e,!1),()=>l.delete(e))})),a?[Math.random(),u]:[n,u]);return(0,s.useMemo)((()=>{l.forEach(((e,t)=>l.set(t,!1)))}),[n]),s.useEffect((()=>{!n&&!l.size&&r&&r()}),[n]),"popLayout"===i&&(e=(0,I.jsx)(Td,{isPresent:n,children:e})),(0,I.jsx)(Gl.Provider,{value:d,children:e})};function Ad(){return new Map}const Rd=e=>e.key||"";function Fd(e){const t=[];return s.Children.forEach(e,(e=>{(0,s.isValidElement)(e)&&t.push(e)})),t}const Dd=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:a="sync",propagate:i=!1})=>{const[l,c]=Xl(i),u=(0,s.useMemo)((()=>Fd(e)),[e]),d=i&&!l?[]:u.map(Rd),m=(0,s.useRef)(!0),f=(0,s.useRef)(u),p=Uu((()=>new Map)),[h,g]=(0,s.useState)(u),[y,v]=(0,s.useState)(u);Mu((()=>{m.current=!1,f.current=u;for(let e=0;e{const s=Rd(e),h=!(i&&!l)&&(u===y||d.includes(s));return(0,I.jsx)(jd,{isPresent:h,initial:!(m.current&&!n)&&void 0,custom:h?void 0:t,presenceAffectsLayout:o,mode:a,onExitComplete:h?void 0:()=>{if(!p.has(s))return;p.set(s,!0);let e=!0;p.forEach((t=>{t||(e=!1)})),e&&(null==x||x(),v(f.current),i&&(null==c||c()),r&&r())},children:e},s)}))})},Md=(...e)=>e.filter(((e,t,n)=>Boolean(e)&&n.indexOf(e)===t)).join(" ");var Od={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 Id=(0,s.forwardRef)((({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:i,...l},c)=>(0,s.createElement)("svg",{ref:c,...Od,width:t,height:t,stroke:e,strokeWidth:r?24*Number(n)/Number(t):n,className:Md("lucide",o),...l},[...i.map((([e,t])=>(0,s.createElement)(e,t))),...Array.isArray(a)?a:[a]]))),Ld=(e,t)=>{const n=(0,s.forwardRef)((({className:n,...r},o)=>{return(0,s.createElement)(Id,{ref:o,iconNode:t,className:Md(`lucide-${a=e,a.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,n),...r});var a}));return n.displayName=`${e}`,n},zd=Ld("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]),Bd=(0,s.createContext)({}),Vd=()=>(0,s.useContext)(Bd),Ud=({size:e="md",children:t,className:n})=>(0,I.jsx)(Bd.Provider,{value:{size:e},children:(0,I.jsx)("div",{className:Fe("flex flex-col bg-background-primary p-2",n),children:t})});Ud.displayName="Menu";const Wd=({heading:e,arrow:t=!1,showArrowOnHover:n=!1,open:r=!0,onClick:o,children:a,className:i})=>{const[l,c]=(0,s.useState)(r),[u,d]=(0,s.useState)(!1),{size:m}=Vd(),f={sm:"text-xs",md:"text-sm"}[m??"md"],p={sm:"size-4",md:"size-5"}[m??"md"],h=()=>{c(!l),o&&o(!l)};return(0,I.jsxs)("div",{children:[!!e&&(0,I.jsxs)("div",{role:"button",tabIndex:0,onClick:h,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&h()},onMouseEnter:()=>n&&d(!0),onMouseLeave:()=>n&&d(!1),className:Fe("text-text-primary bg-transparent cursor-pointer flex justify-between items-center gap-1",f,e?"p-1":"p-0",i),"aria-expanded":l,children:[(0,I.jsx)("span",{className:"text-text-tertiary",children:e}),t&&(0,I.jsx)(Cd.span,{className:"flex items-center text-border-strong",initial:"hidden",animate:n?l||u?"visible":"hidden":"visible",exit:"hidden",variants:{visible:{opacity:1},hidden:{opacity:0}},transition:{duration:.15},children:(0,I.jsx)(Cd.span,{className:"inline-flex p-1",variants:{open:{rotate:180},closed:{rotate:0}},animate:l?"open":"closed",transition:{duration:.15},children:(0,I.jsx)(zd,{className:Fe("shrink-0",p)})})})]}),(0,I.jsx)(Dd,{initial:!1,children:l&&(0,I.jsx)(Cd.ul,{role:"menu",variants:{open:{height:"auto",opacity:1},closed:{height:0,opacity:0}},initial:"closed",animate:"open",exit:"closed",transition:{duration:.3,ease:"easeInOut"},className:"overflow flex gap-0.5 flex-col m-0 bg-white rounded p-0",children:a})})]})};Wd.displayName="Menu.List";const Hd=({disabled:e=!1,active:t,onClick:n,children:r,className:o})=>{const{size:a}=Vd(),i={sm:"[&>svg]:size-4 [&>svg]:m-1 [&>*:not(svg)]:mx-1 [&>*:not(svg)]:my-0.5 text-sm",md:"[&>svg]:size-5 [&>svg]:m-1.5 [&>*:not(svg)]:m-1 text-base"}[a??"md"];return(0,I.jsx)("li",{role:"menuitem",tabIndex:0,onClick:n,onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&n?.()},className:Fe("flex p-1 gap-1 items-center bg-transparent border-none rounded text-text-secondary cursor-pointer m-0",i,"hover:bg-background-secondary hover:text-text-primary",e?"text-text-disabled hover:text-text-disabled cursor-not-allowed hover:bg-transparent":"",t?"text-icon-primary [&>svg]:text-icon-interactive bg-background-secondary":"","transition-colors duration-300 ease-in-out",o),children:r})};Hd.displayName="Menu.Item";const $d=({variant:e="solid",className:t})=>{const n={solid:"border-solid",dashed:"border-dashed",dotted:"border-dotted",double:"border-double",hidden:"border-hidden",none:"border-none"}[e];return(0,I.jsx)("li",{className:"m-0 p-0 list-none",role:"separator","aria-hidden":"true",children:(0,I.jsx)("hr",{className:Fe("w-full border-0 border-t border-border-subtle",n,t)})})};$d.displayName="Menu.Separator",Ud.List=Wd,Ud.Item=Hd,Ud.Separator=$d;const qd=(0,s.createContext)({}),Yd=()=>(0,s.useContext)(qd),Gd=({placement:e="bottom",offset:t=10,boundary:n="clippingAncestors",children:r,className:o})=>{const[a,i]=(0,s.useState)(!1),{refs:l,floatingStyles:c,context:u}=Ur({open:a,onOpenChange:i,placement:e,strategy:"fixed",middleware:[er(t),nr({boundary:n}),tr({boundary:n})],whileElementsMounted:Un}),d=Ir(u),m=Vr(u),f=Xr(u,{role:"menu"}),{getReferenceProps:p,getFloatingProps:h}=Yr([d,m,f]),{isMounted:g,styles:y}=Zr(u,{duration:150,initial:{opacity:0,scale:.95},open:{opacity:1,scale:1},close:{opacity:0,scale:.95}}),v=()=>i((e=>!e));return(0,I.jsx)(qd.Provider,{value:{refs:l,handleClose:()=>i(!1),isMounted:g,styles:y,floatingStyles:c,getFloatingProps:h},children:(0,I.jsxs)("div",{className:Fe("relative inline-block",o),children:[s.Children.map(r,(e=>s.isValidElement(e)&&"DropdownMenu.Trigger"===e?.type?.displayName?(0,s.cloneElement)(e,{ref:l.setReference,onClick:v,...p()}):null)),s.Children.toArray(r).filter((e=>s.isValidElement(e)&&["DropdownMenu.Portal","DropdownMenu.ContentWrapper"].includes(e.type.displayName||""))).map((e=>e))]})})};Gd.displayName="DropdownMenu";const Xd=({children:e,className:t})=>{const{refs:n,floatingStyles:r,getFloatingProps:o,isMounted:a,styles:i}=Yd();return a&&(0,I.jsx)("div",{ref:n.setFloating,className:t,style:{...r,...i},...o(),children:s.Children.map(e,(e=>"DropdownMenu.Content"===e?.type?.displayName?e:null))})};Xd.displayName="DropdownMenu.ContentWrapper";const Kd=({children:e,root:t,id:n})=>(0,I.jsx)(Rr,{id:n,root:t,children:e});Kd.displayName="DropdownMenu.Portal";const Jd=s.forwardRef((({children:e,className:t,...n},r)=>(0,s.isValidElement)(e)?s.cloneElement(e,{className:Fe(t,e.props.className),ref:r,...n}):(0,I.jsx)("div",{ref:r,className:Fe("cursor-pointer",t),role:"button",tabIndex:0,...n,children:e})));Jd.displayName="DropdownMenu.Trigger";const Zd=({children:e,className:t,...n})=>(0,I.jsx)("div",{className:Fe("border border-solid border-border-subtle rounded-md shadow-lg overflow-hidden",t),children:(0,I.jsx)(Ud,{...n,children:e})});Zd.displayName="DropdownMenu.Content";const Qd=e=>(0,I.jsx)(Ud.List,{...e});Qd.displayName="DropdownMenu.List";const em=({children:e,as:t=Ud.Item,...n})=>{const{handleClose:r}=Yd();return e?t===s.Fragment&&(0,s.isValidElement)(e)?(0,s.cloneElement)(e,{onClick:De(e.props?.onClick,r)}):(0,I.jsx)(t,{...n,className:Fe("px-2",n.className),onClick:De(n.onClick,r),children:e}):null};em.displayName="DropdownMenu.Item";const tm=e=>(0,I.jsx)(Ud.Separator,{...e});tm.displayName="DropdownMenu.Separator",Gd.Trigger=Jd,Gd.Content=Zd,Gd.List=Qd,Gd.Item=em,Gd.Separator=tm,Gd.Portal=Kd,Gd.ContentWrapper=Xd;const nm=Ld("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),rm=(0,s.forwardRef)((({label:e="",size:t="sm",className:n="",type:r="pill",variant:o="neutral",icon:a=null,disabled:i=!1,onClose:s=()=>{},closable:l=!1,onMouseDown:c=()=>{},disableHover:u=!1},d)=>{const m={neutral:"bg-badge-background-gray text-badge-color-gray border-badge-border-gray",red:"bg-badge-background-red text-badge-color-red border-badge-border-red",yellow:"bg-badge-background-yellow text-badge-color-yellow border-badge-border-yellow",green:"bg-badge-background-green text-badge-color-green border-badge-border-green",blue:"bg-badge-background-sky text-badge-color-sky border-badge-border-sky",inverse:"bg-background-inverse text-text-inverse border-background-inverse",disabled:"bg-badge-background-disabled text-badge-color-disabled border-badge-border-disabled disabled cursor-not-allowed"};let f="",p="group relative justify-center flex items-center cursor-pointer";const h={xxs:"[&>svg]:size-3",xs:"[&>svg]:size-3",sm:"[&>svg]:size-3",md:"[&>svg]:size-4",lg:"[&>svg]:size-5"};return i?(f=m.disabled,p+=" cursor-not-allowed disabled"):f=m[o],e?(0,I.jsxs)("span",{className:Fe("font-medium border-badge-border-gray flex items-center justify-center border border-solid box-border max-w-full transition-colors duration-150 ease-in-out",{xxs:"py-0.5 px-0.5 text-xs h-4",xs:"py-0.5 px-1 text-xs h-5",sm:"py-1 px-1.5 text-xs h-6",md:"py-1 px-1.5 text-sm h-7",lg:"py-1 px-1.5 text-base h-8"}[t],{pill:"rounded-full",rounded:"rounded"}[r],"gap-0.5",f,!u&&{neutral:"hover:bg-badge-hover-gray",red:"hover:bg-badge-hover-red",yellow:"hover:bg-badge-hover-yellow",green:"hover:bg-badge-hover-green",blue:"hover:bg-badge-hover-sky",inverse:"hover:bg-badge-hover-inverse",disabled:"hover:bg-badge-hover-disabled"}[o],n),ref:d,children:[a?(0,I.jsx)("span",{className:Fe("justify-center flex items-center",h[t]),children:a}):null,(0,I.jsx)("span",{className:"px-1 truncate inline-block",children:e}),l&&(0,I.jsxs)("span",{className:Fe(p,h[t]),onMouseDown:c,role:"button",tabIndex:0,...!i&&{onClick:s},children:[(0,I.jsx)("span",{className:"sr-only",children:`Remove ${e}`}),(0,I.jsx)(nm,{}),(0,I.jsx)("span",{className:"absolute -inset-1"})]})]}):null}));rm.displayName="Badge";const om=e=>{const t=(e=>e.replace(/^([A-Z])|[\s-_]+(\w)/g,((e,t,n)=>n?n.toUpperCase():t.toLowerCase())))(e);return t.charAt(0).toUpperCase()+t.slice(1)},am=(...e)=>e.filter(((e,t,n)=>Boolean(e)&&""!==e.trim()&&n.indexOf(e)===t)).join(" ").trim(),im=e=>{for(const t in e)if(t.startsWith("aria-")||"role"===t||"title"===t)return!0};var sm={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 lm=(0,s.forwardRef)((({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:i,...l},c)=>(0,s.createElement)("svg",{ref:c,...sm,width:t,height:t,stroke:e,strokeWidth:r?24*Number(n)/Number(t):n,className:am("lucide",o),...!a&&!im(l)&&{"aria-hidden":"true"},...l},[...i.map((([e,t])=>(0,s.createElement)(e,t))),...Array.isArray(a)?a:[a]]))),cm=(e,t)=>{const n=(0,s.forwardRef)((({className:n,...r},o)=>{return(0,s.createElement)(lm,{ref:o,iconNode:t,className:am(`lucide-${a=om(e),a.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()}`,`lucide-${e}`,n),...r});var a}));return n.displayName=om(e),n},um=cm("arrow-up-right",[["path",{d:"M7 7h10v10",key:"1tivn9"}],["path",{d:"M7 17 17 7",key:"1vkiza"}]]),dm=cm("circle-question-mark",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3",key:"1u773s"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),mm=cm("file-text",[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]),fm=cm("headset",[["path",{d:"M3 11h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-5Zm0 0a9 9 0 1 1 18 0m0 0v5a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3Z",key:"12oyoe"}],["path",{d:"M21 16v2a4 4 0 0 1-4 4h-5",key:"1x7m43"}]]),pm=cm("user",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]),hm=window.wp.i18n;var gm={dashboard:{path:"dashboard"},widgets:{path:"widgets"},templates:{path:"templates"},learn:{path:"learn"},settings:{path:"settings"},onboarding:{path:"onboarding"},upgrade:{path:"upgrade"},headerFooterBuilder:{path:"elementor-hf"},onboardingsuccess:{path:"onboardingsuccess"}},ym=function(){return ym=Object.assign||function(e){for(var t,n=1,r=arguments.length;n0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]\n\t\n\t\t\n\t\n\t',viewAll:{link:"",label:"View All"},triggerButton:{icon:'',beforeBtn:"",afterBtn:"",className:"",onClick:function(){}},notification:{setLastPostUnixTime:null,getLastPostUnixTime:null},flyout:{title:"What's New?",innerContent:{titleLink:!0,additionalClasses:[]},excerpt:{wordLimit:500,moreSymbol:"…",readMore:{label:"Read More",className:""}},className:"",closeOnEsc:!0,closeOnOverlayClick:!0,closeBtnIcon:'',formatDate:null,onOpen:function(){},onClose:function(){},onReady:function(){}}},wm=function(){function e(e){this.rssFeedURLs=[],this.lastPostUnixTime=0,this.multiLastPostUnixTime={},this.notificationsCount=0,this.multiNotificationCount={},this.hasNewFeeds=!1,this.multiHasNewFeeds={},this.validateArgs(e),this.parseDefaults(e),this.setElement(),this.getElement()?(this.setID(),this.setRSSFeedURLs(),Em.setInstanceID(this.getID()),this.RSS_Fetch_Instance=new _m(this),this.RSS_View_Instance=new km(this),this.setNotificationsCount(),this.setTriggers()):console.warn("WNR: Cannot find element with",this.getArgs().selector)}return e.prototype.validateArgs=function(e){["rssFeedURL","selector"].map((function(t){if(!e[t])throw new Error("".concat(t," is a required argument. It cannot be empty or undefined."));if("rssFeedURL"===t){var n=e[t];Array.isArray(n)&&n.forEach((function(e){if(!(null==e?void 0:e.key))throw new Error('The parameter "key" is required for "'.concat(t,'" parameter in multi-feed mode.'));if(e.key.includes(" "))throw new Error('The parameter "key" cannot have spaces for "'.concat(t,'" parameter in multi-feed mode. Ref Key: "').concat(e.key,'"'))}))}}))},e.prototype.parseDefaults=function(e){var t,n;this.args=ym(ym(ym({},xm),e),{viewAll:ym(ym({},xm.viewAll),null==e?void 0:e.viewAll),triggerButton:ym(ym({},xm.triggerButton),null==e?void 0:e.triggerButton),flyout:ym(ym(ym({},xm.flyout),null==e?void 0:e.flyout),{innerContent:ym(ym({},xm.flyout.innerContent),null===(t=null==e?void 0:e.flyout)||void 0===t?void 0:t.innerContent),excerpt:ym(ym({},xm.flyout.excerpt),null===(n=null==e?void 0:e.flyout)||void 0===n?void 0:n.excerpt)})})},e.prototype.getArgs=function(){return this.args},e.prototype.setElement=function(){this.element=document.querySelector(this.args.selector)},e.prototype.getElement=function(){return this.element},e.prototype.setID=function(){var e=[this.getArgs().selector],t=this.getArgs().rssFeedURL;Array.isArray(t)?t.forEach((function(t){e.push(t.key)})):e.push(t),this.ID=btoa(e.join("-")).slice(-12).replace(/=/g,"")},e.prototype.isMultiFeedRSS=function(){return"string"!=typeof this.getArgs().rssFeedURL},e.prototype.setRSSFeedURLs=function(){var e=this,t=this.getArgs().rssFeedURL;this.isMultiFeedRSS()?Array.isArray(t)&&t.forEach((function(t){e.rssFeedURLs.push(t)})):this.rssFeedURLs.push({key:null,label:"",url:t.toString()})},e.prototype.getRSSFeedURLs=function(){return this.rssFeedURLs},e.prototype.getID=function(){return this.ID},e.prototype.setNotificationsCount=function(){return vm(this,void 0,void 0,(function(){var e=this;return bm(this,(function(t){switch(t.label){case 0:return[4,Promise.all(this.getRSSFeedURLs().map((function(t){var n=t.key;return vm(e,void 0,void 0,(function(){var e;return bm(this,(function(t){switch(t.label){case 0:return e=0,"function"!=typeof this.getArgs().notification.getLastPostUnixTime?[3,2]:[4,this.getArgs().notification.getLastPostUnixTime(n,this)];case 1:return e=t.sent(),[3,3];case 2:e=Em.getLastPostUnixTime(n),t.label=3;case 3:return this.isMultiFeedRSS()?this.multiLastPostUnixTime[n]=+e:this.lastPostUnixTime=+e,[2]}}))}))})))];case 1:return t.sent(),[4,this.RSS_Fetch_Instance.fetchData().then((function(t){Object.keys(t).forEach((function(n){var r=t[n];if(r.length){e.multiNotificationCount[n]=0;var o=+r[0].date,a=e.isMultiFeedRSS()?e.multiLastPostUnixTime[n]:e.lastPostUnixTime;o>a&&(r.forEach((function(t){t.date>a&&(e.isMultiFeedRSS()&&(e.multiNotificationCount[n]++,e.multiHasNewFeeds[n]=!0),e.notificationsCount++,e.hasNewFeeds=!0)})),e.RSS_View_Instance.setNotification(e.notificationsCount))}}))}))];case 2:return t.sent(),[2]}}))}))},e.prototype.getNotificationsCount=function(){return this.notificationsCount},e.prototype.setTriggers=function(){var e=this,t=document.getElementById(this.RSS_View_Instance.getTriggerButtonID()),n=document.getElementById(this.RSS_View_Instance.getFlyoutID()),r=n.querySelector(".whats-new-rss-flyout-inner-content"),o=document.getElementById(this.RSS_View_Instance.getFlyoutCloseBtnID()),a=document.getElementById(this.RSS_View_Instance.getFlyoutMultiFeedNavID()),i=function(t){e.RSS_Fetch_Instance.fetchData().then((function(o){r.innerHTML="";var a=o[t];if(a.length){var i=+a[0].date,s=e.isMultiFeedRSS()?e.multiLastPostUnixTime[t]:e.lastPostUnixTime;a.forEach((function(n){var o=!!s&&n.date>s,a=e.getArgs().flyout.innerContent.titleLink?'\n\t\t\t\t\t\t\t\t

').concat(n.title,"

\n\t\t\t\t\t\t\t
"):"

".concat(n.title,"

"),i='\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t\t

'.concat(e.RSS_View_Instance.formatDate(new Date(n.date)),"

\n\t\t\t\t\t\t\t\t\t").concat(a,"\n\t\t\t\t\t\t\t\t
\n\t\t\t\t\t\t\t\t").concat(e.RSS_View_Instance.createExcerpt(n.description,n.postLink,e.getArgs().flyout.excerpt),"\n\t\t\t\t\t\t\t\t").concat(e.RSS_View_Instance.listChildrenPosts(n.children),"\n\t\t\t\t\t\t\t"),l=e.getArgs().flyout.innerContent.additionalClasses;t&&l.push("`inner-content-item-feed-key-${key}`"),r.innerHTML+=e.RSS_View_Instance.innerContentWrapper(i,o,l.join(" "))})),e.getArgs().viewAll.link&&(r.innerHTML+=e.RSS_View_Instance.innerContentWrapper('\n\t\t\t\t\t\t\t').concat(e.getArgs().viewAll.label,"\n\t\t\t\t\t\t\t"))),e.RSS_View_Instance.setIsLoading(!1),n.classList.add("ready"),e.getArgs().flyout.onReady(e),n.focus(),e.isMultiFeedRSS()||(e.lastPostUnixTime=i,e.hasNewFeeds&&("function"==typeof e.getArgs().notification.setLastPostUnixTime?e.getArgs().notification.setLastPostUnixTime(i,t):Em.setLastPostUnixTime(i,t)))}}))};t.addEventListener("click",(function(t){if(t.preventDefault(),e.getArgs().triggerButton.onClick(e),e.RSS_View_Instance.setIsLoading(!0),n.classList.remove("closed"),n.classList.add("open"),document.body.classList.add("whats-new-rss-is-active"),e.getArgs().flyout.onOpen(e),!e.isMultiFeedRSS())return i(null);var r=a.querySelectorAll("button");r.forEach((function(t){e.RSS_View_Instance.setMultiFeedTabNotificationCount(t.dataset.feedKey,e.multiNotificationCount[t.dataset.feedKey]),t.addEventListener("click",(function(n){n.preventDefault();var o=t.dataset.feedKey;e.multiNotificationCount[o]=0,e.RSS_Fetch_Instance.fetchData().then((function(t){var n=t[o][0].date;e.multiLastPostUnixTime[o]=n,!0===e.multiHasNewFeeds[o]&&("function"==typeof e.getArgs().notification.setLastPostUnixTime?e.getArgs().notification.setLastPostUnixTime(n,o):Em.setLastPostUnixTime(n,o)),e.multiHasNewFeeds[o]=!1})),r.forEach((function(e){e.classList.remove("selected");var t=e.dataset.feedKey,n=".inner-content-item-feed-key-".concat(t);document.querySelectorAll(n).forEach((function(e){o!==t?e.classList.add("hidden"):e.classList.remove("hidden")}))})),t.classList.add("selected"),i(o)}))})),r[0].click()}));var s=function(){n.classList.add("closed"),n.classList.remove("open"),n.classList.remove("ready"),document.body.classList.remove("whats-new-rss-is-active"),e.isMultiFeedRSS()?e.RSS_View_Instance.setNotification(Object.values(e.multiNotificationCount).filter(Boolean).length):(e.hasNewFeeds=!1,e.RSS_View_Instance.setNotification(!1)),r.innerHTML="",e.getArgs().flyout.onClose(e),t.focus()};this.getArgs().flyout.closeOnEsc&&document.addEventListener("keydown",(function(e){"Escape"===e.key&&n.classList.contains("open")&&s()})),this.getArgs().flyout.closeOnOverlayClick&&n.querySelector(".whats-new-rss-flyout-overlay").addEventListener("click",s),o.addEventListener("click",s)},e}(),Em=function(){function e(){}return e.setInstanceID=function(e){this.instanceID||(this.instanceID=e)},e.prefixer=function(e,t){if(void 0===t&&(t=""),!this.instanceID)throw new Error("Instance ID not set.");return t?"".concat(this.keys[e],"-").concat(this.instanceID,"-").concat(t):"".concat(this.keys[e],"-").concat(this.instanceID)},e._setDataExpiry=function(e){void 0===e&&(e="");var t=(new Date).getTime()+864e5;sessionStorage.setItem(this.prefixer("SESSION_DATA_EXPIRY",e),JSON.stringify(t))},e._isDataExpired=function(e){void 0===e&&(e="");var t=this.prefixer("SESSION_DATA_EXPIRY",e),n=window.sessionStorage.getItem(t);if(!n)return!0;var r=JSON.parse(n);return(new Date).getTime()>r&&(window.sessionStorage.removeItem(t),!0)},e.setSessionData=function(e,t){return void 0===t&&(t=""),this._setDataExpiry(t),window.sessionStorage.setItem(this.prefixer("SESSION",t),e)},e.getSessionData=function(e){return void 0===e&&(e=""),this._isDataExpired(e)?"{}":window.sessionStorage.getItem(this.prefixer("SESSION",e))},e.setLastPostUnixTime=function(e,t){return void 0===t&&(t=""),window.localStorage.setItem(this.prefixer("LAST_LATEST_POST",t),e.toString())},e.getLastPostUnixTime=function(e){return void 0===e&&(e=""),+window.localStorage.getItem(this.prefixer("LAST_LATEST_POST",e))},e.keys={SESSION_DATA_EXPIRY:"whats-new-cache-expiry",LAST_LATEST_POST:"whats-new-last-unixtime",SESSION:"whats-new-cache"},e}(),_m=function(){function e(e){var t=this;this.data={},this.RSS=e,this.RSS.getRSSFeedURLs().forEach((function(e){var n=JSON.parse(Em.getSessionData(e.key));n&&n.length&&(t.data[e.key]=n)}))}return e.prototype.fetchData=function(){return vm(this,void 0,void 0,(function(){var e,t=this;return bm(this,(function(n){switch(n.label){case 0:return Object.keys(this.data).length?[2,this.data]:(e=this.RSS.getRSSFeedURLs().map((function(e){return vm(t,void 0,void 0,(function(){var t,n,r=this;return bm(this,(function(o){switch(o.label){case 0:return this.data[e.key]=[],[4,fetch(e.url)];case 1:return[4,o.sent().text()];case 2:return t=(t=o.sent()).replace(/»/g,"&raquo;"),n=new DOMParser,n.parseFromString(t,"text/xml").querySelectorAll("item").forEach((function(t){var n,o=t.querySelector("title").textContent,a=t.querySelector("link").textContent,i=t.querySelector("content\\:encoded, encoded"),s=i?i.textContent:"",l=t.querySelector("pubDate").innerHTML;r.data[e.key].push({title:o,date:l?+new Date(l):null,postLink:a,description:s.replace(/])*)>/g,'').replace(/

\s*<\/p>/g,""),children:JSON.parse((null===(n=t.querySelector("children"))||void 0===n?void 0:n.innerHTML)||"{}")})})),Em.setSessionData(JSON.stringify(this.data[e.key]),e.key),[2]}}))}))})),[4,Promise.all(e)]);case 1:return n.sent(),[2,this.data]}}))}))},e}(),km=function(){function e(e){this.RSS=e,this.createTriggerButton(),this.createFlyOut()}return e.prototype.getTriggerButtonID=function(){return"whats-new-rss-btn-".concat(this.RSS.getID())},e.prototype.getFlyoutID=function(){return"whats-new-rss-flyout-".concat(this.RSS.getID())},e.prototype.getFlyoutCloseBtnID=function(){return"whats-new-rss-flyout-close-".concat(this.RSS.getID())},e.prototype.getFlyoutMultiFeedNavID=function(){return"whats-new-rss-flyout-multi-feed-nav-".concat(this.RSS.getID())},e.prototype.setIsLoading=function(e){void 0===e&&(e=!1);var t=document.getElementById(this.getFlyoutID());e?t.classList.add("is-loading"):t.classList.remove("is-loading")},e.prototype.setNotification=function(e){var t=document.querySelector("#".concat(this.getTriggerButtonID()," .whats-new-rss-notification-badge"));e?(this.RSS.isMultiFeedRSS()?(t.innerHTML="",t.classList.add("is-multi-feed")):t.innerHTML=e>9?"9+":e.toString(),t.classList.remove("hide")):t.classList.add("hide")},e.prototype.createTriggerButton=function(){var e="\n\t\t".concat(this.RSS.getArgs().triggerButton.beforeBtn,'\n\t\t\n\t\t\t').concat(this.RSS.getArgs().triggerButton.icon,'\n\t\t\t

\n\t\t\n\t\t').concat(this.RSS.getArgs().triggerButton.afterBtn,"\n\t\t");this.RSS.getElement().innerHTML+=e},e.prototype.createFlyOut=function(){var e=["whats-new-rss-flyout","closed"];this.RSS.getArgs().flyout.className&&e.push(this.RSS.getArgs().flyout.className);var t=[];this.RSS.isMultiFeedRSS()&&(t.push('"));var n=document.createElement("div");n.setAttribute("id",this.getFlyoutID()),n.setAttribute("class",e.join(" ")),n.setAttribute("role","dialog"),n.innerHTML='\n\t\t
\n\n\t\t\t
\n\n\t\t\t\t
\n\t\t\t\t\t

'.concat(this.RSS.getArgs().flyout.title,'

\n\n\t\t\t\t\t\n\t\t\t\t\t').concat(this.RSS.getArgs().loaderIcon,'\n\t\t\t\t\t\n\t\t\t\t
\n\n\t\t\t\t\n\t\t\t
\n\n\t\t\t").concat(t.join(""),'\n\n\t\t\t
\n\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t\t
\n\t\t\t\t
\n\t\t\t
\n\n\t\t
\n\n\t\t
\n\t\t'),document.body.appendChild(n)},e.prototype.setMultiFeedTabNotificationCount=function(e,t){void 0===t&&(t=0);var n=document.querySelector("#".concat(this.getFlyoutMultiFeedNavID(),' button[data-feed-key="').concat(e,'"]'));if(n){var r=n.querySelector(".new-notification-count");if(t){var o=t>9?"9+":t;r.innerHTML=o.toString()}else r.innerHTML=""}},e.prototype.innerContentWrapper=function(e,t,n){void 0===t&&(t=!1),void 0===n&&(n="");var r=["whats-new-rss-flyout-inner-content-item"];return t&&r.push("rss-new-post"),n&&r.push(n),'\n\t\t
\n\t\t\t').concat(t?'New ✨':"","\n\t\t\t").concat(e,"\n\t\t
\n\t\t")},e.prototype.createExcerpt=function(e,t,n){var r=n.wordLimit,o=n.moreSymbol,a=n.readMore;if(!r)return e;var i=e.replace(/<[^>]*>/g,"").split(/\s+/),s=i.slice(0,r).join(" ");return o&&(s+=o),r>i.length?e:t&&(null==a?void 0:a.label)?"

".concat(s,' ').concat(a.label,"

"):"

".concat(s,"

")},e.prototype.listChildrenPosts=function(e){var t=this,n=Object.values(e);if(!n.length)return"";var r=document.createElement("details"),o=document.createElement("summary"),a=document.createElement("div");return n.forEach((function(e){var n=(new DOMParser).parseFromString(e.post_content,"text/html"),r=document.createElement("div");r.classList.add("sub-version-item"),r.innerHTML='\n\t\t\t\t
\n\t\t\t\t\t

'.concat(e.post_title,'

\n\t\t\t\t\t').concat(t.formatDate(new Date(e.post_date)),'\n\t\t\t\t
\n\t\t\t\t
').concat(n.documentElement.textContent,"
\n\t\t\t"),a.appendChild(r)})),o.innerHTML='

See More

See Less

',r.appendChild(o),r.appendChild(a),a.classList.add("sub-version-items-wrapper"),r.classList.add("whats-new-rss-sub-version-details"),r.outerHTML},e.prototype.formatDate=function(e){if("function"==typeof this.RSS.getArgs().flyout.formatDate)return this.RSS.getArgs().flyout.formatDate(e);var t=new Date,n=e.getTime(),r=t.getTime()-n,o=36e5,a=24*o,i=7*a,s=30*a;if(r<6e4)return"Just now";if(r1?"s":""," ago")}if(r1?"s":""," ago")}if(r1?"s":""," ago")}if(r1?"s":""," ago")}var m=Math.floor(r/s);return"".concat(m," month").concat(m>1?"s":""," ago")},e}();function Sm(){var e=window.location.hash;document.querySelectorAll("#adminmenu #toplevel_page_hfe a").forEach((function(t){var n=t.getAttribute("href"),r=t.closest("li"),o=t.textContent.trim();n&&(e.includes(n.split("#")[1])||"#dashboard"===e&&"Dashboard"===o)?r.classList.add("current"):r.classList.remove("current")}))}const Nm=function(){var e=i((0,s.useState)(!1),2),t=(e[0],e[1]);(0,s.useEffect)((function(){return Sm(),window.addEventListener("hashchange",Sm),function(){window.removeEventListener("hashchange",Sm)}}),[]);var n=window.location.hash,r=function(e){return n.includes(e)},o=function(e){return{color:r(e)?"#111827":"#4B5563",borderBottom:r(e)?"2px solid #6005FF":"none",paddingBottom:"22px",marginBottom:"-16px"}},a=function(e){window.open(e,"_blank"),t(!1)};return function({selector:e,...t}){const n=(0,s.useRef)(null);(0,s.useEffect)((()=>{var r;return async function(){const e="whats-new-rss-styles";if(!document.getElementById(e)){const t=document.createElement("style");t.id=e,t.innerHTML=await async function(){return".whats-new-rss-is-active{overflow:hidden}.whats-new-rss-trigger-button{display:flex;align-items:center;position:relative;width:auto;padding:5px;cursor:pointer}.whats-new-rss-trigger-button .whats-new-rss-notification-badge{position:absolute;top:-8px;right:-5px;width:20px;font-size:10px;line-height:20px;text-align:center;border-radius:10px;color:#fff;background:red;transition:transform .2s ease-in-out}.whats-new-rss-trigger-button .whats-new-rss-notification-badge.is-multi-feed{top:-2px;right:-2px;font-size:0;width:10px;height:10px}.whats-new-rss-trigger-button .whats-new-rss-notification-badge.hide{display:none}.whats-new-rss-trigger-button:hover .whats-new-rss-notification-badge{transform:scale(1.2)}.whats-new-rss-flyout{position:fixed;top:0;right:0;bottom:0;width:100%;z-index:99999;transition:visibility .3s ease-in-out;font-family:Arial,Helvetica,sans-serif}.whats-new-rss-flyout .lightbox-trigger,.whats-new-rss-flyout.hidden{display:none}.whats-new-rss-flyout.is-loading .whats-new-rss-flyout-inner-header__loading-icon{display:block;margin:auto}.whats-new-rss-flyout.is-loading .whats-new-rss-flyout-inner-header__loading-icon svg{display:block;background:0 0;width:25px;height:25px}.whats-new-rss-flyout .whats-new-rss-flyout-contents{position:fixed;display:flex;right:0;width:30%;height:100%;flex-direction:column;background-color:#fff;transition:transform .3s ease-in-out;z-index:9999}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header{display:flex;justify-content:space-between;align-items:center;padding:16px 20px 16px 24px;border-bottom:1px solid #ccc}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header button{border:none;background:0 0;font-size:30px;cursor:pointer;color:#94a3b8;padding:0;margin:0;box-shadow:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header .whats-new-rss-flyout-inner-header__title-icon-wrapper{display:flex;gap:10px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-header .whats-new-rss-flyout-inner-header__title-icon-wrapper h3{margin:0;padding:0;color:#0f172a;font-weight:600;font-size:16px;line-height:24px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav{display:flex;padding:0 30px;border-bottom:1px solid #ccc;gap:2em;overflow:auto;white-space:nowrap}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button{position:relative;background:0 0;color:inherit;padding:15px 0;border-bottom:2px solid transparent}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button:focus,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button:hover{border-color:inherit}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button.selected{border-color:#5d5d5d}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-multi-feed-nav button .new-notification-count{position:absolute;top:0;right:-10px;width:20px;font-size:10px;line-height:20px;text-align:center;border-radius:10px;color:#fff;background:red}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content{flex:1;overflow-y:auto}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .skeleton-container{margin:30px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item{border-bottom:1px solid #d8dfe9;padding:30px 24px;color:#475569;font-weight:400;font-size:14px;line-height:20px;display:flex;flex-direction:column;gap:13px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item>*{margin:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.skeleton-row{height:25vh;margin:40px 0;background:linear-gradient(90deg,#eee 25%,#ddd 50%,#eee 75%);background-size:200% 100%;animation:shimmer 1.5s infinite}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.rss-new-post{position:relative}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item.rss-new-post .new-post-badge{background:#ff3d3d;border-radius:5px;position:absolute;right:45px;padding:0 5px;color:#fff}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header{display:flex;flex-direction:column;gap:15px;padding:0 0 8px 0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header p{color:#94a3b8;margin:0;padding:0;font-weight:600;font-size:14px;line-height:16px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item .rss-content-header h2{margin:0;color:#0f172a;font-weight:700;line-height:28px;font-size:20px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h2{font-weight:700;font-size:18px;line-height:24px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h3{font-weight:700;font-size:16px;line-height:22px;margin-top:12px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h4{font-weight:700;font-size:15px;line-height:20px;margin-top:12px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h5{font-weight:700;font-size:14px;line-height:18px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item h6{font-weight:700;font-size:13px;line-height:16px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item p{padding:0;font-size:14px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item p:last-child{margin-bottom:0;padding-bottom:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item a{color:#1170ff;text-decoration:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure{margin:10px 0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure.wp-block-embed.is-type-video{position:relative;width:100%;height:0;padding-bottom:56.25%}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item figure iframe{position:absolute;top:0;left:0;width:100%;height:100%;border:0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item img{box-sizing:border-box;height:auto;max-width:100%;vertical-align:bottom}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item video{vertical-align:middle;width:100%}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item strong{font-weight:600}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul{padding-inline-start:20px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol li,.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul li{margin-bottom:5px}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ul{list-style-type:disc}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-flyout-inner-content .whats-new-rss-flyout-inner-content-item ol{list-style-type:decimal}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details{line-height:20px;font-size:.9em;margin:10px 0;background:#f9fafb}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary{display:flex;justify-content:space-between;cursor:pointer;padding:20px 15px;height:1em;line-height:20px;font-weight:800}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary::after{content:'⌃';font-size:20px;transform:rotateX(180deg);font-weight:800}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary .text-see-more{display:block}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details summary .text-see-less{display:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary{border-bottom:1px solid #e2e8f0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary::after{transform:rotateX(45deg)}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary .text-see-more{display:none}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details[open] summary .text-see-less{display:block}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item{position:relative;padding:1em;border-bottom:1px solid #e2e8f0}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item .sub-version-header{display:flex;justify-content:space-between}.whats-new-rss-flyout .whats-new-rss-flyout-contents .whats-new-rss-sub-version-details .sub-version-item .sub-version-content{margin-top:1em}.whats-new-rss-flyout .whats-new-rss-flyout-overlay{position:fixed;top:0;right:0;bottom:0;left:0;background:rgba(0,0,0,.5);transition:all .3s ease-in-out}.whats-new-rss-flyout.closed{visibility:hidden}.whats-new-rss-flyout.closed .whats-new-rss-flyout-overlay{opacity:0;visibility:hidden}.whats-new-rss-flyout.closed .whats-new-rss-flyout-contents{transform:translateX(100%)}.whats-new-rss-flyout .whats-new-rss-flyout-inner-header__loading-icon{display:none}@keyframes shimmer{0%{background-position:-200% 0}100%{background-position:200% 0}}@media screen and (max-width:1024px){.whats-new-rss-flyout .whats-new-rss-flyout-contents{width:40%}}@media screen and (max-width:768px){.whats-new-rss-flyout .whats-new-rss-flyout-contents{width:85%}}"}(),document.head.appendChild(t)}}(),n.current||(n.current=(r={selector:e,...t},new wm(r))),()=>{n.current&&"function"==typeof n.current.destroy&&n.current.destroy()}}),[e,...Object.values(t)]),n.current}({rssFeedURL:"https://ultimateelementor.com/whats-new/feed/",selector:"#hfe-whats-new",triggerButton:{beforeBtn:'
',icon:'',afterBtn:"
"},flyout:{title:(0,hm.__)("What's New?","header-footer-elementor"),formatDate:function(e){var t=e.toLocaleDateString("en-US",{weekday:"long"}),n=e.toLocaleDateString("en-US",{month:"long"}),r=e.getDate(),o=e.getFullYear();return"".concat(t," ").concat(n," ").concat(r,", ").concat(o)}}}),c().createElement(ot,{className:"hfe-nav-menu relative",style:{width:"unset",padding:"0.5rem",zIndex:"9",paddingTop:"1rem"}},c().createElement("div",{className:"flex flex-col lg:flex-row items-start md:items-center w-full"},c().createElement("div",{className:"flex flex-row md:items-center md:gap-8 w-full"},c().createElement(ot.Left,null,c().createElement(ot.Item,null,c().createElement(D,{to:gm.dashboard.path},c().createElement("img",{src:"".concat(hfeSettingsData.icon_url),alt:"Icon",className:"ml-4 cursor-pointer",style:{height:"35px",width:"35px"}})))),c().createElement(ot.Middle,{className:"flex-grow",align:"left"},c().createElement(ot.Item,null,c().createElement("nav",{className:"flex flex-wrap gap-6 mt-2 md:mt-0 cursor-pointer"},c().createElement(D,{to:gm.dashboard.path,className:"".concat(r("dashboard")?"active-link":""),style:o("dashboard")},(0,hm.__)("Dashboard","header-footer-elementor")),c().createElement(D,{to:gm.headerFooterBuilder.path,className:"".concat(r("edit.php?post_type=elementor-hf")?"active-link":""),style:o("edit.php?post_type=elementor-hf"),onClick:function(){console.log("Navigating to Header & Footer Builder")}},(0,hm.__)("Header & Footer","header-footer-elementor")),c().createElement(D,{to:gm.widgets.path,className:"".concat(r("widgets")?"active-link":""),style:o("widgets")},(0,hm.__)("Widgets","header-footer-elementor")),c().createElement(D,{to:gm.learn.path,className:"".concat(r("learn")?"active-link":""),style:o("learn")},(0,hm.__)("Learn","header-footer-elementor")),c().createElement(D,{to:gm.settings.path,className:"".concat(r("settings")?"active-link":""),style:o("settings")},(0,hm.__)("Settings","header-footer-elementor")),c().createElement(D,{to:gm.upgrade.path,className:"".concat(r("upgrade")?"active-link":""),style:o("upgrade")},(0,hm.__)("Free vs Pro","header-footer-elementor")))),c().createElement(ot.Item,null,c().createElement(ct,{icon:c().createElement(um,null),iconPosition:"right",variant:"ghost",className:"hfe-remove-ring mb-2",style:{color:"#6005FF",background:"none",border:"none",padding:0,cursor:"pointer"},onClick:function(){return a("https://ultimateelementor.com/pricing/?utm_source=uae-lite-dashboard&utm_medium=navigation-bar&utm_campaign=uae-lite-upgrade")}},(0,hm.__)("Get Full Control","header-footer-elementor")))),c().createElement(ot.Right,{className:"gap-4"},c().createElement(ot.Item,null,c().createElement(Gd,{placement:"bottom-end"},c().createElement(Gd.Trigger,null,c().createElement(rm,{label:(0,hm.__)("Free","header-footer-elementor"),size:"xs",variant:"neutral"}),c().createElement("span",{className:"sr-only"},"Open Menu")),c().createElement(Gd.Portal,null,c().createElement(Gd.ContentWrapper,null,c().createElement(Gd.Content,{className:"w-60"},c().createElement(Gd.List,null,c().createElement(Gd.Item,null,(0,hm.__)("Version","header-footer-elementor")),c().createElement(Gd.Item,null,c().createElement("div",{className:"flex justify-between w-full"},"".concat(hfeSettingsData.uaelite_current_version),c().createElement(rm,{label:(0,hm.__)("Free","header-footer-elementor"),size:"xs",variant:"neutral"}))))))))),c().createElement(ot.Item,{className:"gap-4 cursor-pointer"},c().createElement(Gd,{placement:"bottom-end"},c().createElement(Gd.Trigger,null,c().createElement(dm,null)),c().createElement(Gd.Portal,null,c().createElement(Gd.ContentWrapper,null,c().createElement(Gd.Content,{className:"w-60"},c().createElement(Gd.List,null,c().createElement(Gd.Item,null,(0,hm.__)("Useful Resources","header-footer-elementor")),c().createElement(Gd.Item,{className:"text-text-primary",style:{color:"black"},onClick:function(){return a("https://ultimateelementor.com/docs/getting-started-with-ultimate-addons-for-elementor-lite/")}},c().createElement(mm,{style:{color:"black"}}),(0,hm.__)("Getting Started","header-footer-elementor")),c().createElement(Gd.Item,{onClick:function(){return a("https://ultimateelementor.com/docs-category/widgets/")}},c().createElement(mm,null),(0,hm.__)("How to use widgets","header-footer-elementor")),c().createElement(Gd.Item,{onClick:function(){return a("https://ultimateelementor.com/docs-category/features/")}},c().createElement(mm,null),(0,hm.__)("How to use features","header-footer-elementor")),c().createElement(Gd.Item,{onClick:function(){return a("https://ultimateelementor.com/docs-category/templates/")}},c().createElement(mm,null),(0,hm.__)("How to use templates","header-footer-elementor")),c().createElement(Gd.Item,{onClick:function(){return a("https://ultimateelementor.com/contact/")}},c().createElement(fm,null),(0,hm.__)("Contact us","header-footer-elementor"))))))),c().createElement("div",{className:"pb-1",id:"hfe-whats-new"})),c().createElement(D,{to:gm.settings.path},c().createElement(pm,{className:"cursor-pointer hfe-user-icon",style:{color:"black"}}))))))};function Cm(e){return function(e){if(Array.isArray(e))return r(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||a(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}const Pm=Ld("Info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]),Tm=Ld("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]),jm=Ld("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),Am=Ld("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]),Rm="light",Fm="neutral",Dm=({icon:e,theme:t=Rm,variant:n=Fm})=>{const r="[&>svg]:h-5 [&>svg]:w-5",o=(({theme:e=Rm,variant:t=Fm})=>{let n="light"===e?"text-icon-secondary":"text-icon-inverse";return n={info:"light"===e?"text-support-info":"text-support-info-inverse",success:"light"===e?"text-support-success":"text-support-success-inverse",warning:"light"===e?"text-support-warning":"text-support-warning-inverse",error:"light"===e?"text-support-error":"text-support-error-inverse"}[t]||n,n})({theme:t,variant:n});if(e&&(0,s.isValidElement)(e))return(0,s.cloneElement)(e,{className:Fe(r,o,e?.props?.className??"")});const a={neutral:(0,I.jsx)(Pm,{className:Fe(r,o)}),info:(0,I.jsx)(Pm,{className:Fe(r,o)}),success:(0,I.jsx)(Tm,{className:Fe(r,o)}),warning:(0,I.jsx)(jm,{className:Fe(r,o)}),error:(0,I.jsx)(Am,{className:Fe(r,o)})};return a[n]||a.neutral},Mm=({actionType:e="button",onAction:t=()=>{},actionLabel:n="",theme:r=Rm})=>{const o="focus:ring-0 focus:ring-offset-0 ring-offset-0 focus:outline-none";let a="text-button-primary border-button-primary hover:border-button-primary hover:text-button-primary-hover";switch("dark"===r&&(a="text-text-inverse border-text-inverse hover:border-text-inverse hover:text-text-inverse"),e){case"button":return(0,I.jsx)(ct,{variant:"outline",size:"xs",onClick:t,className:Fe("rounded",o,a,"dark"===r?"bg-transparent hover:bg-transparent":"bg-white hover:bg-white"),children:n});case"link":return(0,I.jsx)(ct,{variant:"link",size:"xs",onClick:t,className:Fe(o,a),children:n});default:return null}},Om=({theme:e=Rm,title:t="",inline:n=!1})=>t?(0,I.jsx)("span",{className:Fe("block",{light:"text-text-primary",dark:"text-text-inverse"}[e],"text-sm leading-5 font-semibold",n?"inline":"block"),children:t}):null,Im=({theme:e=Rm,content:t="",inline:n=!1})=>t?(0,I.jsx)("span",{className:Fe({light:"text-text-primary",dark:"text-text-inverse"}[e],"block text-sm [&_*]:text-sm leading-5 [&_*]:leading-5 font-normal [word-break:break-word]",n?"inline":"block"),children:t}):null,Lm=(...e)=>t=>{e.forEach((e=>{"function"==typeof e?e(t):e&&(e.current=t)}))},zm=({variant:e="dark",placement:t="bottom",title:n="",content:r,arrow:o=!1,open:a,setOpen:i,children:l,className:c,tooltipPortalRoot:u,tooltipPortalId:d,boundary:m="clippingAncestors",strategy:f="fixed",offset:p=8,triggers:h=["hover","focus"],interactive:g=!1})=>{const y=(0,s.useMemo)((()=>"boolean"==typeof a&&"function"==typeof i),[a,i]),[v,b]=(0,s.useState)(!1),x=(0,s.useRef)(null),{refs:w,floatingStyles:E,context:_}=Ur({open:y?a:v,onOpenChange:y?i:b,placement:t,strategy:f,middleware:[er(p),nr({boundary:m}),tr({boundary:m}),(M={element:x},{...Qn(M),options:[M,undefined]})],whileElementsMounted:Un}),k=Ir(_,{enabled:!y&&h.includes("click")}),S=function(e,t){void 0===t&&(t={});const{open:n,onOpenChange:r,dataRef:o,events:a,elements:i}=e,{enabled:l=!0,delay:c=0,handleClose:u=null,mouseOnly:d=!1,restMs:m=0,move:f=!0}=t,p=gr(),h=hr(),g=vr(u),y=vr(c),v=vr(n),b=s.useRef(),x=s.useRef(-1),w=s.useRef(),E=s.useRef(-1),_=s.useRef(!0),k=s.useRef(!1),S=s.useRef((()=>{})),N=s.useRef(!1),C=s.useCallback((()=>{var e;const t=null==(e=o.current.openEvent)?void 0:e.type;return(null==t?void 0:t.includes("mouse"))&&"mousedown"!==t}),[o]);s.useEffect((()=>{if(l)return a.on("openchange",e),()=>{a.off("openchange",e)};function e(e){let{open:t}=e;t||(clearTimeout(x.current),clearTimeout(E.current),_.current=!0,N.current=!1)}}),[l,a]),s.useEffect((()=>{if(!l)return;if(!g.current)return;if(!n)return;function e(e){C()&&r(!1,e,"hover")}const t=It(i.floating).documentElement;return t.addEventListener("mouseleave",e),()=>{t.removeEventListener("mouseleave",e)}}),[i.floating,n,r,l,g,C]);const P=s.useCallback((function(e,t,n){void 0===t&&(t=!0),void 0===n&&(n="hover");const o=xr(y.current,"close",b.current);o&&!w.current?(clearTimeout(x.current),x.current=window.setTimeout((()=>r(!1,e,n)),o)):t&&(clearTimeout(x.current),r(!1,e,n))}),[y,r]),T=ar((()=>{S.current(),w.current=void 0})),j=ar((()=>{if(k.current){const e=It(i.floating).body;e.style.pointerEvents="",e.removeAttribute(br),k.current=!1}})),A=ar((()=>!!o.current.openEvent&&["click","mousedown"].includes(o.current.openEvent.type)));s.useEffect((()=>{if(l&&ht(i.domReference)){var e;const r=i.domReference;return n&&r.addEventListener("mouseleave",s),null==(e=i.floating)||e.addEventListener("mouseleave",s),f&&r.addEventListener("mousemove",t,{once:!0}),r.addEventListener("mouseenter",t),r.addEventListener("mouseleave",a),()=>{var e;n&&r.removeEventListener("mouseleave",s),null==(e=i.floating)||e.removeEventListener("mouseleave",s),f&&r.removeEventListener("mousemove",t),r.removeEventListener("mouseenter",t),r.removeEventListener("mouseleave",a)}}function t(e){if(clearTimeout(x.current),_.current=!1,d&&!Ot(b.current)||m>0&&!xr(y.current,"open"))return;const t=xr(y.current,"open",b.current);t?x.current=window.setTimeout((()=>{v.current||r(!0,e,"hover")}),t):n||r(!0,e,"hover")}function a(e){if(A())return;S.current();const t=It(i.floating);if(clearTimeout(E.current),N.current=!1,g.current&&o.current.floatingContext){n||clearTimeout(x.current),w.current=g.current({...o.current.floatingContext,tree:p,x:e.clientX,y:e.clientY,onClose(){j(),T(),A()||P(e,!0,"safe-polygon")}});const r=w.current;return t.addEventListener("mousemove",r),void(S.current=()=>{t.removeEventListener("mousemove",r)})}("touch"!==b.current||!At(i.floating,e.relatedTarget))&&P(e)}function s(e){A()||o.current.floatingContext&&(null==g.current||g.current({...o.current.floatingContext,tree:p,x:e.clientX,y:e.clientY,onClose(){j(),T(),A()||P(e)}})(e))}}),[i,l,e,d,m,f,P,T,j,r,n,v,p,y,g,o,A]),ir((()=>{var e;if(l&&n&&null!=(e=g.current)&&e.__options.blockPointerEvents&&C()){k.current=!0;const e=i.floating;if(ht(i.domReference)&&e){var t;const n=It(i.floating).body;n.setAttribute(br,"");const r=i.domReference,o=null==p||null==(t=p.nodesRef.current.find((e=>e.id===h)))||null==(t=t.context)?void 0:t.elements.floating;return o&&(o.style.pointerEvents=""),n.style.pointerEvents="none",r.style.pointerEvents="auto",e.style.pointerEvents="auto",()=>{n.style.pointerEvents="",r.style.pointerEvents="",e.style.pointerEvents=""}}}}),[l,n,h,i,p,g,C]),ir((()=>{n||(b.current=void 0,N.current=!1,T(),j())}),[n,T,j]),s.useEffect((()=>()=>{T(),clearTimeout(x.current),clearTimeout(E.current),j()}),[l,i.domReference,T,j]);const R=s.useMemo((()=>{function e(e){b.current=e.pointerType}return{onPointerDown:e,onPointerEnter:e,onMouseMove(e){const{nativeEvent:t}=e;function o(){_.current||v.current||r(!0,t,"hover")}d&&!Ot(b.current)||n||0===m||N.current&&e.movementX**2+e.movementY**2<2||(clearTimeout(E.current),"touch"===b.current?o():(N.current=!0,E.current=window.setTimeout(o,m)))}}}),[d,r,n,v,m]),F=s.useMemo((()=>({onMouseEnter(){clearTimeout(x.current)},onMouseLeave(e){A()||P(e.nativeEvent,!1)}})),[P,A]);return s.useMemo((()=>l?{reference:R,floating:F}:{}),[l,R,F])}(_,{move:!1,enabled:!y&&h.includes("hover"),...g&&{handleClose:eo()}}),N=Wr(_,{enabled:!y&&h.includes("focus")}),C=Vr(_),P=Xr(_,{role:"tooltip"}),{getReferenceProps:T,getFloatingProps:j}=Yr([k,S,N,C,P]),{isMounted:A,styles:R}=Zr(_,{duration:150,initial:{opacity:0},open:{opacity:1},close:{opacity:0}}),F={light:"bg-tooltip-background-light text-text-primary",dark:"bg-tooltip-background-dark text-text-on-color"}[e],D="dark"===e?"text-tooltip-background-dark":"text-tooltip-background-light";var M;return(0,I.jsxs)(s.Fragment,{children:[(0,s.isValidElement)(l)&&(0,I.jsx)(s.Fragment,{children:(0,s.cloneElement)(l,{ref:Lm(l.ref,w.setReference),className:Fe(l.props.className),...T()})},"tooltip-reference"),(0,I.jsx)(Rr,{id:d,root:u,children:A&&(0,I.jsxs)("div",{className:Fe("absolute z-20 py-2 px-3 rounded-md text-xs leading-4 shadow-soft-shadow-lg",F,"max-w-80 w-fit",c),ref:w.setFloating,style:{...E,...R},...j(),children:[(0,I.jsxs)("div",{children:[!!n&&(0,I.jsx)("span",{className:"font-semibold",children:n},"tooltip-title"),!!r&&(0,I.jsx)("div",{className:"font-normal",children:r},"tooltip-content")]}),o&&(0,I.jsx)(mr,{ref:x,context:_,className:Fe("fill-current",D)})]})})]})};zm.displayName="Tooltip";const Bm=(0,s.forwardRef)((({children:e=null,tag:t="label",size:n="sm",className:r="",variant:o="neutral",required:a=!1,...i},s)=>{if(!e)return null;let l="";return a&&(l="after:content-['*'] after:text-field-required after:ml-0.5"),(0,I.jsx)(t,{ref:s,className:Fe("font-medium text-field-label flex items-center gap-0.5",{xs:"text-xs [&>*]:text-xs [&>svg]:h-3 [&>svg]:w-3",sm:"text-sm [&>*]:text-sm [&>svg]:h-4 [&>svg]:w-4",md:"text-base [&>*]:text-base [&>svg]:h-5 [&>svg]:w-5"}[n],{neutral:"text-field-label [&>*]:text-field-label",help:"text-field-helper [&>*]:text-field-helper",error:"text-support-error [&>*]:text-support-error",disabled:"text-field-color-disabled disabled cursor-not-allowed [&>*]:text-field-color-disabled"}[o],l,{neutral:"",help:"font-normal",error:"font-normal",disabled:""}?.[o],r),...i,children:e})}));Bm.displayName="Label";const Vm=({label:e,switchId:t,disabled:n=!1,children:r,size:o})=>{const a={xs:"text-xs leading-4 font-medium",sm:"text-sm leading-5 font-medium",md:"text-base leading-6 font-medium"},i={xs:"text-xs leading-4 font-normal",sm:"text-sm leading-5 font-normal",md:"text-sm leading-5 font-normal"},l={xs:"space-y-0.5",sm:"space-y-0.5",md:"space-y-1"};if((0,s.isValidElement)(e))return(0,I.jsxs)("div",{className:Fe("inline-flex items-center gap-3","items-start"),children:[r,e]});const c=!e?.heading&&!e?.description,u=e?.heading&&e?.description?"items-start":"items-center";return c?r:(0,I.jsxs)("div",{className:Fe("inline-flex",u,"gap-3"),children:[r,(()=>{const{heading:r="",description:s=""}=e||{};return(0,I.jsxs)("div",{className:Fe("space-y-0.5",l[o]),children:[r&&(0,I.jsx)(Bm,{htmlFor:t,className:Fe("m-0",a[o]),...n&&{variant:"disabled"},children:r}),s&&(0,I.jsx)(Bm,{tag:"p",variant:"help",className:Fe("text-sm font-normal leading-5 m-0",i[o]),...n&&{variant:"disabled"},children:s})]})})()]})},Um=(0,s.forwardRef)((({id:e,onChange:t,value:n,defaultValue:r=!1,size:o="sm",disabled:a=!1,label:i={heading:"",description:""},name:l,className:c,...u},d)=>{const m="lg"===o?"md":o,f=(0,s.useMemo)((()=>typeof n<"u"),[n]),p=(0,s.useMemo)((()=>e||`switch-${((e=21)=>{let t="",n=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&n[e]];return t})()}`),[]),[h,g]=(0,s.useState)(r),y="primary",v=(0,s.useCallback)((()=>f?n:h),[f,n,h]),b={primary:{input:"bg-toggle-off checked:bg-toggle-on focus:ring focus:ring-toggle-on focus:ring-offset-2 border border-solid border-toggle-off-border checked:border-toggle-on-border shadow-toggleContainer focus:outline-none checked:focus:border-toggle-on-border focus:border-toggle-off-border",toggleDial:"bg-toggle-dial-background shadow-toggleDial"}},x={md:{container:"w-11 h-6",toggleDial:"size-4 peer-checked:translate-x-5"},sm:{container:"w-10 h-5",toggleDial:"size-3 peer-checked:translate-x-5"},xs:{container:"w-8 h-4",toggleDial:"size-2.5 peer-checked:translate-x-3.75"}};return(0,I.jsx)(Vm,{label:i,switchId:p,disabled:a,size:m,children:(0,I.jsxs)("div",{className:Fe("relative group/switch inline-block cursor-pointer rounded-full shrink-0",x[m].container,c),children:[(0,I.jsx)("input",{ref:d,id:p,type:"checkbox",className:Fe("peer appearance-none absolute rounded-full cursor-pointer transition-colors duration-300 h-full w-full before:content-[''] checked:before:content-[''] m-0 checked:[background-image:none]",b[y].input,a&&"bg-toggle-off-disabled disabled:border-transparent disabled:cursor-not-allowed checked:disabled:bg-toggle-on-disabled disabled:shadow-toggle-disabled",!a&&{primary:{input:"group-hover/switch:bg-toggle-off-hover checked:group-hover/switch:bg-toggle-on-hover checked:group-hover/switch:border-toggle-on-border"}}[y].input),checked:v(),onChange:e=>{if(a)return;const n=e.target.checked;f||g(n),"function"==typeof t&&t(n)},disabled:a,name:l,...u}),(0,I.jsx)("label",{htmlFor:p,className:Fe("peer/toggle-dial bg-white border rounded-full absolute cursor-pointer shadow-md before:content[''] before:transition-opacity before:opacity-0 hover:before:opacity-10 before:hidden border-none transition-all duration-300 top-2/4 not-rtl:left-1 rtl:right-1 -translate-y-2/4 before:w-10 before:h-10 before:rounded-full before:absolute before:top-2/4 not-rtl:before:left-2/4 rtl:before:right-2/4 before:-translate-y-2/4 before:-translate-x-2/4",x[m].toggleDial,b[y].toggleDial,a&&"peer-disabled:cursor-not-allowed",!a&&{md:"group-hover/switch:size-5 group-focus-within/switch:size-5 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5",sm:"group-hover/switch:size-4 group-focus-within/switch:size-4 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5",xs:"group-hover/switch:size-3.25 group-focus-within/switch:size-3.25 not-rtl:group-focus-within/switch:left-0.5 rtl:group-focus-within/switch:right-0.5 not-rtl:group-hover/switch:left-0.5 rtl:group-hover/switch:right-0.5"}[m])})]})})}));Um.displayName="Switch";const Wm=cm("monitor",[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]]),Hm=window.wp.apiFetch;var $m=o.n(Hm),qm=[],Ym=function(){0!==qm.length&&qm.shift()()};const Gm=function(e){var t=e.widget,n=e.updateCounter,r=(e.showTooltip,t.id),o=t.icon,a=t.title,l=(t.infoText,t.is_pro),u=(t.is_active,t.slug,t.demo_url),d=(t.doc_url,t.description),m=(t.is_new,i((0,s.useState)(t.is_active),2)),f=m[0],p=m[1],h=i((0,s.useState)(!1),2),g=h[0],y=h[1],v=i((0,s.useState)(!1),2),b=v[0],x=v[1];(0,s.useEffect)((function(){p(t.is_active)}),[t.is_active,n]);var w=function(e){var t=e?"hfe_deactivate_widget":"hfe_activate_widget",n=new window.FormData;n.append("action",t),n.append("nonce",hfe_admin_data.nonce),n.append("module_id",r),n.append("is_pro",l);try{var o=$m()({url:hfe_admin_data.ajax_url,method:"POST",body:n});o.success?p(f):o.error}catch(e){}finally{y(!1),Ym()}};return c().createElement(c().Fragment,null,c().createElement("style",{dangerouslySetInnerHTML:{__html:"\n\t\t\t\t\t.hfe-uae-pro-link:focus,\n\t\t\t\t\t.hfe-uae-pro-link:active,\n\t\t\t\t\t.hfe-uae-pro-link:hover,\n\t\t\t\t\t.hfe-uae-pro-link:focus-visible {\n\t\t\t\t\t\toutline: none !important;\n\t\t\t\t\t\tbox-shadow: none !important;\n\t\t\t\t\t\tborder: none !important;\n\t\t\t\t\t}\n\t\t\t\t"}}),c().createElement(nt,{align:"center",containerType:"flex",direction:"column",justify:"between",gap:""},c().createElement("div",{className:"flex items-start justify-between w-full mb-4"},c().createElement("div",{className:"h-10 w-10 ".concat(null==o?void 0:o.props),style:{fontSize:"22px"}},o),c().createElement("div",{className:"flex items-center gap-x-2"},l?c().createElement(zm,{arrow:!0,content:c().createElement("div",{style:{textAlign:"left",maxWidth:"280px"}},c().createElement("div",{style:{display:"flex",alignItems:"center",marginBottom:"8px",gap:"6px"}},c().createElement("span",{style:{fontSize:"14px",fontWeight:"600",color:"#ffffff",lineHeight:"1.2"}},a),c().createElement("span",{style:{backgroundColor:"#C026D3",color:"#ffffff",fontSize:"10px",fontWeight:"600",padding:"2px 6px",borderRadius:"4px",textTransform:"uppercase",letterSpacing:"0.5px"}},(0,hm.__)("PRO","header-footer-elementor"))),c().createElement("p",{style:{fontSize:"12px",color:"#E5E7EB",margin:"0 0 12px 0",lineHeight:"1.4"}},d),c().createElement("a",{href:"https://ultimateelementor.com/pricing/?utm_source=uae-lite-dashboard&utm_medium=pro-widgets&utm_campaign=uae-upgrade",target:"_blank",rel:"noopener noreferrer",style:{color:"#C026D3",textDecoration:"none",outline:"none",fontSize:"12px",fontWeight:"600"},className:"hfe-uae-pro-link focus:outline-none"},(0,hm.__)("Get Full Control","header-footer-elementor"))),placement:"bottom",variant:"dark",size:"md",triggers:["click"],open:b,onOpenChange:x},c().createElement("div",{onClick:function(){return x(!b)},style:{cursor:"pointer"}},c().createElement(Um,{onChange:function(){},size:"xs",value:!1,disabled:!0,style:{outline:"none",cursor:"default",pointerEvents:"none"},className:"hfe-remove-ring outline-none"}))):c().createElement(Um,{onChange:function(){g||(y(!0),f?(p(!1),qm.push((function(){return w(f)}))):(p(!0),qm.push((function(){return w(f)}))),1===qm.length&&Ym())},size:"xs",value:f,style:{outline:"none"},className:"hfe-remove-ring outline-none"}))),c().createElement("div",{className:"flex items-start justify-between w-full"},c().createElement("p",{className:"text-sm font-medium text-text-primary m-0 w-full leading-tight flex items-center overflow-hidden",style:{display:"-webkit-box",WebkitLineClamp:1,WebkitBoxOrient:"vertical",wordBreak:"break-word"}},a),u&&c().createElement("div",{className:"ml-2"},c().createElement("a",{href:u,target:"_blank",rel:"noopener noreferrer",title:(0,hm.__)("View Demo","header-footer-elementor"),"aria-label":(0,hm.__)("View Demo","header-footer-elementor"),className:"inline-flex items-center hfe-remove-ring focus:outline-none",style:{cursor:"pointer",outline:"none"}},c().createElement(Wm,{className:"h-4 w-4",size:16,color:"#A0A5B2"}))))))},Xm=({variant:e="rectangular",className:t,...n})=>{const r={circular:"rounded-full bg-gray-200 ",rectangular:"rounded-md bg-gray-200"}[e],o={circular:"size-10",rectangular:"w-96 h-3"}[e];return(0,I.jsx)("div",{className:Fe(r,"animate-pulse",o,t),...n})},Km=function(){var e=i((0,s.useState)(null),2),t=e[0],n=e[1],r=i((0,s.useState)(!0),2),o=r[0],a=r[1],l=i((0,s.useState)(!0),2),u=l[0];return l[1],(0,s.useEffect)((function(){a(!0),$m()({path:"/hfe/v1/widgets",headers:{"Content-Type":"application/json","X-WP-Nonce":hfeSettingsData.hfe_nonce_action}}).then((function(e){var t=function(e){var t=[];for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];t.push({id:n,slug:r.slug,title:r.title,keywords:r.keywords,icon:c().createElement("i",{className:r.icon}),title_url:r.title_url,default:r.default,doc_url:r.doc_url,is_pro:r.is_pro,description:r.description,is_active:void 0===r.is_activate||r.is_activate,demo_url:void 0!==r.demo_url?r.demo_url:r.doc_url})}return t}(e);n(t),a(!1)})).catch((function(e){a(!1)}))}),[]),c().createElement("div",{className:"rounded-lg bg-white w-full mb-6"},c().createElement("div",{className:"flex items-center justify-between p-4",style:{paddingBottom:"0"}},c().createElement("p",{className:"m-0 text-sm font-semibold text-text-primary"},(0,hm.__)("Widgets / Features","header-footer-elementor")),c().createElement(ct,{icon:c().createElement(um,null),iconPosition:"right",variant:"ghost",className:"hfe-remove-ring mb-2",style:{color:"#6005FF",background:"none",border:"none",padding:0,cursor:"pointer"},onClick:function(){return window.open("https://ultimateelementor.com/pricing/?utm_source=uae-lite-dashboard&utm_medium=navigation-bar&utm_campaign=uae-lite-upgrade","_blank")}},(0,hm.__)("Unlock All Features","header-footer-elementor"))),c().createElement("div",{className:"flex bg-black flex-col rounded-lg p-4"},o?c().createElement(nt,{align:"stretch",className:"p-2 gap-1.5 grid grid-cols-2 md:grid-cols-4",style:{backgroundColor:"#F9FAFB"},containerType:"grid",gap:"",justify:"start"},Cm(Array(16)).map((function(e,t){return c().createElement(nt.Item,{key:t,alignSelf:"auto",className:"text-wrap rounded-md shadow-container-item bg-background-primary p-6 space-y-2"},c().createElement(Xm,{className:"w-12 h-2 rounded-md"}),c().createElement(Xm,{className:"w-16 h-2 rounded-md"}),c().createElement(Xm,{className:"w-12 h-2 rounded-md"}))}))):c().createElement(nt,{align:"stretch",className:"p-2 gap-1.5 grid grid-cols-2 md:grid-cols-4",style:{backgroundColor:"#F9FAFB"},containerType:"grid",gap:"",justify:"start"},null==t?void 0:t.slice(10,18).map((function(e){return c().createElement(nt.Item,{key:e.id,alignSelf:"auto",className:"text-wrap rounded-md shadow-container-item bg-background-primary px-4",style:{paddingTop:"8px",paddingBottom:"8px"}},c().createElement(Gm,{widget:e,showTooltip:u,key:e.id,updateCounter:0}))}))),c().createElement("div",{className:"flex items-center justify-center gap-x-2 "},c().createElement(D,{to:gm.widgets.path,className:"text-sm font-normal text-text-primary cursor-pointer",style:{lineHeight:"1rem",paddingTop:"20px"}},(0,hm.__)("View More Widgets","header-footer-elementor"),c().createElement(um,{className:"ml-1 font-semibold",size:14})))))},Jm=({title:e="",description:t="",icon:n=null,iconPosition:r="right",tag:o="h2",size:a="sm",className:i=""})=>{const s={xs:"gap-1 [&>svg]:size-3.5",sm:"gap-1 [&>svg]:size-4",md:"gap-1.5 [&>svg]:size-5",lg:"gap-1.5 [&>svg]:size-5"};if(!e)return null;const l=()=>(0,I.jsx)(o,{className:Fe("font-semibold p-0 m-0",{xs:"text-base [&>*]:text-base gap-1",sm:"text-lg [&>*]:text-lg gap-1",md:"text-xl [&>*]:text-xl gap-1.5",lg:"text-2xl [&>*]:text-2xl gap-1.5"}[a]),children:e});return t?(0,I.jsxs)("div",{className:i,children:[(0,I.jsxs)("div",{children:[n&&"left"===r&&(0,I.jsxs)("div",{className:Fe("flex items-center",s[a]),children:[n,l()]}),n&&"right"===r&&(0,I.jsxs)("div",{className:Fe("flex items-center",s[a]),children:[l(),n]}),!n&&l()]}),(0,I.jsx)("p",{className:Fe("text-text-secondary font-normal my-0",{xs:"text-sm",sm:"text-sm",md:"text-base",lg:"text-base"}[a]),children:t})]}):(0,I.jsxs)("div",{className:i,children:[n&&"left"===r&&(0,I.jsxs)("div",{className:Fe("flex items-center",s[a]),children:[n,l()]}),n&&"right"===r&&(0,I.jsxs)("div",{className:Fe("flex items-center",s[a]),children:[l(),n]}),!n&&l()]})},Zm=cm("headphones",[["path",{d:"M3 14h3a2 2 0 0 1 2 2v3a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-7a9 9 0 0 1 18 0v7a2 2 0 0 1-2 2h-1a2 2 0 0 1-2-2v-3a2 2 0 0 1 2-2h3",key:"1xhozi"}]]),Qm=cm("book-open-text",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M16 12h2",key:"7q9ll5"}],["path",{d:"M16 8h2",key:"msurwy"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}],["path",{d:"M6 12h2",key:"32wvfc"}],["path",{d:"M6 8h2",key:"30oboj"}]]),ef=cm("notepad-text",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M12 2v4",key:"3427ic"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"16",height:"18",x:"4",y:"4",rx:"2",key:"1u9h20"}],["path",{d:"M8 10h6",key:"3oa6kw"}],["path",{d:"M8 14h8",key:"1fgep2"}],["path",{d:"M8 18h5",key:"17enja"}]]),tf=cm("star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]),nf=function(){return c().createElement("div",{className:"box-border hfe-dashboard-quick-access p-4 bg-white rounded-lg shadow-md",style:{width:"-webkit-fill-available"}},c().createElement(Jm,{className:"mb-2",icon:null,iconPosition:"right",size:"xs",tag:"h3",title:(0,hm.__)("Quick Access","header-footer-elementor")}),c().createElement(nt,{align:"stretch",className:"p-1 rounded-lg bg-[#F9FAFB] gap-1",containerType:"flex",direction:"column",gap:"",justify:"start",style:{width:"100%",backgroundColor:"#F9FAFB"}},c().createElement(nt.Item,{alignSelf:"auto",className:"p-4 bg-white flex items-center justify-between rounded-lg shadow-container-item",order:"none",shrink:1},c().createElement(ct,{className:"text-black hfe-remove-ring",icon:c().createElement(Zm,null),iconPosition:"left",variant:"link",onClick:function(){window.open("https://ultimateelementor.com/contact/","_blank")}},(0,hm.__)("VIP Priority Support","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("PRO","header-footer-elementor"),size:"xs",variant:"inverse"})),c().createElement(nt.Item,{alignSelf:"auto",className:"p-4 bg-white rounded-lg shadow-container-item",order:"none",shrink:1},c().createElement(ct,{className:"text-black hfe-remove-ring",icon:c().createElement(Qm,null),iconPosition:"left",variant:"link",onClick:function(){window.open("https://ultimateelementor.com/docs/getting-started-with-ultimate-addons-for-elementor-lite/","_blank")}},(0,hm.__)("Knowledge Base","header-footer-elementor"))),c().createElement(nt.Item,{className:"p-4 bg-white rounded-lg shadow-container-item"},c().createElement(ct,{className:"text-black hfe-remove-ring",icon:c().createElement(dm,null),iconPosition:"left",variant:"link",onClick:function(){window.open("https://ultimateelementor.com/docs/","_blank")}},(0,hm.__)("Help Centre","header-footer-elementor"))),c().createElement(nt.Item,{className:"p-4 bg-white rounded-lg shadow-container-item"},c().createElement(ct,{className:"text-black hfe-remove-ring",icon:c().createElement(ef,null),iconPosition:"left",variant:"link",onClick:function(){window.open("https://ideas.ultimateelementor.com/boards/feature-requests","_blank")}},(0,hm.__)("Request a Feature","header-footer-elementor"))),c().createElement(nt.Item,{className:"p-4 bg-white rounded-lg shadow-container-item"},c().createElement(ct,{className:"text-black hfe-remove-ring",icon:c().createElement(tf,null),iconPosition:"left",variant:"link",onClick:function(){window.open("https://wordpress.org/support/plugin/header-footer-elementor/reviews/#new-post","_blank")}},(0,hm.__)("Rate Us","header-footer-elementor")))))},rf=cm("plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]),of=function(){return c().createElement("div",null,c().createElement(nt,{align:"center",className:"bg-background-primary border-[0.5px] border-subtle rounded-xl shadow-sm mb-6 p-8 flex flex-col lg:flex-row",containerType:"flex",direction:"row",gap:"sm"},c().createElement(nt.Item,{shrink:1,className:"flex-1"},c().createElement(Jm,{description:"",icon:null,iconPosition:"right",className:"max-w-lg",size:"lg",tag:"h3",title:(0,hm.__)("Welcome to Ultimate Addons for Elementor!","header-footer-elementor")}),c().createElement("p",{className:"text-sm font-medium text-text-tertiary m-0 mt-2"},(0,hm.__)("Effortlessly design modern websites with UAE using our powerful range of widgets & features. Get started by selecting an option based on your needs.","header-footer-elementor")),c().createElement("div",{className:"flex items-center pt-6 gap-2 flex-wrap"},c().createElement(ct,{iconPosition:"right",variant:"primary",className:"text-[#6005FF] border-none hfe-remove-ring flex-shrink-0",style:{backgroundColor:"var(--Colors-Button-button-secondary, #DDD6FE)",transition:"background-color 0.3s ease",border:"none",outline:"none",boxShadow:"none"},onMouseEnter:function(e){e.currentTarget.style.backgroundColor="#4B00CC",e.currentTarget.style.color="#fff"},onMouseLeave:function(e){e.currentTarget.style.backgroundColor="var(--Colors-Button-button-secondary, #DDD6FE)",e.currentTarget.style.color="#6005FF"},onClick:function(){window.open(hfeSettingsData.hfe_post_url,"_blank")}},(0,hm.__)("Create Header/Footer","header-footer-elementor")),c().createElement(ct,{icon:c().createElement(rf,null),iconPosition:"right",variant:"outline",className:"hfe-remove-ring flex-shrink-0",style:{color:"#000",borderColor:"#E9DFFC"},onMouseEnter:function(e){return e.currentTarget.style.color="#000000"},onMouseLeave:function(e){return(e.currentTarget.style.color="#000")&&(e.currentTarget.style.borderColor="#E9DFFC")},onClick:function(){window.open(hfeSettingsData.elementor_page_url,"_blank")}},(0,hm.__)("Create New Page","header-footer-elementor")),c().createElement("div",{style:{color:"black",background:"none",border:"none",padding:0,cursor:"pointer"},className:"flex-shrink-0",onMouseEnter:function(e){return e.currentTarget.style.color="#6005ff"},onMouseLeave:function(e){return e.currentTarget.style.color="black"},onClick:function(){window.open("https://ultimateelementor.com/docs/getting-started-with-ultimate-addons-for-elementor-lite/","_blank")}}))),c().createElement(nt.Item,{className:"md:mt-0 mt-4 flex-shrink-0"},c().createElement("iframe",{width:"280",height:"160",src:"https://www.youtube.com/embed/ZeogOxqdKJI",frameBorder:"0",style:{borderRadius:"8px"},allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0}))))},af=cm("rocket",[["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z",key:"m3kijz"}],["path",{d:"m12 15-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z",key:"1fmvmk"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0",key:"1f8sc4"}],["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}]]),sf=cm("check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]),lf=function(){return c().createElement("div",null,c().createElement(nt,{className:"bg-background-primary px-4 border-[0.5px] border-subtle rounded-xl shadow-sm",containerType:"flex",direction:"column",gap:"xs"},c().createElement(nt.Item,{className:"flex flex-col pt-6 justify-between",style:{width:"65%"}},c().createElement(nt.Item,{className:"flex justify-center items-center",style:{width:"34%"}},c().createElement("img",{src:"".concat(hfeSettingsData.augmented_reality),alt:(0,hm.__)("Column Showcase","header-footer-elementor"),className:"object-contain w-full rounded"})),c().createElement("div",{className:"pt-2 px-2 flex flex-col"},c().createElement(Jm,{description:"",icon:c().createElement(af,null),iconPosition:"left",size:"xs",tag:"p",title:(0,hm.__)("Unlock Pro Widgets","header-footer-elementor"),className:"text-xs py-1 text-[#C026D3]"}),c().createElement(Jm,{description:"",icon:"",iconPosition:"left",tag:"h6",title:c().createElement(c().Fragment,null,(0,hm.__)("Design Smarter with Ultimate Addons!","header-footer-elementor")),className:"py-1 text-[16px] font-normal text-text-primary"}),c().createElement("p",{className:"m-0 text-base max-w-96 text-[#4F4E7C]"},(0,hm.__)("Craft stunning websites faster with powerful widgets, advanced features, and total flexibility.","header-footer-elementor"))),c().createElement("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-2 m-0 pt-2"},c().createElement("ul",{className:"list-none font-normal space-y-2 text-sm text-[#111827]"},c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("50+ Widgets","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Conversion Extensions","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Display Conditions","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("White Label","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("WooCommerce Builder","header-footer-elementor")))),c().createElement("ul",{className:"list-none font-normal space-y-2 text-sm text-[#111827]"},c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("200+ Section Blocks","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Form & Pop-up Builder","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Animation Effects","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Bloggers Toolkit","header-footer-elementor"))),c().createElement("li",{className:"flex items-center gap-1 text-text-tertiary whitespace-nowrap"},c().createElement(sf,{color:"#6005FF",size:16,className:"flex-shrink-0"}),c().createElement("span",{className:"truncate"},(0,hm.__)("Social Media Bundle","header-footer-elementor")))))),c().createElement("div",{className:"flex items-center m-0 pb-4 w-full justify-center"},c().createElement(ct,{iconPosition:"right",variant:"primary",className:"bg-[#6005FF] w-full m-0 h-10 flex items-center justify-center hfe-remove-ring",style:{backgroundColor:"#6005FF",transition:"background-color 0.3s ease",outline:"none",height:"40px"},onMouseEnter:function(e){return e.currentTarget.style.backgroundColor="#4B00CC"},onMouseLeave:function(e){return e.currentTarget.style.backgroundColor="#6005FF"},onClick:function(){window.open("https://ultimateelementor.com/pricing/?utm_source=uae-lite-dashboard&utm_medium=unlock-ultimate-feature&utm_campaign=uae-lite-upgrade","_blank")}},(0,hm.__)("View Plans","header-footer-elementor")))))};function cf(e,t,n,r,o,a,i){try{var s=e[a](i),l=s.value}catch(e){return void n(e)}s.done?t(l):Promise.resolve(l).then(r,o)}function uf(e){return function(){var t=this,n=arguments;return new Promise((function(r,o){var a=e.apply(t,n);function i(e){cf(a,r,o,i,s,"next",e)}function s(e){cf(a,r,o,i,s,"throw",e)}i(void 0)}))}}const df=window.regeneratorRuntime;var mf=o.n(df);const ff=(0,s.createContext)({}),pf=()=>(0,s.useContext)(ff),hf={open:{opacity:1},exit:{opacity:0}},gf={duration:.2},yf=({open:e,setOpen:t,children:n,trigger:r=null,className:o,exitOnClickOutside:a=!1,exitOnEsc:i=!0,design:l="simple",scrollLock:c=!0})=>{const u=void 0!==e&&void 0!==t,[d,m]=(0,s.useState)(!1),f=(0,s.useRef)(null),p=(0,s.useRef)(null),h=(0,s.useMemo)((()=>u?e:d),[e,d]),g=(0,s.useMemo)((()=>u?t:m),[m,m]),y=()=>{h||g(!0)},v=()=>{h&&g(!1)},b=(0,s.useCallback)((()=>(0,s.isValidElement)(r)?(0,s.cloneElement)(r,{onClick:De(y,r?.props?.onClick)}):"function"==typeof r?r({onClick:y}):null),[r,y,v]),x=e=>{"Escape"===e.key&&i&&v()},w=e=>{a&&f.current&&!f.current.contains(e.target)&&v()};return(0,s.useEffect)((()=>(window.addEventListener("keydown",x),document.addEventListener("mousedown",w),()=>{window.removeEventListener("keydown",x),document.removeEventListener("mousedown",w)})),[h]),(0,s.useEffect)((()=>{if(!c)return;const e=document.querySelector("html");return h&&e&&(e.style.overflow="hidden"),()=>{e&&(e.style.overflow="")}}),[h]),(0,I.jsxs)(I.Fragment,{children:[b(),(0,I.jsx)(ff.Provider,{value:{open:h,setOpen:g,handleClose:v,design:l,dialogContainerRef:p,dialogRef:f},children:(0,I.jsx)("div",{ref:p,className:Fe("fixed z-999999 w-0 h-0 overflow-visible",o),children:n})})]})};yf.displayName="Dialog";const vf=({children:e,className:t})=>{const{open:n,handleClose:r,dialogRef:o}=pf();return(0,I.jsx)(Dd,{children:n&&(0,I.jsx)(Cd.div,{className:"fixed inset-0 overflow-y-auto",initial:"exit",animate:"open",exit:"exit",variants:hf,role:"dialog",transition:gf,children:(0,I.jsx)("div",{className:"flex items-center justify-center min-h-full",children:(0,I.jsx)("div",{ref:o,className:Fe("flex flex-col gap-5 w-120 h-fit bg-background-primary border border-solid border-border-subtle rounded-xl shadow-soft-shadow-2xl my-5 overflow-hidden",t),children:"function"==typeof e?e({close:r}):e})})})})};vf.displayName="Dialog.Panel";const bf=({className:e,...t})=>{const{open:n,dialogContainerRef:r}=pf();return r?.current?(0,I.jsx)(I.Fragment,{children:(0,rn.createPortal)((0,I.jsx)(Dd,{children:n&&(0,I.jsx)(Cd.div,{className:Fe("fixed inset-0 -z-10 bg-background-inverse/90",e),...t,initial:"exit",animate:"open",exit:"exit",variants:hf,transition:gf})}),r.current)}):null};bf.displayName="Dialog.Backdrop";const xf=({children:e,className:t,...n})=>(0,I.jsx)("div",{className:Fe("space-y-2 px-5 pt-5 pb-1",t),...n,children:e});xf.displayName="Dialog.Header";const wf=({children:e,as:t="h3",className:n,...r})=>(0,I.jsx)(t,{className:Fe("text-base font-semibold text-text-primary m-0 p-0",n),...r,children:e});wf.displayName="Dialog.Title";const Ef=({children:e,as:t="p",className:n,...r})=>(0,I.jsx)(t,{className:Fe("text-sm font-normal text-text-secondary my-0 ml-0 mr-1 p-0",n),...r,children:e});Ef.displayName="Dialog.Description";const _f=({className:e,...t})=>(0,I.jsx)("button",{className:Fe("bg-transparent inline-flex justify-center items-center border-0 p-1 m-0 cursor-pointer focus:outline-none outline-none shadow-none",e),"aria-label":"Close dialog",...t,children:(0,I.jsx)(nm,{className:"size-4 text-text-primary shrink-0"})}),kf=({children:e,as:t=s.Fragment,...n})=>{const{handleClose:r}=pf();return e?t===s.Fragment?"function"==typeof e?e({close:r}):(0,s.cloneElement)(e,{onClick:r}):(0,I.jsx)(t,{...n,onClick:r,children:e}):(0,I.jsx)(_f,{onClick:r,...n})};kf.displayName="Dialog.CloseButton";const Sf=({children:e,className:t,...n})=>(0,I.jsx)("div",{className:Fe("px-5",t),...n,children:e});Sf.displayName="Dialog.Body";const Nf=({children:e,className:t})=>{const{design:n,handleClose:r}=pf();return(0,I.jsx)("div",{className:Fe("p-4 flex justify-end gap-3",{"bg-background-secondary":"footer-divided"===n},t),children:e?"function"==typeof e?e({close:r}):e:null})};Nf.displayName="Dialog.Footer",yf.Panel=vf,yf.Title=wf,yf.Description=Ef,yf.CloseButton=kf,yf.Header=xf,yf.Body=Sf,yf.Footer=Nf,yf.Backdrop=bf;const Cf=function(e){var t=e.plugin,n=e.setUpdateCounter,r=t.path,o=t.slug,a=t.siteUrl,l=t.icon,u=t.type,d=t.name,m=t.zipUrl,f=t.desc,p=(t.wporg,t.isFree,t.action,t.status),h=t.settings_url,g=i((0,s.useState)(!1),2),y=g[0],v=g[1],b=i((0,s.useState)(null),2),x=b[0],w=b[1],E=function(e){v(!1);var t=new window.FormData;t.append("action","hfe_recommended_plugin_activate"),t.append("nonce",hfe_admin_data.nonce),t.append("plugin",e.init),t.append("type",e.type),t.append("slug",e.slug);var r=document.querySelector('[data-slug="'.concat(e.slug,'"]')),o=r.querySelector("span");o.innerText=(0,hm.__)("Activating...","header-footer-elementor"),$m()({url:hfe_admin_data.ajax_url,method:"POST",body:t}).then((function(t){if(t.success)o&&(r.style.color="#16A34A",r.dataset.action="site_redirect",r.classList.add("hfe-plugin-activated"),o.innerText=(0,hm.__)("Activated","header-footer-elementor"),window.open(h,"_blank"),setTimeout((function(){n((function(e){return e+1}))}),5e3));else{e.type;var a=document.querySelector('[data-slug="'.concat(e.slug,'"]'));if(a){var i=a.querySelector("span");i&&(i.innerText=(0,hm.__)("Activate","header-footer-elementor"))}}}))};return c().createElement(nt,{align:"center",containerType:"flex",direction:"column",justify:"between",gap:"lg"},c().createElement("div",{className:"flex items-center justify-between w-full"},c().createElement("div",{className:"h-5 w-5"},c().createElement("img",{src:l,alt:"Recommended Plugins/Themes",className:"w-full h-auto rounded cursor-pointer",style:{width:"140px",height:"140px",marginTop:"-55px"}})),c().createElement("div",{className:"flex items-center gap-x-2"},c().createElement(yf,{design:"simple",open:y,setOpen:v},c().createElement(yf.Backdrop,null),c().createElement(yf.Panel,null,c().createElement(yf.Header,null,c().createElement("div",{className:"flex items-center justify-between"},c().createElement(yf.Title,null,(0,hm.__)("Activate Theme","header-footer-elementor"))),c().createElement(yf.Description,null,(0,hm.__)("Are you sure you want to switch your current theme to Astra?","header-footer-elementor"))),c().createElement(yf.Footer,null,c().createElement(ct,{onClick:function(){return E(x)}},(0,hm.__)("Yes","header-footer-elementor")),c().createElement(ct,{variant:"outline",onClick:function(){return v(!1)}},(0,hm.__)("Close","header-footer-elementor"))))))),c().createElement("div",{className:"flex flex-col w-full pb-4"},c().createElement("p",{className:"text-base font-medium text-text-primary pb-1 m-0 cursor-pointer",onClick:function(){return window.open(t.siteurl,"_blank")},style:{marginTop:"-8px"}},(0,hm.__)(d,"header-footer-elementor")),c().createElement("p",{className:"text-sm font-medium text-text-tertiary m-0"},(0,hm.__)(f,"header-footer-elementor")),c().createElement("div",{className:"hfe-remove-ring"},c().createElement(ct,{size:"sm",className:"cursor-pointer hfe-remove-ring bg-white hover:bg-gray-100 hover:text-gray-900 hover:shadow-md text-gray-800 rounded mt-4 px-2 py-2 transition-all duration-200 ease-in-out transform hover:scale-105 hover:border-gray-400",onClick:function(e){var t=e.currentTarget.dataset.action,n=new window.FormData,r={init:e.currentTarget.dataset.init,type:e.currentTarget.dataset.type,slug:e.currentTarget.dataset.slug,name:e.currentTarget.dataset.pluginname};switch(t){case"hfe_recommended_plugin_activate":"theme"===r.type?(w(r),v(!0)):E(r);break;case"hfe_recommended_plugin_install":n.append("action","theme"===r.type?"hfe_recommended_theme_install":"hfe_recommended_plugin_install"),n.append("_ajax_nonce",hfe_admin_data.installer_nonce),n.append("slug",r.slug),e.target.innerText=(0,hm.__)("Installing...","header-footer-elementor"),$m()({url:hfe_admin_data.ajax_url,method:"POST",body:n}).then((function(t){t.success||"folder_exists"===t.errorCode?(e.target.innerText=(0,hm.__)("Installed","header-footer-elementor"),"theme"===r.type?(document.querySelector('[data-slug="'.concat(r.slug,'"]')).dataset.action="hfe_recommended_plugin_activate",e.target.innerText=(0,hm.__)("Activate","header-footer-elementor")):E(r)):(e.target.innerText=(0,hm.__)("Install","header-footer-elementor"),alert("theme"===r.type?(0,hm.__)("Theme installation failed. Please try again later.","header-footer-elementor"):(0,hm.__)("Plugin installation failed. Please try again later.","header-footer-elementor")))}));break;case"site_redirect":window.open(a,"_blank")}},"data-plugin":m,"data-type":u,"data-pluginname":d,"data-slug":o,"data-site":a,"data-init":r,"data-action":function(e){return"Activated"===e?"site_redirect":"Installed"===e?"hfe_recommended_plugin_activate":"hfe_recommended_plugin_install"}(p),style:{outline:"none",border:"1px solid #ccc"},onMouseEnter:function(e){return e.currentTarget.style.color="#5C2EDE"},onMouseLeave:function(e){return e.currentTarget.style.color="black"}},"Activated"===p?(0,hm.__)("Visit Site","header-footer-elementor"):"Installed"===p?(0,hm.__)("Activate","header-footer-elementor"):(0,hm.__)("Install & Activate","header-footer-elementor")))))};function Pf(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}const Tf=function(){var e=i((0,s.useState)([]),2),t=e[0],n=e[1],r=i((0,s.useState)(!0),2),o=r[0],a=r[1],l=i((0,s.useState)(0),2),u=l[0],d=l[1],m=i((0,s.useState)(!1),2),f=m[0],p=m[1];function g(e){return Object.keys(e).map((function(t){return function(e){for(var t=1;t"object"==typeof window?((e?e.querySelector("#_goober"):window._goober)||Object.assign((e||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:e||Hf,qf=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,Yf=/\/\*[^]*?\*\/| +/g,Gf=/\n+/g,Xf=(e,t)=>{let n="",r="",o="";for(let a in e){let i=e[a];"@"==a[0]?"i"==a[1]?n=a+" "+i+";":r+="f"==a[1]?Xf(i,a):a+"{"+Xf(i,"k"==a[1]?"":t)+"}":"object"==typeof i?r+=Xf(i,t?t.replace(/([^,])+/g,(e=>a.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,(t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)))):a):null!=i&&(a=/^--/.test(a)?a:a.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=Xf.p?Xf.p(a,i):a+":"+i+";")}return n+(t&&o?t+"{"+o+"}":o)+r},Kf={},Jf=e=>{if("object"==typeof e){let t="";for(let n in e)t+=n+Jf(e[n]);return t}return e};function Zf(e){let t=this||{},n=e.call?e(t.p):e;return((e,t,n,r,o)=>{let a=Jf(e),i=Kf[a]||(Kf[a]=(e=>{let t=0,n=11;for(;t>>0;return"go"+n})(a));if(!Kf[i]){let t=a!==e?e:(e=>{let t,n,r=[{}];for(;t=qf.exec(e.replace(Yf,""));)t[4]?r.shift():t[3]?(n=t[3].replace(Gf," ").trim(),r.unshift(r[0][n]=r[0][n]||{})):r[0][t[1]]=t[2].replace(Gf," ").trim();return r[0]})(e);Kf[i]=Xf(o?{["@keyframes "+i]:t}:t,n?"":"."+i)}let s=n&&Kf.g?Kf.g:null;return n&&(Kf.g=Kf[i]),((e,t,n,r)=>{r?t.data=t.data.replace(r,e):-1===t.data.indexOf(e)&&(t.data=n?e+t.data:t.data+e)})(Kf[i],t,r,s),i})(n.unshift?n.raw?((e,t,n)=>e.reduce(((e,r,o)=>{let a=t[o];if(a&&a.call){let e=a(n),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;a=t?"."+t:e&&"object"==typeof e?e.props?"":Xf(e,""):!1===e?"":e}return e+r+(null==a?"":a)}),""))(n,[].slice.call(arguments,1),t.p):n.reduce(((e,n)=>Object.assign(e,n&&n.call?n(t.p):n)),{}):n,$f(t.target),t.g,t.o,t.k)}Zf.bind({g:1});let Qf,ep,tp,np=Zf.bind({k:1});function rp(e,t){let n=this||{};return function(){let r=arguments;function o(a,i){let s=Object.assign({},a),l=s.className||o.className;n.p=Object.assign({theme:ep&&ep()},s),n.o=/ *go\d+/.test(l),s.className=Zf.apply(n,r)+(l?" "+l:""),t&&(s.ref=i);let c=e;return e[0]&&(c=s.as||e,delete s.as),tp&&c[0]&&tp(s),Qf(c,s)}return t?t(o):o}}var op=(e,t)=>(e=>"function"==typeof e)(e)?e(t):e,ap=(()=>{let e=0;return()=>(++e).toString()})(),ip=(()=>{let e;return()=>{if(void 0===e&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),sp=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,20)};case 1:return{...e,toasts:e.toasts.map((e=>e.id===t.toast.id?{...e,...t.toast}:e))};case 2:let{toast:n}=t;return sp(e,{type:e.toasts.find((e=>e.id===n.id))?1:0,toast:n});case 3:let{toastId:r}=t;return{...e,toasts:e.toasts.map((e=>e.id===r||void 0===r?{...e,dismissed:!0,visible:!1}:e))};case 4:return void 0===t.toastId?{...e,toasts:[]}:{...e,toasts:e.toasts.filter((e=>e.id!==t.toastId))};case 5:return{...e,pausedAt:t.time};case 6:let o=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map((e=>({...e,pauseDuration:e.pauseDuration+o})))}}},lp=[],cp={toasts:[],pausedAt:void 0},up=e=>{cp=sp(cp,e),lp.forEach((e=>{e(cp)}))},dp={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},mp=e=>(t,n)=>{let r=((e,t="blank",n)=>({createdAt:Date.now(),visible:!0,dismissed:!1,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:(null==n?void 0:n.id)||ap()}))(t,e,n);return up({type:2,toast:r}),r.id},fp=(e,t)=>mp("blank")(e,t);fp.error=mp("error"),fp.success=mp("success"),fp.loading=mp("loading"),fp.custom=mp("custom"),fp.dismiss=e=>{up({type:3,toastId:e})},fp.remove=e=>up({type:4,toastId:e}),fp.promise=(e,t,n)=>{let r=fp.loading(t.loading,{...n,...null==n?void 0:n.loading});return"function"==typeof e&&(e=e()),e.then((e=>{let o=t.success?op(t.success,e):void 0;return o?fp.success(o,{id:r,...n,...null==n?void 0:n.success}):fp.dismiss(r),e})).catch((e=>{let o=t.error?op(t.error,e):void 0;o?fp.error(o,{id:r,...n,...null==n?void 0:n.error}):fp.dismiss(r)})),e};var pp=(e,t)=>{up({type:1,toast:{id:e,height:t}})},hp=()=>{up({type:5,time:Date.now()})},gp=new Map,yp=np` from { transform: scale(0) rotate(45deg); opacity: 0; } to { transform: scale(1) rotate(45deg); opacity: 1; }`,vp=np` from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; }`,bp=np` from { transform: scale(0) rotate(90deg); opacity: 0; } to { transform: scale(1) rotate(90deg); opacity: 1; }`,xp=rp("div")` width: 20px; opacity: 0; height: 20px; border-radius: 10px; background: ${e=>e.primary||"#ff4b4b"}; position: relative; transform: rotate(45deg); animation: ${yp} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; animation-delay: 100ms; &:after, &:before { content: ''; animation: ${vp} 0.15s ease-out forwards; animation-delay: 150ms; position: absolute; border-radius: 3px; opacity: 0; background: ${e=>e.secondary||"#fff"}; bottom: 9px; left: 4px; height: 2px; width: 12px; } &:before { animation: ${bp} 0.15s ease-out forwards; animation-delay: 180ms; transform: rotate(90deg); } `,Ep=np` from { transform: rotate(0deg); } to { transform: rotate(360deg); } `,_p=rp("div")` width: 12px; height: 12px; box-sizing: border-box; border: 2px solid; border-radius: 100%; border-color: ${e=>e.secondary||"#e0e0e0"}; border-right-color: ${e=>e.primary||"#616161"}; animation: ${Ep} 1s linear infinite; `,kp=np` from { transform: scale(0) rotate(45deg); opacity: 0; } to { transform: scale(1) rotate(45deg); opacity: 1; }`,Sp=np` 0% { height: 0; width: 0; opacity: 0; } 40% { height: 0; width: 6px; opacity: 1; } 100% { opacity: 1; height: 10px; }`,Np=rp("div")` width: 20px; opacity: 0; height: 20px; border-radius: 10px; background: ${e=>e.primary||"#61d345"}; position: relative; transform: rotate(45deg); animation: ${kp} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; animation-delay: 100ms; &:after { content: ''; box-sizing: border-box; animation: ${Sp} 0.2s ease-out forwards; opacity: 0; animation-delay: 200ms; position: absolute; border-right: 2px solid; border-bottom: 2px solid; border-color: ${e=>e.secondary||"#fff"}; bottom: 6px; left: 6px; height: 10px; width: 6px; } `,Cp=rp("div")` position: absolute; `,Pp=rp("div")` position: relative; display: flex; justify-content: center; align-items: center; min-width: 20px; min-height: 20px; `,Tp=np` from { transform: scale(0.6); opacity: 0.4; } to { transform: scale(1); opacity: 1; }`,jp=rp("div")` position: relative; transform: scale(0.6); opacity: 0.4; min-width: 20px; animation: ${Tp} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; `,Ap=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return void 0!==t?"string"==typeof t?s.createElement(jp,null,t):t:"blank"===n?null:s.createElement(Pp,null,s.createElement(_p,{...r}),"loading"!==n&&s.createElement(Cp,null,"error"===n?s.createElement(xp,{...r}):s.createElement(Np,{...r})))},Rp=e=>`\n0% {transform: translate3d(0,${-200*e}%,0) scale(.6); opacity:.5;}\n100% {transform: translate3d(0,0,0) scale(1); opacity:1;}\n`,Fp=e=>`\n0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}\n100% {transform: translate3d(0,${-150*e}%,-1px) scale(.6); opacity:0;}\n`,Dp=rp("div")` display: flex; align-items: center; background: #fff; color: #363636; line-height: 1.3; will-change: transform; box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05); max-width: 350px; pointer-events: auto; padding: 8px 10px; border-radius: 8px; `,Mp=rp("div")` display: flex; justify-content: center; margin: 4px 10px; color: inherit; flex: 1 1 auto; white-space: pre-line; `,Op=s.memo((({toast:e,position:t,style:n,children:r})=>{let o=e.height?((e,t)=>{let n=e.includes("top")?1:-1,[r,o]=ip()?["0%{opacity:0;} 100%{opacity:1;}","0%{opacity:1;} 100%{opacity:0;}"]:[Rp(n),Fp(n)];return{animation:t?`${np(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${np(o)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}})(e.position||t||"top-center",e.visible):{opacity:0},a=s.createElement(Ap,{toast:e}),i=s.createElement(Mp,{...e.ariaProps},op(e.message,e));return s.createElement(Dp,{className:e.className,style:{...o,...n,...e.style}},"function"==typeof r?r({icon:a,message:i}):s.createElement(s.Fragment,null,a,i))}));!function(e){Xf.p=void 0,Qf=e,ep=void 0,tp=void 0}(s.createElement);var Ip=({id:e,className:t,style:n,onHeightUpdate:r,children:o})=>{let a=s.useCallback((t=>{if(t){let n=()=>{let n=t.getBoundingClientRect().height;r(e,n)};n(),new MutationObserver(n).observe(t,{subtree:!0,childList:!0,characterData:!0})}}),[e,r]);return s.createElement("div",{ref:a,className:t,style:n},o)},Lp=Zf` z-index: 9999; > * { pointer-events: auto; } `,zp=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:o,containerStyle:a,containerClassName:i})=>{let{toasts:l,handlers:c}=(e=>{let{toasts:t,pausedAt:n}=((e={})=>{let[t,n]=(0,s.useState)(cp),r=(0,s.useRef)(cp);(0,s.useEffect)((()=>(r.current!==cp&&n(cp),lp.push(n),()=>{let e=lp.indexOf(n);e>-1&&lp.splice(e,1)})),[]);let o=t.toasts.map((t=>{var n,r,o;return{...e,...e[t.type],...t,removeDelay:t.removeDelay||(null==(n=e[t.type])?void 0:n.removeDelay)||(null==e?void 0:e.removeDelay),duration:t.duration||(null==(r=e[t.type])?void 0:r.duration)||(null==e?void 0:e.duration)||dp[t.type],style:{...e.style,...null==(o=e[t.type])?void 0:o.style,...t.style}}}));return{...t,toasts:o}})(e);(0,s.useEffect)((()=>{if(n)return;let e=Date.now(),r=t.map((t=>{if(t.duration===1/0)return;let n=(t.duration||0)+t.pauseDuration-(e-t.createdAt);if(!(n<0))return setTimeout((()=>fp.dismiss(t.id)),n);t.visible&&fp.dismiss(t.id)}));return()=>{r.forEach((e=>e&&clearTimeout(e)))}}),[t,n]);let r=(0,s.useCallback)((()=>{n&&up({type:6,time:Date.now()})}),[n]),o=(0,s.useCallback)(((e,n)=>{let{reverseOrder:r=!1,gutter:o=8,defaultPosition:a}=n||{},i=t.filter((t=>(t.position||a)===(e.position||a)&&t.height)),s=i.findIndex((t=>t.id===e.id)),l=i.filter(((e,t)=>te.visible)).slice(...r?[l+1]:[0,l]).reduce(((e,t)=>e+(t.height||0)+o),0)}),[t]);return(0,s.useEffect)((()=>{t.forEach((e=>{if(e.dismissed)((e,t=1e3)=>{if(gp.has(e))return;let n=setTimeout((()=>{gp.delete(e),up({type:4,toastId:e})}),t);gp.set(e,n)})(e.id,e.removeDelay);else{let t=gp.get(e.id);t&&(clearTimeout(t),gp.delete(e.id))}}))}),[t]),{toasts:t,handlers:{updateHeight:pp,startPause:hp,endPause:r,calculateOffset:o}}})(n);return s.createElement("div",{id:"_rht_toaster",style:{position:"fixed",zIndex:9999,top:16,left:16,right:16,bottom:16,pointerEvents:"none",...a},className:i,onMouseEnter:c.startPause,onMouseLeave:c.endPause},l.map((n=>{let a=n.position||t,i=((e,t)=>{let n=e.includes("top"),r=n?{top:0}:{bottom:0},o=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:ip()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...o}})(a,c.calculateOffset(n,{reverseOrder:e,gutter:r,defaultPosition:t}));return s.createElement(Ip,{id:n.id,key:n.id,onHeightUpdate:c.updateHeight,className:n.visible?Lp:"",style:i},"custom"===n.type?op(n.message,n):o?o(n):s.createElement(Op,{toast:n,position:a}))})))},Bp=fp,Vp=[{id:"1",title:(0,hm.__)("Option 1 (Recommended)","header-footer-elementor"),description:(0,hm.__)("This option will automatically replace your theme's header and footer files with custom templates from the plugin. It works with most themes and is selected by default.","header-footer-elementor"),value:"1"},{id:"2",title:(0,hm.__)("Option 2","header-footer-elementor"),description:(0,hm.__)("This option hides your theme's header and footer using CSS and displays custom templates from the plugin. Use this if Option 1 causes layout issues.","header-footer-elementor"),value:"2"}];const Up=function(){if("no"===hfeSettingsData.show_theme_support)return null;var e=i((0,s.useState)(hfeSettingsData.theme_option),2),t=e[0],n=e[1],r=i((0,s.useState)(!0),2),o=r[0],a=r[1];(0,s.useEffect)((function(){a(!1)}),[]);var l=function(e){var t=e.target.value;n(t),o||u(t)},u=function(){var e=uf(mf().mark((function e(t){var n;return mf().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,fetch(hfe_admin_data.ajax_url,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({action:"save_theme_compatibility_option",hfe_compatibility_option:t,nonce:hfe_admin_data.nonce})});case 3:return n=e.sent,e.next=6,n.json();case 6:e.sent.success?Bp.success((0,hm.__)("Settings saved successfully!","header-footer-elementor")):Bp.error((0,hm.__)("Failed to save settings!","header-footer-elementor")),e.next=13;break;case 10:e.prev=10,e.t0=e.catch(0),Bp.error((0,hm.__)("Failed to save settings!","header-footer-elementor"));case 13:case"end":return e.stop()}}),e,null,[[0,10]])})));return function(t){return e.apply(this,arguments)}}();return c().createElement(c().Fragment,null,c().createElement(Jm,{description:"",icon:null,iconPosition:"right",size:"sm",tag:"h2",title:(0,hm.__)("Theme Support","header-footer-elementor")}),c().createElement(nt,{align:"stretch",className:"bg-background-primary p-6 rounded-lg",containerType:"flex",direction:"column",gap:"sm",justify:"start",style:{marginTop:"24px",maxWidth:"696px"}},c().createElement(nt.Item,{className:"flex flex-col space-y-1"},c().createElement("p",{className:"text-base font-semibold m-0"},(0,hm.__)("Select Option to Add Theme Support","header-footer-elementor")),c().createElement("p",{className:"text-sm font-normal m-0"},(0,hm.__)("To ensure compatibility between the header/footer and your theme, please choose one of the following options to enable theme support:","header-footer-elementor"))),c().createElement(nt.Item,{className:"p-2 space-y-4",alignSelf:"auto",order:"none"},Vp.map((function(e){return c().createElement("div",{key:e.id,className:"flex items-start gap-1 justify-center cursor-pointer"},c().createElement("input",{id:e.id,value:e.value,type:"radio",className:"mt-1 cursor-pointer hfe-radio-field",name:"theme-support-option",onChange:l,checked:t===e.value}),c().createElement("div",{className:"flex flex-col cursor-pointer"},c().createElement(Bm,{size:"sm",variant:"neutral",className:"text-sm font-semibold text-text-secondary cursor-pointer flex flex-col items-start justify-start",htmlFor:e.id},e.title,":",c().createElement("p",{className:"m-0 text-sm font-normal text-text-secondary cursor-pointer"},e.description))))}))),c().createElement("div",{className:"flex items-center p-4 border rounded-lg text-start",style:{paddingTop:"16px",paddingBottom:"16px",backgroundColor:"#F3F0FF"}},c().createElement("p",{className:"m-0 text-sm"},c().createElement("strong",null,(0,hm.__)("Note:","header-footer-elementor"))," ",(0,hm.__)("If neither option works, please contact your theme author to add support for this plugin.","header-footer-elementor")))),c().createElement(zp,{position:"top-right",reverseOrder:!1,gutter:8,containerStyle:{top:20,right:20,marginTop:"80px"},toastOptions:{duration:5e3,style:{background:"white"},success:{duration:3e3,style:{color:""},iconTheme:{primary:"#6005ff",secondary:"#fff"}}}}))},Wp=function(){var e=hfeSettingsData.uaelite_versions,t=(0,s.useRef)(e?e[0].value:""),n=i((0,s.useState)(e?e[0].value:""),2),r=n[0],o=n[1],a=i((0,s.useState)("elementor-header-footer"),2),l=(a[0],a[1]),u=i((0,s.useState)(!1),2),d=u[0],m=u[1];return(0,s.useEffect)((function(){}),[d]),c().createElement(c().Fragment,null,c().createElement(Jm,{description:"",icon:null,iconPosition:"right",size:"sm",tag:"h2",title:(0,hm.__)("Version Control","header-footer-elementor")}),c().createElement("div",{className:"box-border bg-background-primary p-6 rounded-lg",style:{marginTop:"24px"}},c().createElement(nt,{align:"center",className:"flex flex-col lg:flex-row",containerType:"flex",direction:"column",gap:"sm",justify:"start"},c().createElement(nt.Item,{className:"shrink flex flex-col space-y-1"},c().createElement("p",{className:"text-base font-semibold m-0"},(0,hm.__)("Rollback to Previous Version","header-footer-elementor")),c().createElement("p",{className:"text-sm font-normal m-0"},(0,hm.__)("Experiencing an issue with current version? Roll back to a previous version to help troubleshoot the issue.","header-footer-elementor"))),c().createElement(nt.Item,{className:"p-2 flex space-y-4",alignSelf:"auto",order:"none"},c().createElement("div",{className:"bsf-rollback-version"},c().createElement("input",{type:"hidden",name:"product-name",id:"bsf-product-name",value:"header-footer-elementor"}),c().createElement("select",{id:"uaeliteVersionRollback",ref:t,onBlur:function(){l("elementor-header-footer")},onChange:function(e){o(e.target.value)},style:{padding:"8px",marginRight:"10px",marginTop:"16px",cursor:"pointer",borderRadius:"4px",height:"40px",width:"100px",outline:"none",boxShadow:"none"},onFocus:function(e){return e.target.style.borderColor="#6005FF"}},e.map((function(e){return c().createElement("option",{key:e.value,value:e.value},e.label)})))),c().createElement("div",{className:"flex flex-col cursor-pointer"},c().createElement(yf,{design:"simple",exitOnEsc:!0,scrollLock:!0,open:d,setOpen:m,trigger:c().createElement(ct,{style:{backgroundColor:"#6005ff"}},(0,hm.__)("Rollback","header-footer-elementor"))},c().createElement(yf.Backdrop,null),c().createElement(yf.Panel,null,c().createElement(yf.Header,null,c().createElement("div",{className:"flex items-center justify-between"},c().createElement(yf.Title,null,(0,hm.__)("Rollback to Previous Version","header-footer-elementor")),c().createElement(yf.CloseButton,null))),c().createElement(yf.Body,null,(0,hm.__)("Are you sure you want to rollback to Ultimate Addons for Elementor v".concat(r,"?"),"header-footer-elementor")),c().createElement(yf.Footer,null,c().createElement(ct,{onClick:function(){var e=hfeSettingsData.uaelite_rollback_url.replace("VERSION",r);m(!1),window.location.href=e}},(0,hm.__)("Rollback","header-footer-elementor")),c().createElement(ct,{onClick:function(){m(!1)}},(0,hm.__)("Cancel","header-footer-elementor"))))))))))},Hp=function(){var e=i((0,s.useState)(!0),2),t=e[0],n=e[1];(0,s.useEffect)((function(){n("yes"===hfeSettingsData.analytics_status)}),[]);var r=function(){var e=uf(mf().mark((function e(){var r,o;return mf().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n(r=!t),e.prev=2,e.next=5,fetch(hfe_admin_data.ajax_url,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({action:"save_analytics_option",uae_usage_optin:r?"yes":"no",nonce:hfe_admin_data.nonce})});case 5:return o=e.sent,e.next=8,o.json();case 8:e.sent.success?Bp.success((0,hm.__)("Settings saved successfully!","header-footer-elementor")):Bp.error((0,hm.__)("Failed to save settings!","header-footer-elementor")),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(2),Bp.error((0,hm.__)("Failed to save settings!","header-footer-elementor"));case 15:case"end":return e.stop()}}),e,null,[[2,12]])})));return function(){return e.apply(this,arguments)}}();return c().createElement(c().Fragment,null,c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginTop:"20px",marginBottom:"20px",borderColor:"#E5E7EB"}}),c().createElement(nt,{align:"center",className:"flex flex-col lg:flex-row",containerType:"flex",direction:"column",gap:"sm",justify:"start"},c().createElement(nt.Item,{className:"p-2 flex space-y-4",alignSelf:"auto",order:"none"},c().createElement("div",{className:"flex flex-row items-start justify-start px-1 gap-3"},c().createElement(Um,{onChange:r,size:"sm",value:t,className:"hfe-remove-ring"}),c().createElement("div",{className:"flex flex-col justify-start px-1 gap-3"},c().createElement("span",{className:"font-normal text-text-primary m-0"},(0,hm.__)("Help shape the future of Ultimate Addons for Elementor. Share how you use the plugin so we can build features that matter, fix issues faster, and make smarter decisions. ","header-footer-elementor"),c().createElement("a",{href:"https://store.brainstormforce.com/usage-tracking/?utm_source=wp_dashboard&utm_medium=general_settings&utm_campaign=usage_tracking",target:"_blank",rel:"noopener noreferrer",className:"text-link-primary"},(0,hm.__)("Learn More","header-footer-elementor")))),c().createElement(zp,{position:"top-right",reverseOrder:!1,gutter:8,containerStyle:{top:20,right:20,marginTop:"40px"},toastOptions:{duration:1e3,style:{background:"white"},success:{duration:2e3,style:{color:""},iconTheme:{primary:"#6005ff",secondary:"#fff"}}}})))))},$p=function(){return c().createElement(c().Fragment,null,c().createElement(Jm,{description:"",icon:null,iconPosition:"right",size:"sm",tag:"h2",title:(0,hm.__)("My Account","header-footer-elementor")}),c().createElement("div",{className:"",style:{marginTop:"24px"}},c().createElement(nt,{align:"stretch",className:"bg-background-primary p-6 rounded-lg",containerType:"flex",direction:"column",gap:"sm",justify:"start",style:{marginTop:"24px"}},c().createElement(nt.Item,{className:"flex flex-col space-y-2",style:{marginTop:"24px"}},c().createElement("p",{className:"text-base font-semibold m-0"},(0,hm.__)("License Key","header-footer-elementor")),c().createElement("p",{className:"text-sm font-normal m-0"},(0,hm.__)("You are using the free version of Ultimate Addons for Elementor, no license key is needed. "))),c().createElement("div",{className:"flex items-center justify-between px-4 rounded-xl",style:{paddingTop:"6px",paddingBottom:"6px",backgroundColor:"#F3F0FF"}},c().createElement("span",{className:"flex flex-col items-left mt-2 text-base font-semibold"},(0,hm.__)("Build Better Websites With Ultimate Addons Pro","header-footer-elementor"),c().createElement("p",{className:"text-sm font-normal m-0 py-2",style:{width:"500px"}},(0,hm.__)("Unlock advanced addons to power up Elementor - smarter widgets, smoother workflows, and more creative freedom with UAE Pro.","header-footer-elementor"))),c().createElement(ct,{icon:c().createElement(um,null),iconPosition:"right",variant:"link",style:{color:"#6005FF",borderColor:"#6005FF",transition:"color 0.3s ease, border-color 0.3s ease",fontSize:"16px"},className:"hfe-remove-ring text-[#6005FF]",onClick:function(){window.open("https://ultimateelementor.com/pricing/?utm_source=uae-lite-settings&utm_medium=My-accounts&utm_campaign=uae-lite-upgrade","_blank")}},(0,hm.__)("Upgrade Now","header-footer-elementor"))),c().createElement(Hp,null))))},qp=cm("lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]),Yp=cm("move-up-right",[["path",{d:"M13 5H19V11",key:"1n1gyv"}],["path",{d:"M19 5L5 19",key:"72u4yj"}]]);function Gp(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Xp(e){for(var t=1;t Add New > Upload Plugin, and activate.","header-footer-elementor")),c().createElement("a",{className:"hfe-ai-notice-btn text-sm font-semibold",href:"https://github.com/WordPress/mcp-adapter/releases/latest/download/mcp-adapter.zip",target:"_blank",rel:"noopener noreferrer"},(0,hm.__)("Download from GitHub","header-footer-elementor"))))},ph=function(e){var t=e.emphasized,n=e.icon,r=e.title,o=e.description,a=e.tag,i=e.locked,s=e.value,l=e.onChange,u=e.disabled,d=e.switchSize,m=void 0===d?"sm":d;return c().createElement("div",{className:"hfe-ai-trow ".concat(t?"is-emphasized":""," ").concat(i?"is-locked":"")},c().createElement("div",{className:"hfe-ai-trow-icon"},n),c().createElement("div",{className:"hfe-ai-trow-body"},c().createElement("div",{className:"hfe-ai-trow-title hfe-ai-c-ink font-semibold ".concat(t?"text-base":"text-sm")},r,"write"===a&&c().createElement("span",{className:"hfe-ai-tag is-write text-xxs font-semibold"},(0,hm.__)("Write","header-footer-elementor")),"read"===a&&c().createElement("span",{className:"hfe-ai-tag is-read text-xxs font-semibold"},(0,hm.__)("Read","header-footer-elementor")),i&&c().createElement(qp,{size:12,className:"hfe-ai-c-muted"})),c().createElement("div",{className:"hfe-ai-trow-desc hfe-ai-c-muted text-sm"},o)),c().createElement(Um,{size:m,value:!!s,onChange:l,disabled:u,"aria-label":"string"==typeof r?r:void 0}))},hh=function(e){var t=e.active,n=e.onClick,r=e.children;return c().createElement("button",{onClick:n,className:"hfe-ai-tab text-sm ".concat(t?"is-active font-semibold":"font-medium")},r)},gh=function(e){var t=e.active,n=e.onClick,r=e.count,o=e.children;return c().createElement("button",{onClick:n,className:"hfe-ai-fchip text-xs ".concat(t?"is-active":"")},o,c().createElement("span",{className:"hfe-ai-fchip-count text-xxs"},r))},yh=function(e){var t=e.active,n=e.onClick,r=e.children;return c().createElement("button",{onClick:n,className:"hfe-ai-scope-btn text-sm ".concat(t?"is-active font-semibold":"font-medium")},r)},vh=function(e){var t=e.readonly;return c().createElement("span",{className:"hfe-ai-tag text-xxs font-semibold ".concat(t?"is-read":"is-write")},t?(0,hm.__)("Read","header-footer-elementor"):(0,hm.__)("Write","header-footer-elementor"))};const bh=function(){var e,t,n,r,o,a=window.hfeSettingsData||{},l=a.mcp_settings||{},u=a.is_abilities_api_active,d=a.is_mcp_adapter_active,m=a.is_angie_active,f=a.site_url||window.location.origin,p=a.current_user||"admin",g=a.rest_url||f.replace(/\/$/,"")+"/wp-json/",y=a.application_passwords_url||f+"/wp-admin/profile.php#application-passwords-section",v=i((0,s.useState)({enable_abilities:null!==(e=l.enable_abilities)&&void 0!==e&&e,allow_modifications:null===(t=l.allow_modifications)||void 0===t||t,dedicated_server:null!==(n=l.dedicated_server)&&void 0!==n&&n,angie_enabled:null!==(r=l.angie_enabled)&&void 0!==r&&r,disabled_abilities:null!==(o=l.disabled_abilities)&&void 0!==o?o:[]}),2),b=v[0],x=v[1],w=(0,s.useRef)(b);(0,s.useEffect)((function(){w.current=b}),[b]);var E=i((0,s.useState)(!1),2),_=(E[0],E[1]),k=i((0,s.useState)([]),2),S=k[0],N=k[1],C=i((0,s.useState)({}),2),P=C[0],T=C[1],j=i((0,s.useState)("overview"),2),A=j[0],R=j[1],F=i((0,s.useState)("uae-only"),2),D=F[0],M=F[1],O=i((0,s.useState)(!1),2),I=O[0],L=O[1],z=i((0,s.useState)(!1),2),B=z[0],V=z[1],U=i((0,s.useState)(""),2),W=U[0],H=U[1],$=i((0,s.useState)("all"),2),q=$[0],Y=$[1];(0,s.useEffect)((function(){$m()({path:"/hfe/v1/mcp-abilities",headers:{"X-WP-Nonce":a.hfe_nonce_action}}).then((function(e){Array.isArray(e)&&N(e)})).catch((function(){}))}),[]),(0,s.useEffect)((function(){"server"!==A||b.enable_abilities&&b.dedicated_server||R("overview")}),[A,b.enable_abilities,b.dedicated_server]);var G={"hfe-info":(0,hm.__)("Plugin Info","header-footer-elementor"),"hfe-active-templates":(0,hm.__)("Active Templates","header-footer-elementor"),"hfe-templates":(0,hm.__)("Templates & Builder","header-footer-elementor"),"hfe-pages":(0,hm.__)("Pages","header-footer-elementor"),"hfe-widgets":(0,hm.__)("Widgets","header-footer-elementor"),"hfe-extensions":(0,hm.__)("Extensions","header-footer-elementor"),"hfe-display-rules":(0,hm.__)("Display Rules","header-footer-elementor"),"hfe-theme-compat":(0,hm.__)("Theme","header-footer-elementor"),"hfe-settings":(0,hm.__)("Settings","header-footer-elementor"),"hfe-shortcodes":(0,hm.__)("Shortcode","header-footer-elementor"),"hfe-design":(0,hm.__)("Design System","header-footer-elementor"),"hfe-maintenance":(0,hm.__)("Maintenance","header-footer-elementor"),"hfe-pro":(0,hm.__)("Pro Features","header-footer-elementor"),"uael-info":(0,hm.__)("Pro Plugin Info","header-footer-elementor"),"uael-skins":(0,hm.__)("Post Skins","header-footer-elementor"),"uael-settings":(0,hm.__)("Integrations & Branding","header-footer-elementor")},X={"hfe-info":(0,hm.__)("Plugin version, health, and compatibility info","header-footer-elementor"),"hfe-active-templates":(0,hm.__)("See which header/footer is active on any page","header-footer-elementor"),"hfe-templates":(0,hm.__)("Create, edit, and manage templates and page layouts","header-footer-elementor"),"hfe-pages":(0,hm.__)("Create and manage WordPress pages","header-footer-elementor"),"hfe-widgets":(0,hm.__)("Activate, deactivate, and list available widgets","header-footer-elementor"),"hfe-extensions":(0,hm.__)("Toggle Scroll to Top and Reading Progress Bar","header-footer-elementor"),"hfe-display-rules":(0,hm.__)("Control where templates appear on your site","header-footer-elementor"),"hfe-theme-compat":(0,hm.__)("Theme detection and compatibility settings","header-footer-elementor"),"hfe-settings":(0,hm.__)("Read and update plugin configuration","header-footer-elementor"),"hfe-shortcodes":(0,hm.__)("Render template shortcodes","header-footer-elementor"),"hfe-design":(0,hm.__)("Get site colors, fonts, and spacing","header-footer-elementor"),"hfe-maintenance":(0,hm.__)("Clear caches and run maintenance tasks","header-footer-elementor"),"hfe-pro":(0,hm.__)("UAE Pro upgrade information and pricing","header-footer-elementor")},K=(0,s.useMemo)((function(){var e={};return S.forEach((function(t){var n=t.category||"other";e[n]||(e[n]=[]),e[n].push(t)})),e}),[S]),J=(0,s.useMemo)((function(){return S.filter((function(e){return e.readonly})).length}),[S]),Z=S.length-J,Q=function(e){return!(!b.enable_abilities||!e.readonly&&!b.allow_modifications||b.disabled_abilities.includes(e.name))},ee=(0,s.useMemo)((function(){return S.filter(Q).length}),[S,b.enable_abilities,b.allow_modifications,b.disabled_abilities]),te=function(e){return(K[e]||[]).every((function(e){return!b.disabled_abilities.includes(e.name)}))},ne=(0,s.useRef)(Promise.resolve()),re=(0,s.useRef)(b),oe=(0,s.useRef)(0),ae=function(){var e=uf(mf().mark((function e(t,n){var r,o;return mf().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return _(!0),e.prev=1,e.next=4,$m()({path:"/hfe/v1/mcp-settings",method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":a.hfe_nonce_action},body:JSON.stringify(t)});case 4:if((r=e.sent)&&r.success){e.next=7;break}throw new Error(r&&r.message?r.message:"save_failed");case 7:re.current=t,Bp.success((0,hm.__)("Settings saved.","header-footer-elementor")),e.next=15;break;case 11:e.prev=11,e.t0=e.catch(1),n===oe.current&&(o=lh({},re.current),w.current=o,x(o)),Bp.error((0,hm.__)("Failed to save settings.","header-footer-elementor"));case 15:return e.prev=15,_(!1),e.finish(15);case 18:case"end":return e.stop()}}),e,null,[[1,11,15,18]])})));return function(t,n){return e.apply(this,arguments)}}(),ie=function(e){var t=++oe.current;return ne.current=ne.current.then((function(){return ae(e,t)}),(function(){return ae(e,t)})),ne.current},se=function(e,t){var n=lh(lh({},w.current),{},h({},e,t));w.current=n,x(n),ie(n)},le=(0,s.useMemo)((function(){try{return new URL(g).hostname.replace(/[^a-zA-Z0-9-]/g,"-")}catch(e){return"site"}}),[g]),ce="uae-only"===D,ue="".concat(le,ce?"-uae":"-global"),de="".concat(g,ce?"uae/mcp":"mcp/mcp-adapter-default-server"),me={command:"npx",args:["-y","@automattic/mcp-wordpress-remote@latest"],env:{WP_API_URL:de,WP_API_USERNAME:p,WP_API_PASSWORD:"your-application-password"}},fe=JSON.stringify({mcpServers:h({},ue,me)},null,2),pe=JSON.stringify(h({},ue,me),null,2),he="Add this MCP server to my AI client so I can connect to my WordPress site:\n".concat(pe,"\n\nSteps:\n1. Ask which AI client I use if unsure (Claude Code, Claude Desktop, Cursor, Windsurf, VS Code, ChatGPT, etc.) and what OS I'm on (macOS, Windows, Linux) — both are needed to locate the correct config file.\n\n2. Ask for my Application Password upfront (before proceeding to any other steps). The placeholder in the JSON above says \"your-application-password\" — replace it with what I provide. If I don't have one, direct me to:\n ").concat(y,"\n\n3. If using ChatGPT:\n Go to Settings → Connectors → Add Connector and paste this URL as the Connector URL:\n ").concat(de,"\n\n Use HTTP Basic Auth with my WordPress username and an Application Password.\n\n If I don't have an Application Password, direct me to:\n ").concat(y,'\n\n See also:\n https://developers.openai.com/apps-sdk/deploy/connect-chatgpt\n\n Skip steps 4–8.\n\n4. Locate the correct MCP config file for my client and OS. Verify the path exists on my system — do not guess. If it doesn\'t exist, confirm the path with me before creating.\n\n5. Merge into existing config if present — do NOT overwrite other MCP server entries. For VS Code, use "servers" key instead of "mcpServers".\n\n6. Detect my Node.js setup by running:\n which npx && node --version && echo $PATH\n\n - If you can run terminal commands directly (e.g. Claude Code, Cursor, Windsurf, VS Code agent), run this yourself.\n - If you are sandboxed and cannot run terminal commands (e.g. Claude Desktop, ChatGPT), ask me to run it and paste the output back.\n - Requires Node.js v20 or v22. If below v20 or v23+, warn me and stop.\n - Set "command" to the full npx path from "which npx" — never use a path from your own environment.\n - Add "PATH" to "env" using the actual $PATH output — include the node bin directory, Homebrew paths (/opt/homebrew/bin, /usr/local/bin), and system paths.\n - MCP servers don\'t inherit the user\'s shell PATH, so include everything needed for node, npx, and git.\n\n7. If you\'re sandboxed (e.g. Claude Desktop) and can\'t write to the real filesystem, don\'t write to a sandbox path. Instead, output the final JSON in a code block with the file path so I can save it manually.\n\n8. Verify the final JSON is valid and confirm what was added.'),ge=function(e){if("read"===q&&!e.readonly)return!1;if("write"===q&&e.readonly)return!1;if(W){var t=W.toLowerCase();return(e.label||"").toLowerCase().includes(t)||(e.description||"").toLowerCase().includes(t)||e.name.toLowerCase().includes(t)}return!0};if(!u)return c().createElement("div",{className:"hfe-ai-tools hfe-ai-empty"},c().createElement(Jm,{description:"",icon:null,iconPosition:"right",size:"sm",tag:"h2",title:(0,hm.__)("AI Tools","header-footer-elementor")}),c().createElement("div",{className:"hfe-ai-empty-note text-sm"},c().createElement("strong",{className:"hfe-ai-c-ink"},(0,hm.__)("Requires WordPress 6.8+","header-footer-elementor"))," ",(0,hm.__)("AI Tools requires WordPress 6.8 or later, which includes the Abilities API.","header-footer-elementor")),c().createElement(zp,{position:"top-right"}));var ye=b.enable_abilities,ve=ye&&b.dedicated_server,be=ye&&b.allow_modifications,xe=ye&&b.angie_enabled&&m,we=S.length?Math.round(ee/S.length*100):0;return c().createElement("div",{className:"hfe-ai-tools"},c().createElement("div",{className:"hfe-ai-header"},c().createElement("div",null,c().createElement(Jm,{description:"",icon:null,iconPosition:"right",size:"sm",tag:"h2",title:(0,hm.__)("AI Tools","header-footer-elementor")}),c().createElement("div",{className:"hfe-ai-badges"},ye?c().createElement(dh,{tone:"ok",dot:!0},(0,hm.__)("Abilities enabled","header-footer-elementor")):c().createElement(dh,{tone:"neutral",dot:!0},(0,hm.__)("Abilities disabled","header-footer-elementor")),c().createElement(dh,{tone:"neutral",dot:!0,dotClass:ye?"is-blue":"is-grey"},(0,hm.sprintf)((0,hm.__)("%1$d / %2$d abilities","header-footer-elementor"),ye?ee:0,S.length||0)))),c().createElement("button",{onClick:function(){var e={enable_abilities:!1,allow_modifications:!0,dedicated_server:!1,angie_enabled:!1,disabled_abilities:[]};w.current=e,x(e),ie(e),R("overview")},disabled:!1,className:"hfe-ai-reset text-xs font-medium"},c().createElement(Jp,{size:14}),(0,hm.__)("Reset to defaults","header-footer-elementor"))),c().createElement(ch,null,c().createElement(uh,{title:(0,hm.__)("Settings","header-footer-elementor"),description:(0,hm.__)("Control how UAE registers AI tools with WordPress and exposes them to clients.","header-footer-elementor")}),c().createElement("div",null,c().createElement(ph,{emphasized:!0,icon:c().createElement(Zp,{size:18}),title:(0,hm.__)("Enable Abilities","header-footer-elementor"),description:(0,hm.__)("Register UAE AI tools with WordPress so they can be used by MCP clients (such as Claude, Cursor, and VS Code) and Elementor's Angie assistant. Disabled by default — enable this option to expose AI tools.","header-footer-elementor"),value:b.enable_abilities,onChange:function(e){return se("enable_abilities",e)}}),c().createElement(ph,{icon:c().createElement(Qp,{size:18}),title:(0,hm.__)("Enable Edit Abilities","header-footer-elementor"),tag:"write",locked:!ye,description:(0,hm.__)("When enabled, AI clients can create, edit, and delete templates, pages, and widget settings. When disabled, AI clients have read-only access to your data.","header-footer-elementor"),value:b.allow_modifications,onChange:function(e){return se("allow_modifications",e)},disabled:!ye}),c().createElement(ph,{icon:c().createElement(eh,{size:18}),title:(0,hm.__)("Enable MCP Server","header-footer-elementor"),locked:!ye,description:(0,hm.__)("Creates a dedicated UAE MCP endpoint that AI clients like Claude, Cursor, and VS Code can connect to. When disabled, the endpoint is removed and external AI clients cannot discover or call any UAE abilities.","header-footer-elementor"),value:b.dedicated_server,onChange:function(e){return se("dedicated_server",e)},disabled:!ye}),c().createElement(ph,{icon:c().createElement(th,{size:18}),title:(0,hm.__)("Angie Integration","header-footer-elementor"),locked:!ye||!m,description:m?(0,hm.__)("Enable UAE abilities within Elementor's Angie AI assistant so it can use them in-browser without an external MCP client.","header-footer-elementor"):(0,hm.__)("Install and activate the Angie plugin to use in-browser AI.","header-footer-elementor"),value:b.angie_enabled&&m,onChange:function(e){return se("angie_enabled",e)},disabled:!ye||!m}))),ye&&c().createElement(c().Fragment,null,c().createElement("div",{className:"hfe-ai-tabs"},c().createElement(hh,{active:"overview"===A,onClick:function(){return R("overview")}},(0,hm.__)("Overview","header-footer-elementor")),c().createElement(hh,{active:"abilities"===A,onClick:function(){return R("abilities")}},(0,hm.__)("Abilities","header-footer-elementor"),c().createElement("span",{className:"hfe-ai-tab-count text-xxs font-semibold ".concat("abilities"===A?"is-active":"")},S.length)),ve&&c().createElement(hh,{active:"server"===A,onClick:function(){return R("server")}},(0,hm.__)("Server & Connect","header-footer-elementor"))),"overview"===A&&c().createElement(ch,null,c().createElement(uh,{title:(0,hm.__)("Connection status","header-footer-elementor"),description:(0,hm.__)("How AI clients reach your site right now","header-footer-elementor")}),c().createElement("div",{className:"hfe-ai-connbanner ".concat(ye?"is-active":"is-off")},c().createElement("span",{className:"hfe-ai-connbanner-dot"}),c().createElement("div",{className:"hfe-ai-connbanner-main"},c().createElement("div",{className:"hfe-ai-connbanner-title text-sm font-semibold"},ye?(0,hm.__)("AI Tools are active","header-footer-elementor"):(0,hm.__)("AI Tools are off","header-footer-elementor")),c().createElement("div",{className:"hfe-ai-connbanner-sub text-xs"},ye?(0,hm.sprintf)((0,hm.__)("%1$s · %2$s · %3$d of %4$d abilities exposed","header-footer-elementor"),ve?(0,hm.__)("MCP server on","header-footer-elementor"):(0,hm.__)("MCP server off","header-footer-elementor"),be?(0,hm.__)("Read & write","header-footer-elementor"):(0,hm.__)("Read-only","header-footer-elementor"),ee,S.length):(0,hm.__)("Enable “Enable Abilities” above to connect AI clients.","header-footer-elementor")))),c().createElement("div",{className:"hfe-ai-conngrid"},c().createElement("div",{className:"hfe-ai-conncard"},c().createElement("div",{className:"hfe-ai-conncard-head"},c().createElement("span",{className:"hfe-ai-conncard-title text-sm font-semibold"},(0,hm.__)("External MCP server","header-footer-elementor")),c().createElement("span",{className:"hfe-ai-pill ".concat(ve?"is-ok":"is-muted")},ve?(0,hm.__)("Ready","header-footer-elementor"):(0,hm.__)("Server off","header-footer-elementor"))),ve?c().createElement(c().Fragment,null,c().createElement("div",{className:"hfe-ai-conncard-endpoint"},c().createElement("span",{className:"is-mono text-xs"},de),c().createElement("button",{onClick:function(){navigator.clipboard.writeText(de).then((function(){Bp.success((0,hm.__)("Endpoint copied to clipboard","header-footer-elementor"))}))},className:"hfe-ai-iconbtn","aria-label":(0,hm.__)("Copy endpoint","header-footer-elementor")},c().createElement(nh,{size:13}))),c().createElement("button",{onClick:function(){return R("server")},className:"hfe-ai-connlink text-xs font-medium"},(0,hm.__)("Connect a client","header-footer-elementor")," ",c().createElement(rh,{size:13}))):c().createElement("div",{className:"hfe-ai-conncard-hint text-xs"},(0,hm.__)("Turn on Enable MCP Server above to expose the endpoint.","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-conncard"},c().createElement("div",{className:"hfe-ai-conncard-head"},c().createElement("span",{className:"hfe-ai-conncard-title text-sm font-semibold"},(0,hm.__)("Angie (in-editor)","header-footer-elementor")),c().createElement("span",{className:"hfe-ai-pill ".concat(xe?"is-ok":"is-muted")},m?xe?(0,hm.__)("Enabled","header-footer-elementor"):(0,hm.__)("Disabled","header-footer-elementor"):(0,hm.__)("Not installed","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-conncard-hint text-xs"},m?xe?(0,hm.__)("UAE tools are available in Elementor’s in-browser AI.","header-footer-elementor"):(0,hm.__)("Turn on Angie Integration above to use it in the editor.","header-footer-elementor"):(0,hm.__)("Install the Angie plugin to use in-browser AI.","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-conncard"},c().createElement("div",{className:"hfe-ai-conncard-head"},c().createElement("span",{className:"hfe-ai-conncard-title text-sm font-semibold"},(0,hm.__)("Abilities exposed","header-footer-elementor")),c().createElement("span",{className:"hfe-ai-conncard-count text-sm font-bold"},ye?ee:0,c().createElement("span",{className:"hfe-ai-c-muted text-xs font-medium"}," / ",S.length))),c().createElement("div",{className:"hfe-ai-progress-track",style:{marginBottom:"10px"}},c().createElement("div",{className:"hfe-ai-progress-bar",style:{width:"".concat(ye?we:0,"%")}})),c().createElement("button",{onClick:function(){return R("abilities")},className:"hfe-ai-connlink text-xs font-medium"},(0,hm.__)("Manage abilities","header-footer-elementor")," ",c().createElement(rh,{size:13}))),c().createElement("div",{className:"hfe-ai-conncard"},c().createElement("div",{className:"hfe-ai-conncard-head"},c().createElement("span",{className:"hfe-ai-conncard-title text-sm font-semibold"},(0,hm.__)("Access mode","header-footer-elementor")),c().createElement("span",{className:"hfe-ai-pill ".concat(be?"is-brand":"is-muted")},be?(0,hm.__)("Read & write","header-footer-elementor"):(0,hm.__)("Read-only","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-conncard-hint text-xs"},be?(0,hm.__)("AI can create, edit and delete. Toggle “Enable Edit Abilities” above for read-only.","header-footer-elementor"):(0,hm.__)("AI can only read your data. Toggle “Enable Edit Abilities” above to allow changes.","header-footer-elementor")))),ye&&c().createElement("div",{className:"hfe-ai-connactions"},c().createElement("a",{href:y,target:"_blank",rel:"noreferrer",className:"hfe-ai-connbtn text-xs font-medium"},c().createElement(oh,{size:13})," ",(0,hm.__)("Create application password","header-footer-elementor")),ve&&c().createElement("button",{onClick:function(){return R("server")},className:"hfe-ai-connbtn text-xs font-medium"},c().createElement(eh,{size:13})," ",(0,hm.__)("Server & connect","header-footer-elementor")))),"abilities"===A&&c().createElement(ch,null,c().createElement(uh,{title:(0,hm.__)("Ability toggles","header-footer-elementor"),description:(0,hm.__)("Choose exactly which actions AI tools are allowed to perform","header-footer-elementor"),right:c().createElement(mh,{tone:"ok"},(0,hm.sprintf)((0,hm.__)("%1$d of %2$d enabled","header-footer-elementor"),ee,S.length))}),c().createElement("div",{className:"hfe-ai-toolbar"},c().createElement("div",{className:"hfe-ai-search"},c().createElement(Rf,{size:14,className:"hfe-ai-c-muted"}),c().createElement("input",{value:W,onChange:function(e){return H(e.target.value)},"aria-label":(0,hm.__)("Search abilities","header-footer-elementor"),placeholder:(0,hm.__)("Search abilities - e.g. template, widget, page …","header-footer-elementor"),className:"hfe-ai-search-input text-sm"})),c().createElement("div",{className:"hfe-ai-filters"},c().createElement(gh,{active:"all"===q,onClick:function(){return Y("all")},count:S.length},(0,hm.__)("All","header-footer-elementor")),c().createElement(gh,{active:"read"===q,onClick:function(){return Y("read")},count:J},(0,hm.__)("Read","header-footer-elementor")),c().createElement(gh,{active:"write"===q,onClick:function(){return Y("write")},count:Z},(0,hm.__)("Write","header-footer-elementor"))),c().createElement("button",{onClick:function(){var e=Object.keys(K),t=e.every((function(e){return P[e]}));T(t?{}:Object.fromEntries(e.map((function(e){return[e,!0]}))))},className:"hfe-ai-expand text-sm font-medium"},Object.keys(K).every((function(e){return P[e]}))?(0,hm.__)("Collapse all","header-footer-elementor"):(0,hm.__)("Expand all","header-footer-elementor"))),Object.entries(K).map((function(e){var t=i(e,2),n=t[0],r=t[1],o=r.filter(ge);if(0===o.length)return null;var a=!!P[n],s=function(e){return e.filter((function(e){return!b.disabled_abilities.includes(e.name)})).length}(r);return c().createElement("div",{key:n,className:"hfe-ai-group"},c().createElement("div",{className:"hfe-ai-group-head"},c().createElement("button",{type:"button",className:"hfe-ai-group-toggle","aria-expanded":a,"aria-controls":"hfe-ai-group-".concat(n),onClick:function(){return T((function(e){return lh(lh({},e),{},h({},n,!e[n]))}))}},c().createElement(rh,{size:12,className:"hfe-ai-group-chevron ".concat(a?"is-open":"")}),c().createElement("div",{className:"hfe-ai-group-letter text-xs font-bold"},(G[n]||n).charAt(0)),c().createElement("div",{className:"hfe-ai-group-info"},c().createElement("div",{className:"hfe-ai-c-ink text-sm font-semibold"},G[n]||n,c().createElement("span",{className:"hfe-ai-c-muted text-xs font-medium",style:{marginLeft:6}},(0,hm.sprintf)((0,hm.__)("%d abilities","header-footer-elementor"),r.length))),X[n]&&c().createElement("div",{className:"hfe-ai-c-muted text-xs"},X[n])),c().createElement(mh,{tone:s===r.length?"ok":"muted"},s,"/",r.length," ",(0,hm.__)("on","header-footer-elementor"))),c().createElement(Um,{size:"sm",value:te(n),onChange:function(e){return function(e,t){var n=(K[e]||[]).map((function(e){return e.name})),r=Cm(w.current.disabled_abilities);t?r=r.filter((function(e){return!n.includes(e)})):n.forEach((function(e){r.includes(e)||r.push(e)}));var o=lh(lh({},w.current),{},{disabled_abilities:r});w.current=o,x(o),ie(o)}(n,e)},disabled:!1,"aria-label":(0,hm.sprintf)((0,hm.__)("Toggle all %s abilities","header-footer-elementor"),G[n]||n)})),a&&c().createElement("div",{id:"hfe-ai-group-".concat(n)},o.map((function(e){return c().createElement("div",{key:e.name,className:"hfe-ai-arow"},c().createElement("div",null,c().createElement("div",{className:"hfe-ai-arow-title hfe-ai-c-ink text-sm font-semibold"},e.label||e.name,c().createElement(vh,{readonly:e.readonly})),c().createElement("div",{className:"hfe-ai-c-muted text-xs"},e.description)),c().createElement("span",null),c().createElement(Um,{size:"sm",value:Q(e),onChange:function(t){return function(e,t){var n=Cm(w.current.disabled_abilities);t?n=n.filter((function(t){return t!==e})):n.includes(e)||n.push(e);var r=lh(lh({},w.current),{},{disabled_abilities:n});w.current=r,x(r),ie(r)}(e.name,t)},disabled:!e.readonly&&!b.allow_modifications,"aria-label":(0,hm.sprintf)((0,hm.__)("Toggle %s","header-footer-elementor"),e.label||e.name)}))}))))}))),"server"===A&&ve&&c().createElement(c().Fragment,null,!d&&c().createElement(fh,null),c().createElement(ch,null,c().createElement(uh,{title:(0,hm.__)("Connect your AI client","header-footer-elementor"),description:d?(0,hm.__)("UAE's MCP endpoint is live. Wire it into your AI tool below.","header-footer-elementor"):(0,hm.__)("Once the WP MCP Adapter plugin is active, this is how you connect your AI client.","header-footer-elementor"),right:d?c().createElement(mh,{tone:"ok"},(0,hm.__)("Endpoint live","header-footer-elementor")):c().createElement(mh,{tone:"muted"},(0,hm.__)("Setup required","header-footer-elementor"))}),c().createElement("div",{className:"hfe-ai-panel"},c().createElement("ol",{className:"hfe-ai-steps text-sm"},c().createElement("li",null,(0,hm.__)("Create an Application Password","header-footer-elementor")," — ",c().createElement("a",{href:y,target:"_blank",rel:"noopener noreferrer",className:"hfe-ai-link"},(0,hm.__)("Open Application Passwords","header-footer-elementor"),c().createElement(oh,{size:13}))),c().createElement("li",null,(0,hm.__)("Add to your AI client:","header-footer-elementor")," ",c().createElement("a",{href:"https://developer.wordpress.org/news/2026/02/from-abilities-to-ai-agents-introducing-the-wordpress-mcp-adapter/",target:"_blank",rel:"noopener noreferrer",className:"hfe-ai-link"},(0,hm.__)("Learn More","header-footer-elementor"),c().createElement(oh,{size:13})),c().createElement("ul",{className:"hfe-ai-substeps"},c().createElement("li",null,c().createElement("strong",null,(0,hm.__)("Claude Code","header-footer-elementor")),": ",c().createElement("code",{className:"hfe-ai-inlinecode text-xs"},".mcp.json")),c().createElement("li",null,c().createElement("strong",null,(0,hm.__)("Claude Desktop","header-footer-elementor")),": ",c().createElement("code",{className:"hfe-ai-inlinecode text-xs"},"claude_desktop_config.json")),c().createElement("li",null,c().createElement("strong",null,(0,hm.__)("Cursor","header-footer-elementor")),": ",c().createElement("code",{className:"hfe-ai-inlinecode text-xs"},".cursor/mcp.json")),c().createElement("li",null,c().createElement("strong",null,(0,hm.__)("VS Code","header-footer-elementor")),": ",c().createElement("code",{className:"hfe-ai-inlinecode text-xs"},".vscode/mcp.json")),c().createElement("li",null,c().createElement("strong",null,(0,hm.__)("ChatGPT","header-footer-elementor")),": ",(0,hm.__)("go to Settings → Connectors → Add Connector, paste the endpoint URL, and use your WordPress username + Application Password.","header-footer-elementor")))),c().createElement("li",null,(0,hm.__)("Replace","header-footer-elementor")," ",c().createElement("code",{className:"hfe-ai-inlinecode text-xs"},'"your-application-password"')," ",(0,hm.__)("in the JSON with the password from Step 1.","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-scope"},c().createElement(yh,{active:"uae-only"===D,onClick:function(){return M("uae-only")}},(0,hm.__)("UAE Only","header-footer-elementor")),c().createElement(yh,{active:"global"===D,onClick:function(){return M("global")}},(0,hm.__)("Global","header-footer-elementor"))),c().createElement("div",{className:"hfe-ai-code"},c().createElement("div",{className:"hfe-ai-code-actions"},c().createElement(zm,{content:(0,hm.__)("Copy setup prompt for AI client","header-footer-elementor"),delay:50,arrow:!0},c().createElement("button",{onClick:function(){navigator.clipboard.writeText(he).then((function(){V(!0),Bp.success((0,hm.__)("Prompt copied! Paste it into your AI client.","header-footer-elementor")),setTimeout((function(){return V(!1)}),2e3)}))},className:"hfe-ai-iconbtn","aria-label":(0,hm.__)("Copy setup prompt","header-footer-elementor")},B?c().createElement(sf,{size:14,color:"#95E1A0"}):c().createElement(ah,{size:14}))),c().createElement(zm,{content:(0,hm.__)("Copy JSON config","header-footer-elementor"),delay:50,arrow:!0},c().createElement("button",{onClick:function(){navigator.clipboard.writeText(fe).then((function(){L(!0),Bp.success((0,hm.__)("Copied to clipboard","header-footer-elementor")),setTimeout((function(){return L(!1)}),2e3)}))},className:"hfe-ai-iconbtn","aria-label":(0,hm.__)("Copy JSON config","header-footer-elementor")},I?c().createElement(sf,{size:14,color:"#95E1A0"}):c().createElement(nh,{size:14})))),c().createElement("pre",{className:"hfe-ai-code-pre text-xs"},fe)))))),c().createElement(zp,{position:"top-right",reverseOrder:!1,gutter:8,containerStyle:{top:20,right:20,marginTop:80},toastOptions:{duration:5e3,style:{background:"white"},success:{duration:3e3,iconTheme:{primary:"#6005ff",secondary:"#fff"}}}}))},xh=function(){var e=[{id:1,icon:c().createElement("img",{src:"".concat(hfeSettingsData.user_url),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),selected:c().createElement("img",{src:"".concat(hfeSettingsData.user__selected_url),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),title:(0,hm.__)("My Account","header-footer-elementor"),content:c().createElement($p,null)},{id:2,icon:c().createElement("img",{src:"".concat(hfeSettingsData.theme_url),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),selected:c().createElement("img",{src:"".concat(hfeSettingsData.theme_url_selected),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),main:(0,hm.__)("Editor","header-footer-elementor"),title:(0,hm.__)("Theme Support","header-footer-elementor"),content:c().createElement(Up,null)},{id:3,icon:c().createElement("img",{src:"".concat(hfeSettingsData.version_url),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),selected:c().createElement("img",{src:"".concat(hfeSettingsData.version__selected_url),alt:(0,hm.__)("Custom SVG","header-footer-elementor"),className:"object-contain"}),main:(0,hm.__)("Utilities","header-footer-elementor"),title:(0,hm.__)("Version Control","header-footer-elementor"),content:c().createElement(Wp,null)},{id:4,icon:c().createElement("img",{src:"".concat(hfeSettingsData.branding_url),alt:"Custom SVG",className:"object-contain"}),selected:c().createElement("img",{src:"".concat(hfeSettingsData.branding__selected_url),alt:"Custom SVG",className:"object-contain"}),main:"",title:(0,hm.__)("White Label","header-footer-elementor"),content:c().createElement(Kp,null)},{id:5,icon:c().createElement("img",{src:"".concat(hfeSettingsData.ai_tools_url),alt:(0,hm.__)("AI Tools","header-footer-elementor"),className:"object-contain"}),selected:c().createElement("img",{src:"".concat(hfeSettingsData.ai_tools__selected_url),alt:(0,hm.__)("AI Tools","header-footer-elementor"),className:"object-contain"}),main:"",title:(0,hm.__)("AI Tools","header-footer-elementor"),badge:(0,hm.__)("NEW","header-footer-elementor"),content:c().createElement(bh,null)}].filter((function(e){return!("no"===hfeSettingsData.show_theme_support&&2===e.id||hfeSettingsData.is_uael_active&&5===e.id)})),t=i((0,s.useState)((function(){var t=localStorage.getItem("hfeSelectedItemId");return e.find((function(e){return e.id===Number(t)}))||e[0]})),2),n=t[0],r=t[1];return(0,s.useEffect)((function(){localStorage.setItem("hfeSelectedItemId",n.id.toString())}),[n]),(0,s.useEffect)((function(){var t=new URLSearchParams(window.location.search).get("tab");if(t){var n=Number(t),o=e.find((function(e){return e.id===n}));o&&r(o)}}),[]),c().createElement(c().Fragment,null,c().createElement(Nm,{onSettingsTabClick:function(){r(e[0])}}),c().createElement("div",{className:""},c().createElement(nt,{align:"stretch",className:"p-1 flex-col lg:flex-row hfe-settings-page",containerType:"flex",direction:"row",gap:"sm",justify:"start",style:{height:"100%"}},c().createElement(nt.Item,{className:"p-2 hfe-sticky-outer-wrapper",alignSelf:"auto",order:"none",shrink:1,style:{backgroundColor:"#ffffff"}},c().createElement("div",{className:"hfe-sticky-sidebar"},c().createElement(Uf,{items:e,onSelectItem:function(e){r(e)},selectedItemId:n.id}))),c().createElement(nt.Item,{className:"p-2 flex w-full justify-center items-start hfe-hide-scrollbar",alignSelf:"auto",order:"none",shrink:1,style:{height:"calc(100vh - 1px)",overflowY:"auto"}},c().createElement("div",{className:"hfe-78-width"},c().createElement(Wf,{selectedItem:n}))))))};let wh=1;const Eh=new class{#e;#t;constructor(){this.#e=[],this.#t=[]}subscribe(e){return this.#t.push(e),()=>{this.#t=this.#t.filter((t=>t!==e))}}publish(e){this.#t.forEach((t=>t(e)))}add(e){this.#e.push(e),this.publish(e)}remove(e){return this.#e=this.#e.filter((t=>t.id!==e)),e}create(e){const{id:t,message:n="",jsx:r,...o}=e;if(!n&&"function"!=typeof r)return;const a="number"==typeof t?t:wh++;return this.#e.find((e=>e.id===a))&&(this.#e=this.#e.map((e=>e.id===a?(this.publish({...e,title:n,jsx:r,...o}),{...e,title:n,jsx:r,...o}):e))),this.add({id:a,title:n,jsx:r,...o}),a}update(e,t){const{render:n}=t;let r=t;switch(typeof n){case"function":r={jsx:n,...t};break;case"string":r={title:n,...t}}this.#e=this.#e.map((t=>t.id===e?(this.publish({...t,...r}),{...t,...r}):t))}dismiss(e){return e||this.#e.forEach((e=>this.#t.forEach((t=>t({id:e.id,dismiss:!0}))))),this.#t.forEach((t=>t({id:e,dismiss:!0}))),e}history(){return this.#e}default(e="",t={}){return this.create({message:e,type:"neutral",...t})}success(e="",t={}){return this.create({message:e,type:"success",...t})}error(e="",t={}){return this.create({message:e,type:"error",...t})}warning(e="",t={}){return this.create({message:e,type:"warning",...t})}info(e="",t={}){return this.create({message:e,type:"info",...t})}custom(e,t={}){return this.create({jsx:e,type:"custom",...t})}},_h=Object.seal(Object.assign(((e,t)=>Eh.default(e,t)),{success:Eh.success.bind(Eh),error:Eh.error.bind(Eh),warning:Eh.warning.bind(Eh),info:Eh.info.bind(Eh),custom:Eh.custom.bind(Eh),dismiss:Eh.dismiss.bind(Eh),update:Eh.update.bind(Eh)},{getHistory:Eh.history.bind(Eh)})),kh={"top-left":"top-0 bottom-0 left-0 justify-start items-start","top-right":"top-0 bottom-0 right-0 justify-start items-end","bottom-left":"top-0 bottom-0 left-0 justify-end items-start","bottom-right":"top-0 bottom-0 right-0 justify-end items-end"},Sh={neutral:"border-alert-border-neutral bg-alert-background-neutral",custom:"border-alert-border-neutral bg-alert-background-neutral",info:"border-alert-border-info bg-alert-background-info",success:"border-alert-border-green bg-alert-background-green",warning:"border-alert-border-warning bg-alert-background-warning",error:"border-alert-border-danger bg-alert-background-danger"},Nh="bg-background-inverse border-background-inverse",Ch={light:"text-icon-secondary",dark:"text-icon-inverse"};let Ph=!1;const Th=({toastItem:e,title:t="",content:n="",autoDismiss:r=!0,dismissAfter:o=5e3,theme:a="light",design:i="stack",icon:l,variant:c="neutral",removeToast:u})=>{const d=(0,s.useRef)(0),m=(0,s.useRef)(0),f=(0,s.useRef)(),p=(e,t=o)=>{if(r&&!(o<0))return d.current=(new Date).getTime(),setTimeout((()=>{"function"==typeof u&&u(e.id)}),t)};(0,s.useEffect)((()=>{const t=o;return f.current=p(e,t),()=>{clearTimeout(f.current)}}),[]),(0,s.useEffect)((()=>{!e?.dismiss||"function"!=typeof u||u(e.id)}),[e]);const h=()=>{"function"==typeof u&&e?.action?.onClick?.((()=>u(e.id)))};let g=null;return"stack"===i&&(g=(0,I.jsx)("div",{className:Fe("flex items-center justify-start p-4 gap-2 relative border border-solid rounded-md shadow-lg","dark"===a?Nh:Sh?.[c],"w-[22.5rem]"),onMouseEnter:()=>{clearTimeout(f.current),m.current=(new Date).getTime()},onMouseLeave:()=>{f.current=p(e,o-(m.current-d.current))},children:"custom"!==e.type?(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)("div",{className:"self-start flex items-center justify-center [&_svg]:size-5 shrink-0",children:Dm({variant:c,icon:l,theme:a})}),(0,I.jsxs)("div",{className:"flex flex-col items-start justify-start gap-0.5 mr-6",children:[Om({title:t,theme:a}),Im({content:n,theme:a}),e?.action?.label&&"function"==typeof e?.action?.onClick&&(0,I.jsx)("div",{className:"mt-2.5",children:Mm({actionLabel:e?.action?.label,actionType:e?.action?.type??"button",onAction:h,theme:a})})]}),(0,I.jsx)("div",{className:"absolute right-4 top-4 [&_svg]:size-5",children:(0,I.jsx)("button",{className:Fe("bg-transparent m-0 p-0 border-none focus:outline-none active:outline-none cursor-pointer",Ch[a]??Ch.light),onClick:()=>{"function"==typeof u&&u(e.id)},children:(0,I.jsx)(nm,{})})})]}):e?.jsx?.({close:()=>u(e.id),action:e?.action?{...e?.action,onClick:h}:null})})),"inline"===i&&(g=(0,I.jsxs)("div",{className:Fe("flex items-center justify-start p-3 gap-2 relative border border-solid rounded-md shadow-lg","dark"===a?Nh:Sh?.[c],"lg:w-[47.5rem] w-full"),children:[(0,I.jsx)("div",{className:"self-start flex items-center justify-center [&_svg]:size-5 shrink-0",children:Dm({variant:c,icon:l,theme:a})}),(0,I.jsxs)("div",{className:"flex items-start justify-start gap-1 mr-10 [&>span:first-child]:shrink-0",children:[Om({title:t,theme:a}),Im({content:n,theme:a})]}),(0,I.jsx)("div",{className:"absolute right-3 top-3 [&_svg]:size-5",children:(0,I.jsx)("button",{className:Fe("bg-transparent m-0 p-0 border-none focus:outline-none active:outline-none cursor-pointer",Ch[a]??Ch.light),onClick:()=>u(e.id),children:(0,I.jsx)(nm,{})})})]})),g},jh=(e=>(0,s.memo)((t=>{const n=t.singleTon;return Ph&&n?null:(Ph=!0,(0,I.jsx)(e,{...t}))})))((({position:e="top-right",design:t="stack",theme:n="light",className:r="",autoDismiss:o=!0,dismissAfter:a=5e3})=>{const[i,l]=(0,s.useState)([]);(0,s.useEffect)((()=>{Eh.subscribe((e=>{e?.dismiss?l((t=>t.map((t=>t.id===e.id?{...t,dismiss:!0}:t)))):setTimeout((()=>{(0,rn.flushSync)((()=>l((t=>-1!==t.findIndex((t=>t.id===e.id))?t.map((t=>t.id===e.id?{...t,...e}:t)):[...t,e]))))}))}))}),[]);const c=e=>{l((t=>t.filter((t=>t.id!==e))))};return(0,I.jsx)("ul",{className:Fe("fixed flex flex-col list-none z-20 p-10 pointer-events-none [&>li]:pointer-events-auto gap-3",kh[e]??kh["top-right"],r),children:(0,I.jsx)(Dd,{initial:!1,children:i.map((e=>(0,I.jsx)(Cd.li,{initial:{opacity:0,y:50,scale:.7},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,scale:.6,transition:{duration:.15}},layoutId:`toast-${e.id}`,children:(0,I.jsx)(Th,{toastItem:e,title:e.title,content:e?.description,icon:e?.icon??void 0,design:e?.design??t,autoDismiss:e?.autoDismiss??o,dismissAfter:e?.dismissAfter??a,removeToast:c,variant:e.type,theme:e?.theme??n})},e.id)))})})}));function Ah(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Rh(e){for(var t=1;t{const[i,l]=(0,s.useState)(Array.isArray(t)?t:[t]);return(0,I.jsx)("div",{className:Fe("boxed"===e?"space-y-3":"",a),children:s.Children.map(o,(t=>{if(s.isValidElement(t)&&"value"in t.props){const o=!1!==t.props.collapsible,a=!o||i.includes(t.props.value);return s.cloneElement(t,{isOpen:a,onToggle:o?()=>(e=>{l((t=>n?t.includes(e)?[]:[e]:t.includes(e)?t.filter((t=>t!==e)):[...t,e]))})(t.props.value):void 0,type:e,disabled:r||t.props.disabled})}return t}))})};Mh.displayName="Accordion";const Oh=({isOpen:e,onToggle:t,type:n="simple",disabled:r=!1,children:o,className:a})=>{const i={simple:"border-0",separator:"border-0 border-b border-solid border-border-subtle",boxed:"border border-solid border-border-subtle rounded-md"}[n];return(0,I.jsx)("div",{className:Fe(i,a),children:s.Children.map(o,(o=>s.isValidElement(o)?s.cloneElement(o,{isOpen:e,onToggle:t,type:n,disabled:r}):o))})};Oh.displayName="Accordion.Item";const Ih=({onToggle:e,isOpen:t,iconType:n="arrow",collapsible:r=!0,disabled:o=!1,tag:a="h3",type:i="simple",children:s,className:l,...c})=>{const u={simple:"px-2 py-3",separator:"px-2 py-4",boxed:"px-3 py-4"}[i];return(0,I.jsx)(a,{className:"flex m-0 hover:bg-background-secondary transition duration-150 ease-in-out",children:(0,I.jsxs)("button",{className:Fe("flex w-full items-center justify-between text-sm font-medium transition-all appearance-none bg-transparent border-0 cursor-pointer gap-3",u,o&&"cursor-not-allowed opacity-40",l),onClick:!o&&r?e:void 0,"aria-expanded":t,disabled:o,...c,children:[(0,I.jsx)("div",{className:"flex items-center gap-2 text-text-primary font-semibold text-left",children:s}),r?"arrow"===n?(0,I.jsx)(zd,{className:Fe("flex-shrink-0 text-icon-secondary size-5 transition-transform duration-300 ease-in-out",t?"rotate-180":"rotate-0")}):"plus-minus"===n?(0,I.jsx)(Cd.span,{initial:{opacity:0,rotate:t?-180:0},animate:{opacity:1,rotate:t?0:180},exit:{opacity:0},transition:{duration:.3,ease:"easeInOut"},className:"flex items-center flex-shrink-0 text-icon-secondary",children:t?(0,I.jsx)(Fh,{}):(0,I.jsx)(Dh,{})},t?"minus":"plus"):null:null]})})};Ih.displayName="Accordion.Trigger";const Lh=({isOpen:e,disabled:t=!1,type:n="simple",children:r,className:o})=>{const a={simple:"px-2 pb-3",separator:"px-2 pb-4",boxed:"px-3 pb-4"}[n];return(0,I.jsx)(Dd,{initial:!1,children:e&&(0,I.jsx)(Cd.div,{variants:{open:{height:"auto",opacity:1,overflow:"unset",transition:{overflow:{delay:1}}},closed:{height:0,opacity:0,overflow:"hidden"}},initial:"closed",animate:"open",exit:"closed",transition:{duration:.3,ease:"easeInOut"},className:Fe("text-text-secondary w-full text-sm transition-[height, opacity, transform] ease-in box-border",t&&"opacity-40",o),"aria-hidden":!e,children:(0,I.jsx)("div",{className:Fe(a),children:r})},"content")})};Lh.displayName="Accordion.Content";const zh=Object.assign(Mh,{Item:Oh,Trigger:Ih,Content:Lh}),Bh={400:"font-normal",500:"font-medium",600:"font-semibold",700:"font-bold"},Vh={36:"text-4xl",30:"text-3xl",24:"text-2xl",20:"text-xl",18:"text-lg",16:"text-base",14:"text-sm",12:"text-xs"},Uh={44:"leading-11",38:"leading-9.5",32:"leading-8",30:"leading-7.5",28:"leading-7",24:"leading-6",20:"leading-5",16:"leading-4"},Wh={2:"tracking-2"},Hh={brand600:"text-brand-primary-600",link:"text-link-primary",primary:"text-text-primary",secondary:"text-text-secondary",tertiary:"text-text-tertiary",disabled:"text-text-disabled",help:"text-field-helper",label:"text-field-label",info:"text-support-info",success:"text-support-success",warning:"text-support-warning",error:"text-support-error",inverse:"text-text-on-color"},$h=(0,s.forwardRef)((function({as:e,children:t,weight:n,size:r,lineHeight:o,letterSpacing:a,color:i="primary",className:s,...l},c){return(0,I.jsx)(e||"p",{ref:c,className:Fe("m-0 p-0",n?Bh[n]:"",r?Vh[r]:"",o?Uh[o]:"",a?Wh[a]:"",i?Hh[i]:"",s),...l,children:t})})),qh=cm("video",[["path",{d:"m16 13 5.223 3.482a.5.5 0 0 0 .777-.416V7.87a.5.5 0 0 0-.752-.432L16 10.5",key:"ftymec"}],["rect",{x:"2",y:"6",width:"14",height:"12",rx:"2",key:"158x01"}]]),Yh=cm("info",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]]),Gh=function(e){var t=e.step,n=e.chapterId,r=e.isLast,o=void 0!==r&&r,a=e.onCompletionChange,l=e.onLearnHowClick,c=t.id,u=t.title,d=t.description,m=t.learn,f=t.action,p=t.completed,h=void 0!==p&&p,g=t.isPro,y=void 0!==g&&g,v=i((0,s.useState)(h),2),b=v[0],x=v[1];if((0,s.useEffect)((function(){x(h)}),[h]),!c||!u)return null;var w=function(){var e=!b;x(e),a&&a(n,c,e)},E=function(){return"video"===(null==m?void 0:m.type)?React.createElement(qh,{size:14}):React.createElement(Yh,{size:14})},_=b?(0,hm.__)("Mark as incomplete","astra"):(0,hm.__)("Mark as complete","astra");return React.createElement("div",{className:"py-4 sm:py-5 flex items-center gap-2 sm:gap-3 border-solid border-0 border-border-subtle ".concat(o?"":"border-b-0.5")},React.createElement(zm,{arrow:!0,content:_,placement:"top",variant:"dark"},React.createElement("span",{className:"self-start mt-[1px] flex justify-center items-center w-2 h-2 p-[3px] sm:p-[4px] rounded-full cursor-pointer border-[1.25px] border-solid ".concat(b?"bg-support-success border-support-success-inverse":"border-border-strong [&:hover>svg]:text-border-strong"),tabIndex:0,"aria-label":_,onClick:w,onKeyDown:function(e){"Enter"!==e.key&&" "!==e.key||(e.preventDefault(),w())}},React.createElement(sf,{className:"text-icon-on-color sm:w-3.5 sm:h-3.5 transition-all duration-200",size:12,strokeWidth:1.5}))),React.createElement("div",{className:"flex-1 flex items-center gap-2"},React.createElement("div",{className:"flex flex-col gap-1.5"},React.createElement($h,{className:"flex-1",size:14,weight:500,color:"primary"},u),React.createElement($h,{className:"flex-1 hidden sm:block",size:14,color:"secondary"},d)),y&&React.createElement(rm,{label:(0,hm.__)("Pro","astra"),size:"xs",type:"pill",variant:"inverse",className:"uppercase"})),m&&React.createElement(zm,{arrow:!0,content:(null==m?void 0:m.label)||(0,hm.__)("Learn how","astra"),placement:"top",variant:"dark"},React.createElement(ct,{size:"xs",variant:"ghost",icon:React.createElement(E,null),onClick:function(){"link"!==(null==m?void 0:m.type)?l&&m&&l(t):window.open(null==m?void 0:m.url,"_blank","noopener,noreferrer")},className:"text-button-primary hover:bg-transparent outline-none"})),React.createElement(ct,{className:"px-3 gap-0.5 min-w-40 text-button-primary hover:bg-background-button-hover hover:outline-button-secondary",size:"sm",variant:"secondary",icon:React.createElement(um,{size:14}),iconPosition:"right",onClick:function(){null!=f&&f.url?null!=f&&f.isExternal?window.open(null==f?void 0:f.url,"_blank","noopener,noreferrer"):window.location.href=null==f?void 0:f.url:console.info("Empty or missing URL!!!")}},(null==f?void 0:f.label)||(0,hm.__)("Set Up","astra")))},Xh=function(e){var t=e.chapters,n=e.defaultValue,r=e.onStepCompletionChange,o=e.onLearnHowClick,a=function(e,t){e.stopPropagation(),t?window.open(t,"_blank","noopener,noreferrer"):console.info("Empty or missing URL!!!")};return React.createElement(zh,{type:"boxed",autoClose:!0,defaultValue:n},t.map((function(e){var t=e.id,n=e.title,i=e.description,s=e.url,l=e.steps,c=l.length,u=l.filter((function(e){return e.completed})).length,d=c===u;return React.createElement(zh.Item,{key:t,className:"bg-background-primary border-0.5 [&:hover>h3]:bg-transparent rounded-lg overflow-hidden [&:has([aria-expanded='true'])]:shadow-xs transition-all duration-200 ease-in-out",value:t},React.createElement(zh.Trigger,{className:"group p-3 sm:p-4 hover:bg-transparent [&>svg]:hidden [&>div]:flex-grow [&[aria-expanded='true']_.learn-chevron-right]:rotate-90 [&[aria-expanded='true']_.learn-more-btn]:flex"},React.createElement("div",{className:"flex items-center gap-2 sm:gap-3 flex-1"},React.createElement(rh,{className:"learn-chevron-right transition-transform duration-200 ease-in-out",size:20}),React.createElement("div",{className:"flex-1 text-left"},React.createElement($h,{size:14,className:"sm:text-base",weight:600},n)),s&&React.createElement("span",{className:"hover:underline underline-offset-2 learn-more-btn hidden transition-all cursor-pointer text-link-primary outline-link-primary items-center gap-1 text-xs px-2 py-1",onClick:function(e){return a(e,s)},role:"link",tabIndex:0,onKeyDown:function(e){"Enter"!==e.key&&" "!==e.key||a(e,s)}},React.createElement("span",{className:"hidden sm:inline"},(0,hm.__)("Learn how","astra")),React.createElement(oh,{size:16,strokeWidth:1.25})),React.createElement(rm,{className:"relative overflow-hidden w-14 sm:w-[62px] text-xs",label:React.createElement(React.Fragment,null,React.createElement("span",{className:"sr-only"},(0,hm.sprintf)((0,hm.__)("%1$d of %2$d steps completed","astra"),u,c)),React.createElement("span",{className:"flex items-center"},d&&React.createElement(sf,{size:12}),React.createElement("span",{className:"px-1 relative z-10"},u,"/",c)),React.createElement("span",{className:"absolute h-full top-0 left-0 bg-[#BAE6FD]/40 transition-[width] duration-300 ease-in-out",style:{width:"".concat(u/c*100,"%")}})),variant:d?"green":u>0?"blue":"gray"}))),React.createElement(zh.Content,{className:"overflow-visible [&>div]:p-0"},i&&React.createElement($h,{className:"px-3 sm:px-4 ml-7 mr-0 sm:mx-8 -mt-2 pb-4 pt-3 max-w-full sm:max-w-[72%]",size:14,color:"secondary",weight:400},i),React.createElement("span",{className:"block w-full h-[0.5px] bg-border-subtle"}),React.createElement("div",{className:"px-3 sm:px-4 flex flex-col bg-[#FCFCFD]"},l.map((function(e,n){return React.createElement(Gh,{key:e.id,step:e,chapterId:t,isLast:n===l.length-1,onCompletionChange:r,onLearnHowClick:o})})))))})))},Kh=function(){return React.createElement(React.Fragment,null,React.createElement("div",{className:"border-0.5 border-solid border-border-subtle rounded-lg"},React.createElement(Xm,{variant:"rectangular",className:"w-full h-14 rounded-b-none rounded-t-lg bg-background-secondary"}),React.createElement("div",{className:"px-4"},Array(4).fill(0).map((function(e,t){return React.createElement("div",{key:"step-skeleton-".concat(t),className:"py-5 flex items-center gap-3"},React.createElement(Xm,{variant:"circular",className:"w-6 h-6 bg-background-secondary"}),React.createElement("div",{className:"flex-1"},React.createElement(Xm,{variant:"rectangular",className:"w-2/3 h-5 bg-background-secondary"})),React.createElement(Xm,{variant:"rectangular",className:"w-[104px] h-8 bg-background-secondary"}))})))),Array(4).fill(0).map((function(e,t){return React.createElement(Xm,{key:"skeleton-".concat(t),variant:"rectangular",className:"w-full h-14 rounded-lg bg-background-secondary"})})))},Jh=(0,g.forwardRef)((function(e){var t=e.text,n=e.variant,r=e.onClick;return React.createElement(ct,{variant:n||"primary",size:"sm",onClick:function(e){r&&"function"==typeof r&&r(e)}},t)})),Zh=function(e){var t=e.items;return React.createElement("div",{className:"space-y-2"},t.map((function(e,t){return React.createElement("div",{key:t,className:"flex items-start gap-2"},React.createElement($h,{size:14,weight:600,color:"primary",className:"flex-shrink-0"},(0,hm.sprintf)((0,hm.__)("Step %d:","astra"),t+1)),React.createElement($h,{size:14,color:"secondary"},e.text))})))},Qh=function(e){var t=e.src,n=e.alt,r=i((0,s.useState)(!1),2),o=r[0],a=r[1];return React.createElement("div",{className:"relative w-full shadow-sm rounded-lg overflow-hidden"},!o&&React.createElement(Xm,{className:"w-full h-64"}),React.createElement("img",{src:t,alt:n||"",className:"w-full h-auto border-0.5 border-solid border-border-subtle ".concat(o?"block":"hidden"),onLoad:function(){return a(!0)}}))},eg=function(e){var t=e.prefix,n=e.text,r=e.url,o=e.target,a=void 0===o?"_blank":o;return React.createElement("div",{className:"text-sm flex gap-1"},t&&React.createElement("span",null,t),React.createElement($h,{as:"a",href:r,target:a,className:"text-gs-primary underline"},n||r))},tg=function(e){var t=e.items;return React.createElement("ul",{className:"list-disc ml-8"},t.map((function(e,t){return React.createElement("li",{key:t,className:"my-0.5"},React.createElement($h,{size:14,color:"secondary"},e))})))};var ng=function(){for(var e=arguments.length,t=new Array(e),n=0;n0&&void 0!==arguments[0]?arguments[0]:{},t=e.initialChapters,n=void 0===t?[]:t,r=e.saveEndpoint,o=void 0===r?null:r,a=i((0,s.useState)(n),2),l=a[0],c=a[1],u=i((0,s.useState)(!1),2),d=u[0],m=u[1],f=i((0,s.useState)(null),2),p=f[0],h=f[1];(0,s.useEffect)((function(){n.length>0&&c(n)}),[n]);var g=(0,s.useCallback)((function(e,t,n){c((function(r){return r.map((function(r){return r.id===e?Rh(Rh({},r),{},{steps:r.steps.map((function(e){return e.id===t?Rh(Rh({},e),{},{completed:n}):e}))}):r}))})),o&&$m()({path:o,method:"POST",data:{chapterId:e,stepId:t,completed:n}}).catch((function(r){c((function(r){return r.map((function(r){return r.id===e?Rh(Rh({},r),{},{steps:r.steps.map((function(e){return e.id===t?Rh(Rh({},e),{},{completed:!n}):e}))}):r}))})),_h.error((0,hm.__)("Failed to save progress. Please try again.","astra")),console.error("Failed to save progress:",r)}))}),[o]),y=(0,s.useCallback)((function(e,t){g(e,t,!0)}),[g]),v=(0,s.useCallback)((function(e,t){g(e,t,!1)}),[g]),b=(0,s.useCallback)((function(){c((function(e){return e.map((function(e){return Rh(Rh({},e),{},{steps:e.steps.map((function(e){return Rh(Rh({},e),{},{completed:!1})}))})}))}))}),[]),x=(0,s.useMemo)((function(){var e=l.find((function(e){return e.steps.length!==e.steps.filter((function(e){return e.completed})).length}));return null==e?void 0:e.id}),[l]),w=(0,s.useMemo)((function(){var e=l.reduce((function(e,t){return e+t.steps.length}),0),t=l.reduce((function(e,t){return e+t.steps.filter((function(e){return e.completed})).length}),0),n=e>0?Math.round(t/e*100):0;return{totalChapters:l.length,totalSteps:e,completedSteps:t,completionPercentage:n,isFullyCompleted:e>0&&t===e}}),[l]),E=(0,s.useCallback)((function(e){var t=l.find((function(t){return t.id===e}));if(!t)return null;var n=t.steps.length,r=t.steps.filter((function(e){return e.completed})).length;return{totalSteps:n,completedSteps:r,isCompleted:n>0&&r===n,completionPercentage:n>0?Math.round(r/n*100):0}}),[l]),_=(0,s.useCallback)((function(e){h(e),m(!0)}),[]),k=(0,s.useCallback)((function(){m(!1),h(null)}),[]);return{chapters:l,updateStepCompletion:g,markStepCompleted:y,markStepIncomplete:v,resetProgress:b,firstIncompleteChapterId:x,progressStats:w,getChapterStats:E,learnHowDialogOpen:d,currentLearnHowItem:p,openLearnHowDialog:_,closeLearnHowDialog:k,setLearnHowDialogOpen:m}}({initialChapters:null!=o&&o.get?d:n,saveEndpoint:null==o?void 0:o.set}),x=b.chapters,w=b.updateStepCompletion,E=b.firstIncompleteChapterId,_=b.progressStats,k=b.learnHowDialogOpen,S=b.currentLearnHowItem,N=b.openLearnHowDialog,C=b.setLearnHowDialogOpen;return c&&"function"==typeof c&&c(_),p?React.createElement("div",{className:"flex flex-col gap-2 ".concat(l," !bg-transparent")},React.createElement(Kh,null)):y?React.createElement("div",{className:l},React.createElement("div",{className:"text-error p-4"},y)):x&&0!==x.length?React.createElement("div",{className:l},React.createElement(Xh,{chapters:x,defaultValue:E,onStepCompletionChange:w,onLearnHowClick:N}),React.createElement(ig,{open:k,setOpen:C,item:S}),React.createElement(jh,{position:"top-right",design:"stack",theme:"light",autoDismiss:!0,dismissAfter:5e3})):null},lg=function(){var e=i((0,s.useState)(!1),2),t=e[0],n=e[1];return c().createElement(c().Fragment,null,c().createElement(jf,null),c().createElement(Nm,null),c().createElement("div",{className:"bg-gray-50 min-h-[calc(100vh_-_8rem)]"},c().createElement("h1",{className:"sr-only"},(0,hm.__)("Learn","header-footer-elementor")),c().createElement("div",{className:"max-w-5xl mx-auto px-4 sm:px-6 lg:px-8 py-5"},c().createElement("div",{className:"max-w-3xl mx-auto px-4"},c().createElement("div",{className:"p-4 bg-background-primary rounded-xl flex flex-col gap-3 flex flex-col gap-4 sm:gap-8"},c().createElement("div",{className:"px-1 flex justify-between relative flex-col items-start space-y-2"},c().createElement("h2",{className:"m-0 p-0 font-semibold text-base text-text-primary"},(0,hm.__)("Learn","header-footer-elementor")),c().createElement("p",{className:"m-0 p-0 text-sm text-text-primary"},(0,hm.__)("Master UAE with our step-by-step guide and tutorials. Create stunning headers and footers with confidence.","header-footer-elementor")),c().createElement(ct,{className:"absolute right-0 whitespace-nowrap",variant:"ghost",size:"xs",icon:c().createElement(qh,{className:"w-4 h-4"}),onClick:function(){n((function(e){return!e}))}},c().createElement("span",{className:"sm:inline-block"},t?(0,hm.__)("Hide Video","header-footer-elementor"):(0,hm.__)("Watch Video","header-footer-elementor")))),c().createElement("div",{className:"transition-all duration-700 ease-in-out overflow-hidden px-6 ".concat(t?"max-h-[800px] opacity-100 pb-6":"max-h-0 opacity-0 pb-0")},t&&c().createElement("div",{className:"relative rounded-lg shadow-lg aspect-video overflow-hidden"},c().createElement("iframe",{className:"w-full h-full",src:"https://www.youtube-nocookie.com/embed/ZeogOxqdKJI?autoplay=1&enablejsapi=1&start=29&end=72",title:"UAE Tutorial Video",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0}))),c().createElement(sg,{className:"bg-background-secondary p-2 rounded-lg [&>div]:space-y-2",endpoints:{get:"/hfe/v1/get-learn-chapters",set:"/hfe/v1/update-learn-progress"}}))))))},cg=cm("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),ug=function(){var e=[{title:(0,hm.__)("Essentials","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("White Label Option","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("24x7 Premium Support","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("User Portal / User Login","header-footer-elementor"),iconFree:!1,iconPro:!0}]},{title:(0,hm.__)("Content Widgets","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Advanced Heading","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("Business Hours","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("Content Toggle","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("Google Map","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:5,content:(0,hm.__)("Image Gallery","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:6,content:(0,hm.__)("Info Box","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:7,content:(0,hm.__)("Modal Popup","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:8,content:(0,hm.__)("Posts","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:9,content:(0,hm.__)("Price List","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:10,content:(0,hm.__)("Table","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:11,content:(0,hm.__)("Info Card","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:12,content:(0,hm.__)("Video","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:13,content:(0,hm.__)("Video Gallery","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:14,content:(0,hm.__)("Basic Posts","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:15,content:(0,hm.__)("SVG Animator","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:16,content:(0,hm.__)("Table of Contents","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:17,content:(0,hm.__)("Counter","header-footer-elementor"),iconFree:!0,iconPro:!1}]},{title:(0,hm.__)("Creative Widgets","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Before After Slider","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("Countdown Timer","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("Welcome Music","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("Dual Color Heading","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:5,content:(0,hm.__)("Fancy Heading","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:6,content:(0,hm.__)("Hotspots","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:7,content:(0,hm.__)("Login Form","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:8,content:(0,hm.__)("Marketing Button","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:9,content:(0,hm.__)("Multi Buttons","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:10,content:(0,hm.__)("Off-Canvas","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:11,content:(0,hm.__)("Retina Image","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:12,content:(0,hm.__)("Team Member","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:13,content:(0,hm.__)("Price Box","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:14,content:(0,hm.__)("Timeline","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:15,content:(0,hm.__)("User Registration Form","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:16,content:(0,hm.__)("Retina Logo","header-footer-elementor"),iconFree:!0,iconPro:!1}]},{title:(0,hm.__)("Form Styler","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Contact Form 7 Styler","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("Gravity Form Styler","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("WP Fluent Forms Styler","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("WPForms Styler","header-footer-elementor"),iconFree:!1,iconPro:!0}]},{title:(0,hm.__)("SEO","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Business Reviews","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("How To Schema","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("FAQ Schema","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("Breadcrumbs","header-footer-elementor"),iconFree:!1,iconPro:!0}]},{title:(0,hm.__)("WooCommerce","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Woo – Add to Cart","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("Woo – Categories","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("Woo – Thank You Page","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("Woo – Checkout","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:5,content:(0,hm.__)("Woo – Mini Cart","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:6,content:(0,hm.__)("Woo – Products","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:7,content:(0,hm.__)("Woo – Product Grid","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:8,content:(0,hm.__)("Cart","header-footer-elementor"),iconFree:!0,iconPro:!1}]},{title:(0,hm.__)("Social","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Instagram Feed","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("X Feed","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("Social Share","header-footer-elementor"),iconFree:!1,iconPro:!0}]},{title:(0,hm.__)("Special Features","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Cross-Site Copy Paste","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:2,content:(0,hm.__)("Presets","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:3,content:(0,hm.__)("Particle Backgrounds","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:4,content:(0,hm.__)("Party Propz","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:5,content:(0,hm.__)("Scroll to Top","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:6,content:(0,hm.__)("Display Conditions","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:7,content:(0,hm.__)("Sticky Header","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:8,content:(0,hm.__)("UAE Duplicator","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:9,content:(0,hm.__)("Conditional Display","header-footer-elementor"),iconFree:!1,iconPro:!0},{id:10,content:(0,hm.__)("Reading Progress Bar","header-footer-elementor"),iconFree:!0,iconPro:!1}]},{title:(0,hm.__)("Dynamic Header & Footer Widgets","header-footer-elementor"),items:[{id:1,content:(0,hm.__)("Site Logo","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:2,content:(0,hm.__)("Site Title","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:3,content:(0,hm.__)("Navigation Menu","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:4,content:(0,hm.__)("Page Title","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:5,content:(0,hm.__)("Search","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:6,content:(0,hm.__)("Site Tagline","header-footer-elementor"),iconFree:!0,iconPro:!1},{id:7,content:(0,hm.__)("Copyright","header-footer-elementor"),iconFree:!0,iconPro:!1}]}],t=function(e){return e?c().createElement(sf,{color:"#16A34A"}):c().createElement(cg,{color:"#DC2626"})};return c().createElement("div",{className:"rounded-lg bg-white w-full mb-6"},c().createElement("div",{className:"flex items-center justify-between p-5",style:{paddingBottom:"0"}},c().createElement("div",{className:"flex flex-col"},c().createElement("p",{className:"m-0 text-xl font-semibold pt-4 pb-2 text-text-primary"},(0,hm.__)("Free Vs Pro","header-footer-elementor")),c().createElement("p",{className:"m-0 text-sm font-normal pt-1 text-text-secondary"},(0,hm.__)("Ultimate Addons for Elementor Pro offers 50+ widgets and features!","header-footer-elementor")),c().createElement("p",{className:"m-0 text-sm font-normal pt-1 text-text-secondary"},(0,hm.__)("Compare the popular features/widgets to find the best option for your website.","header-footer-elementor"))),c().createElement("div",{className:"flex items-center gap-x-2 mr-7 text-sm"},c().createElement(ct,{iconPosition:"right",variant:"primary",style:{color:"white",borderColor:"#6005FF",transition:"color 0.3s ease, border-color 0.3s ease",backgroundColor:"#6005ff"},className:"hfe-remove-ring text-[#6005FF] text-base p-3.5",onClick:function(){window.open("https://ultimateelementor.com/pricing/?utm_source=uae-lite-FreevsPro&utm_medium=get-uae-pro&utm_campaign=uae-lite-upgrade","_blank")}},(0,hm.__)("Upgrade Now","header-footer-elementor")))),c().createElement("div",{className:"px-4"},c().createElement("div",{className:"flex flex-col space-y-2 pt-5"},e.map((function(e){return c().createElement(c().Fragment,{key:e.title},c().createElement("div",{className:"flex fle-row py-4 px-5 items-center h-4 justify-between rounded-lg shadow-container-item",style:{backgroundColor:"#F9FAFB"}},c().createElement("p",{className:"text-sm text-text-primary font-medium"},e.title),c().createElement("div",{className:"flex flex-row items-center",style:{gap:"12rem"}},c().createElement("p",{className:"text-sm text-text-primary font-medium"},(0,hm.__)("Free","header-footer-elementor")),c().createElement("p",{className:"text-sm text-text-primary font-medium",style:{marginRight:"50px"}},(0,hm.__)("Pro","header-footer-elementor")))),e.items.map((function(e){return c().createElement("div",{key:e.id,className:"flex fle-row py-4 px-5 items-center h-4 justify-between rounded-lg shadow-container-item"},c().createElement("p",{className:"text-sm text-text-secondary font-medium"},e.content),c().createElement("div",{className:"flex flex-row items-center justify-between",style:{gap:10===e.id&&e.content===(0,hm.__)("Navigation Menu","header-footer-elementor")?"10.7rem":"12rem"}},c().createElement("p",{className:"text-sm text-text-primary font-medium"},10===e.id&&e.content===(0,hm.__)("Navigation Menu","header-footer-elementor")?e.iconPro?(0,hm.__)("Advanced","header-footer-elementor"):(0,hm.__)("Basic","header-footer-elementor"):t(e.iconFree)),c().createElement("p",{className:"text-sm text-text-primary font-medium",style:{marginRight:10===e.id&&e.content===(0,hm.__)("Navigation Menu","header-footer-elementor")?"25px":"50px"}},10===e.id&&e.content===(0,hm.__)("Navigation Menu","header-footer-elementor")?e.iconPro?(0,hm.__)("Basic","header-footer-elementor"):(0,hm.__)("Advanced","header-footer-elementor"):t(e.iconPro))))})))})),c().createElement("div",{className:"flex items-center justify-center gap-x-2 "},c().createElement("a",{href:"https://ultimateelementor.com/pricing/?utm_source=uae-lite-dashboard&utm_medium=unlock-ultimate-feature&utm_campaign=uae-lite-upgrade",target:"_blank",rel:"noopener noreferrer",className:"text-sm font-normal text-text-primary cursor-pointer no-underline",style:{lineHeight:"1rem",paddingTop:"10px",paddingBottom:"20px",color:"#6005FF",textDecoration:"none",outline:"none",boxShadow:"none"},onFocus:function(e){return e.target.style.outline="none"},onBlur:function(e){return e.target.style.outline="none"}},(0,hm.__)("See all UAE Pro Features","header-footer-elementor"),c().createElement(um,{className:"ml-1 font-semibold",size:14,color:"#6005FF"}))))))},dg=function(){return c().createElement(c().Fragment,null,c().createElement(jf,null),c().createElement(Nm,null),c().createElement("div",null,c().createElement(nt,{align:"stretch",className:"p-6 flex-col lg:flex-row box-border",containerType:"flex",direction:"row",gap:"sm",justify:"start",style:{width:"100%"}},c().createElement(nt.Item,{className:"p-2 hfe-65-width",alignSelf:"auto",order:"none",shrink:0},c().createElement(ug,null)),c().createElement(nt.Item,{className:"p-2 w-full hfe-35-width hfe-sticky-right-sidebar",shrink:1},c().createElement(lf,null),c().createElement("div",{className:"pt-4 mt-4"},c().createElement(nf,null))))))},mg=(e,t)=>Fe("rounded-full text-brand-primary-600 transition-colors duration-300",e[t].dot,e[t].ring),fg={sm:{dot:"size-2.5",ring:"size-5",numberIcon:"size-5 text-tiny",icon:"size-5",label:"text-xs"},md:{dot:"size-3",ring:"size-6",numberIcon:"size-6 text-sm",icon:"size-6",label:"text-sm"},lg:{dot:"size-3.5",ring:"size-7",numberIcon:"size-7 text-md",icon:"size-7",label:"text-sm"}},pg=({variant:e="dot",size:t="sm",type:n="inline",currentStep:r=1,children:o,className:a,lineClassName:i="min-w-10",completedVariant:l="icon",completedIcon:c=(0,I.jsx)(Tm,{}),...u})=>{const d=s.Children.count(o);-1===r&&(r=d+1);const m=s.Children.map(o,((o,a)=>{const u={isCompleted:a+1{const h=gg(i,r,n,s,l,t,u,m,f),g={lg:"left-[calc(50%+14px)] right-[calc(-50%+14px)]",md:"left-[calc(50%+12px)] right-[calc(-50%+12px)]",sm:"left-[calc(50%+10px)] right-[calc(-50%+10px)]"},y={lg:"top-3.5",md:"top-3",sm:"top-2.5"},v=()=>{if(e){const t=Fe(s[l].label,"text-text-tertiary",n?"text-brand-primary-600":"","break-word","stack"===a?"mt-2 transform max-w-xs":"mx-2 max-w-32");return(0,I.jsx)("span",{className:t,children:e})}return null},b=()=>{if(!c){const t=Fe("block",r?"border-brand-primary-600":"border-border-subtle",d);return"stack"===a?(0,I.jsx)("div",{className:Fe("relative","flex","border-solid","border-y","absolute",r?"border-brand-primary-600":"border-border-subtle",y[l],g[l]),children:(0,I.jsx)("span",{className:"block"})}):(0,I.jsx)("div",{className:"flex-1",children:(0,I.jsx)("span",{className:Fe("mr-2 border-y border-solid",!e&&"ml-2",t)})})}return null};return"stack"===a?(0,I.jsxs)("div",{className:"relative flex-1 justify-center",children:[(0,I.jsxs)("div",{className:Fe("flex items-center flex-col",o),...p,children:[h,v()]}),b()]}):(0,I.jsxs)(I.Fragment,{children:[(0,I.jsxs)("div",{className:Fe("flex items-center",o),...p,children:[h,v()]}),b()]})};hg.displayName="ProgressSteps.Step";const gg=(e,t,n,r,o,a,i,s="icon",l=(0,I.jsx)(Tm,{}))=>{if(t)return"number"===s?(0,I.jsx)("span",{className:Fe(mg(r,o),"flex items-center justify-center bg-brand-primary-600 text-text-on-color rounded-full"),children:i+1}):(0,I.jsx)("span",{className:mg(r,o),children:l});const c=((e,t,n)=>Fe("relative flex items-center rounded-full justify-center transition-colors z-10 duration-500 ring-1",e?"ring-brand-primary-600":"ring-border-subtle",t[n].ring))(!!n,r,o),u=((e,t,n,r)=>{const o=`absolute rounded-full transition-colors duration-500 ${n[r].dot}`;return"dot"===e?Fe(o,n[r].dot,t?"bg-brand-primary-600":"bg-text-tertiary"):"number"===e?Fe(o,n[r].dot,t?"text-brand-primary-600":"text-text-tertiary","flex items-center justify-center"):"icon"===e?Fe(o,t?"text-brand-primary-600":"text-text-tertiary","flex items-center justify-center"):""})(e,n,r,o);let d=null;return"number"===e?d=i+1:"icon"===e&&a&&(d=a),(0,I.jsx)("span",{className:c,children:(0,I.jsx)("span",{className:u,children:d})})};pg.Step=hg;const yg=function(e){var t=e.plugin,n=e.setUpdateCounter,r=e.onPluginSelect,o=t.path,a=t.slug,l=t.siteUrl,u=t.icon,d=t.type,m=t.name,f=t.zipUrl,p=t.desc,h=(t.wporg,t.isFree,t.action,t.status),g=t.settings_url,y=i((0,s.useState)(!1),2),v=y[0],b=y[1],x=i((0,s.useState)(null),2),w=x[0],E=(x[1],i((0,s.useState)(!1),2)),_=E[0],k=E[1];return c().createElement(c().Fragment,null,c().createElement("style",null,"\n .uae-role-checkbox {\n position: relative;\n width: 30px;\n height: 30px;\n -webkit-appearance: none;\n appearance: none;\n border: 2px solid #d1d5db; /* gray-300 */\n border-radius: 4px;\n cursor: pointer;\n }\n\n .uae-role-checkbox:checked {\n background-color: #240064;\n border-color: #0017E1;\n }\n\n .uae-role-checkbox:checked::after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n width: 4px;\n height: 8px;\n border-right: 2px solid #fff;\n border-bottom: 2px solid #fff;\n transform: translate(-50%, -60%) rotate(45deg);\n }\n "),c().createElement(nt,{align:"center",containerType:"flex",direction:"row",justify:"between",gap:"md"},c().createElement("div",{className:"flex items-center gap-x-3 flex-1 cursor-pointer",onClick:function(e){if(!e.target.closest("p.text-sm.font-medium")){var t=!_;k(t),r&&r({slug:a,path:o,type:d,name:m,zipUrl:f,status:h,isChecked:t})}}},c().createElement("div",{className:"h-6 w-6 flex-shrink-0"},c().createElement("img",{src:u,alt:"Recommended Plugins/Themes",className:"w-full h-auto rounded",style:{width:"24px",height:"24px"}})),c().createElement("div",{className:"flex flex-col pl-3 flex-1 min-w-0"},c().createElement("p",{className:"text-sm font-medium text-text-primary pb-1 m-0 cursor-pointer truncate",style:{width:"230px"},onClick:function(e){e.stopPropagation(),window.open(t.siteurl,"_blank")}},(0,hm.__)(m,"header-footer-elementor")),c().createElement("p",{className:"text-sm font-normal text-text-tertiary m-0 truncate"},(0,hm.__)(p,"header-footer-elementor"))),c().createElement("div",{className:"flex-shrink-0 ml-2"},c().createElement("input",{type:"checkbox",checked:_,onChange:function(e){var t=e.target.checked;k(t),r&&r({slug:a,path:o,type:d,name:m,zipUrl:f,status:h,isChecked:t})},onClick:function(e){return e.stopPropagation()},id:"plugin-".concat(a),className:"uae-role-checkbox h-4 w-4 text-purple-600 focus:ring-purple-500 border-gray-300 rounded","data-plugin":f,"data-type":d,"data-pluginname":m,"data-slug":a,"data-site":l,"data-init":o,"data-status":h}))),c().createElement(yf,{design:"simple",open:v,setOpen:b},c().createElement(yf.Backdrop,null),c().createElement(yf.Panel,null,c().createElement(yf.Header,null,c().createElement("div",{className:"flex items-center justify-between"},c().createElement(yf.Title,null,(0,hm.__)("Activate Theme","header-footer-elementor"))),c().createElement(yf.Description,null,(0,hm.__)("Are you sure you want to switch your current theme to Astra?","header-footer-elementor"))),c().createElement(yf.Footer,null,c().createElement(ct,{onClick:function(){return function(e){b(!1);var t=new window.FormData;t.append("action","hfe_recommended_plugin_activate"),t.append("nonce",hfe_admin_data.nonce),t.append("plugin",e.init),t.append("type",e.type),t.append("slug",e.slug);var r=document.querySelector('[data-slug="'.concat(e.slug,'"]')),o=r.querySelector("span");o.innerText=(0,hm.__)("Activating...","header-footer-elementor"),$m()({url:hfe_admin_data.ajax_url,method:"POST",body:t}).then((function(t){if(t.success)o&&(r.style.color="#16A34A",r.dataset.action="site_redirect",r.classList.add("hfe-plugin-activated"),o.innerText=(0,hm.__)("Activated","header-footer-elementor"),window.open(g,"_blank"),setTimeout((function(){n((function(e){return e+1}))}),5e3));else{e.type;var a=document.querySelector('[data-slug="'.concat(e.slug,'"]'));if(a){var i=a.querySelector("span");i&&(i.innerText=(0,hm.__)("Activate","header-footer-elementor"))}}}))}(w)}},(0,hm.__)("Yes","header-footer-elementor")),c().createElement(ct,{variant:"outline",onClick:function(){return b(!1)}},(0,hm.__)("Close","header-footer-elementor")))))))},vg=cm("chevron-left",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);function bg(e,t){var n="undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=function(e,t){if(e){if("string"==typeof e)return xg(e,t);var n={}.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?xg(e,t):void 0}}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,s=!1;return{s:function(){n=n.call(e)},n:function(){var e=n.next();return i=e.done,e},e:function(e){s=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(s)throw a}}}}function xg(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=Array(t);n0);return c().createElement(c().Fragment,null,c().createElement("style",null,"\n .uae-role-checkbox {\n position: relative;\n width: 30px;\n height: 30px;\n -webkit-appearance: none;\n appearance: none;\n border: 2px solid #d1d5db; /* gray-300 */\n border-radius: 4px;\n cursor: pointer;\n }\n\n .uae-role-checkbox:focus {\n outline: none;\n }\n\n .uae-role-checkbox:checked {\n background-color: #5C2EDE !important; /* brand-primary-600 */\n border-color: #0017E1;\n }\n\n .uae-role-checkbox:checked::after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n width: 4px;\n height: 8px;\n border-right: 2px solid #fff;\n border-bottom: 2px solid #fff;\n transform: translate(-50%, -60%) rotate(45deg);\n }\n\n\t\t\t\t\t.uae-error-field {\n\t\t\t\t\t\tborder-color: #dc3545 !important;\n\t\t\t\t\t}\n\n\t\t\t\t\t.uae-error-message {\n\t\t\t\t\t\tcolor: #dc3545;\n\t\t\t\t\t\tfont-size: 0.875rem;\n\t\t\t\t\t\tmargin-top: 0.25rem;\n\t\t\t\t\t}\n "),c().createElement("div",{className:"bg-background-primary border-[0.5px] items-start justify-center border-subtle p-4 rounded-xl shadow-sm mb-6 flex flex-col",style:{width:"42.625rem"}},B&&c().createElement("div",{className:"rounded-lg bg-white w-full"},c().createElement("div",{className:"flex flex-col items-start justify-between",style:{paddingTop:"1rem",paddingLeft:"1rem",paddingRight:"1rem"}},c().createElement("p",{className:"text-text-primary m-0 mb-2 hfe-65-width",style:{fontSize:"24px",lineHeight:"1.3em"}},(0,hm.__)("Recommended Essentials","header-footer-elementor")),c().createElement("span",{className:"text-md font-normal text-text-secondary m-0 mb-2",style:{lineHeight:"1.5em"}},(0,hm.__)("These free plugins add essential features to your website and help speed up your workflow. Select the plugins you want to install.","header-footer-elementor")),c().createElement("div",{className:"flex items-center gap-x-2 mr-7"})),c().createElement("div",{className:"flex flex-col rounded-lg",style:{backgroundColor:"white",paddingTop:"1rem",paddingLeft:"1rem",paddingRight:"1rem"}},d?c().createElement(nt,{align:"stretch",className:"gap-1 p-1 grid grid-cols-1 md:grid-cols-2",containerType:"grid",justify:"start"},Cm(Array(2)).map((function(e,t){return c().createElement(nt.Item,{key:t,alignSelf:"auto",style:{height:"150px"},className:"text-wrap rounded-md shadow-container-item bg-[#F9FAFB] p-4"},c().createElement("div",{className:"flex flex-col gap-6",style:{marginTop:"40px"}},c().createElement(Xm,{className:"w-12 h-2 rounded-md"}),c().createElement(Xm,{className:"w-16 h-2 rounded-md"}),c().createElement(Xm,{className:"w-12 h-2 rounded-md"})))}))):c().createElement(nt,{align:"stretch",className:"gap-1 p-1 grid grid-cols-1 md:grid-cols-1",containerType:"grid",justify:"start",style:{backgroundColor:"#F9FAFB"}},a.slice(0,3).map((function(e){return c().createElement(nt.Item,{key:e.slug,alignSelf:"auto",className:"text-wrap rounded-md shadow-container-item bg-background-primary p-4"},c().createElement(yg,{plugin:e,setUpdateCounter:g,onPluginSelect:L}))}))))),(!j||!B)&&c().createElement("div",{className:"px-5 pt-3 bg-white rounded-lg"},c().createElement("h3",{className:"text-base font-medium text-gray-900 ".concat(B?"":"text-xl mb-3")},(0,hm.__)("Get Important Notifications and Updates","header-footer-elementor")),c().createElement("div",{className:"flex flex-row items-start gap-4 mb-4"},c().createElement("div",{className:"flex flex-col flex-1"},c().createElement("label",{className:"text-sm font-medium text-gray-700 mb-2"},(0,hm.__)("First Name","header-footer-elementor")),c().createElement("input",{type:"text",name:"firstName",value:C.firstName,onChange:function(e){return M("firstName",e.target.value)},className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none hfe-remove-ring transition-colors ".concat(F.firstName?"uae-error-field":""),style:{height:"48px",borderColor:"#e0e0e0",outline:"none",fontSize:"14px",boxShadow:"none"}}),F.firstName&&c().createElement("span",{className:"uae-error-message"},F.firstName)),c().createElement("div",{className:"flex flex-col flex-1"},c().createElement("label",{className:"text-sm font-medium text-gray-700 mb-2"},(0,hm.__)("Last Name","header-footer-elementor")),c().createElement("input",{type:"text",name:"lastName",value:C.lastName,onChange:function(e){return M("lastName",e.target.value)},className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none hfe-remove-ring transition-colors",style:{height:"48px",borderColor:"#e0e0e0",outline:"none",fontSize:"14px",boxShadow:"none"}}))),c().createElement("div",{className:"flex flex-row items-start gap-4 mb-4"},c().createElement("div",{className:"flex flex-col flex-1"},c().createElement("label",{className:"text-sm font-medium text-gray-700 mb-2"},(0,hm.__)("Email Address","header-footer-elementor")),c().createElement("input",{type:"email",name:"email",value:C.email,onChange:function(e){return M("email",e.target.value)},className:"w-full px-3 py-2 border border-gray-300 rounded-md focus:outline-none focus:ring-2 focus:ring-purple-500 focus:border-purple-500 transition-colors ".concat(F.email?"uae-error-field":""),style:{height:"48px",borderColor:"#e0e0e0",outline:"none",fontSize:"14px",boxShadow:"none"}}),F.email&&c().createElement("span",{className:"uae-error-message"},F.email))),c().createElement("div",{className:"flex items-start gap-1"},c().createElement("input",{type:"checkbox",id:"notifications-checkbox",checked:w,onChange:O,className:"uae-role-checkbox mt-1 h-4 w-4 text-[#5C2EDE] focus:ring-[#5C2EDE] border-gray-300 rounded"}),c().createElement("label",{htmlFor:"notifications-checkbox",className:"text-sm text-gray-600 leading-relaxed"},(0,hm.__)("Stay in the loop and help shape Ultimate Addons for Elementor! Get feature updates, and help us build a better Ultimate Addons for Elementor by sharing how you use the plugin. ","header-footer-elementor"),c().createElement("a",{href:"https://store.brainstormforce.com/privacy-policy/?utm_source=uae_onboarding&utm_medium=notification_updates&utm_campaign=privacy_policy",className:"text-sm text-text-primary",target:"_blank"},(0,hm.__)(" Privacy Policy","header-footer-elementor"))))),c().createElement("div",{className:"flex w-full justify-between items-center hfe-onboarding-bottom",style:{paddingLeft:"8px",paddingRight:"8px",paddingTop:"30px"}},c().createElement(ct,{className:"flex items-center gap-1 hfe-remove-ring",icon:c().createElement(vg,null),variant:"outline",onClick:function(){return t(1)}},(0,hm.__)("Back","header-footer-elementor")),c().createElement("div",{className:"flex justify-between gap-3 items-center",style:{paddingRight:"1.875rem"}},c().createElement(ct,{className:"hfe-remove-ring text-text-tertiary",variant:"ghost",onClick:function(){r("configure"),t(3)}}," ",(0,hm.__)("Skip","header-footer-elementor")),c().createElement(ct,{className:"flex items-center gap-1 hfe-remove-ring",icon:c().createElement(rh,null),iconPosition:"right",style:{backgroundColor:"#5C2EDE",transition:"background-color 0.3s ease",padding:"12px"},onClick:function(){if("true"===localStorage.getItem("uaeFormSubmitted")&&B)a.length>0&&z(),n("configure"),t(3);else{var e,r,o={};if(null!==(e=C.email)&&void 0!==e&&e.trim()?/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(C.email.trim())||(o.email=(0,hm.__)("Please enter a valid email address","header-footer-elementor")):o.email=(0,hm.__)("This field is required","header-footer-elementor"),null!==(r=C.firstName)&&void 0!==r&&r.trim()||(o.firstName=(0,hm.__)("This field is required","header-footer-elementor")),Object.keys(o).length>0)return void D(o);D({}),a.length>0&&z(),function(e,n,r,o,a){if(e){var i=(new Date).toISOString().split("T")[0],s=a||window.location.hostname,l=new URLSearchParams({email:e,date:i,fname:n||"",lname:r||"",isActive:o?"yes":"no"});o&&l.append("domain",s),fetch("/wp-json/hfe/v1/email-webhook/?".concat(l.toString()),{method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":hfeSettingsData.hfe_nonce_action}}).then((function(e){if(!e.ok)throw new Error("HTTP error! Status: ".concat(e.status));return e.json()})).then((function(e){"success"===e.message||console.warn("Unexpected webhook response:",e),t(3)})).catch((function(e){console.error("Error calling webhook:",e),t(3)}))}else t(3)}(C.email,C.firstName,C.lastName,w,C.domain),localStorage.setItem("uaeFormSubmitted","true"),A(!0),fetch(hfe_admin_data.ajax_url,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:new URLSearchParams({action:"save_analytics_option",uae_usage_optin:w?"yes":"no",nonce:hfe_admin_data.nonce})}).catch((function(){})),n("configure"),t(3)}}},(0,hm.__)("Next","header-footer-elementor"))))))}},{label:"",component:function(e){var t=e.setCurrentStep,n=e.markStepCompleted,r=e.markStepSkipped,o=i((0,s.useState)({headerFooterBuilder:!1,megaMenu:!1,modalPopup:!1,wooCommerceWidgets:!1,premiumWidgets:!1}),2),a=o[0],l=o[1],u=function(e){l((function(t){return Sg(Sg({},t),{},h({},e,!t[e]))}))},d=(a.headerFooterBuilder||a.megaMenu,a.modalPopup||a.wooCommerceWidgets||a.premiumWidgets);return c().createElement(c().Fragment,null,c().createElement("style",null,"\n .uae-role-checkbox {\n position: relative;\n width: 30px;\n height: 30px;\n -webkit-appearance: none;\n appearance: none;\n border: 2px solid #d1d5db; /* gray-300 */\n border-radius: 4px;\n cursor: pointer;\n outline: none;\n }\n\n .uae-role-checkbox:focus {\n outline: none;\n box-shadow: none;\n }\n\n .uae-role-checkbox:checked {\n background-color: #5C2EDE;\n border-color: #0017E1;\n outline: none;\n }\n\n .uae-role-checkbox:checked::after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n width: 4px;\n height: 8px;\n border-right: 2px solid #fff;\n border-bottom: 2px solid #fff;\n transform: translate(-50%, -60%) rotate(45deg);\n }\n "),c().createElement("div",{className:"box-border bg-background-primary p-6 rounded-lg",style:{width:"42.625rem"}},c().createElement("p",{className:"text-text-primary m-0 mb-2 hfe-65-width",style:{fontSize:"24px",lineHeight:"1.3em"}},(0,hm.__)("Select Your Features","header-footer-elementor")),c().createElement("span",{className:"text-sm font-normal text-text-secondary",style:{lineHeight:"1.5em"}},(0,hm.__)("Unlock more design control, faster setup, and powerful customization so you can build a better website, effortlessly.","header-footer-elementor")),c().createElement("div",{className:"relative",style:{marginTop:"20px"}},c().createElement("div",{className:"flex items-center justify-between gap-3 mt-5 cursor-pointer",onClick:function(e){u("headerFooterBuilder")}},c().createElement("div",{className:"flex flex-col space-y-1 flex-1"},c().createElement("div",{className:"flex items-center justify-start gap-1"},c().createElement("div",{className:"text-sm font-normal m-0"},(0,hm.__)("Header & Footer Builder","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("Free","header-footer-elementor"),size:"xs",type:"pill",variant:"green"})),c().createElement("div",{className:"text-sm font-normal m-0",style:{maxWidth:"90%",color:"#9CA3AF"}},(0,hm.sprintf)((0,hm.__)("Assign headers and footers to specific pages or post types. This gives users complete layout control, something typically locked behind Pro plugins.","header-footer-elementor")))),c().createElement("div",{className:"flex-shrink-0"},c().createElement("input",{type:"checkbox",checked:a.headerFooterBuilder,onClick:function(e){return e.stopPropagation()},onChange:function(){return u("headerFooterBuilder")},className:"uae-role-checkbox w-5 h-5 outline-none",style:{accentColor:"#240064",width:"18px",height:"18px"}})))),c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginTop:"10px",marginBottom:"10px",borderColor:"#E5E7EB"}}),c().createElement("div",{className:"flex items-center justify-between gap-3 cursor-pointer",onClick:function(){return u("megaMenu")}},c().createElement("div",{className:"flex flex-col space-y-1 flex-1"},c().createElement("div",{className:"flex items-center justify-start gap-1"},c().createElement("div",{className:"text-sm font-normal m-0"},(0,hm.__)("Mega Menu & Navigation Widget","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("Free","header-footer-elementor"),size:"xs",type:"pill",variant:"green"})),c().createElement("div",{style:{color:"#9CA3AF"},className:"text-sm font-normal m-0"},(0,hm.sprintf)((0,hm.__)("Save hours by copying Elementor sections, widgets, or pages from one website to another no need to rebuild layouts from scratch.","header-footer-elementor")))),c().createElement("div",{className:"flex-shrink-0"},c().createElement("input",{type:"checkbox",checked:a.megaMenu,onClick:function(e){return e.stopPropagation()},onChange:function(){return u("megaMenu")},className:"uae-role-checkbox w-5 h-5",style:{accentColor:"#240064",width:"18px",height:"18px"}}))),c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginTop:"10px",marginBottom:"10px",borderColor:"#E5E7EB"}}),c().createElement("div",{className:"flex items-center justify-between gap-3 cursor-pointer",onClick:function(){return u("modalPopup")}},c().createElement("div",{className:"flex flex-col space-y-1 flex-1"},c().createElement("div",{className:"flex items-center justify-start gap-1"},c().createElement("div",{className:"text-sm font-normal m-0"},(0,hm.__)("Modal Popup","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("Pro","header-footer-elementor"),size:"xs",type:"pill",variant:"inverse"})),c().createElement("div",{style:{color:"#9CA3AF"},className:"text-sm font-normal m-0"},(0,hm.sprintf)((0,hm.__)("Design eye-catching popups directly in Elementor collect leads, display promotions, or show messages without needing a separate popup plugin.","header-footer-elementor")))),c().createElement("div",{className:"flex-shrink-0"},c().createElement("input",{type:"checkbox",checked:a.modalPopup,onClick:function(e){return e.stopPropagation()},onChange:function(){return u("modalPopup")},className:"uae-role-checkbox w-5 h-5",style:{accentColor:"#240064",width:"18px",height:"18px"}}))),c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginTop:"10px",marginBottom:"10px",borderColor:"#E5E7EB"}}),c().createElement("div",{className:"flex items-center justify-between gap-3 cursor-pointer",onClick:function(){return u("wooCommerceWidgets")}},c().createElement("div",{className:"flex flex-col space-y-1 flex-1"},c().createElement("div",{className:"flex items-center justify-start gap-1"},c().createElement("div",{className:"text-sm font-normal m-0"},(0,hm.__)("WooCommerce Widgets","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("Pro","header-footer-elementor"),size:"xs",type:"pill",variant:"inverse"})),c().createElement("div",{style:{color:"#9CA3AF"},className:"text-sm font-normal m-0"},(0,hm.__)("Design eye-catching popups directly in Elementor collect leads, display promotions, or show messages without needing a separate popup plugin.","header-footer-elementor"))),c().createElement("div",{className:"flex-shrink-0"},c().createElement("input",{type:"checkbox",checked:a.wooCommerceWidgets,onClick:function(e){return e.stopPropagation()},onChange:function(){return u("wooCommerceWidgets")},className:"uae-role-checkbox w-5 h-5",style:{accentColor:"#240064",width:"18px",height:"18px"}}))),c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginTop:"10px",marginBottom:"10px",borderColor:"#E5E7EB"}}),c().createElement("div",{className:"flex items-center justify-between gap-3 cursor-pointer",onClick:function(){return u("premiumWidgets")}},c().createElement("div",{className:"flex flex-col space-y-1 flex-1"},c().createElement("div",{className:"flex items-center justify-start gap-1"},c().createElement("div",{className:"text-sm font-normal m-0"},(0,hm.__)("50+ Premium Widgets & 200+ Templates","header-footer-elementor")),c().createElement(rm,{label:(0,hm.__)("Pro","header-footer-elementor"),size:"xs",type:"pill",variant:"inverse"})),c().createElement("div",{style:{color:"#9CA3AF"},className:"text-sm font-normal m-0"},(0,hm.__)("Design eye-catching popups directly in Elementor collect leads, display promotions, or show messages without needing a separate popup plugin.","header-footer-elementor"))),c().createElement("div",{className:"flex-shrink-0"},c().createElement("input",{type:"checkbox",checked:a.premiumWidgets,onClick:function(e){return e.stopPropagation()},onChange:function(){return u("premiumWidgets")},className:"uae-role-checkbox w-5 h-5",style:{accentColor:"#240064",width:"18px",height:"18px"}}))),c().createElement("div",{className:"flex justify-between items-center px-2 hfe-onboarding-bottom",style:{paddingTop:"30px"}},c().createElement(ct,{className:"flex items-center gap-1 outline-none hfe-remove-ring",icon:c().createElement(vg,null),variant:"outline",onClick:function(){return t(2)}},(0,hm.__)("Back","header-footer-elementor")),c().createElement("div",{className:"flex justify-start text-text-tertiary items-center gap-3"},c().createElement(ct,{className:"hfe-remove-ring text-text-tertiary",variant:"ghost",onClick:function(){r("features"),t(4)}}," ",(0,hm.__)("Skip","header-footer-elementor")),d?c().createElement(ct,{className:"flex items-center gap-1 hfe-remove-ring",icon:c().createElement(rh,null),iconPosition:"right",style:{backgroundColor:"#5C2EDE",transition:"background-color 0.3s ease",padding:"12px"},onClick:function(){window.open("https://ultimateelementor.com/pricing/?utm_source=wp-admin&utm_medium=onboarding&utm_campaign=uae-upgrade","_blank")}},(0,hm.__)("Upgrade","header-footer-elementor")):c().createElement(ct,{className:"flex items-center gap-1 hfe-remove-ring",icon:c().createElement(rh,null),iconPosition:"right",style:{backgroundColor:"#5C2EDE",transition:"background-color 0.3s ease",padding:"12px"},onClick:function(){n("features"),t(4)}},(0,hm.__)("Next","header-footer-elementor")))),d&&c().createElement("div",{className:"mt-4 p-3 rounded-lg border border-gray-400 bg-gray-50",style:{backgroundColor:"#F9FAFB",borderColor:"#E5E7EB",marginTop:"16px"}},c().createElement("div",{className:"text-sm border border-gray-400 text-gray-700 font-medium"},(0,hm.__)("You've picked Pro features upgrade to start using them.","header-footer-elementor")))))}},{label:"",component:function(e){e.setCurrentStep;var t=e.saveOnboardingAnalytics,n=e.stepsCompleted,r=e.stepsSkipped,o=i((0,s.useState)(!1),2),a=o[0],l=o[1],u=i((0,s.useState)(""),2),d=u[0],m=u[1],f=i((0,s.useState)(""),2),p=f[0],h=f[1],g=i((0,s.useState)(""),2),y=g[0],v=g[1],b=i((0,s.useState)(!0),2),x=(b[0],b[1]),w=i((0,s.useState)(""),2),E=w[0],_=w[1],k=i((0,s.useState)(""),2),S=k[0],N=k[1],C=i((0,s.useState)(!1),2),P=C[0],T=C[1];(0,s.useEffect)((function(){m(hfeSettingsData.user_email),x("yes"===hfeSettingsData.analytics_status);var e=(null==n?void 0:n.current)||JSON.parse(localStorage.getItem("hfe_onboarding_steps_completed")||"[]"),o=(null==r?void 0:r.current)||JSON.parse(localStorage.getItem("hfe_onboarding_steps_skipped")||"[]");t({exitedEarly:!1,exitAtStep:"",completedSteps:e,skippedSteps:o}),localStorage.removeItem("hfe_onboarding_steps_completed"),localStorage.removeItem("hfe_onboarding_steps_skipped"),history.pushState(null,"",window.location.href);var a=function(e){e.preventDefault(),localStorage.setItem("currentStep","2"),window.location.reload()};return window.addEventListener("popstate",a),function(){window.removeEventListener("popstate",a)}}),[hfeSettingsData.user_email]);return c().createElement("div",{className:"bg-background-primary border-[0.5px] border-subtle rounded-xl shadow-sm mb-6 p-8",style:{width:"672px"}},c().createElement("div",{className:"flex items-start hfe-display-flex"},c().createElement("div",{className:"flex flex-col items-start",style:{paddingRight:"35px"}},c().createElement("h1",{className:"text-text-primary m-0 mb-2",style:{fontSize:"1.4rem",lineHeight:"1.3em"}},(0,hm.__)("You’re All Set to Start Creating! 🚀","header-footer-elementor")),c().createElement("span",{className:"text-sm font-normal text-text-tertiary m-0 mb-4 ",style:{lineHeight:"1.6em"}},(0,hm.__)("Ultimate Addons is ready to supercharge your Elementor workflow! Build faster, cleaner, and more creatively — with complete control over your site.","header-footer-elementor")),c().createElement("span",{className:"font-semibold m-0 pt-2"},(0,hm.__)("What You Can Do Next:","header-footer-elementor")),c().createElement("ul",{className:"font-normal",style:{fontSize:"0.9rem",lineHeight:"1.6em",color:"#111827"}},c().createElement("li",{className:"font-normal",style:{display:"flex",alignItems:"center",justifyContent:"flex-start",gap:"0.5rem",color:"#111827"}},c().createElement(sf,{color:"#111827",size:18}),(0,hm.__)("Build a custom header","header-footer-elementor")),c().createElement("li",{className:"font-normal ",style:{display:"flex",alignItems:"center",justifyContent:"flex-start",gap:"0.5rem",color:"#111827"}},c().createElement(sf,{color:"#111827",size:18}),(0,hm.__)("Design your site footer","header-footer-elementor")),c().createElement("li",{className:"font-normal",style:{display:"flex",alignItems:"center",justifyContent:"flex-start",gap:"0.5rem",color:"#111827"}},c().createElement(sf,{color:"#111827",size:18}),(0,hm.__)("Create a new page","header-footer-elementor"))),c().createElement("hr",{className:"w-full border-b-0 border-x-0 border-t border-solid border-t-border-subtle",style:{marginBottom:"20px",borderColor:"#E5E7EB"}})),c().createElement("div",{className:"",style:{textAlign:"end"}},c().createElement("img",{alt:"Build",className:"w-full object-contain",style:{height:"130px",width:"160px"},src:"".concat(hfeSettingsData.create_new),loading:"lazy"}))),c().createElement("div",{className:"flex flex-row pt-2 items-center justify-between gap-1 pb-4 hfe-display-flex"},c().createElement("div",{className:"flex items-center justify-start gap-3"},c().createElement(ct,{iconPosition:"right",variant:"outline",className:"hfe-remove-ring text-sm font-semibold",style:{transition:"background-color 0.3s ease"},onMouseEnter:function(e){return e.currentTarget.style.backgroundColor=""},onMouseLeave:function(e){return e.currentTarget.style.backgroundColor=""},onClick:function(){window.open(hfeSettingsData.hfe_post_url,"_self")}},(0,hm.__)("Create New Header","header-footer-elementor")),c().createElement(ct,{iconPosition:"right",variant:"outline",className:"hfe-remove-ring text-sm font-semibold",style:{transition:"background-color 0.3s ease"},onMouseEnter:function(e){return e.currentTarget.style.backgroundColor=""},onMouseLeave:function(e){return e.currentTarget.style.backgroundColor=""},onClick:function(){window.open(hfeSettingsData.hfe_post_url,"_self")}},(0,hm.__)("Create New Footer","header-footer-elementor"))),c().createElement(ct,{iconPosition:"right",variant:"outline",className:"hfe-remove-ring text-sm font-semibold",style:{color:"",borderColor:""},onMouseEnter:function(e){return e.currentTarget.style.color="#000000"},onMouseLeave:function(e){return(e.currentTarget.style.color="")&&(e.currentTarget.style.borderColor="")},onClick:function(){window.open(hfeSettingsData.elementor_page_url,"_blank")}},(0,hm.__)("Create New Page","header-footer-elementor"))),c().createElement(yf,{design:"simple",open:a,setOpen:l},c().createElement(yf.Backdrop,null),c().createElement(yf.Panel,null,c().createElement(yf.Header,{style:{padding:"30px",marginBottom:"0.5rem"}},c().createElement("div",{className:"flex items-center justify-between"},c().createElement("div",{className:"flex items-center justify-center"},c().createElement(yf.Title,{style:{fontSize:"1.6rem",width:"80%",lineHeight:"1.3em"}},(0,hm.__)("We have a special Reward just for you! 🎁","header-footer-elementor")),c().createElement(ct,{icon:c().createElement(cg,{className:"size-10"}),iconPosition:"right",size:"md",variant:"ghost",className:"hfe-remove-ring self-start",onClick:function(){return l(!1)},style:{marginLeft:"60px",marginBottom:"20px"}}))),c().createElement(yf.Description,{style:{width:"90%",color:"#64748B",marginTop:"10px"}},(0,hm.__)("Enter your details to get special offer that we have for you and stay updated on UAE’s latest news and updates.","header-footer-elementor")),c().createElement("div",{className:"flex w-full",style:{marginTop:"15px"}},c().createElement("div",{className:"block",style:{width:"50%",paddingRight:"13px"}},c().createElement("input",{type:"text",placeholder:(0,hm.__)("First Name","header-footer-elementor"),value:p,className:"h-12 border border-subtle px-2 w-full",style:{borderColor:"#e0e0e0",outline:"none",boxShadow:"none",marginTop:"5px"},onFocus:function(e){return e.target.style.borderColor="#6005FF"},onBlur:function(e){return e.target.style.borderColor="#e0e0e0"},onChange:function(e){e&&e.target&&(N(""),h(e.target.value))}}),S&&c().createElement("span",{className:"absolute color-text-danger text-xs text-sm font-normal",style:{color:"#FF0000",marginTop:"0px"}},S)),c().createElement("div",{className:"block",style:{width:"50%"}},c().createElement("input",{type:"text",placeholder:(0,hm.__)("Last Name","header-footer-elementor"),value:y,className:"h-12 border border-subtle px-2 w-full",style:{borderColor:"#e0e0e0",outline:"none",boxShadow:"none",marginTop:"5px"},onFocus:function(e){return e.target.style.borderColor="#6005FF"},onBlur:function(e){return e.target.style.borderColor="#e0e0e0"},onChange:function(e){e&&e.target&&v(e.target.value)}}))),c().createElement("input",{type:"email",placeholder:(0,hm.__)("Your Email Address","header-footer-elementor"),value:d,className:"h-12 border border-subtle px-2 w-full",style:{borderColor:"#e0e0e0",outline:"none",boxShadow:"none",marginTop:"20px"},onFocus:function(e){return e.target.style.borderColor="#6005FF"},onBlur:function(e){return e.target.style.borderColor="#e0e0e0"},onChange:function(e){e&&e.target&&(_(""),m(e.target.value))}}),E&&c().createElement("span",{className:"absolute color-text-danger text-xs text-sm font-normal",style:{color:"#FF0000",marginTop:"0px"}},E),c().createElement(ct,{icon:P?c().createElement(LoaderCircle,{className:"animate-spin"}):null,iconPosition:"right",variant:"primary",className:"bg-[#6005FF] hfe-remove-ring w-full mt-2",disabled:P,style:{backgroundColor:"#6005FF",transition:"background-color 0.3s ease",marginTop:"20px"},onMouseEnter:function(e){return e.currentTarget.style.backgroundColor="#4B00CC"},onMouseLeave:function(e){return e.currentTarget.style.backgroundColor="#6005FF"},onClick:function(){var e=!1;p.trim()?N(""):(N((0,hm.__)("This field is required","header-footer-elementor")),e=!0),/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(d)?_(""):(_((0,hm.__)("Entered email address is invalid!","header-footer-elementor")),e=!0),e||(_(""),N(""),T(!0),function(e,t,n){var r=(new Date).toISOString().split("T")[0],o=new URLSearchParams({email:e,date:r,fname:t,lname:n});fetch("/wp-json/hfe/v1/email-webhook/?".concat(o.toString()),{method:"POST",headers:{"Content-Type":"application/json","X-WP-Nonce":hfeSettingsData.hfe_nonce_action}}).then((function(e){if(!e.ok)throw new Error("HTTP error! Status: ".concat(e.status));return e.json()})).then((function(e){"success"===e.message?(T(!1),window.location.href=hfeSettingsData.onboarding_success_url):(T(!1),console.warn("Unexpected webhook response:",e))})).catch((function(e){console.error("Error calling webhook:",e)}))}(d,p,y))}},(0,hm.__)("Submit","header-footer-elementor"))))))}}],Cg=Ng.slice(0,4),Pg={1:"welcome",2:"configure",3:"features",4:"success"},Tg=function(e){var t=new URLSearchParams;t.append("action","hfe_save_onboarding_analytics"),t.append("nonce",hfe_admin_data.nonce),t.append("exited_early",e.exitedEarly?"true":"false"),t.append("exit_at_step",e.exitAtStep||""),(e.completedSteps||[]).forEach((function(e){return t.append("completed_steps[]",e)})),(e.skippedSteps||[]).forEach((function(e){return t.append("skipped_steps[]",e)})),fetch(hfe_admin_data.ajax_url,{method:"POST",headers:{"Content-Type":"application/x-www-form-urlencoded"},body:t}).catch((function(e){return console.error("Onboarding analytics error:",e)}))};const jg=function(){var e,t=i(c().useState((function(){var e=localStorage.getItem("currentStep");return e?parseInt(e,10):1})),2),n=t[0],r=t[1],o=(0,s.useRef)(JSON.parse(localStorage.getItem("hfe_onboarding_steps_completed")||"[]")),a=(0,s.useRef)(JSON.parse(localStorage.getItem("hfe_onboarding_steps_skipped")||"[]")),l=(0,s.useCallback)((function(e){o.current.includes(e)||(o.current.push(e),localStorage.setItem("hfe_onboarding_steps_completed",JSON.stringify(o.current)))}),[]),u=(0,s.useCallback)((function(e){a.current.includes(e)||(a.current.push(e),localStorage.setItem("hfe_onboarding_steps_skipped",JSON.stringify(a.current)))}),[]);(0,s.useEffect)((function(){localStorage.setItem("currentStep",n)}),[n]),(0,s.useEffect)((function(){var e=setTimeout((function(){localStorage.removeItem("currentStep")}),18e4);return function(){return clearTimeout(e)}}),[]);var d=null===(e=Ng[n-1])||void 0===e?void 0:e.component;return c().createElement("div",null,c().createElement("div",{className:"w-full"},c().createElement("div",{className:"flex flex-col items-center justify-center",style:{marginTop:"-38px",marginBottom:"24px"}},c().createElement(ot,{className:"bg-none",style:{background:"none"}},c().createElement(ot.Left,null,c().createElement(ot.Item,null,hfeSettingsData.icon_svg&&c().createElement(D,{to:gm.dashboard.path},c().createElement("img",{src:"".concat(hfeSettingsData.icon_new),alt:"Logo",className:"cursor-pointer",style:{height:"35px"}})))),c().createElement(ot.Middle,null,c().createElement(ot.Item,null,c().createElement(pg,{currentStep:Math.min(n,Cg.length),className:"uae-steps",variant:"number",completedVariant:"number"},Cg.map((function(e,t){return c().createElement(pg.Step,{key:t,className:"font-bold",labelText:e.label,size:"md"})}))))),c().createElement(ot.Right,null,c().createElement(ot.Item,null,c().createElement(D,{className:"hfe-remove-ring",to:gm.dashboard.path,onClick:function(){n>=4||(Tg({exitedEarly:!0,exitAtStep:Pg[n]||"",completedSteps:o.current,skippedSteps:a.current}),localStorage.removeItem("hfe_onboarding_steps_completed"),localStorage.removeItem("hfe_onboarding_steps_skipped"))}},c().createElement("div",{className:"flex items-center cursor-pointer justify-center gap-1"},c().createElement("p",{style:{fontSize:"0.9rem",color:"#111827"}},(0,hm.__)("Exit Guided Setup","header-footer-elementor")),c().createElement(ct,{icon:c().createElement(cg,{className:"size-4"}),iconPosition:"right",size:"xs",variant:"ghost",className:"hfe-remove-ring"})))))))),c().createElement("div",{className:"flex items-center justify-center"},d&&c().createElement(d,{currentStep:n,setCurrentStep:r,saveOnboardingAnalytics:Tg,markStepCompleted:l,markStepSkipped:u,stepsCompleted:o,stepsSkipped:a})))},Ag=function(){return(0,s.useEffect)((function(){var e=document.body;return e.classList.add("hfe-onboarding-fullscreen"),function(){e.classList.remove("hfe-onboarding-fullscreen")}}),[]),c().createElement(c().Fragment,null,c().createElement(jg,null))},Rg=function(){var e;return React.createElement(O,{routes:gm,defaultRoute:null==gm||null===(e=gm.dashboard)||void 0===e?void 0:e.path},React.createElement(T,{path:gm.dashboard.path},React.createElement(Af,null)),React.createElement(T,{path:gm.onboarding.path},React.createElement(Ag,null)),React.createElement(T,{path:gm.widgets.path},React.createElement(Lf,null)),React.createElement(T,{path:gm.templates.path},React.createElement(Vf,null)),React.createElement(T,{path:gm.learn.path},React.createElement(lg,null)),React.createElement(T,{path:gm.settings.path},React.createElement(xh,null)),React.createElement(T,{path:gm.upgrade.path},React.createElement(dg,null)))},Fg=Ld("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]),Dg=({variant:e="primary",size:t="md",icon:n=null,className:r=""})=>{const o={primary:"text-brand-primary-600",secondary:"text-background-primary"}[e],a={sm:"[&>svg]:size-4",md:"[&>svg]:size-5",lg:"[&>svg]:size-6",xl:"[&>svg]:size-8"}[t];return(0,I.jsx)("span",{className:Fe("flex",a,o,r),children:n||(0,I.jsx)(Fg,{className:"animate-spin shrink-0"})})},Mg=function(){var e=i((0,s.useState)(!1),2),t=e[0],n=e[1],r=i((0,s.useState)(!0),2);return r[0],r[1],window.onhashchange=function(){window.scrollTo(0,0)},(0,s.useEffect)((function(){setTimeout((function(){n(!0)}),1e3)}),[]),t?React.createElement("div",{className:"app-container font-figtree"},React.createElement(Rg,null)):React.createElement("div",{className:"loading-spinner flex items-center justify-center h-screen",style:{background:"#F9FAFB"}},React.createElement(Dg,{icon:null,size:"lg",variant:"primary"}))};n()((function(){var t=document.getElementById("hfe-settings-app");if(t&&(0,e.H)(t).render(React.createElement(Mg,null)),"yes"===hfe_admin_data.show_view_all||window.location.href===hfeSettingsData.header_footer_builder||"yes"===hfeSettingsData.is_hfe_post){var n=document.getElementById("hfe-admin-top-bar-root");if(n){var r=document.createElement("div");r.id="hfe-settings-app",n.appendChild(r),(0,e.H)(r).render(React.createElement(Nm,null))}}}))})()})(); //# sourceMappingURL=main.js.map