Skip to content

Example code for github light/dark #13

@nwhitehead

Description

@nwhitehead

Love the project and the idea!

I think a common case for using the logo could be in README.md files on github. In this case the ideal thing to do is to have a light mode and dark mode variant that is chosen by the theme. This can be done with github-specific anchor tagging. It might be good to include this markup in the description of the different banners.

It's something like this in the README.md:

<a href="https://brainmade.org#gh-dark-mode-only">
 <img src="https://github.com/user-attachments/assets/4aa8232a-5669-47c9-85a5-085060d09ab3"></img>
</a>

<a href="https://brainmade.org#gh-light-mode-only">
  <img src="https://github.com/user-attachments/assets/b1ed74f3-0844-409c-a183-36be32d774fb"></img>
</a>

I uploaded the image files using github editor (pasting in the images) to get the user-attachment URLs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions