1import{e as d,N as p,f,X as v,Y as g,z as h,n as _,L as y,p as S,O as r,o as w}from"./BN-If_5M.js";import{T as x}from"./CUckTKUz.js";const N=d({__name:"like",props:r({eventId:{type:String,required:!0},eventName:{type:String,default:void 0},size:{type:String,default:"small"},user:{type:Object,default:void 0}},{modelValue:{type:Boolean,required:!0},modelModifiers:{}}),emits:r(["change"],["update:modelValue"]),setup(e,{emit:n}){const t=p(e,"modelValue"),a=n,u=f(),{openLoginDialog:l}=v(),o=e,{trackSaveEvent:c}=g();async function m(s){if(s.preventDefault(),s.stopPropagation(),!o.user){l(u.fullPath);return}try{t.value=!t.value,t.value?(await $fetch(`/api/v1/events/${o.eventId}/like`,{method:"POST"}),c({id:o.eventId,name:o.eventName})):await $fetch(`/api/v1/events/${o.eventId}/like`,{method:"DELETE"}),a("change")}catch(i){console.error(i),t.value=!t.value}}return(s,i)=>h((w(),_(S,{icon:t.value?"mdi-heart":"mdi-heart-outline",onClick:y(m,["stop","prevent"]),size:o.size},null,8,["icon","size"])),[[x,t.value?"J'aime plus":"J'aime"]])}}),O=Object.assign(N,{__name:"ButtonLike"}),L=new Set(["nexus","nexus poitiers"]),k=new Set(["nexus","nexus-poitiers"]);function z(e){const n=e.organizationName?.trim().toLowerCase();if(n&&L.has(n))return!0;const a=(e.organizationUrl?.trim().toLowerCase()??"").match(/\/organizations\/([^/?#]+)/)?.[1];return!!(a&&k.has(a))}function D(e){return e.poweredByNexus||e.placeLoyaltyEnabled?!0:z(e)}export{O as _,D as s};
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.