Skip to content

Fix code blocks in /about #1315

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

Merged
merged 1 commit into from
Mar 20, 2021
Merged

Fix code blocks in /about #1315

merged 1 commit into from
Mar 20, 2021

Conversation

camelid
Copy link
Member

@camelid camelid commented Mar 11, 2021

  • Add lang- classes so hl.js identifies them correctly (it thought
    Rust was C++ and TOML was INI before)

  • Remove large blank space caused by newlines in HTML source

@camelid
Copy link
Member Author

camelid commented Mar 11, 2021

I haven't tested this aside from copying-and-pasting into Firefox Developer Tools because I don't have a local dev environment set up for docs.rs. Even with that, I wasn't able to test this that well. So I would really appreciate if someone could test this for me :)

@camelid
Copy link
Member Author

camelid commented Mar 11, 2021

Test failure looks unrelated.

@Kixiron
Copy link
Member

Kixiron commented Mar 12, 2021

TOML and INI are aliases for each other within highlight.js, their highlighting is identical

@jyn514 jyn514 added the S-waiting-on-author Status: This PR is incomplete or needs to address review comments label Mar 12, 2021
* Add `lang-` classes so hl.js identifies them correctly (it thought
  Rust was C++ and TOML was INI before)

* Remove large blank space caused by newlines in HTML source
@camelid
Copy link
Member Author

camelid commented Mar 13, 2021

TOML and INI are aliases for each other within highlight.js, their highlighting is identical

Okay, but it can't hurt to add the hint in case it changes in the future :)

@camelid
Copy link
Member Author

camelid commented Mar 13, 2021

@rustbot label: -S-waiting-on-author +S-waiting-on-review

@rustbot
Copy link
Collaborator

rustbot commented Mar 13, 2021

Error: This repository is not enabled to use triagebot.
Add a triagebot.toml in the root of the master branch to enable it.

Please let @rust-lang/release know if you're having trouble with this bot.

@jyn514 jyn514 added S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed and removed S-waiting-on-author Status: This PR is incomplete or needs to address review comments labels Mar 13, 2021
@jyn514 jyn514 merged commit e6b702b into rust-lang:master Mar 20, 2021
@camelid camelid deleted the fix-about-code branch March 20, 2021 20:58
@camelid
Copy link
Member Author

camelid commented Mar 20, 2021

Hmm, still not quite right:

image

image

Not sure how to fix it though.

@jyn514
Copy link
Member

jyn514 commented Mar 20, 2021

What do you mean? That highlighting looks good to me :)

@camelid
Copy link
Member Author

camelid commented Mar 20, 2021

What do you mean? That highlighting looks good to me :)

Yes, but there's an extra blank line at the top (the removal of the bottom one worked though) and the if let is missing indentation inside it.

@jyn514
Copy link
Member

jyn514 commented Mar 21, 2021

Try changing the decent level to 3 and removing the newline after <pre>.

camelid added a commit to camelid/docs.rs that referenced this pull request Mar 21, 2021
This is a followup to rust-lang#1315 to fix the extra blank line at the top and
to fix the indentation.
camelid added a commit to camelid/docs.rs that referenced this pull request Mar 21, 2021
This is a followup to rust-lang#1315 to fix the extra blank line at the top and
to fix the indentation.
jyn514 pushed a commit to jyn514/docs.rs that referenced this pull request Jun 24, 2021
This is a followup to rust-lang#1315 to fix the extra blank line at the top and
to fix the indentation.
jyn514 pushed a commit to jyn514/docs.rs that referenced this pull request Aug 16, 2021
This is a followup to rust-lang#1315 to fix the extra blank line at the top and
to fix the indentation.
jyn514 added a commit that referenced this pull request Aug 18, 2021
* Better fix code blocks in `/about`

This is a followup to #1315 to fix the extra blank line at the top and
to fix the indentation.

Co-authored-by: Camelid <camelidcamel@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: This pull request has been implemented and needs to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants