@tsparticles/interaction-particles-links 3.9.1 → 4.0.0-alpha.0
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/418.min.js +2 -0
- package/418.min.js.LICENSE.txt +1 -0
- package/497.min.js +2 -0
- package/497.min.js.LICENSE.txt +1 -0
- package/711.min.js +2 -0
- package/711.min.js.LICENSE.txt +1 -0
- package/956.min.js +2 -0
- package/956.min.js.LICENSE.txt +1 -0
- package/browser/CircleWarp.js +2 -2
- package/browser/LinkInstance.js +7 -7
- package/browser/Linker.js +4 -7
- package/browser/Utils.js +5 -11
- package/browser/index.js +7 -9
- package/browser/interaction.js +7 -5
- package/browser/plugin.js +5 -4
- package/cjs/CircleWarp.js +6 -10
- package/cjs/Interfaces.js +1 -2
- package/cjs/LinkInstance.js +22 -26
- package/cjs/Linker.js +12 -19
- package/cjs/LinksPlugin.js +3 -7
- package/cjs/Options/Classes/Links.js +9 -13
- package/cjs/Options/Classes/LinksShadow.js +5 -9
- package/cjs/Options/Classes/LinksTriangle.js +4 -8
- package/cjs/Options/Interfaces/ILinks.js +1 -2
- package/cjs/Options/Interfaces/ILinksShadow.js +1 -2
- package/cjs/Options/Interfaces/ILinksTriangle.js +1 -2
- package/cjs/Types.js +1 -2
- package/cjs/Utils.js +20 -33
- package/cjs/index.js +10 -29
- package/cjs/interaction.js +7 -8
- package/cjs/plugin.js +5 -7
- package/dist_browser_Linker_js.js +40 -0
- package/dist_browser_LinksPlugin_js.js +50 -0
- package/dist_browser_interaction_js.js +30 -0
- package/dist_browser_plugin_js.js +30 -0
- package/esm/CircleWarp.js +2 -2
- package/esm/LinkInstance.js +7 -7
- package/esm/Linker.js +4 -7
- package/esm/Utils.js +5 -11
- package/esm/index.js +7 -9
- package/esm/interaction.js +7 -5
- package/esm/plugin.js +5 -4
- package/package.json +4 -3
- package/report.html +5 -4
- package/tsparticles.interaction.particles.links.js +221 -102
- package/tsparticles.interaction.particles.links.min.js +1 -1
- package/tsparticles.interaction.particles.links.min.js.LICENSE.txt +1 -1
- package/types/LinkInstance.d.ts +1 -1
- package/types/Linker.d.ts +1 -2
- package/types/Types.d.ts +3 -3
- package/types/index.d.ts +4 -4
- package/types/interaction.d.ts +1 -1
- package/types/plugin.d.ts +1 -1
- package/umd/CircleWarp.js +2 -2
- package/umd/LinkInstance.js +7 -7
- package/umd/Linker.js +4 -7
- package/umd/Utils.js +5 -11
- package/umd/index.js +31 -10
- package/umd/interaction.js +42 -6
- package/umd/plugin.js +40 -5
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Demo / Generator : https://particles.js.org/
|
|
5
5
|
* GitHub : https://www.github.com/matteobruni/tsparticles
|
|
6
6
|
* How to use? : Check the GitHub README
|
|
7
|
-
*
|
|
7
|
+
* v4.0.0-alpha.0
|
|
8
8
|
*/
|
|
9
9
|
/*
|
|
10
10
|
* ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
|
|
@@ -28,125 +28,55 @@ return /******/ (() => { // webpackBootstrap
|
|
|
28
28
|
/******/ "use strict";
|
|
29
29
|
/******/ var __webpack_modules__ = ({
|
|
30
30
|
|
|
31
|
-
/***/ "./dist/browser/
|
|
32
|
-
/*!************************************!*\
|
|
33
|
-
!*** ./dist/browser/CircleWarp.js ***!
|
|
34
|
-
\************************************/
|
|
35
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
36
|
-
|
|
37
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ CircleWarp: () => (/* binding */ CircleWarp)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__);\n\nconst double = 2;\nclass CircleWarp extends _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.Circle {\n constructor(x, y, radius, canvasSize) {\n super(x, y, radius);\n this.canvasSize = canvasSize;\n this.canvasSize = {\n ...canvasSize\n };\n }\n contains(point) {\n const {\n width,\n height\n } = this.canvasSize,\n {\n x,\n y\n } = point;\n return super.contains(point) || super.contains({\n x: x - width,\n y\n }) || super.contains({\n x: x - width,\n y: y - height\n }) || super.contains({\n x,\n y: y - height\n });\n }\n intersects(range) {\n if (super.intersects(range)) {\n return true;\n }\n const rect = range,\n circle = range,\n newPos = {\n x: range.position.x - this.canvasSize.width,\n y: range.position.y - this.canvasSize.height\n };\n if (circle.radius !== undefined) {\n const biggerCircle = new _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.Circle(newPos.x, newPos.y, circle.radius * double);\n return super.intersects(biggerCircle);\n } else if (rect.size !== undefined) {\n const rectSW = new _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.Rectangle(newPos.x, newPos.y, rect.size.width * double, rect.size.height * double);\n return super.intersects(rectSW);\n }\n return false;\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/CircleWarp.js?\n}");
|
|
38
|
-
|
|
39
|
-
/***/ }),
|
|
40
|
-
|
|
41
|
-
/***/ "./dist/browser/LinkInstance.js":
|
|
42
|
-
/*!**************************************!*\
|
|
43
|
-
!*** ./dist/browser/LinkInstance.js ***!
|
|
44
|
-
\**************************************/
|
|
45
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
46
|
-
|
|
47
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinkInstance: () => (/* binding */ LinkInstance)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _Utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Utils.js */ \"./dist/browser/Utils.js\");\n\n\nconst minOpacity = 0,\n minWidth = 0,\n minDistance = 0,\n half = 0.5,\n maxFrequency = 1;\nclass LinkInstance {\n constructor(container, engine) {\n this._drawLinkLine = (p1, link) => {\n const p1LinksOptions = p1.options.links;\n if (!p1LinksOptions?.enable) {\n return;\n }\n const container = this._container,\n options = container.actualOptions,\n p2 = link.destination,\n pos1 = p1.getPosition(),\n pos2 = p2.getPosition();\n let opacity = link.opacity;\n container.canvas.draw(ctx => {\n let colorLine;\n const twinkle = p1.options.twinkle?.lines;\n if (twinkle?.enable) {\n const twinkleFreq = twinkle.frequency,\n twinkleRgb = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.rangeColorToRgb)(this._engine, twinkle.color),\n twinkling = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRandom)() < twinkleFreq;\n if (twinkling && twinkleRgb) {\n colorLine = twinkleRgb;\n opacity = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRangeValue)(twinkle.opacity);\n }\n }\n if (!colorLine) {\n const linkColor = p1LinksOptions.id !== undefined ? container.particles.linksColors.get(p1LinksOptions.id) : container.particles.linksColor;\n colorLine = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getLinkColor)(p1, p2, linkColor);\n }\n if (!colorLine) {\n return;\n }\n const width = p1.retina.linksWidth ?? minWidth,\n maxDistance = p1.retina.linksDistance ?? minDistance,\n {\n backgroundMask\n } = options;\n (0,_Utils_js__WEBPACK_IMPORTED_MODULE_1__.drawLinkLine)({\n context: ctx,\n width,\n begin: pos1,\n end: pos2,\n engine: this._engine,\n maxDistance,\n canvasSize: container.canvas.size,\n links: p1LinksOptions,\n backgroundMask: backgroundMask,\n colorLine,\n opacity\n });\n });\n };\n this._drawLinkTriangle = (p1, link1, link2) => {\n const linksOptions = p1.options.links;\n if (!linksOptions?.enable) {\n return;\n }\n const triangleOptions = linksOptions.triangles;\n if (!triangleOptions.enable) {\n return;\n }\n const container = this._container,\n options = container.actualOptions,\n p2 = link1.destination,\n p3 = link2.destination,\n opacityTriangle = triangleOptions.opacity ?? (link1.opacity + link2.opacity) * half;\n if (opacityTriangle <= minOpacity) {\n return;\n }\n container.canvas.draw(ctx => {\n const pos1 = p1.getPosition(),\n pos2 = p2.getPosition(),\n pos3 = p3.getPosition(),\n linksDistance = p1.retina.linksDistance ?? minDistance;\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistance)(pos1, pos2) > linksDistance || (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistance)(pos3, pos2) > linksDistance || (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistance)(pos3, pos1) > linksDistance) {\n return;\n }\n let colorTriangle = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.rangeColorToRgb)(this._engine, triangleOptions.color);\n if (!colorTriangle) {\n const linkColor = linksOptions.id !== undefined ? container.particles.linksColors.get(linksOptions.id) : container.particles.linksColor;\n colorTriangle = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getLinkColor)(p1, p2, linkColor);\n }\n if (!colorTriangle) {\n return;\n }\n (0,_Utils_js__WEBPACK_IMPORTED_MODULE_1__.drawLinkTriangle)({\n context: ctx,\n pos1,\n pos2,\n pos3,\n backgroundMask: options.backgroundMask,\n colorTriangle,\n opacityTriangle\n });\n });\n };\n this._drawTriangles = (options, p1, link, p1Links) => {\n const p2 = link.destination;\n if (!(options.links?.triangles.enable && p2.options.links?.triangles.enable)) {\n return;\n }\n const vertices = p2.links?.filter(t => {\n const linkFreq = this._getLinkFrequency(p2, t.destination),\n minCount = 0;\n return p2.options.links && linkFreq <= p2.options.links.frequency && p1Links.findIndex(l => l.destination === t.destination) >= minCount;\n });\n if (!vertices?.length) {\n return;\n }\n for (const vertex of vertices) {\n const p3 = vertex.destination,\n triangleFreq = this._getTriangleFrequency(p1, p2, p3);\n if (triangleFreq > options.links.triangles.frequency) {\n continue;\n }\n this._drawLinkTriangle(p1, link, vertex);\n }\n };\n this._getLinkFrequency = (p1, p2) => {\n return (0,_Utils_js__WEBPACK_IMPORTED_MODULE_1__.setLinkFrequency)([p1, p2], this._freqs.links);\n };\n this._getTriangleFrequency = (p1, p2, p3) => {\n return (0,_Utils_js__WEBPACK_IMPORTED_MODULE_1__.setLinkFrequency)([p1, p2, p3], this._freqs.triangles);\n };\n this._container = container;\n this._engine = engine;\n this._freqs = {\n links: new Map(),\n triangles: new Map()\n };\n }\n drawParticle(context, particle) {\n const {\n links,\n options\n } = particle;\n if (!links?.length) {\n return;\n }\n const p1Links = links.filter(l => options.links && (options.links.frequency >= maxFrequency || this._getLinkFrequency(particle, l.destination) <= options.links.frequency));\n for (const link of p1Links) {\n this._drawTriangles(options, particle, link, p1Links);\n if (link.opacity > minOpacity && (particle.retina.linksWidth ?? minWidth) > minWidth) {\n this._drawLinkLine(particle, link);\n }\n }\n }\n async init() {\n this._freqs.links = new Map();\n this._freqs.triangles = new Map();\n await Promise.resolve();\n }\n particleCreated(particle) {\n particle.links = [];\n if (!particle.options.links) {\n return;\n }\n const ratio = this._container.retina.pixelRatio,\n {\n retina\n } = particle,\n {\n distance,\n width\n } = particle.options.links;\n retina.linksDistance = distance * ratio;\n retina.linksWidth = width * ratio;\n }\n particleDestroyed(particle) {\n particle.links = [];\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/LinkInstance.js?\n}");
|
|
48
|
-
|
|
49
|
-
/***/ }),
|
|
50
|
-
|
|
51
|
-
/***/ "./dist/browser/Linker.js":
|
|
52
|
-
/*!********************************!*\
|
|
53
|
-
!*** ./dist/browser/Linker.js ***!
|
|
54
|
-
\********************************/
|
|
55
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
56
|
-
|
|
57
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Linker: () => (/* binding */ Linker)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _CircleWarp_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./CircleWarp.js */ \"./dist/browser/CircleWarp.js\");\n/* harmony import */ var _Options_Classes_Links_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Options/Classes/Links.js */ \"./dist/browser/Options/Classes/Links.js\");\n\n\n\nconst squarePower = 2,\n opacityOffset = 1,\n origin = {\n x: 0,\n y: 0\n },\n minDistance = 0;\nfunction getLinkDistance(pos1, pos2, optDistance, canvasSize, warp) {\n const {\n dx,\n dy,\n distance\n } = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistances)(pos1, pos2);\n if (!warp || distance <= optDistance) {\n return distance;\n }\n const absDiffs = {\n x: Math.abs(dx),\n y: Math.abs(dy)\n },\n warpDistances = {\n x: Math.min(absDiffs.x, canvasSize.width - absDiffs.x),\n y: Math.min(absDiffs.y, canvasSize.height - absDiffs.y)\n };\n return Math.sqrt(warpDistances.x ** squarePower + warpDistances.y ** squarePower);\n}\nclass Linker extends _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.ParticlesInteractorBase {\n constructor(container, engine) {\n super(container);\n this._setColor = p1 => {\n if (!p1.options.links) {\n return;\n }\n const container = this._linkContainer,\n linksOptions = p1.options.links;\n let linkColor = linksOptions.id === undefined ? container.particles.linksColor : container.particles.linksColors.get(linksOptions.id);\n if (linkColor) {\n return;\n }\n const optColor = linksOptions.color;\n linkColor = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getLinkRandomColor)(this._engine, optColor, linksOptions.blink, linksOptions.consent);\n if (linksOptions.id === undefined) {\n container.particles.linksColor = linkColor;\n } else {\n container.particles.linksColors.set(linksOptions.id, linkColor);\n }\n };\n this._linkContainer = container;\n this._engine = engine;\n }\n clear() {}\n init() {\n this._linkContainer.particles.linksColor = undefined;\n this._linkContainer.particles.linksColors = new Map();\n }\n interact(p1) {\n if (!p1.options.links) {\n return;\n }\n p1.links = [];\n const pos1 = p1.getPosition(),\n container = this.container,\n canvasSize = container.canvas.size;\n if (pos1.x < origin.x || pos1.y < origin.y || pos1.x > canvasSize.width || pos1.y > canvasSize.height) {\n return;\n }\n const linkOpt1 = p1.options.links,\n optOpacity = linkOpt1.opacity,\n optDistance = p1.retina.linksDistance ?? minDistance,\n warp = linkOpt1.warp;\n let range;\n if (warp) {\n range = new _CircleWarp_js__WEBPACK_IMPORTED_MODULE_1__.CircleWarp(pos1.x, pos1.y, optDistance, canvasSize);\n } else {\n range = new _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.Circle(pos1.x, pos1.y, optDistance);\n }\n const query = container.particles.quadTree.query(range);\n for (const p2 of query) {\n const linkOpt2 = p2.options.links;\n if (p1 === p2 || !linkOpt2?.enable || linkOpt1.id !== linkOpt2.id || p2.spawning || p2.destroyed || !p2.links || p1.links.some(t => t.destination === p2) || p2.links.some(t => t.destination === p1)) {\n continue;\n }\n const pos2 = p2.getPosition();\n if (pos2.x < origin.x || pos2.y < origin.y || pos2.x > canvasSize.width || pos2.y > canvasSize.height) {\n continue;\n }\n const distance = getLinkDistance(pos1, pos2, optDistance, canvasSize, warp && linkOpt2.warp);\n if (distance > optDistance) {\n continue;\n }\n const opacityLine = (opacityOffset - distance / optDistance) * optOpacity;\n this._setColor(p1);\n p1.links.push({\n destination: p2,\n opacity: opacityLine\n });\n }\n }\n isEnabled(particle) {\n return !!particle.options.links?.enable;\n }\n loadParticlesOptions(options, ...sources) {\n if (!options.links) {\n options.links = new _Options_Classes_Links_js__WEBPACK_IMPORTED_MODULE_2__.Links();\n }\n for (const source of sources) {\n options.links.load(source?.links);\n }\n }\n reset() {}\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/Linker.js?\n}");
|
|
58
|
-
|
|
59
|
-
/***/ }),
|
|
60
|
-
|
|
61
|
-
/***/ "./dist/browser/LinksPlugin.js":
|
|
62
|
-
/*!*************************************!*\
|
|
63
|
-
!*** ./dist/browser/LinksPlugin.js ***!
|
|
64
|
-
\*************************************/
|
|
65
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
66
|
-
|
|
67
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinksPlugin: () => (/* binding */ LinksPlugin)\n/* harmony export */ });\n/* harmony import */ var _LinkInstance_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./LinkInstance.js */ \"./dist/browser/LinkInstance.js\");\n\nclass LinksPlugin {\n constructor(engine) {\n this.id = \"links\";\n this._engine = engine;\n }\n getPlugin(container) {\n return Promise.resolve(new _LinkInstance_js__WEBPACK_IMPORTED_MODULE_0__.LinkInstance(container, this._engine));\n }\n loadOptions() {}\n needsPlugin() {\n return true;\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/LinksPlugin.js?\n}");
|
|
68
|
-
|
|
69
|
-
/***/ }),
|
|
70
|
-
|
|
71
|
-
/***/ "./dist/browser/Options/Classes/Links.js":
|
|
31
|
+
/***/ "./dist/browser/Options/Classes/Links.js"
|
|
72
32
|
/*!***********************************************!*\
|
|
73
33
|
!*** ./dist/browser/Options/Classes/Links.js ***!
|
|
74
34
|
\***********************************************/
|
|
75
|
-
|
|
35
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
76
36
|
|
|
77
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Links: () => (/* binding */ Links)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var
|
|
37
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Links: () => (/* binding */ Links)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _LinksShadow_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./LinksShadow.js */ \"./dist/browser/Options/Classes/LinksShadow.js\");\n/* harmony import */ var _LinksTriangle_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./LinksTriangle.js */ \"./dist/browser/Options/Classes/LinksTriangle.js\");\n\n\n\nclass Links {\n constructor() {\n this.blink = false;\n this.color = new _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor();\n this.color.value = \"#fff\";\n this.consent = false;\n this.distance = 100;\n this.enable = false;\n this.frequency = 1;\n this.opacity = 1;\n this.shadow = new _LinksShadow_js__WEBPACK_IMPORTED_MODULE_1__.LinksShadow();\n this.triangles = new _LinksTriangle_js__WEBPACK_IMPORTED_MODULE_2__.LinksTriangle();\n this.width = 1;\n this.warp = false;\n }\n load(data) {\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isNull)(data)) {\n return;\n }\n if (data.id !== undefined) {\n this.id = data.id;\n }\n if (data.blink !== undefined) {\n this.blink = data.blink;\n }\n this.color = _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor.create(this.color, data.color);\n if (data.consent !== undefined) {\n this.consent = data.consent;\n }\n if (data.distance !== undefined) {\n this.distance = data.distance;\n }\n if (data.enable !== undefined) {\n this.enable = data.enable;\n }\n if (data.frequency !== undefined) {\n this.frequency = data.frequency;\n }\n if (data.opacity !== undefined) {\n this.opacity = data.opacity;\n }\n this.shadow.load(data.shadow);\n this.triangles.load(data.triangles);\n if (data.width !== undefined) {\n this.width = data.width;\n }\n if (data.warp !== undefined) {\n this.warp = data.warp;\n }\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/Options/Classes/Links.js?\n}");
|
|
78
38
|
|
|
79
|
-
/***/ }
|
|
39
|
+
/***/ },
|
|
80
40
|
|
|
81
|
-
/***/ "./dist/browser/Options/Classes/LinksShadow.js"
|
|
41
|
+
/***/ "./dist/browser/Options/Classes/LinksShadow.js"
|
|
82
42
|
/*!*****************************************************!*\
|
|
83
43
|
!*** ./dist/browser/Options/Classes/LinksShadow.js ***!
|
|
84
44
|
\*****************************************************/
|
|
85
|
-
|
|
45
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
86
46
|
|
|
87
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinksShadow: () => (/* binding */ LinksShadow)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n
|
|
47
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinksShadow: () => (/* binding */ LinksShadow)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n\nclass LinksShadow {\n constructor() {\n this.blur = 5;\n this.color = new _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor();\n this.color.value = \"#000\";\n this.enable = false;\n }\n load(data) {\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isNull)(data)) {\n return;\n }\n if (data.blur !== undefined) {\n this.blur = data.blur;\n }\n this.color = _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor.create(this.color, data.color);\n if (data.enable !== undefined) {\n this.enable = data.enable;\n }\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/Options/Classes/LinksShadow.js?\n}");
|
|
88
48
|
|
|
89
|
-
/***/ }
|
|
49
|
+
/***/ },
|
|
90
50
|
|
|
91
|
-
/***/ "./dist/browser/Options/Classes/LinksTriangle.js"
|
|
51
|
+
/***/ "./dist/browser/Options/Classes/LinksTriangle.js"
|
|
92
52
|
/*!*******************************************************!*\
|
|
93
53
|
!*** ./dist/browser/Options/Classes/LinksTriangle.js ***!
|
|
94
54
|
\*******************************************************/
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinksTriangle: () => (/* binding */ LinksTriangle)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__);\n\nclass LinksTriangle {\n constructor() {\n this.enable = false;\n this.frequency = 1;\n }\n load(data) {\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isNull)(data)) {\n return;\n }\n if (data.color !== undefined) {\n this.color = _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor.create(this.color, data.color);\n }\n if (data.enable !== undefined) {\n this.enable = data.enable;\n }\n if (data.frequency !== undefined) {\n this.frequency = data.frequency;\n }\n if (data.opacity !== undefined) {\n this.opacity = data.opacity;\n }\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/Options/Classes/LinksTriangle.js?\n}");
|
|
98
|
-
|
|
99
|
-
/***/ }),
|
|
100
|
-
|
|
101
|
-
/***/ "./dist/browser/Utils.js":
|
|
102
|
-
/*!*******************************!*\
|
|
103
|
-
!*** ./dist/browser/Utils.js ***!
|
|
104
|
-
\*******************************/
|
|
105
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
55
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
106
56
|
|
|
107
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */
|
|
57
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ LinksTriangle: () => (/* binding */ LinksTriangle)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n\nclass LinksTriangle {\n constructor() {\n this.enable = false;\n this.frequency = 1;\n }\n load(data) {\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isNull)(data)) {\n return;\n }\n if (data.color !== undefined) {\n this.color = _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.OptionsColor.create(this.color, data.color);\n }\n if (data.enable !== undefined) {\n this.enable = data.enable;\n }\n if (data.frequency !== undefined) {\n this.frequency = data.frequency;\n }\n if (data.opacity !== undefined) {\n this.opacity = data.opacity;\n }\n }\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/Options/Classes/LinksTriangle.js?\n}");
|
|
108
58
|
|
|
109
|
-
/***/ }
|
|
59
|
+
/***/ },
|
|
110
60
|
|
|
111
|
-
/***/ "./dist/browser/index.js"
|
|
61
|
+
/***/ "./dist/browser/index.js"
|
|
112
62
|
/*!*******************************!*\
|
|
113
63
|
!*** ./dist/browser/index.js ***!
|
|
114
64
|
\*******************************/
|
|
115
|
-
|
|
65
|
+
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
116
66
|
|
|
117
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Links: () => (/* reexport safe */
|
|
67
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Links: () => (/* reexport safe */ _Options_Classes_Links_js__WEBPACK_IMPORTED_MODULE_0__.Links),\n/* harmony export */ LinksShadow: () => (/* reexport safe */ _Options_Classes_LinksShadow_js__WEBPACK_IMPORTED_MODULE_1__.LinksShadow),\n/* harmony export */ LinksTriangle: () => (/* reexport safe */ _Options_Classes_LinksTriangle_js__WEBPACK_IMPORTED_MODULE_2__.LinksTriangle),\n/* harmony export */ loadParticlesLinksInteraction: () => (/* binding */ loadParticlesLinksInteraction)\n/* harmony export */ });\n/* harmony import */ var _Options_Classes_Links_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Options/Classes/Links.js */ \"./dist/browser/Options/Classes/Links.js\");\n/* harmony import */ var _Options_Classes_LinksShadow_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Options/Classes/LinksShadow.js */ \"./dist/browser/Options/Classes/LinksShadow.js\");\n/* harmony import */ var _Options_Classes_LinksTriangle_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Options/Classes/LinksTriangle.js */ \"./dist/browser/Options/Classes/LinksTriangle.js\");\nfunction loadParticlesLinksInteraction(engine) {\n engine.checkVersion(\"4.0.0-alpha.0\");\n engine.register(async e => {\n const {\n loadLinksInteraction\n } = await __webpack_require__.e(/*! import() */ \"dist_browser_interaction_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./interaction.js */ \"./dist/browser/interaction.js\")),\n {\n loadLinksPlugin\n } = await __webpack_require__.e(/*! import() */ \"dist_browser_plugin_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./plugin.js */ \"./dist/browser/plugin.js\"));\n loadLinksInteraction(e);\n loadLinksPlugin(e);\n });\n}\n\n\n\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/index.js?\n}");
|
|
118
68
|
|
|
119
|
-
/***/ }
|
|
69
|
+
/***/ },
|
|
120
70
|
|
|
121
|
-
/***/ "
|
|
122
|
-
/*!*************************************!*\
|
|
123
|
-
!*** ./dist/browser/interaction.js ***!
|
|
124
|
-
\*************************************/
|
|
125
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
126
|
-
|
|
127
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadLinksInteraction: () => (/* binding */ loadLinksInteraction)\n/* harmony export */ });\n/* harmony import */ var _Linker_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Linker.js */ \"./dist/browser/Linker.js\");\n\nasync function loadLinksInteraction(engine, refresh = true) {\n await engine.addInteractor(\"particlesLinks\", async container => {\n return Promise.resolve(new _Linker_js__WEBPACK_IMPORTED_MODULE_0__.Linker(container, engine));\n }, refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/interaction.js?\n}");
|
|
128
|
-
|
|
129
|
-
/***/ }),
|
|
130
|
-
|
|
131
|
-
/***/ "./dist/browser/plugin.js":
|
|
132
|
-
/*!********************************!*\
|
|
133
|
-
!*** ./dist/browser/plugin.js ***!
|
|
134
|
-
\********************************/
|
|
135
|
-
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
136
|
-
|
|
137
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadLinksPlugin: () => (/* binding */ loadLinksPlugin)\n/* harmony export */ });\n/* harmony import */ var _LinksPlugin_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./LinksPlugin.js */ \"./dist/browser/LinksPlugin.js\");\n\nasync function loadLinksPlugin(engine, refresh = true) {\n const plugin = new _LinksPlugin_js__WEBPACK_IMPORTED_MODULE_0__.LinksPlugin(engine);\n await engine.addPlugin(plugin, refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/interaction-particles-links/./dist/browser/plugin.js?\n}");
|
|
138
|
-
|
|
139
|
-
/***/ }),
|
|
140
|
-
|
|
141
|
-
/***/ "@tsparticles/engine":
|
|
71
|
+
/***/ "@tsparticles/engine"
|
|
142
72
|
/*!*********************************************************************************************************************************!*\
|
|
143
73
|
!*** external {"commonjs":"@tsparticles/engine","commonjs2":"@tsparticles/engine","amd":"@tsparticles/engine","root":"window"} ***!
|
|
144
74
|
\*********************************************************************************************************************************/
|
|
145
|
-
|
|
75
|
+
(module) {
|
|
146
76
|
|
|
147
77
|
module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_engine__;
|
|
148
78
|
|
|
149
|
-
/***/ }
|
|
79
|
+
/***/ }
|
|
150
80
|
|
|
151
81
|
/******/ });
|
|
152
82
|
/************************************************************************/
|
|
@@ -160,6 +90,12 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_engine__;
|
|
|
160
90
|
/******/ if (cachedModule !== undefined) {
|
|
161
91
|
/******/ return cachedModule.exports;
|
|
162
92
|
/******/ }
|
|
93
|
+
/******/ // Check if module exists (development only)
|
|
94
|
+
/******/ if (__webpack_modules__[moduleId] === undefined) {
|
|
95
|
+
/******/ var e = new Error("Cannot find module '" + moduleId + "'");
|
|
96
|
+
/******/ e.code = 'MODULE_NOT_FOUND';
|
|
97
|
+
/******/ throw e;
|
|
98
|
+
/******/ }
|
|
163
99
|
/******/ // Create a new module (and put it into the cache)
|
|
164
100
|
/******/ var module = __webpack_module_cache__[moduleId] = {
|
|
165
101
|
/******/ // no module.id needed
|
|
@@ -174,19 +110,10 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_engine__;
|
|
|
174
110
|
/******/ return module.exports;
|
|
175
111
|
/******/ }
|
|
176
112
|
/******/
|
|
177
|
-
|
|
178
|
-
/******/
|
|
179
|
-
/******/ (() => {
|
|
180
|
-
/******/ // getDefaultExport function for compatibility with non-harmony modules
|
|
181
|
-
/******/ __webpack_require__.n = (module) => {
|
|
182
|
-
/******/ var getter = module && module.__esModule ?
|
|
183
|
-
/******/ () => (module['default']) :
|
|
184
|
-
/******/ () => (module);
|
|
185
|
-
/******/ __webpack_require__.d(getter, { a: getter });
|
|
186
|
-
/******/ return getter;
|
|
187
|
-
/******/ };
|
|
188
|
-
/******/ })();
|
|
113
|
+
/******/ // expose the modules object (__webpack_modules__)
|
|
114
|
+
/******/ __webpack_require__.m = __webpack_modules__;
|
|
189
115
|
/******/
|
|
116
|
+
/************************************************************************/
|
|
190
117
|
/******/ /* webpack/runtime/define property getters */
|
|
191
118
|
/******/ (() => {
|
|
192
119
|
/******/ // define getter functions for harmony exports
|
|
@@ -199,11 +126,90 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_engine__;
|
|
|
199
126
|
/******/ };
|
|
200
127
|
/******/ })();
|
|
201
128
|
/******/
|
|
129
|
+
/******/ /* webpack/runtime/ensure chunk */
|
|
130
|
+
/******/ (() => {
|
|
131
|
+
/******/ __webpack_require__.f = {};
|
|
132
|
+
/******/ // This file contains only the entry chunk.
|
|
133
|
+
/******/ // The chunk loading function for additional chunks
|
|
134
|
+
/******/ __webpack_require__.e = (chunkId) => {
|
|
135
|
+
/******/ return Promise.all(Object.keys(__webpack_require__.f).reduce((promises, key) => {
|
|
136
|
+
/******/ __webpack_require__.f[key](chunkId, promises);
|
|
137
|
+
/******/ return promises;
|
|
138
|
+
/******/ }, []));
|
|
139
|
+
/******/ };
|
|
140
|
+
/******/ })();
|
|
141
|
+
/******/
|
|
142
|
+
/******/ /* webpack/runtime/get javascript chunk filename */
|
|
143
|
+
/******/ (() => {
|
|
144
|
+
/******/ // This function allow to reference async chunks
|
|
145
|
+
/******/ __webpack_require__.u = (chunkId) => {
|
|
146
|
+
/******/ // return url for filenames based on template
|
|
147
|
+
/******/ return "" + chunkId + ".js";
|
|
148
|
+
/******/ };
|
|
149
|
+
/******/ })();
|
|
150
|
+
/******/
|
|
151
|
+
/******/ /* webpack/runtime/global */
|
|
152
|
+
/******/ (() => {
|
|
153
|
+
/******/ __webpack_require__.g = (function() {
|
|
154
|
+
/******/ if (typeof globalThis === 'object') return globalThis;
|
|
155
|
+
/******/ try {
|
|
156
|
+
/******/ return this || new Function('return this')();
|
|
157
|
+
/******/ } catch (e) {
|
|
158
|
+
/******/ if (typeof window === 'object') return window;
|
|
159
|
+
/******/ }
|
|
160
|
+
/******/ })();
|
|
161
|
+
/******/ })();
|
|
162
|
+
/******/
|
|
202
163
|
/******/ /* webpack/runtime/hasOwnProperty shorthand */
|
|
203
164
|
/******/ (() => {
|
|
204
165
|
/******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
|
|
205
166
|
/******/ })();
|
|
206
167
|
/******/
|
|
168
|
+
/******/ /* webpack/runtime/load script */
|
|
169
|
+
/******/ (() => {
|
|
170
|
+
/******/ var inProgress = {};
|
|
171
|
+
/******/ var dataWebpackPrefix = "@tsparticles/interaction-particles-links:";
|
|
172
|
+
/******/ // loadScript function to load a script via script tag
|
|
173
|
+
/******/ __webpack_require__.l = (url, done, key, chunkId) => {
|
|
174
|
+
/******/ if(inProgress[url]) { inProgress[url].push(done); return; }
|
|
175
|
+
/******/ var script, needAttach;
|
|
176
|
+
/******/ if(key !== undefined) {
|
|
177
|
+
/******/ var scripts = document.getElementsByTagName("script");
|
|
178
|
+
/******/ for(var i = 0; i < scripts.length; i++) {
|
|
179
|
+
/******/ var s = scripts[i];
|
|
180
|
+
/******/ if(s.getAttribute("src") == url || s.getAttribute("data-webpack") == dataWebpackPrefix + key) { script = s; break; }
|
|
181
|
+
/******/ }
|
|
182
|
+
/******/ }
|
|
183
|
+
/******/ if(!script) {
|
|
184
|
+
/******/ needAttach = true;
|
|
185
|
+
/******/ script = document.createElement('script');
|
|
186
|
+
/******/
|
|
187
|
+
/******/ script.charset = 'utf-8';
|
|
188
|
+
/******/ if (__webpack_require__.nc) {
|
|
189
|
+
/******/ script.setAttribute("nonce", __webpack_require__.nc);
|
|
190
|
+
/******/ }
|
|
191
|
+
/******/ script.setAttribute("data-webpack", dataWebpackPrefix + key);
|
|
192
|
+
/******/
|
|
193
|
+
/******/ script.src = url;
|
|
194
|
+
/******/ }
|
|
195
|
+
/******/ inProgress[url] = [done];
|
|
196
|
+
/******/ var onScriptComplete = (prev, event) => {
|
|
197
|
+
/******/ // avoid mem leaks in IE.
|
|
198
|
+
/******/ script.onerror = script.onload = null;
|
|
199
|
+
/******/ clearTimeout(timeout);
|
|
200
|
+
/******/ var doneFns = inProgress[url];
|
|
201
|
+
/******/ delete inProgress[url];
|
|
202
|
+
/******/ script.parentNode && script.parentNode.removeChild(script);
|
|
203
|
+
/******/ doneFns && doneFns.forEach((fn) => (fn(event)));
|
|
204
|
+
/******/ if(prev) return prev(event);
|
|
205
|
+
/******/ }
|
|
206
|
+
/******/ var timeout = setTimeout(onScriptComplete.bind(null, undefined, { type: 'timeout', target: script }), 120000);
|
|
207
|
+
/******/ script.onerror = onScriptComplete.bind(null, script.onerror);
|
|
208
|
+
/******/ script.onload = onScriptComplete.bind(null, script.onload);
|
|
209
|
+
/******/ needAttach && document.head.appendChild(script);
|
|
210
|
+
/******/ };
|
|
211
|
+
/******/ })();
|
|
212
|
+
/******/
|
|
207
213
|
/******/ /* webpack/runtime/make namespace object */
|
|
208
214
|
/******/ (() => {
|
|
209
215
|
/******/ // define __esModule on exports
|
|
@@ -215,6 +221,119 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_engine__;
|
|
|
215
221
|
/******/ };
|
|
216
222
|
/******/ })();
|
|
217
223
|
/******/
|
|
224
|
+
/******/ /* webpack/runtime/publicPath */
|
|
225
|
+
/******/ (() => {
|
|
226
|
+
/******/ var scriptUrl;
|
|
227
|
+
/******/ if (__webpack_require__.g.importScripts) scriptUrl = __webpack_require__.g.location + "";
|
|
228
|
+
/******/ var document = __webpack_require__.g.document;
|
|
229
|
+
/******/ if (!scriptUrl && document) {
|
|
230
|
+
/******/ if (document.currentScript && document.currentScript.tagName.toUpperCase() === 'SCRIPT')
|
|
231
|
+
/******/ scriptUrl = document.currentScript.src;
|
|
232
|
+
/******/ if (!scriptUrl) {
|
|
233
|
+
/******/ var scripts = document.getElementsByTagName("script");
|
|
234
|
+
/******/ if(scripts.length) {
|
|
235
|
+
/******/ var i = scripts.length - 1;
|
|
236
|
+
/******/ while (i > -1 && (!scriptUrl || !/^http(s?):/.test(scriptUrl))) scriptUrl = scripts[i--].src;
|
|
237
|
+
/******/ }
|
|
238
|
+
/******/ }
|
|
239
|
+
/******/ }
|
|
240
|
+
/******/ // When supporting browsers where an automatic publicPath is not supported you must specify an output.publicPath manually via configuration
|
|
241
|
+
/******/ // or pass an empty string ("") and set the __webpack_public_path__ variable from your code to use your own logic.
|
|
242
|
+
/******/ if (!scriptUrl) throw new Error("Automatic publicPath is not supported in this browser");
|
|
243
|
+
/******/ scriptUrl = scriptUrl.replace(/^blob:/, "").replace(/#.*$/, "").replace(/\?.*$/, "").replace(/\/[^\/]+$/, "/");
|
|
244
|
+
/******/ __webpack_require__.p = scriptUrl;
|
|
245
|
+
/******/ })();
|
|
246
|
+
/******/
|
|
247
|
+
/******/ /* webpack/runtime/jsonp chunk loading */
|
|
248
|
+
/******/ (() => {
|
|
249
|
+
/******/ // no baseURI
|
|
250
|
+
/******/
|
|
251
|
+
/******/ // object to store loaded and loading chunks
|
|
252
|
+
/******/ // undefined = chunk not loaded, null = chunk preloaded/prefetched
|
|
253
|
+
/******/ // [resolve, reject, Promise] = chunk loading, 0 = chunk loaded
|
|
254
|
+
/******/ var installedChunks = {
|
|
255
|
+
/******/ "tsparticles.interaction.particles.links": 0
|
|
256
|
+
/******/ };
|
|
257
|
+
/******/
|
|
258
|
+
/******/ __webpack_require__.f.j = (chunkId, promises) => {
|
|
259
|
+
/******/ // JSONP chunk loading for javascript
|
|
260
|
+
/******/ var installedChunkData = __webpack_require__.o(installedChunks, chunkId) ? installedChunks[chunkId] : undefined;
|
|
261
|
+
/******/ if(installedChunkData !== 0) { // 0 means "already installed".
|
|
262
|
+
/******/
|
|
263
|
+
/******/ // a Promise means "currently loading".
|
|
264
|
+
/******/ if(installedChunkData) {
|
|
265
|
+
/******/ promises.push(installedChunkData[2]);
|
|
266
|
+
/******/ } else {
|
|
267
|
+
/******/ if(true) { // all chunks have JS
|
|
268
|
+
/******/ // setup Promise in chunk cache
|
|
269
|
+
/******/ var promise = new Promise((resolve, reject) => (installedChunkData = installedChunks[chunkId] = [resolve, reject]));
|
|
270
|
+
/******/ promises.push(installedChunkData[2] = promise);
|
|
271
|
+
/******/
|
|
272
|
+
/******/ // start chunk loading
|
|
273
|
+
/******/ var url = __webpack_require__.p + __webpack_require__.u(chunkId);
|
|
274
|
+
/******/ // create error before stack unwound to get useful stacktrace later
|
|
275
|
+
/******/ var error = new Error();
|
|
276
|
+
/******/ var loadingEnded = (event) => {
|
|
277
|
+
/******/ if(__webpack_require__.o(installedChunks, chunkId)) {
|
|
278
|
+
/******/ installedChunkData = installedChunks[chunkId];
|
|
279
|
+
/******/ if(installedChunkData !== 0) installedChunks[chunkId] = undefined;
|
|
280
|
+
/******/ if(installedChunkData) {
|
|
281
|
+
/******/ var errorType = event && (event.type === 'load' ? 'missing' : event.type);
|
|
282
|
+
/******/ var realSrc = event && event.target && event.target.src;
|
|
283
|
+
/******/ error.message = 'Loading chunk ' + chunkId + ' failed.\n(' + errorType + ': ' + realSrc + ')';
|
|
284
|
+
/******/ error.name = 'ChunkLoadError';
|
|
285
|
+
/******/ error.type = errorType;
|
|
286
|
+
/******/ error.request = realSrc;
|
|
287
|
+
/******/ installedChunkData[1](error);
|
|
288
|
+
/******/ }
|
|
289
|
+
/******/ }
|
|
290
|
+
/******/ };
|
|
291
|
+
/******/ __webpack_require__.l(url, loadingEnded, "chunk-" + chunkId, chunkId);
|
|
292
|
+
/******/ }
|
|
293
|
+
/******/ }
|
|
294
|
+
/******/ }
|
|
295
|
+
/******/ };
|
|
296
|
+
/******/
|
|
297
|
+
/******/ // no prefetching
|
|
298
|
+
/******/
|
|
299
|
+
/******/ // no preloaded
|
|
300
|
+
/******/
|
|
301
|
+
/******/ // no HMR
|
|
302
|
+
/******/
|
|
303
|
+
/******/ // no HMR manifest
|
|
304
|
+
/******/
|
|
305
|
+
/******/ // no on chunks loaded
|
|
306
|
+
/******/
|
|
307
|
+
/******/ // install a JSONP callback for chunk loading
|
|
308
|
+
/******/ var webpackJsonpCallback = (parentChunkLoadingFunction, data) => {
|
|
309
|
+
/******/ var [chunkIds, moreModules, runtime] = data;
|
|
310
|
+
/******/ // add "moreModules" to the modules object,
|
|
311
|
+
/******/ // then flag all "chunkIds" as loaded and fire callback
|
|
312
|
+
/******/ var moduleId, chunkId, i = 0;
|
|
313
|
+
/******/ if(chunkIds.some((id) => (installedChunks[id] !== 0))) {
|
|
314
|
+
/******/ for(moduleId in moreModules) {
|
|
315
|
+
/******/ if(__webpack_require__.o(moreModules, moduleId)) {
|
|
316
|
+
/******/ __webpack_require__.m[moduleId] = moreModules[moduleId];
|
|
317
|
+
/******/ }
|
|
318
|
+
/******/ }
|
|
319
|
+
/******/ if(runtime) var result = runtime(__webpack_require__);
|
|
320
|
+
/******/ }
|
|
321
|
+
/******/ if(parentChunkLoadingFunction) parentChunkLoadingFunction(data);
|
|
322
|
+
/******/ for(;i < chunkIds.length; i++) {
|
|
323
|
+
/******/ chunkId = chunkIds[i];
|
|
324
|
+
/******/ if(__webpack_require__.o(installedChunks, chunkId) && installedChunks[chunkId]) {
|
|
325
|
+
/******/ installedChunks[chunkId][0]();
|
|
326
|
+
/******/ }
|
|
327
|
+
/******/ installedChunks[chunkId] = 0;
|
|
328
|
+
/******/ }
|
|
329
|
+
/******/
|
|
330
|
+
/******/ }
|
|
331
|
+
/******/
|
|
332
|
+
/******/ var chunkLoadingGlobal = this["webpackChunk_tsparticles_interaction_particles_links"] = this["webpackChunk_tsparticles_interaction_particles_links"] || [];
|
|
333
|
+
/******/ chunkLoadingGlobal.forEach(webpackJsonpCallback.bind(null, 0));
|
|
334
|
+
/******/ chunkLoadingGlobal.push = webpackJsonpCallback.bind(null, chunkLoadingGlobal.push.bind(chunkLoadingGlobal));
|
|
335
|
+
/******/ })();
|
|
336
|
+
/******/
|
|
218
337
|
/************************************************************************/
|
|
219
338
|
/******/
|
|
220
339
|
/******/ // startup
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see tsparticles.interaction.particles.links.min.js.LICENSE.txt */
|
|
2
|
-
!function(
|
|
2
|
+
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@tsparticles/engine"));else if("function"==typeof define&&define.amd)define(["@tsparticles/engine"],t);else{var i="object"==typeof exports?t(require("@tsparticles/engine")):t(e.window);for(var r in i)("object"==typeof exports?exports:e)[r]=i[r]}}(this,(e=>(()=>{var t,i,r={303(t){t.exports=e},509(e,t,i){i.d(t,{q:()=>s});var r=i(303),o=i(525),n=i(853);class s{constructor(){this.blink=!1,this.color=new r.OptionsColor,this.color.value="#fff",this.consent=!1,this.distance=100,this.enable=!1,this.frequency=1,this.opacity=1,this.shadow=new o.s,this.triangles=new n.G,this.width=1,this.warp=!1}load(e){(0,r.isNull)(e)||(void 0!==e.id&&(this.id=e.id),void 0!==e.blink&&(this.blink=e.blink),this.color=r.OptionsColor.create(this.color,e.color),void 0!==e.consent&&(this.consent=e.consent),void 0!==e.distance&&(this.distance=e.distance),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.frequency&&(this.frequency=e.frequency),void 0!==e.opacity&&(this.opacity=e.opacity),this.shadow.load(e.shadow),this.triangles.load(e.triangles),void 0!==e.width&&(this.width=e.width),void 0!==e.warp&&(this.warp=e.warp))}}},525(e,t,i){i.d(t,{s:()=>o});var r=i(303);class o{constructor(){this.blur=5,this.color=new r.OptionsColor,this.color.value="#000",this.enable=!1}load(e){(0,r.isNull)(e)||(void 0!==e.blur&&(this.blur=e.blur),this.color=r.OptionsColor.create(this.color,e.color),void 0!==e.enable&&(this.enable=e.enable))}}},853(e,t,i){i.d(t,{G:()=>o});var r=i(303);class o{constructor(){this.enable=!1,this.frequency=1}load(e){(0,r.isNull)(e)||(void 0!==e.color&&(this.color=r.OptionsColor.create(this.color,e.color)),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.frequency&&(this.frequency=e.frequency),void 0!==e.opacity&&(this.opacity=e.opacity))}}}},o={};function n(e){var t=o[e];if(void 0!==t)return t.exports;var i=o[e]={exports:{}};return r[e](i,i.exports,n),i.exports}n.m=r,n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.f={},n.e=e=>Promise.all(Object.keys(n.f).reduce(((t,i)=>(n.f[i](e,t),t)),[])),n.u=e=>e+".min.js",n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),t={},i="@tsparticles/interaction-particles-links:",n.l=(e,r,o,s)=>{if(t[e])t[e].push(r);else{var a,l;if(void 0!==o)for(var c=document.getElementsByTagName("script"),d=0;d<c.length;d++){var p=c[d];if(p.getAttribute("src")==e||p.getAttribute("data-webpack")==i+o){a=p;break}}a||(l=!0,(a=document.createElement("script")).charset="utf-8",n.nc&&a.setAttribute("nonce",n.nc),a.setAttribute("data-webpack",i+o),a.src=e),t[e]=[r];var h=(i,r)=>{a.onerror=a.onload=null,clearTimeout(u);var o=t[e];if(delete t[e],a.parentNode&&a.parentNode.removeChild(a),o&&o.forEach((e=>e(r))),i)return i(r)},u=setTimeout(h.bind(null,void 0,{type:"timeout",target:a}),12e4);a.onerror=h.bind(null,a.onerror),a.onload=h.bind(null,a.onload),l&&document.head.appendChild(a)}},n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},(()=>{var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&"SCRIPT"===t.currentScript.tagName.toUpperCase()&&(e=t.currentScript.src),!e)){var i=t.getElementsByTagName("script");if(i.length)for(var r=i.length-1;r>-1&&(!e||!/^http(s?):/.test(e));)e=i[r--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e})(),(()=>{var e={203:0};n.f.j=(t,i)=>{var r=n.o(e,t)?e[t]:void 0;if(0!==r)if(r)i.push(r[2]);else{var o=new Promise(((i,o)=>r=e[t]=[i,o]));i.push(r[2]=o);var s=n.p+n.u(t),a=new Error;n.l(s,(i=>{if(n.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var o=i&&("load"===i.type?"missing":i.type),s=i&&i.target&&i.target.src;a.message="Loading chunk "+t+" failed.\n("+o+": "+s+")",a.name="ChunkLoadError",a.type=o,a.request=s,r[1](a)}}),"chunk-"+t,t)}};var t=(t,i)=>{var r,o,[s,a,l]=i,c=0;if(s.some((t=>0!==e[t]))){for(r in a)n.o(a,r)&&(n.m[r]=a[r]);if(l)l(n)}for(t&&t(i);c<s.length;c++)o=s[c],n.o(e,o)&&e[o]&&e[o][0](),e[o]=0},i=this.webpackChunk_tsparticles_interaction_particles_links=this.webpackChunk_tsparticles_interaction_particles_links||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var s={};n.r(s),n.d(s,{Links:()=>a.q,LinksShadow:()=>l.s,LinksTriangle:()=>c.G,loadParticlesLinksInteraction:()=>d});var a=n(509),l=n(525),c=n(853);function d(e){e.checkVersion("4.0.0-alpha.0"),e.register((async e=>{const{loadLinksInteraction:t}=await n.e(418).then(n.bind(n,418)),{loadLinksPlugin:i}=await n.e(711).then(n.bind(n,711));t(e),i(e)}))}return s})()));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! tsParticles Links Particles Interaction
|
|
1
|
+
/*! tsParticles Links Particles Interaction v4.0.0-alpha.0 by Matteo Bruni */
|
package/types/LinkInstance.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export declare class LinkInstance implements IContainerPlugin {
|
|
|
5
5
|
private readonly _engine;
|
|
6
6
|
private readonly _freqs;
|
|
7
7
|
constructor(container: LinkContainer, engine: Engine);
|
|
8
|
-
drawParticle(
|
|
8
|
+
drawParticle(_context: CanvasRenderingContext2D, particle: LinkParticle): void;
|
|
9
9
|
init(): Promise<void>;
|
|
10
10
|
particleCreated(particle: LinkParticle): void;
|
|
11
11
|
particleDestroyed(particle: LinkParticle): void;
|
package/types/Linker.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { type Engine, ParticlesInteractorBase, type RecursivePartial } from "@tsparticles/engine";
|
|
2
2
|
import type { IParticlesLinkOptions, LinkContainer, LinkParticle, ParticlesLinkOptions } from "./Types.js";
|
|
3
|
-
export declare class Linker extends ParticlesInteractorBase {
|
|
3
|
+
export declare class Linker extends ParticlesInteractorBase<LinkContainer, LinkParticle> {
|
|
4
4
|
private readonly _engine;
|
|
5
|
-
private readonly _linkContainer;
|
|
6
5
|
constructor(container: LinkContainer, engine: Engine);
|
|
7
6
|
clear(): void;
|
|
8
7
|
init(): void;
|
package/types/Types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type {
|
|
1
|
+
import type { Container, Engine, ICoordinates, IDimension, IParticlesOptions, IRgb, Particle, ParticlesOptions } from "@tsparticles/engine";
|
|
2
2
|
import type { ILink } from "./Interfaces.js";
|
|
3
3
|
import type { ILinks } from "./Options/Interfaces/ILinks.js";
|
|
4
4
|
import type { Links } from "./Options/Classes/Links.js";
|
|
@@ -17,22 +17,22 @@ export type LinkParticle = Particle & {
|
|
|
17
17
|
};
|
|
18
18
|
};
|
|
19
19
|
export interface LinkLineDrawParams {
|
|
20
|
-
backgroundMask: BackgroundMask;
|
|
21
20
|
begin: ICoordinates;
|
|
22
21
|
canvasSize: IDimension;
|
|
23
22
|
colorLine: IRgb;
|
|
24
23
|
context: CanvasRenderingContext2D;
|
|
25
24
|
end: ICoordinates;
|
|
26
25
|
engine: Engine;
|
|
26
|
+
hdr: boolean;
|
|
27
27
|
links: Links;
|
|
28
28
|
maxDistance: number;
|
|
29
29
|
opacity: number;
|
|
30
30
|
width: number;
|
|
31
31
|
}
|
|
32
32
|
export interface LinkTriangleDrawParams {
|
|
33
|
-
backgroundMask: BackgroundMask;
|
|
34
33
|
colorTriangle: IRgb;
|
|
35
34
|
context: CanvasRenderingContext2D;
|
|
35
|
+
hdr: boolean;
|
|
36
36
|
opacityTriangle: number;
|
|
37
37
|
pos1: ICoordinates;
|
|
38
38
|
pos2: ICoordinates;
|
package/types/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { type Engine } from "@tsparticles/engine";
|
|
2
|
-
export declare function loadParticlesLinksInteraction(engine: Engine
|
|
2
|
+
export declare function loadParticlesLinksInteraction(engine: Engine): void;
|
|
3
3
|
export * from "./Options/Classes/Links.js";
|
|
4
4
|
export * from "./Options/Classes/LinksShadow.js";
|
|
5
5
|
export * from "./Options/Classes/LinksTriangle.js";
|
|
6
|
-
export * from "./Options/Interfaces/ILinks.js";
|
|
7
|
-
export * from "./Options/Interfaces/ILinksShadow.js";
|
|
8
|
-
export * from "./Options/Interfaces/ILinksTriangle.js";
|
|
6
|
+
export type * from "./Options/Interfaces/ILinks.js";
|
|
7
|
+
export type * from "./Options/Interfaces/ILinksShadow.js";
|
|
8
|
+
export type * from "./Options/Interfaces/ILinksTriangle.js";
|
package/types/interaction.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { Engine } from "@tsparticles/engine";
|
|
2
|
-
export declare function loadLinksInteraction(engine: Engine
|
|
2
|
+
export declare function loadLinksInteraction(engine: Engine): void;
|
package/types/plugin.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import type { Engine } from "@tsparticles/engine";
|
|
2
|
-
export declare function loadLinksPlugin(engine: Engine
|
|
2
|
+
export declare function loadLinksPlugin(engine: Engine): void;
|