PageSourceSearch

https://static.3commas.io/3commas-website/_next/static/chunks/5872.654d89e7aff60ce8.js

js 3commas.io collected 2026-10-02 17:46:40 UTC 6,809 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5872],{5872:(e,t,r)=>{r.r(t),r.d(t,{AiVariation:()=>k});var n=r(10465),s=r(3177),l=r(53486),i=r(74045),c=r(80507),u=r(88949),a=r(15090),o=r(39821),m=r(73704),d=r.n(m),p=r(8125),h=r(81863),v=r(60780),x=r(91230);let f={src:"https://static.3commas.io/3commas-website/_next/static/media/ai-cursor.84243a67.svg"},g={src:"https://static.3commas.io/3commas-website/_next/static/media/bg-gradient.ca2ed184.svg",height:557,width:1564,blurWidth:0,blurHeight:0},j=e=>{let{actions:t,styles:r}=e;return(0,n.jsx)("div",{className:r.root,children:l.h2.group(t)?t.map(e=>(0,n.jsx)("div",{className:r.item,children:(0,n.jsx)(i.i,{field:e.icon})},e.icon.id)):null})},y=e=>{let{position:{x:t,y:r},text:s,styles:l}=e;return(0,n.jsx)("span",{role:"tooltip",className:l,style:{left:"".concat(t,"px"),top:"".concat(r,"px")},children:s})},w=e=>{let{slice:t}=e,{t:r}=(0,h.Bd)("main"),m=(0,c.b)(),{variation:w,primary:E}=t,{button_text:b=null,button_icon:L=null,ai_actions:N=null,hover_text:_=null,clevertap_submit_event_name:R=null,clevertap_focus_event_name:S=null,prompts:k=[]}=w===v.Sb.Ai?E:{},{sendClevertapEvent:T}=(0,a.E)(),C=(0,p.useRef)(null),M=(0,p.useRef)(null),B=(0,p.useRef)(null),z=(0,p.useRef)(!1),D=(0,p.useRef)(!1),[F,H]=(0,p.useState)(!1),[W,A]=(0,p.useState)(!1),[I,P]=(0,p.useState)(!1),[Q,V]=(0,p.useState)(""),[X,Y]=(0,p.useState)(!1),[U,$]=(0,p.useState)(!1),q=(0,p.useMemo)(()=>k.map(e=>String(e.prompt_text)),[k]),{cancel:G,restart:J,cancelled:K}=(e=>{let{textareaRef:t,prompts:r,onValueChange:n,enabled:s=!0}=e,l=(0,p.useRef)(null),i=(0,p.useRef)(!1),c=(0,p.useRef)(0),u=(0,p.useRef)(0),a=()=>{i.current=!0,l.current&&(clearTimeout(l.current),l.current=null)},o=e=>e.dispatchEvent(new Event("input",{bubbles:!0})),m=()=>{let e=t.current;if(!e)return a();c.current+=1,c.current>=r.length&&(c.current=0),n(""),o(e),u.current=0,l.current=setTimeout(d,15)},d=()=>{if(i.current)return;let e=t.current;if(!e||!r.length)return a();let s=r[c.current];u.current+=1,n(s.slice(0,u.current)),o(e),u.current>=s.length?l.current=setTimeout(m,1e3):l.current=setTimeout(d,15)};return(0,p.useEffect)(()=>{if(!s)return;let e=t.current;if(!e||!r.length||e.value.trim())return;i.current=!1,c.current=0,u.current=0;let n=e=>{e.isTrusted&&a()};return e.addEventListener("focus",n,{once:!0}),e.addEventListener("keydown",n,{once:!0}),e.addEventListener("pointerdown",n,{once:!0}),e.addEventListener("input",n,{once:!0}),l.current=setTimeout(d,15),()=>{e.removeEventListener("focus",n),e.removeEventListener("keydown",n),e.removeEventListener("pointerdown",n),e.removeEventListener("input",n),a()}},[r,t,n,s]),{cancel:a,cancelled:i,restart:()=>{let e=t.current;e&&r.length&&(a(),i.current=!1,c.current=0,u.current=0,n(""),o(e),l.current=setTimeout(d,15))}}})({textareaRef:C,prompts:q,onValueChange:V,enabled:U}),O=l.h2.keyText(_),Z=(0,s.z)(768),{position:ee,handleMouseMove:et}=(e=>{let{containerRef:t,enabled:r}=e,[n,s]=(0,p.useState)({x:0,y:0});return{position:n,handleMouseMove:(0,p.useCallback)((e,n)=>{let l=t.current;if(!r||!l)return;let i=l.getBoundingClientRect();s({x:e.clientX-i.left,y:e.clientY-i.top}),null==n||n(e)},[r,t])}})({enabled:U&&O&&!Z&&!I,containerRef:M}),er=(0,x.h)({theme:v.Qe.Transparent,variation:w,textareaFocused:F}).aiInput,en=Q.length>3e3,es=l.h2.keyText(b)&&l.h2.image(L),el=O&&!I&&!W&&X&&!Z,ei=el?"url(".concat(f.src,") 0 0, auto"):"text",ec=e=>{let t=B.current;return t&&t.contains(e)&&e!==t},eu=e=>{ec(e.target)?Y(!1):Y(!0)};return(0,u.B)(()=>$(!0),[]),(0,n.jsxs)("div",{ref:M,className:er.root,style:{cursor:ei},onMouseDown:e=>{!C.current||W||ec(e.target)?z.current=!1:(z.current=!0,G(),C.current.focus())},onMouseEnter:()=>{K.current||(G(),V("")),Y(!0)},onMouseLeave:()=>{Y(!1),W||I||J(),W&&(z.current=!1)},onMouseMove:e=>et(e,eu),children:[el?(0,n.jsx)(y,{position:ee,text:_,styles:er.cursorTooltip}):null,(0,n.jsxs)("form",{className:er.contentWrapper,onSubmit:e=>{e.preventDefault();let t=Q.trim().length?Q:q[0],r=new URL(m);r.searchParams.set("prompt",t),T(R,{prompt:t}),window.open(r.toString(),"_self")},children:[(0,n.jsx)("textarea",{value:Q,ref:C,className:er.textarea,name:"prompt",rows:2,style:{cursor:ei},onInput:e=>{let t=e.target;t.style.height="auto",t.style.height="".concat(t.scrollHeight,"px")},onBlur:e=>{let t=e.target;z.current?(t.focus(),z.current=!1):(t.value.length||I||D.current||J(),A(!1),D.current=!1)},onFocus:()=>{T(S),H(!0),A(!0),I||V("")},onChange:e=>{V(e.target.value),P(!0)}}),(0,n.jsxs)("div",{className:er.controlsRow.root,ref:B,children:[(0,n.jsxs)("div",{className:er.controlsRow.actionsWrapper,children:[l.h2.group(N)?(0,n.jsx)(j,{styles:er.controlsRow.actions,actions:N}):null,en?(0,n.jsx)("p",{className:er.charactersLimit,children:r("main.characters_limit",{limit:3e3})}):null]}),es?(0,n.jsx)(o.$n,{className:er.controlsRow.button,disabled:en,onClick:()=>D.current=!0,icon:(0,n.jsx)(i.i,{field:L}),children:b}):null]})]}),(0,n.jsx)("div",{className:er.gradient,children:(0,n.jsx)(d(),{src:g,alt:"",fill:!0})})]})};var E=r(48256),b=r.n(E);let L=e=>{let{containerRef:t}=e,r=(0,s.z)(1024),l=(0,p.useRef)(null),[i,c]=(0,p.useState)(!1),[u,a]=(0,p.useState)({x:"50%",y:"50%"});return((0,p.useEffect)(()=>{let e=t.current;if(!l.current||!e||r)return;let n=!1,s=e=>{n=e,c(e)},i=t=>{if(!n)return;let r=e.getBoundingClientRect(),s=(t.clientX-r.left)/r.width*100,l=(t.clientY-r.top)/r.height*100;a({x:"".concat(s,"%"),y:"".concat(l,"%")})},u=e=>{s(!0),i(e)},o=()=>s(!1),m=()=>document.hidden?s(!1):s(!0);return e.addEventListener("pointermove",i),e.addEventListener("pointerenter",u),e.addEventListener("pointerleave",o),document.addEventListener("visibilitychange",m),()=>{e.removeEventListener("pointermove",i),e.removeEventListener("pointerenter",u),e.removeEventListener("pointerleave",o),document.removeEventListener("visibilitychange",m)}},[r,t]),r)?null:(0,n.jsx)("div",{ref:l,style:{"--hole-x":u.x,"--hole-y":u.y},className:b()("spotlight",{active:i})})};var N=r(72046),_=r(97576),R=r(61706);let S=e=>{let{slice:t,styles:r}=e,{primary:s}=t,{title:l,theme:i}
1=s,c=i===v.Qe.Dark?"primaryDark":"primaryLight";return(0,n.jsx)(_.H,{className:r.wrapper,children:(0,n.jsx)(R.a,{field:l,color:c,className:r.title})})},k=e=>{let{slice:t,containerRef:r,styles:c}=e,{primary:u}=t,{image:a,mobile_image:o}=u,m=(0,s.z)(1024)?o:a;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(L,{containerRef:r}),(0,n.jsxs)("div",{className:c.wrapper,children:[(0,n.jsx)(S,{styles:c.content,slice:t}),(0,n.jsx)(w,{slice:t}),(0,n.jsx)(N.d,{styles:c.content,slice:t})]}),(0,n.jsx)(()=>l.h2.image(m)?(0,n.jsx)("div",{className:c.image.wrapper,children:(0,n.jsx)(i.i,{className:c.image.img,field:m,sizes:"(max-width: 500px) 1000px, (max-width: 768px) 1770px, 3000px",fetchPriority:"high",priority:!0})}):null,{})]})}}}]);

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.