PageSourceSearch

https://www.ajtuotteet.fi/assets/3497.chunk.71130ee7fde8c27297e4.js

js ajtuotteet.fi collected 2026-09-26 18:04:01 UTC 10,160 bytes, 3 lines download raw bytes

1/*! For license information please see 3497.chunk.71130ee7fde8c27297e4.js.LICENSE.txt */
2"use strict";(globalThis.webpackChunknitro5_app=globalThis.webpackChunknitro5_app||[]).push([[3497],{23497(e,t,n){n.d(t,{default:()=>I});var r=n(26166),a=n(95082),o=n(63696),l=n(10774),i=n(30561),c=n(59095),s=n(39879),u=n(13149),m=n(39372),d=n(42914),p=n(29874),f=n(7410),g=n(91511),h=n(25194),v=n(61841),b=n(18291),y=n(24763),E=n(25927),x=n(58463),C=n(97760),k=n(62995),w=n(36806),T=n(20497);const I=(0,l.I4)(function(e){var t;const{currentBlockId:n,block:l,categoryTexts:u,fileSizeLimit:p,allowedFileTypes:g}=e,h=(0,a.Jn)(l.sendButtonText),v=(0,a.Jn)(l.attachmentButton),b=(0,a.Jn)(l.sendSuccessMessage),y=(0,a.Jn)(l.fileSizeErrorMessage),C=(0,a.Jn)(l.contactInfo),I=(0,a.Jn)(l.organization),U=(0,a.Jn)(l.firstRadioLabel),K=(0,a.Jn)(l.secondRadioLabel),G=(0,o.useMemo)(()=>(0,T.K)(u),[u]),Q=null===(t=G[0])||void 0===t?void 0:t.value,Z=(0,E.DD)(),ee=(0,o.useRef)(null),{submitState:te,pushSubmit:ne,closeFeedbackMessage:re}=(0,c.j8)(),[ae,oe]=(0,o.useState)(""),[le,ie]=(0,o.useState)(""),[ce,se]=(0,o.useState)(""),[ue,me]=(0,o.useState)(!1),[de,pe]=(0,o.useState)(null),[fe,ge]=(0,o.useState)(Q),{TooltipWrapper:he,TooltipWrapperProps:ve,showTooltip:be}=(0,w.A)(),ye=!(null==C?void 0:C.html);return o.createElement(S,null,o.createElement(d.x,{appearance:!!ye&&d.bA.Narrow},o.createElement(a.Cx,{for:l.title,component:X}),o.createElement(a.Cx,{for:l.description,component:V}),o.createElement(O,null,o.createElement(P,{css:{flexDirection:ye&&!Z?"row":"column",marginRight:ye||Z?0:2*s.wm},onSubmit:function(e){return(0,r.__awaiter)(this,void 0,void 0,function*(){re();ne((()=>(0,r.__awaiter)(this,void 0,void 0,function*(){try{const e=yield(0,k.S_)(),t="/contactformblock/send",r={contentBlockId:n,customerEmail:ae,organization:ue?K:U,phoneNumber:le,message:ce,categoryText:(0,T.q)(fe,u)},a=yield(0,f.T)(t,r,de,Object.assign({},e));if(!a.success)return Promise.reject(a.message);oe(""),ie(""),se(""),pe(null),ge(Q),ee.current&&(ee.current.value="");const o=0===a.message.length?b:a.message;return Promise.resolve(o)}catch(e){const t="string"==typeof e?e:(0,i.TlY)("/Errors/Unknown");return Promise.reject(t)}}))())})}},o.createElement(J,{css:!!ye&&!Z&&{marginRight:s.wm,flexBasis:"0%"}},o.createElement(q,null,I),o.createElement(W,{name:"organizationType",checked:!ue,onChange:e=>me(!e.currentTarget.checked),label:U},U),o.createElement(W,{name:"organizationType",checked:ue,onChange:e=>me(e.currentTarget.checked),label:K},K),o.createElement(B,{required:!0,value:ae,placeholder:(0,i.TlY)("/Account/MyDetail
2s/YourEmail"),onChange:e=>oe(e.currentTarget.value),preferFramed:!0,autoComplete:"email"}),o.createElement(Y,{required:!0,value:le,placeholder:(0,i.TlY)("/Account/MyDetails/MobileNumber"),onChange:e=>ie(e.currentTarget.value),preferFramed:!0,autoComplete:"tel"}),o.createElement(z,{"aria-label":(0,i.TlY)("/Shared/Select"),id:"contact-form-category-select",preferFramed:!0,options:G,value:fe,onChangeOption:ge})),o.createElement(J,{css:!!ye&&{flexBasis:"0%"}},o.createElement(a.Cx,{for:l.messageHeader,component:q}),o.createElement(F,{value:ce,onChange:e=>se(e.currentTarget.value),required:!0,lockedSize:!0}),o.createElement(a.Cx,{for:l.attachmentHeader,component:q}),o.createElement(he,Object.assign({},ve(),{css:N}),o.createElement(_,null,de?o.createElement(o.Fragment,null,o.createElement(j,null,null==de?void 0:de.name),o.createElement(D,{onClick:function(e){e.preventDefault(),pe(null),re(),ee.current&&(ee.current.value="")},"aria-label":(0,i.TlY)("/Shared/Close")},o.createElement(x.bm,null))):o.createElement(M,{as:m.Sx.Secondary,onClick:function(e){var t;e.preventDefault(),null===(t=ee.current)||void 0===t||t.click()},"aria-label":v},o.createElement(a.Cx,{for:l.attachmentButton})),o.createElement("input",{style:{display:"none"},type:"file",accept:g,ref:ee,onChange:function(e){const t=e.target.files[0];if((null==t?void 0:t.size)>p)return be({content:y,tooltipTheme:"error",showCloseIcon:!0,closeAfterSec:5}),void(e.target.value="");pe(t)}}))),o.createElement($,null,o.createElement(A,null,o.createElement(H,{state:te,as:m.Sx.Primary,type:"submit","aria-label":h,feedbackDirection:"right"},o.createElement(a.Cx,{for:l.sendButtonText}))),o.createElement(L,null,o.createElement(a.Cx,{for:l.privacyPolicyText}))))),!ye&&o.createElement(R,null,o.createElement(a.Ed,{html:null==C?void 0:C.html})))))}),S=(0,l.I4)(d.x,{backgroundColor:e=>e.siteTheme.contactFormBlock.backgroundColor,padding:{xy:s.as},margin:{y:({isCompact:e})=>e?s.Y:s.as},minHeight:"100%",height:"100%"}),A=l.I4.div({width:"fit-content"}),B=(0,l.I4)(g.A,C.rU,{width:"100%",margin:{bottom:s.Y}}),Y=(0,l.I4)(h.A,C.rU,{width:"100%",margin:{bottom:s.Y}}),z=(0,l.I4)(b.Ay,{width:"100%",margin:{bottom:s.as}}),F=(0,l.I4)(v.Ay,{width:"100%",height:150,margin:{top:s.EX,bottom:s.as}}),j=l.I4.span({fontStyle:"italic"}),D=(0,l.I4)(m.pH,{marginLeft:s.Y}),M=(0,l.I4)(m.wl,m.Xy),_=l.I4.div({display:"flex",alignItems:"center",width:"inherit"}),O=l.I4.div({display:"flex",flexDirection:({isCompact:e})=>e?"column":"row",marginTop:({isCompact:e})=>!e&&s.as}),R=l.I4.div({flex:{basis:"0%",grow:1,shrink:1},margin:{top:({isCompact:e})=>e?s.ut:s.EX,right:({isCompact:e})=>!e&&2*s.wm}}),P=(0,l.I4)(p.A,{display:"flex",flex:{basis:"0%",grow:1,shrink:1},textAlign:"left",margin:{top:({isCompact:e})=>e?s.as:s.EX}}),J=l.I4.div({flex:{basis:"auto",grow:1,shrink:1}}),W=(0,l.I4)(y.s,{margin:{top:s.Y,right:s.ut,bottom:s.Y}}),X=(0,l.I4)(u.H2,{marginTop:0}),V=l.I4.span({marginBottom:s.Y}),q=l.I4.span({fontWeight:"bold",display:"flex"}),$=l.I4.div({display:"flex",flexWrap:"wrap",marginTop:s.as}),H=(0,l.I4)((0,c.V4)(m.wl),{flex:{basis:"auto",grow:({isCompact:e})=>e?1:0,shrink:0}}),L=l.I4.div((0,s.X6)({property:"opacity",duration:300}),{flexDirection:"column",flex:{basis:({isCompact:e})=>e?"100%":"auto",grow:({isCompact:e})=>e?0:1,shrink:({isCompact:e})=>e?0:1},display:"flex",justifyContent:"center",marginTop:({isCompact:e})=>e?s.as:s.Y,fontSize:s.Ni}),N={marginTop:s.EX,width:"100%"}},20497(e,t,n){function r(e){return e?e.map((e,t)=>({text:e,value:t.toString()})):[]}function a(e,t){return t[parseInt(e)]||""}n.d(t,{K:()=>r,q:()=>a})}
2,61841(e,t,n){n.d(t,{Ay:()=>d,cL:()=>k,pV:()=>y});var r=n(26166),a=n(63696),o=n(10774),l=n(30561),i=n(39879),c=n(85506),s=n(76569),u=n(60593);const m=(0,o.I4)(e=>{var t,{onFocus:n,onBlur:o,onValidBlur:l,onChange:m,placeholder:d,children:b,uncontrolled:y,customInvalidMessage:E,setWarning:x,lockedSize:C=!1}=e,k=(0,r.__rest)(e,["onFocus","onBlur","onValidBlur","onChange","placeholder","children","uncontrolled","customInvalidMessage","setWarning","lockedSize"]);const w=(0,a.useRef)(null),T=(0,a.useRef)(null),I=k.value=k.value||"",[S,A]=(0,a.useState)(!1),[B,Y]=(0,a.useState)(!1),[z,F]=(0,a.useState)(!1),[j,D]=(0,a.useState)(""),[M,_]=(0,a.useState)(f(I)),O=(0,a.useRef)(!1),R=(0,c.A)().inputs.TextArea.component;(0,a.useEffect)(()=>{X.current||_(f(k.value||I)),Boolean(E)?(w.current.setCustomValidity(E),F(!0)):(w.current.setCustomValidity(""),F(!1),Y(e=>!e))},[E,k.value,I]);const P=(0,a.useCallback)(e=>{A(!0),x&&D(x(e.currentTarget)),null==n||n(e)},[x,n]),J=(0,a.useCallback)(e=>{if(D(""),A(!1),null==o||o(e),!O.current)return;const t=p(e.currentTarget,E);F(t),t||null==l||l(e)},[E,o,l]),W=(0,a.useCallback)(e=>{const t=e.currentTarget;O.current=!0,X.current=!1,x&&D(x(t));const n=f(t.value),r=n&&!M;F(e=>!(!e||r)&&p(t,E)),_(n),m&&m(e)},[x,M,m,E]),X=(0,a.useRef)(!1),V=(0,a.useCallback)(()=>{X.current||(X.current=!0,_(!0))},[]),q=(0,a.useCallback)(e=>{e.preventDefault();const t=p(e.currentTarget,E);F(t)},[E]);y&&(k.defaultValue=I,delete k.value),(0,u.N)(()=>{if(y){const e=I===w.current.value,t=I||"",n=""===t&&e;!w.current||S&&!n||(w.current.value=t)}},[S,y,I]);const $=d||b,{disabled:H,readOnly:L}=k,N=!(H||L),U=11/(0,i.ju)().fontSize,K=(0,a.useMemo)(()=>M?{width:`calc(100% / ${U})`,whiteSpace:"nowrap",transform:`translate3d(0, -7px, 0) scale(${U})`}:void 0,[M,U]);return a.createElement(g,{ref:T},!!$&&a.createElement(h,null,a.createElement(v,{css:K},`${$}${k.required?"*":""}`)),a.createElement(s.A,{message:z?null===(t=w.current)||void 0===t?void 0:t.validationMessage:j,visible:!!(z||j.length>0)&&N},a.createElement(R,Object.assign({},k,{ref:w,filled:M,editable:N,focused:S,invalid:z,onAnimationStart:V,onAnimationIteration:V,onFocus:P,onBlur:J,onChange:W,onInvalid:q,css:!!C&&{resize:"none"}}))))},(0,i.X6)({property:"background"}),{display:"inline-flex",marginBottom:0,color:({siteTheme:e})=>e.inputs.TextArea.color}),d=m;function p(e,t){return!!t||!e.validity.valid}function f(e){return!!e&&/[\S]/.test(e)}const g=o.I4.label({position:"relative",flex:{grow:1,shrink:0},maxWidth:"100%",fontSize:()=>(0,l.un6)()?"16px":void 0}),h=o.I4.div((0,i.O8)(),{position:"absolute",pointerEvents:"none",width:"100%",height:"100%",overflow:"hidden"}),v=o.I4.div((0,i.X6)({property:["transform","color","background-color"],duration:200}),{color:({siteTheme:e})=>e.inputs.TextArea.placeholderColor,transformOrigin:"top left",position:"relative"}),b=(0,o.I4)({width:"100%",padding:{xy:0},border:{xy:{width:0}},borderRadius:0,color:"inherit",backgroundColor:"transparent",":focus":{outlineWidth:0},cursor:"text"}),y=o.I4.textarea(b,(0,i.O8)(),(0,i.kY)({property:["color","border-color","background"]})),E=i.Y,x=i.as,C=(0,o.I4)({flexGrow:1,margin:{top:x,left:E}}),k=(0,o.I4)(m,C,{width:"100%"})},7410(e,t,n){n.d(t,{T:()=>a});var r=n(26166);function a(e,t,n,a){return(0,r.__awaiter)(this,void 0,void 0,function*(){const r=function(e){if(!e)return new FormData;const t=new FormData;return function e(t,n,r){Object.keys(n).forEach(a=>{const o=n[a],l=r?`${r}.${a}`:a;null!=o&&(o instanceof File?t.append(l,o):"object"==typeof o?e(t,o,l):t.append(l,String(o)))})}(t,e),t}(t),o=(Array.isArray(n)?n:[n]).filter(e=>e instanceof File),l=Array.isArray(n)?"attachments":"attachment";o.forEach(e=>r.append(l,e));const i=yield fetch(e,{method:"POST",body:r,headers:a});if(!i.ok){if(500===i.status)return Promise.reject("");const e=yield i.text();return Promise.reject(e)}return 204===i.status?null:yield i.json()})}}}]);
3//# sourceMappingURL=3497.chunk.71130ee7fde8c27297e4.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.