@antv/g 5.0.22-alpha.1 → 5.0.22-alpha.4
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/es/AbstractRenderer.js +1 -3
- package/es/Canvas.d.ts +0 -3
- package/es/Canvas.js +1 -3
- package/es/DisplayObjectPool.js +1 -3
- package/es/camera/Camera.js +1 -3
- package/es/camera/Landmark.js +1 -3
- package/es/components/Cullable.js +1 -3
- package/es/components/Geometry.js +1 -3
- package/es/components/Renderable.js +1 -3
- package/es/components/Sortable.js +1 -3
- package/es/components/Transform.js +1 -3
- package/es/css/CSSProperty.d.ts +1 -1
- package/es/css/LayoutRegistry.js +1 -3
- package/es/css/StyleValueRegistry.d.ts +2 -1
- package/es/css/StyleValueRegistry.js +6 -7
- package/es/css/cssom/CSSColorValue.js +1 -3
- package/es/css/cssom/CSSGradientValue.js +6 -8
- package/es/css/cssom/CSSKeywordValue.js +1 -3
- package/es/css/cssom/CSSMathInvert.js +1 -3
- package/es/css/cssom/CSSMathMax.js +1 -3
- package/es/css/cssom/CSSMathMin.js +1 -3
- package/es/css/cssom/CSSMathNegate.js +1 -3
- package/es/css/cssom/CSSMathProduct.js +1 -3
- package/es/css/cssom/CSSMathSum.js +1 -3
- package/es/css/cssom/CSSMathValue.js +1 -3
- package/es/css/cssom/CSSMathVariadic.js +1 -3
- package/es/css/cssom/CSSNumericValue.js +1 -3
- package/es/css/cssom/CSSNumericValueType.d.ts +1 -1
- package/es/css/cssom/CSSNumericValueType.js +1 -3
- package/es/css/cssom/CSSRGB.js +2 -4
- package/es/css/cssom/CSSStyleValue.d.ts +1 -1
- package/es/css/cssom/CSSStyleValue.js +1 -3
- package/es/css/cssom/CSSTransformComponent.js +1 -3
- package/es/css/cssom/CSSTransformValue.js +1 -3
- package/es/css/cssom/CSSTranslate.js +1 -3
- package/es/css/cssom/CSSUnitValue.js +2 -4
- package/es/css/parser/color.js +1 -1
- package/es/css/parser/dimension.js +1 -1
- package/es/css/parser/transform-origin.d.ts +1 -1
- package/es/css/parser/transform-origin.js +2 -2
- package/es/css/parser/transform.d.ts +1 -1
- package/es/css/parser/transform.js +2 -2
- package/es/css/properties/CSSPropertyAnchor.js +1 -3
- package/es/css/properties/CSSPropertyClipPath.js +1 -3
- package/es/css/properties/CSSPropertyColor.js +1 -3
- package/es/css/properties/CSSPropertyFilter.js +1 -3
- package/es/css/properties/CSSPropertyLengthOrPercentage.js +1 -3
- package/es/css/properties/CSSPropertyLineDash.js +1 -3
- package/es/css/properties/CSSPropertyLocalPosition.js +1 -3
- package/es/css/properties/CSSPropertyOffsetDistance.js +1 -3
- package/es/css/properties/CSSPropertyOffsetPath.js +1 -3
- package/es/css/properties/CSSPropertyOpacity.js +1 -3
- package/es/css/properties/CSSPropertyPath.js +1 -3
- package/es/css/properties/CSSPropertyPoints.js +1 -3
- package/es/css/properties/CSSPropertyShadowBlur.js +1 -3
- package/es/css/properties/CSSPropertyText.js +2 -4
- package/es/css/properties/CSSPropertyTextTransform.js +1 -3
- package/es/css/properties/CSSPropertyTransform.js +1 -3
- package/es/css/properties/CSSPropertyTransformOrigin.js +1 -3
- package/es/css/properties/CSSPropertyVisibility.js +1 -3
- package/es/css/properties/CSSPropertyZIndex.js +1 -3
- package/es/display-objects/Circle.js +1 -3
- package/es/display-objects/CustomElement.js +1 -3
- package/es/display-objects/DisplayObject.js +3 -6
- package/es/display-objects/Ellipse.js +1 -3
- package/es/display-objects/Group.js +1 -3
- package/es/display-objects/HTML.js +3 -6
- package/es/display-objects/Image.js +1 -3
- package/es/display-objects/Line.js +1 -3
- package/es/display-objects/Path.js +1 -3
- package/es/display-objects/Polygon.js +1 -3
- package/es/display-objects/Polyline.js +1 -3
- package/es/display-objects/Rect.js +1 -3
- package/es/display-objects/Text.js +3 -6
- package/es/dom/Animation.js +2 -4
- package/es/dom/AnimationEffectTiming.js +1 -3
- package/es/dom/AnimationEvent.js +1 -3
- package/es/dom/AnimationTimeline.js +1 -3
- package/es/dom/CustomElementRegistry.js +1 -3
- package/es/dom/CustomEvent.js +1 -3
- package/es/dom/Document.js +1 -3
- package/es/dom/Element.js +5 -7
- package/es/dom/EventTarget.js +3 -5
- package/es/dom/FederatedEvent.js +1 -3
- package/es/dom/FederatedMouseEvent.js +1 -3
- package/es/dom/FederatedPointerEvent.js +1 -3
- package/es/dom/FederatedWheelEvent.js +1 -3
- package/es/dom/KeyframeEffect.js +1 -3
- package/es/dom/KeyframeList.js +1 -1
- package/es/dom/MutationEvent.d.ts +1 -1
- package/es/dom/MutationEvent.js +1 -3
- package/es/dom/MutationObserver.d.ts +2 -1
- package/es/dom/MutationObserver.js +4 -11
- package/es/dom/MutationRecord.d.ts +1 -1
- package/es/dom/MutationRecord.js +1 -3
- package/es/dom/Node.js +3 -5
- package/es/dom/interfaces.d.ts +2 -1
- package/es/plugins/CullingPlugin.js +1 -3
- package/es/plugins/DirtyCheckPlugin.js +1 -3
- package/es/plugins/EventPlugin.js +1 -3
- package/es/plugins/FrustumCullingStrategy.js +2 -4
- package/es/plugins/PrepareRendererPlugin.d.ts +1 -1
- package/es/plugins/PrepareRendererPlugin.js +1 -3
- package/es/services/EventService.js +3 -5
- package/es/services/OffscreenCanvasCreator.js +1 -3
- package/es/services/RenderingService.d.ts +2 -2
- package/es/services/RenderingService.js +1 -3
- package/es/services/SceneGraphSelector.js +1 -3
- package/es/services/SceneGraphService.js +1 -3
- package/es/services/TextService.d.ts +2 -2
- package/es/services/TextService.js +5 -6
- package/es/services/aabb/CircleUpdater.js +1 -3
- package/es/services/aabb/EllipseUpdater.js +1 -3
- package/es/services/aabb/LineUpdater.js +1 -3
- package/es/services/aabb/PathUpdater.js +1 -3
- package/es/services/aabb/PolylineUpdater.js +1 -3
- package/es/services/aabb/RectUpdater.js +1 -3
- package/es/services/aabb/TextUpdater.js +1 -3
- package/es/shapes/AABB.js +1 -3
- package/es/shapes/BoundingSphere.js +1 -3
- package/es/shapes/Frustum.js +1 -3
- package/es/shapes/Plane.js +1 -3
- package/es/shapes/Point.js +1 -3
- package/es/shapes/Ray.js +1 -3
- package/es/shapes/Rectangle.js +1 -3
- package/es/types.d.ts +1 -2
- package/es/utils/custom-easing.js +1 -1
- package/es/utils/path.d.ts +2 -2
- package/es/utils/path.js +3 -3
- package/es/utils/text.js +3 -3
- package/lib/AbstractRenderer.js +1 -3
- package/lib/Canvas.d.ts +0 -3
- package/lib/Canvas.js +2 -4
- package/lib/DisplayObjectPool.js +1 -3
- package/lib/camera/Camera.js +2 -4
- package/lib/camera/Landmark.js +1 -3
- package/lib/components/Cullable.js +2 -4
- package/lib/components/Geometry.js +1 -3
- package/lib/components/Renderable.js +1 -3
- package/lib/components/Sortable.js +1 -3
- package/lib/components/Transform.js +1 -3
- package/lib/css/CSSProperty.d.ts +1 -1
- package/lib/css/LayoutRegistry.js +1 -3
- package/lib/css/StyleValueRegistry.d.ts +2 -1
- package/lib/css/StyleValueRegistry.js +15 -11
- package/lib/css/cssom/CSSColorValue.js +1 -3
- package/lib/css/cssom/CSSGradientValue.js +7 -9
- package/lib/css/cssom/CSSKeywordValue.js +1 -3
- package/lib/css/cssom/CSSMathInvert.js +1 -3
- package/lib/css/cssom/CSSMathMax.js +1 -3
- package/lib/css/cssom/CSSMathMin.js +1 -3
- package/lib/css/cssom/CSSMathNegate.js +1 -3
- package/lib/css/cssom/CSSMathOperator.js +1 -1
- package/lib/css/cssom/CSSMathProduct.js +1 -3
- package/lib/css/cssom/CSSMathSum.js +1 -3
- package/lib/css/cssom/CSSMathValue.js +1 -3
- package/lib/css/cssom/CSSMathVariadic.js +2 -4
- package/lib/css/cssom/CSSNumericValue.js +1 -3
- package/lib/css/cssom/CSSNumericValueType.d.ts +1 -1
- package/lib/css/cssom/CSSNumericValueType.js +3 -5
- package/lib/css/cssom/CSSRGB.js +2 -4
- package/lib/css/cssom/CSSStyleValue.d.ts +1 -1
- package/lib/css/cssom/CSSStyleValue.js +2 -4
- package/lib/css/cssom/CSSTransformComponent.js +2 -4
- package/lib/css/cssom/CSSTransformValue.js +1 -3
- package/lib/css/cssom/CSSTranslate.js +1 -3
- package/lib/css/cssom/CSSUnitValue.js +2 -4
- package/lib/css/cssom/types.js +1 -1
- package/lib/css/parser/color.js +3 -3
- package/lib/css/parser/dimension.js +6 -7
- package/lib/css/parser/numeric.js +3 -3
- package/lib/css/parser/path.js +1 -1
- package/lib/css/parser/transform-origin.d.ts +1 -1
- package/lib/css/parser/transform-origin.js +5 -3
- package/lib/css/parser/transform.d.ts +1 -1
- package/lib/css/parser/transform.js +11 -11
- package/lib/css/properties/CSSPropertyAnchor.js +1 -3
- package/lib/css/properties/CSSPropertyClipPath.js +1 -3
- package/lib/css/properties/CSSPropertyColor.js +1 -3
- package/lib/css/properties/CSSPropertyFilter.js +1 -3
- package/lib/css/properties/CSSPropertyLengthOrPercentage.js +1 -3
- package/lib/css/properties/CSSPropertyLineDash.js +1 -3
- package/lib/css/properties/CSSPropertyLocalPosition.js +1 -3
- package/lib/css/properties/CSSPropertyOffsetDistance.js +1 -3
- package/lib/css/properties/CSSPropertyOffsetPath.js +1 -3
- package/lib/css/properties/CSSPropertyOpacity.js +1 -3
- package/lib/css/properties/CSSPropertyPath.js +1 -3
- package/lib/css/properties/CSSPropertyPoints.js +1 -3
- package/lib/css/properties/CSSPropertyShadowBlur.js +1 -3
- package/lib/css/properties/CSSPropertyText.js +2 -4
- package/lib/css/properties/CSSPropertyTextTransform.js +1 -3
- package/lib/css/properties/CSSPropertyTransform.js +1 -3
- package/lib/css/properties/CSSPropertyTransformOrigin.js +1 -3
- package/lib/css/properties/CSSPropertyVisibility.js +1 -3
- package/lib/css/properties/CSSPropertyZIndex.js +1 -3
- package/lib/display-objects/Circle.js +1 -3
- package/lib/display-objects/CustomElement.js +1 -3
- package/lib/display-objects/DisplayObject.js +3 -6
- package/lib/display-objects/Ellipse.js +1 -3
- package/lib/display-objects/Group.js +1 -3
- package/lib/display-objects/HTML.js +4 -6
- package/lib/display-objects/Image.js +1 -3
- package/lib/display-objects/Line.js +1 -3
- package/lib/display-objects/Path.js +1 -3
- package/lib/display-objects/Polygon.js +1 -3
- package/lib/display-objects/Polyline.js +1 -3
- package/lib/display-objects/Rect.js +1 -3
- package/lib/display-objects/Text.js +4 -6
- package/lib/dom/Animation.js +2 -4
- package/lib/dom/AnimationEffectTiming.js +1 -3
- package/lib/dom/AnimationEvent.js +1 -3
- package/lib/dom/AnimationTimeline.js +2 -4
- package/lib/dom/CustomElementRegistry.js +1 -3
- package/lib/dom/CustomEvent.js +1 -3
- package/lib/dom/Document.js +1 -3
- package/lib/dom/Element.js +7 -9
- package/lib/dom/EventTarget.js +3 -5
- package/lib/dom/FederatedEvent.js +1 -3
- package/lib/dom/FederatedMouseEvent.js +1 -3
- package/lib/dom/FederatedPointerEvent.js +1 -3
- package/lib/dom/FederatedWheelEvent.js +1 -3
- package/lib/dom/KeyframeEffect.js +2 -4
- package/lib/dom/KeyframeList.js +1 -1
- package/lib/dom/MutationEvent.d.ts +1 -1
- package/lib/dom/MutationEvent.js +1 -3
- package/lib/dom/MutationObserver.d.ts +2 -1
- package/lib/dom/MutationObserver.js +15 -22
- package/lib/dom/MutationRecord.d.ts +1 -1
- package/lib/dom/MutationRecord.js +1 -3
- package/lib/dom/Node.js +6 -8
- package/lib/dom/interfaces.d.ts +2 -1
- package/lib/index.js +1 -1
- package/lib/plugins/CullingPlugin.js +2 -4
- package/lib/plugins/DirtyCheckPlugin.js +1 -3
- package/lib/plugins/EventPlugin.js +1 -3
- package/lib/plugins/FrustumCullingStrategy.js +3 -5
- package/lib/plugins/PrepareRendererPlugin.d.ts +1 -1
- package/lib/plugins/PrepareRendererPlugin.js +1 -3
- package/lib/services/EventService.js +3 -5
- package/lib/services/OffscreenCanvasCreator.js +1 -3
- package/lib/services/RenderingService.d.ts +2 -2
- package/lib/services/RenderingService.js +1 -3
- package/lib/services/SceneGraphSelector.js +2 -4
- package/lib/services/SceneGraphService.js +3 -5
- package/lib/services/TextService.d.ts +2 -2
- package/lib/services/TextService.js +8 -8
- package/lib/services/aabb/CircleUpdater.js +1 -3
- package/lib/services/aabb/EllipseUpdater.js +1 -3
- package/lib/services/aabb/LineUpdater.js +1 -3
- package/lib/services/aabb/PathUpdater.js +1 -3
- package/lib/services/aabb/PolylineUpdater.js +1 -3
- package/lib/services/aabb/RectUpdater.js +1 -3
- package/lib/services/aabb/TextUpdater.js +1 -3
- package/lib/services/aabb/index.js +10 -10
- package/lib/services/aabb/interfaces.js +1 -1
- package/lib/shapes/AABB.js +1 -3
- package/lib/shapes/BoundingSphere.js +1 -3
- package/lib/shapes/Frustum.js +2 -4
- package/lib/shapes/Plane.js +1 -3
- package/lib/shapes/Point.js +1 -3
- package/lib/shapes/Ray.js +1 -3
- package/lib/shapes/Rectangle.js +1 -3
- package/lib/types.d.ts +1 -2
- package/lib/types.js +1 -1
- package/lib/utils/animation.js +2 -3
- package/lib/utils/bezier-easing.js +1 -1
- package/lib/utils/custom-easing.js +2 -2
- package/lib/utils/math.js +9 -9
- package/lib/utils/path.d.ts +2 -2
- package/lib/utils/path.js +6 -6
- package/lib/utils/text.js +3 -3
- package/package.json +1 -1
- package/dist/index.umd.min.js +0 -30
|
@@ -28,9 +28,7 @@ var _ = require("../..");
|
|
|
28
28
|
}
|
|
29
29
|
});
|
|
30
30
|
*/
|
|
31
|
-
var CSSPropertyClipPath =
|
|
32
|
-
/** @class */
|
|
33
|
-
function () {
|
|
31
|
+
var CSSPropertyClipPath = function () {
|
|
34
32
|
function CSSPropertyClipPath() {}
|
|
35
33
|
|
|
36
34
|
CSSPropertyClipPath.prototype.calculator = function (name, oldClipPath, newClipPath, object) {
|
|
@@ -14,9 +14,7 @@ var _ = require("../..");
|
|
|
14
14
|
/**
|
|
15
15
|
* <length> & <percentage>
|
|
16
16
|
*/
|
|
17
|
-
var CSSPropertyLengthOrPercentage =
|
|
18
|
-
/** @class */
|
|
19
|
-
function () {
|
|
17
|
+
var CSSPropertyLengthOrPercentage = function () {
|
|
20
18
|
function CSSPropertyLengthOrPercentage() {
|
|
21
19
|
this.parser = _.parseLengthOrPercentage;
|
|
22
20
|
this.mixer = _.mergeDimensions;
|
|
@@ -11,9 +11,7 @@ var _manaSyringe = require("mana-syringe");
|
|
|
11
11
|
|
|
12
12
|
var _ = require("../..");
|
|
13
13
|
|
|
14
|
-
var CSSPropertyLineDash =
|
|
15
|
-
/** @class */
|
|
16
|
-
function () {
|
|
14
|
+
var CSSPropertyLineDash = function () {
|
|
17
15
|
function CSSPropertyLineDash() {
|
|
18
16
|
this.parser = _.parseDimensionArray;
|
|
19
17
|
this.mixer = _.mergeDimensionList;
|
|
@@ -16,9 +16,7 @@ var _CSSPropertyLengthOrPercentage = require("./CSSPropertyLengthOrPercentage");
|
|
|
16
16
|
/**
|
|
17
17
|
* local position
|
|
18
18
|
*/
|
|
19
|
-
var CSSPropertyLocalPosition =
|
|
20
|
-
/** @class */
|
|
21
|
-
function (_super) {
|
|
19
|
+
var CSSPropertyLocalPosition = function (_super) {
|
|
22
20
|
(0, _tslib.__extends)(CSSPropertyLocalPosition, _super);
|
|
23
21
|
|
|
24
22
|
function CSSPropertyLocalPosition() {
|
|
@@ -11,9 +11,7 @@ var _manaSyringe = require("mana-syringe");
|
|
|
11
11
|
|
|
12
12
|
var _ = require("../..");
|
|
13
13
|
|
|
14
|
-
var CSSPropertyOffsetDistance =
|
|
15
|
-
/** @class */
|
|
16
|
-
function () {
|
|
14
|
+
var CSSPropertyOffsetDistance = function () {
|
|
17
15
|
function CSSPropertyOffsetDistance() {
|
|
18
16
|
this.parser = _.parseNumber;
|
|
19
17
|
this.mixer = (0, _.clampedMergeNumbers)(0, 1);
|
|
@@ -9,9 +9,7 @@ var _tslib = require("tslib");
|
|
|
9
9
|
|
|
10
10
|
var _manaSyringe = require("mana-syringe");
|
|
11
11
|
|
|
12
|
-
var CSSPropertyOffsetPath =
|
|
13
|
-
/** @class */
|
|
14
|
-
function () {
|
|
12
|
+
var CSSPropertyOffsetPath = function () {
|
|
15
13
|
function CSSPropertyOffsetPath() {}
|
|
16
14
|
|
|
17
15
|
CSSPropertyOffsetPath.prototype.calculator = function (name, oldOffsetPath, newOffsetPath, object) {
|
|
@@ -14,9 +14,7 @@ var _ = require("../..");
|
|
|
14
14
|
/**
|
|
15
15
|
* opacity
|
|
16
16
|
*/
|
|
17
|
-
var CSSPropertyOpacity =
|
|
18
|
-
/** @class */
|
|
19
|
-
function () {
|
|
17
|
+
var CSSPropertyOpacity = function () {
|
|
20
18
|
function CSSPropertyOpacity() {
|
|
21
19
|
this.parser = _.parseNumber;
|
|
22
20
|
this.mixer = (0, _.clampedMergeNumbers)(0, 1);
|
|
@@ -13,9 +13,7 @@ var _ = require("../..");
|
|
|
13
13
|
|
|
14
14
|
var _CSSPropertyLengthOrPercentage = require("./CSSPropertyLengthOrPercentage");
|
|
15
15
|
|
|
16
|
-
var CSSPropertyShadowBlur =
|
|
17
|
-
/** @class */
|
|
18
|
-
function (_super) {
|
|
16
|
+
var CSSPropertyShadowBlur = function (_super) {
|
|
19
17
|
(0, _tslib.__extends)(CSSPropertyShadowBlur, _super);
|
|
20
18
|
|
|
21
19
|
function CSSPropertyShadowBlur() {
|
|
@@ -11,9 +11,7 @@ var _manaSyringe = require("mana-syringe");
|
|
|
11
11
|
|
|
12
12
|
var _ = require("../..");
|
|
13
13
|
|
|
14
|
-
var CSSPropertyText =
|
|
15
|
-
/** @class */
|
|
16
|
-
function () {
|
|
14
|
+
var CSSPropertyText = function () {
|
|
17
15
|
function CSSPropertyText() {}
|
|
18
16
|
|
|
19
17
|
CSSPropertyText.prototype.calculator = function (name, oldParsed, parsed, object) {
|
|
@@ -29,7 +27,7 @@ function () {
|
|
|
29
27
|
};
|
|
30
28
|
|
|
31
29
|
CSSPropertyText.prototype.postProcessor = function (object) {
|
|
32
|
-
object.nodeValue = ""
|
|
30
|
+
object.nodeValue = "" + object.parsedStyle.text || '';
|
|
33
31
|
};
|
|
34
32
|
|
|
35
33
|
CSSPropertyText = (0, _tslib.__decorate)([(0, _manaSyringe.singleton)()], CSSPropertyText);
|
|
@@ -11,9 +11,7 @@ var _manaSyringe = require("mana-syringe");
|
|
|
11
11
|
|
|
12
12
|
var _ = require("../..");
|
|
13
13
|
|
|
14
|
-
var CSSPropertyTextTransform =
|
|
15
|
-
/** @class */
|
|
16
|
-
function () {
|
|
14
|
+
var CSSPropertyTextTransform = function () {
|
|
17
15
|
function CSSPropertyTextTransform() {}
|
|
18
16
|
|
|
19
17
|
CSSPropertyTextTransform.prototype.postProcessor = function (o) {
|
|
@@ -45,9 +45,7 @@ var _cssom = require("../cssom");
|
|
|
45
45
|
* * skew/skewX/skewY
|
|
46
46
|
* * perspective
|
|
47
47
|
*/
|
|
48
|
-
var CSSPropertyTransform =
|
|
49
|
-
/** @class */
|
|
50
|
-
function () {
|
|
48
|
+
var CSSPropertyTransform = function () {
|
|
51
49
|
function CSSPropertyTransform() {
|
|
52
50
|
this.parser = _.parseTransform;
|
|
53
51
|
this.mixer = _.mergeTransforms;
|
|
@@ -16,9 +16,7 @@ var _ = require("../..");
|
|
|
16
16
|
* @example
|
|
17
17
|
* [10px, 10px] [10%, 10%]
|
|
18
18
|
*/
|
|
19
|
-
var CSSPropertyTransformOrigin =
|
|
20
|
-
/** @class */
|
|
21
|
-
function () {
|
|
19
|
+
var CSSPropertyTransformOrigin = function () {
|
|
22
20
|
function CSSPropertyTransformOrigin() {
|
|
23
21
|
this.parser = _.parseTransformOrigin;
|
|
24
22
|
}
|
|
@@ -16,9 +16,7 @@ var _manaSyringe = require("mana-syringe");
|
|
|
16
16
|
* @see https://www.w3.org/TR/CSS21/visufx.html#visibility
|
|
17
17
|
*
|
|
18
18
|
*/
|
|
19
|
-
var CSSPropertyVisibility =
|
|
20
|
-
/** @class */
|
|
21
|
-
function () {
|
|
19
|
+
var CSSPropertyVisibility = function () {
|
|
22
20
|
function CSSPropertyVisibility() {}
|
|
23
21
|
|
|
24
22
|
CSSPropertyVisibility.prototype.calculator = function (name, oldParsed, parsed, object) {
|
|
@@ -15,9 +15,7 @@ var _interfaces = require("../dom/interfaces");
|
|
|
15
15
|
* shadow root
|
|
16
16
|
* @see https://yuque.antfin-inc.com/antv/czqvg5/pgqipg
|
|
17
17
|
*/
|
|
18
|
-
var CustomElement =
|
|
19
|
-
/** @class */
|
|
20
|
-
function (_super) {
|
|
18
|
+
var CustomElement = function (_super) {
|
|
21
19
|
(0, _tslib.__extends)(CustomElement, _super); // private shadowNodes: DisplayObject[] = [];
|
|
22
20
|
|
|
23
21
|
function CustomElement(config) {
|
|
@@ -78,17 +78,14 @@ var DEFAULT_STYLE_PROPS = {
|
|
|
78
78
|
* * attributeChanged
|
|
79
79
|
*/
|
|
80
80
|
|
|
81
|
-
var DisplayObject =
|
|
82
|
-
/** @class */
|
|
83
|
-
function (_super) {
|
|
81
|
+
var DisplayObject = function (_super) {
|
|
84
82
|
(0, _tslib.__extends)(DisplayObject, _super);
|
|
85
83
|
|
|
86
84
|
function DisplayObject(config) {
|
|
87
|
-
var _this = this;
|
|
88
|
-
|
|
89
85
|
var _a, _b, _c;
|
|
90
86
|
|
|
91
|
-
_this = _super.call(this) || this;
|
|
87
|
+
var _this = _super.call(this) || this;
|
|
88
|
+
|
|
92
89
|
_this.styleValueRegistry = _manaSyringe.GlobalContainer.get(_StyleValueRegistry.StyleValueRegistry);
|
|
93
90
|
/**
|
|
94
91
|
* push to active animations after calling `animate()`
|
|
@@ -11,9 +11,7 @@ var _types = require("../types");
|
|
|
11
11
|
|
|
12
12
|
var _DisplayObject = require("./DisplayObject");
|
|
13
13
|
|
|
14
|
-
var Ellipse =
|
|
15
|
-
/** @class */
|
|
16
|
-
function (_super) {
|
|
14
|
+
var Ellipse = function (_super) {
|
|
17
15
|
(0, _tslib.__extends)(Ellipse, _super);
|
|
18
16
|
|
|
19
17
|
function Ellipse(_a) {
|
|
@@ -21,9 +21,7 @@ var _DisplayObject = require("./DisplayObject");
|
|
|
21
21
|
<circle cx="60" cy="60" r="25" />
|
|
22
22
|
</g>
|
|
23
23
|
*/
|
|
24
|
-
var Group =
|
|
25
|
-
/** @class */
|
|
26
|
-
function (_super) {
|
|
24
|
+
var Group = function (_super) {
|
|
27
25
|
(0, _tslib.__extends)(Group, _super);
|
|
28
26
|
|
|
29
27
|
function Group(_a) {
|
|
@@ -19,9 +19,7 @@ var _glMatrix = require("gl-matrix");
|
|
|
19
19
|
* HTML container
|
|
20
20
|
* @see https://github.com/pmndrs/drei#html
|
|
21
21
|
*/
|
|
22
|
-
var HTML =
|
|
23
|
-
/** @class */
|
|
24
|
-
function (_super) {
|
|
22
|
+
var HTML = function (_super) {
|
|
25
23
|
(0, _tslib.__extends)(HTML, _super);
|
|
26
24
|
|
|
27
25
|
function HTML(_a) {
|
|
@@ -29,11 +27,10 @@ function (_super) {
|
|
|
29
27
|
_a = {};
|
|
30
28
|
}
|
|
31
29
|
|
|
32
|
-
var _this = this;
|
|
33
|
-
|
|
34
30
|
var style = _a.style,
|
|
35
31
|
rest = (0, _tslib.__rest)(_a, ["style"]);
|
|
36
|
-
|
|
32
|
+
|
|
33
|
+
var _this = _super.call(this, (0, _tslib.__assign)({
|
|
37
34
|
type: _types.Shape.HTML,
|
|
38
35
|
style: (0, _tslib.__assign)({
|
|
39
36
|
innerHTML: '',
|
|
@@ -41,6 +38,7 @@ function (_super) {
|
|
|
41
38
|
style: ''
|
|
42
39
|
}, style)
|
|
43
40
|
}, rest)) || this;
|
|
41
|
+
|
|
44
42
|
_this.cullable.enable = false;
|
|
45
43
|
return _this;
|
|
46
44
|
}
|
|
@@ -11,9 +11,7 @@ var _types = require("../types");
|
|
|
11
11
|
|
|
12
12
|
var _DisplayObject = require("./DisplayObject");
|
|
13
13
|
|
|
14
|
-
var Polygon =
|
|
15
|
-
/** @class */
|
|
16
|
-
function (_super) {
|
|
14
|
+
var Polygon = function (_super) {
|
|
17
15
|
(0, _tslib.__extends)(Polygon, _super);
|
|
18
16
|
|
|
19
17
|
function Polygon(_a) {
|
|
@@ -15,9 +15,7 @@ var _DisplayObject = require("./DisplayObject");
|
|
|
15
15
|
|
|
16
16
|
var _shapes = require("../shapes");
|
|
17
17
|
|
|
18
|
-
var Polyline =
|
|
19
|
-
/** @class */
|
|
20
|
-
function (_super) {
|
|
18
|
+
var Polyline = function (_super) {
|
|
21
19
|
(0, _tslib.__extends)(Polyline, _super);
|
|
22
20
|
|
|
23
21
|
function Polyline(_a) {
|
|
@@ -14,9 +14,7 @@ var _DisplayObject = require("./DisplayObject");
|
|
|
14
14
|
/**
|
|
15
15
|
* <text> @see https://developer.mozilla.org/en-US/docs/Web/API/SVGTextElement
|
|
16
16
|
*/
|
|
17
|
-
var Text =
|
|
18
|
-
/** @class */
|
|
19
|
-
function (_super) {
|
|
17
|
+
var Text = function (_super) {
|
|
20
18
|
(0, _tslib.__extends)(Text, _super);
|
|
21
19
|
|
|
22
20
|
function Text(_a) {
|
|
@@ -24,11 +22,10 @@ function (_super) {
|
|
|
24
22
|
_a = {};
|
|
25
23
|
}
|
|
26
24
|
|
|
27
|
-
var _this = this;
|
|
28
|
-
|
|
29
25
|
var style = _a.style,
|
|
30
26
|
rest = (0, _tslib.__rest)(_a, ["style"]);
|
|
31
|
-
|
|
27
|
+
|
|
28
|
+
var _this = _super.call(this, (0, _tslib.__assign)({
|
|
32
29
|
type: _types.Shape.TEXT,
|
|
33
30
|
style: (0, _tslib.__assign)({
|
|
34
31
|
text: '',
|
|
@@ -64,6 +61,7 @@ function (_super) {
|
|
|
64
61
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/SVGTextContentElement#constants
|
|
65
62
|
*/
|
|
66
63
|
|
|
64
|
+
|
|
67
65
|
_this.LENGTHADJUST_SPACING = 1;
|
|
68
66
|
_this.LENGTHADJUST_SPACINGANDGLYPHS = 2;
|
|
69
67
|
_this.LENGTHADJUST_UNKNOWN = 0;
|
package/lib/dom/Animation.js
CHANGED
|
@@ -12,9 +12,7 @@ var sequenceNumber = 0;
|
|
|
12
12
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/Animation/Animation
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
var Animation =
|
|
16
|
-
/** @class */
|
|
17
|
-
function () {
|
|
15
|
+
var Animation = function () {
|
|
18
16
|
function Animation(effect, timeline) {
|
|
19
17
|
this.currentTimePending = false;
|
|
20
18
|
/**
|
|
@@ -31,7 +29,7 @@ function () {
|
|
|
31
29
|
this.effect = effect;
|
|
32
30
|
effect.animation = this;
|
|
33
31
|
this.timeline = timeline;
|
|
34
|
-
this.id = ""
|
|
32
|
+
this.id = "" + sequenceNumber++;
|
|
35
33
|
this._inEffect = !!this.effect.update(0);
|
|
36
34
|
this._holdTime = 0;
|
|
37
35
|
this._paused = false;
|
|
@@ -10,9 +10,7 @@ var _animation = require("../utils/animation");
|
|
|
10
10
|
/**
|
|
11
11
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/EffectTiming
|
|
12
12
|
*/
|
|
13
|
-
var AnimationEffectTiming =
|
|
14
|
-
/** @class */
|
|
15
|
-
function () {
|
|
13
|
+
var AnimationEffectTiming = function () {
|
|
16
14
|
function AnimationEffectTiming() {
|
|
17
15
|
/**
|
|
18
16
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/EffectTiming/delay
|
|
@@ -12,9 +12,7 @@ var _FederatedEvent = require("./FederatedEvent");
|
|
|
12
12
|
/**
|
|
13
13
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/AnimationPlaybackEvent
|
|
14
14
|
*/
|
|
15
|
-
var AnimationEvent =
|
|
16
|
-
/** @class */
|
|
17
|
-
function (_super) {
|
|
15
|
+
var AnimationEvent = function (_super) {
|
|
18
16
|
(0, _tslib.__extends)(AnimationEvent, _super);
|
|
19
17
|
|
|
20
18
|
function AnimationEvent(manager, target, currentTime, timelineTime) {
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.AnimationTimeline = void 0;
|
|
7
6
|
exports.compareAnimations = compareAnimations;
|
|
7
|
+
exports.AnimationTimeline = void 0;
|
|
8
8
|
|
|
9
9
|
var _tslib = require("tslib");
|
|
10
10
|
|
|
@@ -18,9 +18,7 @@ function compareAnimations(leftAnimation, rightAnimation) {
|
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
var AnimationTimeline =
|
|
22
|
-
/** @class */
|
|
23
|
-
function () {
|
|
21
|
+
var AnimationTimeline = function () {
|
|
24
22
|
function AnimationTimeline(document) {
|
|
25
23
|
var _this = this;
|
|
26
24
|
|
|
@@ -14,9 +14,7 @@ var _displayObjects = require("../display-objects");
|
|
|
14
14
|
*
|
|
15
15
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/CustomElementRegistry
|
|
16
16
|
*/
|
|
17
|
-
var CustomElementRegistry =
|
|
18
|
-
/** @class */
|
|
19
|
-
function () {
|
|
17
|
+
var CustomElementRegistry = function () {
|
|
20
18
|
function CustomElementRegistry() {
|
|
21
19
|
this.registry = {};
|
|
22
20
|
this.define(_types.Shape.CIRCLE, _displayObjects.Circle);
|
package/lib/dom/CustomEvent.js
CHANGED
|
@@ -21,9 +21,7 @@ var _FederatedEvent = require("./FederatedEvent");
|
|
|
21
21
|
|
|
22
22
|
circle.dispatchEvent(event);
|
|
23
23
|
*/
|
|
24
|
-
var CustomEvent =
|
|
25
|
-
/** @class */
|
|
26
|
-
function (_super) {
|
|
24
|
+
var CustomEvent = function (_super) {
|
|
27
25
|
(0, _tslib.__extends)(CustomEvent, _super); // eslint-disable-next-line @typescript-eslint/ban-types
|
|
28
26
|
|
|
29
27
|
function CustomEvent(eventName, object) {
|
package/lib/dom/Document.js
CHANGED
|
@@ -20,9 +20,7 @@ var _css = require("../css");
|
|
|
20
20
|
* Document -> Node -> EventTarget
|
|
21
21
|
* @see https://developer.mozilla.org/en-US/docs/Web/API/Document
|
|
22
22
|
*/
|
|
23
|
-
var Document =
|
|
24
|
-
/** @class */
|
|
25
|
-
function (_super) {
|
|
23
|
+
var Document = function (_super) {
|
|
26
24
|
(0, _tslib.__extends)(Document, _super);
|
|
27
25
|
|
|
28
26
|
function Document() {
|
package/lib/dom/Element.js
CHANGED
|
@@ -21,7 +21,7 @@ var _interfaces = require("./interfaces");
|
|
|
21
21
|
|
|
22
22
|
var _utils = require("../utils");
|
|
23
23
|
|
|
24
|
-
var
|
|
24
|
+
var _MutationEvent = require("./MutationEvent");
|
|
25
25
|
|
|
26
26
|
var entityCounter = 0;
|
|
27
27
|
/**
|
|
@@ -31,9 +31,7 @@ var entityCounter = 0;
|
|
|
31
31
|
* * Animation
|
|
32
32
|
*/
|
|
33
33
|
|
|
34
|
-
var Element =
|
|
35
|
-
/** @class */
|
|
36
|
-
function (_super) {
|
|
34
|
+
var Element = function (_super) {
|
|
37
35
|
(0, _tslib.__extends)(Element, _super);
|
|
38
36
|
|
|
39
37
|
function Element() {
|
|
@@ -191,7 +189,7 @@ function (_super) {
|
|
|
191
189
|
// index,
|
|
192
190
|
// });
|
|
193
191
|
|
|
194
|
-
child.dispatchEvent(new
|
|
192
|
+
child.dispatchEvent(new _MutationEvent.MutationEvent(_interfaces.ElementEvent.INSERTED, this, '', '', '', 0, '', ''));
|
|
195
193
|
return child;
|
|
196
194
|
};
|
|
197
195
|
|
|
@@ -222,7 +220,7 @@ function (_super) {
|
|
|
222
220
|
destroy = true;
|
|
223
221
|
}
|
|
224
222
|
|
|
225
|
-
child.dispatchEvent(new
|
|
223
|
+
child.dispatchEvent(new _MutationEvent.MutationEvent(_interfaces.ElementEvent.REMOVED, this, '', '', '', 0, '', '')); // emit destroy event
|
|
226
224
|
|
|
227
225
|
if (destroy) {
|
|
228
226
|
child.emit(_interfaces.ElementEvent.DESTROY, {});
|
|
@@ -266,15 +264,15 @@ function (_super) {
|
|
|
266
264
|
};
|
|
267
265
|
|
|
268
266
|
Element.prototype.getElementById = function (id) {
|
|
269
|
-
return this.sceneGraphService.querySelector("#"
|
|
267
|
+
return this.sceneGraphService.querySelector("#" + id, this);
|
|
270
268
|
};
|
|
271
269
|
|
|
272
270
|
Element.prototype.getElementsByName = function (name) {
|
|
273
|
-
return this.sceneGraphService.querySelectorAll("[name=\""
|
|
271
|
+
return this.sceneGraphService.querySelectorAll("[name=\"" + name + "\"]", this);
|
|
274
272
|
};
|
|
275
273
|
|
|
276
274
|
Element.prototype.getElementsByClassName = function (className) {
|
|
277
|
-
return this.sceneGraphService.querySelectorAll("."
|
|
275
|
+
return this.sceneGraphService.querySelectorAll("." + className, this);
|
|
278
276
|
};
|
|
279
277
|
|
|
280
278
|
Element.prototype.getElementsByTagName = function (tagName) {
|
package/lib/dom/EventTarget.js
CHANGED
|
@@ -24,9 +24,7 @@ var DELEGATION_SPLITTER = ':';
|
|
|
24
24
|
|
|
25
25
|
exports.DELEGATION_SPLITTER = DELEGATION_SPLITTER;
|
|
26
26
|
|
|
27
|
-
var EventTarget =
|
|
28
|
-
/** @class */
|
|
29
|
-
function () {
|
|
27
|
+
var EventTarget = function () {
|
|
30
28
|
function EventTarget() {
|
|
31
29
|
/**
|
|
32
30
|
* event emitter
|
|
@@ -68,7 +66,7 @@ function () {
|
|
|
68
66
|
useDelegatedName = true;
|
|
69
67
|
}
|
|
70
68
|
|
|
71
|
-
type = capture ?
|
|
69
|
+
type = capture ? type + "capture" : type;
|
|
72
70
|
listener = (0, _util.isFunction)(listener) ? listener : listener.handleEvent; // compatible with G 3.0
|
|
73
71
|
|
|
74
72
|
if (useDelegatedName) {
|
|
@@ -124,7 +122,7 @@ function () {
|
|
|
124
122
|
EventTarget.prototype.removeEventListener = function (type, listener, options) {
|
|
125
123
|
var capture = (0, _util.isBoolean)(options) && options || (0, _util.isObject)(options) && options.capture;
|
|
126
124
|
var context = (0, _util.isFunction)(listener) ? undefined : listener;
|
|
127
|
-
type = capture ?
|
|
125
|
+
type = capture ? type + "capture" : type;
|
|
128
126
|
listener = (0, _util.isFunction)(listener) ? listener : listener === null || listener === void 0 ? void 0 : listener.handleEvent;
|
|
129
127
|
this.emitter.off(type, listener, context);
|
|
130
128
|
return this;
|
|
@@ -11,9 +11,7 @@ var _Point = require("../shapes/Point");
|
|
|
11
11
|
* An DOM-compatible synthetic event implementation that is "forwarded" on behalf of an original
|
|
12
12
|
* FederatedEvent or native {@link https://dom.spec.whatwg.org/#event Event}.
|
|
13
13
|
*/
|
|
14
|
-
var FederatedEvent =
|
|
15
|
-
/** @class */
|
|
16
|
-
function () {
|
|
14
|
+
var FederatedEvent = function () {
|
|
17
15
|
/**
|
|
18
16
|
* The event boundary which manages this event. Propagation can only occur
|
|
19
17
|
* within the boundary's jurisdiction.
|
|
@@ -11,9 +11,7 @@ var _FederatedEvent = require("./FederatedEvent");
|
|
|
11
11
|
|
|
12
12
|
var _Point = require("../shapes/Point");
|
|
13
13
|
|
|
14
|
-
var FederatedMouseEvent =
|
|
15
|
-
/** @class */
|
|
16
|
-
function (_super) {
|
|
14
|
+
var FederatedMouseEvent = function (_super) {
|
|
17
15
|
(0, _tslib.__extends)(FederatedMouseEvent, _super);
|
|
18
16
|
|
|
19
17
|
function FederatedMouseEvent() {
|