@tsparticles/path-curl-noise 4.0.0-beta.1 → 4.0.0-beta.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/653.min.js +1 -1
- package/browser/CurlNoiseGenerator.js +1 -0
- package/browser/index.js +3 -1
- package/cjs/CurlNoiseGenerator.js +1 -0
- package/cjs/index.js +3 -1
- package/dist_browser_CurlNoiseGenerator_js.js +2 -2
- package/esm/CurlNoiseGenerator.js +1 -0
- package/esm/index.js +3 -1
- package/package.json +3 -4
- package/report.html +1 -1
- package/tsparticles.path.curl.noise.js +6 -6
- package/tsparticles.path.curl.noise.min.js +2 -2
- package/umd/CurlNoiseGenerator.js +0 -53
- package/umd/ICurlOptions.js +0 -12
- package/umd/index.js +0 -60
package/653.min.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(this.webpackChunk_tsparticles_path_curl_noise=this.webpackChunk_tsparticles_path_curl_noise||[]).push([[653],{653(e,s,t){t.d(s,{CurlNoiseGenerator:()=>n});var i=t(303)
|
|
1
|
+
"use strict";(this.webpackChunk_tsparticles_path_curl_noise=this.webpackChunk_tsparticles_path_curl_noise||[]).push([[653],{653(e,s,t){t.d(s,{CurlNoiseGenerator:()=>n});var i=t(303);t(400);var o=t(226);let p={speed:.2,step:250};class n{options;_container;_res;_simplex;constructor(e){this._container=e,this._res=i.Vector.origin;const s=new o.SimplexNoise;this._simplex=s.noise2d,this.options=(0,i.deepExtend)({},p)}generate(e){let s=e.getPosition(),{speed:t,step:o}=this.options,p=s.x/o,n=s.y/o,r=(this._simplex.noise(p,n+.001)-this._simplex.noise(p,n-.001))/(.001*i.double),h=(this._simplex.noise(p+.001,n)-this._simplex.noise(p-.001,n))/(.001*i.double);return e.velocity.x=0,e.velocity.y=0,this._res.x=t*r,this._res.y=-(t*h),this._res}init(){let e=this._container,s=e.actualOptions.particles.move.path.options;this.options.seed=s.seed,this.options.speed=(s.speed??p.speed)*e.retina.pixelRatio,this.options.step=s.step??p.step,this._simplex.seed(this.options.seed??(0,i.getRandom)())}reset(){}update(){}}}}]);
|
package/browser/index.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import {} from "@tsparticles/engine";
|
|
2
|
+
import {} from "@tsparticles/plugin-move";
|
|
1
3
|
export const curlNoisePathName = "curlNoise";
|
|
2
4
|
export async function loadCurlNoisePath(engine) {
|
|
3
|
-
engine.checkVersion("4.0.0-beta.
|
|
5
|
+
engine.checkVersion("4.0.0-beta.2");
|
|
4
6
|
await engine.pluginManager.register(async (e) => {
|
|
5
7
|
const { ensureBaseMoverLoaded } = await import("@tsparticles/plugin-move");
|
|
6
8
|
ensureBaseMoverLoaded(e);
|
package/cjs/index.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import {} from "@tsparticles/engine";
|
|
2
|
+
import {} from "@tsparticles/plugin-move";
|
|
1
3
|
export const curlNoisePathName = "curlNoise";
|
|
2
4
|
export async function loadCurlNoisePath(engine) {
|
|
3
|
-
engine.checkVersion("4.0.0-beta.
|
|
5
|
+
engine.checkVersion("4.0.0-beta.2");
|
|
4
6
|
await engine.pluginManager.register(async (e) => {
|
|
5
7
|
const { ensureBaseMoverLoaded } = await import("@tsparticles/plugin-move");
|
|
6
8
|
ensureBaseMoverLoaded(e);
|
|
@@ -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
|
-
* v4.0.0-beta.
|
|
7
|
+
* v4.0.0-beta.2
|
|
8
8
|
*/
|
|
9
9
|
"use strict";
|
|
10
10
|
/*
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
\********************************************/
|
|
24
24
|
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
25
25
|
|
|
26
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ CurlNoiseGenerator: () => (/* binding */ CurlNoiseGenerator)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var
|
|
26
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ CurlNoiseGenerator: () => (/* binding */ CurlNoiseGenerator)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_plugin_move__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @tsparticles/plugin-move */ \"@tsparticles/plugin-move\");\n/* harmony import */ var _tsparticles_simplex_noise__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! @tsparticles/simplex-noise */ \"@tsparticles/simplex-noise\");\n\n\n\nconst defaultOptions = {\n speed: 0.2,\n step: 250\n};\nclass CurlNoiseGenerator {\n options;\n _container;\n _res;\n _simplex;\n constructor(container){\n this._container = container;\n this._res = _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.Vector.origin;\n const simplex = new _tsparticles_simplex_noise__WEBPACK_IMPORTED_MODULE_2__.SimplexNoise();\n this._simplex = simplex.noise2d;\n this.options = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.deepExtend)({}, defaultOptions);\n }\n generate(particle) {\n const pos = particle.getPosition(), { speed, step } = this.options, x = pos.x / step, y = pos.y / step, eps = 0.001, n1a = this._simplex.noise(x, y + eps), n2a = this._simplex.noise(x, y - eps), a = (n1a - n2a) / (_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.double * eps), n1b = this._simplex.noise(x + eps, y), n2b = this._simplex.noise(x - eps, y), b = (n1b - n2b) / (_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.double * eps);\n particle.velocity.x = 0;\n particle.velocity.y = 0;\n this._res.x = speed * a;\n this._res.y = speed * -b;\n return this._res;\n }\n init() {\n const container = this._container, sourceOptions = container.actualOptions.particles.move.path.options;\n this.options.seed = sourceOptions[\"seed\"];\n this.options.speed = (sourceOptions[\"speed\"] ?? defaultOptions.speed) * container.retina.pixelRatio;\n this.options.step = sourceOptions[\"step\"] ?? defaultOptions.step;\n this._simplex.seed(this.options.seed ?? (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRandom)());\n }\n reset() {}\n update() {}\n}\n\n\n//# sourceURL=webpack://@tsparticles/path-curl-noise/./dist/browser/CurlNoiseGenerator.js?\n}");
|
|
27
27
|
|
|
28
28
|
/***/ }
|
|
29
29
|
|
package/esm/index.js
CHANGED
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
import {} from "@tsparticles/engine";
|
|
2
|
+
import {} from "@tsparticles/plugin-move";
|
|
1
3
|
export const curlNoisePathName = "curlNoise";
|
|
2
4
|
export async function loadCurlNoisePath(engine) {
|
|
3
|
-
engine.checkVersion("4.0.0-beta.
|
|
5
|
+
engine.checkVersion("4.0.0-beta.2");
|
|
4
6
|
await engine.pluginManager.register(async (e) => {
|
|
5
7
|
const { ensureBaseMoverLoaded } = await import("@tsparticles/plugin-move");
|
|
6
8
|
ensureBaseMoverLoaded(e);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tsparticles/path-curl-noise",
|
|
3
|
-
"version": "4.0.0-beta.
|
|
3
|
+
"version": "4.0.0-beta.2",
|
|
4
4
|
"description": "tsParticles curl noise path",
|
|
5
5
|
"homepage": "https://particles.js.org",
|
|
6
6
|
"repository": {
|
|
@@ -98,12 +98,11 @@
|
|
|
98
98
|
"browser": "./browser/index.js",
|
|
99
99
|
"import": "./esm/index.js",
|
|
100
100
|
"require": "./cjs/index.js",
|
|
101
|
-
"
|
|
102
|
-
"default": "./cjs/index.js"
|
|
101
|
+
"default": "./esm/index.js"
|
|
103
102
|
},
|
|
104
103
|
"./package.json": "./package.json"
|
|
105
104
|
},
|
|
106
|
-
"
|
|
105
|
+
"peerDependencies": {
|
|
107
106
|
"@tsparticles/engine": "4.0.0-beta.1",
|
|
108
107
|
"@tsparticles/plugin-move": "4.0.0-beta.1",
|
|
109
108
|
"@tsparticles/simplex-noise": "4.0.0-beta.1"
|
package/report.html
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
<head>
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
|
-
<title>@tsparticles/path-curl-noise [
|
|
6
|
+
<title>@tsparticles/path-curl-noise [2 Apr 2026 at 07:40]</title>
|
|
7
7
|
<link
|
|
8
8
|
rel="shortcut icon"
|
|
9
9
|
href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAMAAACdt4HsAAABrVBMVEUAAAD///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////+O1foceMD///+J0/qK1Pr7/v8Xdr/9///W8P4UdL7L7P0Scr2r4Pyj3vwad8D5/f/2/f+55f3E6f34+/2H0/ojfMKpzOd0rNgQcb3F3O/j9f7c8v6g3Pz0/P/w+v/q+P7n9v6T1/uQ1vuE0vqLut/y+v+Z2fvt+f+15Pzv9fuc2/vR7v2V2Pvd6/bg9P7I6/285/2y4/yp3/zp8vk8i8kqgMT7/P31+fyv4vxGkcz6/P6/6P3j7vfS5PNnpNUxhcbO7f7F6v3O4vHK3/DA2u631Ouy0eqXweKJud5wqthfoNMMbLvY8f73+v2dxeR8sNtTmdDx9/zX6PSjyeaCtd1YnNGX2PuQveCGt95Nls42h8dLlM3F4vBtAAAAM3RSTlMAAyOx0/sKBvik8opWGBMOAe3l1snDm2E9LSb06eHcu5JpHbarfHZCN9CBb08zzkdNS0kYaptYAAAFV0lEQVRYw92X51/aYBDHHS2O2qqttVbrqNq9m+TJIAYIShBkWwqIiCgoWvfeq7Z2/s29hyQNyUcR7LveGwVyXy6XH8/9rqxglLfUPLxVduUor3h0rfp2TYvpivk37929TkG037hffoX0+peVtZQc1589rigVUdXS/ABSAyEmGIO/1XfvldSK8vs3OqB6u3m0nxmIrvgB0dj7rr7Y9IbuF68hnfFaiHA/sxqm0wciIG43P60qKv9WXWc1RXGh/mFESFABTSBi0sNAKzqet17eCtOb3kZIDwxEEU0oAIJGYxNBDhBND29e0rtXXbcpuPmED9IhEAAQ/AXEaF8EPmnrrKsv0LvWR3fg5sWDNAFZOgAgaKvZDogHNU9MFwnnYROkc56RD5CjAbQX9Ow4g7upCsvYu55aSI/Nj0H1akgKQEUM94dwK65hYRmFU9MIcH/fqJYOZYcnuJSU/waKDgTOEVaVKhwrTRP5XzgSpAITYzom7UvkhFX5VutmxeNnWDjjswTKTyfgluNDGbUpWissXhF3s7mlSml+czWkg3D0l1nNjGNjz3myOQOa1KM/jOS6ebdbAVTCi4gljHSFrviza7tOgRWcS0MOUX9zdNgag5w7rRqA44Lzw0hr1WqES36dFliSJFlh2rXIae3FFcDDgKdxrUIDePr8jGcSClV1u7A9xeN0ModY/pHMxmR1EzRh8TJiwqsHmKW0l4FCEZI+jHio+JdPPE9qwQtTRxku2D8sIeRL2LnxWSllANCQGOIiqVHAz2ye2JR0DcH+HoxDkaADLjgxjKQ+AwCX/g0+DNgdG0ukYCONAe+dbc2IAc6fwt1ARoDSezNHxV2Cmzwv3O6lDMV55edBGwGK9n1+x2F8EDfAGCxug8MhpsMEcTEAWf3rx2vZhe/LAmtIn/6apE6PN0ULKgywD9mmdxbmFl3OvD5AS5fW5zLbv/YHmcsBTjf/afDz3MaZTVCfAP9z6/Bw6ycv8EUBWJIn9zYcoAWWlW9+OzO3vkTy8H+RANLmdrpOuYWdZYEXpo+TlCJrW5EARb7fF+bWdqf3hhyZI1nWJQHgznErZhbjoEsWqi8dQNoE294aldzFurwSABL2XXMf9+H1VQGke9exw5P/AnA5Pv5ngMul7LOvO922iwACu8WkCwLCafvM4CeWPxfA8lNHcWZSoi8EwMAIciKX2Z4SWCMAa3snCZ/G4EA8D6CMLNFsGQhkkz/gQNEBbPCbWsxGUpYVu3z8IyNAknwJkfPMEhLyrdi5RTyUVACkw4GSFRNWJNEW+fgPGwHD8/JxnRuLabN4CGNRkAE23na2+VmEAUmrYymSGjMAYqH84YUIyzgzs3XC7gNgH36Vcc4zKY9o9fgPBXUAiHHwVboBHGLiX6Zcjp1f2wu4tvzZKo0ecPnDtQYDQvJXaBeNzce45Fp28ZQLrEZVuFqgBwOalArKXnW1UzlnSusQKJqKYNuz4tOnI6sZG4zanpemv+7ySU2jbA9h6uhcgpfy6G2PahirDZ6zvq6zDduMVFTKvzw8wgyEdelwY9in3XkEPs3osJuwRQ4qTkfzifndg9Gfc4pdsu82+tTnHZTBa2EAMrqr2t43pguc8tNm7JQVQ2S0ukj2d22dhXYP0/veWtwKrCkNoNimAN5+Xr/oLrxswKbVJjteWrX7eR63o4j9q0GxnaBdWgGA5VStpanIjQmEhV0/nVt5VOFUvix6awJhPcAaTEShgrG+iGyvb5a0Ndb1YGHFPEwoqAinoaykaID1o1pdPNu7XsnCKQ3R+hwWIIhGvORcJUBYXe3Xa3vq/mF/N9V13ugufMkfXn+KHsRD0B8AAAAASUVORK5CYII="
|
|
@@ -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
|
-
* v4.0.0-beta.
|
|
7
|
+
* v4.0.0-beta.2
|
|
8
8
|
*/
|
|
9
9
|
/*
|
|
10
10
|
* ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
|
|
@@ -16,14 +16,14 @@
|
|
|
16
16
|
*/
|
|
17
17
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
18
18
|
if(typeof exports === 'object' && typeof module === 'object')
|
|
19
|
-
module.exports = factory(require("@tsparticles/
|
|
19
|
+
module.exports = factory(require("@tsparticles/engine"), require("@tsparticles/plugin-move"), require("@tsparticles/simplex-noise"));
|
|
20
20
|
else if(typeof define === 'function' && define.amd)
|
|
21
|
-
define(["@tsparticles/
|
|
21
|
+
define(["@tsparticles/engine", "@tsparticles/plugin-move", "@tsparticles/simplex-noise"], factory);
|
|
22
22
|
else {
|
|
23
|
-
var a = typeof exports === 'object' ? factory(require("@tsparticles/
|
|
23
|
+
var a = typeof exports === 'object' ? factory(require("@tsparticles/engine"), require("@tsparticles/plugin-move"), require("@tsparticles/simplex-noise")) : factory(root["window"], root["window"], root["window"]);
|
|
24
24
|
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
|
25
25
|
}
|
|
26
|
-
})(this, (
|
|
26
|
+
})(this, (__WEBPACK_EXTERNAL_MODULE__tsparticles_engine__, __WEBPACK_EXTERNAL_MODULE__tsparticles_plugin_move__, __WEBPACK_EXTERNAL_MODULE__tsparticles_simplex_noise__) => {
|
|
27
27
|
return /******/ (() => { // webpackBootstrap
|
|
28
28
|
/******/ "use strict";
|
|
29
29
|
/******/ var __webpack_modules__ = ({
|
|
@@ -64,7 +64,7 @@ module.exports = __WEBPACK_EXTERNAL_MODULE__tsparticles_simplex_noise__;
|
|
|
64
64
|
\*******************************/
|
|
65
65
|
(__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
|
|
66
66
|
|
|
67
|
-
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ curlNoisePathName: () => (/* binding */ curlNoisePathName),\n/* harmony export */ loadCurlNoisePath: () => (/* binding */ loadCurlNoisePath)\n/* harmony export */ });\nconst curlNoisePathName = \"curlNoise\";\nasync function loadCurlNoisePath(engine) {\n engine.checkVersion(\"4.0.0-beta.
|
|
67
|
+
eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ curlNoisePathName: () => (/* binding */ curlNoisePathName),\n/* harmony export */ loadCurlNoisePath: () => (/* binding */ loadCurlNoisePath)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"@tsparticles/engine\");\n/* harmony import */ var _tsparticles_plugin_move__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! @tsparticles/plugin-move */ \"@tsparticles/plugin-move\");\n\n\nconst curlNoisePathName = \"curlNoise\";\nasync function loadCurlNoisePath(engine) {\n engine.checkVersion(\"4.0.0-beta.2\");\n await engine.pluginManager.register(async (e)=>{\n const { ensureBaseMoverLoaded } = await Promise.resolve(/*! import() */).then(__webpack_require__.t.bind(__webpack_require__, /*! @tsparticles/plugin-move */ \"@tsparticles/plugin-move\", 19));\n ensureBaseMoverLoaded(e);\n e.pluginManager.addPathGenerator?.(curlNoisePathName, async (container)=>{\n const { CurlNoiseGenerator } = await __webpack_require__.e(/*! import() */ \"dist_browser_CurlNoiseGenerator_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./CurlNoiseGenerator.js */ \"./dist/browser/CurlNoiseGenerator.js\"));\n return new CurlNoiseGenerator(container);\n });\n });\n}\n\n\n//# sourceURL=webpack://@tsparticles/path-curl-noise/./dist/browser/index.js?\n}");
|
|
68
68
|
|
|
69
69
|
/***/ }
|
|
70
70
|
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@tsparticles/
|
|
2
|
-
(`+i+": "+n+")",a.name="ChunkLoadError",a.type=i,a.request=n,r[1](a)}},"chunk-"+e,e)}},i=(e,t)=>{var r,i,[n,a,s]=t,l=0;if(n.some(e=>0!==o[e])){for(r in a)c.o(a,r)&&(c.m[r]=a[r]);s&&s(c)}for(e&&e(t);l<n.length;l++)i=n[l],c.o(o,i)&&o[i]&&o[i][0](),o[i]=0},(n=this.webpackChunk_tsparticles_path_curl_noise=this.webpackChunk_tsparticles_path_curl_noise||[]).forEach(i.bind(null,0)),n.push=i.bind(null,n.push.bind(n));var g={};c.r(g),c.d(g,{curlNoisePathName:()=>m,loadCurlNoisePath:()=>v});let m="curlNoise";async function v(e){e.checkVersion("4.0.0-beta.
|
|
1
|
+
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@tsparticles/engine"),require("@tsparticles/plugin-move"),require("@tsparticles/simplex-noise"));else if("function"==typeof define&&define.amd)define(["@tsparticles/engine","@tsparticles/plugin-move","@tsparticles/simplex-noise"],t);else{var r="object"==typeof exports?t(require("@tsparticles/engine"),require("@tsparticles/plugin-move"),require("@tsparticles/simplex-noise")):t(e.window,e.window,e.window);for(var o in r)("object"==typeof exports?exports:e)[o]=r[o]}}(this,(e,t,r)=>(()=>{"use strict";var o,i,n,a={303(t){t.exports=e},400(e){e.exports=t},226(e){e.exports=r}},s={};function c(e){var t=s[e];if(void 0!==t)return t.exports;var r=s[e]={exports:{}};return a[e](r,r.exports,c),r.exports}c.m=a,p=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,c.t=function(e,t){if(1&t&&(e=this(e)),8&t||"object"==typeof e&&e&&(4&t&&e.__esModule||16&t&&"function"==typeof e.then))return e;var r=Object.create(null);c.r(r);var o={};l=l||[null,p({}),p([]),p(p)];for(var i=2&t&&e;("object"==typeof i||"function"==typeof i)&&!~l.indexOf(i);i=p(i))Object.getOwnPropertyNames(i).forEach(t=>o[t]=()=>e[t]);return o.default=()=>e,c.d(r,o),r},c.d=(e,t)=>{for(var r in t)c.o(t,r)&&!c.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},c.f={},c.e=e=>Promise.all(Object.keys(c.f).reduce((t,r)=>(c.f[r](e,t),t),[])),c.u=e=>""+e+".min.js",c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),u={},c.l=(e,t,r,o)=>{if(u[e])return void u[e].push(t);if(void 0!==r)for(var i,n,a=document.getElementsByTagName("script"),s=0;s<a.length;s++){var l=a[s];if(l.getAttribute("src")==e||l.getAttribute("data-webpack")=="@tsparticles/path-curl-noise:"+r){i=l;break}}i||(n=!0,(i=document.createElement("script")).charset="utf-8",c.nc&&i.setAttribute("nonce",c.nc),i.setAttribute("data-webpack","@tsparticles/path-curl-noise:"+r),i.src=e),u[e]=[t];var p=(t,r)=>{i.onerror=i.onload=null,clearTimeout(f);var o=u[e];if(delete u[e],i.parentNode&&i.parentNode.removeChild(i),o&&o.forEach(e=>e(r)),t)return t(r)},f=setTimeout(p.bind(null,void 0,{type:"timeout",target:i}),12e4);i.onerror=p.bind(null,i.onerror),i.onload=p.bind(null,i.onload),n&&document.head.appendChild(i)},c.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.g.importScripts&&(f=c.g.location+"");var l,p,u,f,d=c.g.document;if(!f&&d&&(d.currentScript&&"SCRIPT"===d.currentScript.tagName.toUpperCase()&&(f=d.currentScript.src),!f)){var h=d.getElementsByTagName("script");if(h.length)for(var b=h.length-1;b>-1&&(!f||!/^http(s?):/.test(f));)f=h[b--].src}if(!f)throw Error("Automatic publicPath is not supported in this browser");c.p=f=f.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),o={562:0},c.f.j=(e,t)=>{var r=c.o(o,e)?o[e]:void 0;if(0!==r)if(r)t.push(r[2]);else{var i=new Promise((t,i)=>r=o[e]=[t,i]);t.push(r[2]=i);var n=c.p+c.u(e),a=Error();c.l(n,t=>{if(c.o(o,e)&&(0!==(r=o[e])&&(o[e]=void 0),r)){var i=t&&("load"===t.type?"missing":t.type),n=t&&t.target&&t.target.src;a.message="Loading chunk "+e+` failed.
|
|
2
|
+
(`+i+": "+n+")",a.name="ChunkLoadError",a.type=i,a.request=n,r[1](a)}},"chunk-"+e,e)}},i=(e,t)=>{var r,i,[n,a,s]=t,l=0;if(n.some(e=>0!==o[e])){for(r in a)c.o(a,r)&&(c.m[r]=a[r]);s&&s(c)}for(e&&e(t);l<n.length;l++)i=n[l],c.o(o,i)&&o[i]&&o[i][0](),o[i]=0},(n=this.webpackChunk_tsparticles_path_curl_noise=this.webpackChunk_tsparticles_path_curl_noise||[]).forEach(i.bind(null,0)),n.push=i.bind(null,n.push.bind(n));var g={};c.r(g),c.d(g,{curlNoisePathName:()=>m,loadCurlNoisePath:()=>v}),c(303),c(400);let m="curlNoise";async function v(e){e.checkVersion("4.0.0-beta.2"),await e.pluginManager.register(async e=>{let{ensureBaseMoverLoaded:t}=await Promise.resolve().then(c.t.bind(c,400,19));t(e),e.pluginManager.addPathGenerator?.(m,async e=>{let{CurlNoiseGenerator:t}=await c.e(653).then(c.bind(c,653));return new t(e)})})}return g})());
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
(function (factory) {
|
|
2
|
-
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
-
var v = factory(require, exports);
|
|
4
|
-
if (v !== undefined) module.exports = v;
|
|
5
|
-
}
|
|
6
|
-
else if (typeof define === "function" && define.amd) {
|
|
7
|
-
define(["require", "exports", "@tsparticles/engine", "@tsparticles/simplex-noise"], factory);
|
|
8
|
-
}
|
|
9
|
-
})(function (require, exports) {
|
|
10
|
-
"use strict";
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
exports.CurlNoiseGenerator = void 0;
|
|
13
|
-
const engine_1 = require("@tsparticles/engine");
|
|
14
|
-
const simplex_noise_1 = require("@tsparticles/simplex-noise");
|
|
15
|
-
const defaultOptions = {
|
|
16
|
-
speed: 0.2,
|
|
17
|
-
step: 250,
|
|
18
|
-
};
|
|
19
|
-
class CurlNoiseGenerator {
|
|
20
|
-
options;
|
|
21
|
-
_container;
|
|
22
|
-
_res;
|
|
23
|
-
_simplex;
|
|
24
|
-
constructor(container) {
|
|
25
|
-
this._container = container;
|
|
26
|
-
this._res = engine_1.Vector.origin;
|
|
27
|
-
const simplex = new simplex_noise_1.SimplexNoise();
|
|
28
|
-
this._simplex = simplex.noise2d;
|
|
29
|
-
this.options = (0, engine_1.deepExtend)({}, defaultOptions);
|
|
30
|
-
}
|
|
31
|
-
generate(particle) {
|
|
32
|
-
const pos = particle.getPosition(), { speed, step } = this.options, x = pos.x / step, y = pos.y / step, eps = 0.001, n1a = this._simplex.noise(x, y + eps), n2a = this._simplex.noise(x, y - eps), a = (n1a - n2a) / (engine_1.double * eps), n1b = this._simplex.noise(x + eps, y), n2b = this._simplex.noise(x - eps, y), b = (n1b - n2b) / (engine_1.double * eps);
|
|
33
|
-
particle.velocity.x = 0;
|
|
34
|
-
particle.velocity.y = 0;
|
|
35
|
-
this._res.x = speed * a;
|
|
36
|
-
this._res.y = speed * -b;
|
|
37
|
-
return this._res;
|
|
38
|
-
}
|
|
39
|
-
init() {
|
|
40
|
-
const container = this._container, sourceOptions = container.actualOptions.particles.move.path.options;
|
|
41
|
-
this.options.seed = sourceOptions["seed"];
|
|
42
|
-
this.options.speed =
|
|
43
|
-
(sourceOptions["speed"] ?? defaultOptions.speed) * container.retina.pixelRatio;
|
|
44
|
-
this.options.step = sourceOptions["step"] ?? defaultOptions.step;
|
|
45
|
-
this._simplex.seed(this.options.seed ?? (0, engine_1.getRandom)());
|
|
46
|
-
}
|
|
47
|
-
reset() {
|
|
48
|
-
}
|
|
49
|
-
update() {
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
exports.CurlNoiseGenerator = CurlNoiseGenerator;
|
|
53
|
-
});
|
package/umd/ICurlOptions.js
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
(function (factory) {
|
|
2
|
-
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
-
var v = factory(require, exports);
|
|
4
|
-
if (v !== undefined) module.exports = v;
|
|
5
|
-
}
|
|
6
|
-
else if (typeof define === "function" && define.amd) {
|
|
7
|
-
define(["require", "exports"], factory);
|
|
8
|
-
}
|
|
9
|
-
})(function (require, exports) {
|
|
10
|
-
"use strict";
|
|
11
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
-
});
|
package/umd/index.js
DELETED
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
2
|
-
if (k2 === undefined) k2 = k;
|
|
3
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
4
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
5
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
6
|
-
}
|
|
7
|
-
Object.defineProperty(o, k2, desc);
|
|
8
|
-
}) : (function(o, m, k, k2) {
|
|
9
|
-
if (k2 === undefined) k2 = k;
|
|
10
|
-
o[k2] = m[k];
|
|
11
|
-
}));
|
|
12
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
13
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
14
|
-
}) : function(o, v) {
|
|
15
|
-
o["default"] = v;
|
|
16
|
-
});
|
|
17
|
-
var __importStar = (this && this.__importStar) || (function () {
|
|
18
|
-
var ownKeys = function(o) {
|
|
19
|
-
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
20
|
-
var ar = [];
|
|
21
|
-
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
22
|
-
return ar;
|
|
23
|
-
};
|
|
24
|
-
return ownKeys(o);
|
|
25
|
-
};
|
|
26
|
-
return function (mod) {
|
|
27
|
-
if (mod && mod.__esModule) return mod;
|
|
28
|
-
var result = {};
|
|
29
|
-
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
30
|
-
__setModuleDefault(result, mod);
|
|
31
|
-
return result;
|
|
32
|
-
};
|
|
33
|
-
})();
|
|
34
|
-
(function (factory) {
|
|
35
|
-
if (typeof module === "object" && typeof module.exports === "object") {
|
|
36
|
-
var v = factory(require, exports);
|
|
37
|
-
if (v !== undefined) module.exports = v;
|
|
38
|
-
}
|
|
39
|
-
else if (typeof define === "function" && define.amd) {
|
|
40
|
-
define(["require", "exports"], factory);
|
|
41
|
-
}
|
|
42
|
-
})(function (require, exports) {
|
|
43
|
-
"use strict";
|
|
44
|
-
var __syncRequire = typeof module === "object" && typeof module.exports === "object";
|
|
45
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
46
|
-
exports.curlNoisePathName = void 0;
|
|
47
|
-
exports.loadCurlNoisePath = loadCurlNoisePath;
|
|
48
|
-
exports.curlNoisePathName = "curlNoise";
|
|
49
|
-
async function loadCurlNoisePath(engine) {
|
|
50
|
-
engine.checkVersion("4.0.0-beta.1");
|
|
51
|
-
await engine.pluginManager.register(async (e) => {
|
|
52
|
-
const { ensureBaseMoverLoaded } = await (__syncRequire ? Promise.resolve().then(() => __importStar(require("@tsparticles/plugin-move"))) : new Promise((resolve_1, reject_1) => { require(["@tsparticles/plugin-move"], resolve_1, reject_1); }).then(__importStar));
|
|
53
|
-
ensureBaseMoverLoaded(e);
|
|
54
|
-
e.pluginManager.addPathGenerator?.(exports.curlNoisePathName, async (container) => {
|
|
55
|
-
const { CurlNoiseGenerator } = await (__syncRequire ? Promise.resolve().then(() => __importStar(require("./CurlNoiseGenerator.js"))) : new Promise((resolve_2, reject_2) => { require(["./CurlNoiseGenerator.js"], resolve_2, reject_2); }).then(__importStar));
|
|
56
|
-
return new CurlNoiseGenerator(container);
|
|
57
|
-
});
|
|
58
|
-
});
|
|
59
|
-
}
|
|
60
|
-
});
|