Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion src/component/axisPointer/axisTrigger.ts
Original file line number Diff line number Diff line change
Expand Up @@ -164,10 +164,13 @@ export default function axisTrigger(
const coordSysContainsPoint = isIllegalPoint || coordSys.containPoint(point);

each(coordSysAxesInfo.coordSysAxesInfo[coordSysKey], function (axisInfo, key) {
// Allow connected charts to bypass illegalPoint check and always show shared
// axisPointer regardless of series data.
const isAlwaysShowContent = axisInfo.axisPointerModel.get('alwaysShowContent');
const axis = axisInfo.axis;
const inputAxisInfo = findInputAxisInfo(inputAxesInfo, axisInfo);
// If no inputAxesInfo, no axis is restricted.
if (!shouldHide && coordSysContainsPoint && (!inputAxesInfo || inputAxisInfo)) {
if (isAlwaysShowContent || !shouldHide && coordSysContainsPoint && (!inputAxesInfo || inputAxisInfo)) {
let val = inputAxisInfo && inputAxisInfo.value;
if (val == null && !isIllegalPoint) {
val = axis.pointToData(point);
Expand Down
2 changes: 2 additions & 0 deletions src/util/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1662,6 +1662,8 @@ type LabelFormatterParams = {
export interface CommonAxisPointerOption {
show?: boolean | 'auto'

alwaysShowContent?: boolean

z?: number;
zlevel?: number;

Expand Down
172 changes: 172 additions & 0 deletions test/axis-pointer-sync.html

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.