chore(template): various improvements (#666)
This commit is contained in:
1 parent
c28a518607
commit
8778215e28
1 file changed
+12
-7
@@ -47,19 +47,21 @@
|
|||||||
@crust: @catppuccin[@@lookup][@crust];
|
@crust: @catppuccin[@@lookup][@crust];
|
||||||
@accent-color: @catppuccin[@@lookup][@@accent];
|
@accent-color: @catppuccin[@@lookup][@@accent];
|
||||||
|
|
||||||
|
/* Recommended base styles: */
|
||||||
|
color-scheme: if(@lookup = latte, light, dark);
|
||||||
|
|
||||||
/* Start styling your website here: */
|
/* Start styling your website here: */
|
||||||
background-color: @base;
|
background-color: @base;
|
||||||
|
|
||||||
/* If you need to specify an overwrite specific to a Flavor
|
/* If you need to specify an overwrite specific to a flavor
|
||||||
* like Latte, you can use a `when` guard clause. */
|
* (e.g. only when the flavor is set to latte), you can use a `when` guard clause. */
|
||||||
& when (@lookup = latte) {
|
& when (@lookup = latte) {
|
||||||
/* your code for latte */
|
/* ... */
|
||||||
}
|
}
|
||||||
|
/* You can also negate the statement above by using
|
||||||
/* You can also negate the statement above by using
|
|
||||||
* a `when not` guard clause. */
|
* a `when not` guard clause. */
|
||||||
& when not (@lookup = latte) {
|
& when not (@lookup = latte) {
|
||||||
/* your code for frappe, macchiato and mocha */
|
/* ... */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -79,7 +81,10 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
/* If the website you are theming *does* have a light/dark mode toggle,
|
/* If the website you are theming *does* have a light/dark mode toggle,
|
||||||
you can conditionally enable light/dark flavors by targeting whatever attribute that website uses to indicate the theme.
|
you can conditionally enable light/dark flavors by targeting whatever
|
||||||
|
attribute that website uses to indicate the theme. *The example below gives you an idea of what
|
||||||
|
to look for. The website you are themeing may use a class-based approach (e.g. :root.theme-dark),
|
||||||
|
or any of the myriad of other methods like this.*
|
||||||
Un-comment this block if that is the case.
|
Un-comment this block if that is the case.
|
||||||
For an actual example of this, see https://github.com/catppuccin/userstyles/blob/39288b593278e5efa48007d5fc001292cf910672/styles/youtube/catppuccin.user.css#L21-L30.
|
For an actual example of this, see https://github.com/catppuccin/userstyles/blob/39288b593278e5efa48007d5fc001292cf910672/styles/youtube/catppuccin.user.css#L21-L30.
|
||||||
:root[data-theme="dark"] {
|
:root[data-theme="dark"] {
|
||||||
|
|||||||
Reference in new issue
Block a user