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

Add className prop support to TreeView #4512

Merged
merged 5 commits into from
Apr 19, 2024
Merged

Conversation

colebemis
Copy link
Contributor

@colebemis colebemis commented Apr 18, 2024

Related to #4487

This pull request introduces support for external styling on the TreeView and TreeView.Item components through the className prop, allowing for more flexible customization without relying on CSS selectors.

  • Adds className prop: Both TreeView and TreeView.Item components now accept a className prop. This prop is applied to the root element of each component, enabling the application of custom styles directly.
  • Maintains backward compatibility: The addition of the className prop is optional and does not affect existing implementations that do not use this prop.
  • Updates TypeScript types: The TypeScript definitions for TreeView and TreeView.Item have been updated to include the new className prop, ensuring type safety for TypeScript users.

For more details, open the Copilot Workspace session.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
Copy link

changeset-bot bot commented Apr 18, 2024

🦋 Changeset detected

Latest commit: dad7821

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

@github-actions github-actions bot temporarily deployed to storybook-preview-4512 April 18, 2024 21:27 Inactive
Copy link
Contributor

github-actions bot commented Apr 18, 2024

size-limit report 📦

Path Size
packages/react/dist/browser.esm.js 88.03 KB (+0.04% 🔺)
packages/react/dist/browser.umd.js 88.36 KB (+0.14% 🔺)

@colebemis
Copy link
Contributor Author

The PR was updated with Copilot Workspace (v0.17). For more details, open the Copilot Workspace session.

@github-actions github-actions bot temporarily deployed to storybook-preview-4512 April 18, 2024 21:47 Inactive
@colebemis
Copy link
Contributor Author

The PR was updated with Copilot Workspace (v0.17). For more details, open the Copilot Workspace session.

@colebemis colebemis marked this pull request as ready for review April 18, 2024 21:50
@colebemis colebemis requested a review from a team as a code owner April 18, 2024 21:50
@colebemis colebemis requested a review from mperrotti April 18, 2024 21:50
@github-actions github-actions bot temporarily deployed to storybook-preview-4512 April 18, 2024 21:54 Inactive
@colebemis colebemis added this pull request to the merge queue Apr 19, 2024
Merged via the queue into main with commit 622b144 Apr 19, 2024
30 checks passed
@colebemis colebemis deleted the colebemis/treeview-styling branch April 19, 2024 20:47
@primer primer bot mentioned this pull request Apr 19, 2024
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.

None yet

2 participants