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

[docs][material] Highlight global state classes in CSS table in API docs #36633

Merged
merged 3 commits into from
Apr 5, 2023

Conversation

hbjORbj
Copy link
Member

@hbjORbj hbjORbj commented Mar 24, 2023

Changes

  • Make global state classes in CSS table in API docs bold
  • Add a heading below the section name "CSS": "The following class names are useful for styling with CSS. The global state classes are in **bold**. To learn more about state classes, check out the [State classes](https://mui.com/material-ui/customization/how-to-customize/#state-classes) guide."

Preview

Screenshot 2023-03-24 at 17 05 03

@hbjORbj hbjORbj changed the title Make global state classes bold in css table and add description above… [docs][material] Highlight global state classes in CSS table in API docs Mar 24, 2023
@hbjORbj hbjORbj self-assigned this Mar 24, 2023
@hbjORbj hbjORbj requested a review from mnajdova March 24, 2023 21:00
@hbjORbj hbjORbj added docs Improvements or additions to the documentation package: material-ui Specific to @mui/material labels Mar 24, 2023
@mui-bot
Copy link

mui-bot commented Mar 26, 2023

Netlify deploy preview

https://deploy-preview-36633--material-ui.netlify.app/

Bundle size report

No bundle size changes

Generated by 🚫 dangerJS against 6b9bd65

@@ -5,6 +5,7 @@
"themeDefaultProps": "Theme default props",
"themeDefaultPropsDescription": "You can use <code>{{muiName}}</code> to change the default props of this component <a href={{defaultPropsLink}}>with the theme</a>.",
"hookName": "Hook name",
"cssDescription": "The following class names are useful for styling with CSS. The global state classes are in <b>bold</b>. To learn more about state classes, check out the <a href=\"/material-ui/customization/how-to-customize/#state-classes\">State classes</a> guide.",
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
"cssDescription": "The following class names are useful for styling with CSS. The global state classes are in <b>bold</b>. To learn more about state classes, check out the <a href=\"/material-ui/customization/how-to-customize/#state-classes\">State classes</a> guide.",
"cssDescription": "The following class names are useful for styling with CSS (the <a href=\"/material-ui/customization/how-to-customize/#state-classes\">state classes</a> are in <b>bold</b>. <br /> To learn more, visit <a href=\"/material-ui/customization/theme-components/\">component customization</a> page",

I think @samuelsycamore will have a better version 😁.

Copy link
Member

@siriwatknp siriwatknp Mar 30, 2023

Choose a reason for hiding this comment

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

I think it is worth linking to https://deploy-preview-36631--material-ui.netlify.app/material-ui/customization/theme-components/ because that's the next step developers should know.

Copy link
Member

Choose a reason for hiding this comment

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

Just a few tiny fixes on @siriwatknp 's suggestion.

Suggested change
"cssDescription": "The following class names are useful for styling with CSS. The global state classes are in <b>bold</b>. To learn more about state classes, check out the <a href=\"/material-ui/customization/how-to-customize/#state-classes\">State classes</a> guide.",
"cssDescription": "The following class names are useful for styling with CSS (the <a href=\"/material-ui/customization/how-to-customize/#state-classes\">state classes</a> are in <b>bold</b>). <br /> To learn more, visit the <a href=\"/material-ui/customization/theme-components/\">component customization</a> page.",

Copy link
Member Author

Choose a reason for hiding this comment

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

Thanks! addressed.

Copy link
Member Author

Choose a reason for hiding this comment

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

Since we are using chip to mark it as a state rather than bold text, I changed "state classes are in bold" to "state classes are marked". Feel free to change it. @samuelsycamore
Screenshot 2023-03-31 at 16 16 19

@siriwatknp
Copy link
Member

siriwatknp commented Mar 30, 2023

2 things:

@github-actions github-actions bot added the PR: out-of-date The pull request has merge conflicts and can't be merged label Mar 31, 2023
@hbjORbj
Copy link
Member Author

hbjORbj commented Mar 31, 2023

instead of bold, can it be a chip? or a tag? I think bold is meant to emphasize a part of the content but it is not in this case

Agree. Replaced it with a chip. It looks better. Addressed.

Screenshot 2023-03-31 at 16 16 19

the description should contain a link to https://deploy-preview-36631--material-ui.netlify.app/material-ui/customization/theme-components/
@siriwatknp

Can you elaborate on this? By "the description", you mean the column name or individual descriptions of classes?

@github-actions github-actions bot removed the PR: out-of-date The pull request has merge conflicts and can't be merged label Mar 31, 2023
@hbjORbj hbjORbj requested a review from siriwatknp April 3, 2023 13:00
@hbjORbj hbjORbj merged commit b7ebbd6 into mui:master Apr 5, 2023
hbjORbj added a commit to hbjORbj/material-ui that referenced this pull request Apr 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation package: material-ui Specific to @mui/material
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants