Files
2026-05-13 14:20:41 +00:00

1 line
7.7 KiB
JavaScript

(()=>{var e={};e.id=702,e.ids=[702],e.modules={2934:e=>{"use strict";e.exports=require("next/dist/client/components/action-async-storage.external.js")},4580:e=>{"use strict";e.exports=require("next/dist/client/components/request-async-storage.external.js")},5869:e=>{"use strict";e.exports=require("next/dist/client/components/static-generation-async-storage.external.js")},399:e=>{"use strict";e.exports=require("next/dist/compiled/next-server/app-page.runtime.prod.js")},8209:(e,t,r)=>{"use strict";r.r(t),r.d(t,{GlobalError:()=>a.a,__next_app__:()=>u,originalPathname:()=>p,pages:()=>c,routeModule:()=>x,tree:()=>l}),r(9521),r(1506),r(5866);var n=r(3191),i=r(8716),o=r(7922),a=r.n(o),s=r(5231),d={};for(let e in s)0>["default","tree","pages","GlobalError","originalPathname","__next_app__","routeModule"].indexOf(e)&&(d[e]=()=>s[e]);r.d(t,d);let l=["",{children:["dashboard",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(r.bind(r,9521)),"/opt/uno-click/site/app/dashboard/page.tsx"]}]},{}]},{layout:[()=>Promise.resolve().then(r.bind(r,1506)),"/opt/uno-click/site/app/layout.tsx"],"not-found":[()=>Promise.resolve().then(r.t.bind(r,5866,23)),"next/dist/client/components/not-found-error"]}],c=["/opt/uno-click/site/app/dashboard/page.tsx"],p="/dashboard/page",u={require:r,loadChunk:()=>Promise.resolve()},x=new n.AppPageRouteModule({definition:{kind:i.x.APP_PAGE,page:"/dashboard/page",pathname:"/dashboard",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:l}})},9264:(e,t,r)=>{Promise.resolve().then(r.bind(r,7581))},4199:()=>{},9682:(e,t,r)=>{Promise.resolve().then(r.t.bind(r,2994,23)),Promise.resolve().then(r.t.bind(r,6114,23)),Promise.resolve().then(r.t.bind(r,9727,23)),Promise.resolve().then(r.t.bind(r,9671,23)),Promise.resolve().then(r.t.bind(r,1868,23)),Promise.resolve().then(r.t.bind(r,4759,23))},7581:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>a});var n=r(326),i=r(7577),o=r(5047);function a(){let e=(0,o.useRouter)(),[t,r]=(0,i.useState)(null),[a,d]=(0,i.useState)(!0),[l,c]=(0,i.useState)(!1);async function p(){try{await fetch("/api/auth/logout",{method:"POST",credentials:"same-origin"}),e.push("/")}catch(t){console.error("Logout error:",t),e.push("/")}}async function u(){let e=await fetch("/api/auth/csrf",{credentials:"same-origin"});return(await e.json()).csrfToken||""}async function x(){c(!0);try{let t=await u(),r=await fetch("/api/scenario/uniqueizer/start",{method:"POST",credentials:"same-origin",headers:{"Content-Type":"application/json","x-csrf-token":t}});if(r.ok){let t=await r.json();e.push(`/uniqueizer?generationUuid=${t.generationUuid}`)}else{let e=await r.json();alert("Ошибка запуска сценария: "+(e.message||r.statusText))}}catch(e){alert("Ошибка: "+(e instanceof Error?e.message:String(e)))}finally{c(!1)}}return a?n.jsx("div",{style:s.loading,children:"Загрузка..."}):n.jsx("div",{style:s.page,children:(0,n.jsxs)("div",{style:s.container,children:[(0,n.jsxs)("div",{style:s.header,children:[n.jsx("h1",{style:s.headerTitle,children:"Uno Click"}),n.jsx("button",{onClick:p,style:s.logoutBtn,children:"Выйти"})]}),(0,n.jsxs)("div",{style:s.welcome,children:[(0,n.jsxs)("h2",{style:s.welcomeTitle,children:["Добро пожаловать, ",t?.displayName||t?.email,"!"]}),n.jsx("p",{style:s.welcomeText,children:"Выберите сценарий для запуска"})]}),(0,n.jsxs)("div",{style:s.scenariosGrid,children:[(0,n.jsxs)("div",{style:s.scenarioCard,children:[n.jsx("div",{style:{...s.scenarioIcon,...s.scenarioIconBlue},children:"\uD83C\uDFA8"}),n.jsx("div",{style:s.scenarioName,children:"Nano Banana"}),n.jsx("div",{style:s.scenarioDesc,children:"Генерация изображений по текстовому описанию. Введите промпт и получите уникальную иллюстрацию."}),n.jsx("a",{href:"/prompt?scenario=nano-banana",style:s.btnPrimary,children:"Запустить"})]}),(0,n.jsxs)("div",{style:s.scenarioCard,children:[n.jsx("div",{style:{...s.scenarioIcon,...s.scenarioIconGreen},children:"\uD83E\uDDEA"}),n.jsx("div",{style:s.scenarioName,children:"Demo Scenario"}),n.jsx("div",{style:s.scenarioDesc,children:"Тестовый сценарий для проверки функциональности. Многоступенчатая генерация с подтверждением."}),n.jsx("a",{href:"/prompt?scenario=demo-scenario",style:s.btnSecondary,children:"Запустить"})]}),(0,n.jsxs)("div",{style:s.scenarioCard,children:[n.jsx("div",{style:{...s.scenarioIcon,...s.scenarioIconBlue},children:"✨"}),n.jsx("div",{style:s.scenarioName,children:"Уникализация"}),n.jsx("div",{style:s.scenarioDesc,children:"Запуск сценария уникализации контента."}),n.jsx("button",{onClick:x,disabled:l,style:{...s.btnPrimary,...l?s.btnDisabled:{}},children:l?"Запуск...":"Запустить"})]})]})]})})}let s={page:{minHeight:"100vh",padding:"40px 20px",background:"#f5f5f5"},container:{maxWidth:"800px",margin:"0 auto"},header:{background:"white",padding:"20px 30px",borderRadius:"8px",boxShadow:"0 2px 10px rgba(0,0,0,0.1)",marginBottom:"20px",display:"flex",justifyContent:"space-between",alignItems:"center"},headerTitle:{fontSize:"20px",fontWeight:600,color:"#333"},logoutBtn:{background:"none",border:"1px solid #ddd",padding:"8px 16px",borderRadius:"6px",cursor:"pointer",fontSize:"14px",color:"#666"},welcome:{background:"white",padding:"20px 30px",borderRadius:"8px",boxShadow:"0 2px 10px rgba(0,0,0,0.1)",marginBottom:"20px"},welcomeTitle:{fontSize:"18px",fontWeight:600,color:"#333",marginBottom:"8px"},welcomeText:{color:"#666",fontSize:"14px"},scenariosGrid:{display:"grid",gridTemplateColumns:"repeat(auto-fill, minmax(300px, 1fr))",gap:"20px"},scenarioCard:{background:"white",borderRadius:"8px",boxShadow:"0 2px 10px rgba(0,0,0,0.1)",padding:"24px",transition:"box-shadow 0.2s"},scenarioIcon:{width:"48px",height:"48px",borderRadius:"10px",display:"flex",alignItems:"center",justifyContent:"center",fontSize:"24px",marginBottom:"16px"},scenarioIconBlue:{background:"linear-gradient(135deg, #667eea 0%, #764ba2 100%)"},scenarioIconGreen:{background:"linear-gradient(135deg, #11998e 0%, #38ef7d 100%)"},scenarioName:{fontSize:"16px",fontWeight:600,color:"#333",marginBottom:"8px"},scenarioDesc:{fontSize:"14px",color:"#666",marginBottom:"20px",lineHeight:1.5},btnPrimary:{width:"100%",padding:"12px",background:"#007bff",color:"white",border:"none",borderRadius:"6px",fontSize:"14px",fontWeight:500,cursor:"pointer",textAlign:"center",textDecoration:"none",display:"inline-block"},btnSecondary:{width:"100%",padding:"12px",background:"#f5f5f5",color:"#333",border:"1px solid #ddd",borderRadius:"6px",fontSize:"14px",fontWeight:500,cursor:"pointer",textAlign:"center",textDecoration:"none",display:"inline-block"},btnDisabled:{background:"#ccc",cursor:"not-allowed"},loading:{display:"flex",alignItems:"center",justifyContent:"center",minHeight:"100vh",fontSize:"18px",color:"#666"}}},5047:(e,t,r)=>{"use strict";var n=r(7389);r.o(n,"useRouter")&&r.d(t,{useRouter:function(){return n.useRouter}}),r.o(n,"useSearchParams")&&r.d(t,{useSearchParams:function(){return n.useSearchParams}})},9521:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>n});let n=(0,r(8570).createProxy)(String.raw`/opt/uno-click/site/app/dashboard/page.tsx#default`)},1506:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>o,metadata:()=>i});var n=r(9510);r(7272);let i={title:"Uno Click",description:"Uno Click - платформа для генерации контента"};function o({children:e}){return n.jsx("html",{lang:"ru",children:n.jsx("body",{children:e})})}},7272:()=>{}};var t=require("../../webpack-runtime.js");t.C(e);var r=e=>t(t.s=e),n=t.X(0,[819],()=>r(8209));module.exports=n})();