From 355a36e209d2d297c7b7c4b384f6ebffbd8968f4 Mon Sep 17 00:00:00 2001 From: Dym Sohin Date: Sat, 26 Aug 2023 04:40:17 +0200 Subject: [PATCH] updates --- assets/dist/profile.css | 19 ++++++++++++++----- template/about.tmpl | 12 +++++++++++- template/header.tmpl | 14 ++++++++++++-- template/profile.tmpl | 10 +++++----- 4 files changed, 42 insertions(+), 13 deletions(-) diff --git a/assets/dist/profile.css b/assets/dist/profile.css index f86973c..83083fb 100644 --- a/assets/dist/profile.css +++ b/assets/dist/profile.css @@ -257,11 +257,20 @@ .profile .about-user .fields { background: var(--profile-bg); display: grid; - grid-template: max-content 1fr; - padding: 0 0.5rem; + grid-template-columns: 6rem auto; } -.profile .about-user .fields .field + .field { +.profile .about-user .fields > * { + padding: 0.5rem; + } +.profile .about-user .fields > b { + align-self: flex-end; + justify-self: center; + } +.profile .about-user .fields > span { + } +.profile .about-user .fields > span + b, +.profile .about-user .fields > span + b + span { border-top: 0.1rem solid var(--gray2); } @@ -272,10 +281,10 @@ .profile .about-user .accountstats { background: var(--bg-accent); - padding: 1rem; + padding: 0.5rem; display: grid; - grid-template-columns: auto auto; + grid-template-columns: 6rem auto; gap: 0.5rem 1rem; } .profile .about-user .accountstats > b { diff --git a/template/about.tmpl b/template/about.tmpl index 10c5742..f9b4b80 100644 --- a/template/about.tmpl +++ b/template/about.tmpl @@ -50,7 +50,7 @@ @@ -94,6 +94,16 @@ {{end}}

+ +
+

statis

+ +
+ {{ template "footer.tmpl" .}} \ No newline at end of file diff --git a/template/header.tmpl b/template/header.tmpl index 53ead5b..00b4b28 100644 --- a/template/header.tmpl +++ b/template/header.tmpl @@ -16,10 +16,20 @@ // You should have received a copy of the GNU Affero General Public License // along with this program. If not, see . */ -}} +{{- /* + NESTED TEMPLATE DECLARATIONS + If some if/else macro is used multiple times, declare it once here instead. + When invoking these nested templates, remember to pass in the values passed + to the executing template, ie., use '{{ template "example" . }}' not + '{{ template "example" }}', otherwise you'll end up with empty variables. +*/ -}} +{{ define "thumbnailType" }}{{ if .instance.ThumbnailType }}{{ .instance.ThumbnailType }}{{ else }}image/png{{ end }}{{ end }} +{{ define "instanceTitle" }}{{ if .ogMeta }}{{ .ogMeta.Title }}{{ else }}{{ .instance.Title }} - GoToSocial{{ end }}{{ end }} +{{- /* + BOILERPLATE GOES HERE +*/ -}} - - diff --git a/template/profile.tmpl b/template/profile.tmpl index 6915e6b..2cb2ad1 100644 --- a/template/profile.tmpl +++ b/template/profile.tmpl @@ -66,15 +66,15 @@
{{ range .account.Fields }} {{emojify $.account.Emojis (noescape .Name)}} - {{replace 'https?://' '' {{emojify $.account.Emojis (noescape .Value)}} }} + {{emojify $.account.Emojis (noescape .Value)}} {{ end }}
- Joined - Posts{{.account.StatusesCount}} - Followed by{{.account.FollowersCount}} - Following{{.account.FollowingCount}} + join + posts{{.account.StatusesCount}} + follows{{.account.FollowingCount}} + followers{{.account.FollowersCount}}