diff --git a/assets/css/app.css b/assets/css/app.css
index 64d5953..5939420 100644
--- a/assets/css/app.css
+++ b/assets/css/app.css
@@ -6,13 +6,22 @@
@import "./lightbox.css";
@layer base {
- :root {
- --color-primary: 16 185 129;
+ :root[data-theme=default] {
+ --color-primary: 68 68 68;
--color-background: 255 255 255;
- --color-text-base: 82 82 91;
- --color-text-heading: 24 24 27;
- --color-text-muted: 82 82 91;
- --color-text-dim: 244 244 245;
+ --color-text-base: 68 68 68;
+ --color-text-heading: 68 68 68;
+ --color-text-muted: 153 153 153;
+ --color-text-dim: 204 204 204;
+ }
+
+ :root[data-theme=default][data-mode=dark] {
+ --color-primary: 255 255 255;
+ --color-background: 34 34 34;
+ --color-text-base: 204 204 204;
+ --color-text-heading: 255 255 255;
+ --color-text-muted: 102 102 102;
+ --color-text-dim: 68 68 68;
}
:root[data-theme=roguelight] {
@@ -28,7 +37,7 @@
/*
Invert prose styles based on the variant of the theme.
*/
-:root[data-variant=dark] .prose {
+:root[data-mode=dark] .prose {
@apply prose-invert;
}
diff --git a/lib/chiya_web/components/admin_components.ex b/lib/chiya_web/components/admin_components.ex
index 2a8220d..5e86406 100644
--- a/lib/chiya_web/components/admin_components.ex
+++ b/lib/chiya_web/components/admin_components.ex
@@ -70,15 +70,6 @@ defmodule ChiyaWeb.AdminComponents do
<%= @current_user.email %>
-
- <.link
- href="#"
- id="dark-mode-toggle"
- class="text-xs leading-6 text-gray-100 font-semibold hover:text-gray-300"
- >
- <.icon name="hero-sun-mini" class="h-4 w-4" />
-
-
<.link
href={~p"/user"}
@@ -107,10 +98,11 @@ defmodule ChiyaWeb.AdminComponents do
<% else %>
<.link
- href={~p"/user/register"}
+ href="#"
+ id="dark-mode-toggle"
class="text-xs leading-6 text-gray-100 font-semibold hover:text-gray-300"
>
- Register
+ <.icon name="hero-sun-mini" class="h-4 w-4" />
diff --git a/lib/chiya_web/components/layouts.ex b/lib/chiya_web/components/layouts.ex
index 48692c0..a49bec1 100644
--- a/lib/chiya_web/components/layouts.ex
+++ b/lib/chiya_web/components/layouts.ex
@@ -2,11 +2,4 @@ defmodule ChiyaWeb.Layouts do
use ChiyaWeb, :html
embed_templates "layouts/*"
-
- @doc """
- Defines which themes are light and which are dark themes.
- This influences the prose styles in app.css.
- """
- def theme_variant(:default), do: "light"
- def theme_variant(:roguelight), do: "dark"
end
diff --git a/lib/chiya_web/components/layouts/root_public.html.heex b/lib/chiya_web/components/layouts/root_public.html.heex
index c2d0e5a..7ec655d 100644
--- a/lib/chiya_web/components/layouts/root_public.html.heex
+++ b/lib/chiya_web/components/layouts/root_public.html.heex
@@ -1,5 +1,5 @@
-
+
@@ -13,6 +13,13 @@
+
diff --git a/lib/chiya_web/controllers/page_html/home.html.heex b/lib/chiya_web/controllers/page_html/home.html.heex
index 41d7a94..d4f14a7 100644
--- a/lib/chiya_web/controllers/page_html/home.html.heex
+++ b/lib/chiya_web/controllers/page_html/home.html.heex
@@ -1,6 +1,6 @@
-
+
<%= @settings.title %>
@@ -27,7 +27,7 @@
<%= if @channel do %>
<%= for note <- @channel.notes do %>
-
+
<%= note.name %>
<%= pretty_date(note.published_at) %>
diff --git a/lib/chiya_web/controllers/page_html/note.html.heex b/lib/chiya_web/controllers/page_html/note.html.heex
index aca5e79..fd8a8f6 100644
--- a/lib/chiya_web/controllers/page_html/note.html.heex
+++ b/lib/chiya_web/controllers/page_html/note.html.heex
@@ -1,5 +1,5 @@