@visactor/vrender-core 1.1.0-alpha.1 → 1.1.0-alpha.2
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/cjs/canvas/constants.js +1 -2
- package/cjs/canvas/empty-context.js +2 -1
- package/cjs/common/diff.js +2 -1
- package/cjs/common/event-transformer.js +1 -2
- package/cjs/common/rect-utils.js +1 -1
- package/cjs/common/render-area.js +1 -1
- package/cjs/common/render-command-list.js +1 -1
- package/cjs/common/render-curve.js +1 -1
- package/cjs/common/render-utils.js +1 -1
- package/cjs/common/seg-context.js +2 -1
- package/cjs/common/simplify.js +1 -1
- package/cjs/common/sort.js +1 -1
- package/cjs/common/split-path.js +1 -1
- package/cjs/common/store.js +1 -1
- package/cjs/common/text.js +1 -1
- package/cjs/common/utils.js +1 -1
- package/cjs/core/application.js +1 -1
- package/cjs/core/camera.js +1 -1
- package/cjs/core/constants.js +1 -1
- package/cjs/core/core-modules.js +1 -1
- package/cjs/core/global-module.js +0 -2
- package/cjs/core/global.js +1 -1
- package/cjs/core/graphic-utils.js +1 -1
- package/cjs/core/index.js +1 -1
- package/cjs/core/layer-service.js +1 -2
- package/cjs/core/layer.js +1 -1
- package/cjs/core/light.js +1 -1
- package/cjs/core/stage.js +1 -1
- package/cjs/core/window.js +1 -1
- package/cjs/entries/app-context.js +1 -1
- package/cjs/graphic/graphic.js +6 -6
- package/cjs/graphic/graphic.js.map +1 -1
- package/dist/index.es.js +9 -7
- package/es/canvas/constants.js +1 -2
- package/es/canvas/empty-context.js +2 -1
- package/es/common/diff.js +2 -1
- package/es/common/event-transformer.js +1 -2
- package/es/common/rect-utils.js +1 -1
- package/es/common/render-area.js +1 -1
- package/es/common/render-command-list.js +1 -1
- package/es/common/render-curve.js +1 -1
- package/es/common/render-utils.js +1 -1
- package/es/common/seg-context.js +2 -1
- package/es/common/simplify.js +1 -1
- package/es/common/sort.js +1 -1
- package/es/common/split-path.js +1 -1
- package/es/common/store.js +1 -1
- package/es/common/text.js +1 -1
- package/es/common/utils.js +1 -1
- package/es/core/application.js +1 -1
- package/es/core/camera.js +1 -1
- package/es/core/constants.js +1 -1
- package/es/core/core-modules.js +1 -1
- package/es/core/global-module.js +0 -2
- package/es/core/global.js +1 -1
- package/es/core/graphic-utils.js +1 -1
- package/es/core/index.js +1 -1
- package/es/core/layer-service.js +1 -2
- package/es/core/layer.js +1 -1
- package/es/core/light.js +1 -1
- package/es/core/stage.js +1 -1
- package/es/core/window.js +1 -1
- package/es/entries/app-context.js +1 -1
- package/es/graphic/graphic.js +6 -6
- package/es/graphic/graphic.js.map +1 -1
- package/package.json +3 -3
package/dist/index.es.js
CHANGED
|
@@ -10778,12 +10778,16 @@ class Graphic extends Node {
|
|
|
10778
10778
|
};
|
|
10779
10779
|
}
|
|
10780
10780
|
const sharedCompiledDefinitions = boundScope.effectiveCompiledDefinitions;
|
|
10781
|
+
const sharedStateProxyModeKey = this.stateProxy ? 'shared-missing-only' : 'none';
|
|
10782
|
+
const sharedStateProxyEligibility = this.stateProxy
|
|
10783
|
+
? (stateName) => !sharedCompiledDefinitions.has(stateName)
|
|
10784
|
+
: undefined;
|
|
10781
10785
|
if (!hasStates) {
|
|
10782
10786
|
this.localFallbackCompiledDefinitions = undefined;
|
|
10783
10787
|
return {
|
|
10784
10788
|
compiledDefinitions: sharedCompiledDefinitions,
|
|
10785
|
-
stateProxyModeKey:
|
|
10786
|
-
stateProxyEligibility:
|
|
10789
|
+
stateProxyModeKey: sharedStateProxyModeKey,
|
|
10790
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
10787
10791
|
};
|
|
10788
10792
|
}
|
|
10789
10793
|
const localStates = this.states;
|
|
@@ -10800,8 +10804,8 @@ class Graphic extends Node {
|
|
|
10800
10804
|
this.localFallbackCompiledDefinitions = undefined;
|
|
10801
10805
|
return {
|
|
10802
10806
|
compiledDefinitions: sharedCompiledDefinitions,
|
|
10803
|
-
stateProxyModeKey:
|
|
10804
|
-
stateProxyEligibility:
|
|
10807
|
+
stateProxyModeKey: sharedStateProxyModeKey,
|
|
10808
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
10805
10809
|
};
|
|
10806
10810
|
}
|
|
10807
10811
|
const localStatesVersion = this.getLocalStatesVersion();
|
|
@@ -10814,9 +10818,7 @@ class Graphic extends Node {
|
|
|
10814
10818
|
return {
|
|
10815
10819
|
compiledDefinitions: this.localFallbackCompiledDefinitions,
|
|
10816
10820
|
stateProxyModeKey,
|
|
10817
|
-
stateProxyEligibility:
|
|
10818
|
-
? (stateName) => !sharedCompiledDefinitions.has(stateName)
|
|
10819
|
-
: undefined
|
|
10821
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
10820
10822
|
};
|
|
10821
10823
|
}
|
|
10822
10824
|
recomputeCurrentStatePatch() {
|
package/es/canvas/constants.js
CHANGED
package/es/common/diff.js
CHANGED
package/es/common/rect-utils.js
CHANGED
package/es/common/render-area.js
CHANGED
package/es/common/seg-context.js
CHANGED
package/es/common/simplify.js
CHANGED
|
@@ -30,4 +30,4 @@ export function flatten_simplify(points, tolerance, highestQuality) {
|
|
|
30
30
|
if (points.length <= 10) return points;
|
|
31
31
|
return points = highestQuality ? points : simplifyRadialDist(points, void 0 !== tolerance ? tolerance * tolerance : 1);
|
|
32
32
|
}
|
|
33
|
-
//# sourceMappingURL=simplify.js.map
|
|
33
|
+
//# sourceMappingURL=simplify.js.map
|
package/es/common/sort.js
CHANGED
package/es/common/split-path.js
CHANGED
package/es/common/store.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
class StageStore {}
|
|
2
|
-
//# sourceMappingURL=store.js.map
|
|
2
|
+
//# sourceMappingURL=store.js.map
|
package/es/common/text.js
CHANGED
|
@@ -24,4 +24,4 @@ export function textAttributesToStyle(attrs) {
|
|
|
24
24
|
attrs.underline ? style["text-decoration"] = "underline" : attrs.lineThrough && (style["text-decoration"] = "line-through"),
|
|
25
25
|
attrs.fill && isString(attrs.fill) && (style.color = attrs.fill), style;
|
|
26
26
|
}
|
|
27
|
-
//# sourceMappingURL=text.js.map
|
|
27
|
+
//# sourceMappingURL=text.js.map
|
package/es/common/utils.js
CHANGED
package/es/core/application.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export const ApplicationContribution = Symbol("ApplicationContribution");
|
|
2
|
-
//# sourceMappingURL=application.js.map
|
|
2
|
+
//# sourceMappingURL=application.js.map
|
package/es/core/camera.js
CHANGED
package/es/core/constants.js
CHANGED
|
@@ -9,4 +9,4 @@ export const StaticLayerHandlerContribution = Symbol.for("StaticLayerHandlerCont
|
|
|
9
9
|
export const DynamicLayerHandlerContribution = Symbol.for("DynamicLayerHandlerContribution");
|
|
10
10
|
|
|
11
11
|
export const VirtualLayerHandlerContribution = Symbol.for("VirtualLayerHandlerContribution");
|
|
12
|
-
//# sourceMappingURL=constants.js.map
|
|
12
|
+
//# sourceMappingURL=constants.js.map
|
package/es/core/core-modules.js
CHANGED
package/es/core/global-module.js
CHANGED
package/es/core/global.js
CHANGED
package/es/core/graphic-utils.js
CHANGED
package/es/core/index.js
CHANGED
package/es/core/layer-service.js
CHANGED
|
@@ -75,5 +75,4 @@ export class DefaultLayerService {
|
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
-
DefaultLayerService.idprefix = "visactor_layer", DefaultLayerService.prefix_count = 0;
|
|
79
|
-
//# sourceMappingURL=layer-service.js.map
|
|
78
|
+
DefaultLayerService.idprefix = "visactor_layer", DefaultLayerService.prefix_count = 0;
|
package/es/core/layer.js
CHANGED
package/es/core/light.js
CHANGED
package/es/core/stage.js
CHANGED
package/es/core/window.js
CHANGED
package/es/graphic/graphic.js
CHANGED
|
@@ -255,11 +255,11 @@ export class Graphic extends Node {
|
|
|
255
255
|
stateProxyModeKey: this.stateProxy ? "legacy-all" : "none"
|
|
256
256
|
};
|
|
257
257
|
}
|
|
258
|
-
const sharedCompiledDefinitions = boundScope.effectiveCompiledDefinitions;
|
|
258
|
+
const sharedCompiledDefinitions = boundScope.effectiveCompiledDefinitions, sharedStateProxyModeKey = this.stateProxy ? "shared-missing-only" : "none", sharedStateProxyEligibility = this.stateProxy ? stateName => !sharedCompiledDefinitions.has(stateName) : void 0;
|
|
259
259
|
if (!hasStates) return this.localFallbackCompiledDefinitions = void 0, {
|
|
260
260
|
compiledDefinitions: sharedCompiledDefinitions,
|
|
261
|
-
stateProxyModeKey:
|
|
262
|
-
stateProxyEligibility:
|
|
261
|
+
stateProxyModeKey: sharedStateProxyModeKey,
|
|
262
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
263
263
|
};
|
|
264
264
|
const localStates = this.states, missingLocalStateDefinitions = {}, missingStateNames = [];
|
|
265
265
|
if (Object.keys(localStates).forEach((stateName => {
|
|
@@ -268,15 +268,15 @@ export class Graphic extends Node {
|
|
|
268
268
|
})), !missingStateNames.length) return this.localFallbackCompiledDefinitions = void 0,
|
|
269
269
|
{
|
|
270
270
|
compiledDefinitions: sharedCompiledDefinitions,
|
|
271
|
-
stateProxyModeKey:
|
|
272
|
-
stateProxyEligibility:
|
|
271
|
+
stateProxyModeKey: sharedStateProxyModeKey,
|
|
272
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
273
273
|
};
|
|
274
274
|
const localStatesVersion = this.getLocalStatesVersion(), stateProxyModeKey = this.stateProxy ? `missing:${missingStateNames.sort().join("|")}` : "none", cacheKey = `shared:${boundScope.revision}:fallback:${localStatesVersion}:${stateProxyModeKey}`;
|
|
275
275
|
return this.localFallbackCompiledDefinitions && this.compiledStateDefinitionsCacheKey === cacheKey || (this.localFallbackCompiledDefinitions = (new StateDefinitionCompiler).compile(Object.assign(Object.assign({}, boundScope.effectiveSourceDefinitions), missingLocalStateDefinitions)),
|
|
276
276
|
this.compiledStateDefinitionsCacheKey = cacheKey), {
|
|
277
277
|
compiledDefinitions: this.localFallbackCompiledDefinitions,
|
|
278
278
|
stateProxyModeKey: stateProxyModeKey,
|
|
279
|
-
stateProxyEligibility:
|
|
279
|
+
stateProxyEligibility: sharedStateProxyEligibility
|
|
280
280
|
};
|
|
281
281
|
}
|
|
282
282
|
recomputeCurrentStatePatch() {
|