!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var r=e();for(var o in r)("object"==typeof exports?exports:t)[o]=r[o]}}(window,function(){return function(t){var e={};function r(o){if(e[o])return e[o].exports;var n=e[o]={i:o,l:!1,exports:{}};return t[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=t,r.c=e,r.d=function(t,e,o){r.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:o})},r.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.t=function(t,e){if(1&e&&(t=r(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)r.d(o,n,function(e){return t[e]}.bind(null,n));return o},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=10)}([function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(){function t(){}return t.createRect=function(e,r,o){var n=document.createElementNS("http://www.w3.org/2000/svg","rect");return n.setAttribute("width",e.toString()),n.setAttribute("height",r.toString()),o&&t.setAttributes(n,o),n},t.createLine=function(e,r,o,n,i){var s=document.createElementNS("http://www.w3.org/2000/svg","line");return s.setAttribute("x1",e.toString()),s.setAttribute("y1",r.toString()),s.setAttribute("x2",o.toString()),s.setAttribute("y2",n.toString()),i&&t.setAttributes(s,i),s},t.createPolygon=function(e,r){var o=document.createElementNS("http://www.w3.org/2000/svg","polygon");return o.setAttribute("points",e),r&&t.setAttributes(o,r),o},t.createCircle=function(e,r){var o=document.createElementNS("http://www.w3.org/2000/svg","circle");return o.setAttribute("cx",(e/2).toString()),o.setAttribute("cy",(e/2).toString()),o.setAttribute("r",e.toString()),r&&t.setAttributes(o,r),o},t.createGroup=function(e){var r=document.createElementNS("http://www.w3.org/2000/svg","g");return e&&t.setAttributes(r,e),r},t.setAttributes=function(t,e){for(var r=0,o=e;ra)&&void 0===t.nsecs&&(v=0),v>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");a=f,c=v,n=d;var g=(1e4*(268435455&(f+=122192928e5))+v)%4294967296;u[l++]=g>>>24&255,u[l++]=g>>>16&255,u[l++]=g>>>8&255,u[l++]=255&g;var b=f/4294967296*1e4&268435455;u[l++]=b>>>8&255,u[l++]=255&b,u[l++]=b>>>24&15|16,u[l++]=b>>>16&255,u[l++]=d>>>8|128,u[l++]=255&d;for(var w=0;w<6;++w)u[l+w]=p[w];return e||s(u)}},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(17),s=r(5),a=r(6),c=r(0),l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.MIN_SIZE=5,e.CB_DISTANCE=10,e.addControlBox=function(){e.controlBox=c.SvgHelper.createGroup([["class","fc-whiteboard-rect-control-box"]]);var t=c.SvgHelper.createTransform();t.setTranslate(-e.CB_DISTANCE/2,-e.CB_DISTANCE/2),e.controlBox.transform.baseVal.appendItem(t),e.addToVisual(e.controlBox),e.controlRect=c.SvgHelper.createRect(e.width+e.CB_DISTANCE,e.height+e.CB_DISTANCE,[["class","fc-whiteboard-rect-control-rect"]]),e.controlBox.appendChild(e.controlRect),e.controlGrips=new i.RectangularMarkerGrips,e.addControlGrips()},e.adjustControlBox=function(){e.controlRect.setAttribute("width",(e.width+e.CB_DISTANCE).toString()),e.controlRect.setAttribute("height",(e.height+e.CB_DISTANCE).toString()),e.positionGrips()},e.addControlGrips=function(){e.controlGrips.topLeft=e.createGrip(),e.controlGrips.topCenter=e.createGrip(),e.controlGrips.topRight=e.createGrip(),e.controlGrips.centerLeft=e.createGrip(),e.controlGrips.centerRight=e.createGrip(),e.controlGrips.bottomLeft=e.createGrip(),e.controlGrips.bottomCenter=e.createGrip(),e.controlGrips.bottomRight=e.createGrip(),e.positionGrips()},e.createGrip=function(){var t=new a.ResizeGrip;return t.visual.transform.baseVal.appendItem(c.SvgHelper.createTransform()),e.controlBox.appendChild(t.visual),t.visual.addEventListener("mousedown",e.gripMouseDown),t.visual.addEventListener("mousemove",e.gripMouseMove),t.visual.addEventListener("mouseup",e.gripMouseUp),t.visual.addEventListener("touchstart",e.onTouch,{passive:!1}),t.visual.addEventListener("touchend",e.onTouch,{passive:!1}),t.visual.addEventListener("touchmove",e.onTouch,{passive:!1}),t},e.positionGrips=function(){var t=e.controlGrips.topLeft.GRIP_SIZE,r=-t/2,o=r,n=(e.width+e.CB_DISTANCE)/2-t/2,i=(e.height+e.CB_DISTANCE)/2-t/2,s=e.height+e.CB_DISTANCE-t/2,a=e.width+e.CB_DISTANCE-t/2;e.positionGrip(e.controlGrips.topLeft.visual,r,o),e.positionGrip(e.controlGrips.topCenter.visual,n,o),e.positionGrip(e.controlGrips.topRight.visual,a,o),e.positionGrip(e.controlGrips.centerLeft.visual,r,i),e.positionGrip(e.controlGrips.centerRight.visual,a,i),e.positionGrip(e.controlGrips.bottomLeft.visual,r,s),e.positionGrip(e.controlGrips.bottomCenter.visual,n,s),e.positionGrip(e.controlGrips.bottomRight.visual,a,s)},e.positionGrip=function(t,e,r){var o=t.transform.baseVal.getItem(0);o.setTranslate(e,r),t.transform.baseVal.replaceItem(o,0)},e.gripMouseDown=function(t){e.isResizing=!0,e.activeGrip=e.controlGrips.findGripByVisual(t.target)||null,e.previousMouseX=t.screenX,e.previousMouseY=t.screenY,t.stopPropagation()},e.gripMouseUp=function(t){e.isResizing=!1,e.activeGrip=null,t.stopPropagation()},e.gripMouseMove=function(t){e.isResizing&&e.manipulate(t)},e}return n(e,t),e.prototype.endManipulation=function(){t.prototype.endManipulation.call(this),this.isResizing=!1,this.activeGrip=null},e.prototype.select=function(){t.prototype.select.call(this),this.controlBox.style.display=""},e.prototype.deselect=function(){t.prototype.deselect.call(this),this.controlBox.style.display="none"},e.prototype.setup=function(){t.prototype.setup.call(this),this.addControlBox(),this.page&&"mirror"===this.page.mode&&(this.controlBox.style.display="none")},e.prototype.resizeByEvent=function(t,e,r){this.activeGrip=this.controlGrips[r],this.resize(t,e)},e.prototype.resize=function(t,e,r){var o=0,n=0;switch(this.activeGrip){case this.controlGrips.topLeft:this.width-=t,this.height-=e,o+=t,n+=e,r&&r("topLeft");break;case this.controlGrips.bottomLeft:this.width-=t,this.height+=e,o+=t,r&&r("bottomLeft");break;case this.controlGrips.topRight:this.width+=t,this.height-=e,n+=e,r&&r("topRight");break;case this.controlGrips.bottomRight:this.width+=t,this.height+=e,r&&r("bottomRight");break;case this.controlGrips.centerLeft:this.width-=t,o+=t,r&&r("centerLeft");break;case this.controlGrips.centerRight:this.width+=t,r&&r("centerRight");break;case this.controlGrips.topCenter:this.height-=e,n+=e,r&&r("topCenter");break;case this.controlGrips.bottomCenter:this.height+=e,r&&r("bottomCenter")}if(this.width\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(5),s=r(6),a=r(0),c=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.MIN_LENGTH=20,e.x1=0,e.y1=0,e.x2=e.width,e.y2=0,e.getLineLength=function(t,e,r,o){var n=Math.abs(t-r),i=Math.abs(e-o);return Math.sqrt(Math.pow(n,2)+Math.pow(i,2))},e.addControlBox=function(){e.controlBox=a.SvgHelper.createGroup([["class","fc-whiteboard-line-control-box"]]),e.addToVisual(e.controlBox),e.addControlGrips()},e.adjustControlBox=function(){e.positionGrips()},e.addControlGrips=function(){e.controlGrips={left:e.createGrip(),right:e.createGrip()},e.positionGrips()},e.createGrip=function(){var t=new s.ResizeGrip;return t.visual.transform.baseVal.appendItem(a.SvgHelper.createTransform()),e.controlBox.appendChild(t.visual),t.visual.addEventListener("mousedown",e.gripMouseDown),t.visual.addEventListener("mousemove",e.gripMouseMove),t.visual.addEventListener("mouseup",e.gripMouseUp),t.visual.addEventListener("touchstart",e.onTouch,{passive:!1}),t.visual.addEventListener("touchend",e.onTouch,{passive:!1}),t.visual.addEventListener("touchmove",e.onTouch,{passive:!1}),t},e.positionGrips=function(){var t=e.controlGrips.left.GRIP_SIZE,r=e.x1-t/2,o=e.y1-t/2,n=e.x2-t/2,i=e.y2-t/2;e.positionGrip(e.controlGrips.left.visual,r,o),e.positionGrip(e.controlGrips.right.visual,n,i)},e.positionGrip=function(t,e,r){var o=t.transform.baseVal.getItem(0);o.setTranslate(e,r),t.transform.baseVal.replaceItem(o,0)},e.gripMouseDown=function(t){e.isResizing=!0,e.activeGrip=t.target===e.controlGrips.left.visual?e.controlGrips.left:e.controlGrips.right,e.previousMouseX=t.screenX,e.previousMouseY=t.screenY,t.stopPropagation()},e.gripMouseUp=function(t){e.isResizing=!1,e.activeGrip=null,t.stopPropagation()},e.gripMouseMove=function(t){e.isResizing&&e.resize(t.movementX,t.movementY)},e}return n(e,t),e.prototype.endManipulation=function(){t.prototype.endManipulation.call(this),this.isResizing=!1,this.activeGrip=null},e.prototype.select=function(){t.prototype.select.call(this),this.controlBox.style.display=""},e.prototype.deselect=function(){t.prototype.deselect.call(this),this.controlBox.style.display="none"},e.prototype.setup=function(){t.prototype.setup.call(this),this.markerBgLine=a.SvgHelper.createLine(0,0,this.x2,0,[["stroke","transparent"],["stroke-width","30"]]),this.addToRenderVisual(this.markerBgLine),this.markerLine=a.SvgHelper.createLine(0,0,this.x2,0),this.addToRenderVisual(this.markerLine),this.addControlBox(),this.page&&"mirror"===this.page.mode&&(this.controlBox.style.display="none")},e.prototype.resize=function(t,e,r){this.activeGrip&&(this.activeGrip===this.controlGrips.left&&this.getLineLength(this.x1+t,this.y1+1,this.x2,this.y2)>=this.MIN_LENGTH?(this.x1+=t,this.y1+=e,this.markerBgLine.setAttribute("x1",this.x1.toString()),this.markerBgLine.setAttribute("y1",this.y1.toString()),this.markerLine.setAttribute("x1",this.x1.toString()),this.markerLine.setAttribute("y1",this.y1.toString()),r&&r("left")):this.activeGrip===this.controlGrips.right&&this.getLineLength(this.x1,this.y1,this.x2+t,this.y2+e)>=this.MIN_LENGTH&&(this.x2+=t,this.y2+=e,this.markerBgLine.setAttribute("x2",this.x2.toString()),this.markerBgLine.setAttribute("y2",this.y2.toString()),this.markerLine.setAttribute("x2",this.x2.toString()),this.markerLine.setAttribute("y2",this.y2.toString()),r&&r("right"))),this.adjustControlBox()},e.prototype.resizeByEvent=function(t,e,r){this.activeGrip="left"===r?this.controlGrips.left:this.controlGrips.right,this.resize(t,e)},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(i.BaseMarker);e.LinearMarker=c},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=r(11);e.Drawboard=o.Drawboard},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(12),s=r(15),a=r(32),c=r(34);r(36);var l=function(t){function e(e,r){var o=void 0===r?{}:r,n=o.page,i=o.onChange,l=t.call(this,e)||this;return l.scale=1,l.onComplete=function(){},l.onChange=function(){},l.open=function(t,e){t&&(l.onComplete=t),e&&(l.onCancel=e),l.setTargetRect(),l.initBoard(),l.attachEvents(),l.setStyles(),window.addEventListener("resize",l.adjustUI),"master"===l.page.mode&&l.showUI()},l.hide=function(){l.source.imgSrc&&(l.target.style.display="none"),l.boardHolder.style.opacity="0",l.boardHolder.style.zIndex="-1",l.toolbar&&l.toolbar.hide()},l.show=function(){l.source.imgSrc&&(l.target.style.display="block"),l.boardHolder.style.opacity="1",l.boardHolder.style.zIndex="9999",l.toolbar&&l.toolbar.show()},l.close=function(){l.toolbarUI&&document.body.removeChild(l.toolbarUI),l.boardCanvas&&document.body.removeChild(l.boardHolder)},l.render=function(t,e){l.onComplete=t,e&&(l.onCancel=e),l.selectMarker(null),l.startRender(l.renderFinished)},l.addMarker=function(t,e){var r=(void 0===e?{}:e).id,o=t.createMarker(l.page);if(r&&(o.id=r),o.onSelected=l.selectMarker,o.onChange=l.onChange,o.defs&&o.defs.length>0)for(var n=0,i=o.defs;n0&&(l.activeMarker.deselect(),l.activeMarker=null)},l.mouseMove=function(t){l.activeMarker&&(1&t.buttons)>0&&l.activeMarker.manipulate(t)},l.mouseUp=function(t){l.activeMarker&&l.activeMarker.endManipulation()},l.adjustUI=function(t){l.adjustSize(),l.positionUI()},l.adjustSize=function(){l.width=l.target.clientWidth,l.height=l.target.clientHeight;var t=l.target.clientWidth/l.boardHolder.clientWidth;1!==t&&(l.scale*=t,l.boardHolder.style.width=l.width+"px",l.boardHolder.style.height=l.height+"px",l.boardHolder.style.transform="scale("+l.scale+")")},l.positionUI=function(){l.setTargetRect(),l.positionBoard(),l.positionToolbar()},l.positionToolbar=function(){l.toolbarUI.style.left=l.targetRect.left+l.target.offsetWidth-l.toolbarUI.clientWidth+"px",l.toolbarUI.style.top=l.targetRect.top-l.toolbarUI.clientHeight+"px"},l.showUI=function(){l.toolbar=new c.Toolbar(l.toolbars,l.toolbarClick),l.toolbarUI=l.toolbar.getUI(),document.body.appendChild(l.toolbarUI),l.toolbarUI.style.position="absolute",l.positionToolbar()},l.setStyles=function(){var t=document.createElementNS("http://www.w3.org/2000/svg","style");t.innerHTML='\n .rect-marker .render-visual {\n stroke: #ff0000;\n stroke-width: 3;\n fill: transparent;\n }\n .cover-marker .render-visual {\n stroke-width: 0;\n fill: #000000;\n }\n .highlight-marker .render-visual {\n stroke: transparent;\n stroke-width: 0;\n fill: #ffff00;\n fill-opacity: 0.4;\n }\n .line-marker .render-visual {\n stroke: #ff0000;\n stroke-width: 3;\n fill: transparent;\n }\n .arrow-marker .render-visual {\n stroke: #ff0000;\n stroke-width: 3;\n fill: transparent;\n }\n .arrow-marker-tip {\n stroke-width: 0;\n fill: #ff0000;\n }\n .text-marker text {\n fill: #ff0000;\n font-family: -apple-system, BlinkMacSystemFont, "Segoe UI",\n Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji",\n "Segoe UI Emoji", "Segoe UI Symbol";\n }\n .fc-whiteboard-rect-control-box .fc-whiteboard-rect-control-rect {\n stroke: black;\n stroke-width: 1;\n stroke-opacity: 0.5;\n stroke-dasharray: 3, 2;\n fill: transparent;\n }\n .fc-whiteboard-control-grip {\n fill: #cccccc;\n stroke: #333333;\n stroke-width: 2;\n }\n ',l.boardCanvas.appendChild(t)},l.toolbarClick=function(t,e){if(e.markerType)l.addMarker(e.markerType);else switch(e.name){case"delete":l.deleteActiveMarker();break;case"pointer":l.activeMarker&&l.selectMarker(null);break;case"close":l.cancel();break;case"ok":l.complete()}},l.selectMarker=function(t){l.activeMarker&&l.activeMarker!==t&&l.activeMarker.deselect(),l.activeMarker=t},l.deleteMarker=function(t){l.boardCanvas.removeChild(t.visual),l.activeMarker===t&&(l.activeMarker=null),l.markers.splice(l.markers.indexOf(t),1)},l.complete=function(){l.selectMarker(null),l.startRender(l.renderFinishedClose)},l.cancel=function(){l.close(),l.onCancel&&l.onCancel()},l.renderFinished=function(t){l.onComplete(t)},l.renderFinishedClose=function(t){l.close(),l.onComplete(t)},n&&(l.page=n),l.markers=[],l.activeMarker=null,l.toolbars=s.getToolbars(n),i&&(l.onChange=i),l}return n(e,t),Object.defineProperty(e.prototype,"markerMap",{get:function(){var t={};return this.markers.forEach(function(e){t[e.id]=e}),t},enumerable:!0,configurable:!0}),e}(i.Baseboard);e.Drawboard=l},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=r(2),n=r(0),i=function(){return function(t){var e=this;this.id=o.uuid(),this.initBoard=function(){e.boardHolder=document.createElement("div"),e.boardHolder.id="fcw-board-holder-"+e.id,e.boardHolder.style.setProperty("touch-action","none"),e.boardHolder.style.setProperty("-ms-touch-action","none"),document.body.appendChild(e.boardHolder),e.boardCanvas=document.createElementNS("http://www.w3.org/2000/svg","svg"),e.boardCanvas.setAttribute("xmlns","http://www.w3.org/2000/svg"),e.boardCanvas.setAttribute("width",e.width.toString()),e.boardCanvas.setAttribute("height",e.height.toString()),e.boardCanvas.setAttribute("viewBox","0 0 "+e.width.toString()+" "+e.height.toString()),e.boardHolder.style.position="absolute",e.boardHolder.style.width=e.width+"px",e.boardHolder.style.height=e.height+"px",e.boardHolder.style.transformOrigin="top left",e.positionBoard(),e.defs=n.SvgHelper.createDefs(),e.boardCanvas.appendChild(e.defs),e.boardHolder.appendChild(e.boardCanvas)},this.positionBoard=function(){e.boardHolder.style.top=e.targetRect.top+"px",e.boardHolder.style.left=e.targetRect.left+"px"},this.source=t,t.imgEle&&(this.target=t.imgEle,this.width=this.target.clientWidth,this.height=this.target.clientHeight)}}();e.Baseboard=i},function(t,e){var r="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(r){var o=new Uint8Array(16);t.exports=function(){return r(o),o}}else{var n=new Array(16);t.exports=function(){for(var t,e=0;e<16;e++)0==(3&e)&&(t=4294967296*Math.random()),n[e]=t>>>((3&e)<<3)&255;return n}}},function(t,e){for(var r=[],o=0;o<256;++o)r[o]=(o+256).toString(16).substr(1);t.exports=function(t,e){var o=e||0,n=r;return[n[t[o++]],n[t[o++]],n[t[o++]],n[t[o++]],"-",n[t[o++]],n[t[o++]],"-",n[t[o++]],n[t[o++]],"-",n[t[o++]],n[t[o++]],"-",n[t[o++]],n[t[o++]],n[t[o++]],n[t[o++]],n[t[o++]],n[t[o++]]].join("")}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=r(16),n=r(18),i=r(19),s=r(20),a=r(21),c=r(22),l=r(23),u=r(7),p=r(24),d=r(25),h=r(8);e.highlightMarkerToolbarItem=new c.ToolbarItem({name:"cover-marker",tooltipText:"Cover",icon:r(26),markerType:a.HighlightMarker}),e.arrowMarkerToolbarItem=new c.ToolbarItem({name:"arrow-marker",tooltipText:"Arrow",icon:r(27),markerType:s.ArrowMarker}),e.textMarkerToolbarItem=new c.ToolbarItem({name:"text-marker",tooltipText:"Text",icon:r(28),markerType:i.TextMarker}),e.coverMarkerToolbarItem=new c.ToolbarItem({name:"cover-marker",tooltipText:"Cover",icon:r(29),markerType:n.CoverMarker}),e.rectMarkerToolbarItem=new c.ToolbarItem({name:"rect-marker",tooltipText:"Rectangle",icon:r(30),markerType:o.RectMarker}),e.lineMarkerToolbarItem=new c.ToolbarItem({name:"line-marker",tooltipText:"Line",icon:r(31),markerType:l.LineMarker}),e.getToolbars=function(t){var r=[{icon:d,name:"pointer",tooltipText:"Pointer"},{icon:p,name:"delete",tooltipText:"Delete"},{name:"separator",tooltipText:""},e.rectMarkerToolbarItem,e.coverMarkerToolbarItem,e.highlightMarkerToolbarItem,e.lineMarkerToolbarItem,e.arrowMarkerToolbarItem,e.textMarkerToolbarItem,{name:"separator",tooltipText:""}];return t||r.push.apply(r,[{icon:u,name:"ok",tooltipText:"OK"}]),r.push({icon:h,name:"close",tooltipText:"Close"}),r}},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(1),s=r(0),a=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="rect",e}return n(e,t),e.prototype.setup=function(){t.prototype.setup.call(this),s.SvgHelper.setAttributes(this.visual,[["class","rect-marker"]])},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(i.RectBaseMarker);e.RectMarker=a},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(){return function(){var t=this;this.findGripByVisual=function(e){switch(e){case t.topLeft.visual:return t.topLeft;case t.topCenter.visual:return t.topCenter;case t.topRight.visual:return t.topRight;case t.centerLeft.visual:return t.centerLeft;case t.centerRight.visual:return t.centerRight;case t.bottomLeft.visual:return t.bottomLeft;case t.bottomCenter.visual:return t.bottomCenter;case t.bottomRight.visual:return t.bottomRight;default:return t.topLeft}}}}();e.RectangularMarkerGrips=o},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(0),s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="cover",e}return n(e,t),e.prototype.setup=function(){t.prototype.setup.call(this),i.SvgHelper.setAttributes(this.visual,[["class","cover-marker"]])},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(r(1).RectBaseMarker);e.CoverMarker=s},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(4),s=r(0),a=r(7),c=r(8),l=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="text",e.MIN_SIZE=50,e.DEFAULT_TEXT="Double-click to edit text",e.text=e.DEFAULT_TEXT,e.inDoubleTap=!1,e.renderText=function(){for(;e.textElement.lastChild;)e.textElement.removeChild(e.textElement.lastChild);for(var t=0,r=e.text.split(/\r\n|[\n\v\f\r\x85\u2028\u2029]/);t0&&t.height>0){var i=1*e.width/t.width,s=1*e.height/t.height;n=Math.min(i,s),r=(e.width-t.width*n)/2,o=(e.height-t.height*n)/2}e.textElement.transform.baseVal.getItem(0).setTranslate(r,o),e.textElement.transform.baseVal.getItem(1).setScale(n,n)},e.onDblClick=function(t){e.showEditor()},e.onTap=function(t){e.inDoubleTap?(e.inDoubleTap=!1,e.showEditor()):(e.inDoubleTap=!0,setTimeout(function(){e.inDoubleTap=!1},300))},e.showEditor=function(){e.editor=document.createElement("div"),e.editor.className="fc-whiteboard-text-editor",e.editorTextArea=document.createElement("textarea"),e.text!==e.DEFAULT_TEXT&&(e.editorTextArea.value=e.text),e.editorTextArea.addEventListener("keydown",e.onEditorKeyDown),e.editor.appendChild(e.editorTextArea),document.body.appendChild(e.editor);var t=document.createElement("div");t.className="fc-whiteboard-text-editor-button-bar",e.editor.appendChild(t);var r=document.createElement("div");r.className="fc-whiteboard-text-editor-button",r.innerHTML=a,r.addEventListener("click",e.onEditorOkClick),t.appendChild(r);var o=document.createElement("div");o.className="fc-whiteboard-text-editor-button",o.innerHTML=c,o.addEventListener("click",e.closeEditor),t.appendChild(o)},e.onEditorOkClick=function(t){e.editorTextArea.value.trim()?e.text=e.editorTextArea.value:e.text=e.DEFAULT_TEXT,e.onChange({target:"marker",id:e.id,event:"changeText",data:e.text}),e.renderText(),e.closeEditor()},e.closeEditor=function(){document.body.removeChild(e.editor)},e.onEditorKeyDown=function(t){"Enter"===t.key&&t.ctrlKey&&(t.preventDefault(),e.onEditorOkClick(null))},e}return n(e,t),e.prototype.setText=function(t){this.text=t,this.renderText()},e.prototype.setup=function(){t.prototype.setup.call(this),this.textElement=s.SvgHelper.createText(),this.addToRenderVisual(this.textElement),s.SvgHelper.setAttributes(this.visual,[["class","text-marker"]]),this.textElement.transform.baseVal.appendItem(s.SvgHelper.createTransform()),this.textElement.transform.baseVal.appendItem(s.SvgHelper.createTransform()),this.renderText(),this.visual.addEventListener("dblclick",this.onDblClick),this.visual.addEventListener("touchstart",this.onTap)},e.prototype.resize=function(e,r,o){t.prototype.resize.call(this,e,r,o),this.sizeText()},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(i.RectangularMarker);e.TextMarker=l},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(9),s=r(0),a=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="arrow",e.ARROW_SIZE=6,e}return n(e,t),e.prototype.setup=function(){t.prototype.setup.call(this),s.SvgHelper.setAttributes(this.visual,[["class","arrow-marker"]]);var e=s.SvgHelper.createPolygon("0,0 "+this.ARROW_SIZE+","+this.ARROW_SIZE/2+" 0,"+this.ARROW_SIZE,[["class","arrow-marker-tip"]]);this.defs.push(s.SvgHelper.createMarker("arrow-marker-head","auto",this.ARROW_SIZE,this.ARROW_SIZE,this.ARROW_SIZE-1,this.ARROW_SIZE/2,e)),this.markerLine.setAttribute("marker-end","url(#arrow-marker-head")},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(i.LinearMarker);e.ArrowMarker=a},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(0),s=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="highlight",e}return n(e,t),e.prototype.setup=function(){t.prototype.setup.call(this),i.SvgHelper.setAttributes(this.visual,[["class","highlight-marker"]])},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(r(1).RectBaseMarker);e.HighlightMarker=s},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=function(){return function(t){var e=t.name,r=t.tooltipText,o=t.icon,n=t.markerType;this.name=e,this.tooltipText=r,this.icon=o,this.markerType=n}}();e.ToolbarItem=o},function(t,e,r){"use strict";var o,n=this&&this.__extends||(o=function(t,e){return(o=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])})(t,e)},function(t,e){function r(){this.constructor=t}o(t,e),t.prototype=null===e?Object.create(e):(r.prototype=e.prototype,new r)});Object.defineProperty(e,"__esModule",{value:!0});var i=r(9),s=r(0),a=function(t){function e(){var e=null!==t&&t.apply(this,arguments)||this;return e.type="line",e}return n(e,t),e.prototype.setup=function(){t.prototype.setup.call(this),s.SvgHelper.setAttributes(this.visual,[["class","line-marker"]])},e.createMarker=function(t){var r=new e;return r.page=t,r.setup(),r},e}(i.LinearMarker);e.LineMarker=a},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e){t.exports='\x3c!-- Font Awesome Free 5.5.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license/free (Icons: CC BY 4.0, Fonts: SIL OFL 1.1, Code: MIT License) --\x3e'},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=r(33),n=function(){function t(){}return t.prototype.rasterize=function(t,e,r){if(!o.isHTMLImageElement(t))throw new Error("Error: only support export HTMLImageElement");var n=document.createElement("canvas");n.width=e.width.baseVal.value,n.height=e.height.baseVal.value;var i=e.outerHTML,s=n.getContext("2d");if(!s)throw new Error("Invalid ctx");s.drawImage(t,0,0,n.width,n.height);var a=window.URL,c=new Image(n.width,n.height);c.setAttribute("crossOrigin","anonymous");var l=new Blob([i],{type:"image/svg+xml"}),u=a.createObjectURL(l);c.onload=function(){s.drawImage(c,0,0),a.revokeObjectURL(u),r(n.toDataURL("image/png"))},c.src=u},t}();e.Synthetizer=n},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.isHTMLImageElement=function(t){return"object"==typeof t&&t instanceof HTMLImageElement}},function(t,e,r){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var o=r(35),n=r(2),i=function(){function t(t,e){var r=this;this.id=n.uuid(),this.getUI=function(){r.toolbarUI=document.createElement("div"),r.toolbarUI.id="fcw-toolbar-"+r.id,r.toolbarUI.className="fc-whiteboard-toolbar";for(var t=0,e=r.toolbarItems;t=0&&u.splice(e,1)}function m(t){var e=document.createElement("style");if(void 0===t.attrs.type&&(t.attrs.type="text/css"),void 0===t.attrs.nonce){var o=function(){0;return r.nc}();o&&(t.attrs.nonce=o)}return g(e,t.attrs),f(t,e),e}function g(t,e){Object.keys(e).forEach(function(r){t.setAttribute(r,e[r])})}function b(t,e){var r,o,n,i;if(e.transform&&t.css){if(!(i="function"==typeof e.transform?e.transform(t.css):e.transform.default(t.css)))return function(){};t.css=i}if(e.singleton){var s=l++;r=c||(c=m(e)),o=x.bind(null,r,s,!1),n=x.bind(null,r,s,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(r=function(t){var e=document.createElement("link");return void 0===t.attrs.type&&(t.attrs.type="text/css"),t.attrs.rel="stylesheet",g(e,t.attrs),f(t,e),e}(e),o=function(t,e,r){var o=r.css,n=r.sourceMap,i=void 0===e.convertToAbsoluteUrls&&n;(e.convertToAbsoluteUrls||i)&&(o=p(o));n&&(o+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(n))))+" */");var s=new Blob([o],{type:"text/css"}),a=t.href;t.href=URL.createObjectURL(s),a&&URL.revokeObjectURL(a)}.bind(null,r,e),n=function(){v(r),r.href&&URL.revokeObjectURL(r.href)}):(r=m(e),o=function(t,e){var r=e.css,o=e.media;o&&t.setAttribute("media",o);if(t.styleSheet)t.styleSheet.cssText=r;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(r))}}.bind(null,r),n=function(){v(r)});return o(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;o(t=e)}else n()}}t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=s()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var r=h(t,e);return d(r,e),function(t){for(var o=[],n=0;n