PageSourceSearch

https://roadiceland.com/_next/static/chunks/0491kin6fdw5d.js?dpl=dpl_2PQ94prwtHo5P4hpSEKMiA1ZopjB

js roadiceland.com collected 2026-09-24 14:18:18 UTC 83,137 bytes, 5 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,370317,e=>{"use strict";var t=e.i(843476),r=e.i(152236);e.s(["Card",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card",className:(0,r.cn)("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",e),...a})},"CardContent",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card-content",className:(0,r.cn)("px-6",e),...a})},"CardDescription",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card-description",className:(0,r.cn)("text-muted-foreground text-sm",e),...a})},"CardFooter",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card-footer",className:(0,r.cn)("[.border-t]:pt-6 flex items-center px-6",e),...a})},"CardHeader",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card-header",className:(0,r.cn)("@container/card-header has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6 grid auto-rows-min grid-rows-[auto_auto] items-start gap-1.5 px-6",e),...a})},"CardTitle",0,function({className:e,...a}){return(0,t.jsx)("div",{"data-slot":"card-title",className:(0,r.cn)("font-semibold leading-none",e),...a})}])},546467,e=>{"use strict";let t=(0,e.i(475254).default)("external-link",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);e.s(["default",0,t])},778917,e=>{"use strict";var t=e.i(546467);e.s(["ExternalLink",()=>t.default])},705008,e=>{"use strict";let t="id, code_iso, english_name, french_name, country_capital_latitude, country_capital_longitude, country_center_latitude, country_center_longitude, currency_code, cover_image_s3_key",r=`*, user_itinerary(*, expense(*, booking(*)), place(*)), country(${t}), expense(*), booking(*), users(*)`,a=`*, country(${t})`;async function i(e,t,a){if(!t)throw Error("User ID is required");if(a){let{data:i,error:n}=await e.from("itinerary_planner").select(r).eq("user_id",t).eq("mode",a).eq("active",1).order("publication_date",{ascending:!1});if(n)throw console.warn("[getUserItineraries] Error :",n),n;return i}{let{data:a,error:i}=await e.from("itinerary_planner").select(r).eq("user_id",t).eq("active",1).order("publication_date",{ascending:!1});if(i)throw console.warn("[getUserItineraries] Error :",i),i;return a}}async function n(e,t,r){if(!t)throw Error("User ID is required");let i=e.from("itinerary_planner").select(a).eq("user_id",t).eq("active",1).order("publication_date",{ascending:!1});r&&(i=i.eq("mode",r));let{data:n,error:s}=await i;if(s)throw console.warn("[getItineraryPlannersListByUserId] Error :",s),s;return n}async function s(e,t,a){let{data:i,error:n}=await e.from("itinerary_planner").select(r).eq("id",a).eq("active",1).limit(1);if(n)throw console.warn("[getUserItineraryById] Error :",n),n;return i?.[0]}async function o(e,t){let{data:r,error:a}=await e.from("itinerary_planner").select("id").eq("code",t).eq("active",1).limit(1).single();return a?(console.warn("[getItineraryPlannerIdByCode] Error :",a),null):r?.id??null}async function l(e,t,a="en"){let{data:i,error:n}=await e.from("itinerary_planner").select(r).eq("country",t).eq("highlight",1).eq("active",1).eq("language",a).order("publication_date",{ascending:!1});if(n)throw console.warn("[getHighlightedItineraryPlannersByCountryId] Error :",n),n;return i}async function d(e,t){let r={...t,publication_date:new Date().toISOString(),publication_update:new Date().toISOString()},{data:a,error:i}=await e.from("itinerary_planner").insert(r).select("*");if(i)throw console.warn("[createItineraryPlanner] Error :",i),i;return a}async function c(e,t){let{error:r}=await e.from("booking").delete().eq("itinerary_id",t);if(r)throw console.warn("[deleteItineraryPlanner] Error deleting bookings:",r),r;let{error:a}=await e.from("expense").delete().eq("project_id",t);if(a)throw console.warn("[deleteItineraryPlanner] Error deleting expenses:",a),a;let{error:i}=await e.from("user_itinerary").delete().eq("itinerary_id",t);if(i)throw console.warn("[deleteItineraryPlanner] Error deleting user itineraries:",i),i;let{error:n}=await e.from("itinerary_planner").delete().eq("id",t);if(n)throw console.warn("[deleteItineraryPlanner] Error :",n),n}async function u(e,t,r){let a={...r,publication_update:new Date().toISOString()},{data:i,error:n}=await e.from("itinerary_planner").update(a).eq("id",t).select("*, user_itinerary(*, place(*)), country(*)");if(n)throw console.warn("[updateItineraryPlanner] Error :",n),n;if(!i)throw console.warn("[updateItineraryPlanner] No data returned"),Error("No data returned");let s=i?.[0];if(void 0!==a.start_date||void 0!==a.end_date)try{await p(e,t)}catch(e){console.warn("[updateItineraryPlanner] Error updating days count after date change:",e)}return s}
1async function h(e,t){let{count:r,error:a}=await e.from("user_itinerary").select("*",{count:"exact",head:!0}).eq("itinerary_id",t).eq("active",1);if(a)throw console.warn("[updateItineraryPlannerStepsCount] Error counting steps:",a),a;let{error:i}=await e.from("itinerary_planner").update({steps:r??0}).eq("id",t);if(i)throw console.warn("[updateItineraryPlannerStepsCount] Error updating steps:",i),i}async function p(e,t){let{data:r,error:a}=await e.from("user_itinerary").select("day_position").eq("itinerary_id",t).eq("active",1).order("day_position",{ascending:!1}).limit(1);if(a)throw console.warn("[updateItineraryPlannerDaysCount] Error getting max day position:",a),a;let i=r&&r.length>0?r[0]?.day_position??0:0,{data:n,error:s}=await e.from("itinerary_planner").select("start_date, end_date").eq("id",t).single();if(s)throw console.warn("[updateItineraryPlannerDaysCount] Error getting planner dates:",s),s;let o=0;if(n?.start_date&&n?.end_date){let e=new Date(n.start_date),t=new Date(n.end_date);e.setHours(0,0,0,0),t.setHours(0,0,0,0),o=Math.round((t.getTime()-e.getTime())/864e5)+1}let l=Math.max(i??0,o,1),{error:d}=await e.from("itinerary_planner").update({day:l}).eq("id",t);if(d)throw console.warn("[updateItineraryPlannerDaysCount] Error updating days:",d),d}async function m(e,t,a){if(!a)throw Error("New user ID is required");let{data:i,error:n}=await e.from("itinerary_planner").select(r).eq("id",t).limit(1);if(n)throw console.warn("[duplicateItineraryPlanner] Error fetching original planner:",n),n;if(!i?.[0])throw Error("Original itinerary planner not found");let s=i[0],o={active:s.active,budget:s.budget,calendar:s.calendar,comment_id:s.comment_id,country:"object"==typeof s.country&&s.country?s.country.id:s.country,currency:s.currency,date_format:s.date_format,day:s.day,description:s.description,distance:s.distance,domain:s.domain,end_date:s.end_date,highlight:0,image_name:s.image_name,language:s.language,mesure_format:s.mesure_format,mode:s.mode,nb_people_adult:s.nb_people_adult,nb_people_children:s.nb_people_children,parameters:s.parameters,payment_wall:s.payment_wall,premium_wall:s.premium_wall,publication_date:new Date().toISOString(),publication_update:new Date().toISOString(),seo_canonical:s.seo_canonical,seo_description:s.seo_description,seo_url:s.seo_url,start_date:s.start_date,steps:s.steps,time_format:s.time_format,title:`${s.title} (Copie)`,transport:s.transport,user_id:a,visibility:0,countries:s.countries},{data:l,error:d}=await e.from("itinerary_planner").insert(o).select("*").single();if(d)throw console.warn("[duplicateItineraryPlanner] Error creating new planner:",d),d;if(!l)throw Error("Failed to create new itinerary planner");if(s.user_itinerary&&s.user_itinerary.length>0){let t=s.user_itinerary.map(e=>({active:e.active,activity_id:e.activity_id,address:e.address,comment:e.comment,cost:e.cost,country_id:e.country_id,currency_cost:e.currency_cost,date_cost:e.date_cost,day_position:e.day_position,description:e.description,description_cost:e.description_cost,distance_to_next_place:e.distance_to_next_place,end_time:e.end_time,image_id:e.image_id,img_url:e.img_url,ispaid_cost:e.ispaid_cost,itinerary_id:l.id,label:e.label,latitude:e.latitude,longitude:e.longitude,manual_to_next_place:e.manual_to_next_place,map_position:e.map_position,mode:e.mode,mode_to_next_place:e.mode_to_next_place,name:e.name,opening_hours:e.opening_hours,phone_number:e.phone_number,position:e.position,premium_unlock:e.premium_unlock,publication_date:new Date().toISOString(),rating:e.rating,rating_number:e.rating_number,rename_place:e.rename_place,service_id:e.service_id,start_time:e.start_time,time_onsite:e.time_onsite,time_to_next_place:e.time_to_next_place,type:e.type,type_cost:e.type_cost,update_date:new Date().toISOString(),user_id:a,website:e.website,is_macro_anchor:e.is_macro_anchor,duration_nights:e.duration_nights,is_macro_locked:e.is_macro_locked,macro_start_date:e.macro_start_date,macro_end_date:e.macro_end_date,macro_dayposition_group:e.macro_dayposition_group,nature:e.nature,flags:e.flags})),{error:r}=await e.from("user_itinerary").insert(t);if(r)throw console.warn("[duplicateItineraryPlanner] Error creating user itineraries:",r),await e.from("itinerary_planner").delete().eq("id",l.id),r}if(s.expense&&Array.isArray(s.expense)&&s.expense.length>
10){let t=s.expense.filter(e=>!e.booking_id);if(t.length>0){let r=t.map(e=>({amount:e.amount,card_id:e.card_id,category:e.category,comments:e.comments,currency:e.currency,exclude_from_average:e.exclude_from_average,expense_date:e.expense_date,payer_ids:e.payer_ids,payment_method:e.payment_method,project_id:l.id,status:e.status,title:e.title,visibility:e.visibility})),{error:a}=await e.from("expense").insert(r);if(a)throw console.warn("[duplicateItineraryPlanner] Error creating expenses:",a),await e.from("user_itinerary").delete().eq("itinerary_id",l.id),await e.from("itinerary_planner").delete().eq("id",l.id),a}}if(s.user_itinerary&&s.user_itinerary.length>0){let{data:t,error:r}=await e.from("user_itinerary").select("id, position").eq("itinerary_id",l.id).order("position");if(r)console.warn("[duplicateItineraryPlanner] Error fetching new user itineraries for expenses:",r);else if(t){let r=new Map;t.forEach(e=>{r.set(e.position,e.id)});let a=[];if(s.user_itinerary.forEach(e=>{if(e.expense&&Array.isArray(e.expense)&&e.expense.length>0){let t=r.get(e.position);
1t&&e.expense.filter(e=>!e.booking_id).forEach(r=>{a.push({expense:r,originalCardId:e.id,newCardId:t})})}}),a.length>0){let t=a.map(({expense:e,newCardId:t})=>({amount:e.amount,card_id:t,category:e.category,comments:e.comments,currency:e.currency,exclude_from_average:e.exclude_from_average,expense_date:e.expense_date,payer_ids:e.payer_ids,payment_method:e.payment_method,project_id:l.id,status:e.status,title:e.title,visibility:e.visibility})),{error:r}=await e.from("expense").insert(t);if(r)throw console.warn("[duplicateItineraryPlanner] Error creating user_itinerary expenses:",r),await e.from("expense").delete().eq("project_id",l.id),await e.from("user_itinerary").delete().eq("itinerary_id",l.id),await e.from("itinerary_planner").delete().eq("id",l.id),r}}}let{data:c,error:u}=await e.from("itinerary_planner").select(r).eq("id",l.id).limit(1);if(u)throw console.warn("[duplicateItineraryPlanner] Error fetching final planner:",u),u;return c?.[0]}e.s(["createItineraryPlanner",0,d,"deleteItineraryPlanner",0,c,"duplicateItineraryPlanner",0,m,"getHighlightedItineraryPlannersByCountryId",0,l,"getItineraryPlannerByIdAndUserId",0,s,"getItineraryPlannerIdByCode",0,o,"getItineraryPlannersByUserId",0,i,"getItineraryPlannersListByUserId",0,n,"updateItineraryPlanner",0,u,"updateItineraryPlannerStepsCount",0,h])},361277,e=>{"use strict";let t=(0,e.i(475254).default)("calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);e.s(["default",0,t])},87316,e=>{"use strict";var t=e.i(361277);e.s(["Calendar",()=>t.default])},326999,e=>{"use strict";let t,r,a;var i=e.i(271645),n=e.i(981140),s=e.i(820783),o=e.i(30030),l=e.i(610772),d=e.i(369340),c=e.i(726330),u=e.i(765491),h=e.i(774606),p=e.i(296626),m=e.i(248425),g=e.i(303536),x=e.i(985369),y=e.i(186312),f=e.i(843476),v=Symbol("radix.slottable");function w(e){return i.isValidElement(e)&&"function"==typeof e.type&&"__radixId"in e.type&&e.type.__radixId===v}var b="Dialog",[j,_]=(0,o.createContextScope)(b),[N,C]=j(b),k=e=>{let{__scopeDialog:t,children:r,open:a,defaultOpen:n,onOpenChange:s,modal:o=!0}=e,c=i.useRef(null),u=i.useRef(null),[h,p]=(0,d.useControllableState)({prop:a,defaultProp:n??!1,onChange:s,caller:b});return(0,f.jsx)(N,{scope:t,triggerRef:c,contentRef:u,contentId:(0,l.useId)(),titleId:(0,l.useId)(),descriptionId:(0,l.useId)(),open:h,onOpenChange:p,onOpenToggle:i.useCallback(()=>p(e=>!e),[p]),modal:o,children:r})};k.displayName=b;var D="DialogTrigger",I=i.forwardRef((e,t)=>{let{__scopeDialog:r,...a}=e,i=C(D,r),o=(0,s.useComposedRefs)(t,i.triggerRef);return(0,f.jsx)(m.Primitive.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":X(i.open),...a,ref:o,onClick:(0,n.composeEventHandlers)(e.onClick,i.onOpenToggle)})});I.displayName=D;var R="DialogPortal",[S,P]=j(R,{forceMount:void 0}),E=e=>{let{__scopeDialog:t,forceMount:r,children:a,container:n}=e,s=C(R,t);return(0,f.jsx)(S,{scope:t,forceMount:r,children:i.Children.map(a,e=>(0,f.jsx)(p.Presence,{present:r||s.open,children:(0,f.jsx)(h.Portal,{asChild:!0,container:n,children:e})}))})};E.displayName=R;var q="DialogOverlay",O=i.forwardRef((e,t)=>{let r=P(q,e.__scopeDialog),{forceMount:a=r.forceMount,...i}=e,n=C(q,e.__scopeDialog);return n.modal?(0,f.jsx)(p.Presence,{present:a||n.open,children:(0,f.jsx)(M,{...i,ref:t})}):null});O.displayName=q;var $=((a=i.forwardRef((e,t)=>{let{children:r,...a}=e;if(i.isValidElement(r)){var n;let e,o,l=(n=r,(o=(e=Object.getOwnPropertyDescriptor(n.props,"ref")?.get)&&"isReactWarning"in e&&e.isReactWarning)?n.ref:(o=(e=Object.getOwnPropertyDescriptor(n,"ref")?.get)&&"isReactWarning"in e&&e.isReactWarning)?n.props.ref:n.props.ref||n.ref),d=function(e,t){let r={...t};for(let a in t){let i=e[a],n=t[a];/^on[A-Z]/.test(a)?i&&n?r[a]=(...e)=>{let t=n(...e);return i(...e),t}:i&&(r[a]=i):"style"===a?r[a]={...i,...n}:"className"===a&&(r[a]=[i,n].filter(Boolean).join(" "))}return{...e,...r}}(a,r.props);return r.type!==i.Fragment&&(d.ref=t?(0,s.composeRefs)(t,l):l),i.cloneElement(r,d)}return i.Children.count(r)>1?i.Children.only(null):null})).displayName="DialogOverlay.RemoveScroll.SlotClone",t=a,(r=i.forwardRef((e,r)=>{let{children:a,...n}=e,s=i.Children.toArray(a),o=s.find(w);if(o){let e=o.props.children,a=s.map(t=>t!==o?t:i.Children.count(e)>1?i.Children.only(null):i.isValidElement(e)?e.props.children:null);return(0,f.jsx)(t,{...n,ref:r,children:i.isValidElement(e)?i.cloneElement(e,void 0,a):null})}return(0,f.jsx)(t,{...n,ref:r,children:a})})).displayName="DialogOverlay.RemoveScroll.Slot",r),M=i.forwardRef((e,t)=>
1{let{__scopeDialog:r,...a}=e,i=C(q,r);return(0,f.jsx)(x.RemoveScroll,{as:$,allowPinchZoom:!0,shards:[i.contentRef],children:(0,f.jsx)(m.Primitive.div,{"data-state":X(i.open),...a,ref:t,style:{pointerEvents:"auto",...a.style}})})}),T="DialogContent",A=i.forwardRef((e,t)=>{let r=P(T,e.__scopeDialog),{forceMount:a=r.forceMount,...i}=e,n=C(T,e.__scopeDialog);return(0,f.jsx)(p.Presence,{present:a||n.open,children:n.modal?(0,f.jsx)(U,{...i,ref:t}):(0,f.jsx)(L,{...i,ref:t})})});A.displayName=T;var U=i.forwardRef((e,t)=>{let r=C(T,e.__scopeDialog),a=i.useRef(null),o=(0,s.useComposedRefs)(t,r.contentRef,a);return i.useEffect(()=>{let e=a.current;if(e)return(0,y.hideOthers)(e)},[]),(0,f.jsx)(K,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,n.composeEventHandlers)(e.onCloseAutoFocus,e=>{e.preventDefault(),r.triggerRef.current?.focus()}),onPointerDownOutside:(0,n.composeEventHandlers)(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,r=0===t.button&&!0===t.ctrlKey;(2===t.button||r)&&e.preventDefault()}),onFocusOutside:(0,n.composeEventHandlers)(e.onFocusOutside,e=>e.preventDefault())})}),L=i.forwardRef((e,t)=>{let r=C(T,e.__scopeDialog),a=i.useRef(!1),n=i.useRef(!1);return(0,f.jsx)(K,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(a.current||r.triggerRef.current?.focus(),t.preventDefault()),a.current=!1,n.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(a.current=!0,"pointerdown"===t.detail.originalEvent.type&&(n.current=!0));let i=t.target;r.triggerRef.current?.contains(i)&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&n.current&&t.preventDefault()}})}),K=i.forwardRef((e,t)=>{let{__scopeDialog:r,trapFocus:a,onOpenAutoFocus:n,onCloseAutoFocus:o,...l}=e,d=C(T,r),h=i.useRef(null),p=(0,s.useComposedRefs)(t,h);return(0,g.useFocusGuards)(),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(u.FocusScope,{asChild:!0,loop:!0,trapped:a,onMountAutoFocus:n,onUnmountAutoFocus:o,children:(0,f.jsx)(c.DismissableLayer,{role:"dialog",id:d.contentId,"aria-describedby":d.descriptionId,"aria-labelledby":d.titleId,"data-state":X(d.open),...l,ref:p,onDismiss:()=>d.onOpenChange(!1)})}),(0,f.jsxs)(f.Fragment,{children:[(0,f.jsx)(J,{titleId:d.titleId}),(0,f.jsx)(Z,{contentRef:h,descriptionId:d.descriptionId})]})]})}),B="DialogTitle",H=i.forwardRef((e,t)=>{let{__scopeDialog:r,...a}=e,i=C(B,r);return(0,f.jsx)(m.Primitive.h2,{id:i.titleId,...a,ref:t})});H.displayName=B;var z="DialogDescription",F=i.forwardRef((e,t)=>{let{__scopeDialog:r,...a}=e,i=C(z,r);return(0,f.jsx)(m.Primitive.p,{id:i.descriptionId,...a,ref:t})});F.displayName=z;var Y="DialogClose",Q=i.forwardRef((e,t)=>{let{__scopeDialog:r,...a}=e,i=C(Y,r);return(0,f.jsx)(m.Primitive.button,{type:"button",...a,ref:t,onClick:(0,n.composeEventHandlers)(e.onClick,()=>i.onOpenChange(!1))})});function X(e){return e?"open":"closed"}Q.displayName=Y;var W="DialogTitleWarning",[G,V]=(0,o.createContext)(W,{contentName:T,titleName:B,docsSlug:"dialog"}),J=({titleId:e})=>{let t=V(W),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
2
3If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
4
5For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return i.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},Z=({contentRef:e,descriptionId:t})=>{let r=V("DialogDescriptionWarning"),a=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${r.contentName}}.`;return i.useEffect(()=>{let r=e.current?.getAttribute("aria-describedby");t&&r&&(document.getElementById(t)||console.warn(a))},[a,e,t]),null};e.s(["Close",0,Q,"Content",0,A,"Description",0,F,"Overlay",0,O,"Portal",0,E,"Root",0,k,"Title",0,H,"Trigger",0,I,"WarningProvider",0,G,"createDialogScope",0,_],326999)},282879,e=>{"use strict";var t=e.i(843476),r=e.i(271645),a=e.i(326999),i=e.i(37727),n=e.i(152236);let s=a.Root,o=a.Trigger,l=a.Portal,d=a.Close,c=r.forwardRef(({className:e,...r},i)=>(0,t.jsx)(a.Overlay,{ref:i,className:(0,n.cn)("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/80",e),...r}));c.displayName=a.Overlay.displayName;let u=r.forwardRef(({className:e,children:r,...s},o)=>(0,t.jsxs)(l,{children:[(0,t.jsx)(c,{}),(0,t.jsxs)(a.Content,{ref:o,className:(0,n.cn)("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed left-[50%] top-[50%] z-50 grid max-h-[calc(100svh-2rem)] w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 overscroll-contain rounded-none border px-4 shadow-lg duration-200 sm:max-h-[95vh] sm:rou
5nded-lg sm:p-6","scrollbar-lite overflow-y-auto",e),...s,children:[r,(0,t.jsxs)(a.Close,{className:"ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute right-4 top-4 rounded-sm opacity-70 transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-offset-2 disabled:pointer-events-none",children:[(0,t.jsx)(i.X,{className:"h-4 w-4"}),(0,t.jsx)("span",{className:"sr-only",children:"Close"})]})]})]}));u.displayName=a.Content.displayName;let h=({className:e,...r})=>(0,t.jsx)("div",{className:(0,n.cn)("flex flex-col space-y-1.5 text-center sm:text-left",e),...r});h.displayName="DialogHeader";let p=({className:e,...r})=>(0,t.jsx)("div",{className:(0,n.cn)("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",e),...r});p.displayName="DialogFooter";let m=r.forwardRef(({className:e,...r},i)=>(0,t.jsx)(a.Title,{ref:i,className:(0,n.cn)("text-lg font-semibold leading-none tracking-tight",e),...r}));m.displayName=a.Title.displayName;let g=r.forwardRef(({className:e,...r},i)=>(0,t.jsx)(a.Description,{ref:i,className:(0,n.cn)("text-muted-foreground text-sm",e),...r}));g.displayName=a.Description.displayName,e.s(["Dialog",0,s,"DialogClose",0,d,"DialogContent",0,u,"DialogDescription",0,g,"DialogFooter",0,p,"DialogHeader",0,h,"DialogOverlay",0,c,"DialogPortal",0,l,"DialogTitle",0,m,"DialogTrigger",0,o])},717521,e=>{"use strict";let t=(0,e.i(475254).default)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);e.s(["default",0,t])},531278,e=>{"use strict";var t=e.i(717521);e.s(["Loader2",()=>t.default])},757119,e=>{"use strict";var t=e.i(266027);function r(e){return["s3-signed-url",e].filter(Boolean)}async function a(e,t){let r=await fetch(`/api/s3/signed-url?key=${encodeURIComponent(e)}&expiresIn=${t}`);if(!r.ok){let e=Error(`Signed URL request failed: ${r.status}`);throw e.status=r.status,e}return(await r.json()).url??null}e.s(["generateS3SignedUrlQueryKey",0,r,"useS3SignedUrl",0,function(e,i=300){return(0,t.useQuery)({queryKey:r(e),queryFn:()=>e?a(e,i).catch(e=>(console.error("[useS3SignedUrl] error",e),null)):null,enabled:!!e,staleTime:Math.max(0,(i-10)*1e3),gcTime:1e3*i,retry:(e,t)=>!!t&&"object"==typeof t&&"status"in t&&403===t.status&&e<2})}])},984505,e=>{"use strict";var t=e.i(843476),r=e.i(794527),a=e.i(152236);function i({...e}){return(0,t.jsx)(r.Drawer.Portal,{"data-slot":"drawer-portal",...e})}function n({className:e,...i}){return(0,t.jsx)(r.Drawer.Overlay,{"data-slot":"drawer-overlay",className:(0,a.cn)("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",e),...i})}e.s(["Drawer",0,function({...e}){return(0,t.jsx)(r.Drawer.Root,{"data-slot":"drawer",...e})},"DrawerContent",0,function({className:e,children:s,...o}){return(0,t.jsxs)(i,{"data-slot":"drawer-portal",children:[(0,t.jsx)(n,{}),(0,t.jsxs)(r.Drawer.Content,{"data-slot":"drawer-content",className:(0,a.cn)("group/drawer-content bg-background fixed z-50 flex h-auto flex-col","data-[vaul-drawer-direction=top]:inset-x-0 data-[vaul-drawer-direction=top]:top-0 data-[vaul-drawer-direction=top]:mb-24 data-[vaul-drawer-direction=top]:max-h-[80vh] data-[vaul-drawer-direction=top]:rounded-b-lg data-[vaul-drawer-direction=top]:border-b","data-[vaul-drawer-direction=bottom]:inset-x-0 data-[vaul-drawer-direction=bottom]:bottom-0 data-[vaul-drawer-direction=bottom]:mt-24 data-[vaul-drawer-direction=bottom]:max-h-[80vh] data-[vaul-drawer-direction=bottom]:rounded-t-lg data-[vaul-drawer-direction=bottom]:border-t","data-[vaul-drawer-direction=right]:inset-y-0 data-[vaul-drawer-direction=right]:right-0 data-[vaul-drawer-direction=right]:w-3/4 data-[vaul-drawer-direction=right]:border-l data-[vaul-drawer-direction=right]:sm:max-w-sm","data-[vaul-drawer-direction=left]:inset-y-0 data-[vaul-drawer-direction=left]:left-0 data-[vaul-drawer-direction=left]:w-3/4 data-[vaul-drawer-direction=left]:border-r data-[vaul-drawer-direction=left]:sm:max-w-sm",e),...o,children:[(0,t.jsx)("div",{className:"bg-muted mx-auto mt-4 hidden h-2 w-[100px] shrink-0 rounded-full group-data-[vaul-drawer-direction=bottom]/drawer-content:block"}),s]})]})},"DrawerDescription",0,function({className:e,...i}){return(0,t.jsx)(r.Drawer.Description,{"data-slot":"drawer-description",className:(0,a.cn)("text-muted-foreground text-sm",e),...i})},"DrawerFooter",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"drawer-footer",className:(0,a.cn)("mt-auto flex flex-col gap-2 p-4",e),...r})},"DrawerHeader",0,function({className:e,...r}){return(0,t.jsx)("div",{"data-slot":"drawer-header",className:(0,a.cn)("flex flex-col gap-0.5 p-4 group-data-[vaul-drawer-direction=bottom]/drawer-content:text-center group-data-[vaul-drawer-direction=top]/drawer-content:text-center md:gap-1.5 md:text-left",e),...r})},"DrawerTitle",0,function({className:e,...i}){return(0,t.jsx)(r.Drawer.Title,{"data-slot":"drawer-title",className:(0,a.cn)("text-foreground font-semibold",e),...i})},"DrawerTrigger",0,function({...e}){return(0,t.jsx)(r.Drawer.Trigger,{"data-slot":"drawer-trigger",...e})}])},428401,e=>{"use strict";var t=e.i(843476),r=e.i(522016),a=e.i(618566),i=e.i(271645),n=e.i(440087),s=e.i(984505),o=e.i(93421);e.i(785269);var l=e.i(322831),d=e.i(912598),c=e.i(613168),u=e.i(655617),h=e.i(77346),p=e.i(597911),m=e.i(387205),g=e.i(792974),x=e.i(978372),y=e.i(504515);function f({tabLabel:e,lang:a}){let i=`/${a}
5/iceland/guide/location-voiture`,s=`/${a}/iceland/guide/location-van-camping-car`,o=`/${a}/iceland/guide/comment-rejoindre-reykjavik-depuis-aeroport-keflavik`;return(0,x.useRoutePrefetch)([i,s,o]),(0,t.jsxs)(n.DropdownMenu,{children:[(0,t.jsx)(n.DropdownMenuTrigger,{asChild:!0,children:(0,t.jsxs)("button",{className:"hover:bg-brand-primary-hex-dark/10 hover:text-brand-primary-hex-dark hover:border-brand-primary-hex-dark data-[state=open]:bg-brand-primary-hex-dark/10 data-[state=open]:text-brand-primary-hex-dark data-[state=open]:border-brand-primary-hex-dark flex items-center gap-1 border-b-2 border-white px-6 py-4 text-sm font-semibold text-gray-700 transition-all",children:[e,(0,t.jsx)("svg",{className:"h-3 w-3 transition-transform",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]})}),(0,t.jsxs)(n.DropdownMenuContent,{align:"start",className:"",children:[(0,t.jsx)(n.DropdownMenuItem,{asChild:!0,className:"data-[highlighted]:bg-brand-primary-hex-dark/10 data-[highlighted]:text-brand-primary-hex-dark p-3 font-medium uppercase",children:(0,t.jsx)(r.default,{href:i,className:"flex cursor-pointer items-center gap-3",children:"Louer une voiture"})}),(0,t.jsx)(n.DropdownMenuItem,{asChild:!0,className:"data-[highlighted]:bg-brand-primary-hex-dark/10 data-[highlighted]:text-brand-primary-hex-dark p-3 font-medium uppercase",children:(0,t.jsx)(r.default,{href:s,className:"flex cursor-pointer items-center gap-3",children:"Louer un van ou un camping-car"})}),(0,t.jsx)(n.DropdownMenuItem,{asChild:!0,className:"data-[highlighted]:bg-brand-primary-hex-dark/10 data-[highlighted]:text-brand-primary-hex-dark p-3 font-medium uppercase",children:(0,t.jsx)(r.default,{href:o,className:"flex cursor-pointer items-center gap-3",children:"Bus aéroport Kéflavik ↔ Reykjavik"})})]})]})}function v({tabLabel:e,lang:a}){let i=`/${a}/iceland/guide/location-voiture`,n=`/${a}/iceland/guide/location-van-camping-car`,o=`/${a}/iceland/guide/comment-rejoindre-reykjavik-depuis-aeroport-keflavik`;return(0,x.useRoutePrefetch)([i,n,o]),(0,t.jsxs)(s.Drawer,{children:[(0,t.jsx)(s.DrawerTrigger,{asChild:!0,children:(0,t.jsxs)("button",{className:"hover:bg-brand-primary-hex-dark/10 hover:text-brand-primary-hex-dark hover:border-brand-primary-hex-dark data-[state=open]:bg-brand-primary-hex-dark/10 data-[state=open]:text-brand-primary-hex-dark data-[state=open]:border-brand-primary-hex-dark flex items-center gap-1 border-b-2 border-white px-6 py-4 text-sm font-semibold text-gray-700 transition-all",children:[e,(0,t.jsx)("svg",{className:"h-3 w-3 transition-transform",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M19 9l-7 7-7-7"})})]})}),(0,t.jsxs)(s.DrawerContent,{children:[(0,t.jsx)(s.DrawerHeader,{className:"text-left",children:(0,t.jsx)("div",{className:"flex items-center justify-between px-3",children:(0,t.jsx)(s.DrawerTitle,{className:"text-brand-primary-hex-dark text-lg font-semibold uppercase",children:e})})}),(0,t.jsx)("div",{className:"px-4 pb-4",children:(0,t.jsxs)("div",{className:"space-y-2",children:[(0,t.jsx)(r.default,{href:i,className:"hover:bg-brand-primary-hex-dark/10 hover:text-brand-primary-hex-dark flex items-center gap-3 rounded-lg p-3 font-medium uppercase transition-colors",children:"Louer une voiture"}),(0,t.jsx)(r.default,{href:n,className:"hover:bg-brand-primary-hex-dark/10 hover:text-brand-primary-hex-dark flex items-center gap-3 rounded-lg p-3 font-medium uppercase transition-colors",children:"Louer un van ou un camping-car"}),(0,t.jsx)(r.default,{href:o,className:"hover:bg-brand-primary-hex-dark/10 hover:text-brand-primary-hex-dark flex items-center gap-3 rounded-lg p-3 font-medium uppercase transition-colors",children:"Bus aéroport Kéflavik ↔ Reykjavik"})]})})]})]})}e.s(["CountryNavigation",0,function({countrySlug:e,lang:n}){let s=(0,a.usePathname)();(0,a.useRouter)();let w=(0,d.useQueryClient)();(0,i.useRef)(new Set);let b=(0,i.useRef)(new Set),{i18n:j,t:_}=(0,l.useTranslation)(),N=(0,y.normalizeLanguage)(n),C=(0,i.useMemo)(()=>{let t=(0,m.normalizeString)(e),r=(0,o.getCountryIdFromSlug)(t);return r?o.COUNTRY_ID_TO_COUNTRY_SLUG[r]??null:null},[e]),k=s===`/${n}/${e}`?"home":s.startsWith(`/${n}/${e}/itineraries`)||s.startsWith(`/${n}/${e}/itineraire`)?"itineraries":s.includes(`/${n}/${e}/guide/cartes-islande`)?"maps":s.startsWith(`/${n}/${e}/guide`)?"guides":s.startsWith(`/${n}/${e}/visit`)?"visit":s.startsWith(`/${n}/${e}/budget`)?"budget":s.startsWith(`/${n}/${e}/meteo`)||s.startsWith(`/${n}/${e}/weather`)?"weather":s.startsWith(`/${n}/${e}/deals-promos-codes`)?"deals":s.startsWith(`/${n}/${e}/professionals`)?"professionals":"home",D="fr"===n?"itineraire":"itineraries",I=[{id:"home",label:_("countryNavigation.home",{lng:n}),href:`/${n}/${e}`},{id:"itineraries",label:_("countryNavigation.itineraries",{lng:n}),href:`/${n}/${e}/${D}`},{id:"guides",label:_("countryNavigation.guides",{lng:n}),href:`/${n}/${e}/guide`},{id:"visit",label:_("countryNavigation.visit",{lng:n}),href:`/${n}/${e}/visit`},{id:"budget",label:_("countryNavigation.budget",{lng:n}),href:`/${n}/${e}/budget`},{id:"weather",label:_("countryNavigation.weather",{lng:n}),href:`/${n}/${e}/${"fr"===n?"meteo":"weather"}`},{id:"deals",label:_("countryNavigation.deals",{lng:n}),href:`/${n}/${e}/deals-promos-codes`}],R=[...I,{id:"maps",label:_("countryNavigation.maps",{lng:n}),href:`/${n}/${e}/guide/cartes-islande`},{id:"transport",label:_("countryNavigation.transport",{lng:n}),href:`/${n}/${e}/transport`,hasDropdown:!0}],S=e===o.COUNTRY_SLUGS.ICELAND?"en"===n?I.filter(e=>"visit"!==e.id):R:"en"===n?I.filter(e=>"visit"!==e.id):I;async function P(){if(!C||!N)return;let e=`${C}:${N}`;if(!b.current.has(e)){b.current.add(e);try{let e=(0,g.createClient)(),t=["country","by-slug",C],r=w.getQueryData(t)??await w.fetchQuery({queryKey:t,queryFn:async()=>(0,p.getCountryBySlug)(e,C),staleTime:3e5}),a=[w.prefetchQuery({queryKey:["guides","country",C,N],queryFn:async()=>(0,h.getGuidesByCountrySlug)(e,C,N),staleTime:3e5})];
5r?.id&&a.push(w.prefetchQuery({queryKey:[...(0,c.generateAffiliatesQueryKey)(r.id),{includeInactive:!1,allLanguages:!0}],queryFn:async()=>(0,u.getAffiliates)(e,void 0,!1,r.id),staleTime:3e5})),await Promise.all(a)}catch(e){console.warn("[country-navigation] Prefetch country data failed:",e)}}}return(0,x.useRoutePrefetch)(S.map(e=>e.href)),(0,i.useEffect)(()=>{P()},[e,N]),(0,t.jsx)("section",{id:"navigation",className:"sticky top-16 z-40 border-b border-gray-100 bg-white/95 shadow-sm backdrop-blur-sm",children:(0,t.jsx)("div",{className:"container mx-auto sm:px-4 lg:px-8",children:(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("nav",{className:"no-scrollbar overflow-x-auto",children:(0,t.jsx)("div",{className:"flex min-w-max whitespace-nowrap",children:S.map(e=>(0,t.jsx)("div",{className:"flex-shrink-0",children:"hasDropdown"in e&&e.hasDropdown?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"hidden sm:block",children:(0,t.jsx)(f,{tabLabel:e.label,lang:n})}),(0,t.jsx)("div",{className:"block sm:hidden",children:(0,t.jsx)(v,{tabLabel:e.label,lang:n})})]}):(0,t.jsx)(r.default,{href:e.href,className:`block px-6 py-4 text-sm font-semibold transition-all duration-200 ${k===e.id?"text-brand-primary-hex-dark border-brand-primary-hex-dark bg-brand-primary-hex-dark/10 border-b-2":"hover:text-brand-primary-hex-dark hover:border-brand-primary-hex-dark hover:bg-brand-primary-hex-dark/10 border-b-2 border-white text-gray-700"}`,children:e.label})},e.id))})})})})})}])},991593,e=>{"use strict";var t=e.i(843476),r=e.i(522016),a=e.i(778917),i=e.i(152236);e.s(["ExternalLinkText",0,({url:e,children:n,className:s,showIcon:o=!0,isSponsored:l=!0})=>(0,t.jsxs)(r.default,{href:e,target:"_blank",rel:(0,i.cn)("noopener noreferrer",l&&"sponsored"),
5className:(0,i.cn)("inline-flex flex-wrap items-center text-brand-primary-600 underline hover:text-brand-primary-800",s),children:[n,o&&(0,t.jsx)(a.ExternalLink,{className:"ml-1.5 h-4 w-4"})]})])},292491,e=>{"use strict";var t=e.i(843476);e.s(["SectionHeader",0,function({title:e,subtitle:r,showTitleBar:a=!0,description:i}){return(0,t.jsxs)("div",{className:"space-y-3 text-center",children:[(0,t.jsx)("h1",{className:"text-2xl font-medium text-gray-900 md:text-3xl",children:e}),r?(0,t.jsx)("p",{className:"mb-6 text-sm text-gray-600 lg:text-base",children:r}):null,a?(0,t.jsx)("div",{className:"bg-brand-primary-hex-dark bg-linear-to-r mx-auto h-0.5 w-20"}):null,i?(0,t.jsx)("div",{className:"mx-auto max-w-3xl",children:(0,t.jsx)("p",{className:"text-sm leading-7 text-gray-700 md:text-base lg:text-lg",children:i})}):null]})}])},823429,e=>{"use strict";let t=(0,e.i(475254).default)("square-pen",[["path",{d:"M12 3H5a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7",key:"1m0v6g"}],["path",{d:"M18.375 2.625a1 1 0 0 1 3 3l-9.013 9.014a2 2 0 0 1-.853.505l-2.873.84a.5.5 0 0 1-.62-.62l.84-2.873a2 2 0 0 1 .506-.852z",key:"ohrbg2"}]]);e.s(["default",0,t])},688511,e=>{"use strict";var t=e.i(823429);e.s(["Edit",()=>t.default])},855264,e=>{"use strict";var t=e.i(266027),r=e.i(954616),a=e.i(912598),i=e.i(426255);e.s(["useAcceptFollowRequest",0,function(){let e=(0,i.useTRPC)(),t=(0,a.useQueryClient)();return(0,r.useMutation)(e.social.acceptFollowRequest.mutationOptions({onSuccess:()=>{t.invalidateQueries({queryKey:e.social.getPendingRequests.pathKey()})}}))},"useFollowMutation",0,function(e){let t=(0,i.useTRPC)(),n=(0,a.useQueryClient)();return(0,r.useMutation)(t.social.follow.mutationOptions({onSuccess:()=>{n.invalidateQueries({queryKey:t.social.getRelationship.queryKey({userId:e})}),n.invalidateQueries({queryKey:t.social.getFollowCounts.queryKey({userId:e})}),n.invalidateQueries({queryKey:t.social.getFollowedUsersPublicPlanners.pathKey()}),n.invalidateQueries({queryKey:t.social.getFollowedUsersPublicTrips.pathKey()})}}))},"useFollowedUsersPublicPlanners",0,function(e=12,r=!0){let a=(0,i.useTRPC)();return(0,t.useQuery)({...a.social.getFollowedUsersPublicPlanners.queryOptions({limit:e}),enabled:r,staleTime:6e4})},"usePendingFollowRequests",0,function(e=!0){let r=(0,i.useTRPC)();return(0,t.useQuery)({...r.social.getPendingRequests.queryOptions(),enabled:e,staleTime:3e4})},"useRejectFollowRequest",0,function(){let e=(0,i.useTRPC)(),t=(0,a.useQueryClient)();return(0,r.useMutation)(e.social.rejectFollowRequest.mutationOptions({onSuccess:()=>{t.invalidateQueries({queryKey:e.social.getPendingRequests.pathKey()})}}))},"useRelationship",0,function(e,r=!0){let a=(0,i.useTRPC)();return(0,t.useQuery)({...a.social.getRelationship.queryOptions({userId:e}),enabled:r&&Number.isFinite(e)&&e>0,staleTime:3e4})},"useUnfollowMutation",0,function(e){let t=(0,i.useTRPC)(),n=(0,a.useQueryClient)();return(0,r.useMutation)(t.social.unfollow.mutationOptions({onSuccess:()=>{n.invalidateQueries({queryKey:t.social.getRelationship.queryKey({userId:e})}),n.invalidateQueries({queryKey:t.social.getFollowCounts.queryKey({userId:e})}),n.invalidateQueries({queryKey:t.social.getFollowedUsersPublicPlanners.pathKey()}),n.invalidateQueries({queryKey:t.social.getFollowedUsersPublicTrips.pathKey()})}}))}])},744757,e=>{"use strict";let t=(0,e.i(475254).default)("map",[["path",{d:"M14.106 5.553a2 2 0 0 0 1.788 0l3.659-1.83A1 1 0 0 1 21 4.619v12.764a1 1 0 0 1-.553.894l-4.553 2.277a2 2 0 0 1-1.788 0l-4.212-2.106a2 2 0 0 0-1.788 0l-3.659 1.83A1 1 0 0 1 3 19.381V6.618a1 1 0 0 1 .553-.894l4.553-2.277a2 2 0 0 1 1.788 0z",key:"169xi5"}],["path",{d:"M15 5.764v15",key:"1pn4in"}],["path",{d:"M9 3.236v15",key:"1uimfh"}]]);e.s(["default",0,t])},554212,500187,e=>{"use strict";let t=(0,e.i(475254).default)("zoom-in",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["line",{x1:"21",x2:"16.65",y1:"21",y2:"16.65",key:"13gj7c"}],["line",{x1:"11",x2:"11",y1:"8",y2:"14",key:"1vmskp"}],["line",{x1:"8",x2:"14",y1:"11",y2:"11",key:"durymu"}]]);e.s(["default",0,t],500187),e.s(["ZoomIn",0,t],554212)},232660,e=>{"use strict";var t=e.i(271645),r=Object.defineProperty,a=(e,t,a)=>{let i;return(i="symbol"!=typeof t?t+"":t)in e?r(e,i,{enumerable:!0,configurable:!0,writable:!0,value:a}):e[i]=a};let i={x:0,y:0,width:0,height:0,unit:"px"},n=(e,t,r)=>
5Math.min(Math.max(e,t),r),s=(e,t)=>e===t||e.width===t.width&&e.height===t.height&&e.x===t.x&&e.y===t.y&&e.unit===t.unit;function o(e,t,r){return"%"===e.unit?{...i,...e,unit:"%"}:{unit:"%",x:e.x?e.x/t*100:0,y:e.y?e.y/r*100:0,width:e.width?e.width/t*100:0,height:e.height?e.height/r*100:0}}function l(e,t,r){return e.unit?"px"===e.unit?{...i,...e,unit:"px"}:{unit:"px",x:e.x?e.x*t/100:0,y:e.y?e.y*r/100:0,width:e.width?e.width*t/100:0,height:e.height?e.height*r/100:0}:{...i,...e,unit:"px"}}function d(e,t,r,a,i,n=0,s=0,o=a,l=i){let c={...e},u=Math.min(n,a),h=Math.min(s,i),p=Math.min(o,a),m=Math.min(l,i);t&&(t>1?(h=(u=s?s*t:u)/t,p=o*t):(u=(h=n?n/t:h)*t,m=l/t)),c.y<0&&(c.height=Math.max(c.height+c.y,h),c.y=0),c.x<0&&(c.width=Math.max(c.width+c.x,u),c.x=0);let g=a-(c.x+c.width);g<0&&(c.x=Math.min(c.x,a-u),c.width+=g);let x=i-(c.y+c.height);if(x<0&&(c.y=Math.min(c.y,i-h),c.height+=x),c.width<u&&(("sw"===r||"nw"==r)&&(c.x-=u-c.width),c.width=u),c.height<h&&(("nw"===r||"ne"==r)&&(c.y-=h-c.height),c.height=h),c.width>p&&(("sw"===r||"nw"==r)&&(c.x-=p-c.width),c.width=p),c.height>m&&(("nw"===r||"ne"==r)&&(c.y-=m-c.height),c.height=m),t){let e=c.width/c.height;if(e<t){let e=Math.max(c.width/t,h);("nw"===r||"ne"==r)&&(c.y-=e-c.height),c.height=e}else if(e>t){let e=Math.max(c.height*t,u);("sw"===r||"nw"==r)&&(c.x-=e-c.width),c.width=e}}return c}let c={capture:!0,passive:!1},u=0,h=class e extends t.PureComponent{constructor(){super(...arguments),a(this,"docMoveBound",!1),a(this,"mouseDownOnCrop",!1),a(this,"dragStarted",!1),a(this,"evData",{startClientX:0,startClientY:0,startCropX:0,startCropY:0,clientX:0,clientY:0,isResize:!0}),a(this,"componentRef",(0,t.createRef)()),a(this,"mediaRef",(0,t.createRef)()),a(this,"resizeObserver"),a(this,"initChangeCalled",!1),a(this,"instanceId",`rc-${u++}`),a(this,"state",{cropIsActive:!1,newCropIsBeingDrawn:!1}),a(this,"onCropPointerDown",e=>{let{crop:t,disabled:r}=this.props,a=this.getBox();if(!t)return;let i=l(t,a.width,a.height);if(r)return;e.cancelable&&e.preventDefault(),this.bindDocMove(),this.componentRef.current.focus({preventScroll:!0});let n=e.target.dataset.ord,s=e.clientX,o=e.clientY,d=i.x,c=i.y;if(n){let t=e.clientX-a.x,r=e.clientY-a.y,l=0,u=0;"ne"===n||"e"==n?(l=t-(i.x+i.width),u=r-i.y,d=i.x,c=i.y+i.height):"se"===n||"s"===n?(l=t-(i.x+i.width),u=r-(i.y+i.height),d=i.x,c=i.y):"sw"===n||"w"==n?(l=t-i.x,u=r-(i.y+i.height),d=i.x+i.width,c=i.y):("nw"===n||"n"==n)&&(l=t-i.x,u=r-i.y,d=i.x+i.width,c=i.y+i.height),s=d+a.x+l,o=c+a.y+u}this.evData={startClientX:s,startClientY:o,startCropX:d,startCropY:c,clientX:e.clientX,clientY:e.clientY,isResize:!!n,ord:n},this.mouseDownOnCrop=!0,this.setState({cropIsActive:!0})}),a(this,"onComponentPointerDown",e=>{let{crop:t,disabled:r,locked:a,keepSelection:i,onChange:n}=this.props,s=this.getBox();if(r||a||i&&t)return;e.cancelable&&e.preventDefault(),this.bindDocMove(),this.componentRef.current.focus({preventScroll:!0});let d=e.clientX-s.x,c=e.clientY-s.y,u={unit:"px",x:d,y:c,width:0,height:0};this.evData={startClientX:e.clientX,startClientY:e.clientY,startCropX:d,startCropY:c,clientX:e.clientX,clientY:e.clientY,isResize:!0},this.mouseDownOnCrop=!0,n(l(u,s.width,s.height),o(u,s.width,s.height)),this.setState({cropIsActive:!0,newCropIsBeingDrawn:!0})}),a(this,"onDocPointerMove",e=>{let t,{crop:r,disabled:a,onChange:i,onDragStart:n}=this.props,d=this.getBox();if(a||!r||!this.mouseDownOnCrop)return;e.cancelable&&e.preventDefault(),this.dragStarted||(this.dragStarted=!0,n&&n(e));let{evData:c}=this;c.clientX=e.clientX,c.clientY=e.clientY,s(r,t=c.isResize?this.resizeCrop():this.dragCrop())||i(l(t,d.width,d.height),o(t,d.width,d.height))}),a(this,"onComponentKeyDown",t=>{let{crop:r,disabled:a,onChange:i,onComplete:s}=this.props;if(a)return;let d=t.key,c=!1;if(!r)return;let u=this.getBox(),h=this.makePixelCrop(u),p=(navigator.platform.match("Mac")?t.metaKey:t.ctrlKey)?e.nudgeStepLarge:t.shiftKey?e.nudgeStepMedium:e.nudgeStep;if("ArrowLeft"===d?(h.x-=p,c=!0):"ArrowRight"===d?(h.x+=p,c=!0):"ArrowUp"===d?(h.y-=p,c=!0):"ArrowDown"===d&&(h.y+=p,c=!0),c){t.cancelable&&t.preventDefault(),h.x=n(h.x,0,u.width-h.width),h.y=n(h.y,0,u.height-h.height);let e=l(h,u.width,u.height),r=o(h,u.width,u.height);i(e,r),s&&s(e,r)}}),a(this,"onHandlerKeyDown",(t,r)=>{var a,i;let n,{aspect:c=0,crop:u,disabled:h,minWidth:p=0,minHeight:m=0,maxWidth:g,maxHeight:x,onChange:y,onComplete:f}=this.props,v=this.getBox();if(h||!u||"ArrowUp"!==t.key&&"ArrowDown"!==t.key&&"ArrowLeft"!==t.key&&"ArrowRight"!==t.key)return;t.stopPropagation(),t.preventDefault();let w=(navigator.platform.match("Mac")?t.metaKey:t.ctrlKey)?e.nudgeStepLarge:t.shiftKey?e.nudgeStepMedium:e.nudgeStep,b=d((a=l(u,v.width,v.height),i=t.key,n={...a},"ArrowLeft"===i?"nw"===r?(n.x-=w,n.y-=w,n.width+=w,n.height+=w):"w"===r?(n.x-=w,n.width+=w):"sw"===r?(n.x-=w,n.width+=w,n.height+=w):"ne"===r?(n.y+=w,n.width-=w,n.height-=w):"e"===r?n.width-=w:"se"===r&&(n.width-=w,n.height-=w):"ArrowRight"===i&&("nw"===r?(n.x+=w,n.y+=w,n.width-=w,n.height-=w):"w"===r?(n.x+=w,n.width-=w):"sw"===r?(n.x+=w,n.width-=w,n.height-=w):"ne"===r?(n.y-=w,n.width+=w,n.height+=w):"e"===r?n.width+=w:"se"===r&&(n.width+=w,n.height+=w)),"ArrowUp"===i?"nw"===r?(n.x-=w,n.y-=w,n.width+=w,n.height+=w):"n"===r?(n.y-=w,n.height+=w):"ne"===r?(n.y-=w,n.width+=w,n.height+=w):"sw"===r?(n.x+=w,n.width-=w,n.height-=w):"s"===r?n.height-=w:"se"===r&&(n.width-=w,n.height-=w):"ArrowDown"===i&&("nw"===r?(n.x+=w,n.y+=w,n.width-=w,n.height-=w):"n"===r?(n.y+=w,n.height-=w):"ne"===r?(n.y+=w,n.width-=w,n.height-=w):"sw"===r?(n.x-=w,n.width+=w,n.height+=w):"s"===r?n.height+=w:"se"===r&&(n.width+=w,n.height+=w)),n),c,r,v.width,v.height,p,m,g,x);if(!s(u,b)){let e=o(b,v.width,v.height);y(b,e),f&&f(b,e)}}),a(this,"onDocPointerDone",e=>{let{crop:t,disabled:r,onComplete:a,onDragEnd:i}=this.props,n=this.getBox();this.unbindDocMove(),!(r||!t)&&this.mouseDownOnCrop&&(this.mouseDownOnCrop=!1,this.dragStarted=!1,i&&i(e),a&&a(l(t,n.width,n.height),o(t,n.width,n.height)),this.setState({cropIsActive:!1,newCropIsBeingDrawn:!1}))}),a(this,"onDragFocus",()=>{var e;null==(e=this.componentRef.current)||e.scrollTo(0,0)})}get document(){return document}getBox(){let e=this.mediaRef.current;if(!e)return{x:0,y:0,width:0,height:0};let{x:t,y:r,width:a,height:i}=e.getBoundingClientRect();return{x:t,y:r,width:a,height:i}}componentDidUpdate(e){let{crop:t,onComplete:r}=this.props;if(r&&!e.crop&&t){let{width:e,height:a}=this.getBox();e&&a&&r(l(t,e,a),o(t,e,a))}}componentWillUnmount(){this.resizeObserver&&this.resizeObserver.disconnect(),this.unbindDocMove()}bindDocMove(){this.docMoveBound||(this.document.addEventListener("pointermove",this.onDocPointerMove,c),this.document.addEventListener("pointerup",this.onDocPointerDone,c),this.document.addEventListener("pointercancel",this.onDocPointerDone,c),this.docMoveBound=!0)}
5unbindDocMove(){this.docMoveBound&&(this.document.removeEventListener("pointermove",this.onDocPointerMove,c),this.document.removeEventListener("pointerup",this.onDocPointerDone,c),this.document.removeEventListener("pointercancel",this.onDocPointerDone,c),this.docMoveBound=!1)}getCropStyle(){let{crop:e}=this.props;if(e)return{top:`${e.y}${e.unit}`,left:`${e.x}${e.unit}`,width:`${e.width}${e.unit}`,height:`${e.height}${e.unit}`}}dragCrop(){let{evData:e}=this,t=this.getBox(),r=this.makePixelCrop(t),a=e.clientX-e.startClientX,i=e.clientY-e.startClientY;return r.x=n(e.startCropX+a,0,t.width-r.width),r.y=n(e.startCropY+i,0,t.height-r.height),r}getPointRegion(e,t,r,a){let i,{evData:n}=this,s=n.clientX-e.x,o=n.clientY-e.y;return i=a&&t?"nw"===t||"n"===t||"ne"===t:o<n.startCropY,(r&&t?"nw"===t||"w"===t||"sw"===t:s<n.startCropX)?i?"nw":"sw":i?"ne":"se"}resolveMinDimensions(e,t,r=0,a=0){let i=Math.min(r,e.width),n=Math.min(a,e.height);return t&&(i||n)?t>1?i?[i,i/t]:[n*t,n]:n?[n*t,n]:[i,i/t]:[i,n]}resizeCrop(){let{evData:t}=this,{aspect:r=0,maxWidth:a,maxHeight:i}=this.props,s=this.getBox(),[o,l]=this.resolveMinDimensions(s,r,this.props.minWidth,this.props.minHeight),c=this.makePixelCrop(s),u=this.getPointRegion(s,t.ord,o,l),h=t.ord||u,p=t.clientX-t.startClientX,m=t.clientY-t.startClientY;(o&&"nw"===h||"w"===h||"sw"===h)&&(p=Math.min(p,-o)),(l&&"nw"===h||"n"===h||"ne"===h)&&(m=Math.min(m,-l));let g={unit:"px",x:0,y:0,width:0,height:0};"ne"===u?(g.x=t.startCropX,g.width=p,r?g.height=g.width/r:g.height=Math.abs(m),g.y=t.startCropY-g.height):"se"===u?(g.x=t.startCropX,g.y=t.startCropY,g.width=p,r?g.height=g.width/r:g.height=m):"sw"===u?(g.x=t.startCropX+p,g.y=t.startCropY,g.width=Math.abs(p),r?g.height=g.width/r:g.height=m):"nw"===u&&(g.x=t.startCropX+p,g.width=Math.abs(p),r?(g.height=g.width/r,g.y=t.startCropY-g.height):(g.height=Math.abs(m),g.y=t.startCropY+m));let x=d(g,r,u,s.width,s.height,o,l,a,i);return r||e.xyOrds.indexOf(h)>-1?c=x:e.xOrds.indexOf(h)>-1?(c.x=x.x,c.width=x.width):e.yOrds.indexOf(h)>-1&&(c.y=x.y,c.height=x.height),c.x=n(c.x,0,s.width-c.width),c.y=n(c.y,0,s.height-c.height),c}renderCropSelection(){let{ariaLabels:r=e.defaultProps.ariaLabels,disabled:a,locked:i,renderSelectionAddon:n,ruleOfThirds:s,crop:o}=this.props,l=this.getCropStyle();if(o)return t.default.createElement("div",{style:l,className:"ReactCrop__crop-selection",onPointerDown:this.onCropPointerDown,"aria-label":r.cropArea,tabIndex:0,onKeyDown:this.onComponentKeyDown,role:"group"},!a&&!i&&t.default.createElement("div",{className:"ReactCrop__drag-elements",onFocus:this.onDragFocus},t.default.createElement("div",{className:"ReactCrop__drag-bar ord-n","data-ord":"n"}),t.default.createElement("div",{className:"ReactCrop__drag-bar ord-e","data-ord":"e"}),t.default.createElement("div",{className:"ReactCrop__drag-bar ord-s","data-ord":"s"}),t.default.createElement("div",{className:"ReactCrop__drag-bar ord-w","data-ord":"w"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-nw","data-ord":"nw",tabIndex:0,"aria-label":r.nwDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"nw"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-n","data-ord":"n",tabIndex:0,"aria-label":r.nDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"n"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-ne","data-ord":"ne",tabIndex:0,"aria-label":r.neDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"ne"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-e","data-ord":"e",tabIndex:0,"aria-label":r.eDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"e"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-se","data-ord":"se",tabIndex:0,"aria-label":r.seDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"se"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-s","data-ord":"s",tabIndex:0,"aria-label":r.sDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"s"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-sw","data-ord":"sw",tabIndex:0,"aria-label":r.swDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"sw"),role:"button"}),t.default.createElement("div",{className:"ReactCrop__drag-handle ord-w","data-ord":"w",tabIndex:0,"aria-label":r.wDragHandle,onKeyDown:e=>this.onHandlerKeyDown(e,"w"),role:"button"})),n&&t.default.createElement("div",{className:"ReactCrop__selection-addon",onPointerDown:e=>e.stopPropagation()},n(this.state)),s&&t.default.createElement(t.default.Fragment,null,t.default.createElement("div",{className:"ReactCrop__rule-of-thirds-hz"}),t.default.createElement("div",{className:"ReactCrop__rule-of-thirds-vt"})))}makePixelCrop(e){return l({...i,...this.props.crop||{}},e.width,e.height)}render(){let{aspect:e,children:r,circularCrop:a,className:i,crop:n,disabled:s,locked:o,style:l,ruleOfThirds:d}=this.props,{cropIsActive:c,newCropIsBeingDrawn:u}=this.state,h=n?this.renderCropSelection():null,p=((...e)=>e.filter(e=>e&&"string"==typeof e).join(" "))("ReactCrop",i,c&&"ReactCrop--active",s&&"ReactCrop--disabled",o&&"ReactCrop--locked",u&&"ReactCrop--new-crop",n&&e&&"ReactCrop--fixed-aspect",n&&a&&"ReactCrop--circular-crop",n&&d&&"ReactCrop--rule-of-thirds",!this.dragStarted&&n&&!n.width&&!n.height&&"ReactCrop--invisible-crop",a&&"ReactCrop--no-animate");return t.default.createElement("div",{ref:this.componentRef,className:p,style:l},t.default.createElement("div",{ref:this.mediaRef,className:"ReactCrop__child-wrapper",onPointerDown:this.onComponentPointerDown},r),n?t.default.createElement("svg",{className:"ReactCrop__crop-mask",width:"100%",height:"100%"},t.default.createElement("defs",null,t.default.createElement("mask",{id:`hole-${this.instanceId}`},t.default.createElement("rect",{width:"100%",height:"100%",fill:"white"}),a?t.default.createElement("ellipse",{cx:`${n.x+n.width/2}${n.unit}`,cy:`${n.y+n.height/2}${n.unit}`,rx:`${n.width/2}${n.unit}`,ry:`${n.height/2}${n.unit}`,fill:"black"}):t.default.createElement("rect",{x:`${n.x}${n.unit}`,y:`${n.y}${n.unit}`,width:`${n.width}${n.unit}`,height:`${n.height}${n.unit}`,fill:"black"}))),t.default.createElement("rect",{fill:"black",fillOpacity:.5,width:"100%",height:"100%",mask:`url(#hole-${this.instanceId})`})):void 0,h)}};a(h,"xOrds",["e","w"]),a(h,"yOrds",["n","s"]),a(h,"xyOrds",["nw","ne","se","sw"]),a(h,"nudgeStep",1),a(h,"nudgeStepMedium",10),a(h,"nudgeStepLarge",100),a(h,"defaultProps",{ariaLabels:{cropArea:"Use the arrow keys to move the crop selection area",nwDragHandle:"Use the arrow keys to move the north west drag handle to change the crop selection area",nDragHandle:"Use the up and down arrow keys to move the north drag handle to change the crop selection area",neDragHandle:"Use the arrow keys to move the north east drag handle to change the crop selection area",eDragHandle:"Use the up and down arrow keys to move the east drag handle to change the crop selection area",seDragHandle:"Use the arrow keys to move the south east drag handle to change the crop selection area",sDragHandle:"Use the up and down arrow keys to move the south drag handle to change the crop selection area",swDragHandle:"Use the arrow keys to move the south west drag handle to change the crop selection area",wDragHandle:"Use the up and down arrow keys to move the west drag handle to change the crop selection area"}}),e.s(["centerCrop",0,function(e,t,r){let a=l(e,t,r);return a.x=(t-a.width)/2,a.y=(r-a.height)/2,"%"===e.unit?o(a,t,r):a},"default",0,h,"makeAspectCrop",0,function(e,t,r,a){let i=l(e,r,a);return e.width&&(i.height=i.width/t),e.height&&(i.width=i.height*t),i.y+i.height>a&&(i.height=a-i.y,i.width=i.height*t),i.x+i.width>r&&(i.width=r-i.x,i.height=i.width/t),"%"===e.unit?o(i,r,a):i}])},159121,e=>{"use strict";var t=e.i(843476),r=e.i(271645),a=e.i(282879),i=e.i(466691),n=e.i(757119),s=e.i(912598),o=e.i(657688);e.i(785269);var l=e.i(322831),d=e.i(232660),c=e.i(846696),u=e.i(618566);e.s(["ItineraryImageUploadDialog",0,function({open:e,onOpenChange:h,planner:p,onUploadSuccess:m}){let{t:g}=(0,l.useTranslation)(),x=(0,u.useRouter)(),y=(0,s.useQueryClient)(),[f,v]=(0,r.useState)(null),[w,b]=(0,r.useState)(null),[j,_]=(0,r.useState)(!1),[N,C]=(0,r.useState)(),[k,D]=(0,r.useState)(),I=(0,r.useRef)(null),R=(0,r.useRef)(null),S=16/9,P=p.image_name?.replace(/^\/+/,""),E=P?P.startsWith("images/")?P:`images/${P}
5`:"",q=(0,n.useS3SignedUrl)(E),O=(0,r.useCallback)(e=>{let t=e.target.files?.[0]||null;v(t),t?(b(URL.createObjectURL(t)),C(void 0)):b(null)},[]),$=(0,r.useCallback)(()=>{v(null),b(null),C(void 0),R.current&&(R.current.value="")},[]),M=(0,r.useCallback)(e=>{let{width:t,height:r}=e.currentTarget;C((0,d.centerCrop)((0,d.makeAspectCrop)({unit:"%",width:90},S,t,r),t,r))},[S]);async function T(e,t,r){let a=document.createElement("canvas"),i=e.naturalWidth/e.width,n=e.naturalHeight/e.height;a.width=t.width*i,a.height=t.height*n;let s=a.getContext("2d");if(!s)throw Error("No 2d context");return s.drawImage(e,t.x*i,t.y*n,t.width*i,t.height*n,0,0,t.width*i,t.height*n),new Promise((e,t)=>{a.toBlob(a=>{a?e(new File([a],r,{type:"image/jpeg"})):t(Error("Canvas is empty"))},"image/jpeg",.95)})}let A=(0,r.useCallback)(async()=>{if(f&&k&&I.current)try{_(!0);let e=await T(I.current,k,f.name),t=new FormData;t.append("file",e),t.append("plannerId",p.id.toString());let r=await fetch("/api/admin/itinerary-planners/upload",{method:"POST",body:t});if(!r.ok){let e=await r.json();throw Error(e.error||"Upload failed")}let a=await r.json();c.toast.success("Image uploaded successfully!"),a.imageKey&&y.invalidateQueries({queryKey:(0,n.generateS3SignedUrlQueryKey)(a.imageKey)}),E&&y.invalidateQueries({queryKey:(0,n.generateS3SignedUrlQueryKey)(E)}),y.invalidateQueries({predicate:e=>{let t=e.queryKey;return Array.isArray(t)&&"itineraryPlanner"===t[0]&&t.includes(p.id)}}),x.refresh(),m&&m(),h(!1),$()}catch(e){console.error("[ItineraryImageUploadDialog] Upload error:",e),c.toast.error(e instanceof Error?e.message:"Upload failed")}finally{_(!1)}},[f,p.id,k,y,x,h,$,m]);return(0,t.jsx)(a.Dialog,{open:e,onOpenChange:e=>!j&&h(e),children:(0,t.jsx)(a.DialogContent,{className:"sm:max-w-2xl max-h-[90vh] overflow-y-auto",children:(0,t.jsxs)("div",{className:"flex flex-col gap-6",children:[(0,t.jsx)("div",{className:"flex items-center justify-between",children:(0,t.jsx)(a.DialogTitle,{className:"text-xl font-semibold",children:"Upload Inspiration Image"})}),(0,t.jsxs)("div",{className:"flex flex-col items-center gap-4",children:[(0,t.jsx)("div",{className:"w-full flex justify-center",children:j?(0,t.jsx)("div",{className:"flex h-40 w-full items-center justify-center text-sm text-gray-500",children:g("Uploading...")}):w?(0,t.jsx)(d.default,{crop:N,onChange:(e,t)=>
5C(t),onComplete:e=>D(e),aspect:S,className:"max-h-[50vh]",children:(0,t.jsx)("img",{ref:I,src:w,alt:"preview",className:"max-w-full max-h-[50vh] object-contain",onLoad:M})}):p.image_name&&q.data?(0,t.jsx)("div",{className:"h-48 w-full max-w-sm overflow-hidden rounded-lg bg-gray-100",children:(0,t.jsx)(o.default,{src:q.data,alt:p.title,width:400,height:400,className:"h-full w-full object-cover"})}):(0,t.jsx)("div",{className:"flex h-40 w-full max-w-sm items-center justify-center rounded-lg bg-gray-100 text-sm text-gray-400",children:g("No current image")})}),!w&&(0,t.jsx)("div",{className:"flex w-full justify-center",children:(0,t.jsxs)("label",{className:"cursor-pointer rounded-md bg-secondary px-4 py-2 text-sm font-medium hover:bg-secondary/80",children:[g("Select New Image"),(0,t.jsx)("input",{ref:R,type:"file",accept:"image/*",onChange:O,disabled:j,className:"hidden"})]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-end gap-3 pt-4 border-t",children:[f?(0,t.jsx)(i.Button,{variant:"outline",onClick:$,disabled:j,children:g("Cancel")}):null,(0,t.jsx)(i.Button,{onClick:A,disabled:!f||!k||j,className:"w-full sm:w-auto",children:g(j?"Uploading...":"Crop & Upload Image")})]})]})})})}])},722614,e=>{"use strict";var t=e.i(744757);e.s(["MapIcon",()=>t.default])},399994,e=>{"use strict";var t=e.i(266027),r=e.i(792974),a=e.i(705008);e.s(["useHighlightedItineraryPlannersByCountryId",0,function(e,i="fr"){return(0,t.useQuery)({queryKey:["highlightedItineraryPlannersByCountryId",e,i].filter(Boolean),enabled:!!e,staleTime:3e5,queryFn:async()=>{if(!e)return[];let t=(0,r.createClient)();return await (0,a.getHighlightedItineraryPlannersByCountryId)(t,e,i)??[]}})}])},303042,e=>{"use strict";var t=e.i(843476),r=e.i(522016),a=e.i(657688),i=e.i(511152);e.i(785269);var n=e.i(322831),s=e.i(399994),o=e.i(349406),l=e.i(991593),d=e.i(292491),c=e.i(93421);function u({countrySlug:e}){let{i18n:r}=(0,n.useTranslation)();return e===c.COUNTRY_SLUGS.ICELAND?(0,t.jsx)(h,{language:r.language}):e===c.COUNTRY_SLUGS.SOUTH_KOREA?(0,t.jsx)(p,{language:r.language}):e===c.COUNTRY_SLUGS.COSTA_RICA?(0,t.jsx)(m,{language:r.language}):e===c.COUNTRY_SLUGS.NORWAY?(0,t.jsx)(g,{language:r.language}):null}function h({language:e}){return"fr"===e?(0,t.jsx)("div",{className:"",children:(0,t.jsxs)("div",{className:"space-y-8",children:[(0,t.jsx)("div",{className:"text-center",children:(0,t.jsx)(l.ExternalLinkText,{url:"https://guidetoiceland.is/fr/process/tours/search?adults=1&departure_time_from=00%3A00&departure_time_to=23%3A59&min_age_from=0&min_age_to=21&order_by=popularity&order_direction=desc&price_from=0&price_to=999999999&search_currency_id=EUR&tour_category_id=276&a=432050",children:"+ de 43 itinéraires sur Guide to Iceland"})}),(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Quel itinéraire choisir ?"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl",children:[(0,t.jsx)("p",{className:"leading-relaxed text-gray-700",children:"Vu sur une carte, l'Islande ne semble pas si grande que cela. Pourtant il faut du temps pour la visiter car il y a une merveille à découvrir toutes les 30 minutes de route. La voiture reste le meilleur moyen pour parcourir l'île. Vous aurez uniquement besoin d'un 4x4 si vous comptez vous aventurer sur les pistes dans le centre du pays."}),(0,t.jsxs)("div",{className:"mt-8 space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"1 jour / Une journée"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1 : Vous avez une escale longue durée à Reykjavik de plus de 5 heures ? Il faut environ 45 min de l'aeroport de Keflavik à Reykjavik. Cela vous laisse deux heures pour faire un tour dans la capitale."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2 : Allez vous détendre au Blue Lagoon à même pas 20 minutes, il y a des navettes depuis l'aeroport. Pensez à réserver en avance."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire de 3 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1 : visite de Reykjavik durant une demi-journée. Une journée entière consacrée au Cercle d'Or (Bingbellir, Geysir et Gullfoss) et une demi-journée au Blue Lagoon ou une excursion pour observer les baleines."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2 : exploration de la peninsule Snæfellsnes avec la visite de Kirkjufell."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire de 7 jours / une semaine"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1 : en une semaine, vous pouvez aller jusqu'à la lagune de Jokulsarlon et visiter toutes les cascades du Sud en chemin."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2 : découverte de la péninsule Reykjanes et de Snæfellsnes + Cercle d'Or"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire 10 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1 : le tour de l'île en restant sur la route circulaire numéro 1. Vous pourrez faire un détour par les Fjords de l'Est et Husavik pour observer les baleines."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2 : randonnée de 4 jours dans le Landmannalaugar et visite du Sud jusqu'à Jokulsarlon"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire 14 jours / 2 semaines"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1 : vous aurez les temps de faire le tour complet de l'île + les Fjords de l'Ouest"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2 : le tour de l'île et vous aventurez sur les F-Road si vous disposez d'un 4x4"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire 21 jours / 3 semaines"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Prenez le temps de découvrir les recoins les plus isolés d'Islande."})]})]})]})]}),(0,t.jsxs)("section",{className:"text-center",children:[(0,t.jsx)(a.default,{src:"/images/itinerary/iceland/iceland-infographie-road1-sm.webp",alt:"Infographie route 1 Islande",width:800,height:761,className:"mx-auto rounded-md"}),(0,t.jsx)("p",{className:"mx-auto mt-4 max-w-4xl text-sm text-gray-600",children:"Les temps de parcours ci-dessus sont des estimations de Google Maps avec des conditions de circulation optimales, ce qui arrivent rarement. Dans les conditions réelles, prévoyez au moins 30% de temps en plus car on ne roule pas très vite en Islande à cause du vent, d'un camping car et surtout de la beauté du paysage. L'objectif de cette infographie n'est pas de vous faire croire qu'il est possible de faire le tour de l'île en moins de 17h, mais de vous donner une idée des distances et durées entre deux points."})]}),(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Les meilleurs moyens pour se déplacer"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"La voiture"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Louer une voiture est le moyen par excellence pour explorer l'Islande. Vous serez libre de vous arrêter n'importe où pour admirer les paysages. A moins de vouloir emprunter les pistes, le 4x4 n'est pas nécessaire pour faire le tour via la route circulaire. En hiver, un 4x4 est conseillé pour la majorité des itinéraires."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Les vans aménagés / camping cars"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Les hébergements sont onéreux en Islande. Dormir dans son véhicule est une solution intéressante d'autant plus que les campings sont nombreux et bien généralement bien équipés. En revanche, votre itinéraire ne pourra pas s'éloigner de la route goudronnée n°1."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Bus"}),(0,t.jsx)("p",{className:"text-gray-700",children:"L'Islande possède un réseau de bus qui déssert les principales villes du pays en été. C'est une alternative pour ceux qui voyagent seul. De nombreuses lignes sont fermées en hiver."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Stop"}),(0,t.jsx)("p",{className:"text-gray-700",children:"C'est une pratique courante. Assurez vous d'être conscient des risques que le stop induit. En dehors des zone
5s touristiques, les voitures se font plus rares."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Avion"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Si votre itinéraire cible une région précise comme le nord ou les fjords de l'ouest, prendre un vol interne permettra de gagner du temps."})]})]})]})]})}):(0,t.jsx)("div",{className:"",children:(0,t.jsxs)("div",{className:"space-y-8",children:[(0,t.jsx)("div",{className:"text-center",children:(0,t.jsx)(l.ExternalLinkText,{url:"https://guidetoiceland.is/process/tours/search?adults=1&departure_time_from=00%3A00&departure_time_to=23%3A59&min_age_from=0&min_age_to=21&order_by=popularity&order_direction=desc&price_from=0&price_to=999999999&search_currency_id=EUR&tour_category_id=276&a=432050",children:"43+ itineraries on Guide to Iceland"})}),(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Which itinerary to choose?"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl",children:[(0,t.jsx)("p",{className:"leading-relaxed text-gray-700",children:"On a map, Iceland doesn't seem that large. However, it takes time to visit because there is a wonder to discover every 30 minutes on the road. A car remains the best way to explore the island. You will only need a 4x4 if you plan to venture onto the tracks in the center of the country."}),(0,t.jsxs)("div",{className:"mt-8 space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"1 day / One day"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1: Do you have a long stopover in Reykjavik of more than 5 hours? It takes about 45 min from Keflavik airport to Reykjavik. This leaves you two hours to tour the capital."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2: Go relax at the Blue Lagoon just 20 minutes away, there are shuttles from the airport. Remember to book in advance."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"3-day itinerary"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1: half-day visit to Reykjavik. A full day dedicated to the Golden Circle (Þingvellir, Geysir and Gullfoss) and a half-day at the Blue Lagoon or a whale watching excursion."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2: exploration of the Snæfellsnes peninsula with a visit to Kirkjufell."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"7-day / one week itinerary"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1: in one week, you can go to Jökulsárlón lagoon and visit all the South waterfalls along the way."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2: discovery of the Reykjanes and Snæfellsnes peninsulas + Golden Circle"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"10-day itinerary"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1: the tour of the island while staying on Ring Road number 1. You can make a detour through the East Fjords and Húsavík for whale watching."}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2: 4-day hike in Landmannalaugar and visit the South to Jökulsárlón"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"14-day / 2 weeks itinerary"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 1: you will have time to do the complete tour of the island + the Westfjords"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Option 2: tour of the island and venture on the F-Roads if you have a 4x4"})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"21-day / 3 weeks itinerary"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Take your time to discover the most remote corners of Iceland."})]})]})]})]}),(0,t.jsxs)("section",{className:"text-center",children:[(0,t.jsx)(a.default,{src:"/images/itinerary/iceland/iceland-infographie-road1-sm.webp",alt:"Iceland Ring Road infographic",width:800,height:761,className:"mx-auto rounded-md"}),(0,t.jsx)("p",{className:"mx-auto mt-4 max-w-4xl text-sm text-gray-600",children:"The travel times above are Google Maps estimates with optimal traffic conditions, which rarely happen. In real conditions, plan at least 30% more time because you don't drive very fast in Iceland due to wind, campervans and especially the beauty of the landscape. The purpose of this infographic is not to make you believe that it is possible to go around the island in less than 17 hours, but to give you an idea of the distances and durations between two points."})]}),(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Best ways to get around"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Car"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Renting a car is the best way to explore Iceland. You will be free to stop anywhere to admire the landscapes. Unless you want to take the tracks, 4x4 is not necessary to go around via the Ring Road. In winter, a 4x4 is recommended for most itineraries."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Campervans / RVs"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Accommodation is expensive in Iceland. Sleeping in your vehicle is an interesting solution, especially since campsites are numerous and generally well equipped. However, your itinerary will not be able to stray from the paved road n°1."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Bus"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Iceland has a bus network that serves the main cities of the country in summer. It's an alternative for those traveling alone. Many lines are closed in winter."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Hitchhiking"}),(0,t.jsx)("p",{className:"text-gray-700",children:"It's a common practice. Make sure you are aware of the risks that hitchhiking entails. Outside tourist areas, cars are more scarce."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Plane"}),(0,t.jsx)("p",{className:"text-gray-700",children:"If your itinerary targets a specific region such as the north or the westfjords, taking a domestic flight will save time."})]})]})]})]})})}function p({language:e}){return"fr"!==e?(0,t.jsx)("div",{className:"py-12 text-center",children:(0,t.jsx)("p",{className:"text-gray-500",children:"English content coming soon..."})}):(0,t.jsxs)("div",{className:"space-y-12",children:[(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Quel itinéraire choisir ?"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl",children:[(0,t.jsx)("p",{className:"leading-relaxed text-gray-700",children:"Il y a plein de choses à faire à Séoul, mais la Corée du Sud ce n'est pas que sa capitale. Le premier élément dans l'élaboration de votre itinéraire sera la durée de votre voyage. Si vous partez moins d'une semaine, il sera préférable de vous restreindre à une zone ou à deux villes, Séoul et Busan par exemple. Avec deux semaines, un itinéraire faisant le tour de du pays peut être envisagé. Le deuxième paramètre à prendre en compte est la météo. Il fait très froid et il peut y avoir beaucoup de neige en hiver alors qu'en été la température et l'humidité deviennent vite insupportables. Le troisième facteur dans le choix de votre itinéraire en Corée du Sud est votre budget, qui influencera aussi votre mode de déplacement. Allez-vous louer une voiture, voyager par bus ou par train ? Ci-dessous, des exemples :"}),(0,t.jsxs)("div",{className:"mt-8 space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire de moins de 3 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Une escale ou un déplacement professionnel en Corée du Sud. Vous n'aurez pas le temps de vous éloignez de Séoul. Pour vous échapper de la ville le temps d'une journée, la parc Bukhansan et la DMZ sont facilement accessibles en transport en commun."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire d'une semaine / 7 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Il est préférable de se limiter à deux villes : par exemple Seoul avec pourquoi pas une visite du parc national Seoraksan à l'est du pays. La voiture est inutile, vous vous déplacerez en bus express. Il est aussi possible de faire Séoul (3 jours) et Busan ou (2 jours) grâce au train à grande vitesse local."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire de 2 semaines / 14 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Avec deux semaines le choix est large. Définissez ce que vous voulez faire : plages, temples/culture, randonnées ou un peu de tout ? Si vous êtes plutôt à la recherche de repos, optez pour un itinéraire passant par les plages sur la côte Est et l'île de Jeju. Pour les randonnées, les zones montagneuses du nord-est et du centre du pays vous permettront de remplir vos pouvons d'air pur. Pour découvrir la culture coréenne, ne manquez surtout pas Andong (capitale traditionnelle de la Corée du Sud) et Gyeongju (capitale du royaume de Silla)."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Itinéraire de 3 semaines / 21 jours"}),(0,t.jsx)("p",{className:"text-gray-700",children:"C'est la durée idéale pour une immersion totale au pays du matin calme. Vous aurez le temps de découvrir la culture coréenne comme peu de voyageurs ont l'occasion de le faire. Avec trois semaines, vous ferez le tour du pays et de l'île de Jeju, vous explorerez les temples, les sentiers des parcs nationaux et vous dégusterez les spécialités des régions traversées."})]})]})]})]}),(0,t.jsxs)("section",{className:"space-y-5",children:[(0,t.jsx)(d.SectionHeader,{title:"Les meilleurs moyens pour se déplacer"}),(0,t.jsxs)("div",{className:"prose prose-lg mx-auto max-w-4xl space-y-4 lg:space-y-6",children:[(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Bus"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Les bus express relient les grandes villes avec un départ toutes les 15 minutes. Les bus interurbains prennent ensuite le relais pour desservir les petites villes et les parcs nationaux avec des départs toutes les heures. Il y aura toujours un agent pour vous indiquer ou s'assurer que vous montiez dans le bon bus."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Train"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Comme pous les bus, on retrouve les trains à grande vitesse (KTX et Saemaeul) pour relier Séoul à Busan avec très peu d'arrêts. Les mugunghwa s'arrêtent en chemin dans les petites villes."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Ferry"}),(0,t.jsx)("p",{className:"text-gray-700",children:"La majorité des îles coréennes habitées sont reliées par des ferrys. Si vous avez du temps, une alternative plus écologique et économique que l'avion pour se rendre à Jeju est de prendre un bus express pour le sud du pays, puis un ferry."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Voiture"}),(0,t.jsx)("p",{className:"text-gray-700",children:"Pas facile de s'orienter en Corée du Sud car tout est écrit en hangeul (alphabet coréen). Les Sud-Coréens ont une mauvaise réputation en matière de conduite. En fonction de votre itinéraire, demandez-vous si la location d'une voiture est indispensable."})]}),(0,t.jsxs)("div",{children:[(0,t.jsx)("h3",{className:"font-semibold text-gray-900",children:"Avion"}),(0,t.jsx)("p",{className:"text-gray-700",children:"L'avion permet de relier le continent à l'île de Jeju en une heure de vol au plus (depuis Séoul). Les principales compagnies sont Asiana et Korean Air. Des low cost assurent aussi de
5s liaisons : Air Busan, Eastar Jet, Jeju Air, T'way Air."})]})]})]})]})}function m({language:e}){return null}function g({language:e}){return null}var x=e.i(370317),y=e.i(534792);function f(){return(0,t.jsxs)(x.Card,{className:"flex h-full flex-col gap-0 overflow-hidden rounded-md bg-white p-0 shadow transition-shadow hover:shadow-sm",children:[(0,t.jsxs)("div",{className:"block flex-1",children:[(0,t.jsx)("div",{className:"relative cursor-pointer",children:(0,t.jsxs)("div",{className:"relative h-48 bg-gray-200 lg:h-52",children:[(0,t.jsx)(y.Skeleton,{className:"h-full w-full"}),(0,t.jsx)("div",{className:"absolute left-2 top-2 rounded bg-black/80 p-2",children:(0,t.jsx)(y.Skeleton,{className:"h-4 w-4"})}),(0,t.jsx)("div",{className:"absolute right-2 top-2 rounded bg-black/80 px-2 py-1",children:(0,t.jsx)(y.Skeleton,{className:"h-3 w-16 bg-white/20"})}),(0,t.jsx)("div",{className:"absolute bottom-2 right-2 rounded bg-black/80 px-2 py-1",children:(0,t.jsx)(y.Skeleton,{className:"h-3 w-12 bg-white/20"})})]})}),(0,t.jsxs)("div",{className:"px-3 pt-3",children:[(0,t.jsxs)("div",{className:"mb-1 text-center",children:[(0,t.jsx)(y.Skeleton,{className:"mx-auto mb-1 h-4 w-3/4"}),(0,t.jsx)(y.Skeleton,{className:"mx-auto h-4 w-1/2"})]}),(0,t.jsx)("div",{className:"mt-2",children:(0,t.jsx)("div",{className:"flex justify-center gap-1",children:Array.from({length:12}).map((e,r)=>(0,t.jsx)(y.Skeleton,{className:"h-2 w-2 rounded-full"},r))})})]})]}),(0,t.jsx)("div",{className:"mt-auto p-3",children:(0,t.jsx)(y.Skeleton,{className:"h-10 w-full rounded-md"})})]})}var v=e.i(87316),w=e.i(346897),b=e.i(714650),j=e.i(855264),_=e.i(891887);function N(){let{t:e,i18n:r}=(0,n.useTranslation)(),{data:a}=(0,_.useCurrentUser)(),{data:i,isLoading:s}=(0,j.useFollowedUsersPublicPlanners)(12,!!a);return a&&!s&&i&&0!==i.length?(0,t.jsxs)("section",{className:"space-y-4 pb-8 lg:pb-10",children:[(0,t.jsx)("div",{className:"flex items-end justify-between",children:(0,t.jsxs)("div",{children:[(0,t.jsx)("h2",{className:"text-xl font-bold text-slate-900 lg:text-2xl",children:e("social.followedCreatorsTitle","Créateurs que vous suivez")}),(0,t.jsx)("p",{className:"text-sm text-slate-500",children:e("social.followedCreatorsSubtitle","Itinéraires publics récents")})]})}),(0,t.jsx)("div",{className:"-mx-4 flex snap-x snap-mandatory gap-4 overflow-x-auto px-4 pb-2 lg:mx-0 lg:grid lg:grid-cols-3 lg:gap-6 lg:overflow-visible lg:px-0",children:i.map(e=>(0,t.jsx)(C,{planner:e,lang:r.language},e.id))})]}):null}function C({planner:e,lang:a}){let{t:i}=(0,n.useTranslation)(),s=(e.user_username??"U").charAt(0).toUpperCase();return(0,t.jsx)(r.default,{href:`/${a}/planner/${e.code}`,className:"group block min-w-[260px] shrink-0 snap-start lg:min-w-0",children:(0,t.jsxs)("div",{className:"relative overflow-hidden rounded-2xl shadow-sm transition-shadow hover:shadow-lg",children:[(0,t.jsxs)("div",{className:"relative h-32 w-full overflow-hidden bg-gradient-to-br from-slate-200 to-slate-300",children:[e.image_name?(0,t.jsx)("img",{src:e.image_name,alt:e.title??"",className:"h-full w-full object-cover transition-transform duration-300 group-hover:scale-105",loading:"lazy"}):(0,t.jsx)("div",{className:"flex h-full w-full items-center justify-center text-slate-400",children:(0,t.jsx)(w.MapPin,{className:"h-8 w-8"})}),(0,t.jsx)("div",{className:"absolute inset-0 bg-gradient-to-t from-black/40 to-transparent"})]}),(0,t.jsxs)("div",{className:"bg-white p-3",children:[(0,t.jsxs)("div",{className:"mb-2 flex items-center gap-2",children:[(0,t.jsxs)(b.Avatar,{className:"h-7 w-7 border border-white shadow-sm",children:[(0,t.jsx)(b.AvatarImage,{src:e.user_avatar_url??void 0}),(0,t.jsx)(b.AvatarFallback,{className:"bg-brand-primary-500 text-[10px] text-white",children:s})]}),(0,t.jsx)("span",{className:"truncate text-xs font-medium text-slate-600",children:e.user_username??i("profile.defaultUsername","Voyageur")})]}),(0,t.jsx)("p",{className:"line-clamp-2 text-sm font-semibold text-slate-900",children:e.title}),null!=e.day&&(0,t.jsxs)("p",{className:"mt-1 flex items-center gap-1 text-[11px] text-slate-400",children:[(0,t.jsx)(v.Calendar,{className:"h-3 w-3"}),e.day," ",i("profile.days","jours")]})]})]})})}function k(){let{t:e}=(0,n.useTranslation)();return(0,t.jsxs)("div",{className:"space-y-4",children:[(0,t.jsx)(d.SectionHeader,{title:e("countryPage.
5itineraries.selectionTitle")}),(0,t.jsxs)("div",{className:"flex flex-wrap justify-center gap-4 text-sm text-gray-600 lg:text-base",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(i.FaCarSide,{size:18,color:"#6B7280"}),(0,t.jsx)("span",{children:e("countryPage.itineraries.vehicleTypes.car")})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(i.FaTruckMonster,{size:18,color:"#6B7280"}),(0,t.jsx)("span",{children:e("countryPage.itineraries.vehicleTypes.4x4Required")})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)(i.FaShuttleVan,{size:18,color:"#6B7280"}),(0,t.jsx)("span",{children:e("countryPage.itineraries.vehicleTypes.van")})]})]})]})}e.s(["ItinerariesInspirations",0,function({countryId:e,countrySlug:i,countryName:l}){let{t:d,i18n:c}=(0,n.useTranslation)(),{data:h,isLoading:p}=(0,s.useHighlightedItineraryPlannersByCountryId)(e,c.language);return p?(0,t.jsxs)("div",{className:"space-y-8 pb-10 lg:space-y-10",children:[(0,t.jsx)(k,{}),(0,t.jsx)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3 lg:gap-8",children:Array.from({length:6}).map((e,r)=>(0,t.jsx)(f,{},r))}),(0,t.jsx)(r.default,{href:`/${c.language}/planner/new`,target:"_blank",className:"block",children:(0,t.jsx)(a.default,{src:"/images/itinerary/iceland/banniere_itinego_planner.webp",alt:"planificateur de voyage",width:1175,height:685,className:"w-full rounded-md"})})]}):h&&0!==h.length?(0,t.jsxs)("div",{className:"space-y-8 pb-10 lg:space-y-10",children:[(0,t.jsx)(N,{}),(0,t.jsxs)("div",{className:"space-y-8",children:[(0,t.jsx)(k,{}),(0,t.jsx)("div",{className:"grid grid-cols-1 gap-4 md:grid-cols-2 lg:grid-cols-3 lg:gap-8",children:h.map(e=>(0,t.jsx)(o.ItineraryCard,{itineraryPlanner:e,countrySlug:i},e.id))})]}),(0,t.jsx)(u,{countrySlug:i})]}):(0,t.jsx)("div",{className:"py-12 text-center",children:(0,t.jsx)("p",{className:"text-gray-500",children:d("countryPage.itineraries.noInspirations")})})}],303042)}]);

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.