Skip to content

Commit

Permalink
fix: auto applies both stylesheets instead of only the applicable one (
Browse files Browse the repository at this point in the history
…#52)

* fix: auto applies both stylesheets instead of only the applicable one

* Update Assets.php
  • Loading branch information
davwheat authored Nov 30, 2021
1 parent 604f0a5 commit 2dab286
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Content/Assets.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ protected function generateTag(?string $url, string $type, string $auto)
{
return sprintf(
'<link rel="stylesheet" media="%s" class="nightmode-%s" href="%s" />',
$auto && $type === 'dark' ? '(prefers-color-scheme: dark)' : '',
$auto && $type === 'dark' ? '(prefers-color-scheme: dark)' : 'not all and (prefers-color-scheme: dark)',
$type,
$url
);
Expand Down

0 comments on commit 2dab286

Please sign in to comment.