1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8859],{90397:function(t,e,n){n.r(e),n.d(e,{default:function(){return w}});var r=n(85893),i=n(67294),a=n(65820),o=n(7606),l=n(65865),s=n(20558),c=n(30286),u=(n(64055),n(41059),n(85008)),d=n(30381),f=n.n(d),p=n(33851),m=n(11163),g=n(16651);function b(t,e){(null==e||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function x(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function h(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{},r=Object.keys(n);"function"===typeof Object.getOwnPropertySymbols&&(r=r.concat(Object.getOwnPropertySymbols(n).filter((function(t){return Object.getOwnPropertyDescriptor(n,t).enumerable})))),r.forEach((function(e){x(t,e,n[e])}))}return t}function y(t,e){return function(t){if(Array.isArray(t))return t}(t)||function(t,e){var n=null==t?null:"undefined"!==typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(null!=n){var r,i,a=[],o=!0,l=!1;try{for(n=n.call(t);!(o=(r=n.next()).done)&&(a.push(r.value),!e||a.length!==e);o=!0);}catch(s){l=!0,i=s}finally{try{o||null==n.return||n.return()}finally{if(l)throw i}}return a}}(t,e)||function(t,e){if(!t)return;if("string"===typeof t)return b(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);"Object"===n&&t.constructor&&(n=t.constructor.name);if("Map"===n||"Set"===n)return Array.from(n);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return b(t,e)}(t,e)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var v={startDate:new Date,endDate:null,key:"selection",start:null};function w(t){var e=t.type,n=(t.mobile,(0,m.useRouter)()),d=(0,i.useContext)(p.q),b=d.period,x=d.setPeriod,w=d.startDate,k=d.setStartDate,j=d.endDate,D=d.setEndDate,N=d.filters,E=(0,i.useContext)(g.A).lang,O=(0,i.useState)(null),S=O[0],C=O[1],F=(0,i.useState)(!1),z=F[0],M=F[1],R=(0,i.useState)(!1),Y=R[0],A=R[1],I=(0,i.useState)([v]),P=I[0],L=I[1],_=(0,i.useState)(!(window.innerWidth>=480)),U=_[0],W=_[1],q=(0,i.useRef)(null),Q=(0,i.useRef)(null),T=(0,i.useRef)(null),$=(0,i.useRef)(null),B="DD MMM YYYY";"en"==E&&(B="MMM DD, YYYY"),(0,i.useEffect)((function(){if(b){var t=(0,s.uk)(E).filter((function(t){return t.period==b}));t.length>0?C(j?f().unix(w).format(B)+" - "+f().unix(j).format(B):t[0].title):C((0,s.uk)(E)[5].title)}else C((0,s.uk)(E)[5].title);return function(){}}),[b,w,j]),(0,i.useEffect)((function(){return window.addEventListener("resize",H),function(){window.removeEventListener("resize",H)}}),[U]),(0,i.useEffect)((function(){return document.addEventListener("mousedown",G),function(){document.removeEventListener("mousedown",G)}}),[q,Q,T]);var G=function(t){(q&&q.current&&!q.current.contains(t.target)&&!Q.current.contains(t.target)||T&&T.current&&!T.current.contains(t.target))&&(M(!1),A(!1))},H=function(){var t=window.innerWidth;t<480&&!U&&W(!0),t>=480&&U&&W(!1)},J=function(t){if(M(!z),C(t.title),"Personalizza"==t.title||"Customize date"==t.title)A(!0);else{var e=h({period:t.period,start:null,end:null},N);x(t.period),k(null),D(null),V(e)}},K=function(t){A(!1),C(f()(t.startDate).format(B)+" - "+f()(t.endDate).format(B)),L([v]);var e=h({period:"custom",start:f()(t.startDate).unix(),end:f()(t.endDate).unix()},N);x("custom"),k(f()(t.startDate).unix()),D(f()(t.endDate).unix()),V(e)},V=function(t){var e=Object.fromEntries(Object.entries(t).filter((function(t){var e=y(t,2);e[0];return null!=e[1]}))),r=Object.keys(e).map((function(e){return encodeURIComponent(e)+"="+encodeURIComponent(t[e])})).join("&"),i=n.asPath.split("?")[0],a=n.pathname.split("?")[0];n.push(a+"?"+r,i+"?"+r,{shallow:!0})};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{ref:$,className:"relative w-full xs:w-auto inline-block text-left justify-center items-center",children:[(0,r.jsx)("div",{className:"",children:(0,r.jsxs)("a",{ref:Q,onClick:function(){M(!z)},title:"Open Filters by period","aria-label":"Open Filters by period",className:"flex justify-center items-center space-x-2 p-2 bg-vantevo-gray dark:bg-vantevo-dark-100 border border-vantevo-gray shadow-md capitalize cursor-pointer select-none",children:[(0,r.jsx)(l.Qu,{className:"stroke-black dark:stroke-white"}),(0,r.jsx)("span",{className:"text-black dark:text-white text-xs md:text-[13px]",children:S})]})}),!U&&(0,r.jsxs)(a.M,{children:[z&&(0,r.jsx)(o.E.div,{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},ref:q,className:"origin-top-right absolute left-0 mt-2 w-full xs:w-[250px] rounded-md shadow-lg bg-white dark:bg-vantevo-dark-100 ring-1 ring-black ring-opacity-5 z-[100]",children:(0,r.jsx)("div",{className:"py-1",children:(0,s.uk)(E).map((function(t,n){return 10!=t.id||"events"!=e&&"ecommerce"!=e?(0,r.jsx)("a",{onClick:function(){J(t)},title:"Filter - "+t.title,"aria-label":"Filter - "+t.title,className:"block px-4 py-2 text-sm cursor-pointer text-black dark:text-white ".concat(["2","4","6","8"].includes(t.id.toString())?"border-b border-gray-500":""),children:t.title},n):(0,r.jsx)(r.Fragment,{})}))})},"dropdown-account"),Y&&(0,r.jsx)(o.E.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},ref:T,className:"origin-top-left xs:origin-top-right absolute left-0 mr-[30px] md:mr-0 mt-2 w-auto xs:w-[250px] rounded-md shadow-lg bg-white dark:bg-vantevo-dark-100 ring-1 ring-black ring-opacity-5 z-[100]",children:(0,r.jsx)("div",{className:"py-1 origin-top-right",children:(0,r.jsx)(c.C0,{locale:u[E],className:"origin-top-right",editableDateInputs:!1,onChange:function(t){P[0].start||L([h({},t.selection,{start:1})]),P[0].start&&(L([h({},t.selection,{start:0})]),K(t.selection))},moveRangeOnFirstSelection:!1,ranges:P,maxDate:new Date,minDate:new Date("2018-01-01")})})},"dropdown-account-valid-range")]})]}),U&&(0,r.jsxs)(a.M,{children:[z&&(0,r.jsx)(o.E.div,{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},ref:q,className:"origin-top-right absolute right-0 mt-12 w-full xs:w-[250px] rounded-md shadow-lg bg-white dark:bg-vantevo-dark-100 ring-1 ring-black ring-opacity-5 z-[100]",children:(0,r.jsx)("div",{className:"py-1",children:(0,s.uk)(E).map((function(t,n){return 10==t.id&&"events"==e?(0,r.jsx)(r.Fragment,{}):(0,r.jsx)("a",{onClick:function(){J(t)},title:"Filter - "+t.title,"aria-label":"Filter - "+t.title,className:"block px-4 py-2 text-sm cursor-pointer text-black dark:text-white ".concat(["2","4","6","8"].includes(t.id.toString())?"border-b border-gray-500":""),children:t.title},n)}))})},"dropdown-account"),Y&&(0,r.jsx)(o.E.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},ref:T,className:"origin-top-left xs:origin-top-right absolute right-12 mt-8 w-auto xs:w-[250px] rounded-md shadow-lg bg-white dark:bg-vantevo-dark-100 ring-1 ring-black ring-opacity-5 z-[100]",children:(0,r.jsx)("div",{className:"py-1 origin-top-right",children:(0,r.jsx)(c.C0,{locale:u[E],className:"origin-top-right",editableDateInputs:!1,onChange:function(t){P[0].start||L([h({},t.selection,{start:1})]),P[0].start&&(L([h({},t.selection,{start:0})]),K(t.selection))},moveRangeOnFirstSelection:!1,ranges:P,maxDate:new Date,minDate:new Date("2018-01-01")})})},"dropdown-account-valid-range")]})]})}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.