1!function(){try{var e="u">typeof window?window:"u">typeof global?global:"u">typeof globalThis?globalThis:"u">typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="477e8c2a-c087-4692-b75b-d0529dc0d12c",e._sentryDebugIdIdentifier="sentry-dbid-477e8c2a-c087-4692-b75b-d0529dc0d12c")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7177],{1961:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/favicon-16x16.e9179fb1.png",height:16,width:16,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAM1BMVEXZGyLmaG3dMTjsio3lX2TbIyrfP0b//f3YERj1w8Xulpnxp6r53N3pe3/40NLiUVb87u9/05QoAAAACXBIWXMAAAJ1AAACdQF32cIiAAAAPUlEQVR4nBXKWRLAIAgFwUGBB2qW+582lf5uVjKuTsCn1XA4ks4geJ1Hu4Krenf/JSVNklXzXmWOrKKs4wM1RQGEQd/NcwAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:8}},6501:(e,t,s)=>{"use strict";s.d(t,{cn:()=>i});var a=s(63929),r=s(46657);function i(...e){return(0,r.QP)((0,a.$)(e))}},7511:(e,t,s)=>{"use strict";s.d(t,{SiteFooter:()=>h});var a=s(41657),r=s(675),i=s.n(r),n=s(51373);let l=({className:e,size:t})=>(0,a.jsx)(n._,{className:e,size:t,children:(0,a.jsx)("path",{d:"M18.2833 14.1624L27.2178 4H25.1006L17.3427 12.8238L11.1466 4H4L13.3698 17.3432L4 28H6.11732L14.3098 18.6817L20.8534 28H28L18.2827 14.1624H18.2833ZM15.3833 17.4608L14.4339 16.1321L6.88022 5.55962H10.1323L16.2282 14.0919L17.1776 15.4206L25.
11016 26.5113H21.8495L15.3833 17.4613V17.4608Z",fill:"currentColor"})});var o=s(75182);let c=[{items:[{title:"RNZ Stations",links:[{title:"National",url:"/national"},{title:"Concert",url:"/concert"},{title:"RNZ Pacific",url:"/international"},{title:"Parliament - live stream",url:"/parliament"}]},{title:"On demand",links:[{title:"Latest on demand radio",url:"/audio"},{title:"Latest podcasts",url:"/podcasts"},{title:"Latest video",url:"/video"}]}]},{items:[{title:"How to watch & listen",links:[{title:"Audio help",url:"/listen/audiohelp"},{title:"Radio",url:"/listen/amfm"},{title:"Follow our podcasts",url:"/podcasts"},{title:"Sky, Freeview & Satellite",url:"/listen/sky"},{title:"YouTube",url:"https://www.youtube.com/user/radionz"},{title:"RNZ apps for iPhone and Android",url:"/listen/app"},{title:"RNZ Flash Briefing for Amazon Alexa",url:"/listen/alexa"},{title:"RNZ News for Google Assistant",url:"/listen/google"}]}]},{items:[{title:"About RNZ",links:[{title:"About",url:"/about"},{title:"Contact",url:"/about/contact"},{title:"Audience Feedback and Complaints",url:"/complaints"},{title:"Media Releases",url:"/media"},{title:"Awards",url:"/awards"},{title:"Jobs",url:"/jobs"},{title:"Join RNZ Research Panel",url:"/haveyoursay"},{title:"Local Democracy Reporting",url:"/ldr"},{title:"RNZ Commissioning",url:"/commissioning"},{title:"RNZ Emergency",url:"/emergency"}]}]}],d=[{title:"Facebook",icon:({className:e,size:t})=>(0,a.jsx)(n._,{className:e,size:t,children:(0,a.jsx)("path",{d:"M28 16C28 9.373 22.627 4 16 4C9.373 4 4 9.373 4 16C4 21.99 8.388 26.954 14.125 27.854V19.469H11.078V15.999H14.125V13.357C14.125 10.35 15.917 8.688 18.658 8.688C19.97 8.688 21.344 8.923 21.344 8.923V11.876H19.83C18.339 11.876 17.874 12.801 17.874 13.75V16H21.202L20.67 19.47H17.874V27.855C23.612 26.954 28 21.989 28 16Z",fill:"currentColor"})}),url:"https://www.facebook.com/rnznewzealand/"},{title:"Twitter",icon:l,url:"https://twitter.com/radionz"},{title:"YouTube",icon:({className:e,size:t})=>(0,a.jsx)(n._,{className:e,size:t,children:(0,a.jsx)("path",{d:"M16 4C9.376 4 4 9.376 4 16C4 22.624 9.376 28 16 28C22.624 28 28 22.624 28 16C28 9.376 22.624 4 16 4ZM16 23.104C12.076 23.104 8.896 19.924 8.896 16C8.896 12.076 12.076 8.896 16 8.896C19.924 8.896 23.104 12.076 23.104 16C23.104 19.924 19.924 23.104 16 23.104ZM16 9.772C12.568 9.772 9.772 12.568 9.772 16C9.772 19.432 12.568 22.228 16 22.228C19.432 22.228 22.228 19.432 22.228 16C22.228 12.568 19.432 9.772 16 9.772ZM13.684 19.54V12.46L19.816 16L13.684 19.54Z",fill:"currentColor"})}),url:"https://www.youtube.com/user/radionz"},{title:"Instagram",icon:({className:e,size:t})=>(0,a.jsx)(n._,{className:e,size:t,children:(0,a.jsx)("path",{d:"M16 4C12.74 4 12.333 4.015 11.053 4.072C9.775 4.132 8.905 4.333 8.14 4.63C7.351 4.936 6.681 5.347 6.014 6.014C5.347 6.681 4.935 7.35 4.63 8.14C4.333 8.905 4.131 9.775 4.072 11.053C4.012 12.333 4 12.74 4 16C4 19.26 4.015 19.667 4.072 20.947C4.132 22.224 4.333 23.095 4.63 23.86C4.936 24.648 5.347 25.319 6.014 25.986C6.681 26.652 7.35 27.065 8.14 27.37C8.906 27.666 9.776 27.869 11.053 27.928C12.333 27.988 12.74 28 16 28C19.26 28 19.667 27.985 20.947 27.928C22.224 27.868 23.095 27.666 23.86 27.37C24.648 27.064 25.319 26.652 25.986 25.986C26.652 25.319 27.065 24.651 27.37 23.86C27.666 23.095 27.869 22.224 27.928 20.947C27.988 19.667 28 19.26 28 16C28 12.74 27.985 12.333 27.928 11.053C27.868 9.776 27.666 8.904 27.37 8.14C27.064 7.351 26.652 6.681 25.986 6.014C25.319 5.347 24.651 4.935 23.86 4.63C23.095 4.333 22.224 4.131 20.947 4.072C19.667 4.012 19.26 4 16 4ZM16 6.16C19.203 6.16 19.585 6.176 20.85 6.231C22.02 6.286 22.655 6.48 23.077 6.646C23.639 6.863 24.037 7.123 24.459 7.542C24.878 7.962 25.138 8.361 25.355 8.923C25.519 9.345 25.715 9.98 25.768 11.15C25.825 12.416 25.838 12.796 25.838 16C25.838 19.204 25.823 19.585 25.764 20.85C25.703 22.02 25.508 22.655 25.343 23.077C25.119 23.639 24.864 24.037 24.444 24.459C24.025 24.878 23.62 25.138 23.064 25.355C22.644 25.519 21.999 25.715 20.829 25.768C19.555 25.825 19.18 25.838 15.97 25.838C12.759 25.838 12.384 25.823 11.111 25.764C9.94 25.703 9.295 25.508 8.875 25.343C8.306 25.119 7.915 24.864 7.496 24.444C7.075 24.025 6.806 23.62 6.596 23.064C6.431 22.644 6.237 21.999 6.176 20.829C6.131 19.569 6.115 19.18 6.115 15.985C6.115 12.789 6.131 12.399 6.176 11.124C6.237 9.954 6.431 9.31 6.596 8.89C6.806 8.32 7.075 7.93 7.496 7.509C7.915 7.09 8.306 6.82 8.875 6.611C9.295 6.445 9.926 6.25 11.096 6.19C12.371 6.145 12.746 6.13 15.955 6.13L16 6.16ZM16 9.838C12.595 9.838 9.838 12.598 9.838 16C9.838 19.405 12.598 22.162 16 22.162C19.405 22.162 22.162 19.402 22.162 16C22.162 12.595 19.402 9.838 16 9.838ZM16 20C13.79 20 12 18.21 12 16C12 13.79 13.79 12 16 12C18.21 12 20 13.79 20 16C20 18.21 18.21 20 16 20ZM23.846 9.595C23.846 10.39 23.2 11.035 22.406 11.035C21.611 11.035 20.966 10.389 20.9
166 9.595C20.966 8.801 21.612 8.156 22.406 8.156C23.199 8.155 23.846 8.801 23.846 9.595Z",fill:"currentColor"})}),url:"https://www.instagram.com/rnznewzealand/"}],m=(e,t)=>{(0,o.BT)({event:"footer_link_click",linkUrl:e,linkText:t})},u=()=>(0,a.jsxs)("div",{className:"col-span-full row-start-1 mb-16 md:mb-4 lg:col-auto lg:row-start-auto lg:mb-0",children:[(0,a.jsx)("h3",{className:"font-sans-semibold mb-24 text-center uppercase tracking-widest sm:mb-16 sm:border-b sm:pb-16 lg:pb-8",children:"Join & Follow RNZ"}),(0,a.jsx)("ul",{className:"flex justify-center gap-8",children:d.map(e=>(0,a.jsx)("li",{children:(0,a.jsxs)("a",{href:e.url,className:i()("bg-surface-muted text-foreground-secondary inline-flex aspect-square w-48 items-center justify-center rounded-full transition-colors hover:text-white",(e=>{switch(e){case"Facebook":return"hover:bg-facebook-blue";case"Twitter":return"hover:bg-x-black";case"YouTube":return"hover:bg-youtube-red";case"Instagram":return"hover:bg-insta-magenta"}})(e.title)),onClick:()=>m(e.url,e.title),children:[(0,a.jsx)("span",{className:"sr-only",children:e.title}),(0,a.jsx)(e.icon,{size:e.icon===l?"base":"lg"})]})},e.title))}),(0,a.jsx)("div",{className:"flex justify-center",children:(0,a.jsx)("a",{className:"bg-surface-muted text-foreground-secondary font-sans-semibold mt-8 inline-block rounded p-8 text-center transition-colors hover:bg-white",href:"/about/newsletters",onClick:()=>m("/about/newsletters","Sign up to RNZ Newsletters"),children:"Sign up to RNZ Newsletters"})})]}),x=()=>(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("h2",{className:"sr-only",children:"Footer navigation"}),(0,a.jsxs)("nav",{className:"grid gap-16 sm:grid-cols-2 sm:gap-32 md:grid-cols-3 lg:grid-cols-4",children:[c.map((e,t)=>(0,a.jsx)("div",{className:i()("flex flex-col gap-16 md:gap-24",0===t&&"sm:row-span-2 md:row-span-1"),children:e.items.map(e=>(0,a.jsxs)("div",{className:"",children:[(0,a.jsx)("h3",{className:"font-sans-semibold mb-8 border-t pt-24 uppercase tracking-wider sm:border-b sm:border-t-0 sm:pb-16 sm:pt-0 md:pb-8",children:e.title}),(0,a.jsx)("ul",{children:e.links.map(e=>(0,a.jsx)("li",{children:(0,a.jsx)("a",{href:e.url,className:"block py-8 pl-16 underline-offset-4 hover:text-white hover:underline sm:pl-0","data-footer-link":"footer-link",onClick:()=>m(e.url,e.title),children:e.title})},e.title))})]},e.title))},e.items[0].title)),(0,a.jsx)(u,{})]})]}),h=()=>(0,a.jsx)("footer",{className:"text-grey-100 bg-grey-800 pb-fluid-0-32 focus-outline-alt relative z-10 mt-auto print:hidden",children:(0,a.jsxs)("div",{className:"pt-fluid-32-48 mx-auto max-w-screen-2xl px-16 md:px-32",children:[(0,a.jsx)(x,{}),(0,a.jsxs)("div",{className:"mt-24 flex flex-col border-t pt-16 md:flex-row md:items-center md:justify-between",children:[(0,a.jsx)("div",{className:"flex items-center gap-24 border-b pb-16 md:gap-16 md:border-b-0 md:pb-0",children:(0,a.jsx)("a",{href:"/about/legal",className:"hover:text-white",onClick:()=>m("/about/legal","Terms of use"),children:"Terms of use"})}),(0,a.jsx)("p",{className:"pt-24 text-center md:pt-0 md:text-right",children:"\xa9 Copyright Radio New Zealand 2026"})]})]})})},11083:(e,t,s)=>{"use strict";s.d(t,{SkipLinksWrapper:()=>u});var a=s(41657),r=s(48237),i=s(71610),n=s(96507),l=s(40610),o=s.n(l),c=s(44635);let d=({type:e,href:t,text:s})=>{let r=`#${t}`;return(0,a.jsxs)(o(),{href:r,className:"underline-brand-hover text-fluid-sm-base group/skip-link pointer-events-none flex items-center gap-4 [&>svg]:transition-all [&>svg]:hover:translate-y-2",onClick:s=>{let a=document.getElementById(t);a&&"player"===e&&(s.preventDefault(),a.focus())},children:[s,(0,a.jsx)(c.R,{align:"text"})]})},m=({links:e})=>(0,a.jsx)("div",{className:"bg-signal-warning py-fluid-8-16 z-skip-link pointer-events-none absolute flex h-full w-full items-center justify-center opacity-0 transition-opacity focus-within:pointer-events-auto focus-within:opacity-100 [&_a]:focus-within:pointer-events-auto print:hidden",children:(0,a.jsx)("ul",{className:"flex gap-16",children:e.map(e=>(0,a.jsx)("li",{children:(0,a.jsx)(d,{...e})},e.href))})}),u=({mainId:e,playerId:t})=>{let{items:s}=(0,n.M)(),{playerSize:l}=(0,i.h)(),o={type:"main",href:e,text:"Skip to main content"},c={type:"player",href:t,text:"Skip to audio player"},[d,u]=(0,r.useState)([o]);return(0,r.useEffect)(()=>{s?.length>0&&"closed"!==l?u([o,c]):u([o])},[s,l]),(0,a.jsx)(m,{links:d})}},11502:(e,t,s)=>{"use strict";s.r(t),s.d(t,{DeferredPrefetchLink:()=>l});
1var a=s(41657),r=s(48237),i=s(40610),n=s.n(i);let l=({onPointerEnter:e,onFocus:t,onTouchStart:s,children:i,ref:l,...o})=>{let[c,d]=(0,r.useState)(!1);return(0,a.jsx)(n(),{...o,ref:l,prefetch:!!c&&null,onPointerEnter:t=>{d(!0),e?.(t)},onFocus:e=>{d(!0),t?.(e)},onTouchStart:e=>{d(!0),s?.(e)},children:i})}},13701:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/favicon-32x32.bc7fe925.png",height:32,width:32,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAM1BMVEXaICflXWLdMjnsio72xMbmaG3gQEb//f3ZGB/YERjulpnxqKr98/T62tvpfID40dLiUVaXFDgIAAAACXBIWXMAAATrAAAE6wHYKlsNAAAAO0lEQVR4nAXBiQGAMAgEwSUBDvKo/VfrDCsZj2dRNqNGwJV0R8ExvrMLnvbtXmApaVayer6rw1A0Hc4POIUBkDhiO9IAAAAASUVORK5CYII=",blurWidth:8,blurHeight:8}},15686:(e,t,s)=>{"use strict";s.d(t,{L:()=>r});var a=s(41657);s(48237);let r=e=>(0,a.jsx)("div",{className:e.className,style:{...e.colors?.primary_color&&{"--theme-primary":e.colors.primary_color.color},...e.colors?.secondary_color&&{"--theme-secondary":e.colors.secondary_color.color},...e.colors?.tertiary_color&&{"--theme-tertiary":e.colors.tertiary_color.color}},children:e.children})},17980:(e,t,s)=>{"use strict";s.d(t,{_:()=>n,m:()=>l});var a=s(41657),r=s(675),i=s.n(r);let n={maxWidth:"max-w-screen-2xl",horizPadding:"px-16 md:px-32",vertPadding:"py-16 md:py-24 lg:py-32",offsetLeft:"pl-16 md:pl-32 2xl:pl-[calc(50vw-((131.2rem*var(--base-multiplier))/2)+3.2rem*var(--base-multiplier))] pr-0",offsetRight:"pr-16 md:pr-32 2xl:pr-[calc(50vw-((131.2rem*var(--base-multiplier))/2)+3.2rem*var(--base-multiplier))] pl-0"},l=({children:e,id:t,className:s,isFullWidth:r,withNoHorizPadding:l,withNoVertPadding:o,bleedsRight:c})=>(0,a.jsx)("div",{id:t,className:s,children:(0,a.jsx)("div",{className:i()("mx-auto",{[n.horizPadding]:!l&&!c,[n.vertPadding]:!o,[n.maxWidth]:!r&&!c,[n.offsetLeft]:c}),children:e})})},18011:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/favicon-16x16.db3cb623.png",height:16,width:16,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAM1BMVEUAAACGhoaampq1tbVTU1O+vr54eHj9/f0iIiJHR0fV1dXKyspkZGQ2NjZtbW0PDw/s7OyuC+dgAAAACXBIWXMAAAJ1AAACdQF32cIiAAAAOklEQVR4nBXKWxLAIAgEwUGBBfMw9z9tyt+uxop9RwGdTjUsSevA1zwawMscEaeUpKQw8jK8kQM++QExOgE5wPav4gAAAABJRU5ErkJggg==",blurWidth:8,blurHeight:8}},19125:(e,t,s)=>{"use strict";s.d(t,{L:()=>m});var a=s(41657),r=s(48237),i=s(675),n=s.n(i),l=s(69585),o=s(81685),c=s(95091);let d=(0,l.F)("whitespace-nowrap tabular-nums",{variants:{size:{xs:"text-xs",sm:"text-sm",md:"text-base"}}}),m=r.forwardRef(({className:e,indexDetails:t,hasShortDate:s,size:i,hasAccentSeparator:l=!0,...m},u)=>{let[x,h]=(0,r.useState)(void 0);return(0,r.useEffect)(()=>{if("episodic"===t.type&&t.releaseDateISO){let e=(0,o.A)((0,c.A)(t.releaseDateISO),"d MMMM yyyy");h({date:e,shortdate:(0,o.A)((0,c.A)(t.releaseDateISO),"d MMM yyy"),accessibilityFormat:(0,o.A)((0,c.A)(t.releaseDateISO),"yyyy-MM-dd")})}},[t]),(0,a.jsx)("span",{className:n()(d({size:i,className:e}),{"text-foreground-primary":!l}),ref:u,...m,children:"trailer"===t.type?(0,a.jsx)(a.Fragment,{children:"Trailer"}):"bonus"===t.type?(0,a.jsx)(a.Fragment,{children:"Bonus episode"}):"seasonal"===t.type?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("span",{"aria-hidden":"true",children:[`S${t.seasonNumber}`,(0,a.jsx)("span",{className:n()("mx-[0.275em]",{"text-stroke-accent":l,"text-foreground-primary":!l}),children:"/"}),`E${t.episodeNumber}`]}),(0,a.jsx)("span",{className:"sr-only",children:`Season ${t.seasonNumber} / Episode ${t.episodeNumber}`})]}):"miniSeries"===t.type||"oneOff"===t.type?(0,a.jsxs)(a.Fragment,{children:["Episode ",t.episodeNumber]}):"episodic"===t.type&&t.releaseDateISO?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("time",{dateTime:x?.accessibilityFormat,children:s?x?.shortdate:x?.date})}):null})});m.displayName="AudioIndex"},19155:(e,t,s)=>{"use strict";s.d(t,{D:()=>i});var a=s(41657),r=s(48237);let i=({level:e=1,id:t,tabIndex:s,children:i,className:n})=>(0,a.jsx)(({...t})=>r.createElement(`h${e}`,t,i),{className:n,id:t,tabIndex:s,children:i})},23182:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/apple-touch-icon.ce08972d.png",height:180,width:180,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAJFBMVEUAAAA7OztoaGiEhIQVFRV4eHiPj48cHBwlJSVxcXEeHh7Kysovu4GhAAAACXBIWXMAAA1JAAANSQGKhkvfAAAAMElEQVR4nGNgYGBgZGQAAy4mJhYwg5GNkx3MYGPl5gAzmFmZIYoYmZkgDHaYYoh2ABEKAG5BMXvKAAAAAElFTkSuQmCC",blurWidth:8,blurHeight:8}},24200:(e,t,s)=>{"use strict";s.d(t,{r:()=>c,y:()=>d});
1var a=s(41657),r=s(48237),i=s(15742),n=s(69585),l=s(675),o=s.n(l);let c=(0,n.F)("inline-flex items-center justify-center whitespace-nowrap rounded-full border text-sm disabled:cursor-not-allowed",{variants:{intent:{primary:"font-sans-semibold",themePrimary:"font-sans-semibold",themeTertiary:"font-sans-semibold",black:"font-sans-normal",white:"font-sans-normal",grey:"font-sans-normal"},bgContext:{light:"",dark:""},size:{default:"px-8",xs:"px-4 py-1",sm:"px-8 py-2",icon:"h-160 w-160",iconSmall:"h-24 w-24",iconBase:"h-32 w-32",iconLg:"h-48 w-48"},disabled:{true:"bg-transparent hover:cursor-not-allowed hover:bg-transparent"},icon:{null:"leading-snug",prefix:"py-1 pl-2 leading-snug",suffix:"py-1 pr-2 leading-normal",both:"py-1 pl-1 pr-1 leading-normal",only:"pl-0 pr-0 leading-none"}},compoundVariants:[{size:"default",icon:null,className:"py-[calc(0.35rem*var(--base-multiplier))]"},{intent:["primary","black","white","grey"],disabled:!1,className:"hover:text-white *:hover:text-white"},{intent:"primary",disabled:!1,className:"border-red-500 bg-red-500 text-white hover:border-red-500/80 hover:bg-red-500/90"},{intent:"themePrimary",disabled:!1,bgContext:"light",className:"text-theme-primary *:hover:text-grey-800 border-black bg-black *:text-white hover:border-white hover:bg-white hover:text-black [&>svg]:hover:text-black"},{intent:"themePrimary",disabled:!1,bgContext:"dark",className:"text-theme-primary *:text-grey-800 border-white bg-white hover:border-black hover:bg-black hover:text-white *:hover:text-white [&>svg]:text-black"},{intent:"themeTertiary",disabled:!1,bgContext:"light",className:"text-theme-tertiary *:hover:text-grey-800 border-black bg-black *:text-white hover:border-white hover:bg-white hover:text-black [&>svg]:hover:text-black"},{intent:"themeTertiary",disabled:!1,bgContext:"dark",className:"text-theme-tertiary *:text-grey-800 border-white bg-white hover:border-black hover:bg-black hover:text-white *:hover:text-white [&>svg]:text-black"},{intent:"black",disabled:!1,className:"*:text-grey-600 border-black bg-black text-white hover:border-red-500 hover:bg-red-500"},{intent:"white",disabled:!1,className:"*:text-grey-800 border-white bg-white text-black hover:border-red-500 hover:bg-red-500"},{intent:"grey",disabled:!1,bgContext:"light",className:"bg-grey-600 border-grey-600 *:text-grey-800 text-black hover:border-red-500 hover:bg-red-500"},{intent:"grey",disabled:!1,bgContext:"dark",className:"[&>svg]:text-grey-500 border-[#282828] bg-[#282828] text-white hover:border-red-500 hover:bg-red-500"},{intent:["primary","black","white","grey"],disabled:!0,bgContext:"light",className:"border-grey-600 *:text-grey-600 text-black"},{intent:["primary","black","white","grey"],disabled:!0,bgContext:"dark",className:"border-grey-800 *:text-grey-800 text-white"}],defaultVariants:{intent:"primary",size:"default",icon:null,disabled:!1,bgContext:"light"}}),d=r.forwardRef(({disabled:e,className:t,intent:s,bgContext:r,icon:n,size:l,ariaLabel:d,asChild:m=!1,...u},x)=>{let h=m?i.DX:"button";return(0,a.jsx)(h,{className:o()(c({bgContext:r,intent:s,size:l,disabled:e,icon:n,className:t})),disabled:e,ref:x,"aria-label":d,...u})});d.displayName="Button"},26320:(e,t,s)=>{"use strict";s.d(t,{X:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?16:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M15.75 19.1884L14.9951 19.9443H10.3545V18.4335H13.1719L10.3545 15.6152L11.4219 14.5478L14.2402 17.3661V14.5478H15.75V19.1884Z"}),(0,a.jsx)("path",{d:"M13.75 5.12494V12.8398H12.25V5.87494H1.75V16.3749H8.89062V17.8749H1L0.25 17.1249V5.12494L1 4.37494H13L13.75 5.12494Z"}),(0,a.jsx)("path",{d:"M9.83203 10.7226V11.1523L5.37793 13.8007L5 13.5859V8.289L5.37793 8.07416L9.83203 10.7226Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M19 18.3135L18.2451 19.0693H13.6045V17.5586H16.4219L13.6045 14.7402L14.6719 13.6729L17.4902 16.4912V13.6729H19V18.3135Z"}),(0,a.jsx)("path",{d:"M17 4.25V11.9648H15.5V5H5V15.5H12.1406V17H4.25L3.5 16.25V4.25L4.25 3.5H16.25L17 4.25Z"}),(0,a.jsx)("path",{d:"M13.082 9.84766V10.2773L8.62793 12.9258L8.25 12.7109V7.41406L8.62793 7.19922L13.082 9.84766Z"})]})})},31848:(e,t,s)=>{"use strict";s.d(t,{Insights:()=>i});
1var a=s(41657),r=s(44471);function i(){return(0,a.jsx)(r.b,{beforeSend:e=>!function(e){let t=e;try{t=new URL(e,"https://x").pathname}catch{}let s=t.split("/").filter(Boolean);return"/"===t||"news"===s[0]||"life"===s[0]&&s.length>=3?.04>Math.random():"podcast"===s[0]?.4>Math.random():"life"===s[0]||"/podcasts"===t||"video"===s[0]||.25>Math.random()}(e.url)?null:e})}},40531:(e,t,s)=>{"use strict";s.d(t,{k:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?13:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M12.1323 6.59092L1.15708 17.5662L0 16.4091L10.9753 5.43384L12.1323 6.59092Z"}),(0,a.jsx)("path",{d:"M1.15708 5.43384L12.1323 16.4091L10.9753 17.5662L0 6.59092L1.15708 5.43384Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M17.0659 6.09092L6.09068 17.0662L4.93359 15.9091L15.9089 4.93384L17.0659 6.09092Z"}),(0,a.jsx)("path",{d:"M6.09068 4.93384L17.0659 15.9091L15.9089 17.0662L4.93359 6.09092L6.09068 4.93384Z"})]})})},40901:(e,t,s)=>{Promise.resolve().then(s.bind(s,79984)),Promise.resolve().then(s.bind(s,1961)),Promise.resolve().then(s.bind(s,13701)),Promise.resolve().then(s.bind(s,85458)),Promise.resolve().then(s.bind(s,23182)),Promise.resolve().then(s.bind(s,18011)),Promise.resolve().then(s.bind(s,45967)),Promise.resolve().then(s.bind(s,63388)),Promise.resolve().then(s.bind(s,61720)),Promise.resolve().then(s.bind(s,95832)),Promise.resolve().then(s.bind(s,31848)),Promise.resolve().then(s.t.bind(s,65407,23)),Promise.resolve().then(s.bind(s,54661)),Promise.resolve().then(s.bind(s,26797)),Promise.resolve().then(s.bind(s,81596)),Promise.resolve().then(s.bind(s,71058)),Promise.resolve().then(s.bind(s,68281)),Promise.resolve().then(s.t.bind(s,3523,23)),Promise.resolve().then(s.t.bind(s,45999,23)),Promise.resolve().then(s.t.bind(s,71129,23)),Promise.resolve().then(s.t.bind(s,90159,23)),Promise.resolve().then(s.t.bind(s,97691,23)),Promise.resolve().then(s.t.bind(s,89513,23)),Promise.resolve().then(s.t.bind(s,64540,23)),Promise.resolve().then(s.t.bind(s,12923,23)),Promise.resolve().then(s.t.bind(s,60056,23)),Promise.resolve().then(s.bind(s,7511)),Promise.resolve().then(s.bind(s,66305)),Promise.resolve().then(s.bind(s,11083)),Promise.resolve().then(s.bind(s,83873)),Promise.resolve().then(s.bind(s,99726))},44635:(e,t,s)=>{"use strict";s.d(t,{R:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?12:22,height:22,className:t,children:"text"===e?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M6.24859 14.7116L9.99412 10.9671L11.0305 12.0034L6.03292 17H4.99658L0 12.0034L1.03634 10.9671L4.78282 14.7136V5H6.24859V14.7116Z"})}):(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M11.733 14.7116L15.4785 10.9671L16.5148 12.0034L11.5173 17H10.481L5.48438 12.0034L6.52072 10.9671L10.2672 14.7136V5H11.733V14.7116Z"})})})},45885:(e,t,s)=>{"use strict";s.d(t,{s:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M7.52104 10.4215V11.5785L1.15708 17.9425L5.05777e-07 16.7854L5.78542 11L0 5.21458L1.15708 4.0575L7.52104 10.4215Z"}),(0,a.jsx)("path",{d:"M13.521 10.4215V11.5785L7.15708 17.9425L6 16.7854L11.7854 11L6 5.21458L7.15708 4.0575L13.521 10.4215Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M12.2603 10.4215V11.5785L5.89634 17.9425L4.73926 16.7854L10.5247 11L4.73926 5.21458L5.89634 4.0575L12.2603 10.4215Z"}),(0,a.jsx)("path",{d:"M18.2603 10.4215V11.5785L11.8963 17.9425L10.7393 16.7854L16.5247 11L10.7393 5.21458L11.8963 4.0575L18.2603 10.4215Z"})]})})},45967:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/favicon-32x32.57dffcd7.png",height:32,width:32,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAOVBMVEUCAgKRkZG2traFhYVTU1O+vr55eXn8/PxHR0ciIiLU1NQqKiodHR3KyspkZGSgoKA2NjZubm7s7OwdxmCzAAAA
1CXBIWXMAAATrAAAE6wHYKlsNAAAAOUlEQVR4nBXKSRIAIQgEwVKBBmef/z/WMM/JKLj9ADKMSpiS5gn8yasGfPTHfZeSFBSNuAaWyADrLDKEAUog4B0bAAAAAElFTkSuQmCC",blurWidth:8,blurHeight:8}},47954:(e,t,s)=>{"use strict";s.d(t,{Br:()=>o,FK:()=>l,VM:()=>c,lr:()=>d});var a=s(41657),r=s(48237),i=s(56141),n=s(6501);let l=r.forwardRef(({className:e,...t},s)=>(0,a.jsx)(i.bL,{ref:s,className:(0,n.cn)("overflow-hidden",e),style:{"--scrollbar-size":"0.5rem"},...t}));l.displayName=i.bL.displayName;let o=r.forwardRef(({className:e,...t},s)=>(0,a.jsx)(i.LM,{ref:s,className:(0,n.cn)("h-full w-full",e),...t}));o.displayName=i.LM.displayName;let c=r.forwardRef(({className:e,...t},s)=>{let{orientation:r}=t;return(0,a.jsx)(i.Ze,{ref:s,className:(0,n.cn)("hover:bg-surface-muted bg-surface-muted relative z-50 flex touch-none select-none transition-colors",{"w-[var(--scrollbar-size)]":"vertical"===r,"h-[var(--scrollbar-size)] flex-col":"horizontal"===r},e),...t})});c.displayName=i.Ze.displayName;let d=r.forwardRef(({className:e,...t},s)=>(0,a.jsx)(i.zi,{ref:s,className:(0,n.cn)('before:transform-[-50%,-50%] bg-grey-500 relative flex-1 before:absolute before:left-1/2 before:top-1/2 before:h-full before:min-h-48 before:w-full before:min-w-48 before:content-[""]',e),style:{borderRadius:"var(--scrollbar-size)"},...t}));d.displayName=i.zi.displayName,i.OK},48350:(e,t,s)=>{"use strict";s.d(t,{b:()=>o});var a=s(41657),r=s(17629),i=s(34627),n=s(67878),l=s(51162);let o=()=>{let{audioCurrentTime:e,audioDuration:t,isPlaying:s}=(0,i.E)(),o=t-e>=r.vN,c={duration:.15};return(0,a.jsx)(n.N,{mode:"wait",children:s?o?(0,a.jsx)(l.P.p,{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:c,className:"text-foreground-primary flex-shrink-0 text-sm",children:"Behind livestream"},"behind"):(0,a.jsx)(l.P.span,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:c,className:"bg-surface-accent font-sans-normal rounded-md px-4 pb-2 pt-1 text-xs uppercase leading-snug tracking-widest text-white","aria-label":"Live station",children:"Live"},"live"):null})}},51318:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>o});var a=s(41657),r=s(48237),i=s(99467),n=s(675),l=s.n(n);function o({text:e,isSerif:t}){let[s,n]=(0,r.useState)("");return((0,r.useEffect)(()=>{0===e.length||n((0,i.A)(window).sanitize(e))},[e]),s)?(0,a.jsx)("span",{dangerouslySetInnerHTML:{__html:s},className:l()({"[&>em]:font-sans-italic [&>strong]:font-sans-semibold [&>em]:italic":!t,"[&>em]:font-serif-text-italic [&>strong]:font-serif-text-medium [&>em]:italic":t})}):null}},51373:(e,t,s)=>{"use strict";s.d(t,{_:()=>i});var a=s(41657),r=s(51487);let i=({className:e,children:t,strokeWidth:s,size:i})=>(0,a.jsx)("svg",{viewBox:"0 0 32 32",xmlns:"http://www.w3.org/2000/svg",focusable:"false","aria-hidden":"true",className:`${e}`,style:{height:"sm"===i?(0,r.D)(20):"lg"===i?(0,r.D)(32):(0,r.D)(24),width:"sm"===i?(0,r.D)(20):"lg"===i?(0,r.D)(32):(0,r.D)(24),strokeWidth:s??"lg"===i?"2px":"1.5px"},children:t})},51487:(e,t,s)=>{"use strict";function a(e){return`calc(${e/10}rem*var(--base-multiplier))`}function r(e){return`${e/16}em`}function i(e){switch(e){case"xxxs":return r(320);case"xxs":return r(384);case"xs":return r(520);case"sm":return r(640);case"md":return r(768);case"ml":return r(896);case"lg":return r(1024);case"xl":return r(1136);case"2xl":return r(1312);case"3xl":return r(1600)}}s.d(t,{D:()=>a,em:()=>r,s:()=>i})},53641:(e,t,s)=>{"use strict";s.d(t,{u:()=>n});var a=s(41657),r=s(19125),i=s(17629);let n=({media:e,size:t="xs",hasShortDate:s,className:n,hasAccentSeparator:l})=>(0,a.jsx)(r.L,{className:n,size:t,hasShortDate:s,hasAccentSeparator:l,indexDetails:{type:"trailer"===e.type?"trailer":"bonus_episode"===e.type?"bonus":e.structure===i.il.seasonal?"seasonal":e.structure===i.il.miniSeries?"miniSeries":"episodic",seasonNumber:e.seasonNumber,episodeNumber:e.episodeNumber??0,releaseDateISO:e.releaseDate??""}})},53705:(e,t,s)=>{"use strict";s.d(t,{S:()=>c});var a=s(41657),r=s(6501),i=s(78865),n=s(19155),l=s(53641),o=s(11502);let c=({media:e,darkContext:t=!1,titleHeadingLevel:s=2,hasShortDate:c,size:d="small",hasAccentSeparator:m})=>(0,a.jsx)(a.Fragment,{children:e.liveStreamName?(0,a.jsx)(i.V,{headingLevel:s,liveStreamName:e.liveStreamName,isDarkContext:t}):(0,a.jsxs)("div",{className:(0,r.cn)("text-foreground-primary flex flex-col gap-4",{"light-theme":!t,"dark-theme":t}),children:[(0,a.jsx)(n.D,{level:s,className:(0,r.cn)("order-2 mb-4 text-pretty","medium"===d?"line-clamp-1 text-base":"line-clamp-2 text-sm"),children:(0,a.jsx)("span",{dangerouslySetInnerHTML:{__html:e.title},className:"block"})}),(0,a.jsxs)("div",{className:(0,r.cn)("order-1 flex items-baseline gap-8","medium"===d?"text-sm":"text-xs leading-snug"),children:[e.context&&(e.contextHref?"episode"===e.apiSource?(0,a.jsx)(o.DeferredPrefetchLink,{href:e.contextHref,className:(0,r.cn)("font-sans-semibold underline-brand-hover line-clamp-1 pb-1"),children:e.context}):(0,a.jsx)("a",{href:e.contextHref,className:(0,r.cn)("font-sans-semibold underline-brand-hover line-clamp-1 pb-1"),children:e.context}):(0,a.jsx)("span",{className:(0,r.cn)("font-sans-semibold line-clamp-1"),children:e.context})),(0,a.jsx)(l.u,{media:e,hasShortDate:c,hasAccentSeparator:m})]})]})})},55223:(e,t,s)=>{"use strict";s.d(t,{w:()=>o});var a=s(41657),r=s(64252),i=s(40610),n=s.n(i),l=s(11502);let o=({route:e,isNextJSContext:t,isCurrent:s,lang:i,ariaLabel:o,handleClick:c,children:d,className:m,forceRefresh:u,deferPrefetch:x})=>{if(r.nZ?.includes(e)&&t&&!u){let t=x?l.DeferredPrefetchLink:n();return(0,a.jsx)(t,{href:e,className:m,"aria-current":s?"page":void 0,lang:i,"aria-label":o,onClick:()=>c?.(),children:d})}return(0,a.jsx)("a",{href:e,className:m,"aria-current":s?"page":void 0,lang:i,"aria-label":o,onClick:()=>c?.(),children:d})}},55734:(e,t,s)=>{"use strict";s.d(t,{g:()=>i});var a=s(96507),r=s(34627);let i=e=>{let{items:t,marker:s}=(0,a.M)(),{isPlaying:i}=(0,r.E)();if(!e)return!1;let n=t[s];return e.liveStreamName&&n?.liveStreamName?i&&e.liveStreamName===n.liveStreamName:i&&n?.id===e.id}},61720:(e,t,s)=>{"use strict";s.d(t,{NielsenPageTracker:()=>i});var a=s(48237),r=s(45575);let i=()=>{let e=(0,r.usePathname)(),t=(0,a.useRef)(null);return(0,a.useEffect)(()=>
1{if(t.current===e)return;let s=window.nSdkInstance;if(s){let a=window.staticMetadataObject;s.ggPM("staticend",a),a.referrerURL=a.pageURL||window.location,a.pageURL=`page_${window.location.toString()}`,a.assetid=`${window.location.pathname}`,s.ggPM("staticstart",a),window.staticMetadataObject=a,t.current=e}},[e]),null}},63388:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/safari-pinned-tab.8808ba28.svg",height:933,width:933,blurWidth:0,blurHeight:0}},64252:(e,t,s)=>{"use strict";s.d(t,{Qo:()=>r,hm:()=>n,hp:()=>i,nZ:()=>a});let a=["/life","/life/screens","/life/books","/life/culture","/life/music","/life/food","/life/wellbeing","/life/lifestyle","/life/relationships","/life/people","/podcasts","/video","/"],r=e=>!0,i=({route:e,pathname:t,isNextJSContext:s})=>s&&t?t:e??"",n=({segmentIndex:e,route:t,pathname:s,isNextJSContext:a})=>a&&s?s.split("/")[e]:t?t.split("/")[e]:void 0},65407:()=>{},66305:(e,t,s)=>{"use strict";s.d(t,{SiteHeader:()=>ej});var a=s(41657),r=s(675),i=s.n(r),n=s(48237),l=s(45575),o=s(64121),c=s(17629),d=s(51487),m=s(34627),u=s(64252),x=s(30262),h=s(17980),p=s(79594),f=s(13941),g=s(95091),b=s(81685),j=s(55223),v=s(96507),y=s(55734),w=s(47166),N=s(80367),C=s(66185),L=s(29311);let k=({media:e,handleClick:t,pathname:s,className:r})=>{let{items:l,marker:o,insertAt:d,setMarker:u}=(0,v.M)(),{play:x,pause:h}=(0,m.E)(),p=(0,y.g)(e),g=(0,n.useRef)(null),b=e?.liveStreamName,j=`Listen live to ${b?w.ai[b].title:"RNZ Station"}`,k=i()("hover:!bg-surface-hover",{"!bg-station-national-primary":b===c.UZ.national,"!bg-station-concert-primary":b===c.UZ.concert,"!bg-station-pacific-primary":b===c.UZ.pacific,"!bg-station-parliament-primary":b===c.UZ.parliament},r),A=p?(0,a.jsx)(N._,{align:"text"}):(0,a.jsx)(C.A,{align:"text"}),S=()=>{if(p)h();else{let a;d(a=0===l.length?0:o+1,{...e,playbackBeginUrl:s,qid:(0,f.Ak)()}),u(a),x(),t&&t()}};return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"xs:hidden",children:(0,a.jsx)(L.$n,{ref:g,size:"sm",theme:"base",iconPosition:"prefix",icon:A,content:b?w.ai[b].title:"",className:i()(k),"aria-label":j,onClick:S})}),(0,a.jsx)("div",{className:"xs:block hidden",children:(0,a.jsx)(L.$n,{ref:g,size:"sm",theme:"base",iconPosition:"prefix",icon:A,content:"Listen Live",className:i()(k),"aria-label":j,onClick:S})})]})};var A=s(70982);let S=Object.keys(w.ai).map(e=>({...w.ai[e],qid:(0,f.Ak)()})),M=[{text:w.ai.national.title,name:w.ai.national.liveStreamName,route:"/national"},{text:w.ai.concert.title,name:w.ai.concert.liveStreamName,route:"/concert"},{text:w.ai.pacific.title,name:w.ai.pacific.liveStreamName,route:"/pacific"},{text:w.ai.parliament.title,name:w.ai.parliament.liveStreamName,route:"/parliament"}],P=({dialogType:e,section:t,pathname:s,radioLinks:r,hasLatestBulletin:n,latestBulletin:l,hasListenMoreLink:o,onPlayAudio:c,setDialogOpen:d,isNextJSContext:m,hasJS:u,className:x})=>{let h=e=>S.find(t=>t.liveStreamName===e),p=i()("underline-brand-hover hover:!decoration-stroke-link-hover flex-grow py-8 !decoration-transparent focus-visible:outline-offset-0");return(0,a.jsxs)("ul",{className:i()({"xs:columns-1 columns-2 gap-x-16":!u,"flex flex-col":u},x),"aria-labelledby":`nav-primary-${t.name}`,children:[(r??M).map(e=>(0,a.jsxs)("li",{className:"flex items-center justify-between gap-8",children:[(0,a.jsx)(j.w,{route:e.route,isNextJSContext:m,handleClick:()=>d(!1),className:p,children:e.text}),u&&!!h(e.name)&&(0,a.jsx)(k,{media:h(e.name),handleClick:c,pathname:s})]},e.name)),u&&n&&l&&(0,a.jsxs)("li",{className:"flex items-center justify-between gap-8",children:[(0,a.jsx)(j.w,{route:"/programmes/news-bulletin-podcast",isNextJSContext:m,handleClick:()=>d(!1),className:p,children:(()=>{if(!l?.releaseDate)return"Headlines";let e=(0,g.A)(l.releaseDate),t=(0,b.A)(e,"haaa");return`Headlines at ${t}`})()}),(0,a.jsx)(A.LatestBulletinTrigger,{dialogType:e,media:l,pathname:s,onPlayAudio:c})]}),o&&(0,a.jsx)("li",{className:"flex justify-end",children:(0,a.jsx)(j.w,{route:"/listen/amfm",isNextJSContext:m,handleClick:()=>d(!1),className:"underline-brand-hover relative py-8 text-sm focus-visible:outline-offset-0",children:"More ways to listen"})})]})};var E=s(77154);let V=({text:e,route:t,lang:s,isCurrent:r,setDialogOpen:n,isNextJSContext:l,className:o})=>(0,a.jsx)(j.w,{route:t,lang:s,isCurrent:r,isNextJSContext:l,handleClick:()=>n(!1),deferPrefetch:(0,u.Qo)(t),className:i()("underline-brand-hover hover:!decoration-stroke-link-hover py-8 !decoration-transparent focus-visible:outline-offset-0",o),children:e}),H=({section:e,route:t,columns:s=1,setDialogOpen:r,isNextJSContext:n,secondaryLinksAriaLabel:l,children:o,className:c,primaryLinksClassName:d,secondaryLinksClassName:m})=>(0,a.jsxs)("div",{className:c,children:[e.primaryLinks&&(0,a.jsx)("ul",{className:i()("gap-x-16",{"xs:col-span-3 xxs:columns-3 columns-2":3===s,"xs:col-span-2 xxs:columns-2 columns-2":2===s,"columns-1":1===s},d),"aria-labelledby":`nav-primary-${e.name}`,children:e.primaryLinks.map(e=>(0,a.jsx)("li",{className:"relative flex items-center",children:(0,a.jsx)(V,{...e,isCurrent:t===e.route,setDialogOpen:r,isNextJSContext:n,className:i()("flex-grow break-inside-avoid",{"font-sans-semibold":"life"===e.name})})},e.name))}),e.secondaryLinks&&(0,a.jsx)("ul",{className:m,"aria-label":l,children:e.secondaryLinks.map(e=>(0,a.jsx)("li",{className:"relative flex items-center",children:(0,a.jsx)(V,{...e,isCurrent:t===e.route,setDialogOpen:r,isNextJSContext:n,className:"flex-grow"})},e.name))}),o]});var R=s(71537),Z=s(67918);let D=({text:e,subtext:t,name:s,route:r,isCurrent:n,isPanelOpen:l,setDialogOpen:o,isNextJSContext:c,hasJS:d})=>{let m=i()("items-baseline font-sans-semibold flex w-full py-16 border-b-2 border-stroke-accent",{"!border-[#D5B76B]":"life"===s,"!border-station-concert-primary":"radio"===s,"!border-[#5B9656]":"podcasts"===s,"!border-[#4E568A]":"video"===s,"!border-[#10A3F5]":"storytime"===s}),x=()=>(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"group-hover:decoration-stroke-link-hover underline decoration-transparent decoration-2 underline-offset-[0.15em]",children:e}),t&&(0,a.jsx)("span",{className:"@[11.56em]:block font-sans-normal text-foreground-secondary ml-8 hidden",lang:"mi",children:t})]});return(0,a.jsx)("div",{className:"@container w-full",children:r?(0,a.jsx)(j.w,{isNextJSContext:c,route:r,isCurrent:n,handleClick:()=>o(!1),deferPrefetch:(0,u.Qo)(r),className:i()("group !no-underline",m),children:(0,a.jsx)(x,{})}):(0,a.jsxs)("div",{className:i()(m),children:[(0,a.jsx)("div",{className:"flex flex-grow",children:(0,a.jsx)(x,{})}),(0,a.jsx)("div",{className:i()("xs:hidden",{hidden:l&&d,"group-[[open]]/nav-details:hidden":!d}),children:(0,a.jsx)(L.$n,{type:"span",size:"sm",theme:"secondary",icon:(0,a.jsx)(R.r,{align:"text"}),iconPosition:"suffix",content:"Show",className:"font-sans-normal text-sm","aria-hidden":!0})}),(0,a.jsx)("div",{className:i()("xs:hidden",{hidden:!l&&d,"hidden group-[[open]]/nav-details:block":!d}),children:(0,a.jsx)(L.$n,{type:"span",size:"sm",theme:"secondary",icon:(0,a.jsx)(Z.o,{align:"text"}),iconPosition:"suffix",content:"Hide",className:"font-sans-normal text-sm","aria-hidden":!0})})]})})},z=({section:e,columns:t=1,route:s,dialogType:r,setDialogOpen:l,pathname:o,isNextJSContext:d,hasJS:m,secondaryLinksAriaLabel:u,children:x,className:h,primaryLinksClassName:p,secondaryLinksClassName:f})=>
1{let[g,b]=(0,n.useState)(!1),j="news"===e.name,v=i()({"py-8":r===c.Os.sections,"pt-8":r===c.Os.news,"pb-8 lg:pb-0":r===c.Os.news&&j});return(0,a.jsxs)(a.Fragment,{children:[m?(0,a.jsxs)(E.Nt,{open:g,onOpenChange:b,className:i()("xs:hidden",h),children:[(0,a.jsx)("h3",{id:`nav-primary-${e.name}`,children:(0,a.jsx)(E.R6,{className:i()("flex w-full justify-between !outline-offset-[-4px]"),children:(0,a.jsx)(D,{...e,isCurrent:!!s&&e.route===s,isPanelOpen:g,setDialogOpen:l,isNextJSContext:d,hasJS:m})})}),(0,a.jsx)(E.Ke,{className:"xs:hidden border-stroke-light border-b",children:(0,a.jsx)(H,{route:s,section:e,columns:t,dialogType:r,setDialogOpen:l,pathname:o,secondaryLinksAriaLabel:u,isNextJSContext:d,hasJS:m,primaryLinksClassName:i()(v,p),secondaryLinksClassName:i()(v,f),children:x})})]}):(0,a.jsxs)("details",{name:`nav-primary-${e.name}`,className:i()("xs:hidden group/nav-details",h),children:[(0,a.jsx)("summary",{className:"list-none marker:hidden",children:(0,a.jsx)("h3",{className:i()("flex w-full justify-between !outline-offset-[-4px]"),children:(0,a.jsx)(D,{...e,isCurrent:!!s&&e.route===s,isPanelOpen:g,setDialogOpen:l,isNextJSContext:d,hasJS:m})})}),(0,a.jsx)("div",{className:"xs:hidden border-stroke-light border-b",children:(0,a.jsx)(H,{route:s,section:e,columns:t,dialogType:r,setDialogOpen:l,pathname:o,secondaryLinksAriaLabel:u,isNextJSContext:d,hasJS:m,className:v,primaryLinksClassName:i()(v,p),secondaryLinksClassName:i()(v,f),children:x})})]}),(0,a.jsx)("div",{className:i()("xs:block hidden",h),children:(0,a.jsxs)("div",{className:"flex h-full flex-col",children:[(0,a.jsx)("h3",{id:`nav-primary-${e.name}`,children:(0,a.jsx)(D,{...e,isCurrent:!!s&&e.route===s,isPanelOpen:g,setDialogOpen:l,isNextJSContext:d,hasJS:m})}),(0,a.jsx)("div",{className:i()("h-full",{"border-stroke-light border-b lg:border-none":r===c.Os.news&&j,"border-stroke-light border-b":r===c.Os.sections}),children:(0,a.jsx)(H,{route:s,section:e,columns:t,dialogType:r,setDialogOpen:l,pathname:o,secondaryLinksAriaLabel:u,isNextJSContext:d,hasJS:m,className:i()({"xs:grid xs:grid-cols-4 xs:gap-16":j}),primaryLinksClassName:i()(v,p),secondaryLinksClassName:i()(v,f),children:x})})]})})]})},T=[{text:"News sections",name:"news",primaryLinks:[{text:"Politics",name:"news/politics",route:"/news/politics"},{text:"World",name:"news/world",route:"/news/world"},{text:"Business",name:"news/business",route:"/news/business"},{text:"Personal finance",name:"news/personal-finance",route:"/news/personal-finance"},{text:"Sport",name:"news/sport",route:"/news/sport"},{text:"Crime / Justice",name:"news/crime-and-justice",route:"/news/crime-and-justice"},{text:"Health",name:"news/health",route:"/news/health"},{text:"Education",name:"news/education",route:"/news/education"},{text:"Environment",name:"news/environment",route:"/news/environment"},{text:"Science / Tech",name:"news/science-and-technology",route:"/news/science-and-technology"},{text:"Emergencies",name:"news/emergencies",route:"/news/emergencies"},{text:"Community",name:"news/community",route:"/news/community"},{text:"Regions",name:"news/regions",route:"/news/regions"},{text:"Country",name:"news/country",route:"/news/country"},{text:"Weather",name:"news/weather",route:"/news/weather"}],secondaryLinks:[{text:"Te Ao MÄori",name:"news/te-ao-maori",route:"/news/te-ao-maori"},{text:"Pacific",name:"news/pacific",route:"/news/pacific"},{text:"IndoNZ",name:"news/indonz",route:"/news/indonz"},{text:"䏿",name:"news/chinese",route:"/news/chinese",lang:"zh"}]}],O=[{text:"Follow the news",name:"follow",primaryLinks:[{text:"Sign up for our Daily Newsletter",name:"newsletter",route:"https://radionz.us6.list-manage.com/subscribe?u=211a938dcf3e634ba2427dde9&id=b3d362e693"},{text:"Subscribe to RNZ News with RSS",name:"rss",route:"https://www.rnz.co.nz/rss/news.xml"},{text:"Get the RNZ App",name:"app",route:"https://www.rnz.co.nz/listen/app"}],secondaryLinks:[{text:"Facebook",name:"facebook",route:"https://www.facebook.com/rnznewzealand"},{text:"Instagram",name:"instagram",route:"https://www.instagram.com/rnznewzealand"},{text:"YouTube",name:"youtube",route:"https://www.youtube.com/@rnznewzealand"},{text:"TikTok",name:"tiktok",route:"https://www.tiktok.com/@rnznewzealand"}]}],F=[{text:"Listen to the news",name:"listen"}],I=[{text:w.ai.national.title,name:w.ai.national.liveStreamName,route:"/national"},{text:w.ai.pacific.title,name:w.ai.pacific.liveStreamName,route:"/pacific"},{text:w.ai.parliament.title,name:w.ai.parliament.liveStreamName,route:"/parliament"}],B=({latestBulletin:e,onPlayAudio:t,setDialogOpen:s,route:r,isNextJSContext:i,pathname:n,hasJS:l})=>{let o=c.Os.news;return(0,a.jsx)("nav",{children:(0,a.jsxs)("div",{className:"xs:grid-cols-2 grid gap-x-24 lg:grid-cols-4",children:[T.map(e=>(0,a.jsx)(z,{section:e,columns:3,route:r,dialogType:o,setDialogOpen:s,isNextJSContext:i,hasJS:l,secondaryLinksAriaLabel:"Community news services",className:"ml:col-span-2 col-span-full"},e.text)),O.map(e=>(0,a.jsx)(z,{section:e,route:r,dialogType:o,setDialogOpen:s,isNextJSContext:i,hasJS:l,secondaryLinksAriaLabel:"Social accounts",secondaryLinksClassName:"flex justify-between lg:block lg:columns-2 !pt-0"},e.text)),F.map(d=>(0,a.jsx)(z,{section:d,route:r,dialogType:o,setDialogOpen:s,isNextJSContext:i,hasJS:l,children:(0,a.jsx)(P,{dialogType:c.Os.news,section:d,radioLinks:I,hasLatestBulletin:!0,latestBulletin:e,hasListenMoreLink:!0,pathname:n??"",onPlayAudio:t,setDialogOpen:s,isNextJSContext:i,hasJS:l,className:"pt-8"})},d.text))]})})};var J=s(47954);let $=({id:e,ariaLabel:t,children:s})=>{let r=i()("fixed m-0 w-full p-0","!top-[var(--nav-height)] max-h-[calc(100dvh-var(--nav-height))]");return(0,a.jsx)("section",{id:e,popover:"auto",className:r,"aria-label":t,autoF
1ocus:!0,tabIndex:-1,children:(0,a.jsx)("div",{className:"bg-surface-primary text-foreground-primary relative flex w-full flex-col",children:(0,a.jsxs)(J.FK,{className:"flex flex-col",children:[(0,a.jsx)(J.Br,{children:(0,a.jsx)(h.m,{withNoVertPadding:!0,className:"pb-24 pt-8",children:s})}),(0,a.jsx)(J.VM,{orientation:"vertical",className:"hover:bg-surface-muted bg-surface-muted",children:(0,a.jsx)(J.lr,{className:"bg-grey-500"})})]})})})},U=({logoSrc:e,className:t,imgClassName:s,setDialogOpen:r,isNextJSContext:n,forceRefresh:l})=>(0,a.jsx)(j.w,{className:i()("flex","xxs:w-[calc(9.7rem*var(--base-multiplier))] w-[calc(7.5rem*var(--base-multiplier))] xl:w-[calc(11.9rem*var(--base-multiplier))]",t),route:"/",isNextJSContext:n,handleClick:()=>r(!1),forceRefresh:l,deferPrefetch:(0,u.Qo)("/"),children:(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("img",{src:e,alt:"RNZ Home",className:s})})});var _=s(58478);let K=({className:e,align:t})=>(0,a.jsx)(_.h,{align:t,width:"text"===t?12:22,height:22,className:e,children:(0,a.jsx)(a.Fragment,{children:"text"===t?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M12 12.1622H0V10.6622H12V12.1622Z",fill:"currentColor"}),(0,a.jsx)("path",{d:"M12 8H0V6.5H12V8Z",fill:"currentColor"}),(0,a.jsx)("path",{d:"M12 16.0996H0V14.5996H12V16.0996Z",fill:"currentColor"})]}):(0,a.jsx)("path",{d:"M17 15.5996H5V14.4004H17V15.5996ZM17 11.4004H5V10.2002H17V11.4004ZM17 7.2002H5V6H17V7.2002Z",fill:"currentColor"})})});var q=s(77661),G=s(51168),Q=s(10711),X=s(24870);let W=({className:e})=>{let{props:t}=(0,X.getImageProps)({src:"/assets/images/national-fallback-cover.png",alt:"",width:44,height:44});return(0,a.jsx)("img",{...t,className:e,"aria-hidden":"true"})},Y=({pathname:e,currentProgramme:t,className:s})=>{let{items:r,marker:l,insertAt:o,setMarker:c,focusPlayer:d}=(0,v.M)(),{play:u,pause:x}=(0,m.E)(),h=(0,n.useRef)(null),p={...w.ai.national,qid:(0,f.Ak)()},g=(0,y.g)(p),b=(0,Q.JY)(p),j=(0,Q.pz)(p),k=(0,Q.UU)(p),A=()=>{if(g)x();else{let t,s;t={...p,images:j,themeColors:k,title:b},o(s=0===r.length?0:l+1,{...t,playbackBeginUrl:e,qid:(0,f.Ak)()}),c(s),u(),(0,G.j)(h.current,d)}},S=i()("after:absolute after:inset-0"),M=`${g?"Pause":"Play"} RNZ National live stream`,P=i()("hidden @[10.93em]:block h-32 w-32 @[12.9em]:h-[calc(4.4rem*var(--base-multiplier))] @[12.9em]:w-[calc(4.4rem*var(--base-multiplier))]"),E=g?(0,a.jsx)(N._,{className:"h-16 w-16"}):(0,a.jsx)(C.A,{className:"h-16 w-16"});return(0,a.jsx)("div",{className:i()("@container/live-radio-panel w-full",s),children:(0,a.jsxs)("div",{className:"relative inline-flex h-full w-full items-center gap-8",children:[t?.thumbnailUrl?(0,a.jsx)("img",{src:t.thumbnailUrl,alt:"",width:44,height:44,"aria-hidden":!0,className:P}):(0,a.jsx)(W,{className:P}),(0,a.jsxs)("div",{className:"flex w-full flex-col overflow-hidden",children:[(0,a.jsxs)("span",{className:"@container flex w-full flex-nowrap items-center gap-4",children:[(0,a.jsxs)("span",{className:"font-sans-semibold @[12.9em]/live-radio-panel:text-sm text-xs",children:["RNZ",(0,a.jsx)("span",{className:"@[5.9em]:inline hidden",children:" National"})]}),(0,a.jsx)("span",{className:"bg-surface-accent min-w-24 py-1 pl-2 pr-1 text-[calc(0.9rem*var(--base-multiplier))] uppercase leading-none tracking-wider text-white",children:"Live"})]}),t&&(0,a.jsx)("span",{className:"font-sans-normal @[12.9em]/live-radio-panel:text-sm truncate text-xs",children:t.name??t.fallbackTitle})]}),(0,a.jsxs)("div",{children:[(0,a.jsx)("div",{className:"@[10.93em]:hidden",children:(0,a.jsx)(L.$n,{ref:h,size:"iconSm",theme:"base",icon:E,iconPosition:"only","aria-label":M,onClick:A,className:S})}),(0,a.jsx)("div",{className:"@[10.93em]:block @[12.9em]:hidden hidden",children:(0,a.jsx)(L.$n,{ref:h,size:"iconMd",theme:"base",icon:E,iconPosition:"only","aria-label":M,onClick:A,className:S})}),(0,a.jsx)("div",{className:"@[12.9em]:block hidden",children:(0,a.jsx)(L.$n,{ref:h,size:"iconLg",theme:"base",icon:E,iconPosition:"only","aria-label":M,onClick:A,className:S})})]})]})})},ee=(0,n.forwardRef)(({text:e,dialogType:t,isDialogOpen:s,hasNewsDialog:r,anchorClasses:n,...l},o)=>(0,a.jsxs)("button",{ref:o,"aria-label":`${e} navigation`,className:i()(n,{"pointer-events-none":s&&t===c.Os.news,"!decoration-stroke-link-hover !decoration-2":s&&t===c.Os.news,"text-black-alpha-500":s&&t!==c.Os.news}),...l,children:[e,r&&(0,a.jsx)(a.Fragment,{children:s&&t===c.Os.news?(0,a.jsx)(Z.o,{className:"ml-8",align:"text"}):(0,a.jsx)(R.r,{className:"ml-8",align:"text"})})]}));ee.displayName="ButtonTemplate";let et=({text:e,href:t,lang:s,isActive:r,isCurrent:n,classes:l,dialogType:o,setDialogType:d,isDialogOpen:m,newsButtonRef:x,hasNewsDialog:h,isNextJSContext:f,hasJS:g})=>{let b=i()("z-10 flex relative items-center focus-visible:outline-offset-[-3px]","px-8 xl:px-12 py-8","xxs:text-base text-sm xl:text-[calc(1.8rem*var(--base-multiplier))]","underline underline-offset-[0.15em] hover:decoration-stroke-link-hover",{"decoration-transparent decoration-1 hover:decoration-2":!r,"decoration-2":r,"decoration-stroke-link-hover":r&&!m});return(0,a.jsx)("li",{className:i()(l,"flex"),children:h?g?(0,a.jsx)(p.zM,{asChild:!0,children:(0,a.jsx)(ee,{ref:x,text:e,href:t,dialogType:o,isDialogOpen:m,hasNewsDialog:h,anchorClasses:b,...d&&{onClick:()=>d(c.Os.news)}})}):(0,a.jsx)(ee,{ref:x,text:e,href:t,dialogType:o,isDialogOpen:m,hasNewsDialog:h,anchorClasses:b,popoverTarget:"newsPopover",popoverTargetAction:"toggle"}):(0,a.jsx)(j.w,{isNextJSContext:f,route:t,lang:s,isCurrent:n,deferPrefetch:(0,u.Qo)(t),className:i()(b,{"text-black-alpha-500":m}),children:e})})},es=[{text:"News",name:"news",href:"/news"},{text:"Life",name:"life",href:"/life"},{text:"Radio",name:"radio",href:"/radio"},{text:"Podcasts",name:"podcasts",href:"/podcasts"},{text:"Video",name:"video",href:"/video"}],ea=["/national","/concert","/international","/parliament","/programmes","/presenters","/audio"],er=(0,n.forwardRef)(({dialogType:e,setDialogType:t,siteHeaderDialogOpen:s,...r},n)=>(0,a.jsxs)("button",{ref:n,className:i()("xs:gap-8 relative z-10 flex items-center gap-4 leading-relaxed focus-visible:outline-offset-[-3px]","xxs:px-8 xxs:pr-12 xs:px-8 py-8 pl-8 pr-12 xl:px-12","xxs:text-base text-sm xl:text-[calc(1.8rem*var(--base-multiplier))]","hover:decoration-stroke-link-hover underline decoration-transparent decoration-1 underline-offset-[0.15em] hover:decoration-2",{"pointer-events-none":s&&e===c.Os.sections,"!decoration-stroke-link-hover !decoration-2":s&&e===c.Os.sections,"text-black-alpha-500":s&&e!==c.Os.sections}),"aria-label":"Sections navigation",...t&&{onClick:()=>t?.(c.Os.sections)},...r,children:["Sections ",(0,a.jsx)(K,{align:"text"})]}));er.displayName="SectionsButton";let ei=({route:e,routeSection:t,logoSrc:s,currentProgramme:r,siteHeaderDialogOpen:n,dialogType:l,setDialogType:o,setSiteHeaderDialogOpen:d,newsButtonRef:m,sectionsButtonRef:u,pathname:x,isNextJSContext:h,hasJS:f})=>(0,a.jsxs)("nav",{"aria-label":"Primary navigation",className:i()("font-sans-semibold text-foreground-primary flex h-full justify-between"),children:[(0,a.jsxs)("div",{className:"flex",children:[(0,a.jsx)(U,{logoSrc:s,className:"xxs:mr-4 xs:mr-8 mr-8 focus-visible:outline-offset-[-3px] xl:mr-12",imgClassName:"relative z-10",setDialogOpen:d,isNextJSContext:h,forceRefresh:"/"===e||"/"===x}),(0,a.jsxs)("ul",{className:"flex",children:[es.map((s,r)=>("news"==s.name||"life"==s.name)&&(0,a.jsx)(et,{text:s.text,href:s.href,...s.name===t&&{isActive:!0},...s.href===e&&{isCurrent:!0},dialogType:l,setDialogType:o,isDialogOpen:n,newsButtonRef:m,hasNewsDialog:"news"===s.name,isNextJSContext:h,hasJS:f,classes:"hidden sm:flex ml:hidden"},r)),es.map((s,r)=>(0,a.jsx)(et,{text:s.text,href:s.href,...(s.name===t||"radio"===s.name&&ea.includes(`/${t}`))&&{isActive:!0},...s.href===e&&{isCurrent:!0},dialogType:l,setDialogType:o,isDialogOpen:n,newsButtonRef:m,hasNewsDialog:"news"===s.name,isNextJSContext:h,hasJS:f,classes:"ml:flex hidden"},r))]}),(0,a.jsx)("div",{className:"border-stroke-light z-10 mx-8 hidden items-center justify-center self-stretch border-l sm:flex xl:mx-12"}),f?(0,a.jsx)(p.zM,{asChild:!0,children:(0,a.jsx)(er,{ref:u,dialogType:l,setDialogType:o,siteHeaderDialogOpen:n,...o&&{onClick:()=>o?.(c.Os.sections)}})}
1):(0,a.jsx)(er,{ref:u,dialogType:l,popoverTarget:"sectionsPopover",popoverTargetAction:"toggle"})]}),(0,a.jsxs)("div",{className:i()("flex grow justify-end opacity-100 transition-opacity duration-0 ease-in-out",{"!opacity-0":n}),children:[(0,a.jsx)("div",{className:i()({"xxs:flex hidden":f}),children:(0,a.jsx)(j.w,{isNextJSContext:h,route:"/search",ariaLabel:"Search",className:i()("hover:text-foreground-accent [&>svg]:hover:text-foreground-accent [&>svg]:text-foreground-primary flex h-full items-center justify-center focus-visible:outline-offset-[-3px]","xs:w-[calc(4.4rem*var(--base-multiplier))] w-[calc(3.6rem*var(--base-multiplier))] xl:w-64"),children:(0,a.jsx)(q.C,{className:"h-[calc(2rem*var(--base-multiplier))] w-[calc(2rem*var(--base-multiplier))] xl:h-[calc(2.8rem*var(--base-multiplier))] xl:w-[calc(2.8rem*var(--base-multiplier))]"})})}),f&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("div",{className:"border-stroke-light flex items-center justify-center border-l"}),(0,a.jsx)(Y,{pathname:x,currentProgramme:r,className:i()("ml-12 sm:ml-16 xl:ml-24","max-w-[calc(12.8rem*var(--base-multiplier))] sm:max-w-[calc(17.5rem*var(--base-multiplier))] xl:max-w-[calc(21rem*var(--base-multiplier))]")})]})]})]});var en=s(71610),el=s(96171),eo=s(26320);let ec=[{text:"News",subtext:"Pitopito kÅrero",name:"news",primaryLinks:[{text:"Politics",name:"news/politics",route:"/news/politics"},{text:"World",name:"news/world",route:"/news/world"},{text:"Business",name:"news/business",route:"/news/business"},{text:"Personal finance",name:"news/personal-finance",route:"/news/personal-finance"},{text:"Sport",name:"news/sport",route:"/news/sport"},{text:"Crime / Justice",name:"news/crime-and-justice",route:"/news/crime-and-justice"},{text:"Health",name:"news/health",route:"/news/health"},{text:"Education",name:"news/education",route:"/news/education"},{text:"Environment",name:"news/environment",route:"/news/environment"},{text:"Science / Tech",name:"news/science-and-technology",route:"/news/science-and-technology"},{text:"Emergencies",name:"news/emergencies",route:"/news/emergencies"},{text:"Community",name:"news/community",route:"/news/community"},{text:"Regions",name:"news/regions",route:"/news/regions"},{text:"Country",name:"news/country",route:"/news/country"},{text:"Weather",name:"news/weather",route:"/news/weather"}],secondaryLinks:[{text:"Te Ao MÄori",name:"news/te-ao-maori",route:"/news/te-ao-maori"},{text:"Pacific",name:"news/pacific",route:"/news/pacific"},{text:"IndoNZ",name:"news/indonz",route:"/news/indonz"},{text:"䏿",name:"news/chinese",route:"/news/chinese",lang:"zh"}]}],ed=[{text:"Life",subtext:"Tauoranga",name:"life",primaryLinks:[{text:"Browse all",name:"life",route:"/life"},{text:"Screens",name:"life/screens",route:"/life/screens"},{text:"Books",name:"life/books",route:"/life/books"},{text:"Culture",name:"life/culture",route:"/life/culture"},{text:"Music",name:"life/music",route:"/life/music"},{text:"Food",name:"life/food",route:"/life/food"},{text:"Wellbeing",name:"life/wellbeing",route:"/life/wellbeing"},{text:"Lifestyle",name:"life/lifestyle",route:"/life/lifestyle"},{text:"Relationships",name:"life/relationships",route:"/life/relationships"},{text:"People",name:"life/people",route:"/life/people"}]}],em=[{text:"Radio",subtext:"Irirangi",name:"radio"}],eu=[{text:"Podcasts",subtext:"KÅnae ipurangi",name:"podcasts",route:"/podcasts"},{text:"Video",subtext:"Ataata",name:"video",route:"/video"},{text:"Storytime",subtext:"Puna tamariki",name:"storytime",route:"/storytime"}],ex=({latestBulletin:e,setDialogOpen:t,onPlayAudio:s,route:r,isNextJSContext:i,pathname:n,hasJS:l})=>{let{items:o,set:d}=(0,v.M)(),{setPlayerSize:m,setPlayerTab:u}=(0,en.h)(),{national:x}=w.ai,h=c.Os.sections,p=()=>{s?.(),m("expanded"),u("detail"),0===o.length&&d([{...x,qid:"1"}])};return(0,a.jsxs)("nav",{children:[(0,a.jsx)("div",{className:"xxs:hidden",children:(0,a.jsxs)(j.w,{route:"/search",isNextJSContext:i,handleClick:()=>t?.(!1),className:"underline-brand-hover border-stroke-strong flex items-center justify-between gap-8 border-b-2 py-16 !decoration-transparent",children:[(0,a.jsxs)("div",{className:"flex items-center gap-8",children:[(0,a.jsx)(q.C,{align:"text"}),(0,a.jsx)("span",{className:"font-sans-semibold",children:"Search all of RNZ"}),(0,a.jsx)("span",{className:"text-foreground-secondary",lang:"mi",children:"Rapua"})]}),(0,a.jsx)(el.h,{align:"text"})]})}),(0,a.jsxs)("div",{className:"xs:grid-cols-2 grid gap-x-24 lg:grid-cols-4",children:[ec.map(e=>(0,a.jsx)(z,{section:e,columns:3,route:r,dialogType:h,setDialogOpen:t,isNextJSContext:i,hasJS:l,className:"ml:col-span-2 col-span-full",secondaryLinksAriaLabel:"Community news services",secondaryLinksClassName:"border-stroke-light xxs:flex xxs:justify-between xs:block xxs:columns-1 xs:border-0 columns-2 gap-16 border-t"},e.text)),ed.map(e=>(0,a.jsx)(z,{section:e,columns:2,route:r,dialogType:h,setDialogOpen:t,isNextJSContext:i,hasJS:l},e.text)),em.map(e=>(0,a.jsx)(z,{section:e,route:r,dialogType:h,setDialogOpen:t,isNextJSContext:i,hasJS:l,children:(0,a.jsx)(P,{dialogType:c.Os.sections,section:e,hasListenMoreLink:!0,pathname:n??"",onPlayAudio:s,setDialogOpen:t,isNextJSContext:i,hasJS:l,className:"xs:py-8 py-16"})},e.text))]}),(0,a.jsxs)("div",{className:"xs:grid-cols-4 grid grid-cols-2 gap-x-24",children:[eu.map(e=>(0,a.jsx)("div",{children:(0,a.jsx)(D,{...e,isCurrent:e.route===r,setDialogOpen:t,isNextJSContext:i,hasJS:l})},e.text)),l&&(0,a.jsxs)("div",{className:"@container font-sans-semibold xs:justify-end border-surface-inverse inline-flex w-full items-center gap-12 border-b-2 py-16",children:[e&&(0,a.jsx)("div",{className:"@[15.31em]:block hidden",children:(0,a.jsx)(A.LatestBulletinTrigger,{dialogType:c.Os.sections,media:e,pathname:n,onPlayAudio:s})}),(0,a.jsx)("div",{className:"@[6.87em]:hidden block",children:(0,a.jsx)(L.$n,{size:"sm",theme:"base",iconPosition:"suffix",icon:(0,a.jsx)(eo.X,{align:"text"}),content:"Player",onClick:p})}),(0,a.jsx)("div",{className:"@[6.87em]:block hidden",children:(0,a.jsx)(L.$n,{size:"sm",theme:"base",iconPosition:"suffix",icon:(0,a.jsx)(eo.X,{align:"text"}),content:"Show player",onClick:p})})]})]})]})};
1var eh=s(67878),ep=s(51162),ef=s(40531);let eg=({logoSrc:e,setDialogOpen:t,isNextJSContext:s})=>{let r="opacity-100 transition-opacity duration-[500ms] [@starting-style]:opacity-0 ease-in-out";return(0,a.jsx)(h.m,{withNoVertPadding:!0,className:"pointer-events-none absolute h-full w-full *:h-full",children:(0,a.jsxs)("div",{className:"relative h-full",children:[(0,a.jsx)("div",{className:i()("xl:hidden",r),children:(0,a.jsx)(p.HM,{asChild:!0,children:(0,a.jsx)(L.$n,{size:"sm",theme:"base",iconPosition:"suffix",icon:(0,a.jsx)(ef.k,{align:"text"}),content:"Close","aria-label":"Close navigation",className:i()("xxs:bottom-[calc(100%+1.6rem*var(--base-multiplier))] absolute bottom-[calc(100%+1rem*var(--base-multiplier))] right-0","pointer-events-auto after:absolute after:-inset-8 after:block")})})}),(0,a.jsx)("div",{className:i()("hidden xl:block",r),children:(0,a.jsx)(p.HM,{asChild:!0,children:(0,a.jsx)(L.$n,{size:"md",theme:"base",iconPosition:"suffix",icon:(0,a.jsx)(ef.k,{align:"text"}),content:"Close","aria-label":"Close navigation",className:i()("absolute bottom-[calc(100%+1.6rem*var(--base-multiplier))] right-0","pointer-events-auto after:absolute after:-inset-8 after:block")})})}),(0,a.jsx)(U,{logoSrc:e,className:"xxs:bottom-[calc(100%+1.05rem*var(--base-multiplier))] pointer-events-auto absolute bottom-[calc(100%+0.9rem*var(--base-multiplier))] left-0",imgClassName:"opacity-0",setDialogOpen:t,isNextJSContext:s})]})})},eb=({logoSrc:e,latestBulletin:t,dialogType:s,dialogOpen:r,setDialogOpen:l,container:o,newsButtonRef:d,sectionsButtonRef:u,route:x,pathname:f,isNextJSContext:g,hasJS:b})=>{let j={initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2,ease:"easeInOut"}},{focusPlayer:y}=(0,v.M)(),{playTrigger:w,setPlayTrigger:N}=(0,m.x)(),[C,L]=(0,n.useState)(!1),k=s===c.Os.news?d:u,A=()=>{k&&N(k.current),l(!1)};return(0,n.useEffect)(()=>{L(!0)},[C]),(0,n.useEffect)(()=>{C&&(r?N(null):!r&&w&&k.current&&w===k.current?y():k.current?.focus())},[r]),(0,a.jsx)(p.ZJ,{forceMount:!0,container:o,children:(0,a.jsx)(eh.N,{children:r&&(0,a.jsxs)(p.LC,{className:"fixed inset-0",children:[(0,a.jsx)(ep.P.div,{...j,className:"z-modal-overlay bg-white-alpha-200 absolute inset-0 backdrop-blur-[2px]"}),(0,a.jsx)(ep.P.div,{...j,className:i()("z-modal absolute inset-0","xxs:!top-[calc(5.5rem*var(--base-multiplier))] !top-[calc(4.3rem*var(--base-multiplier))] xl:!top-[calc(6.3rem*var(--base-multiplier))]","xxs:max-h-[calc(100dvh-5.5rem*var(--base-multiplier))] max-h-[calc(100dvh-4.3rem*var(--base-multiplier))] xl:max-h-[calc(100dvh-6.3rem*var(--base-multiplier))]"),children:(0,a.jsxs)(p.Cf,{onCloseAutoFocus:e=>{e.preventDefault()},className:"border-stroke-light xs:h-auto bg-surface-primary text-foreground-primary relative flex h-full max-h-full w-full flex-col border-y",children:[(0,a.jsx)(eg,{logoSrc:e,setDialogOpen:l,isNextJSContext:g}),(0,a.jsxs)(J.FK,{className:"flex flex-col",children:[(0,a.jsx)(J.Br,{children:(0,a.jsx)(h.m,{withNoVertPadding:!0,className:"pb-24 pt-8",children:s===c.Os.news?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(p.L3,{className:"sr-only",children:"News navigation links"}),(0,a.jsx)(B,{latestBulletin:t,onPlayAudio:A,setDialogOpen:l,route:x,pathname:f,isNextJSContext:g,hasJS:b})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(p.L3,{className:"sr-only",children:"Sections navigation links"}),(0,a.jsx)(ex,{latestBulletin:t,onPlayAudio:A,setDialogOpen:l,route:x,pathname:f,isNextJSContext:g,hasJS:b})]})})}),(0,a.jsx)(J.VM,{orientation:"vertical",className:"hover:bg-surface-muted bg-surface-muted",children:(0,a.jsx)(J.lr,{className:"bg-grey-500"})})]})]})})]})})})},ej=({route:e,logoSrc:t="/assets/logos/rnz-logo.svg",currentProgramme:s,latestBulletin:r,isNextJSContext:f,children:g})=>{let[b,j]=(0,n.useState)(null),[v,y]=(0,n.useState)(),[w,N]=(0,n.useState)(null),C=(0,n.useRef)(null),L=(0,n.useRef)(null),{siteHeaderDialogOpen:k,setSiteHeaderDialogOpen:A}=(0,m.x)(),S=(0,x.m)(),M=(0,o.Ub)(`(min-width: ${(0,d.s)("sm")})`),P=window.location.pathname,E=(0,l.usePathname)(),V=(0,u.hp)({route:e,pathname:E,isNextJSContext:f}),H=(0,u.hm)({segmentIndex:1,route:e,pathname:E,isNextJSContext:f});return(0,n.useEffect)(()=>{!M&&k&&w===c.Os.news&&A(!1)},[M]),(0,n.useEffect)(()=>{let e=document.querySelector("rnz-site-header");e&&y(e)},[]),(0,n.useEffect)(()=>{v&&(k?v.style.zIndex="10010":v.style.zIndex="")},[v,k]),(0,a.jsxs)("div",{className:i()("sticky top-0 print:hidden",k?"z-header-open":"z-header"),children:[g,(0,a.jsx)("header",{className:i()("border-stroke-light bg-surface-primary border-b","h-[var(--nav-height)]"),children:(0,a.jsxs)(h.m,{withNoVertPadding:!0,className:"h-full *:h-full",children:[(0,a.jsxs)(p.lG,{open:k,onOpenChange:e=>{A(e)},children:[(0,a.jsx)(ei,{route:V,routeSection:H,logoSrc:t,currentProgramme:s,siteHeaderDialogOpen:k,dialogType:w,setDialogType:N,setSiteHeaderDialogOpen:A,newsButtonRef:C,sectionsButtonRef:L,pathname:E??P,isNextJSContext:f,hasJS:S}),(0,a.jsx)(eb,{latestBulletin:r,logoSrc:t,container:b,newsButtonRef:C,sectionsButtonRef:L,dialogType:w,dialogOpen:k,setDialogOpen:A,route:V,pathname:E??P,isNextJSContext:f,hasJS:S})]}),(0,a.jsx)("div",{className:"m-0",ref:j}),(0,a.jsxs)("noscript",{children:[(0,a.jsx)($,{id:"sectionsPopover",ariaLabel:"Sections navigation",children:(0,a.jsx)(ex,{setDialogOpen:A,route:e,pathname:E??P,isNextJSContext:f,hasJS:S})}),(0,a.jsx)($,{id:"newsPopover",ariaLabel:"News navigation",children:(0,a.jsx)(B,{setDialogOpen:A,route:e,pathname:E??P,isNextJSContext:f,hasJS:S})})]})]})})]})}},67918:(e,t,s)=>{"use strict";s.d(t,{o:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:"text"===e?(0,a.jsx)("path",{d:"M6.36396 7.2395L7.52104 7.2395L13.885 13.6035L12.7279 14.7605L6.9425 8.97513L1.15708 14.7605L-1.11271e-06 13.6035L6.36396 7.2395Z"}):(0,a.jsx)("path",{d:"M10.9216 7.2395L12.0787 7.2395L18.4426 13.6035L17.2855 14.7605L11.5001 8.97513L5.7147 14.7605L4.55762 13.6035L10.9216 7.2395Z"})})},70982:(e,t,s)=>{"use strict";s.d(t,{LatestBulletinTrigger:()=>f});
1var a=s(41657),r=s(48237),i=s(30128),n=s(13941),l=s(96507),o=s(34627),c=s(95091),d=s(81685),m=s(29674),u=s(17629),x=s(10711),h=s(29311),p=s(73400);let f=({dialogType:e,hasLongBulletinText:t,media:s,pathname:f,onPlayAudio:g})=>{let b=(0,i.DE)(),{items:j,marker:v,insertAt:y,setMarker:w}=(0,l.M)(),{play:N,pause:C,isPlaying:L,setCurrentGlobalPid:k}=(0,o.E)(),A=s?.id===j[v]?.id,S=A&&L,M=x.U6.images,P=(0,x.UU)(s),E=(()=>{if(!s.releaseDate)return null;let e=(0,c.A)(s.releaseDate);return(0,d.A)(e,"haaa")})(),V=()=>s.releaseDate?`${E} news${t?" bulletin":""}`:`News${t?" bulletin":""}`,H=S?"Pause":"Play";return b?(0,a.jsx)(r.Suspense,{fallback:(0,a.jsx)(a.Fragment,{}),children:(0,a.jsx)(h.$n,{size:"sm",theme:e===u.Os.news?"base":"secondary",iconPosition:"prefix",icon:(0,a.jsx)(p.n,{isPlaying:S,align:"text"}),content:e===u.Os.news?H:V(),...s.duration&&(!e||e===u.Os.sections||e===u.Os.news&&!L)&&{secondaryText:(0,m.Sy)(s.duration)},"aria-label":e===u.Os.news?`${H} headlines${E?` at ${E}`:""}${s.duration?`, ${(0,m.RO)(s.duration)}`:""}`:`${H} ${V()}${s.duration?`, ${(0,m.RO)(s.duration)}`:""}`,onClick:()=>{if(!A){let e;y(e=0===j.length?0:v+1,{...s,images:M,themeColors:P,playbackBeginUrl:f,qid:(0,n.Ak)()}),w(e),k(),N(),g?.();return}S?C():(k(),N(),g?.())}})}):null}},71537:(e,t,s)=>{"use strict";s.d(t,{r:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:"text"===e?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M7.5208 15.7605L6.36372 15.7605L-0.000239929 9.39654L1.15684 8.23945L6.94226 14.0249L12.7277 8.23945L13.8848 9.39654L7.5208 15.7605Z"})}):(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M12.0784 14.7606L10.9213 14.7606L4.55738 8.3966L5.71446 7.23951L11.4999 13.0249L17.2853 7.23951L18.4424 8.3966L12.0784 14.7606Z"})})})},74271:(e,t,s)=>{"use strict";s.d(t,{A:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M6.00044 11.5785L6.00044 10.4215L12.3644 4.0575L13.5215 5.21458L7.73607 11L13.5215 16.7854L12.3644 17.9425L6.00044 11.5785Z"}),(0,a.jsx)("path",{d:"M0.0004402 11.5785L0.000440301 10.4215L6.3644 4.0575L7.52149 5.21458L1.73607 11L7.52148 16.7854L6.3644 17.9425L0.0004402 11.5785Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M9.7397 11.5785L9.7397 10.4215L16.1037 4.0575L17.2607 5.21458L11.4753 11L17.2607 16.7854L16.1037 17.9425L9.7397 11.5785Z"}),(0,a.jsx)("path",{d:"M3.7397 11.5785L3.7397 10.4215L10.1037 4.0575L11.2607 5.21458L5.47532 11L11.2607 16.7854L10.1037 17.9425L3.7397 11.5785Z"})]})})},77154:(e,t,s)=>{"use strict";s.d(t,{Ke:()=>c,Nt:()=>l,R6:()=>o});var a=s(41657),r=s(48237),i=s(6501),n=s(91502);let l=r.forwardRef(({className:e,...t},s)=>(0,a.jsx)(n.bL,{ref:s,className:(0,i.cn)(e),...t}));l.displayName=n.bL.displayName;let o=n.R6,c=r.forwardRef(({className:e,animationType:t="height",...s},r)=>(0,a.jsx)(n.Ke,{ref:r,"data-animation-type":t,className:(0,i.cn)("collapsible-content","height"===t&&"overflow-hidden",e),...s}));c.displayName=n.Ke.displayName},77661:(e,t,s)=>{"use strict";s.d(t,{C:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?15:22,height:22,className:t,children:"text"===e?(0,a.jsx)("path",{d:"M10.667 10.333C10.6668 7.83951 8.64493 5.81836 6.15137 5.81836C3.65797 5.81855 1.63689 7.83963 1.63672 10.333C1.63672 12.8265 3.65786 14.8484 6.15137 14.8486C8.64504 14.8486 10.667 12.8266 10.667 10.333ZM12.3037 10.333C12.3037 11.7366 11.8314 13.0293 11.04 14.0645L13.3965 16.4219L13.9756 17L12.8184 18.1572L12.2402 17.5781L9.88281 15.2217C8.84767 16.013 7.55493 16.4844 6.15137 16.4844C2.75413 16.4842 0 13.7303 0 10.333C0.000171874 6.93588 2.75424 4.18183 6.15137 4.18164C9.54866 4.18164 12.3035 6.93576 12.3037 10.333Z",fill:"currentColor"}):(0,a.jsx)("path",{d:"M14.6357 10.3635C14.6357 8.0038 12.723 6.09106 10.3633 6.09106C8.00359 6.09111 6.09087 8.00383 6.09082 10.3635C6.09082 12.7233 8.00356 14.6359 10.3633 14.636C12.723 14.636 14.6357 12.7233 14.6357 10.3635ZM16.2725 10.3635C16.2725 11.7001 15.8273 12.9321 15.0791 13.9221L17.8838 16.7268L16.7266 17.884L13.9219 15.0793C12.9319 15.8276 11.6999 16.2727 10.3633 16.2727C7.09982 16.2727 4.4541 13.627 4.4541 10.3635C4.45415 7.1001 7.09985 4.45439 10.3633 4.45435C13.6268 4.45435 16.2724 7.10006 16.2725 10.3635Z",fill:"currentColor"})})},78865:(e,t,s)=>{"use strict";s.d(t,{V:()=>o});
1var a=s(41657),r=s(19155),i=s(675),n=s.n(i),l=s(17629);let o=({className:e,liveStreamName:t,isDarkContext:s,size:i="default",headingLevel:o=2})=>{let c=n()("inline-flex items-center whitespace-nowrap uppercase leading-none",{"px-[calc(0.3rem*var(--base-multiplier))] pt-[calc(0.2rem*var(--base-multiplier))] pb-[calc(0.15rem*var(--base-multiplier))] text-xs leading-snug":"sm"===i,"px-4 pb-[calc(0.3rem*var(--base-multiplier))] pt-2 text-sm tracking-wider":"default"===i,"px-[.2em] py-4 text-lg":"lg"===i});return(0,a.jsxs)(r.D,{level:o,className:n()("inline-flex",e),children:[(0,a.jsx)("span",{className:n()(c,"bg-surface-inverse text-foreground-inverse",{"dark-theme":s,"light-theme":!s,"font-sans-semibold":"sm"===i,"font-sans-extrabold":"sm"!==i}),children:"RNZ"}),t&&(0,a.jsx)("span",{className:n()(c,"font-sans-semibold text-white",{"bg-station-national-primary":t===l.UZ.national,"bg-station-concert-primary":t===l.UZ.concert,"bg-station-pacific-primary":t===l.UZ.pacific,"bg-station-parliament-primary !text-station-parliament-secondary":t===l.UZ.parliament}),children:t})]})}},79578:(e,t,s)=>{"use strict";s.d(t,{i:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?15:22,height:22,className:t,children:"text"===e?(0,a.jsx)("path",{d:"M15 16.4365L14.417 17.4277H1.07324L0.490234 16.4365L7.16211 4.42773H8.32812L15 16.4365ZM7.74512 13.4365C7.19283 13.4365 6.74512 13.8842 6.74512 14.4365C6.74515 14.9888 7.19285 15.4365 7.74512 15.4365C8.29738 15.4365 8.74508 14.9888 8.74512 14.4365C8.74512 13.8842 8.2974 13.4365 7.74512 13.4365ZM6.91211 8.09375V12.5938H8.5791V8.09375H6.91211Z"}):(0,a.jsx)("path",{d:"M18.2549 16.4365L17.6719 17.4277H4.32812L3.74512 16.4365L10.417 4.42773H11.583L18.2549 16.4365ZM11 13.4365C10.4477 13.4365 10 13.8842 10 14.4365C10 14.9888 10.4477 15.4365 11 15.4365C11.5523 15.4365 12 14.9888 12 14.4365C12 13.8842 11.5523 13.4365 11 13.4365ZM10.167 8.09375V12.5938H11.834V8.09375H10.167Z"})})},79594:(e,t,s)=>{"use strict";s.d(t,{Cf:()=>d,HM:()=>u,L3:()=>m,LC:()=>c,ZJ:()=>o,lG:()=>n,zM:()=>l});var a=s(41657),r=s(48237),i=s(16629);let n=({...e})=>((0,r.useEffect)(()=>{document.documentElement?.style.setProperty("--page-scrollbar-width","0px")},[]),(0,r.useEffect)(()=>{document.documentElement.querySelector("body")?.style.setProperty("--page-scrollbar-width","var(--removed-body-scroll-bar-size, 0px)")},[e.open]),(0,a.jsx)(i.bL,{...e}));n.displayName=i.bL.displayName;let l=r.forwardRef(({...e},t)=>(0,a.jsx)(i.l9,{...e,ref:t}));l.displayName=i.l9.displayName;let o=({...e})=>(0,a.jsx)(i.ZL,{...e,container:e.container?e.container:document.getElementById("dialog-root")});o.displayName=i.ZL.displayName;let c=r.forwardRef(({...e},t)=>(0,a.jsx)(i.hJ,{...e,ref:t,style:{marginRight:"var(--page-scrollbar-width)"}}));c.displayName=i.hJ.displayName;let d=r.forwardRef(({...e},t)=>(0,a.jsx)(i.UC,{...e,ref:t,"aria-describedby":void 0}));d.displayName=i.UC.displayName;let m=r.forwardRef(({...e},t)=>(0,a.jsx)(i.hE,{...e,ref:t}));m.displayName=i.hE.displayName;let u=r.forwardRef(({...e},t)=>(0,a.jsx)(i.bm,{...e,ref:t}));u.displayName=i.bm.displayName},79984:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/apple-touch-icon.3fb10969.png",height:180,width:180,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAG1BMVEXaHybiU1nsj5Lpen/eOkDunJ/dMznqgYX3z9FI1cmzAAAACXBIWXMAAA1JAAANSQGKhkvfAAAALUlEQVR4nDXLwREAMAgCQRCM9l9xZjThtY8DAEjMXDoDZnmQ0R+xEUML68V7vw5gAF4JqApVAAAAAElFTkSuQmCC",blurWidth:8,blurHeight:8}},80065:(e,t,s)=>{"use strict";s.d(t,{u:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?12:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M6.75 5.25V17.25H5.25V5.25H6.75Z"}),(0,a.jsx)("path",{d:"M0 10.5H12V12H0V10.5Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M11.8125 4.5V17.5H10.1875V4.5H11.8125Z"}),(0,a.jsx)("path",{d:"M4.5 10.1875H17.5V11.8125H4.5V10.1875Z"})]})})},83873:(e,t,s)=>{"use strict";s.d(t,{SubNavigation:()=>p});
1var a=s(41657),r=s(675),i=s.n(r),n=s(45575),l=s(17980),o=s(55223),c=s(64252);let d=[{text:"World",name:"news/world",route:"/news/world"},{text:"Politics",name:"news/politics",route:"/news/politics"},{text:"Crime / Justice",name:"news/crime-and-justice",route:"/news/crime-and-justice"},{text:"Business",name:"news/business",route:"/news/business"},{text:"Sport",name:"news/sport",route:"/news/sport"},{text:"Health",name:"news/health",route:"/news/health"},{text:"Education",name:"news/education",route:"/news/education"},{text:"Environment",name:"news/environment",route:"/news/environment"},{text:"Community",name:"news/community",route:"/news/community"},{text:"Country",name:"news/country",route:"/news/country"},{text:"Weather",name:"news/weather",route:"/news/weather"},{text:"Te Ao MÄori",name:"news/te-ao-maori",route:"/news/te-ao-maori"},{text:"Pacific",name:"news/pacific",route:"/news/pacific"},{text:"IndoNZ",name:"news/indonz",route:"/news/indonz"},{text:"䏿",name:"news/chinese",route:"/news/chinese",lang:"zh"}],m={politics:["political"],"te-ao-maori":["te-manu-korihi"]},u=e=>e.split("/")[2],x=(e,t)=>{if(!t)return!1;let s=t.split("_")[0];if(e===s)return!0;let a=m[e];return!!a&&a.includes(s)},h=new Set([...d.map(e=>e.route.split("/")[2]),...Object.values(m).flat()]),p=({route:e,isNextJSContext:t,forceShow:s})=>{let r=(e=>{if(!e)return e;let t=e.split("/"),s=t[3]?.split("_")[0];return"news"===t[1]&&s&&h.has(s)?(t.splice(2,1),t.join("/")):e})((0,n.usePathname)()),m=(0,c.hp)({route:e,pathname:r,isNextJSContext:t}),p=s=>(0,c.hm)({segmentIndex:s,route:e,pathname:r,isNextJSContext:t}),f=p(1),g=p(2),b="news"===f,j=()=>b||s?d:null;return j()&&(0,a.jsx)(l.m,{bleedsRight:!0,withNoVertPadding:!0,className:"border-stroke-light bg-surface-primary relative z-10 border-b print:hidden",children:(0,a.jsx)("nav",{"aria-label":"Sub navigation",className:"flex overflow-x-auto pr-16 text-sm md:pr-32",children:(0,a.jsx)("div",{className:"-mx-8 flex flex-shrink-0",children:(0,a.jsx)("ul",{className:"flex",children:j()?.map(e=>{var s;let r;return(0,a.jsx)("li",{className:"flex",children:(0,a.jsx)(o.w,{route:e.route,isCurrent:(({linkRoute:e,currentRoutePath:t,currentSubsection:s})=>{let a=u(e),r=3===t.split("/").length;return!!(a&&x(a,s))&&!!r||t===e})({linkRoute:e.route,currentRoutePath:m,currentSubsection:g}),isNextJSContext:t,lang:e.lang,className:i()("px-8 py-12 focus-visible:outline-offset-[-3px]","hover:decoration-stroke-link-hover underline decoration-transparent decoration-1 underline-offset-[0.15em] hover:decoration-2",{"!decoration-stroke-accent":(s=e.route,!!(r=u(s))&&x(r,g))}),children:e.text})},e.name)})})})})})}},85458:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a={src:"/_next/static/media/safari-pinned-tab.8808ba28.svg",height:933,width:933,blurWidth:0,blurHeight:0}},95832:(e,t,s)=>{"use strict";s.d(t,{ReferrerProvider:()=>l,j:()=>n});var a=s(41657),r=s(48237),i=s(45575);let n=(0,r.createContext)(null);function l({children:e}){let t=(0,i.usePathname)(),s=(0,r.useRef)(null);return(0,r.useEffect)(()=>{s.current=window.location.origin+t},[t]),(0,a.jsx)(n.Provider,{value:s.current,children:e})}},96171:(e,t,s)=>{"use strict";s.d(t,{h:()=>i});var a=s(41657),r=s(58478);let i=({align:e,className:t})=>(0,a.jsx)(r.h,{align:e,width:"text"===e?12:22,height:22,className:t,children:"text"===e?(0,a.jsx)("path",{d:"M9.71165 10.7514L5.96708 7.00588L7.00342 5.96954L12 10.9671L12 12.0034L7.00342 17L5.96708 15.9637L9.71356 12.2172L5.70346e-08 12.2172L7.45137e-08 10.7514L9.71165 10.7514Z"}):(0,a.jsx)("path",{d:"M14.7116 9.78187L10.9671 6.03634L12.0034 5L17 9.99753L17 11.0339L12.0034 16.0305L10.9671 14.9941L14.7136 11.2476L5 11.2476L5 9.78187L14.7116 9.78187Z"})})},99726:(e,t,s)=>{"use strict";s.d(t,{QueuePlayer:()=>eQ});var a=s(41657),r=s(30128),i=s(64121),n=s(48237),l=s(5451),o=s(67878),c=s(51162),d=s(34627),m=s(71610),u=s(96507),x=s(75182),h=s(6501),p=s(79578),f=s(19306),g=s(58478);let b=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:(0,a.jsx)(a.Fragment,{children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M7 5.27273C3.83691 5.27273 1.27273 7.83691 1.27273 11C1.27273 14.1631 3.83691 16.7273 7 16.7273C10.1631 16.7273 12.7273 14.1631 12.7273 11C12.7273 7.83691 10.1631 5.27273 7 5.27273ZM0 11C0 7.13401 3.13401 4 7 4C10.866 4 14 7.13401 14 11C14 14.866 10.866 18 7 18C3.13401 18 0 14.866 0 11Z"}),(0,a.jsx)("path",{d:"M7.75879 8.27319C7.75879 8.70306 7.41031 9.05154 6.98044 9.05154H6.97195C6.54208 9.05154 6.1936 8.70306 6.1936 8.27319C6.1936 7.84332 6.54208 7.49484 6.97195 7.49484H6.98044C7.41031 7.49484 7.75879 7.84332 7.75879 8.27319Z"}),(0,a.jsx)("path",{d:"M6.20209 14.5L6.20209 9.82989H7.75879L7.75879 14.5H6.20209Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M11 5.27273C7.83691 5.27273 5.27273 7.83691 5.27273 11C5.27273 14.1631 7.83691 16.7273 11 16.7273C14.1631 16.7273 16.7273 14.1631 16.7273 11C16.7273 7.83691 14.1631 5.27273 11 5.27273ZM4 11C4 7.13401 7.13401 4 11 4C14.866 4 18 7.13401 18 11C18 14.866 14.866 18 11 18C7.13401 18 4 14.866 4 11Z"}),(0,a.jsx)("path",{d:"M11.7588 8.27319C11.7588 8.70306 11.4103 9.05154 10.9804 9.05154H10.972C10.5421 9.05154 10.1936 8.70306 10.1936 8.27319C10.1936 7.84332 10.5421 7.49484 10.972 7.49484H10.9804C11.4103 7.49484 11.7588 7.84332 11.7588 8.27319Z"}),(0,a.jsx)("path",{d:"M10.2021 14.5L10.2021 9.82989H11.7588L11.7588 14.5H10.2021Z"})]})})});var j=s(40531),v=s(29311),y=s(51318),w=s(90185),N=s(59638);let C=(0,w.vt)((0,N.persistNSync)(e=>({error:null,messages:[],addMessage:t=>e(e=>({messages:[t,...e.messages]})),clearMessages:()=>e({messages:[]}),setError:t=>e({error:t}),clearError:()=>e({error:null})}
1),{name:"queue-player-messages"})),L=({type:e,title:t,message:s,clearError:r})=>{let[i,l]=n.useState(!1);return(0,n.useEffect)(()=>{l(!0);let e=setTimeout(()=>{l(!1)},100);return()=>clearTimeout(e)},[s]),(0,a.jsxs)("div",{role:"status","aria-live":"polite",className:(0,h.cn)("text-foreground-primary absolute bottom-0 z-20 flex w-full items-center gap-8 px-8 pb-16 pt-8 transition-transform",{"scale-[1.02]":i,"bg-signal-error":"error"===e,"bg-signal-affirm dark-theme":"success"==e,"bg-signal-warning":"warning"===e}),children:["error"===e?(0,a.jsx)(p.i,{className:"h-24 w-24"}):"success"===e?(0,a.jsx)(f.d,{className:"h-[calc(2rem*var(--base-multiplier))] w-[calc(2rem*var(--base-multiplier))]"}):(0,a.jsx)(b,{className:"h-24 w-24"}),(0,a.jsxs)("div",{className:"text-sm leading-none",children:[(0,a.jsx)("h3",{className:(0,h.cn)("font-sans-semibold mb-2",!t&&"sr-only"),children:t||e}),(0,a.jsx)("div",{className:"mb-4",children:(0,a.jsx)(y.default,{text:s})})]}),r&&(0,a.jsx)(v.$n,{size:"iconMd",theme:"iconGhost",context:"success"===e?"dark":"light",iconPosition:"only",icon:(0,a.jsx)(j.k,{}),"aria-label":"Dismiss message",className:"absolute right-8 top-2",onClick:()=>r()})]})},k=()=>{let{clearMessages:e,messages:t}=C();(0,n.useEffect)(()=>{let t=setTimeout(()=>{e()},5e3);return()=>clearTimeout(t)},[e,t]);let s=t?.[0]??null;return s?(0,a.jsxs)(a.Fragment,{children:["warning"===s.type&&(0,a.jsx)(L,{type:"warning",message:t?.[0]?.message,pulse:!0}),"success"===s.type&&(0,a.jsx)(L,{type:"success",message:t?.[0]?.message,pulse:!0})]}):null},A=({className:e})=>{let{error:t,messages:s,clearError:r}=C();return(0,a.jsx)(o.N,{children:(t??s.length>0)&&(0,a.jsx)(c.P.div,{className:(0,h.cn)(e),...{initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0}},children:t?(0,a.jsx)(L,{type:"error",title:"There was a problem with playback.",message:"Please check your connection and try again.",clearError:r}):(0,a.jsx)(k,{})})})};var S=s(67918),M=s(74271);let P=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?13:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M0 4.96532L0.852314 4.5L8.73092 10.5347V11.4653L0.852314 17.5L0 17.0347V4.96532Z"}),(0,a.jsx)("path",{d:"M12.0694 5.25433V17.3237H10.5607V5.25433H12.0694Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M4.96484 4.96532L5.81716 4.5L13.6958 10.5347V11.4653L5.81716 17.5L4.96484 17.0347V4.96532Z"}),(0,a.jsx)("path",{d:"M17.0342 5.25433V17.3237H15.5255V5.25433H17.0342Z"})]})});var E=s(73400),V=s(79594),H=s(53705),R=s(10711),Z=s(32292);let D=e=>{let{audioCurrentTime:t}=(0,d.E)(),{state:s,send:a,subscribe:r}=(0,Z.D)("audio-seek-channel",{type:"seekTo",value:0},{subscribe:!0});return(0,n.useEffect)(()=>{let s=r(s=>{if(e.current)switch(s.type){case"seekTo":e.current.currentTime=s.value;break;case"seekBy":e.current.currentTime=t+s.value}});return()=>s()},[e,r,t]),{seekTo:(0,n.useCallback)(e=>{try{a({type:"seekTo",value:e})}catch(e){if(e instanceof Error&&e.message.includes("Channel is closed"))return void console.warn("Audio seek channel was closed, seek command ignored");throw e}},[a]),seekBy:(0,n.useCallback)(e=>{try{a({type:"seekBy",value:e})}catch(e){if(e instanceof Error&&e.message.includes("Channel is closed"))return void console.warn("Audio seek channel was closed, seek command ignored");throw e}},[a]),currentSeekEvent:s}};var z=s(45885),T=s(17629);let O=()=>{let{audioCurrentTime:e,audioDuration:t,play:s,isPlaying:r}=(0,d.E)(),{seekTo:i}=D({current:null}),n=t-e>=T.vN;return(0,a.jsx)(v.$n,{onClick:()=>{r||s(),i(t-5)},isDisabled:!n,iconPosition:"suffix",icon:(0,a.jsx)(z.s,{align:"text"}),theme:"base",size:"sm",context:"dark",content:"Live","aria-label":"Skip to live"})};var F=s(29674);let I=({currentTime:e=0,duration:t=0,className:s,theme:r="dark",isLarge:i,hasMinWidth:n})=>(0,a.jsxs)("div",{className:(0,h.cn)("font-sans-normal text-foreground-primary flex justify-center gap-2",{"text-xs":!i,"text-sm":i,"light-theme":"light"===r,"dark-theme":"dark"===r},s),children:[(0,a.jsx)("time",{dateTime:(0,F.zA)(e),className:(0,h.cn)("text-right tabular-nums",{"min-w-48":n}),children:(0,F.fU)(e)}),(0,a.jsx)("span",{className:(0,h.cn)(i?"text-stroke-accent mx-4":"text-grey-100"),children:"/"}),(0,a.jsx)("time",{dateTime:(0,F.zA)(t),className:(0,h.cn)("text-left tabular-nums",i?"text-grey-500":"text-grey-100",{"min-w-48":n}),children:isFinite(t)&&!isNaN(t)?(0,F.fU)(t):(0,F.fU)(0)})]}),B=({canFocusPlayer:e,hasPlayerComponentsMounted:t,setHasPlayerComponentsMounted:s,handleNextItem:r,currentTrack:i,progressBar:l,isPlaying:o,play:c,pause:x})=>{let{items:p,marker:f}=(0,u.M)(),{audioCurrentTime:g,audioDuration:b}=(0,d.E)(),{setPlayerSize:y}=(0,m.h)(),w=(0,R.pz)(i),{setExpandButtonRef:N}=(0,d.x)(),C=(0,n.useRef)(null);(0,n.useEffect)(()=>{s&&s(!0)},[]),(0,n.useEffect)(()=>{t&&C.current&&N(C.current)},[t]);let{seekBy:L}=D({current:null}),k=!!i.liveStreamName;return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:(0,h.cn)("bg-surface-muted border-stroke-light focus-outline-alt dark-theme text-foreground-primary relative border-l border-t p-8"),children:[(0,a.jsx)(v.$n,{size:"iconSm",theme:"secondary",context:"mediaOverlay",iconPosition:"only",icon:(0,a.jsx)(j.k,{}),"aria-label":"Close player",onClick:()=>{y("closed"),x()},className:"bg-grey-800 absolute -top-16 left-8 z-50 after:absolute after:-inset-8"}),(0,a.jsx)(V.zM,{asChild:!0,children:(0,a.jsx)(v.$n,{ref:C,size:"iconSm",theme:"primary",context:"dark",iconPosition:"only",icon:(0,a.jsx)(S.o,{className:"h-[2rem] w-[2rem]"}),autoFocus:e,onClick:()=>{y("expanded")},"aria-label":"Expand player",className:"absolute -top-16 right-8 z-50 after:absolute after:-inset-8"})}),(0,a.jsxs)("div",{className:"flex",children:[(0,a.jsx)("div",{className:"w-player:h-[calc(10rem*var(--base-multiplier))] relative aspect-square h-[calc(8.4rem*var(--base-multiplier))] flex-none overflow-hidden bg-theme-primary",children:(0,a.jsx)("img",{src:w.thumb,srcSet:`${w.thumb} 1x, ${w.thumb_x2} 2x`,alt:"",width:100,height:100,className:"absolute inset-0 h-full w-full cursor-pointer object-cover","aria-hidden":"true",onClick:()=>{y("expanded")}})}),(0,a.jsxs)("div",{className:"w-player:px-16 w-player:pb-16 w-player:pt-2 flex w-full flex-grow flex-col justify-between overflow-hidden pb-8 pl-8 pt-0",children:[(0,a.jsx)(H.S,{media:i,darkContext:!0,hasShortDate:!0,size:"medium"}),(0,a.jsx)("div",{className:"flex items-center justify-between gap-4",children:(0,a.jsxs)("div",{className:"flex w-full items-center gap-8",children:[(0,a.jsx)(v.$n,{onClick:o?x:c,theme:"primary",size:"iconSm",iconPosition:"only",icon:(0,a.jsx)(E.n,{isPlaying:o}),"aria-label":o?`Pause ${i.title}`:`Play ${i.title}`,className:"relative after:absolute after:-inset-4"}),(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"prefix",icon:(0,a.jsx)(M.A,{align:"text"}),content:"15s",onClick:()=>L(-15),"aria-label":"Skip back 15 seconds",className:"relative h-24 after:absolute after:-inset-4"}),!k&&(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(v.$n,{size:"iconSm",theme:"secondary",context:"dark",iconPosition:"only",icon:(0,a.jsx)(P,{}),onClick:r,isDisabled:p.length-1===f,"aria-label":"Play next item in queue",className:"relative after:absolute after:-inset-4"}),i&&(0,a.jsx)(I,{isLarge:!0,currentTime:g,duration:b})]}
1),k&&(0,a.jsx)(O,{})]})})]})]})]}),(0,a.jsx)("div",{className:"absolute bottom-0 left-0 right-0",children:l})]})},J=({canFocusPlayer:e,hasPlayerComponentsMounted:t,setHasPlayerComponentsMounted:s,progressBar:i,id:l,className:o})=>{let c=(0,r.DE)(),{items:m,marker:p,setMarker:f}=(0,u.M)(),{play:g,pause:b,isPlaying:j}=(0,d.E)(),{seekBy:v}=D({current:null}),y=m[p]??null,w=(0,n.useRef)(!0);return((0,n.useEffect)(()=>{w.current&&(m[p]?.title==="Tahi"&&f(0),w.current=!1)},[m,p,f,w]),c)?(0,a.jsx)(a.Fragment,{children:y&&(0,a.jsxs)("section",{id:l,className:(0,h.cn)("",o),tabIndex:-1,"aria-label":"Audio player",children:[(0,a.jsx)("div",{className:"relative",children:(0,a.jsx)(A,{})}),(0,a.jsx)(B,{canFocusPlayer:e,hasPlayerComponentsMounted:t,setHasPlayerComponentsMounted:s,handleSkipBack:()=>{v(-15)},handleNextItem:()=>{let e=p;do++e;while("Tahi"===m[e].title&&e<m.length-1);f("Tahi"!==m[e].title?e:0),(0,x.HT)(y,"next track")},currentTrack:y,isPlaying:j,play:g,pause:b,progressBar:i})]})}):null};var $=s(675),U=s.n($),_=s(67669),K=s(24200);let q=({playbackRates:e=[.75,1,1.25,1.5,1.75,2]})=>{let{playbackRate:t,setPlaybackRate:s}=(0,d.E)();return(0,a.jsx)("div",{className:"flex min-w-80 justify-end",children:(0,a.jsxs)("button",{className:U()("rounded-md px-4 py-1 text-xs uppercase tracking-widest",{"text-grey-500 hover:text-grey-900 bg-black *:text-white hover:bg-white *:hover:text-black":1===t,"text-grey-900 hover:text-grey-500 bg-white *:text-black hover:bg-black *:hover:text-white":1!==t}),onClick:()=>{let a=e.indexOf(t)+1;s(a>e.length-1?e[0]:e[a])},"aria-live":"polite",children:["Speed ",(0,a.jsxs)("span",{className:U()("lowercase"),children:[t,"x"]})]})})},G=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?13:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M12.0693 4.96532L11.217 4.5L3.33841 10.5347V11.4653L11.217 17.5L12.0693 17.0347V4.96532Z"}),(0,a.jsx)("path",{d:"M-1.90735e-05 5.25433V17.3237H1.50865V5.25433H-1.90735e-05Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M17.0352 4.96532L16.1828 4.5L8.3
10423 10.5347V11.4653L16.1828 17.5L17.0352 17.0347V4.96532Z"}),(0,a.jsx)("path",{d:"M4.9658 5.25433V17.3237H6.47447V5.25433H4.9658Z"})]})});var Q=s(48350);let X=()=>{let e=(0,r.DE)(),{items:t,marker:s,setMarker:i}=(0,u.M)(),{play:l,pause:o,isPlaying:c,audioCurrentTime:p,audioDuration:f}=(0,d.E)(),{playerTab:g}=(0,m.h)(),[b,j]=(0,n.useState)(!1),[y,w]=(0,n.useState)(!1),{seekBy:N,seekTo:C}=D({current:null}),L=t[s]??null;(0,n.useEffect)(()=>{j(!!t[s]?.liveStreamName)},[t,s]);let k=(0,n.useRef)(!0);return((0,n.useEffect)(()=>{k.current&&(k.current=!1,t[s]?.title==="Tahi"&&i(0))},[t,s,i,k]),e)?(0,a.jsxs)("div",{className:(0,h.cn)("bg-surface-muted dark-theme p-16"),children:[(0,a.jsx)("div",{className:(0,h.cn)("mb-16 flex items-center justify-center gap-16",{"h-player-controls:flex hidden":"detail"!==g}),children:b?(0,a.jsx)("div",{className:"flex h-[calc(1.73rem*var(--base-multiplier))]",children:(0,a.jsx)(Q.b,{})}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(q,{}),L&&(0,a.jsx)(I,{isLarge:!0,hasMinWidth:!0,currentTime:p,duration:f}),(0,a.jsx)("div",{"aria-hidden":!0,className:"min-w-80"})]})}),(0,a.jsxs)("div",{className:"w-player:gap-16 flex items-center justify-center gap-[calc(1.2rem*var(--base-multiplier))] *:flex-shrink-0",children:[(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"prefix",icon:(0,a.jsx)(M.A,{align:"text"}),content:"15s",onClick:()=>{w(!0),N(-15),setTimeout(()=>w(!1),200)},isDisabled:y,"aria-label":"Skip back 15 seconds",className:"h-24 w-[calc(5.88rem*var(--base-multiplier))]"}),(0,a.jsx)(v.$n,{size:"iconMd",theme:"base",context:"dark",iconPosition:"only",icon:(0,a.jsx)(G,{}),isDisabled:0===s&&p<=3,onClick:()=>{if(b){if(s>0){let e=s;do--e;while("Tahi"===t[e].title&&e>0);i(e),C(0)}return}if(p>3)return void C(0);if(s>0){let e=s;do--e;while("Tahi"===t[e].title&&e>0);i(e),C(0)}(0,x.HT)(L,"previous track")},"aria-label":"Play previous item in queue"}),(0,a.jsx)(v.$n,{size:"iconXl",theme:"primary",iconPosition:"only",context:"dark",icon:(0,a.jsx)(E.n,{isPlaying:c}),isDisabled:!L,onClick:()=>c?o():l(),"aria-label":c?`Pause ${L?L.title:""}`:`Play ${L?L.title:""}`}),(0,a.jsx)(v.$n,{size:"iconMd",theme:"base",context:"dark",iconPosition:"only",icon:(0,a.jsx)(P,{}),isDisabled:t.length-1===s,onClick:()=>{let e=s;do++e;while("Tahi"===t[e].title&&e<t.length-1);i("Tahi"!==t[e].title?e:0),(0,x.HT)(L,"next track")},"aria-label":"Play next item in queue"}),b?(0,a.jsx)(O,{}):(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"suffix",icon:(0,a.jsx)(z.s,{align:"text"}),content:"15s",onClick:()=>{if(b)return null;w(!0),N(15),setTimeout(()=>w(!1),200)},isDisabled:b||y,"aria-label":"Skip forward 15 seconds",className:"h-24 w-[calc(5.88rem*var(--base-multiplier))]"})]})]}):null},W=e=>(0,a.jsx)("h2",{id:e.id,className:"font-sans-normal text-sm uppercase tracking-widest",children:e.children});var Y=s(78865),ee=s(53641),et=s(15686);function es({media:e,reorderTriggers:t,closeTrigger:s,primaryAction:r,liveStation:i,duration:n,themeColors:l}){let o=(0,R.pz)(e);return(0,a.jsx)(et.L,{...l&&{colors:l},className:"w-full",children:(0,a.jsx)("article",{className:(0,h.cn)("dark-theme text-foreground-primary bg-surface-primary flex w-full items-center p-16"),style:l?{backgroundColor:`${l.primary_color?.color}59`}:void 0,children:(0,a.jsxs)("div",{className:"relative flex w-full items-center pl-16",children:[(0,a.jsxs)("div",{className:(0,h.cn)("order-3 flex w-full flex-grow flex-col justify-between pl-16",{"space-y-8":!i,"space-y-16":i}),children:[(0,a.jsxs)("div",{className:"flex flex-col pr-24",children:[!i&&(0,a.jsx)("h3",{className:"order-2 mt-8 line-clamp-2 leading-snug",children:(0,a.jsx)(y.default,{text:e.title})}),(0,a.jsx)("div",{className:(0,h.cn)("font-sans-normal order-1 text-xs",{"line-clamp-1 leading-snug":!i}),children:i?(0,a.jsx)(Y.V,{headingLevel:3,liveStreamName:i,isDarkContext:!0}):(0,a.jsx)("span",{children:e.context})})]}),(0,a.jsxs)("div",{className:"flex items-center justify-between",children:[(0,a.jsxs)("div",{className:"flex items-center gap-8",children:[r,!i&&(0,a.jsx)(ee.u,{media:e,hasShortDate:!0})]}),!s&&(i?(0,a.jsx)(Q.b,{}):n)]})]}),(0,a.jsx)("div",{className:"bg-theme-primary order-2 aspect-square h-64 flex-none overflow-hidden",children:(0,a.jsx)("img",{src:o.thumb,srcSet:`${o.thumb} 1x, ${o.thumb_x2} 2x`,alt:e.imageAlt??"Related image for the audio item",width:60,height:60,className:"h-full w-full object-cover"})}),t&&(0,a.jsx)("div",{className:"order-1 -ml-24 w-24 flex-none pr-4",children:(0,a.jsx)("div",{className:"flex min-h-64 flex-col items-center justify-between",children:t})}),s&&(0,a.jsx)("div",{className:"absolute -right-4 order-4 flex h-full flex-none items-center justify-center",children:s})]})})})}let ea=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?14:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M13 4.25L13.75 5V17L13 17.75H1L0.25 17V5L1 4.25H13ZM1.75 16.25H12.25V5.75H1.75V16.25Z"}),(0,a.jsx)("path",{d:"M9.79346 10.5974V11.0271L5.33936 13.6756L4.96045 13.4607V8.16385L5.33936 7.94901L9.79346 10.5974Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M17 4.25L17.75 5V17L17 17.75H5L4.25 17V5L5 4.25H17ZM5.75 16.25H16.25V5.75H5.75V16.25Z"}),(0,a.jsx)("path",{d:"M13.7935 10.5974V11.0271L9.33936 13.6756L8.96045 13.4607V8.16385L9.33936 7.94901L13.7935 10.5974Z"})]})}),er=({item:e})=>{let{setPlayerTab:t}=(0,m.h)(),s=()=>t("detail");return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("span",{className:"xs:hidden",children:(0,a.jsx)(v.$n,{size:"iconSm",theme:"secondary",context:"dark",iconPosition:"only",icon:(0,a.jsx)(ea,{}),"aria-label":`Open player for ${e.title}`,onClick:s})}),(0,a.jsx)("span",{className:"xs:block hidden",children:(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"prefix",icon:(0,a.jsx)(ea,{align:"text"}),content:"Open","aria-label":`Open player for ${e.title}`,onClick:s})})]})},ei=()=>{let{items:e,marker:t}=(0,u.M)(),{audioCurrentTime:s,audioDuration:r}=(0,d.E)();if(!e.length)return null;let i=e[t]??null;return i&&"Tahi"!==i.title?(0,a.jsxs)("section",{"aria-labelledby":"player-queue-current",children:[(0,a.jsx)("div",{className:"bg-surface-primary text-foreground-primary dark-theme flex p-16 leading-none",children:(0,a.jsx)(W,{id:"player-queue-current",children:"Now playing"})}),(0,a.jsx)("div",{className:"bg-grey-800 flex items-center overflow-hidden",children:(0,a.jsx)(es,{themeColors:i.themeColors,media:i,primaryAction:(0,a.jsx)(er,{item:i}),...!i.liveStreamName&&{duration:(0,a.jsx)(I,{currentTime:s,duration:r})},...i.liveStreamName&&{liveStation:i.liveStreamName}})})]}):null};var en=s(55734),el=s(80367),eo=s(66185);let ec=({item:e,playText:t,handleClick:s})=>{let r=(0,en.g)(e),i=t??"Play";return(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"prefix",icon:r?(0,a.jsx)(el._,{align:"text"}):(0,a.jsx)(eo.A,{align:"text"}),content:r?"Pause":e.liveStreamName?"Listen live":i,secondaryText:!e.liveStreamName&&e.duration?(0,F.Sy)(e.duration):void 0,onClick:()=>s?.(),ariaLabel:r?"Pause":e.liveStreamName?`Listen live to RNZ ${e.liveStreamName}`:`${i} ${e.title}, ${e.duration?(0,F.RO)(e.duration):""}`})},ed=({handleClick:e})=>(0,a.jsx)(v.$n,{size:"iconMd",theme:"iconGhost",context:"dark",iconPosition:"only",icon:(0,a.jsx)(j.k,{}),onClick:()=>e?.(),"aria-label":"Remove this item from the queue",className:"relative -right-4"});var em=s(44635);let eu=({handleClick:e,disabled:t})=>(0,a.jsx)(v.$n,{size:"iconSm",theme:"iconGhost",context:"dark",iconPosition:"only",icon:(0,a.jsx)(em.R,{}
1),className:"relative -bottom-4 -left-2 mt-auto touch-none after:absolute after:-inset-4",onClick:()=>e?.(),isDisabled:t,"aria-label":"Move item down"}),ex=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?12:22,height:22,className:t,children:"text"===e?(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M6.24859 7.28835L9.99412 11.0329L11.0305 9.99658L6.03292 5H4.99658L0 9.99658L1.03634 11.0329L4.78282 7.28644V17H6.24859V7.28835Z"})}):(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("path",{d:"M11.733 7.28835L15.4785 11.0329L16.5148 9.99658L11.5173 5H10.481L5.48438 9.99658L6.52072 11.0329L10.2672 7.28644V17H11.733V7.28835Z"})})}),eh=({handleClick:e,disabled:t})=>(0,a.jsx)(v.$n,{size:"iconSm",theme:"iconGhost",context:"dark",iconPosition:"only",icon:(0,a.jsx)(ex,{}),className:"relative -left-2 -top-4 touch-none after:absolute after:-inset-4",onClick:()=>e?.(),isDisabled:t,"aria-label":"Move item up"});function ep({item:e,index:t,overlay:s=!1}){let{items:r,moveTo:i,marker:n,setMarker:l,removeAt:o}=(0,u.M)(),{play:m,pause:p}=(0,d.E)(),f=(0,en.g)(e),g=s?e.qid+"overlay":e.qid,b="number"==typeof t,j=b&&t>0;return(0,a.jsx)(c.P.div,{className:(0,h.cn)("relative select-none overflow-hidden first:z-10"),layoutId:String(g),initial:{opacity:s?"auto":0},exit:{opacity:s?"auto":0},animate:{x:0,y:0,height:"auto",opacity:1},transition:{duration:.25},children:(0,a.jsx)(es,{media:e,...e.liveStreamName&&{liveStation:e.liveStreamName},reorderTriggers:(0,a.jsxs)(a.Fragment,{children:[(j||s)&&t!==n+1&&(0,a.jsx)(eh,{handleClick:()=>b&&i(t,t-1),disabled:t===n+1}),(j||s)&&r.length-1!==t&&(0,a.jsx)(eu,{handleClick:()=>b&&i(t,t+1),disabled:r.length-1===t})]}),primaryAction:(0,a.jsx)(ec,{item:e,handleClick:()=>{f?p():(()=>{if(!b)return;let s=n+1;i(t,s),l(s),m(),(0,x.HT)(e,"play clip")})()}}),closeTrigger:(0,a.jsx)(ed,{handleClick:()=>void(b&&(o(t),(0,x.HT)(e,"remove clip")))})})})}var ef=s(13941),eg=s(47166),eb=s(45575);let ej=({station:e})=>{let{items:t,marker:s,insertAt:r,setMarker:i}=(0,u.M)(),{play:n,pause:l}=(0,d.E)(),o=(0,en.g)(e),c=(0,eb.usePathname)(),m=window.location.pathname;return(0,a.jsx)(es,{media:e,...e.liveStreamName&&{liveStation:e.liveStreamName},primaryAction:(0,a.jsx)(ec,{item:e,handleClick:()=>{if(o)l();else{let a;r(a=0===t.length?0:s+1,{...e,playbackBeginUrl:c??m,qid:(0,ef.Ak)()}),i(a),n()}}}),closeTrigger:(0,a.jsx)(a.Fragment,{})})},ev=({hasNextItems:e})=>(0,a.jsxs)("div",{className:"font-sans-normal dark-theme bg-surface-primary text-foreground-primary py-8 leading-normal",children:[(0,a.jsx)("p",{className:"text-foreground-secondary pl-16",children:e?"This is the end of your queue.":"You have nothing queued."}),(0,a.jsxs)("p",{className:"mb-16 pl-16",children:["Browse"," ",(0,a.jsx)("a",{className:"underline",href:"/podcasts","aria-label":"Browse podcasts",children:"podcasts"})," ","or tune in to a station:"]}),eg.dU.map(e=>(0,a.jsx)(ej,{station:e},e.qid))]}),ey=()=>{let{items:e,marker:t,clearAfter:s}=(0,u.M)(),r=e.slice(t+1);return(0,a.jsxs)("section",{"aria-labelledby":"player-queue-next",children:[(0,a.jsx)("div",{className:"bg-surface-primary text-foreground-primary dark-theme h-[calc(4.5rem*var(--base-multiplier))] pl-16 pr-8 leading-none",children:(0,a.jsxs)("div",{className:"flex h-full items-center justify-between gap-8",children:[(0,a.jsx)(W,{id:"player-queue-next",children:"Next in queue"}),r.length>0&&(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",content:"Clear all","aria-label":"Clear all items in queue",onClick:()=>{s(t)}})]})}),(0,a.jsxs)("div",{className:"relative",children:[(0,a.jsx)("div",{children:(0,a.jsx)(o.N,{initial:!1,children:e.map((e,s)=>s>t&&"Tahi"!==e.title&&(0,a.jsx)(ep,{item:e,index:s},e.qid))})}),(0,a.jsx)(ev,{hasNextItems:r.length>0})]})]})},ew=()=>(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(ei,{}),(0,a.jsx)(ey,{})]});var eN=s(71537);let eC=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?16:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M8 4C11.866 4 15 7.13401 15 11C15 14.866 11.866 18 8 18C4.13401 18 1 14.866 1 11C1 7.13401 4.13401 4 8 4ZM8 5.5C4.96243 5.5 2.5 7.96243 2.5 11C2.5 14.0376 4.96243 16.5 8 16.5C11.0376 16.5 13.5 14.0376 13.5 11C13.5 7.96243 11.0376 5.5 8 5.5Z"}),(0,a.jsx)("path",{d:"M7.25 6.66974H8.75V10.4988L11.3682 11.8084L10.6973 13.1502L7.66504 11.6336L7.25 10.9627V6.66974Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M11 4C14.866 4 18 7.13401 18 11C18 14.866 14.866 18 11 18C7.13401 18 4 14.866 4 11C4 7.13401 7.13401 4 11 4ZM11 5.5C7.96243 5.5 5.5 7.96243 5.5 11C5.5 14.0376 7.96243 16.5 11 16.5C14.0376 16.5 16.5 14.0376 16.5 11C16.5 7.96243 14.0376 5.5 11 5.5Z"}),(0,a.jsx)("path",{d:"M10.25 6.66974H11.75V10.4988L14.3682 11.8084L13.6973 13.1502L10.665 11.6336L10.25 10.9627V6.66974Z"})]})}),eL=({align:e,className:t})=>(0,a.jsx)(g.h,{align:e,width:"text"===e?12:22,height:22,className:t,children:"text"===e?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M12 15.9122H0V14.4122H12V15.9122Z"}),(0,a.jsx)("path",{d:"M12 11.6622H0V10.1622H12V11.6622Z"}),(0,a.jsx)("path",{d:"M2.92969 6.4151V6.84576L0.459961 8.31354L0.0810547 8.09869V5.16217L0.459961 4.94733L2.92969 6.4151Z"}),(0,a.jsx)("path",{d:"M12 7.41217H5.03711V5.91217H12V7.41217Z"})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)("path",{d:"M17 15.9122H5V14.4122H17V15.9122Z"}),(0,a.jsx)("path",{d:"M17 11.6622H5V10.1622H17V11.6622Z"}),(0,a.jsx)("path",{d:"M7.92969 6.4151V6.84576L5.45996 8.31354L5.08105 8.09869V5.16217L5.45996 4.94733L7.92969 6.4151Z"}),(0,a.jsx)("path",{d:"M17 7.41217H10.0371V5.91217H17V7.41217Z"})]})});var ek=s(47954);let eA=({children:e,scrollable:t=!0,className:s})=>(0,a.jsx)("div",{className:(0,h.cn)("w-player:min-h-[min(calc(43rem*var(--base-multiplier)),calc(100dvh-var(--player-expanded-controls-height)))] max-h-[min(calc(73rem*var(--base-multiplier)),calc(100dvh-var(--player-expanded-controls-height)))] min-h-full","relative flex flex-col",{"overflow-hidden":!t},s),children:(0,a.jsx)(a.Fragment,{children:t?(0,a.jsxs)(ek.FK,{className:(0,h.cn)("flex h-full flex-col","z-10"),children:[(0,a.jsx)(ek.Br,{className:"overscroll-contain",children:e}),(0,a.jsx)(ek.VM,{orientation:"vertical",children:(0,a.jsx)(ek.lr,{})})]}):(0,a.jsx)(a.Fragment,{children:e})})}
1),eS={national:"The best news, current affairs, MÄori programming, series, readings and music 24 hours a day.",concert:"NZâs fine music network, promoting NZ music and composition and featuring live broadcasts of concerts and recitals from across Aotearoa and around the world.",pacific:"The best pacific, current affairs, MÄori programming, series, readings and music 24 hours a day.",parliament:"Live audio from Parliament during all sittings of the House."},eM=e=>{let t=!!e.media.themeColors?.primary_color?.isDark,s=(0,R.pz)(e.media);return(0,a.jsx)(et.L,{colors:e.media.themeColors,className:(0,h.cn)("text-foreground-primary h-full",{"light-theme":!t,"dark-theme":t}),children:(0,a.jsxs)("section",{className:"bg-theme-primary flex h-full flex-col","aria-label":"Now playing view",children:[(0,a.jsx)("div",{className:(0,h.cn)("max-h-[calc(26.6rem*var(--base-multiplier))] basis-full","bg-theme-secondary grow"),children:(0,a.jsxs)("div",{className:"flex h-full pt-16",children:[(0,a.jsx)("div",{className:"grow"}),(0,a.jsx)("div",{className:"h-player-image:bg-theme-primary relative aspect-square",children:(0,a.jsx)("img",{src:s.detail,srcSet:`${s.detail} 1x, ${s.detail_x2} 2x`,alt:e.media?.title??"",width:600,height:600,className:(0,h.cn)("absolute inset-0 h-full w-full object-cover","h-player-image:block hidden")},e.media.qid)}),(0,a.jsx)("div",{className:"bg-theme-tertiary -mt-16 grow"})]})}),(0,a.jsx)("div",{className:(0,h.cn)("bg-theme-primary flex flex-grow flex-col justify-between gap-24 px-16 py-16",e.media.liveStreamName&&"gap-16"),children:e.media.liveStreamName?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(Y.V,{headingLevel:2,liveStreamName:e.media.liveStreamName,isDarkContext:!1,size:"lg",className:"mb-2 flex pt-8"}),(0,a.jsx)("p",{className:"text-sm",children:eS[e.media.liveStreamName]})]}):(0,a.jsxs)(a.Fragment,{children:[(0,a.jsxs)("div",{className:"flex flex-col",children:[(0,a.jsx)("h2",{className:"font-sans-semibold order-1 mt-8 text-lg leading-snug",children:(0,a.jsx)(y.default,{text:e.media?.title})}),(0,a.jsx)("p",{className:"order-0",children:e.media?.context})]}),(0,a.jsx)(ee.u,{media:e.media,size:"sm"})]})})]})})},eP=()=>{let{items:e,marker:t}=(0,u.M)(),s=e[t]??null;return s&&"Tahi"!==s.title?(0,a.jsx)(eM,{media:s}):null};var eE=s(70399),eV=s(80065);let eH=({item:e,handleClick:t})=>(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",iconPosition:"prefix",icon:(0,a.jsx)(eV.u,{align:"text"}),content:"Queue",onClick:()=>t?.(),ariaLabel:`Queue ${e.title}`}),eR=({media:e,prevItems:t})=>{let{marker:s,moveTo:r,setMarker:i,push:n,removeAt:l}=(0,u.M)(),{getById:o}=(0,eE.k)(),{play:c,pause:m}=(0,d.E)(),h=(0,en.g)(e),p=o(e.id);return(0,a.jsx)(es,{media:e,...e.liveStreamName&&{liveStation:e.liveStreamName},primaryAction:p||e.liveStreamName?(0,a.jsx)(ec,{item:e,playText:"Resume",handleClick:()=>{h?m():(r(e.originalIndex,s),c())}}):(0,a.jsx)(eH,{item:e,handleClick:()=>{n({...e,qid:(0,ef.Ak)()})}}),closeTrigger:(0,a.jsx)(ed,{handleClick:()=>{var a;let r;return r=t[a=e.originalIndex],void(l(a),i(Math.min(Math.max(s-1,0),t.length-1)),(0,x.HT)(r,"remove clip"))}})})},eZ=()=>{let{items:e,marker:t,setMarker:s,clearBefore:r}=(0,u.M)(),i=e.slice(0,t).filter(e=>"Tahi"!==e.title),n=i.map((e,t)=>({...e,originalIndex:t})).reverse();return(0,a.jsxs)("section",{"aria-labelledby":"player-history",className:"relative",children:[(0,a.jsx)("div",{className:"bg-surface-primary text-foreground-primary dark-theme sticky top-0 z-10 h-[calc(4.5rem*var(--base-multiplier))] px-16 pr-32 leading-none",children:(0,a.jsxs)("div",{className:"flex h-full items-center justify-between gap-8",children:[(0,a.jsx)(W,{id:"player-history",children:"Recently played"}),i.length>0&&(0,a.jsx)(v.$n,{size:"sm",theme:"secondary",context:"dark",content:"Clear all","aria-label":"Clear all items in queue",onClick:()=>{r(t),s(0)},className:"mr-8"})]})}),0===i.length&&(0,a.jsxs)("p",{className:"p-16 pt-8",children:["You have no saved history or",(0,a.jsx)("br",{})," you have cleared everything."]}),(0,a.jsx)(o.N,{initial:!1,children:n.map(e=>(0,a.jsx)(c.P.div,{className:"flex items-center overflow-hidden",initial:{height:0},exit:{height:0},animate:{height:"auto"},transition:{duration:.25,delay:0},children:(0,a.jsx)(eR,{media:e,prevItems:i})},e.qid))})]})},eD=({value:e,icon:t,children:s,...r})=>{let{playerTab:i}=(0,m.h)(),n=i===e;return(0,a.jsxs)(_.oz,{id:e,...r,className:U()("!font-sans-normal relative cursor-pointer rounded-none first:rounded-l-full last:rounded-r-full focus-visible:z-10",{"!bg-grey-800 !border-grey-700 hover:!bg-surface-accent hover:!border-stroke-accent text-white *:!text-white":!n,"*:!text-black hover:!border-white hover:!bg-white hover:!text-black [&>svg]:!text-black":n},(0,K.r)({intent:n?"white":"grey",icon:"prefix"})),children:[t,s]})},ez=({canFocusPlayer:e,setHasPlayerComponentsMounted:t,progressBar:s})=>{let l=(0,r.DE)(),{items:o,marker:c}=(0,u.M)(),{setCollapseButtonRef:x}=(0,d.x)(),{setPlayerTab:h,playerTab:p,setPlayerSize:f,playerSize:g}=(0,m.h)(),b=o.slice(c+1).filter(e=>"Tahi"!==e.title),j=(0,n.useRef)(null),y=(0,i.Ub)("(min-height: 550px)"),w=()=>{let e=j.current?.offsetHeight??16;document.documentElement.style.setProperty("--player-expanded-controls-height",`calc(${e/10}rem * var(--base-multiplier))`)},N=(0,n.useCallback)(e=>{null!==e&&"expanded"===g&&x(e)},[g]);return((0,n.useEffect)(()=>{t(!0)},[]),(0,n.useEffect)(()=>{l&&setTimeout(()=>{w()},50)},[l]),(0,n.useEffect)(()=>{w()},[y,p]),l)?(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(V.HM,{asChild:!0,children:(0,a.jsx)(v.$n,{ref:N,className:"absolute right-8 top-12 z-50 after:absolute after:-inset-8",size:"iconSm",theme:"primary",context:"dark",iconPosition:"only",icon:(0,a.jsx)(eN.r,{}),onClick:()=>f("mini"),"aria-label":"Collapse player",autoFocus:e})}),(0,a.jsx)(_.wP.Provider,{value:{selectedKey:p,onSelectionChange:e=>{h(e)}},children:(0,a.jsxs)(_.tU,{className:"border-grey-700/50 dark-theme bg-surface-primary text-foreground-primary flex h-full flex-col border-l border-t",children:[(0,a.jsx)(_.Kp,{id:"history",className:"h-full",children:(0,a.jsx)(eA,{children:(0,a.jsx)(eZ,{})})}),(0,a.jsx)(_.Kp,{id:"detail",className:"h-full",children:(0,a.jsx)(eA,{scrollable:!1,
1className:"w-player:h-[min(calc(43rem*var(--base-multiplier)),calc(100dvh-var(--player-expanded-controls-height)))] h-full",children:(0,a.jsx)(eP,{})})}),(0,a.jsx)(_.Kp,{id:"queue",className:"h-full",children:(0,a.jsx)(eA,{children:(0,a.jsx)(ew,{})})}),(0,a.jsxs)("div",{className:"bg-surface-muted relative mt-auto w-full flex-none shadow-2xl",children:[(0,a.jsx)("div",{className:"relative",children:(0,a.jsx)(A,{})}),(0,a.jsxs)("div",{ref:j,children:[(0,a.jsx)("div",{className:U()({"h-player-controls:block hidden":"detail"!==p}),children:s}),(0,a.jsx)(X,{}),(0,a.jsx)("div",{className:"px-16 pb-24",children:(0,a.jsxs)(_.wb,{className:"flex items-center justify-center",children:[(0,a.jsx)(eD,{value:"history",icon:(0,a.jsx)(eC,{align:"text",className:"mx-4 my-1"}),children:"History"}),(0,a.jsx)(eD,{value:"detail",icon:(0,a.jsx)(ea,{align:"text",className:"mx-4 my-1"}),children:"Playing"}),(0,a.jsxs)(eD,{value:"queue",icon:(0,a.jsx)(eL,{align:"text",className:"mx-4 my-1"}),children:["Queue",b&&b.length>0&&(0,a.jsx)("span",{className:"text-grey-100 ml-2",children:`(${b.length})`})]})]})})]})]})]})})]}):null},eT=({dialogOpen:e,dialogContainer:t,...s})=>{let{playTrigger:r,setPlayTrigger:i}=(0,d.x)(),n=(0,l.I)(),o={initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2,ease:"easeInOut"}};return(0,a.jsx)(V.ZJ,{container:t,forceMount:!0,children:e&&(0,a.jsxs)(V.LC,{className:"z-modal fixed inset-0",children:[(0,a.jsx)(c.P.div,{...o,className:"absolute inset-0 bg-white/50"}),(0,a.jsx)(c.P.div,{...n?o:{initial:{y:"100%"},animate:{y:"0%"},exit:{y:"100%"},transition:{duration:.4,ease:"easeInOut"}},className:"focus-outline-alt absolute inset-0",children:(0,a.jsxs)(V.Cf,{onOpenAutoFocus:e=>{e.preventDefault()},onCloseAutoFocus:e=>{e.preventDefault(),r&&(r.focus(),i(null))},className:"h-full w-full",children:[(0,a.jsx)(V.L3,{className:"sr-only",children:"Audio player"}),(0,a.jsx)(ez,{...s})]})})]})})},eO=(0,n.forwardRef)(({...e},t)=>e.isDesktop?(0,a.jsx)("section",{ref:t,id:e.id,tabIndex:-1,"aria-label":"Audio player",children:(0,a.jsx)(ez,{...e})}):(0,a.jsx)(eT,{...e}));eO.displayName="PlayerExpandedWrapper";var eF=s(44945);let eI=e=>"number"==typeof e?e-e==0:"string"==typeof e&&""!==e.trim()&&(Number.isFinite?.(+e)??isFinite(+e)),eB=n.forwardRef(({className:e,isLoading:t,hasError:s,isPlaying:r,playbackRate:i=1,hasBackgroundImage:n=!0,isInteractive:l=!0,...o},c)=>{let d=o.value&&eI(o.value[0])?o.value[0]:0,m=d?(0,F.fd)(d):null,u=n&&(!!t||r),x=!!s||!!t,p=l&&!x;return(0,a.jsxs)(eF.bL,{ref:c,disabled:!p,className:(0,h.cn)("focus-outline-alt relative flex h-8 w-full touch-none select-none items-center",{"bg-grey-500":l||x,"bg-grey-800":!l&&!x},e),...o,children:[(0,a.jsxs)(eF.CC,{className:(0,h.cn)("relative h-8 w-full grow overflow-hidden",{"progress-bg-fade-in":n&&t}),children:[(0,a.jsx)("div",{className:(0,h.cn)("absolute inset-0 invert",{"progress-bg":n,"progress-bg-animate-0p75x":u&&.75===i,"progress-bg-animate-1p0x":u&&1===i,"progress-bg-animate-1p25x":u&&1.25===i,"progress-bg-animate-1p5x":u&&1.5===i,"progress-bg-animate-1p75x":u&&1.75===i,"progress-bg-animate-2p0x":u&&2===i,"opacity-100":s})}),(0,a.jsx)("div",{className:(0,h.cn)("absolute inset-0",{"from-grey-100 to-grey-100 bg-gradient-to-r via-transparent":u})}),s&&(0,a.jsx)("div",{className:"bg-signal-warning absolute inset-0 opacity-90"}),!x&&(0,a.jsx)(eF.Q6,{className:"bg-surface-accent absolute h-full"})]}),p&&!x&&(0,a.jsxs)(eF.zi,{className:"bg-surface-accent flex h-8 w-24 justify-center gap-2 p-2",...m&&{"aria-valuetext":m},"aria-label":"Audio progress",children:[(0,a.jsx)("div",{className:"h-4 w-4 rounded-full bg-white"}),(0,a.jsx)("div",{className:"h-4 w-4 rounded-full bg-white"}),(0,a.jsx)("div",{className:"h-4 w-4 rounded-full bg-white"})]})]})});eB.displayName=eF.bL.displayName;let eJ=({isInteractive:e=!0})=>{let{playbackRate:t,isPlaying:s,audioCurrentTime:r,audioDuration:i,isLoading:l,error:o}=(0,d.E)(),{items:c,marker:m}=(0,u.M)(),[x,p]=(0,n.useState)(null),{seekTo:f}=D({current:null}),g=c[m]??null;return g?.liveStreamName?(0,a.jsx)("div",{className:(0,h.cn)("bg-surface-accent relative flex w-full touch-none select-none items-center"),children:(0,a.jsxs)("div",{className:"relative h-8 w-full grow overflow-hidden",children:[(0,a.jsx)("div",{className:(0,h.cn)("progress-bg absolute inset-0 invert",{"progress-bg-animate-1p0x":s,"opacity-100":!!o})}),(0,a.jsx)("div",{className:"from-surface-accent to-surface-accent absolute inset-0 bg-gradient-to-r via-transparent"})]})}):(0,a.jsx)(eB,{value:[x??r],onValueChange:e=>{isNaN(e[0])||p(e[0])},onValueCommit:e=>{f(e[0]),setTimeout(()=>{p(null)},1e3)},defaultValue:[0],max:eI(i)?i:0,isPlaying:s,isLoading:l,playbackRate:t,hasError:!!o,hasBackgroundImage:l??!!o,isInteractive:e})},e$=s(37811).env.CLOUDINARY_HOSTNAME??"media.rnztools.nz",eU=({children:e})=>{let t=(0,n.useRef)(null),i=(0,n.useRef)(null),l=(0,n.useRef)(0);D(t);let[o,c]=(0,n.useState)(null),[m,x]=(0,n.useState)(!1),h=(0,r.DE)(),{items:p,marker:f,setMarker:g}=(0,u.M)(),{update:b,removeById:j,getById:v}=(0,eE.k)(),{localPid:y}=(0,d.x)(),{globalPid:w,isPlaying:N,pause:L,play:k,playbackRate:A,setAudioCurrentTime:S,setGlobalPid:M,setIsLoading:P,scrubInProgress:E,audioCurrentTime:V,audioDuration:H,setAudioDuration:R}=(0,d.E)(),{setError:Z,addMessage:z}=C(),T=p?.[f]??null,O=T?.audioSrc??"",F=y===w,I=(0,n.useRef)({setError:Z,setIsLoading:P,setGlobalPid:M,pause:L,addMessage:z,play:k,setLastPlayedId:c,updateDuration:b,setAudioCurrentTime:S,setAudioDuration:R,removeById:j,setMarker:g});return((0,n.useEffect)(()=>{I.current={setError:Z,setIsLoading:P,setGlobalPid:M,pause:L,addMessage:z,play:k,setLastPlayedId:c,updateDuration:b,setAudioCurrentTime:S,setAudioDuration:R,removeById:j,setMarker:g}},[Z,P,M,L,z,k,c,b,S,R,j,g]),(0,n.useEffect)(()=>{p.length>0&&void 0!==f&&x(!0)},[p,f]),(0,n.useEffect)(()=>{let e=()=>{w===y&&(I.current.setGlobalPid(null),I.current.addMessage({type:"warning",message:"Playback has been paused. You can avoid this issue by keeping the player open in a separate tab or window."}),I.current.pause())};return window.addEventListener("beforeunload",e),()=>{window.removeEventListener("beforeunload",e)}},[y,w]),(0,n.useEffect)(()=>
1{if("mediaSession"in navigator&&T){let e=T.seriesExternalCoverPatakaId?`https://${e$}/image/upload/t_kt-podcast-media-session-cover/${T.seriesExternalCoverPatakaId}.jpg`:null,t=T.images,s=t?.detail_x2??t?.detail_2x;navigator.mediaSession.metadata=new MediaMetadata({title:T.title,artist:T.context??"Radio New Zealand",artwork:(e?[{src:e,sizes:"512x512",type:"image/jpeg"}]:s?[{src:s,sizes:"512x512",type:"image/jpeg"}]:[])??[]})}return()=>{"mediaSession"in navigator&&(navigator.mediaSession.metadata=null)}},[T]),(0,n.useEffect)(()=>{if(!m)return;let e=t.current;if(!e||!O)return;let a=O.includes(".m3u8"),r=!1;return a?s.e(3576).then(s.bind(s,26276)).then(({default:t})=>{if(!r)if(t.isSupported()){i.current&&i.current.destroy();let s=new t;i.current=s,s.loadSource(O),s.attachMedia(e),s.on(t.Events.MANIFEST_PARSED,()=>{I.current.setIsLoading(!1)}),s.on(t.Events.ERROR,(e,a)=>{if(a.fatal)switch(a.type){case t.ErrorTypes.NETWORK_ERROR:s.startLoad();break;case t.ErrorTypes.MEDIA_ERROR:s.recoverMediaError();break;default:I.current.setError("HLS playback error")}})}else e.canPlayType("application/vnd.apple.mpegurl")?e.src=O:I.current.setError("HLS is not supported in this browser")}).catch(e=>{r||(console.error("Failed to load the audio player (hls.js):",e),I.current.setError("Unable to load the audio player"),I.current.setIsLoading(!1))}):e.src=O,I.current.setIsLoading(!0),()=>{r=!0,i.current&&(i.current.destroy(),i.current=null)}},[O,m]),(0,n.useEffect)(()=>{l.current=V},[V]),(0,n.useEffect)(()=>{if(!m)return;let e=t.current;if(!e)return;let s=T?.id,a=new AbortController;return N&&(I.current.setError(null),e.currentTime=l.current,F&&e.play().then(()=>{a.signal.aborted||(I.current.setLastPlayedId(s),I.current.setIsLoading(!1))}).catch(e=>{a.signal.aborted||e instanceof DOMException&&"AbortError"===e.name||(console.error("Error playing audio:",e),I.current.setError("Error playing audio"),I.current.setIsLoading(!1),I.current.pause())})),N||(e.pause(),I.current.setIsLoading(!1)),()=>{a.abort()}},[N,T,F,m]),(0,n.useEffect)(()=>{if(!m)return;let e=t.current;if(!e)return;let s=p[f]?.id;s&&o!==s&&(I.current.setLastPlayedId(s),p.map(e=>e.id).includes(s)&&(e.currentTime=v(s)??0))},[p,o,f,v,m]),(0,n.useEffect)(()=>{!m||t.current&&(t.current.playbackRate=A)},[A,m]),h&&m)?(0,a.jsxs)(a.Fragment,{children:[!1,e,(0,a.jsx)("audio",{ref:t,onPlay:k,onEnded:()=>{t.current&&p.length-1!==f&&(I.current.pause(),I.current.removeById(T?.id),I.current.setMarker(Math.min(p.length-1,f+1)),I.current.play())},onTimeUpdate:()=>{t.current&&(E||I.current.setAudioCurrentTime(Math.floor(t.current.currentTime)),I.current.updateDuration(T?.id,t.current.currentTime))},onDurationChange:()=>{t.current&&I.current.setAudioDuration(Math.floor(t.current.duration))},onCanPlay:()=>{if(!h||!m)return null;I.current.setIsLoading(!1),N&&F&&t.current?.play().catch(console.error)},onPause:L,controls:!0,"aria-hidden":!0,hidden:!0})]}):null},e_={production:{live:1200,regularUpdate:60},development:{live:1200,regularUpdate:60}}["production"!==s(37811).env.VERCEL_ENV?"development":"production"],eK=e_.live,eq=e_.regularUpdate,eG=()=>{let{isPlaying:e,audioCurrentTime:t,audioDuration:s,globalPid:a}=(0,d.E)(),{localPid:r}=(0,d.x)(),{items:i,marker:l}=(0,u.M)(),o=i[l],c=(0,n.useRef)(!1),m=(0,n.useRef)(0),h=(0,n.useRef)(0),p=(0,n.useRef)(0),f=(0,n.useRef)(Date.now()),g=(0,n.useRef)(0),b=(0,n.useRef)(Date.now()),j=(0,n.useRef)(!1);return(0,n.useEffect)(()=>{j.current=r===a},[r,a]),(0,n.useEffect)(()=>{c.current=!1,p.current=0,g.current=0,f.current=Date.now(),b.current=Date.now()},[o?.id]),(0,n.useEffect)(()=>{if(o&&e&&j.current){let e={event:"audio_play",id:o?.id??null,episodeTitle:o?.title??null,podcastName:o?.context??null,liveStreamName:o?.liveStreamName??null,episodeNumber:o?.episodeNumber??null,episodeReleaseDate:o?.releaseDate??null,seasonNumber:o?.seasonNumber??null,duration:o?.duration??null,playback_begin_url:o?.playbackBeginUrl??null};(0,x.BT)(e)}},[e,o]),(0,n.useEffect)(()=>{if(!o||!e||o.liveStreamName)return;b.current=Date.now();let t=setInterval(()=>{if(!j.current)return;let e=Date.now(),t=(e-b.current)/1e3;if(b.current=e,g.current+=t,g.current>=eq){g.current=0;let e={event:"audio_engagement_ondemand",audio_duration:o.duration??null,audio_id:o.id??null,listening_duration:Math.floor(m.current)??null,audio_title:o.title??null,episode_number:o.episodeNumber??null,episode_title:o.title??null,podcast_name:o.context??null,season_number:o.seasonNumber??null};(0,x.BT)(e)}},1e3);return()=>clearInterval(t)},[o,e]),(0,n.useEffect)(()=>
1{if(!o?.liveStreamName||!e)return;f.current=Date.now();let t=setInterval(()=>{if(!j.current)return;let e=Date.now(),t=(e-f.current)/1e3;if(f.current=e,p.current+=t,p.current>=eK&&!c.current){c.current=!0;let e={event:"audio_engagement_live",liveStreamName:o.liveStreamName??null};(0,x.BT)(e)}},1e3);return()=>clearInterval(t)},[o,e]),(0,n.useEffect)(()=>{m.current=t,h.current=s},[t,s]),null},eQ=({id:e})=>{let[t,s]=(0,n.useState)(!1),[u,x]=(0,n.useState)(!1),[h,p]=(0,n.useState)(!1),[f,g]=(0,n.useState)(null),b=(0,r.DE)(),j=(0,l.I)(),v=(0,i.Ub)("(min-width: 768px)",{initializeWithValue:!0}),{isPlaying:y}=(0,d.E)(),{playTrigger:w,setPlayTrigger:N}=(0,d.x)(),{playerSize:C,setPlayerSize:L}=(0,m.h)();!function({playerSize:e,setPlayerSize:t,dialogOpen:s,setDialogOpen:a}){let r=(0,n.useRef)(null);(0,n.useEffect)(()=>{let i=()=>{("expanded"===e||s)&&(r.current={playerSize:e,dialogOpen:s},t("mini"),a(!1))},n=()=>{r.current&&(t(r.current.playerSize),a(r.current.dialogOpen),r.current=null)};return window.addEventListener("beforeprint",i),window.addEventListener("afterprint",n),()=>{window.removeEventListener("beforeprint",i),window.removeEventListener("afterprint",n)}},[e,t,s,a])}({playerSize:C,setPlayerSize:L,dialogOpen:h,setDialogOpen:p});let k={initial:{opacity:0}
1,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2,ease:"easeInOut"}},A={initial:{y:"100%"},animate:{y:"0%"},exit:{y:"100%"},transition:{duration:.3,ease:"easeInOut"}},S=e=>{"Escape"===e.key&&w&&(v||!v&&"expanded"!==C)&&(w.focus(),N(null))};return((0,n.useEffect)(()=>{t&&x(!0)},[t]),(0,n.useEffect)(()=>(w&&(w.setAttribute("data-player-trigger","true"),window.addEventListener("keydown",S)),()=>{w&&(w.removeAttribute("data-player-trigger"),window.removeEventListener("keydown",S))}),[w]),(0,n.useEffect)(()=>{"expanded"!==C||v||p(!0)},[C]),(0,n.useEffect)(()=>{y&&"closed"===C&&L("mini")},[y,C,L]),b)?(0,a.jsxs)(eU,{children:[(0,a.jsx)(V.lG,{open:h,onOpenChange:e=>{p(e),h&&L("mini")},children:(0,a.jsxs)("div",{className:"z-player focus-outline-alt w-player:max-w-[calc(38rem*var(--base-multiplier))] fixed bottom-0 right-[var(--page-scrollbar-width)] w-[calc(100%-var(--page-scrollbar-width))] print:hidden",children:[(0,a.jsx)(o.N,{initial:!1,children:"expanded"===C&&(0,a.jsx)(c.P.div,{...j?k:A,className:"absolute bottom-0 left-0 right-0",children:(0,a.jsx)(eO,{id:e,dialogOpen:h,setDialogOpen:p,dialogContainer:f,isDesktop:v,canFocusPlayer:u,setHasPlayerComponentsMounted:s,progressBar:(0,a.jsx)(eJ,{})},"desktop-expanded-player")})}),(0,a.jsx)(o.N,{initial:!1,children:"mini"===C&&(0,a.jsx)(c.P.div,{...j?k:A,className:"absolute bottom-0 left-0 right-0",children:(0,a.jsx)(J,{id:e,canFocusPlayer:u,hasPlayerComponentsMounted:t,setHasPlayerComponentsMounted:s,progressBar:(0,a.jsx)(eJ,{isInteractive:!1})},"mini-player")})})]})}),(0,a.jsx)("div",{ref:g,className:"print:hidden"}),(0,a.jsx)(eG,{})]}):null}}},e=>{e.O(0,[8676,5106,7130,9109,610,9897,7407,9647,3174,4121,6575,1921,6943,7163,128,9467,1266,6913,3216,9020,9712,3807,5229,7358],()=>e(e.s=40901)),_N_E=e.O()}]);
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.