Skip to content

fix(datatable): remove toolbar search and menu from tab order#14397

Merged
tay1orjones merged 3 commits into
carbon-design-system:mainfrom
tay1orjones:14357-datatable-focus-improvements
Aug 4, 2023
Merged

fix(datatable): remove toolbar search and menu from tab order#14397
tay1orjones merged 3 commits into
carbon-design-system:mainfrom
tay1orjones:14357-datatable-focus-improvements

Conversation

@tay1orjones

@tay1orjones tay1orjones commented Aug 4, 2023

Copy link
Copy Markdown
Member

This removes the table toolbar search and menu actions from the tab order when batch actions are open, as discussed in #14357 (comment)

Changelog

Changed

  • update Search to put ...rest after other props
  • update stories to remove TableToolbarSearch and TableToolbarMenu actions from tab order when batch action bar is open/visible

Testing / Reviewing

  • focus should move through the actions when the batch action bar is closed
  • focus should not move through the actions when the batch action bar is open
datatable.focus.batch.actions.mov

@tay1orjones tay1orjones requested a review from a team as a code owner August 4, 2023 17:11
type={type}
value={value}
tabIndex={onExpand && !isExpanded ? -1 : undefined}
{...rest}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

I'm not sure why we had this placed before all the existing props. Props passed by consumers would always be overwritten by what we had here.

It's possible this could cause some unintended effects downstream, but I don't think it's necessarily a breaking change. Thoughts?

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.

Is the only "unintended effect" that props users were passing and expecting to work will now actually work? 😅

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.

I don't think this is breaking either, more like a bug fix for something that should have been working.

@netlify

netlify Bot commented Aug 4, 2023

Copy link
Copy Markdown

Deploy Preview for carbon-components-react ready!

Name Link
🔨 Latest commit cd8fb6b
🔍 Latest deploy log https://app.netlify.com/sites/carbon-components-react/deploys/64cd48da0641c500083a1583
😎 Deploy Preview https://deploy-preview-14397--carbon-components-react.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@netlify

netlify Bot commented Aug 4, 2023

Copy link
Copy Markdown

Deploy Preview for carbon-elements ready!

Name Link
🔨 Latest commit cd8fb6b
🔍 Latest deploy log https://app.netlify.com/sites/carbon-elements/deploys/64cd48da65d30100083d9eba
😎 Deploy Preview https://deploy-preview-14397--carbon-elements.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@tw15egan tw15egan 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.

LGTM 👍 ✅

@tw15egan

tw15egan commented Aug 4, 2023

Copy link
Copy Markdown
Contributor

@tay1orjones just needs updated snaps

@alisonjoseph alisonjoseph 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.

LGTM!

@tay1orjones tay1orjones enabled auto-merge August 4, 2023 18:52
@tay1orjones tay1orjones added this pull request to the merge queue Aug 4, 2023
Merged via the queue into carbon-design-system:main with commit b7abe20 Aug 4, 2023
@tay1orjones tay1orjones deleted the 14357-datatable-focus-improvements branch August 4, 2023 19:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants