@antv/g-svg 1.8.30 → 1.8.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/SVGContextService.d.ts +2 -0
- package/dist/SVGContextService.d.ts.map +1 -1
- package/dist/index.esm.js +139 -3
- package/dist/index.js +138 -2
- package/dist/index.umd.js +150 -13
- package/dist/index.umd.min.js +1 -1
- package/package.json +5 -5
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { CanvasContext, DataURLOptions, GlobalRuntime, ContextService } from '@antv/g-lite';
|
|
2
2
|
export declare class SVGContextService implements ContextService<SVGElement> {
|
|
3
|
+
context: GlobalRuntime & CanvasContext;
|
|
3
4
|
private $container;
|
|
4
5
|
private $namespace;
|
|
5
6
|
private dpr;
|
|
@@ -13,6 +14,7 @@ export declare class SVGContextService implements ContextService<SVGElement> {
|
|
|
13
14
|
destroy(): void;
|
|
14
15
|
resize(width: number, height: number): void;
|
|
15
16
|
applyCursorStyle(cursor: string): void;
|
|
17
|
+
private generateCSSText;
|
|
16
18
|
toDataURL(options?: Partial<DataURLOptions>): Promise<string>;
|
|
17
19
|
}
|
|
18
20
|
//# sourceMappingURL=SVGContextService.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SVGContextService.d.ts","sourceRoot":"","sources":["../src/SVGContextService.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,cAAc,EACd,aAAa,EAEb,cAAc,
|
|
1
|
+
{"version":3,"file":"SVGContextService.d.ts","sourceRoot":"","sources":["../src/SVGContextService.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,cAAc,EACd,aAAa,EAEb,cAAc,EAEf,MAAM,cAAc,CAAC;AAKtB,qBAAa,iBAAkB,YAAW,cAAc,CAAC,UAAU,CAAC;IAO/C,OAAO,EAAE,aAAa,GAAG,aAAa;IANzD,OAAO,CAAC,UAAU,CAAqB;IACvC,OAAO,CAAC,UAAU,CAAoB;IACtC,OAAO,CAAC,GAAG,CAAS;IAEpB,OAAO,CAAC,YAAY,CAAwB;gBAEzB,OAAO,EAAE,aAAa,GAAG,aAAa;IAInD,IAAI;IA2BV,aAAa;IAIb,UAAU;IAIV,MAAM;IAIN,qBAAqB;IAIrB,OAAO;IAOP,MAAM,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM;IAQpC,gBAAgB,CAAC,MAAM,EAAE,MAAM;IAM/B,OAAO,CAAC,eAAe;IA8BjB,SAAS,CAAC,OAAO,GAAE,OAAO,CAAC,cAAc,CAAM;CAgItD"}
|
package/dist/index.esm.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isBrowser, AbstractRendererPlugin, AbstractRenderer } from '@antv/g-lite';
|
|
1
|
+
import { propertyMetadataCache, isBrowser, AbstractRendererPlugin, AbstractRenderer } from '@antv/g-lite';
|
|
2
2
|
import { Plugin as Plugin$1 } from '@antv/g-plugin-dom-interaction';
|
|
3
3
|
import * as DomInteraction from '@antv/g-plugin-dom-interaction';
|
|
4
4
|
export { DomInteraction };
|
|
@@ -353,13 +353,31 @@ function _setPrototypeOf(o, p) {
|
|
|
353
353
|
};
|
|
354
354
|
return _setPrototypeOf(o, p);
|
|
355
355
|
}
|
|
356
|
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
357
|
+
if (source == null) return {};
|
|
358
|
+
var target = {};
|
|
359
|
+
var sourceKeys = Object.keys(source);
|
|
360
|
+
var key, i;
|
|
361
|
+
for (i = 0; i < sourceKeys.length; i++) {
|
|
362
|
+
key = sourceKeys[i];
|
|
363
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
364
|
+
target[key] = source[key];
|
|
365
|
+
}
|
|
366
|
+
return target;
|
|
367
|
+
}
|
|
356
368
|
|
|
369
|
+
var _excluded = ["offset", "composite", "computedOffset", "easing"],
|
|
370
|
+
_excluded2 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
371
|
+
_excluded3 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
372
|
+
_excluded4 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"];
|
|
357
373
|
var SVGContextService = /*#__PURE__*/function () {
|
|
358
374
|
function SVGContextService(context) {
|
|
375
|
+
this.context = void 0;
|
|
359
376
|
this.$container = void 0;
|
|
360
377
|
this.$namespace = void 0;
|
|
361
378
|
this.dpr = void 0;
|
|
362
379
|
this.canvasConfig = void 0;
|
|
380
|
+
this.context = context;
|
|
363
381
|
this.canvasConfig = context.config;
|
|
364
382
|
}
|
|
365
383
|
var _proto = SVGContextService.prototype;
|
|
@@ -430,19 +448,137 @@ var SVGContextService = /*#__PURE__*/function () {
|
|
|
430
448
|
this.$container.style.cursor = cursor;
|
|
431
449
|
}
|
|
432
450
|
};
|
|
451
|
+
_proto.generateCSSText = function generateCSSText(animationName, selector, keyframes, timing, prefixes) {
|
|
452
|
+
if (prefixes === void 0) {
|
|
453
|
+
prefixes = {};
|
|
454
|
+
}
|
|
455
|
+
var duration = timing.duration,
|
|
456
|
+
easing = timing.easing,
|
|
457
|
+
delay = timing.delay,
|
|
458
|
+
direction = timing.direction,
|
|
459
|
+
iterations = timing.iterations,
|
|
460
|
+
fill = timing.fill;
|
|
461
|
+
return "@keyframes " + animationName + "{" + keyframes.map(function (keyframe) {
|
|
462
|
+
var offset = keyframe.offset,
|
|
463
|
+
composite = keyframe.composite,
|
|
464
|
+
computedOffset = keyframe.computedOffset,
|
|
465
|
+
easing = keyframe.easing,
|
|
466
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded);
|
|
467
|
+
var rules = Object.keys(rest).map(function (attributeName) {
|
|
468
|
+
return attributeName + ":" + (prefixes[attributeName] || '') + rest[attributeName] + ";";
|
|
469
|
+
}).join('');
|
|
470
|
+
return computedOffset * 100 + "%{" + rules + "}";
|
|
471
|
+
}).join('') + "}" + (selector + " {animation: " + animationName + " " + duration + "ms " + easing + " " + delay + "ms " + (iterations === Infinity ? 'infinite' : iterations) + " " + direction + " " + fill + ";}");
|
|
472
|
+
};
|
|
433
473
|
_proto.toDataURL = /*#__PURE__*/function () {
|
|
434
474
|
var _toDataURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(options) {
|
|
435
|
-
var
|
|
475
|
+
var _this = this;
|
|
476
|
+
var cloneNode, doc, animationCounter, $style, svgDocType, svgDoc;
|
|
436
477
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
437
478
|
while (1) {
|
|
438
479
|
switch (_context2.prev = _context2.next) {
|
|
439
480
|
case 0:
|
|
440
481
|
cloneNode = this.$namespace.cloneNode(true);
|
|
482
|
+
doc = this.canvasConfig.document;
|
|
483
|
+
animationCounter = 0;
|
|
484
|
+
$style = null;
|
|
485
|
+
this.context.renderingContext.root.forEach(function (object) {
|
|
486
|
+
var animations = object.getAnimations();
|
|
487
|
+
if (animations.length) {
|
|
488
|
+
if (!$style) {
|
|
489
|
+
// export animations to <style>, using CSS Transformation
|
|
490
|
+
$style = (doc || document).createElement('style');
|
|
491
|
+
cloneNode.appendChild($style);
|
|
492
|
+
}
|
|
493
|
+
// @ts-ignore
|
|
494
|
+
var svgElement = object.elementSVG;
|
|
495
|
+
var selfSelector = "#" + svgElement.$el.id;
|
|
496
|
+
var groupSelector = "#" + svgElement.$groupEl.id;
|
|
497
|
+
var selfCssText = '';
|
|
498
|
+
var groupCssText = '';
|
|
499
|
+
animations.forEach(function (animation) {
|
|
500
|
+
var keyframes = animation.effect.getKeyframes();
|
|
501
|
+
// split attributes into self and group
|
|
502
|
+
if (keyframes.length) {
|
|
503
|
+
var selfAttributes = [];
|
|
504
|
+
var groupAttributes = [];
|
|
505
|
+
var _keyframes$ = keyframes[0],
|
|
506
|
+
offset = _keyframes$.offset,
|
|
507
|
+
composite = _keyframes$.composite,
|
|
508
|
+
computedOffset = _keyframes$.computedOffset,
|
|
509
|
+
easing = _keyframes$.easing,
|
|
510
|
+
transformOrigin = _keyframes$.transformOrigin,
|
|
511
|
+
rest = _objectWithoutPropertiesLoose(_keyframes$, _excluded2);
|
|
512
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
513
|
+
var _propertyMetadataCach;
|
|
514
|
+
if (attributeName === 'transform') {
|
|
515
|
+
groupAttributes.push(attributeName);
|
|
516
|
+
}
|
|
517
|
+
var inherited = !!((_propertyMetadataCach = propertyMetadataCache[attributeName]) === null || _propertyMetadataCach === void 0 ? void 0 : _propertyMetadataCach.inh);
|
|
518
|
+
if (inherited) {
|
|
519
|
+
groupAttributes.push(attributeName);
|
|
520
|
+
} else if (attributeName !== 'transform') {
|
|
521
|
+
selfAttributes.push(attributeName);
|
|
522
|
+
}
|
|
523
|
+
});
|
|
524
|
+
if (groupAttributes.length) {
|
|
525
|
+
var keyframesWithGroup = keyframes.map(function (keyframe) {
|
|
526
|
+
var offset = keyframe.offset,
|
|
527
|
+
composite = keyframe.composite,
|
|
528
|
+
computedOffset = keyframe.computedOffset,
|
|
529
|
+
easing = keyframe.easing,
|
|
530
|
+
transformOrigin = keyframe.transformOrigin,
|
|
531
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded3);
|
|
532
|
+
var ret = {
|
|
533
|
+
offset: offset,
|
|
534
|
+
composite: composite,
|
|
535
|
+
computedOffset: computedOffset,
|
|
536
|
+
easing: easing
|
|
537
|
+
};
|
|
538
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
539
|
+
if (groupAttributes.includes(attributeName)) {
|
|
540
|
+
ret[attributeName] = keyframe[attributeName];
|
|
541
|
+
}
|
|
542
|
+
});
|
|
543
|
+
return ret;
|
|
544
|
+
});
|
|
545
|
+
groupCssText += _this.generateCSSText("a" + animationCounter++, groupSelector, keyframesWithGroup, animation.effect.getComputedTiming(), {
|
|
546
|
+
transform: svgElement.$groupEl.getAttribute('transform')
|
|
547
|
+
});
|
|
548
|
+
}
|
|
549
|
+
if (selfAttributes.length) {
|
|
550
|
+
var keyframesWithSelf = keyframes.map(function (keyframe) {
|
|
551
|
+
var offset = keyframe.offset,
|
|
552
|
+
composite = keyframe.composite,
|
|
553
|
+
computedOffset = keyframe.computedOffset,
|
|
554
|
+
easing = keyframe.easing,
|
|
555
|
+
transformOrigin = keyframe.transformOrigin,
|
|
556
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded4);
|
|
557
|
+
var ret = {
|
|
558
|
+
offset: offset,
|
|
559
|
+
composite: composite,
|
|
560
|
+
computedOffset: computedOffset,
|
|
561
|
+
easing: easing
|
|
562
|
+
};
|
|
563
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
564
|
+
if (selfAttributes.includes(attributeName)) {
|
|
565
|
+
ret[attributeName] = keyframe[attributeName];
|
|
566
|
+
}
|
|
567
|
+
});
|
|
568
|
+
return ret;
|
|
569
|
+
});
|
|
570
|
+
selfCssText += _this.generateCSSText("a" + animationCounter++, selfSelector, keyframesWithSelf, animation.effect.getComputedTiming());
|
|
571
|
+
}
|
|
572
|
+
}
|
|
573
|
+
});
|
|
574
|
+
$style.textContent += selfCssText + groupCssText;
|
|
575
|
+
}
|
|
576
|
+
});
|
|
441
577
|
svgDocType = document.implementation.createDocumentType('svg', '-//W3C//DTD SVG 1.1//EN', 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd');
|
|
442
578
|
svgDoc = document.implementation.createDocument('http://www.w3.org/2000/svg', 'svg', svgDocType);
|
|
443
579
|
svgDoc.replaceChild(cloneNode, svgDoc.documentElement);
|
|
444
580
|
return _context2.abrupt("return", "data:image/svg+xml;charset=utf8," + encodeURIComponent(new XMLSerializer().serializeToString(svgDoc)));
|
|
445
|
-
case
|
|
581
|
+
case 10:
|
|
446
582
|
case "end":
|
|
447
583
|
return _context2.stop();
|
|
448
584
|
}
|
package/dist/index.js
CHANGED
|
@@ -375,13 +375,31 @@ function _setPrototypeOf(o, p) {
|
|
|
375
375
|
};
|
|
376
376
|
return _setPrototypeOf(o, p);
|
|
377
377
|
}
|
|
378
|
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
379
|
+
if (source == null) return {};
|
|
380
|
+
var target = {};
|
|
381
|
+
var sourceKeys = Object.keys(source);
|
|
382
|
+
var key, i;
|
|
383
|
+
for (i = 0; i < sourceKeys.length; i++) {
|
|
384
|
+
key = sourceKeys[i];
|
|
385
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
386
|
+
target[key] = source[key];
|
|
387
|
+
}
|
|
388
|
+
return target;
|
|
389
|
+
}
|
|
378
390
|
|
|
391
|
+
var _excluded = ["offset", "composite", "computedOffset", "easing"],
|
|
392
|
+
_excluded2 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
393
|
+
_excluded3 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
394
|
+
_excluded4 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"];
|
|
379
395
|
var SVGContextService = /*#__PURE__*/function () {
|
|
380
396
|
function SVGContextService(context) {
|
|
397
|
+
this.context = void 0;
|
|
381
398
|
this.$container = void 0;
|
|
382
399
|
this.$namespace = void 0;
|
|
383
400
|
this.dpr = void 0;
|
|
384
401
|
this.canvasConfig = void 0;
|
|
402
|
+
this.context = context;
|
|
385
403
|
this.canvasConfig = context.config;
|
|
386
404
|
}
|
|
387
405
|
var _proto = SVGContextService.prototype;
|
|
@@ -452,19 +470,137 @@ var SVGContextService = /*#__PURE__*/function () {
|
|
|
452
470
|
this.$container.style.cursor = cursor;
|
|
453
471
|
}
|
|
454
472
|
};
|
|
473
|
+
_proto.generateCSSText = function generateCSSText(animationName, selector, keyframes, timing, prefixes) {
|
|
474
|
+
if (prefixes === void 0) {
|
|
475
|
+
prefixes = {};
|
|
476
|
+
}
|
|
477
|
+
var duration = timing.duration,
|
|
478
|
+
easing = timing.easing,
|
|
479
|
+
delay = timing.delay,
|
|
480
|
+
direction = timing.direction,
|
|
481
|
+
iterations = timing.iterations,
|
|
482
|
+
fill = timing.fill;
|
|
483
|
+
return "@keyframes " + animationName + "{" + keyframes.map(function (keyframe) {
|
|
484
|
+
var offset = keyframe.offset,
|
|
485
|
+
composite = keyframe.composite,
|
|
486
|
+
computedOffset = keyframe.computedOffset,
|
|
487
|
+
easing = keyframe.easing,
|
|
488
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded);
|
|
489
|
+
var rules = Object.keys(rest).map(function (attributeName) {
|
|
490
|
+
return attributeName + ":" + (prefixes[attributeName] || '') + rest[attributeName] + ";";
|
|
491
|
+
}).join('');
|
|
492
|
+
return computedOffset * 100 + "%{" + rules + "}";
|
|
493
|
+
}).join('') + "}" + (selector + " {animation: " + animationName + " " + duration + "ms " + easing + " " + delay + "ms " + (iterations === Infinity ? 'infinite' : iterations) + " " + direction + " " + fill + ";}");
|
|
494
|
+
};
|
|
455
495
|
_proto.toDataURL = /*#__PURE__*/function () {
|
|
456
496
|
var _toDataURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(options) {
|
|
457
|
-
var
|
|
497
|
+
var _this = this;
|
|
498
|
+
var cloneNode, doc, animationCounter, $style, svgDocType, svgDoc;
|
|
458
499
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
459
500
|
while (1) {
|
|
460
501
|
switch (_context2.prev = _context2.next) {
|
|
461
502
|
case 0:
|
|
462
503
|
cloneNode = this.$namespace.cloneNode(true);
|
|
504
|
+
doc = this.canvasConfig.document;
|
|
505
|
+
animationCounter = 0;
|
|
506
|
+
$style = null;
|
|
507
|
+
this.context.renderingContext.root.forEach(function (object) {
|
|
508
|
+
var animations = object.getAnimations();
|
|
509
|
+
if (animations.length) {
|
|
510
|
+
if (!$style) {
|
|
511
|
+
// export animations to <style>, using CSS Transformation
|
|
512
|
+
$style = (doc || document).createElement('style');
|
|
513
|
+
cloneNode.appendChild($style);
|
|
514
|
+
}
|
|
515
|
+
// @ts-ignore
|
|
516
|
+
var svgElement = object.elementSVG;
|
|
517
|
+
var selfSelector = "#" + svgElement.$el.id;
|
|
518
|
+
var groupSelector = "#" + svgElement.$groupEl.id;
|
|
519
|
+
var selfCssText = '';
|
|
520
|
+
var groupCssText = '';
|
|
521
|
+
animations.forEach(function (animation) {
|
|
522
|
+
var keyframes = animation.effect.getKeyframes();
|
|
523
|
+
// split attributes into self and group
|
|
524
|
+
if (keyframes.length) {
|
|
525
|
+
var selfAttributes = [];
|
|
526
|
+
var groupAttributes = [];
|
|
527
|
+
var _keyframes$ = keyframes[0],
|
|
528
|
+
offset = _keyframes$.offset,
|
|
529
|
+
composite = _keyframes$.composite,
|
|
530
|
+
computedOffset = _keyframes$.computedOffset,
|
|
531
|
+
easing = _keyframes$.easing,
|
|
532
|
+
transformOrigin = _keyframes$.transformOrigin,
|
|
533
|
+
rest = _objectWithoutPropertiesLoose(_keyframes$, _excluded2);
|
|
534
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
535
|
+
var _propertyMetadataCach;
|
|
536
|
+
if (attributeName === 'transform') {
|
|
537
|
+
groupAttributes.push(attributeName);
|
|
538
|
+
}
|
|
539
|
+
var inherited = !!((_propertyMetadataCach = gLite.propertyMetadataCache[attributeName]) === null || _propertyMetadataCach === void 0 ? void 0 : _propertyMetadataCach.inh);
|
|
540
|
+
if (inherited) {
|
|
541
|
+
groupAttributes.push(attributeName);
|
|
542
|
+
} else if (attributeName !== 'transform') {
|
|
543
|
+
selfAttributes.push(attributeName);
|
|
544
|
+
}
|
|
545
|
+
});
|
|
546
|
+
if (groupAttributes.length) {
|
|
547
|
+
var keyframesWithGroup = keyframes.map(function (keyframe) {
|
|
548
|
+
var offset = keyframe.offset,
|
|
549
|
+
composite = keyframe.composite,
|
|
550
|
+
computedOffset = keyframe.computedOffset,
|
|
551
|
+
easing = keyframe.easing,
|
|
552
|
+
transformOrigin = keyframe.transformOrigin,
|
|
553
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded3);
|
|
554
|
+
var ret = {
|
|
555
|
+
offset: offset,
|
|
556
|
+
composite: composite,
|
|
557
|
+
computedOffset: computedOffset,
|
|
558
|
+
easing: easing
|
|
559
|
+
};
|
|
560
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
561
|
+
if (groupAttributes.includes(attributeName)) {
|
|
562
|
+
ret[attributeName] = keyframe[attributeName];
|
|
563
|
+
}
|
|
564
|
+
});
|
|
565
|
+
return ret;
|
|
566
|
+
});
|
|
567
|
+
groupCssText += _this.generateCSSText("a" + animationCounter++, groupSelector, keyframesWithGroup, animation.effect.getComputedTiming(), {
|
|
568
|
+
transform: svgElement.$groupEl.getAttribute('transform')
|
|
569
|
+
});
|
|
570
|
+
}
|
|
571
|
+
if (selfAttributes.length) {
|
|
572
|
+
var keyframesWithSelf = keyframes.map(function (keyframe) {
|
|
573
|
+
var offset = keyframe.offset,
|
|
574
|
+
composite = keyframe.composite,
|
|
575
|
+
computedOffset = keyframe.computedOffset,
|
|
576
|
+
easing = keyframe.easing,
|
|
577
|
+
transformOrigin = keyframe.transformOrigin,
|
|
578
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded4);
|
|
579
|
+
var ret = {
|
|
580
|
+
offset: offset,
|
|
581
|
+
composite: composite,
|
|
582
|
+
computedOffset: computedOffset,
|
|
583
|
+
easing: easing
|
|
584
|
+
};
|
|
585
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
586
|
+
if (selfAttributes.includes(attributeName)) {
|
|
587
|
+
ret[attributeName] = keyframe[attributeName];
|
|
588
|
+
}
|
|
589
|
+
});
|
|
590
|
+
return ret;
|
|
591
|
+
});
|
|
592
|
+
selfCssText += _this.generateCSSText("a" + animationCounter++, selfSelector, keyframesWithSelf, animation.effect.getComputedTiming());
|
|
593
|
+
}
|
|
594
|
+
}
|
|
595
|
+
});
|
|
596
|
+
$style.textContent += selfCssText + groupCssText;
|
|
597
|
+
}
|
|
598
|
+
});
|
|
463
599
|
svgDocType = document.implementation.createDocumentType('svg', '-//W3C//DTD SVG 1.1//EN', 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd');
|
|
464
600
|
svgDoc = document.implementation.createDocument('http://www.w3.org/2000/svg', 'svg', svgDocType);
|
|
465
601
|
svgDoc.replaceChild(cloneNode, svgDoc.documentElement);
|
|
466
602
|
return _context2.abrupt("return", "data:image/svg+xml;charset=utf8," + encodeURIComponent(new XMLSerializer().serializeToString(svgDoc)));
|
|
467
|
-
case
|
|
603
|
+
case 10:
|
|
468
604
|
case "end":
|
|
469
605
|
return _context2.stop();
|
|
470
606
|
}
|
package/dist/index.umd.js
CHANGED
|
@@ -347,6 +347,18 @@
|
|
|
347
347
|
};
|
|
348
348
|
return _setPrototypeOf(o, p);
|
|
349
349
|
}
|
|
350
|
+
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
351
|
+
if (source == null) return {};
|
|
352
|
+
var target = {};
|
|
353
|
+
var sourceKeys = Object.keys(source);
|
|
354
|
+
var key, i;
|
|
355
|
+
for (i = 0; i < sourceKeys.length; i++) {
|
|
356
|
+
key = sourceKeys[i];
|
|
357
|
+
if (excluded.indexOf(key) >= 0) continue;
|
|
358
|
+
target[key] = source[key];
|
|
359
|
+
}
|
|
360
|
+
return target;
|
|
361
|
+
}
|
|
350
362
|
|
|
351
363
|
function _regeneratorRuntime$1() {
|
|
352
364
|
_regeneratorRuntime$1 = function _regeneratorRuntime() {
|
|
@@ -736,11 +748,11 @@
|
|
|
736
748
|
renderingService.hooks.pointerWheel.call(ev);
|
|
737
749
|
};
|
|
738
750
|
var addPointerEventListener = function addPointerEventListener($el) {
|
|
739
|
-
globalThis.document.addEventListener('pointermove', onPointerMove, true);
|
|
751
|
+
gLite.runtime.globalThis.document.addEventListener('pointermove', onPointerMove, true);
|
|
740
752
|
$el.addEventListener('pointerdown', onPointerDown, true);
|
|
741
753
|
$el.addEventListener('pointerleave', onPointerOut, true);
|
|
742
754
|
$el.addEventListener('pointerover', onPointerOver, true);
|
|
743
|
-
globalThis.addEventListener('pointerup', onPointerUp, true);
|
|
755
|
+
gLite.runtime.globalThis.addEventListener('pointerup', onPointerUp, true);
|
|
744
756
|
};
|
|
745
757
|
var addTouchEventListener = function addTouchEventListener($el) {
|
|
746
758
|
$el.addEventListener('touchstart', onPointerDown, true);
|
|
@@ -749,18 +761,18 @@
|
|
|
749
761
|
$el.addEventListener('touchcancel', onPointerCancel, true);
|
|
750
762
|
};
|
|
751
763
|
var addMouseEventListener = function addMouseEventListener($el) {
|
|
752
|
-
globalThis.document.addEventListener('mousemove', onPointerMove, true);
|
|
764
|
+
gLite.runtime.globalThis.document.addEventListener('mousemove', onPointerMove, true);
|
|
753
765
|
$el.addEventListener('mousedown', onPointerDown, true);
|
|
754
766
|
$el.addEventListener('mouseout', onPointerOut, true);
|
|
755
767
|
$el.addEventListener('mouseover', onPointerOver, true);
|
|
756
|
-
globalThis.addEventListener('mouseup', onPointerUp, true);
|
|
768
|
+
gLite.runtime.globalThis.addEventListener('mouseup', onPointerUp, true);
|
|
757
769
|
};
|
|
758
770
|
var removePointerEventListener = function removePointerEventListener($el) {
|
|
759
|
-
globalThis.document.removeEventListener('pointermove', onPointerMove, true);
|
|
771
|
+
gLite.runtime.globalThis.document.removeEventListener('pointermove', onPointerMove, true);
|
|
760
772
|
$el.removeEventListener('pointerdown', onPointerDown, true);
|
|
761
773
|
$el.removeEventListener('pointerleave', onPointerOut, true);
|
|
762
774
|
$el.removeEventListener('pointerover', onPointerOver, true);
|
|
763
|
-
globalThis.removeEventListener('pointerup', onPointerUp, true);
|
|
775
|
+
gLite.runtime.globalThis.removeEventListener('pointerup', onPointerUp, true);
|
|
764
776
|
};
|
|
765
777
|
var removeTouchEventListener = function removeTouchEventListener($el) {
|
|
766
778
|
$el.removeEventListener('touchstart', onPointerDown, true);
|
|
@@ -769,11 +781,11 @@
|
|
|
769
781
|
$el.removeEventListener('touchcancel', onPointerCancel, true);
|
|
770
782
|
};
|
|
771
783
|
var removeMouseEventListener = function removeMouseEventListener($el) {
|
|
772
|
-
globalThis.document.removeEventListener('mousemove', onPointerMove, true);
|
|
784
|
+
gLite.runtime.globalThis.document.removeEventListener('mousemove', onPointerMove, true);
|
|
773
785
|
$el.removeEventListener('mousedown', onPointerDown, true);
|
|
774
786
|
$el.removeEventListener('mouseout', onPointerOut, true);
|
|
775
787
|
$el.removeEventListener('mouseover', onPointerOver, true);
|
|
776
|
-
globalThis.removeEventListener('mouseup', onPointerUp, true);
|
|
788
|
+
gLite.runtime.globalThis.removeEventListener('mouseup', onPointerUp, true);
|
|
777
789
|
};
|
|
778
790
|
renderingService.hooks.init.tapPromise(DOMInteractionPlugin.tag, /*#__PURE__*/_asyncToGenerator$1( /*#__PURE__*/_regeneratorRuntime$1().mark(function _callee() {
|
|
779
791
|
var $el;
|
|
@@ -782,7 +794,7 @@
|
|
|
782
794
|
switch (_context.prev = _context.next) {
|
|
783
795
|
case 0:
|
|
784
796
|
$el = _this.context.contextService.getDomElement(); // @ts-ignore
|
|
785
|
-
if (globalThis.navigator.msPointerEnabled) {
|
|
797
|
+
if (gLite.runtime.globalThis.navigator.msPointerEnabled) {
|
|
786
798
|
// @ts-ignore
|
|
787
799
|
$el.style.msContentZooming = 'none';
|
|
788
800
|
// @ts-ignore
|
|
@@ -814,7 +826,7 @@
|
|
|
814
826
|
renderingService.hooks.destroy.tap(DOMInteractionPlugin.tag, function () {
|
|
815
827
|
var $el = _this.context.contextService.getDomElement();
|
|
816
828
|
// @ts-ignore
|
|
817
|
-
if (globalThis.navigator.msPointerEnabled) {
|
|
829
|
+
if (gLite.runtime.globalThis.navigator.msPointerEnabled) {
|
|
818
830
|
// @ts-ignore
|
|
819
831
|
$el.style.msContentZooming = '';
|
|
820
832
|
// @ts-ignore
|
|
@@ -2080,7 +2092,7 @@
|
|
|
2080
2092
|
});
|
|
2081
2093
|
};
|
|
2082
2094
|
_proto.getId = function getId(object) {
|
|
2083
|
-
return G_SVG_PREFIX + "-" + object.
|
|
2095
|
+
return G_SVG_PREFIX + "-" + object.entity;
|
|
2084
2096
|
};
|
|
2085
2097
|
_proto.reorderChildren = function reorderChildren(doc, $groupEl, children) {
|
|
2086
2098
|
// need to reorder parent's children
|
|
@@ -2252,6 +2264,7 @@
|
|
|
2252
2264
|
}
|
|
2253
2265
|
if (($el.hasAttribute('data-wrapgroup') || $el.nodeName !== 'g') && !noWrapWithGroup) {
|
|
2254
2266
|
$groupEl = createSVGElement('g', document);
|
|
2267
|
+
$groupEl.id = $el.id + '-g';
|
|
2255
2268
|
$groupEl.appendChild($el);
|
|
2256
2269
|
} else {
|
|
2257
2270
|
$groupEl = $el;
|
|
@@ -3847,12 +3860,18 @@
|
|
|
3847
3860
|
Plugin: Plugin$2
|
|
3848
3861
|
});
|
|
3849
3862
|
|
|
3863
|
+
var _excluded = ["offset", "composite", "computedOffset", "easing"],
|
|
3864
|
+
_excluded2 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
3865
|
+
_excluded3 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"],
|
|
3866
|
+
_excluded4 = ["offset", "composite", "computedOffset", "easing", "transformOrigin"];
|
|
3850
3867
|
var SVGContextService = /*#__PURE__*/function () {
|
|
3851
3868
|
function SVGContextService(context) {
|
|
3869
|
+
this.context = void 0;
|
|
3852
3870
|
this.$container = void 0;
|
|
3853
3871
|
this.$namespace = void 0;
|
|
3854
3872
|
this.dpr = void 0;
|
|
3855
3873
|
this.canvasConfig = void 0;
|
|
3874
|
+
this.context = context;
|
|
3856
3875
|
this.canvasConfig = context.config;
|
|
3857
3876
|
}
|
|
3858
3877
|
var _proto = SVGContextService.prototype;
|
|
@@ -3923,19 +3942,137 @@
|
|
|
3923
3942
|
this.$container.style.cursor = cursor;
|
|
3924
3943
|
}
|
|
3925
3944
|
};
|
|
3945
|
+
_proto.generateCSSText = function generateCSSText(animationName, selector, keyframes, timing, prefixes) {
|
|
3946
|
+
if (prefixes === void 0) {
|
|
3947
|
+
prefixes = {};
|
|
3948
|
+
}
|
|
3949
|
+
var duration = timing.duration,
|
|
3950
|
+
easing = timing.easing,
|
|
3951
|
+
delay = timing.delay,
|
|
3952
|
+
direction = timing.direction,
|
|
3953
|
+
iterations = timing.iterations,
|
|
3954
|
+
fill = timing.fill;
|
|
3955
|
+
return "@keyframes " + animationName + "{" + keyframes.map(function (keyframe) {
|
|
3956
|
+
var offset = keyframe.offset,
|
|
3957
|
+
composite = keyframe.composite,
|
|
3958
|
+
computedOffset = keyframe.computedOffset,
|
|
3959
|
+
easing = keyframe.easing,
|
|
3960
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded);
|
|
3961
|
+
var rules = Object.keys(rest).map(function (attributeName) {
|
|
3962
|
+
return attributeName + ":" + (prefixes[attributeName] || '') + rest[attributeName] + ";";
|
|
3963
|
+
}).join('');
|
|
3964
|
+
return computedOffset * 100 + "%{" + rules + "}";
|
|
3965
|
+
}).join('') + "}" + (selector + " {animation: " + animationName + " " + duration + "ms " + easing + " " + delay + "ms " + (iterations === Infinity ? 'infinite' : iterations) + " " + direction + " " + fill + ";}");
|
|
3966
|
+
};
|
|
3926
3967
|
_proto.toDataURL = /*#__PURE__*/function () {
|
|
3927
3968
|
var _toDataURL = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(options) {
|
|
3928
|
-
var
|
|
3969
|
+
var _this = this;
|
|
3970
|
+
var cloneNode, doc, animationCounter, $style, svgDocType, svgDoc;
|
|
3929
3971
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
3930
3972
|
while (1) {
|
|
3931
3973
|
switch (_context2.prev = _context2.next) {
|
|
3932
3974
|
case 0:
|
|
3933
3975
|
cloneNode = this.$namespace.cloneNode(true);
|
|
3976
|
+
doc = this.canvasConfig.document;
|
|
3977
|
+
animationCounter = 0;
|
|
3978
|
+
$style = null;
|
|
3979
|
+
this.context.renderingContext.root.forEach(function (object) {
|
|
3980
|
+
var animations = object.getAnimations();
|
|
3981
|
+
if (animations.length) {
|
|
3982
|
+
if (!$style) {
|
|
3983
|
+
// export animations to <style>, using CSS Transformation
|
|
3984
|
+
$style = (doc || document).createElement('style');
|
|
3985
|
+
cloneNode.appendChild($style);
|
|
3986
|
+
}
|
|
3987
|
+
// @ts-ignore
|
|
3988
|
+
var svgElement = object.elementSVG;
|
|
3989
|
+
var selfSelector = "#" + svgElement.$el.id;
|
|
3990
|
+
var groupSelector = "#" + svgElement.$groupEl.id;
|
|
3991
|
+
var selfCssText = '';
|
|
3992
|
+
var groupCssText = '';
|
|
3993
|
+
animations.forEach(function (animation) {
|
|
3994
|
+
var keyframes = animation.effect.getKeyframes();
|
|
3995
|
+
// split attributes into self and group
|
|
3996
|
+
if (keyframes.length) {
|
|
3997
|
+
var selfAttributes = [];
|
|
3998
|
+
var groupAttributes = [];
|
|
3999
|
+
var _keyframes$ = keyframes[0],
|
|
4000
|
+
offset = _keyframes$.offset,
|
|
4001
|
+
composite = _keyframes$.composite,
|
|
4002
|
+
computedOffset = _keyframes$.computedOffset,
|
|
4003
|
+
easing = _keyframes$.easing,
|
|
4004
|
+
transformOrigin = _keyframes$.transformOrigin,
|
|
4005
|
+
rest = _objectWithoutPropertiesLoose(_keyframes$, _excluded2);
|
|
4006
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
4007
|
+
var _propertyMetadataCach;
|
|
4008
|
+
if (attributeName === 'transform') {
|
|
4009
|
+
groupAttributes.push(attributeName);
|
|
4010
|
+
}
|
|
4011
|
+
var inherited = !!((_propertyMetadataCach = gLite.propertyMetadataCache[attributeName]) === null || _propertyMetadataCach === void 0 ? void 0 : _propertyMetadataCach.inh);
|
|
4012
|
+
if (inherited) {
|
|
4013
|
+
groupAttributes.push(attributeName);
|
|
4014
|
+
} else if (attributeName !== 'transform') {
|
|
4015
|
+
selfAttributes.push(attributeName);
|
|
4016
|
+
}
|
|
4017
|
+
});
|
|
4018
|
+
if (groupAttributes.length) {
|
|
4019
|
+
var keyframesWithGroup = keyframes.map(function (keyframe) {
|
|
4020
|
+
var offset = keyframe.offset,
|
|
4021
|
+
composite = keyframe.composite,
|
|
4022
|
+
computedOffset = keyframe.computedOffset,
|
|
4023
|
+
easing = keyframe.easing,
|
|
4024
|
+
transformOrigin = keyframe.transformOrigin,
|
|
4025
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded3);
|
|
4026
|
+
var ret = {
|
|
4027
|
+
offset: offset,
|
|
4028
|
+
composite: composite,
|
|
4029
|
+
computedOffset: computedOffset,
|
|
4030
|
+
easing: easing
|
|
4031
|
+
};
|
|
4032
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
4033
|
+
if (groupAttributes.includes(attributeName)) {
|
|
4034
|
+
ret[attributeName] = keyframe[attributeName];
|
|
4035
|
+
}
|
|
4036
|
+
});
|
|
4037
|
+
return ret;
|
|
4038
|
+
});
|
|
4039
|
+
groupCssText += _this.generateCSSText("a" + animationCounter++, groupSelector, keyframesWithGroup, animation.effect.getComputedTiming(), {
|
|
4040
|
+
transform: svgElement.$groupEl.getAttribute('transform')
|
|
4041
|
+
});
|
|
4042
|
+
}
|
|
4043
|
+
if (selfAttributes.length) {
|
|
4044
|
+
var keyframesWithSelf = keyframes.map(function (keyframe) {
|
|
4045
|
+
var offset = keyframe.offset,
|
|
4046
|
+
composite = keyframe.composite,
|
|
4047
|
+
computedOffset = keyframe.computedOffset,
|
|
4048
|
+
easing = keyframe.easing,
|
|
4049
|
+
transformOrigin = keyframe.transformOrigin,
|
|
4050
|
+
rest = _objectWithoutPropertiesLoose(keyframe, _excluded4);
|
|
4051
|
+
var ret = {
|
|
4052
|
+
offset: offset,
|
|
4053
|
+
composite: composite,
|
|
4054
|
+
computedOffset: computedOffset,
|
|
4055
|
+
easing: easing
|
|
4056
|
+
};
|
|
4057
|
+
Object.keys(rest).forEach(function (attributeName) {
|
|
4058
|
+
if (selfAttributes.includes(attributeName)) {
|
|
4059
|
+
ret[attributeName] = keyframe[attributeName];
|
|
4060
|
+
}
|
|
4061
|
+
});
|
|
4062
|
+
return ret;
|
|
4063
|
+
});
|
|
4064
|
+
selfCssText += _this.generateCSSText("a" + animationCounter++, selfSelector, keyframesWithSelf, animation.effect.getComputedTiming());
|
|
4065
|
+
}
|
|
4066
|
+
}
|
|
4067
|
+
});
|
|
4068
|
+
$style.textContent += selfCssText + groupCssText;
|
|
4069
|
+
}
|
|
4070
|
+
});
|
|
3934
4071
|
svgDocType = document.implementation.createDocumentType('svg', '-//W3C//DTD SVG 1.1//EN', 'http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd');
|
|
3935
4072
|
svgDoc = document.implementation.createDocument('http://www.w3.org/2000/svg', 'svg', svgDocType);
|
|
3936
4073
|
svgDoc.replaceChild(cloneNode, svgDoc.documentElement);
|
|
3937
4074
|
return _context2.abrupt("return", "data:image/svg+xml;charset=utf8," + encodeURIComponent(new XMLSerializer().serializeToString(svgDoc)));
|
|
3938
|
-
case
|
|
4075
|
+
case 10:
|
|
3939
4076
|
case "end":
|
|
3940
4077
|
return _context2.stop();
|
|
3941
4078
|
}
|
package/dist/index.umd.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@antv/g-lite")):"function"==typeof define&&define.amd?define(["exports","@antv/g-lite"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self).G=t.G||{},t.G.SVG={}),t.window.G)}(this,(function(t,e){"use strict";function r(){r=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var o=Object.create((e&&e.prototype instanceof d?e:d).prototype),a=new O(n||[]);return i(o,"_invoke",{value:x(t,r,a)}),o}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h={};function d(){}function p(){}function v(){}var m={};c(m,a,(function(){return this}));var y=Object.getPrototypeOf,g=y&&y(y(C([])));g&&g!==e&&n.call(g,a)&&(m=g);var b=v.prototype=d.prototype=Object.create(m);function w(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function r(i,o,a,u){var s=f(t[i],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var o;i(this,"_invoke",{value:function(t,n){function i(){return new e((function(e,i){r(t,n,e,i)}))}return o=o?o.then(i,i):i()}})}function x(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return k()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=A(a,r);if(u){if(u===h)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=f(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===h)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function A(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,A(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var i=f(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,h;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function L(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function C(t){if(t){var e=t[a];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,i=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=v,i(b,"constructor",{value:v,configurable:!0}),i(v,"constructor",{value:p,configurable:!0}),p.displayName=c(v,s,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,c(t,s,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},w(E.prototype),c(E.prototype,u,(function(){return this})),t.AsyncIterator=E,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new E(l(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(b),c(b,s,"Generator"),c(b,a,(function(){return this})),c(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=C,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(L),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(this.prev>=o.tryLoc){var u=n.call(o,"catchLoc"),s=n.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return r(o.catchLoc,!0);if(o.finallyLoc>this.prev)return r(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return r(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return r(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(this.prev>=i.tryLoc&&n.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),L(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;L(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:C(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},t}function n(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function i(t){return function(){var e=this,r=arguments;return new Promise((function(i,o){var a=t.apply(e,r);function u(t){n(a,i,o,u,s,"next",t)}function s(t){n(a,i,o,u,s,"throw",t)}u(void 0)}))}}function o(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,a(t,e)}function a(t,e){return a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},a(t,e)}function u(){u=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",s=i.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,i){var o=Object.create((e&&e.prototype instanceof d?e:d).prototype),a=new O(i||[]);return n(o,"_invoke",{value:x(t,r,a)}),o}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h={};function d(){}function p(){}function v(){}var m={};c(m,o,(function(){return this}));var y=Object.getPrototypeOf,g=y&&y(y(C([])));g&&g!==e&&r.call(g,o)&&(m=g);var b=v.prototype=d.prototype=Object.create(m);function w(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function i(n,o,a,u){var s=f(t[n],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&r.call(l,"__await")?e.resolve(l.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return k()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=A(a,r);if(u){if(u===h)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=f(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===h)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function A(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,A(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var i=f(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,h;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function L(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function C(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=v,n(b,"constructor",{value:v,configurable:!0}),n(v,"constructor",{value:p,configurable:!0}),p.displayName=c(v,s,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,c(t,s,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},w(E.prototype),c(E.prototype,a,(function(){return this})),t.AsyncIterator=E,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new E(l(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(b),c(b,s,"Generator"),c(b,o,(function(){return this})),c(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=C,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(L),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),L(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;L(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:C(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},t}function s(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function c(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){s(o,n,i,a,u,"next",t)}function u(t){s(o,n,i,a,u,"throw",t)}a(void 0)}))}}function l(t,e){return l=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},l(t,e)}var f=function(){function t(){this.context=void 0}return t.prototype.apply=function(e){var r=this,n=e.renderingService,i=e.renderingContext;this.context=e;var o=i.root.ownerDocument.defaultView,a=function(t){n.hooks.pointerMove.call(t)},s=function(t){n.hooks.pointerUp.call(t)},l=function(t){n.hooks.pointerDown.call(t)},f=function(t){n.hooks.pointerOver.call(t)},h=function(t){n.hooks.pointerOut.call(t)},d=function(t){n.hooks.pointerCancel.call(t)},p=function(t){n.hooks.pointerWheel.call(t)},v=function(t){globalThis.document.addEventListener("pointermove",a,!0),t.addEventListener("pointerdown",l,!0),t.addEventListener("pointerleave",h,!0),t.addEventListener("pointerover",f,!0),globalThis.addEventListener("pointerup",s,!0)},m=function(t){t.addEventListener("touchstart",l,!0),t.addEventListener("touchend",s,!0),t.addEventListener("touchmove",a,!0),t.addEventListener("touchcancel",d,!0)},y=function(t){globalThis.document.addEventListener("mousemove",a,!0),t.addEventListener("mousedown",l,!0),t.addEventListener("mouseout",h,!0),t.addEventListener("mouseover",f,!0),globalThis.addEventListener("mouseup",s,!0)};n.hooks.init.tapPromise(t.tag,c(u().mark((function t(){var e;return u().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:e=r.context.contextService.getDomElement(),globalThis.navigator.msPointerEnabled?(e.style.msContentZooming="none",e.style.msTouchAction="none"):o.supportsPointerEvents&&(e.style.touchAction="none"),o.supportsPointerEvents?v(e):y(e),o.supportsTouchEvents&&m(e),e.addEventListener("wheel",p,{passive:!0,capture:!0});case 5:case"end":return t.stop()}}),t)})))),n.hooks.destroy.tap(t.tag,(function(){var t=r.context.contextService.getDomElement();globalThis.navigator.msPointerEnabled?(t.style.msContentZooming="",t.style.msTouchAction=""):o.supportsPointerEvents&&(t.style.touchAction=""),o.supportsPointerEvents?function(t){globalThis.document.removeEventListener("pointermove",a,!0),t.removeEventListener("pointerdown",l,!0),t.removeEventListener("pointerleave",h,!0),t.removeEventListener("pointerover",f,!0),globalThis.removeEventListener("pointerup",s,!0)}(t):function(t){globalThis.document.removeEventListener("mousemove",a,!0),t.removeEventListener("mousedown",l,!0),t.removeEventListener("mouseout",h,!0),t.removeEventListener("mouseover",f,!0),globalThis.removeEventListener("mouseup",s,!0)}(t),o.supportsTouchEvents&&function(t){t.removeEventListener("touchstart",l,!0),t.removeEventListener("touchend",s,!0),t.removeEventListener("touchmove",a,!0),t.removeEventListener("touchcancel",d,!0)}(t),t.removeEventListener("wheel",p,!0)}))},t}();f.tag="DOMInteraction";var h=function(t){var e,r;function n(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="dom-interaction",e}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,l(e,r);var i=n.prototype;return i.init=function(){this.addRenderingPlugin(new f)},i.destroy=function(){this.removeAllRenderingPlugins()},n}(e.AbstractRendererPlugin),d=Object.freeze({__proto__:null,Plugin:h}),p="undefined"!=typeof Float32Array?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});var v=function(t){return null==t},m={}.toString,y=function(t){return e="String",m.call(t)==="[object "+e+"]";var e},g=function(t,e,r){if(r||2===arguments.length)for(var n,i=0,o=e.length;o>i;i++)!n&&i in e||(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return t.concat(n||Array.prototype.slice.call(e))},b=function(t,e,r){this.name=t,this.version=e,this.os=r,this.type="browser"},w=function(t){this.version=t,this.type="node",this.name="node",this.os=process.platform},E=function(t,e,r,n){this.name=t,this.version=e,this.os=r,this.bot=n,this.type="bot-device"},x=function(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null},A=function(){this.type="react-native",this.name="react-native",this.version=null,this.os=null},S=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,L=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/]],O=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function C(t){return t?k(t):"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product?new A:"undefined"!=typeof navigator?k(navigator.userAgent):"undefined"!=typeof process&&process.version?new w(process.version.slice(1)):null}function k(t){var e=function(t){return""!==t&&L.reduce((function(e,r){var n=r[0];if(e)return e;var i=r[1].exec(t);return!!i&&[n,i]}),!1)}(t);if(!e)return null;var r=e[0],n=e[1];if("searchbot"===r)return new x;var i=n[1]&&n[1].split(".").join("_").split("_").slice(0,3);i?3>i.length&&(i=g(g([],i,!0),function(t){for(var e=[],r=0;t>r;r++)e.push("0");return e}(3-i.length),!0)):i=[];var o=i.join("."),a=function(t){for(var e=0,r=O.length;r>e;e++){var n=O[e],i=n[0];if(n[1].exec(t))return i}return null}(t),u=S.exec(t);return u&&u[1]?new E(r,o,a,u[1]):new b(r,o,a)}function P(){P=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function c(t,e,r,i){var o=Object.create((e&&e.prototype instanceof h?e:h).prototype),a=new L(i||[]);return n(o,"_invoke",{value:E(t,r,a)}),o}function l(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function h(){}function d(){}function p(){}var v={};s(v,o,(function(){return this}));var m=Object.getPrototypeOf,y=m&&m(m(O([])));y&&y!==e&&r.call(y,o)&&(v=y);var g=p.prototype=h.prototype=Object.create(v);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){function i(n,o,a,u){var s=l(t[n],t,o);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==typeof f&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function E(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return C()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=x(a,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=l(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function x(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f;var i=l(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,f;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function O(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:C}}function C(){return{value:void 0,done:!0}}return d.prototype=p,n(g,"constructor",{value:p,configurable:!0}),n(p,"constructor",{value:d,configurable:!0}),d.displayName=s(p,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(w.prototype),s(w.prototype,a,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new w(c(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,u,"Generator"),s(g,o,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=O,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),S(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;S(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:O(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function T(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function G(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){T(o,n,i,a,u,"next",t)}function u(t){T(o,n,i,a,u,"throw",t)}a(void 0)}))}}function M(){return M=Object.assign?Object.assign.bind():function(t){for(var e=1;arguments.length>e;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},M.apply(this,arguments)}function _(t,e){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},_(t,e)}var N=function(){this.$el=void 0,this.$groupEl=void 0,this.$hitTestingEl=void 0};function j(t,e){var r=e.img,n=void 0===r?"":r,i=e.width,o=e.height;if(t.setAttribute("x","0"),t.setAttribute("y","0"),y(n))t.setAttribute("href",n);else if(n instanceof Image)i||t.setAttribute("width",""+n.width),o||t.setAttribute("height",""+n.height),t.setAttribute("href",n.src);else if(n instanceof HTMLElement&&y(n.nodeName)&&"CANVAS"===n.nodeName.toUpperCase())t.setAttribute("href",n.toDataURL());else if(n instanceof ImageData){var a=document.createElement("canvas");a.setAttribute("width",""+n.width),a.setAttribute("height",""+n.height);var u=a.getContext("2d");u&&(u.putImageData(n,0,0),i||t.setAttribute("width",""+n.width),o||t.setAttribute("height",""+n.height),t.setAttribute("href",a.toDataURL()))}}function $(t,r){var n=r.x1,i=r.y1,o=r.x2,a=r.y2,u=r.defX,s=void 0===u?0:u,c=r.defY,l=void 0===c?0:c,f=r.markerStart,h=r.markerEnd,d=r.markerStartOffset,p=r.markerEndOffset,v=0,m=0,y=0,g=0,b=0;f&&f instanceof e.DisplayObject&&d&&(v=Math.cos(b=Math.atan2(a-i,o-n))*(d||0),m=Math.sin(b)*(d||0)),h&&h instanceof e.DisplayObject&&p&&(y=Math.cos(b=Math.atan2(i-a,n-o))*(p||0),g=Math.sin(b)*(p||0)),t.setAttribute("x1",""+(n-s+v)),t.setAttribute("y1",""+(i-l+m)),t.setAttribute("x2",""+(o-s+y)),t.setAttribute("y2",""+(a-l+g))}function D(t,r){var n=r.path,i=r.defX,o=void 0===i?0:i,a=r.defY,u=void 0===a?0:a,s=r.markerStart,c=r.markerEnd,l=r.markerStartOffset,f=r.markerEndOffset,h=0,d=0,p=0,v=0,m=0;if(s&&s instanceof e.DisplayObject&&l){var y=s.parentNode.getStartTangent(),g=y[0],b=y[1];h=Math.cos(m=Math.atan2(g[1]-b[1],g[0]-b[0]))*(l||0),d=Math.sin(m)*(l||0)}if(c&&c instanceof e.DisplayObject&&f){var w=c.parentNode.getEndTangent(),E=w[0],x=w[1];p=Math.cos(m=Math.atan2(E[1]-x[1],E[0]-x[0]))*(f||0),v=Math.sin(m)*(f||0)}t.setAttribute("d",e.translatePathToString(n.absolutePath,o,u,h,d,p,v))}function I(t,r){var n=r.points.points,i=r.defX,o=void 0===i?0:i,a=r.defY,u=void 0===a?0:a,s=r.markerStart,c=r.markerStartOffset,l=r.markerEnd,f=r.markerEndOffset,h=n.length;if(n&&h>=2){var d=0,p=0,v=0,m=0,y=0;s&&s instanceof e.DisplayObject&&c&&(d=Math.cos(y=Math.atan2(n[1][1]-n[0][1],n[1][0]-n[0][0]))*(c||0),p=Math.sin(y)*(c||0)),l&&l instanceof e.DisplayObject&&f&&(v=Math.cos(y=Math.atan2(n[h-2][1]-n[h-1][1],n[h-2][0]-n[h-1][0]))*(f||0),m=Math.sin(y)*(f||0)),t.setAttribute("points",n.map((function(t,e){var r=0,n=0;return 0===e?(r=d,n=p):e===h-1&&(r=v,n=m),t[0]-o+r+","+(t[1]-u+n)})).join(" "))}}function V(t,e){var r=e.radius,n=e.width,i=e.height;if(isFinite(n)&&isFinite(i)){var o="";if(r&&r.some((function(t){return 0!==t}))){var a=r.map((function(t){return e=t,r=0,o=Math.min(Math.abs(n)/2,Math.abs(i)/2),r>e?r:e>o?o:e;var e,r,o})),u=a[0],s=a[1],c=a[2],l=a[3],f=n>0?1:-1,h=i>0?1:-1,d=f+h!==0?1:0;o=[["M "+f*u+",0"],["l "+(n-f*(u+s))+",0"],["a "+s+","+s+",0,0,"+d+","+f*s+","+h*s],["l 0,"+(i-h*(s+c))],["a "+c+","+c+",0,0,"+d+","+-f*c+","+h*c],["l "+(f*(c+l)-n)+",0"],["a "+l+","+l+",0,0,"+d+","+-f*l+","+-h*l],["l 0,"+(h*(l+u)-i)],["a "+u+","+u+",0,0,"+d+","+f*u+","+-h*u],["z"]].join(" ")}else o="M 0,0 l "+n+",0 l 0,"+i+" l"+-n+" 0 z";t.setAttribute("d",o)}}function R(t,e){return(e||document).createElementNS("http://www.w3.org/2000/svg",t)}function U(t){return t.toFixed(6).replace(".000000","")}function W(t){return t.replace(/[&|<|>|"|']/g,(function(t){return"&"===t?"&":"<"===t?"<":">"===t?">":'"'===t?""":"'"}))}N.tag="c-svg-element";var F={opacity:"opacity",fillStyle:"fill",fill:"fill",fillRule:"fill-rule",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",clipPath:"clip-path",textPath:"text-path",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",letterSpacing:"letter-spacing",startArrow:"marker-start",endArrow:"marker-end",class:"class",id:"id",preserveAspectRatio:"preserveAspectRatio",visibility:"visibility",anchor:"anchor",shadowColor:"flood-color",shadowBlur:"stdDeviation",shadowOffsetX:"dx",shadowOffsetY:"dy",filter:"filter",innerHTML:"innerHTML",textAlign:"text-anchor",pointerEvents:"pointer-events"},B={textAlign:{inherit:"inherit",left:"left",start:"left",center:"middle",right:"end",end:"end"}},H={textAlign:"inherit",lineCap:"butt",lineJoin:"miter",lineWidth:"1px",opacity:"1",fillOpacity:"1",fillRule:"nonzero",strokeOpacity:"1",strokeWidth:"0",strokeMiterLimit:"4",letterSpacing:"0",fontSize:"inherit",fontFamily:"inherit",pointerEvents:"auto"},Y="g-svg",X="clip-path-",z="text-path-",q=function(){function t(t,e,r){this.pluginOptions=void 0,this.defElementManager=void 0,this.context=void 0,this.$camera=void 0,this.renderQueue=[],this.dirtyAttributes=new WeakMap,this.pendingReorderQueue=new Set,this.clipPathUseMap=new WeakMap,this.pluginOptions=t,this.defElementManager=e,this.context=r}var r=t.prototype;return r.apply=function(r){var n=this,i=r.renderingService,o=r.renderingContext;this.context=r;var a=o.root.ownerDocument.defaultView,u=this.context.config.document,s=function(t){var e=t.target;if(n.clipPathUseMap.get(e)){var r=n.defElementManager.getDefElement().querySelector("#"+n.getId(e));r&&r.remove()}n.createSVGDom(u,e,n.$camera)},c=function(t){var e=t.target;n.defElementManager.clear(e.entity),n.clipPathUseMap.delete(e),n.removeSVGDom(e)},l=function(t){var e=t.target;if(e.elementSVG){var r=t.attrName,i=n.dirtyAttributes.get(e);i||(n.dirtyAttributes.set(e,[]),i=n.dirtyAttributes.get(e)),i.push(r)}},f=function(t){var r,i=t.target,o=null===(r=i.elementSVG)||void 0===r?void 0:r.$el,a=i.parsedStyle,u=a.fill,s=a.stroke;!u||u instanceof e.CSSRGB||n.defElementManager.createOrUpdateGradientAndPattern(i,o,u,"fill",n),!s||s instanceof e.CSSRGB||n.defElementManager.createOrUpdateGradientAndPattern(i,o,s,"stroke",n)};i.hooks.init.tapPromise(t.tag,G(P().mark((function t(){var r,i,o,u;return P().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:i=(r=n.context.config).background,o=r.document,n.defElementManager.init(),u=n.context.contextService.getContext(),i&&(u.style.background=i),u.setAttribute("color-interpolation-filters","sRGB"),n.$camera=R("g",o),n.$camera.id="g-svg-camera",n.applyTransform(n.$camera,n.context.camera.getOrthoMatrix()),u.appendChild(n.$camera),a.addEventListener(e.ElementEvent.MOUNTED,s),a.addEventListener(e.ElementEvent.UNMOUNTED,c),a.addEventListener(e.ElementEvent.ATTR_MODIFIED,l),a.addEventListener(e.ElementEvent.BOUNDS_CHANGED,f);case 13:case"end":return t.stop()}}),t)})))),i.hooks.destroy.tap(t.tag,(function(){a.removeEventListener(e.ElementEvent.MOUNTED,s),a.removeEventListener(e.ElementEvent.UNMOUNTED,c),a.removeEventListener(e.ElementEvent.ATTR_MODIFIED,l),a.removeEventListener(e.ElementEvent.BOUNDS_CHANGED,f)})),i.hooks.render.tap(t.tag,(function(t){n.renderQueue.push(t)})),i.hooks.beginFrame.tap(t.tag,(function(){var t=n.context.config.document;n.pendingReorderQueue.size&&(n.pendingReorderQueue.forEach((function(e){var r,i=((null==e?void 0:e.children)||[]).slice(),o=null==e||null===(r=e.elementSVG)||void 0===r?void 0:r.$groupEl;o&&n.reorderChildren(t||u,o,i||[])})),n.pendingReorderQueue.clear())})),i.hooks.endFrame.tap(t.tag,(function(){o.renderReasons.has(e.RenderReason.CAMERA_CHANGED)&&n.applyTransform(n.$camera,n.context.camera.getOrthoMatrix()),n.renderQueue.forEach((function(t){var e,r,i=null===(e=t.elementSVG)||void 0===e?void 0:e.$el,o=null===(r=t.elementSVG)||void 0===r?void 0:r.$groupEl;if(i&&o){var a=t.getLocalTransform();n.applyTransform(o,a);var s=n.clipPathUseMap.get(t);s&&s.length&&s.forEach((function(e){n.applyTransform(e,t.getWorldTransform())})),t.renderable.dirty=!1}var c=n.dirtyAttributes.get(t);c&&(c.forEach((function(e){if("zIndex"===e){var r,a,s=t.parentNode,c=null===(r=t.parentNode)||void 0===r||null===(a=r.elementSVG)||void 0===a?void 0:a.$groupEl,l=((null==s?void 0:s.children)||[]).slice();c&&n.reorderChildren(u,c,l)}else"increasedLineWidthForHitTesting"===e&&n.createOrUpdateHitArea(t,i,o);n.updateAttribute(t,[e])})),n.dirtyAttributes.delete(t))})),n.renderQueue=[]}))},r.getId=function(t){return"g-svg-"+t.nodeName+"-"+t.entity},r.reorderChildren=function(t,e,r){if(r.sort((function(t,e){return t.sortable.renderOrder-e.sortable.renderOrder})),r.length){var n=(t||document).createDocumentFragment();r.forEach((function(t){if(t.isConnected){var e=t.elementSVG.$groupEl;e&&n.appendChild(e)}})),e.appendChild(n)}},r.applyTransform=function(t,e){t.setAttribute("transform","matrix("+U(e[0])+","+U(e[1])+","+U(e[4])+","+U(e[5])+","+U(e[12])+","+U(e[13])+")")},r.applyAttributes=function(t){var r=t.elementSVG,n=null==r?void 0:r.$el;if(n&&(null==r?void 0:r.$groupEl)){var i=t.nodeName,o=t.attributes;n.setAttribute("fill","none"),i===e.Shape.IMAGE&&n.setAttribute("preserveAspectRatio","none"),this.updateAttribute(t,Object.keys(o))}},r.updateAttribute=function(t,r){var n=this,i=this.context.config.document,o=t.elementSVG,a=o.$el,u=o.$groupEl,s=o.$hitTestingEl,c=t.parsedStyle,l=t.computedStyle;r.some((function(e){return n.context.SVGElementLifeCycleContribution.shouldUpdateElementAttribute(t,e)}))&&a&&[a,s].forEach((function(r){r&&(n.context.SVGElementLifeCycleContribution.updateElementAttribute(t,r),t.nodeName!==e.Shape.TEXT&&n.updateAnchorWithTransform(t))})),r.forEach((function(r){var o,f,h=F[r],d=l[r],p=d&&""+d,v=(null===(o=B[r])||void 0===o?void 0:o[p])||p,m=c[r],y=!!(null===(f=e.propertyMetadataCache[r])||void 0===f?void 0:f.inh);h&&(t.nodeName===e.Shape.HTML&&("lineWidth"===r?a.style["border-width"]=(m||0)+"px":"lineDash"===r&&(a.style["border-style"]="dashed")),"fill"===r?t.nodeName===e.Shape.HTML?a.style.background=""+m:n.defElementManager.createOrUpdateGradientAndPattern(t,a,m,h,n):"stroke"===r?t.nodeName===e.Shape.HTML?(a.style["border-color"]=""+m,a.style["border-style"]="solid"):n.defElementManager.createOrUpdateGradientAndPattern(t,a,m,h,n):y&&h?"unset"!==p&&p!==H[r]?null==u||u.setAttribute(h,v):null==u||u.removeAttribute(h):"clipPath"===r?n.createOrUpdateClipOrTextPath(i,m,t):"textPath"===r?n.createOrUpdateClipOrTextPath(i,m,t,!0):"shadowType"===r||"shadowColor"===r||"shadowBlur"===r||"shadowOffsetX"===r||"shadowOffsetY"===r?n.defElementManager.createOrUpdateShadow(t,a,r):"filter"===r?n.defElementManager.createOrUpdateFilter(t,a,m):"innerHTML"===r?n.createOrUpdateInnerHTML(i,a,m):"anchor"===r?t.nodeName!==e.Shape.TEXT&&n.updateAnchorWithTransform(t):d&&[a,s].forEach((function(t){t&&h&&("unset"!==p&&p!==H[r]?t.setAttribute(h,v):t.removeAttribute(h))})))}))},r.createSVGDom=function(t,r,n,i){void 0===i&&(i=!1),r.elementSVG=new N;var o=r.elementSVG,a=this.context.SVGElementLifeCycleContribution.createElement(r);if(a){var u,s;r.nodeName===e.Shape.HTML&&(r.parsedStyle.$el=a),this.pluginOptions.outputSVGElementId&&(a.id=this.getId(r)),this.pluginOptions.outputSVGElementName&&r.name&&a.setAttribute("name",r.name),!a.hasAttribute("data-wrapgroup")&&"g"===a.nodeName||i?s=a:(s=R("g",t)).appendChild(a),o.$el=a,o.$groupEl=s,this.applyAttributes(r),this.createOrUpdateHitArea(r,a,s);var c=n||r.parentNode&&(null===(u=r.parentNode.elementSVG)||void 0===u?void 0:u.$groupEl);c&&(c.appendChild(s),this.pendingReorderQueue.add(r.parentNode))}},r.removeSVGDom=function(t){var e,r=null===(e=t.elementSVG)||void 0===e?void 0:e.$groupEl;r&&r.parentNode&&(r.parentNode.removeChild(r),this.context.SVGElementLifeCycleContribution.destroyElement(t,r))},r.createOrUpdateHitArea=function(t,e,r){var n=t.elementSVG,i=n.$hitTestingEl,o=t.parsedStyle.increasedLineWidthForHitTesting;if(o){if(!i){i=e.cloneNode(),this.pluginOptions.outputSVGElementId&&(i.id="g-svg-"+t.nodeName+"-hittesting-"+t.entity),["filter"].forEach((function(t){i.removeAttribute(t)}));var a="none"!==e.getAttribute("fill");i.setAttribute("fill",a?"transparent":"none"),i.setAttribute("stroke","transparent"),r.appendChild(i),n.$hitTestingEl=i}i.setAttribute("stroke-width",""+(o+t.parsedStyle.lineWidth))}else i&&(r.removeChild(i),n.$hitTestingEl=null)},r.createOrUpdateInnerHTML=function(t,e,r){var n=(t||document).createElement("div");"string"==typeof r?n.innerHTML=r:n.appendChild(r),e.innerHTML="",e.appendChild(n)},r.createOrUpdateClipOrTextPath=function(t,e,r,n){void 0===n&&(n=!1);var i,o=r.elementSVG.$groupEl,a=n?"g":"clipPath",u=n?"text-path":"clip-path";if(e){var s=(n?z:X)+e.entity+"-"+r.entity,c=this.defElementManager.getDefElement();if(!c.querySelector("#"+s)){var l;if(n)this.createSVGDom(t,e,null,!0),l=e.elementSVG.$el;else{if(!e.isConnected)c.querySelector("#"+this.getId(e))||this.createSVGDom(t,e,c,!0);l=R(a,t);var f=R("use",t);f.setAttribute("href","#"+e.elementSVG.$el.id),l.appendChild(f);var h=this.clipPathUseMap.get(e);h||(this.clipPathUseMap.set(e,[]),h=this.clipPathUseMap.get(e)),h.push(f),this.applyTransform(f,e.getWorldTransform());var d=function(t,e){var r=e[0],n=e[1],i=e[2],o=e[3],a=e[4],u=e[5],s=e[6],c=e[7],l=e[8],f=e[9],h=e[10],d=e[11],p=e[12],v=e[13],m=e[14],y=e[15],g=r*u-n*a,b=r*s-i*a,w=r*c-o*a,E=n*s-i*u,x=n*c-o*u,A=i*c-o*s,S=l*v-f*p,L=l*m-h*p,O=l*y-d*p,C=f*m-h*v,k=f*y-d*v,P=h*y-d*m,T=g*P-b*k+w*C+E*O-x*L+A*S;return T?(t[0]=(u*P-s*k+c*C)*(T=1/T),t[1]=(i*k-n*P-o*C)*T,t[2]=(v*A-m*x+y*E)*T,t[3]=(h*x-f*A-d*E)*T,t[4]=(s*O-a*P-c*L)*T,t[5]=(r*P-i*O+o*L)*T,t[6]=(m*w-p*A-y*b)*T,t[7]=(l*A-h*w+d*b)*T,t[8]=(a*k-u*O+c*S)*T,t[9]=(n*O-r*k-o*S)*T,t[10]=(p*x-v*w+y*g)*T,t[11]=(f*w-l*x-d*g)*T,t[12]=(u*L-a*C-s*S)*T,t[13]=(r*C-n*L+i*S)*T,t[14]=(v*b-p*E-m*g)*T,t[15]=(l*E-f*b+h*g)*T,t):null}((i=new p(16),p!=Float32Array&&(i[1]=0,i[2]=0,i[3]=0,i[4]=0,i[6]=0,i[7]=0,i[8]=0,i[9]=0,i[11]=0,i[12]=0,i[13]=0,i[14]=0),i[0]=1,i[5]=1,i[10]=1,i[15]=1,i),r.getWorldTransform());this.applyTransform(l,d)}l.id=s,c.appendChild(l)}this.applyAttributes(e),n||o.setAttribute(u,"url(#"+s+")")}else n||o.removeAttribute(u)},r.updateAnchorWithTransform=function(t){var r,n,i=t.getGeometryBounds(),o=i&&2*i.halfExtents[0]||0,a=i&&2*i.halfExtents[1]||0,u=(t.parsedStyle||{}).anchor;[null===(r=t.elementSVG)||void 0===r?void 0:r.$el,null===(n=t.elementSVG)||void 0===n?void 0:n.$hitTestingEl].forEach((function(r){if(r){var n=-u[0]*o,i=-u[1]*a;0===n&&0===i||r.setAttribute("transform","translate("+n+","+i+")"),t.nodeName!==e.Shape.CIRCLE&&t.nodeName!==e.Shape.ELLIPSE||(r.setAttribute("cx",""+o/2),r.setAttribute("cy",""+a/2))}}))},t}();q.tag="SVGRenderer";var Q,K,J={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"},Z={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"};function tt(t,e){var r=e.textBaseline,n=e.lineWidth,i=e.metrics,o=e.dx,a=e.dy,u=e.textPath,s=e.textPathSide,c=void 0===s?"left":s,l=e.textPathStartOffset,f=void 0===l?0:l,h=e.textDecorationLine,d=void 0===h?"":h,p=e.textDecorationColor,v=void 0===p?"":p,m=e.textDecorationStyle,y=void 0===m?"":m,g=C();g&&"firefox"===g.name?t.setAttribute("dominant-baseline",Z[r]||"alphabetic"):(t.setAttribute("dominant-baseline",Z[r]),t.setAttribute("alignment-baseline",J[r])),t.setAttribute("paint-order","stroke");var b=i.lines,w=i.lineHeight,E=i.height,x=b.length,A="";if(0===o&&0===a||(A+="transform:translate("+o+"px, "+a+"px);"),d&&"none"!==d&&(A+="text-decoration:"+d+" "+y+" "+v+";"),A&&t.setAttribute("style",A),1===x){var S=W(b[0]);if(t.setAttribute("dx",""+n/2),u){t.innerHTML="";var L=R("textPath",t.ownerDocument);L.setAttribute("href","#"+(z+u.entity)),"left"!==c&&L.setAttribute("side",c),0!==f&&L.setAttribute("startOffset",""+f),L.innerHTML=S,t.appendChild(L)}else t.innerHTML=S}else t.innerHTML=b.map((function(t,e){var i=0;return 0===e?"middle"===r?i=w/2-E/2:"top"===r||"hanging"===r?i=0:"bottom"!==r&&"alphabetic"!==r&&"ideographic"!==r||(i=-w*(x-1)):i=w,'<tspan x="0" dx="'+n/2+'" dy="'+i+'">'+W(t)+"</tspan>"})).join("")}var et=((Q={})[e.Shape.RECT]="path",Q[e.Shape.CIRCLE]="circle",Q[e.Shape.ELLIPSE]="ellipse",Q[e.Shape.IMAGE]="image",Q[e.Shape.GROUP]="g",Q[e.Shape.LINE]="line",Q[e.Shape.POLYLINE]="polyline",Q[e.Shape.POLYGON]="polygon",Q[e.Shape.TEXT]="text",Q[e.Shape.PATH]="path",Q[e.Shape.HTML]="foreignObject",Q),rt=((K={})[e.Shape.CIRCLE]=["r"],K[e.Shape.ELLIPSE]=["rx","ry"],K[e.Shape.RECT]=["width","height","radius"],K[e.Shape.IMAGE]=["img","width","height"],K[e.Shape.LINE]=["x1","y1","x2","y2","markerStart","markerEnd","markerStartOffset","markerEndOffset"],K[e.Shape.POLYLINE]=["points","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],K[e.Shape.POLYGON]=["points","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],K[e.Shape.PATH]=["path","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],K[e.Shape.TEXT]=["text","font","fontSize","fontFamily","fontStyle","fontWeight","fontVariant","lineHeight","letterSpacing","wordWrap","wordWrapWidth","maxLines","leading","textBaseline","textAlign","textTransform","textOverflow","textPath","textPathSide","textPathStartOffset","textDecorationLine","textDecorationColor","textDecorationStyle","dx","dy"],K),nt=function(){function t(t){this.context=void 0,this.context=t}var r=t.prototype;return r.createElement=function(t){return R(et[t.nodeName]||"g",this.context.config.document||document)},r.destroyElement=function(t,e){},r.shouldUpdateElementAttribute=function(t,e){return(rt[t.nodeName]||[]).indexOf(e)>-1},r.updateElementAttribute=function(t){var r=t.elementSVG.$el,n=t.parsedStyle;switch(t.nodeName){case e.Shape.IMAGE:j(r,n);break;case e.Shape.RECT:V(r,n);break;case e.Shape.LINE:$(r,n);break;case e.Shape.POLYGON:case e.Shape.POLYLINE:I(r,n);break;case e.Shape.PATH:D(r,n);break;case e.Shape.TEXT:tt(r,n)}},t}(),it="g-filter-";function ot(t,r,n,i,o){var a=it+n.entity,u=r.querySelectorAll("[name="+a+"]");if(u.length&&u.forEach((function(t){r.removeChild(t)})),0===o.length)null==i||i.removeAttribute("filter");else{var s=o.map((function(n,i){var o=n.name,u=n.params,s=R("filter",t);return s.setAttribute("filterUnits","userSpaceOnUse"),"blur"===o?function(t,e,r){var n=R("feGaussianBlur",t);n.setAttribute("in","SourceGraphic"),n.setAttribute("stdDeviation",""+r[0].value),e.appendChild(n)}(t,s,u):"brightness"===o?function(t,e,r){var n=at(r[0]);ut(t,e,{type:"linear",slope:n,intercept:0})}(t,s,u):"drop-shadow"===o?function(t,e,r){var n=r[0].value,i=r[1].value,o=r[2].value,a=r[3].formatted,u=R("feGaussianBlur",t);u.setAttribute("in","SourceAlpha"),u.setAttribute("stdDeviation",""+o),e.appendChild(u);var s=R("feOffset",t);s.setAttribute("dx",""+n),s.setAttribute("dy",""+i),s.setAttribute("result","offsetblur"),e.appendChild(s);var c=R("feFlood",t);c.setAttribute("flood-color",a),e.appendChild(c);var l=R("feComposite",t);l.setAttribute("in2","offsetblur"),l.setAttribute("operator","in"),e.appendChild(l);var f=R("feMerge",t);e.appendChild(f);var h=R("feMergeNode",t),d=R("feMergeNode",t);d.setAttribute("in","SourceGraphic"),f.appendChild(h),f.appendChild(d)}(t,s,u):"contrast"===o?function(t,e,r){var n=at(r[0]);ut(t,e,{type:"linear",slope:n,intercept:-.5*n+.5})}(t,s,u):"grayscale"===o?function(t,e,r){var n=at(r[0]);st(t,e,[.2126+.7874*(1-n),.7152-.7152*(1-n),.0722-.0722*(1-n),0,0,.2126-.2126*(1-n),.7152+.2848*(1-n),.0722-.0722*(1-n),0,0,.2126-.2126*(1-n),.7152-.7152*(1-n),.0722+.9278*(1-n),0,0,0,0,0,1,0])}(t,s,u):"sepia"===o?function(t,e,r){var n=at(r[0]);st(t,e,[.393+.607*(1-n),.769-.769*(1-n),.189-.189*(1-n),0,0,.349-.349*(1-n),.686+.314*(1-n),.168-.168*(1-n),0,0,.272-.272*(1-n),.534-.534*(1-n),.131+.869*(1-n),0,0,0,0,0,1,0])}(t,s,u):"saturate"===o?function(t,e,r){var n=at(r[0]),i=R("feColorMatrix",t);i.setAttribute("type","saturate"),i.setAttribute("values",""+n),e.appendChild(i)}(t,s,u):"hue-rotate"===o?function(t,r,n){var i=R("feColorMatrix",t);i.setAttribute("type","hueRotate"),i.setAttribute("values",""+n[0].to(e.UnitType.kDegrees).value),r.appendChild(i)}(t,s,u):"invert"===o&&function(t,e,r){var n=at(r[0]);ut(t,e,{type:"table",tableValues:n+" "+(1-n)})}(t,s,u),s.id=a+"-"+i,s.setAttribute("name",a),r.appendChild(s),s.id}));setTimeout((function(){null==i||i.setAttribute("filter",s.map((function(t){return"url(#"+t+")"})).join(" "))}))}}function at(t){return t.unit===e.UnitType.kPercentage?t.value/100:t.value}function ut(t,e,r){var n=r.type,i=r.slope,o=r.intercept,a=r.tableValues,u=R("feComponentTransfer",t);[R("feFuncR",t),R("feFuncG",t),R("feFuncB",t)].forEach((function(t){t.setAttribute("type",n),"table"===n?t.setAttribute("tableValues",""+a):(t.setAttribute("slope",""+i),t.setAttribute("intercept",""+o)),u.appendChild(t)})),e.appendChild(u)}function st(t,e,r){var n=R("feColorMatrix",t);n.setAttribute("type","matrix"),n.setAttribute("values",r.join(" ")),e.appendChild(n)}var ct={},lt=0;function ft(t,r,n,i,o,a,u,s){if(!o)return"";if(!(o instanceof e.CSSRGB)){if(e.isPattern(o)){var c=function(t,r,n,i,o,a){var u=ht(i);if(!r.querySelector("#"+u)){var s=i.image,c="";if(y(s)?c=s:e.isBrowser&&(s instanceof HTMLImageElement?c=s.src:s instanceof HTMLCanvasElement&&(c=s.toDataURL())),c){var l,f=R("image",t);f.setAttribute("href",c),o?l=o(c):e.isBrowser&&(l=new window.Image),c.match(/^data:/i)||(l.crossOrigin="Anonymous",f.setAttribute("crossorigin","anonymous")),l.src=c;var h=function(){var e=dt(t,r,n,i,u,l.width,l.height);r.appendChild(e),e.appendChild(f),f.setAttribute("x","0"),f.setAttribute("y","0"),f.setAttribute("width",""+l.width),f.setAttribute("height",""+l.height)};l.complete?h():l.onload=h}if(s instanceof e.Rect){var d=s.parsedStyle,p=dt(t,r,s,i,u,d.width,d.height);s.forEach((function(e){a.createSVGDom(t,e,null);var r=e.elementSVG,n=e.getLocalTransform();a.applyTransform(r.$groupEl,n)})),p.appendChild(s.elementSVG.$groupEl)}}return u}(t,r,n,o,u,s);return i.style[a]="url(#"+c+")",c}if(1===o.length){var l=pt(t,n,r,i,o[0]);return null==i||i.setAttribute(a,"url(#"+l+")"),l}var f=function(t,e,r,n,i){var o=it+e.entity+"-gradient",a=r.querySelector("#"+o);a||((a=R("filter",t)).setAttribute("filterUnits","userSpaceOnUse"),a.setAttribute("x","0%"),a.setAttribute("y","0%"),a.setAttribute("width","100%"),a.setAttribute("height","100%"),a.id=o,r.appendChild(a));var u=0;i.forEach((function(i,s){var c=pt(t,e,r,n,i),l=c+"_rect",f=R("rect",t);f.setAttribute("x","0"),f.setAttribute("y","0"),f.setAttribute("width","100%"),f.setAttribute("height","100%"),f.setAttribute("fill","url(#"+c+")"),f.id=l,r.appendChild(f);var h=R("feImage",t);if(h.setAttribute("href","#"+l),h.setAttribute("result",o+"-"+s),a.appendChild(h),s>0){var d=R("feBlend",t);d.setAttribute("in",1===s?o+"-"+(s-1):o+"-blended-"+(u-1)),d.setAttribute("in2",o+"-"+s),d.setAttribute("result",o+"-blended-"+u++),d.setAttribute("mode","multiply"),a.appendChild(d)}}));var s=R("feComposite",t);return s.setAttribute("in",o+"-blended-"+u),s.setAttribute("in2","SourceGraphic"),s.setAttribute("operator","in"),a.appendChild(s),o}(t,n,r,i,o);return null==i||i.setAttribute("filter","url(#"+f+")"),null==i||i.setAttribute("fill","black"),f}return"currentColor"===n.style[a]?null==i||i.setAttribute(a,"currentColor"):null==i||i.setAttribute(a,o.isNone?"none":""+o),""}function ht(t,r){void 0===r&&(r={});var n="";if(t instanceof e.CSSGradientValue){var i=t.type;if(i===e.GradientType.LinearGradient||i===e.GradientType.RadialGradient){var o=M({},t.value,r),a=o.angle,u=o.cx,s=o.cy,c=o.size;n="gradient-"+o.type+"-"+((null==a?void 0:""+a)||0)+"-"+((null==u?void 0:""+u)||0)+"-"+((null==s?void 0:""+s)||0)+"-"+((null==c?void 0:""+c)||0)+"-"+o.width+"-"+o.height+"-"+o.steps.map((function(t){return""+t.offset+t.color})).join("-")}}else e.isPattern(t)&&(n=y(t.image)?"pattern-"+t.image+"-"+t.repetition:t.image instanceof e.Rect?"pattern-rect-"+t.image.entity:"pattern-"+lt);return n&&(ct[n]||(ct[n]="g-pattern-"+lt++)),ct[n]}function dt(t,r,n,i,o,a,u){var s=i.repetition,c=i.transform,l=R("pattern",t);c&&l.setAttribute("patternTransform",function(t){return e.parseTransform(t).map((function(t){var e=t.t,r=t.d;if("translate"===e)return"translate("+r[0].value+" "+r[1].value+")";if("translatex"===e)return"translate("+r[0].value+" 0)";if("translatey"===e)return"translate(0 "+r[0].value+")";if("rotate"===e)return"rotate("+r[0].value+")";if("scale"===e){var n=(null==r?void 0:r.map((function(t){return t.value})))||[1,1];return"scale("+n[0]+", "+n[1]+")"}if("scalex"===e)return"scale("+((null==r?void 0:r.map((function(t){return t.value})))||[1])[0]+", 1)";if("scaley"===e)return"scale(1, "+((null==r?void 0:r.map((function(t){return t.value})))||[1])[0]+")";if("skew"===e){var i=(null==r?void 0:r.map((function(t){return t.value})))||[0,0];return"skewX("+i[0]+") skewY("+i[1]+")"}if("skewx"===e)return"skewX("+((null==r?void 0:r.map((function(t){return t.value})))||[0])[0]+")";if("skewy"===e)return"skewY("+((null==r?void 0:r.map((function(t){return t.value})))||[0])[0]+")";if("matrix"===e){var o=r.map((function(t){return t.value}));return"matrix("+o[0]+" "+o[1]+" "+o[2]+" "+o[3]+" "+o[4]+" "+o[5]+")"}})).join(" ")}(c)),l.setAttribute("patternUnits","userSpaceOnUse"),l.id=o,r.appendChild(l),l.setAttribute("x","0"),l.setAttribute("y","0");var f=n.getGeometryBounds().halfExtents,h=a,d=u;return"repeat-x"===s?d=2*f[1]:"repeat-y"===s?h=2*f[0]:"no-repeat"===s&&(h=2*f[0],d=2*f[1]),l.setAttribute("width",""+h),l.setAttribute("height",""+d),l}function pt(t,r,n,i,o){var a=r.getGeometryBounds(),u=a&&2*a.halfExtents[0]||0,s=a&&2*a.halfExtents[1]||0,c=ht(o,{width:u,height:s}),l=n.querySelector("#"+c);if(!l){(l=R(o.type===e.GradientType.LinearGradient?"linearGradient":"radialGradient",t)).setAttribute("gradientUnits","userSpaceOnUse");var f="";o.value.steps.sort((function(t,e){return t.offset.value-e.offset.value})).forEach((function(t){f+='<stop offset="'+t.offset.value/100+'" stop-color="'+t.color+'"></stop>'})),l.innerHTML=f,l.id=c,n.appendChild(l)}if(o.type===e.GradientType.LinearGradient){var h=e.computeLinearGradient(u,s,o.value.angle),d=h.y1,p=h.x2,v=h.y2;l.setAttribute("x1",""+h.x1),l.setAttribute("y1",""+d),l.setAttribute("x2",""+p),l.setAttribute("y2",""+v)}else{var m=o.value,y=e.computeRadialGradient(u,s,m.cx,m.cy,m.size),g=y.y,b=y.r;l.setAttribute("cx",""+y.x),l.setAttribute("cy",""+g),l.setAttribute("r",""+b)}return c}var vt=/url\("?#(.*)\)/,mt=function(){function t(t){this.context=void 0,this.$def=void 0,this.gradientCache={},this.context=t}var r=t.prototype;return r.getDefElement=function(){return this.$def},r.init=function(){var t=this.context.config.document,e=this.context.contextService.getContext();this.$def=R("defs",t),e.appendChild(this.$def)},r.clear=function(t){var e=this;Object.keys(this.gradientCache).forEach((function(r){e.clearUnusedDefElement(e.gradientCache,r,t)}))},r.clearUnusedDefElement=function(t,e,r){if(t[e]&&1===t[e].size&&t[e].has(r)){var n=this.$def.querySelector("#"+e);n&&this.$def.removeChild(n)}},r.createOrUpdateGradientAndPattern=function(t,r,n,i,o){var a=this.context.config,u=a.document,s=a.createImage;if(r){var c=(e.isPattern(n)?r.style[i]:r.getAttribute(i)||"").match(vt);c&&c.length>1&&this.clearUnusedDefElement(this.gradientCache,c[1].replace('"',""),t.entity);var l=ft(u||document,this.$def,t,r,n,i,s,o);l&&(this.gradientCache[l]||(this.gradientCache[l]=new Set),this.gradientCache[l].add(t.entity))}},r.createOrUpdateShadow=function(t,e,r){!function(t,e,r,n,i){var o=r.parsedStyle,a=o.shadowType,u=o.shadowBlur,s=o.shadowColor,c=o.shadowOffsetX,l=o.shadowOffsetY,f=!v(s)&&u>0,h="g-filter-dropshadow-"+r.entity,d=e.querySelector("#"+h);if(d&&(d.getAttribute("data-type")===a&&f||(d.remove(),d=null)),f){if(null==n||n.setAttribute("filter","url(#"+h+")"),!d){if((d=R("filter",t)).setAttribute("data-type",a),"outer"===a){var p=R("feDropShadow",t);p.setAttribute("dx",""+(c||0)/2),p.setAttribute("dy",""+(l||0)/2),p.setAttribute("stdDeviation",""+(u||0)/4),p.setAttribute("flood-color",""+s),d.appendChild(p)}else if("inner"===a){var m=R("feComponentTransfer",t);m.setAttribute("in","SourceAlpha");var y=R("feFuncA",t);y.setAttribute("type","table"),y.setAttribute("tableValues","1 0"),m.appendChild(y),d.appendChild(m);var g=R("feGaussianBlur",t);g.setAttribute("stdDeviation",""+(u||0)/4),d.appendChild(g);var b=R("feOffset",t);b.setAttribute("dx",""+(c||0)/2),b.setAttribute("dy",""+(l||0)/2),b.setAttribute("result","offsetblur"),d.appendChild(b);var w=R("feFlood",t);w.setAttribute("flood-color",""+s),w.setAttribute("result","color"),d.appendChild(w);var E=R("feComposite",t);E.setAttribute("in2","offsetblur"),E.setAttribute("operator","in"),d.appendChild(E);var x=R("feComposite",t);x.setAttribute("in2","SourceAlpha"),x.setAttribute("operator","in"),d.appendChild(x);var A=R("feMerge",t);d.appendChild(A);var S=R("feMergeNode",t);S.setAttribute("in","SourceGraphic");var L=R("feMergeNode",t);A.appendChild(S),A.appendChild(L)}return d.id=h,d.setAttribute("filterUnits","userSpaceOnUse"),void e.appendChild(d)}if("inner"===a){var O=d.children[1],C=d.children[2];"shadowColor"===i?d.children[3].setAttribute("flood-color",""+s):"shadowBlur"===i?O.setAttribute("stdDeviation",""+(u||0)/4):"shadowOffsetX"===i?C.setAttribute("dx",""+(c||0)/2):"shadowOffsetY"===i&&C.setAttribute("dy",""+(l||0)/2)}else if("outer"===a){var k=d.children[0];"shadowColor"===i?k.setAttribute("flood-color",""+s):"shadowBlur"===i?k.setAttribute("stdDeviation",""+(u||0)/4):"shadowOffsetX"===i?k.setAttribute("dx",""+(c||0)/2):"shadowOffsetY"===i&&k.setAttribute("dy",""+(l||0)/2)}}else null==n||n.removeAttribute("filter")}(this.context.config.document||document,this.$def,t,e,r)},r.createOrUpdateFilter=function(t,e,r){ot(this.context.config.document||document,this.$def,t,e,r)},t}(),yt=function(t){var e,r;function n(e){var r;return void 0===e&&(e={}),(r=t.call(this)||this).options=void 0,r.name="svg-renderer",r.options=e,r}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,_(e,r);var i=n.prototype;return i.init=function(){var t=this.options,e=t.outputSVGElementId,r=t.outputSVGElementName,n=new mt(this.context),i=new nt(this.context);this.context.defaultElementLifeCycleContribution=i,this.context.SVGElementLifeCycleContribution=i;var o={outputSVGElementId:!!v(e)||!!e,outputSVGElementName:!!v(r)||!!r};this.addRenderingPlugin(new q(o,n,this.context))},i.destroy=function(){this.removeAllRenderingPlugins(),delete this.context.defaultElementLifeCycleContribution,delete this.context.SVGElementLifeCycleContribution},n}(e.AbstractRendererPlugin),gt=Object.freeze({__proto__:null,CLIP_PATH_PREFIX:X,DEFAULT_VALUE_MAP:H,DefaultElementLifeCycleContribution:nt,ElementSVG:N,G_SVG_PREFIX:Y,Plugin:yt,SHAPE2TAGS:et,SHAPE_UPDATE_DEPS:rt,SVGRendererPlugin:q,SVG_ATTR_MAP:F,TEXT_PATH_PREFIX:z,createSVGElement:R,updateImageElementAttribute:j,updateLineElementAttribute:$,updatePathElementAttribute:D,updatePolylineElementAttribute:I,updateRectElementAttribute:V,updateTextElementAttribute:tt});function bt(){bt=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function c(t,e,r,i){var o=Object.create((e&&e.prototype instanceof h?e:h).prototype),a=new L(i||[]);return n(o,"_invoke",{value:E(t,r,a)}),o}function l(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function h(){}function d(){}function p(){}var v={};s(v,o,(function(){return this}));var m=Object.getPrototypeOf,y=m&&m(m(O([])));y&&y!==e&&r.call(y,o)&&(v=y);var g=p.prototype=h.prototype=Object.create(v);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){function i(n,o,a,u){var s=l(t[n],t,o);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==typeof f&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function E(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return C()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=x(a,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=l(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function x(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f;var i=l(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,f;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function O(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:C}}function C(){return{value:void 0,done:!0}}return d.prototype=p,n(g,"constructor",{value:p,configurable:!0}),n(p,"constructor",{value:d,configurable:!0}),d.displayName=s(p,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t},t.awrap=function(t){return{__await:t}},b(w.prototype),s(w.prototype,a,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new w(c(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(g),s(g,u,"Generator"),s(g,o,(function(){return this})),s(g,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=O,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),S(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;S(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:O(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function wt(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function Et(t,e){return Et=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},Et(t,e)}function xt(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);e>r;r++)n[r]=t[r];return n}function At(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return xt(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?xt(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return t.length>n?{done:!1,value:t[n++]}:{done:!0}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var St=function(){function t(){}var r=t.prototype;return r.apply=function(e){var r=this,n=e.config.document,i=e.renderingService;i.hooks.pick.tapPromise(t.tag,function(){var t,e=(t=bt().mark((function t(e){return bt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",r.pick(n,e));case 1:case"end":return t.stop()}}),t)})),function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){wt(o,n,i,a,u,"next",t)}function u(t){wt(o,n,i,a,u,"throw",t)}a(void 0)}))});return function(t){return e.apply(this,arguments)}}()),i.hooks.pickSync.tap(t.tag,(function(t){return r.pick(n,t)}))},r.pick=function(t,r){var n=r.topmost,i=r.position,o=i.clientX,a=i.clientY;try{for(var u,s=[],c=At((t||document).elementsFromPoint(o,a));!(u=c()).done;){var l=u.value,f=l&&l.getAttribute("id");if(f&&f.startsWith(Y)){var h=f.lastIndexOf("-"),d=e.runtime.displayObjectPool.getByEntity(f.substring(h+1));if(d&&d.isInteractive()&&(s.push(d),n))return r.picked=s,r}}r.picked=s}catch(t){r.picked=[]}return r},t}();St.tag="SVGPicker";var Lt=function(t){var e,r;function n(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="svg-picker",e}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,Et(e,r);var i=n.prototype;return i.init=function(){this.addRenderingPlugin(new St)},i.destroy=function(){this.removeAllRenderingPlugins()},n}(e.AbstractRendererPlugin),Ot=Object.freeze({__proto__:null,Plugin:Lt}),Ct=function(){function t(t){this.$container=void 0,this.$namespace=void 0,this.dpr=void 0,this.canvasConfig=void 0,this.canvasConfig=t.config}var n=t.prototype;return n.init=function(){var t=i(r().mark((function t(){var n,i,o,a,u,s;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:o=(n=this.canvasConfig).document,a=n.devicePixelRatio,this.$container=y(i=n.container)?(o||document).getElementById(i):i,this.$container&&(this.$container.style.position||(this.$container.style.position="relative"),(u=R("svg",o)).setAttribute("width",""+this.canvasConfig.width),u.setAttribute("height",""+this.canvasConfig.height),this.$container.appendChild(u),this.$namespace=u),s=a||e.isBrowser&&window.devicePixelRatio||1,this.dpr=s=1>s?1:Math.ceil(s);case 6:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}(),n.getDomElement=function(){return this.$namespace},n.getContext=function(){return this.$namespace},n.getDPR=function(){return this.dpr},n.getBoundingClientRect=function(){var t;return null===(t=this.$namespace)||void 0===t?void 0:t.getBoundingClientRect()},n.destroy=function(){this.$container&&this.$namespace&&this.$namespace.parentNode&&this.$container.removeChild(this.$namespace)},n.resize=function(t,e){this.$namespace&&(this.$namespace.setAttribute("width",""+t),this.$namespace.setAttribute("height",""+e))},n.applyCursorStyle=function(t){this.$container&&(this.$container.style.cursor=t)},n.toDataURL=function(){var t=i(r().mark((function t(e){var n,i,o;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=this.$namespace.cloneNode(!0),i=document.implementation.createDocumentType("svg","-//W3C//DTD SVG 1.1//EN","http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"),(o=document.implementation.createDocument("http://www.w3.org/2000/svg","svg",i)).replaceChild(n,o.documentElement),t.abrupt("return","data:image/svg+xml;charset=utf8,"+encodeURIComponent((new XMLSerializer).serializeToString(o)));case 6:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}(),t}(),kt=function(t){function e(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="svg-context-register",e}o(e,t);var r=e.prototype;return r.init=function(){this.context.ContextService=Ct},r.destroy=function(){delete this.context.ContextService},e}(e.AbstractRendererPlugin),Pt=function(t){function e(e){var r;return void 0===e&&(e={}),(r=t.call(this,e)||this).registerPlugin(new kt),r.registerPlugin(new yt({outputSVGElementId:e.outputSVGElementId})),r.registerPlugin(new h),r.registerPlugin(new Lt),r}return o(e,t),e}(e.AbstractRenderer);t.DomInteraction=d,t.Renderer=Pt,t.SVGPicker=Ot,t.SVGRenderer=gt,Object.defineProperty(t,"__esModule",{value:!0})}));
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports,require("@antv/g-lite")):"function"==typeof define&&define.amd?define(["exports","@antv/g-lite"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self).G=t.G||{},t.G.SVG={}),t.window.G)}(this,(function(t,e){"use strict";function r(){r=function(){return t};var t={},e=Object.prototype,n=e.hasOwnProperty,i=Object.defineProperty||function(t,e,r){t[e]=r.value},o="function"==typeof Symbol?Symbol:{},a=o.iterator||"@@iterator",u=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,n){var o=Object.create((e&&e.prototype instanceof d?e:d).prototype),a=new L(n||[]);return i(o,"_invoke",{value:x(t,r,a)}),o}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h={};function d(){}function p(){}function v(){}var m={};c(m,a,(function(){return this}));var g=Object.getPrototypeOf,y=g&&g(g(C([])));y&&y!==e&&n.call(y,a)&&(m=y);var b=v.prototype=d.prototype=Object.create(m);function w(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function r(i,o,a,u){var s=f(t[i],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,u)}),(function(t){r("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return r("throw",t,a,u)}))}u(s.arg)}var o;i(this,"_invoke",{value:function(t,n){function i(){return new e((function(e,i){r(t,n,e,i)}))}return o=o?o.then(i,i):i()}})}function x(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return k()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=A(a,r);if(u){if(u===h)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=f(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===h)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function A(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,A(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var i=f(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,h;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function O(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function C(t){if(t){var e=t[a];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var r=-1,i=function e(){for(;++r<t.length;)if(n.call(t,r))return e.value=t[r],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=v,i(b,"constructor",{value:v,configurable:!0}),i(v,"constructor",{value:p,configurable:!0}),p.displayName=c(v,s,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,c(t,s,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},w(E.prototype),c(E.prototype,u,(function(){return this})),t.AsyncIterator=E,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new E(l(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(b),c(b,s,"Generator"),c(b,a,(function(){return this})),c(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=C,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!t)for(var e in this)"t"===e.charAt(0)&&n.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function r(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return r("end");if(this.prev>=o.tryLoc){var u=n.call(o,"catchLoc"),s=n.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return r(o.catchLoc,!0);if(o.finallyLoc>this.prev)return r(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return r(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return r(o.finallyLoc)}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var i=this.tryEntries[r];if(this.prev>=i.tryLoc&&n.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),O(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;O(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:C(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},t}function n(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function i(t){return function(){var e=this,r=arguments;return new Promise((function(i,o){var a=t.apply(e,r);function u(t){n(a,i,o,u,s,"next",t)}function s(t){n(a,i,o,u,s,"throw",t)}u(void 0)}))}}function o(t,e){t.prototype=Object.create(e.prototype),t.prototype.constructor=t,a(t,e)}function a(t,e){return a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},a(t,e)}function u(t,e){if(null==t)return{};var r,n,i={},o=Object.keys(t);for(n=0;o.length>n;n++)0>e.indexOf(r=o[n])&&(i[r]=t[r]);return i}function s(){s=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(t){c=function(t,e,r){return t[e]=r}}function l(t,e,r,i){var o=Object.create((e&&e.prototype instanceof d?e:d).prototype),a=new L(i||[]);return n(o,"_invoke",{value:x(t,r,a)}),o}function f(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=l;var h={};function d(){}function p(){}function v(){}var m={};c(m,o,(function(){return this}));var g=Object.getPrototypeOf,y=g&&g(g(C([])));y&&y!==e&&r.call(y,o)&&(m=y);var b=v.prototype=d.prototype=Object.create(m);function w(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function E(t,e){function i(n,o,a,u){var s=f(t[n],t,o);if("throw"!==s.type){var c=s.arg,l=c.value;return l&&"object"==typeof l&&r.call(l,"__await")?e.resolve(l.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(l).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function x(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return k()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=A(a,r);if(u){if(u===h)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=f(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===h)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function A(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,A(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),h;var i=f(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,h;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,h):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,h)}function S(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function O(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function L(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(S,this),this.reset(!0)}function C(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:k}}function k(){return{value:void 0,done:!0}}return p.prototype=v,n(b,"constructor",{value:v,configurable:!0}),n(v,"constructor",{value:p,configurable:!0}),p.displayName=c(v,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===p||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,v):(t.__proto__=v,c(t,u,"GeneratorFunction")),t.prototype=Object.create(b),t},t.awrap=function(t){return{__await:t}},w(E.prototype),c(E.prototype,a,(function(){return this})),t.AsyncIterator=E,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new E(l(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},w(b),c(b,u,"Generator"),c(b,o,(function(){return this})),c(b,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=C,L.prototype={constructor:L,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(O),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,h):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),h},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),O(r),h}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;O(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:C(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),h}},t}function c(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function l(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){c(o,n,i,a,u,"next",t)}function u(t){c(o,n,i,a,u,"throw",t)}a(void 0)}))}}function f(t,e){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},f(t,e)}var h=function(){function t(){this.context=void 0}return t.prototype.apply=function(r){var n=this,i=r.renderingService,o=r.renderingContext;this.context=r;var a=o.root.ownerDocument.defaultView,u=function(t){i.hooks.pointerMove.call(t)},c=function(t){i.hooks.pointerUp.call(t)},f=function(t){i.hooks.pointerDown.call(t)},h=function(t){i.hooks.pointerOver.call(t)},d=function(t){i.hooks.pointerOut.call(t)},p=function(t){i.hooks.pointerCancel.call(t)},v=function(t){i.hooks.pointerWheel.call(t)},m=function(t){e.runtime.globalThis.document.addEventListener("pointermove",u,!0),t.addEventListener("pointerdown",f,!0),t.addEventListener("pointerleave",d,!0),t.addEventListener("pointerover",h,!0),e.runtime.globalThis.addEventListener("pointerup",c,!0)},g=function(t){t.addEventListener("touchstart",f,!0),t.addEventListener("touchend",c,!0),t.addEventListener("touchmove",u,!0),t.addEventListener("touchcancel",p,!0)},y=function(t){e.runtime.globalThis.document.addEventListener("mousemove",u,!0),t.addEventListener("mousedown",f,!0),t.addEventListener("mouseout",d,!0),t.addEventListener("mouseover",h,!0),e.runtime.globalThis.addEventListener("mouseup",c,!0)};i.hooks.init.tapPromise(t.tag,l(s().mark((function t(){var r;return s().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:r=n.context.contextService.getDomElement(),e.runtime.globalThis.navigator.msPointerEnabled?(r.style.msContentZooming="none",r.style.msTouchAction="none"):a.supportsPointerEvents&&(r.style.touchAction="none"),a.supportsPointerEvents?m(r):y(r),a.supportsTouchEvents&&g(r),r.addEventListener("wheel",v,{passive:!0,capture:!0});case 5:case"end":return t.stop()}}),t)})))),i.hooks.destroy.tap(t.tag,(function(){var t=n.context.contextService.getDomElement();e.runtime.globalThis.navigator.msPointerEnabled?(t.style.msContentZooming="",t.style.msTouchAction=""):a.supportsPointerEvents&&(t.style.touchAction=""),a.supportsPointerEvents?function(t){e.runtime.globalThis.document.removeEventListener("pointermove",u,!0),t.removeEventListener("pointerdown",f,!0),t.removeEventListener("pointerleave",d,!0),t.removeEventListener("pointerover",h,!0),e.runtime.globalThis.removeEventListener("pointerup",c,!0)}(t):function(t){e.runtime.globalThis.document.removeEventListener("mousemove",u,!0),t.removeEventListener("mousedown",f,!0),t.removeEventListener("mouseout",d,!0),t.removeEventListener("mouseover",h,!0),e.runtime.globalThis.removeEventListener("mouseup",c,!0)}(t),a.supportsTouchEvents&&function(t){t.removeEventListener("touchstart",f,!0),t.removeEventListener("touchend",c,!0),t.removeEventListener("touchmove",u,!0),t.removeEventListener("touchcancel",p,!0)}(t),t.removeEventListener("wheel",v,!0)}))},t}();h.tag="DOMInteraction";var d=function(t){var e,r;function n(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="dom-interaction",e}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,f(e,r);var i=n.prototype;return i.init=function(){this.addRenderingPlugin(new h)},i.destroy=function(){this.removeAllRenderingPlugins()},n}(e.AbstractRendererPlugin),p=Object.freeze({__proto__:null,Plugin:d}),v="undefined"!=typeof Float32Array?Float32Array:Array;Math.hypot||(Math.hypot=function(){for(var t=0,e=arguments.length;e--;)t+=arguments[e]*arguments[e];return Math.sqrt(t)});var m=function(t){return null==t},g={}.toString,y=function(t){return e="String",g.call(t)==="[object "+e+"]";var e},b=function(t,e,r){if(r||2===arguments.length)for(var n,i=0,o=e.length;o>i;i++)!n&&i in e||(n||(n=Array.prototype.slice.call(e,0,i)),n[i]=e[i]);return t.concat(n||Array.prototype.slice.call(e))},w=function(t,e,r){this.name=t,this.version=e,this.os=r,this.type="browser"},E=function(t){this.version=t,this.type="node",this.name="node",this.os=process.platform},x=function(t,e,r,n){this.name=t,this.version=e,this.os=r,this.bot=n,this.type="bot-device"},A=function(){this.type="bot",this.bot=!0,this.name="bot",this.version=null,this.os=null},S=function(){this.type="react-native",this.name="react-native",this.version=null,this.os=null},O=/(nuhk|curl|Googlebot|Yammybot|Openbot|Slurp|MSNBot|Ask\ Jeeves\/Teoma|ia_archiver)/,L=[["aol",/AOLShield\/([0-9\._]+)/],["edge",/Edge\/([0-9\._]+)/],["edge-ios",/EdgiOS\/([0-9\._]+)/],["yandexbrowser",/YaBrowser\/([0-9\._]+)/],["kakaotalk",/KAKAOTALK\s([0-9\.]+)/],["samsung",/SamsungBrowser\/([0-9\.]+)/],["silk",/\bSilk\/([0-9._-]+)\b/],["miui",/MiuiBrowser\/([0-9\.]+)$/],["beaker",/BeakerBrowser\/([0-9\.]+)/],["edge-chromium",/EdgA?\/([0-9\.]+)/],["chromium-webview",/(?!Chrom.*OPR)wv\).*Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["chrome",/(?!Chrom.*OPR)Chrom(?:e|ium)\/([0-9\.]+)(:?\s|$)/],["phantomjs",/PhantomJS\/([0-9\.]+)(:?\s|$)/],["crios",/CriOS\/([0-9\.]+)(:?\s|$)/],["firefox",/Firefox\/([0-9\.]+)(?:\s|$)/],["fxios",/FxiOS\/([0-9\.]+)/],["opera-mini",/Opera Mini.*Version\/([0-9\.]+)/],["opera",/Opera\/([0-9\.]+)(?:\s|$)/],["opera",/OPR\/([0-9\.]+)(:?\s|$)/],["pie",/^Microsoft Pocket Internet Explorer\/(\d+\.\d+)$/],["pie",/^Mozilla\/\d\.\d+\s\(compatible;\s(?:MSP?IE|MSInternet Explorer) (\d+\.\d+);.*Windows CE.*\)$/],["netfront",/^Mozilla\/\d\.\d+.*NetFront\/(\d.\d)/],["ie",/Trident\/7\.0.*rv\:([0-9\.]+).*\).*Gecko$/],["ie",/MSIE\s([0-9\.]+);.*Trident\/[4-7].0/],["ie",/MSIE\s(7\.0)/],["bb10",/BB10;\sTouch.*Version\/([0-9\.]+)/],["android",/Android\s([0-9\.]+)/],["ios",/Version\/([0-9\._]+).*Mobile.*Safari.*/],["safari",/Version\/([0-9\._]+).*Safari/],["facebook",/FB[AS]V\/([0-9\.]+)/],["instagram",/Instagram\s([0-9\.]+)/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Mobile/],["ios-webview",/AppleWebKit\/([0-9\.]+).*Gecko\)$/],["curl",/^curl\/([0-9\.]+)$/],["searchbot",/alexa|bot|crawl(er|ing)|facebookexternalhit|feedburner|google web preview|nagios|postrank|pingdom|slurp|spider|yahoo!|yandex/]],C=[["iOS",/iP(hone|od|ad)/],["Android OS",/Android/],["BlackBerry OS",/BlackBerry|BB10/],["Windows Mobile",/IEMobile/],["Amazon OS",/Kindle/],["Windows 3.11",/Win16/],["Windows 95",/(Windows 95)|(Win95)|(Windows_95)/],["Windows 98",/(Windows 98)|(Win98)/],["Windows 2000",/(Windows NT 5.0)|(Windows 2000)/],["Windows XP",/(Windows NT 5.1)|(Windows XP)/],["Windows Server 2003",/(Windows NT 5.2)/],["Windows Vista",/(Windows NT 6.0)/],["Windows 7",/(Windows NT 6.1)/],["Windows 8",/(Windows NT 6.2)/],["Windows 8.1",/(Windows NT 6.3)/],["Windows 10",/(Windows NT 10.0)/],["Windows ME",/Windows ME/],["Windows CE",/Windows CE|WinCE|Microsoft Pocket Internet Explorer/],["Open BSD",/OpenBSD/],["Sun OS",/SunOS/],["Chrome OS",/CrOS/],["Linux",/(Linux)|(X11)/],["Mac OS",/(Mac_PowerPC)|(Macintosh)/],["QNX",/QNX/],["BeOS",/BeOS/],["OS/2",/OS\/2/]];function k(t){return t?T(t):"undefined"==typeof document&&"undefined"!=typeof navigator&&"ReactNative"===navigator.product?new S:"undefined"!=typeof navigator?T(navigator.userAgent):"undefined"!=typeof process&&process.version?new E(process.version.slice(1)):null}function T(t){var e=function(t){return""!==t&&L.reduce((function(e,r){var n=r[0];if(e)return e;var i=r[1].exec(t);return!!i&&[n,i]}),!1)}(t);if(!e)return null;var r=e[0],n=e[1];if("searchbot"===r)return new A;var i=n[1]&&n[1].split(".").join("_").split("_").slice(0,3);i?3>i.length&&(i=b(b([],i,!0),function(t){for(var e=[],r=0;t>r;r++)e.push("0");return e}(3-i.length),!0)):i=[];var o=i.join("."),a=function(t){for(var e=0,r=C.length;r>e;e++){var n=C[e],i=n[0];if(n[1].exec(t))return i}return null}(t),u=O.exec(t);return u&&u[1]?new x(r,o,a,u[1]):new w(r,o,a)}function P(){P=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function c(t,e,r,i){var o=Object.create((e&&e.prototype instanceof h?e:h).prototype),a=new O(i||[]);return n(o,"_invoke",{value:E(t,r,a)}),o}function l(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function h(){}function d(){}function p(){}var v={};s(v,o,(function(){return this}));var m=Object.getPrototypeOf,g=m&&m(m(L([])));g&&g!==e&&r.call(g,o)&&(v=g);var y=p.prototype=h.prototype=Object.create(v);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){function i(n,o,a,u){var s=l(t[n],t,o);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==typeof f&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function E(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return C()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=x(a,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=l(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function x(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f;var i=l(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,f;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function L(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:C}}function C(){return{value:void 0,done:!0}}return d.prototype=p,n(y,"constructor",{value:p,configurable:!0}),n(p,"constructor",{value:d,configurable:!0}),d.displayName=s(p,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,u,"GeneratorFunction")),t.prototype=Object.create(y),t},t.awrap=function(t){return{__await:t}},b(w.prototype),s(w.prototype,a,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new w(c(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(y),s(y,u,"Generator"),s(y,o,(function(){return this})),s(y,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=L,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),S(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;S(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:L(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function G(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function M(t){return function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){G(o,n,i,a,u,"next",t)}function u(t){G(o,n,i,a,u,"throw",t)}a(void 0)}))}}function _(){return _=Object.assign?Object.assign.bind():function(t){for(var e=1;arguments.length>e;e++){var r=arguments[e];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])}return t},_.apply(this,arguments)}function N(t,e){return N=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},N(t,e)}var j=function(){this.$el=void 0,this.$groupEl=void 0,this.$hitTestingEl=void 0};function $(t,e){var r=e.img,n=void 0===r?"":r,i=e.width,o=e.height;if(t.setAttribute("x","0"),t.setAttribute("y","0"),y(n))t.setAttribute("href",n);else if(n instanceof Image)i||t.setAttribute("width",""+n.width),o||t.setAttribute("height",""+n.height),t.setAttribute("href",n.src);else if(n instanceof HTMLElement&&y(n.nodeName)&&"CANVAS"===n.nodeName.toUpperCase())t.setAttribute("href",n.toDataURL());else if(n instanceof ImageData){var a=document.createElement("canvas");a.setAttribute("width",""+n.width),a.setAttribute("height",""+n.height);var u=a.getContext("2d");u&&(u.putImageData(n,0,0),i||t.setAttribute("width",""+n.width),o||t.setAttribute("height",""+n.height),t.setAttribute("href",a.toDataURL()))}}function D(t,r){var n=r.x1,i=r.y1,o=r.x2,a=r.y2,u=r.defX,s=void 0===u?0:u,c=r.defY,l=void 0===c?0:c,f=r.markerStart,h=r.markerEnd,d=r.markerStartOffset,p=r.markerEndOffset,v=0,m=0,g=0,y=0,b=0;f&&f instanceof e.DisplayObject&&d&&(v=Math.cos(b=Math.atan2(a-i,o-n))*(d||0),m=Math.sin(b)*(d||0)),h&&h instanceof e.DisplayObject&&p&&(g=Math.cos(b=Math.atan2(i-a,n-o))*(p||0),y=Math.sin(b)*(p||0)),t.setAttribute("x1",""+(n-s+v)),t.setAttribute("y1",""+(i-l+m)),t.setAttribute("x2",""+(o-s+g)),t.setAttribute("y2",""+(a-l+y))}function I(t,r){var n=r.path,i=r.defX,o=void 0===i?0:i,a=r.defY,u=void 0===a?0:a,s=r.markerStart,c=r.markerEnd,l=r.markerStartOffset,f=r.markerEndOffset,h=0,d=0,p=0,v=0,m=0;if(s&&s instanceof e.DisplayObject&&l){var g=s.parentNode.getStartTangent(),y=g[0],b=g[1];h=Math.cos(m=Math.atan2(y[1]-b[1],y[0]-b[0]))*(l||0),d=Math.sin(m)*(l||0)}if(c&&c instanceof e.DisplayObject&&f){var w=c.parentNode.getEndTangent(),E=w[0],x=w[1];p=Math.cos(m=Math.atan2(E[1]-x[1],E[0]-x[0]))*(f||0),v=Math.sin(m)*(f||0)}t.setAttribute("d",e.translatePathToString(n.absolutePath,o,u,h,d,p,v))}function V(t,r){var n=r.points.points,i=r.defX,o=void 0===i?0:i,a=r.defY,u=void 0===a?0:a,s=r.markerStart,c=r.markerStartOffset,l=r.markerEnd,f=r.markerEndOffset,h=n.length;if(n&&h>=2){var d=0,p=0,v=0,m=0,g=0;s&&s instanceof e.DisplayObject&&c&&(d=Math.cos(g=Math.atan2(n[1][1]-n[0][1],n[1][0]-n[0][0]))*(c||0),p=Math.sin(g)*(c||0)),l&&l instanceof e.DisplayObject&&f&&(v=Math.cos(g=Math.atan2(n[h-2][1]-n[h-1][1],n[h-2][0]-n[h-1][0]))*(f||0),m=Math.sin(g)*(f||0)),t.setAttribute("points",n.map((function(t,e){var r=0,n=0;return 0===e?(r=d,n=p):e===h-1&&(r=v,n=m),t[0]-o+r+","+(t[1]-u+n)})).join(" "))}}function R(t,e){var r=e.radius,n=e.width,i=e.height;if(isFinite(n)&&isFinite(i)){var o="";if(r&&r.some((function(t){return 0!==t}))){var a=r.map((function(t){return e=t,r=0,o=Math.min(Math.abs(n)/2,Math.abs(i)/2),r>e?r:e>o?o:e;var e,r,o})),u=a[0],s=a[1],c=a[2],l=a[3],f=n>0?1:-1,h=i>0?1:-1,d=f+h!==0?1:0;o=[["M "+f*u+",0"],["l "+(n-f*(u+s))+",0"],["a "+s+","+s+",0,0,"+d+","+f*s+","+h*s],["l 0,"+(i-h*(s+c))],["a "+c+","+c+",0,0,"+d+","+-f*c+","+h*c],["l "+(f*(c+l)-n)+",0"],["a "+l+","+l+",0,0,"+d+","+-f*l+","+-h*l],["l 0,"+(h*(l+u)-i)],["a "+u+","+u+",0,0,"+d+","+f*u+","+-h*u],["z"]].join(" ")}else o="M 0,0 l "+n+",0 l 0,"+i+" l"+-n+" 0 z";t.setAttribute("d",o)}}function U(t,e){return(e||document).createElementNS("http://www.w3.org/2000/svg",t)}function W(t){return t.toFixed(6).replace(".000000","")}function F(t){return t.replace(/[&|<|>|"|']/g,(function(t){return"&"===t?"&":"<"===t?"<":">"===t?">":'"'===t?""":"'"}))}j.tag="c-svg-element";var B={opacity:"opacity",fillStyle:"fill",fill:"fill",fillRule:"fill-rule",fillOpacity:"fill-opacity",strokeStyle:"stroke",strokeOpacity:"stroke-opacity",stroke:"stroke",clipPath:"clip-path",textPath:"text-path",r:"r",rx:"rx",ry:"ry",width:"width",height:"height",lineCap:"stroke-linecap",lineJoin:"stroke-linejoin",lineWidth:"stroke-width",lineDash:"stroke-dasharray",lineDashOffset:"stroke-dashoffset",miterLimit:"stroke-miterlimit",font:"font",fontSize:"font-size",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",fontFamily:"font-family",letterSpacing:"letter-spacing",startArrow:"marker-start",endArrow:"marker-end",class:"class",id:"id",preserveAspectRatio:"preserveAspectRatio",visibility:"visibility",anchor:"anchor",shadowColor:"flood-color",shadowBlur:"stdDeviation",shadowOffsetX:"dx",shadowOffsetY:"dy",filter:"filter",innerHTML:"innerHTML",textAlign:"text-anchor",pointerEvents:"pointer-events"},H={textAlign:{inherit:"inherit",left:"left",start:"left",center:"middle",right:"end",end:"end"}},Y={textAlign:"inherit",lineCap:"butt",lineJoin:"miter",lineWidth:"1px",opacity:"1",fillOpacity:"1",fillRule:"nonzero",strokeOpacity:"1",strokeWidth:"0",strokeMiterLimit:"4",letterSpacing:"0",fontSize:"inherit",fontFamily:"inherit",pointerEvents:"auto"},X="g-svg",z="clip-path-",q="text-path-",Q=function(){function t(t,e,r){this.pluginOptions=void 0,this.defElementManager=void 0,this.context=void 0,this.$camera=void 0,this.renderQueue=[],this.dirtyAttributes=new WeakMap,this.pendingReorderQueue=new Set,this.clipPathUseMap=new WeakMap,this.pluginOptions=t,this.defElementManager=e,this.context=r}var r=t.prototype;return r.apply=function(r){var n=this,i=r.renderingService,o=r.renderingContext;this.context=r;var a=o.root.ownerDocument.defaultView,u=this.context.config.document,s=function(t){var e=t.target;if(n.clipPathUseMap.get(e)){var r=n.defElementManager.getDefElement().querySelector("#"+n.getId(e));r&&r.remove()}n.createSVGDom(u,e,n.$camera)},c=function(t){var e=t.target;n.defElementManager.clear(e.entity),n.clipPathUseMap.delete(e),n.removeSVGDom(e)},l=function(t){var e=t.target;if(e.elementSVG){var r=t.attrName,i=n.dirtyAttributes.get(e);i||(n.dirtyAttributes.set(e,[]),i=n.dirtyAttributes.get(e)),i.push(r)}},f=function(t){var r,i=t.target,o=null===(r=i.elementSVG)||void 0===r?void 0:r.$el,a=i.parsedStyle,u=a.fill,s=a.stroke;!u||u instanceof e.CSSRGB||n.defElementManager.createOrUpdateGradientAndPattern(i,o,u,"fill",n),!s||s instanceof e.CSSRGB||n.defElementManager.createOrUpdateGradientAndPattern(i,o,s,"stroke",n)};i.hooks.init.tapPromise(t.tag,M(P().mark((function t(){var r,i,o,u;return P().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:i=(r=n.context.config).background,o=r.document,n.defElementManager.init(),u=n.context.contextService.getContext(),i&&(u.style.background=i),u.setAttribute("color-interpolation-filters","sRGB"),n.$camera=U("g",o),n.$camera.id="g-svg-camera",n.applyTransform(n.$camera,n.context.camera.getOrthoMatrix()),u.appendChild(n.$camera),a.addEventListener(e.ElementEvent.MOUNTED,s),a.addEventListener(e.ElementEvent.UNMOUNTED,c),a.addEventListener(e.ElementEvent.ATTR_MODIFIED,l),a.addEventListener(e.ElementEvent.BOUNDS_CHANGED,f);case 13:case"end":return t.stop()}}),t)})))),i.hooks.destroy.tap(t.tag,(function(){a.removeEventListener(e.ElementEvent.MOUNTED,s),a.removeEventListener(e.ElementEvent.UNMOUNTED,c),a.removeEventListener(e.ElementEvent.ATTR_MODIFIED,l),a.removeEventListener(e.ElementEvent.BOUNDS_CHANGED,f)})),i.hooks.render.tap(t.tag,(function(t){n.renderQueue.push(t)})),i.hooks.beginFrame.tap(t.tag,(function(){var t=n.context.config.document;n.pendingReorderQueue.size&&(n.pendingReorderQueue.forEach((function(e){var r,i=((null==e?void 0:e.children)||[]).slice(),o=null==e||null===(r=e.elementSVG)||void 0===r?void 0:r.$groupEl;o&&n.reorderChildren(t||u,o,i||[])})),n.pendingReorderQueue.clear())})),i.hooks.endFrame.tap(t.tag,(function(){o.renderReasons.has(e.RenderReason.CAMERA_CHANGED)&&n.applyTransform(n.$camera,n.context.camera.getOrthoMatrix()),n.renderQueue.forEach((function(t){var e,r,i=null===(e=t.elementSVG)||void 0===e?void 0:e.$el,o=null===(r=t.elementSVG)||void 0===r?void 0:r.$groupEl;if(i&&o){var a=t.getLocalTransform();n.applyTransform(o,a);var s=n.clipPathUseMap.get(t);s&&s.length&&s.forEach((function(e){n.applyTransform(e,t.getWorldTransform())})),t.renderable.dirty=!1}var c=n.dirtyAttributes.get(t);c&&(c.forEach((function(e){if("zIndex"===e){var r,a,s=t.parentNode,c=null===(r=t.parentNode)||void 0===r||null===(a=r.elementSVG)||void 0===a?void 0:a.$groupEl,l=((null==s?void 0:s.children)||[]).slice();c&&n.reorderChildren(u,c,l)}else"increasedLineWidthForHitTesting"===e&&n.createOrUpdateHitArea(t,i,o);n.updateAttribute(t,[e])})),n.dirtyAttributes.delete(t))})),n.renderQueue=[]}))},r.getId=function(t){return"g-svg-"+t.entity},r.reorderChildren=function(t,e,r){if(r.sort((function(t,e){return t.sortable.renderOrder-e.sortable.renderOrder})),r.length){var n=(t||document).createDocumentFragment();r.forEach((function(t){if(t.isConnected){var e=t.elementSVG.$groupEl;e&&n.appendChild(e)}})),e.appendChild(n)}},r.applyTransform=function(t,e){t.setAttribute("transform","matrix("+W(e[0])+","+W(e[1])+","+W(e[4])+","+W(e[5])+","+W(e[12])+","+W(e[13])+")")},r.applyAttributes=function(t){var r=t.elementSVG,n=null==r?void 0:r.$el;if(n&&(null==r?void 0:r.$groupEl)){var i=t.nodeName,o=t.attributes;n.setAttribute("fill","none"),i===e.Shape.IMAGE&&n.setAttribute("preserveAspectRatio","none"),this.updateAttribute(t,Object.keys(o))}},r.updateAttribute=function(t,r){var n=this,i=this.context.config.document,o=t.elementSVG,a=o.$el,u=o.$groupEl,s=o.$hitTestingEl,c=t.parsedStyle,l=t.computedStyle;r.some((function(e){return n.context.SVGElementLifeCycleContribution.shouldUpdateElementAttribute(t,e)}))&&a&&[a,s].forEach((function(r){r&&(n.context.SVGElementLifeCycleContribution.updateElementAttribute(t,r),t.nodeName!==e.Shape.TEXT&&n.updateAnchorWithTransform(t))})),r.forEach((function(r){var o,f,h=B[r],d=l[r],p=d&&""+d,v=(null===(o=H[r])||void 0===o?void 0:o[p])||p,m=c[r],g=!!(null===(f=e.propertyMetadataCache[r])||void 0===f?void 0:f.inh);h&&(t.nodeName===e.Shape.HTML&&("lineWidth"===r?a.style["border-width"]=(m||0)+"px":"lineDash"===r&&(a.style["border-style"]="dashed")),"fill"===r?t.nodeName===e.Shape.HTML?a.style.background=""+m:n.defElementManager.createOrUpdateGradientAndPattern(t,a,m,h,n):"stroke"===r?t.nodeName===e.Shape.HTML?(a.style["border-color"]=""+m,a.style["border-style"]="solid"):n.defElementManager.createOrUpdateGradientAndPattern(t,a,m,h,n):g&&h?"unset"!==p&&p!==Y[r]?null==u||u.setAttribute(h,v):null==u||u.removeAttribute(h):"clipPath"===r?n.createOrUpdateClipOrTextPath(i,m,t):"textPath"===r?n.createOrUpdateClipOrTextPath(i,m,t,!0):"shadowType"===r||"shadowColor"===r||"shadowBlur"===r||"shadowOffsetX"===r||"shadowOffsetY"===r?n.defElementManager.createOrUpdateShadow(t,a,r):"filter"===r?n.defElementManager.createOrUpdateFilter(t,a,m):"innerHTML"===r?n.createOrUpdateInnerHTML(i,a,m):"anchor"===r?t.nodeName!==e.Shape.TEXT&&n.updateAnchorWithTransform(t):d&&[a,s].forEach((function(t){t&&h&&("unset"!==p&&p!==Y[r]?t.setAttribute(h,v):t.removeAttribute(h))})))}))},r.createSVGDom=function(t,r,n,i){void 0===i&&(i=!1),r.elementSVG=new j;var o=r.elementSVG,a=this.context.SVGElementLifeCycleContribution.createElement(r);if(a){var u,s;r.nodeName===e.Shape.HTML&&(r.parsedStyle.$el=a),this.pluginOptions.outputSVGElementId&&(a.id=this.getId(r)),this.pluginOptions.outputSVGElementName&&r.name&&a.setAttribute("name",r.name),!a.hasAttribute("data-wrapgroup")&&"g"===a.nodeName||i?s=a:((s=U("g",t)).id=a.id+"-g",s.appendChild(a)),o.$el=a,o.$groupEl=s,this.applyAttributes(r),this.createOrUpdateHitArea(r,a,s);var c=n||r.parentNode&&(null===(u=r.parentNode.elementSVG)||void 0===u?void 0:u.$groupEl);c&&(c.appendChild(s),this.pendingReorderQueue.add(r.parentNode))}},r.removeSVGDom=function(t){var e,r=null===(e=t.elementSVG)||void 0===e?void 0:e.$groupEl;r&&r.parentNode&&(r.parentNode.removeChild(r),this.context.SVGElementLifeCycleContribution.destroyElement(t,r))},r.createOrUpdateHitArea=function(t,e,r){var n=t.elementSVG,i=n.$hitTestingEl,o=t.parsedStyle.increasedLineWidthForHitTesting;if(o){if(!i){i=e.cloneNode(),this.pluginOptions.outputSVGElementId&&(i.id="g-svg-"+t.nodeName+"-hittesting-"+t.entity),["filter"].forEach((function(t){i.removeAttribute(t)}));var a="none"!==e.getAttribute("fill");i.setAttribute("fill",a?"transparent":"none"),i.setAttribute("stroke","transparent"),r.appendChild(i),n.$hitTestingEl=i}i.setAttribute("stroke-width",""+(o+t.parsedStyle.lineWidth))}else i&&(r.removeChild(i),n.$hitTestingEl=null)},r.createOrUpdateInnerHTML=function(t,e,r){var n=(t||document).createElement("div");"string"==typeof r?n.innerHTML=r:n.appendChild(r),e.innerHTML="",e.appendChild(n)},r.createOrUpdateClipOrTextPath=function(t,e,r,n){void 0===n&&(n=!1);var i,o=r.elementSVG.$groupEl,a=n?"g":"clipPath",u=n?"text-path":"clip-path";if(e){var s=(n?q:z)+e.entity+"-"+r.entity,c=this.defElementManager.getDefElement();if(!c.querySelector("#"+s)){var l;if(n)this.createSVGDom(t,e,null,!0),l=e.elementSVG.$el;else{if(!e.isConnected)c.querySelector("#"+this.getId(e))||this.createSVGDom(t,e,c,!0);l=U(a,t);var f=U("use",t);f.setAttribute("href","#"+e.elementSVG.$el.id),l.appendChild(f);var h=this.clipPathUseMap.get(e);h||(this.clipPathUseMap.set(e,[]),h=this.clipPathUseMap.get(e)),h.push(f),this.applyTransform(f,e.getWorldTransform());var d=function(t,e){var r=e[0],n=e[1],i=e[2],o=e[3],a=e[4],u=e[5],s=e[6],c=e[7],l=e[8],f=e[9],h=e[10],d=e[11],p=e[12],v=e[13],m=e[14],g=e[15],y=r*u-n*a,b=r*s-i*a,w=r*c-o*a,E=n*s-i*u,x=n*c-o*u,A=i*c-o*s,S=l*v-f*p,O=l*m-h*p,L=l*g-d*p,C=f*m-h*v,k=f*g-d*v,T=h*g-d*m,P=y*T-b*k+w*C+E*L-x*O+A*S;return P?(t[0]=(u*T-s*k+c*C)*(P=1/P),t[1]=(i*k-n*T-o*C)*P,t[2]=(v*A-m*x+g*E)*P,t[3]=(h*x-f*A-d*E)*P,t[4]=(s*L-a*T-c*O)*P,t[5]=(r*T-i*L+o*O)*P,t[6]=(m*w-p*A-g*b)*P,t[7]=(l*A-h*w+d*b)*P,t[8]=(a*k-u*L+c*S)*P,t[9]=(n*L-r*k-o*S)*P,t[10]=(p*x-v*w+g*y)*P,t[11]=(f*w-l*x-d*y)*P,t[12]=(u*O-a*C-s*S)*P,t[13]=(r*C-n*O+i*S)*P,t[14]=(v*b-p*E-m*y)*P,t[15]=(l*E-f*b+h*y)*P,t):null}((i=new v(16),v!=Float32Array&&(i[1]=0,i[2]=0,i[3]=0,i[4]=0,i[6]=0,i[7]=0,i[8]=0,i[9]=0,i[11]=0,i[12]=0,i[13]=0,i[14]=0),i[0]=1,i[5]=1,i[10]=1,i[15]=1,i),r.getWorldTransform());this.applyTransform(l,d)}l.id=s,c.appendChild(l)}this.applyAttributes(e),n||o.setAttribute(u,"url(#"+s+")")}else n||o.removeAttribute(u)},r.updateAnchorWithTransform=function(t){var r,n,i=t.getGeometryBounds(),o=i&&2*i.halfExtents[0]||0,a=i&&2*i.halfExtents[1]||0,u=(t.parsedStyle||{}).anchor;[null===(r=t.elementSVG)||void 0===r?void 0:r.$el,null===(n=t.elementSVG)||void 0===n?void 0:n.$hitTestingEl].forEach((function(r){if(r){var n=-u[0]*o,i=-u[1]*a;0===n&&0===i||r.setAttribute("transform","translate("+n+","+i+")"),t.nodeName!==e.Shape.CIRCLE&&t.nodeName!==e.Shape.ELLIPSE||(r.setAttribute("cx",""+o/2),r.setAttribute("cy",""+a/2))}}))},t}();Q.tag="SVGRenderer";var K,J,Z={top:"before-edge",middle:"central",bottom:"after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"},tt={top:"text-before-edge",middle:"central",bottom:"text-after-edge",alphabetic:"alphabetic",ideographic:"ideographic",hanging:"hanging"};function et(t,e){var r=e.textBaseline,n=e.lineWidth,i=e.metrics,o=e.dx,a=e.dy,u=e.textPath,s=e.textPathSide,c=void 0===s?"left":s,l=e.textPathStartOffset,f=void 0===l?0:l,h=e.textDecorationLine,d=void 0===h?"":h,p=e.textDecorationColor,v=void 0===p?"":p,m=e.textDecorationStyle,g=void 0===m?"":m,y=k();y&&"firefox"===y.name?t.setAttribute("dominant-baseline",tt[r]||"alphabetic"):(t.setAttribute("dominant-baseline",tt[r]),t.setAttribute("alignment-baseline",Z[r])),t.setAttribute("paint-order","stroke");var b=i.lines,w=i.lineHeight,E=i.height,x=b.length,A="";if(0===o&&0===a||(A+="transform:translate("+o+"px, "+a+"px);"),d&&"none"!==d&&(A+="text-decoration:"+d+" "+g+" "+v+";"),A&&t.setAttribute("style",A),1===x){var S=F(b[0]);if(t.setAttribute("dx",""+n/2),u){t.innerHTML="";var O=U("textPath",t.ownerDocument);O.setAttribute("href","#"+(q+u.entity)),"left"!==c&&O.setAttribute("side",c),0!==f&&O.setAttribute("startOffset",""+f),O.innerHTML=S,t.appendChild(O)}else t.innerHTML=S}else t.innerHTML=b.map((function(t,e){var i=0;return 0===e?"middle"===r?i=w/2-E/2:"top"===r||"hanging"===r?i=0:"bottom"!==r&&"alphabetic"!==r&&"ideographic"!==r||(i=-w*(x-1)):i=w,'<tspan x="0" dx="'+n/2+'" dy="'+i+'">'+F(t)+"</tspan>"})).join("")}var rt=((K={})[e.Shape.RECT]="path",K[e.Shape.CIRCLE]="circle",K[e.Shape.ELLIPSE]="ellipse",K[e.Shape.IMAGE]="image",K[e.Shape.GROUP]="g",K[e.Shape.LINE]="line",K[e.Shape.POLYLINE]="polyline",K[e.Shape.POLYGON]="polygon",K[e.Shape.TEXT]="text",K[e.Shape.PATH]="path",K[e.Shape.HTML]="foreignObject",K),nt=((J={})[e.Shape.CIRCLE]=["r"],J[e.Shape.ELLIPSE]=["rx","ry"],J[e.Shape.RECT]=["width","height","radius"],J[e.Shape.IMAGE]=["img","width","height"],J[e.Shape.LINE]=["x1","y1","x2","y2","markerStart","markerEnd","markerStartOffset","markerEndOffset"],J[e.Shape.POLYLINE]=["points","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],J[e.Shape.POLYGON]=["points","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],J[e.Shape.PATH]=["path","markerStart","markerEnd","markerMid","markerStartOffset","markerEndOffset"],J[e.Shape.TEXT]=["text","font","fontSize","fontFamily","fontStyle","fontWeight","fontVariant","lineHeight","letterSpacing","wordWrap","wordWrapWidth","maxLines","leading","textBaseline","textAlign","textTransform","textOverflow","textPath","textPathSide","textPathStartOffset","textDecorationLine","textDecorationColor","textDecorationStyle","dx","dy"],J),it=function(){function t(t){this.context=void 0,this.context=t}var r=t.prototype;return r.createElement=function(t){return U(rt[t.nodeName]||"g",this.context.config.document||document)},r.destroyElement=function(t,e){},r.shouldUpdateElementAttribute=function(t,e){return(nt[t.nodeName]||[]).indexOf(e)>-1},r.updateElementAttribute=function(t){var r=t.elementSVG.$el,n=t.parsedStyle;switch(t.nodeName){case e.Shape.IMAGE:$(r,n);break;case e.Shape.RECT:R(r,n);break;case e.Shape.LINE:D(r,n);break;case e.Shape.POLYGON:case e.Shape.POLYLINE:V(r,n);break;case e.Shape.PATH:I(r,n);break;case e.Shape.TEXT:et(r,n)}},t}(),ot="g-filter-";function at(t,r,n,i,o){var a=ot+n.entity,u=r.querySelectorAll("[name="+a+"]");if(u.length&&u.forEach((function(t){r.removeChild(t)})),0===o.length)null==i||i.removeAttribute("filter");else{var s=o.map((function(n,i){var o=n.name,u=n.params,s=U("filter",t);return s.setAttribute("filterUnits","userSpaceOnUse"),"blur"===o?function(t,e,r){var n=U("feGaussianBlur",t);n.setAttribute("in","SourceGraphic"),n.setAttribute("stdDeviation",""+r[0].value),e.appendChild(n)}(t,s,u):"brightness"===o?function(t,e,r){var n=ut(r[0]);st(t,e,{type:"linear",slope:n,intercept:0})}(t,s,u):"drop-shadow"===o?function(t,e,r){var n=r[0].value,i=r[1].value,o=r[2].value,a=r[3].formatted,u=U("feGaussianBlur",t);u.setAttribute("in","SourceAlpha"),u.setAttribute("stdDeviation",""+o),e.appendChild(u);var s=U("feOffset",t);s.setAttribute("dx",""+n),s.setAttribute("dy",""+i),s.setAttribute("result","offsetblur"),e.appendChild(s);var c=U("feFlood",t);c.setAttribute("flood-color",a),e.appendChild(c);var l=U("feComposite",t);l.setAttribute("in2","offsetblur"),l.setAttribute("operator","in"),e.appendChild(l);var f=U("feMerge",t);e.appendChild(f);var h=U("feMergeNode",t),d=U("feMergeNode",t);d.setAttribute("in","SourceGraphic"),f.appendChild(h),f.appendChild(d)}(t,s,u):"contrast"===o?function(t,e,r){var n=ut(r[0]);st(t,e,{type:"linear",slope:n,intercept:-.5*n+.5})}(t,s,u):"grayscale"===o?function(t,e,r){var n=ut(r[0]);ct(t,e,[.2126+.7874*(1-n),.7152-.7152*(1-n),.0722-.0722*(1-n),0,0,.2126-.2126*(1-n),.7152+.2848*(1-n),.0722-.0722*(1-n),0,0,.2126-.2126*(1-n),.7152-.7152*(1-n),.0722+.9278*(1-n),0,0,0,0,0,1,0])}(t,s,u):"sepia"===o?function(t,e,r){var n=ut(r[0]);ct(t,e,[.393+.607*(1-n),.769-.769*(1-n),.189-.189*(1-n),0,0,.349-.349*(1-n),.686+.314*(1-n),.168-.168*(1-n),0,0,.272-.272*(1-n),.534-.534*(1-n),.131+.869*(1-n),0,0,0,0,0,1,0])}(t,s,u):"saturate"===o?function(t,e,r){var n=ut(r[0]),i=U("feColorMatrix",t);i.setAttribute("type","saturate"),i.setAttribute("values",""+n),e.appendChild(i)}(t,s,u):"hue-rotate"===o?function(t,r,n){var i=U("feColorMatrix",t);i.setAttribute("type","hueRotate"),i.setAttribute("values",""+n[0].to(e.UnitType.kDegrees).value),r.appendChild(i)}(t,s,u):"invert"===o&&function(t,e,r){var n=ut(r[0]);st(t,e,{type:"table",tableValues:n+" "+(1-n)})}(t,s,u),s.id=a+"-"+i,s.setAttribute("name",a),r.appendChild(s),s.id}));setTimeout((function(){null==i||i.setAttribute("filter",s.map((function(t){return"url(#"+t+")"})).join(" "))}))}}function ut(t){return t.unit===e.UnitType.kPercentage?t.value/100:t.value}function st(t,e,r){var n=r.type,i=r.slope,o=r.intercept,a=r.tableValues,u=U("feComponentTransfer",t);[U("feFuncR",t),U("feFuncG",t),U("feFuncB",t)].forEach((function(t){t.setAttribute("type",n),"table"===n?t.setAttribute("tableValues",""+a):(t.setAttribute("slope",""+i),t.setAttribute("intercept",""+o)),u.appendChild(t)})),e.appendChild(u)}function ct(t,e,r){var n=U("feColorMatrix",t);n.setAttribute("type","matrix"),n.setAttribute("values",r.join(" ")),e.appendChild(n)}var lt={},ft=0;function ht(t,r,n,i,o,a,u,s){if(!o)return"";if(!(o instanceof e.CSSRGB)){if(e.isPattern(o)){var c=function(t,r,n,i,o,a){var u=dt(i);if(!r.querySelector("#"+u)){var s=i.image,c="";if(y(s)?c=s:e.isBrowser&&(s instanceof HTMLImageElement?c=s.src:s instanceof HTMLCanvasElement&&(c=s.toDataURL())),c){var l,f=U("image",t);f.setAttribute("href",c),o?l=o(c):e.isBrowser&&(l=new window.Image),c.match(/^data:/i)||(l.crossOrigin="Anonymous",f.setAttribute("crossorigin","anonymous")),l.src=c;var h=function(){var e=pt(t,r,n,i,u,l.width,l.height);r.appendChild(e),e.appendChild(f),f.setAttribute("x","0"),f.setAttribute("y","0"),f.setAttribute("width",""+l.width),f.setAttribute("height",""+l.height)};l.complete?h():l.onload=h}if(s instanceof e.Rect){var d=s.parsedStyle,p=pt(t,r,s,i,u,d.width,d.height);s.forEach((function(e){a.createSVGDom(t,e,null);var r=e.elementSVG,n=e.getLocalTransform();a.applyTransform(r.$groupEl,n)})),p.appendChild(s.elementSVG.$groupEl)}}return u}(t,r,n,o,u,s);return i.style[a]="url(#"+c+")",c}if(1===o.length){var l=vt(t,n,r,i,o[0]);return null==i||i.setAttribute(a,"url(#"+l+")"),l}var f=function(t,e,r,n,i){var o=ot+e.entity+"-gradient",a=r.querySelector("#"+o);a||((a=U("filter",t)).setAttribute("filterUnits","userSpaceOnUse"),a.setAttribute("x","0%"),a.setAttribute("y","0%"),a.setAttribute("width","100%"),a.setAttribute("height","100%"),a.id=o,r.appendChild(a));var u=0;i.forEach((function(i,s){var c=vt(t,e,r,n,i),l=c+"_rect",f=U("rect",t);f.setAttribute("x","0"),f.setAttribute("y","0"),f.setAttribute("width","100%"),f.setAttribute("height","100%"),f.setAttribute("fill","url(#"+c+")"),f.id=l,r.appendChild(f);var h=U("feImage",t);if(h.setAttribute("href","#"+l),h.setAttribute("result",o+"-"+s),a.appendChild(h),s>0){var d=U("feBlend",t);d.setAttribute("in",1===s?o+"-"+(s-1):o+"-blended-"+(u-1)),d.setAttribute("in2",o+"-"+s),d.setAttribute("result",o+"-blended-"+u++),d.setAttribute("mode","multiply"),a.appendChild(d)}}));var s=U("feComposite",t);return s.setAttribute("in",o+"-blended-"+u),s.setAttribute("in2","SourceGraphic"),s.setAttribute("operator","in"),a.appendChild(s),o}(t,n,r,i,o);return null==i||i.setAttribute("filter","url(#"+f+")"),null==i||i.setAttribute("fill","black"),f}return"currentColor"===n.style[a]?null==i||i.setAttribute(a,"currentColor"):null==i||i.setAttribute(a,o.isNone?"none":""+o),""}function dt(t,r){void 0===r&&(r={});var n="";if(t instanceof e.CSSGradientValue){var i=t.type;if(i===e.GradientType.LinearGradient||i===e.GradientType.RadialGradient){var o=_({},t.value,r),a=o.angle,u=o.cx,s=o.cy,c=o.size;n="gradient-"+o.type+"-"+((null==a?void 0:""+a)||0)+"-"+((null==u?void 0:""+u)||0)+"-"+((null==s?void 0:""+s)||0)+"-"+((null==c?void 0:""+c)||0)+"-"+o.width+"-"+o.height+"-"+o.steps.map((function(t){return""+t.offset+t.color})).join("-")}}else e.isPattern(t)&&(n=y(t.image)?"pattern-"+t.image+"-"+t.repetition:t.image instanceof e.Rect?"pattern-rect-"+t.image.entity:"pattern-"+ft);return n&&(lt[n]||(lt[n]="g-pattern-"+ft++)),lt[n]}function pt(t,r,n,i,o,a,u){var s=i.repetition,c=i.transform,l=U("pattern",t);c&&l.setAttribute("patternTransform",function(t){return e.parseTransform(t).map((function(t){var e=t.t,r=t.d;if("translate"===e)return"translate("+r[0].value+" "+r[1].value+")";if("translatex"===e)return"translate("+r[0].value+" 0)";if("translatey"===e)return"translate(0 "+r[0].value+")";if("rotate"===e)return"rotate("+r[0].value+")";if("scale"===e){var n=(null==r?void 0:r.map((function(t){return t.value})))||[1,1];return"scale("+n[0]+", "+n[1]+")"}if("scalex"===e)return"scale("+((null==r?void 0:r.map((function(t){return t.value})))||[1])[0]+", 1)";if("scaley"===e)return"scale(1, "+((null==r?void 0:r.map((function(t){return t.value})))||[1])[0]+")";if("skew"===e){var i=(null==r?void 0:r.map((function(t){return t.value})))||[0,0];return"skewX("+i[0]+") skewY("+i[1]+")"}if("skewx"===e)return"skewX("+((null==r?void 0:r.map((function(t){return t.value})))||[0])[0]+")";if("skewy"===e)return"skewY("+((null==r?void 0:r.map((function(t){return t.value})))||[0])[0]+")";if("matrix"===e){var o=r.map((function(t){return t.value}));return"matrix("+o[0]+" "+o[1]+" "+o[2]+" "+o[3]+" "+o[4]+" "+o[5]+")"}})).join(" ")}(c)),l.setAttribute("patternUnits","userSpaceOnUse"),l.id=o,r.appendChild(l),l.setAttribute("x","0"),l.setAttribute("y","0");var f=n.getGeometryBounds().halfExtents,h=a,d=u;return"repeat-x"===s?d=2*f[1]:"repeat-y"===s?h=2*f[0]:"no-repeat"===s&&(h=2*f[0],d=2*f[1]),l.setAttribute("width",""+h),l.setAttribute("height",""+d),l}function vt(t,r,n,i,o){var a=r.getGeometryBounds(),u=a&&2*a.halfExtents[0]||0,s=a&&2*a.halfExtents[1]||0,c=dt(o,{width:u,height:s}),l=n.querySelector("#"+c);if(!l){(l=U(o.type===e.GradientType.LinearGradient?"linearGradient":"radialGradient",t)).setAttribute("gradientUnits","userSpaceOnUse");var f="";o.value.steps.sort((function(t,e){return t.offset.value-e.offset.value})).forEach((function(t){f+='<stop offset="'+t.offset.value/100+'" stop-color="'+t.color+'"></stop>'})),l.innerHTML=f,l.id=c,n.appendChild(l)}if(o.type===e.GradientType.LinearGradient){var h=e.computeLinearGradient(u,s,o.value.angle),d=h.y1,p=h.x2,v=h.y2;l.setAttribute("x1",""+h.x1),l.setAttribute("y1",""+d),l.setAttribute("x2",""+p),l.setAttribute("y2",""+v)}else{var m=o.value,g=e.computeRadialGradient(u,s,m.cx,m.cy,m.size),y=g.y,b=g.r;l.setAttribute("cx",""+g.x),l.setAttribute("cy",""+y),l.setAttribute("r",""+b)}return c}var mt=/url\("?#(.*)\)/,gt=function(){function t(t){this.context=void 0,this.$def=void 0,this.gradientCache={},this.context=t}var r=t.prototype;return r.getDefElement=function(){return this.$def},r.init=function(){var t=this.context.config.document,e=this.context.contextService.getContext();this.$def=U("defs",t),e.appendChild(this.$def)},r.clear=function(t){var e=this;Object.keys(this.gradientCache).forEach((function(r){e.clearUnusedDefElement(e.gradientCache,r,t)}))},r.clearUnusedDefElement=function(t,e,r){if(t[e]&&1===t[e].size&&t[e].has(r)){var n=this.$def.querySelector("#"+e);n&&this.$def.removeChild(n)}},r.createOrUpdateGradientAndPattern=function(t,r,n,i,o){var a=this.context.config,u=a.document,s=a.createImage;if(r){var c=(e.isPattern(n)?r.style[i]:r.getAttribute(i)||"").match(mt);c&&c.length>1&&this.clearUnusedDefElement(this.gradientCache,c[1].replace('"',""),t.entity);var l=ht(u||document,this.$def,t,r,n,i,s,o);l&&(this.gradientCache[l]||(this.gradientCache[l]=new Set),this.gradientCache[l].add(t.entity))}},r.createOrUpdateShadow=function(t,e,r){!function(t,e,r,n,i){var o=r.parsedStyle,a=o.shadowType,u=o.shadowBlur,s=o.shadowColor,c=o.shadowOffsetX,l=o.shadowOffsetY,f=!m(s)&&u>0,h="g-filter-dropshadow-"+r.entity,d=e.querySelector("#"+h);if(d&&(d.getAttribute("data-type")===a&&f||(d.remove(),d=null)),f){if(null==n||n.setAttribute("filter","url(#"+h+")"),!d){if((d=U("filter",t)).setAttribute("data-type",a),"outer"===a){var p=U("feDropShadow",t);p.setAttribute("dx",""+(c||0)/2),p.setAttribute("dy",""+(l||0)/2),p.setAttribute("stdDeviation",""+(u||0)/4),p.setAttribute("flood-color",""+s),d.appendChild(p)}else if("inner"===a){var v=U("feComponentTransfer",t);v.setAttribute("in","SourceAlpha");var g=U("feFuncA",t);g.setAttribute("type","table"),g.setAttribute("tableValues","1 0"),v.appendChild(g),d.appendChild(v);var y=U("feGaussianBlur",t);y.setAttribute("stdDeviation",""+(u||0)/4),d.appendChild(y);var b=U("feOffset",t);b.setAttribute("dx",""+(c||0)/2),b.setAttribute("dy",""+(l||0)/2),b.setAttribute("result","offsetblur"),d.appendChild(b);var w=U("feFlood",t);w.setAttribute("flood-color",""+s),w.setAttribute("result","color"),d.appendChild(w);var E=U("feComposite",t);E.setAttribute("in2","offsetblur"),E.setAttribute("operator","in"),d.appendChild(E);var x=U("feComposite",t);x.setAttribute("in2","SourceAlpha"),x.setAttribute("operator","in"),d.appendChild(x);var A=U("feMerge",t);d.appendChild(A);var S=U("feMergeNode",t);S.setAttribute("in","SourceGraphic");var O=U("feMergeNode",t);A.appendChild(S),A.appendChild(O)}return d.id=h,d.setAttribute("filterUnits","userSpaceOnUse"),void e.appendChild(d)}if("inner"===a){var L=d.children[1],C=d.children[2];"shadowColor"===i?d.children[3].setAttribute("flood-color",""+s):"shadowBlur"===i?L.setAttribute("stdDeviation",""+(u||0)/4):"shadowOffsetX"===i?C.setAttribute("dx",""+(c||0)/2):"shadowOffsetY"===i&&C.setAttribute("dy",""+(l||0)/2)}else if("outer"===a){var k=d.children[0];"shadowColor"===i?k.setAttribute("flood-color",""+s):"shadowBlur"===i?k.setAttribute("stdDeviation",""+(u||0)/4):"shadowOffsetX"===i?k.setAttribute("dx",""+(c||0)/2):"shadowOffsetY"===i&&k.setAttribute("dy",""+(l||0)/2)}}else null==n||n.removeAttribute("filter")}(this.context.config.document||document,this.$def,t,e,r)},r.createOrUpdateFilter=function(t,e,r){at(this.context.config.document||document,this.$def,t,e,r)},t}(),yt=function(t){var e,r;function n(e){var r;return void 0===e&&(e={}),(r=t.call(this)||this).options=void 0,r.name="svg-renderer",r.options=e,r}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,N(e,r);var i=n.prototype;return i.init=function(){var t=this.options,e=t.outputSVGElementId,r=t.outputSVGElementName,n=new gt(this.context),i=new it(this.context);this.context.defaultElementLifeCycleContribution=i,this.context.SVGElementLifeCycleContribution=i;var o={outputSVGElementId:!!m(e)||!!e,outputSVGElementName:!!m(r)||!!r};this.addRenderingPlugin(new Q(o,n,this.context))},i.destroy=function(){this.removeAllRenderingPlugins(),delete this.context.defaultElementLifeCycleContribution,delete this.context.SVGElementLifeCycleContribution},n}(e.AbstractRendererPlugin),bt=Object.freeze({__proto__:null,CLIP_PATH_PREFIX:z,DEFAULT_VALUE_MAP:Y,DefaultElementLifeCycleContribution:it,ElementSVG:j,G_SVG_PREFIX:X,Plugin:yt,SHAPE2TAGS:rt,SHAPE_UPDATE_DEPS:nt,SVGRendererPlugin:Q,SVG_ATTR_MAP:B,TEXT_PATH_PREFIX:q,createSVGElement:U,updateImageElementAttribute:$,updateLineElementAttribute:D,updatePathElementAttribute:I,updatePolylineElementAttribute:V,updateRectElementAttribute:R,updateTextElementAttribute:et});function wt(){wt=function(){return t};var t={},e=Object.prototype,r=e.hasOwnProperty,n=Object.defineProperty||function(t,e,r){t[e]=r.value},i="function"==typeof Symbol?Symbol:{},o=i.iterator||"@@iterator",a=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function s(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{s({},"")}catch(t){s=function(t,e,r){return t[e]=r}}function c(t,e,r,i){var o=Object.create((e&&e.prototype instanceof h?e:h).prototype),a=new O(i||[]);return n(o,"_invoke",{value:E(t,r,a)}),o}function l(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}t.wrap=c;var f={};function h(){}function d(){}function p(){}var v={};s(v,o,(function(){return this}));var m=Object.getPrototypeOf,g=m&&m(m(L([])));g&&g!==e&&r.call(g,o)&&(v=g);var y=p.prototype=h.prototype=Object.create(v);function b(t){["next","throw","return"].forEach((function(e){s(t,e,(function(t){return this._invoke(e,t)}))}))}function w(t,e){function i(n,o,a,u){var s=l(t[n],t,o);if("throw"!==s.type){var c=s.arg,f=c.value;return f&&"object"==typeof f&&r.call(f,"__await")?e.resolve(f.__await).then((function(t){i("next",t,a,u)}),(function(t){i("throw",t,a,u)})):e.resolve(f).then((function(t){c.value=t,a(c)}),(function(t){return i("throw",t,a,u)}))}u(s.arg)}var o;n(this,"_invoke",{value:function(t,r){function n(){return new e((function(e,n){i(t,r,e,n)}))}return o=o?o.then(n,n):n()}})}function E(t,e,r){var n="suspendedStart";return function(i,o){if("executing"===n)throw Error("Generator is already running");if("completed"===n){if("throw"===i)throw o;return C()}for(r.method=i,r.arg=o;;){var a=r.delegate;if(a){var u=x(a,r);if(u){if(u===f)continue;return u}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if("suspendedStart"===n)throw n="completed",r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n="executing";var s=l(t,e,r);if("normal"===s.type){if(n=r.done?"completed":"suspendedYield",s.arg===f)continue;return{value:s.arg,done:r.done}}"throw"===s.type&&(n="completed",r.method="throw",r.arg=s.arg)}}}function x(t,e){var r=e.method,n=t.iterator[r];if(void 0===n)return e.delegate=null,"throw"===r&&t.iterator.return&&(e.method="return",e.arg=void 0,x(t,e),"throw"===e.method)||"return"!==r&&(e.method="throw",e.arg=new TypeError("The iterator does not provide a '"+r+"' method")),f;var i=l(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,f;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=void 0),e.delegate=null,f):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,f)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function S(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function L(t){if(t){var e=t[o];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,i=function e(){for(;++n<t.length;)if(r.call(t,n))return e.value=t[n],e.done=!1,e;return e.value=void 0,e.done=!0,e};return i.next=i}}return{next:C}}function C(){return{value:void 0,done:!0}}return d.prototype=p,n(y,"constructor",{value:p,configurable:!0}),n(p,"constructor",{value:d,configurable:!0}),d.displayName=s(p,u,"GeneratorFunction"),t.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===d||"GeneratorFunction"===(e.displayName||e.name))},t.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,p):(t.__proto__=p,s(t,u,"GeneratorFunction")),t.prototype=Object.create(y),t},t.awrap=function(t){return{__await:t}},b(w.prototype),s(w.prototype,a,(function(){return this})),t.AsyncIterator=w,t.async=function(e,r,n,i,o){void 0===o&&(o=Promise);var a=new w(c(e,r,n,i),o);return t.isGeneratorFunction(r)?a:a.next().then((function(t){return t.done?t.value:a.next()}))},b(y),s(y,u,"Generator"),s(y,o,(function(){return this})),s(y,"toString",(function(){return"[object Generator]"})),t.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function t(){for(;r.length;){var n=r.pop();if(n in e)return t.value=n,t.done=!1,t}return t.done=!0,t}},t.values=L,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=void 0,this.done=!1,this.delegate=null,this.method="next",this.arg=void 0,this.tryEntries.forEach(S),!t)for(var e in this)"t"===e.charAt(0)&&r.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=void 0)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(r,n){return a.type="throw",a.arg=t,e.next=r,n&&(e.method="next",e.arg=void 0),!!n}for(var i=this.tryEntries.length-1;i>=0;--i){var o=this.tryEntries[i],a=o.completion;if("root"===o.tryLoc)return n("end");if(this.prev>=o.tryLoc){var u=r.call(o,"catchLoc"),s=r.call(o,"finallyLoc");if(u&&s){if(o.catchLoc>this.prev)return n(o.catchLoc,!0);if(o.finallyLoc>this.prev)return n(o.finallyLoc)}else if(u){if(o.catchLoc>this.prev)return n(o.catchLoc,!0)}else{if(!s)throw Error("try statement without catch or finally");if(o.finallyLoc>this.prev)return n(o.finallyLoc)}}}},abrupt:function(t,e){for(var n=this.tryEntries.length-1;n>=0;--n){var i=this.tryEntries[n];if(this.prev>=i.tryLoc&&r.call(i,"finallyLoc")&&i.finallyLoc>this.prev){var o=i;break}}o&&("break"===t||"continue"===t)&&e>=o.tryLoc&&o.finallyLoc>=e&&(o=null);var a=o?o.completion:{};return a.type=t,a.arg=e,o?(this.method="next",this.next=o.finallyLoc,f):this.complete(a)},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),f},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),S(r),f}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;S(r)}return i}}throw Error("illegal catch attempt")},delegateYield:function(t,e,r){return this.delegate={iterator:L(t),resultName:e,nextLoc:r},"next"===this.method&&(this.arg=void 0),f}},t}function Et(t,e,r,n,i,o,a){try{var u=t[o](a),s=u.value}catch(t){return void r(t)}u.done?e(s):Promise.resolve(s).then(n,i)}function xt(t,e){return xt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(t,e){return t.__proto__=e,t},xt(t,e)}function At(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);e>r;r++)n[r]=t[r];return n}function St(t,e){var r="undefined"!=typeof Symbol&&t[Symbol.iterator]||t["@@iterator"];if(r)return(r=r.call(t)).next.bind(r);if(Array.isArray(t)||(r=function(t,e){if(t){if("string"==typeof t)return At(t,e);var r=Object.prototype.toString.call(t).slice(8,-1);return"Object"===r&&t.constructor&&(r=t.constructor.name),"Map"===r||"Set"===r?Array.from(t):"Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?At(t,e):void 0}}(t))||e&&t&&"number"==typeof t.length){r&&(t=r);var n=0;return function(){return t.length>n?{done:!1,value:t[n++]}:{done:!0}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var Ot=function(){function t(){}var r=t.prototype;return r.apply=function(e){var r=this,n=e.config.document,i=e.renderingService;i.hooks.pick.tapPromise(t.tag,function(){var t,e=(t=wt().mark((function t(e){return wt().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.abrupt("return",r.pick(n,e));case 1:case"end":return t.stop()}}),t)})),function(){var e=this,r=arguments;return new Promise((function(n,i){var o=t.apply(e,r);function a(t){Et(o,n,i,a,u,"next",t)}function u(t){Et(o,n,i,a,u,"throw",t)}a(void 0)}))});return function(t){return e.apply(this,arguments)}}()),i.hooks.pickSync.tap(t.tag,(function(t){return r.pick(n,t)}))},r.pick=function(t,r){var n=r.topmost,i=r.position,o=i.clientX,a=i.clientY;try{for(var u,s=[],c=St((t||document).elementsFromPoint(o,a));!(u=c()).done;){var l=u.value,f=l&&l.getAttribute("id");if(f&&f.startsWith(X)){var h=f.lastIndexOf("-"),d=e.runtime.displayObjectPool.getByEntity(f.substring(h+1));if(d&&d.isInteractive()&&(s.push(d),n))return r.picked=s,r}}r.picked=s}catch(t){r.picked=[]}return r},t}();Ot.tag="SVGPicker";var Lt=function(t){var e,r;function n(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="svg-picker",e}(e=n).prototype=Object.create((r=t).prototype),e.prototype.constructor=e,xt(e,r);var i=n.prototype;return i.init=function(){this.addRenderingPlugin(new Ot)},i.destroy=function(){this.removeAllRenderingPlugins()},n}(e.AbstractRendererPlugin),Ct=Object.freeze({__proto__:null,Plugin:Lt}),kt=["offset","composite","computedOffset","easing"],Tt=["offset","composite","computedOffset","easing","transformOrigin"],Pt=["offset","composite","computedOffset","easing","transformOrigin"],Gt=["offset","composite","computedOffset","easing","transformOrigin"],Mt=function(){function t(t){this.context=void 0,this.$container=void 0,this.$namespace=void 0,this.dpr=void 0,this.canvasConfig=void 0,this.context=t,this.canvasConfig=t.config}var n=t.prototype;return n.init=function(){var t=i(r().mark((function t(){var n,i,o,a,u,s;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:o=(n=this.canvasConfig).document,a=n.devicePixelRatio,this.$container=y(i=n.container)?(o||document).getElementById(i):i,this.$container&&(this.$container.style.position||(this.$container.style.position="relative"),(u=U("svg",o)).setAttribute("width",""+this.canvasConfig.width),u.setAttribute("height",""+this.canvasConfig.height),this.$container.appendChild(u),this.$namespace=u),s=a||e.isBrowser&&window.devicePixelRatio||1,this.dpr=s=1>s?1:Math.ceil(s);case 6:case"end":return t.stop()}}),t,this)})));return function(){return t.apply(this,arguments)}}(),n.getDomElement=function(){return this.$namespace},n.getContext=function(){return this.$namespace},n.getDPR=function(){return this.dpr},n.getBoundingClientRect=function(){var t;return null===(t=this.$namespace)||void 0===t?void 0:t.getBoundingClientRect()},n.destroy=function(){this.$container&&this.$namespace&&this.$namespace.parentNode&&this.$container.removeChild(this.$namespace)},n.resize=function(t,e){this.$namespace&&(this.$namespace.setAttribute("width",""+t),this.$namespace.setAttribute("height",""+e))},n.applyCursorStyle=function(t){this.$container&&(this.$container.style.cursor=t)},n.generateCSSText=function(t,e,r,n,i){void 0===i&&(i={});var o=n.duration,a=n.easing,s=n.delay,c=n.direction,l=n.iterations,f=n.fill;return"@keyframes "+t+"{"+r.map((function(t){var e=t.computedOffset,r=u(t,kt);return 100*e+"%{"+Object.keys(r).map((function(t){return t+":"+(i[t]||"")+r[t]+";"})).join("")+"}"})).join("")+"}"+e+" {animation: "+t+" "+o+"ms "+a+" "+s+"ms "+(l===1/0?"infinite":l)+" "+c+" "+f+";}"},n.toDataURL=function(){var t=i(r().mark((function t(n){var i,o,a,s,c,l,f=this;return r().wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=this.$namespace.cloneNode(!0),o=this.canvasConfig.document,a=0,s=null,this.context.renderingContext.root.forEach((function(t){var r=t.getAnimations();if(r.length){s||(s=(o||document).createElement("style"),i.appendChild(s));var n=t.elementSVG,c="#"+n.$el.id,l="#"+n.$groupEl.id,h="",d="";r.forEach((function(t){var r=t.effect.getKeyframes();if(r.length){var i=[],o=[],s=r[0],p=u(s,Tt);if(Object.keys(p).forEach((function(t){var r;"transform"===t&&o.push(t),!!(null===(r=e.propertyMetadataCache[t])||void 0===r?void 0:r.inh)?o.push(t):"transform"!==t&&i.push(t)})),o.length){var v=r.map((function(t){var e=t.offset,r=t.composite,n=t.computedOffset,i=t.easing,a=u(t,Pt),s={offset:e,composite:r,computedOffset:n,easing:i};return Object.keys(a).forEach((function(e){o.includes(e)&&(s[e]=t[e])})),s}));d+=f.generateCSSText("a"+a++,l,v,t.effect.getComputedTiming(),{transform:n.$groupEl.getAttribute("transform")})}if(i.length){var m=r.map((function(t){var e=t.offset,r=t.composite,n=t.computedOffset,o=t.easing,a=u(t,Gt),s={offset:e,composite:r,computedOffset:n,easing:o};return Object.keys(a).forEach((function(e){i.includes(e)&&(s[e]=t[e])})),s}));h+=f.generateCSSText("a"+a++,c,m,t.effect.getComputedTiming())}}})),s.textContent+=h+d}})),c=document.implementation.createDocumentType("svg","-//W3C//DTD SVG 1.1//EN","http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"),(l=document.implementation.createDocument("http://www.w3.org/2000/svg","svg",c)).replaceChild(i,l.documentElement),t.abrupt("return","data:image/svg+xml;charset=utf8,"+encodeURIComponent((new XMLSerializer).serializeToString(l)));case 10:case"end":return t.stop()}}),t,this)})));return function(e){return t.apply(this,arguments)}}(),t}(),_t=function(t){function e(){for(var e,r=arguments.length,n=Array(r),i=0;r>i;i++)n[i]=arguments[i];return(e=t.call.apply(t,[this].concat(n))||this).name="svg-context-register",e}o(e,t);var r=e.prototype;return r.init=function(){this.context.ContextService=Mt},r.destroy=function(){delete this.context.ContextService},e}(e.AbstractRendererPlugin),Nt=function(t){function e(e){var r;return void 0===e&&(e={}),(r=t.call(this,e)||this).registerPlugin(new _t),r.registerPlugin(new yt({outputSVGElementId:e.outputSVGElementId})),r.registerPlugin(new d),r.registerPlugin(new Lt),r}return o(e,t),e}(e.AbstractRenderer);t.DomInteraction=p,t.Renderer=Nt,t.SVGPicker=Ct,t.SVGRenderer=bt,Object.defineProperty(t,"__esModule",{value:!0})}));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antv/g-svg",
|
|
3
|
-
"version": "1.8.
|
|
3
|
+
"version": "1.8.31",
|
|
4
4
|
"description": "A renderer implemented by SVG",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"antv",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"sync": "tnpm sync"
|
|
31
31
|
},
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@antv/g-plugin-dom-interaction": "^1.7.
|
|
34
|
-
"@antv/g-plugin-svg-picker": "^1.7.
|
|
35
|
-
"@antv/g-plugin-svg-renderer": "^1.8.
|
|
33
|
+
"@antv/g-plugin-dom-interaction": "^1.7.34",
|
|
34
|
+
"@antv/g-plugin-svg-picker": "^1.7.34",
|
|
35
|
+
"@antv/g-plugin-svg-renderer": "^1.8.31",
|
|
36
36
|
"@antv/util": "^3.3.1",
|
|
37
37
|
"tslib": "^2.3.1"
|
|
38
38
|
},
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"publishConfig": {
|
|
47
47
|
"access": "public"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "d780322215f8ece20e3a2d8c137c02c0a6b57f84"
|
|
50
50
|
}
|