"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[665],{4665:function(e,n,r){r.r(n);var t=r(5893),c=r(7294),u=r(4460);var o=function(e){var n=(0,c.useRef)(null),r=e.rfb,o=e.url,i=e.viewOnly,s=e.focusOnClick,l=e.clipViewport,a=e.dragViewport,d=e.scaleViewport,v=e.resizeSession,f=e.showDotCursor,m=e.background,p=e.qualityLevel,w=e.compressionLevel,h=e.onDisconnect;(0,c.useEffect)((function(){return n.current?(r.current||(n.current.innerHTML="",r.current=new u.Z(n.current,o),r.current.viewOnly=i,r.current.focusOnClick=s,r.current.clipViewport=l,r.current.dragViewport=a,r.current.resizeSession=v,r.current.scaleViewport=d,r.current.showDotCursor=f,r.current.background=m,r.current.qualityLevel=p,r.current.compressionLevel=w,r.current.addEventListener("disconnect",h)),r.current?function(){r.current&&(r.current.disconnect(),r.current=void 0)}:void 0):function(){r.current&&(null===r||void 0===r||r.current.disconnect(),r.current=void 0)}}),[r]);return(0,t.jsx)("div",{style:{width:"100%",height:"75vh"},ref:n,onMouseEnter:function(){var e,n;document.activeElement&&(e=document.activeElement,null!=(n=HTMLElement)&&"undefined"!==typeof Symbol&&n[Symbol.hasInstance]?n[Symbol.hasInstance](e):e instanceof n)&&document.activeElement.blur(),(null===r||void 0===r?void 0:r.current)&&r.current.focus()}})};n.default=(0,c.memo)(o)}}]);