Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TreeView: Add indication of empty directory #5168

Merged
merged 8 commits into from
Nov 4, 2024

Conversation

TylerJDev
Copy link
Contributor

@TylerJDev TylerJDev commented Oct 22, 2024

Closes https://github.com/github/primer/issues/3447

Example story: Empty Directory

Adds indication of no nodes in a empty directory. Previously, the directory wouldn't indicate the user if the directory was empty or not, even though the icon changed to open/closed when interacting with it.

Example:
Empty tree items, one is expanded with the text 'no items found' directly underneath, whereas the second tree item is not currently expanded

Screen reader support
VoiceOver (Safari) VoiceOver (Chrome) NVDA (Firefox)
Announces "empty" live region Yes Yes Yes
Announces empty node Yes Yes Yes
Announces expanded/collapsed state Yes Yes Yes

Changelog

New

  • Adds indication of no nodes in tree item/directory via EmptyItem

Changed

  • Allows for aria-expanded even if tree item is empty

Removed

Rollout strategy

  • Patch release
  • Minor release
  • Major release; if selected, include a written rollout or migration plan
  • None; if selected, include a brief description as to why

Testing & Reviewing

Merge checklist

Copy link

changeset-bot bot commented Oct 22, 2024

🦋 Changeset detected

Latest commit: 5ace102

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@primer/react Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

👋 Hi, this pull request contains changes to the source code that github/github depends on. If you are GitHub staff, we recommend testing these changes with github/github using the integration workflow. Thanks!

@github-actions github-actions bot added the integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm label Oct 22, 2024
@github-actions github-actions bot temporarily deployed to storybook-preview-5168 October 22, 2024 04:17 Inactive
Copy link
Contributor

github-actions bot commented Oct 22, 2024

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 98.39 KB (+0.04% 🔺)
packages/react/dist/browser.umd.js 98.75 KB (+0.05% 🔺)

@primer-integration
Copy link

primer-integration bot commented Oct 23, 2024

🟢 golden-jobs completed with status success.

@TylerJDev TylerJDev marked this pull request as ready for review October 23, 2024 14:52
@TylerJDev TylerJDev requested a review from a team as a code owner October 23, 2024 14:52
@TylerJDev TylerJDev changed the title TreeView: Add indication of empty directory [WIP] TreeView: Add indication of empty directory Oct 24, 2024
@primer-integration
Copy link

👋 Hi from github/github! Your integration PR is ready: https://github.com/github/github/pull/349856

@TylerJDev TylerJDev added this pull request to the merge queue Nov 4, 2024
@TylerJDev TylerJDev added integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh and removed integration-tests: recommended This change needs to be tested for breaking changes. See https://arc.net/l/quote/tdmpakpm labels Nov 4, 2024
Merged via the queue into main with commit b9749d4 Nov 4, 2024
48 checks passed
@TylerJDev TylerJDev deleted the tylerjdev/treeview-empty-indication branch November 4, 2024 17:36
@primer primer bot mentioned this pull request Nov 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration-tests: passing Changes in this PR do NOT cause breaking changes in gh/gh
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants