"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7502],{77502:(r,e,n)=>{n.r(e),n.d(e,{default:()=>a});var t=n(50245),o=n(29766);function l(){return(l=Object.assign||function(r){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var t in n)Object.prototype.hasOwnProperty.call(n,t)&&(r[t]=n[t])}return r}).apply(this,arguments)}let a=(0,t.memo)(function(r){var e=r.children,n=r.math,a=r.block,s=r.errorColor,i=r.renderError,c=r.settings,u=r.as,f=function(r,e){if(null==r)return{};var n,t,o={},l=Object.keys(r);for(t=0;t<l.length;t++)e.indexOf(n=l[t])>=0||(o[n]=r[n]);return o}(r,["children","math","block","errorColor","renderError","settings","as"]),h=null!=e?e:n,d=(0,t.useState)({innerHtml:""}),m=d[0],E=d[1];return(0,t.useEffect)(function(){try{var r=o.default.renderToString(h,l({displayMode:!!a,errorColor:s,throwOnError:!!i},c));E({innerHtml:r})}catch(r){if(!(r instanceof o.default.ParseError||r instanceof TypeError))throw r;E(i?{errorElement:i(r)}:{innerHtml:r.message})}},[a,h,s,i,c]),"errorElement"in m?m.errorElement:t.createElement(u||(a?"div":"span"),Object.assign({},f,{dangerouslySetInnerHTML:{__html:m.innerHtml}}))})}}]);