PageSourceSearch

https://www.turista.com.mx/_next/static/chunks/ddbe97619d2d8506.js

js turista.com.mx collected 2026-10-02 12:33:50 UTC 34,950 bytes, 3 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,48053,e=>{"use strict";var t=e.i(43476),a=e.i(9876),r=e.i(22016),s=e.i(18566),l=e.i(27664);let i=()=>{let e=(0,a.useTheme)(),i=(0,s.usePathname)();return(0,t.jsx)("nav",{className:"mb-4 lg:mb-0 lg:mr-0 w-full lg:w-[300px] flex-shrink-0",children:(0,t.jsx)("ul",{className:"flex flex-wrap lg:flex-col gap-px",children:l.default.map(a=>{let s=i===a.url||i.startsWith(`${a.url}/`),l=e.colors.primary1,n=e.colors.primary5;return(0,t.jsx)("li",{className:"text-xs sm:text-sm md:text-base lg:text-lg w-auto max-w-full",style:{backgroundImage:s?"none":"url(/images/menu_bg.png)",backgroundRepeat:"repeat-x",backgroundPosition:"left top",backgroundColor:s?"white":l,maxHeight:51,textTransform:"uppercase"},children:(0,t.jsxs)(r.default,{href:a.url,className:`flex items-center gap-3 px-4 py-2 transition-colors duration-150 ${s?"":"hover:bg-white/10 hover:text-white"}`,style:{color:s?n:"white"},children:[(0,t.jsx)("span",{children:a.icon}),(0,t.jsx)("span",{children:a.text})]})},a.id)})})})};var n=e.i(50724),o=e.i(74167);e.s(["default",0,({title:e,children:r,sideNavSec:s})=>{let l=(0,a.useTheme)();return(0,t.jsxs)("div",{className:"relative mb-4 rounded-lg",style:{backgroundColor:l.colors.primary1},children:[(0,t.jsx)("h2",{className:"m-0 text-4xl font-normal leading-[62px] text-white px-4 uppercase relative rounded-t-lg",style:{backgroundImage:`url(${l.images.headingBg})`,backgroundRepeat:"repeat-x",backgroundPosition:"left top"},children:e}),(0,t.jsxs)("div",{className:"mx-2 p-1 flex flex-col lg:flex-row",style:{backgroundColor:l.colors.primary10},children:[s&&(0,t.jsxs)("div",{className:"mb-3 mt-4 order-last lg:order-none lg:mt-0 lg:mb-0 lg:mr-2",children:[(0,t.jsx)(i,{}),(0,t.jsxs)("div",{className:"mt-4",children:[(0,t.jsx)(n.default,{position:"1",className:"lg:block hidden"}),(0,t.jsx)(n.default,{position:"4",className:"block lg:hidden"})]}),(0,t.jsx)(o.default,{src:l.images.icon,alt:e,width:150,height:150,className:"mx-auto mt-4 block"})]}),(0,t.jsx)("div",{className:"bg-white p-4 w-full min-w-0 flex flex-col",children:r})]}),(0,t.jsx)("div",{className:"h-3 w-full rounded-b-lg",style:{backgroundImage:`url(${l.images.headingBg})`,backgroundRepeat:"repeat-x",backgroundPosition:"left bottom"}})]})}],48053)},50724,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(9165),s=e.i(89970),l=e.i(74167);let i=({code:e})=>{let r=(0,a.useRef)(null),[s,l]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{if(!r.current||s)return;r.current.innerHTML="";let t=document.createElement("div");t.innerHTML=e;let a=[];Array.from(t.childNodes).forEach(e=>{if("SCRIPT"===e.nodeName){let t=e.getAttribute("src");a.push({src:t||void 0,content:e.textContent||void 0})}else r.current?.appendChild(e.cloneNode(!0))}),(async()=>{for(let e of a)await new Promise(t=>{let a=document.createElement("script");if(a.async=!0,e.src){let r=e.src;r.startsWith("//")&&(r="https:"+r),a.src=r,a.onload=()=>t(),a.onerror=()=>t()}else e.content&&(a.textContent=e.content),t();r.current?.appendChild(a)})})(),l(!0)},[e,s]),(0,t.jsx)("div",{ref:r,className:"flex justify-center w-full max-w-full overflow-hidden bg-gray-50 border border-gray-100/50 rounded-sm py-2",style:{minHeight:"90px"}})},n=e=>{try{navigator.sendBeacon("/api/banner-click",new Blob([JSON.stringify({bid:e})],{type:"application/json"}))}catch{}};e.s(["default",0,({position:e,className:o=""})=>{let[c,d]=(0,a.useState)(null),[m,u]=(0,a.useState)(!0),[h,x]=(0,a.useState)(null),p=(0,a.useRef)(null);return((0,a.useEffect)(()=>{(async()=>{x(null);try{let t=await (0,r.getRandomBanner)(e);t?d(t):d(null)}catch(e){x(e?.message||"Unknown error")}finally{u(!1)}})()},[e]),(0,a.useEffect)(()=>{c&&p.current&&s.gsap.fromTo(p.current,{opacity:0,y:10},{opacity:1,y:0,duration:.5,ease:"power2.out"})},[c]),m)?(0,t.jsx)("div",{className:`animate-pulse bg-gray-200 rounded ${o}`,style:{minHeight:"90px",width:"100%"}}):h||!c?null:(0,t.jsx)("div",{ref:p,className:`banner-container ${o} relative`,children:(()=>{switch(c.ad_class){case"code":return(0,t.jsx)(i,{code:c.ad_code||""});case"image":return(0,t.jsx)("a",{href:c.clickurl,target:"_blank",rel:"noopener noreferrer",className:"block",onClick:()=>n(c.bid),children:(0,t.jsx)(l.default,{src:c.imageurl,alt:c.alttext,width:Number(c.ad_width)||728,height:Number(c.ad_height)||90,className:"max-w-full h-auto mx-auto"})});case"hotelhome":return(0,t.jsxs)("div",{className:"flex flex-col items-center",children:[(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("a",{href:c.clickurl,onClick:()=>n(c.bid),children:(0,t.jsx)(l.default,{src:c.imageurl,alt:c.alttext,width:436,height:329,className:"rounded-lg shadow-md"})})}),(0,t.jsxs)("div",{className:"mt-2 text-center",children:[(0,t.jsx)("span",{className:"font-bold text-lg",children:c.name}),(0,t.jsx)("a",{href:c.ad_code,className:"inline-block ml-2",children:(0,t.jsx)(l.default,{src:"https://turista.me/themes/travel16/images/spacer.png",width:14,height:18,alt:c.name})}),(0,t.jsxs)("span",{className:"block text-primary font-semibold",children:["$",c.ad_width]})]})]});default:return null}})()})}])},74167,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(57688);let s=(0,a.memo)(({src:e,alt:s,width:l,height:i,fill:n=!1,className:o="",priority:c=!1,qual
1ity:d=75,sizes:m,title:u,itemProp:h,onError:x,fallbackSrc:p="/images/placeholder.jpg"})=>{let f=e=>"https:"===window.location.protocol&&e.startsWith("http://")&&(e.includes("turista.com.mx")||e.includes("turista.me"))?e.replace("http://","https://"):e,[g,b]=(0,a.useState)(()=>f(e)),[j,y]=(0,a.useState)(!1);g===f(e)||j||b(f(e)),a.default.useEffect(()=>{b(f(e)),y(!1)},[e]);let w=()=>{!j&&p&&p!==g&&(b(p),y(!0)),x?.()};return g.startsWith("http://")||g.startsWith("https://")?(0,t.jsx)("img",{src:g,alt:s,title:u,className:o,loading:c?"eager":"lazy",fetchPriority:c?"high":void 0,decoding:"async",onError:w,...h&&{itemProp:h},...l&&{width:l},...i&&{height:i},style:n?{objectFit:"cover",width:"100%",height:"100%"}:void 0}):n?(0,t.jsx)(r.default,{src:g,alt:s,title:u,fill:!0,className:o,priority:c,quality:d,sizes:m||"100vw",onError:w,...h&&{itemProp:h}}):(0,t.jsx)(r.default,{src:g,alt:s,title:u,width:l||400,height:i||300,className:o,priority:c,quality:d,sizes:m,loading:c?"eager":"lazy",onError:w,...h&&{itemProp:h}})});e.s(["default",0,s])},9165,e=>{"use strict";let t=Number(e.i(47167).default.env.MAX_PAGES_FETCH)||7;async function a(e,t=1){let r=e.includes("?")?"&":"?",s=`${e}${r}page=${t}`,l=`/api/proxy?endpoint=${encodeURIComponent(s)}`;try{let a=await fetch(l,{headers:{Accept:"application/json","Content-Type":"application/json"}});if(!a.ok)return console.warn(`API fetchSinglePage warning: ${l} responded with HTTP ${a.status}`),{items:[],total_items:null,page_count:null,page:t};let r=await a.json(),s=function(e,t){if(!e||!e._embedded)return null;let a=t.split("?")[0].split("/").filter(Boolean),r=a[a.length-1];if(r&&e._embedded[r])return e._embedded[r];if("hotel-fotos"===r)return e._embedded.hotel_fotos||e._embedded.hotel_foto||null;if("banner"===r||"banners"===r)return e._embedded.banners||e._embedded.banner||null;if("banner-position"===r||"banner_position"===r)return e._embedded.banner_position||e._embedded.banner_positions||null;let s=Object.keys(e._embedded);if(1===s.length)return e._embedded[s[0]];let l=s.find(e=>r&&e.includes(r));return l?e._embedded[l]:null}(r,e),i=s&&Array.isArray(s)?s:[],n=r?.total_items,o="number"==typeof n?n:"string"==typeof n&&n.trim()?Number(n):null,c=r?.page_count,d="number"==typeof c?c:"string"==typeof c&&c.trim()?Number(c):null;return{items:i,total_items:Number.isFinite(o)?o:null,page_count:Number.isFinite(d)?d:null,page:t}}catch(e){return console.error(`Error fetching single page from ${l}:`,e),{items:[],total_items:null,page_count:null,page:t}}}async function r(e,s=t){let l=await a(e,1),i=[...l.items],n=Math.min(l.page_count??1,s);if(n<=1)return i;for(let t=2;t<=n;t+=10){let r=Array.from({length:Math.min(t+10-1,n)-t+1},(e,a)=>t+a);for(let t of(await Promise.all(r.map(t=>a(e,t)))))i=i.concat(t.items)}return i}async function s(e){let t=`/hotel/${e}.spanish`,a=`/api/proxy?endpoint=${encodeURIComponent(t)}`;try{let e=await fetch(a,{headers:{Accept:"application/json","Content-Type":"application/json"}});if(!e.ok)return null;return await e.json()}catch(t){return console.error(`Error fetching hotel ${e}:`,t),null}}async function l(e){let t=`/banner-random?position=${e}`,a=`/api/proxy?endpoint=${encodeURIComponent(t)}`;try{let e=await fetch(a,{headers:{Accept:"application/json","Content-Type":"application/json"}});if(!e.ok)return null;let t=await e.json();return t?.banner??t}catch(t){return console.error(`Error fetching random banner for position ${e}:`,t),null}}e.s(["fetchAllData",()=>r,"fetchSinglePage",()=>a,"getHotel",()=>s,"getRandomBanner",()=>l])},27664,e=>{"use strict";var t=e.i(43476),a=e.i(11152);let r=[{id:1,icon:(0,t.jsx)(a.FaHome,{}),text:"inicio",url:"/"},{id:2,icon:(0,t.jsx)(a.FaUser,{}),text:"Mi turista",url:"/miturista"},{id:3,icon:(0,t.jsx)(a.FaInfoCircle,{}),text:"información",url:"/informacion"},{id:4,icon:(0,t.jsx)(a.FaRegNewspaper,{}),text:"noticias",url:"/noticias"},{id:5,icon:(0,t.jsx)(a.FaCamera,{}),text:"fotos",url:"/fotos"},{id:6,icon:(0,t.jsx)(a.FaHotel,{}),text:"hoteles",url:"/hoteles"},{id:7,icon:(0,t.jsx)(a.FaLink,{}),text:"directorio",url:"/directorio"},{id:10,icon:(0,t.jsx)(a.FaRoad,{}),text:"carreteras",url:"/carreteras"},{id:8,icon:(0,t.jsx)(a.FaPlane,{}),text:"vuelos",url:"/vuelos"},{id:9,icon:(0,t.jsx)(a.FaCar,{}),text:"renta-autos",url:"/renta-autos"},{id:11,icon:(0,t.jsx)(a.FaSearch,{}),text:"buscar",url:"/buscar"}];e.s(["default",0,r])},5572,e=>{"use strict";let t=(e,t="-")=>{if(!e)return"";let a=e.trim().toLowerCase(),r={á:"a",à:"a",ä:"a",â:"a",é:"e",è:"e",ë:"e",ê:"e",í:"i",ì:"i",ï:"i",î:"i",ó:"o",ò:"o",ö:"o",ô:"o",ú:"u",ù:"u",ü:"u",û:"u",ñ:"n",ç:"c","@"
1:"at","&":"and"};return(a=a.replace(/[áàäâéèëêíìïîóòöôúùüûñç@&]/g,e=>r[e]||e)).replace(/[\W_]+/g,t)};e.s(["buildHotelSlug",0,e=>t(e,"-"),"buildLocationSlug",0,e=>{let a=e.alias?t(e.alias,"-"):"",r=t(e.hvi_desc_spanish,"-");return a||r},"sanearString",0,t])},80881,53828,e=>{"use strict";var t=e.i(47167);function a(e){let t=String(e?.sid||e?.id||"").trim(),a=(e?.title||"").toLowerCase().normalize("NFD").replace(/[\u0300-\u036f]/g,"").replace(/[^a-z0-9]+/g,"-").replace(/^-+|-+$/g,"");return t?`${t}-${a}`:""}function r(e){let a=t.default.env.NEXT_PUBLIC_TOPIC_IMAGES_BASE_URL||"//turista.me/news/topics/",r=a.endsWith("/")?a:`${a}/`,s=`${r}${e}`;return s.startsWith("//")?`https:${s}`:s}e.i(9165),t.default.env.MAX_PAGES_FETCH,e.s(["buildSlug",()=>a],80881),e.s(["getTopicImageUrl",()=>r],53828)},99545,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(22016),s=e.i(11152),l=e.i(5572),i=e.i(80881),n=e.i(53828),o=e.i(54338);let c=(0,a.memo)(({noticia:e,hideTopicImage:a})=>{let{isLoggedIn:c}=(0,o.useAuth)(),d=e.hometext||"";e.title;let m=(0,i.buildSlug)(e),u=m?`/noticias/${m}`:"#",h=e.topicimage?(0,n.getTopicImageUrl)(e.topicimage):null,x=e.portada||null,p=x||h,f=e.topictext?`/noticias/tema/${(0,l.sanearString)(e.topictext,"-")}`:null,g=(0,t.jsx)(t.Fragment,{children:x?(0,t.jsx)("img",{src:x,className:"rounded-lg w-full h-32 object-cover",alt:e.portadaalt||e.title||"Imagen de noticia"}):(0,t.jsx)("img",{src:h,className:"rounded-lg w-full h-32 object-cover",alt:e.topictext||"Imagen de noticia",title:e.topictext||"",loading:"lazy"})}),b=e.date||e.time,j="";if(b){let e=new Date(b.replace(" ","T"));j=isNaN(e.getTime())?b:e.toLocaleDateString("es-MX",{weekday:"short",day:"numeric",month:"short",year:"2-digit"})}let y=e.cattitle?.trim(),w=Number(e.counter)||0,v=Number(e.score)||0,N=Number(e.ratings)||0,k=N>0?v/N:0;return(0,t.jsxs)("article",{className:"transition rounded-lg bg-white hover:bg-gray-50 shadow-md hover:shadow-xl relative mb-5 p-4 overflow-hidden",children:[(0,t.jsxs)("div",{className:"flex flex-col md:flex-row gap-4 items-start",children:[!a&&p&&(0,t.jsx)("div",{className:"w-full md:w-1/4 mb-4 md:mb-0",children:f?(0,t.jsx)(r.default,{href:f,children:g}):g}),(0,t.jsx)("div",{className:"w-full md:w-3/4",children:(0,t.jsxs)(r.default,{href:u,className:"block",children:[(0,t.jsx)("h3",{className:"text-2xl font-bold text-gray-800 mb-2",children:e.title}),(0,t.jsx)("div",{className:"richtext text-gray-600 mb-4",dangerouslySetInnerHTML:{__html:d}})]})})]}),(0,t.jsxs)("footer",{className:"mt-4 pt-4 border-t flex items-center justify-between text-gray-500 text-sm",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3 flex-wrap",children:[(0,t.jsxs)("span",{className:"flex items-center gap-1",children:[(0,t.jsx)(s.FaRegClock,{className:"text-gray-400"}),j]}),c&&(0,t.jsxs)("span",{className:"flex items-center gap-1",title:`${w} lecturas`,children:[(0,t.jsx)(s.FaEye,{className:"text-gray-400"}),w.toLocaleString("es-MX")]}),N>0&&(0,t.jsxs)("span",{className:"flex items-center gap-1",title:`${k.toFixed(1)} de 5 (${N} ${1===N?"voto":"votos"})`,children:[(0,t.jsx)(s.FaStar,{className:"text-yellow-500"}),k.toFixed(1)]})]}),y&&(0,t.jsx)(r.default,{href:`/noticias/categoria/${(0,l.sanearString)(y,"-")}`,children:(0,t.jsxs)("span",{className:"bg-gray-100 text-gray-800 px-2 py-1 rounded-full text-sm font-semibold flex items-center",children:[(0,t.jsx)(s.FaFolder,{className:"mr-1"})," ",y]})})]})]})});var d=e.i(50724);e.s(["default",0,({noticias:e,isHome:r,perPage:s=5,title:l,hideTopicImage:i,apiEndpoint:n,totalItems:o,rpp:m=16})=>{let[u,h]=(0,a.useState)(e),[x,p]=(0,a.useState)(s),[f,g]=(0,a.useState)(1),[b,j]=(0,a.useState)(!1),[y,w]=(0,a.useState)(!1),[v,N]=(0,a.useState)(0),[k,$]=(0,a.useState)(!1),S=(0,a.useRef)(null),C=(0,a.useRef)(!1);(0,a.useEffect)(()=>{h(e),p(s),g(1),w(!1),N(0),$(!1)},[e,s]);let _=(0,a.useCallback)(async()=>{if(!n||C.current||y)return;C.current=!0,j(!0);let e=f+1,t=n.includes("?")?"&":"?",a=`${n}${t}page=${e}&pq_rpp=${m}`,r=`/api/proxy?endpoint=${encodeURIComponent(a)}`;try{let t=await fetch(r);if(!t.ok)return void w(!0);let a=await t.json(),s=function(e){let t=e?._embedded;
1if(!t||"object"!=typeof t)return[];let a=Object.keys(t);if(0===a.length)return[];let r=t[a[0]];return Array.isArray(r)?r:[]}(a);if(0===s.length)w(!0);else{h(e=>[...e,...s]),g(e);let t=v+1;N(t),t>=4&&$(!0),s.length<m&&w(!0),o&&u.length+s.length>=o&&w(!0)}}catch{w(!0)}finally{j(!1),C.current=!1}},[n,f,m,y,o,u.length,v]);(0,a.useEffect)(()=>{if(!S.current)return;let e=S.current,t=new IntersectionObserver(e=>{e[0].isIntersecting&&(x<u.length?p(e=>Math.min(e+s,u.length)):!n||y||k||C.current||_())},{root:null,rootMargin:"200px 0px",threshold:.1});return t.observe(e),()=>t.disconnect()},[u.length,x,s,n,y,k,_]),(0,a.useEffect)(()=>{u.length>x&&p(e=>Math.min(e+s,u.length))},[u.length]);let I=u.slice(0,x),M=n&&!y||x<u.length;return(0,t.jsxs)("div",{children:[I.map((e,r)=>(0,t.jsxs)(a.default.Fragment,{children:[r%5==0&&r>0&&(0,t.jsx)("div",{className:"my-4 flex justify-center",children:(0,t.jsx)("div",{className:"w-full md:w-[728px] lg:w-[970px]",children:(0,t.jsx)(d.default,{position:"0"})})}),(0,t.jsx)(c,{noticia:e,hideTopicImage:i})]},e.sid||e.id||r)),b&&(0,t.jsx)("div",{className:"flex justify-center py-6",children:(0,t.jsx)("div",{className:"animate-spin w-6 h-6 border-3 border-gray-300 border-t-gray-600 rounded-full"})}),k&&!y&&(0,t.jsx)("div",{className:"flex justify-center py-8",children:(0,t.jsx)("button",{onClick:()=>{$(!1),N(0)},className:"inline-flex items-center gap-2 text-white font-semibold px-8 py-3 rounded-lg transition duration-200 shadow-md hover:shadow-lg hover:brightness-90 cursor-pointer",style:{backgroundColor:"#30642d"},children:"📰 Cargar más noticias"})}),M&&!k&&(0,t.jsx)("div",{ref:S,className:"h-10 w-full","aria-hidden":"true"})]})}],99545)},61044,e=>{"use strict";var t=e.i(43476),a=e.i(9876);e.s(["default",0,({title:e,children:r})=>{let s=(0,a.useTheme)();return(0,t.jsx)("div",{className:"border border-[#e1e1e1] mb-4 rounded-lg",children:(0,t.jsxs)("div",{className:"bg-[#f3f3f3] border border-[#fcfcfc] rounded-[7px]",children:[e&&(0,t.jsx)("h2",{className:"bg-[#e4e3e3] text-[1.8rem] font-normal text-primary1 leading-[39px] border-b border-[#f8f8f8] px-5 m-0 rounded-t-[7px] relative tracking-tighter",style:{color:s.colors.primary1},children:e}),(0,t.jsx)("div",{className:`text-[#acabab] p-4 ${e?"border-t border-[#e7e7e7]":""}`,children:r})]})})}])},83117,(e,t,a)=>{t.exports={stateMapUrl:"https://www.stay22.com/embed/691f683a6598be77b170a25b",afiliateId:"enriqueadelinomontesaraujo",campaignId:"chiapasturistacommx"}},44164,e=>{"use strict";e.s(["default",0,{stateMapUrl:"https://www.stay22.com/embed/691f713caa56fa55fafbbcda",afiliateId:"enriqueadelinomontesaraujo",campaignId:"edomexicoturistacommx"}])},49093,(e,t,a)=>{t.exports={stateMapUrl:"https://www.stay22.com/embed/691f72a6aa56fa55fafbc0ad",afiliateId:"enriqueadelinomontesaraujo",campaignId:"yucatanturistacommx"}},87086,(e,t,a)=>{t.exports={stateMapUrl:"https://www.stay22.com/embed/692d3aa6b2478d16bb97600e",afiliateId:"enriqueadelinomontesaraujo",campaignId:"pueblaturistacommx"}},98628,(e,t,a)=>{t.exports={stateMapUrl:"https://www.stay22.com/embed/6935ef95f30a49984291eda7",afiliateId:"enriqueadelinomontesaraujo",campaignId:"quintanaroo-turistacommx"}},97175,(e,t,a)=>{t.exports={stateMapUrl:"https://www.stay22.com/embed/6935df4e67173ecf385cbf52",afiliateId:"enriqueadelinomontesaraujo",campaignId:"mexico-turistacommx"}},82040,e=>{"use strict";var t=e.i(5572);let a="https://turista.me";function r(e){let t=Math.min(Math.max(Math.floor(Number(e.rating||0))||0,1),6);return e.portada?a+e.portada:`/images/hoteles-sin-foto/${t}starshotel_normal.jpg`}function s(e){return new Intl.NumberFormat("es-MX",{style:"currency",currency:"MXN",maximumFractionDigits:0}).format(e)}function l(e,a,r,s){let l=`/hotel/${e.hotelid}/${(0,t.buildHotelSlug)(e.nombre)}`,i=function(e){if(!e?.config)return{};try{return"string"==typeof e.config?JSON.parse(e.config):e.config}catch{return{}}}(e),n=i.expediaId||null,o=i.hotelsId||null,c=i.searchAlias||e.nombre,d=i.phoneBooking||null,m=i.whatsappBooking||null,u=i.telegramBooking||null,h=i.bookingEmail||null,x=e.paginaweb||null,p=String(i.bookingUrl||"").trim(),f=p?p.startsWith("http")?p:`https://${p}`:null,g=s?.hotels||{},b=s?.expedia||{},j=o&&g.clickUrl&&g.searchBaseUrl?`${g.clickUrl}?url=${encodeURIComponent(`${g.searchBaseUrl}${c}`)}`:null,y=n&&b.clickUrl&&b.hotelBaseUrl?`${b.clickUrl}?url=${encodeURIComponent(`${b.hotelBaseUrl}${n}${b.hotelSuffix||".Hotel-Information"}`)}`:null,w=null,v=r?.afiliateId,N=r?.campaignId;if(v&&N){let e=a?.metadata?.name||"",t=encodeURIComponent(e?`${e}, Mexico`:"Mexico");w=`https://www.stay22.com/allez/roam?aid=${encodeURIComponent(v)}&campaign=${encodeURIComponent(N)}&hotelname=${encodeURIComponent(c||"Hotel")}&address=${t}`}let k=m?`https://wa.me/${m.replace(/\D/g,"")}?text=${encodeURIComponent(`Hola, me interesa reservar en ${e.nombre}. \xbfPodr\xedan darme informaci\xf3n sobre disponibilidad y tarifas?
2
3Esta solicitud viene de: https://www.turista.com.mx${l}`)}`:null;return{hotelUrl:l,hotelExpediaHref:y,hotelBookingHref:j,externalCtaHref:w||y||j,stay22Url:w,phoneBooking:d,whatsappBooking:m,whatsappHref:k,telegramBooking:u,bookingEmail:h,websiteBooking:x,bookingUrl:f,hasOtaLinks:!!(n||o)}}e.s(["HOTEL_CDN",0,a,"buildHotelLinks",()=>l,"formatMXN",()=>s,"getHotelCoverImage",()=>r])},24204,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(57688),s=e.i(9876),l=e.i(36768),i=e.i(83117),n=e.i(44164),o=e.i(49
3093),c=e.i(87086),d=e.i(98628),m=e.i(97175);let u={chiapas:"Chiapas es auténtico por naturaleza.  Chiapas es, y ha sido, siempre la última frontera de México, el lugar que aparece en tus sueños cuando la selva tapa el cielo con el verde de su follaje, cascadas maravillosas, lagos de colores, un estado que no puedes dejar de visitar.",edomexico:"El estado de México tiene mucho para ver, desde los más impresionantes sitios arqueológicos, museos y maravillas naturales; hasta los más modernos desarrollos urbanos.",yucatan:"Yucatán es la tierra del faisán y del venado, es poesía... es música... el lugar de las maravillas, imponente arqueología, la cuna de la trova. No dejes de visitar la tierra de los elegidos.",puebla:"Puebla es historia, gastronomía y arquitectura colonial. Entre volcanes imponentes, pueblos mágicos y sabores únicos como el mole poblano, es un destino obligado para descubrir el corazón de México.",quintanaroo:"Quintana Roo es un estado que combina la cultura maya con la modernidad. Con sus playas paradisíacas, sitios arqueológicos impresionantes y gastronomía única, es un destino que no puedes perderte.",mexico:"México es un país rico en cultura, historia y tradiciones. Desde las antiguas civilizaciones prehispánicas hasta la vibrante vida moderna, cada rincón ofrece experiencias únicas. Descubre sus maravillas naturales, su gastronomía re
3conocida mundialmente y la calidez de su gente."},h=(0,a.memo)(({metadata:e,variant:h="home"})=>{let x=u[e.slug]??"",p=(0,s.useTheme)(),f=p.metadata.slug,[g,b]=(0,a.useState)(!1),j=(0,a.useRef)(null);(0,a.useEffect)(()=>{let e=new IntersectionObserver(t=>{t.forEach(t=>{t.isIntersecting&&(b(!0),e.disconnect())})},{rootMargin:"200px",threshold:.1});return j.current&&e.observe(j.current),()=>e.disconnect()},[]);let y={chiapas:i.default,edomexico:n.default,yucatan:o.default,puebla:c.default,quintanaroo:d.default,mexico:m.default}[f],w="hoteles"===h,v=w?700:520;return w?(0,t.jsx)("section",{className:"w-full",children:(0,t.jsxs)("div",{className:"bg-white rounded-md p-6 md:p-8 flex flex-col items-center",ref:j,children:[(0,t.jsxs)("h3",{className:"text-center text-red-600 uppercase text-lg md:text-xl",children:["¿Conoces ",e.name,"?"]}),(0,t.jsx)("div",{className:"mt-6 mb-8 flex justify-center",children:(0,t.jsx)("div",{className:"border-t border-gray-300 w-2/3 max-w-xl"})}),x&&(0,t.jsx)("p",{className:"text-gray-700 text-justify max-w-4xl mx-auto leading-relaxed mb-8",children:x}),(0,t.jsx)("div",{className:"w-full max-w-5xl bg-white border border-gray-300 rounded shadow-sm flex items-stretch justify-center",children:y?.stateMapUrl&&g?(0,t.jsx)("iframe",{id:"stay22-widget",src:y.stateMapUrl,width:"100%",height:v,frameBorder:"0",loading:"lazy",title:"Mapa de hoteles"}):(0,t.jsx)("div",{className:"w-full flex items-center justify-center bg-gray-100 text-gray-500",style:{height:v},children:(0,t.jsx)("span",{children:"Cargando mapa..."})})})]})}):(0,t.jsxs)("section",{className:"w-full",children:[(0,t.jsxs)("div",{className:"bg-white rounded-md p-6 md:p-8 flex flex-col items-center",children:[(0,t.jsx)("div",{className:"w-24 h-24 md:w-32 md:h-32 rounded-full bg-white border border-gray-300 mb-4 overflow-hidden flex items-center justify-center",children:(0,t.jsx)(r.default,{src:p.images.topicTurista,alt:e.name,width:128,height:128,className:"w-full h-full object-cover",loading:"lazy",quality:75})}),(0,t.jsx)("div",{className:"text-center mb-2",children:(0,t.jsxs)("p",{className:"text-sm md:text-base text-red-700 font-serif",children:["La Guía de Turismo en ",e.name]})}),(0,t.jsx)(l.default,{styleClass:"flex gap-3 justify-center mb-4 text-2xl text-primary2",slugEstado:f}),(0,t.jsx)("div",{ref:j,className:"w-full max-w-5xl bg-white border border-gray-300 rounded shadow-sm flex items-stretch justify-center",children:y?.stateMapUrl&&g?(0,t.jsx)("iframe",{id:"stay22-widget",src:y.stateMapUrl,width:"100%",height:v,frameBorder:"0",loading:"lazy",title:"Mapa de hoteles"}):(0,t.jsx)("div",{className:"w-full flex items-center justify-center bg-gray-100 text-gray-500",style:{height:v},children:(0,t.jsx)("span",{children:"Cargando mapa..."})})})]}),(0,t.jsxs)("h3",{className:"mt-8 text-center text-red-600 uppercase text-lg md:text-xl",children:["¿Conoces ",e.name,"?"]}),(0,t.jsx)("div",{className:"mt-6 mb-8 flex justify-center",children:(0,t.jsx)("div",{className:"border-t border-gray-300 w-2/3 max-w-xl"})}),x&&(0,t.jsx)("p",{className:"text-gray-700 text-justify max-w-4xl mx-auto leading-relaxed",children:x})]})});e.s(["default",0,h])},76285,e=>{"use strict";var t=e.i(43476),a=e.i(9876);let r=({title:e,subtitle:r,className:s=""})=>{let l=(0,a.useTheme)();return(0,t.jsx)("div",{className:`mb-8 ${s}`,children:(0,t.jsxs)("h4",{className:"text-2xl sm:text-4xl text-center tracking-wider",style:{color:l.colors.primary2},children:[(0,t.jsx)("span",{className:"text-black block sm:inline-block sm:mx-1",children:e}),(0,t.jsx)("span",{className:"block sm:inline-block sm:mx-1",children:r})]})})};var s=e.i(33401);let l=({text:e})=>{let r=(0,a.useTheme)();return(0,t.jsxs)("div",{className:"name transition-all duration-300 flex items-center text-xl pl-2 pr-4 rounded-md cursor-pointer",style:{color:r.colors.primary5},onMouseEnter:e=>{e.currentTarget.style.backgroundColor=r.colors.primary6,e.currentTarget.style.color=r.colors.primary10},onMouseLeave:e=>{e.currentTarget.style.backgroundColor="transparent",e.currentTarget.style.color=r.colors.primary5},children:[(0,t.jsx)(s.BiChevronRight,{}),e]})};var i=e.i(22016),n=e.i(45789),o=e.i(5572);e.s(["default",0,({metadata:e,locations:a,showTitle:s=!0})=>{let{t:c}=(0,n.useTranslation)(),d=e.metadata?.name||"Estado";return(0,t.jsxs)("section",{className:"py-8",children:[s&&(0,t.jsx)(r,{title:c("Principales Destinos"),subtitle:` ${c("en")} ${c(d)}`,className:"mt-12"}),(0,t.jsx)("ul",{className:"columns-2 sm:columns-3 xl:columns-4 gap-4",children:a&&a.map((e,a)=>
3{if(e.hviid&&parseInt(e.hviid)>0){let r=(0,o.buildLocationSlug)(e);return(0,t.jsx)("li",{className:"break-inside-avoid mb-2",children:(0,t.jsx)(i.default,{href:`/hoteles/${r}`,title:`Hoteles en ${e.hvi_desc_spanish}`,className:"block",children:(0,t.jsx)(l,{text:e.hvi_desc_spanish})})},a)}return null})})]})}],76285)},80341,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(11152);e.s(["default",0,({limit:e=5})=>{let[s,l]=(0,a.useState)([]),[i,n]=(0,a.useState)(""),[o,c]=(0,a.useState)(!0),[d,m]=(0,a.useState)(!1),[u,h]=(0,a.useState)(null),[x,p]=(0,a.useState)(!1);(0,a.useEffect)(()=>{p(!!(window.localStorage.getItem("miturista_login")||window.localStorage.getItem("miturista_auth")))},[]);let f=async()=>{c(!0),h(null);try{let t=await fetch(`/api/public-messages?limit=${e}`);if(!t.ok)throw Error("No se pudieron cargar los mensajes");let a=await t.json();l(a.messages||[])}catch(e){h("Error al cargar mensajes"),l([{id:1,content:"RECORRIDOS AL ESTADO INGLES O ESPANOL 961 19 22 6 99",username:"eltaxista",created_at:new Date(Date.now()-36e5).toISOString()}])}finally{c(!1)}};(0,a.useEffect)(()=>{f()},[e]);let g=async e=>{e.preventDefault();let t=i.trim();if(t&&!d){if(/[\u{1F300}-\u{1F9FF}]|[\u{2600}-\u{26FF}]|[\u{2700}-\u{27BF}]/u.test(t))return void h("Los emojis no son permitidos. Por favor usa solo texto simple.");m(!0),h(null);try{let e=window.localStorage.getItem("miturista_auth"),a=e?e.replace(/^Bearer\s+/i,""):null;if(!a)return void h("Debes iniciar sesión para publicar");let r="usuario",i="Usu",o=window.localStorage.getItem("miturista_login");if(o)try{let e=JSON.parse(o);r=e.username||e.login||e.uname||"usuario",i=e.name&&e.name.trim()?e.name:r.slice(0,3)}catch(e){i=(r=o||"usuario").slice(0,3)}else{let e=window.localStorage.getItem("miturista_auth");if(e)try{let t=JSON.parse(e);r=t.username||t.login||t.uname||"usuario",i=t.name&&t.name.trim()?t.name:r.slice(0,3)}catch(e){r="usuario",i="Usu"}}let c=await fetch("/api/public-messages",{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${a}`},body:JSON.stringify({content:t,username:r,name:i})});if(!c.ok){let e=await c.json();throw Error(e.error||"Error al publicar mensaje")}let d=await c.json();l([d.message,...s]),n("")}catch(e){h(e.message||"Error al publicar mensaje")}finally{m(!1)}}},b=(e,t)=>t&&t.trim()?t.trim():e&&e.length>3?e.slice(0,3)+"...":e||"Usu";return(0,t.jsxs)("div",{className:"public-messages-wall",children:[x&&(0,t.jsxs)("form",{onSubmit:g,className:"mb-4",children:[(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)("input",{type:"text",value:i,onChange:e=>n(e.target.value.slice(0,280)),placeholder:"Comparte tu experiencia...",className:"flex-1 px-3 py-2 border border-gray-300 rounded-lg focus:outline-none focus:ring-2 focus:ring-emerald-500 text-sm",maxLength:280,disabled:d}),(0,t.jsx)("button",{type:"submit",disabled:!i.trim()||d,className:"px-4 py-2 bg-emerald-600 text-white rounded-lg hover:bg-emerald-700 disabled:bg-gray-300 disabled:cursor-not-allowed transition-colors flex items-center gap-2",children:d?(0,t.jsx)(r.FaSpinner,{className:"animate-spin"}):(0,t.jsx)(r.FaPaperPlane,{})})]}),(0,t.jsxs)("div",{className:"text-xs text-gray-500 mt-1 text-right",children:[i.length,"/280"]})]}),!x&&(0,t.jsxs)("div",{className:"mb-4 p-3 bg-gray-50 rounded-lg text-center",children:[(0,t.jsx)("p",{className:"text-sm text-gray-600 mb-2",children:"Inicia sesión para participar en el muro del viajero"}),(0,t.jsx)("a",{href:"/login",className:"text-emerald-600 hover:text-emerald-700 text-sm font-medium",children:"Iniciar sesión →"})]}),u&&(0,t.jsx)("div",{className:"mb-4 p-3 bg-red-50 border border-red-200 rounded-lg text-red-600 text-sm",children:u}),(0,t.jsx)("div",{className:"messages-list space-y-3",children:o?(0,t.jsx)("div",{className:"flex justify-center py-8",children:(0,t.jsx)(r.FaSpinner,{className:"animate-spin text-emerald-600 text-2xl"})}):0===s.length?(0,t.jsx)("div",{className:"text-center py-8 text-gray-500",children:(0,t.jsx)("p",{children:"No hay mensajes aún. ¡Sé el primero en compartir!"})}):s.map(e=>(0,t.jsx)("div",{className:"bg-white border border-gray-200 rounded-lg p-3 hover:shadow-md transition-shadow",children:(0,t.jsxs)("div",{className:"flex gap-3",children:[(0,t.jsx)("div",{className:"flex-shrink-0",children:(0,t.jsx)("div",{className:"w-10 h-10 bg-emerald-100 rounded-full flex items-center justify-center text-emerald-700 font-bold text-sm",children:b(e.username,e.name).slice(0,2).toUpperCase()})}),(0,t.jsxs)("div",{className:"flex-1 min-w-0",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 mb-1",children:[(0,t.jsx)("span",{className:"font-semibold text-gray-800 text-sm",children:b(e.username,e.name)}),(0,t.jsxs)("span",{className:"text-xs text-gray-500 flex items-center gap-1",children:[(0,t.jsx)(r.FaClock,{className:"text-xs"}),(e=>
3{try{let[t,a]=e.split(" "),[r,s,l]=t.split("-").map(Number),[i,n,o]=a.split(":").map(Number),c=new Date(r,s-1,l,i,n,o),d=new Date,m=Math.abs(d.getTime()-c.getTime()),u=Math.floor(m/1e3),h=Math.floor(u/60),x=Math.floor(h/60),p=Math.floor(x/24);if(u<60)return"hace unos segundos";if(h<1)return"hace 1 minuto";if(h<60)return`hace ${h} minutos`;else if(x<2)return"hace 1 hora";else if(x<24)return`hace ${x} horas`;else if(p<2)return"hace 1 día";else if(p<30)return`hace ${p} d\xedas`;else if(p<365){let e=Math.floor(p/30);return`hace ${e} mes${e>1?"es":""}`}else{let e=Math.floor(p/365);return`hace ${e} a\xf1o${e>1?"s":""}`}}catch{return"Fecha desconocida"}})(e.created_at)]})]}),(0,t.jsx)("p",{className:"text-gray-700 text-sm break-words",children:e.content})]})]})},e.id))}),!o&&s.length>=e&&(0,t.jsx)("div",{className:"mt-4 text-center",children:(0,t.jsx)("button",{onClick:f,className:"text-emerald-600 hover:text-emerald-700 text-sm font-medium",children:"Cargar más mensajes →"})})]})}])},723,e=>{"use strict";var t=e.i(43476),a=e.i(71645),r=e.i(22016),s=e.i(5572),l=e.i(82040),i=e.i(74167);let n=["Reserva Directa","Atención Directa","Sin Intermediarios","Mejor Tarifa"];e.s(["default",0,({hoteles:e,vistaNames:o,title:c="Hoteles Recomendados",bandColor:d})=>{let m=(0,a.useRef)(null),[u,h]=(0,a.useState)(!1),[x,p]=(0,a.useState)(!0),f=()=>{m.current&&(h(m.current.scrollLeft>0),p(m.current.scrollLeft<m.current.scrollWidth-m.current.clientWidth))},g=e=>{m.current&&m.current.scrollBy({left:"left"===e?-300:300,behavior:"smooth"})};return((0,a.useEffect)(()=>(f(),window.addEventListener("resize",f),()=>window.removeEventListener("resize",f)),[e]),e&&0!==e.length)?(0,t.jsxs)("section",{className:"py-8",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[(0,t.jsx)("h2",{className:"text-xl md:text-2xl font-bold text-gray-900",children:c}),(0,t.jsxs)("div",{className:"flex gap-2",children:[(0,t.jsx)("button",{onClick:()=>g("left"),disabled:!u,className:"p-1.5 rounded-full bg-gray-100 hover:bg-gray-200 disabled:opacity-30 disabled:cursor-not-allowed transition-colors border border-gray-200","aria-label":"Anterior",children:(0,t.jsx)("svg",{className:"w-5 h-5 text-gray-600",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})})}),(0,t.jsx)("button",{onClick:()=>g("right"),disabled:!x,className:"p-1.5 rounded-full bg-gray-100 hover:bg-gray-200 disabled:opacity-30 disabled:cursor-not-allowed transition-colors border border-gray-200","aria-label":"Siguiente",children:(0,t.jsx)("svg",{className:"w-5 h-5 text-gray-600",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",children:(0,t.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})})})]})]}),(0,t.jsx)("div",{ref:m,className:"flex gap-4 overflow-x-auto pb-2 scrollbar-hide",onScroll:f,children:e.map((e,a)=>{let c=`/hotel/${e.hotelid}/${(0,s.buildHotelSlug)(e.nombre)}`,m=(0,l.getHotelCoverImage)(e),u=Math.floor(Number(e.rating||0)),h=Number(e.promorate||e.lowestrate||0),x=o[String(e.vista)]||"";return(0,t.jsxs)(r.default,{href:c,className:"flex-shrink-0 w-52 group",children:[(0,t.jsxs)("div",{className:"relative bg-gray-100 rounded-lg overflow-hidden aspect-[4/3] mb-2",children:[(0,t.jsx)(i.default,{src:m,alt:e.nombre,className:"w-full h-full object-cover group-hover:scale-105 transition-transform duration-300",width:220,height:165,quality:60}),(0,t.jsx)("span",{className:"absolute top-2 left-2 text-[10px] font-bold uppercase tracking-wider text-white px-2 py-0.5 rounded-full shadow",style:{backgroundColor:d||"#b45309"},children:n[a%n.length]})]}),(0,t.jsx)("h3",{className:"text-sm font-medium text-gray-800 line-clamp-2 group-hover:text-blue-600 transition-colors",children:e.nombre}),x&&(0,t.jsx)("p",{className:"text-xs text-gray-500 mt-1",children:x}),u>0&&(6===u?(0,t.jsx)("p",{className:"text-xs font-bold text-orange-600 mt-1",children:"Gran Turismo"}):(0,t.jsxs)("p",{className:"text-yellow-400 text-sm mt-0.5",title:`${u} estrellas`,children:["★".repeat(Math.min(u,5)),(0,t.jsx)("span",{className:"text-gray-300",children:"★".repeat(Math.max(0,5-u))})]})),h>0&&(0,t.jsxs)("p",{className:"text-sm font-semibold text-green-700 mt-1",children:[(0,l.formatMXN)(h)," ",(0,t.jsx)("span",{className:"text-xs font-normal text-gray-500",children:"/ noche"})]})]},e.hotelid)})})]}):null}])},35318,e=>{e.v(t=>Promise.all(["static/chunks/03607d2c6a751cdb.js"].map(t=>e.l(t))).then(()=>t(22140)))}]);

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.