{"version":3,"sources":["kendo.drawing.js"],"names":["f","define","$","createPromise","Deferred","promiseAll","promises","when","apply","kendo","drawing","util","deepExtend","window","jQuery","amd","a1","a2","a3","normalizeText","text","String","replace","REPLACE_REGEX","SPACE","objectKey","object","key","parts","push","sort","join","hashKey","str","i","hash","length","charCodeAt","zeroSize","width","height","baseline","measureText","style","measureBox","TextMetrics","current","measure","LRUCache","DEFAULT_OPTIONS","defaultMeasureBox","Class","extend","init","size","this","_size","_length","_map","put","value","map","entry","_head","_tail","newer","older","get","baselineMarkerSize","document","createElement","cssText","options","_cache","styleKey","cacheKey","cachedResult","baselineMarker","textStr","box","_baselineMarker","cloneNode","textContent","appendChild","body","offsetWidth","offsetHeight","offsetTop","parentNode","removeChild","marker","append","first","second","arabicToRoman","n","values","roman","shift","literals","defined","UNDEFINED","definitionId","defId","deg","radians","DEG_TO_RAD","encodeUTF8","input","c","output","fromCharCode","encodeBase64","chr1","chr2","chr3","enc1","enc2","enc3","enc4","utfInput","isNaN","KEY_STR","charAt","eventCoordinates","e","x","location","y","pageX","clientX","pageY","clientY","eventElement","touch","initialTouch","target","isTransparent","color","last","array","limitValue","min","max","Math","mergeSort","a","cmp","merge","b","r","ai","bi","slice","m","left","right","floor","rad","degrees","pow","p","round","precision","power","valueOrDefault","defaultValue","bindEvents","element","events","eventName","eventNames","idx","trim","split","addEventListener","elementOffset","getBoundingClientRect","documentElement","top","pageYOffset","scrollTop","clientTop","pageXOffset","scrollLeft","clientLeft","elementStyles","styles","field","result","getComputedStyle","stylesArray","Array","isArray","getPixels","elementSize","size$1","parseInt","unbindEvents","name","removeEventListener","setAccessor","geometryChange","getAccessor","defineAccessors","fn","fields","capitalized","toUpperCase","substring","toMatrix","transformation","matrix","transform","Transformation","ellipseExtremeAngles","center","rx","ry","extremeX","extremeY","atan2","d","geometryAccessor","fieldName","_observerField","defineGeometryAccessors","names","close","tolerance","PRECISION","abs","closeOrLess","lineIntersection","p0","p1","p2","p3","s1x","s2x","s1y","s2y","nx","ny","s","t","Point","calculateAngle","cx","cy","cos","sin","normalizeArcParameters","parameters","cosine","sine","xT","yT","sign","xt2","yt2","rx2","ry2","delta","constT","cxT","cyT","uX","uY","vX","vY","startAngle","angleCosine","angle","endAngle","signEndAngle","x1","y1","x2","y2","largeArc","swipe","rotation","sqrt","acos","radiusX","radiusY","xRotation","bboxStartAngle","start","pointAccessor","create","definePointAccessors","isOutOfEndPoint","endPoint","controlPoint","point","rotatedPoint","transformCopy","rotate","calculateCurveAt","points","t1","toCubicPolynomial","numberSign","solveQuadraticEquation","squareRoot","solveCubicEquation","q","Q","b3a","y3","z1","z2","ComplexNumber","nthRoot","add","multiplyConstant","negate","multiply","isReal","real","hasRootsInRange","rootField","range","intersection","polynomial","roots","curveIntersectionsCount","bbox","rayIntersection","intersectsRay","count","bottomRight","lineIntersectionsCount","intersects","minX","maxX","minY","maxY","inRange","arrayLimits","arr","MAX_NUM","MIN_NUM","elementsBoundingBox","elements","applyTransform","boundingBox","elementBoundingBox","visible","rawBBox","Rect","union","elementsClippedBoundingBox","clippedBBox","toLineParamaters","isVertical","insertPosition","splice","reflectionPoint","scaleCopy","translate","quadraticToCubicControlPoints","position","scaledPoint","clone","scale","controlOut","translateWith","third","controlIn","parseParameters","SPLIT_REGEX","match","number","parseFloat","translateToPoint","transofrm","origin","alignStart","rect","align","axis","sizeField","alignStartReverse","alignElements","alignment","vAlign","stackElements","stackAxis","otherAxis","previousBBox","createStackElements","stack","vStack","getStacks","maxSize","stacks","stackSize","addElementToStack","wrapElements","startElement","elementIdx","wrap","vWrap","fit","rectSize","transform$$1","optionsAccessor","set","defineOptionsAccessors","swing","PI","linear","easeOutElastic","time","diff","asin","renderAttr","renderAllAttr","attrs","renderStyle","isDefinition","type","nodeType","baseUrl","hashIndex","base","getElementsByTagName","href","url","supportBrowser","msie","indexOf","alignToScreen","ctm","getScreenCTM","decodeEntities","ENTITY_REGEX","test","_element","lastIndex","innerHTML","innerText","exportGroup","group","exportRoot","svg","root","RootNode","skipBaseHref","rootGroup","getOrigin","Group","children","load","SVG_NS","render","destroy","renderPath","ctx","path","segment","anchor","prevSeg","prevOut","segments","moveTo","bezierCurveTo","lineTo","closed","closePath","zIndexComparer","_zIndex","addGradientStops","gradient","stops","stop","parseColor","opacity","addColorStop","offset","toCssRgba","exportImage","surfaceOptions","container","surface","promise","defaults","cors","getSize","display","Surface$3","suspendTracking","draw","image","then","exportSVG","raw","resolve","slice$1","thing","prototype","call","addClass","el","cls","classList","className","removeClass","remove","reduce","word","setCSS","Object","keys","forEach","closest","selector","matches","getXY","drawDOM","doOne","pos","setTransform","nodeInfo","_clipbox","_matrix","Matrix","unit","_stackingContext","_avoidLinks","avoidLinks","renderElement","makeTemplate","template$$1","template","data","div","firstElementChild","handlePageBreaks","callback","forceBreak","pageWidth","pageHeight","margin","doPageBreak","splitElement","copy","page","makePage","insertBefore","pages","pageNum","totalPages","cacheImages","whenImagesAreActuallyLoaded","keepTogether","adjust","tag","tagName","getAttribute","bottomPadding","bottomBorder","saveAdjust","isFirst","fall","tableLayout","getPropertyValue","firstChild","nextSibling","breakAtElement","fallsOnMargin","splitText","firstInParent","table","colgroup","thead","grid","gridHead","querySelector","repeatHeaders","doc","createRange","setStartBefore","setEndBefore","extractContents","preventBulletOnListItem","boxSizing","padding","bottom","overflow","clear","pageClassName","available","node","len","nextnode","selectNodeContents","findEOP","setEnd","endOffset","li","setAttribute","ownerDocument","_destructive","cloneNodes","querySelectorAll","tfoot","ol","index","paddingLeft","paddingRight","beforePageBreak","setTimeout","reject","Error","pdf","defineFont","getFontFaces","forcePageBreak","hasPaperSize","paperSize","paperOptions","getPaperOptions","def","hasMargin","multiPage","_ignoreMargin","progress","canceled","next","cancel","doStylesheet","ss","rules","cssRules","ex","addRules","findFonts","rule","font","src","splitProperty","getFontURL","styleSheet","family","bold","italic","addRule","styleSheets","hasOwnProperty","obj","getCounter","getAllCounters","getPrototypeOf","reverse","incCounter","inc","_root","resetCounter","val","doCounters","updateCounters","counterIncrement","counterReset","parseColor$1","css","toRGB","pending","img","images","complete","onload","onerror","IMAGE_CACHE","urls","dive","parseBackgroundImage","bg","Image","crossOrigin","alphaNumeral","pushNodeInfo","decoration","toLowerCase","createsStackingContext","popNodeInfo","updateClipbox","intersect","emptyClipbox","cb","prop","pseudoElt","defa","browser","webkit","mozilla","opera","microsoft","arguments","pleaseSetPropertyValue","important","setProperty","getBorder","side","saveStyle","func","prev","getBorderRadius","sanitizeRadius","getContentBox","innerBox","wt","wr","wb","wl","getTransform","exec","radiansToDegrees","parseAngle","num","shape","setClipping","clipPath","clip","addArcToPath","Arc$2","curvePoints","curveTo","adjustBorderRadiusForBox","rTL","rTR","rBR","rBL","tl_x","tl_y","tr_x","tr_y","br_x","br_y","bl_x","bl_y","tl","tr","br","bl","elementRoundBox","bt","bb","pt","pr","pb","pl","roundBox","rTL0","rTR0","rBR0","rBL0","tmp","Path","fill","stroke","formatCounter","evalPseudoElementContent","content","displayCounter","separator","getCssText","_renderWithPseudoElements","pseudo","kind","place","psel","KENDO_PSEUDO_ELEMENT","fake","saveClass","_renderElement","adjustBoxes","boxes","tableBorderLeft","tableBorderTop","tableBox","firstCell","firstCellBox","rows","cells","drawEdge","Wtop","Wleft","Wright","rl","rr","drawRoundCorner","ri","anticlockwise","edge","drawBackground","background","backgroundColor","backgroundImage","drawOneBackground","backgroundRepeat","backgroundPosition","backgroundOrigin","backgroundSize","drawBackgroundImage","img_width","img_height","renderBG","rewX","rewY","repeatX","aspect_ratio","orgBox","Image$1","gradientRenderer","drawBullet","_drawBullet","bullet","listStylePosition","textAlign","elementIndex","k","listStyleType","fontSize","lineHeight","fontFamily","disc","circle","square","drawOneBox","isLast","inv","shouldDrawLeft","shouldDrawRight","dir","textOverflow","saveTextOverflow","innerbox","version","currentStyle","getClientRects","g","_pdfLink","clipit","isFormField","maybeRenderWidget","renderContents","pxlen","scaledAngle","implicit","end","to","atan","tan","percent","fromRect","LinearGradient","userSpace","console","log","visual","widget","wrap$$1","_kendoExportVisual","attr","widgetInstance","exportDOMVisual","exportVisual","renderImage","zIndexSort","sa","sb","za","zb","pa","getSelectedOption","selectedOptions","selectedIndex","renderCheckbox","checked","Circle","Circle$2","renderFormField","option","whiteSpace","multiple","floats","positioned","floating","toDataURL","renderText","actuallyGetRangeBoundingRect","rectangles","done","chrome","Infinity","prevLineBottom","doChunk","found","cc","code","indent","origStart","substr","search","setStart","isJustified","columnCount","findEOL","eol","estimateLineLength","startOffset","drawText","getFontHeight","textTransform","l","TextRect","decorate","line","ypos","underline","lineThrough","overline","align$$1","hasDecoration","selectNode","groupInStackingContext","zIndex","main","_dom_zIndex","insert","invert","visibility","mmul","multiplyCopy","b1","c1","d1","e1","f1","b2","c2","d2","e2","f2","kendoDrawing","kendoDrawingUtil","kendoUtil","support","ObserversMixin","toString","OptionsStore","Size","Element$1","PI_DIV_2","GRADIENT","Paintable","IDENTITY_MATRIX_HASH","Measurable","DEFAULT_STROKE","MAX_INTERVAL","pow$1","pop","unshift","ElementsArray","GeometryElementsArray","Segment","MultiPath","ShapeMap","SEGMENT_REGEX","MOVE","CLOSE","PathParser","DEFAULT_STROKE$1","Arc","DEFAULT_FONT","DEFAULT_FILL","Text","Traversable","forEachReverse","Layout","Rect$2","StopsArray","GradientStop","Gradient","RadialGradient","easingFunctions","AnimationFactory","now","Animation","SurfaceFactory","Surface","BaseNode","NODE_MAP","NONE","renderSVG","testFragment","testContainer","hasParser","renderSVG$1","TRANSFORM","DefinitionMap","Node","GradientStopNode","GradientNode","LinearGradientNode","RadialGradientNode","ClipNode","DefinitionNode","RTL","Surface$1","GroupNode","DASH_ARRAYS","SOLID","BUTT","ATTRIBUTE_MAP","PathNode","ArcNode","CircleNode","RectNode","ImageNode","TextNode","MultiPathNode","geometry","NODE_MAP$2","Node$2","GroupNode$2","FRAME_DELAY","RootNode$2","QuadRoot","QuadNode","ROOT_SIZE","LEVEL_STEP","MAX_LEVEL","ShapesQuadTree","SurfaceCursor","PathNode$2","ArcNode$2","CircleNode$2","RectNode$2","ImageNode$2","TextNode$2","MultiPathNode$2","canvas","inBrowser","proto","method","this$1","observers","_observers","addObserver","removeObserver","trigger","methodName","event","observer","_suspended","optionsChange","suspend","resume","1","10","100","2","20","200","3","30","300","4","40","400","5","50","500","6","60","600","7","70","700","8","80","800","9","90","900","1000","Number","MAX_VALUE","prefix","member","_wrap","part","_set","composite","parentObj","_clear","wrapped","ref","h","det","equals","other","toArray","scaleX","scaleY","IDENTITY","originPoint","ZERO","move","distanceTo","dx","dy","digits","doRound","arg0","arg1","arguments$1","minPoint","maxPoint","defineProperties","setOrigin","setSize","topLeft","topRight","bottomLeft","fromPoints","expand","expandCopy","containsPoint","_isOnPath","rectOuter","rectInner","rect1","rect2","_optionsChange","_initOptions","id","parentTransform","parentMatrix","parent","currentTransform","elementTransform","elementMatrix","combinedMatrix","_clippedBBox","transformedPoint","_hasFill","_containsPoint","_hasStroke","radius","setCenter","setRadius","getCenter","pointAt","_pointAt","currentPointX","currentPointY","currentPoint","extremeAngles","inCircle","pointDistance","newFill","strokeWidth","matrixHash","_bboxCache","_matrixHash","_bbox","_geometry","radian","nextAngle","interval","_arcInterval","intervalAngle","subIntervalsCount","ceil","subIntervalAngle","currentAngle","_intervalCurvePoints","cp1","cp2","currentAngleX","currentAngleY","oldStart","p1Derivative","_derivativeAt","p2Derivative","inAngleRange","distance","angleRad","pointRadius","startPoint","arcParameters","_splice","_change","_add","_remove","howMany","concat","_clearObserver","_setObserver","cNumber","addConstant","rad$$1","nthR","bboxTo","toSegment","segmentAnchor","toSegmentAnchor","_curveBoundingBox","_lineBoundingBox","extremesX","_curveExtremesFor","extremesY","xLimits","yLimits","extremes","_curveExtremes","x3","x4","t2","_intersectionsTo","intersectionsCount","_isOnCurveTo","endSegment","p4","rotatedPoints","_isOnLineTo","_isOnPathTo","isOnPath","paths","arc","arcTo","isRelative","v","lastControlIn","previousCommand","cubicControlPoints","lastSegment","parse","multiPath","params","command","lineJoin","_addArcSegments","previous","pathWidth","segmentBox","fromArc","toPath","metrics","_rect","childrenField","traverse","child","childrenChange","action","items","_reparent","insertAt","removeAt","newParent","alignContent","justifyContent","alignItems","spacing","orientation","lineSpacing","revers","_fieldMap","_initMap","fieldMap","groupsSizeField","groupAxis","groupsAxis","justifyAlign","reflow","groups","groupsSize","ref$1","groupOrigin","elementOrigin","groupStart","elementStart","groupBox","arrangeElements","groupIdx","scaledStart","scaledSize","newStart","_initGroups","lineSize","bboxes","_newGroup","addGroup","_addToGroup","arg","_createStops","_userSpace","addStop","removeStop","_radius","_fallbackFill","fallbackFill","_items","register","Date","getTime","setup","step","play","easing","finish","duration","delay","abort","loop","wallTime","easingPosition","_stopped","animationFrame","order","preferred","logToConsole","navigator","userAgent","Observable","bind","_click","_handler","_mouseenter","_mouseleave","_mousemove","_visual","_enableTracking","unbind","eventTarget","domNode","_kendoNode","parentElement","srcElement","currentSize","_resize","resize","force","_suspendedTracking","resumeTracking","originalEvent","_elementOffset","paddingTop","_surfacePoint","coord","childNodes","observe","removeSelf","invalidate","DOMParser","namespaceURI","parser","chartDoc","parseFromString","importedDoc","adoptNode","definitions","clearDefinitions","childNode","createDefinitions","attachTo","domElement","setElement","nodes","childElement","renderChildren","updateDefinition","removeAttr","allAttr","allCss","removeAttribute","mapTransform","renderTransform","transformChange","mapStyle","cursor","renderOpacity","renderId","hasDefinitions","definition","definitionChange","refUrl","renderDefinitions","mapDefinitions","baseHref","renderOffset","loadStops","stopNode","mapCoordinates","renderCoordinates","mapSpace","definitionMap","addDefinitions","removeDefinitions","createDefinition","item","addDefinition","mapItem","removeDefinition","defs","rtl","direction","_template","_rootElement","click","mouseover","mouseout","mousemove","viewBox","_offset","implementation","hasFeature","dot","dash","longdash","dashdot","longdashdot","longdashdotdot","fill.opacity","stroke.color","stroke.width","stroke.opacity","renderData","mapFill","mapStroke","printPath","currentType","segmentType","printPoints","segmentStart","segmentEnd","renderLinecap","dashType","renderDashType","renderStroke","dashArray","lineCap","renderFill","mapPosition","mapSource","renderPosition","encode","htmlEncode","renderSource","setY","renderContent","renderTextAnchor","initClip","clearClip","setClip","beginPath","loadElements","setOpacity","globalAlpha","opactity","renderTo","save","restore","getContext","invalidateHandler","_invalidate","throttle","clearRect","shapes","_quadNode","pointShapes","inBounds","nodeRect","nodeBottomRight","inserted","_initChildren","halfWidth","halfHeight","initRoots","rootMap","rootElements","pointShape","sectorRoot","assignZindex","levelWeight","parents","bboxChange","_insertShape","elementsArray","_insert","sectors","getSectors","inRoot","bottomX","bottomY","_resetCursor","_shapeCursor","_current","_defaultCursor","_getCursor","_setCursor","_mouseTrackHandler","_trackMouse","_searchTree","_cursor","undefined","resolveDataURL","rootElement","loadingStates","loading","currentShape","_currentShape","renderPoints","setLineDash","setLineCap","setLineJoin","setFill","setStroke","hasFill","setGradientFill","fillStyle","createLinearGradient","createRadialGradient","strokeStyle","lineWidth","mozDash","webkitLineDash","onLoad","onError","state","drawImage","fillText","strokeText","_pdfRect","Element","webkitMatchesSelector","mozMatchesSelector","msMatchesSelector","$el","$clone","selected","orig","canvases","canvas$$1","skip_ws","tok_whitespace","read","token","read_stop","tok_length","tok_percent","read_linear_gradient","propName","to1","to2","tok_popen","tok_angle","tok_comma","tok_keyword","tok_pclose","read_url","tok_content","tok","cache1","tok_linear_gradient","tok_url","cache2","cache","looking_at","ret","last$$1","in_paren","in_string","dataviz","Color","NS","utils","outerWidth","_outerWidth","outerHeight","_outerHeight","proxy","TOOLTIP_TEMPLATE","TOOLTIP_CLOSE_TEMPLATE","SurfaceTooltip","_tooltipOptions","popupOptions","appendTo","animation","copyAnchorStyles","collision","_openPopupHandler","_openPopup","_bindEvents","showOn","autoHide","hideDelay","showAfter","_showHandler","_showEvent","_surfaceLeaveHandler","_surfaceLeave","_mouseleaveHandler","_mousemoveHandler","on","_hideClick","_tooltipLeave","getPopup","popup","ui","Popup","off","clearTimeout","_timeout","shared","_tooltipShape","tooltip","_updateContent","isFunction","html","_position","tooltipOffset","_instance","surfaceOffset","show","_show","hide","_showTimeout","preventDefault","_autoHide","_measure","open","_closeButton","prependTo","wrapper","_popupRelatedTarget","relatedTarget","DrawingSurface","Widget","_triggerInstanceHandler","_triggerInstanceEvent","_bindHandler","hideTooltip","_tooltip","showTooltip","plugin"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;CAwBC,SAAUA,EAAGC,QACVA,OAAO,gBAAiB,cAAeD,IACzC,WAcE,MAbC,UAAUE,GACP,QAASC,KACL,MAAOD,GAAEE,WAEb,QAASC,GAAWC,GAChB,MAAOJ,GAAEK,KAAKC,MAAMN,EAAGI,GAE3BG,MAAMC,QAAQC,KAAOF,MAAMC,QAAQC,SACnCF,MAAMG,WAAWH,MAAMC,QAAQC,MAC3BR,cAAeA,EACfE,WAAYA,KAElBQ,OAAOJ,MAAMK,QACRD,OAAOJ,OACE,kBAAVR,SAAwBA,OAAOc,IAAMd,OAAS,SAAUe,EAAIC,EAAIC,IACrEA,GAAMD,OAEV,SAAUjB,EAAGC,QACVA,OAAO,qBAAsB,cAAeD,IAC9C,YACG,SAAUE,GAqDP,QAASiB,GAAcC,GACnB,OAAcA,EAAPC,IAAaC,QAAQC,EAAeC,GAE/C,QAASC,GAAUC,GAAnB,GAEaC,GADLC,IACJ,KAASD,IAAOD,GACZE,EAAMC,KAAKF,EAAMD,EAAOC,GAE5B,OAAOC,GAAME,OAAOC,KAAK,IAE7B,QAASC,GAAQC,GAAjB,GAEaC,GADLC,EAAO,UACX,KAASD,EAAI,EAAGA,EAAID,EAAIG,SAAUF,EAC9BC,IAASA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IAAMA,GAAQ,IACzEA,GAAQF,EAAII,WAAWH,EAE3B,OAAOC,KAAS,EAEpB,QAASG,KACL,OACIC,MAAO,EACPC,OAAQ,EACRC,SAAU,GA0DlB,QAASC,GAAYtB,EAAMuB,EAAOC,GAC9B,MAAOC,GAAYC,QAAQC,QAAQ3B,EAAMuB,EAAOC,GAtIvD,GAEOI,GAiDAzB,EACAC,EA0BAy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AS,SAAUe,EAAIC,EAAIC,IACrEA,GAAMD,OAEV,SAAUjB,EAAGC,QACVA,OAAO,iBACH,eACA,wBACA,0BACA,kBACA,gBACDD,IACL,aAYkB,kBAAVC,SAAwBA,OAAOc,IAAMd,OAAS,SAAUe,EAAIC,EAAIC,IACrEA,GAAMD","file":"kendo.drawing.min.js","sourcesContent":["/*!\n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n                                                                                                                                                                                                       \n\n*/\n(function (f, define) {\n    define('drawing/util', ['kendo.core'], f);\n}(function () {\n    (function ($) {\n        function createPromise() {\n            return $.Deferred();\n        }\n        function promiseAll(promises) {\n            return $.when.apply($, promises);\n        }\n        kendo.drawing.util = kendo.drawing.util || {};\n        kendo.deepExtend(kendo.drawing.util, {\n            createPromise: createPromise,\n            promiseAll: promiseAll\n        });\n    }(window.kendo.jQuery));\n    return window.kendo;\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('util/text-metrics', ['kendo.core'], f);\n}(function () {\n    (function ($) {\n        window.kendo.util = window.kendo.util || {};\n        var LRUCache = kendo.Class.extend({\n            init: function (size) {\n                this._size = size;\n                this._length = 0;\n                this._map = {};\n            },\n            put: function (key, value) {\n                var map = this._map;\n                var entry = {\n                    key: key,\n                    value: value\n                };\n                map[key] = entry;\n                if (!this._head) {\n                    this._head = this._tail = entry;\n                } else {\n                    this._tail.newer = entry;\n                    entry.older = this._tail;\n                    this._tail = entry;\n                }\n                if (this._length >= this._size) {\n                    map[this._head.key] = null;\n                    this._head = this._head.newer;\n                    this._head.older = null;\n                } else {\n                    this._length++;\n                }\n            },\n            get: function (key) {\n                var entry = this._map[key];\n                if (entry) {\n                    if (entry === this._head && entry !== this._tail) {\n                        this._head = entry.newer;\n                        this._head.older = null;\n                    }\n                    if (entry !== this._tail) {\n                        if (entry.older) {\n                            entry.older.newer = entry.newer;\n                            entry.newer.older = entry.older;\n                        }\n                        entry.older = this._tail;\n                        entry.newer = null;\n                        this._tail.newer = entry;\n                        this._tail = entry;\n                    }\n                    return entry.value;\n                }\n            }\n        });\n        var REPLACE_REGEX = /\\r?\\n|\\r|\\t/g;\n        var SPACE = ' ';\n        function normalizeText(text) {\n            return String(text).replace(REPLACE_REGEX, SPACE);\n        }\n        function objectKey(object) {\n            var parts = [];\n            for (var key in object) {\n                parts.push(key + object[key]);\n            }\n            return parts.sort().join('');\n        }\n        function hashKey(str) {\n            var hash = 2166136261;\n            for (var i = 0; i < str.length; ++i) {\n                hash += (hash << 1) + (hash << 4) + (hash << 7) + (hash << 8) + (hash << 24);\n                hash ^= str.charCodeAt(i);\n            }\n            return hash >>> 0;\n        }\n        function zeroSize() {\n            return {\n                width: 0,\n                height: 0,\n                baseline: 0\n            };\n        }\n        var DEFAULT_OPTIONS = { baselineMarkerSize: 1 };\n        var defaultMeasureBox;\n        if (typeof document !== 'undefined') {\n            defaultMeasureBox = document.createElement('div');\n            defaultMeasureBox.style.cssText = 'position: absolute !important; top: -4000px !important; width: auto !important; height: auto !important;' + 'padding: 0 !important; margin: 0 !important; border: 0 !important;' + 'line-height: normal !important; visibility: hidden !important; white-space: pre!important;';\n        }\n        var TextMetrics = kendo.Class.extend({\n            init: function (options) {\n                this._cache = new LRUCache(1000);\n                this.options = $.extend({}, DEFAULT_OPTIONS, options);\n            },\n            measure: function (text, style, options) {\n                if (options === void 0) {\n                    options = {};\n                }\n                if (!text) {\n                    return zeroSize();\n                }\n                var styleKey = objectKey(style);\n                var cacheKey = hashKey(text + styleKey);\n                var cachedResult = this._cache.get(cacheKey);\n                if (cachedResult) {\n                    return cachedResult;\n                }\n                var size = zeroSize();\n                var measureBox = options.box || defaultMeasureBox;\n                var baselineMarker = this._baselineMarker().cloneNode(false);\n                for (var key in style) {\n                    var value = style[key];\n                    if (typeof value !== 'undefined') {\n                        measureBox.style[key] = value;\n                    }\n                }\n                var textStr = options.normalizeText !== false ? normalizeText(text) : String(text);\n                measureBox.textContent = textStr;\n                measureBox.appendChild(baselineMarker);\n                document.body.appendChild(measureBox);\n                if (textStr.length) {\n                    size.width = measureBox.offsetWidth - this.options.baselineMarkerSize;\n                    size.height = measureBox.offsetHeight;\n                    size.baseline = baselineMarker.offsetTop + this.options.baselineMarkerSize;\n                }\n                if (size.width > 0 && size.height > 0) {\n                    this._cache.put(cacheKey, size);\n                }\n                measureBox.parentNode.removeChild(measureBox);\n                return size;\n            },\n            _baselineMarker: function () {\n                var marker = document.createElement('div');\n                marker.style.cssText = 'display: inline-block; vertical-align: baseline;width: ' + this.options.baselineMarkerSize + 'px; height: ' + this.options.baselineMarkerSize + 'px;overflow: hidden;';\n                return marker;\n            }\n        });\n        TextMetrics.current = new TextMetrics();\n        function measureText(text, style, measureBox) {\n            return TextMetrics.current.measure(text, style, measureBox);\n        }\n        kendo.deepExtend(kendo.util, {\n            LRUCache: LRUCache,\n            TextMetrics: TextMetrics,\n            measureText: measureText,\n            objectKey: objectKey,\n            hashKey: hashKey,\n            normalizeText: normalizeText\n        });\n    }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('drawing/kendo-drawing', [\n        'drawing/util',\n        'kendo.color',\n        'util/text-metrics'\n    ], f);\n}(function () {\n    (function ($) {\n        window.kendo = window.kendo || {};\n        var kendoDrawing = kendo.drawing;\n        var kendoDrawingUtil = kendoDrawing.util;\n        var Class = kendo.Class;\n        var kendoUtil = kendo.util;\n        var support = kendo.support;\n        var supportBrowser = support.browser;\n        var createPromise = kendoDrawingUtil.createPromise;\n        var promiseAll = kendoDrawingUtil.promiseAll;\n        var ObserversMixin = {\n            extend: function (proto) {\n                var this$1 = this;\n                for (var method in this) {\n                    if (method !== 'extend') {\n                        proto[method] = this$1[method];\n                    }\n                }\n            },\n            observers: function () {\n                this._observers = this._observers || [];\n                return this._observers;\n            },\n            addObserver: function (element) {\n                if (!this._observers) {\n                    this._observers = [element];\n                } else {\n                    this._observers.push(element);\n                }\n                return this;\n            },\n            removeObserver: function (element) {\n                var observers = this.observers();\n                var index = observers.indexOf(element);\n                if (index !== -1) {\n                    observers.splice(index, 1);\n                }\n                return this;\n            },\n            trigger: function (methodName, event) {\n                var observers = this._observers;\n                if (observers && !this._suspended) {\n                    for (var idx = 0; idx < observers.length; idx++) {\n                        var observer = observers[idx];\n                        if (observer[methodName]) {\n                            observer[methodName](event);\n                        }\n                    }\n                }\n                return this;\n            },\n            optionsChange: function (e) {\n                if (e === void 0) {\n                    e = {};\n                }\n                e.element = this;\n                this.trigger('optionsChange', e);\n            },\n            geometryChange: function () {\n                this.trigger('geometryChange', { element: this });\n            },\n            suspend: function () {\n                this._suspended = (this._suspended || 0) + 1;\n                return this;\n            },\n            resume: function () {\n                this._suspended = Math.max((this._suspended || 0) - 1, 0);\n                return this;\n            },\n            _observerField: function (field, value) {\n                if (this[field]) {\n                    this[field].removeObserver(this);\n                }\n                this[field] = value;\n                value.addObserver(this);\n            }\n        };\n        function append(first, second) {\n            first.push.apply(first, second);\n            return first;\n        }\n        var literals = {\n            1: 'i',\n            10: 'x',\n            100: 'c',\n            2: 'ii',\n            20: 'xx',\n            200: 'cc',\n            3: 'iii',\n            30: 'xxx',\n            300: 'ccc',\n            4: 'iv',\n            40: 'xl',\n            400: 'cd',\n            5: 'v',\n            50: 'l',\n            500: 'd',\n            6: 'vi',\n            60: 'lx',\n            600: 'dc',\n            7: 'vii',\n            70: 'lxx',\n            700: 'dcc',\n            8: 'viii',\n            80: 'lxxx',\n            800: 'dccc',\n            9: 'ix',\n            90: 'xc',\n            900: 'cm',\n            1000: 'm'\n        };\n        function arabicToRoman(n) {\n            var values = [\n                1000,\n                900,\n                800,\n                700,\n                600,\n                500,\n                400,\n                300,\n                200,\n                100,\n                90,\n                80,\n                70,\n                60,\n                50,\n                40,\n                30,\n                20,\n                10,\n                9,\n                8,\n                7,\n                6,\n                5,\n                4,\n                3,\n                2,\n                1\n            ];\n            var roman = '';\n            while (n > 0) {\n                if (n < values[0]) {\n                    values.shift();\n                } else {\n                    roman += literals[values[0]];\n                    n -= values[0];\n                }\n            }\n            return roman;\n        }\n        var UNDEFINED = 'undefined';\n        function defined(value) {\n            return typeof value !== UNDEFINED;\n        }\n        var defId = 1;\n        function definitionId() {\n            return 'kdef' + defId++;\n        }\n        var DEG_TO_RAD = Math.PI / 180;\n        var MAX_NUM = Number.MAX_VALUE;\n        var MIN_NUM = -Number.MAX_VALUE;\n        function deg(radians) {\n            return radians / DEG_TO_RAD;\n        }\n        var KEY_STR = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=';\n        var fromCharCode = String.fromCharCode;\n        function encodeUTF8(input) {\n            var output = '';\n            for (var i = 0; i < input.length; i++) {\n                var c = input.charCodeAt(i);\n                if (c < 128) {\n                    output += fromCharCode(c);\n                } else if (c < 2048) {\n                    output += fromCharCode(192 | c >>> 6);\n                    output += fromCharCode(128 | c & 63);\n                } else if (c < 65536) {\n                    output += fromCharCode(224 | c >>> 12);\n                    output += fromCharCode(128 | c >>> 6 & 63);\n                    output += fromCharCode(128 | c & 63);\n                }\n            }\n            return output;\n        }\n        function encodeBase64(input) {\n            var output = '';\n            var i = 0;\n            var utfInput = encodeUTF8(input);\n            while (i < utfInput.length) {\n                var chr1 = utfInput.charCodeAt(i++);\n                var chr2 = utfInput.charCodeAt(i++);\n                var chr3 = utfInput.charCodeAt(i++);\n                var enc1 = chr1 >> 2;\n                var enc2 = (chr1 & 3) << 4 | chr2 >> 4;\n                var enc3 = (chr2 & 15) << 2 | chr3 >> 6;\n                var enc4 = chr3 & 63;\n                if (isNaN(chr2)) {\n                    enc3 = enc4 = 64;\n                } else if (isNaN(chr3)) {\n                    enc4 = 64;\n                }\n                output = output + KEY_STR.charAt(enc1) + KEY_STR.charAt(enc2) + KEY_STR.charAt(enc3) + KEY_STR.charAt(enc4);\n            }\n            return output;\n        }\n        function eventCoordinates(e) {\n            if (defined((e.x || {}).location)) {\n                return {\n                    x: e.x.location,\n                    y: e.y.location\n                };\n            }\n            return {\n                x: e.pageX || e.clientX || 0,\n                y: e.pageY || e.clientY || 0\n            };\n        }\n        function eventElement(e) {\n            if (e === void 0) {\n                e = {};\n            }\n            return e.touch ? e.touch.initialTouch : e.target;\n        }\n        function isTransparent(color) {\n            return color === '' || color === null || color === 'none' || color === 'transparent' || !defined(color);\n        }\n        function last(array) {\n            if (array) {\n                return array[array.length - 1];\n            }\n        }\n        function limitValue(value, min, max) {\n            return Math.max(Math.min(value, max), min);\n        }\n        function mergeSort(a, cmp) {\n            if (a.length < 2) {\n                return a.slice();\n            }\n            function merge(a, b) {\n                var r = [], ai = 0, bi = 0, i = 0;\n                while (ai < a.length && bi < b.length) {\n                    if (cmp(a[ai], b[bi]) <= 0) {\n                        r[i++] = a[ai++];\n                    } else {\n                        r[i++] = b[bi++];\n                    }\n                }\n                if (ai < a.length) {\n                    r.push.apply(r, a.slice(ai));\n                }\n                if (bi < b.length) {\n                    r.push.apply(r, b.slice(bi));\n                }\n                return r;\n            }\n            return function sort(a) {\n                if (a.length <= 1) {\n                    return a;\n                }\n                var m = Math.floor(a.length / 2);\n                var left = a.slice(0, m);\n                var right = a.slice(m);\n                left = sort(left);\n                right = sort(right);\n                return merge(left, right);\n            }(a);\n        }\n        function rad(degrees) {\n            return degrees * DEG_TO_RAD;\n        }\n        function pow(p) {\n            if (p) {\n                return Math.pow(10, p);\n            }\n            return 1;\n        }\n        function round(value, precision) {\n            var power = pow(precision);\n            return Math.round(value * power) / power;\n        }\n        function valueOrDefault(value, defaultValue) {\n            return defined(value) ? value : defaultValue;\n        }\n        function bindEvents(element, events) {\n            for (var eventName in events) {\n                var eventNames = eventName.trim().split(' ');\n                for (var idx = 0; idx < eventNames.length; idx++) {\n                    element.addEventListener(eventNames[idx], events[eventName], false);\n                }\n            }\n        }\n        function elementOffset(element) {\n            var box = element.getBoundingClientRect();\n            var documentElement = document.documentElement;\n            return {\n                top: box.top + (window.pageYOffset || documentElement.scrollTop) - (documentElement.clientTop || 0),\n                left: box.left + (window.pageXOffset || documentElement.scrollLeft) - (documentElement.clientLeft || 0)\n            };\n        }\n        function elementStyles(element, styles) {\n            var result = {};\n            var style = window.getComputedStyle(element) || {};\n            var stylesArray = Array.isArray(styles) ? styles : [styles];\n            for (var idx = 0; idx < stylesArray.length; idx++) {\n                var field = stylesArray[idx];\n                result[field] = style[field];\n            }\n            return result;\n        }\n        function getPixels(value) {\n            if (isNaN(value)) {\n                return value;\n            }\n            return value + 'px';\n        }\n        function elementSize(element, size) {\n            if (size) {\n                var width = size.width;\n                var height = size.height;\n                if (defined(width)) {\n                    element.style.width = getPixels(width);\n                }\n                if (defined(height)) {\n                    element.style.height = getPixels(height);\n                }\n            } else {\n                var size$1 = elementStyles(element, [\n                    'width',\n                    'height'\n                ]);\n                return {\n                    width: parseInt(size$1.width, 10),\n                    height: parseInt(size$1.height, 10)\n                };\n            }\n        }\n        function unbindEvents(element, events) {\n            if (events === void 0) {\n                events = {};\n            }\n            for (var name in events) {\n                var eventNames = name.trim().split(' ');\n                for (var idx = 0; idx < eventNames.length; idx++) {\n                    element.removeEventListener(eventNames[idx], events[name], false);\n                }\n            }\n        }\n        var util = {\n            append: append,\n            arabicToRoman: arabicToRoman,\n            createPromise: createPromise,\n            defined: defined,\n            definitionId: definitionId,\n            deg: deg,\n            encodeBase64: encodeBase64,\n            eventCoordinates: eventCoordinates,\n            eventElement: eventElement,\n            isTransparent: isTransparent,\n            last: last,\n            limitValue: limitValue,\n            mergeSort: mergeSort,\n            promiseAll: promiseAll,\n            rad: rad,\n            round: round,\n            valueOrDefault: valueOrDefault,\n            bindEvents: bindEvents,\n            elementOffset: elementOffset,\n            elementSize: elementSize,\n            elementStyles: elementStyles,\n            unbindEvents: unbindEvents,\n            DEG_TO_RAD: DEG_TO_RAD,\n            MAX_NUM: MAX_NUM,\n            MIN_NUM: MIN_NUM\n        };\n        var toString = {}.toString;\n        var OptionsStore = Class.extend({\n            init: function (options, prefix) {\n                var this$1 = this;\n                if (prefix === void 0) {\n                    prefix = '';\n                }\n                this.prefix = prefix;\n                for (var field in options) {\n                    var member = options[field];\n                    member = this$1._wrap(member, field);\n                    this$1[field] = member;\n                }\n            },\n            get: function (field) {\n                var parts = field.split('.');\n                var result = this;\n                while (parts.length && result) {\n                    var part = parts.shift();\n                    result = result[part];\n                }\n                return result;\n            },\n            set: function (field, value) {\n                var current = this.get(field);\n                if (current !== value) {\n                    this._set(field, this._wrap(value, field));\n                    this.optionsChange({\n                        field: this.prefix + field,\n                        value: value\n                    });\n                }\n            },\n            _set: function (field, value) {\n                var this$1 = this;\n                var composite = field.indexOf('.') >= 0;\n                var parentObj = this;\n                var fieldName = field;\n                if (composite) {\n                    var parts = fieldName.split('.');\n                    var prefix = this.prefix;\n                    while (parts.length > 1) {\n                        fieldName = parts.shift();\n                        prefix += fieldName + '.';\n                        var obj = parentObj[fieldName];\n                        if (!obj) {\n                            obj = new OptionsStore({}, prefix);\n                            obj.addObserver(this$1);\n                            parentObj[fieldName] = obj;\n                        }\n                        parentObj = obj;\n                    }\n                    fieldName = parts[0];\n                }\n                parentObj._clear(fieldName);\n                parentObj[fieldName] = value;\n            },\n            _clear: function (field) {\n                var current = this[field];\n                if (current && current.removeObserver) {\n                    current.removeObserver(this);\n                }\n            },\n            _wrap: function (object, field) {\n                var type = toString.call(object);\n                var wrapped = object;\n                if (wrapped !== null && defined(wrapped) && type === '[object Object]') {\n                    if (!(object instanceof OptionsStore) && !(object instanceof Class)) {\n                        wrapped = new OptionsStore(wrapped, this.prefix + field + '.');\n                    }\n                    wrapped.addObserver(this);\n                }\n                return wrapped;\n            }\n        });\n        ObserversMixin.extend(OptionsStore.prototype);\n        function setAccessor(field) {\n            return function (value) {\n                if (this[field] !== value) {\n                    this[field] = value;\n                    this.geometryChange();\n                }\n                return this;\n            };\n        }\n        function getAccessor(field) {\n            return function () {\n                return this[field];\n            };\n        }\n        function defineAccessors(fn, fields) {\n            for (var i = 0; i < fields.length; i++) {\n                var name = fields[i];\n                var capitalized = name.charAt(0).toUpperCase() + name.substring(1, name.length);\n                fn['set' + capitalized] = setAccessor(name);\n                fn['get' + capitalized] = getAccessor(name);\n            }\n        }\n        var Matrix = Class.extend({\n            init: function (a, b, c, d, e, f) {\n                if (a === void 0) {\n                    a = 0;\n                }\n                if (b === void 0) {\n                    b = 0;\n                }\n                if (c === void 0) {\n                    c = 0;\n                }\n                if (d === void 0) {\n                    d = 0;\n                }\n                if (e === void 0) {\n                    e = 0;\n                }\n                if (f === void 0) {\n                    f = 0;\n                }\n                this.a = a;\n                this.b = b;\n                this.c = c;\n                this.d = d;\n                this.e = e;\n                this.f = f;\n            },\n            multiplyCopy: function (matrix) {\n                return new Matrix(this.a * matrix.a + this.c * matrix.b, this.b * matrix.a + this.d * matrix.b, this.a * matrix.c + this.c * matrix.d, this.b * matrix.c + this.d * matrix.d, this.a * matrix.e + this.c * matrix.f + this.e, this.b * matrix.e + this.d * matrix.f + this.f);\n            },\n            invert: function () {\n                var ref = this;\n                var a = ref.a;\n                var b = ref.b;\n                var d = ref.c;\n                var e = ref.d;\n                var g = ref.e;\n                var h = ref.f;\n                var det = a * e - b * d;\n                if (det === 0) {\n                    return null;\n                }\n                return new Matrix(e / det, -b / det, -d / det, a / det, (d * h - e * g) / det, (b * g - a * h) / det);\n            },\n            clone: function () {\n                return new Matrix(this.a, this.b, this.c, this.d, this.e, this.f);\n            },\n            equals: function (other) {\n                if (!other) {\n                    return false;\n                }\n                return this.a === other.a && this.b === other.b && this.c === other.c && this.d === other.d && this.e === other.e && this.f === other.f;\n            },\n            round: function (precision) {\n                this.a = round(this.a, precision);\n                this.b = round(this.b, precision);\n                this.c = round(this.c, precision);\n                this.d = round(this.d, precision);\n                this.e = round(this.e, precision);\n                this.f = round(this.f, precision);\n                return this;\n            },\n            toArray: function (precision) {\n                var result = [\n                    this.a,\n                    this.b,\n                    this.c,\n                    this.d,\n                    this.e,\n                    this.f\n                ];\n                if (defined(precision)) {\n                    for (var i = 0; i < result.length; i++) {\n                        result[i] = round(result[i], precision);\n                    }\n                }\n                return result;\n            },\n            toString: function (precision, separator) {\n                if (separator === void 0) {\n                    separator = ',';\n                }\n                return this.toArray(precision).join(separator);\n            }\n        });\n        Matrix.translate = function (x, y) {\n            return new Matrix(1, 0, 0, 1, x, y);\n        };\n        Matrix.unit = function () {\n            return new Matrix(1, 0, 0, 1, 0, 0);\n        };\n        Matrix.rotate = function (angle, x, y) {\n            var matrix = new Matrix();\n            matrix.a = Math.cos(rad(angle));\n            matrix.b = Math.sin(rad(angle));\n            matrix.c = -matrix.b;\n            matrix.d = matrix.a;\n            matrix.e = x - x * matrix.a + y * matrix.b || 0;\n            matrix.f = y - y * matrix.a - x * matrix.b || 0;\n            return matrix;\n        };\n        Matrix.scale = function (scaleX, scaleY) {\n            return new Matrix(scaleX, 0, 0, scaleY, 0, 0);\n        };\n        Matrix.IDENTITY = Matrix.unit();\n        function toMatrix(transformation) {\n            if (transformation && typeof transformation.matrix === 'function') {\n                return transformation.matrix();\n            }\n            return transformation;\n        }\n        var Point = Class.extend({\n            init: function (x, y) {\n                this.x = x || 0;\n                this.y = y || 0;\n            },\n            equals: function (other) {\n                return other && other.x === this.x && other.y === this.y;\n            },\n            clone: function () {\n                return new Point(this.x, this.y);\n            },\n            rotate: function (angle, origin) {\n                var originPoint = Point.create(origin) || Point.ZERO;\n                return this.transform(Matrix.rotate(angle, originPoint.x, originPoint.y));\n            },\n            translate: function (x, y) {\n                this.x += x;\n                this.y += y;\n                this.geometryChange();\n                return this;\n            },\n            translateWith: function (point) {\n                return this.translate(point.x, point.y);\n            },\n            move: function (x, y) {\n                this.x = this.y = 0;\n                return this.translate(x, y);\n            },\n            scale: function (scaleX, scaleY) {\n                if (scaleY === void 0) {\n                    scaleY = scaleX;\n                }\n                this.x *= scaleX;\n                this.y *= scaleY;\n                this.geometryChange();\n                return this;\n            },\n            scaleCopy: function (scaleX, scaleY) {\n                return this.clone().scale(scaleX, scaleY);\n            },\n            transform: function (transformation) {\n                var matrix = toMatrix(transformation);\n                var ref = this;\n                var x = ref.x;\n                var y = ref.y;\n                this.x = matrix.a * x + matrix.c * y + matrix.e;\n                this.y = matrix.b * x + matrix.d * y + matrix.f;\n                this.geometryChange();\n                return this;\n            },\n            transformCopy: function (transformation) {\n                var point = this.clone();\n                if (transformation) {\n                    point.transform(transformation);\n                }\n                return point;\n            },\n            distanceTo: function (point) {\n                var dx = this.x - point.x;\n                var dy = this.y - point.y;\n                return Math.sqrt(dx * dx + dy * dy);\n            },\n            round: function (digits) {\n                this.x = round(this.x, digits);\n                this.y = round(this.y, digits);\n                this.geometryChange();\n                return this;\n            },\n            toArray: function (digits) {\n                var doRound = defined(digits);\n                var x = doRound ? round(this.x, digits) : this.x;\n                var y = doRound ? round(this.y, digits) : this.y;\n                return [\n                    x,\n                    y\n                ];\n            },\n            toString: function (digits, separator) {\n                if (separator === void 0) {\n                    separator = ' ';\n                }\n                var ref = this;\n                var x = ref.x;\n                var y = ref.y;\n                if (defined(digits)) {\n                    x = round(x, digits);\n                    y = round(y, digits);\n                }\n                return x + separator + y;\n            }\n        });\n        Point.create = function (arg0, arg1) {\n            if (defined(arg0)) {\n                if (arg0 instanceof Point) {\n                    return arg0;\n                } else if (arguments.length === 1 && arg0.length === 2) {\n                    return new Point(arg0[0], arg0[1]);\n                }\n                return new Point(arg0, arg1);\n            }\n        };\n        Point.min = function () {\n            var arguments$1 = arguments;\n            var minX = MAX_NUM;\n            var minY = MAX_NUM;\n            for (var i = 0; i < arguments.length; i++) {\n                var point = arguments$1[i];\n                minX = Math.min(point.x, minX);\n                minY = Math.min(point.y, minY);\n            }\n            return new Point(minX, minY);\n        };\n        Point.max = function () {\n            var arguments$1 = arguments;\n            var maxX = MIN_NUM;\n            var maxY = MIN_NUM;\n            for (var i = 0; i < arguments.length; i++) {\n                var point = arguments$1[i];\n                maxX = Math.max(point.x, maxX);\n                maxY = Math.max(point.y, maxY);\n            }\n            return new Point(maxX, maxY);\n        };\n        Point.minPoint = function () {\n            return new Point(MIN_NUM, MIN_NUM);\n        };\n        Point.maxPoint = function () {\n            return new Point(MAX_NUM, MAX_NUM);\n        };\n        if (Object.defineProperties) {\n            Object.defineProperties(Point, {\n                ZERO: {\n                    get: function () {\n                        return new Point(0, 0);\n                    }\n                }\n            });\n        }\n        defineAccessors(Point.prototype, [\n            'x',\n            'y'\n        ]);\n        ObserversMixin.extend(Point.prototype);\n        var Size = Class.extend({\n            init: function (width, height) {\n                this.width = width || 0;\n                this.height = height || 0;\n            },\n            equals: function (other) {\n                return other && other.width === this.width && other.height === this.height;\n            },\n            clone: function () {\n                return new Size(this.width, this.height);\n            },\n            toArray: function (digits) {\n                var doRound = defined(digits);\n                var width = doRound ? round(this.width, digits) : this.width;\n                var height = doRound ? round(this.height, digits) : this.height;\n                return [\n                    width,\n                    height\n                ];\n            }\n        });\n        Size.create = function (arg0, arg1) {\n            if (defined(arg0)) {\n                if (arg0 instanceof Size) {\n                    return arg0;\n                } else if (arguments.length === 1 && arg0.length === 2) {\n                    return new Size(arg0[0], arg0[1]);\n                }\n                return new Size(arg0, arg1);\n            }\n        };\n        if (Object.defineProperties) {\n            Object.defineProperties(Size, {\n                ZERO: {\n                    get: function () {\n                        return new Size(0, 0);\n                    }\n                }\n            });\n        }\n        defineAccessors(Size.prototype, [\n            'width',\n            'height'\n        ]);\n        ObserversMixin.extend(Size.prototype);\n        var Rect = Class.extend({\n            init: function (origin, size) {\n                if (origin === void 0) {\n                    origin = new Point();\n                }\n                if (size === void 0) {\n                    size = new Size();\n                }\n                this.setOrigin(origin);\n                this.setSize(size);\n            },\n            clone: function () {\n                return new Rect(this.origin.clone(), this.size.clone());\n            },\n            equals: function (other) {\n                return other && other.origin.equals(this.origin) && other.size.equals(this.size);\n            },\n            setOrigin: function (value) {\n                this._observerField('origin', Point.create(value));\n                this.geometryChange();\n                return this;\n            },\n            getOrigin: function () {\n                return this.origin;\n            },\n            setSize: function (value) {\n                this._observerField('size', Size.create(value));\n                this.geometryChange();\n                return this;\n            },\n            getSize: function () {\n                return this.size;\n            },\n            width: function () {\n                return this.size.width;\n            },\n            height: function () {\n                return this.size.height;\n            },\n            topLeft: function () {\n                return this.origin.clone();\n            },\n            bottomRight: function () {\n                return this.origin.clone().translate(this.width(), this.height());\n            },\n            topRight: function () {\n                return this.origin.clone().translate(this.width(), 0);\n            },\n            bottomLeft: function () {\n                return this.origin.clone().translate(0, this.height());\n            },\n            center: function () {\n                return this.origin.clone().translate(this.width() / 2, this.height() / 2);\n            },\n            bbox: function (matrix) {\n                var tl = this.topLeft().transformCopy(matrix);\n                var tr = this.topRight().transformCopy(matrix);\n                var br = this.bottomRight().transformCopy(matrix);\n                var bl = this.bottomLeft().transformCopy(matrix);\n                return Rect.fromPoints(tl, tr, br, bl);\n            },\n            transformCopy: function (m) {\n                return Rect.fromPoints(this.topLeft().transform(m), this.bottomRight().transform(m));\n            },\n            expand: function (x, y) {\n                if (y === void 0) {\n                    y = x;\n                }\n                this.size.width += 2 * x;\n                this.size.height += 2 * y;\n                this.origin.translate(-x, -y);\n                return this;\n            },\n            expandCopy: function (x, y) {\n                return this.clone().expand(x, y);\n            },\n            containsPoint: function (point) {\n                var origin = this.origin;\n                var bottomRight = this.bottomRight();\n                return !(point.x < origin.x || point.y < origin.y || bottomRight.x < point.x || bottomRight.y < point.y);\n            },\n            _isOnPath: function (point, width) {\n                var rectOuter = this.expandCopy(width, width);\n                var rectInner = this.expandCopy(-width, -width);\n                return rectOuter.containsPoint(point) && !rectInner.containsPoint(point);\n            }\n        });\n        Rect.fromPoints = function () {\n            var topLeft = Point.min.apply(null, arguments);\n            var bottomRight = Point.max.apply(null, arguments);\n            var size = new Size(bottomRight.x - topLeft.x, bottomRight.y - topLeft.y);\n            return new Rect(topLeft, size);\n        };\n        Rect.union = function (a, b) {\n            return Rect.fromPoints(Point.min(a.topLeft(), b.topLeft()), Point.max(a.bottomRight(), b.bottomRight()));\n        };\n        Rect.intersect = function (a, b) {\n            var rect1 = {\n                left: a.topLeft().x,\n                top: a.topLeft().y,\n                right: a.bottomRight().x,\n                bottom: a.bottomRight().y\n            };\n            var rect2 = {\n                left: b.topLeft().x,\n                top: b.topLeft().y,\n                right: b.bottomRight().x,\n                bottom: b.bottomRight().y\n            };\n            if (rect1.left <= rect2.right && rect2.left <= rect1.right && rect1.top <= rect2.bottom && rect2.top <= rect1.bottom) {\n                return Rect.fromPoints(new Point(Math.max(rect1.left, rect2.left), Math.max(rect1.top, rect2.top)), new Point(Math.min(rect1.right, rect2.right), Math.min(rect1.bottom, rect2.bottom)));\n            }\n        };\n        ObserversMixin.extend(Rect.prototype);\n        var Transformation = Class.extend({\n            init: function (matrix) {\n                if (matrix === void 0) {\n                    matrix = Matrix.unit();\n                }\n                this._matrix = matrix;\n            },\n            clone: function () {\n                return new Transformation(this._matrix.clone());\n            },\n            equals: function (other) {\n                return other && other._matrix.equals(this._matrix);\n            },\n            translate: function (x, y) {\n                this._matrix = this._matrix.multiplyCopy(Matrix.translate(x, y));\n                this._optionsChange();\n                return this;\n            },\n            scale: function (scaleX, scaleY, origin) {\n                if (scaleY === void 0) {\n                    scaleY = scaleX;\n                }\n                if (origin === void 0) {\n                    origin = null;\n                }\n                var originPoint = origin;\n                if (originPoint) {\n                    originPoint = Point.create(originPoint);\n                    this._matrix = this._matrix.multiplyCopy(Matrix.translate(originPoint.x, originPoint.y));\n                }\n                this._matrix = this._matrix.multiplyCopy(Matrix.scale(scaleX, scaleY));\n                if (originPoint) {\n                    this._matrix = this._matrix.multiplyCopy(Matrix.translate(-originPoint.x, -originPoint.y));\n                }\n                this._optionsChange();\n                return this;\n            },\n            rotate: function (angle, origin) {\n                var originPoint = Point.create(origin) || Point.ZERO;\n                this._matrix = this._matrix.multiplyCopy(Matrix.rotate(angle, originPoint.x, originPoint.y));\n                this._optionsChange();\n                return this;\n            },\n            multiply: function (transformation) {\n                var matrix = toMatrix(transformation);\n                this._matrix = this._matrix.multiplyCopy(matrix);\n                this._optionsChange();\n                return this;\n            },\n            matrix: function (value) {\n                if (value) {\n                    this._matrix = value;\n                    this._optionsChange();\n                    return this;\n                }\n                return this._matrix;\n            },\n            _optionsChange: function () {\n                this.optionsChange({\n                    field: 'transform',\n                    value: this\n                });\n            }\n        });\n        ObserversMixin.extend(Transformation.prototype);\n        function transform(matrix) {\n            if (matrix === null) {\n                return null;\n            }\n            if (matrix instanceof Transformation) {\n                return matrix;\n            }\n            return new Transformation(matrix);\n        }\n        var Element$1 = Class.extend({\n            init: function (options) {\n                this._initOptions(options);\n            },\n            _initOptions: function (options) {\n                if (options === void 0) {\n                    options = {};\n                }\n                var clip = options.clip;\n                var transform$$1 = options.transform;\n                if (transform$$1) {\n                    options.transform = transform(transform$$1);\n                }\n                if (clip && !clip.id) {\n                    clip.id = definitionId();\n                }\n                this.options = new OptionsStore(options);\n                this.options.addObserver(this);\n            },\n            transform: function (value) {\n                if (defined(value)) {\n                    this.options.set('transform', transform(value));\n                } else {\n                    return this.options.get('transform');\n                }\n            },\n            parentTransform: function () {\n                var element = this;\n                var parentMatrix;\n                while (element.parent) {\n                    element = element.parent;\n                    var transformation = element.transform();\n                    if (transformation) {\n                        parentMatrix = transformation.matrix().multiplyCopy(parentMatrix || Matrix.unit());\n                    }\n                }\n                if (parentMatrix) {\n                    return transform(parentMatrix);\n                }\n            },\n            currentTransform: function (parentTransform) {\n                if (parentTransform === void 0) {\n                    parentTransform = this.parentTransform();\n                }\n                var elementTransform = this.transform();\n                var elementMatrix = toMatrix(elementTransform);\n                var parentMatrix = toMatrix(parentTransform);\n                var combinedMatrix;\n                if (elementMatrix && parentMatrix) {\n                    combinedMatrix = parentMatrix.multiplyCopy(elementMatrix);\n                } else {\n                    combinedMatrix = elementMatrix || parentMatrix;\n                }\n                if (combinedMatrix) {\n                    return transform(combinedMatrix);\n                }\n            },\n            visible: function (value) {\n                if (defined(value)) {\n                    this.options.set('visible', value);\n                    return this;\n                }\n                return this.options.get('visible') !== false;\n            },\n            clip: function (value) {\n                var options = this.options;\n                if (defined(value)) {\n                    if (value && !value.id) {\n                        value.id = definitionId();\n                    }\n                    options.set('clip', value);\n                    return this;\n                }\n                return options.get('clip');\n            },\n            opacity: function (value) {\n                if (defined(value)) {\n                    this.options.set('opacity', value);\n                    return this;\n                }\n                return valueOrDefault(this.options.get('opacity'), 1);\n            },\n            clippedBBox: function (transformation) {\n                var bbox = this._clippedBBox(transformation);\n                if (bbox) {\n                    var clip = this.clip();\n                    return clip ? Rect.intersect(bbox, clip.bbox(transformation)) : bbox;\n                }\n            },\n            containsPoint: function (point, parentTransform) {\n                if (this.visible()) {\n                    var transform$$1 = this.currentTransform(parentTransform);\n                    var transformedPoint = point;\n                    if (transform$$1) {\n                        transformedPoint = point.transformCopy(transform$$1.matrix().invert());\n                    }\n                    return this._hasFill() && this._containsPoint(transformedPoint) || this._isOnPath && this._hasStroke() && this._isOnPath(transformedPoint);\n                }\n                return false;\n            },\n            _hasFill: function () {\n                var fill = this.options.fill;\n                return fill && !isTransparent(fill.color);\n            },\n            _hasStroke: function () {\n                var stroke = this.options.stroke;\n                return stroke && stroke.width > 0 && !isTransparent(stroke.color);\n            },\n            _clippedBBox: function (transformation) {\n                return this.bbox(transformation);\n            }\n        });\n        Element$1.prototype.nodeType = 'Element';\n        ObserversMixin.extend(Element$1.prototype);\n        function ellipseExtremeAngles(center, rx, ry, matrix) {\n            var extremeX = 0;\n            var extremeY = 0;\n            if (matrix) {\n                extremeX = Math.atan2(matrix.c * ry, matrix.a * rx);\n                if (matrix.b !== 0) {\n                    extremeY = Math.atan2(matrix.d * ry, matrix.b * rx);\n                }\n            }\n            return {\n                x: extremeX,\n                y: extremeY\n            };\n        }\n        var PI_DIV_2 = Math.PI / 2;\n        var Circle$2 = Class.extend({\n            init: function (center, radius) {\n                if (center === void 0) {\n                    center = new Point();\n                }\n                if (radius === void 0) {\n                    radius = 0;\n                }\n                this.setCenter(center);\n                this.setRadius(radius);\n            },\n            setCenter: function (value) {\n                this._observerField('center', Point.create(value));\n                this.geometryChange();\n                return this;\n            },\n            getCenter: function () {\n                return this.center;\n            },\n            equals: function (other) {\n                return other && other.center.equals(this.center) && other.radius === this.radius;\n            },\n            clone: function () {\n                return new Circle$2(this.center.clone(), this.radius);\n            },\n            pointAt: function (angle) {\n                return this._pointAt(rad(angle));\n            },\n            bbox: function (matrix) {\n                var this$1 = this;\n                var extremeAngles = ellipseExtremeAngles(this.center, this.radius, this.radius, matrix);\n                var minPoint = Point.maxPoint();\n                var maxPoint = Point.minPoint();\n                for (var i = 0; i < 4; i++) {\n                    var currentPointX = this$1._pointAt(extremeAngles.x + i * PI_DIV_2).transformCopy(matrix);\n                    var currentPointY = this$1._pointAt(extremeAngles.y + i * PI_DIV_2).transformCopy(matrix);\n                    var currentPoint = new Point(currentPointX.x, currentPointY.y);\n                    minPoint = Point.min(minPoint, currentPoint);\n                    maxPoint = Point.max(maxPoint, currentPoint);\n                }\n                return Rect.fromPoints(minPoint, maxPoint);\n            },\n            _pointAt: function (angle) {\n                var ref = this;\n                var center = ref.center;\n                var radius = ref.radius;\n                return new Point(center.x + radius * Math.cos(angle), center.y + radius * Math.sin(angle));\n            },\n            containsPoint: function (point) {\n                var ref = this;\n                var center = ref.center;\n                var radius = ref.radius;\n                var inCircle = Math.pow(point.x - center.x, 2) + Math.pow(point.y - center.y, 2) <= Math.pow(radius, 2);\n                return inCircle;\n            },\n            _isOnPath: function (point, width) {\n                var ref = this;\n                var center = ref.center;\n                var radius = ref.radius;\n                var pointDistance = center.distanceTo(point);\n                return radius - width <= pointDistance && pointDistance <= radius + width;\n            }\n        });\n        defineAccessors(Circle$2.prototype, ['radius']);\n        ObserversMixin.extend(Circle$2.prototype);\n        var GRADIENT = 'Gradient';\n        var Paintable = {\n            extend: function (proto) {\n                proto.fill = this.fill;\n                proto.stroke = this.stroke;\n            },\n            fill: function (color, opacity) {\n                var options = this.options;\n                if (defined(color)) {\n                    if (color && color.nodeType !== GRADIENT) {\n                        var newFill = { color: color };\n                        if (defined(opacity)) {\n                            newFill.opacity = opacity;\n                        }\n                        options.set('fill', newFill);\n                    } else {\n                        options.set('fill', color);\n                    }\n                    return this;\n                }\n                return options.get('fill');\n            },\n            stroke: function (color, width, opacity) {\n                if (defined(color)) {\n                    this.options.set('stroke.color', color);\n                    if (defined(width)) {\n                        this.options.set('stroke.width', width);\n                    }\n                    if (defined(opacity)) {\n                        this.options.set('stroke.opacity', opacity);\n                    }\n                    return this;\n                }\n                return this.options.get('stroke');\n            }\n        };\n        var IDENTITY_MATRIX_HASH = Matrix.IDENTITY.toString();\n        var Measurable = {\n            extend: function (proto) {\n                proto.bbox = this.bbox;\n                proto.geometryChange = this.geometryChange;\n            },\n            bbox: function (transformation) {\n                var combinedMatrix = toMatrix(this.currentTransform(transformation));\n                var matrixHash = combinedMatrix ? combinedMatrix.toString() : IDENTITY_MATRIX_HASH;\n                var bbox;\n                if (this._bboxCache && this._matrixHash === matrixHash) {\n                    bbox = this._bboxCache.clone();\n                } else {\n                    bbox = this._bbox(combinedMatrix);\n                    this._bboxCache = bbox ? bbox.clone() : null;\n                    this._matrixHash = matrixHash;\n                }\n                var strokeWidth = this.options.get('stroke.width');\n                if (strokeWidth && bbox) {\n                    bbox.expand(strokeWidth / 2);\n                }\n                return bbox;\n            },\n            geometryChange: function () {\n                delete this._bboxCache;\n                this.trigger('geometryChange', { element: this });\n            }\n        };\n        function geometryAccessor(name) {\n            var fieldName = '_' + name;\n            return function (value) {\n                if (defined(value)) {\n                    this._observerField(fieldName, value);\n                    this.geometryChange();\n                    return this;\n                }\n                return this[fieldName];\n            };\n        }\n        function defineGeometryAccessors(fn, names) {\n            for (var i = 0; i < names.length; i++) {\n                fn[names[i]] = geometryAccessor(names[i]);\n            }\n        }\n        var DEFAULT_STROKE = '#000';\n        var Circle = Element$1.extend({\n            init: function (geometry, options) {\n                if (geometry === void 0) {\n                    geometry = new Circle$2();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                Element$1.fn.init.call(this, options);\n                this.geometry(geometry);\n                if (!defined(this.options.stroke)) {\n                    this.stroke(DEFAULT_STROKE);\n                }\n            },\n            rawBBox: function () {\n                return this._geometry.bbox();\n            },\n            _bbox: function (matrix) {\n                return this._geometry.bbox(matrix);\n            },\n            _containsPoint: function (point) {\n                return this.geometry().containsPoint(point);\n            },\n            _isOnPath: function (point) {\n                return this.geometry()._isOnPath(point, this.options.stroke.width / 2);\n            }\n        });\n        Circle.prototype.nodeType = 'Circle';\n        Paintable.extend(Circle.prototype);\n        Measurable.extend(Circle.prototype);\n        defineGeometryAccessors(Circle.prototype, ['geometry']);\n        var PRECISION = 10;\n        function close(a, b, tolerance) {\n            if (tolerance === void 0) {\n                tolerance = PRECISION;\n            }\n            return round(Math.abs(a - b), tolerance) === 0;\n        }\n        function closeOrLess(a, b, tolerance) {\n            return a < b || close(a, b, tolerance);\n        }\n        function lineIntersection(p0, p1, p2, p3) {\n            var s1x = p1.x - p0.x;\n            var s2x = p3.x - p2.x;\n            var s1y = p1.y - p0.y;\n            var s2y = p3.y - p2.y;\n            var nx = p0.x - p2.x;\n            var ny = p0.y - p2.y;\n            var d = s1x * s2y - s2x * s1y;\n            var s = (s1x * ny - s1y * nx) / d;\n            var t = (s2x * ny - s2y * nx) / d;\n            if (s >= 0 && s <= 1 && t >= 0 && t <= 1) {\n                return new Point(p0.x + t * s1x, p0.y + t * s1y);\n            }\n        }\n        var MAX_INTERVAL = 45;\n        var pow$1 = Math.pow;\n        var Arc$2 = Class.extend({\n            init: function (center, options) {\n                if (center === void 0) {\n                    center = new Point();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                this.setCenter(center);\n                this.radiusX = options.radiusX;\n                this.radiusY = options.radiusY || options.radiusX;\n                this.startAngle = options.startAngle;\n                this.endAngle = options.endAngle;\n                this.anticlockwise = options.anticlockwise || false;\n                this.xRotation = options.xRotation;\n            },\n            clone: function () {\n                return new Arc$2(this.center, {\n                    radiusX: this.radiusX,\n                    radiusY: this.radiusY,\n                    startAngle: this.startAngle,\n                    endAngle: this.endAngle,\n                    anticlockwise: this.anticlockwise\n                });\n            },\n            setCenter: function (value) {\n                this._observerField('center', Point.create(value));\n                this.geometryChange();\n                return this;\n            },\n            getCenter: function () {\n                return this.center;\n            },\n            pointAt: function (angle) {\n                var center = this.center;\n                var radian = rad(angle);\n                return new Point(center.x + this.radiusX * Math.cos(radian), center.y + this.radiusY * Math.sin(radian));\n            },\n            curvePoints: function () {\n                var this$1 = this;\n                var startAngle = this.startAngle;\n                var dir = this.anticlockwise ? -1 : 1;\n                var curvePoints = [this.pointAt(startAngle)];\n                var interval = this._arcInterval();\n                var intervalAngle = interval.endAngle - interval.startAngle;\n                var subIntervalsCount = Math.ceil(intervalAngle / MAX_INTERVAL);\n                var subIntervalAngle = intervalAngle / subIntervalsCount;\n                var currentAngle = startAngle;\n                var transformation;\n                if (this.xRotation) {\n                    transformation = transform().rotate(this.xRotation, this.center);\n                }\n                for (var i = 1; i <= subIntervalsCount; i++) {\n                    var nextAngle = currentAngle + dir * subIntervalAngle;\n                    var points = this$1._intervalCurvePoints(currentAngle, nextAngle, transformation);\n                    curvePoints.push(points.cp1, points.cp2, points.p2);\n                    currentAngle = nextAngle;\n                }\n                return curvePoints;\n            },\n            bbox: function (matrix) {\n                var this$1 = this;\n                var interval = this._arcInterval();\n                var startAngle = interval.startAngle;\n                var endAngle = interval.endAngle;\n                var extremeAngles = ellipseExtremeAngles(this.center, this.radiusX, this.radiusY, matrix);\n                var extremeX = deg(extremeAngles.x);\n                var extremeY = deg(extremeAngles.y);\n                var endPoint = this.pointAt(endAngle).transformCopy(matrix);\n                var currentAngleX = bboxStartAngle(extremeX, startAngle);\n                var currentAngleY = bboxStartAngle(extremeY, startAngle);\n                var currentPoint = this.pointAt(startAngle).transformCopy(matrix);\n                var minPoint = Point.min(currentPoint, endPoint);\n                var maxPoint = Point.max(currentPoint, endPoint);\n                while (currentAngleX < endAngle || currentAngleY < endAngle) {\n                    var currentPointX = void 0;\n                    if (currentAngleX < endAngle) {\n                        currentPointX = this$1.pointAt(currentAngleX).transformCopy(matrix);\n                        currentAngleX += 90;\n                    }\n                    var currentPointY = void 0;\n                    if (currentAngleY < endAngle) {\n                        currentPointY = this$1.pointAt(currentAngleY).transformCopy(matrix);\n                        currentAngleY += 90;\n                    }\n                    currentPoint = new Point(currentPointX.x, currentPointY.y);\n                    minPoint = Point.min(minPoint, currentPoint);\n                    maxPoint = Point.max(maxPoint, currentPoint);\n                }\n                return Rect.fromPoints(minPoint, maxPoint);\n            },\n            _arcInterval: function () {\n                var ref = this;\n                var startAngle = ref.startAngle;\n                var endAngle = ref.endAngle;\n                var anticlockwise = ref.anticlockwise;\n                if (anticlockwise) {\n                    var oldStart = startAngle;\n                    startAngle = endAngle;\n                    endAngle = oldStart;\n                }\n                if (startAngle > endAngle || anticlockwise && startAngle === endAngle) {\n                    endAngle += 360;\n                }\n                return {\n                    startAngle: startAngle,\n                    endAngle: endAngle\n                };\n            },\n            _intervalCurvePoints: function (startAngle, endAngle, transformation) {\n                var p1 = this.pointAt(startAngle);\n                var p2 = this.pointAt(endAngle);\n                var p1Derivative = this._derivativeAt(startAngle);\n                var p2Derivative = this._derivativeAt(endAngle);\n                var t = (rad(endAngle) - rad(startAngle)) / 3;\n                var cp1 = new Point(p1.x + t * p1Derivative.x, p1.y + t * p1Derivative.y);\n                var cp2 = new Point(p2.x - t * p2Derivative.x, p2.y - t * p2Derivative.y);\n                if (transformation) {\n                    p1.transform(transformation);\n                    p2.transform(transformation);\n                    cp1.transform(transformation);\n                    cp2.transform(transformation);\n                }\n                return {\n                    p1: p1,\n                    cp1: cp1,\n                    cp2: cp2,\n                    p2: p2\n                };\n            },\n            _derivativeAt: function (angle) {\n                var radian = rad(angle);\n                return new Point(-this.radiusX * Math.sin(radian), this.radiusY * Math.cos(radian));\n            },\n            containsPoint: function (point) {\n                var interval = this._arcInterval();\n                var intervalAngle = interval.endAngle - interval.startAngle;\n                var ref = this;\n                var center = ref.center;\n                var radiusX = ref.radiusX;\n                var radiusY = ref.radiusY;\n                var distance = center.distanceTo(point);\n                var angleRad = Math.atan2(point.y - center.y, point.x - center.x);\n                var pointRadius = radiusX * radiusY / Math.sqrt(pow$1(radiusX, 2) * pow$1(Math.sin(angleRad), 2) + pow$1(radiusY, 2) * pow$1(Math.cos(angleRad), 2));\n                var startPoint = this.pointAt(this.startAngle).round(PRECISION);\n                var endPoint = this.pointAt(this.endAngle).round(PRECISION);\n                var intersection = lineIntersection(center, point.round(PRECISION), startPoint, endPoint);\n                var containsPoint;\n                if (intervalAngle < 180) {\n                    containsPoint = intersection && closeOrLess(center.distanceTo(intersection), distance) && closeOrLess(distance, pointRadius);\n                } else {\n                    var angle = calculateAngle(center.x, center.y, radiusX, radiusY, point.x, point.y);\n                    if (angle !== 360) {\n                        angle = (360 + angle) % 360;\n                    }\n                    var inAngleRange = interval.startAngle <= angle && angle <= interval.endAngle;\n                    containsPoint = inAngleRange && closeOrLess(distance, pointRadius) || !inAngleRange && (!intersection || intersection.equals(point));\n                }\n                return containsPoint;\n            },\n            _isOnPath: function (point, width) {\n                var interval = this._arcInterval();\n                var center = this.center;\n                var angle = calculateAngle(center.x, center.y, this.radiusX, this.radiusY, point.x, point.y);\n                if (angle !== 360) {\n                    angle = (360 + angle) % 360;\n                }\n                var inAngleRange = interval.startAngle <= angle && angle <= interval.endAngle;\n                return inAngleRange && this.pointAt(angle).distanceTo(point) <= width;\n            }\n        });\n        Arc$2.fromPoints = function (start, end, rx, ry, largeArc, swipe, rotation) {\n            var arcParameters = normalizeArcParameters({\n                x1: start.x,\n                y1: start.y,\n                x2: end.x,\n                y2: end.y,\n                rx: rx,\n                ry: ry,\n                largeArc: largeArc,\n                swipe: swipe,\n                rotation: rotation\n            });\n            return new Arc$2(arcParameters.center, {\n                startAngle: arcParameters.startAngle,\n                endAngle: arcParameters.endAngle,\n                radiusX: arcParameters.radiusX,\n                radiusY: arcParameters.radiusY,\n                xRotation: arcParameters.xRotation,\n                anticlockwise: swipe === 0\n            });\n        };\n        defineAccessors(Arc$2.prototype, [\n            'radiusX',\n            'radiusY',\n            'startAngle',\n            'endAngle',\n            'anticlockwise'\n        ]);\n        ObserversMixin.extend(Arc$2.prototype);\n        function calculateAngle(cx, cy, rx, ry, x, y) {\n            var cos = round((x - cx) / rx, 3);\n            var sin = round((y - cy) / ry, 3);\n            return round(deg(Math.atan2(sin, cos)));\n        }\n        function normalizeArcParameters(parameters) {\n            var x1 = parameters.x1;\n            var y1 = parameters.y1;\n            var x2 = parameters.x2;\n            var y2 = parameters.y2;\n            var rx = parameters.rx;\n            var ry = parameters.ry;\n            var largeArc = parameters.largeArc;\n            var swipe = parameters.swipe;\n            var rotation = parameters.rotation;\n            if (rotation === void 0) {\n                rotation = 0;\n            }\n            var radians = rad(rotation);\n            var cosine = Math.cos(radians);\n            var sine = Math.sin(radians);\n            var xT = cosine * (x1 - x2) / 2 + sine * (y1 - y2) / 2;\n            var yT = -sine * (x1 - x2) / 2 + cosine * (y1 - y2) / 2;\n            var sign = largeArc !== swipe ? 1 : -1;\n            var xt2 = Math.pow(xT, 2);\n            var yt2 = Math.pow(yT, 2);\n            var rx2 = Math.pow(rx, 2);\n            var ry2 = Math.pow(ry, 2);\n            var delta = xt2 / rx2 + yt2 / ry2;\n            if (delta > 1) {\n                delta = Math.sqrt(xt2 / rx2 + yt2 / ry2);\n                rx = delta * rx;\n                rx2 = Math.pow(rx, 2);\n                ry = delta * ry;\n                ry2 = Math.pow(ry, 2);\n            }\n            var constT = sign * Math.sqrt((rx2 * ry2 - rx2 * yt2 - ry2 * xt2) / (rx2 * yt2 + ry2 * xt2));\n            if (isNaN(constT)) {\n                constT = 0;\n            }\n            var cxT = constT * (rx * yT) / ry;\n            var cyT = -constT * (ry * xT) / rx;\n            var cx = cosine * cxT - sine * cyT + (x1 + x2) / 2;\n            var cy = sine * cxT + cosine * cyT + (y1 + y2) / 2;\n            var uX = (xT - cxT) / rx;\n            var uY = (yT - cyT) / ry;\n            var vX = -(xT + cxT) / rx;\n            var vY = -(yT + cyT) / ry;\n            var startAngle = (uY >= 0 ? 1 : -1) * deg(Math.acos(uX / Math.sqrt(uX * uX + uY * uY)));\n            var angleCosine = round((uX * vX + uY * vY) / (Math.sqrt(uX * uX + uY * uY) * Math.sqrt(vX * vX + vY * vY)), 10);\n            var angle = (uX * vY - uY * vX >= 0 ? 1 : -1) * deg(Math.acos(angleCosine));\n            if (!swipe && angle > 0) {\n                angle -= 360;\n            }\n            if (swipe && angle < 0) {\n                angle += 360;\n            }\n            var endAngle = startAngle + angle;\n            var signEndAngle = endAngle >= 0 ? 1 : -1;\n            endAngle = Math.abs(endAngle) % 360 * signEndAngle;\n            return {\n                center: new Point(cx, cy),\n                startAngle: startAngle,\n                endAngle: endAngle,\n                radiusX: rx,\n                radiusY: ry,\n                xRotation: rotation\n            };\n        }\n        function bboxStartAngle(angle, start) {\n            var startAngle = angle;\n            while (startAngle < start) {\n                startAngle += 90;\n            }\n            return startAngle;\n        }\n        var push = [].push;\n        var pop = [].pop;\n        var splice = [].splice;\n        var shift = [].shift;\n        var slice = [].slice;\n        var unshift = [].unshift;\n        var ElementsArray = Class.extend({\n            init: function (array) {\n                if (array === void 0) {\n                    array = [];\n                }\n                this.length = 0;\n                this._splice(0, array.length, array);\n            },\n            elements: function (value) {\n                if (value) {\n                    this._splice(0, this.length, value);\n                    this._change();\n                    return this;\n                }\n                return this.slice(0);\n            },\n            push: function () {\n                var elements = arguments;\n                var result = push.apply(this, elements);\n                this._add(elements);\n                return result;\n            },\n            slice: function () {\n                return slice.call(this);\n            },\n            pop: function () {\n                var length = this.length;\n                var result = pop.apply(this);\n                if (length) {\n                    this._remove([result]);\n                }\n                return result;\n            },\n            splice: function (index, howMany) {\n                var elements = slice.call(arguments, 2);\n                var result = this._splice(index, howMany, elements);\n                this._change();\n                return result;\n            },\n            shift: function () {\n                var length = this.length;\n                var result = shift.apply(this);\n                if (length) {\n                    this._remove([result]);\n                }\n                return result;\n            },\n            unshift: function () {\n                var elements = arguments;\n                var result = unshift.apply(this, elements);\n                this._add(elements);\n                return result;\n            },\n            indexOf: function (element) {\n                var this$1 = this;\n                var length = this.length;\n                for (var idx = 0; idx < length; idx++) {\n                    if (this$1[idx] === element) {\n                        return idx;\n                    }\n                }\n                return -1;\n            },\n            _splice: function (index, howMany, elements) {\n                var result = splice.apply(this, [\n                    index,\n                    howMany\n                ].concat(elements));\n                this._clearObserver(result);\n                this._setObserver(elements);\n                return result;\n            },\n            _add: function (elements) {\n                this._setObserver(elements);\n                this._change();\n            },\n            _remove: function (elements) {\n                this._clearObserver(elements);\n                this._change();\n            },\n            _setObserver: function (elements) {\n                var this$1 = this;\n                for (var idx = 0; idx < elements.length; idx++) {\n                    elements[idx].addObserver(this$1);\n                }\n            },\n            _clearObserver: function (elements) {\n                var this$1 = this;\n                for (var idx = 0; idx < elements.length; idx++) {\n                    elements[idx].removeObserver(this$1);\n                }\n            },\n            _change: function () {\n            }\n        });\n        ObserversMixin.extend(ElementsArray.prototype);\n        var GeometryElementsArray = ElementsArray.extend({\n            _change: function () {\n                this.geometryChange();\n            }\n        });\n        function pointAccessor(name) {\n            var fieldName = '_' + name;\n            return function (value) {\n                if (defined(value)) {\n                    this._observerField(fieldName, Point.create(value));\n                    this.geometryChange();\n                    return this;\n                }\n                return this[fieldName];\n            };\n        }\n        function definePointAccessors(fn, names) {\n            for (var i = 0; i < names.length; i++) {\n                fn[names[i]] = pointAccessor(names[i]);\n            }\n        }\n        function isOutOfEndPoint(endPoint, controlPoint, point) {\n            var angle = deg(Math.atan2(controlPoint.y - endPoint.y, controlPoint.x - endPoint.x));\n            var rotatedPoint = point.transformCopy(transform().rotate(-angle, endPoint));\n            return rotatedPoint.x < endPoint.x;\n        }\n        function calculateCurveAt(t, field, points) {\n            var t1 = 1 - t;\n            return Math.pow(t1, 3) * points[0][field] + 3 * Math.pow(t1, 2) * t * points[1][field] + 3 * Math.pow(t, 2) * t1 * points[2][field] + Math.pow(t, 3) * points[3][field];\n        }\n        function toCubicPolynomial(points, field) {\n            return [\n                -points[0][field] + 3 * points[1][field] - 3 * points[2][field] + points[3][field],\n                3 * (points[0][field] - 2 * points[1][field] + points[2][field]),\n                3 * (-points[0][field] + points[1][field]),\n                points[0][field]\n            ];\n        }\n        var ComplexNumber = Class.extend({\n            init: function (real, img) {\n                if (real === void 0) {\n                    real = 0;\n                }\n                if (img === void 0) {\n                    img = 0;\n                }\n                this.real = real;\n                this.img = img;\n            },\n            add: function (cNumber) {\n                return new ComplexNumber(round(this.real + cNumber.real, PRECISION), round(this.img + cNumber.img, PRECISION));\n            },\n            addConstant: function (value) {\n                return new ComplexNumber(this.real + value, this.img);\n            },\n            negate: function () {\n                return new ComplexNumber(-this.real, -this.img);\n            },\n            multiply: function (cNumber) {\n                return new ComplexNumber(this.real * cNumber.real - this.img * cNumber.img, this.real * cNumber.img + this.img * cNumber.real);\n            },\n            multiplyConstant: function (value) {\n                return new ComplexNumber(this.real * value, this.img * value);\n            },\n            nthRoot: function (n) {\n                var rad$$1 = Math.atan2(this.img, this.real);\n                var r = Math.sqrt(Math.pow(this.img, 2) + Math.pow(this.real, 2));\n                var nthR = Math.pow(r, 1 / n);\n                return new ComplexNumber(nthR * Math.cos(rad$$1 / n), nthR * Math.sin(rad$$1 / n));\n            },\n            equals: function (cNumber) {\n                return this.real === cNumber.real && this.img === cNumber.img;\n            },\n            isReal: function () {\n                return this.img === 0;\n            }\n        });\n        function numberSign(x) {\n            return x < 0 ? -1 : 1;\n        }\n        function solveQuadraticEquation(a, b, c) {\n            var squareRoot = Math.sqrt(Math.pow(b, 2) - 4 * a * c);\n            return [\n                (-b + squareRoot) / (2 * a),\n                (-b - squareRoot) / (2 * a)\n            ];\n        }\n        function solveCubicEquation(a, b, c, d) {\n            if (a === 0) {\n                return solveQuadraticEquation(b, c, d);\n            }\n            var p = (3 * a * c - Math.pow(b, 2)) / (3 * Math.pow(a, 2));\n            var q = (2 * Math.pow(b, 3) - 9 * a * b * c + 27 * Math.pow(a, 2) * d) / (27 * Math.pow(a, 3));\n            var Q = Math.pow(p / 3, 3) + Math.pow(q / 2, 2);\n            var i = new ComplexNumber(0, 1);\n            var b3a = -b / (3 * a);\n            var x1, x2, y1, y2, y3, z1, z2;\n            if (Q < 0) {\n                x1 = new ComplexNumber(-q / 2, Math.sqrt(-Q)).nthRoot(3);\n                x2 = new ComplexNumber(-q / 2, -Math.sqrt(-Q)).nthRoot(3);\n            } else {\n                x1 = -q / 2 + Math.sqrt(Q);\n                x1 = new ComplexNumber(numberSign(x1) * Math.pow(Math.abs(x1), 1 / 3));\n                x2 = -q / 2 - Math.sqrt(Q);\n                x2 = new ComplexNumber(numberSign(x2) * Math.pow(Math.abs(x2), 1 / 3));\n            }\n            y1 = x1.add(x2);\n            z1 = x1.add(x2).multiplyConstant(-1 / 2);\n            z2 = x1.add(x2.negate()).multiplyConstant(Math.sqrt(3) / 2);\n            y2 = z1.add(i.multiply(z2));\n            y3 = z1.add(i.negate().multiply(z2));\n            var result = [];\n            if (y1.isReal()) {\n                result.push(round(y1.real + b3a, PRECISION));\n            }\n            if (y2.isReal()) {\n                result.push(round(y2.real + b3a, PRECISION));\n            }\n            if (y3.isReal()) {\n                result.push(round(y3.real + b3a, PRECISION));\n            }\n            return result;\n        }\n        function hasRootsInRange(points, point, field, rootField, range) {\n            var polynomial = toCubicPolynomial(points, rootField);\n            var roots = solveCubicEquation(polynomial[0], polynomial[1], polynomial[2], polynomial[3] - point[rootField]);\n            var intersection;\n            for (var idx = 0; idx < roots.length; idx++) {\n                if (0 <= roots[idx] && roots[idx] <= 1) {\n                    intersection = calculateCurveAt(roots[idx], field, points);\n                    if (Math.abs(intersection - point[field]) <= range) {\n                        return true;\n                    }\n                }\n            }\n        }\n        function curveIntersectionsCount(points, point, bbox) {\n            var polynomial = toCubicPolynomial(points, 'x');\n            var roots = solveCubicEquation(polynomial[0], polynomial[1], polynomial[2], polynomial[3] - point.x);\n            var rayIntersection, intersectsRay;\n            var count = 0;\n            for (var i = 0; i < roots.length; i++) {\n                rayIntersection = calculateCurveAt(roots[i], 'y', points);\n                intersectsRay = close(rayIntersection, point.y) || rayIntersection > point.y;\n                if (intersectsRay && ((roots[i] === 0 || roots[i] === 1) && bbox.bottomRight().x > point.x || 0 < roots[i] && roots[i] < 1)) {\n                    count++;\n                }\n            }\n            return count;\n        }\n        function lineIntersectionsCount(a, b, point) {\n            var intersects;\n            if (a.x !== b.x) {\n                var minX = Math.min(a.x, b.x);\n                var maxX = Math.max(a.x, b.x);\n                var minY = Math.min(a.y, b.y);\n                var maxY = Math.max(a.y, b.y);\n                var inRange = minX <= point.x && point.x < maxX;\n                if (minY === maxY) {\n                    intersects = point.y <= minY && inRange;\n                } else {\n                    intersects = inRange && (maxY - minY) * ((a.x - b.x) * (a.y - b.y) > 0 ? point.x - minX : maxX - point.x) / (maxX - minX) + minY - point.y >= 0;\n                }\n            }\n            return intersects ? 1 : 0;\n        }\n        var Segment = Class.extend({\n            init: function (anchor, controlIn, controlOut) {\n                this.anchor(anchor || new Point());\n                this.controlIn(controlIn);\n                this.controlOut(controlOut);\n            },\n            bboxTo: function (toSegment, matrix) {\n                var segmentAnchor = this.anchor().transformCopy(matrix);\n                var toSegmentAnchor = toSegment.anchor().transformCopy(matrix);\n                var rect;\n                if (this.controlOut() && toSegment.controlIn()) {\n                    rect = this._curveBoundingBox(segmentAnchor, this.controlOut().transformCopy(matrix), toSegment.controlIn().transformCopy(matrix), toSegmentAnchor);\n                } else {\n                    rect = this._lineBoundingBox(segmentAnchor, toSegmentAnchor);\n                }\n                return rect;\n            },\n            _lineBoundingBox: function (p1, p2) {\n                return Rect.fromPoints(p1, p2);\n            },\n            _curveBoundingBox: function (p1, cp1, cp2, p2) {\n                var points = [\n                    p1,\n                    cp1,\n                    cp2,\n                    p2\n                ];\n                var extremesX = this._curveExtremesFor(points, 'x');\n                var extremesY = this._curveExtremesFor(points, 'y');\n                var xLimits = arrayLimits([\n                    extremesX.min,\n                    extremesX.max,\n                    p1.x,\n                    p2.x\n                ]);\n                var yLimits = arrayLimits([\n                    extremesY.min,\n                    extremesY.max,\n                    p1.y,\n                    p2.y\n                ]);\n                return Rect.fromPoints(new Point(xLimits.min, yLimits.min), new Point(xLimits.max, yLimits.max));\n            },\n            _curveExtremesFor: function (points, field) {\n                var extremes = this._curveExtremes(points[0][field], points[1][field], points[2][field], points[3][field]);\n                return {\n                    min: calculateCurveAt(extremes.min, field, points),\n                    max: calculateCurveAt(extremes.max, field, points)\n                };\n            },\n            _curveExtremes: function (x1, x2, x3, x4) {\n                var a = x1 - 3 * x2 + 3 * x3 - x4;\n                var b = -2 * (x1 - 2 * x2 + x3);\n                var c = x1 - x2;\n                var sqrt = Math.sqrt(b * b - 4 * a * c);\n                var t1 = 0;\n                var t2 = 1;\n                if (a === 0) {\n                    if (b !== 0) {\n                        t1 = t2 = -c / b;\n                    }\n                } else if (!isNaN(sqrt)) {\n                    t1 = (-b + sqrt) / (2 * a);\n                    t2 = (-b - sqrt) / (2 * a);\n                }\n                var min = Math.max(Math.min(t1, t2), 0);\n                if (min < 0 || min > 1) {\n                    min = 0;\n                }\n                var max = Math.min(Math.max(t1, t2), 1);\n                if (max > 1 || max < 0) {\n                    max = 1;\n                }\n                return {\n                    min: min,\n                    max: max\n                };\n            },\n            _intersectionsTo: function (segment, point) {\n                var intersectionsCount;\n                if (this.controlOut() && segment.controlIn()) {\n                    intersectionsCount = curveIntersectionsCount([\n                        this.anchor(),\n                        this.controlOut(),\n                        segment.controlIn(),\n                        segment.anchor()\n                    ], point, this.bboxTo(segment));\n                } else {\n                    intersectionsCount = lineIntersectionsCount(this.anchor(), segment.anchor(), point);\n                }\n                return intersectionsCount;\n            },\n            _isOnCurveTo: function (segment, point, width, endSegment) {\n                var bbox = this.bboxTo(segment).expand(width, width);\n                if (bbox.containsPoint(point)) {\n                    var p1 = this.anchor();\n                    var p2 = this.controlOut();\n                    var p3 = segment.controlIn();\n                    var p4 = segment.anchor();\n                    if (endSegment === 'start' && p1.distanceTo(point) <= width) {\n                        return !isOutOfEndPoint(p1, p2, point);\n                    } else if (endSegment === 'end' && p4.distanceTo(point) <= width) {\n                        return !isOutOfEndPoint(p4, p3, point);\n                    }\n                    var points = [\n                        p1,\n                        p2,\n                        p3,\n                        p4\n                    ];\n                    if (hasRootsInRange(points, point, 'x', 'y', width) || hasRootsInRange(points, point, 'y', 'x', width)) {\n                        return true;\n                    }\n                    var rotation = transform().rotate(45, point);\n                    var rotatedPoints = [\n                        p1.transformCopy(rotation),\n                        p2.transformCopy(rotation),\n                        p3.transformCopy(rotation),\n                        p4.transformCopy(rotation)\n                    ];\n                    return hasRootsInRange(rotatedPoints, point, 'x', 'y', width) || hasRootsInRange(rotatedPoints, point, 'y', 'x', width);\n                }\n            },\n            _isOnLineTo: function (segment, point, width) {\n                var p1 = this.anchor();\n                var p2 = segment.anchor();\n                var angle = deg(Math.atan2(p2.y - p1.y, p2.x - p1.x));\n                var rect = new Rect([\n                    p1.x,\n                    p1.y - width / 2\n                ], [\n                    p1.distanceTo(p2),\n                    width\n                ]);\n                return rect.containsPoint(point.transformCopy(transform().rotate(-angle, p1)));\n            },\n            _isOnPathTo: function (segment, point, width, endSegment) {\n                var isOnPath;\n                if (this.controlOut() && segment.controlIn()) {\n                    isOnPath = this._isOnCurveTo(segment, point, width / 2, endSegment);\n                } else {\n                    isOnPath = this._isOnLineTo(segment, point, width);\n                }\n                return isOnPath;\n            }\n        });\n        definePointAccessors(Segment.prototype, [\n            'anchor',\n            'controlIn',\n            'controlOut'\n        ]);\n        ObserversMixin.extend(Segment.prototype);\n        function arrayLimits(arr) {\n            var length = arr.length;\n            var min = MAX_NUM;\n            var max = MIN_NUM;\n            for (var i = 0; i < length; i++) {\n                max = Math.max(max, arr[i]);\n                min = Math.min(min, arr[i]);\n            }\n            return {\n                min: min,\n                max: max\n            };\n        }\n        function elementsBoundingBox(elements, applyTransform, transformation) {\n            var boundingBox;\n            for (var i = 0; i < elements.length; i++) {\n                var element = elements[i];\n                if (element.visible()) {\n                    var elementBoundingBox = applyTransform ? element.bbox(transformation) : element.rawBBox();\n                    if (elementBoundingBox) {\n                        if (boundingBox) {\n                            boundingBox = Rect.union(boundingBox, elementBoundingBox);\n                        } else {\n                            boundingBox = elementBoundingBox;\n                        }\n                    }\n                }\n            }\n            return boundingBox;\n        }\n        function elementsClippedBoundingBox(elements, transformation) {\n            var boundingBox;\n            for (var i = 0; i < elements.length; i++) {\n                var element = elements[i];\n                if (element.visible()) {\n                    var elementBoundingBox = element.clippedBBox(transformation);\n                    if (elementBoundingBox) {\n                        if (boundingBox) {\n                            boundingBox = Rect.union(boundingBox, elementBoundingBox);\n                        } else {\n                            boundingBox = elementBoundingBox;\n                        }\n                    }\n                }\n            }\n            return boundingBox;\n        }\n        var MultiPath = Element$1.extend({\n            init: function (options) {\n                Element$1.fn.init.call(this, options);\n                this.paths = new GeometryElementsArray();\n                this.paths.addObserver(this);\n                if (!defined(this.options.stroke)) {\n                    this.stroke('#000');\n                }\n            },\n            moveTo: function (x, y) {\n                var path = new Path();\n                path.moveTo(x, y);\n                this.paths.push(path);\n                return this;\n            },\n            lineTo: function (x, y) {\n                if (this.paths.length > 0) {\n                    last(this.paths).lineTo(x, y);\n                }\n                return this;\n            },\n            curveTo: function (controlOut, controlIn, point) {\n                if (this.paths.length > 0) {\n                    last(this.paths).curveTo(controlOut, controlIn, point);\n                }\n                return this;\n            },\n            arc: function (startAngle, endAngle, radiusX, radiusY, anticlockwise) {\n                if (this.paths.length > 0) {\n                    last(this.paths).arc(startAngle, endAngle, radiusX, radiusY, anticlockwise);\n                }\n                return this;\n            },\n            arcTo: function (end, rx, ry, largeArc, swipe, rotation) {\n                if (this.paths.length > 0) {\n                    last(this.paths).arcTo(end, rx, ry, largeArc, swipe, rotation);\n                }\n                return this;\n            },\n            close: function () {\n                if (this.paths.length > 0) {\n                    last(this.paths).close();\n                }\n                return this;\n            },\n            _bbox: function (matrix) {\n                return elementsBoundingBox(this.paths, true, matrix);\n            },\n            rawBBox: function () {\n                return elementsBoundingBox(this.paths, false);\n            },\n            _containsPoint: function (point) {\n                var paths = this.paths;\n                for (var idx = 0; idx < paths.length; idx++) {\n                    if (paths[idx]._containsPoint(point)) {\n                        return true;\n                    }\n                }\n                return false;\n            },\n            _isOnPath: function (point) {\n                var paths = this.paths;\n                var width = this.options.stroke.width;\n                for (var idx = 0; idx < paths.length; idx++) {\n                    if (paths[idx]._isOnPath(point, width)) {\n                        return true;\n                    }\n                }\n                return false;\n            },\n            _clippedBBox: function (transformation) {\n                return elementsClippedBoundingBox(this.paths, this.currentTransform(transformation));\n            }\n        });\n        MultiPath.prototype.nodeType = 'MultiPath';\n        Paintable.extend(MultiPath.prototype);\n        Measurable.extend(MultiPath.prototype);\n        var ShapeMap = {\n            l: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                for (var i = 0; i < parameters.length; i += 2) {\n                    var point = new Point(parameters[i], parameters[i + 1]);\n                    if (options.isRelative) {\n                        point.translateWith(position);\n                    }\n                    path.lineTo(point.x, point.y);\n                    position.x = point.x;\n                    position.y = point.y;\n                }\n            },\n            c: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                for (var i = 0; i < parameters.length; i += 6) {\n                    var controlOut = new Point(parameters[i], parameters[i + 1]);\n                    var controlIn = new Point(parameters[i + 2], parameters[i + 3]);\n                    var point = new Point(parameters[i + 4], parameters[i + 5]);\n                    if (options.isRelative) {\n                        controlIn.translateWith(position);\n                        controlOut.translateWith(position);\n                        point.translateWith(position);\n                    }\n                    path.curveTo(controlOut, controlIn, point);\n                    position.x = point.x;\n                    position.y = point.y;\n                }\n            },\n            v: function (path, options) {\n                var value = options.isRelative ? 0 : options.position.x;\n                toLineParamaters(options.parameters, true, value);\n                this.l(path, options);\n            },\n            h: function (path, options) {\n                var value = options.isRelative ? 0 : options.position.y;\n                toLineParamaters(options.parameters, false, value);\n                this.l(path, options);\n            },\n            a: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                for (var i = 0; i < parameters.length; i += 7) {\n                    var radiusX = parameters[i];\n                    var radiusY = parameters[i + 1];\n                    var rotation = parameters[i + 2];\n                    var largeArc = parameters[i + 3];\n                    var swipe = parameters[i + 4];\n                    var endPoint = new Point(parameters[i + 5], parameters[i + 6]);\n                    if (options.isRelative) {\n                        endPoint.translateWith(position);\n                    }\n                    if (position.x !== endPoint.x || position.y !== endPoint.y) {\n                        path.arcTo(endPoint, radiusX, radiusY, largeArc, swipe, rotation);\n                        position.x = endPoint.x;\n                        position.y = endPoint.y;\n                    }\n                }\n            },\n            s: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                var previousCommand = options.previousCommand;\n                var lastControlIn;\n                if (previousCommand === 's' || previousCommand === 'c') {\n                    lastControlIn = last(last(path.paths).segments).controlIn();\n                }\n                for (var i = 0; i < parameters.length; i += 4) {\n                    var controlIn = new Point(parameters[i], parameters[i + 1]);\n                    var endPoint = new Point(parameters[i + 2], parameters[i + 3]);\n                    var controlOut = void 0;\n                    if (options.isRelative) {\n                        controlIn.translateWith(position);\n                        endPoint.translateWith(position);\n                    }\n                    if (lastControlIn) {\n                        controlOut = reflectionPoint(lastControlIn, position);\n                    } else {\n                        controlOut = position.clone();\n                    }\n                    lastControlIn = controlIn;\n                    path.curveTo(controlOut, controlIn, endPoint);\n                    position.x = endPoint.x;\n                    position.y = endPoint.y;\n                }\n            },\n            q: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                for (var i = 0; i < parameters.length; i += 4) {\n                    var controlPoint = new Point(parameters[i], parameters[i + 1]);\n                    var endPoint = new Point(parameters[i + 2], parameters[i + 3]);\n                    if (options.isRelative) {\n                        controlPoint.translateWith(position);\n                        endPoint.translateWith(position);\n                    }\n                    var cubicControlPoints = quadraticToCubicControlPoints(position, controlPoint, endPoint);\n                    path.curveTo(cubicControlPoints.controlOut, cubicControlPoints.controlIn, endPoint);\n                    position.x = endPoint.x;\n                    position.y = endPoint.y;\n                }\n            },\n            t: function (path, options) {\n                var parameters = options.parameters;\n                var position = options.position;\n                var previousCommand = options.previousCommand;\n                var controlPoint;\n                if (previousCommand === 'q' || previousCommand === 't') {\n                    var lastSegment = last(last(path.paths).segments);\n                    controlPoint = lastSegment.controlIn().clone().translateWith(position.scaleCopy(-1 / 3)).scale(3 / 2);\n                }\n                for (var i = 0; i < parameters.length; i += 2) {\n                    var endPoint = new Point(parameters[i], parameters[i + 1]);\n                    if (options.isRelative) {\n                        endPoint.translateWith(position);\n                    }\n                    if (controlPoint) {\n                        controlPoint = reflectionPoint(controlPoint, position);\n                    } else {\n                        controlPoint = position.clone();\n                    }\n                    var cubicControlPoints = quadraticToCubicControlPoints(position, controlPoint, endPoint);\n                    path.curveTo(cubicControlPoints.controlOut, cubicControlPoints.controlIn, endPoint);\n                    position.x = endPoint.x;\n                    position.y = endPoint.y;\n                }\n            }\n        };\n        function toLineParamaters(parameters, isVertical, value) {\n            var insertPosition = isVertical ? 0 : 1;\n            for (var i = 0; i < parameters.length; i += 2) {\n                parameters.splice(i + insertPosition, 0, value);\n            }\n        }\n        function reflectionPoint(point, center) {\n            if (point && center) {\n                return center.scaleCopy(2).translate(-point.x, -point.y);\n            }\n        }\n        var third = 1 / 3;\n        function quadraticToCubicControlPoints(position, controlPoint, endPoint) {\n            var scaledPoint = controlPoint.clone().scale(2 / 3);\n            return {\n                controlOut: scaledPoint.clone().translateWith(position.scaleCopy(third)),\n                controlIn: scaledPoint.translateWith(endPoint.scaleCopy(third))\n            };\n        }\n        var SEGMENT_REGEX = /([a-df-z]{1})([^a-df-z]*)(z)?/gi;\n        var SPLIT_REGEX = /[,\\s]?([+\\-]?(?:\\d*\\.\\d+|\\d+)(?:[eE][+\\-]?\\d+)?)/g;\n        var MOVE = 'm';\n        var CLOSE = 'z';\n        function parseParameters(str) {\n            var parameters = [];\n            str.replace(SPLIT_REGEX, function (match, number) {\n                parameters.push(parseFloat(number));\n            });\n            return parameters;\n        }\n        var PathParser = Class.extend({\n            parse: function (str, options) {\n                var multiPath = new MultiPath(options);\n                var position = new Point();\n                var previousCommand;\n                str.replace(SEGMENT_REGEX, function (match, element, params, closePath) {\n                    var command = element.toLowerCase();\n                    var isRelative = command === element;\n                    var parameters = parseParameters(params.trim());\n                    if (command === MOVE) {\n                        if (isRelative) {\n                            position.x += parameters[0];\n                            position.y += parameters[1];\n                        } else {\n                            position.x = parameters[0];\n                            position.y = parameters[1];\n                        }\n                        multiPath.moveTo(position.x, position.y);\n                        if (parameters.length > 2) {\n                            command = 'l';\n                            parameters.splice(0, 2);\n                        }\n                    }\n                    if (ShapeMap[command]) {\n                        ShapeMap[command](multiPath, {\n                            parameters: parameters,\n                            position: position,\n                            isRelative: isRelative,\n                            previousCommand: previousCommand\n                        });\n                        if (closePath && closePath.toLowerCase() === CLOSE) {\n                            multiPath.close();\n                        }\n                    } else if (command !== MOVE) {\n                        throw new Error('Error while parsing SVG path. Unsupported command: ' + command);\n                    }\n                    previousCommand = command;\n                });\n                return multiPath;\n            }\n        });\n        PathParser.current = new PathParser();\n        var Path = Element$1.extend({\n            init: function (options) {\n                Element$1.fn.init.call(this, options);\n                this.segments = new GeometryElementsArray();\n                this.segments.addObserver(this);\n                if (!defined(this.options.stroke)) {\n                    this.stroke('#000');\n                    if (!defined(this.options.stroke.lineJoin)) {\n                        this.options.set('stroke.lineJoin', 'miter');\n                    }\n                }\n            },\n            moveTo: function (x, y) {\n                this.suspend();\n                this.segments.elements([]);\n                this.resume();\n                this.lineTo(x, y);\n                return this;\n            },\n            lineTo: function (x, y) {\n                var point = defined(y) ? new Point(x, y) : x;\n                var segment = new Segment(point);\n                this.segments.push(segment);\n                return this;\n            },\n            curveTo: function (controlOut, controlIn, point) {\n                if (this.segments.length > 0) {\n                    var lastSegment = last(this.segments);\n                    var segment = new Segment(point, controlIn);\n                    this.suspend();\n                    lastSegment.controlOut(controlOut);\n                    this.resume();\n                    this.segments.push(segment);\n                }\n                return this;\n            },\n            arc: function (startAngle, endAngle, radiusX, radiusY, anticlockwise) {\n                if (this.segments.length > 0) {\n                    var lastSegment = last(this.segments);\n                    var anchor = lastSegment.anchor();\n                    var start = rad(startAngle);\n                    var center = new Point(anchor.x - radiusX * Math.cos(start), anchor.y - radiusY * Math.sin(start));\n                    var arc = new Arc$2(center, {\n                        startAngle: startAngle,\n                        endAngle: endAngle,\n                        radiusX: radiusX,\n                        radiusY: radiusY,\n                        anticlockwise: anticlockwise\n                    });\n                    this._addArcSegments(arc);\n                }\n                return this;\n            },\n            arcTo: function (end, rx, ry, largeArc, swipe, rotation) {\n                if (this.segments.length > 0) {\n                    var lastSegment = last(this.segments);\n                    var anchor = lastSegment.anchor();\n                    var arc = Arc$2.fromPoints(anchor, end, rx, ry, largeArc, swipe, rotation);\n                    this._addArcSegments(arc);\n                }\n                return this;\n            },\n            _addArcSegments: function (arc) {\n                var this$1 = this;\n                this.suspend();\n                var curvePoints = arc.curvePoints();\n                for (var i = 1; i < curvePoints.length; i += 3) {\n                    this$1.curveTo(curvePoints[i], curvePoints[i + 1], curvePoints[i + 2]);\n                }\n                this.resume();\n                this.geometryChange();\n            },\n            close: function () {\n                this.options.closed = true;\n                this.geometryChange();\n                return this;\n            },\n            rawBBox: function () {\n                return this._bbox();\n            },\n            _containsPoint: function (point) {\n                var segments = this.segments;\n                var length = segments.length;\n                var intersectionsCount = 0;\n                var previous, current;\n                for (var idx = 1; idx < length; idx++) {\n                    previous = segments[idx - 1];\n                    current = segments[idx];\n                    intersectionsCount += previous._intersectionsTo(current, point);\n                }\n                if (this.options.closed || !segments[0].anchor().equals(segments[length - 1].anchor())) {\n                    intersectionsCount += lineIntersectionsCount(segments[0].anchor(), segments[length - 1].anchor(), point);\n                }\n                return intersectionsCount % 2 !== 0;\n            },\n            _isOnPath: function (point, width) {\n                var segments = this.segments;\n                var length = segments.length;\n                var pathWidth = width || this.options.stroke.width;\n                if (length > 1) {\n                    if (segments[0]._isOnPathTo(segments[1], point, pathWidth, 'start')) {\n                        return true;\n                    }\n                    for (var idx = 2; idx <= length - 2; idx++) {\n                        if (segments[idx - 1]._isOnPathTo(segments[idx], point, pathWidth)) {\n                            return true;\n                        }\n                    }\n                    if (segments[length - 2]._isOnPathTo(segments[length - 1], point, pathWidth, 'end')) {\n                        return true;\n                    }\n                }\n                return false;\n            },\n            _bbox: function (matrix) {\n                var segments = this.segments;\n                var length = segments.length;\n                var boundingBox;\n                if (length === 1) {\n                    var anchor = segments[0].anchor().transformCopy(matrix);\n                    boundingBox = new Rect(anchor, Size.ZERO);\n                } else if (length > 0) {\n                    for (var i = 1; i < length; i++) {\n                        var segmentBox = segments[i - 1].bboxTo(segments[i], matrix);\n                        if (boundingBox) {\n                            boundingBox = Rect.union(boundingBox, segmentBox);\n                        } else {\n                            boundingBox = segmentBox;\n                        }\n                    }\n                }\n                return boundingBox;\n            }\n        });\n        Path.fromRect = function (rect, options) {\n            return new Path(options).moveTo(rect.topLeft()).lineTo(rect.topRight()).lineTo(rect.bottomRight()).lineTo(rect.bottomLeft()).close();\n        };\n        Path.fromPoints = function (points, options) {\n            if (points) {\n                var path = new Path(options);\n                for (var i = 0; i < points.length; i++) {\n                    var point = Point.create(points[i]);\n                    if (point) {\n                        if (i === 0) {\n                            path.moveTo(point);\n                        } else {\n                            path.lineTo(point);\n                        }\n                    }\n                }\n                return path;\n            }\n        };\n        Path.fromArc = function (arc, options) {\n            var path = new Path(options);\n            var startAngle = arc.startAngle;\n            var start = arc.pointAt(startAngle);\n            path.moveTo(start.x, start.y);\n            path.arc(startAngle, arc.endAngle, arc.radiusX, arc.radiusY, arc.anticlockwise);\n            return path;\n        };\n        Path.prototype.nodeType = 'Path';\n        Paintable.extend(Path.prototype);\n        Measurable.extend(Path.prototype);\n        Path.parse = function (str, options) {\n            return PathParser.current.parse(str, options);\n        };\n        var DEFAULT_STROKE$1 = '#000';\n        var Arc = Element$1.extend({\n            init: function (geometry, options) {\n                if (geometry === void 0) {\n                    geometry = new Arc$2();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                Element$1.fn.init.call(this, options);\n                this.geometry(geometry);\n                if (!defined(this.options.stroke)) {\n                    this.stroke(DEFAULT_STROKE$1);\n                }\n            },\n            _bbox: function (matrix) {\n                return this._geometry.bbox(matrix);\n            },\n            rawBBox: function () {\n                return this.geometry().bbox();\n            },\n            toPath: function () {\n                var path = new Path();\n                var curvePoints = this.geometry().curvePoints();\n                if (curvePoints.length > 0) {\n                    path.moveTo(curvePoints[0].x, curvePoints[0].y);\n                    for (var i = 1; i < curvePoints.length; i += 3) {\n                        path.curveTo(curvePoints[i], curvePoints[i + 1], curvePoints[i + 2]);\n                    }\n                }\n                return path;\n            },\n            _containsPoint: function (point) {\n                return this.geometry().containsPoint(point);\n            },\n            _isOnPath: function (point) {\n                return this.geometry()._isOnPath(point, this.options.stroke.width / 2);\n            }\n        });\n        Arc.prototype.nodeType = 'Arc';\n        Paintable.extend(Arc.prototype);\n        Measurable.extend(Arc.prototype);\n        defineGeometryAccessors(Arc.prototype, ['geometry']);\n        var DEFAULT_FONT = '12px sans-serif';\n        var DEFAULT_FILL = '#000';\n        var Text = Element$1.extend({\n            init: function (content, position, options) {\n                if (position === void 0) {\n                    position = new Point();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                Element$1.fn.init.call(this, options);\n                this.content(content);\n                this.position(position);\n                if (!this.options.font) {\n                    this.options.font = DEFAULT_FONT;\n                }\n                if (!defined(this.options.fill)) {\n                    this.fill(DEFAULT_FILL);\n                }\n            },\n            content: function (value) {\n                if (defined(value)) {\n                    this.options.set('content', value);\n                    return this;\n                }\n                return this.options.get('content');\n            },\n            measure: function () {\n                var metrics = kendoUtil.measureText(this.content(), { font: this.options.get('font') });\n                return metrics;\n            },\n            rect: function () {\n                var size = this.measure();\n                var pos = this.position().clone();\n                return new Rect(pos, [\n                    size.width,\n                    size.height\n                ]);\n            },\n            bbox: function (transformation) {\n                var combinedMatrix = toMatrix(this.currentTransform(transformation));\n                return this.rect().bbox(combinedMatrix);\n            },\n            rawBBox: function () {\n                return this.rect().bbox();\n            },\n            _containsPoint: function (point) {\n                return this.rect().containsPoint(point);\n            }\n        });\n        Text.prototype.nodeType = 'Text';\n        Paintable.extend(Text.prototype);\n        definePointAccessors(Text.prototype, ['position']);\n        var Image$1 = Element$1.extend({\n            init: function (src, rect, options) {\n                if (rect === void 0) {\n                    rect = new Rect();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                Element$1.fn.init.call(this, options);\n                this.src(src);\n                this.rect(rect);\n            },\n            src: function (value) {\n                if (defined(value)) {\n                    this.options.set('src', value);\n                    return this;\n                }\n                return this.options.get('src');\n            },\n            bbox: function (transformation) {\n                var combinedMatrix = toMatrix(this.currentTransform(transformation));\n                return this._rect.bbox(combinedMatrix);\n            },\n            rawBBox: function () {\n                return this._rect.bbox();\n            },\n            _containsPoint: function (point) {\n                return this._rect.containsPoint(point);\n            },\n            _hasFill: function () {\n                return this.src();\n            }\n        });\n        Image$1.prototype.nodeType = 'Image';\n        defineGeometryAccessors(Image$1.prototype, ['rect']);\n        var Traversable = {\n            extend: function (proto, childrenField) {\n                proto.traverse = function (callback) {\n                    var children = this[childrenField];\n                    for (var i = 0; i < children.length; i++) {\n                        var child = children[i];\n                        if (child.traverse) {\n                            child.traverse(callback);\n                        } else {\n                            callback(child);\n                        }\n                    }\n                    return this;\n                };\n            }\n        };\n        var Group = Element$1.extend({\n            init: function (options) {\n                Element$1.fn.init.call(this, options);\n                this.children = [];\n            },\n            childrenChange: function (action, items, index) {\n                this.trigger('childrenChange', {\n                    action: action,\n                    items: items,\n                    index: index\n                });\n            },\n            append: function () {\n                append(this.children, arguments);\n                this._reparent(arguments, this);\n                this.childrenChange('add', arguments);\n                return this;\n            },\n            insert: function (index, element) {\n                this.children.splice(index, 0, element);\n                element.parent = this;\n                this.childrenChange('add', [element], index);\n                return this;\n            },\n            insertAt: function (element, index) {\n                return this.insert(index, element);\n            },\n            remove: function (element) {\n                var index = this.children.indexOf(element);\n                if (index >= 0) {\n                    this.children.splice(index, 1);\n                    element.parent = null;\n                    this.childrenChange('remove', [element], index);\n                }\n                return this;\n            },\n            removeAt: function (index) {\n                if (0 <= index && index < this.children.length) {\n                    var element = this.children[index];\n                    this.children.splice(index, 1);\n                    element.parent = null;\n                    this.childrenChange('remove', [element], index);\n                }\n                return this;\n            },\n            clear: function () {\n                var items = this.children;\n                this.children = [];\n                this._reparent(items, null);\n                this.childrenChange('remove', items, 0);\n                return this;\n            },\n            bbox: function (transformation) {\n                return elementsBoundingBox(this.children, true, this.currentTransform(transformation));\n            },\n            rawBBox: function () {\n                return elementsBoundingBox(this.children, false);\n            },\n            _clippedBBox: function (transformation) {\n                return elementsClippedBoundingBox(this.children, this.currentTransform(transformation));\n            },\n            currentTransform: function (transformation) {\n                return Element$1.prototype.currentTransform.call(this, transformation) || null;\n            },\n            containsPoint: function (point, parentTransform) {\n                if (this.visible()) {\n                    var children = this.children;\n                    var transform = this.currentTransform(parentTransform);\n                    for (var idx = 0; idx < children.length; idx++) {\n                        if (children[idx].containsPoint(point, transform)) {\n                            return true;\n                        }\n                    }\n                }\n                return false;\n            },\n            _reparent: function (elements, newParent) {\n                var this$1 = this;\n                for (var i = 0; i < elements.length; i++) {\n                    var child = elements[i];\n                    var parent = child.parent;\n                    if (parent && parent !== this$1 && parent.remove) {\n                        parent.remove(child);\n                    }\n                    child.parent = newParent;\n                }\n            }\n        });\n        Group.prototype.nodeType = 'Group';\n        Traversable.extend(Group.prototype, 'children');\n        function translateToPoint(point, bbox, element) {\n            var transofrm = element.transform() || transform();\n            var matrix = transofrm.matrix();\n            matrix.e += point.x - bbox.origin.x;\n            matrix.f += point.y - bbox.origin.y;\n            transofrm.matrix(matrix);\n            element.transform(transofrm);\n        }\n        function alignStart(size, rect, align, axis, sizeField) {\n            var start;\n            if (align === 'start') {\n                start = rect.origin[axis];\n            } else if (align === 'end') {\n                start = rect.origin[axis] + rect.size[sizeField] - size;\n            } else {\n                start = rect.origin[axis] + (rect.size[sizeField] - size) / 2;\n            }\n            return start;\n        }\n        function alignStartReverse(size, rect, align, axis, sizeField) {\n            var start;\n            if (align === 'start') {\n                start = rect.origin[axis] + rect.size[sizeField] - size;\n            } else if (align === 'end') {\n                start = rect.origin[axis];\n            } else {\n                start = rect.origin[axis] + (rect.size[sizeField] - size) / 2;\n            }\n            return start;\n        }\n        var DEFAULT_OPTIONS = {\n            alignContent: 'start',\n            justifyContent: 'start',\n            alignItems: 'start',\n            spacing: 0,\n            orientation: 'horizontal',\n            lineSpacing: 0,\n            wrap: true,\n            revers: false\n        };\n        var forEach = function (elements, callback) {\n            elements.forEach(callback);\n        };\n        var forEachReverse = function (elements, callback) {\n            var length = elements.length;\n            for (var idx = length - 1; idx >= 0; idx--) {\n                callback(elements[idx], idx);\n            }\n        };\n        var Layout = Group.extend({\n            init: function (rect, options) {\n                Group.fn.init.call(this, $.extend({}, DEFAULT_OPTIONS, options));\n                this._rect = rect;\n                this._fieldMap = {};\n            },\n            rect: function (value) {\n                if (value) {\n                    this._rect = value;\n                    return this;\n                }\n                return this._rect;\n            },\n            _initMap: function () {\n                var options = this.options;\n                var fieldMap = this._fieldMap;\n                if (options.orientation === 'horizontal') {\n                    fieldMap.sizeField = 'width';\n                    fieldMap.groupsSizeField = 'height';\n                    fieldMap.groupAxis = 'x';\n                    fieldMap.groupsAxis = 'y';\n                } else {\n                    fieldMap.sizeField = 'height';\n                    fieldMap.groupsSizeField = 'width';\n                    fieldMap.groupAxis = 'y';\n                    fieldMap.groupsAxis = 'x';\n                }\n                if (options.reverse) {\n                    this.forEach = forEachReverse;\n                    this.justifyAlign = alignStartReverse;\n                } else {\n                    this.forEach = forEach;\n                    this.justifyAlign = alignStart;\n                }\n            },\n            reflow: function () {\n                var this$1 = this;\n                if (!this._rect || this.children.length === 0) {\n                    return;\n                }\n                this._initMap();\n                if (this.options.transform) {\n                    this.transform(null);\n                }\n                var options = this.options;\n                var rect = this._rect;\n                var ref = this._initGroups();\n                var groups = ref.groups;\n                var groupsSize = ref.groupsSize;\n                var ref$1 = this._fieldMap;\n                var sizeField = ref$1.sizeField;\n                var groupsSizeField = ref$1.groupsSizeField;\n                var groupAxis = ref$1.groupAxis;\n                var groupsAxis = ref$1.groupsAxis;\n                var groupOrigin = new Point();\n                var elementOrigin = new Point();\n                var size = new Size();\n                var groupStart = alignStart(groupsSize, rect, options.alignContent, groupsAxis, groupsSizeField);\n                var elementStart, group, groupBox;\n                var arrangeElements = function (bbox, idx) {\n                    var element = group.elements[idx];\n                    elementOrigin[groupAxis] = elementStart;\n                    elementOrigin[groupsAxis] = alignStart(bbox.size[groupsSizeField], groupBox, options.alignItems, groupsAxis, groupsSizeField);\n                    translateToPoint(elementOrigin, bbox, element);\n                    elementStart += bbox.size[sizeField] + options.spacing;\n                };\n                for (var groupIdx = 0; groupIdx < groups.length; groupIdx++) {\n                    group = groups[groupIdx];\n                    groupOrigin[groupAxis] = elementStart = this$1.justifyAlign(group.size, rect, options.justifyContent, groupAxis, sizeField);\n                    groupOrigin[groupsAxis] = groupStart;\n                    size[sizeField] = group.size;\n                    size[groupsSizeField] = group.lineSize;\n                    groupBox = new Rect(groupOrigin, size);\n                    this$1.forEach(group.bboxes, arrangeElements);\n                    groupStart += group.lineSize + options.lineSpacing;\n                }\n                if (!options.wrap && group.size > rect.size[sizeField]) {\n                    var scale = rect.size[sizeField] / groupBox.size[sizeField];\n                    var scaledStart = groupBox.topLeft().scale(scale, scale);\n                    var scaledSize = groupBox.size[groupsSizeField] * scale;\n                    var newStart = alignStart(scaledSize, rect, options.alignContent, groupsAxis, groupsSizeField);\n                    var transform$$1 = transform();\n                    if (groupAxis === 'x') {\n                        transform$$1.translate(rect.origin.x - scaledStart.x, newStart - scaledStart.y);\n                    } else {\n                        transform$$1.translate(newStart - scaledStart.x, rect.origin.y - scaledStart.y);\n                    }\n                    transform$$1.scale(scale, scale);\n                    this.transform(transform$$1);\n                }\n            },\n            _initGroups: function () {\n                var this$1 = this;\n                var ref = this;\n                var options = ref.options;\n                var children = ref.children;\n                var lineSpacing = options.lineSpacing;\n                var wrap = options.wrap;\n                var spacing = options.spacing;\n                var sizeField = this._fieldMap.sizeField;\n                var group = this._newGroup();\n                var groups = [];\n                var addGroup = function () {\n                    groups.push(group);\n                    groupsSize += group.lineSize + lineSpacing;\n                };\n                var groupsSize = -lineSpacing;\n                for (var idx = 0; idx < children.length; idx++) {\n                    var element = children[idx];\n                    var bbox = children[idx].clippedBBox();\n                    if (element.visible() && bbox) {\n                        if (wrap && group.size + bbox.size[sizeField] + spacing > this$1._rect.size[sizeField]) {\n                            if (group.bboxes.length === 0) {\n                                this$1._addToGroup(group, bbox, element);\n                                addGroup();\n                                group = this$1._newGroup();\n                            } else {\n                                addGroup();\n                                group = this$1._newGroup();\n                                this$1._addToGroup(group, bbox, element);\n                            }\n                        } else {\n                            this$1._addToGroup(group, bbox, element);\n                        }\n                    }\n                }\n                if (group.bboxes.length) {\n                    addGroup();\n                }\n                return {\n                    groups: groups,\n                    groupsSize: groupsSize\n                };\n            },\n            _addToGroup: function (group, bbox, element) {\n                group.size += bbox.size[this._fieldMap.sizeField] + this.options.spacing;\n                group.lineSize = Math.max(bbox.size[this._fieldMap.groupsSizeField], group.lineSize);\n                group.bboxes.push(bbox);\n                group.elements.push(element);\n            },\n            _newGroup: function () {\n                return {\n                    lineSize: 0,\n                    size: -this.options.spacing,\n                    bboxes: [],\n                    elements: []\n                };\n            }\n        });\n        var Rect$2 = Element$1.extend({\n            init: function (geometry, options) {\n                if (geometry === void 0) {\n                    geometry = new Rect();\n                }\n                if (options === void 0) {\n                    options = {};\n                }\n                Element$1.fn.init.call(this, options);\n                this.geometry(geometry);\n                if (!defined(this.options.stroke)) {\n                    this.stroke('#000');\n                }\n            },\n            _bbox: function (matrix) {\n                return this._geometry.bbox(matrix);\n            },\n            rawBBox: function () {\n                return this._geometry.bbox();\n            },\n            _containsPoint: function (point) {\n                return this._geometry.containsPoint(point);\n            },\n            _isOnPath: function (point) {\n                return this.geometry()._isOnPath(point, this.options.stroke.width / 2);\n            }\n        });\n        Rect$2.prototype.nodeType = 'Rect';\n        Paintable.extend(Rect$2.prototype);\n        Measurable.extend(Rect$2.prototype);\n        defineGeometryAccessors(Rect$2.prototype, ['geometry']);\n        function alignElements(elements, rect, alignment, axis, sizeField) {\n            for (var idx = 0; idx < elements.length; idx++) {\n                var bbox = elements[idx].clippedBBox();\n                if (bbox) {\n                    var point = bbox.origin.clone();\n                    point[axis] = alignStart(bbox.size[sizeField], rect, alignment || 'start', axis, sizeField);\n                    translateToPoint(point, bbox, elements[idx]);\n                }\n            }\n        }\n        function align(elements, rect, alignment) {\n            alignElements(elements, rect, alignment, 'x', 'width');\n        }\n        function vAlign(elements, rect, alignment) {\n            alignElements(elements, rect, alignment, 'y', 'height');\n        }\n        function stackElements(elements, stackAxis, otherAxis, sizeField) {\n            if (elements.length > 1) {\n                var origin = new Point();\n                var previousBBox = elements[0].bbox;\n                for (var idx = 1; idx < elements.length; idx++) {\n                    var element = elements[idx].element;\n                    var bbox = elements[idx].bbox;\n                    origin[stackAxis] = previousBBox.origin[stackAxis] + previousBBox.size[sizeField];\n                    origin[otherAxis] = bbox.origin[otherAxis];\n                    translateToPoint(origin, bbox, element);\n                    bbox.origin[stackAxis] = origin[stackAxis];\n                    previousBBox = bbox;\n                }\n            }\n        }\n        function createStackElements(elements) {\n            var stackElements = [];\n            for (var idx = 0; idx < elements.length; idx++) {\n                var element = elements[idx];\n                var bbox = element.clippedBBox();\n                if (bbox) {\n                    stackElements.push({\n                        element: element,\n                        bbox: bbox\n                    });\n                }\n            }\n            return stackElements;\n        }\n        function stack(elements) {\n            stackElements(createStackElements(elements), 'x', 'y', 'width');\n        }\n        function vStack(elements) {\n            stackElements(createStackElements(elements), 'y', 'x', 'height');\n        }\n        function getStacks(elements, rect, sizeField) {\n            var maxSize = rect.size[sizeField];\n            var stacks = [];\n            var stack = [];\n            var stackSize = 0;\n            var element, bbox;\n            var addElementToStack = function () {\n                stack.push({\n                    element: element,\n                    bbox: bbox\n                });\n            };\n            for (var idx = 0; idx < elements.length; idx++) {\n                element = elements[idx];\n                bbox = element.clippedBBox();\n                if (bbox) {\n                    var size = bbox.size[sizeField];\n                    if (stackSize + size > maxSize) {\n                        if (stack.length) {\n                            stacks.push(stack);\n                            stack = [];\n                            addElementToStack();\n                            stackSize = size;\n                        } else {\n                            addElementToStack();\n                            stacks.push(stack);\n                            stack = [];\n                            stackSize = 0;\n                        }\n                    } else {\n                        addElementToStack();\n                        stackSize += size;\n                    }\n                }\n            }\n            if (stack.length) {\n                stacks.push(stack);\n            }\n            return stacks;\n        }\n        function wrapElements(elements, rect, axis, otherAxis, sizeField) {\n            var stacks = getStacks(elements, rect, sizeField);\n            var origin = rect.origin.clone();\n            var result = [];\n            for (var idx = 0; idx < stacks.length; idx++) {\n                var stack = stacks[idx];\n                var startElement = stack[0];\n                origin[otherAxis] = startElement.bbox.origin[otherAxis];\n                translateToPoint(origin, startElement.bbox, startElement.element);\n                startElement.bbox.origin[axis] = origin[axis];\n                stackElements(stack, axis, otherAxis, sizeField);\n                result.push([]);\n                for (var elementIdx = 0; elementIdx < stack.length; elementIdx++) {\n                    result[idx].push(stack[elementIdx].element);\n                }\n            }\n            return result;\n        }\n        function wrap(elements, rect) {\n            return wrapElements(elements, rect, 'x', 'y', 'width');\n        }\n        function vWrap(elements, rect) {\n            return wrapElements(elements, rect, 'y', 'x', 'height');\n        }\n        function fit(element, rect) {\n            var bbox = element.clippedBBox();\n            if (bbox) {\n                var elementSize = bbox.size;\n                var rectSize = rect.size;\n                if (rectSize.width < elementSize.width || rectSize.height < elementSize.height) {\n                    var scale = Math.min(rectSize.width / elementSize.width, rectSize.height / elementSize.height);\n                    var transform$$1 = element.transform() || transform();\n                    transform$$1.scale(scale, scale);\n                    element.transform(transform$$1);\n                }\n            }\n        }\n        var StopsArray = ElementsArray.extend({\n            _change: function () {\n                this.optionsChange({ field: 'stops' });\n            }\n        });\n        function optionsAccessor(name) {\n            return function (value) {\n                if (defined(value)) {\n                    this.options.set(name, value);\n                    return this;\n                }\n                return this.options.get(name);\n            };\n        }\n        function defineOptionsAccessors(fn, names) {\n            for (var i = 0; i < names.length; i++) {\n                fn[names[i]] = optionsAccessor(names[i]);\n            }\n        }\n        var GradientStop = Class.extend({\n            init: function (offset, color, opacity) {\n                this.options = new OptionsStore({\n                    offset: offset,\n                    color: color,\n                    opacity: defined(opacity) ? opacity : 1\n                });\n                this.options.addObserver(this);\n            }\n        });\n        GradientStop.create = function (arg) {\n            if (defined(arg)) {\n                var stop;\n                if (arg instanceof GradientStop) {\n                    stop = arg;\n                } else if (arg.length > 1) {\n                    stop = new GradientStop(arg[0], arg[1], arg[2]);\n                } else {\n                    stop = new GradientStop(arg.offset, arg.color, arg.opacity);\n                }\n                return stop;\n            }\n        };\n        defineOptionsAccessors(GradientStop.prototype, [\n            'offset',\n            'color',\n            'opacity'\n        ]);\n        ObserversMixin.extend(GradientStop.prototype);\n        var Gradient = Class.extend({\n            init: function (options) {\n                if (options === void 0) {\n                    options = {};\n                }\n                this.stops = new StopsArray(this._createStops(options.stops));\n                this.stops.addObserver(this);\n                this._userSpace = options.userSpace;\n                this.id = definitionId();\n            },\n            userSpace: function (value) {\n                if (defined(value)) {\n                    this._userSpace = value;\n                    this.optionsChange();\n                    return this;\n                }\n                return this._userSpace;\n            },\n            _createStops: function (stops) {\n                if (stops === void 0) {\n                    stops = [];\n                }\n                var result = [];\n                for (var idx = 0; idx < stops.length; idx++) {\n                    result.push(GradientStop.create(stops[idx]));\n                }\n                return result;\n            },\n            addStop: function (offset, color, opacity) {\n                this.stops.push(new GradientStop(offset, color, opacity));\n            },\n            removeStop: function (stop) {\n                var index = this.stops.indexOf(stop);\n                if (index >= 0) {\n                    this.stops.splice(index, 1);\n                }\n            }\n        });\n        Gradient.prototype.nodeType = 'Gradient';\n        ObserversMixin.extend(Gradient.prototype);\n        $.extend(Gradient.prototype, {\n            optionsChange: function (e) {\n                this.trigger('optionsChange', {\n                    field: 'gradient' + (e ? '.' + e.field : ''),\n                    value: this\n                });\n            },\n            geometryChange: function () {\n                this.optionsChange();\n            }\n        });\n        var LinearGradient = Gradient.extend({\n            init: function (options) {\n                if (options === void 0) {\n                    options = {};\n                }\n                Gradient.fn.init.call(this, options);\n                this.start(options.start || new Point());\n                this.end(options.end || new Point(1, 0));\n            }\n        });\n        definePointAccessors(LinearGradient.prototype, [\n            'start',\n            'end'\n        ]);\n        var RadialGradient = Gradient.extend({\n            init: function (options) {\n                if (options === void 0) {\n                    options = {};\n                }\n                Gradient.fn.init.call(this, options);\n                this.center(options.center || new Point());\n                this._radius = defined(options.radius) ? options.radius : 1;\n                this._fallbackFill = options.fallbackFill;\n            },\n            radius: function (value) {\n                if (defined(value)) {\n                    this._radius = value;\n                    this.geometryChange();\n                    return this;\n                }\n                return this._radius;\n            },\n            fallbackFill: function (value) {\n                if (defined(value)) {\n                    this._fallbackFill = value;\n                    this.optionsChange();\n                    return this;\n                }\n                return this._fallbackFill;\n            }\n        });\n        definePointAccessors(RadialGradient.prototype, ['center']);\n        function swing(position) {\n            return 0.5 - Math.cos(position * Math.PI) / 2;\n        }\n        function linear(position) {\n            return position;\n        }\n        function easeOutElastic(position, time, start, diff) {\n            var s = 1.70158, p = 0, a = diff;\n            if (position === 0) {\n                return start;\n            }\n            if (position === 1) {\n                return start + diff;\n            }\n            if (!p) {\n                p = 0.5;\n            }\n            if (a < Math.abs(diff)) {\n                a = diff;\n                s = p / 4;\n            } else {\n                s = p / (2 * Math.PI) * Math.asin(diff / a);\n            }\n            return a * Math.pow(2, -10 * position) * Math.sin((Number(position) - s) * (1.1 * Math.PI) / p) + diff + start;\n        }\n        var easingFunctions = {\n            swing: swing,\n            linear: linear,\n            easeOutElastic: easeOutElastic\n        };\n        var AnimationFactory = Class.extend({\n            init: function () {\n                this._items = [];\n            },\n            register: function (name, type) {\n                this._items.push({\n                    name: name,\n                    type: type\n                });\n            },\n            create: function (element, options) {\n                var items = this._items;\n                var match;\n                if (options && options.type) {\n                    var type = options.type.toLowerCase();\n                    for (var i = 0; i < items.length; i++) {\n                        if (items[i].name.toLowerCase() === type) {\n                            match = items[i];\n                            break;\n                        }\n                    }\n                }\n                if (match) {\n                    return new match.type(element, options);\n                }\n            }\n        });\n        AnimationFactory.current = new AnimationFactory();\n        var now = Date.now || function () {\n            return new Date().getTime();\n        };\n        var Animation = Class.extend({\n            init: function (element, options) {\n                this.options = $.extend({}, this.options, options);\n                this.element = element;\n            },\n            setup: function () {\n            },\n            step: function () {\n            },\n            play: function () {\n                var this$1 = this;\n                var options = this.options;\n                var duration = options.duration;\n                var delay = options.delay;\n                if (delay === void 0) {\n                    delay = 0;\n                }\n                var easing = easingFunctions[options.easing];\n                var start = now() + delay;\n                var finish = start + duration;\n                if (duration === 0) {\n                    this.step(1);\n                    this.abort();\n                } else {\n                    setTimeout(function () {\n                        var loop = function () {\n                            if (this$1._stopped) {\n                                return;\n                            }\n                            var wallTime = now();\n                            var time = limitValue(wallTime - start, 0, duration);\n                            var position = time / duration;\n                            var easingPosition = easing(position, time, 0, 1, duration);\n                            this$1.step(easingPosition);\n                            if (wallTime < finish) {\n                                kendo.animationFrame(loop);\n                            } else {\n                                this$1.abort();\n                            }\n                        };\n                        loop();\n                    }, delay);\n                }\n            },\n            abort: function () {\n                this._stopped = true;\n            },\n            destroy: function () {\n                this.abort();\n            }\n        });\n        Animation.prototype.options = {\n            duration: 500,\n            easing: 'swing'\n        };\n        Animation.create = function (type, element, options) {\n            return AnimationFactory.current.create(type, element, options);\n        };\n        var SurfaceFactory = Class.extend({\n            init: function () {\n                this._items = [];\n            },\n            register: function (name, type, order) {\n                var items = this._items;\n                var first = items[0];\n                var entry = {\n                    name: name,\n                    type: type,\n                    order: order\n                };\n                if (!first || order < first.order) {\n                    items.unshift(entry);\n                } else {\n                    items.push(entry);\n                }\n            },\n            create: function (element, options) {\n                var items = this._items;\n                var match = items[0];\n                if (options && options.type) {\n                    var preferred = options.type.toLowerCase();\n                    for (var i = 0; i < items.length; i++) {\n                        if (items[i].name === preferred) {\n                            match = items[i];\n                            break;\n                        }\n                    }\n                }\n                if (match) {\n                    return new match.type(element, options);\n                }\n                kendo.logToConsole('Warning: Unable to create Kendo UI Drawing Surface. Possible causes:\\n' + '- The browser does not support SVG and Canvas. User agent: ' + navigator.userAgent);\n            }\n        });\n        SurfaceFactory.current = new SurfaceFactory();\n        var events = [\n            'click',\n            'mouseenter',\n            'mouseleave',\n            'mousemove',\n            'resize'\n        ];\n        var Surface = kendo.Observable.extend({\n            init: function (element, options) {\n                kendo.Observable.fn.init.call(this);\n                this.options = $.extend({}, options);\n                this.element = element;\n                this.element._kendoExportVisual = this.exportVisual.bind(this);\n                this._click = this._handler('click');\n                this._mouseenter = this._handler('mouseenter');\n                this._mouseleave = this._handler('mouseleave');\n                this._mousemove = this._handler('mousemove');\n                this._visual = new Group();\n                elementSize(element, this.options);\n                this.bind(events, this.options);\n                this._enableTracking();\n            },\n            draw: function (element) {\n                this._visual.children.push(element);\n            },\n            clear: function () {\n                this._visual.children = [];\n            },\n            destroy: function () {\n                this._visual = null;\n                this.element._kendoExportVisual = null;\n                this.unbind();\n            },\n            eventTarget: function (e) {\n                var this$1 = this;\n                var domNode = eventElement(e);\n                var node;\n                while (!node && domNode) {\n                    node = domNode._kendoNode;\n                    if (domNode === this$1.element) {\n                        break;\n                    }\n                    domNode = domNode.parentElement;\n                }\n                if (node) {\n                    return node.srcElement;\n                }\n            },\n            exportVisual: function () {\n                return this._visual;\n            },\n            getSize: function () {\n                return elementSize(this.element);\n            },\n            currentSize: function (size) {\n                if (size) {\n                    this._size = size;\n                } else {\n                    return this._size;\n                }\n            },\n            setSize: function (size) {\n                elementSize(this.element, size);\n                this.currentSize(size);\n                this._resize();\n            },\n            resize: function (force) {\n                var size = this.getSize();\n                var currentSize = this.currentSize();\n                if (force || (size.width > 0 || size.height > 0) && (!currentSize || size.width !== currentSize.width || size.height !== currentSize.height)) {\n                    this.currentSize(size);\n                    this._resize(size, force);\n                    this.trigger('resize', size);\n                }\n            },\n            size: function (value) {\n                if (!value) {\n                    return this.getSize();\n                }\n                this.setSize(value);\n            },\n            suspendTracking: function () {\n                this._suspendedTracking = true;\n            },\n            resumeTracking: function () {\n                this._suspendedTracking = false;\n            },\n            _enableTracking: function () {\n            },\n            _resize: function () {\n            },\n            _handler: function (eventName) {\n                var this$1 = this;\n                return function (e) {\n                    var node = this$1.eventTarget(e);\n                    if (node && !this$1._suspendedTracking) {\n                        this$1.trigger(eventName, {\n                            element: node,\n                            originalEvent: e,\n                            type: eventName\n                        });\n                    }\n                };\n            },\n            _elementOffset: function () {\n                var element = this.element;\n                var ref = elementStyles(element, [\n                    'paddingLeft',\n                    'paddingTop'\n                ]);\n                var paddingLeft = ref.paddingLeft;\n                var paddingTop = ref.paddingTop;\n                var ref$1 = elementOffset(element);\n                var left = ref$1.left;\n                var top = ref$1.top;\n                return {\n                    left: left + parseInt(paddingLeft, 10),\n                    top: top + parseInt(paddingTop, 10)\n                };\n            },\n            _surfacePoint: function (e) {\n                var offset = this._elementOffset();\n                var coord = eventCoordinates(e);\n                var x = coord.x - offset.left;\n                var y = coord.y - offset.top;\n                return new Point(x, y);\n            }\n        });\n        Surface.create = function (element, options) {\n            return SurfaceFactory.current.create(element, options);\n        };\n        Surface.support = {};\n        var BaseNode = Class.extend({\n            init: function (srcElement) {\n                this.childNodes = [];\n                this.parent = null;\n                if (srcElement) {\n                    this.srcElement = srcElement;\n                    this.observe();\n                }\n            },\n            destroy: function () {\n                var this$1 = this;\n                if (this.srcElement) {\n                    this.srcElement.removeObserver(this);\n                }\n                var children = this.childNodes;\n                for (var i = 0; i < children.length; i++) {\n                    this$1.childNodes[i].destroy();\n                }\n                this.parent = null;\n            },\n            load: function () {\n            },\n            observe: function () {\n                if (this.srcElement) {\n                    this.srcElement.addObserver(this);\n                }\n            },\n            append: function (node) {\n                this.childNodes.push(node);\n                node.parent = this;\n            },\n            insertAt: function (node, pos) {\n                this.childNodes.splice(pos, 0, node);\n                node.parent = this;\n            },\n            remove: function (index, count) {\n                var this$1 = this;\n                var end = index + count;\n                for (var i = index; i < end; i++) {\n                    this$1.childNodes[i].removeSelf();\n                }\n                this.childNodes.splice(index, count);\n            },\n            removeSelf: function () {\n                this.clear();\n                this.destroy();\n            },\n            clear: function () {\n                this.remove(0, this.childNodes.length);\n            },\n            invalidate: function () {\n                if (this.parent) {\n                    this.parent.invalidate();\n                }\n            },\n            geometryChange: function () {\n                this.invalidate();\n            },\n            optionsChange: function () {\n                this.invalidate();\n            },\n            childrenChange: function (e) {\n                if (e.action === 'add') {\n                    this.load(e.items, e.index);\n                } else if (e.action === 'remove') {\n                    this.remove(e.index, e.items.length);\n                }\n                this.invalidate();\n            }\n        });\n        function renderAttr(name, value) {\n            return defined(value) && value !== null ? ' ' + name + '=\"' + value + '\" ' : '';\n        }\n        function renderAllAttr(attrs) {\n            var output = '';\n            for (var i = 0; i < attrs.length; i++) {\n                output += renderAttr(attrs[i][0], attrs[i][1]);\n            }\n            return output;\n        }\n        function renderStyle(attrs) {\n            var output = '';\n            for (var i = 0; i < attrs.length; i++) {\n                var value = attrs[i][1];\n                if (defined(value)) {\n                    output += attrs[i][0] + ':' + value + ';';\n                }\n            }\n            if (output !== '') {\n                return output;\n            }\n        }\n        var NODE_MAP = {};\n        var SVG_NS = 'http://www.w3.org/2000/svg';\n        var NONE = 'none';\n        var renderSVG = function (container, svg) {\n            container.innerHTML = svg;\n        };\n        if (typeof document !== 'undefined') {\n            var testFragment = '<svg xmlns=\\'' + SVG_NS + '\\'></svg>';\n            var testContainer = document.createElement('div');\n            var hasParser = typeof DOMParser !== 'undefined';\n            testContainer.innerHTML = testFragment;\n            if (hasParser && testContainer.firstChild.namespaceURI !== SVG_NS) {\n                renderSVG = function (container, svg) {\n                    var parser = new DOMParser();\n                    var chartDoc = parser.parseFromString(svg, 'text/xml');\n                    var importedDoc = document.adoptNode(chartDoc.documentElement);\n                    container.innerHTML = '';\n                    container.appendChild(importedDoc);\n                };\n            }\n        }\n        var renderSVG$1 = renderSVG;\n        var TRANSFORM = 'transform';\n        var DefinitionMap = {\n            clip: 'clip-path',\n            fill: 'fill'\n        };\n        function isDefinition(type, value) {\n            return type === 'clip' || type === 'fill' && (!value || value.nodeType === 'Gradient');\n        }\n        function baseUrl() {\n            var base = document.getElementsByTagName('base')[0];\n            var href = document.location.href;\n            var url = '';\n            if (base && !supportBrowser.msie) {\n                var hashIndex = href.indexOf('#');\n                if (hashIndex !== -1) {\n                    href = href.substring(0, hashIndex);\n                }\n                url = href;\n            }\n            return url;\n        }\n        var Node = BaseNode.extend({\n            init: function (srcElement, options) {\n                BaseNode.fn.init.call(this, srcElement);\n                this.definitions = {};\n                this.options = options;\n            },\n            destroy: function () {\n                if (this.element) {\n                    this.element._kendoNode = null;\n                    this.element = null;\n                }\n                this.clearDefinitions();\n                BaseNode.fn.destroy.call(this);\n            },\n            load: function (elements, pos) {\n                var this$1 = this;\n                for (var i = 0; i < elements.length; i++) {\n                    var srcElement = elements[i];\n                    var children = srcElement.children;\n                    var childNode = new NODE_MAP[srcElement.nodeType](srcElement, this$1.options);\n                    if (defined(pos)) {\n                        this$1.insertAt(childNode, pos);\n                    } else {\n                        this$1.append(childNode);\n                    }\n                    childNode.createDefinitions();\n                    if (children && children.length > 0) {\n                        childNode.load(children);\n                    }\n                    var element = this$1.element;\n                    if (element) {\n                        childNode.attachTo(element, pos);\n                    }\n                }\n            },\n            root: function () {\n                var root = this;\n                while (root.parent) {\n                    root = root.parent;\n                }\n                return root;\n            },\n            attachTo: function (domElement, pos) {\n                var container = document.createElement('div');\n                renderSVG$1(container, '<svg xmlns=\\'' + SVG_NS + '\\' version=\\'1.1\\'>' + this.render() + '</svg>');\n                var element = container.firstChild.firstChild;\n                if (element) {\n                    if (defined(pos)) {\n                        domElement.insertBefore(element, domElement.childNodes[pos] || null);\n                    } else {\n                        domElement.appendChild(element);\n                    }\n                    this.setElement(element);\n                }\n            },\n            setElement: function (element) {\n                if (this.element) {\n                    this.element._kendoNode = null;\n                }\n                this.element = element;\n                this.element._kendoNode = this;\n                var nodes = this.childNodes;\n                for (var i = 0; i < nodes.length; i++) {\n                    var childElement = element.childNodes[i];\n                    nodes[i].setElement(childElement);\n                }\n            },\n            clear: function () {\n                this.clearDefinitions();\n                if (this.element) {\n                    this.element.innerHTML = '';\n                }\n                var children = this.childNodes;\n                for (var i = 0; i < children.length; i++) {\n                    children[i].destroy();\n                }\n                this.childNodes = [];\n            },\n            removeSelf: function () {\n                if (this.element) {\n                    var parentNode = this.element.parentNode;\n                    if (parentNode) {\n                        parentNode.removeChild(this.element);\n                    }\n                    this.element = null;\n                }\n                BaseNode.fn.removeSelf.call(this);\n            },\n            template: function () {\n                return this.renderChildren();\n            },\n            render: function () {\n                return this.template();\n            },\n            renderChildren: function () {\n                var nodes = this.childNodes;\n                var output = '';\n                for (var i = 0; i < nodes.length; i++) {\n                    output += nodes[i].render();\n                }\n                return output;\n            },\n            optionsChange: function (e) {\n                var field = e.field;\n                var value = e.value;\n                if (field === 'visible') {\n                    this.css('display', value ? '' : NONE);\n                } else if (DefinitionMap[field] && isDefinition(field, value)) {\n                    this.updateDefinition(field, value);\n                } else if (field === 'opacity') {\n                    this.attr('opacity', value);\n                } else if (field === 'cursor') {\n                    this.css('cursor', value);\n                } else if (field === 'id') {\n                    if (value) {\n                        this.attr('id', value);\n                    } else {\n                        this.removeAttr('id');\n                    }\n                }\n                BaseNode.fn.optionsChange.call(this, e);\n            },\n            attr: function (name, value) {\n                if (this.element) {\n                    this.element.setAttribute(name, value);\n                }\n            },\n            allAttr: function (attrs) {\n                var this$1 = this;\n                for (var i = 0; i < attrs.length; i++) {\n                    this$1.attr(attrs[i][0], attrs[i][1]);\n                }\n            },\n            css: function (name, value) {\n                if (this.element) {\n                    this.element.style[name] = value;\n                }\n            },\n            allCss: function (styles) {\n                var this$1 = this;\n                for (var i = 0; i < styles.length; i++) {\n                    this$1.css(styles[i][0], styles[i][1]);\n                }\n            },\n            removeAttr: function (name) {\n                if (this.element) {\n                    this.element.removeAttribute(name);\n                }\n            },\n            mapTransform: function (transform) {\n                var attrs = [];\n                if (transform) {\n                    attrs.push([\n                        TRANSFORM,\n                        'matrix(' + transform.matrix().toString(6) + ')'\n                    ]);\n                }\n                return attrs;\n            },\n            renderTransform: function () {\n                return renderAllAttr(this.mapTransform(this.srcElement.transform()));\n            },\n            transformChange: function (value) {\n                if (value) {\n                    this.allAttr(this.mapTransform(value));\n                } else {\n                    this.removeAttr(TRANSFORM);\n                }\n            },\n            mapStyle: function () {\n                var options = this.srcElement.options;\n                var style = [[\n                        'cursor',\n                        options.cursor\n                    ]];\n                if (options.visible === false) {\n                    style.push([\n                        'display',\n                        NONE\n                    ]);\n                }\n                return style;\n            },\n            renderStyle: function () {\n                return renderAttr('style', renderStyle(this.mapStyle(true)));\n            },\n            renderOpacity: function () {\n                return renderAttr('opacity', this.srcElement.options.opacity);\n            },\n            renderId: function () {\n                return renderAttr('id', this.srcElement.options.id);\n            },\n            createDefinitions: function () {\n                var srcElement = this.srcElement;\n                var definitions = this.definitions;\n                if (srcElement) {\n                    var options = srcElement.options;\n                    var hasDefinitions;\n                    for (var field in DefinitionMap) {\n                        var definition = options.get(field);\n                        if (definition && isDefinition(field, definition)) {\n                            definitions[field] = definition;\n                            hasDefinitions = true;\n                        }\n                    }\n                    if (hasDefinitions) {\n                        this.definitionChange({\n                            action: 'add',\n                            definitions: definitions\n                        });\n                    }\n                }\n            },\n            definitionChange: function (e) {\n                if (this.parent) {\n                    this.parent.definitionChange(e);\n                }\n            },\n            updateDefinition: function (type, value) {\n                var definitions = this.definitions;\n                var current = definitions[type];\n                var attr = DefinitionMap[type];\n                var definition = {};\n                if (current) {\n                    definition[type] = current;\n                    this.definitionChange({\n                        action: 'remove',\n                        definitions: definition\n                    });\n                    delete definitions[type];\n                }\n                if (!value) {\n                    if (current) {\n                        this.removeAttr(attr);\n                    }\n                } else {\n                    definition[type] = value;\n                    this.definitionChange({\n                        action: 'add',\n                        definitions: definition\n                    });\n                    definitions[type] = value;\n                    this.attr(attr, this.refUrl(value.id));\n                }\n            },\n            clearDefinitions: function () {\n                var definitions = this.definitions;\n                this.definitionChange({\n                    action: 'remove',\n                    definitions: definitions\n                });\n                this.definitions = {};\n            },\n            renderDefinitions: function () {\n                return renderAllAttr(this.mapDefinitions());\n            },\n            mapDefinitions: function () {\n                var this$1 = this;\n                var definitions = this.definitions;\n                var attrs = [];\n                for (var field in definitions) {\n                    attrs.push([\n                        DefinitionMap[field],\n                        this$1.refUrl(definitions[field].id)\n                    ]);\n                }\n                return attrs;\n            },\n            refUrl: function (id) {\n                var skipBaseHref = (this.options || {}).skipBaseHref;\n                var baseHref = this.baseUrl().replace(/'/g, '\\\\\\'');\n                var base = skipBaseHref ? '' : baseHref;\n                return 'url(' + base + '#' + id + ')';\n            },\n            baseUrl: function () {\n                return baseUrl();\n            }\n        });\n        var GradientStopNode = Node.extend({\n            template: function () {\n                return '<stop ' + this.renderOffset() + ' ' + this.renderStyle() + ' />';\n            },\n            renderOffset: function () {\n                return renderAttr('offset', this.srcElement.offset());\n            },\n            mapStyle: function () {\n                var srcElement = this.srcElement;\n                return [\n                    [\n                        'stop-color',\n                        srcElement.color()\n                    ],\n                    [\n                        'stop-opacity',\n                        srcElement.opacity()\n                    ]\n                ];\n            },\n            optionsChange: function (e) {\n                if (e.field === 'offset') {\n                    this.attr(e.field, e.value);\n                } else if (e.field === 'color' || e.field === 'opacity') {\n                    this.css('stop-' + e.field, e.value);\n                }\n            }\n        });\n        var GradientNode = Node.extend({\n            init: function (srcElement) {\n                Node.fn.init.call(this, srcElement);\n                this.id = srcElement.id;\n                this.loadStops();\n            },\n            loadStops: function () {\n                var this$1 = this;\n                var stops = this.srcElement.stops;\n                var element = this.element;\n                for (var idx = 0; idx < stops.length; idx++) {\n                    var stopNode = new GradientStopNode(stops[idx]);\n                    this$1.append(stopNode);\n                    if (element) {\n                        stopNode.attachTo(element);\n                    }\n                }\n            },\n            optionsChange: function (e) {\n                if (e.field === 'gradient.stops') {\n                    BaseNode.prototype.clear.call(this);\n                    this.loadStops();\n                } else if (e.field === 'gradient') {\n                    this.allAttr(this.mapCoordinates());\n                }\n            },\n            renderCoordinates: function () {\n                return renderAllAttr(this.mapCoordinates());\n            },\n            mapSpace: function () {\n                return [\n                    'gradientUnits',\n                    this.srcElement.userSpace() ? 'userSpaceOnUse' : 'objectBoundingBox'\n                ];\n            }\n        });\n        var LinearGradientNode = GradientNode.extend({\n            template: function () {\n                return '<linearGradient id=\\'' + this.id + '\\' ' + this.renderCoordinates() + '>' + this.renderChildren() + '</linearGradient>';\n            },\n            mapCoordinates: function () {\n                var srcElement = this.srcElement;\n                var start = srcElement.start();\n                var end = srcElement.end();\n                var attrs = [\n                    [\n                        'x1',\n                        start.x\n                    ],\n                    [\n                        'y1',\n                        start.y\n                    ],\n                    [\n                        'x2',\n                        end.x\n                    ],\n                    [\n                        'y2',\n                        end.y\n                    ],\n                    this.mapSpace()\n                ];\n                return attrs;\n            }\n        });\n        var RadialGradientNode = GradientNode.extend({\n            template: function () {\n                return '<radialGradient id=\\'' + this.id + '\\' ' + this.renderCoordinates() + '>' + this.renderChildren() + '</radialGradient>';\n            },\n            mapCoordinates: function () {\n                var srcElement = this.srcElement;\n                var center = srcElement.center();\n                var radius = srcElement.radius();\n                var attrs = [\n                    [\n                        'cx',\n                        center.x\n                    ],\n                    [\n                        'cy',\n                        center.y\n                    ],\n                    [\n                        'r',\n                        radius\n                    ],\n                    this.mapSpace()\n                ];\n                return attrs;\n            }\n        });\n        var ClipNode = Node.extend({\n            init: function (srcElement) {\n                Node.fn.init.call(this);\n                this.srcElement = srcElement;\n                this.id = srcElement.id;\n                this.load([srcElement]);\n            },\n            template: function () {\n                return '<clipPath id=\\'' + this.id + '\\'>' + this.renderChildren() + '</clipPath>';\n            }\n        });\n        var DefinitionNode = Node.extend({\n            init: function () {\n                Node.fn.init.call(this);\n                this.definitionMap = {};\n            },\n            attachTo: function (domElement) {\n                this.element = domElement;\n            },\n            template: function () {\n                return '<defs>' + this.renderChildren() + '</defs>';\n            },\n            definitionChange: function (e) {\n                var definitions = e.definitions;\n                var action = e.action;\n                if (action === 'add') {\n                    this.addDefinitions(definitions);\n                } else if (action === 'remove') {\n                    this.removeDefinitions(definitions);\n                }\n            },\n            createDefinition: function (type, item) {\n                var nodeType;\n                if (type === 'clip') {\n                    nodeType = ClipNode;\n                } else if (type === 'fill') {\n                    if (item instanceof LinearGradient) {\n                        nodeType = LinearGradientNode;\n                    } else if (item instanceof RadialGradient) {\n                        nodeType = RadialGradientNode;\n                    }\n                }\n                return new nodeType(item);\n            },\n            addDefinitions: function (definitions) {\n                var this$1 = this;\n                for (var field in definitions) {\n                    this$1.addDefinition(field, definitions[field]);\n                }\n            },\n            addDefinition: function (type, srcElement) {\n                var ref = this;\n                var element = ref.element;\n                var definitionMap = ref.definitionMap;\n                var id = srcElement.id;\n                var mapItem = definitionMap[id];\n                if (!mapItem) {\n                    var node = this.createDefinition(type, srcElement);\n                    definitionMap[id] = {\n                        element: node,\n                        count: 1\n                    };\n                    this.append(node);\n                    if (element) {\n                        node.attachTo(this.element);\n                    }\n                } else {\n                    mapItem.count++;\n                }\n            },\n            removeDefinitions: function (definitions) {\n                var this$1 = this;\n                for (var field in definitions) {\n                    this$1.removeDefinition(definitions[field]);\n                }\n            },\n            removeDefinition: function (srcElement) {\n                var definitionMap = this.definitionMap;\n                var id = srcElement.id;\n                var mapItem = definitionMap[id];\n                if (mapItem) {\n                    mapItem.count--;\n                    if (mapItem.count === 0) {\n                        this.remove(this.childNodes.indexOf(mapItem.element), 1);\n                        delete definitionMap[id];\n                    }\n                }\n            }\n        });\n        var RootNode = Node.extend({\n            init: function (options) {\n                Node.fn.init.call(this);\n                this.options = options;\n                this.defs = new DefinitionNode();\n            },\n            attachTo: function (domElement) {\n                this.element = domElement;\n                this.defs.attachTo(domElement.firstElementChild);\n            },\n            clear: function () {\n                BaseNode.prototype.clear.call(this);\n            },\n            template: function () {\n                return this.defs.render() + this.renderChildren();\n            },\n            definitionChange: function (e) {\n                this.defs.definitionChange(e);\n            }\n        });\n        var RTL = 'rtl';\n        function alignToScreen(element) {\n            var ctm;\n            try {\n                ctm = element.getScreenCTM ? element.getScreenCTM() : null;\n            } catch (e) {\n            }\n            if (ctm) {\n                var left = -ctm.e % 1;\n                var top = -ctm.f % 1;\n                var style = element.style;\n                if (left !== 0 || top !== 0) {\n                    style.left = left + 'px';\n                    style.top = top + 'px';\n                }\n            }\n        }\n        var Surface$1 = Surface.extend({\n            init: function (element, options) {\n                Surface.fn.init.call(this, element, options);\n                this._root = new RootNode($.extend({ rtl: elementStyles(element, 'direction').direction === RTL }, this.options));\n                renderSVG$1(this.element, this._template());\n                this._rootElement = this.element.firstElementChild;\n                alignToScreen(this._rootElement);\n                this._root.attachTo(this._rootElement);\n                bindEvents(this.element, {\n                    click: this._click,\n                    mouseover: this._mouseenter,\n                    mouseout: this._mouseleave,\n                    mousemove: this._mousemove\n                });\n                this.resize();\n            },\n            destroy: function () {\n                if (this._root) {\n                    this._root.destroy();\n                    this._root = null;\n                    this._rootElement = null;\n                    unbindEvents(this.element, {\n                        click: this._click,\n                        mouseover: this._mouseenter,\n                        mouseout: this._mouseleave,\n                        mousemove: this._mousemove\n                    });\n                }\n                Surface.fn.destroy.call(this);\n            },\n            translate: function (offset) {\n                var viewBox = Math.round(offset.x) + ' ' + Math.round(offset.y) + ' ' + this._size.width + ' ' + this._size.height;\n                this._offset = offset;\n                this._rootElement.setAttribute('viewBox', viewBox);\n            },\n            draw: function (element) {\n                Surface.fn.draw.call(this, element);\n                this._root.load([element]);\n            },\n            clear: function () {\n                Surface.fn.clear.call(this);\n                this._root.clear();\n            },\n            svg: function () {\n                return '<?xml version=\\'1.0\\' ?>' + this._template();\n            },\n            exportVisual: function () {\n                var ref = this;\n                var visual = ref._visual;\n                var offset = ref._offset;\n                if (offset) {\n                    var wrap = new Group();\n                    wrap.children.push(visual);\n                    wrap.transform(transform().translate(-offset.x, -offset.y));\n                    visual = wrap;\n                }\n                return visual;\n            },\n            _resize: function () {\n                if (this._offset) {\n                    this.translate(this._offset);\n                }\n            },\n            _template: function () {\n                return '<svg style=\\'width: 100%; height: 100%; overflow: hidden;\\' xmlns=\\'' + SVG_NS + '\\' xmlns:xlink=\\'http://www.w3.org/1999/xlink\\' version=\\'1.1\\'>' + this._root.render() + '</svg>';\n            }\n        });\n        Surface$1.prototype.type = 'svg';\n        if (typeof document !== 'undefined' && document.implementation.hasFeature('http://www.w3.org/TR/SVG11/feature#BasicStructure', '1.1')) {\n            Surface.support.svg = true;\n            SurfaceFactory.current.register('svg', Surface$1, 10);\n        }\n        var GroupNode = Node.extend({\n            template: function () {\n                return '<g' + (this.renderId() + this.renderTransform() + this.renderStyle() + this.renderOpacity() + this.renderDefinitions()) + '>' + this.renderChildren() + '</g>';\n            },\n            optionsChange: function (e) {\n                if (e.field === 'transform') {\n                    this.transformChange(e.value);\n                }\n                Node.fn.optionsChange.call(this, e);\n            }\n        });\n        NODE_MAP.Group = GroupNode;\n        var DASH_ARRAYS = {\n            dot: [\n                1.5,\n                3.5\n            ],\n            dash: [\n                4,\n                3.5\n            ],\n            longdash: [\n                8,\n                3.5\n            ],\n            dashdot: [\n                3.5,\n                3.5,\n                1.5,\n                3.5\n            ],\n            longdashdot: [\n                8,\n                3.5,\n                1.5,\n                3.5\n            ],\n            longdashdotdot: [\n                8,\n                3.5,\n                1.5,\n                3.5,\n                1.5,\n                3.5\n            ]\n        };\n        var SOLID = 'solid';\n        var BUTT = 'butt';\n        var ATTRIBUTE_MAP = {\n            'fill.opacity': 'fill-opacity',\n            'stroke.color': 'stroke',\n            'stroke.width': 'stroke-width',\n            'stroke.opacity': 'stroke-opacity'\n        };\n        var SPACE = ' ';\n        var PathNode = Node.extend({\n            geometryChange: function () {\n                this.attr('d', this.renderData());\n                this.invalidate();\n            },\n            optionsChange: function (e) {\n                switch (e.field) {\n                case 'fill':\n                    if (e.value) {\n                        this.allAttr(this.mapFill(e.value));\n                    } else {\n                        this.removeAttr('fill');\n                    }\n                    break;\n                case 'fill.color':\n                    this.allAttr(this.mapFill({ color: e.value }));\n                    break;\n                case 'stroke':\n                    if (e.value) {\n                        this.allAttr(this.mapStroke(e.value));\n                    } else {\n                        this.removeAttr('stroke');\n                    }\n                    break;\n                case 'transform':\n                    this.transformChange(e.value);\n                    break;\n                default:\n                    var name = ATTRIBUTE_MAP[e.field];\n                    if (name) {\n                        this.attr(name, e.value);\n                    }\n                    break;\n                }\n                Node.fn.optionsChange.call(this, e);\n            },\n            content: function () {\n                if (this.element) {\n                    this.element.textContent = this.srcElement.content();\n                }\n            },\n            renderData: function () {\n                return this.printPath(this.srcElement);\n            },\n            printPath: function (path) {\n                var this$1 = this;\n                var segments = path.segments;\n                var length = segments.length;\n                if (length > 0) {\n                    var parts = [];\n                    var output, currentType;\n                    for (var i = 1; i < length; i++) {\n                        var segmentType = this$1.segmentType(segments[i - 1], segments[i]);\n                        if (segmentType !== currentType) {\n                            currentType = segmentType;\n                            parts.push(segmentType);\n                        }\n                        if (segmentType === 'L') {\n                            parts.push(this$1.printPoints(segments[i].anchor()));\n                        } else {\n                            parts.push(this$1.printPoints(segments[i - 1].controlOut(), segments[i].controlIn(), segments[i].anchor()));\n                        }\n                    }\n                    output = 'M' + this.printPoints(segments[0].anchor()) + SPACE + parts.join(SPACE);\n                    if (path.options.closed) {\n                        output += 'Z';\n                    }\n                    return output;\n                }\n            },\n            printPoints: function () {\n                var points = arguments;\n                var length = points.length;\n                var result = [];\n                for (var i = 0; i < length; i++) {\n                    result.push(points[i].toString(3));\n                }\n                return result.join(' ');\n            },\n            segmentType: function (segmentStart, segmentEnd) {\n                return segmentStart.controlOut() && segmentEnd.controlIn() ? 'C' : 'L';\n            },\n            mapStroke: function (stroke) {\n                var attrs = [];\n                if (stroke && !isTransparent(stroke.color)) {\n                    attrs.push([\n                        'stroke',\n                        stroke.color\n                    ]);\n                    attrs.push([\n                        'stroke-width',\n                        stroke.width\n                    ]);\n                    attrs.push([\n                        'stroke-linecap',\n                        this.renderLinecap(stroke)\n                    ]);\n                    attrs.push([\n                        'stroke-linejoin',\n                        stroke.lineJoin\n                    ]);\n                    if (defined(stroke.opacity)) {\n                        attrs.push([\n                            'stroke-opacity',\n                            stroke.opacity\n                        ]);\n                    }\n                    if (defined(stroke.dashType)) {\n                        attrs.push([\n                            'stroke-dasharray',\n                            this.renderDashType(stroke)\n                        ]);\n                    }\n                } else {\n                    attrs.push([\n                        'stroke',\n                        NONE\n                    ]);\n                }\n                return attrs;\n            },\n            renderStroke: function () {\n                return renderAllAttr(this.mapStroke(this.srcElement.options.stroke));\n            },\n            renderDashType: function (stroke) {\n                var dashType = stroke.dashType;\n                var width = stroke.width;\n                if (width === void 0) {\n                    width = 1;\n                }\n                if (dashType && dashType !== SOLID) {\n                    var dashArray = DASH_ARRAYS[dashType.toLowerCase()];\n                    var result = [];\n                    for (var i = 0; i < dashArray.length; i++) {\n                        result.push(dashArray[i] * width);\n                    }\n                    return result.join(' ');\n                }\n            },\n            renderLinecap: function (stroke) {\n                var dashType = stroke.dashType;\n                var lineCap = stroke.lineCap;\n                return dashType && dashType !== 'solid' ? BUTT : lineCap;\n            },\n            mapFill: function (fill) {\n                var attrs = [];\n                if (!(fill && fill.nodeType === 'Gradient')) {\n                    if (fill && !isTransparent(fill.color)) {\n                        attrs.push([\n                            'fill',\n                            fill.color\n                        ]);\n                        if (defined(fill.opacity)) {\n                            attrs.push([\n                                'fill-opacity',\n                                fill.opacity\n                            ]);\n                        }\n                    } else {\n                        attrs.push([\n                            'fill',\n                            NONE\n                        ]);\n                    }\n                }\n                return attrs;\n            },\n            renderFill: function () {\n                return renderAllAttr(this.mapFill(this.srcElement.options.fill));\n            },\n            template: function () {\n                return '<path ' + this.renderId() + ' ' + this.renderStyle() + ' ' + this.renderOpacity() + ' ' + renderAttr('d', this.renderData()) + '' + this.renderStroke() + this.renderFill() + this.renderDefinitions() + this.renderTransform() + '></path>';\n            }\n        });\n        NODE_MAP.Path = PathNode;\n        var ArcNode = PathNode.extend({\n            renderData: function () {\n                return this.printPath(this.srcElement.toPath());\n            }\n        });\n        NODE_MAP.Arc = ArcNode;\n        var CircleNode = PathNode.extend({\n            geometryChange: function () {\n                var center = this.center();\n                this.attr('cx', center.x);\n                this.attr('cy', center.y);\n                this.attr('r', this.radius());\n                this.invalidate();\n            },\n            center: function () {\n                return this.srcElement.geometry().center;\n            },\n            radius: function () {\n                return this.srcElement.geometry().radius;\n            },\n            template: function () {\n                return '<circle ' + this.renderId() + ' ' + this.renderStyle() + ' ' + this.renderOpacity() + 'cx=\\'' + this.center().x + '\\' cy=\\'' + this.center().y + '\\' r=\\'' + this.radius() + '\\'' + this.renderStroke() + ' ' + this.renderFill() + ' ' + this.renderDefinitions() + this.renderTransform() + ' ></circle>';\n            }\n        });\n        NODE_MAP.Circle = CircleNode;\n        var RectNode = PathNode.extend({\n            geometryChange: function () {\n                var geometry = this.srcElement.geometry();\n                this.attr('x', geometry.origin.x);\n                this.attr('y', geometry.origin.y);\n                this.attr('width', geometry.size.width);\n                this.attr('height', geometry.size.height);\n                this.invalidate();\n            },\n            size: function () {\n                return this.srcElement.geometry().size;\n            },\n            origin: function () {\n                return this.srcElement.geometry().origin;\n            },\n            template: function () {\n                return '<rect ' + this.renderId() + ' ' + this.renderStyle() + ' ' + this.renderOpacity() + ' x=\\'' + this.origin().x + '\\' y=\\'' + this.origin().y + '\\' ' + 'width=\\'' + this.size().width + '\\' height=\\'' + this.size().height + '\\' ' + this.renderStroke() + ' ' + this.renderFill() + ' ' + this.renderDefinitions() + ' ' + this.renderTransform() + ' />';\n            }\n        });\n        NODE_MAP.Rect = RectNode;\n        var ImageNode = PathNode.extend({\n            geometryChange: function () {\n                this.allAttr(this.mapPosition());\n                this.invalidate();\n            },\n            optionsChange: function (e) {\n                if (e.field === 'src') {\n                    this.allAttr(this.mapSource());\n                }\n                PathNode.fn.optionsChange.call(this, e);\n            },\n            mapPosition: function () {\n                var rect = this.srcElement.rect();\n                var tl = rect.topLeft();\n                return [\n                    [\n                        'x',\n                        tl.x\n                    ],\n                    [\n                        'y',\n                        tl.y\n                    ],\n                    [\n                        'width',\n                        rect.width() + 'px'\n                    ],\n                    [\n                        'height',\n                        rect.height() + 'px'\n                    ]\n                ];\n            },\n            renderPosition: function () {\n                return renderAllAttr(this.mapPosition());\n            },\n            mapSource: function (encode) {\n                var src = this.srcElement.src();\n                if (encode) {\n                    src = kendo.htmlEncode(src);\n                }\n                return [[\n                        'xlink:href',\n                        src\n                    ]];\n            },\n            renderSource: function () {\n                return renderAllAttr(this.mapSource(true));\n            },\n            template: function () {\n                return '<image preserveAspectRatio=\\'none\\' ' + this.renderId() + ' ' + this.renderStyle() + ' ' + this.renderTransform() + ' ' + this.renderOpacity() + this.renderPosition() + ' ' + this.renderSource() + ' ' + this.renderDefinitions() + '>' + '</image>';\n            }\n        });\n        NODE_MAP.Image = ImageNode;\n        var ENTITY_REGEX = /&(?:[a-zA-Z]+|#\\d+);/g;\n        function decodeEntities(text) {\n            if (!text || typeof text !== 'string' || !ENTITY_REGEX.test(text)) {\n                return text;\n            }\n            var element = decodeEntities._element;\n            ENTITY_REGEX.lastIndex = 0;\n            return text.replace(ENTITY_REGEX, function (match) {\n                element.innerHTML = match;\n                return element.textContent || element.innerText;\n            });\n        }\n        if (typeof document !== 'undefined') {\n            decodeEntities._element = document.createElement('span');\n        }\n        var TextNode = PathNode.extend({\n            geometryChange: function () {\n                var pos = this.pos();\n                this.attr('x', pos.x);\n                this.attr('y', pos.y);\n                this.invalidate();\n            },\n            optionsChange: function (e) {\n                if (e.field === 'font') {\n                    this.attr('style', renderStyle(this.mapStyle()));\n                    this.geometryChange();\n                } else if (e.field === 'content') {\n                    PathNode.fn.content.call(this, this.srcElement.content());\n                }\n                PathNode.fn.optionsChange.call(this, e);\n            },\n            mapStyle: function (encode) {\n                var style = PathNode.fn.mapStyle.call(this, encode);\n                var font = this.srcElement.options.font;\n                if (encode) {\n                    font = kendo.htmlEncode(font);\n                }\n                style.push([\n                    'font',\n                    font\n                ], [\n                    'white-space',\n                    'pre'\n                ]);\n                return style;\n            },\n            pos: function () {\n                var pos = this.srcElement.position();\n                var size = this.srcElement.measure();\n                return pos.clone().setY(pos.y + size.baseline);\n            },\n            renderContent: function () {\n                var content = this.srcElement.content();\n                content = decodeEntities(content);\n                content = kendo.htmlEncode(content);\n                return kendoUtil.normalizeText(content);\n            },\n            renderTextAnchor: function () {\n                var anchor;\n                if ((this.options || {}).rtl && !(supportBrowser.msie || supportBrowser.edge)) {\n                    anchor = 'end';\n                }\n                return renderAttr('text-anchor', anchor);\n            },\n            template: function () {\n                return '<text ' + this.renderId() + ' ' + this.renderTextAnchor() + ' ' + this.renderStyle() + ' ' + this.renderOpacity() + 'x=\\'' + this.pos().x + '\\' y=\\'' + this.pos().y + '\\' ' + this.renderStroke() + ' ' + this.renderTransform() + ' ' + this.renderDefinitions() + this.renderFill() + '>' + this.renderContent() + '</text>';\n            }\n        });\n        NODE_MAP.Text = TextNode;\n        var MultiPathNode = PathNode.extend({\n            renderData: function () {\n                var this$1 = this;\n                var paths = this.srcElement.paths;\n                if (paths.length > 0) {\n                    var result = [];\n                    for (var i = 0; i < paths.length; i++) {\n                        result.push(this$1.printPath(paths[i]));\n                    }\n                    return result.join(' ');\n                }\n            }\n        });\n        NODE_MAP.MultiPath = MultiPathNode;\n        var geometry = {\n            Circle: Circle$2,\n            Arc: Arc$2,\n            Rect: Rect,\n            Point: Point,\n            Segment: Segment,\n            Matrix: Matrix,\n            Size: Size,\n            toMatrix: toMatrix,\n            Transformation: Transformation,\n            transform: transform\n        };\n        function exportGroup(group) {\n            var root = new RootNode({ skipBaseHref: true });\n            var bbox = group.clippedBBox();\n            var rootGroup = group;\n            if (bbox) {\n                var origin = bbox.getOrigin();\n                var exportRoot = new Group();\n                exportRoot.transform(transform().translate(-origin.x, -origin.y));\n                exportRoot.children.push(group);\n                rootGroup = exportRoot;\n            }\n            root.load([rootGroup]);\n            var svg = '<?xml version=\\'1.0\\' ?><svg xmlns=\\'' + SVG_NS + '\\' xmlns:xlink=\\'http://www.w3.org/1999/xlink\\' version=\\'1.1\\'>' + root.render() + '</svg>';\n            root.destroy();\n            return svg;\n        }\n        var svg = {\n            Surface: Surface$1,\n            RootNode: RootNode,\n            Node: Node,\n            GroupNode: GroupNode,\n            ArcNode: ArcNode,\n            CircleNode: CircleNode,\n            RectNode: RectNode,\n            ImageNode: ImageNode,\n            TextNode: TextNode,\n            PathNode: PathNode,\n            MultiPathNode: MultiPathNode,\n            DefinitionNode: DefinitionNode,\n            ClipNode: ClipNode,\n            GradientStopNode: GradientStopNode,\n            LinearGradientNode: LinearGradientNode,\n            RadialGradientNode: RadialGradientNode,\n            exportGroup: exportGroup\n        };\n        var NODE_MAP$2 = {};\n        function renderPath(ctx, path) {\n            var segments = path.segments;\n            if (segments.length === 0) {\n                return;\n            }\n            var segment = segments[0];\n            var anchor = segment.anchor();\n            ctx.moveTo(anchor.x, anchor.y);\n            for (var i = 1; i < segments.length; i++) {\n                segment = segments[i];\n                anchor = segment.anchor();\n                var prevSeg = segments[i - 1];\n                var prevOut = prevSeg.controlOut();\n                var controlIn = segment.controlIn();\n                if (prevOut && controlIn) {\n                    ctx.bezierCurveTo(prevOut.x, prevOut.y, controlIn.x, controlIn.y, anchor.x, anchor.y);\n                } else {\n                    ctx.lineTo(anchor.x, anchor.y);\n                }\n            }\n            if (path.options.closed) {\n                ctx.closePath();\n            }\n        }\n        var Node$2 = BaseNode.extend({\n            init: function (srcElement) {\n                BaseNode.fn.init.call(this, srcElement);\n                if (srcElement) {\n                    this.initClip();\n                }\n            },\n            initClip: function () {\n                var clip = this.srcElement.clip();\n                if (clip) {\n                    this.clip = clip;\n                    clip.addObserver(this);\n                }\n            },\n            clear: function () {\n                if (this.srcElement) {\n                    this.srcElement.removeObserver(this);\n                }\n                this.clearClip();\n                BaseNode.fn.clear.call(this);\n            },\n            clearClip: function () {\n                if (this.clip) {\n                    this.clip.removeObserver(this);\n                    delete this.clip;\n                }\n            },\n            setClip: function (ctx) {\n                if (this.clip) {\n                    ctx.beginPath();\n                    renderPath(ctx, this.clip);\n                    ctx.clip();\n                }\n            },\n            optionsChange: function (e) {\n                if (e.field === 'clip') {\n                    this.clearClip();\n                    this.initClip();\n                }\n                BaseNode.fn.optionsChange.call(this, e);\n            },\n            setTransform: function (ctx) {\n                if (this.srcElement) {\n                    var transform = this.srcElement.transform();\n                    if (transform) {\n                        ctx.transform.apply(ctx, transform.matrix().toArray(6));\n                    }\n                }\n            },\n            loadElements: function (elements, pos, cors) {\n                var this$1 = this;\n                for (var i = 0; i < elements.length; i++) {\n                    var srcElement = elements[i];\n                    var children = srcElement.children;\n                    var childNode = new NODE_MAP$2[srcElement.nodeType](srcElement, cors);\n                    if (children && children.length > 0) {\n                        childNode.load(children, pos, cors);\n                    }\n                    if (defined(pos)) {\n                        this$1.insertAt(childNode, pos);\n                    } else {\n                        this$1.append(childNode);\n                    }\n                }\n            },\n            load: function (elements, pos, cors) {\n                this.loadElements(elements, pos, cors);\n                this.invalidate();\n            },\n            setOpacity: function (ctx) {\n                if (this.srcElement) {\n                    var opacity = this.srcElement.opacity();\n                    if (defined(opacity)) {\n                        this.globalAlpha(ctx, opacity);\n                    }\n                }\n            },\n            globalAlpha: function (ctx, value) {\n                var opactity = value;\n                if (opactity && ctx.globalAlpha) {\n                    opactity *= ctx.globalAlpha;\n                }\n                ctx.globalAlpha = opactity;\n            },\n            visible: function () {\n                var src = this.srcElement;\n                return !src || src && src.options.visible !== false;\n            }\n        });\n        var GroupNode$2 = Node$2.extend({\n            renderTo: function (ctx) {\n                if (!this.visible()) {\n                    return;\n                }\n                ctx.save();\n                this.setTransform(ctx);\n                this.setClip(ctx);\n                this.setOpacity(ctx);\n                var childNodes = this.childNodes;\n                for (var i = 0; i < childNodes.length; i++) {\n                    var child = childNodes[i];\n                    if (child.visible()) {\n                        child.renderTo(ctx);\n                    }\n                }\n                ctx.restore();\n            }\n        });\n        Traversable.extend(GroupNode$2.prototype, 'childNodes');\n        NODE_MAP$2.Group = GroupNode$2;\n        var FRAME_DELAY = 1000 / 60;\n        var RootNode$2 = GroupNode$2.extend({\n            init: function (canvas) {\n                GroupNode$2.fn.init.call(this);\n                this.canvas = canvas;\n                this.ctx = canvas.getContext('2d');\n                var invalidateHandler = this._invalidate.bind(this);\n                this.invalidate = kendo.throttle(function () {\n                    kendo.animationFrame(invalidateHandler);\n                }, FRAME_DELAY);\n            },\n            destroy: function () {\n                GroupNode$2.fn.destroy.call(this);\n                this.canvas = null;\n                this.ctx = null;\n            },\n            load: function (elements, pos, cors) {\n                this.loadElements(elements, pos, cors);\n                this._invalidate();\n            },\n            _invalidate: function () {\n                if (!this.ctx) {\n                    return;\n                }\n                this.ctx.clearRect(0, 0, this.canvas.width, this.canvas.height);\n                this.renderTo(this.ctx);\n            }\n        });\n        Traversable.extend(RootNode$2.prototype, 'childNodes');\n        var QuadRoot = Class.extend({\n            init: function () {\n                this.shapes = [];\n            },\n            _add: function (shape, bbox) {\n                this.shapes.push({\n                    bbox: bbox,\n                    shape: shape\n                });\n                shape._quadNode = this;\n            },\n            pointShapes: function (point) {\n                var shapes = this.shapes;\n                var length = shapes.length;\n                var result = [];\n                for (var idx = 0; idx < length; idx++) {\n                    if (shapes[idx].bbox.containsPoint(point)) {\n                        result.push(shapes[idx].shape);\n                    }\n                }\n                return result;\n            },\n            insert: function (shape, bbox) {\n                this._add(shape, bbox);\n            },\n            remove: function (shape) {\n                var shapes = this.shapes;\n                var length = shapes.length;\n                for (var idx = 0; idx < length; idx++) {\n                    if (shapes[idx].shape === shape) {\n                        shapes.splice(idx, 1);\n                        break;\n                    }\n                }\n            }\n        });\n        var QuadNode = QuadRoot.extend({\n            init: function (rect) {\n                QuadRoot.fn.init.call(this);\n                this.children = [];\n                this.rect = rect;\n            },\n            inBounds: function (rect) {\n                var nodeRect = this.rect;\n                var nodeBottomRight = nodeRect.bottomRight();\n                var bottomRight = rect.bottomRight();\n                var inBounds = nodeRect.origin.x <= rect.origin.x && nodeRect.origin.y <= rect.origin.y && bottomRight.x <= nodeBottomRight.x && bottomRight.y <= nodeBottomRight.y;\n                return inBounds;\n            },\n            pointShapes: function (point) {\n                var children = this.children;\n                var length = children.length;\n                var result = QuadRoot.fn.pointShapes.call(this, point);\n                for (var idx = 0; idx < length; idx++) {\n                    append(result, children[idx].pointShapes(point));\n                }\n                return result;\n            },\n            insert: function (shape, bbox) {\n                var children = this.children;\n                var inserted = false;\n                if (this.inBounds(bbox)) {\n                    if (this.shapes.length < 4) {\n                        this._add(shape, bbox);\n                    } else {\n                        if (!children.length) {\n                            this._initChildren();\n                        }\n                        for (var idx = 0; idx < children.length; idx++) {\n                            if (children[idx].insert(shape, bbox)) {\n                                inserted = true;\n                                break;\n                            }\n                        }\n                        if (!inserted) {\n                            this._add(shape, bbox);\n                        }\n                    }\n                    inserted = true;\n                }\n                return inserted;\n            },\n            _initChildren: function () {\n                var ref = this;\n                var rect = ref.rect;\n                var children = ref.children;\n                var center = rect.center();\n                var halfWidth = rect.width() / 2;\n                var halfHeight = rect.height() / 2;\n                children.push(new QuadNode(new Rect([\n                    rect.origin.x,\n                    rect.origin.y\n                ], [\n                    halfWidth,\n                    halfHeight\n                ])), new QuadNode(new Rect([\n                    center.x,\n                    rect.origin.y\n                ], [\n                    halfWidth,\n                    halfHeight\n                ])), new QuadNode(new Rect([\n                    rect.origin.x,\n                    center.y\n                ], [\n                    halfWidth,\n                    halfHeight\n                ])), new QuadNode(new Rect([\n                    center.x,\n                    center.y\n                ], [\n                    halfWidth,\n                    halfHeight\n                ])));\n            }\n        });\n        var ROOT_SIZE = 3000;\n        var LEVEL_STEP = 10000;\n        var MAX_LEVEL = 75;\n        var ShapesQuadTree = Class.extend({\n            init: function () {\n                this.initRoots();\n            },\n            initRoots: function () {\n                this.rootMap = {};\n                this.root = new QuadRoot();\n                this.rootElements = [];\n            },\n            clear: function () {\n                var this$1 = this;\n                var rootElements = this.rootElements;\n                for (var idx = 0; idx < rootElements.length; idx++) {\n                    this$1.remove(rootElements[idx]);\n                }\n                this.initRoots();\n            },\n            pointShape: function (point) {\n                var sectorRoot = (this.rootMap[Math.floor(point.x / ROOT_SIZE)] || {})[Math.floor(point.y / ROOT_SIZE)];\n                var result = this.root.pointShapes(point);\n                if (sectorRoot) {\n                    result = result.concat(sectorRoot.pointShapes(point));\n                }\n                this.assignZindex(result);\n                result.sort(zIndexComparer);\n                for (var idx = 0; idx < result.length; idx++) {\n                    if (result[idx].containsPoint(point)) {\n                        return result[idx];\n                    }\n                }\n            },\n            assignZindex: function (elements) {\n                var this$1 = this;\n                for (var idx = 0; idx < elements.length; idx++) {\n                    var element = elements[idx];\n                    var zIndex = 0;\n                    var levelWeight = Math.pow(LEVEL_STEP, MAX_LEVEL);\n                    var parents = [];\n                    while (element) {\n                        parents.push(element);\n                        element = element.parent;\n                    }\n                    while (parents.length) {\n                        element = parents.pop();\n                        zIndex += ((element.parent ? element.parent.children : this$1.rootElements).indexOf(element) + 1) * levelWeight;\n                        levelWeight /= LEVEL_STEP;\n                    }\n                    elements[idx]._zIndex = zIndex;\n                }\n            },\n            optionsChange: function (e) {\n                if (e.field === 'transform' || e.field === 'stroke.width') {\n                    this.bboxChange(e.element);\n                }\n            },\n            geometryChange: function (e) {\n                this.bboxChange(e.element);\n            },\n            bboxChange: function (element) {\n                var this$1 = this;\n                if (element.nodeType === 'Group') {\n                    for (var idx = 0; idx < element.children.length; idx++) {\n                        this$1.bboxChange(element.children[idx]);\n                    }\n                } else {\n                    if (element._quadNode) {\n                        element._quadNode.remove(element);\n                    }\n                    this._insertShape(element);\n                }\n            },\n            add: function (elements) {\n                var elementsArray = Array.isArray(elements) ? elements.slice(0) : [elements];\n                append(this.rootElements, elementsArray);\n                this._insert(elementsArray);\n            },\n            childrenChange: function (e) {\n                var this$1 = this;\n                if (e.action === 'remove') {\n                    for (var idx = 0; idx < e.items.length; idx++) {\n                        this$1.remove(e.items[idx]);\n                    }\n                } else {\n                    this._insert(Array.prototype.slice.call(e.items, 0));\n                }\n            },\n            _insert: function (elements) {\n                var this$1 = this;\n                var element;\n                while (elements.length > 0) {\n                    element = elements.pop();\n                    element.addObserver(this$1);\n                    if (element.nodeType === 'Group') {\n                        append(elements, element.children);\n                    } else {\n                        this$1._insertShape(element);\n                    }\n                }\n            },\n            _insertShape: function (shape) {\n                var bbox = shape.bbox();\n                if (bbox) {\n                    var sectors = this.getSectors(bbox);\n                    var x = sectors[0][0];\n                    var y = sectors[1][0];\n                    if (this.inRoot(sectors)) {\n                        this.root.insert(shape, bbox);\n                    } else {\n                        var rootMap = this.rootMap;\n                        if (!rootMap[x]) {\n                            rootMap[x] = {};\n                        }\n                        if (!rootMap[x][y]) {\n                            rootMap[x][y] = new QuadNode(new Rect([\n                                x * ROOT_SIZE,\n                                y * ROOT_SIZE\n                            ], [\n                                ROOT_SIZE,\n                                ROOT_SIZE\n                            ]));\n                        }\n                        rootMap[x][y].insert(shape, bbox);\n                    }\n                }\n            },\n            remove: function (element) {\n                var this$1 = this;\n                element.removeObserver(this);\n                if (element.nodeType === 'Group') {\n                    var children = element.children;\n                    for (var idx = 0; idx < children.length; idx++) {\n                        this$1.remove(children[idx]);\n                    }\n                } else if (element._quadNode) {\n                    element._quadNode.remove(element);\n                    delete element._quadNode;\n                }\n            },\n            inRoot: function (sectors) {\n                return sectors[0].length > 1 || sectors[1].length > 1;\n            },\n            getSectors: function (rect) {\n                var bottomRight = rect.bottomRight();\n                var bottomX = Math.floor(bottomRight.x / ROOT_SIZE);\n                var bottomY = Math.floor(bottomRight.y / ROOT_SIZE);\n                var sectors = [\n                    [],\n                    []\n                ];\n                for (var x = Math.floor(rect.origin.x / ROOT_SIZE); x <= bottomX; x++) {\n                    sectors[0].push(x);\n                }\n                for (var y = Math.floor(rect.origin.y / ROOT_SIZE); y <= bottomY; y++) {\n                    sectors[1].push(y);\n                }\n                return sectors;\n            }\n        });\n        function zIndexComparer(x1, x2) {\n            if (x1._zIndex < x2._zIndex) {\n                return 1;\n            }\n            if (x1._zIndex > x2._zIndex) {\n                return -1;\n            }\n            return 0;\n        }\n        var SurfaceCursor = Class.extend({\n            init: function (surface) {\n                surface.bind('mouseenter', this._mouseenter.bind(this));\n                surface.bind('mouseleave', this._mouseleave.bind(this));\n                this.element = surface.element;\n            },\n            clear: function () {\n                this._resetCursor();\n            },\n            destroy: function () {\n                this._resetCursor();\n                delete this.element;\n            },\n            _mouseenter: function (e) {\n                var cursor = this._shapeCursor(e);\n                if (!cursor) {\n                    this._resetCursor();\n                } else {\n                    if (!this._current) {\n                        this._defaultCursor = this._getCursor();\n                    }\n                    this._setCursor(cursor);\n                }\n            },\n            _mouseleave: function () {\n                this._resetCursor();\n            },\n            _shapeCursor: function (e) {\n                var shape = e.element;\n                while (shape && !defined(shape.options.cursor)) {\n                    shape = shape.parent;\n                }\n                if (shape) {\n                    return shape.options.cursor;\n                }\n            },\n            _getCursor: function () {\n                if (this.element) {\n                    return this.element.style.cursor;\n                }\n            },\n            _setCursor: function (cursor) {\n                if (this.element) {\n                    this.element.style.cursor = cursor;\n                    this._current = cursor;\n                }\n            },\n            _resetCursor: function () {\n                if (this._current) {\n                    this._setCursor(this._defaultCursor || '');\n                    delete this._current;\n                }\n            }\n        });\n        var Surface$3 = Surface.extend({\n            init: function (element, options) {\n                Surface.fn.init.call(this, element, options);\n                this.element.innerHTML = this._template(this);\n                var canvas = this.element.firstElementChild;\n                var size = elementSize(element);\n                canvas.width = size.width;\n                canvas.height = size.height;\n                this._rootElement = canvas;\n                this._root = new RootNode$2(canvas);\n                this._mouseTrackHandler = this._trackMouse.bind(this);\n                bindEvents(this.element, {\n                    click: this._mouseTrackHandler,\n                    mousemove: this._mouseTrackHandler\n                });\n            },\n            destroy: function () {\n                Surface.fn.destroy.call(this);\n                if (this._root) {\n                    this._root.destroy();\n                    this._root = null;\n                }\n                if (this._searchTree) {\n                    this._searchTree.clear();\n                    delete this._searchTree;\n                }\n                if (this._cursor) {\n                    this._cursor.destroy();\n                    delete this._cursor;\n                }\n                unbindEvents(this.element, {\n                    click: this._mouseTrackHandler,\n                    mousemove: this._mouseTrackHandler\n                });\n            },\n            draw: function (element) {\n                Surface.fn.draw.call(this, element);\n                this._root.load([element], undefined, this.options.cors);\n                if (this._searchTree) {\n                    this._searchTree.add([element]);\n                }\n            },\n            clear: function () {\n                Surface.fn.clear.call(this);\n                this._root.clear();\n                if (this._searchTree) {\n                    this._searchTree.clear();\n                }\n                if (this._cursor) {\n                    this._cursor.clear();\n                }\n            },\n            eventTarget: function (e) {\n                if (this._searchTree) {\n                    var point = this._surfacePoint(e);\n                    var shape = this._searchTree.pointShape(point);\n                    return shape;\n                }\n            },\n            image: function () {\n                var ref = this;\n                var root = ref._root;\n                var rootElement = ref._rootElement;\n                var loadingStates = [];\n                root.traverse(function (childNode) {\n                    if (childNode.loading) {\n                        loadingStates.push(childNode.loading);\n                    }\n                });\n                var promise = createPromise();\n                var resolveDataURL = function () {\n                    root._invalidate();\n                    try {\n                        var data = rootElement.toDataURL();\n                        promise.resolve(data);\n                    } catch (e) {\n                        promise.reject(e);\n                    }\n                };\n                promiseAll(loadingStates).then(resolveDataURL, resolveDataURL);\n                return promise;\n            },\n            suspendTracking: function () {\n                Surface.fn.suspendTracking.call(this);\n                if (this._searchTree) {\n                    this._searchTree.clear();\n                    delete this._searchTree;\n                }\n            },\n            resumeTracking: function () {\n                Surface.fn.resumeTracking.call(this);\n                if (!this._searchTree) {\n                    this._searchTree = new ShapesQuadTree();\n                    var childNodes = this._root.childNodes;\n                    var rootElements = [];\n                    for (var idx = 0; idx < childNodes.length; idx++) {\n                        rootElements.push(childNodes[idx].srcElement);\n                    }\n                    this._searchTree.add(rootElements);\n                }\n            },\n            _resize: function () {\n                this._rootElement.width = this._size.width;\n                this._rootElement.height = this._size.height;\n                this._root.invalidate();\n            },\n            _template: function () {\n                return '<canvas style=\\'width: 100%; height: 100%;\\'></canvas>';\n            },\n            _enableTracking: function () {\n                this._searchTree = new ShapesQuadTree();\n                this._cursor = new SurfaceCursor(this);\n                Surface.fn._enableTracking.call(this);\n            },\n            _trackMouse: function (e) {\n                if (this._suspendedTracking) {\n                    return;\n                }\n                var shape = this.eventTarget(e);\n                if (e.type !== 'click') {\n                    var currentShape = this._currentShape;\n                    if (currentShape && currentShape !== shape) {\n                        this.trigger('mouseleave', {\n                            element: currentShape,\n                            originalEvent: e,\n                            type: 'mouseleave'\n                        });\n                    }\n                    if (shape && currentShape !== shape) {\n                        this.trigger('mouseenter', {\n                            element: shape,\n                            originalEvent: e,\n                            type: 'mouseenter'\n                        });\n                    }\n                    this.trigger('mousemove', {\n                        element: shape,\n                        originalEvent: e,\n                        type: 'mousemove'\n                    });\n                    this._currentShape = shape;\n                } else if (shape) {\n                    this.trigger('click', {\n                        element: shape,\n                        originalEvent: e,\n                        type: 'click'\n                    });\n                }\n            }\n        });\n        Surface$3.prototype.type = 'canvas';\n        if (typeof document !== 'undefined' && document.createElement('canvas').getContext) {\n            Surface.support.canvas = true;\n            SurfaceFactory.current.register('canvas', Surface$3, 20);\n        }\n        function addGradientStops(gradient, stops) {\n            for (var idx = 0; idx < stops.length; idx++) {\n                var stop = stops[idx];\n                var color = kendo.parseColor(stop.color());\n                color.a *= stop.opacity();\n                gradient.addColorStop(stop.offset(), color.toCssRgba());\n            }\n        }\n        var PathNode$2 = Node$2.extend({\n            renderTo: function (ctx) {\n                ctx.save();\n                this.setTransform(ctx);\n                this.setClip(ctx);\n                this.setOpacity(ctx);\n                ctx.beginPath();\n                this.renderPoints(ctx, this.srcElement);\n                this.setLineDash(ctx);\n                this.setLineCap(ctx);\n                this.setLineJoin(ctx);\n                this.setFill(ctx);\n                this.setStroke(ctx);\n                ctx.restore();\n            },\n            setFill: function (ctx) {\n                var fill = this.srcElement.options.fill;\n                var hasFill = false;\n                if (fill) {\n                    if (fill.nodeType === 'Gradient') {\n                        this.setGradientFill(ctx, fill);\n                        hasFill = true;\n                    } else if (!isTransparent(fill.color)) {\n                        ctx.fillStyle = fill.color;\n                        ctx.save();\n                        this.globalAlpha(ctx, fill.opacity);\n                        ctx.fill();\n                        ctx.restore();\n                        hasFill = true;\n                    }\n                }\n                return hasFill;\n            },\n            setGradientFill: function (ctx, fill) {\n                var bbox = this.srcElement.rawBBox();\n                var gradient;\n                if (fill instanceof LinearGradient) {\n                    var start = fill.start();\n                    var end = fill.end();\n                    gradient = ctx.createLinearGradient(start.x, start.y, end.x, end.y);\n                } else if (fill instanceof RadialGradient) {\n                    var center = fill.center();\n                    gradient = ctx.createRadialGradient(center.x, center.y, 0, center.x, center.y, fill.radius());\n                }\n                addGradientStops(gradient, fill.stops);\n                ctx.save();\n                if (!fill.userSpace()) {\n                    ctx.transform(bbox.width(), 0, 0, bbox.height(), bbox.origin.x, bbox.origin.y);\n                }\n                ctx.fillStyle = gradient;\n                ctx.fill();\n                ctx.restore();\n            },\n            setStroke: function (ctx) {\n                var stroke = this.srcElement.options.stroke;\n                if (stroke && !isTransparent(stroke.color) && stroke.width > 0) {\n                    ctx.strokeStyle = stroke.color;\n                    ctx.lineWidth = valueOrDefault(stroke.width, 1);\n                    ctx.save();\n                    this.globalAlpha(ctx, stroke.opacity);\n                    ctx.stroke();\n                    ctx.restore();\n                    return true;\n                }\n            },\n            dashType: function () {\n                var stroke = this.srcElement.options.stroke;\n                if (stroke && stroke.dashType) {\n                    return stroke.dashType.toLowerCase();\n                }\n            },\n            setLineDash: function (ctx) {\n                var dashType = this.dashType();\n                if (dashType && dashType !== SOLID) {\n                    var dashArray = DASH_ARRAYS[dashType];\n                    if (ctx.setLineDash) {\n                        ctx.setLineDash(dashArray);\n                    } else {\n                        ctx.mozDash = dashArray;\n                        ctx.webkitLineDash = dashArray;\n                    }\n                }\n            },\n            setLineCap: function (ctx) {\n                var dashType = this.dashType();\n                var stroke = this.srcElement.options.stroke;\n                if (dashType && dashType !== SOLID) {\n                    ctx.lineCap = BUTT;\n                } else if (stroke && stroke.lineCap) {\n                    ctx.lineCap = stroke.lineCap;\n                }\n            },\n            setLineJoin: function (ctx) {\n                var stroke = this.srcElement.options.stroke;\n                if (stroke && stroke.lineJoin) {\n                    ctx.lineJoin = stroke.lineJoin;\n                }\n            },\n            renderPoints: function (ctx, path) {\n                renderPath(ctx, path);\n            }\n        });\n        NODE_MAP$2.Path = PathNode$2;\n        var ArcNode$2 = PathNode$2.extend({\n            renderPoints: function (ctx) {\n                var path = this.srcElement.toPath();\n                renderPath(ctx, path);\n            }\n        });\n        NODE_MAP$2.Arc = ArcNode$2;\n        var CircleNode$2 = PathNode$2.extend({\n            renderPoints: function (ctx) {\n                var ref = this.srcElement.geometry();\n                var center = ref.center;\n                var radius = ref.radius;\n                ctx.arc(center.x, center.y, radius, 0, Math.PI * 2);\n            }\n        });\n        NODE_MAP$2.Circle = CircleNode$2;\n        var RectNode$2 = PathNode$2.extend({\n            renderPoints: function (ctx) {\n                var ref = this.srcElement.geometry();\n                var origin = ref.origin;\n                var size = ref.size;\n                ctx.rect(origin.x, origin.y, size.width, size.height);\n            }\n        });\n        NODE_MAP$2.Rect = RectNode$2;\n        var ImageNode$2 = PathNode$2.extend({\n            init: function (srcElement, cors) {\n                PathNode$2.fn.init.call(this, srcElement);\n                this.onLoad = this.onLoad.bind(this);\n                this.onError = this.onError.bind(this);\n                this.loading = createPromise();\n                var img = this.img = new Image();\n                if (cors && !/^data:/i.test(srcElement.src())) {\n                    img.crossOrigin = cors;\n                }\n                img.src = srcElement.src();\n                if (img.complete) {\n                    this.onLoad();\n                } else {\n                    img.onload = this.onLoad;\n                    img.onerror = this.onError;\n                }\n            },\n            renderTo: function (ctx) {\n                if (this.loading.state() === 'resolved') {\n                    ctx.save();\n                    this.setTransform(ctx);\n                    this.setClip(ctx);\n                    this.drawImage(ctx);\n                    ctx.restore();\n                }\n            },\n            optionsChange: function (e) {\n                if (e.field === 'src') {\n                    this.loading = createPromise();\n                    this.img.src = this.srcElement.src();\n                } else {\n                    PathNode$2.fn.optionsChange.call(this, e);\n                }\n            },\n            onLoad: function () {\n                this.loading.resolve();\n                this.invalidate();\n            },\n            onError: function () {\n                this.loading.reject(new Error('Unable to load image \\'' + this.img.src + '\\'. Check for connectivity and verify CORS headers.'));\n            },\n            drawImage: function (ctx) {\n                var rect = this.srcElement.rect();\n                var topLeft = rect.topLeft();\n                ctx.drawImage(this.img, topLeft.x, topLeft.y, rect.width(), rect.height());\n            }\n        });\n        NODE_MAP$2.Image = ImageNode$2;\n        var TextNode$2 = PathNode$2.extend({\n            renderTo: function (ctx) {\n                var text = this.srcElement;\n                var pos = text.position();\n                var size = text.measure();\n                ctx.save();\n                this.setTransform(ctx);\n                this.setClip(ctx);\n                this.setOpacity(ctx);\n                ctx.beginPath();\n                ctx.font = text.options.font;\n                ctx.textAlign = 'left';\n                if (this.setFill(ctx)) {\n                    ctx.fillText(text.content(), pos.x, pos.y + size.baseline);\n                }\n                if (this.setStroke(ctx)) {\n                    this.setLineDash(ctx);\n                    ctx.strokeText(text.content(), pos.x, pos.y + size.baseline);\n                }\n                ctx.restore();\n            }\n        });\n        NODE_MAP$2.Text = TextNode$2;\n        var MultiPathNode$2 = PathNode$2.extend({\n            renderPoints: function (ctx) {\n                var paths = this.srcElement.paths;\n                for (var i = 0; i < paths.length; i++) {\n                    renderPath(ctx, paths[i]);\n                }\n            }\n        });\n        NODE_MAP$2.MultiPath = MultiPathNode$2;\n        var canvas = {\n            Surface: Surface$3,\n            RootNode: RootNode$2,\n            Node: Node$2,\n            GroupNode: GroupNode$2,\n            ArcNode: ArcNode$2,\n            CircleNode: CircleNode$2,\n            RectNode: RectNode$2,\n            ImageNode: ImageNode$2,\n            TextNode: TextNode$2,\n            PathNode: PathNode$2,\n            MultiPathNode: MultiPathNode$2\n        };\n        function exportImage(group, options) {\n            var defaults = {\n                width: '800px',\n                height: '600px',\n                cors: 'Anonymous'\n            };\n            var exportRoot = group;\n            var bbox = group.clippedBBox();\n            if (bbox) {\n                var origin = bbox.getOrigin();\n                exportRoot = new Group();\n                exportRoot.transform(transform().translate(-origin.x, -origin.y));\n                exportRoot.children.push(group);\n                var size = bbox.getSize();\n                defaults.width = size.width + 'px';\n                defaults.height = size.height + 'px';\n            }\n            var surfaceOptions = $.extend(defaults, options);\n            var container = document.createElement('div');\n            var style = container.style;\n            style.display = 'none';\n            style.width = surfaceOptions.width;\n            style.height = surfaceOptions.height;\n            document.body.appendChild(container);\n            var surface = new Surface$3(container, surfaceOptions);\n            surface.suspendTracking();\n            surface.draw(exportRoot);\n            var promise = surface.image();\n            var destroy = function () {\n                surface.destroy();\n                document.body.removeChild(container);\n            };\n            promise.then(destroy, destroy);\n            return promise;\n        }\n        function exportSVG(group, options) {\n            var svg = exportGroup(group);\n            if (!options || !options.raw) {\n                svg = 'data:image/svg+xml;base64,' + encodeBase64(svg);\n            }\n            return createPromise().resolve(svg);\n        }\n        var browser = supportBrowser;\n        function slice$1(thing) {\n            return Array.prototype.slice.call(thing);\n        }\n        var KENDO_PSEUDO_ELEMENT = 'KENDO-PSEUDO-ELEMENT';\n        var IMAGE_CACHE = {};\n        var nodeInfo = {};\n        nodeInfo._root = nodeInfo;\n        var inBrowser = typeof window !== 'undefined';\n        var microsoft = inBrowser ? browser.msie || browser.edge : false;\n        var TextRect = Text.extend({\n            init: function (str, rect, options) {\n                Text.fn.init.call(this, str, rect.getOrigin(), options);\n                this._pdfRect = rect;\n            },\n            rect: function () {\n                return this._pdfRect;\n            },\n            rawBBox: function () {\n                return this._pdfRect;\n            }\n        });\n        function addClass(el, cls) {\n            if (el.classList) {\n                el.classList.add(cls);\n            } else {\n                el.className += ' ' + cls;\n            }\n        }\n        function removeClass(el, cls) {\n            if (el.classList) {\n                el.classList.remove(cls);\n            } else {\n                el.className = el.className.split(/\\s+/).reduce(function (a, word) {\n                    if (word != cls) {\n                        a.push(word);\n                    }\n                    return a;\n                }, []).join(' ');\n            }\n        }\n        function setCSS(el, styles) {\n            Object.keys(styles).forEach(function (key) {\n                el.style[key] = styles[key];\n            });\n        }\n        var matches = typeof Element !== 'undefined' && Element.prototype && function (p) {\n            if (p.matches) {\n                return function (el, selector) {\n                    return el.matches(selector);\n                };\n            }\n            if (p.webkitMatchesSelector) {\n                return function (el, selector) {\n                    return el.webkitMatchesSelector(selector);\n                };\n            }\n            if (p.mozMatchesSelector) {\n                return function (el, selector) {\n                    return el.mozMatchesSelector(selector);\n                };\n            }\n            if (p.msMatchesSelector) {\n                return function (el, selector) {\n                    return el.msMatchesSelector(selector);\n                };\n            }\n            return function (s) {\n                return [].indexOf.call(document.querySelectorAll(s), this) !== -1;\n            };\n        }(Element.prototype);\n        function closest(el, selector) {\n            if (el.closest) {\n                return el.closest(selector);\n            }\n            while (el && !/^\\[object (?:HTML)?Document\\]$/.test(String(el))) {\n                if (el.nodeType == 1 && matches(el, selector)) {\n                    return el;\n                }\n                el = el.parentNode;\n            }\n        }\n        var cloneNodes = function ($) {\n            if ($) {\n                return function cloneNodes(el) {\n                    var clone = el.cloneNode(false);\n                    if (el.nodeType == 1) {\n                        var $el = $(el), $clone = $(clone), i;\n                        var data = $el.data();\n                        for (i in data) {\n                            $clone.data(i, data[i]);\n                        }\n                        if (/^canvas$/i.test(el.tagName)) {\n                            clone.getContext('2d').drawImage(el, 0, 0);\n                        } else if (/^(?:input|select|textarea|option)$/i.test(el.tagName)) {\n                            clone.removeAttribute('id');\n                            clone.removeAttribute('name');\n                            clone.value = el.value;\n                            clone.checked = el.checked;\n                            clone.selected = el.selected;\n                        }\n                        for (i = el.firstChild; i; i = i.nextSibling) {\n                            clone.appendChild(cloneNodes(i));\n                        }\n                    }\n                    return clone;\n                };\n            } else {\n                return function cloneNodes(el) {\n                    var clone = function dive(node) {\n                        var clone = node.cloneNode(false);\n                        if (node._kendoExportVisual) {\n                            clone._kendoExportVisual = node._kendoExportVisual;\n                        }\n                        for (var i = node.firstChild; i; i = i.nextSibling) {\n                            clone.appendChild(dive(i));\n                        }\n                        return clone;\n                    }(el);\n                    var canvases = el.querySelectorAll('canvas');\n                    if (canvases.length) {\n                        slice$1(clone.querySelectorAll('canvas')).forEach(function (canvas$$1, i) {\n                            canvas$$1.getContext('2d').drawImage(canvases[i], 0, 0);\n                        });\n                    }\n                    var orig = el.querySelectorAll('input, select, textarea, option');\n                    slice$1(clone.querySelectorAll('input, select, textarea, option')).forEach(function (el, i) {\n                        el.removeAttribute('id');\n                        el.removeAttribute('name');\n                        el.value = orig[i].value;\n                        el.checked = orig[i].checked;\n                        el.selected = orig[i].selected;\n                    });\n                    return clone;\n                };\n            }\n        }(typeof window !== 'undefined' && window.kendo && window.kendo.jQuery);\n        function getXY(thing) {\n            if (typeof thing == 'number') {\n                return {\n                    x: thing,\n                    y: thing\n                };\n            }\n            if (Array.isArray(thing)) {\n                return {\n                    x: thing[0],\n                    y: thing[1]\n                };\n            }\n            return {\n                x: thing.x,\n                y: thing.y\n            };\n        }\n        function drawDOM(element, options) {\n            if (!options) {\n                options = {};\n            }\n            var promise = createPromise();\n            if (!element) {\n                return promise.reject('No element to export');\n            }\n            if (typeof window.getComputedStyle != 'function') {\n                throw new Error('window.getComputedStyle is missing.  You are using an unsupported browser, or running in IE8 compatibility mode.  Drawing HTML is supported in Chrome, Firefox, Safari and IE9+.');\n            }\n            kendo.pdf.defineFont(getFontFaces(element.ownerDocument));\n            var scale = getXY(options.scale || 1);\n            function doOne(element) {\n                var group = new Group();\n                var pos = element.getBoundingClientRect();\n                setTransform(group, [\n                    scale.x,\n                    0,\n                    0,\n                    scale.y,\n                    -pos.left * scale.x,\n                    -pos.top * scale.y\n                ]);\n                nodeInfo._clipbox = false;\n                nodeInfo._matrix = Matrix.unit();\n                nodeInfo._stackingContext = {\n                    element: element,\n                    group: group\n                };\n                if (options.avoidLinks === true) {\n                    nodeInfo._avoidLinks = 'a';\n                } else {\n                    nodeInfo._avoidLinks = options.avoidLinks;\n                }\n                addClass(element, 'k-pdf-export');\n                renderElement(element, group);\n                removeClass(element, 'k-pdf-export');\n                return group;\n            }\n            cacheImages(element, function () {\n                var forceBreak = options && options.forcePageBreak;\n                var hasPaperSize = options && options.paperSize && options.paperSize != 'auto';\n                var paperOptions = kendo.pdf.getPaperOptions(function (key, def) {\n                    if (key == 'paperSize') {\n                        return hasPaperSize ? options[key] : 'A4';\n                    }\n                    return key in options ? options[key] : def;\n                });\n                var pageWidth = hasPaperSize && paperOptions.paperSize[0];\n                var pageHeight = hasPaperSize && paperOptions.paperSize[1];\n                var margin = options.margin && paperOptions.margin;\n                var hasMargin = Boolean(margin);\n                if (forceBreak || pageHeight) {\n                    if (!margin) {\n                        margin = {\n                            left: 0,\n                            top: 0,\n                            right: 0,\n                            bottom: 0\n                        };\n                    }\n                    if (pageWidth) {\n                        pageWidth /= scale.x;\n                    }\n                    if (pageHeight) {\n                        pageHeight /= scale.y;\n                    }\n                    margin.left /= scale.x;\n                    margin.right /= scale.x;\n                    margin.top /= scale.y;\n                    margin.bottom /= scale.y;\n                    var group = new Group({\n                        pdf: {\n                            multiPage: true,\n                            paperSize: hasPaperSize ? paperOptions.paperSize : 'auto',\n                            _ignoreMargin: hasMargin\n                        }\n                    });\n                    handlePageBreaks(function (x) {\n                        if (options.progress) {\n                            var canceled = false, pageNum = 0;\n                            (function next() {\n                                if (pageNum < x.pages.length) {\n                                    var page = doOne(x.pages[pageNum]);\n                                    group.append(page);\n                                    options.progress({\n                                        page: page,\n                                        pageNum: ++pageNum,\n                                        totalPages: x.pages.length,\n                                        cancel: function () {\n                                            canceled = true;\n                                        }\n                                    });\n                                    if (!canceled) {\n                                        setTimeout(next);\n                                    } else {\n                                        x.container.parentNode.removeChild(x.container);\n                                    }\n                                } else {\n                                    x.container.parentNode.removeChild(x.container);\n                                    promise.resolve(group);\n                                }\n                            }());\n                        } else {\n                            x.pages.forEach(function (page) {\n                                group.append(doOne(page));\n                            });\n                            x.container.parentNode.removeChild(x.container);\n                            promise.resolve(group);\n                        }\n                    }, element, forceBreak, pageWidth ? pageWidth - margin.left - margin.right : null, pageHeight ? pageHeight - margin.top - margin.bottom : null, margin, options);\n                } else {\n                    promise.resolve(doOne(element));\n                }\n            });\n            function makeTemplate(template$$1) {\n                if (template$$1 != null) {\n                    if (typeof template$$1 == 'string') {\n                        template$$1 = kendo.template(template$$1.replace(/^\\s+|\\s+$/g, ''));\n                    }\n                    if (typeof template$$1 == 'function') {\n                        return function (data) {\n                            var el = template$$1(data);\n                            if (el && typeof el == 'string') {\n                                var div = document.createElement('div');\n                                div.innerHTML = el;\n                                el = div.firstElementChild;\n                            }\n                            return el;\n                        };\n                    }\n                    return function () {\n                        return template$$1.cloneNode(true);\n                    };\n                }\n            }\n            function handlePageBreaks(callback, element, forceBreak, pageWidth, pageHeight, margin, options) {\n                var template$$1 = makeTemplate(options.template);\n                var doc = element.ownerDocument;\n                var pages = [];\n                var copy = options._destructive ? element : cloneNodes(element);\n                var container = doc.createElement('KENDO-PDF-DOCUMENT');\n                var adjust = 0;\n                slice$1(copy.querySelectorAll('tfoot')).forEach(function (tfoot) {\n                    tfoot.parentNode.appendChild(tfoot);\n                });\n                slice$1(copy.querySelectorAll('ol')).forEach(function (ol) {\n                    slice$1(ol.children).forEach(function (li, index) {\n                        li.setAttribute('kendo-split-index', index);\n                    });\n                });\n                setCSS(container, {\n                    display: 'block',\n                    position: 'absolute',\n                    boxSizing: 'content-box',\n                    left: '-10000px',\n                    top: '-10000px'\n                });\n                if (pageWidth) {\n                    setCSS(container, {\n                        width: pageWidth + 'px',\n                        paddingLeft: margin.left + 'px',\n                        paddingRight: margin.right + 'px'\n                    });\n                    setCSS(copy, { overflow: 'hidden' });\n                }\n                element.parentNode.insertBefore(container, element);\n                container.appendChild(copy);\n                if (options.beforePageBreak) {\n                    setTimeout(function () {\n                        options.beforePageBreak(container, doPageBreak);\n                    }, 15);\n                } else {\n                    setTimeout(doPageBreak, 15);\n                }\n                function doPageBreak() {\n                    if (forceBreak != '-' || pageHeight) {\n                        splitElement(copy);\n                    }\n                    {\n                        var page = makePage();\n                        copy.parentNode.insertBefore(page, copy);\n                        page.appendChild(copy);\n                    }\n                    if (template$$1) {\n                        pages.forEach(function (page, i) {\n                            var el = template$$1({\n                                element: page,\n                                pageNum: i + 1,\n                                totalPages: pages.length\n                            });\n                            if (el) {\n                                page.appendChild(el);\n                            }\n                        });\n                    }\n                    cacheImages(pages, function () {\n                        whenImagesAreActuallyLoaded(pages, function () {\n                            callback({\n                                pages: pages,\n                                container: container\n                            });\n                        });\n                    });\n                }\n                function keepTogether(el) {\n                    if (options.keepTogether && matches(el, options.keepTogether) && el.offsetHeight <= pageHeight - adjust) {\n                        return true;\n                    }\n                    var tag = el.tagName;\n                    if (/^h[1-6]$/i.test(tag) && el.offsetHeight >= pageHeight - adjust) {\n                        return false;\n                    }\n                    return el.getAttribute('data-kendo-chart') || /^(?:img|tr|thead|th|tfoot|iframe|svg|object|canvas|input|textarea|select|video|h[1-6])/i.test(el.tagName);\n                }\n                function splitElement(element) {\n                    if (element.tagName == 'TABLE') {\n                        setCSS(element, { tableLayout: 'fixed' });\n                    }\n                    if (keepTogether(element)) {\n                        return;\n                    }\n                    var style = getComputedStyle(element);\n                    var bottomPadding = parseFloat(getPropertyValue(style, 'padding-bottom'));\n                    var bottomBorder = parseFloat(getPropertyValue(style, 'border-bottom-width'));\n                    var saveAdjust = adjust;\n                    adjust += bottomPadding + bottomBorder;\n                    var isFirst = true;\n                    for (var el = element.firstChild; el; el = el.nextSibling) {\n                        if (el.nodeType == 1) {\n                            isFirst = false;\n                            if (matches(el, forceBreak)) {\n                                breakAtElement(el);\n                                continue;\n                            }\n                            if (!pageHeight) {\n                                splitElement(el);\n                                continue;\n                            }\n                            if (!/^(?:static|relative)$/.test(getPropertyValue(getComputedStyle(el), 'position'))) {\n                                continue;\n                            }\n                            var fall = fallsOnMargin(el);\n                            if (fall == 1) {\n                                breakAtElement(el);\n                            } else if (fall) {\n                                if (keepTogether(el)) {\n                                    breakAtElement(el);\n                                } else {\n                                    splitElement(el);\n                                }\n                            } else {\n                                splitElement(el);\n                            }\n                        } else if (el.nodeType == 3 && pageHeight) {\n                            splitText(el, isFirst);\n                            isFirst = false;\n                        }\n                    }\n                    adjust = saveAdjust;\n                }\n                function firstInParent(el) {\n                    var p = el.parentNode, first = p.firstChild;\n                    if (el === first) {\n                        return true;\n                    }\n                    if (el === p.children[0]) {\n                        if (first.nodeType == 7 || first.nodeType == 8) {\n                            return true;\n                        }\n                        if (first.nodeType == 3) {\n                            return !/\\S/.test(first.data);\n                        }\n                    }\n                    return false;\n                }\n                function breakAtElement(el) {\n                    if (el.nodeType == 1 && el !== copy && firstInParent(el)) {\n                        return breakAtElement(el.parentNode);\n                    }\n                    var table, colgroup, thead, grid, gridHead;\n                    table = closest(el, 'table');\n                    colgroup = table && table.querySelector('colgroup');\n                    if (options.repeatHeaders) {\n                        thead = table && table.querySelector('thead');\n                        grid = closest(el, '.k-grid.k-widget');\n                        if (grid && grid.querySelector('.k-auto-scrollable')) {\n                            gridHead = grid.querySelector('.k-grid-header');\n                        }\n                    }\n                    var page = makePage();\n                    var range = doc.createRange();\n                    range.setStartBefore(copy);\n                    range.setEndBefore(el);\n                    page.appendChild(range.extractContents());\n                    copy.parentNode.insertBefore(page, copy);\n                    preventBulletOnListItem(el.parentNode);\n                    if (table) {\n                        table = closest(el, 'table');\n                        if (options.repeatHeaders && thead) {\n                            table.insertBefore(thead.cloneNode(true), table.firstChild);\n                        }\n                        if (colgroup) {\n                            table.insertBefore(colgroup.cloneNode(true), table.firstChild);\n                        }\n                    }\n                    if (options.repeatHeaders && gridHead) {\n                        grid = closest(el, '.k-grid.k-widget');\n                        grid.insertBefore(gridHead.cloneNode(true), grid.firstChild);\n                    }\n                }\n                function makePage() {\n                    var page = doc.createElement('KENDO-PDF-PAGE');\n                    setCSS(page, {\n                        display: 'block',\n                        boxSizing: 'content-box',\n                        width: pageWidth ? pageWidth + 'px' : 'auto',\n                        padding: margin.top + 'px ' + margin.right + 'px ' + margin.bottom + 'px ' + margin.left + 'px',\n                        position: 'relative',\n                        height: pageHeight ? pageHeight + 'px' : 'auto',\n                        overflow: pageHeight || pageWidth ? 'hidden' : 'visible',\n                        clear: 'both'\n                    });\n                    if (options && options.pageClassName) {\n                        page.className = options.pageClassName;\n                    }\n                    pages.push(page);\n                    return page;\n                }\n                function fallsOnMargin(thing) {\n                    var box = thing.getBoundingClientRect();\n                    if (box.width === 0 || box.height === 0) {\n                        return 0;\n                    }\n                    var top = copy.getBoundingClientRect().top;\n                    var available = pageHeight - adjust;\n                    return box.height > available ? 3 : box.top - top > available ? 1 : box.bottom - top > available ? 2 : 0;\n                }\n                function splitText(node, isFirst) {\n                    if (!/\\S/.test(node.data)) {\n                        return;\n                    }\n                    var len = node.data.length;\n                    var range = doc.createRange();\n                    range.selectNodeContents(node);\n                    var fall = fallsOnMargin(range);\n                    if (!fall) {\n                        return;\n                    }\n                    var nextnode = node;\n                    if (fall == 1) {\n                        if (isFirst) {\n                            breakAtElement(node.parentNode);\n                        } else {\n                            breakAtElement(node);\n                        }\n                    } else {\n                        (function findEOP(min, pos, max) {\n                            range.setEnd(node, pos);\n                            if (min == pos || pos == max) {\n                                return pos;\n                            }\n                            if (fallsOnMargin(range)) {\n                                return findEOP(min, min + pos >> 1, pos);\n                            } else {\n                                return findEOP(pos, pos + max >> 1, max);\n                            }\n                        }(0, len >> 1, len));\n                        if (!/\\S/.test(range.toString()) && isFirst) {\n                            breakAtElement(node.parentNode);\n                        } else {\n                            nextnode = node.splitText(range.endOffset);\n                            var page = makePage();\n                            range.setStartBefore(copy);\n                            page.appendChild(range.extractContents());\n                            copy.parentNode.insertBefore(page, copy);\n                            preventBulletOnListItem(nextnode.parentNode);\n                        }\n                    }\n                    splitText(nextnode);\n                }\n                function preventBulletOnListItem(el) {\n                    var li = closest(el, 'li');\n                    if (li) {\n                        li.setAttribute('kendo-no-bullet', '1');\n                        preventBulletOnListItem(li.parentNode);\n                    }\n                }\n            }\n            return promise;\n        }\n        drawDOM.getFontFaces = getFontFaces;\n        drawDOM.drawText = function (element) {\n            var group = new Group();\n            nodeInfo._clipbox = false;\n            nodeInfo._matrix = Matrix.unit();\n            nodeInfo._stackingContext = {\n                element: element,\n                group: group\n            };\n            pushNodeInfo(element, getComputedStyle(element), group);\n            if (element.firstChild.nodeType == 3) {\n                renderText(element, element.firstChild, group);\n            } else {\n                _renderElement(element, group);\n            }\n            popNodeInfo();\n            return group;\n        };\n        var parseBackgroundImage = function () {\n            var tok_linear_gradient = /^((-webkit-|-moz-|-o-|-ms-)?linear-gradient\\s*)\\(/;\n            var tok_percent = /^([-0-9.]+%)/;\n            var tok_length = /^([-0-9.]+px)/;\n            var tok_keyword = /^(left|right|top|bottom|to|center)\\W/;\n            var tok_angle = /^([-0-9.]+(deg|grad|rad|turn))/;\n            var tok_whitespace = /^(\\s+)/;\n            var tok_popen = /^(\\()/;\n            var tok_pclose = /^(\\))/;\n            var tok_comma = /^(,)/;\n            var tok_url = /^(url)\\(/;\n            var tok_content = /^(.*?)\\)/;\n            var cache1 = {}, cache2 = {};\n            function parse(input) {\n                var orig = input;\n                if (hasOwnProperty(cache1, orig)) {\n                    return cache1[orig];\n                }\n                function skip_ws() {\n                    var m = tok_whitespace.exec(input);\n                    if (m) {\n                        input = input.substr(m[1].length);\n                    }\n                }\n                function read(token) {\n                    skip_ws();\n                    var m = token.exec(input);\n                    if (m) {\n                        input = input.substr(m[1].length);\n                        return m[1];\n                    }\n                }\n                function read_stop() {\n                    var color = kendo.parseColor(input, true);\n                    var length, percent;\n                    if (color) {\n                        var match = /^#[0-9a-f]+/i.exec(input) || /^rgba?\\(.*?\\)/i.exec(input) || /^..*?\\b/.exec(input);\n                        input = input.substr(match[0].length);\n                        color = color.toRGB();\n                        if (!(length = read(tok_length))) {\n                            percent = read(tok_percent);\n                        }\n                        return {\n                            color: color,\n                            length: length,\n                            percent: percent\n                        };\n                    }\n                }\n                function read_linear_gradient(propName) {\n                    var angle;\n                    var to1, to2;\n                    var stops = [];\n                    var reverse = false;\n                    if (read(tok_popen)) {\n                        angle = read(tok_angle);\n                        if (angle) {\n                            angle = parseAngle(angle);\n                            read(tok_comma);\n                        } else {\n                            to1 = read(tok_keyword);\n                            if (to1 == 'to') {\n                                to1 = read(tok_keyword);\n                            } else if (to1 && /^-/.test(propName)) {\n                                reverse = true;\n                            }\n                            to2 = read(tok_keyword);\n                            read(tok_comma);\n                        }\n                        if (/-moz-/.test(propName) && angle == null && to1 == null) {\n                            var x = read(tok_percent), y = read(tok_percent);\n                            reverse = true;\n                            if (x == '0%') {\n                                to1 = 'left';\n                            } else if (x == '100%') {\n                                to1 = 'right';\n                            }\n                            if (y == '0%') {\n                                to2 = 'top';\n                            } else if (y == '100%') {\n                                to2 = 'bottom';\n                            }\n                            read(tok_comma);\n                        }\n                        while (input && !read(tok_pclose)) {\n                            var stop = read_stop();\n                            if (!stop) {\n                                break;\n                            }\n                            stops.push(stop);\n                            read(tok_comma);\n                        }\n                        return {\n                            type: 'linear',\n                            angle: angle,\n                            to: to1 && to2 ? to1 + ' ' + to2 : to1 ? to1 : to2 ? to2 : null,\n                            stops: stops,\n                            reverse: reverse\n                        };\n                    }\n                }\n                function read_url() {\n                    if (read(tok_popen)) {\n                        var url = read(tok_content);\n                        url = url.replace(/^['\"]+|[\"']+$/g, '');\n                        read(tok_pclose);\n                        return {\n                            type: 'url',\n                            url: url\n                        };\n                    }\n                }\n                var tok;\n                if (tok = read(tok_linear_gradient)) {\n                    tok = read_linear_gradient(tok);\n                } else if (tok = read(tok_url)) {\n                    tok = read_url();\n                }\n                return cache1[orig] = tok || { type: 'none' };\n            }\n            return function (input) {\n                if (hasOwnProperty(cache2, input)) {\n                    return cache2[input];\n                }\n                return cache2[input] = splitProperty(input).map(parse);\n            };\n        }();\n        var splitProperty = function () {\n            var cache = {};\n            return function (input, separator) {\n                if (!separator) {\n                    separator = /^\\s*,\\s*/;\n                }\n                var cacheKey = input + separator;\n                if (hasOwnProperty(cache, cacheKey)) {\n                    return cache[cacheKey];\n                }\n                var ret = [];\n                var last$$1 = 0, pos = 0;\n                var in_paren = 0;\n                var in_string = false;\n                var m;\n                function looking_at(rx) {\n                    return m = rx.exec(input.substr(pos));\n                }\n                function trim(str) {\n                    return str.replace(/^\\s+|\\s+$/g, '');\n                }\n                while (pos < input.length) {\n                    if (!in_string && looking_at(/^[\\(\\[\\{]/)) {\n                        in_paren++;\n                        pos++;\n                    } else if (!in_string && looking_at(/^[\\)\\]\\}]/)) {\n                        in_paren--;\n                        pos++;\n                    } else if (!in_string && looking_at(/^[\\\"\\']/)) {\n                        in_string = m[0];\n                        pos++;\n                    } else if (in_string == '\\'' && looking_at(/^\\\\\\'/)) {\n                        pos += 2;\n                    } else if (in_string == '\"' && looking_at(/^\\\\\\\"/)) {\n                        pos += 2;\n                    } else if (in_string == '\\'' && looking_at(/^\\'/)) {\n                        in_string = false;\n                        pos++;\n                    } else if (in_string == '\"' && looking_at(/^\\\"/)) {\n                        in_string = false;\n                        pos++;\n                    } else if (looking_at(separator)) {\n                        if (!in_string && !in_paren && pos > last$$1) {\n                            ret.push(trim(input.substring(last$$1, pos)));\n                            last$$1 = pos + m[0].length;\n                        }\n                        pos += m[0].length;\n                    } else {\n                        pos++;\n                    }\n                }\n                if (last$$1 < pos) {\n                    ret.push(trim(input.substring(last$$1, pos)));\n                }\n                return cache[cacheKey] = ret;\n            };\n        }();\n        var getFontURL = function (cache) {\n            return function (el) {\n                var url = cache[el];\n                if (!url) {\n                    var m;\n                    if (m = /url\\((['\"]?)([^'\")]*?)\\1\\)\\s+format\\((['\"]?)truetype\\3\\)/.exec(el)) {\n                        url = cache[el] = m[2];\n                    } else if (m = /url\\((['\"]?)([^'\")]*?\\.ttf)\\1\\)/.exec(el)) {\n                        url = cache[el] = m[2];\n                    }\n                }\n                return url;\n            };\n        }(Object.create ? Object.create(null) : {});\n        var getFontHeight = function (cache) {\n            return function (font) {\n                var height = cache[font];\n                if (height == null) {\n                    height = cache[font] = kendoUtil.measureText('Mapq', { font: font }).height;\n                }\n                return height;\n            };\n        }(Object.create ? Object.create(null) : {});\n        function getFontFaces(doc) {\n            if (doc == null) {\n                doc = document;\n            }\n            var result = {};\n            for (var i = 0; i < doc.styleSheets.length; ++i) {\n                doStylesheet(doc.styleSheets[i]);\n            }\n            return result;\n            function doStylesheet(ss) {\n                if (ss) {\n                    var rules = null;\n                    try {\n                        rules = ss.cssRules;\n                    } catch (ex) {\n                    }\n                    if (rules) {\n                        addRules(ss, rules);\n                    }\n                }\n            }\n            function findFonts(rule) {\n                var src = getPropertyValue(rule.style, 'src');\n                if (src) {\n                    return splitProperty(src).reduce(function (a, el) {\n                        var font = getFontURL(el);\n                        if (font) {\n                            a.push(font);\n                        }\n                        return a;\n                    }, []);\n                } else {\n                    var font = getFontURL(rule.cssText);\n                    return font ? [font] : [];\n                }\n            }\n            function addRules(styleSheet, rules) {\n                for (var i = 0; i < rules.length; ++i) {\n                    var r = rules[i];\n                    switch (r.type) {\n                    case 3:\n                        doStylesheet(r.styleSheet);\n                        break;\n                    case 5:\n                        var style = r.style;\n                        var family = splitProperty(getPropertyValue(style, 'font-family'));\n                        var bold = /^([56789]00|bold)$/i.test(getPropertyValue(style, 'font-weight'));\n                        var italic = 'italic' == getPropertyValue(style, 'font-style');\n                        var src = findFonts(r);\n                        if (src.length > 0) {\n                            addRule(styleSheet, family, bold, italic, src[0]);\n                        }\n                    }\n                }\n            }\n            function addRule(styleSheet, names, bold, italic, url) {\n                if (!/^data:/i.test(url)) {\n                    if (!(/^[^\\/:]+:\\/\\//.test(url) || /^\\//.test(url))) {\n                        url = String(styleSheet.href).replace(/[^\\/]*$/, '') + url;\n                    }\n                }\n                names.forEach(function (name) {\n                    name = name.replace(/^(['\"]?)(.*?)\\1$/, '$2');\n                    if (bold) {\n                        name += '|bold';\n                    }\n                    if (italic) {\n                        name += '|italic';\n                    }\n                    result[name] = url;\n                });\n            }\n        }\n        function hasOwnProperty(obj, key) {\n            return Object.prototype.hasOwnProperty.call(obj, key);\n        }\n        function getCounter(name) {\n            name = '_counter_' + name;\n            return nodeInfo[name];\n        }\n        function getAllCounters(name) {\n            var values = [], p = nodeInfo;\n            name = '_counter_' + name;\n            while (p) {\n                if (hasOwnProperty(p, name)) {\n                    values.push(p[name]);\n                }\n                p = Object.getPrototypeOf(p);\n            }\n            return values.reverse();\n        }\n        function incCounter(name, inc) {\n            var p = nodeInfo;\n            name = '_counter_' + name;\n            while (p && !hasOwnProperty(p, name)) {\n                p = Object.getPrototypeOf(p);\n            }\n            if (!p) {\n                p = nodeInfo._root;\n            }\n            p[name] = (p[name] || 0) + (inc == null ? 1 : inc);\n        }\n        function resetCounter(name, val) {\n            name = '_counter_' + name;\n            nodeInfo[name] = val == null ? 0 : val;\n        }\n        function doCounters(a, f, def) {\n            for (var i = 0; i < a.length;) {\n                var name = a[i++];\n                var val = parseFloat(a[i]);\n                if (isNaN(val)) {\n                    f(name, def);\n                } else {\n                    f(name, val);\n                    ++i;\n                }\n            }\n        }\n        function updateCounters(style) {\n            var counterReset = getPropertyValue(style, 'counter-reset');\n            if (counterReset) {\n                doCounters(splitProperty(counterReset, /^\\s+/), resetCounter, 0);\n            }\n            var counterIncrement = getPropertyValue(style, 'counter-increment');\n            if (counterIncrement) {\n                doCounters(splitProperty(counterIncrement, /^\\s+/), incCounter, 1);\n            }\n        }\n        function parseColor$1(str, css) {\n            var color = kendo.parseColor(str, true);\n            if (color) {\n                color = color.toRGB();\n                if (css) {\n                    color = color.toCssRgba();\n                } else if (color.a === 0) {\n                    color = null;\n                }\n            }\n            return color;\n        }\n        function whenImagesAreActuallyLoaded(elements, callback) {\n            var pending = 0;\n            elements.forEach(function (el) {\n                var images = el.querySelectorAll('img');\n                for (var i = 0; i < images.length; ++i) {\n                    var img = images[i];\n                    if (!img.complete) {\n                        pending++;\n                        img.onload = img.onerror = next;\n                    }\n                }\n            });\n            if (!pending) {\n                next();\n            }\n            function next() {\n                if (--pending <= 0) {\n                    callback();\n                }\n            }\n        }\n        function cacheImages(element, callback) {\n            var urls = [];\n            function add(url) {\n                if (!IMAGE_CACHE[url]) {\n                    IMAGE_CACHE[url] = true;\n                    urls.push(url);\n                }\n            }\n            function dive(element) {\n                if (/^img$/i.test(element.tagName)) {\n                    add(element.src);\n                }\n                parseBackgroundImage(getPropertyValue(getComputedStyle(element), 'background-image')).forEach(function (bg) {\n                    if (bg.type == 'url') {\n                        add(bg.url);\n                    }\n                });\n                if (element.children) {\n                    slice$1(element.children).forEach(dive);\n                }\n            }\n            if (Array.isArray(element)) {\n                element.forEach(dive);\n            } else {\n                dive(element);\n            }\n            var count = urls.length;\n            function next() {\n                if (--count <= 0) {\n                    callback();\n                }\n            }\n            if (count === 0) {\n                next();\n            }\n            urls.forEach(function (url) {\n                var img = IMAGE_CACHE[url] = new window.Image();\n                if (!/^data:/i.test(url)) {\n                    img.crossOrigin = 'Anonymous';\n                }\n                img.src = url;\n                if (img.complete) {\n                    next();\n                } else {\n                    img.onload = next;\n                    img.onerror = function () {\n                        IMAGE_CACHE[url] = null;\n                        next();\n                    };\n                }\n            });\n        }\n        function alphaNumeral(n) {\n            var result = '';\n            do {\n                var r = n % 26;\n                result = String.fromCharCode(97 + r) + result;\n                n = Math.floor(n / 26);\n            } while (n > 0);\n            return result;\n        }\n        function pushNodeInfo(element, style, group) {\n            nodeInfo = Object.create(nodeInfo);\n            nodeInfo[element.tagName.toLowerCase()] = {\n                element: element,\n                style: style\n            };\n            var decoration = getPropertyValue(style, 'text-decoration');\n            if (decoration && decoration != 'none') {\n                var color = getPropertyValue(style, 'color');\n                decoration.split(/\\s+/g).forEach(function (name) {\n                    if (!nodeInfo[name]) {\n                        nodeInfo[name] = color;\n                    }\n                });\n            }\n            if (createsStackingContext(style)) {\n                nodeInfo._stackingContext = {\n                    element: element,\n                    group: group\n                };\n            }\n        }\n        function popNodeInfo() {\n            nodeInfo = Object.getPrototypeOf(nodeInfo);\n        }\n        function updateClipbox(path) {\n            if (nodeInfo._clipbox != null) {\n                var box = path.bbox(nodeInfo._matrix);\n                if (nodeInfo._clipbox) {\n                    nodeInfo._clipbox = Rect.intersect(nodeInfo._clipbox, box);\n                } else {\n                    nodeInfo._clipbox = box;\n                }\n            }\n        }\n        function emptyClipbox() {\n            var cb = nodeInfo._clipbox;\n            if (cb == null) {\n                return true;\n            }\n            if (cb) {\n                return cb.width() === 0 || cb.height() === 0;\n            }\n        }\n        function createsStackingContext(style) {\n            function prop(name) {\n                return getPropertyValue(style, name);\n            }\n            if (prop('transform') != 'none' || prop('position') != 'static' || prop('z-index') != 'auto' || prop('opacity') < 1) {\n                return true;\n            }\n        }\n        function getComputedStyle(element, pseudoElt) {\n            return window.getComputedStyle(element, pseudoElt || null);\n        }\n        function getPropertyValue(style, prop, defa) {\n            var val = style.getPropertyValue(prop);\n            if (val == null || val === '') {\n                if (browser.webkit) {\n                    val = style.getPropertyValue('-webkit-' + prop);\n                } else if (browser.mozilla) {\n                    val = style.getPropertyValue('-moz-' + prop);\n                } else if (browser.opera) {\n                    val = style.getPropertyValue('-o-' + prop);\n                } else if (microsoft) {\n                    val = style.getPropertyValue('-ms-' + prop);\n                }\n            }\n            if (arguments.length > 2 && (val == null || val === '')) {\n                return defa;\n            } else {\n                return val;\n            }\n        }\n        function pleaseSetPropertyValue(style, prop, value, important) {\n            style.setProperty(prop, value, important);\n            if (browser.webkit) {\n                style.setProperty('-webkit-' + prop, value, important);\n            } else if (browser.mozilla) {\n                style.setProperty('-moz-' + prop, value, important);\n            } else if (browser.opera) {\n                style.setProperty('-o-' + prop, value, important);\n            } else if (microsoft) {\n                style.setProperty('-ms-' + prop, value, important);\n                prop = 'ms' + prop.replace(/(^|-)([a-z])/g, function (s, p1, p2) {\n                    return p1 + p2.toUpperCase();\n                });\n                style[prop] = value;\n            }\n        }\n        function getBorder(style, side) {\n            side = 'border-' + side;\n            return {\n                width: parseFloat(getPropertyValue(style, side + '-width')),\n                style: getPropertyValue(style, side + '-style'),\n                color: parseColor$1(getPropertyValue(style, side + '-color'), true)\n            };\n        }\n        function saveStyle(element, func) {\n            var prev = element.style.cssText;\n            var result = func();\n            element.style.cssText = prev;\n            return result;\n        }\n        function getBorderRadius(style, side) {\n            var r = getPropertyValue(style, 'border-' + side + '-radius').split(/\\s+/g).map(parseFloat);\n            if (r.length == 1) {\n                r.push(r[0]);\n            }\n            return sanitizeRadius({\n                x: r[0],\n                y: r[1]\n            });\n        }\n        function getContentBox(element) {\n            var box = element.getBoundingClientRect();\n            box = innerBox(box, 'border-*-width', element);\n            box = innerBox(box, 'padding-*', element);\n            return box;\n        }\n        function innerBox(box, prop, element) {\n            var style, wt, wr, wb, wl;\n            if (typeof prop == 'string') {\n                style = getComputedStyle(element);\n                wt = parseFloat(getPropertyValue(style, prop.replace('*', 'top')));\n                wr = parseFloat(getPropertyValue(style, prop.replace('*', 'right')));\n                wb = parseFloat(getPropertyValue(style, prop.replace('*', 'bottom')));\n                wl = parseFloat(getPropertyValue(style, prop.replace('*', 'left')));\n            } else if (typeof prop == 'number') {\n                wt = wr = wb = wl = prop;\n            }\n            return {\n                top: box.top + wt,\n                right: box.right - wr,\n                bottom: box.bottom - wb,\n                left: box.left + wl,\n                width: box.right - box.left - wr - wl,\n                height: box.bottom - box.top - wb - wt\n            };\n        }\n        function getTransform(style) {\n            var transform$$1 = getPropertyValue(style, 'transform');\n            if (transform$$1 == 'none') {\n                return null;\n            }\n            var matrix = /^\\s*matrix\\(\\s*(.*?)\\s*\\)\\s*$/.exec(transform$$1);\n            if (matrix) {\n                var origin = getPropertyValue(style, 'transform-origin');\n                matrix = matrix[1].split(/\\s*,\\s*/g).map(parseFloat);\n                origin = origin.split(/\\s+/g).map(parseFloat);\n                return {\n                    matrix: matrix,\n                    origin: origin\n                };\n            }\n        }\n        function radiansToDegrees(radians) {\n            return 180 * radians / Math.PI % 360;\n        }\n        function parseAngle(angle) {\n            var num = parseFloat(angle);\n            if (/grad$/.test(angle)) {\n                return Math.PI * num / 200;\n            } else if (/rad$/.test(angle)) {\n                return num;\n            } else if (/turn$/.test(angle)) {\n                return Math.PI * num * 2;\n            } else if (/deg$/.test(angle)) {\n                return Math.PI * num / 180;\n            }\n        }\n        function setTransform(shape, m) {\n            m = new Matrix(m[0], m[1], m[2], m[3], m[4], m[5]);\n            shape.transform(m);\n            return m;\n        }\n        function setClipping(shape, clipPath) {\n            shape.clip(clipPath);\n        }\n        function addArcToPath(path, x, y, options) {\n            var points = new Arc$2([\n                    x,\n                    y\n                ], options).curvePoints(), i = 1;\n            while (i < points.length) {\n                path.curveTo(points[i++], points[i++], points[i++]);\n            }\n        }\n        function sanitizeRadius(r) {\n            if (r.x <= 0 || r.y <= 0) {\n                r.x = r.y = 0;\n            }\n            return r;\n        }\n        function adjustBorderRadiusForBox(box, rTL, rTR, rBR, rBL) {\n            var tl_x = Math.max(0, rTL.x), tl_y = Math.max(0, rTL.y);\n            var tr_x = Math.max(0, rTR.x), tr_y = Math.max(0, rTR.y);\n            var br_x = Math.max(0, rBR.x), br_y = Math.max(0, rBR.y);\n            var bl_x = Math.max(0, rBL.x), bl_y = Math.max(0, rBL.y);\n            var f = Math.min(box.width / (tl_x + tr_x), box.height / (tr_y + br_y), box.width / (br_x + bl_x), box.height / (bl_y + tl_y));\n            if (f < 1) {\n                tl_x *= f;\n                tl_y *= f;\n                tr_x *= f;\n                tr_y *= f;\n                br_x *= f;\n                br_y *= f;\n                bl_x *= f;\n                bl_y *= f;\n            }\n            return {\n                tl: {\n                    x: tl_x,\n                    y: tl_y\n                },\n                tr: {\n                    x: tr_x,\n                    y: tr_y\n                },\n                br: {\n                    x: br_x,\n                    y: br_y\n                },\n                bl: {\n                    x: bl_x,\n                    y: bl_y\n                }\n            };\n        }\n        function elementRoundBox(element, box, type) {\n            var style = getComputedStyle(element);\n            var rTL = getBorderRadius(style, 'top-left');\n            var rTR = getBorderRadius(style, 'top-right');\n            var rBL = getBorderRadius(style, 'bottom-left');\n            var rBR = getBorderRadius(style, 'bottom-right');\n            if (type == 'padding' || type == 'content') {\n                var bt = getBorder(style, 'top');\n                var br = getBorder(style, 'right');\n                var bb = getBorder(style, 'bottom');\n                var bl = getBorder(style, 'left');\n                rTL.x -= bl.width;\n                rTL.y -= bt.width;\n                rTR.x -= br.width;\n                rTR.y -= bt.width;\n                rBR.x -= br.width;\n                rBR.y -= bb.width;\n                rBL.x -= bl.width;\n                rBL.y -= bb.width;\n                if (type == 'content') {\n                    var pt = parseFloat(getPropertyValue(style, 'padding-top'));\n                    var pr = parseFloat(getPropertyValue(style, 'padding-right'));\n                    var pb = parseFloat(getPropertyValue(style, 'padding-bottom'));\n                    var pl = parseFloat(getPropertyValue(style, 'padding-left'));\n                    rTL.x -= pl;\n                    rTL.y -= pt;\n                    rTR.x -= pr;\n                    rTR.y -= pt;\n                    rBR.x -= pr;\n                    rBR.y -= pb;\n                    rBL.x -= pl;\n                    rBL.y -= pb;\n                }\n            }\n            if (typeof type == 'number') {\n                rTL.x -= type;\n                rTL.y -= type;\n                rTR.x -= type;\n                rTR.y -= type;\n                rBR.x -= type;\n                rBR.y -= type;\n                rBL.x -= type;\n                rBL.y -= type;\n            }\n            return roundBox(box, rTL, rTR, rBR, rBL);\n        }\n        function roundBox(box, rTL0, rTR0, rBR0, rBL0) {\n            var tmp = adjustBorderRadiusForBox(box, rTL0, rTR0, rBR0, rBL0);\n            var rTL = tmp.tl;\n            var rTR = tmp.tr;\n            var rBR = tmp.br;\n            var rBL = tmp.bl;\n            var path = new Path({\n                fill: null,\n                stroke: null\n            });\n            path.moveTo(box.left, box.top + rTL.y);\n            if (rTL.x) {\n                addArcToPath(path, box.left + rTL.x, box.top + rTL.y, {\n                    startAngle: -180,\n                    endAngle: -90,\n                    radiusX: rTL.x,\n                    radiusY: rTL.y\n                });\n            }\n            path.lineTo(box.right - rTR.x, box.top);\n            if (rTR.x) {\n                addArcToPath(path, box.right - rTR.x, box.top + rTR.y, {\n                    startAngle: -90,\n                    endAngle: 0,\n                    radiusX: rTR.x,\n                    radiusY: rTR.y\n                });\n            }\n            path.lineTo(box.right, box.bottom - rBR.y);\n            if (rBR.x) {\n                addArcToPath(path, box.right - rBR.x, box.bottom - rBR.y, {\n                    startAngle: 0,\n                    endAngle: 90,\n                    radiusX: rBR.x,\n                    radiusY: rBR.y\n                });\n            }\n            path.lineTo(box.left + rBL.x, box.bottom);\n            if (rBL.x) {\n                addArcToPath(path, box.left + rBL.x, box.bottom - rBL.y, {\n                    startAngle: 90,\n                    endAngle: 180,\n                    radiusX: rBL.x,\n                    radiusY: rBL.y\n                });\n            }\n            return path.close();\n        }\n        function formatCounter(val, style) {\n            var str = String(parseFloat(val));\n            switch (style) {\n            case 'decimal-leading-zero':\n                if (str.length < 2) {\n                    str = '0' + str;\n                }\n                return str;\n            case 'lower-roman':\n                return arabicToRoman(val).toLowerCase();\n            case 'upper-roman':\n                return arabicToRoman(val).toUpperCase();\n            case 'lower-latin':\n            case 'lower-alpha':\n                return alphaNumeral(val - 1);\n            case 'upper-latin':\n            case 'upper-alpha':\n                return alphaNumeral(val - 1).toUpperCase();\n            default:\n                return str;\n            }\n        }\n        function evalPseudoElementContent(element, content) {\n            function displayCounter(name, style, separator) {\n                if (!separator) {\n                    return formatCounter(getCounter(name) || 0, style);\n                }\n                separator = separator.replace(/^\\s*([\"'])(.*)\\1\\s*$/, '$2');\n                return getAllCounters(name).map(function (val) {\n                    return formatCounter(val, style);\n                }).join(separator);\n            }\n            var a = splitProperty(content, /^\\s+/);\n            var result = [], m;\n            a.forEach(function (el) {\n                var tmp;\n                if (m = /^\\s*([\"'])(.*)\\1\\s*$/.exec(el)) {\n                    result.push(m[2].replace(/\\\\([0-9a-f]{4})/gi, function (s, p) {\n                        return String.fromCharCode(parseInt(p, 16));\n                    }));\n                } else if (m = /^\\s*counter\\((.*?)\\)\\s*$/.exec(el)) {\n                    tmp = splitProperty(m[1]);\n                    result.push(displayCounter(tmp[0], tmp[1]));\n                } else if (m = /^\\s*counters\\((.*?)\\)\\s*$/.exec(el)) {\n                    tmp = splitProperty(m[1]);\n                    result.push(displayCounter(tmp[0], tmp[2], tmp[1]));\n                } else if (m = /^\\s*attr\\((.*?)\\)\\s*$/.exec(el)) {\n                    result.push(element.getAttribute(m[1]) || '');\n                } else {\n                    result.push(el);\n                }\n            });\n            return result.join('');\n        }\n        function getCssText(style) {\n            if (style.cssText) {\n                return style.cssText;\n            }\n            var result = [];\n            for (var i = 0; i < style.length; ++i) {\n                result.push(style[i] + ': ' + getPropertyValue(style, style[i]));\n            }\n            return result.join(';\\n');\n        }\n        function _renderWithPseudoElements(element, group) {\n            if (element.tagName == KENDO_PSEUDO_ELEMENT) {\n                _renderElement(element, group);\n                return;\n            }\n            var fake = [];\n            function pseudo(kind, place) {\n                var style = getComputedStyle(element, kind), content = style.content;\n                updateCounters(style);\n                if (content && content != 'normal' && content != 'none' && style.width != '0px') {\n                    var psel = element.ownerDocument.createElement(KENDO_PSEUDO_ELEMENT);\n                    psel.style.cssText = getCssText(style);\n                    psel.textContent = evalPseudoElementContent(element, content);\n                    element.insertBefore(psel, place);\n                    fake.push(psel);\n                }\n            }\n            pseudo(':before', element.firstChild);\n            pseudo(':after', null);\n            if (fake.length > 0) {\n                var saveClass = element.className;\n                element.className += ' kendo-pdf-hide-pseudo-elements';\n                _renderElement(element, group);\n                element.className = saveClass;\n                fake.forEach(function (el) {\n                    element.removeChild(el);\n                });\n            } else {\n                _renderElement(element, group);\n            }\n        }\n        function _renderElement(element, group) {\n            var style = getComputedStyle(element);\n            var top = getBorder(style, 'top');\n            var right = getBorder(style, 'right');\n            var bottom = getBorder(style, 'bottom');\n            var left = getBorder(style, 'left');\n            var rTL0 = getBorderRadius(style, 'top-left');\n            var rTR0 = getBorderRadius(style, 'top-right');\n            var rBL0 = getBorderRadius(style, 'bottom-left');\n            var rBR0 = getBorderRadius(style, 'bottom-right');\n            var dir = getPropertyValue(style, 'direction');\n            var backgroundColor = getPropertyValue(style, 'background-color');\n            backgroundColor = parseColor$1(backgroundColor);\n            var backgroundImage = parseBackgroundImage(getPropertyValue(style, 'background-image'));\n            var backgroundRepeat = splitProperty(getPropertyValue(style, 'background-repeat'));\n            var backgroundPosition = splitProperty(getPropertyValue(style, 'background-position'));\n            var backgroundOrigin = splitProperty(getPropertyValue(style, 'background-origin'));\n            var backgroundSize = splitProperty(getPropertyValue(style, 'background-size'));\n            var textOverflow, saveTextOverflow;\n            if (microsoft) {\n                textOverflow = style.textOverflow;\n                if (textOverflow == 'ellipsis') {\n                    saveTextOverflow = element.style.textOverflow;\n                    element.style.textOverflow = 'clip';\n                }\n            }\n            if (browser.msie && browser.version < 10) {\n                backgroundPosition = splitProperty(element.currentStyle.backgroundPosition);\n            }\n            var innerbox = innerBox(element.getBoundingClientRect(), 'border-*-width', element);\n            (function () {\n                var clip = getPropertyValue(style, 'clip');\n                var m = /^\\s*rect\\((.*)\\)\\s*$/.exec(clip);\n                if (m) {\n                    var a = m[1].split(/[ ,]+/g);\n                    var top = a[0] == 'auto' ? innerbox.top : parseFloat(a[0]) + innerbox.top;\n                    var right = a[1] == 'auto' ? innerbox.right : parseFloat(a[1]) + innerbox.left;\n                    var bottom = a[2] == 'auto' ? innerbox.bottom : parseFloat(a[2]) + innerbox.top;\n                    var left = a[3] == 'auto' ? innerbox.left : parseFloat(a[3]) + innerbox.left;\n                    var tmp = new Group();\n                    var clipPath = new Path().moveTo(left, top).lineTo(right, top).lineTo(right, bottom).lineTo(left, bottom).close();\n                    setClipping(tmp, clipPath);\n                    group.append(tmp);\n                    group = tmp;\n                    updateClipbox(clipPath);\n                }\n            }());\n            var boxes, i, cells;\n            var display = getPropertyValue(style, 'display');\n            if (display == 'table-row') {\n                boxes = [];\n                for (i = 0, cells = element.children; i < cells.length; ++i) {\n                    boxes.push(cells[i].getBoundingClientRect());\n                }\n            } else {\n                boxes = element.getClientRects();\n                if (boxes.length == 1) {\n                    boxes = [element.getBoundingClientRect()];\n                }\n            }\n            boxes = adjustBoxes(boxes);\n            for (i = 0; i < boxes.length; ++i) {\n                drawOneBox(boxes[i], i === 0, i == boxes.length - 1);\n            }\n            if (element.tagName == 'A' && element.href && !/^#?$/.test(element.getAttribute('href'))) {\n                if (!nodeInfo._avoidLinks || !matches(element, nodeInfo._avoidLinks)) {\n                    var r = document.createRange();\n                    r.selectNodeContents(element);\n                    slice$1(r.getClientRects()).forEach(function (box) {\n                        var g = new Group();\n                        g._pdfLink = {\n                            url: element.href,\n                            top: box.top,\n                            right: box.right,\n                            bottom: box.bottom,\n                            left: box.left\n                        };\n                        group.append(g);\n                    });\n                }\n            }\n            if (boxes.length > 0 && display == 'list-item' && !element.getAttribute('kendo-no-bullet')) {\n                drawBullet(boxes[0]);\n            }\n            (function () {\n                function clipit() {\n                    var clipPath = elementRoundBox(element, innerbox, 'padding');\n                    var tmp = new Group();\n                    setClipping(tmp, clipPath);\n                    group.append(tmp);\n                    group = tmp;\n                    updateClipbox(clipPath);\n                }\n                if (isFormField(element)) {\n                    clipit();\n                } else if (/^(hidden|auto|scroll)/.test(getPropertyValue(style, 'overflow'))) {\n                    clipit();\n                } else if (/^(hidden|auto|scroll)/.test(getPropertyValue(style, 'overflow-x'))) {\n                    clipit();\n                } else if (/^(hidden|auto|scroll)/.test(getPropertyValue(style, 'overflow-y'))) {\n                    clipit();\n                }\n            }());\n            if (!maybeRenderWidget(element, group)) {\n                renderContents(element, group);\n            }\n            if (microsoft && textOverflow == 'ellipsis') {\n                element.style.textOverflow = saveTextOverflow;\n            }\n            return group;\n            function adjustBoxes(boxes) {\n                if (/^td$/i.test(element.tagName)) {\n                    var table = nodeInfo.table;\n                    if (table && getPropertyValue(table.style, 'border-collapse') == 'collapse') {\n                        var tableBorderLeft = getBorder(table.style, 'left').width;\n                        var tableBorderTop = getBorder(table.style, 'top').width;\n                        if (tableBorderLeft === 0 && tableBorderTop === 0) {\n                            return boxes;\n                        }\n                        var tableBox = table.element.getBoundingClientRect();\n                        var firstCell = table.element.rows[0].cells[0];\n                        var firstCellBox = firstCell.getBoundingClientRect();\n                        if (firstCellBox.top == tableBox.top || firstCellBox.left == tableBox.left) {\n                            return slice$1(boxes).map(function (box) {\n                                return {\n                                    left: box.left + tableBorderLeft,\n                                    top: box.top + tableBorderTop,\n                                    right: box.right + tableBorderLeft,\n                                    bottom: box.bottom + tableBorderTop,\n                                    height: box.height,\n                                    width: box.width\n                                };\n                            });\n                        }\n                    }\n                }\n                return boxes;\n            }\n            function drawEdge(color, len, Wtop, Wleft, Wright, rl, rr, transform$$1) {\n                if (Wtop <= 0) {\n                    return;\n                }\n                var path, edge = new Group();\n                setTransform(edge, transform$$1);\n                group.append(edge);\n                sanitizeRadius(rl);\n                sanitizeRadius(rr);\n                path = new Path({\n                    fill: { color: color },\n                    stroke: null\n                });\n                edge.append(path);\n                path.moveTo(rl.x ? Math.max(rl.x, Wleft) : 0, 0).lineTo(len - (rr.x ? Math.max(rr.x, Wright) : 0), 0).lineTo(len - Math.max(rr.x, Wright), Wtop).lineTo(Math.max(rl.x, Wleft), Wtop).close();\n                if (rl.x) {\n                    drawRoundCorner(Wleft, rl, [\n                        -1,\n                        0,\n                        0,\n                        1,\n                        rl.x,\n                        0\n                    ]);\n                }\n                if (rr.x) {\n                    drawRoundCorner(Wright, rr, [\n                        1,\n                        0,\n                        0,\n                        1,\n                        len - rr.x,\n                        0\n                    ]);\n                }\n                function drawRoundCorner(Wright, r, transform$$1) {\n                    var angle = Math.PI / 2 * Wright / (Wright + Wtop);\n                    var ri = {\n                        x: r.x - Wright,\n                        y: r.y - Wtop\n                    };\n                    var path = new Path({\n                        fill: { color: color },\n                        stroke: null\n                    }).moveTo(0, 0);\n                    setTransform(path, transform$$1);\n                    addArcToPath(path, 0, r.y, {\n                        startAngle: -90,\n                        endAngle: -radiansToDegrees(angle),\n                        radiusX: r.x,\n                        radiusY: r.y\n                    });\n                    if (ri.x > 0 && ri.y > 0) {\n                        path.lineTo(ri.x * Math.cos(angle), r.y - ri.y * Math.sin(angle));\n                        addArcToPath(path, 0, r.y, {\n                            startAngle: -radiansToDegrees(angle),\n                            endAngle: -90,\n                            radiusX: ri.x,\n                            radiusY: ri.y,\n                            anticlockwise: true\n                        });\n                    } else if (ri.x > 0) {\n                        path.lineTo(ri.x, Wtop).lineTo(0, Wtop);\n                    } else {\n                        path.lineTo(ri.x, Wtop).lineTo(ri.x, 0);\n                    }\n                    edge.append(path.close());\n                }\n            }\n            function drawBackground(box) {\n                var background = new Group();\n                setClipping(background, roundBox(box, rTL0, rTR0, rBR0, rBL0));\n                group.append(background);\n                if (backgroundColor) {\n                    var path = new Path({\n                        fill: { color: backgroundColor.toCssRgba() },\n                        stroke: null\n                    });\n                    path.moveTo(box.left, box.top).lineTo(box.right, box.top).lineTo(box.right, box.bottom).lineTo(box.left, box.bottom).close();\n                    background.append(path);\n                }\n                for (var i = backgroundImage.length; --i >= 0;) {\n                    drawOneBackground(background, box, backgroundImage[i], backgroundRepeat[i % backgroundRepeat.length], backgroundPosition[i % backgroundPosition.length], backgroundOrigin[i % backgroundOrigin.length], backgroundSize[i % backgroundSize.length]);\n                }\n            }\n            function drawOneBackground(group, box, background, backgroundRepeat, backgroundPosition, backgroundOrigin, backgroundSize) {\n                if (!background || background == 'none') {\n                    return;\n                }\n                if (background.type == 'url') {\n                    if (/^url\\(\\\"data:image\\/svg/i.test(background.url)) {\n                        return;\n                    }\n                    var img = IMAGE_CACHE[background.url];\n                    if (img && img.width > 0 && img.height > 0) {\n                        drawBackgroundImage(group, box, img.width, img.height, function (group, rect) {\n                            group.append(new Image$1(background.url, rect));\n                        });\n                    }\n                } else if (background.type == 'linear') {\n                    drawBackgroundImage(group, box, box.width, box.height, gradientRenderer(background));\n                } else {\n                    return;\n                }\n                function drawBackgroundImage(group, box, img_width, img_height, renderBG) {\n                    var aspect_ratio = img_width / img_height, f;\n                    var orgBox = box;\n                    if (backgroundOrigin == 'content-box') {\n                        orgBox = innerBox(orgBox, 'border-*-width', element);\n                        orgBox = innerBox(orgBox, 'padding-*', element);\n                    } else if (backgroundOrigin == 'padding-box') {\n                        orgBox = innerBox(orgBox, 'border-*-width', element);\n                    }\n                    if (!/^\\s*auto(\\s+auto)?\\s*$/.test(backgroundSize)) {\n                        if (backgroundSize == 'contain') {\n                            f = Math.min(orgBox.width / img_width, orgBox.height / img_height);\n                            img_width *= f;\n                            img_height *= f;\n                        } else if (backgroundSize == 'cover') {\n                            f = Math.max(orgBox.width / img_width, orgBox.height / img_height);\n                            img_width *= f;\n                            img_height *= f;\n                        } else {\n                            var size = backgroundSize.split(/\\s+/g);\n                            if (/%$/.test(size[0])) {\n                                img_width = orgBox.width * parseFloat(size[0]) / 100;\n                            } else {\n                                img_width = parseFloat(size[0]);\n                            }\n                            if (size.length == 1 || size[1] == 'auto') {\n                                img_height = img_width / aspect_ratio;\n                            } else if (/%$/.test(size[1])) {\n                                img_height = orgBox.height * parseFloat(size[1]) / 100;\n                            } else {\n                                img_height = parseFloat(size[1]);\n                            }\n                        }\n                    }\n                    var pos = String(backgroundPosition);\n                    switch (pos) {\n                    case 'bottom':\n                        pos = '50% 100%';\n                        break;\n                    case 'top':\n                        pos = '50% 0';\n                        break;\n                    case 'left':\n                        pos = '0 50%';\n                        break;\n                    case 'right':\n                        pos = '100% 50%';\n                        break;\n                    case 'center':\n                        pos = '50% 50%';\n                        break;\n                    }\n                    pos = pos.split(/\\s+/);\n                    if (pos.length == 1) {\n                        pos[1] = '50%';\n                    }\n                    if (/%$/.test(pos[0])) {\n                        pos[0] = parseFloat(pos[0]) / 100 * (orgBox.width - img_width);\n                    } else {\n                        pos[0] = parseFloat(pos[0]);\n                    }\n                    if (/%$/.test(pos[1])) {\n                        pos[1] = parseFloat(pos[1]) / 100 * (orgBox.height - img_height);\n                    } else {\n                        pos[1] = parseFloat(pos[1]);\n                    }\n                    var rect = new Rect([\n                        orgBox.left + pos[0],\n                        orgBox.top + pos[1]\n                    ], [\n                        img_width,\n                        img_height\n                    ]);\n                    function rewX() {\n                        while (rect.origin.x > box.left) {\n                            rect.origin.x -= img_width;\n                        }\n                    }\n                    function rewY() {\n                        while (rect.origin.y > box.top) {\n                            rect.origin.y -= img_height;\n                        }\n                    }\n                    function repeatX() {\n                        while (rect.origin.x < box.right) {\n                            renderBG(group, rect.clone());\n                            rect.origin.x += img_width;\n                        }\n                    }\n                    if (backgroundRepeat == 'no-repeat') {\n                        renderBG(group, rect);\n                    } else if (backgroundRepeat == 'repeat-x') {\n                        rewX();\n                        repeatX();\n                    } else if (backgroundRepeat == 'repeat-y') {\n                        rewY();\n                        while (rect.origin.y < box.bottom) {\n                            renderBG(group, rect.clone());\n                            rect.origin.y += img_height;\n                        }\n                    } else if (backgroundRepeat == 'repeat') {\n                        rewX();\n                        rewY();\n                        var origin = rect.origin.clone();\n                        while (rect.origin.y < box.bottom) {\n                            rect.origin.x = origin.x;\n                            repeatX();\n                            rect.origin.y += img_height;\n                        }\n                    }\n                }\n            }\n            function drawBullet() {\n                var listStyleType = getPropertyValue(style, 'list-style-type');\n                if (listStyleType == 'none') {\n                    return;\n                }\n                var listStylePosition = getPropertyValue(style, 'list-style-position');\n                function _drawBullet(f) {\n                    saveStyle(element, function () {\n                        element.style.position = 'relative';\n                        var bullet = element.ownerDocument.createElement(KENDO_PSEUDO_ELEMENT);\n                        bullet.style.position = 'absolute';\n                        bullet.style.boxSizing = 'border-box';\n                        if (listStylePosition == 'outside') {\n                            bullet.style.width = '6em';\n                            bullet.style.left = '-6.8em';\n                            bullet.style.textAlign = 'right';\n                        } else {\n                            bullet.style.left = '0px';\n                        }\n                        f(bullet);\n                        element.insertBefore(bullet, element.firstChild);\n                        renderElement(bullet, group);\n                        element.removeChild(bullet);\n                    });\n                }\n                function elementIndex(f) {\n                    var a = element.parentNode.children;\n                    var k = element.getAttribute('kendo-split-index');\n                    if (k != null) {\n                        return f(k | 0, a.length);\n                    }\n                    for (var i = 0; i < a.length; ++i) {\n                        if (a[i] === element) {\n                            return f(i, a.length);\n                        }\n                    }\n                }\n                switch (listStyleType) {\n                case 'circle':\n                case 'disc':\n                case 'square':\n                    _drawBullet(function (bullet) {\n                        bullet.style.fontSize = '60%';\n                        bullet.style.lineHeight = '200%';\n                        bullet.style.paddingRight = '0.5em';\n                        bullet.style.fontFamily = 'DejaVu Serif';\n                        bullet.innerHTML = {\n                            'disc': '\\u25CF',\n                            'circle': '\\u25EF',\n                            'square': '\\u25A0'\n                        }[listStyleType];\n                    });\n                    break;\n                case 'decimal':\n                case 'decimal-leading-zero':\n                    _drawBullet(function (bullet) {\n                        elementIndex(function (idx) {\n                            ++idx;\n                            if (listStyleType == 'decimal-leading-zero' && idx < 10) {\n                                idx = '0' + idx;\n                            }\n                            bullet.innerHTML = idx + '.';\n                        });\n                    });\n                    break;\n                case 'lower-roman':\n                case 'upper-roman':\n                    _drawBullet(function (bullet) {\n                        elementIndex(function (idx) {\n                            idx = arabicToRoman(idx + 1);\n                            if (listStyleType == 'upper-roman') {\n                                idx = idx.toUpperCase();\n                            }\n                            bullet.innerHTML = idx + '.';\n                        });\n                    });\n                    break;\n                case 'lower-latin':\n                case 'lower-alpha':\n                case 'upper-latin':\n                case 'upper-alpha':\n                    _drawBullet(function (bullet) {\n                        elementIndex(function (idx) {\n                            idx = alphaNumeral(idx);\n                            if (/^upper/i.test(listStyleType)) {\n                                idx = idx.toUpperCase();\n                            }\n                            bullet.innerHTML = idx + '.';\n                        });\n                    });\n                    break;\n                }\n            }\n            function drawOneBox(box, isFirst, isLast) {\n                if (box.width === 0 || box.height === 0) {\n                    return;\n                }\n                drawBackground(box);\n                var shouldDrawLeft = left.width > 0 && (isFirst && dir == 'ltr' || isLast && dir == 'rtl');\n                var shouldDrawRight = right.width > 0 && (isLast && dir == 'ltr' || isFirst && dir == 'rtl');\n                if (top.width === 0 && left.width === 0 && right.width === 0 && bottom.width === 0) {\n                    return;\n                }\n                if (top.color == right.color && top.color == bottom.color && top.color == left.color) {\n                    if (top.width == right.width && top.width == bottom.width && top.width == left.width) {\n                        if (shouldDrawLeft && shouldDrawRight) {\n                            box = innerBox(box, top.width / 2);\n                            var path = elementRoundBox(element, box, top.width / 2);\n                            path.options.stroke = {\n                                color: top.color,\n                                width: top.width\n                            };\n                            group.append(path);\n                            return;\n                        }\n                    }\n                }\n                if (rTL0.x === 0 && rTR0.x === 0 && rBR0.x === 0 && rBL0.x === 0) {\n                    if (top.width < 2 && left.width < 2 && right.width < 2 && bottom.width < 2) {\n                        if (top.width > 0) {\n                            group.append(new Path({\n                                stroke: {\n                                    width: top.width,\n                                    color: top.color\n                                }\n                            }).moveTo(box.left, box.top + top.width / 2).lineTo(box.right, box.top + top.width / 2));\n                        }\n                        if (bottom.width > 0) {\n                            group.append(new Path({\n                                stroke: {\n                                    width: bottom.width,\n                                    color: bottom.color\n                                }\n                            }).moveTo(box.left, box.bottom - bottom.width / 2).lineTo(box.right, box.bottom - bottom.width / 2));\n                        }\n                        if (shouldDrawLeft) {\n                            group.append(new Path({\n                                stroke: {\n                                    width: left.width,\n                                    color: left.color\n                                }\n                            }).moveTo(box.left + left.width / 2, box.top).lineTo(box.left + left.width / 2, box.bottom));\n                        }\n                        if (shouldDrawRight) {\n                            group.append(new Path({\n                                stroke: {\n                                    width: right.width,\n                                    color: right.color\n                                }\n                            }).moveTo(box.right - right.width / 2, box.top).lineTo(box.right - right.width / 2, box.bottom));\n                        }\n                        return;\n                    }\n                }\n                var tmp = adjustBorderRadiusForBox(box, rTL0, rTR0, rBR0, rBL0);\n                var rTL = tmp.tl;\n                var rTR = tmp.tr;\n                var rBR = tmp.br;\n                var rBL = tmp.bl;\n                drawEdge(top.color, box.width, top.width, left.width, right.width, rTL, rTR, [\n                    1,\n                    0,\n                    0,\n                    1,\n                    box.left,\n                    box.top\n                ]);\n                drawEdge(bottom.color, box.width, bottom.width, right.width, left.width, rBR, rBL, [\n                    -1,\n                    0,\n                    0,\n                    -1,\n                    box.right,\n                    box.bottom\n                ]);\n                function inv(p) {\n                    return {\n                        x: p.y,\n                        y: p.x\n                    };\n                }\n                drawEdge(left.color, box.height, left.width, bottom.width, top.width, inv(rBL), inv(rTL), [\n                    0,\n                    -1,\n                    1,\n                    0,\n                    box.left,\n                    box.bottom\n                ]);\n                drawEdge(right.color, box.height, right.width, top.width, bottom.width, inv(rTR), inv(rBR), [\n                    0,\n                    1,\n                    -1,\n                    0,\n                    box.right,\n                    box.top\n                ]);\n            }\n        }\n        function gradientRenderer(gradient) {\n            return function (group, rect) {\n                var width = rect.width(), height = rect.height();\n                switch (gradient.type) {\n                case 'linear':\n                    var angle = gradient.angle != null ? gradient.angle : Math.PI;\n                    switch (gradient.to) {\n                    case 'top':\n                        angle = 0;\n                        break;\n                    case 'left':\n                        angle = -Math.PI / 2;\n                        break;\n                    case 'bottom':\n                        angle = Math.PI;\n                        break;\n                    case 'right':\n                        angle = Math.PI / 2;\n                        break;\n                    case 'top left':\n                    case 'left top':\n                        angle = -Math.atan2(height, width);\n                        break;\n                    case 'top right':\n                    case 'right top':\n                        angle = Math.atan2(height, width);\n                        break;\n                    case 'bottom left':\n                    case 'left bottom':\n                        angle = Math.PI + Math.atan2(height, width);\n                        break;\n                    case 'bottom right':\n                    case 'right bottom':\n                        angle = Math.PI - Math.atan2(height, width);\n                        break;\n                    }\n                    if (gradient.reverse) {\n                        angle -= Math.PI;\n                    }\n                    angle %= 2 * Math.PI;\n                    if (angle < 0) {\n                        angle += 2 * Math.PI;\n                    }\n                    var pxlen = Math.abs(width * Math.sin(angle)) + Math.abs(height * Math.cos(angle));\n                    var scaledAngle = Math.atan(width * Math.tan(angle) / height);\n                    var sin = Math.sin(scaledAngle), cos = Math.cos(scaledAngle);\n                    var len = Math.abs(sin) + Math.abs(cos);\n                    var x = len / 2 * sin;\n                    var y = len / 2 * cos;\n                    if (angle > Math.PI / 2 && angle <= 3 * Math.PI / 2) {\n                        x = -x;\n                        y = -y;\n                    }\n                    var implicit = [], right = 0;\n                    var stops = gradient.stops.map(function (s, i) {\n                        var offset = s.percent;\n                        if (offset) {\n                            offset = parseFloat(offset) / 100;\n                        } else if (s.length) {\n                            offset = parseFloat(s.length) / pxlen;\n                        } else if (i === 0) {\n                            offset = 0;\n                        } else if (i == gradient.stops.length - 1) {\n                            offset = 1;\n                        }\n                        var stop = {\n                            color: s.color.toCssRgba(),\n                            offset: offset\n                        };\n                        if (offset != null) {\n                            right = offset;\n                            implicit.forEach(function (s, i) {\n                                var stop = s.stop;\n                                stop.offset = s.left + (right - s.left) * (i + 1) / (implicit.length + 1);\n                            });\n                            implicit = [];\n                        } else {\n                            implicit.push({\n                                left: right,\n                                stop: stop\n                            });\n                        }\n                        return stop;\n                    });\n                    var start = [\n                        0.5 - x,\n                        0.5 + y\n                    ];\n                    var end = [\n                        0.5 + x,\n                        0.5 - y\n                    ];\n                    group.append(Path.fromRect(rect).stroke(null).fill(new LinearGradient({\n                        start: start,\n                        end: end,\n                        stops: stops,\n                        userSpace: false\n                    })));\n                    break;\n                case 'radial':\n                    if (window.console && window.console.log) {\n                        window.console.log('Radial gradients are not yet supported in HTML renderer');\n                    }\n                    break;\n                }\n            };\n        }\n        function maybeRenderWidget(element, group) {\n            var visual;\n            if (element._kendoExportVisual) {\n                visual = element._kendoExportVisual();\n            } else if (window.kendo && window.kendo.jQuery && element.getAttribute(window.kendo.attr('role'))) {\n                var widget = window.kendo.widgetInstance(window.kendo.jQuery(element));\n                if (widget && (widget.exportDOMVisual || widget.exportVisual)) {\n                    if (widget.exportDOMVisual) {\n                        visual = widget.exportDOMVisual();\n                    } else {\n                        visual = widget.exportVisual();\n                    }\n                }\n            }\n            if (!visual) {\n                return false;\n            }\n            var wrap$$1 = new Group();\n            wrap$$1.children.push(visual);\n            var bbox = element.getBoundingClientRect();\n            wrap$$1.transform(transform().translate(bbox.left, bbox.top));\n            group.append(wrap$$1);\n            return true;\n        }\n        function renderImage(element, url, group) {\n            var box = getContentBox(element);\n            var rect = new Rect([\n                box.left,\n                box.top\n            ], [\n                box.width,\n                box.height\n            ]);\n            var image = new Image$1(url, rect);\n            setClipping(image, elementRoundBox(element, box, 'content'));\n            group.append(image);\n        }\n        function zIndexSort(a, b) {\n            var sa = getComputedStyle(a);\n            var sb = getComputedStyle(b);\n            var za = parseFloat(getPropertyValue(sa, 'z-index'));\n            var zb = parseFloat(getPropertyValue(sb, 'z-index'));\n            var pa = getPropertyValue(sa, 'position');\n            var pb = getPropertyValue(sb, 'position');\n            if (isNaN(za) && isNaN(zb)) {\n                if (/static|absolute/.test(pa) && /static|absolute/.test(pb)) {\n                    return 0;\n                }\n                if (pa == 'static') {\n                    return -1;\n                }\n                if (pb == 'static') {\n                    return 1;\n                }\n                return 0;\n            }\n            if (isNaN(za)) {\n                return zb === 0 ? 0 : zb > 0 ? -1 : 1;\n            }\n            if (isNaN(zb)) {\n                return za === 0 ? 0 : za > 0 ? 1 : -1;\n            }\n            return parseFloat(za) - parseFloat(zb);\n        }\n        function isFormField(element) {\n            return /^(?:textarea|select|input)$/i.test(element.tagName);\n        }\n        function getSelectedOption(element) {\n            if (element.selectedOptions && element.selectedOptions.length > 0) {\n                return element.selectedOptions[0];\n            }\n            return element.options[element.selectedIndex];\n        }\n        function renderCheckbox(element, group) {\n            var style = getComputedStyle(element);\n            var color = getPropertyValue(style, 'color');\n            var box = element.getBoundingClientRect();\n            if (element.type == 'checkbox') {\n                group.append(Path.fromRect(new Rect([\n                    box.left + 1,\n                    box.top + 1\n                ], [\n                    box.width - 2,\n                    box.height - 2\n                ])).stroke(color, 1));\n                if (element.checked) {\n                    group.append(new Path().stroke(color, 1.2).moveTo(box.left + 0.22 * box.width, box.top + 0.55 * box.height).lineTo(box.left + 0.45 * box.width, box.top + 0.75 * box.height).lineTo(box.left + 0.78 * box.width, box.top + 0.22 * box.width));\n                }\n            } else {\n                group.append(new Circle(new Circle$2([\n                    (box.left + box.right) / 2,\n                    (box.top + box.bottom) / 2\n                ], Math.min(box.width - 2, box.height - 2) / 2)).stroke(color, 1));\n                if (element.checked) {\n                    group.append(new Circle(new Circle$2([\n                        (box.left + box.right) / 2,\n                        (box.top + box.bottom) / 2\n                    ], Math.min(box.width - 8, box.height - 8) / 2)).fill(color).stroke(null));\n                }\n            }\n        }\n        function renderFormField(element, group) {\n            var tag = element.tagName.toLowerCase();\n            if (tag == 'input' && (element.type == 'checkbox' || element.type == 'radio')) {\n                return renderCheckbox(element, group);\n            }\n            var p = element.parentNode;\n            var doc = element.ownerDocument;\n            var el = doc.createElement(KENDO_PSEUDO_ELEMENT);\n            var option;\n            el.style.cssText = getCssText(getComputedStyle(element));\n            if (tag == 'input') {\n                el.style.whiteSpace = 'pre';\n            }\n            if (tag == 'select' || tag == 'textarea') {\n                el.style.overflow = 'auto';\n            }\n            if (tag == 'select') {\n                if (element.multiple) {\n                    for (var i = 0; i < element.options.length; ++i) {\n                        option = doc.createElement(KENDO_PSEUDO_ELEMENT);\n                        option.style.cssText = getCssText(getComputedStyle(element.options[i]));\n                        option.style.display = 'block';\n                        option.textContent = element.options[i].textContent;\n                        el.appendChild(option);\n                    }\n                } else {\n                    option = getSelectedOption(element);\n                    if (option) {\n                        el.textContent = option.textContent;\n                    }\n                }\n            } else {\n                el.textContent = element.value;\n            }\n            p.insertBefore(el, element);\n            el.scrollLeft = element.scrollLeft;\n            el.scrollTop = element.scrollTop;\n            element.style.display = 'none';\n            renderContents(el, group);\n            element.style.display = '';\n            p.removeChild(el);\n        }\n        function renderContents(element, group) {\n            if (nodeInfo._stackingContext.element === element) {\n                nodeInfo._stackingContext.group = group;\n            }\n            switch (element.tagName.toLowerCase()) {\n            case 'img':\n                renderImage(element, element.src, group);\n                break;\n            case 'canvas':\n                try {\n                    renderImage(element, element.toDataURL('image/png'), group);\n                } catch (ex) {\n                }\n                break;\n            case 'textarea':\n            case 'input':\n            case 'select':\n                renderFormField(element, group);\n                break;\n            default:\n                var children = [], floats = [], positioned = [];\n                for (var i = element.firstChild; i; i = i.nextSibling) {\n                    switch (i.nodeType) {\n                    case 3:\n                        if (/\\S/.test(i.data)) {\n                            renderText(element, i, group);\n                        }\n                        break;\n                    case 1:\n                        var style = getComputedStyle(i);\n                        var floating = getPropertyValue(style, 'float');\n                        var position = getPropertyValue(style, 'position');\n                        if (position != 'static') {\n                            positioned.push(i);\n                        } else if (floating != 'none') {\n                            floats.push(i);\n                        } else {\n                            children.push(i);\n                        }\n                        break;\n                    }\n                }\n                mergeSort(children, zIndexSort).forEach(function (el) {\n                    renderElement(el, group);\n                });\n                mergeSort(floats, zIndexSort).forEach(function (el) {\n                    renderElement(el, group);\n                });\n                mergeSort(positioned, zIndexSort).forEach(function (el) {\n                    renderElement(el, group);\n                });\n            }\n        }\n        function renderText(element, node, group) {\n            if (emptyClipbox()) {\n                return;\n            }\n            var style = getComputedStyle(element);\n            if (parseFloat(getPropertyValue(style, 'text-indent')) < -500) {\n                return;\n            }\n            var text = node.data;\n            var start = 0;\n            var end = text.search(/\\S\\s*$/) + 1;\n            if (!end) {\n                return;\n            }\n            var fontSize = getPropertyValue(style, 'font-size');\n            var lineHeight = getPropertyValue(style, 'line-height');\n            var font = [\n                getPropertyValue(style, 'font-style'),\n                getPropertyValue(style, 'font-variant'),\n                getPropertyValue(style, 'font-weight'),\n                fontSize,\n                getPropertyValue(style, 'font-family')\n            ].join(' ');\n            fontSize = parseFloat(fontSize);\n            lineHeight = parseFloat(lineHeight);\n            if (fontSize === 0) {\n                return;\n            }\n            var color = getPropertyValue(style, 'color');\n            var range = element.ownerDocument.createRange();\n            var align$$1 = getPropertyValue(style, 'text-align');\n            var isJustified = align$$1 == 'justify';\n            var columnCount = getPropertyValue(style, 'column-count', 1);\n            var whiteSpace = getPropertyValue(style, 'white-space');\n            var textTransform = getPropertyValue(style, 'text-transform');\n            var estimateLineLength = element.getBoundingClientRect().width / fontSize * 5;\n            if (estimateLineLength === 0) {\n                estimateLineLength = 500;\n            }\n            var prevLineBottom = null;\n            var underline = nodeInfo['underline'];\n            var lineThrough = nodeInfo['line-through'];\n            var overline = nodeInfo['overline'];\n            var hasDecoration = underline || lineThrough || overline;\n            while (!doChunk()) {\n            }\n            if (hasDecoration) {\n                range.selectNode(node);\n                slice$1(range.getClientRects()).forEach(decorate);\n            }\n            return;\n            function actuallyGetRangeBoundingRect(range) {\n                if (microsoft || browser.chrome) {\n                    var rectangles = range.getClientRects(), box = {\n                            top: Infinity,\n                            right: -Infinity,\n                            bottom: -Infinity,\n                            left: Infinity\n                        }, done = false;\n                    for (var i = 0; i < rectangles.length; ++i) {\n                        var b = rectangles[i];\n                        if (b.width <= 1 || b.bottom === prevLineBottom) {\n                            continue;\n                        }\n                        box.left = Math.min(b.left, box.left);\n                        box.top = Math.min(b.top, box.top);\n                        box.right = Math.max(b.right, box.right);\n                        box.bottom = Math.max(b.bottom, box.bottom);\n                        done = true;\n                    }\n                    if (!done) {\n                        return range.getBoundingClientRect();\n                    }\n                    box.width = box.right - box.left;\n                    box.height = box.bottom - box.top;\n                    return box;\n                }\n                return range.getBoundingClientRect();\n            }\n            function doChunk() {\n                var origStart = start;\n                var box, pos = text.substr(start).search(/\\S/);\n                start += pos;\n                if (pos < 0 || start >= end) {\n                    return true;\n                }\n                range.setStart(node, start);\n                range.setEnd(node, start + 1);\n                box = actuallyGetRangeBoundingRect(range);\n                var found = false;\n                if (isJustified || columnCount > 1) {\n                    pos = text.substr(start).search(/\\s/);\n                    if (pos >= 0) {\n                        range.setEnd(node, start + pos);\n                        var r = actuallyGetRangeBoundingRect(range);\n                        if (r.bottom == box.bottom) {\n                            box = r;\n                            found = true;\n                            start += pos;\n                        }\n                    }\n                }\n                if (!found) {\n                    pos = function findEOL(min, eol, max) {\n                        range.setEnd(node, eol);\n                        var r = actuallyGetRangeBoundingRect(range);\n                        if (r.bottom != box.bottom && min < eol) {\n                            return findEOL(min, min + eol >> 1, eol);\n                        } else if (r.right != box.right) {\n                            box = r;\n                            if (eol < max) {\n                                return findEOL(eol, eol + max >> 1, max);\n                            } else {\n                                return eol;\n                            }\n                        } else {\n                            return eol;\n                        }\n                    }(start, Math.min(end, start + estimateLineLength), end);\n                    if (pos == start) {\n                        return true;\n                    }\n                    start = pos;\n                    pos = range.toString().search(/\\s+$/);\n                    if (pos === 0) {\n                        return false;\n                    }\n                    if (pos > 0) {\n                        range.setEnd(node, range.startOffset + pos);\n                        box = actuallyGetRangeBoundingRect(range);\n                    }\n                }\n                if (microsoft) {\n                    box = range.getClientRects()[0];\n                }\n                var str = range.toString();\n                if (!/^(?:pre|pre-wrap)$/i.test(whiteSpace)) {\n                    str = str.replace(/\\s+/g, ' ');\n                } else if (/\\t/.test(str)) {\n                    var cc = 0;\n                    for (pos = origStart; pos < range.startOffset; ++pos) {\n                        var code = text.charCodeAt(pos);\n                        if (code == 9) {\n                            cc += 8 - cc % 8;\n                        } else if (code == 10 || code == 13) {\n                            cc = 0;\n                        } else {\n                            cc++;\n                        }\n                    }\n                    while ((pos = str.search('\\t')) >= 0) {\n                        var indent = '        '.substr(0, 8 - (cc + pos) % 8);\n                        str = str.substr(0, pos) + indent + str.substr(pos + 1);\n                    }\n                }\n                if (!found) {\n                    prevLineBottom = box.bottom;\n                }\n                drawText(str, box);\n            }\n            function drawText(str, box) {\n                if (microsoft && !isNaN(lineHeight)) {\n                    var height = getFontHeight(font);\n                    var top = (box.top + box.bottom - height) / 2;\n                    box = {\n                        top: top,\n                        right: box.right,\n                        bottom: top + height,\n                        left: box.left,\n                        height: height,\n                        width: box.right - box.left\n                    };\n                }\n                switch (textTransform) {\n                case 'uppercase':\n                    str = str.toUpperCase();\n                    break;\n                case 'lowercase':\n                    str = str.toLowerCase();\n                    break;\n                case 'capitalize':\n                    str = str.replace(/(?:^|\\s)\\S/g, function (l) {\n                        return l.toUpperCase();\n                    });\n                    break;\n                }\n                var text = new TextRect(str, new Rect([\n                    box.left,\n                    box.top\n                ], [\n                    box.width,\n                    box.height\n                ]), {\n                    font: font,\n                    fill: { color: color }\n                });\n                group.append(text);\n            }\n            function decorate(box) {\n                line(underline, box.bottom);\n                line(lineThrough, box.bottom - box.height / 2.7);\n                line(overline, box.top);\n                function line(color, ypos) {\n                    if (color) {\n                        var width = fontSize / 12;\n                        var path = new Path({\n                            stroke: {\n                                width: width,\n                                color: color\n                            }\n                        });\n                        ypos -= width;\n                        path.moveTo(box.left, ypos).lineTo(box.right, ypos);\n                        group.append(path);\n                    }\n                }\n            }\n        }\n        function groupInStackingContext(element, group, zIndex) {\n            var main;\n            if (zIndex != 'auto') {\n                main = nodeInfo._stackingContext.group;\n                zIndex = parseFloat(zIndex);\n            } else {\n                main = group;\n                zIndex = 0;\n            }\n            var a = main.children;\n            for (var i = 0; i < a.length; ++i) {\n                if (a[i]._dom_zIndex != null && a[i]._dom_zIndex > zIndex) {\n                    break;\n                }\n            }\n            var tmp = new Group();\n            main.insert(i, tmp);\n            tmp._dom_zIndex = zIndex;\n            if (main !== group) {\n                if (nodeInfo._clipbox) {\n                    var m = nodeInfo._matrix.invert();\n                    var r = nodeInfo._clipbox.transformCopy(m);\n                    setClipping(tmp, Path.fromRect(r));\n                }\n            }\n            return tmp;\n        }\n        function renderElement(element, container) {\n            var style = getComputedStyle(element);\n            updateCounters(style);\n            if (/^(style|script|link|meta|iframe|svg|col|colgroup)$/i.test(element.tagName)) {\n                return;\n            }\n            if (nodeInfo._clipbox == null) {\n                return;\n            }\n            var opacity = parseFloat(getPropertyValue(style, 'opacity'));\n            var visibility = getPropertyValue(style, 'visibility');\n            var display = getPropertyValue(style, 'display');\n            if (opacity === 0 || visibility == 'hidden' || display == 'none') {\n                return;\n            }\n            var tr = getTransform(style);\n            var group;\n            var zIndex = getPropertyValue(style, 'z-index');\n            if ((tr || opacity < 1) && zIndex == 'auto') {\n                zIndex = 0;\n            }\n            group = groupInStackingContext(element, container, zIndex);\n            if (opacity < 1) {\n                group.opacity(opacity * group.opacity());\n            }\n            pushNodeInfo(element, style, group);\n            if (!tr) {\n                _renderWithPseudoElements(element, group);\n            } else {\n                saveStyle(element, function () {\n                    pleaseSetPropertyValue(element.style, 'transform', 'none', 'important');\n                    pleaseSetPropertyValue(element.style, 'transition', 'none', 'important');\n                    if (getPropertyValue(style, 'position') == 'static') {\n                        pleaseSetPropertyValue(element.style, 'position', 'relative', 'important');\n                    }\n                    var bbox = element.getBoundingClientRect();\n                    var x = bbox.left + tr.origin[0];\n                    var y = bbox.top + tr.origin[1];\n                    var m = [\n                        1,\n                        0,\n                        0,\n                        1,\n                        -x,\n                        -y\n                    ];\n                    m = mmul(m, tr.matrix);\n                    m = mmul(m, [\n                        1,\n                        0,\n                        0,\n                        1,\n                        x,\n                        y\n                    ]);\n                    m = setTransform(group, m);\n                    nodeInfo._matrix = nodeInfo._matrix.multiplyCopy(m);\n                    _renderWithPseudoElements(element, group);\n                });\n            }\n            popNodeInfo();\n        }\n        function mmul(a, b) {\n            var a1 = a[0], b1 = a[1], c1 = a[2], d1 = a[3], e1 = a[4], f1 = a[5];\n            var a2 = b[0], b2 = b[1], c2 = b[2], d2 = b[3], e2 = b[4], f2 = b[5];\n            return [\n                a1 * a2 + b1 * c2,\n                a1 * b2 + b1 * d2,\n                c1 * a2 + d1 * c2,\n                c1 * b2 + d1 * d2,\n                e1 * a2 + f1 * c2 + e2,\n                e1 * b2 + f1 * d2 + f2\n            ];\n        }\n        var drawing = {\n            svg: svg,\n            canvas: canvas,\n            util: util,\n            PathParser: PathParser,\n            Surface: Surface,\n            BaseNode: BaseNode,\n            SurfaceFactory: SurfaceFactory,\n            OptionsStore: OptionsStore,\n            exportImage: exportImage,\n            exportSVG: exportSVG,\n            QuadNode: QuadNode,\n            ShapesQuadTree: ShapesQuadTree,\n            ObserversMixin: ObserversMixin,\n            Element: Element$1,\n            Circle: Circle,\n            Arc: Arc,\n            Path: Path,\n            MultiPath: MultiPath,\n            Text: Text,\n            Image: Image$1,\n            Group: Group,\n            Layout: Layout,\n            Rect: Rect$2,\n            align: align,\n            vAlign: vAlign,\n            stack: stack,\n            vStack: vStack,\n            wrap: wrap,\n            vWrap: vWrap,\n            fit: fit,\n            LinearGradient: LinearGradient,\n            RadialGradient: RadialGradient,\n            GradientStop: GradientStop,\n            Gradient: Gradient,\n            Animation: Animation,\n            AnimationFactory: AnimationFactory,\n            drawDOM: drawDOM\n        };\n        kendo.deepExtend(kendo, {\n            drawing: drawing,\n            geometry: geometry\n        });\n        kendo.drawing.Segment = kendo.geometry.Segment;\n        kendo.dataviz.drawing = kendo.drawing;\n        kendo.dataviz.geometry = kendo.geometry;\n        kendo.drawing.util.measureText = kendo.util.measureText;\n        kendo.drawing.util.objectKey = kendo.util.objectKey;\n        kendo.drawing.Color = kendo.Color;\n        kendo.util.encodeBase64 = kendo.drawing.util.encodeBase64;\n    }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('drawing/surface-tooltip', [\n        'kendo.popup',\n        'drawing/kendo-drawing'\n    ], f);\n}(function () {\n    (function ($) {\n        var NS = '.kendo';\n        var kendo = window.kendo;\n        var deepExtend = kendo.deepExtend;\n        var utils = kendo.drawing.util;\n        var defined = utils.defined;\n        var limitValue = utils.limitValue;\n        var eventCoordinates = utils.eventCoordinates;\n        var outerWidth = kendo._outerWidth;\n        var outerHeight = kendo._outerHeight;\n        var proxy = $.proxy;\n        var TOOLTIP_TEMPLATE = '<div class=\"k-tooltip\">' + '<div class=\"k-tooltip-content\"></div>' + '</div>';\n        var TOOLTIP_CLOSE_TEMPLATE = '<div class=\"k-tooltip-button\"><a href=\"\\\\#\" class=\"k-icon k-i-close\">close</a></div>';\n        var SurfaceTooltip = kendo.Class.extend({\n            init: function (surface, options) {\n                this.element = $(TOOLTIP_TEMPLATE);\n                this.content = this.element.children('.k-tooltip-content');\n                options = options || {};\n                this.options = deepExtend({}, this.options, this._tooltipOptions(options));\n                this.popupOptions = {\n                    appendTo: options.appendTo,\n                    animation: options.animation,\n                    copyAnchorStyles: false,\n                    collision: 'fit fit'\n                };\n                this._openPopupHandler = $.proxy(this._openPopup, this);\n                this.surface = surface;\n                this._bindEvents();\n            },\n            options: {\n                position: 'top',\n                showOn: 'mouseenter',\n                offset: 7,\n                autoHide: true,\n                hideDelay: 0,\n                showAfter: 100\n            },\n            _bindEvents: function () {\n                this._showHandler = proxy(this._showEvent, this);\n                this._surfaceLeaveHandler = proxy(this._surfaceLeave, this);\n                this._mouseleaveHandler = proxy(this._mouseleave, this);\n                this._mousemoveHandler = proxy(this._mousemove, this);\n                this.surface.bind('click', this._showHandler);\n                this.surface.bind('mouseenter', this._showHandler);\n                this.surface.bind('mouseleave', this._mouseleaveHandler);\n                this.surface.bind('mousemove', this._mousemoveHandler);\n                this.surface.element.on('mouseleave' + NS, this._surfaceLeaveHandler);\n                this.element.on('click' + NS, '.k-tooltip-button', proxy(this._hideClick, this));\n                this.element.on('mouseleave' + NS, proxy(this._tooltipLeave, this));\n            },\n            getPopup: function () {\n                if (!this.popup) {\n                    this.popup = new kendo.ui.Popup(this.element, this.popupOptions);\n                }\n                return this.popup;\n            },\n            destroy: function () {\n                var popup = this.popup;\n                this.surface.unbind('click', this._showHandler);\n                this.surface.unbind('mouseenter', this._showHandler);\n                this.surface.unbind('mouseleave', this._mouseleaveHandler);\n                this.surface.unbind('mousemove', this._mousemoveHandler);\n                this.surface.element.off('mouseleave' + NS, this._surfaceLeaveHandler);\n                this.element.off('click' + NS);\n                this.element.off('mouseleave' + NS);\n                if (popup) {\n                    popup.destroy();\n                    delete this.popup;\n                }\n                delete this.popupOptions;\n                clearTimeout(this._timeout);\n                delete this.element;\n                delete this.content;\n                delete this.surface;\n            },\n            _tooltipOptions: function (options) {\n                options = options || {};\n                return {\n                    position: options.position,\n                    showOn: options.showOn,\n                    offset: options.offset,\n                    autoHide: options.autoHide,\n                    width: options.width,\n                    height: options.height,\n                    content: options.content,\n                    shared: options.shared,\n                    hideDelay: options.hideDelay,\n                    showAfter: options.showAfter\n                };\n            },\n            _tooltipShape: function (shape) {\n                while (shape && !shape.options.tooltip) {\n                    shape = shape.parent;\n                }\n                return shape;\n            },\n            _updateContent: function (target, shape, options) {\n                var content = options.content;\n                if (kendo.isFunction(content)) {\n                    content = content({\n                        element: shape,\n                        target: target\n                    });\n                }\n                if (content) {\n                    this.content.html(content);\n                    return true;\n                }\n            },\n            _position: function (shape, options, elementSize, event) {\n                var position = options.position;\n                var tooltipOffset = options.offset || 0;\n                var surface = this.surface;\n                var offset = surface._instance._elementOffset();\n                var size = surface.getSize();\n                var surfaceOffset = surface._instance._offset;\n                var bbox = shape.bbox();\n                var width = elementSize.width;\n                var height = elementSize.height;\n                var left = 0, top = 0;\n                bbox.origin.translate(offset.left, offset.top);\n                if (surfaceOffset) {\n                    bbox.origin.translate(-surfaceOffset.x, -surfaceOffset.y);\n                }\n                if (position == 'cursor' && event) {\n                    var coord = eventCoordinates(event);\n                    left = coord.x - width / 2;\n                    top = coord.y - height - tooltipOffset;\n                } else if (position == 'left') {\n                    left = bbox.origin.x - width - tooltipOffset;\n                    top = bbox.center().y - height / 2;\n                } else if (position == 'right') {\n                    left = bbox.bottomRight().x + tooltipOffset;\n                    top = bbox.center().y - height / 2;\n                } else if (position == 'bottom') {\n                    left = bbox.center().x - width / 2;\n                    top = bbox.bottomRight().y + tooltipOffset;\n                } else {\n                    left = bbox.center().x - width / 2;\n                    top = bbox.origin.y - height - tooltipOffset;\n                }\n                return {\n                    left: limitValue(left, offset.left, offset.left + size.width),\n                    top: limitValue(top, offset.top, offset.top + size.height)\n                };\n            },\n            show: function (shape, options) {\n                this._show(shape, shape, deepExtend({}, this.options, this._tooltipOptions(shape.options.tooltip), options));\n            },\n            hide: function () {\n                var popup = this.popup;\n                var current = this._current;\n                delete this._current;\n                clearTimeout(this._showTimeout);\n                if (popup && popup.visible() && current && !this.surface.trigger('tooltipClose', {\n                        element: current.shape,\n                        target: current.target,\n                        popup: popup\n                    })) {\n                    popup.close();\n                }\n            },\n            _hideClick: function (e) {\n                e.preventDefault();\n                this.hide();\n            },\n            _show: function (target, shape, options, event, delay) {\n                var current = this._current;\n                clearTimeout(this._timeout);\n                if (current && (current.shape === shape && options.shared || current.target === target)) {\n                    return;\n                }\n                clearTimeout(this._showTimeout);\n                var popup = this.getPopup();\n                if (!this.surface.trigger('tooltipOpen', {\n                        element: shape,\n                        target: target,\n                        popup: popup\n                    }) && this._updateContent(target, shape, options)) {\n                    this._autoHide(options);\n                    var elementSize = this._measure(options);\n                    if (popup.visible()) {\n                        popup.close(true);\n                    }\n                    this._current = {\n                        options: options,\n                        elementSize: elementSize,\n                        shape: shape,\n                        target: target,\n                        position: this._position(options.shared ? shape : target, options, elementSize, event)\n                    };\n                    if (delay) {\n                        this._showTimeout = setTimeout(this._openPopupHandler, options.showAfter || 0);\n                    } else {\n                        this._openPopup();\n                    }\n                }\n            },\n            _openPopup: function () {\n                var current = this._current;\n                var position = current.position;\n                this.getPopup().open(position.left, position.top);\n            },\n            _autoHide: function (options) {\n                if (options.autoHide && this._closeButton) {\n                    this.element.removeClass('k-tooltip-closable');\n                    this._closeButton.remove();\n                    delete this._closeButton;\n                }\n                if (!options.autoHide && !this._closeButton) {\n                    this.element.addClass('k-tooltip-closable');\n                    this._closeButton = $(TOOLTIP_CLOSE_TEMPLATE).prependTo(this.element);\n                }\n            },\n            _showEvent: function (e) {\n                var shape = this._tooltipShape(e.element);\n                if (shape) {\n                    var options = deepExtend({}, this.options, this._tooltipOptions(shape.options.tooltip));\n                    if (options && options.showOn == e.type) {\n                        this._show(e.element, shape, options, e.originalEvent, true);\n                    }\n                }\n            },\n            _measure: function (options) {\n                var popup = this.getPopup();\n                var width, height;\n                this.element.css({\n                    width: 'auto',\n                    height: 'auto'\n                });\n                var visible = popup.visible();\n                if (!visible) {\n                    popup.wrapper.show();\n                }\n                this.element.css({\n                    width: defined(options.width) ? options.width : 'auto',\n                    height: defined(options.height) ? options.height : 'auto'\n                });\n                width = outerWidth(this.element);\n                height = outerHeight(this.element);\n                if (!visible) {\n                    popup.wrapper.hide();\n                }\n                return {\n                    width: width,\n                    height: height\n                };\n            },\n            _mouseleave: function (e) {\n                if (this.popup && !this._popupRelatedTarget(e.originalEvent)) {\n                    var tooltip = this;\n                    var current = tooltip._current;\n                    if (current && current.options.autoHide) {\n                        tooltip._timeout = setTimeout(function () {\n                            clearTimeout(tooltip._showTimeout);\n                            tooltip.hide();\n                        }, current.options.hideDelay || 0);\n                    }\n                }\n            },\n            _mousemove: function (e) {\n                var current = this._current;\n                if (current && e.element) {\n                    var options = current.options;\n                    if (options.position == 'cursor') {\n                        var position = this._position(e.element, options, current.elementSize, e.originalEvent);\n                        current.position = position;\n                        this.getPopup().wrapper.css({\n                            left: position.left,\n                            top: position.top\n                        });\n                    }\n                }\n            },\n            _surfaceLeave: function (e) {\n                if (this.popup && !this._popupRelatedTarget(e)) {\n                    clearTimeout(this._showTimeout);\n                    this.hide();\n                }\n            },\n            _popupRelatedTarget: function (e) {\n                return e.relatedTarget && $(e.relatedTarget).closest(this.popup.wrapper).length;\n            },\n            _tooltipLeave: function () {\n                var tooltip = this;\n                var current = tooltip._current;\n                if (current && current.options.autoHide) {\n                    tooltip._timeout = setTimeout(function () {\n                        tooltip.hide();\n                    }, current.options.hideDelay || 0);\n                }\n            }\n        });\n        kendo.drawing.SurfaceTooltip = SurfaceTooltip;\n    }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('drawing/surface', [\n        'drawing/kendo-drawing',\n        'drawing/surface-tooltip'\n    ], f);\n}(function () {\n    (function ($) {\n        var kendo = window.kendo;\n        var draw = kendo.drawing;\n        var DrawingSurface = draw.Surface;\n        var Widget = kendo.ui.Widget;\n        var deepExtend = kendo.deepExtend;\n        var proxy = $.proxy;\n        kendo.support.svg = DrawingSurface.support.svg;\n        kendo.support.canvas = DrawingSurface.support.canvas;\n        var Surface = Widget.extend({\n            init: function (element, options) {\n                Widget.fn.init.call(this, element, {});\n                this.options = deepExtend({}, this.options, options);\n                this._instance = DrawingSurface.create(this.element[0], options);\n                if (this._instance.translate) {\n                    this.translate = translate;\n                }\n                this._triggerInstanceHandler = proxy(this._triggerInstanceEvent, this);\n                this._bindHandler('click');\n                this._bindHandler('mouseenter');\n                this._bindHandler('mouseleave');\n                this._bindHandler('mousemove');\n                this._enableTracking();\n            },\n            options: {\n                name: 'Surface',\n                tooltip: {}\n            },\n            events: [\n                'click',\n                'mouseenter',\n                'mouseleave',\n                'mousemove',\n                'resize',\n                'tooltipOpen',\n                'tooltipClose'\n            ],\n            _triggerInstanceEvent: function (e) {\n                this.trigger(e.type, e);\n            },\n            _bindHandler: function (event) {\n                this._instance.bind(event, this._triggerInstanceHandler);\n            },\n            draw: function (element) {\n                this._instance.draw(element);\n            },\n            clear: function () {\n                if (this._instance) {\n                    this._instance.clear();\n                }\n                this.hideTooltip();\n            },\n            destroy: function () {\n                if (this._instance) {\n                    this._instance.destroy();\n                    delete this._instance;\n                }\n                if (this._tooltip) {\n                    this._tooltip.destroy();\n                    delete this._tooltip;\n                }\n                Widget.fn.destroy.call(this);\n            },\n            exportVisual: function () {\n                return this._instance.exportVisual();\n            },\n            eventTarget: function (e) {\n                return this._instance.eventTarget(e);\n            },\n            showTooltip: function (shape, options) {\n                if (this._tooltip) {\n                    this._tooltip.show(shape, options);\n                }\n            },\n            hideTooltip: function () {\n                if (this._tooltip) {\n                    this._tooltip.hide();\n                }\n            },\n            suspendTracking: function () {\n                this._instance.suspendTracking();\n                this.hideTooltip();\n            },\n            resumeTracking: function () {\n                this._instance.resumeTracking();\n            },\n            getSize: function () {\n                return {\n                    width: this.element.width(),\n                    height: this.element.height()\n                };\n            },\n            setSize: function (size) {\n                this.element.css({\n                    width: size.width,\n                    height: size.height\n                });\n                this._size = size;\n                this._instance.currentSize(size);\n                this._resize();\n            },\n            _resize: function () {\n                this._instance.currentSize(this._size);\n                this._instance._resize();\n            },\n            _enableTracking: function () {\n                if (kendo.ui.Popup) {\n                    this._tooltip = new draw.SurfaceTooltip(this, this.options.tooltip || {});\n                }\n            }\n        });\n        kendo.ui.plugin(Surface);\n        Surface.create = function (element, options) {\n            return new Surface(element, options);\n        };\n        kendo.drawing.Surface = Surface;\n        function translate(offset) {\n            this._instance.translate(offset);\n        }\n    }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('drawing/html', ['drawing/kendo-drawing'], f);\n}(function () {\n    (function ($) {\n        var kendo = window.kendo;\n        var drawing = kendo.drawing;\n        var drawDOM = drawing.drawDOM;\n        drawing.drawDOM = function (element, options) {\n            return drawDOM($(element)[0], options);\n        };\n        drawing.drawDOM.drawText = drawDOM.drawText;\n        drawing.drawDOM.getFontFaces = drawDOM.getFontFaces;\n    }(window.kendo.jQuery));\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));\n(function (f, define) {\n    define('kendo.drawing', [\n        'drawing/util',\n        'drawing/kendo-drawing',\n        'drawing/surface-tooltip',\n        'drawing/surface',\n        'drawing/html'\n    ], f);\n}(function () {\n    var __meta__ = {\n        id: 'drawing',\n        name: 'Drawing API',\n        category: 'framework',\n        description: 'The Kendo UI low-level drawing API',\n        depends: [\n            'core',\n            'color',\n            'popup'\n        ]\n    };\n}, typeof define == 'function' && define.amd ? define : function (a1, a2, a3) {\n    (a3 || a2)();\n}));"]}