@next-bricks/data-view 1.9.2 → 1.10.0
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/dist/bricks.json +9 -5
- package/dist/chunks/2785.3bc16dc7.js +1 -0
- package/dist/chunks/5235.ad56bd82.js +2 -0
- package/dist/chunks/5235.ad56bd82.js.map +1 -0
- package/dist/chunks/8763.298c81f7.js +1 -0
- package/dist/chunks/8826.2d0820ed.js +2 -0
- package/dist/chunks/8826.2d0820ed.js.map +1 -0
- package/dist/chunks/china-map-chart.52890013.js +2 -0
- package/dist/chunks/china-map-chart.52890013.js.map +1 -0
- package/dist/chunks/china-map.c8780d37.js +2 -0
- package/dist/chunks/china-map.c8780d37.js.map +1 -0
- package/dist/chunks/main.e8031b63.js +2 -0
- package/dist/chunks/main.e8031b63.js.map +1 -0
- package/dist/examples.json +12 -9
- package/dist/index.38a026f6.js +2 -0
- package/dist/index.38a026f6.js.map +1 -0
- package/dist/manifest.json +122 -95
- package/dist/types.json +183 -104
- package/dist-types/bootstrap.d.ts +1 -0
- package/dist-types/china-map/index.d.ts +37 -0
- package/dist-types/china-map/index.spec.d.ts +1 -0
- package/docs/china-map.md +58 -0
- package/package.json +2 -2
- package/dist/chunks/32.40f02922.js +0 -2
- package/dist/chunks/32.40f02922.js.map +0 -1
- package/dist/chunks/china-map-chart.331f7837.js +0 -2
- package/dist/chunks/china-map-chart.331f7837.js.map +0 -1
- package/dist/chunks/main.2de8b5d7.js +0 -2
- package/dist/chunks/main.2de8b5d7.js.map +0 -1
- package/dist/index.863009f8.js +0 -2
- package/dist/index.863009f8.js.map +0 -1
package/dist/types.json
CHANGED
|
@@ -40,6 +40,110 @@
|
|
|
40
40
|
"events": [],
|
|
41
41
|
"methods": []
|
|
42
42
|
},
|
|
43
|
+
"data-view.modern-style-component-title": {
|
|
44
|
+
"properties": [
|
|
45
|
+
{
|
|
46
|
+
"name": "hideLeftComponent",
|
|
47
|
+
"annotation": {
|
|
48
|
+
"type": "keyword",
|
|
49
|
+
"value": "boolean"
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
"name": "hideRightComponent",
|
|
54
|
+
"annotation": {
|
|
55
|
+
"type": "keyword",
|
|
56
|
+
"value": "boolean"
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"name": "componentTitle",
|
|
61
|
+
"annotation": {
|
|
62
|
+
"type": "keyword",
|
|
63
|
+
"value": "string"
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"name": "titleTextStyle",
|
|
68
|
+
"annotation": {
|
|
69
|
+
"type": "reference",
|
|
70
|
+
"typeName": {
|
|
71
|
+
"type": "identifier",
|
|
72
|
+
"name": "CSSProperties"
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
"name": "squareColor",
|
|
78
|
+
"annotation": {
|
|
79
|
+
"type": "indexedAccess",
|
|
80
|
+
"objectType": {
|
|
81
|
+
"type": "reference",
|
|
82
|
+
"typeName": {
|
|
83
|
+
"type": "identifier",
|
|
84
|
+
"name": "CSSProperties"
|
|
85
|
+
}
|
|
86
|
+
},
|
|
87
|
+
"indexType": {
|
|
88
|
+
"type": "jsLiteral",
|
|
89
|
+
"value": "color"
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
],
|
|
94
|
+
"events": [],
|
|
95
|
+
"methods": []
|
|
96
|
+
},
|
|
97
|
+
"data-view.modern-style-page-title": {
|
|
98
|
+
"properties": [
|
|
99
|
+
{
|
|
100
|
+
"name": "pageTitle",
|
|
101
|
+
"annotation": {
|
|
102
|
+
"type": "keyword",
|
|
103
|
+
"value": "string"
|
|
104
|
+
}
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
"name": "description",
|
|
108
|
+
"annotation": {
|
|
109
|
+
"type": "keyword",
|
|
110
|
+
"value": "string"
|
|
111
|
+
}
|
|
112
|
+
},
|
|
113
|
+
{
|
|
114
|
+
"name": "backgroundStyle",
|
|
115
|
+
"annotation": {
|
|
116
|
+
"type": "reference",
|
|
117
|
+
"typeName": {
|
|
118
|
+
"type": "identifier",
|
|
119
|
+
"name": "CSSProperties"
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
},
|
|
123
|
+
{
|
|
124
|
+
"name": "leftRoundStyle",
|
|
125
|
+
"annotation": {
|
|
126
|
+
"type": "reference",
|
|
127
|
+
"typeName": {
|
|
128
|
+
"type": "identifier",
|
|
129
|
+
"name": "CSSProperties"
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
{
|
|
134
|
+
"name": "rightRoundStyle",
|
|
135
|
+
"annotation": {
|
|
136
|
+
"type": "reference",
|
|
137
|
+
"typeName": {
|
|
138
|
+
"type": "identifier",
|
|
139
|
+
"name": "CSSProperties"
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
],
|
|
144
|
+
"events": [],
|
|
145
|
+
"methods": []
|
|
146
|
+
},
|
|
43
147
|
"data-view.tabs-drawer": {
|
|
44
148
|
"properties": [
|
|
45
149
|
{
|
|
@@ -832,60 +936,6 @@
|
|
|
832
936
|
"events": [],
|
|
833
937
|
"methods": []
|
|
834
938
|
},
|
|
835
|
-
"data-view.modern-style-component-title": {
|
|
836
|
-
"properties": [
|
|
837
|
-
{
|
|
838
|
-
"name": "hideLeftComponent",
|
|
839
|
-
"annotation": {
|
|
840
|
-
"type": "keyword",
|
|
841
|
-
"value": "boolean"
|
|
842
|
-
}
|
|
843
|
-
},
|
|
844
|
-
{
|
|
845
|
-
"name": "hideRightComponent",
|
|
846
|
-
"annotation": {
|
|
847
|
-
"type": "keyword",
|
|
848
|
-
"value": "boolean"
|
|
849
|
-
}
|
|
850
|
-
},
|
|
851
|
-
{
|
|
852
|
-
"name": "componentTitle",
|
|
853
|
-
"annotation": {
|
|
854
|
-
"type": "keyword",
|
|
855
|
-
"value": "string"
|
|
856
|
-
}
|
|
857
|
-
},
|
|
858
|
-
{
|
|
859
|
-
"name": "titleTextStyle",
|
|
860
|
-
"annotation": {
|
|
861
|
-
"type": "reference",
|
|
862
|
-
"typeName": {
|
|
863
|
-
"type": "identifier",
|
|
864
|
-
"name": "CSSProperties"
|
|
865
|
-
}
|
|
866
|
-
}
|
|
867
|
-
},
|
|
868
|
-
{
|
|
869
|
-
"name": "squareColor",
|
|
870
|
-
"annotation": {
|
|
871
|
-
"type": "indexedAccess",
|
|
872
|
-
"objectType": {
|
|
873
|
-
"type": "reference",
|
|
874
|
-
"typeName": {
|
|
875
|
-
"type": "identifier",
|
|
876
|
-
"name": "CSSProperties"
|
|
877
|
-
}
|
|
878
|
-
},
|
|
879
|
-
"indexType": {
|
|
880
|
-
"type": "jsLiteral",
|
|
881
|
-
"value": "color"
|
|
882
|
-
}
|
|
883
|
-
}
|
|
884
|
-
}
|
|
885
|
-
],
|
|
886
|
-
"events": [],
|
|
887
|
-
"methods": []
|
|
888
|
-
},
|
|
889
939
|
"data-view.cabinet-app-layer": {
|
|
890
940
|
"properties": [
|
|
891
941
|
{
|
|
@@ -915,56 +965,6 @@
|
|
|
915
965
|
"events": [],
|
|
916
966
|
"methods": []
|
|
917
967
|
},
|
|
918
|
-
"data-view.modern-style-page-title": {
|
|
919
|
-
"properties": [
|
|
920
|
-
{
|
|
921
|
-
"name": "pageTitle",
|
|
922
|
-
"annotation": {
|
|
923
|
-
"type": "keyword",
|
|
924
|
-
"value": "string"
|
|
925
|
-
}
|
|
926
|
-
},
|
|
927
|
-
{
|
|
928
|
-
"name": "description",
|
|
929
|
-
"annotation": {
|
|
930
|
-
"type": "keyword",
|
|
931
|
-
"value": "string"
|
|
932
|
-
}
|
|
933
|
-
},
|
|
934
|
-
{
|
|
935
|
-
"name": "backgroundStyle",
|
|
936
|
-
"annotation": {
|
|
937
|
-
"type": "reference",
|
|
938
|
-
"typeName": {
|
|
939
|
-
"type": "identifier",
|
|
940
|
-
"name": "CSSProperties"
|
|
941
|
-
}
|
|
942
|
-
}
|
|
943
|
-
},
|
|
944
|
-
{
|
|
945
|
-
"name": "leftRoundStyle",
|
|
946
|
-
"annotation": {
|
|
947
|
-
"type": "reference",
|
|
948
|
-
"typeName": {
|
|
949
|
-
"type": "identifier",
|
|
950
|
-
"name": "CSSProperties"
|
|
951
|
-
}
|
|
952
|
-
}
|
|
953
|
-
},
|
|
954
|
-
{
|
|
955
|
-
"name": "rightRoundStyle",
|
|
956
|
-
"annotation": {
|
|
957
|
-
"type": "reference",
|
|
958
|
-
"typeName": {
|
|
959
|
-
"type": "identifier",
|
|
960
|
-
"name": "CSSProperties"
|
|
961
|
-
}
|
|
962
|
-
}
|
|
963
|
-
}
|
|
964
|
-
],
|
|
965
|
-
"events": [],
|
|
966
|
-
"methods": []
|
|
967
|
-
},
|
|
968
968
|
"data-view.cabinet-graph": {
|
|
969
969
|
"properties": [
|
|
970
970
|
{
|
|
@@ -3353,6 +3353,85 @@
|
|
|
3353
3353
|
}
|
|
3354
3354
|
]
|
|
3355
3355
|
},
|
|
3356
|
+
"data-view.china-map": {
|
|
3357
|
+
"properties": [
|
|
3358
|
+
{
|
|
3359
|
+
"name": "province",
|
|
3360
|
+
"annotation": {
|
|
3361
|
+
"type": "keyword",
|
|
3362
|
+
"value": "string"
|
|
3363
|
+
}
|
|
3364
|
+
},
|
|
3365
|
+
{
|
|
3366
|
+
"name": "dataSource",
|
|
3367
|
+
"annotation": {
|
|
3368
|
+
"type": "array",
|
|
3369
|
+
"elementType": {
|
|
3370
|
+
"type": "reference",
|
|
3371
|
+
"typeName": {
|
|
3372
|
+
"type": "identifier",
|
|
3373
|
+
"name": "DataItem"
|
|
3374
|
+
}
|
|
3375
|
+
}
|
|
3376
|
+
}
|
|
3377
|
+
},
|
|
3378
|
+
{
|
|
3379
|
+
"name": "maxScale",
|
|
3380
|
+
"annotation": {
|
|
3381
|
+
"type": "keyword",
|
|
3382
|
+
"value": "number"
|
|
3383
|
+
}
|
|
3384
|
+
}
|
|
3385
|
+
],
|
|
3386
|
+
"events": [],
|
|
3387
|
+
"methods": [],
|
|
3388
|
+
"types": [
|
|
3389
|
+
{
|
|
3390
|
+
"type": "interface",
|
|
3391
|
+
"name": "DataItem",
|
|
3392
|
+
"body": [
|
|
3393
|
+
{
|
|
3394
|
+
"type": "propertySignature",
|
|
3395
|
+
"key": {
|
|
3396
|
+
"type": "identifier",
|
|
3397
|
+
"name": "province"
|
|
3398
|
+
},
|
|
3399
|
+
"annotation": {
|
|
3400
|
+
"type": "keyword",
|
|
3401
|
+
"value": "string"
|
|
3402
|
+
},
|
|
3403
|
+
"optional": true,
|
|
3404
|
+
"computed": false
|
|
3405
|
+
},
|
|
3406
|
+
{
|
|
3407
|
+
"type": "propertySignature",
|
|
3408
|
+
"key": {
|
|
3409
|
+
"type": "identifier",
|
|
3410
|
+
"name": "city"
|
|
3411
|
+
},
|
|
3412
|
+
"annotation": {
|
|
3413
|
+
"type": "keyword",
|
|
3414
|
+
"value": "string"
|
|
3415
|
+
},
|
|
3416
|
+
"optional": true,
|
|
3417
|
+
"computed": false
|
|
3418
|
+
},
|
|
3419
|
+
{
|
|
3420
|
+
"type": "propertySignature",
|
|
3421
|
+
"key": {
|
|
3422
|
+
"type": "identifier",
|
|
3423
|
+
"name": "text"
|
|
3424
|
+
},
|
|
3425
|
+
"annotation": {
|
|
3426
|
+
"type": "keyword",
|
|
3427
|
+
"value": "string"
|
|
3428
|
+
},
|
|
3429
|
+
"computed": false
|
|
3430
|
+
}
|
|
3431
|
+
]
|
|
3432
|
+
}
|
|
3433
|
+
]
|
|
3434
|
+
},
|
|
3356
3435
|
"data-view.modern-style-treemap": {
|
|
3357
3436
|
"properties": [
|
|
3358
3437
|
{
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { ReactNextElement } from "@next-core/react-element";
|
|
3
|
+
import "@next-core/theme";
|
|
4
|
+
export interface ChinaMapProps {
|
|
5
|
+
province?: string;
|
|
6
|
+
dataSource?: DataItem[];
|
|
7
|
+
maxScale?: number;
|
|
8
|
+
}
|
|
9
|
+
export interface DataItem {
|
|
10
|
+
province?: string;
|
|
11
|
+
city?: string;
|
|
12
|
+
text: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* 构件 `data-view.china-map`
|
|
16
|
+
*/
|
|
17
|
+
export declare class ChinaMap extends ReactNextElement implements ChinaMapProps {
|
|
18
|
+
/**
|
|
19
|
+
* 省份名称,例如“广东”。如果设置,则只显示该省份的地图,否则显示全国地图
|
|
20
|
+
*/
|
|
21
|
+
accessor province: string | undefined;
|
|
22
|
+
/**
|
|
23
|
+
* 数据源
|
|
24
|
+
*/
|
|
25
|
+
accessor dataSource: DataItem[] | undefined;
|
|
26
|
+
/**
|
|
27
|
+
* 最大缩放比例
|
|
28
|
+
*
|
|
29
|
+
* @default 1
|
|
30
|
+
*/
|
|
31
|
+
accessor maxScale: number | undefined;
|
|
32
|
+
render(): React.JSX.Element;
|
|
33
|
+
}
|
|
34
|
+
export interface ChinaMapComponentProps extends ChinaMapProps {
|
|
35
|
+
root: ChinaMap;
|
|
36
|
+
}
|
|
37
|
+
export declare function ChinaMapComponent({ root, province, dataSource, maxScale, }: ChinaMapComponentProps): React.JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "./";
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
构件 `data-view.china-map`
|
|
2
|
+
|
|
3
|
+
## Examples
|
|
4
|
+
|
|
5
|
+
### Basic
|
|
6
|
+
|
|
7
|
+
```yaml preview height="600px"
|
|
8
|
+
brick: div
|
|
9
|
+
properties:
|
|
10
|
+
style:
|
|
11
|
+
height: calc(100vh - 4em)
|
|
12
|
+
position: relative
|
|
13
|
+
children:
|
|
14
|
+
- brick: data-view.china-map
|
|
15
|
+
properties:
|
|
16
|
+
dataSource:
|
|
17
|
+
- text: "西藏 12311"
|
|
18
|
+
province: 西藏
|
|
19
|
+
- text: "四川 89781169"
|
|
20
|
+
province: 四川
|
|
21
|
+
- text: "台湾 234181"
|
|
22
|
+
province: 台湾
|
|
23
|
+
- text: "江西 21348"
|
|
24
|
+
province: 江西
|
|
25
|
+
# Currently this brick only looks well within dark theme
|
|
26
|
+
lifeCycle:
|
|
27
|
+
onPageLoad:
|
|
28
|
+
action: theme.setTheme
|
|
29
|
+
args:
|
|
30
|
+
- dark-v2
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Province map
|
|
34
|
+
|
|
35
|
+
```yaml preview height="600px"
|
|
36
|
+
brick: div
|
|
37
|
+
properties:
|
|
38
|
+
style:
|
|
39
|
+
height: calc(100vh - 4em)
|
|
40
|
+
position: relative
|
|
41
|
+
children:
|
|
42
|
+
- brick: data-view.china-map
|
|
43
|
+
properties:
|
|
44
|
+
province: 广东
|
|
45
|
+
dataSource:
|
|
46
|
+
- text: "广州 12311"
|
|
47
|
+
city: 广州
|
|
48
|
+
- text: "深圳 89781169"
|
|
49
|
+
city: 深圳
|
|
50
|
+
- text: "湛江 234181"
|
|
51
|
+
city: 湛江
|
|
52
|
+
# Currently this brick only looks well within dark theme
|
|
53
|
+
lifeCycle:
|
|
54
|
+
onPageLoad:
|
|
55
|
+
action: theme.setTheme
|
|
56
|
+
args:
|
|
57
|
+
- dark-v2
|
|
58
|
+
```
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@next-bricks/data-view",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.10.0",
|
|
4
4
|
"homepage": "https://github.com/easyops-cn/next-bricks/tree/master/bricks/data-view",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -42,5 +42,5 @@
|
|
|
42
42
|
"@next-bricks/basic": "*",
|
|
43
43
|
"@next-bricks/icons": "*"
|
|
44
44
|
},
|
|
45
|
-
"gitHead": "
|
|
45
|
+
"gitHead": "64c663cd8872e54863b21c87e758e39141c82ee5"
|
|
46
46
|
}
|