1import{j as r}from"./jsx-runtime-u17CrQMm.js";import{B as R,F as ee,z as Ge,w as M,E as Re,S as $,t as Ae,v as Ve,am as ge,an as We,f as xe,g as qe,ao as Xe,ap as Je,aq as Qe,ar as Ke}from"./Button-D3dM_5em.js";import{r as p,L as Me,j as Ze}from"./chunk-JMJ3UQ3L-Cl6nLvSq.js";import{t as ue,i as Fe}from"./html-CPurVmc8.js";import{S as et}from"./FourUpWithTitle-Mgrgs7KN.js";import{S as tt}from"./EventMetaFields-wzWBdL0_.js";const we=n=>p.createElement("svg",{width:86,height:88,viewBox:"0 0 86 88",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("line",{y1:-6.95588,x2:86,y2:-6.95588,transform:"matrix(1 0 0 -1 0 73.377)",stroke:"#161616",strokeWidth:13.9118}),p.createElement("line",{y1:-6.95588,x2:86,y2:-6.95588,transform:"matrix(0 -1 -1 0 72.0977 86)",stroke:"#161616",strokeWidth:13.9118}),p.createElement("line",{y1:-6.95588,x2:101.058,y2:-6.95588,transform:"matrix(-0.713336 -0.700822 -0.700822 0.713336 72.0977 80.9668)",stroke:"#161616",strokeWidth:13.9118})),rt=n=>p.createElement("svg",{width:14,height:14,viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("path",{d:"M7 8.75V1.75",stroke:"currentColor",strokeWidth:1.16667,strokeLinecap:"round",strokeLinejoin:"round"}),p.createElement("path",{d:"M12.25 8.75V11.0833C12.25 11.3928 12.1271 11.6895 11.9083 11.9083C11.6895 12.1271 11.3928 12.25 11.0833 12.25H2.91667C2.60725 12.25 2.3105 12.1271 2.09171 11.9083C1.87292 11.6895 1.75 11.3928 1.75 11.0833V8.75",stroke:"currentColor",strokeWidth:1.16667,strokeLinecap:"round",strokeLinejoin:"round"}),p.createElement("path",{d:"M4.08203 5.83203L6.9987 8.7487L9.91536 5.83203",stroke:"currentColor",strokeWidth:1.16667,strokeLinecap:"round",strokeLinejoin:"round"})),it=n=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("rect",{x:6,y:4,width:4,height:16,fill:"currentColor"}),p.createElement("rect",{x:14,y:4,width:4,height:16,fill:"currentColor"})),nt=n=>p.createElement("svg",{width:24,height:24,viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("path",{d:"M8 5V19L19 12L8 5Z",fill:"currentColor"})),st=n=>p.createElement("svg",{viewBox:"0 0 263 268",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("path",{d:"M100.617 9.00589C102.374 -0.485664 114.631 -3.27349 120.32 4.52459L164.891 65.6184C167.264 68.8711 171.224 70.5674 175.216 70.0409L250.19 60.1507C259.76 58.8883 266.199 69.684 260.541 77.5044L216.21 138.773C213.85 142.035 213.461 146.325 215.195 149.959L247.769 218.208C251.927 226.919 243.65 236.379 234.464 233.414L162.495 210.186C158.663 208.95 154.462 209.905 151.542 212.678L96.7 264.748C89.6998 271.394 78.145 266.445 78.126 256.792L77.9776 181.168C77.9697 177.142 75.7627 173.442 72.2239 171.521L5.75481 135.454C-2.72937 130.85 -1.59305 118.331 7.58138 115.331L79.4582 91.8203C83.2849 90.5686 86.1221 87.3262 86.8548 83.3672L100.617 9.00589Z",fill:"currentColor"})),ot=n=>p.createElement("svg",{width:19,height:19,viewBox:"0 0 19 19",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("path",{d:"M8.7085 3.72236C8.70834 3.61209 8.67552 3.50434 8.61418 3.4127C8.55284 3.32107 8.46573 3.24966 8.36385 3.20748C8.26196 3.1653 8.14987 3.15425 8.04171 3.17572C7.93355 3.19719 7.83417 3.25021 7.75612 3.32811L5.07712 6.00632C4.97373 6.11032 4.85073 6.19278 4.71524 6.2489C4.57976 6.30503 4.43448 6.3337 4.28783 6.33327H2.37516C2.1652 6.33327 1.96384 6.41668 1.81537 6.56515C1.6669 6.71361 1.5835 6.91498 1.5835 7.12494V11.8749C1.5835 12.0849 1.6669 12.2863 1.81537 12.4347C1.96384 12.5832 2.1652 12.6666 2.37516 12.6666H4.28783C4.43448 12.6662 4.57976 12.6949 4.71524 12.751C4.85073 12.8071 4.97373 12.8896 5.07712 12.9936L7.75533 15.6726C7.83339 15.7508 7.93291 15.8041 8.04127 15.8257C8.14964 15.8473 8.26198 15.8362 8.36406 15.7939C8.46614 15.7516 8.55337 15.6799 8.61468 15.588C8.676 15.4961 8.70865 15.388 8.7085 15.2775V3.72236Z",stroke:"white",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),p.createElement("path",{d:"M17.4165 7.125L12.6665 11.875",stroke:"white",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),p.createElement("path",{d:"M12.6665 7.125L17.4165 11.875",stroke:"white",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),at=n=>p.createElement("svg",{width:10,height:17,viewBox:"0 0 10 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",...n},p.createElement("g",{clipPath:"url(#clip0_1512_10671)"},p.createElement("path",{d:"M7.79297 3.33068C7.79283 3.23202 7.76346 3.13561 7.70858 3.05362C7.6537 2.97164 7.57576 2.90774 7.4846 2.87C7.39344 2.83227 7.29314 2.82238 7.19637 2.84159C7.09959 2.8608 7.01068 2.90824 6.94084 2.97793L4.54384 5.37423C4.45134 5.46728 4.34128 5.54106 4.22006 5.59128C4.09883 5.64149 3.96885 5.66715 3.83764 5.66677H2.1263C1.93844 5.66677 1.75827 5.7414 1.62543 5.87423C1.4926 6.00707 1.41797 6.18724 1.41797 6.3751V10.6251C1.41797 10.813 1.4926 10.9931 1.62543 11.126C1.75827 11.2588 1.93844 11.3334 2.1263 11.3334H3.83764C3.96885 11.333 4.09883 11.3587 4.22006 11.4089C4.34128 11.4591 4.45134 11.5329 4.54384 11.626L6.94013 14.023C7.00998 14.093 7.09902 14.1406 7.19598 14.16C7.29294 14.1793 7.39346 14.1694 7.48479 14.1315C7.57613 14.0937 7.65417 14.0296 7.70903 13.9473C7.76389 13.8651 7.79311 13.7684 7.79297 13.6695V3.33068Z",stroke:"white",strokeWidth:1.41667,strokeLinecap:"round",strokeLinejoin:"round"})),p.createElement("defs",null,p.createElement("clipPath",{id:"clip0_1512_10671"},p.createElement("rect",{width:9.91667,height:17,fill:"white"})))),ve=6,lt=({title:n,content:s,sectionHeading:a})=>{const[o,u]=p.useState(!1),c=p.useId(),f=p.useId();return r.jsxs("div",{className:"not-last:border-b",children:[r.jsxs("button",{type:"button",className:` 2 content-padding-x flex w-full justify-between pt-6 pb-4 text-left 3 transition-colors 4 hover:text-primary-red 5 desktop:px-28 6 `,onClick:()=>{const h=!o,d=a?.trim();ee({event:"click",click_id:h?d?`${d} - expand accordion`:"expand accordion":d?`${d} - close accordion`:"close accordion",click_target:"body"}),u(h)},"aria-expanded":o,"aria-controls":c,id:f,children:[r.jsx("h4",{className:` 7 body-large 8 ${o?"font-medium":""} 9 `,children:n}),r.jsx(Ge,{className:M(` 10 h-5 w-5 shrink-0 11 motion-safe:transition-transform motion-safe:duration-300 12 `,{"rotate-180":o})})]}),r.jsx("div",{className:` 13 grid ease-in-out 14 motion-safe:transition-[grid-template-rows] motion-safe:duration-300 15 ${o?"grid-rows-[1fr]":"grid-rows-[0fr]"} 16 `,children:r.jsx("div",{className:M(` 17 overflow-hidden 18 motion-safe:transition-[visibility] motion-safe:duration-300 19 `,{visible:o,invisible:!o}),children:r.jsx("div",{id:c,"aria-labelledby":f,className:` 20 rich-editor-content content-padding-x pt-2 pb-8 21 desktop:px-28 22 `,dangerouslySetInnerHTML:{__html:ue(s,{pClass:"body-small"})}})})})]})},yr=({data:n})=>{const{heading:s,items:a,show_all_items:o}=n,[u,c]=p.useState(!1),f=p.useId(),h=o===!0||u,d=a.length>ve,m=!d||h?a:a.slice(0,ve),b=d&&!h;return a.length?r.jsxs("section",{className:` 23 pb-14 24 desktop:pb-18 25 `,children:[s&&r.jsx("h3",{className:"h5-medium content-padding-x py-4",children:s}),r.jsx("div",{id:f,children:m.map((y,k)=>r.jsx(lt,{sectionHeading:s,...y},k))}),b&&r.jsx("div",{className:` 26 px-4 27 desktop:px-28 28 `,children:r.jsx(R,{suppressGtmButtonClick:!0,onClick:()=>
28{ee({event:"click",click_id:[s,"Load more"].filter(Boolean).join(" · ")||"Load more",click_target:"body"}),c(!0)},size:"sm-desktop",children:"Load more"})})]}):null},ct=-.225,ke=.2;function Te(){return typeof window>"u"?!0:window.matchMedia("(prefers-reduced-motion: reduce)").matches}const he=({imageUrl:n,className:s="",imageClassName:a="",fit:o="cover"})=>{const u=p.useRef(null),c=p.useRef(null),f=p.useRef(!0),[h,d]=p.useState(void 0);if(p.useEffect(()=>{if(!n)return;const y=new Image;y.src=n,y.onload=()=>{d({w:y.naturalWidth,h:y.naturalHeight})},y.onerror=()=>d(void 0)},[n]),p.useEffect(()=>{f.current=Te();const y=window.matchMedia("(prefers-reduced-motion: reduce)"),k=()=>{f.current=Te()};return y.addEventListener("change",k),()=>y.removeEventListener("change",k)},[]),Re(()=>{const y=u.current,k=c.current;if(!y||!k||f.current)return;const C=y.getBoundingClientRect(),w=(C.top+C.height/2-window.innerHeight/2)*ct;k.style.transform=`translateY(${w}px)`}),!n)return null;const m=o==="contain",b=h!==void 0?`${h.w/h.h}`:void 0;return r.jsx("div",{ref:u,className:` 29 relative w-full overflow-hidden 30 ${s} 31 `,style:{...b&&!s.includes("aspect-")?{aspectRatio:b}:{}},children:r.jsx("div",{ref:c,className:` 32 absolute left-0 w-full bg-center bg-no-repeat 33 ${m?"inset-y-0 bg-contain":"top-0 bg-cover"} 34 ${a} 35 `,style:{...m?{}:{height:`${(1+2*ke)*100}%`,top:`${-ke*100}%`},backgroundImage:`url(${n})`}})})};function dt(n){if(!n?.trim())return"";const s=n.match(/<h[1-6]\b[^>]*>([\s\S]*?)<\/h[1-6]>/i);return s?.[1]?s[1].replace(/<[^>]*>/g," ").replace(/\s+/g," ").trim():""}const v={section:"min-h-0",sectionViewportHeight:"viewport-height-wrapper",sectionLayoutStack:"flex flex-col",sectionHeader:` 36 content-padding-x content-padding-y flex shrink-0 flex-col items-start 37 justify-between gap-4 38 desktop:flex-row desktop:items-center 39 `,sectionHeaderMbFiftyMobile:"mb-4 desktop:mb-0",sectionHeaderPb0Desktop:"desktop:pb-0",sectionHeading:"h4-medium mb-0 text-primary-soft-black",shell:"flex min-h-0 flex-1 flex-col overflow-hidden",shellPadX:` 40 px-4 41 desktop:px-8 42 `,shellPadXFiftyArrowDesktop:"desktop:px-8",shellPadDefault:` 43 pt-4 pb-14 44 desktop:pt-8 desktop:pb-[80px] 45 `,shellPadYFiftyArrowDesktop:"desktop:pt-10 desktop:pb-22",main:"flex min-h-0 min-w-0 flex-1 flex-col overflow-hidden desktop:items-start",mainFiftyFifty:` 46 items-stretch gap-0 47 desktop:min-w-0 desktop:flex-row 48 `,mainDefault:` 49 gap-6 50 desktop:gap-[clamp(3rem,10vw,9.375rem)] 51 `,contentCol:"flex min-h-0 min-w-0 flex-col gap-6 overflow-hidden",contentColFifty:` 52 px-4 53 desktop:w-1/2 desktop:min-w-0 desktop:flex-none 54 desktop:p-[clamp(1rem,2.5vw,2rem)] 55 `,contentColFiftyPadDefault:"py-5",contentColFiftyPadArrowMobile:` 56 pt-5 pb-16 57 desktop:p-[clamp(1rem,2.5vw,2rem)] 58 `,mediaOrderArrowMobile:"order-1 desktop:order-none",contentOrderArrowMobile:"order-2 desktop:order-none",contentColDefault:` 59 w-full 60 desktop:w-[clamp(17.5rem,32vw,26.25rem)] desktop:min-w-0 desktop:shrink-0 61 `,bodyHtmlBase:"min-h-0 flex flex-col gap-6 break-words",bodyHtmlFiftyNarrow:"desktop:max-w-[70%]",mediaCol:"flex min-h-0 min-w-0 w-full overflow-hidden",mediaColFifty:` 62 flex-col 63 desktop:w-1/2 desktop:min-w-0 desktop:flex-none 64 `,mediaColDefault:` 65 flex-1 66 desktop:min-h-0 67 `,parallaxBase:` 68 max-h-full min-h-0 w-full max-w-full 69 desktop:min-w-0 70 `,parallaxFifty:"aspect-[700/750] min-h-0 flex-1 max-h-full w-auto",parallaxDefault:"aspect-[800/530] max-h-full w-auto",arrowDesktopStrip:` 71 relative hidden shrink-0 bg-primary-soft-white 72 desktop:block desktop:h-[clamp(7.5rem,12vw,13.125rem)] 73 `,arrowMobileStrip:` 74 relative order-3 block h-[108px] shrink-0 bg-primary-soft-white 75 desktop:hidden 76 `,arrowIconInnerDesktop:"absolute bottom-0",arrowIconInnerMobile:"absolute bottom-8 left-4"},br=({data:n})=>{const{section_heading:s,header_button_label:a,header_button_link:o,has_dot:u=!1,body_font_size:c="body-large",image_position:f="right",content:h,image:d,button_label:m,button_link:b,button_full_width:y=!1,image_ratio:k="default",background_color:C,button_style:g="default",has_arrow_style:w=!1,image_no_crop:N=!1,render_h2_tag:P=!1}=n,O=P?"h2":"h4";if(!s&&!h&&!d)return null;const x=k==="50/50",S=f==="left",_=w&&x,D=x&&C&&!Fe(C)?"text-primary-true-white":"text-primary-soft-black",E=g==="clear"?"clear":"default",F=S?"desktop:flex-row-reverse":"desktop:flex-row",q=dt(h)||s?.trim()||m?.trim()||"call to action";return r.jsxs("section",{className:M(v.section,N?v.sectionLayoutStack:v.sectionViewportHe
76ight),children:[s&&r.jsxs("div",{className:M(v.sectionHeader,x&&v.sectionHeaderMbFiftyMobile,(!x||_)&&v.sectionHeaderPb0Desktop),children:[r.jsx("h4",{className:v.sectionHeading,children:s}),a&&o&&r.jsx(R,{as:"a",href:o,size:"sm-desktop",variant:"clear",icon:r.jsx($,{}),hoverEffect:"right",children:a})]}),r.jsx("div",{className:M(v.shell,!x&&v.shellPadX,_&&v.shellPadXFiftyArrowDesktop,!x&&v.shellPadDefault,_&&v.shellPadYFiftyArrowDesktop),children:r.jsxs("div",{className:M(v.main,F,x?v.mainFiftyFifty:v.mainDefault,y&&"desktop:items-stretch"),style:x&&C?{backgroundColor:C}:void 0,children:[h&&r.jsxs("div",{className:M(v.contentCol,x?v.contentColFifty:v.contentColDefault,x&&!_&&v.contentColFiftyPadDefault,x&&_&&v.contentColFiftyPadArrowMobile,_&&v.contentOrderArrowMobile),children:[r.jsx("div",{className:M(v.bodyHtmlBase,"rich-editor-content",x&&D,x&&v.bodyHtmlFiftyNarrow),dangerouslySetInnerHTML:{__html:ue(h,{hClass:O,pClass:c,headingMb0:!0,colorInherit:!0,hasDot:u})}}),m&&b&&r.jsx(R,{as:"a",href:b,size:y?"full":"sm-desktop",variant:E,icon:r.jsx($,{}),hoverEffect:"right",suppressGtmButtonClick:!0,onClick:()=>{ee({event:"click",click_id:q,click_target:"body"})},className:M("shrink-0",y&&"mt-auto"),children:m})]}),d&&r.jsxs("div",{className:M(v.mediaCol,x?v.mediaColFifty:v.mediaColDefault,_&&v.mediaOrderArrowMobile),children:[N?r.jsx("img",{className:"h-auto w-full",src:d,alt:s}):r.jsx(he,{imageUrl:d,className:M(v.parallaxBase,x?v.parallaxFifty:v.parallaxDefault)}),_&&r.jsx("div",{className:v.arrowDesktopStrip,children:r.jsx("div",{className:M(v.arrowIconInnerDesktop,S?"left-0":"left-4"),children:r.jsx(we,{className:"h-22 w-22"})})})]}),_&&r.jsx("div",{className:v.arrowMobileStrip,children:r.jsx("div",{className:v.arrowIconInnerMobile,children:r.jsx(we,{className:"h-13 w-13"})})})]})})]})},ut=({title:n="",items:s})=>r.jsxs("section",{className:` 77 content-padding-x w-full pt-4 pb-6 78 desktop:pt-8 desktop:pb-10 79 `,children:[n&&r.jsx("h2",{className:"h5-medium mb-2",children:n}),r.jsx("div",{className:` 80 grid w-full grid-cols-1 gap-4 pt-5 81 desktop:grid-cols-4 desktop:gap-6 desktop:pt-16 82 `,children:s.map((a,o)=>{const{text:u,link:c,image:f,image_alt:h,column_span:d}=a,m=()=>{ee({event:"click",click_id:u?.trim()||"art artists thumbnail",click_target:"body"})},b=r.jsxs("div",{className:"flex flex-col gap-6",children:[r.jsx("div",{children:f?r.jsx("img",{className:` 83 block h-full w-full scale-100 object-cover 84 transition-[scale] duration-300 ease-out 85 group-hover:scale-102 86 `,src:f,alt:h??u??""}):null}),u&&r.jsxs("div",{className:` 87 flex justify-between border-t border-primary-true-black pt-3 88 `,children:[r.jsx("p",{className:"body-large",children:r.jsx("strong",{className:"text-inherit",children:u})}),r.jsx(et,{className:` 89 h-3 w-3 shrink-0 transition-[rotate] duration-200 ease-out 90 group-hover:rotate-90 91 `})]})]}),y=M("group",` 92 col-span-1 flex min-w-0 flex-col gap-2 self-start 93 transition-colors duration-300 ease-out 94 hover:text-primary-red 95 `,d===2&&"desktop:col-span-2",d!==2&&"desktop:col-span-1");return c?Ae(c)?r.jsx("a",{href:c,className:y,target:"_blank",rel:"noopener noreferrer",onClick:m,children:b},o):r.jsx(Me,{to:Ve(c),className:y,onClick:m,children:b},o):r.jsx("div",{className:y,onClick:m,children:b},o)})})]}),pt=({title:n="",items:s})=>r.jsxs("section",{className:` 96 content-padding-x w-full pt-4 pb-6 97 desktop:pt-8 desktop:pb-10 98 `,children:[n&&r.jsx("h2",{className:"h5-medium mb-2",children:n}),r.jsx("div",{className:"flex flex-col gap-6",children:s.map((a,o)=>r.jsxs("div",{className:` 99 flex flex-col items-start gap-4 100 desktop:flex-row desktop:gap-8 desktop:py-4 101 `,children:[a.image?r.jsx("img",{className:` 102 block aspect-3/2 h-auto w-full object-cover 103 desktop:w-2/5 104 `,src:a.image,alt:a.image_alt||""}):null,r.jsxs("div",{className:` 105 flex flex-col gap-4 106 desktop:max-w-[40%] 107 `,children:[r.jsx("div",{className:"rich-editor-content flex flex-col gap-4",dangerouslySetInnerHTML:{__html:ue(a.content||"",{hClass:"h5-medium",pClass:"body-small",headingMb0:!0,pMb0:!0})}}),a.primary_button_text&&r.jsx(R,{as:"a",href:a.primary_button_link,size:"sm-desktop",variant:"clear",icon:r.
107jsx($,{}),hoverEffect:"right",children:a.primary_button_text})]})]},o))})]}),mt=({title:n="",type:s="2-up",items:a})=>r.jsxs("section",{className:` 108 content-padding-x w-full pt-4 pb-6 109 desktop:pt-8 desktop:pb-20 110 `,children:[n&&r.jsx("h2",{className:"h5-medium mb-5",children:n}),r.jsx("div",{className:M("grid w-full grid-cols-1 gap-8",s==="2-up"&&"desktop:grid-cols-2",s==="3-up"&&"desktop:grid-cols-3"),children:a.map((o,u)=>r.jsxs("div",{className:"flex h-auto w-full min-w-0 flex-col gap-4",children:[o.image?r.jsx("img",{className:"block aspect-670/450 h-auto w-full object-cover",src:o.image,alt:o.image_alt||""}):null,r.jsx("div",{className:"flex flex-col gap-4",children:r.jsx("div",{className:"rich-editor-content flex flex-col gap-4",dangerouslySetInnerHTML:{__html:ue(o.content||"",{hClass:"h6-medium",pClass:"body-small",headingMb0:!0,pMb0:!0})}})}),r.jsxs("div",{className:` 111 flex flex-col gap-4 112 desktop:mt-auto desktop:flex-row 113 `,children:[o.primary_button_text&&r.jsx(R,{className:"flex-1",as:"a",href:o.primary_button_link,size:"sm-desktop",variant:"default",icon:r.jsx($,{}),hoverEffect:"right",children:o.primary_button_text}),o.secondary_button_text&&r.jsx(R,{className:"flex-1",as:"a",href:o.secondary_button_link,size:"sm-desktop",variant:"clear",icon:r.jsx($,{}),hoverEffect:"right",children:o.secondary_button_text})]})]},u))})]}),gr=({data:n})=>{const{style_type:s,title:a}=n;return s==="2-up"||s==="3-up"?r.jsx(mt,{type:s,title:a,items:n.items}):s==="image-left-card-stack"?r.jsx(pt,{title:a,items:n.items}
113):s==="art-artists-thumbnail"?r.jsx(ut,{title:a,items:n.items}):null};function ft(){return"https://donate.aucklandartgallery.com/cart/"}function ht(){return"39988884570178"}function yt(n){return`${ft()}${ht()}:${n}`}const fe=[5,10,15,25,30,"custom"];function Ee(n,s){const a=fe[n];if(a==="custom"){const o=Number(s);return Number.isFinite(o)&&o>0?o:"null"}return a}const je=({children:n,onSelect:s,isSelected:a})=>r.jsxs("div",{className:` 114 content-padding-x flex max-h-[72px] items-center justify-between py-4 115 not-last:border-b 116 desktop:px-[20%] desktop:first:border-t desktop:last:border-b 117 `,children:[n,r.jsx(R,{size:"sm",variant:"clear",suppressGtmButtonClick:!0,onClick:s,isSelected:a,children:a?"Selected":"Select"})]}),xr=({gtmClickTarget:n="body"})=>{const[s,a]=p.useState(""),[o,u]=p.useState(null),c=h=>{u(h),ge("select amount","donation",Ee(h,s),n)},f=()=>{if(o===null)return;const h=fe[o],d=h==="custom"?s:h;if(!d)return;const m=Ee(o,s);m!=="null"&&(ge("donate entry","make a donation",m,n),window.location.href=yt(Number(d)))};return r.jsxs("section",{className:"pt-4 pb-12",children:[r.jsx("div",{children:fe.map((h,d)=>h==="custom"?r.jsx(je,{onSelect:()=>c(d),isSelected:o===d,children:r.jsxs("div",{children:[r.jsxs("div",{className:"flex items-center space-x-2",children:[r.jsx("p",{className:"h6 relative mb-0",children:"$"}),r.jsx("input",{className:"input max-w-[100px]",type:"number",value:s,onChange:m=>a(m.target.value)})]}),r.jsx("p",{className:"caption mt-1 mb-0",children:"Enter custom amount"})]})},d):r.jsx(je,{onSelect:()=>c(d),isSelected:o===d,children:r.jsxs("p",{className:"h6 mb-0",children:["$",h]})},d))}),r.jsx("div",{className:` 118 content-padding-x flex py-4 119 desktop:justify-end desktop:px-[20%] 120 `,children:r.jsx(R,{size:"sm-desktop",variant:"default",suppressGtmButtonClick:!0,onClick:f,disabled:o===null,children:"Donate"})})]})},ye="/assets/download-bg-CJIhzdmt.png";function bt(n){if(!n?.trim())return null;const s=n.toLowerCase().trim(),a={"application/pdf":"PDF","image/png":"PNG","image/jpeg":"JPEG","image/jpg":"JPEG","image/gif":"GIF","image/webp":"WebP","application/zip":"ZIP"};if(a[s])return a[s];const o=s.split("/")[1];return o?o.toUpperCase().slice(0,12):n}function gt(n){if(n==null||n==="")return null;const s=Number.parseInt(String(n),10);return!Number.isFinite(s)||s<0?null:s<1024?`${s} B`:s<1024*1024?`${(s/1024).toFixed(s<10240?1:0)} KB`:`${(s/(1024*1024)).toFixed(1)} MB`}const xt=({title:n,description:s,file:a,mimetype:o,filesize:u,displayImage:c,preview_image:f})=>{const h=a.split("/").pop()||"download",d=bt(o),m=gt(u),b=[d,m].filter(Boolean),y=b.length>0?b.join(" · "):null,k=f||ye;return r.jsxs("div",{className:"flex basis-1/3 flex-col gap-2",children:[c&&r.jsx("img",{className:"mb-2 aspect-435/290 object-contain",src:k,alt:`Download ${n??h}`}),r.jsxs("div",{className:` 121 flex min-w-0 flex-col items-start justify-between gap-1 122 desktop:flex-row 123 `,children:[r.jsx("h4",{className:"h7-medium min-w-0 flex-1",children:n}),y&&r.jsx("p",{className:` 124 legal mb-0 shrink-0 text-right text-primary-soft-black 125 desktop:mt-2 126 `,"aria-label":[d&&`Type ${d}`,m&&`Size ${m}`].filter(Boolean).join(", "),children:y})]}),s&&r.jsx("p",{className:"body-small",children:s}),r.jsx(R,{className:"mt-auto",as:"a",href:a,download:n??h,size:"full",variant:"clear",icon:r.jsx(rt,{}),target:"_blank",rel:"noopener noreferrer",suppressGtmButtonClick:!0,onClick:()=>{We(a,o)},children:"Download"})]})},wr=({data:n})=>{const{title:s,display_image:a,items:o}=n;return r.jsxs("section",{className:` 127 content-padding-x pt-4 pb-10 128 desktop:pt-6 desktop:pb-20 129 `,children:[s&&r.jsx("h5",{className:` 130 h5-medium mb-6 131 desktop:mb-10 132 `,children:s}),r.jsx("div",{className:` 133 grid items-stretch gap-6 134 desktop:grid-cols-3 desktop:gap-8 135 `,children:o.map(u=>r.jsx(xt,{...u,displayImage:a},u.id))})]})};function wt(n){return n==null||typeof n!="object"?"":(n.attributes??n).thumbnail_image??""}function vt(n){const s=n.data;return Array.isArray(s)?s:s!=null&&typeof s=="object"?[s]:[]}function kt(n){const s=n?.items;return s?.length?s.flatMap(a=>{const o=vt(a),u=a.name??"Artwork";return o.map(c=>({src:wt(c)||ye,alt:u}))}):[]}const $e=[2,2,2,3,2,3],He=[3,6,5],Ie=Math.max($e.reduce((n,s)=>n+s,0),He.reduce((n,s)=>n+s,0)),Tt=.75,Et=[{direction:1,speed:.06,topOffsetPercent:-2},{direction:-1,speed:.08,topOffsetPercent:52},{direction:-1,speed:.2,topOffsetPercent:87},{direction:-1,speed:.2,topOffsetPercent:0},{direction:1,speed:.2,topOffsetPercent:-9},{direction:1,speed:.2,topOffsetPercent:0},{direction:1,speed:.3,topOffsetPercent:-17},{direction:-1,speed:.2,topOffsetPercent:89},{direction:-1,speed:.2,topOffsetPercent:0},{direction:1,speed:.1,topOffsetPercent:26},{direction:1,speed:.1,topOffsetPercent:0},{direction:-1,speed:.1,topOffsetPercent:-2},{direction:-1,speed:.3,topOffsetPercent:40},{direction:-1,speed:.3,topOffsetPercent:0}],jt=[{direction:1,speed:.1,topOffsetPercent:30},{direction:-1,speed:.1,topOffsetPercent:35},{direction:-1,speed:.1,topOffsetPercent:0},{direction:1,speed:.06,topOffsetPercent:15},{direction:1,speed:.06,topOffsetPercent:0},{direction:1,speed:.06,topOffsetPercent:0},{direction:-1,speed:.06,topOffsetPercent:20},{direction:-1,speed:.06,topOffsetPercent:0},{direction:-1,speed:.06,topOffsetPercent:0},{direction:1,speed:.06,topOffsetPercent:10},{direction:1,speed:.06,topOffsetPercent:0},{direction:-1,speed:.06,topOffsetPercent:20},{direction:-1,speed:.06,topOffsetPercent:0},{direction:-1,speed:.06,topOffsetPercent:0}],vr=({data:n})=>{const{title:s,link_text:a,link_url:o}=n??{},u=p.useRef(null),c=p.useRef(0),f=p.useRef(0),[,h]=p.useState(0),d=p.useRef(null),m=p.useMemo(()=>{const g=kt(n);return g.length===0?Array.from({length:Ie},()=>({src:ye,alt:"Artwork"})):Array.from({length:Ie},(w,N)=>g[N%g.length])},[n]),b=p.useCallback(()=>{const g=u.current;if(!g)return;const w=g.getBoundingClientRect(),N=typeof window<"u"?window.innerHeight:0,P=w.top,O=typeof window<"u"?window.scrollY:0,x=O+P,S=O-x+N*.5;c.current=S,f.current=w.height,h(_=>_+1)},[]);p.useEffect(()=>{const g=()=>{d.current!=null&&cancelAnimationFrame(d.current),d.current=requestAnimationFrame(()=>{b(),d.current=null})},w=requestAnimationFrame(()=>b());return window.addEventListener("scroll",g,{passive:!0}),window.addEventListener("resize",b),()=>{cancelAnimationFrame(w),window.removeEventListener("scroll",g),window.removeEventListener("resize",b),d.current!=null&&cancelAnimationFrame(d.current)}},[b]);const y=c.current,k=f.current,C=(g,w,N)=>Array.from({length:g.length},(P,O)=>{const x=g.slice(0,O).reduce((D,E)=>D+E,0),S=g[O],_=m.slice(x,x+S);return r.jsx("div",{className:` 136 flex flex-1 flex-col gap-3 137 desktop:gap-6 138 `,children:_.map((D,E)=>
138{const F=x+E,q=N[F]??N[0],{direction:te,speed:H,topOffsetPercent:Q}=q,re=Q??0,j=y*te*H*Tt,z=k>0?k*re/100:0;return r.jsx("div",{className:"relative w-full overflow-hidden",style:{marginTop:z,transform:`translate3d(0, ${j}px, 0)`,willChange:"transform"},children:r.jsx("img",{src:D.src,alt:D.alt,className:"w-full"})},`${w}-${O}-${F}`)})},`${w}-${O}`)});return r.jsxs("section",{ref:u,className:` 139 content-padding-x relative aspect-390/800 w-full overflow-hidden 140 desktop:aspect-1440/900 141 `,children:[r.jsxs("div",{className:` 142 content-padding-x absolute top-0 left-0 z-10 143 bg-[linear-gradient(to_bottom,var(--color-primary-soft-white)_0%,var(--color-primary-soft-white)_85%,transparent_100%)] 144 py-10 145 desktop:top-1/2 desktop:max-w-[400px] desktop:-translate-y-1/2 146 desktop:bg-none desktop:py-0 147 `,children:[r.jsx("h5",{className:"h5-medium mb-4",children:s}),a&&o&&r.jsx(R,{as:"a",href:o,size:"sm-desktop",variant:"clear",icon:r.jsx($,{}),children:a})]}),r.jsx("div",{className:` 148 flex gap-3 149 desktop:hidden 150 `,children:C(He,"mobile",jt)}),r.jsx("div",{className:` 151 hidden gap-3 152 desktop:flex desktop:gap-6 153 `,children:C($e,"desktop",Et)})]})},It=({data:n})=>{const{slug:s,start_date:a,end_date:o,main_image:u,name:c,theme_color:f,short_description:h,cost:d,sold_out:m}=n??{};if(!n||!s)return null;const b=xe(a),y=xe(o),k=b&&y?`${b} â ${y}`:b??y??"",C=b&&y?r.jsxs(r.Fragment,{children:[b," â ",r.jsx("br",{}),y]}):b??y??null,g=Fe(f),w=g?"text-primary-true-black":"text-primary-true-white",N=g?"bg-primary-true-black":"bg-primary-true-white",P=Xe(s),O="Learn more",x=d?.toString()?.toLowerCase()?.trim()==="free",S=m?"Sold out":d?x?"Free":d:null,_=m?"bg-primary-red":x?"bg-secondary-pohutukawa":N;return r.jsxs("section",{className:` 154 viewport-height-wrapper 155 desktop:px-8 desktop:pt-6 desktop:pb-22 156 `,children:[r.jsxs("div",{className:` 157 mb-0 flex shrink-0 flex-col justify-between gap-6 p-4 158 desktop:mb-10 desktop:flex-row desktop:p-0 159 `,children:[r.jsx("h4",{className:"h4-medium mb-0 text-primary-true-black",children:"Featured exhibition"}),r.jsx(R,{as:"a",href:qe,variant:"clear",size:"sm-desktop",icon:r.jsx($,{className:"h-4 w-4"}),hoverEffect:"right",children:"View all"}),r.jsx("h1",{className:` 160 h1 mb-0 161 desktop:mt-12 desktop:hidden 162 `,children:C})]}),r.jsxs("div",{className:` 163 flex min-h-0 flex-1 flex-col items-stretch 164 desktop:flex-row 165 `,children:[r.jsxs("div",{className:"flex min-h-0 flex-1 flex-col overflow-hidden",children:[r.jsx("div",{className:"min-h-0 flex-1 overflow-hidden",children:r.jsx(he,{imageUrl:u??"",className:` 166 aspect-square h-full max-h-full w-auto max-w-full 167 desktop:aspect-700/470 168 `})}),r.jsx("h1",{className:` 169 h1 mb-3 hidden 170 desktop:mt-12 desktop:block 171 `,children:C})]}),r.jsxs("div",{className:` 172 flex min-h-fit flex-1 flex-col justify-between gap-11 px-4 pt-5 173 pb-10 174 desktop:pt-8 desktop:pr-6 desktop:pb-6 desktop:pl-8 175 `,style:{backgroundColor:f},children:[r.jsxs("div",{className:` 176 flex flex-col gap-6 177 desktop:max-w-[80%] 178 `,children:[r.jsxs("h4",{className:` 179 h4-medium mb-0 180 ${w} 181 `,children:[r.jsx("span",{className:` 182 mr-1 inline-block h-6 w-6 rounded-full 183 ${N} 184 `}),c]}),r.jsx("p",{className:` 185 body-medium mb-0 186 ${w} 187 `,children:h}),r.jsx(R,{as:"a",href:P,variant:"default",size:"sm-desktop",icon:r.jsx($,{className:"h-4 w-4"}),hoverEffect:"right",children:O})]}),r.jsxs("div",{className:` 188 flex flex-col gap-1 189 ${w} 190 `,children:[r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx(tt,{className:"h-4 w-4"}),r.jsx("p",{className:"body-medium mb-0",children:k})]}),S&&r.jsxs("div",{className:"flex items-center gap-2",children:[r.jsx("span",{className:M("inline-block h-3 w-3 rounded-full",_)}),r.jsx("p",{className:"body-medium mb-0",children:S})]})]})]})]})]})},Ce=n=>` 191 h2 mb-0 cursor-pointer text-primary-true-white 192 transition-opacity duration-200 193 ${n?"opacity-80":""} 194`,Ct=({data:n})=>{const{title:s,image:a,cta_link:o,cta_text:u}=n,[c,f]=p.useState(!1),h={onMouseEnter:()=>f(!0),onMouseLeave:()=>f(!1)},d=s&&r.jsxs(r.Fragment,{children:[r.jsx("span",{className:` 195 mr-2 mb-2 inline-block h-5 w-5 rounded-full bg-primary-true-white 196 desktop:mb-3 desktop:h-9 desktop:w-9 197 `,"aria-hidden":!0}),s]});return r.jsx("section",{className:` 198 pt-8 pb-10 199 desktop:px-8 desktop:pb-42 200 `,children:r.jsxs("div",{className:` 201 viewport-height-wrapper flex min-h-[200px] flex-col 202 text-primary-true-white 203 desktop:flex-row desktop:items-stretch 204 `,children:[r.jsxs("div",{className:` 205 relative flex min-h-[300px] w-full flex-col justify-end 206 bg-primary-soft-black p-4 207 desktop:mb-18 desktop:w-3/5 desktop:p-6 208 `,children:[r.jsx($,{className:` 209 absolute top-4 left-4 h-12 w-12 transition-transform duration-300 210 desktop:h-28 desktop:w-28 211 ${c?"rotate-45":"-rotate-45"} 212 `}),s&&r.jsx("div",{...h,children:o?r.jsx("a",{href:o,className:"block",children:r.jsx("h2",{className:Ce(c),children:d})}):r.jsx("h2",{className:Ce(c),children:d})})]}),r.jsxs("div",{className:` 213 relative mb-18 flex flex-1 flex-col items-center justify-stretch 214 bg-primary-soft-black 215 `,children:[r.jsx(he,{imageUrl:a??"",className:` 216 aspect-390/230 217 desktop:aspect-550/715 desktop:max-h-full 218 `}),r.jsx("div",{className:` 219 top-full left-0 h-18 w-full 220 desktop:absolute 221 `,...h,children:o&&u&&r.jsx(R,{as:"a",href:o,size:"full",variant:"secondary",suppressGtmButtonClick:!0,onClick:()=>{ee({event:"click",click_id:u})},className:` 222 h-full p-3 223 ${c?"bg-primary-red! text-primary-true-white!":void 0}
224 `,icon:r.jsx($,{className:"h-4 w-4"}),children:u})})]})]})})},ce="var(--color-kids-yellow)",Nt=263,Pt=268,Lt=.8660254;function _t(n,s){const a=n.getBoundingClientRect(),o=s+a.top;return s-o+(typeof window<"u"?window.innerHeight:0)*.5}function Dt(n,s,a){const o=s*a;switch(n){case"scrollVertical":return{dx:0,dy:-o};case"scrollDownLeft45":return{dx:-o,dy:o};case"scrollDownRight45":return{dx:o,dy:o};case"scrollUpRight45":return{dx:o,dy:-o};case"scrollUpLeft45":return{dx:-o,dy:-o}}}const Ot=.2,Ut={circle:1.5,"square-a":.6,"square-b":.6,triangle:.6,star:.6},St={circle:"scrollVertical","square-a":"scrollDownLeft45",triangle:"scrollDownRight45","square-b":"scrollUpLeft45",star:"scrollUpRight45"},Ne=[{id:"circle",type:"circle",top:"80%",left:"0%",size:200,mobile:{top:"74%",left:"10%",size:120}},{id:"square-a",type:"square",top:"-5%",left:"30%",size:200,rotateDeg:20,mobile:{top:"-5%",left:"30%",rotateDeg:20,size:100}},{id:"square-b",type:"square",top:"115%",left:"88%",size:200,rotateDeg:20,mobile:{top:"150%",left:"78%",rotateDeg:8,size:100}},{id:"triangle",type:"triangle",top:"-5%",left:"80%",size:200,rotateDeg:-20,mobile:{top:"10%",left:"72%",rotateDeg:-12,size:150}},{id:"star",type:"star",top:"90%",left:"35%",size:300,rotateDeg:-12,mobile:{top:"98%",left:"70%",rotateDeg:-6,size:160}}],be=768,Pe=320,Le=1440,_e=.3;function Rt(n){if(n>=Le||n<=be)return 1;const s=(n-Pe)/(Le-Pe);return _e+s*(1-_e)}function At(n){return typeof window>"u"?()=>{}:(window.addEventListener("resize",n,{passive:!0}),()=>window.removeEventListener("resize",n))}const ze={sizeMul:1,layoutDesktop:!0};let pe=null;function Vt(){if(typeof window>"u")return ze;const n=window.innerWidth,s=Rt(n),a=n>=be,o=`${s}:${Number(a)}`;if(pe?.key===o)return pe.snap;const u={sizeMul:s,layoutDesktop:a};return pe={key:o,snap:u},u}function Mt(){return ze}function Ft(){return p.useSyncExternalStore(At,Vt,Mt)}function De(n,s){return s||!n.mobile?{top:n.top,left:n.left,rotateDeg:n.rotateDeg}:{top:n.mobile.top,left:n.mobile.left,rotateDeg:n.mobile.rotateDeg??n.rotateDeg}}function $t(n,s,a){const o=!s&&n.mobile?.size!=null?n.mobile.size:n.size;return Math.round(o*a)}function Ht(n,s){return{position:"absolute",top:n,left:s,transformOrigin:"center"}}function me(n,s,a){const o=n!=null?` rotate(${n}deg)`:"";return`translate(calc(-50% + ${s}px), calc(-50% + ${a}px))${o}`}function Oe(){return typeof window>"u"?!0:window.matchMedia("(prefers-reduced-motion: reduce)").matches}function zt({sectionRef:n}){const s=p.useRef({}),a=p.useRef(!0),o=Ft();p.useEffect(()=>{a.current=Oe();const c=window.matchMedia("(prefers-reduced-motion: reduce)"),f=()=>{a.current=Oe()};return c.addEventListener("change",f),()=>c.removeEventListener("change",f)},[]);const u=p.useCallback(c=>{const f=n.current;if(!f||typeof window>"u")return;const h=c?.scroll??window.scrollY??window.pageYOffset,d=_t(f,h),m=a.current,b=window.innerWidth>=be;for(const y of Ne){const k=s.current[y.id];if(!k)continue;const{rotateDeg:C}=De(y,b);if(m){k.style.transform=me(C,0,0);continue}const g=St[y.id];if(!g)continue;const w=Ut[y.id]??1,{dx:N,dy:P}=Dt(g,d,Ot*w);k.style.transform=me(C,N,P)}},[n]);return Re(c=>{u(c)}),p.useLayoutEffect(()=>{u()},[u,o.sizeMul,o.layoutDesktop]),r.jsx("div",{className:"pointer-events-none absolute inset-0","aria-hidden":!0,children:Ne.map(c=>{const f=De(c,o.layoutDesktop),h=Ht(f.top,f.left),d=me(f.rotateDeg,0,0),m=$t(c,o.layoutDesktop,o.sizeMul);if(c.type==="circle")return r.jsx("div",{ref:y=>{y?s.current[c.id]=y:delete s.current[c.id]},style:{...h,transform:d,width:m,height:m,borderRadius:"50%",backgroundColor:ce}},c.id);if(c.type==="square")return r.jsx("div",{ref:y=>{y?s.current[c.id]=y:delete s.current[c.id]},style:{...h,transform:d,width:m,height:m,backgroundColor:ce}},c.id);if(c.type==="triangle"){const y=Math.round(m*Lt);return r.jsx("div",{ref:k=>{k?s.current[c.id]=k:delete s.current[c.id]},style:{...h,transform:d,width:m,height:y,backgroundColor:ce,clipPath:"polygon(50% 0%, 0% 100%, 100% 100%)"}},c.id)}const b=Math.round(m*Pt/Nt);return r.jsx(st,{ref:y=>{y?s.current[c.id]=y:delete s.current[c.id]},width:m,height:b,className:"block shrink-0",style:{...h,transform:d,color:ce},"aria-hidden":!0},c.id)})})}const Bt=({data:n})=>{const s=p.useRef(null),{image:a,image_alt:o,image_mobile:u,section_heading:c,section_button_text:f,section_button_link:h,heading:d,description:m,button_text:b,button_link:y}=n,k=u?.trim()||a?.trim()||"",C=a?.trim()||"",g=!!(k||C),w=!!c?.trim()||!!h?.trim()&&!!f?.trim(),N=!!(d?.trim()||m?.trim()),P=!!(y?.trim()&&b?.trim()),O=N||P,x=N&&P;if(!w&&!g&&!O)return null;const S=o?.trim()||d?.trim()||"",_=` 225 mx-auto block h-auto w-full max-w-full object-contain 226 desktop:max-h-full 227 `;return r.jsx("section",{ref:s,className:` 228 flex min-h-0 w-full max-w-full flex-col overflow-hidden pb-12 229 desktop:px-8 desktop:pt-6 desktop:pb-22 230 `,children:r.jsxs("div",{className:` 231 viewport-height-wrapper mx-auto flex min-h-0 w-full max-w-full min-w-0 232 flex-1 flex-col 233 `,children:[w&&r.jsxs("div",{className:` 234 mb-0 flex w-full shrink-0 flex-col justify-between gap-6 p-4 235 desktop:mb-6 desktop:flex-row desktop:items-center desktop:p-0 236 `,children:[c?.trim()&&r.jsx("h5",{className:"h5-medium mb-0 text-primary-true-black",children:c}),h?.trim()&&f?.trim()&&r.jsx(R,{as:"a",href:h,size:"sm-desktop",icon:r.
236jsx($,{className:"h-4 w-4"}),hoverEffect:"right",children:f})]}),r.jsxs("div",{className:"flex min-h-0 min-w-0 flex-1 flex-col",children:[g&&r.jsx("div",{className:` 237 flex min-h-0 w-full min-w-0 flex-1 flex-col items-center 238 justify-center overflow-hidden 239 `,children:r.jsxs("div",{className:` 240 relative flex max-h-full min-h-0 w-full flex-1 items-center 241 justify-center 242 `,children:[r.jsx("img",{src:k,alt:S,className:` 243 ${_} 244 desktop:hidden 245 `}),r.jsx("img",{src:C,alt:S,className:` 246 ${_} 247 hidden 248 desktop:block 249 `}),r.jsx(zt,{sectionRef:s})]})}),O&&r.jsxs("div",{className:` 250 flex min-h-0 w-full min-w-0 shrink-0 flex-col items-start gap-4 251 overflow-y-auto overscroll-contain text-primary-true-white 252 desktop:gap-8 253 ${x?"desktop:flex-row":""} 254 `,children:[N&&r.jsxs("div",{className:` 255 order-2 flex min-w-0 flex-col gap-2 px-4 py-2 256 desktop:order-1 desktop:px-0 257 ${x?"desktop:flex-1":"w-full"} 258 `,children:[d?.trim()&&r.jsx("h5",{className:"h5-medium mb-0 text-primary-true-black",children:d}),m?.trim()&&r.jsx("p",{className:"body-large mb-0 text-primary-true-black",children:m})]}),P&&r.jsx("div",{className:` 259 order-1 flex w-full flex-col items-start 260 desktop:order-2 261 ${x?` 262 min-w-0 263 desktop:w-2/5 264 `:""} 265 `,children:r.jsx(R,{as:"a",href:y,size:"full",variant:"secondary",className:"self-start",icon:r.jsx($,{className:"h-4 w-4"}),children:b})})]})]})]})})},kr=({data:n})=>{if(n.variant==="date"){const s=n.exhibition;return r.jsx(It,{data:s})}return n.variant==="event2"?r.jsx(Bt,{data:n}):r.jsx(Ct,{data:n})},Yt="https://aucklandunlimited.jotform.com",Gt=600,Wt=120,qt=2e4;function Xt(n){return n.includes("jotform")}function Jt(n){return Math.min(qt,Math.max(Wt,Math.round(n)))}function Qt(n){if(typeof n!="string"||!n.startsWith("setHeight:"))return null;const s=Number.parseInt(n.slice(10),10);return Number.isFinite(s)&&s>0?s:null}function Kt(n,s){const a=n.startsWith("http")?n:`${Yt}/${n}`,o=new URL(a);if(o.searchParams.set("isIframeEmbed","1"),typeof window<"u"&&new URLSearchParams(window.location.search).forEach((c,f)=>{o.searchParams.has(f)||o.searchParams.set(f,c)}),s)for(const[u,c]of Object.entries(s))c!=null&&c!==""&&o.searchParams.set(u,c);return o.toString()}
265function Zt(n){n.contentWindow&&n.contentWindow.postMessage(JSON.stringify({type:"urls",value:{docurl:encodeURIComponent(document.URL),referrer:encodeURIComponent(document.referrer)}}),"*")}function er(n,s){if(!s||typeof n.data=="object")return null;const a=String(n.data).split(":");switch(a[0]){case"scrollIntoView":s.scrollIntoView();break;case"setHeight":{const o=Qt(n.data);if(o!=null)return Jt(o);break}case"collapseErrorPage":s.clientHeight>window.innerHeight&&(s.style.height=`${window.innerHeight}px`);break;case"reloadPage":window.location.reload();break;case"loadScript":{let o=a[1];a.length>3&&(o=`${a[1]}:${a[2]}`);const u=document.createElement("script");u.src=o,u.type="text/javascript",document.body.appendChild(u);break}case"exitFullscreen":{const o=window.document;o.exitFullscreen?o.exitFullscreen():"mozCancelFullScreen"in o&&typeof o.mozCancelFullScreen=="function"?o.mozCancelFullScreen():"webkitExitFullscreen"in o&&typeof o.webkitExitFullscreen=="function"?o.webkitExitFullscreen():"msExitFullscreen"in o&&typeof o.msExitFullscreen=="function"&&o.msExitFullscreen();break}}return Xt(n.origin)&&Zt(s),null}const Tr=({data:n})=>{const{form_id:s}=n,a=p.useRef(null),[o,u]=p.useState(Gt),c=p.useMemo(()=>s?Kt(s):"",[s]);return p.useEffect(()=>{const f=h=>{const d=er(h,a.current);d!=null&&u(d)};return window.addEventListener("message",f),()=>{window.removeEventListener("message",f)}},[]),s?r.jsx("section",{className:` 266 content-padding-x w-full py-6 267 desktop:py-8 268 `,children:r.jsx("iframe",{ref:a,id:`JotFormIFrame-${s}`,title:"JotForm",allowFullScreen:!0,allow:"geolocation; microphone; camera",src:c,frameBorder:"0",className:"w-full border-none",style:{width:1,minWidth:"100%",height:`${o}px`},scrolling:"no"})}):null},Er=({data:n})=>{const{title:s,images:a=[]}=n||{},o=a;return r.jsxs("section",{className:` 269 w-full px-4 py-4 pb-12 270 desktop:px-8 desktop:py-6 desktop:pb-22 271 `,children:[s&&r.jsx("h5",{className:"h5-medium mb-6",children:s}),r.jsx("div",{className:` 272 grid grid-cols-1 gap-2 273 desktop:grid-cols-4 desktop:gap-8 274 `,children:o.map((u,c)=>{const f=u.file_alt||u.url||`logo-${c}`,h=r.jsxs("div",{className:"flex h-full flex-col border-b pb-2",style:{borderColor:"var(--color-grey-stroke)"},children:[r.jsx("div",{className:` 275 mb-2 flex flex-1 items-center justify-center transition-opacity 276 hover:opacity-80 277 desktop:mb-6 278 `,children:u.file&&r.jsx("img",{src:u.file,alt:u.file_alt||u.description||`Logo ${c+1}`,className:"max-h-[155px] w-full object-contain"})}),u.description&&r.jsx("p",{className:"body-small mt-auto mb-0 text-left",children:u.description})]});if(u.url){const d=s?.trim()||u.description?.trim()||u.file_alt?.trim()||"logo wall",m=()=>{ee({event:"click",click_id:d,click_target:"body"})};return Ae(u.url)?r.jsx("a",{href:u.url,target:"_blank",rel:"noopener noreferrer",className:"block h-full",onClick:m,children:h},f):r.jsx(Me,{to:Ve(u.url),className:"block h-full",onClick:m,children:h},f)}return r.jsx("div",{className:"h-full",children:h},f)})})]})},jr=({data:n})=>{const{quote:s,cite:a}=n;return r.jsx("section",{className:"pt-4 pb-12",children:r.jsxs("div",{children:[r.jsx("span",{"aria-hidden":"true",className:"h3-medium block text-center text-primary-red",children:"â"}),r.jsx("blockquote",{className:"h4-medium mb-4 block text-center",children:s}),r.jsx("cite",{className:"body-small block text-center not-italic",children:a})]})})},tr=({className:n=""})=>r.jsx("div",{className:` 279 flex items-center justify-center bg-primary-soft-white 280 ${n} 281 `,"aria-hidden":!0,children:r.jsx("span",{className:` 282 block h-10 w-10 animate-spin rounded-full border-2 283 border-primary-soft-black/20 border-t-primary-red 284 motion-reduce:animate-none 285 `})});var de={exports:{}},rr=de.exports,Ue;function ir(){return Ue||(Ue=1,(function(n,s){(function(a,o){n.exports=o()})(rr,(function(){function a(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?a=function(t){return typeof t}:a=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},a(e)}var o=function(t){if(typeof t!="string")return{};t=t.split("+").join(" ");var i={},l=t.match(/(?:[?](?:[^=]+)=(?:[^&#]*)(?:[&](?:[^=]+)=(?:[^&#]*))*(?:[#].*)?)|(?:[#].*)/),I;if(l===null)return{};I=l[0].substr(1).split(/[&#=]/);for(var V=0;V<I.length;V+=2)i[decodeURIComponent(I[V])]=decodeURIComponent(I[V+1]||"");return i},u=function(t,i){if(a(t)!=="object")return"";var l="",I=0,V=Object.keys(t);if(V.length===0)return"";for(V.sort(),i||(l+="?"+V[0]+"="+t[V[0]],I+=1);I<V.length;I+=1)l+="&"+V[I]+"="+t[V[I]];return l};function c(e){var t=0,i={s:1,m:60,h:3600,d:3600*24,w:3600*24*7},l;e=e.replace(/([smhdw])/g," $1 ").trim(),l=e.split(" ");for(var I=0;I<l.length;I+=2)t+=parseInt(l[I],10)*i[l[I+1]||"s"];return t}function f(e){for(var t=0,i=[1,60,3600,3600*24,3600*24*7],l=e.split(":"),I=0;I<l.length;
285I++)t+=parseInt(l[I],10)*i[l.length-I-1];return t}var h=function(t){return typeof t>"u"?0:t.match(/^(\d+[smhdw]?)+$/)?c(t):t.match(/^(\d+:?)+$/)?f(t):0},d={getQueryParams:o,combineParams:u,getTime:h},m=d.getQueryParams;function b(){for(var e=0,t=["parseProvider","parse","bind","create"];e<t.length;e++){var i=t[e];this[i]=this[i].bind(this)}this.plugins={}}var y=b;b.prototype.parseProvider=function(e){var t=e.match(/(?:(?:https?:)?\/\/)?(?:[^.]+\.)?(\w+)\./i);return t?t[1]:void 0},b.prototype.parse=function(e){if(!(typeof e>"u")){var t=this.parseProvider(e),i,l=this.plugins[t];if(!(!t||!l||!l.parse))return i=l.parse.call(l,e,m(e)),i&&(i=k(i),i.provider=l.provider),i}},b.prototype.bind=function(e){if(this.plugins[e.provider]=e,e.alternatives)for(var t=0;t<e.alternatives.length;t+=1)this.plugins[e.alternatives[t]]=e},b.prototype.create=function(e){if(!(a(e)!=="object"||a(e.videoInfo)!=="object")){var t=e.videoInfo,i=e.params,l=this.plugins[t.provider];if(i=i==="internal"?t.params:i||{},l&&(e.format=e.format||l.defaultFormat,l.formats.hasOwnProperty(e.format)))return l.formats[e.format].apply(l,[t,Object.assign({},i)])}};function k(e){return e.params&&Object.keys(e.params).length===0&&delete e.params,e}var C=new y,g=C;function w(){this.provider="allocine",this.alternatives=[],this.defaultFormat="embed",this.formats={embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video"}}w.prototype.parseUrl=function(e){var t=e.match(/(?:\/video\/player_gen_cmedia=)([A-Za-z0-9]+)/i);return t?t[1]:void 0},w.prototype.parse=function(e){var t={mediaType:this.mediaTypes.VIDEO,id:this.parseUrl(e)};return t.id?t:void 0},w.prototype.createEmbedUrl=function(e){if(!(!e.id||e.mediaType!==this.mediaTypes.VIDEO))return"https://player.allocine.fr/"+e.id+".html"},g.bind(new w);var N=d.combineParams;function P(){this.provider="canalplus",this.defaultFormat="embed",this.formats={embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video"}}P.prototype.parseParameters=function(e){return delete e.vid,e},P.prototype.parse=function(e,t){var i=this,l={mediaType:this.mediaTypes.VIDEO,id:t.vid};if(l.params=i.parseParameters(t),!!l.id)return l},P.prototype.createEmbedUrl=function(e,t){if(!(!e.id||e.mediaType!==this.mediaTypes.VIDEO)){var i="http://player.canalplus.fr/embed/";return t.vid=e.id,i+=N(t),i}},g.bind(new P);var O=d.combineParams;function x(){this.provider="coub",this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video"}}x.prototype.parseUrl=function(e){var t=e.match(/(?:embed|view)\/([a-zA-Z\d]+)/i);return t?t[1]:void 0},x.prototype.parse=function(e,t){var i={mediaType:this.mediaTypes.VIDEO,params:t,id:this.parseUrl(e)};if(i.id)return i},x.prototype.createUrl=function(e,t,i){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO)){var l=e+t.id;return l+=O(i),l}},x.prototype.createLongUrl=function(e,t){return this.createUrl("https://coub.com/view/",e,t)},x.prototype.createEmbedUrl=function(e,t){return this.createUrl("//coub.com/embed/",e,t)},g.bind(new x);var S=d.combineParams,_=d.getTime;function D(){this.provider="dailymotion",this.alternatives=["dai"],this.defaultFormat="long",this.formats={short:this.createShortUrl,long:this.createLongUrl,embed:this.createEmbedUrl,image:this.createImageUrl},this.mediaTypes={VIDEO:"video"}}D.prototype.parseParameters=function(e){return this.parseTime(e)},D.prototype.parseTime=function(e){return e.start&&(e.start=_(e.start)),e},D.prototype.parseUrl=function(e){var t=e.match(/(?:\/video|ly)\/([A-Za-z0-9]+)/i);return t?t[1]:void 0},D.prototype.parse=function(e,t){var i=this,l={mediaType:this.mediaTypes.VIDEO,params:i.parseParameters(t),id:i.parseUrl(e)};return l.id?l:void 0},D.prototype.createUrl=function(e,t,i){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO))return e+t.id+S(i)},D.prototype.createShortUrl=function(e,t){return this.createUrl("https://dai.ly/",e,t)},D.prototype.createLongUrl=function(e,t){return this.createUrl("https://dailymotion.com/video/",e,t)},D.prototype.createEmbedUrl=function(e,t){return this.createUrl("https://www.dailymotion.com/embed/video/",e,t)},D.prototype.createImageUrl=function(e,t){return delete t.start,this.createUrl("https://www.dailymotion.com/thumbnail/video/",e,t)},g.bind(new D);
285var E=d.combineParams;function F(){this.provider="loom",this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video"}}F.prototype.parseUrl=function(e){var t=e.match(/(?:share|embed)\/([a-zA-Z\d]+)/i);return t?t[1]:void 0},F.prototype.parse=function(e,t){var i={mediaType:this.mediaTypes.VIDEO,params:t,id:this.parseUrl(e)};return i.id?i:void 0},F.prototype.createUrl=function(e,t,i){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO)){var l=e+t.id;return l+=E(i),l}},F.prototype.createLongUrl=function(e,t){return this.createUrl("https://loom.com/share/",e,t)},F.prototype.createEmbedUrl=function(e,t){return this.createUrl("//loom.com/embed/",e,t)},g.bind(new F);var q=d.combineParams,te=d.getTime;function H(){this.provider="twitch",this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video",STREAM:"stream",CLIP:"clip"}}H.prototype.seperateId=function(e){return{pre:e[0],id:e.substr(1)}},H.prototype.parseChannel=function(e,t){var i=t.channel||t.utm_content||e.channel;return delete t.utm_content,delete t.channel,i},H.prototype.parseUrl=function(e,t,i){var l;return l=e.match(/(clips\.)?twitch\.tv\/(?:(?:videos\/(\d+))|(\w+(?:-[\w\d-]+)?)(?:\/clip\/(\w+))?)/i),l&&l[2]?t.id="v"+l[2]:i.video?(t.i
285d=i.video,delete i.video):i.clip?(t.id=i.clip,t.isClip=!0,delete i.clip):l&&l[1]&&l[3]?(t.id=l[3],t.isClip=!0):l&&l[3]&&l[4]?(t.channel=l[3],t.id=l[4],t.isClip=!0):l&&l[3]&&(t.channel=l[3]),t},H.prototype.parseMediaType=function(e){var t;return e.id?e.isClip?(t=this.mediaTypes.CLIP,delete e.isClip):t=this.mediaTypes.VIDEO:e.channel&&(t=this.mediaTypes.STREAM),t},H.prototype.parseParameters=function(e){return e.t&&(e.start=te(e.t),delete e.t),e},H.prototype.parse=function(e,t){var i=this,l={};return l=i.parseUrl(e,l,t),l.channel=i.parseChannel(l,t),l.mediaType=i.parseMediaType(l),l.params=i.parseParameters(t),l.channel||l.id?l:void 0},H.prototype.createLongUrl=function(e,t){var i="";if(e.mediaType===this.mediaTypes.STREAM&&e.channel)i="https://twitch.tv/"+e.channel;else if(e.mediaType===this.mediaTypes.VIDEO&&e.id){var l=this.seperateId(e.id);i="https://twitch.tv/videos/"+l.id,t.start&&(t.t=t.start+"s",delete t.start)}else if(e.mediaType===this.mediaTypes.CLIP&&e.id)e.channel?i="https://www.twitch.tv/"+e.channel+"/clip/"+e.id:i="https://clips.twitch.tv/"+e.id;else return;return i+=q(t),i},H.prototype.createEmbedUrl=function(e,t){var i="https://player.twitch.tv/";if(e.mediaType===this.mediaTypes.STREAM&&e.channel)t.channel=e.channel;else if(e.mediaType===this.mediaTypes.VIDEO&&e.id)t.video=e.id,t.start&&(t.t=t.start+"s",delete t.start);else if(e.mediaType===this.mediaTypes.CLIP&&e.id)i="https://clips.twitch.tv/embed",t.clip=e.id;else return;return i+=q(t),i},g.bind(new H);var Q=d.combineParams,re=d.getTime;function j(){this.provider="vimeo",this.alternatives=["vimeopro"],this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video"}}j.prototype.parseUrl=function(e){var t=e.match(/(?:\/showcase\/\d+)?(?:\/(?:channels\/[\w]+|(?:(?:album\/\d+|groups\/[\w]+)\/)?videos?))?\/(\d+)/i);return t?t[1]:void 0},j.prototype.parseHash=function(e){var t=e.match(/\/\d+\/(\w+)$/i);return t?t[1]:void 0},j.prototype.parseParameters=function(e){return e.t&&(e.start=re(e.t),delete e.t),e.h&&(e.hash=e.h,delete e.h),e},j.prototype.parse=function(e,t){var i={mediaType:this.mediaTypes.VIDEO,params:this.parseParameters(t),id:this.parseUrl(e)},l=this.parseHash(e,t);return l&&(i.params.hash=l),i.id?i:void 0},j.prototype.createUrl=function(e,t,i,l){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO)){var I=e+t.id,V=i.start;return delete i.start,i.hash&&(l==="embed"?i.h=i.hash:l==="long"&&(I+="/"+i.hash),delete i.hash),I+=Q(i),V&&(I+="#t="+V),I}},j.prototype.createLongUrl=function(e,t){return this.createUrl("https://vimeo.com/",e,t,"long")},j.prototype.createEmbedUrl=function(e,t){return this.createUrl("//player.vimeo.com/video/",e,t,"embed")},g.bind(new j);var z=d.combineParams,K=d.getTime;function B(){this.provider="wistia",this.alternatives=[],this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl,embedjsonp:this.createEmbedJsonpUrl},this.mediaTypes={VIDEO:"video",EMBEDVIDEO:"embedvideo"}}B.prototype.parseUrl=function(e){var t=e.match(/(?:(?:medias|iframe)\/|wvideo=)([\w-]+)/);return t?t[1]:void 0},B.prototype.parseChannel=function(e){var t=e.match(/(?:(?:https?:)?\/\/)?([^.]*)\.wistia\./),i=t?t[1]:void 0;if(!(i==="fast"||i==="content"))return i},B.prototype.parseParameters=function(e,t){return e.wtime&&(e.start=K(e.wtime),delete e.wtime),e.wvideo===t.id&&delete e.wvideo,e},B.prototype.parseMediaType=function(e){return e.id&&e.channel?this.mediaTypes.VIDEO:e.id?(delete e.channel,this.mediaTypes.EMBEDVIDEO):void 0},B.prototype.parse=function(e,t){var i={id:this.parseUrl(e),channel:this.parseChannel(e)};if(i.params=this.parseParameters(t,i),i.mediaType=this.parseMediaType(i),!!i.id)return i},B.prototype.createUrl=function(e,t,i){return t.start&&(t.wtime=t.start,delete t.start),i+=z(t),i},B.prototype.createLongUrl=function(e,t){if(!(!e.id||e.mediaType!==this.mediaTypes.VIDEO)){var i="https://"+e.channel+".wistia.com/medias/"+e.id;return this.createUrl(e,t,i)}},B.prototype.createEmbedUrl=function(e,t){if(!(!e.id||!(e.mediaType===this.mediaTypes.VIDEO||e.mediaType===this.mediaTypes.EMBEDVIDEO))){var i="https://fast.wistia.com/embed/iframe/"+e.id;return this.createUrl(e,t,i)}},B.prototype.createEmbedJsonpUrl=function(e){if(!(!e.id||!(e.mediaType===this.mediaTypes.VIDEO||e.mediaType===this.mediaTypes.EMBEDVIDEO)))return"https://fast.wistia.com/embed/medias/"+e.id+".jsonp"},g.bind(new B);var X=d.combineParams;function T(){this.provider="youku",this.defaultFormat="long",this.formats={embed:this.createEmbedUrl,long:this.createLongUrl,flash:this.createFlashUrl,static:this.createStaticUrl},this.mediaTypes={VIDEO:"video"}}T.prototype.parseUrl=function(e){var t=e.match(/(?:(?:embed|sid)\/|v_show\/id_|VideoIDS=)([a-zA-Z0-9]+)/);return t?t[1]:void 0},T.prototype.parseParameters=function(e){return e.VideoIDS&&delete e.VideoIDS,e},T.prototype.parse=function(e,t){var i=this,l={mediaType:this.mediaTypes.VIDEO,id:i.parseUrl(e),params:i.parseParameters(t)};if(l.id)return l},T.prototype.createUrl=function(e,t,i){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO)){var l=e+t.id;return l+=X(i),l}},T.prototype.createEmbedUrl=function(e,t){return this.createUrl("http://player.youku.com/embed/",e,t)},T.prototype.createLongUrl=function(e,t){return this.createUrl("http://v.youku.com/v_show/id_",e,t)},T.prototype.createStaticUrl=function(e,t){return this.createUrl("http://static.youku.com/v1.0.0638/v/swf/loader.swf?VideoIDS=",e,t)},T.prototype.createFlashUrl=function(e,t){if(!(!e.id||e.mediaType!==this.mediaTypes.VIDEO)){var i="http://player.youku.com/player.php/sid/"+e.id+"/v.swf";return i+=X(t),i}},g.bind(new T);var A=d.combineParams,U=d.getTime;function L(){this.provider="youtube",this.alternatives=["youtu","ytimg"],this.defaultFormat="long",this.formats={short:this.createShortUrl,long:this.createLongUrl,embed:this.createEmbedUrl,shortImage:this.createShortImageUrl,longImage:this.createLongImageUrl},this.imageQualities={0:"0",1:"1",2:"2",3:"3",DEFAULT:"default",HQDEFAULT:"hqdefault",SDDEFAULT:"sddefault",MQDEFAULT:"mqdefault",MAXRESDEFAULT:"maxresdefault"},this.defaultImageQuality=this.imageQualities.HQDEFAULT,this.mediaTypes={VIDEO:"video",PLAYLIST:"playlist",SHARE:"share",CHANNEL:"channel"}}L.prototype.parseVideoUrl=function(e){var t=e.match(/(?:(?:v|vi|be|videos|embed)\/(?!videoseries
285)|(?:v|ci)=)([\w-]{11})/i);return t?t[1]:void 0},L.prototype.parseChannelUrl=function(e){var t=e.match(/\/channel\/([\w-]+)/);if(t)return{id:t[1],mediaType:this.mediaTypes.CHANNEL};if(t=e.match(/\/(?:c|user)\/([\w-]+)/),t)return{name:t[1],mediaType:this.mediaTypes.CHANNEL}},L.prototype.parseParameters=function(e,t){return(e.start||e.t)&&(e.start=U(e.start||e.t),delete e.t),e.v===t.id&&delete e.v,e.list===t.id&&delete e.list,e},L.prototype.parseMediaType=function(e){if(e.params.list&&(e.list=e.params.list,delete e.params.list),e.id&&!e.params.ci)e.mediaType=this.mediaTypes.VIDEO;else if(e.list)delete e.id,e.mediaType=this.mediaTypes.PLAYLIST;else if(e.params.ci)delete e.params.ci,e.mediaType=this.mediaTypes.SHARE;else return;return e},L.prototype.parse=function(e,t){var i=this.parseChannelUrl(e);if(i)return i;var l={params:t,id:this.parseVideoUrl(e)};return l.params=this.parseParameters(t,l),l=this.parseMediaType(l),l},L.prototype.createShortUrl=function(e,t){if(!(!e.id||e.mediaType!==this.mediaTypes.VIDEO)){var i="https://youtu.be/"+e.id;return t.start&&(i+="#t="+t.start),i}},L.prototype.createLongUrl=function(e,t){var i="",l=t.start;if(delete t.start,e.mediaType===this.mediaTypes.CHANNEL)if(e.id)i+="https://www.youtube.com/channel/"+e.id;else if(e.name)i+="https://www.youtube.com/c/"+e.name;else return;else if(e.mediaType===this.mediaTypes.PLAYLIST&&e.list)t.feature="share",i+="https://www.youtube.com/playlist";else if(e.mediaType===this.mediaTypes.VIDEO&&e.id)t.v=e.id,i+="https://www.youtube.com/watch";else if(e.mediaType===this.mediaTypes.SHARE&&e.id)t.ci=e.id,i+="https://www.youtube.com/shared";else return;return e.list&&(t.list=e.list),i+=A(t),e.mediaType!==this.mediaTypes.PLAYLIST&&l&&(i+="#t="+l),i},L.prototype.createEmbedUrl=function(e,t){var i="https://www.youtube.com/embed";if(e.mediaType===this.mediaTypes.PLAYLIST&&e.list)t.listType="playlist";else if(e.mediaType===this.mediaTypes.VIDEO&&e.id)i+="/"+e.id,t.loop==="1"&&(t.playlist=e.id);else return;return e.list&&(t.list=e.list),i+=A(t),i},L.prototype.createImageUrl=function(e,t,i){if(!(!t.id||t.mediaType!==this.mediaTypes.VIDEO)){var l=e+t.id+"/",I=i.imageQuality||this.defaultImageQuality;return l+I+".jpg"}},L.prototype.createShortImageUrl=function(e,t){return this.createImageUrl("https://i.ytimg.com/vi/",e,t)},L.prototype.createLongImageUrl=function(e,t){return this.createImageUrl("https://img.youtube.com/vi/",e,t)},g.bind(new L);var ie=d.combineParams,oe=d.getTime;function Y(){this.provider="soundcloud",this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={TRACK:"track",PLAYLIST:"playlist",APITRACK:"apitrack",APIPLAYLIST:"apiplaylist"}}Y.prototype.parseUrl=function(e,t){var i=e.match(/(?:m\.)?soundcloud\.com\/(?:([\w-]+)\/(sets\/)?)([\w-]+)/i);return i&&(t.channel=i[1],i[1]==="playlists"||i[2]?t.list=i[3]:t.id=i[3]),t},Y.prototype.parseParameters=function(e){return e.t&&(e.start=oe(e.t),delete e.t),e},Y.prototype.parseMediaType=function(e){return e.id&&(e.channel==="tracks"?(delete e.channel,delete e.params.url,e.mediaType=this.mediaTypes.APITRACK):e.mediaType=this.mediaTypes.TRACK),e.list&&(e.channel==="playlists"?(delete e.channel,delete e.params.url,e.mediaType=this.mediaTypes.APIPLAYLIST):e.mediaType=this.mediaTypes.PLAYLIST),e},Y.prototype.parse=function(e,t){var i={};if(i=this.parseUrl(e,i),i.params=this.parseParameters(t),i=this.parseMediaType(i),!(!i.id&&!i.list))return i},Y.prototype.createLongUrl=function(e,t){var i="",l=t.start;if(delete t.start,e.mediaType===this.mediaTypes.TRACK&&e.id&&e.channel)i="https://soundcloud.com/"+e.channel+"/"+e.id;else if(e.mediaType===this.mediaTypes.PLAYLIST&&e.list&&e.channel)i="https://soundcloud.com/"+e.channel+"/sets/"+e.list;else if(e.mediaType===this.mediaTypes.APITRACK&&e.id)i="https://api.soundcloud.com/tracks/"+e.id;else if(e.mediaType===this.mediaTypes.APIPLAYLIST&&e.list)i="https://api.soundcloud.com/playlists/"+e.list;else return;return i+=ie(t),l&&(i+="#t="+l),i},Y.prototype.createEmbedUrl=function(e,t){var i="https://w.soundcloud.com/player/";if(delete t.start,e.mediaType===this.mediaTypes.APITRACK&&e.id)t.url="https%3A//api.soundcloud.com/tracks/"+e.id;else if(e.mediaType===this.mediaTypes.APIPLAYLIST&&e.list)t.url="https%3A//api.soundcloud.com/playlists/"+e.list;else return;return i+=ie(t),i},g.bind(new Y);var ne=d.combineParams;function G(){this.provider="teachertube",this.alternatives=[],this.defaultFormat="long",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video",AUDIO:"audio",DOCUMENT:"document",CHANNEL:"channel",COLLECTION:"collection",GROUP:"group"}}G.prototype.parse=function(e,t){var i={};i.list=this.parsePlaylist(t),i.params=t;var l=e.match(/\/(audio|video|document|user\/channel|collection|group)\/(?:[\w-]+-)?(\w+)/);if(l)return i.mediaType=this.parseMediaType(l[1]),i.id=l[2],i},G.prototype.parsePlaylist=function(e){if(e["playlist-id"]){var t=e["playlist-id"];return delete e["playlist-id"],t}},G.prototype.parseMediaType=function(e){switch(e){case"audio":return this.mediaTypes.AUDIO;case"video":return this.mediaTypes.VIDEO;case"document":return this.mediaTypes.DOCUMENT;case"user/channel":return this.mediaTypes.CHANNEL;case"collection":return this.mediaTypes.COLLECTION;case"group":return this.mediaTypes.GROUP}},G.prototype.createLongUrl=function(e,t){if(e.id){var i="https://www.teachertube.com/";return e.list&&(t["playlist-id"]=e.list),e.mediaType===this.mediaTypes.CHANNEL?i+="user/channel/":i+=e.mediaType+"/",i+=e.id,i+=ne(t),i}},G.prototype.createEmbedUrl=function(e,t){if(e.id){var i="https://www.teachertube.com/embed/";if(e.mediaType===this.mediaTypes.VIDEO||e.mediaType===this.mediaTypes.AUDIO)i+=e.mediaType+"/"+e.id;else return;return i+=ne(t),i}},g.bind(new G);var ae=d.combineParams;function Z(){this.provider="tiktok",this.defaultFormat="long",this.formats={long:this.createLongUrl},this.mediaTypes={VIDEO:"video"}}Z.prototype.parse=function(e,t){var i={params:t,mediaType:this.mediaTypes.VIDEO},l=e.match(/@([^/]+)\/video\/(\d{19})/);if(l)return i.channel=l[1],i.id=l[2],i},Z.prototype.createLongUrl=function(e,t){var i="";if(e.mediaType===this.mediaTypes.VIDEO&&e.id&&e.channel)i+="https://www.tiktok.com/@".concat(e.channel,"/video/").concat(e.id);else return;return i+=ae(t),i},g.bind(new Z);var se=d.combineParams;function W(){this.provider="ted",this.formats={long:this.createLongUrl,embed:this.createEmbedUrl},this.mediaTypes={VIDEO:"video",PLAYLIST:"playlist"}}W.prototype.parseUrl=function(e,t){var i=e.match(/\/(talks|playlists\/(\d+))\/([\w-]+)/i),l=i?i[1]:void 0;return l&&(t.channel=l.split("/")[0],t.id=i[3],t.channel==="playlists"&&(t.list=i[2])),t},W.prototype.parseMediaType=function(e){return e.id&&e.channel==="playlists"&&(delete e.channel,e.mediaType=this.mediaTypes.PLAYLIST),e.id&&e.channel==="talks"&&(delete e.channel,e.mediaType=this.mediaTypes.VIDEO),e},W.prototype.parse=function(e,t){var i={params:t};if(i=this.parseUrl(e,i),i=this.parseMediaType(i),!!i.id)return i},W.prototype.createLongUrl=function(e,t){var i="";if(e.mediaType===this.mediaTypes.VIDEO&&e.id)i+="https://ted.com/talks/"+e.id;else if(e.mediaType===this.mediaTypes.PLAYLIST&&e.id)i+="https://ted.com/playlists/"+e.list+"/"+e.id;else return;return i+=se(t),i},W.prototype.createEmbedUrl=function(e,t){var i="https://embed.ted.com/";if(e.mediaType===this.mediaTypes.PLAYLIST&&e.id)i+="playlists/"+e.list+"/"+e.id;else if(e.mediaType===this.mediaTypes.VIDEO&&e.id)i+="talks/"+e.id;else return;return i+=se(t),i},g.bind(new W);var le=d.combineParams;function J(){this.provider="facebook",this.alternatives=[],this.defaultFormat="long",this.formats={long:this.createLongUrl,watch:this.createWatchUrl},this.mediaTypes={VIDEO:"video"}}J.prototype.parse=function(e,t){var i={params:t,mediaType:this.mediaTypes.VIDEO},l=e.match(/(?:\/(\d+))?\/videos(?:\/.*?)?\/(\d+)/i);if(l&&(l[1]&&(i.pageId=l[1]),i.id=l[2]),t.v&&!i.id&&(i.id=t.v,delete t.v,i.params=t),!!i.id)return i},J.prototype.createWatchUrl=function(e,t){var i="https://facebook.com/watch/";if(!(e.mediaType!==this.mediaTypes.VIDEO||!e.id))return t={v:e.id}
285,i+=le(t),i},J.prototype.createLongUrl=function(e,t){var i="https://facebook.com/";if(e.pageId)i+=e.pageId;else return;if(e.mediaType===this.mediaTypes.VIDEO&&e.id)i+="/videos/"+e.id;else return;return i+=le(t),i},g.bind(new J);var Ye=g;return Ye}))})(de)),de.exports}var nr=ir();const sr=Ze(nr);function Be(n){if(!n)return{platform:null,videoId:null,embedUrl:null};try{const s=sr.parse(n);return s?s.provider==="youtube"&&s.id?{platform:"youtube",videoId:s.id,embedUrl:`https://www.youtube.com/embed/${s.id}?autoplay=1&loop=1&mute=1&playlist=${s.id}&controls=1&modestbranding=1&rel=0&enablejsapi=1`}:s.provider==="vimeo"&&s.id?{platform:"vimeo",videoId:s.id,embedUrl:`https://player.vimeo.com/video/${s.id}?autoplay=1&loop=1&muted=1&background=1`}:{platform:null,videoId:null,embedUrl:null}:{platform:null,videoId:null,embedUrl:null}}catch(s){return console.error("Error parsing video URL:",s),{platform:null,videoId:null,embedUrl:null}}}const or=[{fraction:.25,label:"25"},{fraction:.5,label:"50"},{fraction:.75,label:"75"}],Se=()=>{if(typeof window>"u")return[];const n=window;return n.__youtubeReadyQueue??=[],n.__youtubeReadyQueue},ar=1e4;function lr(){return typeof window>"u"?Promise.resolve(!1):window.Vimeo?.Player?Promise.resolve(!0):new Promise(n=>{const s=document.querySelector('script[src*="player.vimeo.com/api/player.js"]');let a,o,u=!1;const c=()=>{u||(u=!0,a!==void 0&&clearInterval(a),o!==void 0&&clearTimeout(o),s?.removeEventListener("load",c),n(!!window.Vimeo?.Player))};s?.addEventListener("load",c,{once:!0}),a=setInterval(()=>{window.Vimeo?.Player&&c()},50),o=setTimeout(c,ar)})}const cr=({videoUrl:n,className:s="",muted:a=!0,showPlayPauseButton:o=!0,showVolumeButton:u=!1,autoplay:c=!1,gtmVideoTitle:f,posterUrl:h=null})=>{const d=p.useRef(null),m=p.useRef(null),b=p.useRef(null),y=p.useRef(null),k=p.useRef(null),C=p.useRef(null),g=p.useRef(null),[w,N]=p.useState(!1),[P,O]=p.useState(a),[x,S]=p.useState(!1),[_,D]=p.useState(!1),E=n?Be(n):null,F=E?.platform==="vimeo";p.useEffect(()=>{O(a)},[a]),p.useEffect(()=>{(w||F&&c&&x)&&D(!0)},[w,F,c,x]),p.useEffect(()=>{if(!E||!E.videoId||!d.current)return;const j=d.current,z=E.platform==="youtube",K=E.platform==="vimeo";let B=!1;if(S(!1),D(!1),z){const X=()=>{if(!j||!window.YT)return;const T=`youtube-player-${Date.now()}-${Math.random().toString(36).substr(2,9)}`;j.id=T;const A=U=>{U.data===1||U.data===3?N(!0):(U.data===2||U.data===0)&&N(!1)};try{const U=new window.YT.Player(T,{videoId:E.videoId,playerVars:{autoplay:c?1:0,loop:1,mute:a?1:0,playlist:E.videoId,controls:0,modestbranding:1,rel:0,iv_load_policy:3,fs:0,cc_load_policy:0,enablejsapi:1},events:{onReady:()=>{S(!0),b.current&&clearTimeout(b.current),b.current=setTimeout(()=>{const L=j.querySelector("iframe");L&&(L.style.width="100%",L.style.height="100%",L.style.pointerEvents="none")},100);try{a?U.mute():U.unMute?.()}catch{}if(c)try{U.playVideo()}catch{}},onStateChange:A}});m.current=U}catch(U){console.error("Failed to initialize YouTube player:",U)}};window.YT&&window.YT.Player?X():(Se().push(X),window.onYouTubeIframeAPIReady||(window.onYouTubeIframeAPIReady=()=>{window.onYouTubeIframeAPIReady=void 0,Se().splice(0).forEach(L=>L())}))}return K&&(async()=>{if(!j)return;const T=document.createElement("iframe");if(T.src=`https://player.vimeo.com/video/${E.videoId}?autoplay=${c?1:0}&loop=1&muted=${a?1:0}&background=${o?0:1}&controls=0`,T.style.width="100%",T.style.aspectRatio="16 / 9",T.style.position="absolute",T.style.top="50%",T.style.left="0",T.style.transform="translateY(-50%)",T.style.minWidth="100%",T.style.height="auto",T.style.pointerEvents="none",T.allow="autoplay; encrypted-media; fullscreen",T.title="Video player",T.addEventListener("load",()=>S(!0)),j.appendChild(T),await lr(),!B&&window.Vimeo?.Player)try{const A=new window.Vimeo.Player(T);m.current=A;try{A.setVolume(a?0:1)}catch{}const U=!!f?.trim(),L=f?.trim()??"";let ie=!1,oe=!1;const Y=new Set,ne=()=>{!U||oe||(oe=!0,Je(L))},G=()=>{N(!0),U&&!ie&&(ie=!0,Qe(L))},ae=()=>N(!1),Z=W=>{if(U){for(const{fraction:le,label:J}of or)W.percent>=le&&!Y.has(J)&&(Y.add(J),Ke(L,J));W.percent>=.99&&ne()}},se=()=>{N(!1),ne()};y.current=G,k.current=ae,C.current=Z,g.current=se;try{A.on("play",G),A.on("pause",ae),U&&(A.on("timeupdate",Z),A.on("ended",se))}catch{}c&&A.play().catch(()=>{})}catch(A){console.error("Failed to initialize Vimeo player:",A)}})(),()=>{if(B=!0,b.current&&(clearTimeout(b.current),b.current=null),K&&m.current){try{y.current&&m.current.off("play",y.current),k.current&&m.current.off("pause",k.current),C.current&&m.current.off("timeupdate",C.current),g.current&&m.current.off("ended",g.current)}catch{}y.current=null,k.current=null,C.current=null,g.current=null}if(m.current){try{(z&&m.current.destroy||K&&m.current.destroy)&&m.current.destroy()}catch(X){console.error("Error destroying player:",X)}m.current=null}j&&K&&(j.innerHTML="")}},[E?.platform,E?.videoId,a,c,o,f]);const q=async()=>
285{if(m.current){w||D(!0);try{const j=E?.platform==="youtube",z=E?.platform==="vimeo";j?w?m.current.pauseVideo():m.current.playVideo():z&&(w?await m.current.pause():await m.current.play())}catch(j){console.error("Error toggling play/pause:",j)}}},te=async()=>{if(m.current)try{const j=E?.platform==="youtube",z=E?.platform==="vimeo";j?P?m.current.unMute?.():m.current.mute():z&&(P?await m.current.setVolume(1):await m.current.setVolume(0)),O(!P)}catch(j){console.error("Error toggling volume:",j)}};if(!n||!E||!E.videoId)return null;const H=E.platform==="youtube"?`https://i.ytimg.com/vi/${E.videoId}/maxresdefault.jpg`:null,Q=h??H,re=j=>{const z=j.currentTarget;E.platform==="youtube"&&z.src.includes("maxresdefault")&&(z.src=`https://i.ytimg.com/vi/${E.videoId}/hqdefault.jpg`)};return r.jsxs("div",{className:`relative w-full overflow-hidden ${s}`.trim(),style:{maxHeight:s?void 0:"100vh",aspectRatio:"16 / 9"},children:[r.jsx("div",{className:"absolute",style:{width:"100%",aspectRatio:"16 / 9",top:"50%",left:"0",transform:"translateY(-50%)"},children:r.jsxs("div",{className:"relative h-full w-full",children:[r.jsx("div",{ref:d,className:"relative h-full w-full",style:{width:"100%",height:"100%"}}),r.jsx("div",{className:"pointer-events-auto absolute inset-0 z-2","aria-hidden":!0})]})}),!_&&(Q?r.jsx("img",{src:Q,alt:"","aria-hidden":!0,onError:re,className:` 286 absolute inset-0 z-3 h-full w-full object-cover object-center 287 `}):x?null:r.jsx(tr,{className:"absolute inset-0 z-3"})),x&&(o||u)&&r.jsxs("div",{className:` 288 absolute bottom-0 z-10 flex w-full items-center justify-between gap-2 289 p-2 290 desktop:justify-end 291 `,children:[o&&r.jsx("button",{type:"button",onClick:q,className:` 292 flex h-10 w-10 items-center justify-center 293 bg-primary-soft-black/80 text-white transition-colors 294 duration-200 295 hover:bg-primary-red 296 `,"aria-label":w?"Pause video":"Play video",children:w?r.jsx(it,{}):r.jsx(nt,{})}),u&&r.jsx("button",{type:"button",onClick:te,className:` 297 flex h-10 w-10 items-center justify-center 298 bg-primary-soft-black/80 text-white transition-colors 299 duration-200 300 hover:bg-primary-red 301 `,"aria-label":P?"Unmute":"Mute",children:P?r.jsx(ot,{}):r.jsx(at,{})})]})]})},Ir=({data:n})=>{const{title:s,video_url:a,credit:o,button_text:u,button_url:c}=n,f=a?Be(a):null,h=!!u;return!a||!f?.videoId||!f.embedUrl?null:r.jsxs("section",{className:` 302 max-width-container content-padding-x pt-8 pb-10 303 desktop:pt-6 desktop:pb-18 304 `,children:[r.jsxs("div",{className:` 305 mb-6 flex flex-col items-start justify-between 306 desktop:mb-8 desktop:flex-row 307 `,children:[r.jsxs("div",{className:` 308 w-full 309 desktop:w-1/2 310 `,children:[s&&r.jsx("h5",{className:` 311 h5-medium 312 desktop:mb-2 313 `,children:s}),o&&r.jsx("p",{className:"body-small mb-0",children:o})]}),h&&r.jsx(R,{className:` 314 hidden 315 desktop:flex 316 `,as:"a",href:c??"#",size:"sm",variant:"clear",icon:r.jsx($,{}),hoverEffect:"right",children:u})]}),r.jsx(cr,{videoUrl:a,showPlayPauseButton:!0,showVolumeButton:!0,gtmVideoTitle:f.platform==="vimeo"?s?.trim()||"video content block":void 0}),h&&r.jsx(R,{className:` 317 mt-10 318 desktop:hidden 319 `,as:"a",href:c??"#",size:"sm",variant:"clear",icon:r.jsx($,{}),hoverEffect:"right",children:u})]})};export{yr as A,gr as C,wr as D,vr as E,kr as F,Gt as I,Tr as J,Er as L,he as P,jr as Q,cr as V,Ir as a,xr as b,br as c,Kt as d,er as h};
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.