1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[45063],{1926:(e,t,r)=>{"use strict";r.d(t,{d:()=>a});var n=r(12115),o=r(46397),i=r(73894);function a(){let{settings:e}=(0,o.Kq)();return(0,n.useMemo)(()=>({...(0,i.e5)(e),"--theme-primary":e.primaryColor,"--theme-secondary":e.secondaryColor,"--theme-accent":e.accentColor,"--theme-surface":e.surfaceColor}),[e])}},14367:(e,t,r)=>{"use strict";async function n(e){let t=String(e.headers.get("content-type")||"").toLowerCase(),r=(await e.text()).trim();if(t.includes("text/html")||r.startsWith("<!DOCTYPE")||r.startsWith("<html"))throw Error("İstek Cloudflare g\xfcvenlik kontrol\xfcne takıldı. Admin â Cloudflare â \xabYorum / iletiÅim spam\xbbı Pasif yapın (Turnstile zaten koruyor).");if(!r)throw Error("Sunucu boÅ yanıt d\xf6nd\xfc. L\xfctfen tekrar deneyin.");try{return JSON.parse(r)}catch{throw Error("Sunucu JSON yerine beklenmeyen yanıt d\xf6nd\xfc. Sayfayı yenileyip tekrar deneyin.")}}r.d(t,{Y:()=>n})},20708:(e,t,r)=>{"use strict";r.d(t,{c:()=>i});var n=r(12115),o=r(43889);function i(){let e=(0,o.e)(),[t,r]=(0,n.useState)(e);return(0,n.useEffect)(()=>{let e=!1;return fetch("/api/public/turnstile",{cache:"no-store"}).then(e=>e.json()).then(t=>{if(e)return;let n=String(t?.siteKey||"").trim();n&&r(n)}).catch(()=>{}),()=>{e=!0}},[e]),t}},38386:e=>{e.exports={form:"HybridCommentForm_form__gE52S",honeypot:"HybridCommentForm_honeypot__da_jG",header:"HybridCommentForm_header__qoqyQ",modeHeader:"HybridCommentForm_modeHeader__rAwFt",modeLabel:"HybridCommentForm_modeLabel__yGJ_S",securityTitle:"HybridCommentForm_securityTitle__GZJvM",modeToggle:"HybridCommentForm_modeToggle__0rAR7",modeButton:"HybridCommentForm_modeButton__cFh0d",modeButtonPrimary:"HybridCommentForm_modeButtonPrimary__z9IEF",modeButtonGuest:"HybridCommentForm_modeButtonGuest__ifGYy",smallIcon:"HybridCommentForm_smallIcon__mIuly",memberMode:"HybridCommentForm_memberMode___xNJ8",primaryText:"HybridCommentForm_primaryText__wKQCn",body:"HybridCommentForm_body__GMFJd",statusText:"HybridCommentForm_statusText__4Wo1r",loginPrompt:"HybridCommentForm_loginPrompt__r7U4X",loginTitle:"HybridCommentForm_loginTitle__YolzQ",loginText:"HybridCommentForm_loginText__0Jygs",loginActions:"HybridCommentForm_loginActions__JyJTI",loginButton:"HybridCommentForm_loginButton__rOBBJ",loginButtonSecondary:"HybridCommentForm_loginButtonSecondary__EINgf",memberProfile:"HybridCommentForm_memberProfile__8oXGf",memberAvatar:"HybridCommentForm_memberAvatar__vZuqW",memberCopy:"HybridCommentForm_memberCopy__xmcsI",memberName:"HybridCommentForm_memberName__tb2OV",memberEmail:"HybridCommentForm_memberEmail__wwgGS",guestGrid:"HybridCommentForm_guestGrid__vn_M5",input:"HybridCommentForm_input__0Auo3",textarea:"HybridCommentForm_textarea__grh0F",replyBox:"HybridCommentForm_replyBox__VS8ND",replyCancel:"HybridCommentForm_replyCancel__01oIC",securityBox:"HybridCommentForm_securityBox__7alev",securityHint:"HybridCommentForm_securityHint__A__2Z",submitRow:"HybridCommentForm_submitRow__V6uzz",submitButton:"HybridCommentForm_submitButton__kmdnt",moderationHint:"HybridCommentForm_moderationHint__AzoZT",hintIcon:"HybridCommentForm_hintIcon__ZUitD",notice:"HybridCommentForm_notice__Sv_dh",error:"HybridCommentForm_error__Iikbg"}},43889:(e,t,r)=>{"use strict";r.d(t,{$:()=>l,e:()=>m});var n=r(95155),o=r(12115),i=r(50407),a=r.n(i),s=r(41463);function l({siteKey:e,onToken:t}){let r=(0,o.useRef)(null),i=(0,o.useRef)(null),s=(0,o.useRef)(t),[m,c]=(0,o.useState)("");return((0,o.useEffect)(()=>{s.current=t},[t]),(0,o.useEffect)(()=>{if(!e)return;let t=!1,n=0,o=()=>{let e=i.current;if(i.current=null,e&&window.turnstile?.remove)try{window.turnstile.remove(e)}catch{}r.current&&(r.current.innerHTML="")};return(async()=>{let a=++n;c("");try{await function(){if(window.turnstile)return Promise.resolve();let e=document.querySelector('script[data-turnstile="1"]');return new Promise(e?(t,r)=>{window.turnstile?t():(e.addEventListener("load",()=>t(),{once:!0}),e.addEventListener("error",()=>r(Error("Turnstile script load failed")),{once:!0}))}:(e,t)=>{let r=document.createElement("script");r.src="https://challenges.cloudflare.com/turnstile/v0/api.js?render=explicit",r.async=!0,r.dataset.turnstile="1",r.onload=()=>e(),r.onerror=()=>t(Error("Turnstile script load failed")),document.head.appendChild(r)})}()}catch{t||c("DoÄrulama scriptâi y\xfcklenemedi. Sayfayı yenileyin.");return}if(!t&&a===n&&r.current&&window.turnstile&&(o(),!t&&r.current&&window.turnstile))try{i.current=window.turnstile.render(r.current,{sitekey:e,action:"turnstile-spin-v2",callback:e=>s.current(e),"expired-callback":()=>{s.current("");try{i.current&&window.turnstile?.reset(i.current)}catch{}},"error-callback":()=>{s.current("");let e=window.location.hostname;c(e?`DoÄrulama y\xfcklenemedi. Cloudflare Turnstile widget Hostnames listesine \xab${e}\xbb ekleyin; sonra sayfayı yenileyin.`:"DoÄrulama y\xfcklenemedi. Turnstile widget Hostnames listesine bu sitenin adresini ekleyin.")},theme:"auto",size:"flexible"})}catch{t||c("DoÄrulama baÅlatılamadı. Sayfayı yenileyin.")}})(),()=>{t=!0,n+=1,o()}},[e]),e)?(0,n.jsxs)("div",{className:a().wrapper,children:[(0,n.jsx)("div",{ref:r,className:a().host}),m?(0,n.jsx)("p",{className:a().error,children:m}):null]}):null}function m(){return String(s.env.NEXT_PUBLIC_TURNSTILE_SITE_KEY||"").trim()}},45063:(e,t,r)=>{"use strict";r.r(t),r.d(t,{GlobalCommentsSection:()=>F});var n=r(95155),o=r(12115),i=r(54757),a=r(45165),s=r(24551),l=r(59103),m=r(98500),c=r.n(m),d=r(73321),u=r(96339),y=r(21143),_=r(88359),h=r(9383),b=r(50981),p=r(89239),x=r(60529),C=r(43889),g=r(20708),f=r(38386),N=r.n(f);function j({profileReady:e,isMember:t,memberName:r="",memberEmail:i="",authorName:a,authorEmail:s,content:l,replyTarget:m,submitting:f,pendingNotice:k,error:S,themeStyle:v,onAuthorNameChange:w,onAuthorEmailChange:H,onContentChange:B,onCancelReply:T,onSubmit:F,honeypot:I="",onHoneypotChange:G,turnstileToken:E="",onTurnstileToken:A}){let z=(0,d.usePathname)(),[$,Y]=(0,o.useState)("guest"),R=(0,g.c)(),M=(0,o.useMemo)(()=>{let e=`${z||"/"}#comments`;return`/giris?next=${encodeURIComponent(e)}`},[z]),L=t?"member":$,P=t?(0,n.jsxs)(n.Fragment,{children:["Profiliniz \xfczerinden moderasyon takibi yapabilirsiniz."," ",(0,n.jsx)(c(),{href:"/profil?tab=comments",children:"Yorumlarım"})]}):"Misafir yorumları moderasyon sonrası yayınlanır.";return(0,n.jsxs)("form",{onSubmit:F,className:N().form,style:v,children:[(0,n.jsx)("div",{"aria-hidden":"true",className:N().honeypot,children:(0,n.jsxs)("label",{children:["Website",(0,n.jsx)("input",{tabIndex:-1,autoComplete:"off",value:I,onChange:e=>G?.(e.target.value)})]})}),(0,n.jsx)("div",{className:N().header,children:t?(0,n.jsxs)("div",{className:N().memberMode,children:[(0,n.jsx)(_.A,{className:`${N().smallIcon} ${N().primaryText}`}),"\xdcye Olarak Yorum Yapıyorsunuz:"," ",(0,n.jsx)("span",{className:N().primaryText,children:r})]}):(0,n.jsxs)("div",{className:N().modeHeader,children:[(0,n.jsx)("p",{className:N().modeLabel,children:"Yorum modu"}),(0,n.jsxs)("div",{className:N().modeToggle,children:[(0,n.jsxs)("button",{type:"button",onClick:()=>Y("member"),className:`${N().modeButton} ${"member"===L?N().modeButtonPrimary:""}`,"aria-pressed":"member"===L,children:[(0,n.jsx)(u.A,{className:N().smallIcon}),"\xdcye giriÅi yaparak yorum yapın"]}),(0,n.jsxs)("button",{type:"button",onClick:()=>Y("guest"),className:`${N().modeButton} ${"guest"===L?N().modeButtonGuest:""}`,"aria-pressed":"guest"===L,children:[(0,n.jsx)(y.A,{className:N().smallIcon}),"Misafir olarak devam edin"]})]})]})}),(0,n.jsxs)("div",{className:N().body,children:[e?null:(0,n.jsx)("p",{className:N().statusText,children:"Oturum durumu kontrol ediliyor..."}),"member"!==L||t?null:(0,n.jsxs)("div",{className:N().loginPrompt,children:[(0,n.jsx)("p",{className:N().loginTitle,children:"\xdcye hesabınızla yorum yapın"}),(0,n.jsx)("p",{className:N().loginText,children:"Yorumlarınız profilinize baÄlanır ve moderasyon s\xfcrecini takip edebilirsiniz."}),(0,n.jsxs)("div",{className:N().loginActions,children:[(0,n.jsx)(p.$,{asChild:!0,size:"sm",className:N().loginButton,children:(0,n.jsx)(c(),{href:M,children:"GiriÅ Yap"})}),(0,n.jsx)(p.$,{asChild:!0,size:"sm",variant:"secondary",className:`${N().loginButton} ${N().loginButtonSecondary}`,children:(0,n.jsx)(c(),{href:"/kayit",children:"Kayıt Ol"})})]})]}),t?(0,n.jsxs)("div",{className:N().memberProfile,children:[(0,n.jsx)("div",{className:N().memberAvatar,children:r.slice(0,1).toUpperCase()}),(0,n.jsxs)("div",{className:N().memberCopy,children:[(0,n.jsx)("p",{className:N().memberName,children:r}),(0,n.jsx)("p",{className:N().memberEmail,children:i})]})]}):null,"guest"!==L||t?null:(0,n.jsxs)("div",{className:N().guestGrid,children:[(0,n.jsx)(x.p,{value:a,onChange:e=>w(e.target.value),placeholder:"Adınız *",required:!0,className:N().input}),(0,n.jsx)(x.p,{value:s,onChange:e=>H(e.target.value),placeholder:"E-posta *",type:"email",required:!0,className:N().input})]}),t||"guest"===L?(0,n.jsxs)(n.Fragment,{children:[m?(0,n.jsxs)("div",{className:N().replyBox,children:[(0,n.jsxs)("span",{children:[(0,n.jsx)("strong",{children:m.authorName})," yorumuna yanıt yazıyorsunuz"]}),(0,n.jsx)("button",{type:"button",className:N().replyCancel,onClick:T,children:"İptal"})]}
1):null,(0,n.jsx)("textarea",{value:l,onChange:e=>B(e.target.value),placeholder:"Yorumunuzu yazın...",rows:4,required:!0,className:N().textarea}),R&&A?(0,n.jsxs)("div",{className:N().securityBox,children:[(0,n.jsx)("p",{className:N().securityTitle,children:"G\xfcvenlik doÄrulaması"}),(0,n.jsx)(C.$,{siteKey:R,onToken:A}),E?null:(0,n.jsx)("p",{className:N().securityHint,children:"DoÄrulama tamamlanınca yorum g\xf6nderebilirsiniz."})]}):null,(0,n.jsxs)("div",{className:N().submitRow,children:[(0,n.jsxs)(p.$,{type:"submit",disabled:f||!!R&&!E,className:N().submitButton,children:[(0,n.jsx)(h.A,{className:N().smallIcon}),f?"G\xf6nderiliyor...":m?"Yanıt G\xf6nder":"Yorum G\xf6nder"]}),(0,n.jsxs)("span",{className:N().moderationHint,children:[(0,n.jsx)(b.A,{className:N().hintIcon}),P]})]})]}):null,k?(0,n.jsx)("p",{className:N().notice,children:k}):null,S?(0,n.jsx)("p",{className:N().error,children:S}):null]})]})}var k=r(1926);let S="haber_guest_comment_profile";var v=r(14367),w=r(59079),H=r.n(w);function B({comment:e,onReply:t,onLike:r,themeStyle:o,depth:s=0}){return(0,n.jsxs)("article",{className:`${H().commentCard} ${s>0?H().replyCard:""}`,style:o,children:[(0,n.jsxs)("div",{className:H().commentHeader,children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("strong",{className:H().authorName,children:e.authorName}),(0,n.jsx)("p",{className:H().commentDate,children:function(e){if(!e)return"Az \xf6nce";let t=new Date(e);return Number.isNaN(t.getTime())?e:t.toLocaleString("tr-TR",{day:"2-digit",month:"short",year:"numeric",hour:"2-digit",minute:"2-digit"})}(e.createdAt)})]}),(0,n.jsxs)("button",{type:"button",onClick:()=>r(e.id),className:`${H().likeButton} ${e.likedByVisitor?H().likeButtonActive:""}`,"aria-label":`${e.authorName} yorumunu beÄen`,"aria-pressed":e.likedByVisitor,children:[(0,n.jsx)(i.A,{className:`${H().likeIcon} ${e.likedByVisitor?H().likeIconActive:""}`}),e.likesCount]})]}),(0,n.jsx)("p",{className:H().commentBody,children:e.content}),0===s?(0,n.jsxs)("button",{type:"button",onClick:()=>t(e),className:H().replyButton,children:[(0,n.jsx)(a.A,{className:H().replyIcon}),"Yanıtla"]}):null,e.replies.length>0?(0,n.jsx)("div",{className:H().replies,children:e.replies.map(e=>(0,n.jsx)(B,{comment:e,onReply:t,onLike:r,themeStyle:o,depth:s+1},e.id))}):null]})}let T=(0,o.forwardRef)(function({entityType:e,entityKey:t,newsId:r=null,title:i="Yorumlar",subtitle:a="Yorum yazabilir, yazılan yorumlara yanıt verebilirsiniz.",className:m},c){let d=(0,k.d)(),u=(0,o.useRef)(null),{ready:y,isMember:_,member:h,guestProfile:b,rememberGuestProfile:p}=function(){let[e,t]=(0,o.useState)(null),[r,n]=(0,o.useState)({name:"",email:""}),[i,a]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{let e=!0;try{let e=window.localStorage.getItem(S);if(e){let t=JSON.parse(e);n({name:String(t.name||""),email:String(t.email||"")})}}catch{}return fetch("/api/public/member-session",{cache:"no-store",credentials:"include"}).then(e=>e.json()).then(r=>{e&&r?.ok&&r?.member&&t({id:String(r.member.id||""),name:String(r.member.name||`${r.member.firstName||""} ${r.member.lastName||""}`.trim()),email:String(r.member.email||""),avatar:r.member.avatar?String(r.member.avatar):void 0})}).catch(()=>{e&&t(null)}).finally(()=>{e&&a(!0)}),()=>{e=!1}},[]),{ready:i,isMember:!!e,member:e,guestProfile:r,rememberGuestProfile:function(e,t){let r={name:e,email:t};n(r),window.localStorage.setItem(S,JSON.stringify(r))}}}(),[x,C]=(0,o.useState)([]),[g,f]=(0,o.useState)(!0),[N,w]=(0,o.useState)(!1),[T,F]=(0,o.useState)(""),[I]=(0,o.useState)(()=>Date.now()),[G,E]=(0,o.useState)(""),[A,z]=(0,o.useState)(""),[$,Y]=(0,o.useState)(0),[R,M]=(0,o.useState)(""),[L,P]=(0,o.useState)(""),[D,O]=(0,o.useState)(""),[J,V]=(0,o.useState)(null),[U,W]=(0,o.useState)(""),q=(0,o.useMemo)(()=>`entityType=${encodeURIComponent(e)}&entityKey=${encodeURIComponent(t)}`,[t,e]),K=(0,o.useCallback)(async()=>{f(!0),F("");try{let e=await fetch(`/api/public/comments?${q}`,{cache:"no-store"}),t=await e.json();if(!e.ok||!t?.ok)throw Error(t?.message||"Yorumlar y\xfcklenemedi.");C(Array.isArray(t.items)?t.items:[])}catch(e){F(e instanceof Error?e.message:"Yorumlar y\xfcklenemedi."),C([])}finally{f(!1)}},[q]);async function Q(n){n.preventDefault(),w(!0),F(""),W("");try{let n=_?h?.name||"":R.trim(),o=_?h?.email||"":L.trim();if(!_&&(!n||!o))throw Error("Misafir yorumları i\xe7in ad ve e-posta zorunludur.");let i=await fetch("/api/public/comments",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({entityType:e,entityKey:t,newsId:r,parentId:J?.id??null,authorName:n,authorEmail:o,content:D,isMember:_,website:G,_formOpenedAt:I,turnstileToken:A||void 0})}),a=await (0,v.Y)(i);if(!i.ok||!a?.ok)throw Error(a?.message||"Yorum g\xf6nderilemedi.");_||p(n,o),O(""),V(null),z(""),Y(e=>e+1),W("pending"===a.status?`Onay bekliyor. ${a.message||""}`:a.message||"Yorumunuz g\xf6nderildi."),await K()}catch(e){F(e instanceof Error?e.message:"Yorum g\xf6nderilemedi."),z(""),Y(e=>e+1)}finally{w(!1)}}async function X(e){try{let t=await fetch("/api/public/comments/like",{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({commentId:e})}),r=await t.json();if(!t.ok||!r?.ok)return;C(t=>t.map(function(t){return t.id===e?{...t,likedByVisitor:!!r.liked,likesCount:Number(r.likesCount??t.likesCount)}:{...t,replies:t.replies.map(t=>
1t.id===e?{...t,likedByVisitor:!!r.liked,likesCount:Number(r.likesCount??t.likesCount)}:t)}}))}catch{}}return(0,o.useEffect)(()=>{y&&!_&&(M(b.name),P(b.email))},[b.email,b.name,_,y]),(0,o.useEffect)(()=>{K()},[K]),(0,o.useImperativeHandle)(c,()=>({scrollIntoView(){u.current?.scrollIntoView({behavior:"smooth",block:"start"})}})),(0,n.jsxs)("section",{ref:u,id:"comments","data-entity-key":t,className:`${H().section} ${m||""}`,style:d,children:[(0,n.jsxs)("div",{className:H().headingRow,children:[(0,n.jsx)("div",{className:H().headingMarker,"aria-hidden":"true"}),(0,n.jsx)(s.A,{className:H().headingIcon,"aria-hidden":"true"}),(0,n.jsxs)("div",{className:H().headingCopy,children:[(0,n.jsx)("h2",{className:H().headingTitle,children:i}),(0,n.jsx)("p",{className:H().subtitle,children:a})]})]}),(0,n.jsx)(j,{profileReady:y,isMember:_,memberName:h?.name,memberEmail:h?.email,authorName:R,authorEmail:L,content:D,replyTarget:J,submitting:N,pendingNotice:U,error:T,themeStyle:d,onAuthorNameChange:M,onAuthorEmailChange:P,onContentChange:O,onCancelReply:()=>V(null),onSubmit:e=>void Q(e),honeypot:G,onHoneypotChange:E,turnstileToken:A,onTurnstileToken:z},`comment-form-${$}`),(0,n.jsx)("div",{className:H().commentsList,children:g?(0,n.jsxs)("div",{className:H().stateBox,children:[(0,n.jsx)(l.A,{className:H().loadingIcon}),"Yorumlar y\xfckleniyor..."]}):0===x.length?(0,n.jsx)("div",{className:H().stateBox,children:"Hen\xfcz yorum yapılmadı. İlk yorumu siz yazın."}):x.map(e=>(0,n.jsx)(B,{comment:e,onReply:V,onLike:X,themeStyle:d},e.id))})]})}),F=(0,o.forwardRef)(function(e,t){return(0,n.jsx)(o.Suspense,{fallback:null,children:(0,n.jsx)(T,{...e,ref:t})})})},50407:e=>{e.exports={wrapper:"TurnstileWidget_wrapper__tmw_E",host:"TurnstileWidget_host__tIwrL",error:"TurnstileWidget_error__QSkFi"}},59079:e=>{e.exports={section:"GlobalCommentsSection_section__BkKdm",headingRow:"GlobalCommentsSection_headingRow__u9sD_",headingMarker:"GlobalCommentsSection_headingMarker__bi0GJ",headingIcon:"GlobalCommentsSection_headingIcon__7jpFv",headingCopy:"GlobalCommentsSection_headingCopy__xBQLz",headingTitle:"GlobalCommentsSection_headingTitle__UHDyE",subtitle:"GlobalCommentsSection_subtitle__6gmQx",commentsList:"GlobalCommentsSection_commentsList__AooD5",replies:"GlobalCommentsSection_replies__ph4ds",commentCard:"GlobalCommentsSection_commentCard__jkLo9",replyCard:"GlobalCommentsSection_replyCard__ha_o2",commentHeader:"GlobalCommentsSection_commentHeader__dHXXt",authorName:"GlobalCommentsSection_authorName__n7qmM",commentDate:"GlobalCommentsSection_commentDate__tnE5j",likeButton:"GlobalCommentsSection_likeButton__2jbDv",replyButton:"GlobalCommentsSection_replyButton__yaY7C",likeButtonActive:"GlobalCommentsSection_likeButtonActive__8GBME",likeIcon:"GlobalCommentsSection_likeIcon__wI8cQ",replyIcon:"GlobalCommentsSection_replyIcon__1cVOB",loadingIcon:"GlobalCommentsSection_loadingIcon__NTYaW",likeIconActive:"GlobalCommentsSection_likeIconActive__0xBJZ",commentBody:"GlobalCommentsSection_commentBody__z_eWr",stateBox:"GlobalCommentsSection_stateBox__X4_vu","comments-pulse":"GlobalCommentsSection_comments-pulse__bBXbU"}},60529:(e,t,r)=>{"use strict";r.d(t,{p:()=>a});var n=r(95155),o=r(12115),i=r(40980);let a=o.forwardRef(({className:e,type:t,...r},o)=>(0,n.jsx)("input",{type:t,className:(0,i.cn)("flex h-11 w-full rounded-2xl border border-slate-200 bg-white px-4 py-2 text-sm text-slate-900 shadow-sm file:border-0 file:bg-transparent file:text-sm file:font-medium placeholder:text-slate-400 focus-visible:outline-none focus-visible:ring-4 focus-visible:ring-red-500/10 disabled:cursor-not-allowed disabled:opacity-50",e),ref:o,...r}));a.displayName="Input"}}]);
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.