-
-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding dark-mode favicon capability and images
Resolves #924 Our current theme inherits from docsy and the favicons are generates from the following template: https://github.com/google/docsy/blob/1d126ab1bbf186fa0ea52a6d6a3f58229b2b7942/layouts/partials/favicons.html This changes adds a new favicon layout to override the base. The new layout is the same as the base, but adds the media attribute to supply browsers with light/dark options should they choose to respect it. White color images are included for all sizes for the dark option.
- Loading branch information
Craig Landry
committed
Dec 22, 2022
1 parent
1641f05
commit 7435dd7
Showing
11 changed files
with
23 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<!-- regular/light mode --> | ||
<link rel="shortcut icon" media="(prefers-color-scheme: light)" href="{{ "favicons/favicon.ico" | relURL }}" > | ||
<link rel="apple-touch-icon" media="(prefers-color-scheme: light)" href="{{ "favicons/apple-touch-icon-180x180.png" | relURL }}" sizes="180x180"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/favicon-16x16.png" | relURL }}" sizes="16x16"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/favicon-32x32.png" | relURL }}" sizes="32x32"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-36x36.png" | relURL }}" sizes="36x36"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-48x48.png" | relURL }}" sizes="48x48"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-72x72.png" | relURL }}" sizes="72x72"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-96x96.png" | relURL }}" sizes="96x96"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-144x144.png" | relURL }}" sizes="144x144"> | ||
<link rel="icon" media="(prefers-color-scheme: light)" type="image/png" href="{{ "favicons/android-192x192.png" | relURL }}" sizes="192x192"> | ||
|
||
<!-- dark mode --> | ||
<link rel="shortcut icon" media="(prefers-color-scheme: dark)" href="{{ "favicons/favicon-dark.ico" | relURL }}" > | ||
<link rel="apple-touch-icon" media="(prefers-color-scheme: dark)" href="{{ "favicons/apple-touch-icon-dark-180x180.png" | relURL }}" sizes="180x180"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/favicon-dark-16x16.png" | relURL }}" sizes="16x16"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/favicon-dark-32x32.png" | relURL }}" sizes="32x32"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-36x36.png" | relURL }}" sizes="36x36"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-48x48.png" | relURL }}" sizes="48x48"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-72x72.png" | relURL }}" sizes="72x72"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-96x96.png" | relURL }}" sizes="96x96"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-144x144.png" | relURL }}" sizes="144x144"> | ||
<link rel="icon" media="(prefers-color-scheme: dark)" type="image/png" href="{{ "favicons/android-dark-192x192.png" | relURL }}" sizes="192x192"> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.