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

Mentioned gh_color_mode in .md #16266

Closed
wants to merge 2 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,19 @@ You can display an image by adding <kbd>!</kbd> and wrapping the alt text in `[

{% tip %}

**Tip:** You can append `#gh_color_mode=light` or `#gh_color_mode=dark` to a githubusercontent.com hosted image to only show it while the user is using the respective mode.

{% endtip %}

Here are some examples for using gh_color_mode to display the image only in respective mode.

| Context | URL |
|--------|--------|
| Dark Mode | `![GitHub Light](https://github.com/github-light.png#gh_color_mode=dark)` |
| Light Mode | `![GitHub Dark](https://github.com/github-dark.png#gh_color_mode=light)` |

{% tip %}

**Tip:** When you want to display an image which is in your repository, you should use relative links instead of absolute links.

{% endtip %}
Expand Down