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

fix(content-docs): sidebar generator should return customProps for doc items #9107

Merged
merged 1 commit into from Jun 29, 2023

Conversation

TheCatLady
Copy link
Contributor

Pre-flight checklist

  • I have read the Contributing Guidelines on pull requests.
  • If this is a code change: I have written unit tests and/or added dogfooding pages to fully verify the new behavior.
  • If this is a new API or substantial change: the PR has an accompanying issue (closes #0000) and the maintainers have approved on my working plan.

Motivation

While customizing the sidebar generator behavior for a Docusaurus site I maintain, I discovered that customProps was missing on non-category sidebar items.

Test Plan

Added a custom prop to an existing test and regenerated the snapshot.

@facebook-github-bot facebook-github-bot added the CLA Signed Signed Facebook CLA label Jun 27, 2023
@netlify
Copy link

netlify bot commented Jun 27, 2023

[V2]

Built without sensitive environment variables

Name Link
🔨 Latest commit 2c2c2a6
🔍 Latest deploy log https://app.netlify.com/sites/docusaurus-2/deploys/649a48b9d267a800084e5f7d
😎 Deploy Preview https://deploy-preview-9107--docusaurus-2.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.

@github-actions
Copy link

⚡️ Lighthouse report for the deploy preview of this PR

URL Performance Accessibility Best Practices SEO PWA Report
/ 🟠 86 🟢 97 🟢 92 🟢 100 🟠 89 Report
/docs/installation 🟠 75 🟢 100 🟢 92 🟢 100 🟠 89 Report

Copy link
Collaborator

@slorber slorber left a comment

Choose a reason for hiding this comment

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

Good catch, thanks for the fix 👍

@slorber slorber merged commit 9391a33 into facebook:main Jun 29, 2023
29 of 31 checks passed
@TheCatLady TheCatLady deleted the dh/sidebargenerator branch June 29, 2023 17:59
@TheCatLady
Copy link
Contributor Author

@slorber I noticed that this PR didn't get labeled with to backport like my other PR, but it'd be really nice to apply this fix to v2 as well -- we are currently blocked from upgrading to v3 due to PaloAltoNetworks/docusaurus-openapi-docs being incompatible with MDX 2.

Thanks for your prompt review of both PRs though! Really appreciate it 😺

@slorber slorber added pr: bug fix This PR fixes a bug in a past release. to backport This PR is planned to be backported to a stable version of Docusaurus labels Jun 29, 2023
@slorber
Copy link
Collaborator

slorber commented Jun 29, 2023

Thanks, added the label :)

slorber added a commit that referenced this pull request Sep 20, 2023
…lease (#9324)

Co-authored-by: Joshua Chen <sidachen2003@gmail.com>
Co-authored-by: sebastienlorber <lorber.sebastien@gmail.com>
Co-authored-by: Sébastien Lorber <slorber@users.noreply.github.com>
Co-authored-by: Ori Shalom <ori-shalom@users.noreply.github.com>
Co-authored-by: Mikey O'Toole <mikey@homotechsual.dev>
Co-authored-by: TheCatLady <52870424+TheCatLady@users.noreply.github.com>
fix flaky screenshots, add html data-has-hydrated attribute (#9256)
fix(theme-common): ThemedComponent should display something when JS is disabled (#9243)
fix(theme): canonical url should be not change after hydration if url accessed with/without trailing slash (#9130)
fix(theme): only set classname on ul elements if they have an existing class (#9099)
fix(content-docs): sidebar generator should return customProps for doc items (#9107)
@slorber slorber added backported This PR has been backported to a stable version of Docusaurus and removed to backport This PR is planned to be backported to a stable version of Docusaurus labels Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backported This PR has been backported to a stable version of Docusaurus CLA Signed Signed Facebook CLA pr: bug fix This PR fixes a bug in a past release.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants