Skip to content

Commit

Permalink
add emphasis.disabled, select.disabled. selectedMode: series
Browse files Browse the repository at this point in the history
  • Loading branch information
pissang committed Jan 14, 2022
1 parent e19d251 commit 3b26614
Show file tree
Hide file tree
Showing 61 changed files with 904 additions and 16 deletions.
8 changes: 8 additions & 0 deletions en/option/component/geo-common.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,10 @@ Area filling color.

Map area style in highlighted state.

{{ use: partial-emphasis-disabled(
prefix = "#" + ${prefix}
) }}

{{ if: !${inMap} }}
{{ use: partial-focus-blur-scope(
isGeoCoordSys = true
Expand All @@ -194,6 +198,10 @@ Map area style in highlighted state.

Map area style in selected state.

{{ use: partial-select-disabled(
prefix = "#" + ${prefix}
) }}

{{ use: partial-geo-common-state(
prefix = '#' + ${prefix}
) }}
Expand Down
79 changes: 79 additions & 0 deletions en/option/partial/emphasis-common.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@

{{ target: partial-emphasis-disabled }}

#${prefix} disabled(boolean)

<ExampleUIControlBoolean default="false" />

Whether to disable the emphasis state.

When emphasis state is disabled. There will be no highlight effect when the mouse hovered the element, tooltip is triggered, or the legend is hovered. It can be used to improve interaction fluency when there are massive graphic elements.



{{ target: partial-focus-blur-scope }}

### focus(string) = 'none'

{{ if: ${isGeoCoordSys} }}
{{ use: partial-version(
version = "5.1.0"
) }}
{{ else }}
{{ use: partial-version(
version = "5.0.0"
) }}
{{ /if }}

When the data is highlighted, whether to fade out of other data to focus the highlighted. The following configurations are supported:

+ `'none'` Do not fade out other data, it's by default.
+ `'self'` Only focus (not fade out) the element of the currently highlighted data.

{{ if: !${isGeoCoordSys} }}
+ `'series'` Focus on all elements of the series which the currently highlighted data belongs to.
{{ /if }}

{{ if: ${isGraph} }}
+ `'adjacency'` Focus on the elements of adjacent nodes and edges in the graph.

{{ elif: ${isTree} }}
+ `'ancestor'` Focus on all ancestor nodes.
+ `'descendant'` Focus on all descendants nodes.
{{ /if }}

**Example: **

{{ if: !${isGeoCoordSys} }}
```js
emphasis: {
focus: 'series',
blurScope: 'coordinateSystem'
}
```

~[600x400](${galleryViewPath}bar-y-category-stack&reset=1&edit=1)
{{ else }}
```js
emphasis: {
focus: 'self'
}
```

~[600x400](${galleryViewPath}geo-organ&reset=1&edit=1)
{{ /if }}

{{ if: !${isGeoCoordSys} }}
### blurScope(string) = 'coordinateSystem'

{{ use: partial-version(
version = "5.0.0"
) }}

The range of fade out when `focus` is enabled. Support the following configurations

+ `'coordinateSystem'`
+ `'series'`
+ `'global'`
{{ /if }}

8 changes: 8 additions & 0 deletions en/option/partial/mark-area.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ Style of the mark area.

Emphasis status of mark area.

{{ use: partial-emphasis-disabled(
prefix = "##" + ${prefix}
) }}

###${prefix} label(Object)

{{ use: partial-label(
Expand Down Expand Up @@ -241,6 +245,10 @@ Label style of start point and end point will be merged together.

#${prefix} emphasis(Object)

{{ use: partial-emphasis-disabled(
prefix = "#" + ${prefix}
) }}

##${prefix} itemStyle(Object)

{{ use: partial-item-style(
Expand Down
8 changes: 8 additions & 0 deletions en/option/partial/mark-line.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ Mark line style.

Emphasis status of mark line.

{{ use: partial-emphasis-disabled(
prefix = "##" + ${prefix}
) }}

###${prefix} label(Object)

{{ use: mark-line-label(
Expand Down Expand Up @@ -339,6 +343,10 @@ Label of this data item, which will be merged with `label` of starting point and

#${prefix} emphasis(Object)

{{ use: partial-emphasis-disabled(
prefix = "#" + ${prefix}
) }}

##${prefix} lineStyle(Object)

{{ use: partial-line-style(
Expand Down
8 changes: 8 additions & 0 deletions en/option/partial/mark-point.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ Mark point style.

Emphasis status of mark point.

{{ use: partial-emphasis-disabled(
prefix = "##" + ${prefix}
) }}

###${prefix} label(Object)

{{ use: partial-label(
Expand Down Expand Up @@ -184,6 +188,10 @@ Mark point style.

###${prefix} emphasis(Object)

{{ use: partial-emphasis-disabled(
prefix = "###" + ${prefix}
) }}

####${prefix} label(Object)

{{ use: partial-label(
Expand Down
10 changes: 10 additions & 0 deletions en/option/partial/select-common.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

{{ target: partial-select-disabled }}

#${prefix} disabled(boolean)

<ExampleUIControlBoolean default="false" />

If data can be selected. Available when `selectedMode` is used. Can be used to disable selection for part of the data.


4 changes: 2 additions & 2 deletions en/option/partial/selected-mode.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
) }}
{{ /if }}

<ExampleUIControlEnum options="false,true,single,multiple" />
<ExampleUIControlEnum options="false,true,single,multiple,series" />

Selected mode. It is enabled by default, and you may set it to be `false` to disabled it.

Besides, it can be set to `'single'` or `'multiple'`, for single selection and multiple selections.
Besides, it can be set to `'single'`, `'multiple'` or `'series'`, for single selection, multiple selections and whole series selection.

6 changes: 6 additions & 0 deletions en/option/partial/zr-graphic.md
Original file line number Diff line number Diff line change
Expand Up @@ -1773,6 +1773,8 @@ x value of element scale and rotation origin. In pixels
y value of element scale and rotation origin. In pixels.
{{ target: partial-graphic-cpt-focus-blur }}
##${prefix} focus(string) = 'none'
Expand Down Expand Up @@ -1804,6 +1806,10 @@ The range of fade out when `focus` is enabled. Support the following configurati
{{ target: partial-graphic-cpt-style-emphasis }}
{{ if: ${usageType} === 'customSeries' }}
##${prefix} emphasisEnabled(boolean)
Whether to disable the emphasis state.
##${prefix} emphasis(Object)
Emphasis state of the element.
Expand Down
20 changes: 20 additions & 0 deletions en/option/series/bar.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,10 @@ Background style of each bar if [showBackground](~series-bar.showBackground) is

Configurations of emphasis state.

{{ use: partial-emphasis-disabled(
prefix = "##"
) }}

{{ use: partial-focus-blur-scope() }}

{{ use: partial-bar-state(
Expand All @@ -106,8 +110,16 @@ Configurations of blur state. Available when [emphasis.focus](~series-bar.emphas

## select(Object)

{{ use: partial-version(
version = "5.0.0"
) }}

Configurations of select state. Available when [selectedMode](~series-bar.selectedMode) is set.

{{ use: partial-select-disabled(
prefix = "##"
) }}

{{ use: partial-bar-state(
prefix = "##",
topLevel = true,
Expand Down Expand Up @@ -191,6 +203,10 @@ The value of a single data item.

Emphasis state of single data.

{{ use: partial-emphasis-disabled(
prefix = "###"
) }}

{{ use: partial-bar-state(
prefix = "###",
topLevel = false,
Expand Down Expand Up @@ -219,6 +235,10 @@ Blur state of single data.

Select state of single data.

{{ use: partial-select-disabled(
prefix = "###"
) }}

{{ use: partial-bar-state(
prefix = "###",
topLevel = false,
Expand Down
16 changes: 16 additions & 0 deletions en/option/series/boxplot.md
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,10 @@ Style of boxplot.

Configurations of emphasis state.

{{ use: partial-emphasis-disabled(
prefix = "##"
) }}

{{ use: partial-focus-blur-scope() }}

### itemStyle(Object)
Expand Down Expand Up @@ -116,6 +120,10 @@ Configurations of blur state. Available when [emphasis.focus](~series-boxplot.em

Configurations of select state. Available when [selectedMode](~series-boxplot.selectedMode) is set.

{{ use: partial-select-disabled(
prefix = "##"
) }}

### itemStyle(Object)

{{ use: partial-item-style(
Expand Down Expand Up @@ -198,6 +206,10 @@ Style of a single data.

Emphasis state of a single data.

{{ use: partial-emphasis-disabled(
prefix = "###"
) }}

#### itemStyle(Object)

{{ use: partial-item-style(
Expand Down Expand Up @@ -229,6 +241,10 @@ Blur state of single data.

Select state of single data.

{{ use: partial-select-disabled(
prefix = "###"
) }}

#### itemStyle(Object)

{{ use: partial-item-style(
Expand Down
16 changes: 16 additions & 0 deletions en/option/series/candlestick.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,10 @@ Item style of candlestick.

Emphasis style of candlestick.

{{ use: partial-emphasis-disabled(
prefix = "##"
) }}

{{ use: partial-focus-blur-scope() }}

### itemStyle(Object)
Expand Down Expand Up @@ -128,6 +132,10 @@ Configurations of blur state. Available when [emphasis.focus](~series-candlestic

Configurations of select state. Available when [selectedMode](~series-candlestick.selectedMode) is set.

{{ use: partial-select-disabled(
prefix = "##"
) }}

### itemStyle(Object)

{{ use: partial-candlestick-item-style-detail(
Expand Down Expand Up @@ -213,6 +221,10 @@ Style of a candle box.

Emphasis style of a candle box.

{{ use: partial-emphasis-disabled(
prefix = "###"
) }}

#### itemStyle(Object)

{{ use: partial-candlestick-item-style-detail(
Expand Down Expand Up @@ -241,6 +253,10 @@ Blur state of single data.

Select state of single data.

{{ use: partial-select-disabled(
prefix = "###"
) }}

#### itemStyle(Object)

{{ use: partial-candlestick-item-style-detail(
Expand Down
16 changes: 16 additions & 0 deletions en/option/series/effectScatter.md
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,10 @@ The brush type for ripples. options: `'stroke'` and `'fill'`.

Configurations of emphasis state.

{{ use: partial-emphasis-disabled(
prefix = "##"
) }}

### scale(boolean) = true

<ExampleUIControlBoolean default="true" />
Expand Down Expand Up @@ -170,6 +174,10 @@ Configurations of blur state. Available when [emphasis.focus](~series-effectScat

Configurations of select state. Available when [selectedMode](~series-effectScatter.selectedMode) is set.

{{ use: partial-select-disabled(
prefix = "##"
) }}

{{ use: effectScatter-state(
prefix = "##"
) }}
Expand Down Expand Up @@ -231,6 +239,10 @@ Configurations of select state. Available when [selectedMode](~series-effectScat

Emphasis state of the specified single data.

{{ use: partial-emphasis-disabled(
prefix = "###"
) }}

{{ use: effectScatter-state(
prefix = "###"
) }}
Expand All @@ -251,6 +263,10 @@ Blur state of the specified single data.

Select state of the specified single data.

{{ use: partial-select-disabled(
prefix = "###"
) }}

{{ use: effectScatter-state(
prefix = "###"
) }}
Expand Down
Loading

0 comments on commit 3b26614

Please sign in to comment.