Bulma prefers-dark theme for devices which support dark mode

This commit is contained in:
Noah 2022-08-31 22:33:25 -07:00
parent ff0d6f16be
commit 91fcf9f320
6 changed files with 6614 additions and 11 deletions

File diff suppressed because it is too large Load Diff

1
web/static/css/bulma.min.css vendored Normal file

File diff suppressed because one or more lines are too long

View File

@ -5,8 +5,8 @@
<head> <head>
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bulma@0.9.4/css/bulma.min.css"> <link rel="stylesheet" type="text/css" href="/static/css/bulma.min.css">
<!-- <link rel="stylesheet" type="text/css" href="https://unpkg.com/bulma-prefers-dark" /> --> <link rel="stylesheet" type="text/css" href="/static/css/bulma-prefers-dark.css" />
<link rel="stylesheet" href="/static/fontawesome-free-6.1.2-web/css/all.css"> <link rel="stylesheet" href="/static/fontawesome-free-6.1.2-web/css/all.css">
<link rel="stylesheet" href="/static/css/theme.css"> <link rel="stylesheet" href="/static/css/theme.css">
<title>{{template "title" .}} - {{ .Title }}</title> <title>{{template "title" .}} - {{ .Title }}</title>

View File

@ -77,7 +77,7 @@
<div class="block p-2"> <div class="block p-2">
{{range .Threads}} {{range .Threads}}
{{$Stats := $Root.ThreadMap.Get .ID}} {{$Stats := $Root.ThreadMap.Get .ID}}
<div class="box has-background-success-light"> <div class="box has-background-success-light has-text-dark">
<div class="columns"> <div class="columns">
<div class="column is-2 has-text-centered pt-0 pb-1"> <div class="column is-2 has-text-centered pt-0 pb-1">
<div> <div>
@ -95,7 +95,7 @@
</div> </div>
<div class="column content pt-1 pb-0"> <div class="column content pt-1 pb-0">
<a href="/forum/thread/{{.ID}}" class="has-text-dark"> <a href="/forum/thread/{{.ID}}" class="has-text-dark">
<h2 class="is-size-4 pt-0"> <h2 class="is-size-4 pt-0 has-text-dark">
{{if .Pinned}}<sup class="fa fa-thumbtack has-text-success mr-2 is-size-6" title="Pinned"></sup>{{end}} {{if .Pinned}}<sup class="fa fa-thumbtack has-text-success mr-2 is-size-6" title="Pinned"></sup>{{end}}
{{or .Title "Untitled"}} {{or .Title "Untitled"}}
</h2> </h2>

View File

@ -58,7 +58,7 @@
{{else}} {{else}}
{{range .Forums}} {{range .Forums}}
{{$Stats := $Root.ForumMap.Get .ID}} {{$Stats := $Root.ForumMap.Get .ID}}
<div class="card block has-background-primary-light"> <div class="card block has-background-primary-light has-text-dark">
<div class="card-content"> <div class="card-content">
<div class="columns"> <div class="columns">
<div class="column is-3 pt-0 pb-1"> <div class="column is-3 pt-0 pb-1">
@ -93,8 +93,8 @@
</div> </div>
<div class="column py-1"> <div class="column py-1">
<div class="box has-background-success-light"> <div class="box has-background-success-light has-text-dark">
<h2 class="subtitle mb-1">Latest Post</h2> <h2 class="subtitle has-text-dark mb-1">Latest Post</h2>
{{if $Stats.RecentThread}} {{if $Stats.RecentThread}}
<a href="/forum/thread/{{$Stats.RecentThread.ID}}"> <a href="/forum/thread/{{$Stats.RecentThread.ID}}">
<strong>{{$Stats.RecentThread.Title}}</strong> <strong>{{$Stats.RecentThread.Title}}</strong>
@ -116,7 +116,7 @@
<div class="column is-3 py-1"> <div class="column is-3 py-1">
<div class="columns is-mobile is-gapless"> <div class="columns is-mobile is-gapless">
<div class="column has-text-centered mr-1"> <div class="column has-text-centered mr-1">
<div class="box has-background-warning-light p-2"> <div class="box has-background-warning-light has-text-dark p-2">
<p class="is-size-7">Topics</p> <p class="is-size-7">Topics</p>
{{if $Stats}} {{if $Stats}}
{{$Stats.Threads}} {{$Stats.Threads}}
@ -126,7 +126,7 @@
</div> </div>
</div> </div>
<div class="column has-text-centered mx-1"> <div class="column has-text-centered mx-1">
<div class="box has-background-warning-light p-2"> <div class="box has-background-warning-light has-text-dark p-2">
<p class="is-size-7">Posts</p> <p class="is-size-7">Posts</p>
{{if $Stats}} {{if $Stats}}
{{$Stats.Posts}} {{$Stats.Posts}}
@ -136,7 +136,7 @@
</div> </div>
</div> </div>
<div class="column has-text-centered ml-1"> <div class="column has-text-centered ml-1">
<div class="box has-background-warning-light p-2"> <div class="box has-background-warning-light has-text-dark p-2">
<p class="is-size-7">Users</p> <p class="is-size-7">Users</p>
{{if $Stats}} {{if $Stats}}
{{$Stats.Users}} {{$Stats.Users}}

View File

@ -120,7 +120,7 @@
{{$Root := .}} {{$Root := .}}
<div class="block p-2"> <div class="block p-2">
{{range .Comments}} {{range .Comments}}
<div class="box has-background-link-light"> <div class="box has-background-link-light has-text-dark">
<div class="columns"> <div class="columns">
<div class="column is-2 has-text-centered"> <div class="column is-2 has-text-centered">
<div> <div>