PageSourceSearch

https://www.travafa.com/_next/static/chunks/77558.3578b6b5b7fb5421.js

js travafa.com collected 2026-10-09 04:50:34 UTC 14,972 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[77558],{5937:(e,a,l)=>{"use strict";l.d(a,{A:()=>t});let t=(0,l(71847).A)("message-circle",[["path",{d:"M2.992 16.342a2 2 0 0 1 .094 1.167l-1.065 3.29a1 1 0 0 0 1.236 1.168l3.413-.998a2 2 0 0 1 1.099.092 10 10 0 1 0-4.777-4.719",key:"1sd12s"}]])},18085:(e,a,l)=>{"use strict";l.d(a,{A:()=>t});let t=(0,l(71847).A)("send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]])},24691:e=>{e.exports={overlay:"media-dialogs_overlay__WOdwg",backdrop:"media-dialogs_backdrop__VuosM",backdropVisible:"media-dialogs_backdropVisible__yIpQa",panel:"media-dialogs_panel___AvCv",panelComments:"media-dialogs_panelComments__jAxaR",panelLikes:"media-dialogs_panelLikes__mN6Qb",panelVisible:"media-dialogs_panelVisible__dIyWC",dialog:"media-dialogs_dialog__m09xZ",dialogComments:"media-dialogs_dialogComments__JLCe3",dialogLikes:"media-dialogs_dialogLikes__wfwvS",header:"media-dialogs_header__hdlP9",headerLeft:"media-dialogs_headerLeft__sKVqV",headerTitle:"media-dialogs_headerTitle__hzQJu",headerIcon:"media-dialogs_headerIcon__T7Xgd",heartIcon:"media-dialogs_heartIcon__Ezikr",closeIcon:"media-dialogs_closeIcon__MH9sg",closeBtn:"media-dialogs_closeBtn__mXGn5",body:"media-dialogs_body__FnfLz",bodyCentered:"media-dialogs_bodyCentered__ZJ2vx",avatar:"media-dialogs_avatar__Jfh42",objectCover:"media-dialogs_objectCover__g_Vw3",avatarFallback:"media-dialogs_avatarFallback__An9xu",avatarFallbackText:"media-dialogs_avatarFallbackText__r0kgP",skeletonRow:"media-dialogs_skeletonRow__sIAz4",dlgPulse:"media-dialogs_dlgPulse__OALu7",skelCircle:"media-dialogs_skelCircle__uOKcR",skelLines:"media-dialogs_skelLines__20LvD",skelLineStrong:"media-dialogs_skelLineStrong__8Pg2c",skelLine:"media-dialogs_skelLine__2Nbsj",skelLineSmall:"media-dialogs_skelLineSmall__unnAE",empty:"media-dialogs_empty__3pXhH",emptyIcon:"media-dialogs_emptyIcon__Xm1KQ",mutedIcon:"media-dialogs_mutedIcon__goTjn",sendIcon:"media-dialogs_sendIcon__omB4g",emptyTitle:"media-dialogs_emptyTitle__pk_Mh",emptyDesc:"media-dialogs_emptyDesc__XJdBn",commentRow:"media-dialogs_commentRow__cu9xO",commentMain:"media-dialogs_commentMain__xQAAP",commentTop:"media-dialogs_commentTop__q_n40",commentTextWrap:"media-dialogs_commentTextWrap__invEt",commentName:"media-dialogs_commentName__jnEyv",commentHandle:"media-dialogs_commentHandle__fpo5L",commentText:"media-dialogs_commentText__6jFgy",commentTime:"media-dialogs_commentTime__r39pF",deleteBtn:"media-dialogs_deleteBtn__jGpPV",loadMoreWrap:"media-dialogs_loadMoreWrap__7HB3G",loadMoreBtn:"media-dialogs_loadMoreBtn__iofzN",confirmBar:"media-dialogs_confirmBar__Pnn0f",confirmText:"media-dialogs_confirmText__9wJs8",confirmActions:"media-dialogs_confirmActions__rNk6h",btn:"media-dialogs_btn__BZEBn",btnSecondary:"media-dialogs_btnSecondary___hyDi",btnDanger:"media-dialogs_btnDanger__5LYqH",inputRow:"media-dialogs_inputRow__Vf055",actionError:"media-dialogs_actionError__XJqZ1",currentUserBubble:"media-dialogs_currentUserBubble__d6bpM",currentUserBubbleText:"media-dialogs_currentUserBubbleText__647ZP",inputWrap:"media-dialogs_inputWrap__i_XjE",input:"media-dialogs_input__mQIiY",sendBtn:"media-dialogs_sendBtn__0XCN_",likeItem:"media-dialogs_likeItem__Zomp8",likeName:"media-dialogs_likeName__RHpQd",likeHandle:"media-dialogs_likeHandle__hL4SJ",spin:"media-dialogs_spin__omctg",dlgSpin:"media-dialogs_dlgSpin___q4r1",replyBtn:"media-dialogs_replyBtn___39Hl",replies:"media-dialogs_replies__zgCZA"}},35299:(e,a,l)=>{"use strict";l.d(a,{A:()=>t});let t=(0,l(71847).A)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]])},65229:(e,a,l)=>{"use strict";l.d(a,{A:()=>t});let t=(0,l(71847).A)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]])},71360:(e,a,l)=>{"use strict";l.d(a,{A:()=>t});let t=(0,l(71847).A)("trash-2",[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]])},71847:(e,a,l)=>{"use strict";l.d(a,{A:()=>o});var t=l(12115);let s=e=>{let a=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,a,l)=>l?l.toUpperCase():a.toLowerCase());return a.charAt(0).toUpperCase()+a.slice(1)},i=function(){for(var e=arguments.length,a=Array(e),l=0;l<e;l++)a[l]=arguments[l];return a.filter((e,a,l)=>!!e&&""!==e.trim()&&l.indexOf(e)===a).join(" ").trim()};var n={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let d=(0,t.forwardRef)((e,a)=>{let{color:l="currentColor",size:s=24,strokeWidth:d=2,absoluteStrokeWidth:o,className:r="",children:c,iconNode:m,..._}=e;return(0,t.createElement)("svg",{ref:a,...n,width:s,height:s,stroke:l,strokeWidth:o?24*Number(d)/Number(s):d,className:i("lucide",r),...!c&&!(e=>{for(let a in e)if(a.startsWith("aria-")||"role"===a||"title"===a)return!0})(_)&&{"aria-hidden":"true"},..._},[...m.map(e=>{let[a,l]=e;return(0,t.createElement)(a,l)}),...Array.isArray(c)?c:[c]])}),o=(e,a)=>{let l=(0,t.forwardRef)((l,n)=>{let{className:o,...r}=l;return(0,t.createElement)(d,{ref:n,iconNode:a,className:i("lucide-".concat(s(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),"lucide-".concat(e),o),...r})});return l.displayName=s(e),l}},77558:(e,a,l)=>{"use strict";l.r(a),l.d(a,{default:()=>b});var t=l(95155),s=l(12115),i=l(47650),n=l(1213),d=l(35299),o=l(71360),r=l(5937),c=l(65229),m=l(18085),_=l(73754),u=l(90721),p=l(99667),g=l(24691),h=l.n(g),v=l(26276);function f(e){let{src:a,name:l,size:s=36}=e,i=(0,p.I)(l)||"?";return(0,t.jsx)("div",{className:h().avatar,style:{width:s,height:s},children:(0,t.jsx)(p.A,{src:a,alt:l||"user",sizes:"".concat(s,"px"),className:h().objectCover,fallback:(0,t.jsx)("div",{className:h().avatarFallback,children:(0,t.jsx)("span",{className:h().avatarFallbackText,style:{fontSize:s>=44?14:12},children:i})})})})}function x(){return(0,t.jsxs)("div",{className:h().skeletonRow,children:[(0,t.jsx)("div",{className:h().skelCircle}),(0,t.jsxs)("div",{className:h().skelLines,children:[(0,t.jsx)("div",{className:h().skelLineStrong}),(0,t.jsx)("div",{className:h().skelLine}),(0,t.jsx)("div",{className:h().skelLineSmall})]})]})}function j(e){var a;let{comment:l,currentUserId:s,onDelete:i,isDeleting:n,onReply:r,deletingId:c,isReply:m=!1}=e,_=l.user||{},u=_.user_display_name||_.display_name||_.name||[_.user_first_name,_.user_second_name].filter(
1Boolean).join(" ")||"User",p=_.user_handle||_.handle||"",g=_.user_signed_image||_.profile_picture||"",v=String(_.user_id||_.id||_.uid||""),x=!!s&&!!v&&v===String(s);return(0,t.jsxs)("div",{className:h().commentRow,children:[(0,t.jsx)(f,{src:g,name:u,size:36}),(0,t.jsxs)("div",{className:h().commentMain,children:[(0,t.jsxs)("div",{className:h().commentTop,children:[(0,t.jsxs)("div",{className:h().commentTextWrap,children:[(0,t.jsx)("span",{className:h().commentName,children:u}),p&&(0,t.jsxs)("span",{className:h().commentHandle,children:["@",p]}),(0,t.jsx)("span",{className:h().commentText,children:l.text})]}),x&&(0,t.jsx)("button",{onClick:()=>i(l.comment_id),disabled:n,className:h().deleteBtn,"aria-label":"Delete comment",children:n?(0,t.jsx)(d.A,{size:14,className:h().spin}):(0,t.jsx)(o.A,{size:14})})]}),l.created_at&&(0,t.jsx)("p",{className:h().commentTime,children:function(e){if(!e)return"";let a=(Date.now()-new Date(e).getTime())/1e3;return a<60?"".concat(Math.floor(a),"s"):a<3600?"".concat(Math.floor(a/60),"m"):a<86400?"".concat(Math.floor(a/3600),"h"):a<604800?"".concat(Math.floor(a/86400),"d"):new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric"})}(l.created_at)}),!m&&r&&(0,t.jsx)("button",{type:"button",className:h().replyBtn,onClick:()=>r(l),children:"Reply"}),!m&&(null==(a=l.replies)?void 0:a.length)>0&&(0,t.jsx)("div",{className:h().replies,children:l.replies.map(e=>(0,t.jsx)(j,{comment:e,currentUserId:s,onDelete:i,isDeleting:c===e.comment_id,isReply:!0},e.comment_id))})]})]})}function b(e){var a,l,o,p;let{mediaId:g,modelType:b,commentCount:y=0,isOpen:k,onClose:N,onCountChange:C}=e,A=(0,n.wA)(),w=(0,s.useRef)(null),L=(0,s.useRef)(null),[B,I]=(0,s.useState)(""),[S,T]=(0,s.useState)(null),[M,E]=(0,s.useState)(null),[z,R]=(0,s.use
1State)(null),[D,H]=(0,s.useState)(!1),[P,W]=(0,s.useState)(null),U=(0,n.d4)(v.rH),V=(0,n.d4)(v.mC),F=(0,n.d4)(v.MM),X=(0,n.d4)(v.bx),Z=(0,n.d4)(v.Bv),J=(0,n.d4)(v.ef),Q=(0,n.d4)(v.$X),q=(0,n.d4)(v.Dg),K=function(){let[e,a]=(0,s.useState)(null);return(0,s.useEffect)(()=>{let e=document.getElementById("modal-root");e||((e=document.createElement("div")).id="modal-root",document.body.appendChild(e)),a(e)},[]),e}(),{userId:O}=(0,_.i)(),G=(0,n.d4)(e=>{var a;return null==(a=e.userProfile)?void 0:a.profile}),$=(0,s.useRef)(0);$.current=null!=(p=null!=V?V:y)?p:0;let Y=(0,s.useRef)(C);(0,s.useEffect)(()=>{Y.current=C},[C]);let ee=e=>{var a;let l=Number(e);Number.isFinite(l)&&(null==(a=Y.current)||a.call(Y,Math.max(0,l)))};(0,s.useEffect)(()=>{k?requestAnimationFrame(()=>H(!0)):H(!1)},[k]),(0,s.useEffect)(()=>{if(!k||!g||!b)return;let e=!1;return A((0,v.bH)({mediaId:g,modelType:b,page:1,pageSize:20})).unwrap().then(a=>{var l,t;e||ee(null==a||null==(t=a.response)||null==(l=t.data)?void 0:l.count)}).catch(()=>{}),()=>{e=!0,A((0,v.gy)()),I(""),T(null),E(null),W(null)}},[k,g,b,A]),(0,s.useEffect)(()=>{k&&setTimeout(()=>{var e;return null==(e=w.current)?void 0:e.focus()},350)},[k]);let ea=(0,s.useRef)(N);(0,s.useEffect)(()=>{ea.current=N},[N]),(0,s.useEffect)(()=>{if(!k)return;let e=e=>"Escape"===e.key&&ea.current();return document.addEventListener("keydown",e),()=>document.removeEventListener("keydown",e)},[k]);let el=async e=>{var a;null==e||e.preventDefault();let l=B.trim();if(!l||Q)return;W(null);let t=$.current,s=await A((0,v.pX)({mediaId:g,modelType:b,text:l,parentId:null==S?void 0:S.comment_id}));if(!v.pX.fulfilled.match(s))return void W("Couldn't post your comment. Please try again.");(0,u.u4)("comment_added",{media_id:g,model_type:b}),ee(t+ +!S),T(null),I(""),S||null==(a=L.current)||a.scrollTo({top:0,behavior:"smooth"})},et=e=>{R(e)},es=async()=>{(0,u.u4)("comment_deleted",{media_id:g,model_type:b,comment_id:z}),R(null),E(z),W(null);let e=$.current,a=await A((0,v.LR)({commentId:z}));if(E(null),!v.LR.fulfilled.match(a))return void W("Couldn't delete that comment. Please try again.");ee(e-!!U.some(e=>e.comment_id===z)),(null==S?void 0:S.comment_id)===z&&T(null)};if(!k||!K)return null;let ei=null!=V?V:y,en=(null==G?void 0:G.avatarImage)||"",ed=[null==G?void 0:G.firstName,null==G?void 0:G.lastName].filter(Boolean).join(" ")||(null==G?void 0:G.handle)||"User";return(0,i.createPortal)((0,t.jsxs)("div",{className:h().overlay,onClick:e=>e.stopPropagation(),children:[(0,t.jsx)("div",{className:"".concat(h().backdrop," ").concat(D?h().backdropVisible:""),onClick:N}),(0,t.jsx)("div",{className:"".concat(h().panel," ").concat(h().panelComments," ").concat(D?h().panelVisible:""),children:(0,t.jsxs)("div",{className:"".concat(h().dialog," ").concat(h().dialogComments),children:[(0,t.jsxs)("div",{className:h().header,children:[(0,t.jsxs)("div",{className:h().headerLeft,children:[(0,t.jsx)(r.A,{size:16,className:h().headerIcon}),(0,t.jsx)("h2",{className:h().headerTitle,children:ei>0?"".concat(ei.toLocaleString()," ").concat(1===ei?"Comment":"Comments"):"Comments"})]}),(0,t.jsx)("button",{onClick:N,className:h().closeBtn,"aria-label":"Close",children:(0,t.jsx)(c.A,{size:18,className:h().closeIcon})})]}),(0,t.jsx)("div",{ref:L,className:"".concat(h().body," ").concat(Z||0!==U.length?"":h().bodyCentered),children:Z?(0,t.jsx)("div",{children:[void 0,void 0,void 0,void 0,void 0].map((e,a)=>(0,t.jsx)(x,{},a))}):0===U.length?(0,t.jsxs)("div",{className:h().empty,children:[(0,t.jsx)("div",{className:h().emptyIcon,children:(0,t.jsx)(r.A,{size:28,className:h().mutedIcon})}),(0,t.jsx)("p",{className:h().emptyTitle,children:"No comments yet"}),(0,t.jsx)("p",{className:h().emptyDesc,children:"Start the conversation!"})]}):(0,t.jsxs)("div",{children:[U.map(e=>(0,t.jsx)(j,{comment:e,currentUserId:O,onDelete:et,deletingId:M,onReply:Q?null:e=>{var a;T(e),null==(a=w.current)||a.focus()},isDeleting:q&&M===e.comment_id},e.comment_id)),F&&(0,t.jsx)("div",{className:h().loadMoreWrap,children:(0,t.jsx)("button",{onClick:()=>{F&&!J&&((0,u.u4)("social_comments_load_more_clicked",{media_id:g,model_type:b,page:X+1}),A((0,v.bH)({mediaId:g,modelType:b,page:X+1,pageSize:20,isLoadMore:!0})))},disabled:J,className:h().loadMoreBtn,children:J?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d.A,{size:13,className:h().spin}),"Loading…"]}):"Load more comments"})})]})}),z&&(0,t.jsxs)("div",{className:h().confirmBar,children:[(0,t.jsx)("p",{className:h().confirmText,children:"Delete this comment?"}),(0,t.jsxs)("div",{className:h().confirmActions,children:[(0,t.jsx)("button",{onClick:()=>{R(null)},className:"".concat(h().btn," ").concat(h().btnSecondary),children:"Cancel"}),(0,t.jsx)("button",{onClick:es,className:"".concat(h().btn," ").concat(h().btnDanger),children:"Delete"})]})]}),P&&(0,t.jsx)("p",{className:h().actionError,role:"alert",children:P}),S&&(0,t.jsxs)("div",{className:h().confirmBar,children:[(0,t.jsxs)("p",{className:h().confirmText,children:["Replying to ",(null==(a=S.user)?void 0:a.user_display_name)||[null==(l=S.user)?void 0:l.user_first_name,null==(o=S.user)?void 0:o.user_second_name].filter(
1Boolean).join(" ")||"User"]}),(0,t.jsx)("button",{type:"button",className:h().closeBtn,"aria-label":"Cancel reply",disabled:Q,onClick:()=>T(null),children:(0,t.jsx)(c.A,{size:16})})]}),(0,t.jsxs)("form",{onSubmit:el,className:h().inputRow,children:[O&&(0,t.jsx)(f,{src:en,name:ed,size:32}),(0,t.jsx)("div",{className:h().inputWrap,children:(0,t.jsx)("input",{ref:w,type:"text",value:B,onChange:e=>{I(e.target.value),P&&W(null)},onKeyDown:e=>{"Enter"!==e.key||e.shiftKey||(e.preventDefault(),el())},placeholder:S?"Write a reply…":"Add a comment…",className:h().input,maxLength:500,disabled:Q})}),(0,t.jsx)("button",{type:"submit",disabled:!B.trim()||Q,className:h().sendBtn,"aria-label":"Post comment",children:Q?(0,t.jsx)(d.A,{size:16,className:h().spin}):(0,t.jsx)(m.A,{size:16,className:h().sendIcon})})]})]})})]}),K)}},99667:(e,a,l)=>{"use strict";l.d(a,{A:()=>d,I:()=>n});var t=l(95155),s=l(12115),i=l(15239);function n(e){let a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,l=String(e||"").trim().split(/\s+/).filter(Boolean);return l.length?l.map(e=>e[0]).join("").toUpperCase().slice(0,a):""}function d(e){let{src:a,alt:l,sizes:n,className:d,fallback:o=null}=e,[r,c]=(0,s.useState)(!1);return((0,s.useEffect)(()=>{c(!1)},[a]),!a||r)?o:(0,t.jsx)(i.default,{src:a,alt:l||"User",fill:!0,sizes:n,className:d,unoptimized:!0,onError:()=>c(!0)})}}}]);

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.