@cloudbase/framework-plugin-low-code 1.7.2 → 1.7.3
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/lib/builder/config/common.d.ts +2 -0
- package/lib/builder/config/common.d.ts.map +1 -0
- package/lib/builder/config/common.js +13 -0
- package/lib/builder/config/index.d.ts +3 -0
- package/lib/builder/config/index.d.ts.map +1 -0
- package/lib/builder/config/index.js +29 -0
- package/lib/builder/config/mp.d.ts +2 -0
- package/lib/builder/config/mp.d.ts.map +1 -0
- package/lib/builder/config/mp.js +13 -0
- package/lib/builder/core/copy.d.ts +5 -0
- package/lib/builder/core/copy.d.ts.map +1 -0
- package/lib/builder/core/copy.js +62 -0
- package/lib/builder/core/generate.d.ts +9 -0
- package/lib/builder/core/generate.d.ts.map +1 -0
- package/lib/builder/core/generate.js +128 -0
- package/lib/builder/core/index.d.ts +32 -0
- package/lib/builder/core/index.d.ts.map +1 -0
- package/lib/builder/core/index.js +149 -0
- package/lib/builder/core/material.d.ts +4 -0
- package/lib/builder/core/material.d.ts.map +1 -0
- package/lib/builder/core/material.js +80 -0
- package/lib/builder/core/plugin.d.ts +4 -0
- package/lib/builder/core/plugin.d.ts.map +1 -0
- package/lib/builder/core/plugin.js +30 -0
- package/lib/builder/core/prepare.d.ts +8 -0
- package/lib/builder/core/prepare.d.ts.map +1 -0
- package/lib/builder/core/prepare.js +108 -0
- package/lib/builder/core/webpack.d.ts +15 -0
- package/lib/builder/core/webpack.d.ts.map +1 -0
- package/lib/builder/core/webpack.js +58 -0
- package/lib/builder/mp/BuildContext.d.ts +13 -0
- package/lib/builder/mp/BuildContext.d.ts.map +1 -0
- package/lib/builder/mp/BuildContext.js +2 -0
- package/lib/builder/mp/index.d.ts +33 -0
- package/lib/builder/mp/index.d.ts.map +1 -0
- package/lib/builder/mp/index.js +450 -0
- package/lib/builder/mp/lowcode.d.ts +8 -0
- package/lib/builder/mp/lowcode.d.ts.map +1 -0
- package/lib/builder/mp/lowcode.js +54 -0
- package/lib/builder/mp/materials.d.ts +15 -0
- package/lib/builder/mp/materials.d.ts.map +1 -0
- package/lib/builder/mp/materials.js +338 -0
- package/lib/builder/mp/mixMode.d.ts +10 -0
- package/lib/builder/mp/mixMode.d.ts.map +1 -0
- package/lib/builder/mp/mixMode.js +215 -0
- package/lib/builder/mp/mp_config.d.ts +18 -0
- package/lib/builder/mp/mp_config.d.ts.map +1 -0
- package/lib/builder/mp/mp_config.js +206 -0
- package/lib/builder/mp/util.d.ts +20 -0
- package/lib/builder/mp/util.d.ts.map +1 -0
- package/lib/builder/mp/util.js +243 -0
- package/lib/builder/mp/wxml.d.ts +16 -0
- package/lib/builder/mp/wxml.d.ts.map +1 -0
- package/lib/builder/mp/wxml.js +300 -0
- package/lib/builder/service/builder/copy.d.ts +14 -0
- package/lib/builder/service/builder/copy.d.ts.map +1 -0
- package/lib/builder/service/builder/copy.js +189 -0
- package/lib/builder/service/builder/generate.d.ts +52 -0
- package/lib/builder/service/builder/generate.d.ts.map +1 -0
- package/lib/builder/service/builder/generate.js +792 -0
- package/lib/builder/service/builder/index.d.ts +16 -0
- package/lib/builder/service/builder/index.d.ts.map +1 -0
- package/lib/builder/service/builder/index.js +69 -0
- package/lib/builder/service/builder/plugin.d.ts +8 -0
- package/lib/builder/service/builder/plugin.d.ts.map +1 -0
- package/lib/builder/service/builder/plugin.js +149 -0
- package/lib/builder/service/builder/webpack.d.ts +91 -0
- package/lib/builder/service/builder/webpack.d.ts.map +1 -0
- package/lib/builder/service/builder/webpack.js +589 -0
- package/lib/builder/types/common.d.ts +12 -0
- package/lib/builder/types/common.d.ts.map +1 -0
- package/lib/builder/types/common.js +7 -0
- package/lib/builder/util/common.d.ts +36 -0
- package/lib/builder/util/common.d.ts.map +1 -0
- package/lib/builder/util/common.js +257 -0
- package/lib/builder/util/console.d.ts +2 -0
- package/lib/builder/util/console.d.ts.map +1 -0
- package/lib/builder/util/console.js +13 -0
- package/lib/builder/util/generateFiles.d.ts +6 -0
- package/lib/builder/util/generateFiles.d.ts.map +1 -0
- package/lib/builder/util/generateFiles.js +94 -0
- package/lib/builder/util/index.d.ts +2 -0
- package/lib/builder/util/index.d.ts.map +1 -0
- package/lib/builder/util/index.js +13 -0
- package/lib/builder/util/junk.d.ts +3 -0
- package/lib/builder/util/junk.d.ts.map +1 -0
- package/lib/builder/util/junk.js +25 -0
- package/lib/builder/util/mp.d.ts +5 -0
- package/lib/builder/util/mp.d.ts.map +1 -0
- package/lib/builder/util/mp.js +99 -0
- package/lib/builder/util/name-mangler.d.ts +3 -0
- package/lib/builder/util/name-mangler.d.ts.map +1 -0
- package/lib/builder/util/name-mangler.js +7 -0
- package/lib/builder/util/net.d.ts +3 -0
- package/lib/builder/util/net.d.ts.map +1 -0
- package/lib/builder/util/net.js +54 -0
- package/lib/builder/util/process.d.ts +9 -0
- package/lib/builder/util/process.d.ts.map +1 -0
- package/lib/builder/util/process.js +28 -0
- package/lib/builder/util/style.d.ts +2 -0
- package/lib/builder/util/style.d.ts.map +1 -0
- package/lib/builder/util/style.js +13 -0
- package/lib/builder/util/weapp.d.ts +2 -0
- package/lib/builder/util/weapp.d.ts.map +1 -0
- package/lib/builder/util/weapp.js +13 -0
- package/lib/config/private.d.ts +3 -0
- package/lib/config/private.d.ts.map +1 -0
- package/lib/config/private.js +14 -0
- package/lib/generate.d.ts +2 -0
- package/lib/generate.d.ts.map +1 -0
- package/lib/generate.js +49 -0
- package/lib/generator/config/common.d.ts +6 -0
- package/lib/generator/config/common.d.ts.map +1 -0
- package/lib/generator/config/common.js +25 -0
- package/lib/generator/config/index.d.ts +18 -0
- package/lib/generator/config/index.d.ts.map +1 -0
- package/lib/generator/config/index.js +43 -0
- package/lib/generator/config/mp.d.ts +56 -0
- package/lib/generator/config/mp.d.ts.map +1 -0
- package/lib/generator/config/mp.js +104 -0
- package/lib/generator/core/generate.d.ts +59 -0
- package/lib/generator/core/generate.d.ts.map +1 -0
- package/lib/generator/core/generate.js +663 -0
- package/lib/generator/core/index.d.ts +25 -0
- package/lib/generator/core/index.d.ts.map +1 -0
- package/lib/generator/core/index.js +102 -0
- package/lib/generator/core/material.d.ts +14 -0
- package/lib/generator/core/material.d.ts.map +1 -0
- package/lib/generator/core/material.js +230 -0
- package/lib/generator/template.d.ts +3 -0
- package/lib/generator/template.d.ts.map +1 -0
- package/lib/generator/template.js +3 -0
- package/lib/generator/types/common.d.ts +69 -0
- package/lib/generator/types/common.d.ts.map +1 -0
- package/lib/generator/types/common.js +21 -0
- package/lib/generator/util/common.d.ts +36 -0
- package/lib/generator/util/common.d.ts.map +1 -0
- package/lib/generator/util/common.js +238 -0
- package/lib/generator/util/console.d.ts +3 -0
- package/lib/generator/util/console.d.ts.map +1 -0
- package/lib/generator/util/console.js +17 -0
- package/lib/generator/util/index.d.ts +2 -0
- package/lib/generator/util/index.d.ts.map +1 -0
- package/lib/generator/util/index.js +13 -0
- package/lib/generator/util/name-mangler.d.ts +17 -0
- package/lib/generator/util/name-mangler.d.ts.map +1 -0
- package/lib/generator/util/name-mangler.js +63 -0
- package/lib/generator/util/postcss-rpx.d.ts +11 -0
- package/lib/generator/util/postcss-rpx.d.ts.map +1 -0
- package/lib/generator/util/postcss-rpx.js +16 -0
- package/lib/generator/util/style.d.ts +6 -0
- package/lib/generator/util/style.d.ts.map +1 -0
- package/lib/generator/util/style.js +92 -0
- package/lib/generator/util/weapp.d.ts +5 -0
- package/lib/generator/util/weapp.d.ts.map +1 -0
- package/lib/generator/util/weapp.js +17 -0
- package/lib/index.d.ts +0 -0
- package/lib/index.d.ts.map +0 -0
- package/lib/index.js +0 -0
- package/lib/types.d.ts +14 -0
- package/lib/types.d.ts.map +1 -0
- package/lib/types.js +19 -0
- package/lib/utils/common.d.ts +0 -0
- package/lib/utils/common.d.ts.map +0 -0
- package/lib/utils/common.js +0 -0
- package/lib/utils/dataSource.d.ts +28 -0
- package/lib/utils/dataSource.d.ts.map +1 -0
- package/lib/utils/dataSource.js +171 -0
- package/lib/utils/index.d.ts +0 -0
- package/lib/utils/index.d.ts.map +0 -0
- package/lib/utils/index.js +0 -0
- package/lib/utils/postProcess.d.ts +3 -0
- package/lib/utils/postProcess.d.ts.map +1 -0
- package/lib/utils/postProcess.js +48 -0
- package/lib/weapps-core/config/index.d.ts +2 -0
- package/lib/weapps-core/config/index.d.ts.map +1 -0
- package/lib/weapps-core/config/index.js +13 -0
- package/lib/weapps-core/config/style.d.ts +7 -0
- package/lib/weapps-core/config/style.d.ts.map +1 -0
- package/lib/weapps-core/config/style.js +70 -0
- package/lib/weapps-core/index.d.ts +6 -0
- package/lib/weapps-core/index.d.ts.map +1 -0
- package/lib/weapps-core/index.js +31 -0
- package/lib/weapps-core/types/action.d.ts +25 -0
- package/lib/weapps-core/types/action.d.ts.map +1 -0
- package/lib/weapps-core/types/action.js +28 -0
- package/lib/weapps-core/types/app.d.ts +142 -0
- package/lib/weapps-core/types/app.d.ts.map +1 -0
- package/lib/weapps-core/types/app.js +21 -0
- package/lib/weapps-core/types/appbuild.d.ts +63 -0
- package/lib/weapps-core/types/appbuild.d.ts.map +1 -0
- package/lib/weapps-core/types/appbuild.js +78 -0
- package/lib/weapps-core/types/code_types.d.ts +26 -0
- package/lib/weapps-core/types/code_types.d.ts.map +1 -0
- package/lib/weapps-core/types/code_types.js +2 -0
- package/lib/weapps-core/types/git.d.ts +7 -0
- package/lib/weapps-core/types/git.d.ts.map +1 -0
- package/lib/weapps-core/types/git.js +2 -0
- package/lib/weapps-core/types/index.d.ts +11 -0
- package/lib/weapps-core/types/index.d.ts.map +1 -0
- package/lib/weapps-core/types/index.js +22 -0
- package/lib/weapps-core/types/lowcode.d.ts +26 -0
- package/lib/weapps-core/types/lowcode.d.ts.map +1 -0
- package/lib/weapps-core/types/lowcode.js +25 -0
- package/lib/weapps-core/types/material.d.ts +90 -0
- package/lib/weapps-core/types/material.d.ts.map +1 -0
- package/lib/weapps-core/types/material.js +9 -0
- package/lib/weapps-core/types/plugins.d.ts +17 -0
- package/lib/weapps-core/types/plugins.d.ts.map +1 -0
- package/lib/weapps-core/types/plugins.js +2 -0
- package/lib/weapps-core/types/style.d.ts +93 -0
- package/lib/weapps-core/types/style.d.ts.map +1 -0
- package/lib/weapps-core/types/style.js +2 -0
- package/lib/weapps-core/types/web.d.ts +120 -0
- package/lib/weapps-core/types/web.d.ts.map +1 -0
- package/lib/weapps-core/types/web.js +2 -0
- package/lib/weapps-core/utils/appbuild.d.ts +6 -0
- package/lib/weapps-core/utils/appbuild.d.ts.map +1 -0
- package/lib/weapps-core/utils/appbuild.js +40 -0
- package/lib/weapps-core/utils/common.d.ts +16 -0
- package/lib/weapps-core/utils/common.d.ts.map +1 -0
- package/lib/weapps-core/utils/common.js +90 -0
- package/lib/weapps-core/utils/file.d.ts +12 -0
- package/lib/weapps-core/utils/file.d.ts.map +1 -0
- package/lib/weapps-core/utils/file.js +142 -0
- package/lib/weapps-core/utils/formily.d.ts +5 -0
- package/lib/weapps-core/utils/formily.d.ts.map +1 -0
- package/lib/weapps-core/utils/formily.js +416 -0
- package/lib/weapps-core/utils/index.d.ts +7 -0
- package/lib/weapps-core/utils/index.d.ts.map +1 -0
- package/lib/weapps-core/utils/index.js +18 -0
- package/lib/weapps-core/utils/lowcdoe.d.ts +4 -0
- package/lib/weapps-core/utils/lowcdoe.d.ts.map +1 -0
- package/lib/weapps-core/utils/lowcdoe.js +69 -0
- package/lib/weapps-core/utils/style.d.ts +17 -0
- package/lib/weapps-core/utils/style.d.ts.map +1 -0
- package/lib/weapps-core/utils/style.js +330 -0
- package/package.json +3 -3
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getDatasetProfiles = exports.getDataVarProfiles = exports.getDatasourceProfiles = exports.standardizeDataSource = exports.lowercaseKey = exports.mergeDependencies = exports.getDatasourceDatabaseName = exports.getAppDatasourceResourceName = exports.getDatasourceResourceName = exports.DATABASE_TYPE = exports.EXTERNAL_FUNCTION_TYPE = exports.CLOUD_FUNCTION_TYPE = void 0;
|
|
7
|
+
const merge_package_json_1 = __importDefault(require("merge-package-json"));
|
|
8
|
+
const types_1 = require("../types");
|
|
9
|
+
const expression_1 = require("@cloudbase/cals/lib/parser/expression");
|
|
10
|
+
const util_1 = require("../builder/mp/util");
|
|
11
|
+
const config_1 = require("../builder/config");
|
|
12
|
+
exports.CLOUD_FUNCTION_TYPE = 'cloud-function';
|
|
13
|
+
exports.EXTERNAL_FUNCTION_TYPE = 'http';
|
|
14
|
+
exports.DATABASE_TYPE = 'database';
|
|
15
|
+
function getDatasourceResourceName(datasrouce, mode) {
|
|
16
|
+
let suffix = mode === types_1.DEPLOY_MODE.PREVIEW ? `-preview` : '';
|
|
17
|
+
return `lcap-${datasrouce.id}-${datasrouce.name}${suffix}`;
|
|
18
|
+
}
|
|
19
|
+
exports.getDatasourceResourceName = getDatasourceResourceName;
|
|
20
|
+
function getAppDatasourceResourceName(appId, datasrouce, mode) {
|
|
21
|
+
let suffix = mode === types_1.DEPLOY_MODE.PREVIEW ? `-preview` : '';
|
|
22
|
+
return `lcap-${datasrouce.id}-${datasrouce.name}-${appId}${suffix}`;
|
|
23
|
+
}
|
|
24
|
+
exports.getAppDatasourceResourceName = getAppDatasourceResourceName;
|
|
25
|
+
function getDatasourceDatabaseName(dsConfig, mode) {
|
|
26
|
+
return dsConfig.type === exports.DATABASE_TYPE
|
|
27
|
+
? getDatasourceResourceName(dsConfig, mode)
|
|
28
|
+
: null;
|
|
29
|
+
}
|
|
30
|
+
exports.getDatasourceDatabaseName = getDatasourceDatabaseName;
|
|
31
|
+
function mergeDependencies(...pkgs) {
|
|
32
|
+
let result = { dependencies: {} };
|
|
33
|
+
result = pkgs.reduce((acc, pkg) => {
|
|
34
|
+
var _a;
|
|
35
|
+
const formated = getDependencies(pkg);
|
|
36
|
+
for (let key in formated.dependencies) {
|
|
37
|
+
formated.dependencies[key] =
|
|
38
|
+
formated.dependencies[key] === '*' && ((_a = acc === null || acc === void 0 ? void 0 : acc.dependencies) === null || _a === void 0 ? void 0 : _a[key]) === '*'
|
|
39
|
+
? 'latest'
|
|
40
|
+
: formated.dependencies[key];
|
|
41
|
+
}
|
|
42
|
+
const merged = (0, merge_package_json_1.default)(formated, acc);
|
|
43
|
+
return JSON.parse(merged);
|
|
44
|
+
}, result);
|
|
45
|
+
return result.dependencies;
|
|
46
|
+
}
|
|
47
|
+
exports.mergeDependencies = mergeDependencies;
|
|
48
|
+
function getDependencies(pkg) {
|
|
49
|
+
if (pkg.dependencies && typeof pkg.dependencies === 'object') {
|
|
50
|
+
return {
|
|
51
|
+
dependencies: pkg.dependencies,
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
return {
|
|
55
|
+
dependencies: pkg,
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
function lowercaseKey(obj, deep) {
|
|
59
|
+
if (!obj || typeof obj !== 'object')
|
|
60
|
+
return obj;
|
|
61
|
+
if (Array.isArray(obj))
|
|
62
|
+
return obj.map((item) => lowercaseKey(item, deep));
|
|
63
|
+
const result = {};
|
|
64
|
+
return Object.keys(obj).reduce((acc, key) => {
|
|
65
|
+
const smallCase = key.charAt(0).toLowerCase() + key.slice(1);
|
|
66
|
+
const val = obj[key];
|
|
67
|
+
acc[smallCase] = deep ? lowercaseKey(val, deep) : val;
|
|
68
|
+
return acc;
|
|
69
|
+
}, result);
|
|
70
|
+
}
|
|
71
|
+
exports.lowercaseKey = lowercaseKey;
|
|
72
|
+
function standardizeDataSource(ds) {
|
|
73
|
+
const transformed = lowercaseKey(ds, true);
|
|
74
|
+
try {
|
|
75
|
+
const { schema } = ds;
|
|
76
|
+
if (typeof transformed.schema === 'string') {
|
|
77
|
+
transformed.schema = JSON.parse(transformed.schema);
|
|
78
|
+
}
|
|
79
|
+
if (!transformed.schema || typeof transformed.schema !== 'object') {
|
|
80
|
+
transformed.schema = {};
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
catch (error) {
|
|
84
|
+
transformed.schema = {};
|
|
85
|
+
}
|
|
86
|
+
try {
|
|
87
|
+
const { methods } = ds;
|
|
88
|
+
if (typeof transformed.methods === 'string') {
|
|
89
|
+
transformed.methods = JSON.parse(transformed.methods);
|
|
90
|
+
}
|
|
91
|
+
if (!Array.isArray(transformed.methods)) {
|
|
92
|
+
transformed.methods = [];
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
catch (error) {
|
|
96
|
+
transformed.methods = [];
|
|
97
|
+
}
|
|
98
|
+
return transformed;
|
|
99
|
+
}
|
|
100
|
+
exports.standardizeDataSource = standardizeDataSource;
|
|
101
|
+
function getDatasourceProfiles(datasources) {
|
|
102
|
+
return ((datasources === null || datasources === void 0 ? void 0 : datasources.map((item) => {
|
|
103
|
+
const ds = standardizeDataSource(item);
|
|
104
|
+
return {
|
|
105
|
+
id: ds.id,
|
|
106
|
+
title: ds.title,
|
|
107
|
+
name: ds.name,
|
|
108
|
+
type: ds.type,
|
|
109
|
+
childDataSourceNames: ds.childDataSourceNames,
|
|
110
|
+
schema: ds.schema,
|
|
111
|
+
methods: ds.methods,
|
|
112
|
+
};
|
|
113
|
+
})) || []);
|
|
114
|
+
}
|
|
115
|
+
exports.getDatasourceProfiles = getDatasourceProfiles;
|
|
116
|
+
function getDataVarProfiles(appData) {
|
|
117
|
+
const result = {
|
|
118
|
+
$global: (appData.vars && appData.vars.data) || [],
|
|
119
|
+
};
|
|
120
|
+
appData.pageInstanceList.forEach((pageInstance) => {
|
|
121
|
+
let p = pageInstance;
|
|
122
|
+
result[p.id] = (p.vars && p.vars.data) || [];
|
|
123
|
+
});
|
|
124
|
+
return result;
|
|
125
|
+
}
|
|
126
|
+
exports.getDataVarProfiles = getDataVarProfiles;
|
|
127
|
+
function _generateDynamicDataset(dataset) {
|
|
128
|
+
var _a;
|
|
129
|
+
let { state } = dataset;
|
|
130
|
+
if (state) {
|
|
131
|
+
for (let key in state) {
|
|
132
|
+
let config = state[key];
|
|
133
|
+
if (config.varType === 'datasource' && ((_a = config.initMethod) === null || _a === void 0 ? void 0 : _a.params)) {
|
|
134
|
+
let params = config.initMethod.params;
|
|
135
|
+
if (params) {
|
|
136
|
+
let processed = {};
|
|
137
|
+
for (let paramKey in params) {
|
|
138
|
+
let bind = params[paramKey];
|
|
139
|
+
if (!bind.type || bind.type === expression_1.PropBindType.static) {
|
|
140
|
+
let value = bind.value;
|
|
141
|
+
processed[paramKey] = `${config_1.REPLACE_SIGN}(app, $page) => (${typeof value === 'string' ? `'${value}'` : JSON.stringify(value)})${config_1.REPLACE_SIGN}`;
|
|
142
|
+
}
|
|
143
|
+
else {
|
|
144
|
+
let jsExp = (0, util_1.generateDataBind)(bind);
|
|
145
|
+
processed[paramKey] = `${config_1.REPLACE_SIGN}(app, $page) => (\n${jsExp || 'undefined'}\n)${config_1.REPLACE_SIGN}`;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
config.initMethod.params = processed;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
return dataset;
|
|
154
|
+
}
|
|
155
|
+
function getDatasetProfiles(mainAppData, apps) {
|
|
156
|
+
const result = {};
|
|
157
|
+
if (mainAppData.dataset) {
|
|
158
|
+
result['$global'] = _generateDynamicDataset(mainAppData.dataset);
|
|
159
|
+
}
|
|
160
|
+
(apps || []).forEach((app) => {
|
|
161
|
+
var _a;
|
|
162
|
+
(_a = app.pageInstanceList) === null || _a === void 0 ? void 0 : _a.forEach((pageInstance) => {
|
|
163
|
+
let p = pageInstance;
|
|
164
|
+
if (p.dataset) {
|
|
165
|
+
result[app.rootPath ? `${app.rootPath}/${p.id}` : p.id] = _generateDynamicDataset(p.dataset);
|
|
166
|
+
}
|
|
167
|
+
});
|
|
168
|
+
});
|
|
169
|
+
return result;
|
|
170
|
+
}
|
|
171
|
+
exports.getDatasetProfiles = getDatasetProfiles;
|
package/lib/utils/index.d.ts
CHANGED
|
File without changes
|
package/lib/utils/index.d.ts.map
CHANGED
|
File without changes
|
package/lib/utils/index.js
CHANGED
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"postProcess.d.ts","sourceRoot":"","sources":["../../src/utils/postProcess.ts"],"names":[],"mappings":"AAIA,wBAAgB,wBAAwB,CAAC,eAAe,KAAA,EAAE,IAAI,KAAA,QAI7D;AAED,wBAAgB,0BAA0B,CAAC,WAAW,KAAA,EAAE,aAAa,KAAA,QAkBpE"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
+
};
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.postprocessDeployExtraJson = exports.postprocessProjectConfig = void 0;
|
|
30
|
+
const fs_extra_1 = __importStar(require("fs-extra"));
|
|
31
|
+
const lodash_1 = require("lodash");
|
|
32
|
+
const path_1 = __importDefault(require("path"));
|
|
33
|
+
function postprocessProjectConfig(projectJsonPath, data) {
|
|
34
|
+
let projectJson = fs_extra_1.default.readJsonSync(projectJsonPath);
|
|
35
|
+
fs_extra_1.default.writeJsonSync(projectJsonPath, (0, lodash_1.merge)(projectJson, data), { spaces: 2 });
|
|
36
|
+
}
|
|
37
|
+
exports.postprocessProjectConfig = postprocessProjectConfig;
|
|
38
|
+
function postprocessDeployExtraJson(projectPath, deployOptions) {
|
|
39
|
+
let { targetMpAppId, mpAppId } = deployOptions;
|
|
40
|
+
if (targetMpAppId !== mpAppId) {
|
|
41
|
+
let projectJson = fs_extra_1.default.readJsonSync(path_1.default.resolve(projectPath, 'project.config.json'));
|
|
42
|
+
const miniprogramRoot = (projectJson === null || projectJson === void 0 ? void 0 : projectJson.miniprogramRoot) || './';
|
|
43
|
+
const extPaht = path_1.default.resolve(projectPath, miniprogramRoot, 'ext.json');
|
|
44
|
+
const extJson = Object.assign(Object.assign({}, (fs_extra_1.default.existsSync(extPaht) ? (0, fs_extra_1.readJsonSync)(extPaht) : {})), { extEnable: true, extAppid: targetMpAppId, directCommit: true });
|
|
45
|
+
fs_extra_1.default.writeFileSync(extPaht, JSON.stringify(extJson, null, 2));
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
exports.postprocessDeployExtraJson = postprocessDeployExtraJson;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/weapps-core/config/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAA"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./style"), exports);
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare const SELF_REMOVE_STYLE_KEY_LIST: string[];
|
|
2
|
+
export declare const SELF_REMOVE_WITH_PERCENTAGE_KEY_LIST: string[];
|
|
3
|
+
export declare const WRAPPER_REMOVE_STYLE_KEY_LIST: string[];
|
|
4
|
+
export declare const PERCENTAGE_KEY_LIST: string[];
|
|
5
|
+
export declare const DISTANCE_KEY_LIST: string[];
|
|
6
|
+
export declare const KEBAB_REGEX: RegExp;
|
|
7
|
+
//# sourceMappingURL=style.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"style.d.ts","sourceRoot":"","sources":["../../../src/weapps-core/config/style.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,0BAA0B,UAgBtC,CAAA;AAED,eAAO,MAAM,oCAAoC,UAAsB,CAAA;AAGvE,eAAO,MAAM,6BAA6B,UA8CzC,CAAA;AAED,eAAO,MAAM,mBAAmB,UAS/B,CAAA;AAED,eAAO,MAAM,iBAAiB,UAAqC,CAAA;AAEnE,eAAO,MAAM,WAAW,QAAW,CAAA"}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.KEBAB_REGEX = exports.DISTANCE_KEY_LIST = exports.PERCENTAGE_KEY_LIST = exports.WRAPPER_REMOVE_STYLE_KEY_LIST = exports.SELF_REMOVE_WITH_PERCENTAGE_KEY_LIST = exports.SELF_REMOVE_STYLE_KEY_LIST = void 0;
|
|
4
|
+
exports.SELF_REMOVE_STYLE_KEY_LIST = [
|
|
5
|
+
'margin',
|
|
6
|
+
'marginTop',
|
|
7
|
+
'marginRight',
|
|
8
|
+
'marginBottom',
|
|
9
|
+
'marginLeft',
|
|
10
|
+
'position',
|
|
11
|
+
'top',
|
|
12
|
+
'right',
|
|
13
|
+
'bottom',
|
|
14
|
+
'left',
|
|
15
|
+
'float',
|
|
16
|
+
'transform',
|
|
17
|
+
'animation',
|
|
18
|
+
];
|
|
19
|
+
exports.SELF_REMOVE_WITH_PERCENTAGE_KEY_LIST = ['width', 'height'];
|
|
20
|
+
exports.WRAPPER_REMOVE_STYLE_KEY_LIST = [
|
|
21
|
+
'justifyContent',
|
|
22
|
+
'alignItems',
|
|
23
|
+
'flexDirection',
|
|
24
|
+
'flexWrap',
|
|
25
|
+
'flexFlow',
|
|
26
|
+
'background',
|
|
27
|
+
'backgroundColor',
|
|
28
|
+
'backgroundImage',
|
|
29
|
+
'padding',
|
|
30
|
+
'paddingTop',
|
|
31
|
+
'paddingRight',
|
|
32
|
+
'paddingBottom',
|
|
33
|
+
'paddingLeft',
|
|
34
|
+
'border',
|
|
35
|
+
'borderStyle',
|
|
36
|
+
'borderWidth',
|
|
37
|
+
'borderColor',
|
|
38
|
+
'borderImage',
|
|
39
|
+
'borderRadius',
|
|
40
|
+
'borderTop',
|
|
41
|
+
'borderRight',
|
|
42
|
+
'borderBottom',
|
|
43
|
+
'borderLeft',
|
|
44
|
+
'outline',
|
|
45
|
+
'outlineColor',
|
|
46
|
+
'outlineOffset',
|
|
47
|
+
'outlineStyle',
|
|
48
|
+
'outlineWidth',
|
|
49
|
+
'boxShadow',
|
|
50
|
+
'columnCount',
|
|
51
|
+
'columnGap',
|
|
52
|
+
'columnRuleStyle',
|
|
53
|
+
'columnRuleWidth',
|
|
54
|
+
'columnRuleColor',
|
|
55
|
+
'columnRule',
|
|
56
|
+
'columnSpan',
|
|
57
|
+
'columnWidth',
|
|
58
|
+
];
|
|
59
|
+
exports.PERCENTAGE_KEY_LIST = [
|
|
60
|
+
'opacity',
|
|
61
|
+
'order',
|
|
62
|
+
'flex',
|
|
63
|
+
'flexGrow',
|
|
64
|
+
'flexShrink',
|
|
65
|
+
'zIndex',
|
|
66
|
+
'fontWeight',
|
|
67
|
+
'borderImage',
|
|
68
|
+
];
|
|
69
|
+
exports.DISTANCE_KEY_LIST = ['top', 'right', 'bottom', 'left'];
|
|
70
|
+
exports.KEBAB_REGEX = /[A-Z]/g;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/weapps-core/index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAS,CAAA;AACvB,cAAc,SAAS,CAAA;AAEvB,OAAO,KAAK,OAAO,MAAM,iBAAiB,CAAA;AAC1C,OAAO,KAAK,KAAK,MAAM,eAAe,CAAA;AAEtC,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAA"}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
+
}) : function(o, v) {
|
|
12
|
+
o["default"] = v;
|
|
13
|
+
});
|
|
14
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
15
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
16
|
+
};
|
|
17
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
18
|
+
if (mod && mod.__esModule) return mod;
|
|
19
|
+
var result = {};
|
|
20
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
21
|
+
__setModuleDefault(result, mod);
|
|
22
|
+
return result;
|
|
23
|
+
};
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.style = exports.formily = void 0;
|
|
26
|
+
__exportStar(require("./types"), exports);
|
|
27
|
+
__exportStar(require("./utils"), exports);
|
|
28
|
+
const formily = __importStar(require("./utils/formily"));
|
|
29
|
+
exports.formily = formily;
|
|
30
|
+
const style = __importStar(require("./utils/style"));
|
|
31
|
+
exports.style = style;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
export declare enum BaseActionTrigger {
|
|
2
|
+
INIT = "__weapps_action_trigger_init",
|
|
3
|
+
CLICK = "__weapps_action_trigger_click",
|
|
4
|
+
MOUSE_ENTER = "__weapps_action_trigger_mouseEnter",
|
|
5
|
+
MOUSE_LEAVE = "__weapps_action_trigger_mouseLeave",
|
|
6
|
+
DOUBLE_CLICK = "__weapps_action_trigger_double_click",
|
|
7
|
+
LONG_PRESS = "__weapps_action_trigger_long_press",
|
|
8
|
+
ENTER_VIEW = "__weapps_action_trigger_enter_view",
|
|
9
|
+
LEAVE_VIEW = "__weapps_action_trigger_leave_view",
|
|
10
|
+
UNMOUNT = "__weapps_action_trigger_unmount",
|
|
11
|
+
FIELD_VALUE_CHANGE = "__weapps_action_trigger_field_value_change"
|
|
12
|
+
}
|
|
13
|
+
export declare type ActionTrigger = BaseActionTrigger | 'string';
|
|
14
|
+
export declare enum ActionType {
|
|
15
|
+
Rematch = "rematch",
|
|
16
|
+
Material = "material",
|
|
17
|
+
GeneralFunc = "general-func",
|
|
18
|
+
LifeCycle = "lifecycle",
|
|
19
|
+
PropEvent = "prop-event",
|
|
20
|
+
HandlerFn = "handler-fn",
|
|
21
|
+
Inline = "inline",
|
|
22
|
+
Platform = "platform",
|
|
23
|
+
DataSource = "dataSource"
|
|
24
|
+
}
|
|
25
|
+
//# sourceMappingURL=action.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.d.ts","sourceRoot":"","sources":["../../../src/weapps-core/types/action.ts"],"names":[],"mappings":"AAAA,oBAAY,iBAAiB;IAC3B,IAAI,iCAAiC;IACrC,KAAK,kCAAkC;IACvC,WAAW,uCAAuC;IAClD,WAAW,uCAAuC;IAClD,YAAY,yCAAyC;IACrD,UAAU,uCAAuC;IACjD,UAAU,uCAAuC;IACjD,UAAU,uCAAuC;IACjD,OAAO,oCAAoC;IAC3C,kBAAkB,+CAA+C;CAClE;AAED,oBAAY,aAAa,GAAG,iBAAiB,GAAG,QAAQ,CAAA;AAExD,oBAAY,UAAU;IACpB,OAAO,YAAY;IACnB,QAAQ,aAAa;IACrB,WAAW,iBAAiB;IAC5B,SAAS,cAAc;IACvB,SAAS,eAAe;IACxB,SAAS,eAAe;IACxB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,UAAU,eAAe;CAC1B"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ActionType = exports.BaseActionTrigger = void 0;
|
|
4
|
+
var BaseActionTrigger;
|
|
5
|
+
(function (BaseActionTrigger) {
|
|
6
|
+
BaseActionTrigger["INIT"] = "__weapps_action_trigger_init";
|
|
7
|
+
BaseActionTrigger["CLICK"] = "__weapps_action_trigger_click";
|
|
8
|
+
BaseActionTrigger["MOUSE_ENTER"] = "__weapps_action_trigger_mouseEnter";
|
|
9
|
+
BaseActionTrigger["MOUSE_LEAVE"] = "__weapps_action_trigger_mouseLeave";
|
|
10
|
+
BaseActionTrigger["DOUBLE_CLICK"] = "__weapps_action_trigger_double_click";
|
|
11
|
+
BaseActionTrigger["LONG_PRESS"] = "__weapps_action_trigger_long_press";
|
|
12
|
+
BaseActionTrigger["ENTER_VIEW"] = "__weapps_action_trigger_enter_view";
|
|
13
|
+
BaseActionTrigger["LEAVE_VIEW"] = "__weapps_action_trigger_leave_view";
|
|
14
|
+
BaseActionTrigger["UNMOUNT"] = "__weapps_action_trigger_unmount";
|
|
15
|
+
BaseActionTrigger["FIELD_VALUE_CHANGE"] = "__weapps_action_trigger_field_value_change";
|
|
16
|
+
})(BaseActionTrigger = exports.BaseActionTrigger || (exports.BaseActionTrigger = {}));
|
|
17
|
+
var ActionType;
|
|
18
|
+
(function (ActionType) {
|
|
19
|
+
ActionType["Rematch"] = "rematch";
|
|
20
|
+
ActionType["Material"] = "material";
|
|
21
|
+
ActionType["GeneralFunc"] = "general-func";
|
|
22
|
+
ActionType["LifeCycle"] = "lifecycle";
|
|
23
|
+
ActionType["PropEvent"] = "prop-event";
|
|
24
|
+
ActionType["HandlerFn"] = "handler-fn";
|
|
25
|
+
ActionType["Inline"] = "inline";
|
|
26
|
+
ActionType["Platform"] = "platform";
|
|
27
|
+
ActionType["DataSource"] = "dataSource";
|
|
28
|
+
})(ActionType = exports.ActionType || (exports.ActionType = {}));
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
import { CSSProperties, ICommonStyle } from './style';
|
|
2
|
+
import { ActionType } from './action';
|
|
3
|
+
import { IWeAppCode } from './lowcode';
|
|
4
|
+
import { IMiniprogramPlugin, IPlugin } from '../types/plugins';
|
|
5
|
+
import { HISTORY_TYPE } from '../../types';
|
|
6
|
+
export interface IAppAndPageVar {
|
|
7
|
+
dataset?: {
|
|
8
|
+
state?: {};
|
|
9
|
+
param?: {};
|
|
10
|
+
};
|
|
11
|
+
vars: {
|
|
12
|
+
data: any[];
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
export interface IWeAppData {
|
|
16
|
+
mpPkgUrl?: string;
|
|
17
|
+
selectedPageId?: string;
|
|
18
|
+
historyType?: HISTORY_TYPE;
|
|
19
|
+
pageInstanceList: IWeAppPage[];
|
|
20
|
+
lowCodes: IWeAppCode[];
|
|
21
|
+
npmDependencies: {
|
|
22
|
+
[packageName: string]: string;
|
|
23
|
+
};
|
|
24
|
+
plugins: IPlugin[];
|
|
25
|
+
maxID?: number;
|
|
26
|
+
rootPath?: string;
|
|
27
|
+
themeVars?: {
|
|
28
|
+
[key: string]: string;
|
|
29
|
+
};
|
|
30
|
+
presetColors?: string[];
|
|
31
|
+
appConfig?: Record<string, any>;
|
|
32
|
+
envId: string;
|
|
33
|
+
datasources: any[];
|
|
34
|
+
dataset?: IAppAndPageVar['dataset'];
|
|
35
|
+
vars: IAppAndPageVar['vars'];
|
|
36
|
+
miniprogramPlugins: IMiniprogramPlugin[];
|
|
37
|
+
extra: {
|
|
38
|
+
domain: string;
|
|
39
|
+
clientId?: string;
|
|
40
|
+
loginConfigVersion?: string;
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
export interface IWeAppPage {
|
|
44
|
+
id: string;
|
|
45
|
+
isHome: boolean;
|
|
46
|
+
data: {
|
|
47
|
+
[prop: string]: IDynamicValue;
|
|
48
|
+
};
|
|
49
|
+
listeners: IEventListener[];
|
|
50
|
+
componentInstances: {
|
|
51
|
+
[key: string]: IWeAppComponentInstance;
|
|
52
|
+
};
|
|
53
|
+
pluginInstances: any[];
|
|
54
|
+
commonStyle: ICommonStyle;
|
|
55
|
+
styleBindPath: string;
|
|
56
|
+
lowCodes?: IWeAppCode[];
|
|
57
|
+
children?: IWeAppPage[];
|
|
58
|
+
pageId?: string;
|
|
59
|
+
codeType?: 'page' | 'global';
|
|
60
|
+
code?: string;
|
|
61
|
+
dataset?: IAppAndPageVar['dataset'];
|
|
62
|
+
}
|
|
63
|
+
export interface IWeAppComponentInstance {
|
|
64
|
+
xComponent?: {
|
|
65
|
+
moduleName: string;
|
|
66
|
+
name: string;
|
|
67
|
+
};
|
|
68
|
+
xProps?: {
|
|
69
|
+
data: {
|
|
70
|
+
[prop: string]: IDynamicValue;
|
|
71
|
+
};
|
|
72
|
+
directives?: {
|
|
73
|
+
waIf?: IDynamicValue;
|
|
74
|
+
waFor?: IDynamicValue;
|
|
75
|
+
waForKey?: IDynamicValue;
|
|
76
|
+
};
|
|
77
|
+
listeners?: IEventListener[];
|
|
78
|
+
style: CSSProperties;
|
|
79
|
+
styleBind: IDynamicValue;
|
|
80
|
+
classList: string[];
|
|
81
|
+
classListBind: IDynamicValue;
|
|
82
|
+
commonStyle: ICommonStyle;
|
|
83
|
+
styleBindPath?: string;
|
|
84
|
+
customDataForm: Record<string, any>;
|
|
85
|
+
staticResourceAttribute: string[];
|
|
86
|
+
};
|
|
87
|
+
xIndex?: number;
|
|
88
|
+
properties?: {
|
|
89
|
+
[key: string]: IWeAppComponentInstance;
|
|
90
|
+
};
|
|
91
|
+
genericComp?: {
|
|
92
|
+
propName: string;
|
|
93
|
+
title: string;
|
|
94
|
+
description?: string;
|
|
95
|
+
allowedCompType?: string;
|
|
96
|
+
xIndex?: number;
|
|
97
|
+
};
|
|
98
|
+
}
|
|
99
|
+
export interface IEventListener extends IEventModifiers {
|
|
100
|
+
key?: string;
|
|
101
|
+
trigger: string;
|
|
102
|
+
type: ActionType;
|
|
103
|
+
handler?: {
|
|
104
|
+
moduleName: string;
|
|
105
|
+
name: string;
|
|
106
|
+
};
|
|
107
|
+
jsCode?: string;
|
|
108
|
+
data: {
|
|
109
|
+
[prop: string]: IDynamicValue;
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
export interface IEventModifiers {
|
|
113
|
+
isCapturePhase?: boolean;
|
|
114
|
+
noPropagation?: boolean;
|
|
115
|
+
}
|
|
116
|
+
export interface IDynamicValue {
|
|
117
|
+
type?: 'static' | PropBindType;
|
|
118
|
+
value: any | string;
|
|
119
|
+
}
|
|
120
|
+
export declare enum PropBindType {
|
|
121
|
+
state = "rematch",
|
|
122
|
+
computed = "computed",
|
|
123
|
+
forItem = "for-item",
|
|
124
|
+
expression = "expression",
|
|
125
|
+
prop = "prop",
|
|
126
|
+
slot = "slot",
|
|
127
|
+
dataVar = "dataVar",
|
|
128
|
+
stateData = "state",
|
|
129
|
+
paramData = "params",
|
|
130
|
+
scope = "scope"
|
|
131
|
+
}
|
|
132
|
+
export declare enum BindPropertyPath {
|
|
133
|
+
style = "style",
|
|
134
|
+
classNameList = "classNameList"
|
|
135
|
+
}
|
|
136
|
+
export interface ILockedPage {
|
|
137
|
+
id: string;
|
|
138
|
+
username: string;
|
|
139
|
+
socketId: string;
|
|
140
|
+
}
|
|
141
|
+
export declare type IBuildType = 'web' | 'mp' | 'app' | 'qywxH5' | 'wxH5';
|
|
142
|
+
//# sourceMappingURL=app.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../../../src/weapps-core/types/app.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AACtD,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AACvC,OAAO,EAAE,kBAAkB,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,aAAa,CAAC;AAE3C,MAAM,WAAW,cAAc;IAE7B,OAAO,CAAC,EAAE;QACR,KAAK,CAAC,EAAE,EAAE,CAAC;QACX,KAAK,CAAC,EAAE,EAAE,CAAC;KACZ,CAAC;IACF,IAAI,EAAE;QAEJ,IAAI,EAA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AQ,GAAG,MAAM,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BindPropertyPath = exports.PropBindType = void 0;
|
|
4
|
+
var PropBindType;
|
|
5
|
+
(function (PropBindType) {
|
|
6
|
+
PropBindType["state"] = "rematch";
|
|
7
|
+
PropBindType["computed"] = "computed";
|
|
8
|
+
PropBindType["forItem"] = "for-item";
|
|
9
|
+
PropBindType["expression"] = "expression";
|
|
10
|
+
PropBindType["prop"] = "prop";
|
|
11
|
+
PropBindType["slot"] = "slot";
|
|
12
|
+
PropBindType["dataVar"] = "dataVar";
|
|
13
|
+
PropBindType["stateData"] = "state";
|
|
14
|
+
PropBindType["paramData"] = "params";
|
|
15
|
+
PropBindType["scope"] = "scope";
|
|
16
|
+
})(PropBindType = exports.PropBindType || (exports.PropBindType = {}));
|
|
17
|
+
var BindPropertyPath;
|
|
18
|
+
(function (BindPropertyPath) {
|
|
19
|
+
BindPropertyPath["style"] = "style";
|
|
20
|
+
BindPropertyPath["classNameList"] = "classNameList";
|
|
21
|
+
})(BindPropertyPath = exports.BindPropertyPath || (exports.BindPropertyPath = {}));
|