@cloudbase/cals 1.0.3-alpha.6 → 1.0.3-alpha.8
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/cloudbase.cals.umd.min.js +5 -0
- package/lib/parser/cals/index.d.ts +366 -371
- package/lib/parser/cals/index.d.ts.map +1 -1
- package/lib/parser/cals/index.js +12 -12
- package/lib/parser/cals/utils/block/index.d.ts +14 -14
- package/lib/parser/cals/utils/block/index.js +3 -3
- package/lib/parser/cals/utils/code/index.d.ts +30 -30
- package/lib/parser/cals/utils/code/index.js +13 -12
- package/lib/parser/cals/utils/common.d.ts +11 -11
- package/lib/parser/cals/utils/runtime.d.ts +13 -13
- package/lib/parser/cals/utils/runtime.d.ts.map +1 -1
- package/lib/parser/cals/utils/runtime.js +2 -2
- package/lib/parser/cals/utils/spinoff/index.d.ts +9 -9
- package/lib/parser/cals/utils/style.d.ts +42 -42
- package/lib/parser/cals/utils/style.d.ts.map +1 -1
- package/lib/parser/cals/utils/style.js +3 -3
- package/lib/parser/cals/utils/template.d.ts +5 -5
- package/lib/parser/cals/utils/template.js +3 -6
- package/lib/parser/cals/utils/version/common.d.ts +4 -4
- package/lib/parser/cals/utils/version/common.js +11 -34
- package/lib/parser/cals/utils/version/config.d.ts +13 -13
- package/lib/parser/cals/utils/version/index.d.ts +2 -2
- package/lib/parser/cals/utils/version/parses.d.ts +15 -15
- package/lib/parser/cals/utils/version/parses.js +14 -37
- package/lib/parser/cals/utils/version/utils.d.ts +13 -13
- package/lib/parser/cals/utils/version/utils.d.ts.map +1 -1
- package/lib/parser/cals/utils/version/utils.js +2 -2
- package/lib/parser/expression/index.d.ts +122 -122
- package/lib/parser/index.d.ts +8 -8
- package/lib/parser/plugins/postcss-rpx2clac.d.ts +17 -17
- package/lib/parser/plugins/postcss-rpx2clac.js +2 -2
- package/lib/types/basic/app.d.ts +72 -72
- package/lib/types/basic/common.d.ts +88 -88
- package/lib/types/basic/component.d.ts +208 -208
- package/lib/types/basic/datasource.d.ts +49 -49
- package/lib/types/index.d.ts +9 -9
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/index.js +14 -1
- package/lib/types/lcds.d.ts +447 -197
- package/lib/types/lcds.d.ts.map +1 -1
- package/lib/types/platform/app.d.ts +176 -176
- package/lib/types/platform/common.d.ts +137 -137
- package/lib/types/platform/component.d.ts +140 -140
- package/lib/types/platform/datasource.d.ts +466 -466
- package/lib/types/platform/widget/form.d.ts +89 -89
- package/lib/types/platform/widget/meta.d.ts +59 -59
- package/lib/utils/CSSProperty.d.ts +63 -63
- package/lib/utils/build.d.ts +1 -1
- package/lib/utils/build.js +3 -6
- package/lib/utils/constant.d.ts +40 -40
- package/lib/utils/dts/auto-generated.d.ts +1 -1
- package/lib/utils/dts/auto-generated.d.ts.map +1 -1
- package/lib/utils/dts/auto-generated.js +1 -1
- package/lib/utils/dts/build.d.ts +1 -1
- package/lib/utils/dts/index.d.ts +130 -130
- package/lib/utils/dts/index.d.ts.map +1 -1
- package/lib/utils/dts/index.js +116 -78
- package/lib/utils/index.d.ts +7 -7
- package/lib/utils/version/common.d.ts +2 -2
- package/lib/utils/version/featureChecker.d.ts +2 -2
- package/lib/utils/version/featureChecker.d.ts.map +1 -1
- package/lib/utils/version/migrations/version4.d.ts +2 -2
- package/lib/utils/version/migrations/version4.js +2 -2
- package/package.json +12 -3
- package/lib/utils/version-migrations/common.d.ts +0 -5
- package/lib/utils/version-migrations/common.d.ts.map +0 -1
- package/lib/utils/version-migrations/common.js +0 -29
- package/lib/utils/version-migrations/version4.d.ts +0 -3
- package/lib/utils/version-migrations/version4.d.ts.map +0 -1
- package/lib/utils/version-migrations/version4.js +0 -199
package/lib/types/basic/app.d.ts
CHANGED
|
@@ -1,73 +1,73 @@
|
|
|
1
|
-
import { IListener, IResource } from './common';
|
|
2
|
-
import { IDataSource } from './datasource';
|
|
3
|
-
import { IComponent } from './component';
|
|
4
|
-
export interface IApp {
|
|
5
|
-
/**
|
|
6
|
-
* 必填, 应用名称, 标识
|
|
7
|
-
* @maxLength 214
|
|
8
|
-
* @minLength 1
|
|
9
|
-
* @pattern ^(?:\x40[a-z0-9-*~][a-z0-9-*._~]*\x47)?[a-z0-9-~][a-z0-9-._~]*$
|
|
10
|
-
*/
|
|
11
|
-
name?: string;
|
|
12
|
-
/**
|
|
13
|
-
* 选填, 应用别名
|
|
14
|
-
*/
|
|
15
|
-
label?: string;
|
|
16
|
-
/**
|
|
17
|
-
* 选填, 应用版本
|
|
18
|
-
* version 值应该能够被 node-semver 解析
|
|
19
|
-
*
|
|
20
|
-
* @default 0.1.0
|
|
21
|
-
*/
|
|
22
|
-
version?: string;
|
|
23
|
-
/**
|
|
24
|
-
* 协议版本 semer version
|
|
25
|
-
* x.x.x | latest
|
|
26
|
-
*/
|
|
27
|
-
schemaVersion?: string;
|
|
28
|
-
/**
|
|
29
|
-
* 选填, 应用简介
|
|
30
|
-
*/
|
|
31
|
-
description?: string;
|
|
32
|
-
/**
|
|
33
|
-
* 选填, 应用的入口组件
|
|
34
|
-
*
|
|
35
|
-
* @default home
|
|
36
|
-
*/
|
|
37
|
-
main?: string;
|
|
38
|
-
/**
|
|
39
|
-
* 选填, 应用的作者
|
|
40
|
-
*/
|
|
41
|
-
author?: string;
|
|
42
|
-
/**
|
|
43
|
-
* 可选, 应用的控制属性
|
|
44
|
-
*/
|
|
45
|
-
attributes?: Record<string, any>;
|
|
46
|
-
/**
|
|
47
|
-
* 可选, 应用事件信息
|
|
48
|
-
*/
|
|
49
|
-
events?: any;
|
|
50
|
-
/**
|
|
51
|
-
* 必填, 应用的组件集合
|
|
52
|
-
*/
|
|
53
|
-
items: IComponent[];
|
|
54
|
-
/**
|
|
55
|
-
* 可选, 数据源集合
|
|
56
|
-
*/
|
|
57
|
-
dataSources?: IDataSource[];
|
|
58
|
-
/**
|
|
59
|
-
* 可选, 应用的资源集合
|
|
60
|
-
*
|
|
61
|
-
* 例如, 代码片段、组件库、静态资源
|
|
62
|
-
*/
|
|
63
|
-
resources?: IResource[];
|
|
64
|
-
/**
|
|
65
|
-
* 可选, 应用绑定的监听器
|
|
66
|
-
*/
|
|
67
|
-
listeners?: IListener[];
|
|
68
|
-
/**
|
|
69
|
-
* 可选, 扩展字段, 尽量避免用
|
|
70
|
-
*/
|
|
71
|
-
extra?: any;
|
|
72
|
-
}
|
|
1
|
+
import { IListener, IResource } from './common';
|
|
2
|
+
import { IDataSource } from './datasource';
|
|
3
|
+
import { IComponent } from './component';
|
|
4
|
+
export interface IApp {
|
|
5
|
+
/**
|
|
6
|
+
* 必填, 应用名称, 标识
|
|
7
|
+
* @maxLength 214
|
|
8
|
+
* @minLength 1
|
|
9
|
+
* @pattern ^(?:\x40[a-z0-9-*~][a-z0-9-*._~]*\x47)?[a-z0-9-~][a-z0-9-._~]*$
|
|
10
|
+
*/
|
|
11
|
+
name?: string;
|
|
12
|
+
/**
|
|
13
|
+
* 选填, 应用别名
|
|
14
|
+
*/
|
|
15
|
+
label?: string;
|
|
16
|
+
/**
|
|
17
|
+
* 选填, 应用版本
|
|
18
|
+
* version 值应该能够被 node-semver 解析
|
|
19
|
+
*
|
|
20
|
+
* @default 0.1.0
|
|
21
|
+
*/
|
|
22
|
+
version?: string;
|
|
23
|
+
/**
|
|
24
|
+
* 协议版本 semer version
|
|
25
|
+
* x.x.x | latest
|
|
26
|
+
*/
|
|
27
|
+
schemaVersion?: string;
|
|
28
|
+
/**
|
|
29
|
+
* 选填, 应用简介
|
|
30
|
+
*/
|
|
31
|
+
description?: string;
|
|
32
|
+
/**
|
|
33
|
+
* 选填, 应用的入口组件
|
|
34
|
+
*
|
|
35
|
+
* @default home
|
|
36
|
+
*/
|
|
37
|
+
main?: string;
|
|
38
|
+
/**
|
|
39
|
+
* 选填, 应用的作者
|
|
40
|
+
*/
|
|
41
|
+
author?: string;
|
|
42
|
+
/**
|
|
43
|
+
* 可选, 应用的控制属性
|
|
44
|
+
*/
|
|
45
|
+
attributes?: Record<string, any>;
|
|
46
|
+
/**
|
|
47
|
+
* 可选, 应用事件信息
|
|
48
|
+
*/
|
|
49
|
+
events?: any;
|
|
50
|
+
/**
|
|
51
|
+
* 必填, 应用的组件集合
|
|
52
|
+
*/
|
|
53
|
+
items: IComponent[];
|
|
54
|
+
/**
|
|
55
|
+
* 可选, 数据源集合
|
|
56
|
+
*/
|
|
57
|
+
dataSources?: IDataSource[];
|
|
58
|
+
/**
|
|
59
|
+
* 可选, 应用的资源集合
|
|
60
|
+
*
|
|
61
|
+
* 例如, 代码片段、组件库、静态资源
|
|
62
|
+
*/
|
|
63
|
+
resources?: IResource[];
|
|
64
|
+
/**
|
|
65
|
+
* 可选, 应用绑定的监听器
|
|
66
|
+
*/
|
|
67
|
+
listeners?: IListener[];
|
|
68
|
+
/**
|
|
69
|
+
* 可选, 扩展字段, 尽量避免用
|
|
70
|
+
*/
|
|
71
|
+
extra?: any;
|
|
72
|
+
}
|
|
73
73
|
//# sourceMappingURL=app.d.ts.map
|
|
@@ -1,89 +1,89 @@
|
|
|
1
|
-
export interface IResource extends Record<string, any> {
|
|
2
|
-
/**
|
|
3
|
-
* 必填,资源名
|
|
4
|
-
*/
|
|
5
|
-
name: string;
|
|
6
|
-
/**
|
|
7
|
-
* 必填,资源类型
|
|
8
|
-
*/
|
|
9
|
-
type: string;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* 应用/组件 绑定的监听器
|
|
13
|
-
*/
|
|
14
|
-
export interface IListener {
|
|
15
|
-
/**
|
|
16
|
-
* 可选,listener id
|
|
17
|
-
*/
|
|
18
|
-
id?: string;
|
|
19
|
-
/**
|
|
20
|
-
* 可选,是否在捕获阶段响应
|
|
21
|
-
* @default false
|
|
22
|
-
*/
|
|
23
|
-
isCapturePhase?: boolean;
|
|
24
|
-
/**
|
|
25
|
-
* 可选, 监听器类型
|
|
26
|
-
*/
|
|
27
|
-
type?: string;
|
|
28
|
-
/**
|
|
29
|
-
* 可选, 绑定的处理器
|
|
30
|
-
*/
|
|
31
|
-
handler?: IHandler;
|
|
32
|
-
/**
|
|
33
|
-
* 必填, 监听的事件名, 来源于 IEvents 定义的事件
|
|
34
|
-
*/
|
|
35
|
-
eventName: string;
|
|
36
|
-
}
|
|
37
|
-
/**
|
|
38
|
-
* 监听器触发的处理器
|
|
39
|
-
*/
|
|
40
|
-
export interface IHandler {
|
|
41
|
-
/**
|
|
42
|
-
* 必填, 处理器的名称
|
|
43
|
-
*/
|
|
44
|
-
name: string;
|
|
45
|
-
/**
|
|
46
|
-
* 可选, 处理器所属的模块
|
|
47
|
-
*/
|
|
48
|
-
module?: string;
|
|
49
|
-
/**
|
|
50
|
-
* 可选, 处理器的入参
|
|
51
|
-
*/
|
|
52
|
-
params?: object;
|
|
53
|
-
}
|
|
54
|
-
/** 变量 */
|
|
55
|
-
export interface IDataset {
|
|
56
|
-
/** 状态 */
|
|
57
|
-
state?: Record<string, IStateVariable | any>;
|
|
58
|
-
/** 页面/应用 参数 */
|
|
59
|
-
params?: Record<string, IParamsVariable>;
|
|
60
|
-
/**
|
|
61
|
-
* 可选,页面配置名称
|
|
62
|
-
* @deprecated 请使用页面 attributes.title 代替
|
|
63
|
-
*/
|
|
64
|
-
pageName?: string;
|
|
65
|
-
}
|
|
66
|
-
export interface IStateVariable {
|
|
67
|
-
/** 中文名 */
|
|
68
|
-
label?: string;
|
|
69
|
-
/** 变量类型 */
|
|
70
|
-
varType: 'state';
|
|
71
|
-
/**
|
|
72
|
-
* 原始数据类型
|
|
73
|
-
* string, number, object, array, boolean
|
|
74
|
-
*/
|
|
75
|
-
dataType: string;
|
|
76
|
-
/** 初始值 */
|
|
77
|
-
initialValue: any;
|
|
78
|
-
}
|
|
79
|
-
/** 页面参数定义 */
|
|
80
|
-
export interface IParamsVariable {
|
|
81
|
-
/** 中文名 */
|
|
82
|
-
label: string;
|
|
83
|
-
/** 是否必填, 默认 false */
|
|
84
|
-
required?: boolean;
|
|
85
|
-
/** 无需类型, 默认数据类型均为 string */
|
|
86
|
-
/** 示例值, ide 开发时使用 */
|
|
87
|
-
sampleValue?: string;
|
|
88
|
-
}
|
|
1
|
+
export interface IResource extends Record<string, any> {
|
|
2
|
+
/**
|
|
3
|
+
* 必填,资源名
|
|
4
|
+
*/
|
|
5
|
+
name: string;
|
|
6
|
+
/**
|
|
7
|
+
* 必填,资源类型
|
|
8
|
+
*/
|
|
9
|
+
type: string;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* 应用/组件 绑定的监听器
|
|
13
|
+
*/
|
|
14
|
+
export interface IListener {
|
|
15
|
+
/**
|
|
16
|
+
* 可选,listener id
|
|
17
|
+
*/
|
|
18
|
+
id?: string;
|
|
19
|
+
/**
|
|
20
|
+
* 可选,是否在捕获阶段响应
|
|
21
|
+
* @default false
|
|
22
|
+
*/
|
|
23
|
+
isCapturePhase?: boolean;
|
|
24
|
+
/**
|
|
25
|
+
* 可选, 监听器类型
|
|
26
|
+
*/
|
|
27
|
+
type?: string;
|
|
28
|
+
/**
|
|
29
|
+
* 可选, 绑定的处理器
|
|
30
|
+
*/
|
|
31
|
+
handler?: IHandler;
|
|
32
|
+
/**
|
|
33
|
+
* 必填, 监听的事件名, 来源于 IEvents 定义的事件
|
|
34
|
+
*/
|
|
35
|
+
eventName: string;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* 监听器触发的处理器
|
|
39
|
+
*/
|
|
40
|
+
export interface IHandler {
|
|
41
|
+
/**
|
|
42
|
+
* 必填, 处理器的名称
|
|
43
|
+
*/
|
|
44
|
+
name: string;
|
|
45
|
+
/**
|
|
46
|
+
* 可选, 处理器所属的模块
|
|
47
|
+
*/
|
|
48
|
+
module?: string;
|
|
49
|
+
/**
|
|
50
|
+
* 可选, 处理器的入参
|
|
51
|
+
*/
|
|
52
|
+
params?: object;
|
|
53
|
+
}
|
|
54
|
+
/** 变量 */
|
|
55
|
+
export interface IDataset {
|
|
56
|
+
/** 状态 */
|
|
57
|
+
state?: Record<string, IStateVariable | any>;
|
|
58
|
+
/** 页面/应用 参数 */
|
|
59
|
+
params?: Record<string, IParamsVariable>;
|
|
60
|
+
/**
|
|
61
|
+
* 可选,页面配置名称
|
|
62
|
+
* @deprecated 请使用页面 attributes.title 代替
|
|
63
|
+
*/
|
|
64
|
+
pageName?: string;
|
|
65
|
+
}
|
|
66
|
+
export interface IStateVariable {
|
|
67
|
+
/** 中文名 */
|
|
68
|
+
label?: string;
|
|
69
|
+
/** 变量类型 */
|
|
70
|
+
varType: 'state';
|
|
71
|
+
/**
|
|
72
|
+
* 原始数据类型
|
|
73
|
+
* string, number, object, array, boolean
|
|
74
|
+
*/
|
|
75
|
+
dataType: string;
|
|
76
|
+
/** 初始值 */
|
|
77
|
+
initialValue: any;
|
|
78
|
+
}
|
|
79
|
+
/** 页面参数定义 */
|
|
80
|
+
export interface IParamsVariable {
|
|
81
|
+
/** 中文名 */
|
|
82
|
+
label: string;
|
|
83
|
+
/** 是否必填, 默认 false */
|
|
84
|
+
required?: boolean;
|
|
85
|
+
/** 无需类型, 默认数据类型均为 string */
|
|
86
|
+
/** 示例值, ide 开发时使用 */
|
|
87
|
+
sampleValue?: string;
|
|
88
|
+
}
|
|
89
89
|
//# sourceMappingURL=common.d.ts.map
|