@anoki/fse-marche-ui
Version:
FSE UI components library
3 lines (2 loc) • 3.52 kB
JavaScript
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require('./components/navigations/HeaderDesktop/HeaderDesktop.css');const e=require("./index.cjs137.js"),v=require("./index.cjs153.js"),o=require("./index.cjs24.js"),E=require("./index.cjs17.js"),i=require("./index.cjs139.js"),f=require("./index.cjs210.js"),g=require("./index.cjs25.js"),w=require("./index.cjs6.js");;/* empty css */const a=require("./index.cjs9.js"),N=({title:r,region:x,asLink:c="a",labels:d,navigatonItems:m,supportLink:n,loginLink:j="/",shortTitle:l,headerTitleClassname:u,children:h})=>{const t=c,p=o.LOGOS.nazionale,R=o.LOGOS[x];return e.jsxRuntimeExports.jsxs("div",{className:"sticky-header bg-white",children:[e.jsxRuntimeExports.jsxs(E.HeaderSlim,{pt:"x16",pb:"x16",display:"flex",justifyContent:"space-between",alignItems:"center",children:[e.jsxRuntimeExports.jsxs(t,{href:"/",className:"text-white fw-semibold text-decoration-none fs-7 hover-underline",children:[l||r,e.jsxRuntimeExports.jsx("span",{className:"visually-hidden",children:"Vai alla homepage"})]}),h]}),e.jsxRuntimeExports.jsxs("header",{className:"bg-white",children:[e.jsxRuntimeExports.jsxs(a.Row,{py:"x20",gap:"x16",alignItems:"center",justifyContent:"space-between",className:"min-h-x120 ui-container",children:[e.jsxRuntimeExports.jsxs(a.Row,{gap:"x16",alignItems:"center",children:[e.jsxRuntimeExports.jsxs(a.Row,{gap:"x16",alignItems:"center",justifyContent:"center",children:[e.jsxRuntimeExports.jsx(p,{height:58}),x!=="nazionale"&&e.jsxRuntimeExports.jsxs(e.jsxRuntimeExports.Fragment,{children:[e.jsxRuntimeExports.jsx(v.Divider,{bg:"border-divider",direction:"vertical"}),e.jsxRuntimeExports.jsx(R,{width:58,height:58})]})]}),e.jsxRuntimeExports.jsx("h1",{className:i.clsx(u),children:e.jsxRuntimeExports.jsx(f.Balancer,{children:e.jsxRuntimeExports.jsxs(t,{href:"/",className:"fs-2 fw-bold text-slate-20 text-decoration-none hover-underline",children:[r,e.jsxRuntimeExports.jsx("span",{className:"visually-hidden",children:"Vai alla homepage"})]})})})]}),e.jsxRuntimeExports.jsxs(g.Button,{size:"2",href:j,asLink:"a",children:[d.login,e.jsxRuntimeExports.jsx("span",{className:"visually-hidden",children:" Accedi con Cohesion"})]})]}),e.jsxRuntimeExports.jsx("nav",{"aria-label":"Menu di navigazione",className:"shadow-bottom",children:e.jsxRuntimeExports.jsxs(w.Container,{className:"base-row align-items-center justify-content-between",children:[e.jsxRuntimeExports.jsx(a.Row,{as:"ul",className:"list-style-none",role:"list",children:m.map((s,b)=>e.jsxRuntimeExports.jsx("li",{className:i.clsx("py-x12 px-x16 ui-header-desktop-nav-item min-h-x56",s.active&&"active"),children:e.jsxRuntimeExports.jsxs(t,{href:s.href,"aria-label":`Vai alla pagina ${s.label}`,className:i.clsx("text-decoration-none fs-custom",s.active?"fw-bold text-blue-30":"fw-semibold text-primary"),target:s.isNewTab?"_blank":void 0,rel:s.isNewTab?"noopener noreferrer":void 0,children:[s.label,s.active&&e.jsxRuntimeExports.jsx("span",{className:"visually-hidden",children:"Attivo"})]})},b))}),n&&e.jsxRuntimeExports.jsxs(t,{href:n.href,"aria-label":`Vai alla pagina ${n.label}`,className:i.clsx("text-decoration-none fs-custom py-x12 px-x24",n.active?"fw-bold text-blue-30":"fw-semibold text-primary","ui-header-desktop-support-link",n.active&&"active"),children:[n.label,n.active&&e.jsxRuntimeExports.jsx("span",{className:"visually-hidden",children:"Attivo"})]})]})})]})]})};exports.HeaderDesktop=N;
//# sourceMappingURL=index.cjs164.js.map