@tsparticles/ribbons 4.3.0 → 4.3.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.
@@ -1,5 +1,5 @@
1
1
  (function(g){g.__tsParticlesInternals=g.__tsParticlesInternals||{};g.__tsParticlesInternals.bundles=g.__tsParticlesInternals.bundles||{};g.__tsParticlesInternals.effects=g.__tsParticlesInternals.effects||{};g.__tsParticlesInternals.engine=g.__tsParticlesInternals.engine||{};g.__tsParticlesInternals.interactions=g.__tsParticlesInternals.interactions||{};g.__tsParticlesInternals.palettes=g.__tsParticlesInternals.palettes||{};g.__tsParticlesInternals.paths=g.__tsParticlesInternals.paths||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins.emittersShapes=g.__tsParticlesInternals.plugins.emittersShapes||{};g.__tsParticlesInternals.presets=g.__tsParticlesInternals.presets||{};g.__tsParticlesInternals.shapes=g.__tsParticlesInternals.shapes||{};g.__tsParticlesInternals.updaters=g.__tsParticlesInternals.updaters||{};g.__tsParticlesInternals.utils=g.__tsParticlesInternals.utils||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas.utils=g.__tsParticlesInternals.canvas.utils||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path.utils=g.__tsParticlesInternals.path.utils||{};var __tsProxyFactory=typeof Proxy!=="undefined"?function(obj){return new Proxy(obj,{get:function(target,key){if(!(key in target)){target[key]={};}return target[key];}});}:function(obj){return obj;};g.__tsParticlesInternals.bundles=__tsProxyFactory(g.__tsParticlesInternals.bundles);g.__tsParticlesInternals.effects=__tsProxyFactory(g.__tsParticlesInternals.effects);g.__tsParticlesInternals.interactions=__tsProxyFactory(g.__tsParticlesInternals.interactions);g.__tsParticlesInternals.palettes=__tsProxyFactory(g.__tsParticlesInternals.palettes);g.__tsParticlesInternals.paths=__tsProxyFactory(g.__tsParticlesInternals.paths);g.__tsParticlesInternals.plugins=__tsProxyFactory(g.__tsParticlesInternals.plugins);g.__tsParticlesInternals.plugins.emittersShapes=__tsProxyFactory(g.__tsParticlesInternals.plugins.emittersShapes);g.__tsParticlesInternals.presets=__tsProxyFactory(g.__tsParticlesInternals.presets);g.__tsParticlesInternals.shapes=__tsProxyFactory(g.__tsParticlesInternals.shapes);g.__tsParticlesInternals.updaters=__tsProxyFactory(g.__tsParticlesInternals.updaters);g.__tsParticlesInternals.utils=__tsProxyFactory(g.__tsParticlesInternals.utils);g.__tsParticlesInternals.canvas=__tsProxyFactory(g.__tsParticlesInternals.canvas);g.__tsParticlesInternals.path=__tsProxyFactory(g.__tsParticlesInternals.path);g.tsparticlesInternalExports=g.tsparticlesInternalExports||{};})(typeof globalThis!=="undefined"?globalThis:typeof window!=="undefined"?window:this);
2
- /* tsParticles v4.3.0 */
2
+ /* tsParticles v4.3.2 */
3
3
  (function (global, factory) {
4
4
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports) :
5
5
  typeof define === 'function' && define.amd ? define(['exports'], factory) :
@@ -332,6 +332,9 @@
332
332
  })(exports.PixelMode || (exports.PixelMode = {}));
333
333
 
334
334
  const minRadius$1 = 0;
335
+ function isForbiddenKey(key) {
336
+ return key === "__proto__" || key === "constructor" || key === "prototype";
337
+ }
335
338
  function hasMatchMedia() {
336
339
  return typeof matchMedia !== "undefined";
337
340
  }
@@ -407,7 +410,7 @@
407
410
  if (!hasNested) {
408
411
  const sourceDict = source, destDict = destination;
409
412
  for (const key of sourceKeys) {
410
- if (key === "__proto__" || key === "constructor" || key === "prototype") {
413
+ if (isForbiddenKey(key)) {
411
414
  continue;
412
415
  }
413
416
  const v = sourceDict[key];
@@ -418,7 +421,7 @@
418
421
  continue;
419
422
  }
420
423
  for (const key of sourceKeys) {
421
- if (key === "__proto__" || key === "constructor" || key === "prototype") {
424
+ if (isForbiddenKey(key)) {
422
425
  continue;
423
426
  }
424
427
  const sourceDict = source, destDict = destination, value = sourceDict[key];
@@ -877,7 +880,7 @@
877
880
  return this.#domArray;
878
881
  }
879
882
  get version() {
880
- return "4.3.0";
883
+ return "4.3.2";
881
884
  }
882
885
  addEventListener(type, listener) {
883
886
  this.#eventDispatcher.addEventListener(type, listener);
@@ -1160,7 +1163,12 @@
1160
1163
  }
1161
1164
  function loadExtendProperty(obj, key, value) {
1162
1165
  if (value !== undefined) {
1163
- obj[key] = deepExtend(obj[key] ?? {}, value);
1166
+ const keyStr = key;
1167
+ if (keyStr === "__proto__" || keyStr === "constructor" || keyStr === "prototype") {
1168
+ return;
1169
+ }
1170
+ const objRecord = obj, currentValue = Object.prototype.hasOwnProperty.call(objRecord, keyStr) ? objRecord[keyStr] : {};
1171
+ objRecord[keyStr] = deepExtend(currentValue, value);
1164
1172
  }
1165
1173
  }
1166
1174
  function loadOptionProperty(obj, key, optionClass, ...sources) {
@@ -2253,7 +2261,7 @@
2253
2261
  }
2254
2262
 
2255
2263
  async function loadBlendPlugin(engine) {
2256
- engine.checkVersion("4.3.0");
2264
+ engine.checkVersion("4.3.2");
2257
2265
  await engine.pluginManager.register(e => {
2258
2266
  e.pluginManager.addPlugin(new BlendPlugin());
2259
2267
  });
@@ -2290,7 +2298,7 @@
2290
2298
  }
2291
2299
 
2292
2300
  async function loadCircleShape(engine) {
2293
- engine.checkVersion("4.3.0");
2301
+ engine.checkVersion("4.3.2");
2294
2302
  await engine.pluginManager.register(e => {
2295
2303
  e.pluginManager.addShape(["circle"], () => {
2296
2304
  return Promise.resolve(new CircleDrawer());
@@ -2338,7 +2346,7 @@
2338
2346
  }
2339
2347
 
2340
2348
  async function loadHexColorPlugin(engine) {
2341
- engine.checkVersion("4.3.0");
2349
+ engine.checkVersion("4.3.2");
2342
2350
  await engine.pluginManager.register(e => {
2343
2351
  e.pluginManager.addColorManager("hex", new HexColorManager());
2344
2352
  });
@@ -2391,7 +2399,7 @@
2391
2399
  }
2392
2400
 
2393
2401
  async function loadHslColorPlugin(engine) {
2394
- engine.checkVersion("4.3.0");
2402
+ engine.checkVersion("4.3.2");
2395
2403
  await engine.pluginManager.register(e => {
2396
2404
  e.pluginManager.addColorManager("hsl", new HslColorManager());
2397
2405
  });
@@ -2415,7 +2423,7 @@
2415
2423
  }
2416
2424
 
2417
2425
  async function loadMovePlugin(engine) {
2418
- engine.checkVersion("4.3.0");
2426
+ engine.checkVersion("4.3.2");
2419
2427
  await engine.pluginManager.register(e => {
2420
2428
  const moveEngine = e, movePluginManager = moveEngine.pluginManager;
2421
2429
  movePluginManager.initializers.pathGenerators ??= new Map();
@@ -2625,7 +2633,7 @@
2625
2633
  }
2626
2634
 
2627
2635
  async function loadOpacityUpdater(engine) {
2628
- engine.checkVersion("4.3.0");
2636
+ engine.checkVersion("4.3.2");
2629
2637
  await engine.pluginManager.register(e => {
2630
2638
  e.pluginManager.addParticleUpdater("opacity", container => {
2631
2639
  return Promise.resolve(new OpacityUpdater(container));
@@ -2970,7 +2978,7 @@
2970
2978
  }
2971
2979
 
2972
2980
  async function loadOutModesUpdater(engine) {
2973
- engine.checkVersion("4.3.0");
2981
+ engine.checkVersion("4.3.2");
2974
2982
  await engine.pluginManager.register(e => {
2975
2983
  e.pluginManager.addParticleUpdater("outModes", container => {
2976
2984
  return Promise.resolve(new OutOfCanvasUpdater(container));
@@ -3041,7 +3049,7 @@
3041
3049
  }
3042
3050
 
3043
3051
  async function loadPaintUpdater(engine) {
3044
- engine.checkVersion("4.3.0");
3052
+ engine.checkVersion("4.3.2");
3045
3053
  await engine.pluginManager.register(e => {
3046
3054
  e.pluginManager.addParticleUpdater("paint", container => {
3047
3055
  return Promise.resolve(new PaintUpdater(e.pluginManager, container));
@@ -3096,7 +3104,7 @@
3096
3104
  }
3097
3105
 
3098
3106
  async function loadRgbColorPlugin(engine) {
3099
- engine.checkVersion("4.3.0");
3107
+ engine.checkVersion("4.3.2");
3100
3108
  await engine.pluginManager.register(e => {
3101
3109
  e.pluginManager.addColorManager("rgb", new RgbColorManager());
3102
3110
  });
@@ -3181,7 +3189,7 @@
3181
3189
  }
3182
3190
 
3183
3191
  async function loadSizeUpdater(engine) {
3184
- engine.checkVersion("4.3.0");
3192
+ engine.checkVersion("4.3.2");
3185
3193
  await engine.pluginManager.register(e => {
3186
3194
  e.pluginManager.addParticleUpdater("size", container => {
3187
3195
  return Promise.resolve(new SizeUpdater(container));
@@ -3190,7 +3198,7 @@
3190
3198
  }
3191
3199
 
3192
3200
  async function loadBasic(engine) {
3193
- engine.checkVersion("4.3.0");
3201
+ engine.checkVersion("4.3.2");
3194
3202
  await engine.pluginManager.register(async (e) => {
3195
3203
  await Promise.all([
3196
3204
  loadBlendPlugin(e),
@@ -3430,7 +3438,7 @@
3430
3438
  })(EmitterClickMode || (EmitterClickMode = {}));
3431
3439
 
3432
3440
  async function loadEmittersPluginSimple(engine) {
3433
- engine.checkVersion("4.3.0");
3441
+ engine.checkVersion("4.3.2");
3434
3442
  await engine.pluginManager.register(async (e) => {
3435
3443
  const instancesManager = await getEmittersInstancesManager(e);
3436
3444
  await addEmittersShapesManager(e);
@@ -3518,7 +3526,7 @@
3518
3526
  }
3519
3527
 
3520
3528
  async function loadEmittersShapeSquare(engine) {
3521
- engine.checkVersion("4.3.0");
3529
+ engine.checkVersion("4.3.2");
3522
3530
  await engine.pluginManager.register((e) => {
3523
3531
  ensureEmittersPluginLoaded(e);
3524
3532
  e.pluginManager.addEmitterShapeGenerator?.("square", new EmittersSquareShapeGenerator());
@@ -3662,7 +3670,7 @@
3662
3670
  }
3663
3671
 
3664
3672
  async function loadLifeUpdater(engine) {
3665
- engine.checkVersion("4.3.0");
3673
+ engine.checkVersion("4.3.2");
3666
3674
  await engine.pluginManager.register(e => {
3667
3675
  e.pluginManager.addParticleUpdater("life", container => {
3668
3676
  return Promise.resolve(new LifeUpdater(container));
@@ -3716,7 +3724,7 @@
3716
3724
  }
3717
3725
 
3718
3726
  async function loadMotionPlugin(engine) {
3719
- engine.checkVersion("4.3.0");
3727
+ engine.checkVersion("4.3.2");
3720
3728
  await engine.pluginManager.register(e => {
3721
3729
  e.pluginManager.addPlugin(new MotionPlugin());
3722
3730
  });
@@ -4114,7 +4122,7 @@
4114
4122
  }
4115
4123
 
4116
4124
  async function loadRibbonShape(engine) {
4117
- engine.checkVersion("4.3.0");
4125
+ engine.checkVersion("4.3.2");
4118
4126
  await engine.pluginManager.register(e => {
4119
4127
  e.pluginManager.addShape(["ribbon"], (container) => Promise.resolve(new RibbonDrawer(container)));
4120
4128
  });
@@ -4434,7 +4442,7 @@
4434
4442
 
4435
4443
  let initPromise = null;
4436
4444
  async function doInitPlugins(engine) {
4437
- engine.checkVersion("4.3.0");
4445
+ engine.checkVersion("4.3.2");
4438
4446
  await engine.pluginManager.register(async (e) => {
4439
4447
  const emittersRegister = async (engine) => {
4440
4448
  await loadEmittersPluginSimple(engine);
@@ -4501,7 +4509,7 @@
4501
4509
  ribbons.init = async () => {
4502
4510
  await initPlugins(tsParticles);
4503
4511
  };
4504
- ribbons.version = "4.3.0";
4512
+ ribbons.version = "4.3.2";
4505
4513
  globalThis.ribbons = ribbons;
4506
4514
 
4507
4515
  const globalObject = globalThis;