PageSourceSearch

https://www.wellingtonnz.com/_nuxt/BTInGQgp.js

js wellingtonnz.com collected 2026-09-24 09:29:11 UTC 1,708 bytes, 1 lines download raw bytes

1import{o as R,a1 as m,bd as y,B,W as n,r as C,j as M,T as k,e as S,a as T,b as p,F as x,k as o,n as L,_ as I}from"./B8rRnRRV.js";const $=({id:s,title:d})=>{const t=B(!1);R(()=>{const e=m();y(()=>e.has(s),c=>t.value=c)});const a=()=>m().toggle(s),u=n(()=>t.value?"Remove from favourites":"Add to favourites"),i=n(()=>t.value?"Remove from favourites":"Add to favourites"),r=n(()=>{const e=d||"Item";return t.value?`${e} has been added to your favourites.`:`${e} has been removed from your favourites.`});return{isFavourited:t,toggle:a,ariaLabel:u,buttonTitle:i,toastMessage:r}},D={class:"favourite-button-wrapper"},E=["aria-pressed","aria-label","title"],P={class:"favourite-button__icon sr-only"},j=C({__name:"FavouriteButton",props:{id:{},title:{},modifier:{}},emits:["toggled"],setup(s,{emit:d}){const t=d,a=s,u=M(),{appStore:i}=k(),r=n(()=>u.path==="/favourites"&&!u.query.ids),{isFavourited:e,toggle:c,ariaLabel:_,buttonTitle:b}=$({id:a.id,title:a.title}),h=n(()=>r.value?"Remove from favourites":_.value),g=n(()=>r.value?"Remove from favourites":b.value);let l=null;const w=v=>{v.preventDefault(),v.stopPropagation();const f=c();t("toggled",{id:a.id,isFavourited:f,title:a.title})},F=()=>{l=i.cursor.shown,i.cursor.shown=!1},A=()=>{l!==null&&(i.cursor.shown=l,l=null)};return(v,f)=>(S(),T("div",D,[p("button",{type:"button",class:L(["favourite-button",[{"favourite-button--active":o(e)},{"favourite-button--remove":o(r)},s.modifier&&`favourite-button--${s.modifier}`]]),"aria-pressed":o(e),"aria-label":o(h),title:o(g),onClick:w,onMouseenter:F,onMouseleave:A},[p("span",P,x(o(r)||o(e)?"Remove from favourites":"Add to favourites"),1)],42,E)]))}}),z=I(j,[["__scopeId","data-v-d793253d"]]);export{z as _};

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.