(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3278],{20101:function(e,t,n){"use strict";n.d(t,{CZ:function(){return l},D1:function(){return i},PK:function(){return d},SD:function(){return s},W$:function(){return c},WF:function(){return a},cc:function(){return o},uy:function(){return r}}),n(75646);var r="mnc8st7",a="mnc8st6",i="mnc8st4",o="mnc8st0",l="mnc8st1",c="mnc8st8",s="mnc8st2",d="mnc8st3"},20739:function(e,t,n){"use strict";n.d(t,{c5:function(){return r},pX:function(){return a},vd:function(){return i}}),n(95546);var r={default:"_2ozzgc7",narrow:"_2ozzgc7",aside:"_2ozzgc7",nav:"_2ozzgc7",detail:"_2ozzgcc _2ozzgc7"},a={WIDTH:{MIN:652,MAX:992}},i={default:"_2ozzgc3 _2ozzgc0",narrow:"_2ozzgc4 _2ozzgc2",detail:"_2ozzgc5",nav:"_2ozzgc1"}},47390:function(e,t,n){"use strict";n.d(t,{A:function(){return Layout}});var r=n(26925),a=n(20739);let Layout=e=>{switch(e.variants){case"nav":return(0,r.BX)("div",{className:a.vd.nav,"data-section-name":e["data-section-name"],children:[(0,r.tZ)("nav",{children:e.nav}),(0,r.tZ)("div",{className:a.c5.nav,children:e.children})]});case"detail":return(0,r.tZ)("div",{className:a.vd.detail,children:(0,r.tZ)("div",{className:a.c5.detail,children:e.children})});case"narrow":return(0,r.tZ)("div",{className:a.vd.narrow,children:(0,r.tZ)("div",{className:a.c5.narrow,children:e.children})});default:return(0,r.tZ)("div",{className:a.vd.default,children:(0,r.tZ)("div",{className:a.c5.default,children:e.children})})}}},81867:function(e,t,n){"use strict";n.d(t,{k:function(){return RollingNumbers}});var r=n(26925),a=n(52334),i=n(27593),o=n(93663),l=n(69581),c=n(30341),s=n(80544),d=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,u=(0,s.Z)(function(e){return d.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&91>e.charCodeAt(2)}),p=n(14100),m=n(88037),h=n(550),f=n(69610),testOmitPropsOnComponent=function(e){return"theme"!==e},getDefaultShouldForwardProp=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?u:testOmitPropsOnComponent},composeShouldForwardProps=function(e,t,n){var r;if(t){var a=t.shouldForwardProp;r=e.__emotion_forwardProp&&a?function(t){return e.__emotion_forwardProp(t)&&a(t)}:a}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Insertion=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return(0,m.hC)(t,n,r),(0,f.L)(function(){return(0,m.My)(t,n,r)}),null},g=(function createStyled(e,t){var n,r,i=e.__emotion_real===e,o=i&&e.__emotion_base||e;void 0!==t&&(n=t.label,r=t.target);var l=composeShouldForwardProps(e,t,i),s=l||getDefaultShouldForwardProp(o),d=!s("as");return function(){var u=arguments,f=i&&void 0!==e.__emotion_styles?e.__emotion_styles.slice(0):[];if(void 0!==n&&f.push("label:"+n+";"),null==u[0]||void 0===u[0].raw)f.push.apply(f,u);else{f.push(u[0][0]);for(var g=u.length,y=1;y<g;y++)f.push(u[y],u[0][y])}var v=(0,p.w)(function(e,t,n){var i=d&&e.as||o,c="",u=[],g=e;if(null==e.theme){for(var y in g={},e)g[y]=e[y];g.theme=a.useContext(p.T)}"string"==typeof e.className?c=(0,m.fp)(t.registered,u,e.className):null!=e.className&&(c=e.className+" ");var v=(0,h.O)(f.concat(u),t.registered,g);c+=t.key+"-"+v.name,void 0!==r&&(c+=" "+r);var x=d&&void 0===l?getDefaultShouldForwardProp(i):s,b={};for(var _ in e)(!d||"as"!==_)&&x(_)&&(b[_]=e[_]);return b.className=c,b.ref=n,a.createElement(a.Fragment,null,a.createElement(Insertion,{cache:t,serialized:v,isStringTag:"string"==typeof i}),a.createElement(i,b))});return v.displayName=void 0!==n?n:"Styled("+("string"==typeof o?o:o.displayName||o.name||"Component")+")",v.defaultProps=e.defaultProps,v.__emotion_real=v,v.__emotion_base=o,v.__emotion_styles=f,v.__emotion_forwardProp=l,Object.defineProperty(v,"toString",{value:function(){return"."+r}}),v.withComponent=function(e,n){return createStyled(e,(0,c.Z)({},t,n,{shouldForwardProp:composeShouldForwardProps(v,n,!0)})).apply(void 0,f)},v}}).bind();["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"].forEach(function(e){g[e]=g(e)});var y=n(91275),v=n(4778),x=n(64668),b=n(3218),_=n(52861),k=n(1213),w=n(39078);function _tagged_template_literal(e,t){return t||(t=e.slice(0)),Object.freeze(Object.defineProperties(e,{raw:{value:Object.freeze(t)}}))}function _templateObject(){let e=_tagged_template_literal(["translate3d(0, ","px, 0)"]);return _templateObject=function(){return e},e}function _templateObject1(){let e=_tagged_template_literal(["\n  position: relative;\n  height: ",";\n  overflow: hidden;\n  font-variant-numeric: tabular-nums;\n"]);return _templateObject1=function(){return e},e}n(133);let I=[0,1,2,3,4,5,6,7,8,9];function RollingNumberItem(e){let{value:t,color:n,height:a}=e,i=Number(t),o=(0,y.c)(-i*a),l=(0,v.q)(o,{mass:1,stiffness:300,damping:24}),c=function(e,...t){let n=e.length;return function(e,t){let n=(0,y.c)(t()),updateValue=()=>n.set(t());return updateValue(),(0,x.L)(()=>{let scheduleUpdate=()=>b.Wi.preRender(updateValue,!1,!0),t=e.map(e=>e.on("change",scheduleUpdate));return()=>{t.forEach(e=>e()),(0,b.Pn)(updateValue)}}),n}(t.filter(_.i),function(){let r="";for(let a=0;a<n;a++){r+=e[a];let n=t[a];n&&(r+=(0,_.i)(n)?n.get():n)}return r})}(_templateObject(),l);return(0,w.L)(()=>{o.set(-i*a)},[a,i,o]),(0,r.tZ)(N,{height:a,children:(0,r.tZ)(k.E.div,{"aria-hidden":!0,className:"_1vp8dod1",style:{transform:c,color:n},children:I.map(e=>(0,r.tZ)("span",{style:{color:"inherit"},children:e},e))})})}let N=g.div(_templateObject1(),e=>{let{height:t}=e;return"".concat(t,"px")});function RollingNumbers(e){let{numbersStr:t,color:n}=e,c=(0,l.J)(),[s,d]=(0,a.useState)(0),u=(0,o.y)(e=>{d(e.contentRect.height)});return c?(0,r.tZ)(r.HY,{children:t}):(0,r.BX)(i.H_,{as:"div",className:"_1vxpe8f0",typography:"h5",children:[0===s?(0,r.tZ)("span",{className:"_1vxpe8f1",children:t}):(0,r.tZ)(r.HY,{children:t.split("").map((e,t)=>/[0-9]/.test(e)?(0,r.tZ)(RollingNumberItem,{color:n,height:s,value:e},t):(0,r.tZ)("span",{"aria-hidden":!0,style:{color:n},children:e},t))}),(0,r.tZ)("span",{ref:u,"aria-hidden":!0,className:"_1vxpe8f2",children:t})]})}n(59236)},60896:function(e,t,n){"use strict";n.d(t,{c:function(){return useBodyBackgroundColor}});var r=n(19772),a=n(63769),i=n(17978);let useBodyBackgroundColor=e=>{(0,a.L)(()=>{if(!r.fN||!r.Oj){let e=document.body.style.getPropertyValue(i.U);if(null!=e&&""!==e)throw Error("useBodyBackgroundColor가 한 페이지에서 두 번 이상 사용되었습니다.")}return document.body.style.setProperty(i.U,e),document.body.classList.add(i.V),()=>{document.body.style.removeProperty(i.U),document.body.classList.remove(i.V)}},[e])}},89459:function(e,t,n){"use strict";n.d(t,{IF:function(){return getIndexPrice},Nl:function(){return getIndexTradeTrend},UZ:function(){return getIndexPriceCandle},ZF:function(){return getExchangeRatePriceCandle},ar:function(){return getIndexInfoList},f8:function(){return getIndexInfo},zx:function(){return getExchangeRatePrice}});var r=n(22829),a=n(96619),i=n(3942);let getIndexInfo=e=>a.hi.get("".concat(i.H.INFO,"/api/v2/index-infos/").concat(e)),getIndexPrice=e=>a.hi.get("".concat(i.H.INFO,"/api/v1/index-prices/").concat(e)),getIndexPriceCandle=(e,t,n)=>a.hi.get("".concat(i.H.INFO,"/api/v1/index-prices/").concat(e,"/candles/").concat(t,":").concat(n)),getIndexTradeTrend=e=>{let t=(0,r.stringify)({codes:e.join(",")},{addQueryPrefix:!0});return a.hi.get("".concat(i.H.INFO,"/api/v1/index-infos/trade/trend").concat(t))},getIndexInfoList=()=>a.hi.get("".concat(i.H.INFO,"/api/v2/index-infos")),getExchangeRatePrice=e=>a.hi.get("".concat(i.H.INFO,"/api/v1/exchange-rate-prices/").concat(e)),getExchangeRatePriceCandle=(e,t,n)=>a.hi.get("".concat(i.H.INFO,"/api/v1/exchange-rate-prices/").concat(e,"/candles/").concat(t,":").concat(n))},71020:function(e,t,n){"use strict";n.d(t,{N:function(){return ChartError}});var r=n(26925),a=n(27593),i=n(11483);let ChartError=e=>{let{onRetry:t}=e;return(0,r.tZ)(i.k,{alignItems:"center",direction:"column",justifyContent:"center",style:{height:"100%"},children:(0,r.tZ)(a.HY,{size:"small",asset:(0,r.tZ)(a.JO,{name:"icon-warning-circle",size:36,style:{width:36,height:36,marginBottom:12}}),title:(0,r.tZ)(a.HY.Title,{children:"차트를 불러오지 못했어요"}),button:(0,r.tZ)(a.HY.Button,{theme:"grey",variant:"weak",onClick:t,"data-tossinvest-log":"Empty.Button","data-parent-name":"ChartError",children:"새로고침"})})})}},19921:function(e,t,n){"use strict";n.d(t,{J:function(){return IndexChart}});var r=n(26925),a=n(27593),i=n(64008),o=n.n(i),l=n(20101),c=n(57354),s=n(71020);let d=o()(()=>Promise.all([n.e(7342),n.e(1869),n.e(5102)]).then(n.bind(n,45102)).then(e=>e.IndexChart),{loadableGenerated:{webpack:()=>[45102]},ssr:!1,loading:e=>{let{error:t,retry:n}=e;return null!=t?((0,c.U)(t),(0,r.tZ)(s.N,{onRetry:()=>null==n?void 0:n()})):(0,r.tZ)("div",{className:l.D1,children:(0,r.tZ)("div",{className:l.W$,children:(0,r.tZ)(a.nt,{children:(0,r.tZ)(a.nt.Spinner,{})})})})}}),IndexChart=e=>(0,r.tZ)(d,{...e})},21592:function(e,t,n){"use strict";n.d(t,{k:function(){return IndexHeaderLayout}});var r=n(26925),a=n(27593),i=n(10533);n(52547);let IndexHeaderLayout=e=>{let{title:t,numbers:n,titleSuffix:o,subTitle:l,imageUrl:c}=e;return(0,r.BX)("div",{className:"_1y8i0uf0",children:[(0,r.tZ)("div",{className:"_1y8i0uf1",children:null!=c?(0,r.tZ)("img",{alt:"",className:"_1y8i0uf2",src:c}):null}),(0,r.BX)("div",{className:"_1y8i0uf3",children:[(0,r.tZ)(a.H_,{as:"div",color:i.j$.grey800,fontWeight:"bold",typography:"h5",children:t}),(0,r.tZ)("div",{children:n}),o]}),(0,r.tZ)(a.H_,{as:"div",className:"_1y8i0uf4",color:i.j$.grey600,fontWeight:"medium",typography:"small",children:l})]})}},96504:function(e,t,n){"use strict";n.d(t,{f:function(){return IndexList}});var r=n(26925),a=n(89459),i=n(57103);let useIndexInfoList=e=>(0,i.a)({queryKey:useIndexInfoList.getKey(),queryFn:()=>(0,a.ar)(),...e});useIndexInfoList.getKey=()=>["/api/v2/index-infos"];var o=n(27593),l=n(10533),c=n(50412),s=n(16853),d=n(43114),u=n.n(d),p=n(57367),m=n(14522),h=n(88908),f=n(20973);n(39995);let IndexList=e=>{let{}=e,{data:t}=useIndexInfoList({refetchInterval:(0,c.U$)(1e4)});return(0,r.BX)("div",{className:"_1djdlxd0",children:[(0,r.tZ)(o.H_,{as:"h4",color:l.j$.grey800,fontWeight:"bold",typography:"p",className:"_1djdlxd1",children:"주요지수"}),(0,r.tZ)("div",{className:"_1djdlxd2",children:null!=t&&Object.entries(t.indexMap).map(e=>{let[t,n]=e;return(0,r.BX)("div",{className:"_1djdlxd3",children:[(0,r.tZ)(o.H_,{as:"h5",typography:"small",color:l.j$.grey700,fontWeight:"medium",className:"_1djdlxd5",children:t}),n.map(e=>(0,r.tZ)(u(),{href:"EXCHANGE_RATE"===e.code?"/indices/exchange-rate":"/indices/".concat(e.code),"data-tossinvest-log":"Link","data-parent-name":"IndexList",children:(0,r.tZ)(o.wc,{hasHoverStyle:!0,colspan:[1,"fit","fit"],icon:(0,r.tZ)(p.E,{src:e.logoImageUrl,alt:"",width:16,height:16,className:"_1djdlxd4"}),column1:(0,r.tZ)(o.wc.Text,{title:(0,r.tZ)(o.wc.Text.Title,{className:(0,h.S)({lines:1}),children:e.name})}),column2:(0,r.tZ)(o.wc.Text,{title:(0,r.tZ)(o.wc.Text.Title,{color:l.j$.grey700,fontWeight:"medium",children:e.close})}),column3:(0,r.tZ)(o.wc.Text,{style:{width:"70px"},title:(0,r.tZ)(o.wc.Text.Title,{color:m.O[Math.sign((0,s.Z)(e.close).minus(e.base).toNumber())],fontWeight:"medium",children:(0,f.AI)({base:e.base,close:e.close},{sign:!0})})})})},e.code))]},t)})})]})}},47398:function(e,t,n){"use strict";n.d(t,{$:function(){return useStockDetailBodyBackground}});var r=n(27593),a=n(10533),i=n(60896);let useStockDetailBodyBackground=()=>{let{colorPreference:e}=(0,r.xG)();(0,i.c)("dark"===e?a.O9.darkThemeBackgroundLevelB01:"#F6F7F9")}},75646:function(){},95546:function(){},133:function(){},59236:function(){},52547:function(){},39995:function(){}}]);