Skip to content

Optimize logo for darkmode and add logos to assets folder#404

Merged
athre0z merged 2 commits intozyantific:masterfrom
rich-ayr:logo-darkmode
Nov 26, 2022
Merged

Optimize logo for darkmode and add logos to assets folder#404
athre0z merged 2 commits intozyantific:masterfrom
rich-ayr:logo-darkmode

Conversation

@rich-ayr
Copy link
Copy Markdown
Contributor

@rich-ayr rich-ayr commented Nov 26, 2022

GitHub has recently added an option to control images based on light/dark color mode using the <picture> element.

This PR adds the relevant HTML to README and provides a dark/light mode logo under the assets/img folder. Shipping the logos adds around 6KB to the repo, load time should stay the same as the logo is currently also served through githubusercontent.com

@rich-ayr rich-ayr changed the title Optimize logo for darkmode and add logo to assets folder Optimize logo for darkmode and add logos to assets folder Nov 26, 2022
@athre0z
Copy link
Copy Markdown
Member

athre0z commented Nov 26, 2022

Awesome! This has always annoyed me and I didn't expect it to be possible to fix it. Thanks for taking care of this! :)

@athre0z athre0z added C-enhancement Category: Enhancement of existing features A-doc Area: Documentation labels Nov 26, 2022
@athre0z athre0z merged commit 0cfaa39 into zyantific:master Nov 26, 2022
@flobernd
Copy link
Copy Markdown
Member

Nice, didn't know about this new feature.

If we ever add an organization README, let's remember to include our new Zyan logos the same way 🙂

@flobernd
Copy link
Copy Markdown
Member

image

The iOS app sadly seems to have problems supporting the svg.

@athre0z
Copy link
Copy Markdown
Member

athre0z commented Nov 26, 2022

This was already an SVG previously though.

@flobernd
Copy link
Copy Markdown
Member

In this case, it's the new feature that's not supported. I might report that bug if I find out where 😋

@rich-ayr rich-ayr deleted the logo-darkmode branch November 26, 2022 13:03
@rich-ayr
Copy link
Copy Markdown
Contributor Author

In this case, it's the new feature that's not supported. I might report that bug if I find out where 😋

Maybe it's an issue with relative paths or it just doesn't support the HTML tags/prefers-color-scheme yet.

@rich-ayr rich-ayr restored the logo-darkmode branch November 26, 2022 13:48
@rich-ayr
Copy link
Copy Markdown
Contributor Author

@flobernd I have made a branch with absolute paths on my fork: https://github.com/oberrich/zydis/blob/logo-darkmode-abspath/README.md

@flobernd
Copy link
Copy Markdown
Member

The absolute path indeed seems to work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-doc Area: Documentation C-enhancement Category: Enhancement of existing features

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants