Skip to content

Commit b33f108

Browse files
authored
Merge pull request #3809 from VisActor/docs/region-options
Docs/region options
2 parents 919fee1 + e4c36a8 commit b33f108

File tree

12 files changed

+183
-156
lines changed

12 files changed

+183
-156
lines changed

common/config/rush/pnpm-lock.yaml

+117-117
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/assets/option/en/common/layout-item.md

+7-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ The currently supported layout types are as follows:
1919

2020
Layout order level. The higher the level, the higher the priority for layout. For example, if both the title and the legend are at the top, the title should be placed at the top first, followed by the legend.
2121

22-
{{ if: !${noOrient} }}
22+
{{ if: !${noOrient} & !${isRegion} }}
2323
#${prefix} orient(string)
2424

2525
Module layout position. Available positions:
@@ -31,6 +31,7 @@ Module layout position. Available positions:
3131

3232
{{ /if }}
3333

34+
{{ if: !${isRegion} }}
3435
#${prefix} alignSelf('start' | 'end' | 'middle') = 'start'
3536

3637
Starting from version 1.8.9,
@@ -41,6 +42,7 @@ For elements with a layout type of 'normal-inline', set the alignment of inline
4142
- For elements at the bottom, 'start' - align to the bottom; 'end' - align to the top; 'middle' - align to the middle
4243
- For elements on the left, 'start' - align to the left; 'end' - align to the right; 'middle' - align to the middle
4344
- For elements on the right, 'start' - align to the right; 'end' - align to the left; 'middle' - align to the middle
45+
{{ if: !${isRegion} }}
4446

4547
#${prefix} padding(ILayoutNumber|Array|Object) = 0
4648

@@ -139,13 +141,15 @@ Offset for the module's layout position in the Y direction.
139141

140142
Display layer level for the module. When two modules overlap, the one with the larger level is displayed on top.
141143

142-
{{ if: !${noClip} }}
144+
{{ if: !${noClip} | ${isRegion} }}
143145
#${prefix} clip(boolean)
144146

145147
Whether to clip the drawing content outside the layout area of the module.
146148

147149
{{ /if }}
148150

151+
{{ if: !${isRegion} }}
152+
149153
#${prefix} left(ILayoutNumber)
150154

151155
Distance from the module to the left side of the chart in absolute layout. Note that **this is only effective when layoutType === 'absolute'**.
@@ -173,3 +177,4 @@ Distance from the module to the bottom side of the chart in absolute layout. Not
173177
#${prefix} center(boolean)
174178

175179
In absolute layout, the element will be placed in the center of the chart. Note that **this is only effective when layoutType === 'absolute', and the padding property will be ignored**.
180+
{{ /if }}

docs/assets/option/en/common/region.md

+8
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,11 @@ Supported since `1.4.0` version, Whether to reverse the order when stacking
100100
### stackSort(boolean)
101101

102102
Supported since `1.10.4` version, Whether to sorting data when stacking
103+
104+
{{ use: common-layout-item(
105+
prefix = '##',
106+
defaultLayoutType = 'region',
107+
defaultLayoutLevel = 10,
108+
defaultLayoutZIndex = 450,
109+
isRegion = true,
110+
) }}

docs/assets/option/zh/common/layout-item.md

+8-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919

2020
布局顺序等级,等级越大的,越优先布局,比如顶部同时有标题和图例的场景,期望标题先放在顶部,然后放置图例。
2121

22-
{{ if: !${noOrient} }}
22+
{{ if: !${noOrient} & !${isRegion} }}
2323
#${prefix} orient(string)
2424

2525
模块布局位置。可选位置:
@@ -31,6 +31,8 @@
3131

3232
{{ /if }}
3333

34+
{{ if: !${isRegion} }}
35+
3436
#${prefix} alignSelf('start' | 'end' | 'middle') = 'start'
3537

3638
从 1.8.9 版本开始支持,
@@ -42,6 +44,8 @@
4244
- 左侧的元素,'start' - 左侧对齐;'end' - '右侧对齐'; 'middle' - 居中对齐
4345
- 右侧的元素,'start' - 右侧对齐;'end' - '左侧对齐'; 'middle' - 居中对齐
4446

47+
{{ /if }}
48+
4549
#${prefix} padding(ILayoutNumber|Array|Object) = 0
4650

4751
模块的布局间距配置(上下左右四个方向),支持非对象配置、数组配置与对象配置。
@@ -139,13 +143,14 @@ padding: {
139143

140144
模块的展示层级,当 2 个模块重叠时,层级较大的展示在上方。
141145

142-
{{ if: !${noClip} }}
146+
{{ if: !${noClip} | ${isRegion} }}
143147
#${prefix} clip(boolean)
144148

145149
模块是否裁剪超出布局区域外的绘图内容 。
146150

147151
{{/if}}
148152

153+
{{ if: !${isRegion} }}
149154
#${prefix} left(ILayoutNumber)
150155

151156
模块绝对布局下,与图表左侧的距离。注意**仅在 layoutType === 'absolute' 时生效**
@@ -173,3 +178,4 @@ padding: {
173178
#${prefix} center(boolean)
174179

175180
模块绝对布局下,元素将放置在图表的正中间。注意**仅在 layoutType === 'absolute' 时生效,同时将忽略 padding 属性**
181+
{{/if}}

docs/assets/option/zh/common/region.md

+8
Original file line numberDiff line numberDiff line change
@@ -100,3 +100,11 @@ region 的 id,可以在其他功能模块中使用这个 id 来索引这个 re
100100
### stackSort(boolean)
101101

102102
`1.10.4` 版本开始支持,是否在堆积时对数据排序。
103+
104+
{{ use: common-layout-item(
105+
prefix = '##',
106+
defaultLayoutType = 'region',
107+
defaultLayoutLevel = 10,
108+
defaultLayoutZIndex = 450,
109+
isRegion = true,
110+
) }}

docs/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@
1919
"@visactor/vchart-theme": "~1.6.6",
2020
"@visactor/vmind": "1.2.4-alpha.5",
2121
"@visactor/vutils": "~0.19.4",
22-
"@visactor/vrender": "0.22.4",
23-
"@visactor/vrender-kits": "0.22.4",
24-
"@visactor/vgrammar": "0.16.0",
22+
"@visactor/vrender": "0.22.5",
23+
"@visactor/vrender-kits": "0.22.5",
24+
"@visactor/vgrammar": "0.16.1",
2525
"@visactor/vtable": "1.12.0",
2626
"@visactor/vtable-editors": "1.12.0",
2727
"@visactor/vtable-gantt": "1.12.0",
@@ -59,4 +59,4 @@
5959
"react-device-detect": "^2.2.2",
6060
"minimist": "1.2.8"
6161
}
62-
}
62+
}

packages/openinula-vchart/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
"dependencies": {
3131
"@visactor/vchart": "workspace:1.13.6",
3232
"@visactor/vutils": "~0.19.4",
33-
"@visactor/vrender-core": "0.22.4",
34-
"@visactor/vrender-kits": "0.22.4",
35-
"@visactor/vgrammar-core": "0.16.0",
33+
"@visactor/vrender-core": "0.22.5",
34+
"@visactor/vrender-kits": "0.22.5",
35+
"@visactor/vgrammar-core": "0.16.1",
3636
"react-is": "^18.2.0"
3737
},
3838
"devDependencies": {
@@ -79,4 +79,4 @@
7979
"access": "public",
8080
"registry": "https://registry.npmjs.org/"
8181
}
82-
}
82+
}

packages/react-vchart/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,9 @@
3030
"dependencies": {
3131
"@visactor/vchart": "workspace:1.13.6",
3232
"@visactor/vutils": "~0.19.4",
33-
"@visactor/vrender-core": "0.22.4",
34-
"@visactor/vrender-kits": "0.22.4",
35-
"@visactor/vgrammar-core": "0.16.0",
33+
"@visactor/vrender-core": "0.22.5",
34+
"@visactor/vrender-kits": "0.22.5",
35+
"@visactor/vgrammar-core": "0.16.1",
3636
"react-is": "^18.2.0"
3737
},
3838
"devDependencies": {
@@ -83,4 +83,4 @@
8383
"access": "public",
8484
"registry": "https://registry.npmjs.org/"
8585
}
86-
}
86+
}

packages/vchart-extension/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,10 @@
2121
"start": "ts-node __tests__/runtime/browser/scripts/initVite.ts && vite serve __tests__/runtime/browser"
2222
},
2323
"dependencies": {
24-
"@visactor/vrender-core": "0.22.4",
25-
"@visactor/vrender-kits": "0.22.4",
26-
"@visactor/vrender-components": "0.22.4",
27-
"@visactor/vgrammar-core": "0.16.0",
24+
"@visactor/vrender-core": "0.22.5",
25+
"@visactor/vrender-kits": "0.22.5",
26+
"@visactor/vrender-components": "0.22.5",
27+
"@visactor/vgrammar-core": "0.16.1",
2828
"@visactor/vutils": "~0.19.4",
2929
"@visactor/vdataset": "~0.19.4",
3030
"@visactor/vchart": "workspace:1.13.6"

packages/vchart/package.json

+12-12
Original file line numberDiff line numberDiff line change
@@ -121,21 +121,21 @@
121121
"@visactor/vutils": "~0.19.4",
122122
"@visactor/vdataset": "~0.19.4",
123123
"@visactor/vscale": "~0.19.4",
124-
"@visactor/vrender-core": "0.22.4",
125-
"@visactor/vrender-kits": "0.22.4",
126-
"@visactor/vrender-components": "0.22.4",
127-
"@visactor/vgrammar-core": "0.16.0",
128-
"@visactor/vgrammar-projection": "0.16.0",
129-
"@visactor/vgrammar-wordcloud": "0.16.0",
130-
"@visactor/vgrammar-wordcloud-shape": "0.16.0",
131-
"@visactor/vgrammar-hierarchy": "0.16.0",
132-
"@visactor/vgrammar-sankey": "0.16.0",
133-
"@visactor/vgrammar-venn": "0.16.0",
134-
"@visactor/vgrammar-util": "0.16.0",
124+
"@visactor/vrender-core": "0.22.5",
125+
"@visactor/vrender-kits": "0.22.5",
126+
"@visactor/vrender-components": "0.22.5",
127+
"@visactor/vgrammar-core": "0.16.1",
128+
"@visactor/vgrammar-projection": "0.16.1",
129+
"@visactor/vgrammar-wordcloud": "0.16.1",
130+
"@visactor/vgrammar-wordcloud-shape": "0.16.1",
131+
"@visactor/vgrammar-hierarchy": "0.16.1",
132+
"@visactor/vgrammar-sankey": "0.16.1",
133+
"@visactor/vgrammar-venn": "0.16.1",
134+
"@visactor/vgrammar-util": "0.16.1",
135135
"@visactor/vutils-extension": "workspace:1.13.6"
136136
},
137137
"publishConfig": {
138138
"access": "public",
139139
"registry": "https://registry.npmjs.org/"
140140
}
141-
}
141+
}

packages/vstory/package.json

+3-3
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,9 @@
2121
},
2222
"dependencies": {
2323
"@visactor/vchart": "workspace:1.11.0",
24-
"@visactor/vrender-core": "0.22.4",
25-
"@visactor/vrender-kits": "0.22.4",
26-
"@visactor/vrender-components": "0.22.4",
24+
"@visactor/vrender-core": "0.22.5",
25+
"@visactor/vrender-kits": "0.22.5",
26+
"@visactor/vrender-components": "0.22.5",
2727
"@visactor/vutils": "~0.19.4"
2828
},
2929
"devDependencies": {

tools/story-player/package.json

+4-4
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,10 @@
5656
"vite": "3.2.6"
5757
},
5858
"dependencies": {
59-
"@visactor/vrender-core": "0.22.4",
60-
"@visactor/vrender-kits": "0.22.4",
59+
"@visactor/vrender-core": "0.22.5",
60+
"@visactor/vrender-kits": "0.22.5",
6161
"@visactor/vchart": "workspace:1.13.6",
62-
"@visactor/vrender": "0.22.4",
62+
"@visactor/vrender": "0.22.5",
6363
"@visactor/vutils": "~0.19.4"
6464
}
65-
}
65+
}

0 commit comments

Comments
 (0)