dazscript-framework 0.1.14 → 0.1.16
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 +365 -93
- package/babel.config.js +33 -33
- package/dist/babel/trace-babel-plugin.js +243 -243
- package/dist/babel/trace-log-babel-plugin.js +164 -164
- package/dist/scripts/install-generator.js +185 -185
- package/package.json +72 -70
- package/src/common/dz-dump.ts +120 -120
- package/src/common/log.ts +56 -57
- package/src/common/trace.ts +26 -26
- package/src/core/action-decorator.ts +15 -15
- package/src/core/base-script.ts +30 -30
- package/src/core/custom-action.ts +11 -11
- package/src/core/global.ts +4 -4
- package/src/dialog/basic-dialog.ts +40 -32
- package/src/dialog/builders/button-builder.ts +52 -52
- package/src/dialog/builders/checkbox-builder.ts +29 -29
- package/src/dialog/builders/color-picker-builder.ts +36 -0
- package/src/dialog/builders/combo-box-builder.ts +38 -35
- package/src/dialog/builders/combo-edit-builder.ts +35 -35
- package/src/dialog/builders/dialog-builder.ts +49 -49
- package/src/dialog/builders/groupbox-builder.ts +121 -73
- package/src/dialog/builders/label-builder.ts +33 -29
- package/src/dialog/builders/layout-builder.ts +59 -59
- package/src/dialog/builders/line-edit-builder.ts +124 -119
- package/src/dialog/builders/list-box-builder.ts +103 -0
- package/src/dialog/builders/list-view-builder.ts +396 -328
- package/src/dialog/builders/node-selection-builder.ts +55 -55
- package/src/dialog/builders/path-combo-box-builder.ts +24 -24
- package/src/dialog/builders/popup-menu-builder.ts +46 -46
- package/src/dialog/builders/radio-builder.ts +42 -42
- package/src/dialog/builders/slider-builder.ts +40 -0
- package/src/dialog/builders/splitter-builder.ts +88 -88
- package/src/dialog/builders/tab-builder.ts +120 -106
- package/src/dialog/builders/widget-builder.ts +136 -124
- package/src/dialog/builders/widgets-builder.ts +140 -125
- package/src/dialog/input-dialog.ts +30 -27
- package/src/dialog/input-validator.ts +8 -8
- package/src/dialog/selection-dialog.ts +47 -0
- package/src/dialog/shared.ts +8 -8
- package/src/helpers/action-helper.ts +214 -81
- package/src/helpers/array-helper.ts +170 -145
- package/src/helpers/camera-helper.ts +12 -12
- package/src/helpers/custom-action-helper.ts +176 -176
- package/src/helpers/directory-helper.ts +14 -0
- package/src/helpers/file-helper.ts +90 -90
- package/src/helpers/http-helper.ts +186 -0
- package/src/helpers/input-helper.ts +18 -18
- package/src/helpers/list-view-helper.ts +105 -89
- package/src/helpers/menu-helper.ts +28 -28
- package/src/helpers/message-box-helper.ts +25 -15
- package/src/helpers/node-helper.ts +461 -236
- package/src/helpers/number-helper.ts +10 -10
- package/src/helpers/numeric-property-helper.ts +91 -91
- package/src/helpers/object-helper.ts +2 -2
- package/src/helpers/pane-helper.ts +28 -20
- package/src/helpers/progress-helper.ts +51 -33
- package/src/helpers/property-helper.ts +61 -52
- package/src/helpers/record-helper.ts +16 -16
- package/src/helpers/scene-helper.ts +144 -95
- package/src/helpers/script-helper.ts +15 -15
- package/src/helpers/skeleton-helper.ts +26 -26
- package/src/helpers/splitter-helper.ts +8 -8
- package/src/helpers/string-helper.ts +39 -31
- package/src/helpers/surface-helper.ts +5 -5
- package/src/helpers/undo-helper.ts +8 -7
- package/src/helpers/viewport-helper.ts +21 -8
- package/src/lib/delayed.ts +38 -38
- package/src/lib/dictionary.ts +3 -0
- package/src/lib/frame-keys.ts +67 -67
- package/src/lib/guid.ts +2 -2
- package/src/lib/menu-item.ts +10 -9
- package/src/lib/observable.ts +147 -94
- package/src/lib/set.ts +50 -25
- package/src/lib/settings.ts +112 -104
- package/src/lib/tree-node.ts +149 -145
- package/src/samples/config.ts +2 -2
- package/src/samples/hello-world.dsa.ts +12 -12
- package/src/samples/sample-dialog.dsa.ts +51 -51
- package/src/samples/sample-dialog.ts +48 -48
- package/src/shared/set-keyboard-shortcut.ts +146 -102
- package/tsconfig.json +116 -116
- package/webpack.config.js +70 -70
package/webpack.config.js
CHANGED
|
@@ -1,70 +1,70 @@
|
|
|
1
|
-
const path = require('path');
|
|
2
|
-
const glob = require('glob');
|
|
3
|
-
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
|
|
4
|
-
|
|
5
|
-
module.exports = (env, argv) => {
|
|
6
|
-
const isFileSpecified = env && env.file;
|
|
7
|
-
const entryFiles = isFileSpecified
|
|
8
|
-
? [`./src/${env.file}.dsa.ts`]
|
|
9
|
-
: glob.sync('./src/**/*.dsa.ts');
|
|
10
|
-
|
|
11
|
-
const outputPath =
|
|
12
|
-
env && env.outputPath
|
|
13
|
-
? path.resolve(env.outputPath)
|
|
14
|
-
: path.resolve(__dirname, 'out');
|
|
15
|
-
|
|
16
|
-
return {
|
|
17
|
-
mode: 'production',
|
|
18
|
-
optimization: {
|
|
19
|
-
usedExports: true,
|
|
20
|
-
},
|
|
21
|
-
entry: entryFiles.reduce((acc, filePath) => {
|
|
22
|
-
const entry = filePath.replace('.dsa.ts', '').replace('src/', '');
|
|
23
|
-
acc[entry] = `./${filePath}`;
|
|
24
|
-
return acc;
|
|
25
|
-
}, {}),
|
|
26
|
-
module: {
|
|
27
|
-
rules: [
|
|
28
|
-
{
|
|
29
|
-
test: /\.ts$/,
|
|
30
|
-
use: [
|
|
31
|
-
{
|
|
32
|
-
loader: 'babel-loader',
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
loader: 'ts-loader',
|
|
36
|
-
options: {
|
|
37
|
-
allowTsInNodeModules: true,
|
|
38
|
-
},
|
|
39
|
-
},
|
|
40
|
-
],
|
|
41
|
-
exclude: [
|
|
42
|
-
{
|
|
43
|
-
and: [path.resolve(__dirname, 'node_modules')],
|
|
44
|
-
not: [
|
|
45
|
-
path.resolve(__dirname, 'node_modules/dazscript-framework/src'),
|
|
46
|
-
],
|
|
47
|
-
},
|
|
48
|
-
],
|
|
49
|
-
},
|
|
50
|
-
],
|
|
51
|
-
},
|
|
52
|
-
resolve: {
|
|
53
|
-
extensions: ['.ts'],
|
|
54
|
-
plugins: [new TsconfigPathsPlugin()],
|
|
55
|
-
},
|
|
56
|
-
output: {
|
|
57
|
-
filename: '[name].dsa',
|
|
58
|
-
path: outputPath,
|
|
59
|
-
environment: {
|
|
60
|
-
arrowFunction: false,
|
|
61
|
-
bigIntLiteral: false,
|
|
62
|
-
const: false,
|
|
63
|
-
destructuring: false,
|
|
64
|
-
dynamicImport: false,
|
|
65
|
-
forOf: true,
|
|
66
|
-
module: false,
|
|
67
|
-
},
|
|
68
|
-
},
|
|
69
|
-
};
|
|
70
|
-
};
|
|
1
|
+
const path = require('path');
|
|
2
|
+
const glob = require('glob');
|
|
3
|
+
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
|
|
4
|
+
|
|
5
|
+
module.exports = (env, argv) => {
|
|
6
|
+
const isFileSpecified = env && env.file;
|
|
7
|
+
const entryFiles = isFileSpecified
|
|
8
|
+
? [`./src/${env.file}.dsa.ts`]
|
|
9
|
+
: glob.sync('./src/**/*.dsa.ts');
|
|
10
|
+
|
|
11
|
+
const outputPath =
|
|
12
|
+
env && env.outputPath
|
|
13
|
+
? path.resolve(env.outputPath)
|
|
14
|
+
: path.resolve(__dirname, 'out');
|
|
15
|
+
|
|
16
|
+
return {
|
|
17
|
+
mode: 'production',
|
|
18
|
+
optimization: {
|
|
19
|
+
usedExports: true,
|
|
20
|
+
},
|
|
21
|
+
entry: entryFiles.reduce((acc, filePath) => {
|
|
22
|
+
const entry = filePath.replace('.dsa.ts', '').replace('src/', '');
|
|
23
|
+
acc[entry] = `./${filePath}`;
|
|
24
|
+
return acc;
|
|
25
|
+
}, {}),
|
|
26
|
+
module: {
|
|
27
|
+
rules: [
|
|
28
|
+
{
|
|
29
|
+
test: /\.ts$/,
|
|
30
|
+
use: [
|
|
31
|
+
{
|
|
32
|
+
loader: 'babel-loader',
|
|
33
|
+
},
|
|
34
|
+
{
|
|
35
|
+
loader: 'ts-loader',
|
|
36
|
+
options: {
|
|
37
|
+
allowTsInNodeModules: true,
|
|
38
|
+
},
|
|
39
|
+
},
|
|
40
|
+
],
|
|
41
|
+
exclude: [
|
|
42
|
+
{
|
|
43
|
+
and: [path.resolve(__dirname, 'node_modules')],
|
|
44
|
+
not: [
|
|
45
|
+
path.resolve(__dirname, 'node_modules/dazscript-framework/src'),
|
|
46
|
+
],
|
|
47
|
+
},
|
|
48
|
+
],
|
|
49
|
+
},
|
|
50
|
+
],
|
|
51
|
+
},
|
|
52
|
+
resolve: {
|
|
53
|
+
extensions: ['.ts'],
|
|
54
|
+
plugins: [new TsconfigPathsPlugin()],
|
|
55
|
+
},
|
|
56
|
+
output: {
|
|
57
|
+
filename: '[name].dsa',
|
|
58
|
+
path: outputPath,
|
|
59
|
+
environment: {
|
|
60
|
+
arrowFunction: false,
|
|
61
|
+
bigIntLiteral: false,
|
|
62
|
+
const: false,
|
|
63
|
+
destructuring: false,
|
|
64
|
+
dynamicImport: false,
|
|
65
|
+
forOf: true,
|
|
66
|
+
module: false,
|
|
67
|
+
},
|
|
68
|
+
},
|
|
69
|
+
};
|
|
70
|
+
};
|