PageSourceSearch

https://mathai.ai/_next/static/chunks/3001.a537a9e18c9257fd.js

js mathai.ai collected 2026-10-05 12:17:15 UTC 14,195 bytes, 2 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3001],{93001:function(e,n,t){t.r(n),t.d(n,{default:function(){return E}});var i=t(47568),o=t(828),l=t(29815),r=t(97582),a=t(85893),s=t(67294),u=t(45090),d=t(50081),c=t(68458),v=t(26042),p=t(69396),f=t(75173),x=[!0,"true","1",1],h={color:"rgb(0, 0, 0)",textDecoration:"none",fontFamily:"Epilogue",fontSize:"16px",fontWeight:400},m=function(e){var n,t,i,o,l,r,s,d,c,m,b,g,y,_,k=e.button,w=e.componentIndex,S=e.clusterIndex,I=e.index,D=x.includes(null===k||void 0===k||null===(n=k.props)||void 0===n||null===(t=n.iconVisible)||void 0===t?void 0:t.value),j=null===k||void 0===k||null===(i=k.props)||void 0===i||null===(o=i.icon)||void 0===o||null===(l=o.value)||void 0===l?void 0:l.asset,C=null===k||void 0===k||null===(r=k.props)||void 0===r||null===(s=r.input_background)||void 0===s||null===(d=s.value)||void 0===d?void 0:d.color,M=x.includes(null===k||void 0===k||null===(c=k.props)||void 0===c||null===(m=c.textVisible)||void 0===m?void 0:m.value),E=null===k||void 0===k||null===(b=k.props)||void 0===b||null===(g=b.text)||void 0===g?void 0:g.value,Z=null===k||void 0===k||null===(y=k.props)||void 0===y||null===(_=y.events)||void 0===_?void 0:_.value;return(0,a.jsxs)("div",{style:{height:"43px",minWidth:"52px",maxWidth:"328px",flexShrink:0,padding:"4px",borderRadius:"2px",position:"initial",borderColor:"rgb(79, 79, 79)",borderWidth:"0.5px",background:null!==C&&void 0!==C?C:"rgb(249, 248, 248)",justifyContent:"flex-start",alignItems:"center",columnGap:"10px",display:"flex",overflow:"hidden",cursor:"pointer"},onClick:function(){null===Z||void 0===Z||Z.forEach((function(e){u.Z.emit(e.event,(0,p.Z)((0,v.Z)({},e,e.data),{componentIndex:w,clusterIndex:e.index}))}))},id:"component_".concat(w,"_cluster_").concat(S,"_").concat(I),children:[D&&(0,a.jsx)("div",{style:{width:"23px",height:"23px",minWidth:"23px",flexShrink:0,position:"initial",opacity:1,background:"url(".concat(j,") center center / cover")}}),M&&(0,a.jsxs)("div",{style:{minWidth:"20px",maxWidth:"280px",flexShrink:0,padding:"7px 4px",position:"initial",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",gap:"4px",display:"flex"},children:[(0,a.jsx)("div",{}),(0,f.jG)(null!==E&&void 0!==E?E:[],{textStyle:h,handleUpdateDescriptionAssetsLoaded:function(){}})]})]})},b=function(e){var n=e.cluster,t=e.componentIndex,i=e.clusterIndex;return(0,a.jsx)("div",{style:{minWidth:"5px",maxWidth:"320px",flexShrink:0,position:"initial",flexDirection:"column",justifyContent:"flex-start",alignItems:"center",display:"flex"},children:(0,a.jsx)("div",{style:{minWidth:"360px",flexShrink:0,position:"initial",flexDirection:"column",justifyContent:"flex-start",alignItems:"flex-start",gap:"10px",display:"flex"},children:(0,a.jsx)("div",{style:{width:"360px",minWidth:"360px",flexShrink:0,padding:"16px 24px",position:"initial",placeContent:"center flex-end",alignItems:"center",gap:"12px",display:"flex",flexWrap:"wrap"},children:n.buttons_list.map((function(e,n){return(0,a.jsx)(m,{button:e,index:n,componentIndex:t,clusterIndex:i},n)}))})})})},g=t(60887),y=t(68390),_=t(44793),k=t(21627),w=t(75209),S=t(79804),I=t(25707),D=t(5152),j=t.n(D)()((function(){return Promise.resolve().then(t.bind(t,24588))}),{ssr:!1});function C(e){for(var n,t,i,o,l,r,a=e.collisionRect,s=e.droppableRects,u=e.droppableContainers,d=e.active,c=null===d||void 0===d||null===(n=d.data)||void 0===n||null===(t=n.current)||void 0===t?void 0:t.topLeftCorner,v=a.top,p=a.left,f=a.width,x=void 0===f?0:f,h={top:v+(null!==(i=null===c||void 0===c?void 0:c.top)&&void 0!==i?i:0),left:p+(null!==(o=null===c||void 0===c?void 0:c.left)&&void 0!==o?o:0)},m={top:v+(null!==(l=null===c||void 0===c?void 0:c.top)&&void 0!==l?l:0),left:p+x+(null!==(r=null===c||void 0===c?void 0:c.left)&&void 0!==r?r:0)},b=1/0,g=null,y=null,_=0;_<u.length;_++){var k,w,S=u[_];if("droparea"!==(null===S||void 0===S||null===(k=S.data)||void 0===k||null===(w=k.current)||void 0===w?void 0:w.type)){var I=s.get(S.id);if(I){var D=Math.sqrt(Math.pow(h.left-I.left,2)+Math.pow(h.top-I.top,2));D<b&&(b=D,g=S)}}else y=S}if(g&&b<50)return[{id:g.id,data:{droppableContainer:g}}];if(b>100&&y)return[{id:y.id,data:{droppableContainer:y}}];if(y){var j=s.get(y.id);if(j){var C=function(e){var n=Math.max(j.left,Math.min(j.left+j.width,e.left));return Math.sqrt(Math.pow(e.left-n,2)+Math.pow(e.top-j.top,2))},M=C(h),E=C(m);if(Math.min(M,E)<100)return[{id:y.id,data:{droppableContainer:y}}]}}return g&&b<100?[{id:g.id,data:{droppableContainer:g}}]:[]}function M(e){var n,t,i,o,l=e.transform,r=e.active,a=null===r||void 0===r||null===(n=r.data)||void 0===n||null===(t=n.current)||void 0===t||null===(i=t.modifiers)||void 0===i?void 0:i.sliderRestrictions;if(!Array.isArray(a))return console.log("slider restrictions",a),console.warn("No valid sliderRestrictions foun
1d, returning original transform."),l;o=Math.abs(l.x)>Math.abs(l.y)?l.x>0?"right":"left":l.y>0?"bottom":"top";var s=null;if(a.forEach((function(e){var n=e.dx,t=e.dy;("right"===o&&n>0||"left"===o&&n<0||"bottom"===o&&t>0||"top"===o&&t<0)&&(!s||Math.abs(n||t)>Math.abs(s.dx||s.dy))&&(s=e)})),!s)return{x:0,y:0};var u=s.dx,d=s.dy,c=Math.sqrt(u*u+d*d),v=u/c,p=d/c,f=l.x*v+l.y*p,x=Math.max(0,Math.min(f,c));return{x:v*x,y:p*x}}var E=s.memo((function(e){var n=e.component,t=e.componentIndex,v=e.isPreview,p=e.isDisabled,f=e.path,x=e.noBadge,h=e.isAnswerRenderer,m=e.roundData,D=e.block_id,E=(n.cluster_settings,(0,o.Z)(s.useState(!1),2)),Z=E[0],P=E[1],N=(0,o.Z)(s.useState(!1),2),W=N[0],R=(N[1],(0,s.useRef)(null)),T=(0,o.Z)(s.useState(!1),2),F=T[0],A=T[1],B=((0,s.useRef)({}),(0,o.Z)(s.useState(!1),2)),O=B[0],z=(B[1],(0,o.Z)(s.useState(!0),2)),L=z[0],G=(z[1],(0,s.useMemo)((function(){var e,t,i;return{isDisabled:null!==(e=n.component_settings.disable_interaction)&&void 0!==e&&e,showInPreview:null!==(t=n.component_settings.show_in_preview)&&void 0!==t&&t,skipEvaluation:null!==(i=n.component_settings.skip_evaluation)&&void 0!==i&&i}}),[t])),V=G.isDisabled,q=G.showInPreview,H=G.skipEvaluation,J=(0,s.useMemo)((function(){var e,t,i,o,l;return{evaluationType:null===n||void 0===n||null===(e=n.evaluation_config)||void 0===e?void 0:e.evaluation_type,feedbackType:null===n||void 0===n||null===(t=n.evaluation_config)||void 0===t?void 0:t.feedback_type,hasFeedbackFill:null===n||void 0===n||null===(i=n.evaluation_config)||void 0===i?void 0:i.has_feedback_fill,hasFeedbackStroke:null===n||void 0===n||null===(o=n.evaluation_config)||void 0===o?void 0:o.has_feedback_stroke,hasHighlight:null===n||void 0===n||null===(l=n.evaluation_config)||void 0===l?void 0:l.has_highlight}}),[t]),Y=J.evaluationType,K=J.feedbackType,U=(J.hasFeedbackFill,J.hasFeedbackStroke),Q=J.hasHighlight,X=(0,s.useMemo)((function(){return!V&&!p&&!v}),[V,p,v,F]);(0,s.useEffect)((function(){function e(e){return a.apply(this,arguments)}function a(){return a=(0,i.Z)((function(e){var i,a,s,c,v,p,f,x,h,m,b,g,y,_;return(0,r.__generator)(this,(function(k){switch(k.label){case 0:return i=e.componentIndex,a=e.resolve,s=e.isPreRun,c=e.isPartialSubmit,i!=t?[2]:H?(null===a||void 0===a||a(),[2]):s?(v=[],"ONE_BY_ONE"!==Y&&Y||n.clusters.map((function(e,i){if("table_collection"===(null===e||void 0===e?void 0:e.type))return u.Z.emit("table_evaluation_component_".concat(t,"_cluster_").concat(i),{isPreRun:!0,isPartialSubmit:c,feedbackPool:n.feedbackPool,resolve:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];v=(0,l.Z)(v).concat((0,l.Z)(e))}})})),console.log("sounds:::",JSON.parse(JSON.stringify(v))),null===a||void 0===a||a(v),[2]):(P(!1),p=n.functions.find((function(e){return"updateStartFeedbackPool"===e.name})),f=(0,d.mj)(p,[[],n.feedbackPool],{componentIndex:t,clusterIndex:null}),[4,(0,d.MK)(R.current,{isAwait:!0})]);case 1:if(k.sent(),"ONE_BY_ONE"!==Y&&Y)return[3,9];x=!0,h=!1,m=void 0,k.label=2;case 2:k.trys.push([2,7,8,9]),b=function(){var e,n,i;return(0,r.__generator)(this,(function(l){switch(l.label){case 0:return e=(0,o.Z)(y.value,2),n=e[0],"table_collection"!==(null===(i=e[1])||void 0===i?void 0:i.type)?[3,2]:[4,new Promise((function(e){u.Z.emit("table_evaluation_component_".concat(t,"_cluster_").concat(n),{isPreRun:!1,feedbackPool:f,isPartialSubmit:c,resolve:e})}))];case 1:l.sent(),l.label=2;case 2:return[2]}}
1))},g=n.clusters.entries()[Symbol.iterator](),k.label=3;case 3:return(x=(y=g.next()).done)?[3,6]:[5,(0,r.__values)(b())];case 4:k.sent(),k.label=5;case 5:return x=!0,[3,3];case 6:return[3,9];case 7:return _=k.sent(),h=!0,m=_,[3,9];case 8:try{x||null==g.return||g.return()}finally{if(h)throw m}return[7];case 9:return P(U),a&&a(),[2]}}))})),a.apply(this,arguments)}return u.Z.on("evaluation",e),function(){u.Z.off("evaluation",e)}}),[t,H,Q,K,Y,n]),(0,s.useEffect)((function(){if(!h){u.Z.emit("update_components_loaded",{componentIndex:t,value:!0});var e=function(){var e=(0,i.Z)((function(e){return(0,r.__generator)(this,(function(e){switch(e.label){case 0:return[4,(0,_.gw)(2e3)];case 1:return e.sent(),V||p||v?[2]:document.querySelector('div[style*="pointer-events: none"] [aria-roledescription="draggable"]')?(I.j.track("interaction_auto_enabled",{component:"table",isDisabled:V,isPreview:v,isGlobalDisabled:p,componentIndex:t}),A((function(e){return!e})),[2]):[2]}}))}));return function(n){return e.apply(this,arguments)}}();return u.Z.on("check_disabled",e),function(){u.Z.off("check_disabled",e)}}}),[]);var $=(0,k.usePullToRefreshContext)().setIsDragged,ee=(0,g.VT)(g.MA,{activationConstraint:{distance:5}}),ne=(0,g.VT)(g.LO,{activationConstraint:{distance:5,delay:(0,y.gn)()?300:0,tolerance:(0,y.gn)()?300:150},bypassActivationConstraint:function(e){var n=e.activeNode,t=e.event,i=e.options;return console.log("bypassActivationConstraint"+(null===t||void 0===t?void 0:t.type),n,i,t),!1}}),te=(0,g.VT)(g.Lg),ie=(0,g.Dy)(ee,ne,te),oe=(0,s.useMemo)((function(){return n.clusters.some((function(e){var n,t,i;return"table_collection"===(null===e||void 0===e?void 0:e.type)&&(null===e||void 0===e||null===(n=e.tableData)||void 0===n||null===(t=n.value)||void 0===t||null===(i=t.puzzle)||void 0===i?void 0:i.enabled)}))}),[n.clusters]),le=(0,s.useMemo)((function(){return!!oe&&n.clusters.some((function(e){var n,t,i,o;return"table_collection"===(null===e||void 0===e?void 0:e.type)&&(null===e||void 0===e||null===(n=e.tableData)||void 0===n||null===(t=n.value)||void 0===t||null===(i=t.puzzle)||void 0===i||null===(o=i.slider)||void 0===o?void 0:o.enabled)}))}),[n.clusters,oe]);if(v&&!q||!L)return null;var re=(0,a.jsx)(a.Fragment,{children:n.clusters.map((function(e,i){switch(null===e||void 0===e?void 0:e.type){case"table_collection":var o;return(0,a.jsx)(j,{cluster:e,componentIndex:t,clusterIndex:i,clusterFunctions:n.clusterFunctions,clusterSettings:n.clusterSettings,isDisabled:!X,isDisabledPermanently:V,isGlobalDisabled:p,skipEvaluation:null!==(o=n.component_settings.skip_evaluation)&&void 0!==o&&o,path:(0,l.Z)(f).concat(["clusters",i]),noBadge:x,isAnswerRenderer:h,roundData:m,block_id:D},"component_".concat(t,"_cluster_").concat(i));case"tags_collection":return(null===e||void 0===e?void 0:e.isClusterVisible)?(0,a.jsx)(c.Z,{cluster:e,componentIndex:t,clusterIndex:i,isDisabled:!X}):null;case"buttons_collection":return(0,a.jsx)(b,{cluster:e,componentIndex:t,clusterIndex:i,isDisabled:!X});default:return(0,a.jsx)(a.Fragment,{})}}))}),ae=function(e){$(!1),w.Z.handleOnDragEnd(e)};return(0,a.jsx)("div",{style:{visibility:"visible",position:"inherit",zIndex:1,pointerEvents:"auto",opacity:1,marginBottom:"8px"},className:"w-full",children:(0,a.jsx)("div",{id:"tailwind_main",className:"relative flex justify-center",children:(0,a.jsx)("div",{ref:R,style:{minWidth:"320px",maxWidth:"502px",flexShrink:"0",position:"initial",flexDirection:"column",justifyContent:"flex-start",alignItems:"center",display:"flex",pointerEvents:X?"auto":"none"},children:(0,a.jsx)("div",{style:{pointerEvents:X||h?"auto":"none",width:h?"fit-content":"320px",minWidth:"320px",maxWidth:"502px",flexShrink:0,position:"initial",flexDirection:"column",justifyContent:"flex-start",alignItems:"center",rowGap:"40px",display:"flex",alignSelf:"center",border:Z?"2px solid ".concat(O?"#219653":"#EB5757"):"none",boxShadow:W?"0px 0px 4px 2px #000fff":"none"},children:oe?(0,a.jsxs)(g.LB,{sensors:ie,onDragMove:function(e){$(!0),w.Z.handleOnDragMove(e)},onDragCancel:ae,onDragEnd:ae,collisionDetection:C,autoScroll:{enabled:!1,layoutShiftCompensation:!1},modifiers:le?[M]:[],children:[re,(0,a.jsx)(S.default,{})]}):re})})})})}))},79804:function(e,n,t){t.r(n);var i=t(26042),o=t(85893),l=t(67294),r=t(60887),a=t(14643),s=t(89068);n.default=function(){var e=(0,l.useState)(null),n=e[0],t=e[1],u=(0,l.useState)(!1),d=u[0],c=u[1];(0,r.IJ)({onDragStart:function(e){var n,i,o,l,r,a,u=null===(n=e.active)||void 0===n||null===(i=n.data)||void 0===i||null===(o=i.current)||void 0===o?void 0:o.elementId,d=null===(l=e.active)||void 0===l||null===(r=l.data)||void 0===r||null===(a=r.current)||void 0===a?void 0:a.isPuzzlePiece;if(d){var v=document.getElementById(u),p=null===v||void 0===v?void 0:v.cloneNode(!0);if(p){var f=window.getComputedStyle(v);p.style.cssText=f.cssText}if(!p)return;p.style.visibility="visible",p.id="drag-overlay-item",t(p)}else{var x,h=null===(x=document.getElementById(u))||void 0===x?void 0:x.cloneNode(!0);if(!h)return;h.style.visibility="visible",h.id="drag-overlay-item",t(h)}!d&&setTimeout((function(){return c(!0)}),50),(0,s.pauseScroll)()},onDragEnd:function(){return v()},onDragCancel:function(){return v()}});var v=function(){if(!a.G.isDisabled){(0,s.resumeScroll)(),c(!1),null===n||void 0===n||n.remove(),t(null);var e=document.getElementById("drag-overlay-html-container");if(e&&e.parentNode){for(;e.firstChild;)e.removeChild(e.firstChild);e.parentNode.removeChild(e)}}};(0,l.useEffect)((function(){return function(){return v()}}),[]);var p={transition:d?"transform 0.2s ease-in-out":void 0,transform:d?"scale(1.2)":void 0,boxShadow:d?"0 0 10px 0 rgba(0, 0, 0, 0.1)":void 0};return(0,o.jsx)(r.y9,{dropAnimation:null,children:(0,o.jsx)("div",{id:"drag-overlay-html-container",style:(0,i.Z)({},p),dangerouslySetInnerHTML:{__html:null===n||void 0===n?void 0:n.outerHTML}})})}}}]);
2//# sourceMappingURL=3001.a537a9e18c9257fd.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.