Skip to content

Commit d32c2c7

Browse files
committed
update: refactor partials and their styles
1 parent 3c61b2d commit d32c2c7

File tree

19 files changed

+200
-127
lines changed

19 files changed

+200
-127
lines changed

assets/css/article.css

-18
This file was deleted.

assets/css/main.css renamed to assets/css/baseof.css

+7-5
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,11 @@ main {
1515
background-color: var(--bg-color);
1616
}
1717

18+
main {
19+
overflow-x: hidden;
20+
overflow-y: auto;
21+
}
22+
1823
a {
1924
color: var(--txt-minorcolor-dark);
2025
text-decoration: none;
@@ -25,9 +30,6 @@ a {
2530
}
2631
}
2732

28-
main {
29-
display: grid;
30-
place-content: center;
31-
place-items: center;
32-
row-gap: 1rem;
33+
img {
34+
max-width: 100%;
3335
}

assets/css/index.css renamed to assets/css/home.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
font-size: 18px;
2727
}
2828

29-
.home.list {
29+
.home.category {
3030
font-size: 22px;
3131
margin-top: 4rem;
3232

assets/css/layouts.css

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
main.home {
2+
display: grid;
3+
justify-content: center;
4+
justify-items: center;
5+
align-content: center;
6+
7+
> h2 {
8+
align-self: center;
9+
}
10+
}
11+
12+
main.section {
13+
display: flex;
14+
flex-direction: column;
15+
16+
> h2 {
17+
margin: 2rem auto;
18+
align-self: center;
19+
}
20+
}

assets/css/list.css

-17
This file was deleted.

assets/css/partials/article.css

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
.article {
2+
display: flex;
3+
flex-direction: column;
4+
5+
}
6+
7+
.article.header {
8+
margin: 1rem 0;
9+
height: fit-content;
10+
> h1 {
11+
text-align: center;
12+
font-size: 2rem;
13+
}
14+
> small {
15+
display: flex;
16+
17+
> li {
18+
list-style-type: '- ';
19+
margin: 0 2rem;
20+
font-size: 1rem;
21+
}
22+
}
23+
}

assets/css/partials/list.css

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
.list.navbar {
2+
margin: 1rem auto;
3+
}
4+
5+
.list.articles {
6+
overflow: auto;
7+
margin: 1rem auto;
8+
> li {
9+
list-style-type: none;
10+
margin: 1rem;
11+
}
12+
}

assets/css/single.css

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
.single {
2+
display: flex;
3+
flex-direction: column;
4+
justify-items: center;
5+
align-items: center;
6+
}
7+
8+
.single.nav {
9+
background-color: aquamarine;
10+
margin: 1rem;
11+
}
12+
13+
.single.article {
14+
margin: 0 12rem;
15+
}

assets/css/vars.css

-9
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,3 @@
1-
/* @font-face {
2-
font-family: 'go fonts';
3-
src:
4-
url('../font/Go-Regular.ttf') format('truetyle'),
5-
url('../font/Go-Bold.ttf') format('ttf'),
6-
url('../font/Go-Italic.ttf') format('truetyle'),
7-
url('../font/Go-Mono.ttf') format('truetyle');
8-
} */
9-
101
:root {
112
--font-base: 'consolas';
123

content/posts/8051-digital-clock/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ title: "8051MCU | 电子时钟"
33
date: 2023-12-13T08:33:24+08:00
44
slug: stc51-clock
55
tags: [embedded]
6-
links:
6+
links:
77
- title: 项目源码
88
description: 下次不写那么多注释了😌
99
website: https://github.com/Proxyerium/8051-digital-clock
+51
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
---
2+
title: 'Linguistics Notes'
3+
date: 2024-11-15T00:29:31+08:00
4+
slug: ''
5+
tags: []
6+
draft: true
7+
---
8+
9+
## hierarchy of linguistics
10+
11+
```txt
12+
sentences ___ syntax
13+
phrases ^^^
14+
words ___ morphology
15+
morphemes ^^^
16+
phonemes, phones ___ phonology
17+
features ^^^
18+
pronunciation --- phonetics
19+
```
20+
21+
## basic properties of language
22+
23+
1. communicativity(most basic): there must be a way to **produce** and **perceive** utterances.
24+
- 3 modalities of human lang: auditory-vocal, visual-gestural, vusual-written
25+
26+
2. semanticity: all forms have their meanings by some linking (subfield: semiotics)
27+
- (form, meaning) = sign
28+
- 3 kinds of sign: icon via physical feature, index via a sort of result, symbol via community convertion.
29+
30+
> is the sign always arbitrary?
31+
32+
(*Onomatopoeia* is when the word sounds like its meaning) have kinda iconic, so signs are not always arbirary.
33+
34+
35+
3. cultural transmission: no genetic influences on what lang you can learn, the lang you learn is solely determined by the people you interact with.
36+
37+
4. displacemant(most rare): we can use lang to talk about thing that are not in the current scenario.
38+
39+
5. productivity(human lang unique): linguistic units can be recombined to express novel meanings.
40+
41+
so, language is a learned system of signs that enables us to communicate an unlimited number of meanings about anything.
42+
43+
44+
## descriptive vs. prescriptive grammar
45+
46+
descriptive grammar: what this lang is like
47+
48+
prescriptive grammar: what this lang should be like
49+
50+
mental grammar: you unconsciously know the rules of your lang.
51+
An utterance that follows the rules you unconsciously know is so called **grammatical**, otherwise it's **ungrammatical**.

layouts/_default/baseof.html

+11-12
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,20 @@
11
<!DOCTYPE html>
22
<html lang="{{ .Site.Language }}">
33

4-
<head> {{ block "head" . }} {{ end }} </head>
4+
<head>
5+
<meta charset="utf-8">
6+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
57

6-
<body>
7-
8-
<main>
9-
{{ block "main" . }}
10-
{{ end }}
11-
</main>
12-
13-
<aside>
14-
{{ block "aside" . }}
15-
{{ end }}
16-
</aside>
8+
{{/* {{ block "title" . }} */}}
9+
<title>proxyerium's website</title>
1710

11+
{{ $styles := resources.Match "/css/**.css"}}
12+
{{ $bundle := $styles | resources.Concat "css/bundle.css" | minify }}
13+
<link rel="stylesheet" href="{{ $bundle.RelPermalink }}" />
14+
</head>
1815

16+
<body>
17+
{{ block "main" . }} {{ end }}
1918
</body>
2019

2120
</html>

layouts/_default/home.html

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
{{ define "main" }}
2+
3+
<main class="home">
4+
<div class="home hero">
5+
<h1>$ proxyerium</h1>
6+
</div>
7+
8+
<div class="home navbar">
9+
<nav>
10+
{{ range .Page.Params.links }}
11+
<a href="{{ .url }}">{{ .name }}</a>
12+
{{ end }}
13+
</nav>
14+
</div>
15+
16+
<div class="home category">
17+
{{ range .Site.Sections.ByWeight }}
18+
<a href="{{ .RelPermalink }}">::{{ .Title }} -></a>
19+
{{ end }}
20+
</div>
21+
</main>
22+
23+
24+
{{ end }}

layouts/_default/section.html

+7-18
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,10 @@
11
{{ define "main" }}
2-
<div id="list-navbar">
2+
<main class="section">
3+
<h2>{{ .Page.Title }}</h2>
4+
<nav class="list navbar">
35
<a href=".."><- back</a>
4-
</div>
5-
<h2 id="list-title">{{ .Page.Title }}</h2>
6-
<ul id="list-articles">
7-
{{ range .Pages.ByDate.Reverse }}
8-
<li>
9-
<a href="{{ .RelPermalink }}">
10-
{{ .Title }}
11-
<br>
12-
{{ .Date.Format "2006-01-02" }}
13-
</a>
14-
</li>
15-
{{ end }}
16-
</ul>
17-
{{ end }}
18-
19-
{{ define "footer" }}
20-
{{ partial "footer" . }}
6+
</nav>
7+
{{ .Content }}
8+
{{ partial "list" . }}
9+
</main>
2110
{{ end }}

layouts/_default/single.html

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
{{ define "title" }}
2-
{{ .Page.Title }}
3-
{{ end }}
4-
51
{{ define "main" }}
6-
<div class="single-back" style="margin-left: 2vw">
2+
<main class="single">
3+
<nav class="single nav">
4+
{{/* {{ particle "back" .}} */}}
75
<a href="..">~{{ .RelPermalink }}</a>
8-
</div>
9-
{{ partial "article" . }}
6+
</nav>
7+
<article class="single article">
8+
{{ partial "article" . }}
9+
</article>
10+
</main>
1011
{{ end }}

layouts/index.html

-21
This file was deleted.

layouts/partials/article.html

+9-5
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
1-
<div class="article">
2-
<header id="article-title">
1+
<article class="article">
2+
<header class="article header">
33
<h1>{{ .Title }}</h1>
4-
created: {{ .Date.Format "2006-01-02" }}
4+
{{ if eq .Kind "page" }}
5+
<small>
6+
<li>created {{ .Date.Format "2006-01-02" }}</li>
7+
</small>
8+
{{ end }}
59
</header>
610

7-
<main id="article-content">
11+
<main class="article content">
812
{{ .Content }}
913
</main>
10-
</div>
14+
</article>

layouts/partials/head.html

-13
This file was deleted.

layouts/partials/list.html

+11
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<ul class="list articles">
2+
{{ range .Pages.ByDate.Reverse }}
3+
<li>
4+
<a href="{{ .RelPermalink }}">
5+
{{ .Title }}
6+
<br>
7+
{{ .Date.Format "2006-01-02" }}
8+
</a>
9+
</li>
10+
{{ end }}
11+
</ul>

0 commit comments

Comments
 (0)