zrender-nightly 5.6.1-dev.20241230 → 5.6.2-dev.20250101

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.
@@ -75,6 +75,26 @@ if (untrackedFiles.length) {
75
75
  console.log(chalk.green('✔️ No unexpected files found.'));
76
76
  console.log();
77
77
 
78
+ console.log(chalk.yellow('🔎 Checking registry url of the packages in package-lock.json...\n'));
79
+
80
+ const NPM_REGISTRY = 'https://registry.npmjs.org/';
81
+ const packageLock = require('../package-lock.json');
82
+
83
+ const unexpectedPkgsFromUnofficialRegistry = Object.entries(packageLock.dependencies)
84
+ .concat(Object.entries(packageLock.packages))
85
+ .filter(([pkgName, pkgRegistry]) => pkgRegistry.resolved && !pkgRegistry.resolved.startsWith(NPM_REGISTRY));
86
+ if (unexpectedPkgsFromUnofficialRegistry.length) {
87
+ console.error(chalk.red('❌ Found packages that are not from npm registry in package-lock.json! Please double-check before publishing them to npm.'));
88
+ unexpectedPkgsFromUnofficialRegistry.forEach(([pkgName, pkgRegistry]) => {
89
+ console.log(` ∟ ${pkgName} (${pkgRegistry.resolved})`);
90
+ });
91
+ console.log();
92
+ process.exit(-1);
93
+ }
94
+
95
+ console.log(chalk.green('✔️ No unexpected packages with unofficial registry url found.'));
96
+ console.log();
97
+
78
98
  function escapeOctal(str) {
79
99
  const matches = str.match(/(\\\d{3}){3}/g);
80
100
  if (matches) {
package/dist/zrender.js CHANGED
@@ -292,7 +292,7 @@
292
292
  }
293
293
  function defaults(target, source, overlay) {
294
294
  var keysArr = keys(source);
295
- for (var i = 0; i < keysArr.length; i++) {
295
+ for (var i = 0, len = keysArr.length; i < len; i++) {
296
296
  var key = keysArr[i];
297
297
  if ((overlay ? source[key] != null : target[key] == null)) {
298
298
  target[key] = source[key];
@@ -7337,7 +7337,7 @@
7337
7337
  function registerSSRDataGetter(getter) {
7338
7338
  ssrDataGetter = getter;
7339
7339
  }
7340
- var version = '5.6.1-dev.20241230';
7340
+ var version = '5.6.2-dev.20250101';
7341
7341
 
7342
7342
  var STYLE_MAGIC_KEY = '__zr_style_' + Math.round((Math.random() * 10));
7343
7343
  var DEFAULT_COMMON_STYLE = {
@@ -8008,7 +8008,7 @@
8008
8008
  for (var i = 0; i < len; i++) {
8009
8009
  appendSize += path[i].len();
8010
8010
  }
8011
- if (hasTypedArray && (this.data instanceof Float32Array || !this.data)) {
8011
+ if (hasTypedArray && (this.data instanceof Float32Array)) {
8012
8012
  this.data = new Float32Array(offset + appendSize);
8013
8013
  }
8014
8014
  for (var i = 0; i < len; i++) {
@@ -9643,7 +9643,7 @@
9643
9643
  var innerOpts = extend({}, opts);
9644
9644
  innerOpts.buildPath = function (path) {
9645
9645
  if (isPathProxy(path)) {
9646
- path.appendPath(pathProxy);
9646
+ path.setData(pathProxy.data);
9647
9647
  var ctx = path.getContext();
9648
9648
  if (ctx) {
9649
9649
  path.rebuildPath(ctx, 1);