PageSourceSearch

https://www.uusisuomi.fi/static/static/js/async/elections.7263ba689c.js

js uusisuomi.fi collected 2026-10-01 11:38:39 UTC 7,218 bytes, 4 lines download raw bytes

1"use strict";(globalThis.rspackChunktalent_news_frontend||=[]).push([["4s"],{XX(t,e,i){var a=i("X4"),o=i("DG"),n=i("WR");let{mediaShortSlugs:r,apiRoot:s}=a.A;e.A=function(t,e){let i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:15;return(a,l,c)=>{let d=l();return((t,e,i,a)=>{if((0,o.b0)(e))return!1;let n=t.topic[e];return!n||!n.lastUpdated||n.lastUpdated+6e4<Date.now()||n.items.length<i+a})(d,t,e,i)?c.get(`${s}pages/v2/listingpage/topic/${r}/${t}/${e}/${i}`).then(i=>i.topicList.items.length||"vain-tilaajille"===t?(a((0===e?n.TJ:n.tj)((0,n.CE)({slug:t,data:i}))),Promise.resolve(i.topicList)):Promise.reject({status:404})).catch(t=>Promise.reject(t)):Promise.resolve(d.topic[t])}}},Hw(__unused_rspack_module,__webpack_exports__,__webpack_require__){var react_jsx_runtime__rspack_import_0=__webpack_require__("X"),react__rspack_import_1=__webpack_require__("u"),styled_components__rspack_import_2=__webpack_require__("tE");function _defineProperty(t,e,i){return(e=_toPropertyKey(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function _toPropertyKey(t){var e=_toPrimitive(t,"string");return"symbol"==typeof e?e:e+""}function _toPrimitive(t,e){if("object"!=typeof t||!t)return t;var i=t[Symbol.toPrimitive];if(void 0!==i){var a=i.call(t,e||"default");if("object"!=typeof a)return a;throw TypeError("@@toPrimitive must return a primitive value.")}return("string"===e?String:Number)(t)}let Embed=(styled_components__rspack_import_2.Ay.div.withConfig({componentId:"sc-198d75c4-0"}))(["max-width:100%;background-color:inherit;clear:both;iframe,> *{max-width:100%;}"]),scriptId=t=>`ext-${t}`;function evalJS(id){try{let scripts=document.querySelectorAll(`#${scriptId(id)} script`);Array.prototype.forEach.call(scripts,script=>{if(script.src){let s=document.createElement("script");s.async=!0,s.src=script.src,document.head.appendChild(s)}else eval(script.text)})}catch(error){console.log(error)}window.scripts[id]=!0}function cleanupJS(t){delete window.scripts[t];let e=document.querySelectorAll(`#${scriptId(t)} script`);Array.prototype.forEach.call(e,t=>{t.parentNode&&t.parentNode.removeChild(t)})}class GenericExternalHtml extends react__rspack_import_1.Component{componentDidMount(){window.scripts=window.scripts||{},this.setState({mounted:!0}),this.prevId=this.props.id}componentDidUpdate(){var t;this.prevId&&this.prevId!==this.props.id&&(cleanupJS(this.prevId),this.prevId=this.props.id),(null==(t=window.scripts)?void 0:t[this.props.id])||evalJS(this.props.id)}componentWillUnmount(){this.props.loadEveryTimePageIsVisited&&cleanupJS(this.props.id)}render(){return this.state.mounted?(0,react_jsx_runtime__rspack_import_0.jsx)(Embed,{id:scriptId(this.props.id),dangerouslySetInnerHTML:{__html:this.props.html}}):null}constructor(...t){super(...t),_defineProperty(this,"state",{}),_defineProperty(this,"prevId",null)}}__webpack_exports__.A=GenericExternalHtml},Qz(t,e,i){i.d(e,{A:()=>P});var a,o,n,r=i("X"),s=i("u"),l=i("XE"),c=i("tE"),d=i("Tu"),p=i("fq");let u=(0,c.i7)(["0%{opacity:.2;}20%{opacity:1;}100%{opacity:.2;}"]),m=(0,c.i7)(["0%{opacity:0}100%{opacity:0.8}"]),h=(c.Ay.div.withConfig({componentId:"sc-20be0b5c-0"}))(["display:inline-block;background-color:",";margin:4px;height:10px;width:10px;animation-name:",";animation-duration:1.4s;animation-iteration-count:infinite;animation-fill-mode:both;animation-delay:","s;"],p.Ay.colors.main,u,t=>{let{$index:e}=t;return .2*e}),v=(c.Ay.div.withConfig({componentId:"sc-20be0b5c-1"}))(["text-align:center;padding:20px 0;"]),f=(c.Ay.div.withConfig({componentId:"sc-20be0b5c-2"}))(["position:fixed;top:40vh;left:0;right:0;text-align:center;"]),g=(c.Ay.div.withConfig({componentId:"sc-20be0b5c-3"}))(["background:#fff;opacity:0.8;position:absolute;width:100%;height:100%;z-index:100;animation:"," 0.15s;"],m),y=[0,1,2,3,4].map(t=>(0,r.jsx)(h,{$index:t},t));var w=t=>{let{overlay:e,...i}=t;return e?(0,r.jsx)(g,{...i,children:a||(a=(0,r.jsx)(f,{children:y}))}):(0,r.jsx)(v,{...i,children:y})};let b=(c.Ay.div.withConfig({componentId:"sc-f4eed479-0"}))(["position:relative;padding:0.9375rem 0;",";"],(0,d.A)("tablet")`
2        padding-top: 0;
3    `);var x=(0,l.Ng)(t=>({loading:t.ui.loading}))(t=>{let{loading:e,children:i}=t;return(0,r.jsxs)(b,{children:[e&&(o||(o=(0,r.jsx)(w,{overlay:!0}))),i]})}),A=i("Hw"),j=i("Xi"),I=i("Xo"),k=i("Rf"),C=i("lW");let E=(c.Ay.main.withConfig({componentId:"sc-cf4b58c7-0"}))(["color:",";",";@media ","{margin:0 auto;}@media ","{padding:0 ",";}"],I.I8.color.primary["5"],t=>{let{theme:e}=t;
3return e.foundation.media.type.ui.medium},I.I8.mediaquery.max.small,I.I8.mediaquery.min.small,I.I8.spacing.large),$=(c.Ay.section.withConfig({componentId:"sc-cf4b58c7-1"}))(["padding-top:",";"],I.I8.spacing["x-large"]);var P=(0,l.Ng)(t=>{var e,i;return{teasers:(null==(i=t.topic)||null==(e=i.vaalit)?void 0:e.items)||[]}})(t=>{let{teasers:e,html:i,id:a,genericPageHead:o}=t,c=(0,l.d4)(t=>{var e;return(null==(e=t.history.location)?void 0:e.pathname)||""}),d=s.useRef(!1),p=s.useRef(C.A.location.hash),u=s.useRef(null),m=s.useCallback(()=>{requestAnimationFrame(()=>{setTimeout(()=>{var t;let e=null==(t=u.current)?void 0:t.getBoundingClientRect().top;if(void 0!==e){let t=window.pageYOffset+e-20;window.scrollTo({top:t,behavior:"smooth"})}},100)})},[]);s.useEffect(()=>{"/vaalikone2025"===c&&(d.current=!0,C.A.location.hash!==p.current&&m(),p.current=C.A.location.hash)},[c,C.A.location.hash,m]);let h=s.useMemo(()=>"/vaalikone2025"!==c||!d.current,[c]);return s.useEffect(()=>{let t=t=>{var e;(null==(e=t.data)?void 0:e.type)==="hashchange"&&m()};return window.addEventListener("message",t),()=>window.removeEventListener("message",t)},[m]),(0,r.jsx)(x,{children:(0,r.jsxs)(E,{id:"skyscraper-height-div",children:[o,(0,r.jsxs)($,{children:[(0,r.jsx)("div",{ref:u,children:(0,r.jsx)(A.A,{html:i,id:a,loadEveryTimePageIsVisited:h})}),(0,r.jsx)(X,{teaserList:e.slice(0,6),title:"Vaalit",$_css:`${I.I8.spacing["x-large"]} 0`}),n||(n=(0,r.jsx)(j.F0,{postContent:!0,skipPlaceholder:!0}))]})]})})}),X=(0,c.Ay)(k.A).withConfig({componentId:"sc-cf4b58c7-2"})(t=>({margin:t.$_css}))},UO(t,e,i){i.r(e);var a=i("X");i("u");var o=i("XX"),n=i("VT"),r=i("EJ"),s=i("Qz"),l=i("k4"),c=i("jo");async function d(t){let e,{params:i,store:d}=t;switch(i.year){case"2019":e="https://tulospalvelu.vaalit.almamedia.fi/ekv-2019/tulospalvelu.js";break;case"2021":e="https://tulospalvelu.vaalit.almamedia.fi/kv-2021/tulospalvelu.kv2021.js";break;case"2022":e="https://tulospalvelu.vaalit.almamedia.fi/av-2022/tulospalvelu.js";break;case"2023":e="https://tulospalvelu.vaalit.almamedia.fi/ekv-2023/tulospalvelu.js";break;case"2024":e="https://tulospalvelu.vaalit.almamedia.fi/tpv-2024-2/tulospalvelu.js";break;default:return(0,c.A)({status:404,store:d})}await Promise.all([d.dispatch((0,l.A)("vaalit","vaalitulos","vaalitulos","otherpage"))]),await (0,n.it)([(0,o.A)("presidentinvaalit",0,24)].filter(Boolean).map(t=>d.dispatch(t).catch(r.A)));let p=`<div id="alma-tulospalvelu-app" data-is-alma="true" data-enable-theme="true"><script type="text/javascript" src="${e}" ><\/script></div>`;return(0,a.jsx)(s.A,{html:p,id:"vaalitulos"})}i.d(e,{default:()=>d})}}]);
4//# sourceMappingURL=elections.7263ba689c.js.map

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.