1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="89b537a8-2ec1-400c-a4a7-4b922bff1eb9",e._sentryDebugIdIdentifier="sentry-dbid-89b537a8-2ec1-400c-a4a7-4b922bff1eb9")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1662],{28022:(e,t,s)=>{"use strict";s.d(t,{A:()=>i});var r=s(14232);let i=r.forwardRef(function({title:e,titleId:t,...s},i){return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":t},s),e?r.createElement("title",{id:t},e):null,r.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m14.74 9-.346 9m-4.788 0L9.26 9m9.968-3.21c.342.052.682.107 1.022.166m-1.022-.165L18.16 19.673a2.25 2.25 0 0 1-2.244 2.077H8.084a2.25 2.25 0 0 1-2.244-2.077L4.772 5.79m14.456 0a48.108 48.108 0 0 0-3.478-.397m-12 .562c.34-.059.68-.114 1.022-.165m0 0a48.11 48.11 0 0 1 3.478-.397m7.5 0v-.916c0-1.18-.91-2.164-2.09-2.201a51.964 51.964 0 0 0-3.32 0c-1.18.037-2.09 1.022-2.09 2.201v.916m7.5 0a48.667 48.667 0 0 0-7.5 0"}))})},33612:(e,t,s)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/story/create",function(){return s(54123)}])},40097:(e,t,s)=>{"use strict";s.d(t,{n:()=>c});var r=s(14232),i=s(21407),a=s(60388),n=s(90089),o=s(37149),l=class extends n.Q{#e;#t=void 0;#s;#r;constructor(e,t){super(),this.#e=e,this.setOptions(t),this.bindMethods(),this.#i()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){let t=this.options;this.options=this.#e.defaultMutationOptions(e),(0,o.f8)(this.options,t)||this.#e.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#s,observer:this}),t?.mutationKey&&this.options.mutationKey&&(0,o.EN)(t.mutationKey)!==(0,o.EN)(this.options.mutationKey)?this.reset():this.#s?.state.status==="pending"&&this.#s.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#s?.removeObserver(this)}onMutationUpdate(e){this.#i(),this.#a(e)}getCurrentResult(){return this.#t}reset(){this.#s?.removeObserver(this),this.#s=void 0,this.#i(),this.#a()}mutate(e,t){return this.#r=t,this.#s?.removeObserver(this),this.#s=this.#e.getMutationCache().build(this.#e,this.options),this.#s.addObserver(this),this.#s.execute(e)}#i(){let e=this.#s?.state??(0,i.$)();this.#t={...e,isPending:"pending"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset}}#a(e){a.jG.batch(()=>{if(this.#r&&this.hasListeners()){let t=this.#t.variables,s=this.#t.context,r={client:this.#e,meta:this.options.meta,mutationKey:this.options.mutationKey};if(e?.type==="success"){try{this.#r.onSuccess?.(e.data,t,s,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(e.data,null,t,s,r)}catch(e){Promise.reject(e)}}else if(e?.type==="error"){try{this.#r.onError?.(e.error,t,s,r)}catch(e){Promise.reject(e)}try{this.#r.onSettled?.(void 0,e.error,t,s,r)}catch(e){Promise.reject(e)}}}this.listeners.forEach(e=>{e(this.#t)})})}},u=s(67768);function c(e,t){let s=(0,u.jE)(t),[i]=r.useState(()=>new l(s,e));r.useEffect(()=>{i.setOptions(e)},[i,e]);let n=r.useSyncExternalStore(r.useCallback(e=>i.subscribe(a.jG.batchCalls(e)),[i]),()=>i.getCurrentResult(),()=>i.getCurrentResult()),c=r.useCallback((e,t)=>{i.mutate(e,t).catch(o.lQ)},[i]);if(n.error&&(0,o.GU)(i.options.throwOnError,[n.error]))throw n.error;return{...n,mutate:c,mutateAsync:n.mutate}}},44542:(e,t,s)=>{"use strict";s.d(t,{fH:()=>a,vV:()=>n});let r=console;function i(e,t,s){if("error"!==e&&"warn"!==e)return;let i=`[WuubiWeb][${e}] ${t}`;return"error"===e?void r?.error?.(i,s):"warn"===e?void r?.warn?.(i,s):"debug"===e?void r?.debug?.(i,s):void r?.info?.(i,s)}function a(e,t){i("info",e,t)}function n(e,t){i("error",e,t)}},54123:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>b});var r=s(37876),i=s(24178),a=s(82437),n=s(71734),o=s(44948),l=s(73873),u=s(78464),c=s(89099),d=s(14232),h=s(97685),m=s(92963);let f=["image/png","image/jpeg","image/jpg","image/webp","video/mp4","video/webm"],p=()=>{let e=(0,c.useRouter)(),t=(0,m.A)(),[s,i]=(0,d.useState)(null),[p,b]=(0,d.useState)(null),[y,g]=(0,d.useState)(""),[x,v]=(0,d.useState)(!1),[w,k]=(0,d.useState)(""),j=(0,d.useRef)(null),{mutateAsync:N,isPending:M}=(0,o.nd)();if(!t)return e.push("/sign-in"),null;let R=async()=>
1{if(!s)return void h.Ay.error("L\xfctfen bir medya dosyası se\xe7in");try{await N({file:s,caption:y.trim()||void 0,duration:86400}),e.push("/story/my")}catch{}};return(0,r.jsxs)("div",{className:"mx-auto max-w-lg px-4 py-8",children:[(0,r.jsxs)("div",{className:"mb-6 flex items-center gap-3",children:[(0,r.jsx)("button",{type:"button",onClick:()=>e.back(),className:"flex h-9 w-9 items-center justify-center rounded-xl border border-border-soft bg-white shadow-sm hover:bg-slate-50",children:(0,r.jsx)(u.A,{className:"h-4 w-4 text-dark/70"})}),(0,r.jsxs)("div",{children:[(0,r.jsx)("h1",{className:"text-2xl font-semibold text-dark",children:"Yeni Hikaye"}),(0,r.jsx)("p",{className:"text-sm text-dark/60",children:"24 saat boyunca g\xf6r\xfcn\xfcr kalacak"})]})]}),(0,r.jsxs)("div",{className:"rounded-[28px] border border-border-soft bg-[linear-gradient(180deg,#ffffff_0%,#f8fafc_100%)] p-6 shadow-sm",children:[s?(0,r.jsx)("div",{className:"mx-auto w-full",children:(0,r.jsx)(n.A,{file:s,preview:p||"",onReplace:()=>j.current?.click(),onRemove:()=>{i(null),b(null),j.current&&(j.current.value="")}})}):(0,r.jsxs)("div",{className:"cursor-pointer rounded-[24px] border-2 border-dashed border-border-soft bg-[linear-gradient(180deg,#f8fafc_0%,#ffffff_100%)] p-10 text-center transition-colors hover:border-secondary",onClick:()=>j.current?.click(),children:[(0,r.jsx)("div",{className:"mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-2xl border border-slate-200 bg-white shadow-sm",children:(0,r.jsx)(l.A,{className:"h-8 w-8 text-dark/35"})}),(0,r.jsxs)("p",{className:"text-base font-semibold text-dark/75",children:[(0,r.jsx)("span",{className:"text-secondary",children:"Dosya se\xe7"})," veya s\xfcr\xfckle bırak"]}),(0,r.jsx)("p",{className:"mt-2 text-sm text-dark/45",children:"PNG, JPG, MP4 (max 10MB)"})]}),(0,r.jsx)("input",{type:"file",ref:j,accept:"image/png,image/jpeg,image/jpg,image/webp,video/mp4,video/webm",className:"hidden",onChange:e=>{let t=e.target.files?.[0];if(t){if(!f.includes(t.type.toLowerCase()))return void h.Ay.error("Sadece PNG, JPG, MP4 veya WebM dosyaları y\xfcklenebilir");if(t.size>0xa00000)return void h.Ay.error("Dosya boyutu 10MB'dan k\xfc\xe7\xfck olmalıdır");if(t.type.startsWith("image/")){let e=new FileReader;e.onload=e=>{k(e.target?.result),v(!0)},e.readAsDataURL(t)}else{i(t);let e=new FileReader;e.onload=e=>b(e.target?.result),e.readAsDataURL(t)}}}}),s&&(0,r.jsx)("button",{type:"button",onClick:()=>j.current?.click(),className:"mt-3 w-full text-center text-sm text-secondary hover:underline",children:"Farklı dosya se\xe7"}),(0,r.jsxs)("div",{className:"mt-5",children:[(0,r.jsx)("textarea",{value:y,onChange:e=>g(e.target.value),placeholder:"Hikaye a\xe7ıklaması ekle (opsiyonel)",maxLength:200,rows:3,className:"input w-full resize-none"}),(0,r.jsxs)("p",{className:"mt-1 text-right text-xs text-dark/40",children:[y.length,"/200"]})]}),(0,r.jsxs)("div",{className:"mt-5 flex gap-3",children:[(0,r.jsx)("button",{type:"button",onClick:()=>e.back(),className:"btn btn-ghost flex-1",children:"İptal"}),(0,r.jsx)("button",{type:"button",onClick:R,disabled:!s||M,className:"btn btn-primary flex-1 disabled:opacity-50",children:M?"PaylaÅılıyor...":"Hikayeyi PaylaÅ"})]})]}),(0,r.jsx)(a.A,{isOpen:x,imageSrc:w,title:"Hikayeyi kırp (9:16)",aspect:9/16,onClose:()=>{v(!1),k(""),j.current&&(j.current.value="")},onApply:e=>{let[t,s]=e.split(","),r=t.match(/data:(.*?);base64/)?.[1]||"image/jpeg",a=atob(s),n=new Uint8Array(a.length);for(let e=0;e<a.length;e++)n[e]=a.charCodeAt(e);i(new File([n],`story-${Date.now()}.jpg`,{type:r})),b(e),v(!1),k("")}})]})},b=p;p.getLayout=e=>(0,r.jsx)(i.A,{children:e})},73873:(e,t,s)=>{"use strict";s.d(t,{A:()=>i});var r=s(14232);let i=r.forwardRef(function({title:e,titleId:t,...s},i){return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":t},s),e?r.createElement("title",{id:t},e):null,r.createElement("path",{fillRule:"evenodd",d:"M1 5.25A2.25 2.25 0 0 1 3.25 3h13.5A2.25 2.25 0 0 1 19 5.25v9.5A2.25 2.25 0 0 1 16.75 17H3.25A2.25 2.25 0 0 1 1 14.75v-9.5Zm1.5 5.81v3.69c0 .414.336.75.75.75h13.5a.75.75 0 0 0 .75-.75v-2.69l-2.22-2.219a.75.75 0 0 0-1.06 0l-1.91 1.909.47.47a.75.75 0 1 1-1.06 1.06L6.53 8.091a.75.75 0 0 0-1.06 0l-2.97 2.97ZM12 7a1 1 0 1 1-2 0 1 1 0 0 1 2 0Z",clipRule:"evenodd"}))})},74359:(e,t,s)=>{"use strict";s.d(t,{I:()=>a});var r=s(13478),i=s(23836);function a(e,t){return(0,i.t)(e,r.$,t)}},78464:(e,t,s)=>{"use strict";s.d(t,{A:()=>i});var r=s(14232);let i=r.forwardRef(function({title:e,titleId:t,...s},i){return r.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:i,"aria-labelledby":t},s),e?r.createElement("title",{id:t},e):null,r.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M10.5 19.5 3 12m0 0 7.5-7.5M3 12h18"}))})}},e=>{e.O(0,[4938,152,975,6978,2615,4178,1811,636,6593,8792],()=>e(e.s=33612)),_N_E=e.O()}]);
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.