!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react"),require("lodash")):"function"==typeof define&&define.amd?define("rb_wixui.thunderbolt[DropDownMenu_SeparateLinesMenuButtonSkin]",["react","lodash"],t):"object"==typeof exports?exports["rb_wixui.thunderbolt[DropDownMenu_SeparateLinesMenuButtonSkin]"]=t(require("react"),require("lodash")):e["rb_wixui.thunderbolt[DropDownMenu_SeparateLinesMenuButtonSkin]"]=t(e.React,e._)}(self,(e,t)=>(()=>{var r={75178(e,t,r){e.exports=r(33188)(r(37183),"DataView")},48561(e,t,r){e.exports=r(33188)(r(37183),"Map")},1490(e,t,r){e.exports=r(33188)(r(37183),"Promise")},96775(e,t,r){e.exports=r(33188)(r(37183),"Set")},7187(e,t,r){e.exports=r(37183).Symbol},88985(e,t,r){e.exports=r(33188)(r(37183),"WeakMap")},16990(e,t,r){var n=r(7187),o=r(51029),a=r(8704),i=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":i&&i in Object(e)?o(e):a(e)}},46252(e,t,r){var n=r(16990),o=r(46184);e.exports=function(e){return o(e)&&"[object Arguments]"==n(e)}},73829(e,t,r){var n=r(94360),o=r(67234),a=r(46015),i=r(70275),l=/^\[object .+?Constructor\]$/,s=Object.prototype,u=Function.prototype.toString,c=s.hasOwnProperty,p=RegExp("^"+u.call(c).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");e.exports=function(e){return!(!a(e)||o(e))&&(n(e)?p:l).test(i(e))}},84271(e,t,r){var n=r(16990),o=r(31784),a=r(46184),i={};i["[object Float32Array]"]=i["[object Float64Array]"]=i["[object Int8Array]"]=i["[object Int16Array]"]=i["[object Int32Array]"]=i["[object Uint8Array]"]=i["[object Uint8ClampedArray]"]=i["[object Uint16Array]"]=i["[object Uint32Array]"]=!0,i["[object Arguments]"]=i["[object Array]"]=i["[object ArrayBuffer]"]=i["[object Boolean]"]=i["[object DataView]"]=i["[object Date]"]=i["[object Error]"]=i["[object Function]"]=i["[object Map]"]=i["[object Number]"]=i["[object Object]"]=i["[object RegExp]"]=i["[object Set]"]=i["[object String]"]=i["[object WeakMap]"]=!1,e.exports=function(e){return a(e)&&o(e.length)&&!!i[n(e)]}},29966(e,t,r){var n=r(88089),o=r(6128),a=Object.prototype.hasOwnProperty;e.exports=function(e){if(!n(e))return o(e);var t=[];for(var r in Object(e))a.call(e,r)&&"constructor"!=r&&t.push(r);return t}},26143(e){e.exports=function(e){return function(t){return e(t)}}},85171(e,t,r){e.exports=r(37183)["__core-js_shared__"]},75194(e,t,r){e.exports="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g},33188(e,t,r){var n=r(73829),o=r(91870);e.exports=function(e,t){var r=o(e,t);return n(r)?r:void 0}},51029(e,t,r){var n=r(7187),o=Object.prototype,a=o.hasOwnProperty,i=o.toString,l=n?n.toStringTag:void 0;e.exports=function(e){var t=a.call(e,l),r=e[l];try{e[l]=void 0;var n=!0}catch(e){}var o=i.call(e);return n&&(t?e[l]=r:delete e[l]),o}},58355(e,t,r){var n=r(75178),o=r(48561),a=r(1490),i=r(96775),l=r(88985),s=r(16990),u=r(70275),c="[object Map]",p="[object Promise]",d="[object Set]",b="[object WeakMap]",f="[object DataView]",h=u(n),m=u(o),y=u(a),v=u(i),x=u(l),j=s;(n&&j(new n(new ArrayBuffer(1)))!=f||o&&j(new o)!=c||a&&j(a.resolve())!=p||i&&j(new i)!=d||l&&j(new l)!=b)&&(j=function(e){var t=s(e),r="[object Object]"==t?e.constructor:void 0,n=r?u(r):"";if(n)switch(n){case h:return f;case m:return c;case y:return p;case v:return d;case x:return b}return t}),e.exports=j},91870(e){e.exports=function(e,t){return null==e?void 0:e[t]}},67234(e,t,r){var n,o=r(85171),a=(n=/[^.]+$/.exec(o&&o.keys&&o.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"";e.exports=function(e){return!!a&&a in e}},88089(e){var t=Object.prototype;e.exports=function(e){var r=e&&e.constructor;return e===("function"==typeof r&&r.prototype||t)}},6128(e,t,r){e.exports=r(61429)(Object.keys,Object)},43271(e,t,r){e=r.nmd(e);var n=r(75194),o=t&&!t.nodeType&&t,a=o&&e&&!e.nodeType&&e,i=a&&a.exports===o&&n.process,l=function(){try{var e=a&&a.require&&a.require("util").types;if(e)return e;return i&&i.binding&&i.binding("util")}catch(e){}}();e.exports=l},8704(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},61429(e){e.exports=function(e,t){return function(r){return e(t(r))}}},37183(e,t,r){var n=r(75194),o="object"==typeof self&&self&&self.Object===Object&&self;e.exports=n||o||Function("return this")()},70275(e){var t=Function.prototype.toString;e.exports=function(e){if(null!=e){try{return t.call(e)}catch(e){}try{return e+""}catch(e){}}return""}},95962(e,t,r){var n=r(46252),o=r(46184),a=Object.prototype,i=a.hasOwnProperty,l=a.propertyIsEnumerable;e.exports=n(function(){return arguments}())?n:function(e){return o(e)&&i.call(e,"callee")&&!l.call(e,"callee")}},64383(e){e.exports=Array.isArray},19592(e,t,r){var n=r(94360),o=r(31784);e.exports=function(e){return null!=e&&o(e.length)&&!n(e)}},78098(e,t,r){e=r.nmd(e);var n=r(37183),o=r(11329),a=t&&!t.nodeType&&t,i=a&&e&&!e.nodeType&&e,l=i&&i.exports===a?n.Buffer:void 0,s=l?l.isBuffer:void 0;e.exports=s||o},55359(e,t,r){var n=r(29966),o=r(58355),a=r(95962),i=r(64383),l=r(19592),s=r(78098),u=r(88089),c=r(63905),p=Object.prototype.hasOwnProperty;e.exports=function(e){if(null==e)return!0;if(l(e)&&(i(e)||"string"==typeof e||"function"==typeof e.splice||s(e)||c(e)||a(e)))return!e.length;var t=o(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(u(e))return!n(e).length;for(var r in e)if(p.call(e,r))return!1;return!0}},94360(e,t,r){var n=r(16990),o=r(46015);e.exports=function(e){if(!o(e))return!1;var t=n(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}},31784(e){e.exports=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=0x1fffffffffffff}},46015(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},46184(e){e.exports=function(e){return null!=e&&"object"==typeof e}},63905(e,t,r){var n=r(84271),o=r(26143),a=r(43271),i=a&&a.isTypedArray;e.exports=i?o(i):n},11329(e){e.exports=function(){return!1}},89094(e,t,r){"use strict";var n=r(87006),o=Symbol.for("react.element"),a=(Symbol.for("react.fragment"),Object.prototype.hasOwnProperty),i=n.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function s(e,t,r){var n,s={},u=null,c=null;for(n in void 0!==r&&(u=""+r),void 0!==t.key&&(u=""+t.key),void 0!==t.ref&&(c=t.ref),t)a.call(t,n)&&!l.hasOwnProperty(n)&&(s[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps)void 0===s[n]&&(s[n]=t[n]);return{$$typeof:o,type:e,key:u,ref:c,props:s,_owner:i.current}}t.jsx=s,t.jsxs=s},36870(e,t,r){"use strict";e.exports=r(89094)},58478(e){"use strict";e.exports=t},87006(t){"use strict";t.exports=e}},n={};function o(e){var t=n[e];if(void 0!==t)return t.exports;var a=n[e]={id:e,loaded:!1,exports:{}};return r[e](a,a.exports,o),a.loaded=!0,a.exports}o.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return o.d(t,{a:t}),t},o.d=(e,t)=>{for(var r in t)o.o(t,r)&&!o.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},o.g=(()=>{if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}})(),o.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),o.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var a={};return(()=>{"use strict";let e;o.r(a),o.d(a,{components:()=>A});var t=o(36870),r=o(87006);let n=function(){for(var e,t,r=0,n="";r<arguments.length;)(e=arguments[r++])&&(t=function e(t){var r,n,o="";if("string"==typeof t||"number"==typeof t)o+=t;else if("object"==typeof t)if(Array.isArray(t))for(r=0;r<t.length;r++)t[r]&&(n=e(t[r]))&&(o&&(o+=" "),o+=n);else for(r in t)t[r]&&(o&&(o+=" "),o+=r);return o}(e))&&(n&&(n+=" "),n+=t);return n},i=e=>{let{dir:r,textAlign:n,className:o,children:a,tagName:i="p",id:l}=e;return(0,t.jsx)(i,{className:o,style:{textAlign:n},dir:r,id:`${l}label`,children:a})},l=e=>{let{wrapperProps:{dir:r,textAlign:o,id:a},classNames:l,children:s}=e;return(0,t.jsx)("div",{className:n(l.bg),style:{textAlign:o},children:(0,t.jsx)(i,{dir:r,textAlign:o,className:l.label,id:a,children:s})})};function s(e){return t=>{t.keyCode===e&&(t.preventDefault(),t.stopPropagation(),t.currentTarget.click())}}let u=s(32),c=s(13),p=e=>{c(e),u(e)};s(27);let d=["aria-id","aria-metadata","aria-type"],b=e=>Object.entries(e).reduce((e,[t,r])=>(t.includes("data-")&&(e[t]=r),e),{}),f=r.forwardRef((e,r)=>{let n,{href:o,role:a,target:i,rel:l,className:s="",children:d,linkPopupId:f,anchorDataId:h,anchorCompId:m,tabIndex:y,dataTestId:v="linkElement",title:x,onClick:j,onDoubleClick:g,onMouseEnter:w,onMouseLeave:k,onFocus:S,onFocusCapture:I,onBlurCapture:M,"aria-live":O,"aria-disabled":P,"aria-label":C,"aria-labelledby":N,"aria-pressed":B,"aria-expanded":_,"aria-describedby":E,"aria-haspopup":D,"aria-current":A,dataPreview:L,dataPart:T}=e;switch(void 0!==e.activateByKey?e.activateByKey:f?"SpaceOrEnter":"Enter"){case"Enter":n=c;break;case"Space":n=u;break;case"SpaceOrEnter":n=p;break;default:n=void 0}return void 0!==o||f?(0,t.jsx)("a",{...b(e),"data-testid":v,"data-popupid":f,"data-anchor":h,"data-anchor-comp-id":m,"data-preview":L,"data-part":T,href:o||void 0,target:i,role:f?"button":a,rel:l,className:s,onKeyDown:n,"aria-live":O,"aria-disabled":P,"aria-label":C,"aria-labelledby":N,"aria-pressed":B,"aria-expanded":_,"aria-haspopup":D,"aria-describedby":E,"aria-current":A,title:x,onClick:j,onMouseEnter:w,onMouseLeave:k,onDoubleClick:g,onFocus:S,onFocusCapture:I,onBlurCapture:M,ref:r,tabIndex:f?0:y,children:d}):(0,t.jsx)("div",{...b(e),"data-testid":v,"data-preview":L,"data-part":T,className:s,tabIndex:y,"aria-label":C,"aria-labelledby":N,"aria-haspopup":D,"aria-disabled":P,"aria-expanded":_,title:x,role:a,onClick:j,onDoubleClick:g,onMouseEnter:w,onMouseLeave:k,ref:r,children:d})}),h=e=>{let{wrapperProps:{ariaHasPopup:r,isMoreButton:n,ariaDescribedBy:o,ariaExpanded:a,ariaCurrent:i,role:l},className:s,children:u,link:c,tabIndex:p}=e;return(0,t.jsx)(f,{...c,"aria-haspopup":r,"aria-describedby":o,"aria-current":i,"aria-expanded":a,tabIndex:p||(!n&&c&&c.href?void 0:0),className:s,role:l,children:u})},m=()=>(0,t.jsx)("svg",{width:"10",height:"10",viewBox:"0 0 16 11",fill:"black",xmlns:"http://www.w3.org/2000/svg",children:(0,t.jsx)("path",{d:"M8 10.5L16 1.86193L14.7387 0.5L8 7.77613L1.26133 0.499999L-5.95321e-08 1.86193L8 10.5Z"})}),y=e=>{let{label:o,direction:a="ltr",positionInList:i,parentId:l,dataId:s,isContainer:u,isSelected:c,isHovered:p,link:d,tagName:f="div",id:y,className:v,compClassName:x,onClick:j,onDoubleClick:g,onMouseEnter:w,onMouseLeave:k,index:S,children:I,isDropDownButton:M,subItems:O}=e,[P,C]=r.useState(!1),N=O&&O.length>0,B=e=>{P||(C(!0),w?.(e))},_=e=>{P&&(C(!1),k?.(e))},E=d&&(d.hasOwnProperty("href")||d.hasOwnProperty("target")||d.hasOwnProperty("rel")||d.hasOwnProperty("linkPopupId")),D={...b(e),"data-direction":a,"data-listposition":i,"data-parent-id":l,"data-data-id":s,"data-state":[u?"drop":"menu",c&&"selected",p&&"over",E?"link":"header"].join(" "),"data-index":S,"data-dropdown":M},A=e=>e?e.trim():"\xa0",L=N?(0,t.jsx)("ul",{"aria-hidden":!0,style:{display:"none"},children:O.map((e,r)=>{let{hasPopup:n,"aria-current":o}=e;return(0,t.jsx)("li",{children:(0,t.jsx)(h,{wrapperProps:{ariaHasPopup:n,ariaCurrent:o},link:e.link,tabIndex:-1,compClassName:x,children:A(e.label)})},e.id||r)})}):null;return(0,t.jsxs)(f,{id:y,...D,className:n(x,v),onClick:j,onDoubleClick:g,onMouseEnter:B,onMouseLeave:_,onFocus:e=>{e.nativeEvent instanceof MouseEvent&&B(e)},onBlur:e=>{e.nativeEvent instanceof MouseEvent?_(e):C(!1)},onKeyDown:e=>{"Escape"===e.key&&(P&&C(!1),k?.(e))},children:[I(A(o)),N&&(0,t.jsx)("button",{className:n("H4AHlN",{Ln3X5V:P}),onKeyDown:e=>{("Enter"===e.key||" "===e.key)&&(P||(C(!0),w?.({...e,currentTarget:e.currentTarget?.parentNode})),P&&(C(!1),k?.({...e,currentTarget:e.currentTarget?.parentNode})))},"aria-label":e?.translations?.dropdownButtonAriaLabel?.replace("<%= itemName %>",A(o))||"More pages",children:(0,t.jsx)(m,{})}),L]})},v={root:"EoGSHr",SeparateLinesMenuButtonNSkin:"EFX5Px",separateLinesMenuButtonNSkin:"EFX5Px",linkElement:"cm2csG",gapper:"XEJX6Y",borderWrapper:"JtWMtp",label:"p2S5b4"},x=e=>{let{id:r,"aria-haspopup":o,"aria-describedby":a,"aria-current":i,"aria-expanded":s,role:u,isMoreButton:c,dir:p,textAlign:d,positionInList:b,link:f,className:m}=e;return(0,t.jsx)(y,{...e,className:n(m,v.SeparateLinesMenuButtonNSkin),children:e=>(0,t.jsx)(h,{wrapperProps:{positionInList:b,ariaHasPopup:o,ariaDescribedBy:a,isMoreButton:c,ariaCurrent:i,ariaExpanded:s,role:u},link:f,className:v.linkElement,children:(0,t.jsx)("div",{className:v.gapper,children:(0,t.jsx)("div",{className:v.borderWrapper,children:(0,t.jsx)(l,{wrapperProps:{dir:p,textAlign:d,id:r},classNames:{bg:v.bg,label:v.label},children:e})})})})})},j={wrapper:"SiBgBF",navContainer:"Kefle8",itemsContainerWrapper:"NxPbZa",itemsContainer:"iTBB8q",menuItem:"N9ciTf",moreButton:"QBNfeJ",dropdownButton:"tEMtJk",dropWrapper:"Xjwu46",moreContainer:"m5Bhqi",showMore:"MPpwEt",utility:"GiXuym",SeparateLinesMenuButtonSkin:"RFaPbn",separateLinesMenuButtonSkin:"RFaPbn"},g="wixui-",w=(e,...t)=>{let r=[];return e&&r.push(`${g}${e}`),t.forEach(e=>{e&&(r.push(`${g}${e}`),r.push(e))}),r.join(" ")},k=new Set(["PointerMenuButtonHorizontalMenuAdaptationSkin","PointerMenuButtonSkin","VerticalRibbonsMenuButtonSkin","RibbonsMenuButtonSkin"]),S="__more__",I=e=>e.split("?")[0],M=function(){let e,t,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"",i=new Set([...Array.from((e=o.compId||o.dataId,t=new Set,e&&(t=new Set(r.filter(e=>e.link&&(!e.link.href||I(e.link.href)===I(n))&&(e.link.anchorCompId&&e.link.anchorCompId===o.compId||e.link.anchorDataId&&e.link.anchorDataId===o.dataId&&"SCROLL_TO_TOP"!==e.link.anchorDataId&&"SCROLL_TO_BOTTOM"!==e.link.anchorDataId)))),t)),...Array.from(r.filter(e=>e.link&&e.link.linkPopupId&&e.link.linkPopupId===a))]),l=i.size>0;return r.forEach(e=>{let t=e.items&&e.items.length?M(e.items,n,o,a):new Set;!1!==e.selected&&((e.selected||!l&&!(e.link&&(e.link.anchorDataId||e.link.anchorCompId))&&e.link&&e.link.href&&decodeURIComponent(I(e.link.href))===I(n)||e.link&&Object.keys(e.link).length>0&&t.size>0)&&i.add(e),t.forEach(e=>i.add(e)))}),i};function O(e,t){return e.filter((e,r)=>{var n;let o=(n=r.toString(),`${t}${n}`),a=document.getElementById(o);return a?.style?.visibility==="hidden"})}var P=o(55359),C=o.n(P),N=o(58478);let B=e=>{let o=r.useMemo(()=>M(e.items,e.currentUrl,e.activeAnchor,e.currentPopupId),[e.items,e.currentUrl,e.activeAnchor,e.currentPopupId]),{ariaAttributes:a}=e,i=(e,r)=>{let{Button:n}=e,o={...{onMouseEnter:e.onItemMouseEnter,onMouseLeave:e.onItemMouseLeave,onDoubleClick:e.onItemDblClick,onClick:e.onItemClick,textAlign:e.alignText,translations:e.translations},...r};return(0,t.jsx)(n,{...o})},l=(e,t)=>{let{items:r=[],compClassName:n,dropdown:a,rtl:l,buttonAlign:u,stretch:c}=t,{hover:p}=e,d={};return r.map((t,b)=>{var f,h,m,y,v,x;let j=t.hasPopup??(t?.items?.length??0)>0,g=`${a?"moreContainer":""}${b}`,w={isContainer:a,isSelected:o.has(t),positionInList:t.positionInList||(f=b,h=r.length,m=a,y=l,v=u,x=c,f===h-1?1===h?"dropLonely":m?"bottom":x||"right"===v?y?"left":"right":"center":0===f?m?"top":x||"left"===v?y?"right":"left":"center":m?"dropCenter":"center"),id:s(g),index:b,refInParent:g,isDropDownButton:a,...o.has(t)&&{"aria-current":"page"},...j&&{"aria-haspopup":"true","aria-expanded":!(0,N.isNil)(p)&&parseInt(p,10)===b},tagName:"li",direction:l?"rtl":"ltr",parentId:t.parent,dataId:t.id,label:t.label,link:t.link,compClassName:n,key:((e,t)=>{let r=e,n=0;for(;t[r]&&n<100;)r+=t[r]++,n++;return t[r]=(t[r]||0)+1,r})(t.label,d),subItems:a?void 0:t.items?.map(e=>({...e,...o.has(e)&&{"aria-current":"page"}})),role:j&&C()(t.link)?"button":void 0};return i(e,w)})},s=t=>{var r;return r=e.id,`${r}${t}`},u=(e=>{let t,{role:r,tabIndex:n,tabindex:o,screenReader:a,lang:i,ariaAttributes:l={}}=e;return{role:r,tabIndex:n??o,screenReader:a,ariaAttributes:(t=Object.entries(l).reduce((e,[t,r])=>({...e,[`aria-${t}`.toLowerCase()]:r}),{}),Object.entries(t).reduce((e,[t,r])=>(d.includes(t)||(e[t]=r),e),{})),lang:i}})({role:e.role,ariaAttributes:a});return function(r){let o,{translations:a,styles:c}=r,p=function(e){let{styles:r,skin:o,alignButtons:a="center",marginAllChildren:u,onMenuKeyDown:c}=e,p=function(e){let{styles:t,items:r,rtl:o,stretchButtonsToMenuWidth:a,alignButtons:u="center"}=e,c=l(e,{items:r,compClassName:n(t.menuItem,w("dropdown-menu__item")),rtl:o,buttonAlign:u,stretch:a}),p=function(e){let{rtl:t,styles:r,stretchButtonsToMenuWidth:n,alignButtons:o="center",moreButtonLabel:a,onItemMouseEnter:l,onItemMouseLeave:u,onSubMenuKeyDown:c}=e,p=t?"left":"right";return n||"right"===o||(p="center"),i(e,{label:a||"",isSelected:!1,positionInList:p,id:s(S),index:S,refInParent:S,key:S,onFocus:l,onBlur:u,"aria-haspopup":"true",tagName:"li",onKeyDown:c,isDropDownButton:!1,compClassName:r.moreButton,isMoreButton:!0})}(e);return p&&c.push(p),c}(e),d=s("itemsContainer"),b=(0,t.jsx)("ul",{className:n(r.itemsContainer,r[`${a}`]),id:d,style:{textAlign:a},"data-marginallchildren":u,onKeyDown:c,children:p});if((()=>{switch(o){case"IndentedMenuButtonSkin":case"ShinyMenuIIButtonSkin":case"SloppyBorderMenuButtonSkin":return!0;default:return!1}})()){let e=s("wrapper");b=(0,t.jsx)("div",{className:n(r.itemsContainerWrapper),id:e,children:b})}return b}(r),d=function(e){let{skin:r,styles:n}=e,o=null;return k.has(r)&&(o=(0,t.jsx)("div",{className:n.utility})),o}(r),b=function(r){let{alignButtons:o="center",onSubMenuKeyDown:a,hover:i,styles:u}=r,c=function(t){let{items:r,rtl:n,alignButtons:o="center",stretchButtonsToMenuWidth:a,hover:i,styles:s}=t,u=null,c=[];if(r&&i){let t=parseInt(i,10);Number.isInteger(t)&&r[t]?u=r[t].items:i===S&&(u=O(r,e.id).reduce((e,t)=>{let r=[];return t.items&&(r=t.items.map(e=>({...e,parent:t.id}))),[...e,t,...r]},[]))}return u&&(c=l(t,{items:u,compClassName:s.dropdownButton,dropdown:!0,rtl:n,buttonAlign:o,stretch:a})),c}(r),p=s("moreContainer"),d=s("dropWrapper"),b=(c?.length??0)>0,f=n(u.dropWrapper,{[u.showMore]:b}),h=function(e){let{hover:t,hoverListPosition:r}=e;return t?r:null}(r);return(0,t.jsx)("div",{className:f,id:d,"data-drophposition":h,"data-dropalign":o,"data-dropdown-shown":b,children:(0,t.jsx)("ul",{className:n(u.moreContainer,w("dropdown-menu__submenu")),"data-hover":i,id:p,onKeyDown:a,children:c})})}(r),f=s("navContainer");return(0,t.jsxs)("nav",{className:n(c.navContainer),id:f,"aria-label":a.ariaLabel,...u.ariaAttributes,role:u.role,onMouseEnter:r.onMouseEnter,onMouseLeave:r.onMouseLeave,children:[d,p,b,(o=a.subMenuIndication,(0,t.jsx)("div",{style:{display:"none"},id:`${s("navContainer")}-hiddenA11ySubMenuIndication`,children:o}))]})}(e)},_={hover:null,hoverListPosition:null},E=e=>{let o,[a,i]=r.useState(_),l=r.useRef(),s=t=>{let{hover:r}=a,{id:n,items:o}=e,i=parseInt(t.getAttribute("data-index")||"-1",10);return t?.parentNode?.id!==`${n}moreContainer`?o[i]:r?r===S?O(o,n)[i]:o[parseInt(r,10)].items[i]:null},u=t=>{let{onItemMouseIn:r}=e,{currentTarget:n}=t;r?.(t,s(n)),c(t)},c=t=>{let{hover:r}=a,{id:n}=e,{currentTarget:l}=t,s=l.getAttribute("data-listposition"),u=l.getAttribute("data-index")||"-1",c=parseInt(u,10);clearTimeout(o),l?.parentNode?.id!==`${n}moreContainer`&&(Number.isInteger(c)&&-1!==c||u.startsWith("__"))&&u!==r&&i({hover:u,hoverListPosition:s})},p=t=>{let{onItemMouseOut:r}=e,{currentTarget:n}=t;r?.(t,s(n)),d(t)},d=e=>{e.nativeEvent instanceof MouseEvent?o=setTimeout(()=>{i({hover:null,hoverListPosition:null})},1e3):i({hover:null,hoverListPosition:null})},b=t=>{let{onItemDblClick:r}=e,{currentTarget:n}=t;r?.(t,s(n))},f=t=>{let{hover:r}=a,{currentTarget:n}=t,{items:o,onItemClick:i,isTouchDevice:l}=e;if(i?.(t,s(n)),l){let e=n.getAttribute("data-index")||"-1",a="true"===n.getAttribute("data-dropdown"),i=parseInt(e,10),l=o?o[i]:null,s=e===S||l?.items?.length>0;a?d(t):r?(d(t),s&&r!==e&&(t.preventDefault(),t.stopPropagation(),c(t))):s&&(c(t),t.preventDefault(),t.stopPropagation())}},h=function(t){let r=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(l.current){let{id:n}=e,o=l.current.querySelector(`#${n}itemsContainer > li:nth-child(${t+1})`);for(;o&&"true"===o.getAttribute("aria-hidden");)o=r?o.previousSibling:o.nextSibling;if(o){let e=o.querySelector("button")||o.childNodes?.[0];if(e)return e.focus(),!0}}return!1},m=t=>{let{hover:r}=a,{items:n}=e,{key:o,shiftKey:i}=t;if(null!==r){let a=r?parseInt(r,10):-1,s=!1;if("Tab"===o&&!i&&n){let t=n[a];t&&t.items&&(s=(t=>{let{id:r}=e;if(l.current){let e=l.current.querySelector(`#${r}moreContainer li:nth-child(${t+1}) a`);if(e)return e.focus(),!0}return!1})(0))}s&&(t.stopPropagation(),t.preventDefault())}},y=t=>{let{hover:r}=a,{items:n}=e,{shiftKey:o,key:i,target:l,currentTarget:s}=t,u=l;if(l!==s&&"li"!==l.tagName.toLowerCase()&&(u=l.closest("li")),u){let e=u.getAttribute("data-index")||"",a=!1;if(r){let l,s=Number.isNaN(l=parseInt(r,10))?-1:l;if("Escape"===i&&(a=h(s,o)),"Tab"===i){let r=parseInt(e,10);if(s>=0){if(o)0===r&&(a=h(s,o),p(t));else if(n&&n[s]){let e=n[s];e&&e.items&&e.items.length===r+1&&(a=h(s+1),p(t))}}}}a&&(t.stopPropagation(),t.preventDefault())}};return function(r,o){let{id:a,className:i,customClassNames:s=[],skin:c,rtl:d,styles:h,lang:v}=r,x={id:a,class:n(h[c],h.wrapper,i,w("dropdown-menu",...s),"hidden-during-prewarmup"),ref:l,tabIndex:-1,dir:d?"rtl":"ltr",lang:v,...function(e,t){let{hover:r,hoverListPosition:n}=t,{stretchButtonsToMenuWidth:o,sameWidthButtons:a,skinExports:i,alignButtons:l="center",items:s,isQaMode:u,fullNameCompType:c}=e;return{"data-stretch-buttons-to-menu-width":o,"data-same-width-buttons":a,"data-num-items":s?.length,"data-menuborder-y":i.menuBorderY,"data-menubtn-border":i.menuBtnBorder,"data-ribbon-els":i.ribbonEls,"data-label-pad":i.labelPad,"data-ribbon-extra":i.ribbonExtra,"data-drophposition":n,"data-dropalign":l,"data-hovered-item":r,...u?{"data-comp":c,"data-aid":c}:{}}}(r,o)};return(0,t.jsx)("wix-dropdown-menu",{...x,children:(0,t.jsx)(B,{...r,...o,onItemMouseEnter:e.isTouchDevice?void 0:u,onItemMouseLeave:e.isTouchDevice?void 0:p,onItemDoubleClick:e.onItemDblClick?b:void 0,onItemClick:e.isTouchDevice||e.onItemClick?f:void 0,onMenuKeyDown:m,onSubMenuKeyDown:y})})}(e,a)},D=r.forwardRef((e,r)=>{let{styles:n,Button:o}=e;return(0,t.jsx)(E,{...e,ref:r,styles:n,Button:o})}),A={DropDownMenu_SeparateLinesMenuButtonSkin:{component:r.forwardRef((e,r)=>(0,t.jsx)(D,{...e,ref:r,styles:j,Button:x})),controller:(e=e=>{let{stateValues:t,mapperProps:r}=e,{currentUrl:n}=t;return{...r,currentUrl:n}},{useComponentProps:(t,r,n)=>e({mapperProps:t,stateValues:r,controllerUtils:{...n,updateStyles:e=>{let t=Object.entries(e).reduce((e,[t,r])=>({...e,[t.startsWith("--")?t:t.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)]:void 0===r?null:r}),{});n.updateStyles(t)}}})})}}})(),a})());