This is an automated email from the ASF dual-hosted git repository. ovilia pushed a commit to branch gauge in repository https://gitbox.apache.org/repos/asf/echarts-doc.git
commit c1748bb4ee3cbc6f67055d081e2a12a75d0ef929 Author: Ovilia <zwl.s...@gmail.com> AuthorDate: Thu Sep 22 15:38:56 2022 +0800 doc(gauge): axisLabel support rotate apache/echarts#16985 --- en/option/partial/label-rotate-tangential.md | 9 +++++++++ en/option/series/gauge.md | 4 ++++ en/option/series/sunburst.md | 19 +++---------------- zh/option/partial/label-rotate-tangential.md | 9 +++++++++ zh/option/series/gauge.md | 4 ++++ zh/option/series/sunburst.md | 17 +++-------------- 6 files changed, 32 insertions(+), 30 deletions(-) diff --git a/en/option/partial/label-rotate-tangential.md b/en/option/partial/label-rotate-tangential.md new file mode 100644 index 00000000..b0a29d3a --- /dev/null +++ b/en/option/partial/label-rotate-tangential.md @@ -0,0 +1,9 @@ +{{ target: partial-label-rotate-tangential }} + +#${prefix} rotate(string|number) = 'radial' + +If it is `number` type, then is stands for rotation, from -90 degrees to 90 degrees, and positive values stand for counterclockwise. + +Besides, it can be string `'radial'`, standing for radial rotation; or `'tangential'`, standing for tangential rotation. + +By default, it is `'radial'`. If no rotation is wanted, it can be set to `0`. diff --git a/en/option/series/gauge.md b/en/option/series/gauge.md index 0a0c1889..faa9fbdb 100644 --- a/en/option/series/gauge.md +++ b/en/option/series/gauge.md @@ -279,6 +279,10 @@ Whether to show the label. The distance between the label and tick line. +{{ use: partial-label-rotate-tangential( + prefix = '##' +) }} + ### formatter(string|Function) The content formatter of scale label, which supports both string template and callback function. diff --git a/en/option/series/sunburst.md b/en/option/series/sunburst.md index e4d73ecf..822404d5 100644 --- a/en/option/series/sunburst.md +++ b/en/option/series/sunburst.md @@ -1,26 +1,14 @@ {{ target: partial-sunburst-label-helper }} -#${prefix} rotate(string|number) = 'radial' - -<ExampleUIControlEnum options="radial,tangential" default="radial" /> - -{{ if: ${prefix} === '##' }} -If it is `number` type, then is stands for rotation, from -90 degrees to 90 degrees, and positive values stand for counterclockwise. - -Besides, it can be string `'radial'`, standing for radial rotation; or `'tangential'`, standing for tangential rotation. - -By default, it is `'radial'`. If no rotation is wanted, it can be set to `0`. +{{ use: partial-label-rotate-tangential( + prefix = ${prefix} +) }} The following example shows different `rotate` settings: ~[700x400](${galleryViewPath}sunburst-label-rotate&edit=1&reset=1) -Same to [label.rotate](~sunburst.label.rotate) -{{ else }} -Same to [label.rotate](~sunburst.label.rotate) -{{ /if }} - #${prefix} align(string) = 'center' <ExampleUIControlEnum options="left,center,right" default="center" /> @@ -413,4 +401,3 @@ Select state. defaultAnimationDuration = 1000, defaultAnimationDurationUpdate = 500 ) }} - diff --git a/zh/option/partial/label-rotate-tangential.md b/zh/option/partial/label-rotate-tangential.md new file mode 100644 index 00000000..3d245c24 --- /dev/null +++ b/zh/option/partial/label-rotate-tangential.md @@ -0,0 +1,9 @@ +{{ target: partial-label-rotate-tangential }} + +#${prefix} rotate(string|number) = 'radial' + +如果是 `number` 类型,则表示标签的旋转角,从 -90 度到 90 度,正值是逆时针。 + +除此之外,还可以是字符串 `'radial'` 表示径向旋转、`'tangential'` 表示切向旋转。 + +默认径向旋转,如果不需要文字旋转,可以将其设为 `0`。 diff --git a/zh/option/series/gauge.md b/zh/option/series/gauge.md index 6897d634..29622795 100644 --- a/zh/option/series/gauge.md +++ b/zh/option/series/gauge.md @@ -292,6 +292,10 @@ color: [ 标签与刻度线的距离。 +{{ use: partial-label-rotate-tangential( + prefix = '##' +) }} + ### formatter(string|Function) 刻度标签的内容格式器,支持字符串模板和回调函数两种形式。 diff --git a/zh/option/series/sunburst.md b/zh/option/series/sunburst.md index 3909a8b8..ab5d461e 100644 --- a/zh/option/series/sunburst.md +++ b/zh/option/series/sunburst.md @@ -1,23 +1,13 @@ {{ target: partial-sunburst-label-helper }} -#${prefix} rotate(string|number) = 'radial' - -<ExampleUIControlEnum options="radial,tangential" default="radial" /> - -{{ if: ${prefix} === '##' }} -如果是 `number` 类型,则表示标签的旋转角,从 -90 度到 90 度,正值是逆时针。 - -除此之外,还可以是字符串 `'radial'` 表示径向旋转、`'tangential'` 表示切向旋转。 - -默认径向旋转,如果不需要文字旋转,可以将其设为 `0`。 +{{ use: partial-label-rotate-tangential( + prefix = ${prefix} +) }} 下面的例子展示了不同的 `rotate` 设置方法: ~[700x400](${galleryViewPath}sunburst-label-rotate&edit=1&reset=1) -{{ else }} -同 [label.rotate](~sunburst.label.rotate) -{{ /if }} #${prefix} align(string) = 'center' @@ -560,4 +550,3 @@ series: { defaultAnimationDuration = 1000, defaultAnimationDurationUpdate = 500 ) }} - --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@echarts.apache.org For additional commands, e-mail: commits-h...@echarts.apache.org