1 line
8.2 KiB
JavaScript
1 line
8.2 KiB
JavaScript
(()=>{var e={};e.id=890,e.ids=[890],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")},6081:(e,t,s)=>{"use strict";s.r(t),s.d(t,{GlobalError:()=>l.a,__next_app__:()=>u,originalPathname:()=>x,pages:()=>c,routeModule:()=>m,tree:()=>o}),s(3076),s(5166),s(5866);var a=s(3191),r=s(8716),n=s(7922),l=s.n(n),i=s(5231),d={};for(let e in i)0>["default","tree","pages","GlobalError","originalPathname","__next_app__","routeModule"].indexOf(e)&&(d[e]=()=>i[e]);s.d(t,d);let o=["",{children:["stock",{children:["[code]",{children:["__PAGE__",{},{page:[()=>Promise.resolve().then(s.bind(s,3076)),"/Users/aaron/source_code/astock-agent/frontend/src/app/stock/[code]/page.tsx"]}]},{}]},{}]},{layout:[()=>Promise.resolve().then(s.bind(s,5166)),"/Users/aaron/source_code/astock-agent/frontend/src/app/layout.tsx"],"not-found":[()=>Promise.resolve().then(s.t.bind(s,5866,23)),"next/dist/client/components/not-found-error"]}],c=["/Users/aaron/source_code/astock-agent/frontend/src/app/stock/[code]/page.tsx"],x="/stock/[code]/page",u={require:s,loadChunk:()=>Promise.resolve()},m=new a.AppPageRouteModule({definition:{kind:r.x.APP_PAGE,page:"/stock/[code]/page",pathname:"/stock/[code]",bundlePath:"",filename:"",appPaths:[]},userland:{loaderTree:o}})},2647:(e,t,s)=>{Promise.resolve().then(s.bind(s,8601))},8601:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>c});var a=s(326),r=s(7577),n=s(5047),l=s(1223);function i({data:e}){let t=(0,r.useRef)(null);return(0,a.jsxs)("div",{className:"bg-bg-card rounded-xl p-4",children:[a.jsx("h2",{className:"text-sm font-medium text-text-secondary mb-2",children:"K线图"}),a.jsx("div",{ref:t,className:"w-full h-64 md:h-80"})]})}function d({data:e}){let t=(0,r.useRef)(null);return(0,a.jsxs)("div",{className:"bg-bg-card rounded-xl p-4",children:[a.jsx("h2",{className:"text-sm font-medium text-text-secondary mb-2",children:"资金流向"}),a.jsx("div",{ref:t,className:"w-full h-48"})]})}function o({signals:e}){let t=(0,r.useRef)(null);return(0,a.jsxs)("div",{className:"bg-bg-card rounded-xl p-4",children:[a.jsx("h2",{className:"text-sm font-medium text-text-secondary mb-2",children:"信号雷达"}),a.jsx("div",{ref:t,className:"w-full h-56"})]})}function c(){(0,n.useParams)().code;let[e,t]=(0,r.useState)(null),[s,c]=(0,r.useState)(null),[m,p]=(0,r.useState)([]),[h,g]=(0,r.useState)([]);return(0,a.jsxs)("div",{className:"max-w-6xl mx-auto px-4 md:px-8 pt-6 pb-20 md:pb-10 space-y-5",children:[(0,a.jsxs)("a",{href:"/",className:"inline-flex items-center gap-1.5 text-xs text-text-muted hover:text-text-primary transition-colors animate-fade-in-up",children:[a.jsx("svg",{width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round",strokeLinejoin:"round",children:a.jsx("path",{d:"M19 12H5M12 19l-7-7 7-7"})}),"返回"]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-4 animate-fade-in-up",children:[e&&(0,a.jsxs)("div",{className:"glass-card-static p-5 md:col-span-2",children:[a.jsx("div",{className:"flex items-center justify-between mb-3",children:(0,a.jsxs)("div",{className:"flex items-center gap-3",children:[a.jsx("span",{className:"text-lg font-bold tracking-tight",children:e.name}),a.jsx("span",{className:"text-xs text-text-muted font-mono tabular-nums",children:e.ts_code})]})}),(0,a.jsxs)("div",{className:"flex items-baseline gap-3",children:[a.jsx("span",{className:`text-3xl font-bold font-mono tabular-nums tracking-tight ${e.pct_chg>0?"text-red-400":e.pct_chg<0?"text-emerald-400":"text-text-primary"}`,children:e.price.toFixed(2)}),(0,a.jsxs)("span",{className:`text-sm font-mono tabular-nums font-medium ${e.pct_chg>0?"text-red-400":"text-emerald-400"}`,children:[e.pct_chg>0?"+":"",e.pct_chg.toFixed(2),"%"]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-4 gap-3 mt-4",children:[a.jsx(x,{label:"换手率",value:`${e.turnover_rate?.toFixed(2)}%`}),a.jsx(x,{label:"市盈率",value:e.pe?.toFixed(1)??"-"}),a.jsx(x,{label:"市净率",value:e.pb?.toFixed(2)??"-"}),a.jsx(x,{label:"流通市值",value:e.circ_mv?`${e.circ_mv.toFixed(0)}亿`:"-"})]})]}),s&&a.jsx("div",{className:"hidden md:block",children:a.jsx(o,{signals:s})})]}),s&&(0,a.jsxs)("div",{className:"glass-card-static p-5 animate-fade-in-up delay-75",children:[(0,a.jsxs)("div",{className:"flex items-center justify-between mb-4",children:[a.jsx("h2",{className:"text-xs font-semibold text-text-muted uppercase tracking-wider",children:"技术面信号"}),(0,a.jsxs)("div",{className:`text-lg font-bold font-mono tabular-nums ${(0,l.Uz)(s.score)}`,children:[s.score,a.jsx("span",{className:"text-xs text-text-muted ml-0.5",children:"分"})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-2",children:[a.jsx(u,{label:"均线多头",active:s.ma_bullish,points:15}),a.jsx(u,{label:"放量突破",active:s.volume_breakout,points:20}),a.jsx(u,{label:"MACD金叉",active:s.macd_golden,points:15}),a.jsx(u,{label:"RSI健康",active:s.rsi_healthy,points:10}),a.jsx(u,{label:"缩量回踩",active:s.pullback_support,points:15}),a.jsx(u,{label:"放量长阳",active:s.big_yang,points:15}),a.jsx(u,{label:"布林支撑",active:s.boll_support,points:10})]}),(0,a.jsxs)("div",{className:"flex justify-between mt-4 pt-4 border-t border-white/[0.04] text-xs",children:[(0,a.jsxs)("div",{children:[a.jsx("span",{className:"text-text-muted",children:"支撑位 "}),a.jsx("span",{className:"text-orange-400 font-mono tabular-nums",children:s.support_price??"-"})]}),(0,a.jsxs)("div",{children:[a.jsx("span",{className:"text-text-muted",children:"压力位 "}),a.jsx("span",{className:"text-red-400 font-mono tabular-nums",children:s.resist_price??"-"})]}),(0,a.jsxs)("div",{children:[a.jsx("span",{className:"text-text-muted",children:"止损位 "}),a.jsx("span",{className:"text-emerald-400 font-mono tabular-nums",children:s.stop_loss_price??"-"})]})]})]}),(0,a.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4 animate-fade-in-up delay-150",children:[m.length>0&&a.jsx(i,{data:m}),h.length>0&&a.jsx(d,{data:h})]}),s&&a.jsx("div",{className:"md:hidden animate-fade-in-up delay-225",children:a.jsx(o,{signals:s})})]})}function x({label:e,value:t}){return(0,a.jsxs)("div",{className:"bg-white/[0.02] rounded-lg px-3 py-2 border border-white/[0.03]",children:[a.jsx("div",{className:"text-xs text-text-muted mb-0.5",children:e}),a.jsx("div",{className:"text-xs font-mono tabular-nums",children:t})]})}function u({label:e,active:t,points:s}){return(0,a.jsxs)("div",{className:`flex items-center justify-between px-3 py-2 rounded-xl text-xs transition-all duration-200 ${t?"bg-red-500/[0.08] text-red-400 border border-red-500/10":"bg-white/[0.02] text-text-muted border border-transparent"}`,children:[a.jsx("span",{className:"font-medium",children:e}),a.jsx("span",{className:`font-mono tabular-nums ${t?"font-semibold":""}`,children:t?`+${s}`:"0"})]})}},1223:(e,t,s)=>{"use strict";function a(e){return Math.abs(e)>=1e4?(e/1e4).toFixed(2)+"亿":Math.abs(e)>=1?e.toFixed(2)+"万":e.toFixed(2)}function r(e){return e>=80?"text-red-400":e>=60?"text-orange-400":e>=40?"text-yellow-400":"text-gray-400"}function n(e){switch(e){case"强烈推荐":return{bg:"bg-red-500/20",text:"text-red-400"};case"推荐":return{bg:"bg-orange-500/20",text:"text-orange-400"};case"观望":return{bg:"bg-yellow-500/20",text:"text-yellow-400"};default:return{bg:"bg-gray-500/20",text:"text-gray-400"}}}function l(e){return"BUY"===e?"text-red-400":"SELL"===e?"text-green-400":"text-gray-400"}function i(e){return e>=70?"#ff6b6b":e>=50?"#f59e0b":e>=30?"#fbbf24":"#34d399"}function d(e){return e>=70?"火热":e>=50?"温和":e>=30?"偏冷":"冰点"}s.d(t,{R8:()=>l,Uz:()=>r,Zd:()=>d,jD:()=>i,ny:()=>n,uf:()=>a})},3076:(e,t,s)=>{"use strict";s.r(t),s.d(t,{default:()=>a});let a=(0,s(8570).createProxy)(String.raw`/Users/aaron/source_code/astock-agent/frontend/src/app/stock/[code]/page.tsx#default`)}};var t=require("../../../webpack-runtime.js");t.C(e);var s=e=>t(t.s=e),a=t.X(0,[948,982,171],()=>s(6081));module.exports=a})(); |