@visactor/vrender-core 1.1.0-alpha.1 → 1.1.0-alpha.11

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.
Files changed (104) hide show
  1. package/cjs/canvas/constants.js +1 -2
  2. package/cjs/canvas/empty-context.js +2 -1
  3. package/cjs/common/canvas-utils.js +0 -1
  4. package/cjs/common/diff.js +2 -1
  5. package/cjs/common/explicit-binding.js +1 -1
  6. package/cjs/common/generator.js +1 -1
  7. package/cjs/common/matrix.js +1 -1
  8. package/cjs/common/morphing-utils.js +1 -1
  9. package/cjs/common/path-svg.js +1 -1
  10. package/cjs/common/performance-raf.js +1 -1
  11. package/cjs/common/polygon.js +2 -2
  12. package/cjs/common/rect-utils.js +1 -1
  13. package/cjs/common/render-area.js +1 -1
  14. package/cjs/common/render-command-list.js +1 -1
  15. package/cjs/common/render-curve.js +1 -1
  16. package/cjs/common/render-utils.js +1 -1
  17. package/cjs/common/seg-context.js +2 -1
  18. package/cjs/common/simplify.js +1 -1
  19. package/cjs/common/sort.js +1 -1
  20. package/cjs/common/split-path.js +1 -1
  21. package/cjs/common/store.js +1 -1
  22. package/cjs/common/text.js +1 -1
  23. package/cjs/common/utils.js +1 -1
  24. package/cjs/core/application.js +1 -1
  25. package/cjs/core/camera.js +1 -1
  26. package/cjs/core/constants.js +1 -1
  27. package/cjs/core/core-modules.js +1 -1
  28. package/cjs/core/global-module.js +0 -2
  29. package/cjs/core/global.js +1 -1
  30. package/cjs/core/graphic-utils.js +1 -1
  31. package/cjs/core/index.js +1 -1
  32. package/cjs/core/layer-service.js +1 -2
  33. package/cjs/core/layer.js +1 -1
  34. package/cjs/core/light.js +1 -1
  35. package/cjs/core/stage.js +1 -1
  36. package/cjs/core/window.js +1 -1
  37. package/cjs/entries/browser.js +1 -1
  38. package/cjs/entries/index.js +1 -1
  39. package/cjs/entries/miniapp.js +1 -1
  40. package/cjs/entries/node.js +1 -1
  41. package/cjs/entries/runtime-installer.js +1 -1
  42. package/cjs/entries/types.js +1 -1
  43. package/cjs/graphic/graphic.d.ts +4 -1
  44. package/cjs/graphic/graphic.js +39 -13
  45. package/cjs/graphic/graphic.js.map +1 -1
  46. package/cjs/graphic/rect.d.ts +2 -0
  47. package/cjs/graphic/rect.js +44 -0
  48. package/cjs/graphic/rect.js.map +1 -1
  49. package/cjs/graphic/state/state-transition-orchestrator.d.ts +5 -0
  50. package/cjs/graphic/state/state-transition-orchestrator.js +17 -5
  51. package/cjs/graphic/state/state-transition-orchestrator.js.map +1 -1
  52. package/dist/index.es.js +151 -20
  53. package/es/canvas/constants.js +1 -2
  54. package/es/canvas/empty-context.js +2 -1
  55. package/es/common/canvas-utils.js +1 -2
  56. package/es/common/diff.js +2 -1
  57. package/es/common/explicit-binding.js +1 -1
  58. package/es/common/generator.js +1 -1
  59. package/es/common/matrix.js +1 -1
  60. package/es/common/morphing-utils.js +1 -1
  61. package/es/common/path-svg.js +1 -1
  62. package/es/common/performance-raf.js +1 -1
  63. package/es/common/polygon.js +1 -1
  64. package/es/common/rect-utils.js +1 -1
  65. package/es/common/render-area.js +1 -1
  66. package/es/common/render-command-list.js +1 -1
  67. package/es/common/render-curve.js +1 -1
  68. package/es/common/render-utils.js +1 -1
  69. package/es/common/seg-context.js +2 -1
  70. package/es/common/simplify.js +1 -1
  71. package/es/common/sort.js +1 -1
  72. package/es/common/split-path.js +1 -1
  73. package/es/common/store.js +1 -1
  74. package/es/common/text.js +1 -1
  75. package/es/common/utils.js +1 -1
  76. package/es/core/application.js +1 -1
  77. package/es/core/camera.js +1 -1
  78. package/es/core/constants.js +1 -1
  79. package/es/core/core-modules.js +1 -1
  80. package/es/core/global-module.js +0 -2
  81. package/es/core/global.js +1 -1
  82. package/es/core/graphic-utils.js +1 -1
  83. package/es/core/index.js +1 -1
  84. package/es/core/layer-service.js +1 -2
  85. package/es/core/layer.js +1 -1
  86. package/es/core/light.js +1 -1
  87. package/es/core/stage.js +1 -1
  88. package/es/core/window.js +1 -1
  89. package/es/entries/browser.js +1 -1
  90. package/es/entries/index.js +1 -1
  91. package/es/entries/miniapp.js +1 -1
  92. package/es/entries/node.js +1 -1
  93. package/es/entries/runtime-installer.js +1 -1
  94. package/es/entries/types.js +1 -1
  95. package/es/graphic/graphic.d.ts +4 -1
  96. package/es/graphic/graphic.js +39 -13
  97. package/es/graphic/graphic.js.map +1 -1
  98. package/es/graphic/rect.d.ts +2 -0
  99. package/es/graphic/rect.js +44 -0
  100. package/es/graphic/rect.js.map +1 -1
  101. package/es/graphic/state/state-transition-orchestrator.d.ts +5 -0
  102. package/es/graphic/state/state-transition-orchestrator.js +17 -5
  103. package/es/graphic/state/state-transition-orchestrator.js.map +1 -1
  104. package/package.json +3 -3
@@ -3,5 +3,4 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: !0
5
5
  }), exports.Context2dFactory = exports.CanvasFactory = void 0, exports.CanvasFactory = Symbol.for("CanvasFactory"),
6
- exports.Context2dFactory = Symbol.for("Context2dFactory");
7
- //# sourceMappingURL=constants.js.map
6
+ exports.Context2dFactory = Symbol.for("Context2dFactory");
@@ -204,4 +204,5 @@ class EmptyContext2d {
204
204
  }
205
205
  }
206
206
 
207
- exports.EmptyContext2d = EmptyContext2d;
207
+ exports.EmptyContext2d = EmptyContext2d;
208
+ //# sourceMappingURL=empty-context.js.map
@@ -57,5 +57,4 @@ function createConicGradient(context, color, x, y, w, h) {
57
57
  })), canvasGradient.GetPattern ? canvasGradient.GetPattern(w + x, h + y, undefined) : canvasGradient;
58
58
  }
59
59
 
60
- //# sourceMappingURL=canvas-utils.js.map
61
60
  exports.getScaledStroke = getScaledStroke, exports.createColor = createColor;
@@ -16,4 +16,5 @@ function diff(oldAttrs, newAttrs, getAttr) {
16
16
  return diffObj;
17
17
  }
18
18
 
19
- exports.diff = diff;
19
+ exports.diff = diff;
20
+ //# sourceMappingURL=diff.js.map
@@ -13,4 +13,4 @@ function resolveContainerBinding(container, serviceIdentifier) {
13
13
  Object.defineProperty(exports, "__esModule", {
14
14
  value: !0
15
15
  }), exports.resolveContainerBinding = void 0, exports.resolveContainerBinding = resolveContainerBinding;
16
- //# sourceMappingURL=explicit-binding.js.map
16
+ //# sourceMappingURL=explicit-binding.js.map
@@ -11,4 +11,4 @@ class Generator {
11
11
  }
12
12
 
13
13
  exports.Generator = Generator, Generator.auto_increment_id = 0;
14
- //# sourceMappingURL=generator.js.map
14
+ //# sourceMappingURL=generator.js.map
@@ -129,4 +129,4 @@ exports.identityMat4 = identityMat4, exports.rotateX = rotateX, exports.rotateY
129
129
  exports.rotateZ = rotateZ, exports.translate = translate, exports.mat3Tomat4 = mat3Tomat4,
130
130
  exports.multiplyMat4Mat3 = multiplyMat4Mat3, exports.scaleMat4 = scaleMat4, exports.multiplyMat4Mat4 = multiplyMat4Mat4,
131
131
  exports.lookAt = lookAt, exports.ortho = ortho, exports.transformMat4 = transformMat4;
132
- //# sourceMappingURL=matrix.js.map
132
+ //# sourceMappingURL=matrix.js.map
@@ -200,4 +200,4 @@ exports.cubicSubdivide = cubicSubdivide, exports.alignSubpath = alignSubpath, ex
200
200
  exports.findBestMorphingRotation = findBestMorphingRotation, exports.alignBezierCurves = alignBezierCurves,
201
201
  exports.pathToBezierCurves = pathToBezierCurves, exports.applyTransformOnBezierCurves = applyTransformOnBezierCurves,
202
202
  exports.bezierCurversToPath = bezierCurversToPath;
203
- //# sourceMappingURL=morphing-utils.js.map
203
+ //# sourceMappingURL=morphing-utils.js.map
@@ -61,4 +61,4 @@ exports.enumCommandMap = {
61
61
  Q: 7,
62
62
  R: 8
63
63
  }, exports.parseSvgPath = parseSvgPath;
64
- //# sourceMappingURL=path-svg.js.map
64
+ //# sourceMappingURL=path-svg.js.map
@@ -34,4 +34,4 @@ class PerformanceRAF {
34
34
  }
35
35
 
36
36
  exports.PerformanceRAF = PerformanceRAF;
37
- //# sourceMappingURL=performance-raf.js.map
37
+ //# sourceMappingURL=performance-raf.js.map
@@ -41,8 +41,8 @@ function getProportionPoint(point, segment, length, dx, dy) {
41
41
  };
42
42
  }
43
43
 
44
- //# sourceMappingURL=polygon.js.map
45
44
  Object.defineProperty(exports, "__esModule", {
46
45
  value: !0
47
46
  }), exports.drawRoundedPolygon = exports.drawPolygon = void 0, exports.drawPolygon = drawPolygon,
48
- exports.drawRoundedPolygon = drawRoundedPolygon;
47
+ exports.drawRoundedPolygon = drawRoundedPolygon;
48
+ //# sourceMappingURL=polygon.js.map
@@ -24,4 +24,4 @@ const vutils_1 = require("@visactor/vutils"), normalizeRectAttributes = attribut
24
24
  };
25
25
 
26
26
  exports.normalizeRectAttributes = normalizeRectAttributes;
27
- //# sourceMappingURL=rect-utils.js.map
27
+ //# sourceMappingURL=rect-utils.js.map
@@ -61,5 +61,5 @@ function drawAreaBlock(path, topList, bottomList, params) {
61
61
  path.closePath();
62
62
  }
63
63
 
64
+ exports.drawAreaSegments = drawAreaSegments;
64
65
  //# sourceMappingURL=render-area.js.map
65
- exports.drawAreaSegments = drawAreaSegments;
@@ -14,4 +14,4 @@ function renderCommandList(commandList, context, x = 0, y = 0, sx = 1, sy = 1, z
14
14
  }
15
15
 
16
16
  exports.renderCommandList = renderCommandList;
17
- //# sourceMappingURL=render-command-list.js.map
17
+ //# sourceMappingURL=render-command-list.js.map
@@ -99,4 +99,4 @@ function drawIncrementalAreaSegments(path, lastSeg, segments, params) {
99
99
 
100
100
  exports.drawSegments = drawSegments, exports.drawIncrementalSegments = drawIncrementalSegments,
101
101
  exports.drawIncrementalAreaSegments = drawIncrementalAreaSegments;
102
- //# sourceMappingURL=render-curve.js.map
102
+ //# sourceMappingURL=render-curve.js.map
@@ -19,4 +19,4 @@ function drawSegItem(ctx, curve, endPercent, params) {
19
19
  }
20
20
 
21
21
  exports.drawSegItem = drawSegItem;
22
- //# sourceMappingURL=render-utils.js.map
22
+ //# sourceMappingURL=render-utils.js.map
@@ -94,4 +94,5 @@ class ReflectSegContext extends SegContext {
94
94
  }
95
95
  }
96
96
 
97
- exports.ReflectSegContext = ReflectSegContext;
97
+ exports.ReflectSegContext = ReflectSegContext;
98
+ //# sourceMappingURL=seg-context.js.map
@@ -36,4 +36,4 @@ function flatten_simplify(points, tolerance, highestQuality) {
36
36
  Object.defineProperty(exports, "__esModule", {
37
37
  value: !0
38
38
  }), exports.flatten_simplify = void 0, exports.flatten_simplify = flatten_simplify;
39
- //# sourceMappingURL=simplify.js.map
39
+ //# sourceMappingURL=simplify.js.map
@@ -101,4 +101,4 @@ Object.defineProperty(exports, "__esModule", {
101
101
  value: !0
102
102
  }), exports.findNextGraphic = exports.foreachAsync = exports.foreach = void 0, exports.foreach = foreach,
103
103
  exports.foreachAsync = foreachAsync, exports.findNextGraphic = findNextGraphic;
104
- //# sourceMappingURL=sort.js.map
104
+ //# sourceMappingURL=sort.js.map
@@ -269,4 +269,4 @@ const splitPath = (path, count) => {
269
269
  };
270
270
 
271
271
  exports.splitPath = splitPath;
272
- //# sourceMappingURL=split-path.js.map
272
+ //# sourceMappingURL=split-path.js.map
@@ -1,2 +1,2 @@
1
1
  class StageStore {}
2
- //# sourceMappingURL=store.js.map
2
+ //# sourceMappingURL=store.js.map
@@ -34,4 +34,4 @@ function textAttributesToStyle(attrs) {
34
34
 
35
35
  exports.textDrawOffsetY = textDrawOffsetY, exports.textDrawOffsetX = textDrawOffsetX,
36
36
  exports.textLayoutOffsetY = textLayoutOffsetY, exports.textAttributesToStyle = textAttributesToStyle;
37
- //# sourceMappingURL=text.js.map
37
+ //# sourceMappingURL=text.js.map
@@ -163,4 +163,4 @@ const calculateLineHeight = (lineHeight, fontSize) => {
163
163
  };
164
164
 
165
165
  exports.calculateLineHeight = calculateLineHeight;
166
- //# sourceMappingURL=utils.js.map
166
+ //# sourceMappingURL=utils.js.map
@@ -3,4 +3,4 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: !0
5
5
  }), exports.ApplicationContribution = void 0, exports.ApplicationContribution = Symbol("ApplicationContribution");
6
- //# sourceMappingURL=application.js.map
6
+ //# sourceMappingURL=application.js.map
@@ -71,4 +71,4 @@ const registerOrthoCamera = () => {
71
71
  };
72
72
 
73
73
  exports.registerOrthoCamera = registerOrthoCamera;
74
- //# sourceMappingURL=camera.js.map
74
+ //# sourceMappingURL=camera.js.map
@@ -7,4 +7,4 @@ exports.TransformUtil = Symbol.for("TransformUtil"), exports.GraphicUtil = Symbo
7
7
  exports.LayerService = Symbol.for("LayerService"), exports.StaticLayerHandlerContribution = Symbol.for("StaticLayerHandlerContribution"),
8
8
  exports.DynamicLayerHandlerContribution = Symbol.for("DynamicLayerHandlerContribution"),
9
9
  exports.VirtualLayerHandlerContribution = Symbol.for("VirtualLayerHandlerContribution");
10
- //# sourceMappingURL=constants.js.map
10
+ //# sourceMappingURL=constants.js.map
@@ -16,4 +16,4 @@ function bindCoreModules({bind: bind}) {
16
16
  }
17
17
 
18
18
  exports.bindCoreModules = bindCoreModules, exports.default = bindCoreModules;
19
- //# sourceMappingURL=core-modules.js.map
19
+ //# sourceMappingURL=core-modules.js.map
@@ -1,3 +1 @@
1
-
2
-
3
1
  //# sourceMappingURL=global-module.js.map
@@ -222,4 +222,4 @@ class DefaultGlobal extends event_listener_manager_1.EventListenerManager {
222
222
  }
223
223
 
224
224
  exports.DefaultGlobal = DefaultGlobal;
225
- //# sourceMappingURL=global.js.map
225
+ //# sourceMappingURL=global.js.map
@@ -162,4 +162,4 @@ class DefaultTransformUtil {
162
162
  }
163
163
 
164
164
  exports.DefaultTransformUtil = DefaultTransformUtil;
165
- //# sourceMappingURL=graphic-utils.js.map
165
+ //# sourceMappingURL=graphic-utils.js.map
package/cjs/core/index.js CHANGED
@@ -22,4 +22,4 @@ __exportStar(require("./layer"), exports), __exportStar(require("./stage"), expo
22
22
  __exportStar(require("./graphic-utils"), exports), __exportStar(require("./contributions"), exports),
23
23
  __exportStar(require("./layer-service"), exports), __exportStar(require("./constants"), exports),
24
24
  __exportStar(require("../interface/core"), exports);
25
- //# sourceMappingURL=index.js.map
25
+ //# sourceMappingURL=index.js.map
@@ -80,5 +80,4 @@ class DefaultLayerService {
80
80
  }
81
81
 
82
82
  exports.DefaultLayerService = DefaultLayerService, DefaultLayerService.idprefix = "visactor_layer",
83
- DefaultLayerService.prefix_count = 0;
84
- //# sourceMappingURL=layer-service.js.map
83
+ DefaultLayerService.prefix_count = 0;
package/cjs/core/layer.js CHANGED
@@ -116,4 +116,4 @@ class Layer extends group_1.Group {
116
116
  }
117
117
 
118
118
  exports.Layer = Layer;
119
- //# sourceMappingURL=layer.js.map
119
+ //# sourceMappingURL=layer.js.map
package/cjs/core/light.js CHANGED
@@ -29,4 +29,4 @@ const registerDirectionalLight = () => {
29
29
  };
30
30
 
31
31
  exports.registerDirectionalLight = registerDirectionalLight;
32
- //# sourceMappingURL=light.js.map
32
+ //# sourceMappingURL=light.js.map
package/cjs/core/stage.js CHANGED
@@ -571,4 +571,4 @@ class Stage extends group_1.Group {
571
571
  }
572
572
 
573
573
  exports.Stage = Stage;
574
- //# sourceMappingURL=stage.js.map
574
+ //# sourceMappingURL=stage.js.map
@@ -150,4 +150,4 @@ class DefaultWindow extends event_listener_manager_1.EventListenerManager {
150
150
  }
151
151
 
152
152
  exports.DefaultWindow = DefaultWindow;
153
- //# sourceMappingURL=window.js.map
153
+ //# sourceMappingURL=window.js.map
@@ -41,4 +41,4 @@ function createBrowserApp(options = {}) {
41
41
  }
42
42
 
43
43
  exports.BrowserEntry = BrowserEntry, exports.createBrowserApp = createBrowserApp;
44
- //# sourceMappingURL=browser.js.map
44
+ //# sourceMappingURL=browser.js.map
@@ -29,4 +29,4 @@ Object.defineProperty(exports, "createApp", {
29
29
  return browser_1.createBrowserApp;
30
30
  }
31
31
  });
32
- //# sourceMappingURL=index.js.map
32
+ //# sourceMappingURL=index.js.map
@@ -17,4 +17,4 @@ function createMiniappApp(options = {}) {
17
17
  }
18
18
 
19
19
  exports.MiniappEntry = MiniappEntry, exports.createMiniappApp = createMiniappApp;
20
- //# sourceMappingURL=miniapp.js.map
20
+ //# sourceMappingURL=miniapp.js.map
@@ -17,4 +17,4 @@ function createNodeApp(options = {}) {
17
17
  }
18
18
 
19
19
  exports.NodeEntry = NodeEntry, exports.createNodeApp = createNodeApp;
20
- //# sourceMappingURL=node.js.map
20
+ //# sourceMappingURL=node.js.map
@@ -108,4 +108,4 @@ exports.getRuntimeInstallerGlobal = getRuntimeInstallerGlobal, exports.configure
108
108
  exports.installRuntimeGraphicRenderersToApp = installRuntimeGraphicRenderersToApp,
109
109
  exports.installRuntimeDrawContributionsToApp = installRuntimeDrawContributionsToApp,
110
110
  exports.installRuntimePickersToApp = installRuntimePickersToApp;
111
- //# sourceMappingURL=runtime-installer.js.map
111
+ //# sourceMappingURL=runtime-installer.js.map
@@ -3,4 +3,4 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: !0
5
5
  });
6
- //# sourceMappingURL=types.js.map
6
+ //# sourceMappingURL=types.js.map
@@ -149,6 +149,7 @@ export declare abstract class Graphic<T extends Partial<IGraphicAttribute> = Par
149
149
  };
150
150
  protected recomputeCurrentStatePatch(): void;
151
151
  protected buildStaticAttributeSnapshot(): Partial<T>;
152
+ protected buildRemovedStateAnimationAttrs(targetStateAttrs: Partial<T>, previousResolvedStatePatch?: Partial<T>): Partial<T>;
152
153
  protected syncObjectToSnapshot(target: Record<string, any>, snapshot: Record<string, any>): AttributeDelta;
153
154
  protected _syncAttribute(): AttributeDelta;
154
155
  protected _syncFinalAttributeFromStaticTruth(): void;
@@ -210,8 +211,10 @@ export declare abstract class Graphic<T extends Partial<IGraphicAttribute> = Par
210
211
  getState(stateName: string): Partial<T> | StateDefinition<T> | undefined;
211
212
  protected createStateModel(): StateModel<T>;
212
213
  protected resolveStateAnimateConfig(animateConfig?: IAnimateConfig): any;
213
- applyStateAttrs(attrs: Partial<T>, stateNames: string[], hasAnimation?: boolean, isClear?: boolean, animateConfig?: IAnimateConfig): void;
214
+ applyStateAttrs(attrs: Partial<T>, stateNames: string[], hasAnimation?: boolean, isClear?: boolean, animateConfig?: IAnimateConfig, extraAnimateAttrs?: Partial<T>): void;
214
215
  updateNormalAttrs(stateAttrs: Partial<T>): void;
216
+ protected getStateTransitionDefaultAttribute(key: string, targetAttrs?: Partial<T>): any;
217
+ protected shouldSkipStateTransitionDefaultAttribute(_key: string, _targetAttrs?: Partial<T>): boolean;
215
218
  protected stopStateAnimates(type?: 'start' | 'end'): void;
216
219
  private getNormalAttribute;
217
220
  clearStates(hasAnimation?: boolean): void;
@@ -212,11 +212,11 @@ class Graphic extends node_tree_1.Node {
212
212
  stateProxyModeKey: this.stateProxy ? "legacy-all" : "none"
213
213
  };
214
214
  }
215
- const sharedCompiledDefinitions = boundScope.effectiveCompiledDefinitions;
215
+ const sharedCompiledDefinitions = boundScope.effectiveCompiledDefinitions, sharedStateProxyModeKey = this.stateProxy ? "shared-missing-only" : "none", sharedStateProxyEligibility = this.stateProxy ? stateName => !sharedCompiledDefinitions.has(stateName) : void 0;
216
216
  if (!hasStates) return this.localFallbackCompiledDefinitions = void 0, {
217
217
  compiledDefinitions: sharedCompiledDefinitions,
218
- stateProxyModeKey: this.stateProxy ? "shared-disabled" : "none",
219
- stateProxyEligibility: this.stateProxy ? () => !1 : void 0
218
+ stateProxyModeKey: sharedStateProxyModeKey,
219
+ stateProxyEligibility: sharedStateProxyEligibility
220
220
  };
221
221
  const localStates = this.states, missingLocalStateDefinitions = {}, missingStateNames = [];
222
222
  if (Object.keys(localStates).forEach((stateName => {
@@ -225,15 +225,15 @@ class Graphic extends node_tree_1.Node {
225
225
  })), !missingStateNames.length) return this.localFallbackCompiledDefinitions = void 0,
226
226
  {
227
227
  compiledDefinitions: sharedCompiledDefinitions,
228
- stateProxyModeKey: this.stateProxy ? "shared-disabled" : "none",
229
- stateProxyEligibility: this.stateProxy ? () => !1 : void 0
228
+ stateProxyModeKey: sharedStateProxyModeKey,
229
+ stateProxyEligibility: sharedStateProxyEligibility
230
230
  };
231
231
  const localStatesVersion = this.getLocalStatesVersion(), stateProxyModeKey = this.stateProxy ? `missing:${missingStateNames.sort().join("|")}` : "none", cacheKey = `shared:${boundScope.revision}:fallback:${localStatesVersion}:${stateProxyModeKey}`;
232
232
  return this.localFallbackCompiledDefinitions && this.compiledStateDefinitionsCacheKey === cacheKey || (this.localFallbackCompiledDefinitions = (new state_definition_compiler_1.StateDefinitionCompiler).compile(Object.assign(Object.assign({}, boundScope.effectiveSourceDefinitions), missingLocalStateDefinitions)),
233
233
  this.compiledStateDefinitionsCacheKey = cacheKey), {
234
234
  compiledDefinitions: this.localFallbackCompiledDefinitions,
235
235
  stateProxyModeKey: stateProxyModeKey,
236
- stateProxyEligibility: this.stateProxy ? stateName => !sharedCompiledDefinitions.has(stateName) : void 0
236
+ stateProxyEligibility: sharedStateProxyEligibility
237
237
  };
238
238
  }
239
239
  recomputeCurrentStatePatch() {
@@ -254,6 +254,22 @@ class Graphic extends node_tree_1.Node {
254
254
  "deep" === this.stateMergeMode && isPlainObjectValue(previousValue) && isPlainObjectValue(nextValue) ? snapshot[key] = deepMergeAttributeValue(previousValue, nextValue) : snapshot[key] = cloneAttributeValue(nextValue);
255
255
  })), snapshot) : snapshot;
256
256
  }
257
+ buildRemovedStateAnimationAttrs(targetStateAttrs, previousResolvedStatePatch) {
258
+ const extraAttrs = {};
259
+ if (!previousResolvedStatePatch) return extraAttrs;
260
+ const snapshot = this.buildStaticAttributeSnapshot(), staticTargetAttrs = snapshot;
261
+ return Object.keys(previousResolvedStatePatch).forEach((key => {
262
+ const hasTargetAttr = Object.prototype.hasOwnProperty.call(targetStateAttrs, key);
263
+ if (hasTargetAttr && void 0 !== targetStateAttrs[key]) return;
264
+ const assignFallbackAttr = value => {
265
+ void 0 === value && this.shouldSkipStateTransitionDefaultAttribute(key, staticTargetAttrs) || (extraAttrs[key] = void 0 === value ? value : cloneAttributeValue(value));
266
+ };
267
+ if (hasTargetAttr) assignFallbackAttr(this.getStateTransitionDefaultAttribute(key, staticTargetAttrs)); else if (Object.prototype.hasOwnProperty.call(snapshot, key)) {
268
+ const snapshotValue = snapshot[key];
269
+ assignFallbackAttr(void 0 === snapshotValue ? this.getStateTransitionDefaultAttribute(key, staticTargetAttrs) : snapshotValue);
270
+ } else assignFallbackAttr(this.getStateTransitionDefaultAttribute(key, staticTargetAttrs));
271
+ })), extraAttrs;
272
+ }
257
273
  syncObjectToSnapshot(target, snapshot) {
258
274
  const delta = new Map;
259
275
  return new Set([ ...Object.keys(target), ...Object.keys(snapshot) ]).forEach((key => {
@@ -681,20 +697,30 @@ class Graphic extends node_tree_1.Node {
681
697
  var _a, _b, _c;
682
698
  return null !== (_c = null !== (_a = null != animateConfig ? animateConfig : this.stateAnimateConfig) && void 0 !== _a ? _a : null === (_b = this.context) || void 0 === _b ? void 0 : _b.stateAnimateConfig) && void 0 !== _c ? _c : config_2.DefaultStateAnimateConfig;
683
699
  }
684
- applyStateAttrs(attrs, stateNames, hasAnimation, isClear, animateConfig) {
700
+ applyStateAttrs(attrs, stateNames, hasAnimation, isClear, animateConfig, extraAnimateAttrs) {
685
701
  const resolvedAnimateConfig = hasAnimation ? this.resolveStateAnimateConfig(animateConfig) : void 0, transitionOptions = resolvedAnimateConfig ? {
686
- animateConfig: resolvedAnimateConfig
702
+ animateConfig: resolvedAnimateConfig,
703
+ extraAnimateAttrs: extraAnimateAttrs,
704
+ shouldSkipDefaultAttribute: this.shouldSkipStateTransitionDefaultAttribute.bind(this)
687
705
  } : void 0;
688
706
  if (isClear) return void this.getStateTransitionOrchestrator().applyClearTransition(this, attrs, hasAnimation, stateNames, transitionOptions);
689
707
  const plan = this.getStateTransitionOrchestrator().analyzeTransition({}, attrs, stateNames, hasAnimation, {
690
708
  noWorkAnimateAttr: this.getNoWorkAnimateAttr(),
691
- animateConfig: resolvedAnimateConfig
709
+ animateConfig: resolvedAnimateConfig,
710
+ extraAnimateAttrs: extraAnimateAttrs,
711
+ shouldSkipDefaultAttribute: this.shouldSkipStateTransitionDefaultAttribute.bind(this)
692
712
  });
693
713
  this.getStateTransitionOrchestrator().applyTransition(this, plan, hasAnimation, transitionOptions);
694
714
  }
695
715
  updateNormalAttrs(stateAttrs) {
696
716
  this._deprecatedNormalAttrsView = cloneAttributeValue(this.baseAttributes);
697
717
  }
718
+ getStateTransitionDefaultAttribute(key, targetAttrs) {
719
+ return this.getDefaultAttribute(key);
720
+ }
721
+ shouldSkipStateTransitionDefaultAttribute(_key, _targetAttrs) {
722
+ return !1;
723
+ }
698
724
  stopStateAnimates(type = "end") {
699
725
  const stopAnimationState = this.stopAnimationState;
700
726
  if ("function" == typeof stopAnimationState) return void stopAnimationState.call(this, "state", type);
@@ -710,7 +736,7 @@ class Graphic extends node_tree_1.Node {
710
736
  }
711
737
  clearStates(hasAnimation) {
712
738
  var _a, _b, _c;
713
- const previousStates = this.currentStates ? this.currentStates.slice() : [], transition = this.createStateModel().clearStates();
739
+ const previousStates = this.currentStates ? this.currentStates.slice() : [], previousResolvedStatePatch = this.resolvedStatePatch ? cloneAttributeValue(this.resolvedStatePatch) : void 0, transition = this.createStateModel().clearStates();
714
740
  if (!transition.changed && 0 === previousStates.length) return this.currentStates = [],
715
741
  this.effectiveStates = [], this.resolvedStatePatch = void 0, this.sharedStateDirty = !1,
716
742
  void this.clearSharedStateActiveRegistrations();
@@ -721,7 +747,7 @@ class Graphic extends node_tree_1.Node {
721
747
  null === (_c = (0, state_perf_monitor_1.getStageStatePerfMonitor)(this.stage)) || void 0 === _c || _c.recordEvent("state-commit", {
722
748
  graphicId: this._uid,
723
749
  targetStates: []
724
- }), hasAnimation ? (this._syncFinalAttributeFromStaticTruth(), this.applyStateAttrs(resolvedStateAttrs, transition.states, hasAnimation, !0)) : (this.stopStateAnimates(),
750
+ }), hasAnimation ? (this._syncFinalAttributeFromStaticTruth(), this.applyStateAttrs(resolvedStateAttrs, transition.states, hasAnimation, !0, void 0, this.buildRemovedStateAnimationAttrs(resolvedStateAttrs, previousResolvedStatePatch))) : (this.stopStateAnimates(),
725
751
  this._restoreAttributeFromStaticTruth({
726
752
  type: enums_1.AttributeUpdateType.STATE
727
753
  }), this._emitCustomEvent("afterStateUpdate", {
@@ -743,7 +769,7 @@ class Graphic extends node_tree_1.Node {
743
769
  useStates(states, hasAnimation) {
744
770
  var _a, _b, _c, _d, _e;
745
771
  if (!states.length) return void this.clearStates(hasAnimation);
746
- const previousStates = this.currentStates ? this.currentStates.slice() : [], stateResolveBaseAttrs = null !== (_a = this.baseAttributes) && void 0 !== _a ? _a : this.attribute, stateModel = this.createStateModel();
772
+ const previousStates = this.currentStates ? this.currentStates.slice() : [], previousResolvedStatePatch = this.resolvedStatePatch ? cloneAttributeValue(this.resolvedStatePatch) : void 0, stateResolveBaseAttrs = null !== (_a = this.baseAttributes) && void 0 !== _a ? _a : this.attribute, stateModel = this.createStateModel();
747
773
  null === (_b = this.stateEngine) || void 0 === _b || _b.setResolveContext(this, stateResolveBaseAttrs);
748
774
  const transition = stateModel.useStates(states);
749
775
  if (!transition.changed && this.sameStateNames(previousStates, transition.states)) return;
@@ -755,7 +781,7 @@ class Graphic extends node_tree_1.Node {
755
781
  null === (_e = (0, state_perf_monitor_1.getStageStatePerfMonitor)(this.stage)) || void 0 === _e || _e.recordEvent("state-commit", {
756
782
  graphicId: this._uid,
757
783
  targetStates: [ ...transition.states ]
758
- }), hasAnimation ? (this._syncFinalAttributeFromStaticTruth(), this.applyStateAttrs(resolvedStateAttrs, transition.states, hasAnimation)) : (this.stopStateAnimates(),
784
+ }), hasAnimation ? (this._syncFinalAttributeFromStaticTruth(), this.applyStateAttrs(resolvedStateAttrs, transition.states, hasAnimation, !1, void 0, this.buildRemovedStateAnimationAttrs(resolvedStateAttrs, previousResolvedStatePatch))) : (this.stopStateAnimates(),
759
785
  this._restoreAttributeFromStaticTruth({
760
786
  type: enums_1.AttributeUpdateType.STATE
761
787
  }), this._emitCustomEvent("afterStateUpdate", {