flo-mat 3.0.3 → 3.0.5
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/browser/index.js +30678 -0
- package/browser/index.min.js +1 -1
- package/d.bat +4 -0
- package/newdocs/d.bat +4 -0
- package/node/bezier/total-curvature.d.ts +13 -1
- package/node/bezier/total-length.d.ts +13 -1
- package/node/cp-node/cp-node-fs.d.ts +12 -1
- package/node/cp-node/fs/get-distance-to-next.d.ts +12 -1
- package/node/cp-node/fs/get-mat-curve-to-next.d.ts +12 -1
- package/node/cp-node/fs/get-smoothed-speed.d.ts +12 -1
- package/node/cp-node/fs/get-speed.d.ts +12 -1
- package/node/cp-node/fs/traverse-edges.d.ts +1 -3
- package/node/cp-node/fs/traverse-edges.js +1 -34
- package/node/cp-node/fs/traverse-edges.js.map +1 -1
- package/node/debug/functions/draw-elem/draw-mat.js +2 -5
- package/node/debug/functions/draw-elem/draw-mat.js.map +1 -1
- package/node/geometry/get-bounding-box-.d.ts +13 -1
- package/node/point-on-shape/is-pos-quite-sharp-corner.d.ts +12 -1
- package/node/point-on-shape/is-pos-sharp-corner.d.ts +12 -1
- package/node/svg/get-loop-bounds.d.ts +12 -1
- package/node/svg/get-shape-bounds.d.ts +12 -1
- package/package.json +20 -21
- package/src/cp-node/fs/traverse-edges.ts +1 -50
- package/src/debug/functions/draw-elem/draw-mat.ts +5 -12
- package/tsconfig.json +5 -4
- package/webpack.config.cjs +83 -63
- package/node/utils/sleep.d.ts +0 -2
- package/node/utils/sleep.js +0 -5
- package/node/utils/sleep.js.map +0 -1
package/webpack.config.cjs
CHANGED
|
@@ -4,80 +4,100 @@
|
|
|
4
4
|
const path = require('path');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
const config_Basic = {
|
|
8
|
-
mode
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
7
|
+
const config_Basic = (env, argv) => {
|
|
8
|
+
const mode = argv.mode === 'production'
|
|
9
|
+
? 'production'
|
|
10
|
+
: 'development';
|
|
11
|
+
|
|
12
|
+
const devtool = mode === 'production'
|
|
13
|
+
? false
|
|
14
|
+
: 'eval-cheap-module-source-map';
|
|
15
|
+
|
|
16
|
+
return {
|
|
17
|
+
mode,
|
|
18
|
+
devtool,
|
|
19
|
+
output: {
|
|
20
|
+
path: path.resolve(__dirname, 'browser'),
|
|
21
|
+
library: { type: 'module' }
|
|
22
|
+
},
|
|
23
|
+
entry: './src/index.ts',
|
|
24
|
+
resolve: {
|
|
25
|
+
extensions: [
|
|
26
|
+
'.js', '.mjs', '.cjs',
|
|
27
|
+
'.jsx', '.cjsx', '.mjsx',
|
|
28
|
+
'.tsx', '.ts', '.d.ts'
|
|
29
|
+
],
|
|
30
|
+
extensionAlias: {
|
|
31
|
+
".js": [".js", ".ts"],
|
|
32
|
+
".cjs": [".cjs", ".cts"],
|
|
33
|
+
".mjs": [".mjs", ".mts"]
|
|
34
|
+
},
|
|
35
|
+
alias: {}
|
|
36
|
+
},
|
|
37
|
+
module: {
|
|
38
|
+
rules: [{
|
|
39
|
+
test: /\.tsx?$/,
|
|
40
|
+
use: [{
|
|
41
|
+
loader: 'ts-loader',
|
|
42
|
+
options: { silent: true }
|
|
43
|
+
}],
|
|
44
|
+
exclude: /node_modules/,
|
|
45
|
+
sideEffects: false
|
|
46
|
+
}]
|
|
47
|
+
},
|
|
48
|
+
stats: {
|
|
49
|
+
// Don't display most things
|
|
50
|
+
all: false,
|
|
51
|
+
colors: true,
|
|
52
|
+
errors: true,
|
|
53
|
+
builtAt: true
|
|
21
54
|
},
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
// Don't display most things
|
|
35
|
-
all: false,
|
|
36
|
-
colors: true,
|
|
37
|
-
errors: true,
|
|
38
|
-
builtAt: true
|
|
39
|
-
},
|
|
40
|
-
plugins: [
|
|
41
|
-
// new CircularDependencyPlugin({
|
|
42
|
-
// // exclude detection of files based on a RegExp
|
|
43
|
-
// exclude: /node_modules/,
|
|
44
|
-
// // add errors to webpack instead of warnings
|
|
45
|
-
// failOnError: true,
|
|
46
|
-
// // set the current working directory for displaying module paths
|
|
47
|
-
// cwd: process.cwd(),
|
|
48
|
-
// })
|
|
49
|
-
],
|
|
50
|
-
output: {
|
|
51
|
-
path: path.resolve(__dirname, 'browser'),
|
|
52
|
-
library: { type: 'module' }
|
|
53
|
-
},
|
|
54
|
-
experiments: { outputModule: true }
|
|
55
|
+
plugins: [
|
|
56
|
+
// new CircularDependencyPlugin({
|
|
57
|
+
// // exclude detection of files based on a RegExp
|
|
58
|
+
// exclude: /node_modules/,
|
|
59
|
+
// // add errors to webpack instead of warnings
|
|
60
|
+
// failOnError: true,
|
|
61
|
+
// // set the current working directory for displaying module paths
|
|
62
|
+
// cwd: process.cwd(),
|
|
63
|
+
// })
|
|
64
|
+
],
|
|
65
|
+
experiments: { outputModule: true }
|
|
66
|
+
};
|
|
55
67
|
}
|
|
56
68
|
|
|
57
69
|
|
|
58
70
|
/** ESM, minified */
|
|
59
|
-
const config_EsmMinify = {
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
71
|
+
const config_EsmMinify = (env, argv) => {
|
|
72
|
+
const baseConfig = config_Basic(env, argv);
|
|
73
|
+
|
|
74
|
+
return {
|
|
75
|
+
...baseConfig,
|
|
76
|
+
output: {
|
|
77
|
+
...baseConfig.output,
|
|
78
|
+
filename: 'index.min.js',
|
|
79
|
+
},
|
|
80
|
+
optimization: { minimize: true }
|
|
81
|
+
};
|
|
66
82
|
};
|
|
67
83
|
|
|
68
84
|
|
|
69
85
|
/** ESM, not minified */
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
86
|
+
const config_EsmNoMinify = (env, argv) => {
|
|
87
|
+
const baseConfig = config_Basic(env, argv);
|
|
88
|
+
|
|
89
|
+
return {
|
|
90
|
+
...baseConfig,
|
|
91
|
+
output: {
|
|
92
|
+
...baseConfig.output,
|
|
93
|
+
filename: 'index.js',
|
|
94
|
+
},
|
|
95
|
+
optimization: { minimize: false },
|
|
96
|
+
};
|
|
97
|
+
};
|
|
78
98
|
|
|
79
99
|
|
|
80
100
|
module.exports = [
|
|
81
101
|
config_EsmMinify,
|
|
82
|
-
|
|
102
|
+
config_EsmNoMinify
|
|
83
103
|
];
|
package/node/utils/sleep.d.ts
DELETED
package/node/utils/sleep.js
DELETED
package/node/utils/sleep.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"sleep.js","sourceRoot":"","sources":["../../src/utils/sleep.ts"],"names":[],"mappings":"AACA,SAAS,KAAK,CAAC,EAAU;IACrB,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,UAAU,CAAC,OAAO,EAAE,EAAE,CAAC,CAAC,CAAC;AAC3D,CAAC;AAGD,OAAO,EAAE,KAAK,EAAE,CAAA"}
|