From f044debe57769905b3bb0571b8a0d9f36016783a Mon Sep 17 00:00:00 2001 From: Linerly Date: Fri, 19 Apr 2024 20:01:13 +0700 Subject: [PATCH] Improve layout --- content/community.md | 2 + layouts/_default/baseof.html | 201 ++++++++-------- layouts/_default/summary.html | 8 + layouts/blog/blog.html | 2 +- layouts/index.html | 1 + public/admin/config.yml | 30 +-- public/blog/index.html | 215 +++++++++--------- public/blog/index.xml | 2 +- .../welcome-to-the-mediaplay-blog/index.html | 209 ++++++++--------- public/community/index.html | 211 ++++++++--------- public/css/main.css | 6 +- public/css/navbar.css | 3 +- public/css/slideshow.css | 4 +- public/index.html | 210 ++++++++--------- public/index.xml | 2 +- static/css/main.css | 6 +- static/css/navbar.css | 3 +- static/css/slideshow.css | 4 +- 18 files changed, 546 insertions(+), 573 deletions(-) create mode 100644 layouts/_default/summary.html diff --git a/content/community.md b/content/community.md index 27d9a7b..635298e 100644 --- a/content/community.md +++ b/content/community.md @@ -1,6 +1,8 @@ +++ title = 'Community' date = 2024-04-19T06:36:53+07:00 +author = 'TechNewVideo' +discord = '@technewvideo' +++ *If you're new to here, welcome! 👋* diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index 4ebae51..840d083 100755 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -1,128 +1,117 @@ - - - - - - - - - - - - {{ block "title" . }}{{ $title := site.Title }}{{ if not .IsHome }}{{ $title = printf "%s - %s" .Title site.Title }}{{ end }}{{ $title }}{{ end }} - - - + + + - - + + + + + + + + + + {{ block "title" . }}{{ $title := site.Title }}{{ if not .IsHome }}{{ $title = printf "%s - %s" .Title site.Title }}{{ end }}{{ $title }}{{ end }} + + + + - - - + + + - -
- - + + \ No newline at end of file diff --git a/layouts/_default/summary.html b/layouts/_default/summary.html new file mode 100644 index 0000000..4fc5915 --- /dev/null +++ b/layouts/_default/summary.html @@ -0,0 +1,8 @@ +
+

{{ .Title }}

+

+ {{ .Summary | replaceRE "(’)" "’" | replaceRE "(—)" "—" | replaceRE "([.:]$)" "…"}} +

+ by {{ .Params.author }} ({{ .Params.discord }}) · around {{ .ReadingTime }} {{ cond (eq .ReadingTime 1) "minute" "minutes" }} · published on {{ .Date.Format "2006-01-02" }} · {{ .WordCount }} words +
+
diff --git a/layouts/blog/blog.html b/layouts/blog/blog.html index 347d64c..df02c1f 100644 --- a/layouts/blog/blog.html +++ b/layouts/blog/blog.html @@ -5,7 +5,7 @@

Blog posts from members — subscribe to the RSS feed

- {{- range where .Site.RegularPages "Type" "blog" -}} + {{ range where .Site.RegularPages "Type" "blog" }} {{ .Render "summary" }} {{ end }}
diff --git a/layouts/index.html b/layouts/index.html index fa44917..9d83bfd 100644 --- a/layouts/index.html +++ b/layouts/index.html @@ -239,6 +239,7 @@
+
{{ .Content }} diff --git a/public/admin/config.yml b/public/admin/config.yml index 885c5c4..6defebc 100644 --- a/public/admin/config.yml +++ b/public/admin/config.yml @@ -22,18 +22,18 @@ collections: - { label: 'Author', name: 'author', widget: 'string' } - { label: 'Discord Profile', name: 'discord', widget: 'string' } - { label: 'Body', name: 'body', widget: 'markdown' } - - name: 'content' - label: 'Blog' - folder: 'content/blog' - create: true - slug: '{{slug}}' - preview_path: blog/{{slug}} - editor: - preview: true - fields: - - { label: 'Title', name: 'title', widget: 'string' } - - { label: 'Publish Date', name: 'date', widget: 'datetime' } - - { label: 'Draft', name: 'draft', widget: 'boolean', default: true } - - { label: 'Author', name: 'author', widget: 'string' } - - { label: 'Discord Profile', name: 'discord', widget: 'string' } - - { label: 'Body', name: 'body', widget: 'markdown' } + - name: 'blog' + label: 'Blog' + folder: 'content/blog' + create: true + slug: '{{slug}}' + preview_path: blog/{{slug}} + editor: + preview: true + fields: + - { label: 'Title', name: 'title', widget: 'string' } + - { label: 'Publish Date', name: 'date', widget: 'datetime' } + - { label: 'Draft', name: 'draft', widget: 'boolean', default: true } + - { label: 'Author', name: 'author', widget: 'string' } + - { label: 'Discord Profile', name: 'discord', widget: 'string' } + - { label: 'Body', name: 'body', widget: 'markdown' } \ No newline at end of file diff --git a/public/blog/index.html b/public/blog/index.html index fe279b7..2d8cf83 100644 --- a/public/blog/index.html +++ b/public/blog/index.html @@ -1,135 +1,134 @@ - - - - - - - - - - - - Blog - MediaPlay - - - + + + - - + + + + + + + + + + Blog - MediaPlay + + + + - - - - - -
- - + + \ No newline at end of file diff --git a/public/blog/index.xml b/public/blog/index.xml index 27dc585..fa7a376 100644 --- a/public/blog/index.xml +++ b/public/blog/index.xml @@ -4,7 +4,7 @@ Blogs on MediaPlay http://localhost:1313/blog/ Recent content in Blogs on MediaPlay - Hugo -- gohugo.io + Hugo 0.125.1 en-us Fri, 19 Apr 2024 06:44:53 +0700 diff --git a/public/blog/welcome-to-the-mediaplay-blog/index.html b/public/blog/welcome-to-the-mediaplay-blog/index.html index a0a7615..919ac21 100644 --- a/public/blog/welcome-to-the-mediaplay-blog/index.html +++ b/public/blog/welcome-to-the-mediaplay-blog/index.html @@ -1,92 +1,88 @@ - - - - - - - - - - - - - Welcome to the MediaPlay blog! - MediaPlay - - - - - + + + + + + + + + + + + + + Welcome to the MediaPlay blog! - MediaPlay + + + + + + + + + + + - - - - - -
- - + + \ No newline at end of file diff --git a/public/community/index.html b/public/community/index.html index 9df6301..23e669d 100644 --- a/public/community/index.html +++ b/public/community/index.html @@ -1,96 +1,92 @@ - - - - - - - - - - - - Community - MediaPlay - - - + + + - - + + + + + + + + + + Community - MediaPlay + + + + + + + + + + + - - - - - -
- - + + \ No newline at end of file diff --git a/public/css/main.css b/public/css/main.css index 887b8f7..53dd277 100644 --- a/public/css/main.css +++ b/public/css/main.css @@ -82,10 +82,14 @@ code { font-family: "JetBrains Mono", monospace; } -p, h1, h2, h3, h4, h5, h6 { +p, sub, h1, h2, h3, h4, h5, h6 { color: #9fcedf; } +a { + color: #19afe6; +} + p { font-size: 16pt; } diff --git a/public/css/navbar.css b/public/css/navbar.css index c48c692..181c8f3 100644 --- a/public/css/navbar.css +++ b/public/css/navbar.css @@ -7,8 +7,7 @@ .container { height: 105px; - background: rgb(13,19,71); - background: linear-gradient(180deg, rgba(13,19,71,1) 0%, rgba(17,23,66,1) 100%); + background: linear-gradient(180deg, rgba(13,19,71,1) 0%, rgba(17,23,66,0) 100%); display: -webkit-box; display: -ms-flexbox; display: flex; diff --git a/public/css/slideshow.css b/public/css/slideshow.css index 74ee5c4..f1aaf44 100644 --- a/public/css/slideshow.css +++ b/public/css/slideshow.css @@ -1,5 +1,5 @@ .slideshow-container { - max-width: clamp(250px, 75%, 850px); + max-width: 800px; position: relative; margin: auto; } @@ -80,5 +80,5 @@ .active, .dot:hover { - background-color: #0d1347; + background-color: #00adec; } \ No newline at end of file diff --git a/public/index.html b/public/index.html index ce162b3..2610d44 100644 --- a/public/index.html +++ b/public/index.html @@ -1,93 +1,89 @@ - - - - - - - - - - - - - - MediaPlay - - - - - + + + + + + + + + + + + + + + MediaPlay + + + + + + + + + + + - - - - - -
- - - - -
- + + \ No newline at end of file diff --git a/public/index.xml b/public/index.xml index 769a241..8137700 100644 --- a/public/index.xml +++ b/public/index.xml @@ -4,7 +4,7 @@ MediaPlay http://localhost:1313/ Recent content on MediaPlay - Hugo -- gohugo.io + Hugo 0.125.1 en-us Fri, 19 Apr 2024 06:44:53 +0700 diff --git a/static/css/main.css b/static/css/main.css index 887b8f7..53dd277 100644 --- a/static/css/main.css +++ b/static/css/main.css @@ -82,10 +82,14 @@ code { font-family: "JetBrains Mono", monospace; } -p, h1, h2, h3, h4, h5, h6 { +p, sub, h1, h2, h3, h4, h5, h6 { color: #9fcedf; } +a { + color: #19afe6; +} + p { font-size: 16pt; } diff --git a/static/css/navbar.css b/static/css/navbar.css index c48c692..181c8f3 100644 --- a/static/css/navbar.css +++ b/static/css/navbar.css @@ -7,8 +7,7 @@ .container { height: 105px; - background: rgb(13,19,71); - background: linear-gradient(180deg, rgba(13,19,71,1) 0%, rgba(17,23,66,1) 100%); + background: linear-gradient(180deg, rgba(13,19,71,1) 0%, rgba(17,23,66,0) 100%); display: -webkit-box; display: -ms-flexbox; display: flex; diff --git a/static/css/slideshow.css b/static/css/slideshow.css index 74ee5c4..f1aaf44 100644 --- a/static/css/slideshow.css +++ b/static/css/slideshow.css @@ -1,5 +1,5 @@ .slideshow-container { - max-width: clamp(250px, 75%, 850px); + max-width: 800px; position: relative; margin: auto; } @@ -80,5 +80,5 @@ .active, .dot:hover { - background-color: #0d1347; + background-color: #00adec; } \ No newline at end of file