-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Allow Code Component to have custom props and extra class styles #9960
Conversation
🦋 Changeset detectedLatest commit: c3ca52d The changes in this PR will be included in the next version bump. 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 |
Co-authored-by: Florian Lefebvre <contact@florian-lefebvre.dev>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Almost there!
Hey @florian-lefebvre I've added your suggestions. You can see in the above comments the issues I found. I'm also suddenly having issues building so I don't have a great way of testing. |
Don't worry about the failing tests called |
Hey @StandardGage are you still interested in this PR? |
Hey @florian-lefebvre , I haven't had much time to finish this PR so if it needs to be closed I understand and hopefully once I get more time I can open a new request towards this issue. |
No worries, thanks for the initial effort! We'll take it from here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
@florian-lefebvre and @bluwy, do you know if we need to update some documentation somewhere? I found only this page that mentions the |
I think that's the only place. Tbh, people kinda expected additional props to work already so it feels more like a patch. VSC will show the types anyway so I think we don't need to update the docs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving for docs!
Changes
Allows Astro's Code component to use custom props, including extra classes. Attempts to fix #9009
Testing
Used Minimal example to test changes. Specifically tested using the issue description and also tested with inline set to true.
Docs
I don't believe docs would be needed.