Skip to content

[charts] Add FocusedBar component to BarScatterComposition demo#22704

Merged
JCQuintas merged 8 commits into
mui:masterfrom
sai6855:composition
Jun 9, 2026
Merged

[charts] Add FocusedBar component to BarScatterComposition demo#22704
JCQuintas merged 8 commits into
mui:masterfrom
sai6855:composition

Conversation

@sai6855

@sai6855 sai6855 commented Jun 8, 2026

Copy link
Copy Markdown
Member

closes #19708

FocusedBar is present in markup but missing in actual demo. This PR adds FocusedBar in demo, to highlight focused bar

Preview https://deploy-preview-22704--material-ui-x.netlify.app/x/react-charts/bars/#composition

image

@sai6855 sai6855 added type: bug It doesn't behave as expected. docs Improvements or additions to the documentation. scope: charts Changes related to the charts. labels Jun 8, 2026
@code-infra-dashboard

code-infra-dashboard Bot commented Jun 8, 2026

Copy link
Copy Markdown

Deploy preview

Bundle size

Bundle Parsed size Gzip size
@mui/x-data-grid 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-pro 0B(0.00%) 0B(0.00%)
@mui/x-data-grid-premium 0B(0.00%) 0B(0.00%)
@mui/x-charts 0B(0.00%) 0B(0.00%)
@mui/x-charts-pro 0B(0.00%) 0B(0.00%)
@mui/x-charts-premium 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers 0B(0.00%) 0B(0.00%)
@mui/x-date-pickers-pro 0B(0.00%) 0B(0.00%)
@mui/x-tree-view 0B(0.00%) 0B(0.00%)
@mui/x-tree-view-pro 0B(0.00%) 0B(0.00%)
@mui/x-license 0B(0.00%) 0B(0.00%)

Details of bundle changes


Check out the code infra dashboard for more information about this PR.

@sai6855
sai6855 marked this pull request as ready for review June 8, 2026 16:54
Copilot AI review requested due to automatic review settings June 8, 2026 16:54

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the charts docs demo for the “bar + scatter composition” example so that focused bars get a visible focus outline during keyboard navigation, aligning the demo behavior with the documented composition markup.

Changes:

  • Import FocusedBar from @mui/x-charts/BarChart in the BarScatterComposition demo.
  • Render <FocusedBar /> in the composed chart surface so focused bars are visually highlighted.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.

File Description
docs/data/charts/bars/BarScatterCompostion.tsx Adds FocusedBar to the TS demo composition so focused bars show a focus outline.
docs/data/charts/bars/BarScatterCompostion.js Adds FocusedBar to the JS demo composition so focused bars show a focus outline.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread docs/data/charts/bars/BarScatterCompostion.tsx Outdated
Comment on lines 104 to 106
<ChartsXAxis axisId="bar" />
<FocusedBar />
<ChartsYAxis />
Comment on lines 3 to 4
import { BarPlot, FocusedBar } from '@mui/x-charts/BarChart';
import { ScatterPlot } from '@mui/x-charts/ScatterChart';
Comment on lines 102 to 104
<ChartsXAxis axisId="bar" />
<FocusedBar />
<ChartsYAxis />
sai6855 and others added 2 commits June 8, 2026 23:01
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
Signed-off-by: sai chand <[email protected]>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.

@JCQuintas
JCQuintas merged commit e952b46 into mui:master Jun 9, 2026
21 checks passed
mbrookes pushed a commit to mbrookes/mui-x that referenced this pull request Jun 27, 2026
…22704)

Signed-off-by: sai chand <[email protected]>
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Improvements or additions to the documentation. scope: charts Changes related to the charts. type: bug It doesn't behave as expected.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[charts][docs] During keyboard navigation focus doesn't show for line plot in a composed chart

3 participants