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

Color utils docs #32819

Merged
merged 4 commits into from
Feb 3, 2021
Merged

Color utils docs #32819

merged 4 commits into from
Feb 3, 2021

Conversation

mdo
Copy link
Member

@mdo mdo commented Jan 16, 2021

  • Splits background utils from color utils for our docs with a new page.
  • Adds some Sass docs for variables, maps, and mixins

The scss-docs shortcode is amazing, but one limitation is it doesn't seem to work with indentation at the beginning of the single line comments to identify sections. This is what I ran into in #32747 with documenting the utilities map. Curious if @MartijnCuppens or @XhmikosR has some ideas for how to address that.

Also documents the existence of .bg-body, closing the docs part of #32810.

Still a little copyediting to refine here, so consider this one a little WIP still.

  • Document CSS custom properties somewhere (under Sass? another h2 called CSS?)
  • Other vars, mixins, etc to add?
  • Revert the indentation changes and properly indent capture start/end statements

@mdo
Copy link
Member Author

mdo commented Jan 19, 2021

@XhmikosR Elaborating per Slack... the latest commit here should break the build because there's indentation before the comment lines.

scss/_utilities.scss Outdated Show resolved Hide resolved
@XhmikosR
Copy link
Member

@mdo see if it works and we'll clean up the branch later. Also check the OP TODO.

I'll look into improving the shortcode later in #32781

@mdo mdo marked this pull request as ready for review January 27, 2021 22:00
@mdo mdo requested a review from a team as a code owner January 27, 2021 22:00
@mdo
Copy link
Member Author

mdo commented Jan 27, 2021

Looking solid @XhmikosR, thanks!

One thing for your referenced PR, it'd be awesome to un-indent these lines if possible. Right now the snippet brings in those extra spaces. That might be too difficult, so not a huge deal if so.

mdo and others added 2 commits January 28, 2021 07:57
- Split colors from background utilities with new docs page
- Add Sass docs for both pages
Should work now with indented start/end capture statements
@XhmikosR
Copy link
Member

One thing for your referenced PR, it'd be awesome to un-indent these lines if possible. Right now the snippet brings in those extra spaces. That might be too difficult, so not a huge deal if so.

Yup, I know, it's in my TODO after this one lands :)

@XhmikosR XhmikosR requested a review from ffoodd January 29, 2021 12:53
@@ -92,6 +92,7 @@
- title: Utilities
pages:
- title: API
- title: Background
- title: Borders
- title: Colors
Copy link
Member

Choose a reason for hiding this comment

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

Shouldn't this be renamed as Color for consistency? Questionning only, no opinion.

Copy link
Member

Choose a reason for hiding this comment

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

We actually seem to mix and match these... we have Interactions, shadows etc. We should probably streamline these at some point and add redirects.

@XhmikosR XhmikosR merged commit a1bb65e into main Feb 3, 2021
@XhmikosR XhmikosR deleted the color-utils-docs branch February 3, 2021 05:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants