forked from dancgray/adapt-chartjs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproperties.schema
executable file
·98 lines (98 loc) · 2.51 KB
/
properties.schema
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
{
"type": "object",
"$schema": "http://json-schema.org/draft-04/schema",
"id": "http://jsonschema.net",
"$ref": "http://localhost/plugins/content/component/model.schema",
"globals": {
"ariaRegion": {
"type": "string",
"required": true,
"default": "这是一个图表组件",
"inputType": "Text",
"validators": []
}
},
"properties": {
"_supportedLayout": {
"type": "string",
"required": true,
"enum": ["full-width", "half-width", "both"],
"default": "both",
"editorOnly": true
},
"instruction": {
"type": "string",
"required": false,
"default": "",
"title": "提示信息",
"inputType": "Text",
"validators": [],
"help": "请在这里输入提示帮助、介绍信息"
},
"_chartType": {
"type": "string",
"required": true,
"default": "line",
"title": "图表类型",
"enum": ["line", "bar", "horizontalBar", "radar", "polarArea", "pie", "doughnut"],
"inputType": {
"type": "Select",
"options": ["line", "bar", "horizontalBar", "radar", "polarArea", "pie", "doughnut"]
},
"validators": [],
"help": "请选择图表类型。"
},
"_width": {
"type": "number",
"required": true,
"default": 640,
"title": "图表宽度",
"inputType": "Number",
"validators": ["required", "number"],
"help": "图表宽度(单位:像素)"
},
"_height": {
"type": "number",
"required": true,
"default": 480,
"title": "图表高度",
"inputType": "Number",
"validators": ["required", "number"],
"help": "图表高度(单位:像素)"
},
"data": {
"type": "object",
"required": false,
"default": {},
"title": "数据",
"inputType": {
"type": "CodeEditor",
"mode": "json"
},
"validators": [],
"help": "请在这里输入图表数据"
},
"_options": {
"type": "object",
"required": false,
"default": {},
"title": "图表选项",
"inputType": {
"type": "CodeEditor",
"mode": "json"
},
"validators": [],
"help": "请在此输入其他图表设置,必须设置为Object"
},
"_dataSrc": {
"type": "string",
"required": false,
"default": "",
"title": "数据来源",
"inputType": "Text",
"validators": [],
"help": "请在此输入数据来源",
"translatable": true
}
}
}