@tsparticles/preset-links 3.0.0-alpha.1 → 3.0.0-beta.1
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/README.md +13 -37
- package/browser/bundle.js +1 -3
- package/browser/index.js +5 -15
- package/browser/options.js +3 -0
- package/browser/package.json +1 -0
- package/cjs/bundle.js +1 -12
- package/cjs/index.js +5 -26
- package/cjs/options.js +3 -0
- package/cjs/package.json +1 -0
- package/esm/bundle.js +1 -3
- package/esm/index.js +5 -15
- package/esm/options.js +3 -0
- package/esm/package.json +1 -0
- package/package.json +11 -15
- package/report.html +4 -4
- package/tsparticles.preset.links.bundle.js +2116 -2329
- package/tsparticles.preset.links.bundle.min.js +1 -1
- package/tsparticles.preset.links.bundle.min.js.LICENSE.txt +1 -8
- package/tsparticles.preset.links.js +32 -22
- package/tsparticles.preset.links.min.js +1 -1
- package/tsparticles.preset.links.min.js.LICENSE.txt +1 -8
- package/types/index.d.ts +1 -1
- package/types/options.d.ts +23 -2
- package/umd/bundle.js +1 -3
- package/umd/index.js +6 -16
- package/umd/options.js +3 -0
package/types/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { Engine } from "@tsparticles/engine";
|
|
2
|
-
export declare function loadLinksPreset(engine: Engine): Promise<void>;
|
|
2
|
+
export declare function loadLinksPreset(engine: Engine, refresh?: boolean): Promise<void>;
|
package/types/options.d.ts
CHANGED
|
@@ -1,2 +1,23 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
export declare const options: {
|
|
2
|
+
background: {
|
|
3
|
+
color: string;
|
|
4
|
+
};
|
|
5
|
+
particles: {
|
|
6
|
+
number: {
|
|
7
|
+
value: number;
|
|
8
|
+
};
|
|
9
|
+
links: {
|
|
10
|
+
distance: number;
|
|
11
|
+
enable: boolean;
|
|
12
|
+
};
|
|
13
|
+
move: {
|
|
14
|
+
enable: boolean;
|
|
15
|
+
};
|
|
16
|
+
size: {
|
|
17
|
+
value: number;
|
|
18
|
+
};
|
|
19
|
+
shape: {
|
|
20
|
+
type: string;
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
};
|
package/umd/bundle.js
CHANGED
|
@@ -14,7 +14,5 @@
|
|
|
14
14
|
Object.defineProperty(exports, "loadLinksPreset", { enumerable: true, get: function () { return _1.loadLinksPreset; } });
|
|
15
15
|
const engine_1 = require("@tsparticles/engine");
|
|
16
16
|
Object.defineProperty(exports, "tsParticles", { enumerable: true, get: function () { return engine_1.tsParticles; } });
|
|
17
|
-
(
|
|
18
|
-
await (0, _1.loadLinksPreset)(engine_1.tsParticles);
|
|
19
|
-
})();
|
|
17
|
+
(0, _1.loadLinksPreset)(engine_1.tsParticles);
|
|
20
18
|
});
|
package/umd/index.js
CHANGED
|
@@ -4,29 +4,19 @@
|
|
|
4
4
|
if (v !== undefined) module.exports = v;
|
|
5
5
|
}
|
|
6
6
|
else if (typeof define === "function" && define.amd) {
|
|
7
|
-
define(["require", "exports", "@tsparticles/
|
|
7
|
+
define(["require", "exports", "@tsparticles/basic", "@tsparticles/interaction-particles-links", "./options"], factory);
|
|
8
8
|
}
|
|
9
9
|
})(function (require, exports) {
|
|
10
10
|
"use strict";
|
|
11
11
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
12
|
exports.loadLinksPreset = void 0;
|
|
13
|
-
const
|
|
14
|
-
const shape_circle_1 = require("@tsparticles/shape-circle");
|
|
15
|
-
const updater_color_1 = require("@tsparticles/updater-color");
|
|
16
|
-
const updater_opacity_1 = require("@tsparticles/updater-opacity");
|
|
17
|
-
const updater_out_modes_1 = require("@tsparticles/updater-out-modes");
|
|
13
|
+
const basic_1 = require("@tsparticles/basic");
|
|
18
14
|
const interaction_particles_links_1 = require("@tsparticles/interaction-particles-links");
|
|
19
|
-
const updater_size_1 = require("@tsparticles/updater-size");
|
|
20
15
|
const options_1 = require("./options");
|
|
21
|
-
async function loadLinksPreset(engine) {
|
|
22
|
-
await (0,
|
|
23
|
-
await (0,
|
|
24
|
-
await (
|
|
25
|
-
await (0, interaction_particles_links_1.loadParticlesLinksInteraction)(engine);
|
|
26
|
-
await (0, updater_out_modes_1.loadOutModesUpdater)(engine);
|
|
27
|
-
await (0, updater_opacity_1.loadOpacityUpdater)(engine);
|
|
28
|
-
await (0, updater_size_1.loadSizeUpdater)(engine);
|
|
29
|
-
await engine.addPreset("links", options_1.options);
|
|
16
|
+
async function loadLinksPreset(engine, refresh = true) {
|
|
17
|
+
await (0, basic_1.loadBasic)(engine, false);
|
|
18
|
+
await (0, interaction_particles_links_1.loadParticlesLinksInteraction)(engine, false);
|
|
19
|
+
await engine.addPreset("links", options_1.options, refresh);
|
|
30
20
|
}
|
|
31
21
|
exports.loadLinksPreset = loadLinksPreset;
|
|
32
22
|
});
|