1import{_ as y}from"./DTi0P79d.js";import{d as w,a as $,c as p,o as b,p as v,e as r,h as k,w as C,l as g,b as n,g as s,f as c,t as E}from"./01aceCaE.js";import{u as T}from"./ICS24BcA.js";import"./BEHD0UYf.js";const M={class:"container mx-auto px-4 py-8 max-w-4xl mt-[66px]"},U={key:0,class:"flex justify-center items-center py-12"},Z={key:1,class:"prose prose-gray max-w-none"},B=["innerHTML"],D={key:2,class:"text-center py-12"},F={class:"text-gray-500"},I=w({__name:"cgus",setup(H){const{t:u,locale:t}=$(),i=p(()=>t.value==="fr"?"Conditions Générales d'Utilisation ExpertZoom":"Terms of Use ExpertZoom"),m=p(()=>t.value==="fr"?"Conditions Générales d'Utilisation de la plateforme ExpertZoom":"Terms of Use for the ExpertZoom platform");T({title:i,ogTitle:i,description:m,ogDescription:m,twitterCard:"summary_large_image"});const a=g(""),l=g(!0),f=e=>e.replace(/\r\n?/g,` 2`).replace(/^# (.*$)/gm,'<h1 class="text-3xl font-bold mb-8 text-gray-800">$1</h1>').replace(/^## (.*$)/gm,'<h2 class="text-xl font-semibold text-gray-700 mb-4 mt-8">$1</h2>').replace(/^### (.*$)/gm,'<h3 class="text-lg font-semibold text-gray-700 mb-3 mt-6">$1</h3>').replace(/\*\*(.*?)\*\*/g,"<strong>$1</strong>").replace(/\[([^\]]+)\]\(([^)]+)\)/g,'<a href="$2" class="text-blue-600 hover:underline">$1</a>').replace(/^- (.*$)/gm,'<li class="ml-4">$1</li>').replace(/^<li[^\n]*<\/li>(?:\n+<li[^\n]*<\/li>)*/gm,'<ul class="list-disc pl-6 mt-2 space-y-2 mb-4">$&</ul>').replace(/^(?!<[h|u|l])(.*$)/gm,'<p class="mb-4 text-gray-600 leading-relaxed">$1</p>').replace(/<p class="mb-4 text-gray-600 leading-relaxed"><\/p>/g,""),x=async()=>{try{return(await $fetch(`/region/legal/${t.value}`)).cgv_content}catch{return console.log("API legal content not available, falling back to static file"),null}},h=async()=>{const e=t.value==="fr"?"fr.md":"en.md",o=await fetch(`/components/cgv/${e}`);if(!o.ok)throw new Error(`Failed to load ${e}`);return o.text()},d=async()=>{try{l.value=!0;let e=await x();e||(e=await h()),a.value=f(e)}catch(e){console.error("Error loading legal content:",e),a.value=""}finally{l.value=!1}};return b(()=>{d()}),v(t,()=>{d()}),(e,o)=>{const _=y;return n(),r("div",M,[k(_,{class:"p-8 bg-white shadow-none border-none"},{default:C(()=>[s(l)?(n(),r("div",U,[...o[0]||(o[0]=[c("div",{class:"animate-spin rounded-full h-8 w-8 border-b-2 border-gray-900"},null,-1)])])):s(a)?(n(),r("div",Z,[c("div",{innerHTML:s(a)},null,8,B)])):(n(),r("div",D,[c("p",F,E(s(u)("common.errorLoadingContent")),1)]))]),_:1})])}}});export{I as default};
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.