Skip to content
This repository has been archived by the owner on Jul 1, 2024. It is now read-only.

change code styles to dark #2846

Merged
merged 8 commits into from
Jun 7, 2023
Merged

change code styles to dark #2846

merged 8 commits into from
Jun 7, 2023

Conversation

cnunciato
Copy link
Contributor

@cnunciato cnunciato commented May 16, 2023

fixes pulumi/docs#8973


help from Christian:

@susanev Threw this PR together to give you something to use as a guide for pulumi/docs#8973.

Hugo syntax highlighting is powered by Chroma, and there's a built-in hugo subcommand that lets you generate a base set of styles using one of several built-in templates. For this PR, I did a couple of things to help point you in the right direction:

  1. I ran this hugo gen chromastyles subcommand and passed it a dark theme that looked decent, just to give you something to use as a reference. Here's the command I ran:

    hugo gen chromastyles --style=github-dark > themes/default/theme/src/scss/_chroma.scss

    The command writes to a file called _chroma.scss, which is then loaded by main.scss (replacing _pygments.scss --- IIRC Pygments was the tool Hugo used before Chroma).

  2. I made a few tweaks in _code.scss, _copybutton.scss, and _choosable.scss to remove a few overrides and change a few others -- again just as a demonstration of how we override the base set of generated styles up to now. I think these are the only places where we override these default/generated Hugo styles, but there might be a few other places here and there.

Feel free to click around in the Chrome styles gallery to find a dark-background that works for you. You should be able to use that hugo gen command to regenerate the baseline themes pretty easily and them override them as necessary.

Hope this helps!

@pulumi-bot

This comment was marked as outdated.

@susanev susanev force-pushed the cnunciato/code-styles branch from 898842b to 2f70952 Compare June 7, 2023 21:05
@susanev susanev self-assigned this Jun 7, 2023
@pulumi-bot

This comment was marked as outdated.

@pulumi-bot

This comment was marked as outdated.

Signed-off-by: susanev <[email protected]>
@susanev susanev changed the title Throwaway demo for code styles change code styles to dark Jun 7, 2023
@susanev susanev marked this pull request as ready for review June 7, 2023 21:40
@pulumi-bot

This comment was marked as outdated.

@susanev susanev requested a review from anita-trimbur June 7, 2023 21:46
@pulumi-bot

This comment was marked as outdated.

Signed-off-by: susanev <[email protected]>
@pulumi-bot

This comment was marked as outdated.

Signed-off-by: susanev <[email protected]>
@pulumi-bot

This comment was marked as outdated.

susanev added 2 commits June 7, 2023 16:16
Signed-off-by: susanev <[email protected]>
Signed-off-by: susanev <[email protected]>
@susanev susanev mentioned this pull request Jun 7, 2023
21 tasks
@pulumi-bot

This comment was marked as outdated.

@pulumi-bot
Copy link
Collaborator

Your site preview for commit 52e0445 is ready! 🎉

http://pulumi-hugo-origin-pr-2846-52e0445c.s3-website.us-west-2.amazonaws.com.

Copy link
Contributor

@anita-trimbur anita-trimbur left a comment

Choose a reason for hiding this comment

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

lgtm!! 🚀

@susanev susanev merged commit 408728b into master Jun 7, 2023
@susanev susanev deleted the cnunciato/code-styles branch June 7, 2023 23:24
gthuang added a commit that referenced this pull request Jun 13, 2023
* Add clarity around AWS classic vs native

* Adjust AWS classic reference

* add redirects for get started guides (#2984)

* Update go.mod

* new code font! (#2976)

* make keynote 40 minutes, shift all other times up by 20 minutes (#2985)

* create startup offer page (#2971)

* create startup offer page

* feedback updates: fix customer logos, adjust sizing, text changes

* update styles for left side text

* update copy

* add new layoutz to registry (#2977)

* Update go.mod

* update some registry links (#2974)

* Update go.mod

* fix resource h1 sizes (#2986)

* Update go.mod

* fix scheduling mistake (#2987)

* fix scheduling mistake

* add break to schedule

* Update go.mod

* fix (#2992)

* Update go.mod

* make blank whitepapers page fancy (#2993)

* Add a sidebar link to open issues in pulumi-ai repository (#2991)

* Add a note re Github Org member vis for PR preview (#2990)

* edit this page - links (#2995)

* Update go.mod

* fix text for line wrapping handler (#2999)

* Update go.mod

* pass at updating inputs/outputs doc (#2996)

* Update lifting section (#3000)

* Revert "pass at updating inputs/outputs doc (#2996)" (#3002)

This reverts commit ef67491.

* add redirect for /pugs (#3006)

* call the get started thing a tutorial (#3005)

* change code styles to dark (#2846)

* Update _index.md (#3008)

* Update go.mod

* fix up copy buttons (#3013)

* Update go.mod

* remove url route from footer (#3017)

* Update go.mod

* add zitadel logo (#3016)

* block edit links on some pages (#3015)

* add meta imgs for docs (#3018)

* Update go.mod

* Sarah/pulumiup workshops (#3007)

* add more workshops to pulumiup thank you page

* add workshops to PulumiUP landing page

* Add blog meta image (#3020)

* quickstart experience (#2983)

* fix code blocks in notes (#3019)

* Update go.mod

* add property search

---------

Co-authored-by: Monica <[email protected]>
Co-authored-by: susan evans <[email protected]>
Co-authored-by: susanev <[email protected]>
Co-authored-by: Sarah Hughes <[email protected]>
Co-authored-by: Monica <[email protected]>
Co-authored-by: mnlumi <[email protected]>
Co-authored-by: shughes26 <[email protected]>
Co-authored-by: Alex Qiu <[email protected]>
Co-authored-by: Mitch Gerdisch <[email protected]>
Co-authored-by: Sean Holung <[email protected]>
Co-authored-by: sean1588 <[email protected]>
Co-authored-by: Lee Briggs <[email protected]>
Co-authored-by: Christian Nunciato <[email protected]>
Co-authored-by: Anita Trimbur <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create a dark theme code block
4 participants