import{i as y,r as i,o as a,c as o,b as e,a as l,w as _,F as r,d as u,t as f,n as w,h as k,z as S,A as B}from"./app-DmJ8GS-7.js";import{C as M}from"./SearchModal.vue_vue_type_style_index_0_scoped_a4fc4416_lang-CbsljUTZ.js";import{S as N,M as j,B as z}from"./ClientFooterDown-D8UuGhzW.js";/* empty css */import{_ as C}from"./_plugin-vue_export-helper-DlAUqK2U.js";const I={name:"MainNavBar",props:{sections:{type:Object}},data(){return{}},components:{SearchModal:N,MobileNavbar:j,BaseIcon:z,ClientGlobalSearch:M,Link:y},methods:{isSameRoute(t){if(t===this.$page.props.ziggy.location)return!0;const d=this.$page.props.ziggy.location,c=this.$page.props.ziggy.url+"/"+t;return d===c},hasActivePage(t){if(t.pages)return t.pages.some(d=>this.isSameRoute(d.path));if(t.subSections)return t.subSections.some(d=>this.hasActivePage(d))}}},n=t=>(S("data-v-dc2022ad"),t=t(),B(),t),L={class:"flex duration-500 fixed top-0 left-0 right-0 flex-wrap lg:justify-start lg:flex-nowrap z-50 w-full text-sm py-3 lg:py-0 header-filter"},R={class:"max-w-screen-xl w-full mx-auto px-4 py-3","aria-label":"Global"},$={class:"relative lg:flex lg:items-center lg:justify-between"},A={class:"flex items-center justify-between"},V=n(()=>e("img",{class:"max-w-[300px]",src:"/logos/ntspi-logo.svg",alt:""},null,-1)),D=k('
',1),F={id:"navbar-collapse-with-animation",class:"hs-collapse hidden overflow-hidden transition-all duration-300 basis-full grow lg:block"},G={class:"overflow-hidden overflow-y-auto max-h-[75vh] [&::-webkit-scrollbar]:w-2 [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-track]:bg-gray-100 [&::-webkit-scrollbar-thumb]:bg-gray-300"},P={class:"flex flex-col gap-x-0 mt-5 md:flex-row md:items-center md:justify-end md:gap-x-7 md:mt-0 md:ps-7 md:divide-y-0 md:divide-solid"},E={type:"button",class:"active:text-blue-600 flex items-center w-full text-black hover:text-gray-300 font-medium"},O={class:"hs-dropdown-menu transition-opacity duration-150 md:duration-500 hs-dropdown-open:opacity-100 opacity-0 w-full hidden z-10 top-full start-0 min-w-[15rem] bg-white md:shadow-2xl rounded-lg py-2 md:p-4 before:absolute before:-top-5 before:start-0 before:w-full before:h-5"},U={class:"grid px-5 grid-cols-1 md:grid-cols-10"},q={class:"flex flex-col py-6 px-3 md:px-6"},H={class:"space-y-4"},J={class:"flex items-center mb-2 gap-x-2"},K={class:"text-xs font-bold uppercase text-gray-800"},Q=["href"],T={class:"grow"},W={href:"#",class:"hover:opacity-70 py-3 className"},X=n(()=>e("span",{class:"md:hidden"},"Режим для слабовидящих",-1)),Y=n(()=>e("span",{class:"md:hidden text-black"},"Расписание",-1)),Z={class:"hover:opacity-70 py-3 cursor-pointer","data-hs-overlay":"#hs-full-screen-modal-below-md"},ee=n(()=>e("span",{class:"md:hidden text-black"},"Поиск",-1));function te(t,d,c,se,ae,v){const b=i("Link"),h=i("BaseIcon"),x=i("MobileNavbar"),g=i("SearchModal");return a(),o(r,null,[e("header",L,[e("nav",R,[e("div",$,[e("div",A,[l(b,{class:"flex-none text-xl font-semibold",href:"/","aria-label":"Brand"},{default:_(()=>[V]),_:1}),D]),e("div",F,[e("div",G,[e("div",P,[(a(!0),o(r,null,u(this.sections.data,p=>(a(),o("div",{key:p.id,class:"hs-dropdown [--strategy:static] md:[--strategy:absolute] [--adaptive:none] md:[--trigger:hover] py-3 md:py-6"},[e("button",E,f(p.title),1),e("div",O,[e("div",U,[(a(!0),o(r,null,u(p.subSections,m=>(a(),o("div",{key:m.id,class:"md:col-span-3"},[e("div",q,[e("div",H,[e("div",J,[e("span",K,f(m.title),1)]),(a(!0),o(r,null,u(m.pages,s=>(a(),o("a",{key:s.id,class:w([{"text-secondDarkBlue hover:text-gray-800 font-semibold ":v.isSameRoute(s.path),"text-gray-800 hover:text-gray-500":!v.isSameRoute(s.path)},"flex items-center gap-x-2"]),href:s.is_url?s.path:t.route("page.view",s.path)+"/"},[e("div",T,[e("p",null,f(s.title),1)])],10,Q))),128))])])]))),128))])])]))),128)),e("a",W,[l(h,{name:"eye",class:"w-6 h-6 duration-300 md:block hidden"}),X]),l(b,{href:t.route("client.schedule"),class:"hover:opacity-70 py-3"},{default:_(()=>[l(h,{name:"schedule",class:"w-6 h-6 text-black md:block hidden"}),Y]),_:1},8,["href"]),e("a",Z,[l(h,{name:"search",class:"w-6 h-6 text-black md:block hidden"}),ee])])])])])])]),l(x,{sections:c.sections},null,8,["sections"]),l(g,{open_id:"hs-full-screen-modal-below-md"})],64)}const ne=C(I,[["render",te],["__scopeId","data-v-dc2022ad"]]);export{ne as M};