aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGabriel Arakaki Giovanini <mail@gabrielgio.me>2023-08-16 19:31:48 +0200
committerGabriel Arakaki Giovanini <mail@gabrielgio.me>2023-08-16 19:31:48 +0200
commit969b7600a86185187cd17d45bd252143db4a6728 (patch)
treec4d625c9b1a1fa5584e70f02f02f5cd077fb94c9
parenta98acb9c8b86a2c2f35841c86d3c3f1d7c176b61 (diff)
downloadlens-969b7600a86185187cd17d45bd252143db4a6728.tar.gz
lens-969b7600a86185187cd17d45bd252143db4a6728.tar.bz2
lens-969b7600a86185187cd17d45bd252143db4a6728.zip
ref: Some typography tweaks
-rw-r--r--scss/main.scss19
-rw-r--r--templates/album.qtpl6
-rw-r--r--templates/base.qtpl10
-rw-r--r--templates/fs.qtpl8
-rw-r--r--templates/media.qtpl2
-rw-r--r--templates/settings.qtpl14
6 files changed, 38 insertions, 21 deletions
diff --git a/scss/main.scss b/scss/main.scss
index 89d2096..addae37 100644
--- a/scss/main.scss
+++ b/scss/main.scss
@@ -1,4 +1,4 @@
-$breakpoint: 520px;
+$breakpoint: 360px;
$tablet: $breakpoint;
$body-font-size: 1rem;
@@ -18,6 +18,11 @@ $card-content-padding: 0;
$table-cell-padding: 0.5em;
$table-cell-border-width: 0;
+$tag-radius: 0;
+$tag-delete-margin: 15px;
+
+$title-weight: normal;
+
@import "bulma/sass/base/_all.sass";
@import "bulma/sass/utilities/_all.sass";
@import "bulma/sass/grid/_all.sass";
@@ -28,7 +33,8 @@ $table-cell-border-width: 0;
@import "bulma/sass/elements/_all.sass";
body {
- font-family: $family-primary
+ font-family: $family-primary;
+ padding-bottom: 10px;
}
.input, .button{
@@ -85,3 +91,12 @@ th {
.img {
object-fit: cover;
}
+
+// exting size
+.text-size-1{
+ @extend .is-size-4 !optional;
+}
+
+.text-size-2{
+ @extend .is-size-5 !optional;
+}
diff --git a/templates/album.qtpl b/templates/album.qtpl
index ce8111e..9f4c0bd 100644
--- a/templates/album.qtpl
+++ b/templates/album.qtpl
@@ -20,10 +20,10 @@ func (m *AlbumPage) PreloadAttr() string {
{% func (p *AlbumPage) Title() %}Media{% endfunc %}
{% func (p *AlbumPage) Content() %}
-<h1 class="title">{%s p.Name %}</h1>
+<h1 class="title text-size-1">{%s p.Name %}</h1>
<div class="tags are-large">
{% for _, a := range p.Albums %}
- <a href="/album/?albumId={%s FromUInttoString(&a.ID) %}" class="tag">{%s a.Name %}</a>
+ <a href="/album/?albumId={%s FromUInttoString(&a.ID) %}" class="tag text-size-2">{%s a.Name %}</a>
{% endfor %}
</div>
<div class="columns is-multiline">
@@ -41,7 +41,7 @@ func (m *AlbumPage) PreloadAttr() string {
</div>
{% endfor %}
</div>
-<div class="row">
+<div>
<a href="/media/?page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
</div>
{% endfunc %}
diff --git a/templates/base.qtpl b/templates/base.qtpl
index 772167d..b1878ba 100644
--- a/templates/base.qtpl
+++ b/templates/base.qtpl
@@ -33,16 +33,16 @@ Page prints a page implementing Page interface.
<body>
<nav class="navbar">
<div class="navbar-start">
- <a href="/fs/" class="navbar-item">
- files
+ <a href="/fs/" class="navbar-item text-size-1">
+ file
</a>
- <a href="/media/" class="navbar-item">
+ <a href="/media/" class="navbar-item text-size-1">
media
</a>
- <a href="/album/" class="navbar-item">
+ <a href="/album/" class="navbar-item text-size-1">
album
</a>
- <a href="/settings/" class="navbar-item">
+ <a href="/settings/" class="navbar-item text-size-1">
settings
</a>
</div>
diff --git a/templates/fs.qtpl b/templates/fs.qtpl
index 489f79f..3dc2c5a 100644
--- a/templates/fs.qtpl
+++ b/templates/fs.qtpl
@@ -14,7 +14,7 @@ type FilePage struct {
<div class="panel-block">
<div class="columns file-row is-gapless is-mobile">
<div id="path" class="container-fluid">
- <small>{% for _, h := range p.Page.History %}<a href="/fs?path={%s h.UrlEncodedPath %}" >{%s h.Name %}/</a>{% endfor %}</small>
+ <small>{% for _, h := range p.Page.History %}<a class="text-size-2" href="/fs?path={%s h.UrlEncodedPath %}" >{%s h.Name %}/</a>{% endfor %}</small>
</div>
</div>
</div>
@@ -22,15 +22,17 @@ type FilePage struct {
<div class="panel-block">
<div class="columns wide-column is-mono is-gapless is-mobile">
<div class="column">
+ <span class="text-size-2">
{% if p.ShowMode %}{%s f.Info.Mode().String() %}&emsp;{% endif %}
{% if p.ShowOwner %}{%d f.GetGid() %}:{%d f.GetUid() %}&emsp;{% endif %}
{% if f.Info.IsDir() %}
- <a href="/?path={%s f.UrlEncodedPath %}">{%s f.Info.Name() %}/</a>
+ </span>
+ <a class="text-size-2" href="/?path={%s f.UrlEncodedPath %}">{%s f.Info.Name() %}/</a>
{% else %}
{%s f.Info.Name() %}
{% endif %}
</div>
- <div class="column has-text-right">{%dl f.Info.Size() %} B</div>
+ <div class="column text-size-2 has-text-right">{%dl f.Info.Size() %} B</div>
</div>
</div>
{% endfor %}
diff --git a/templates/media.qtpl b/templates/media.qtpl
index ae58e61..11fc9bc 100644
--- a/templates/media.qtpl
+++ b/templates/media.qtpl
@@ -33,7 +33,7 @@ func (m *MediaPage) PreloadAttr() string {
</div>
{% endfor %}
</div>
-<div class="row">
+<div>
<a href="/media/?page={%d p.Next.Page %}" class="button is-pulled-right">next</a>
</div>
{% endfunc %}
diff --git a/templates/settings.qtpl b/templates/settings.qtpl
index 4207439..3d1af81 100644
--- a/templates/settings.qtpl
+++ b/templates/settings.qtpl
@@ -15,7 +15,7 @@ type SettingsPage struct {
<form action="/settings/", method="post">
<div class="field">
<div class="control">
- <label class="checkbox">
+ <label class="checkbox text-size-2">
<input type="checkbox" id="showMode" name="showMode" {% if p.Settings.ShowMode %}checked{% endif %}>
Show File Modes
</label>
@@ -23,7 +23,7 @@ type SettingsPage struct {
</div>
<div class="field">
<div class="control">
- <label class="checkbox">
+ <label class="checkbox text-size-2">
<input type="checkbox" id="showOwner" name="showOwner" {% if p.Settings.ShowOwner %}checked{% endif %}>
Show File Owner
</label>
@@ -31,7 +31,7 @@ type SettingsPage struct {
</div>
<div class="field">
<div class="control">
- <label class="checkbox">
+ <label class="checkbox text-size-2">
<input type="checkbox" id="preloadVideoMetadata" name="preloadVideoMetadata" {% if p.Settings.PreloadVideoMetadata %}checked{% endif %}>
Preload video metadata
</label>
@@ -44,12 +44,12 @@ type SettingsPage struct {
</div>
<div class="column">
{% for _, user := range p.Users %}
- <div class="panel-block">
+ <div class="panel-block field">
<div class="columns wide-column is-gapless is-mobile">
- <div class="column">
+ <div class="column text-size-2">
{%s user.Username %}
</div>
- <div class="column">
+ <div class="column text-size-2">
{%s user.Path %}
</div>
<div class="column has-text-right"><a href="/users?userId={%s FromUInttoString(&user.ID) %}">Edit</a> <a href="/users/delete?userId={%s FromUInttoString(&user.ID) %}" class="is-danger">Delete</a></div>
@@ -57,7 +57,7 @@ type SettingsPage struct {
</div>
{% endfor %}
<div class="field">
- <a href="/users/" class="button">Create</a>
+ <a href="/users/" class="button">create</a>
</div>
</div>
</div>