Skip to content

Commit 0d6ddf9

Browse files
Improve styling.
1 parent f8cb01d commit 0d6ddf9

File tree

2 files changed

+20
-19
lines changed

2 files changed

+20
-19
lines changed

src/header.go

Lines changed: 18 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -22,23 +22,23 @@ const headerTemplate = `
2222
body {
2323
font-family: Roboto,Helvetica,sans-serif;
2424
background: #ddd;
25-
margin-left: auto;
26-
margin-right: auto;
27-
margin-top: 20px;
25+
margin: 1em auto;
2826
max-width: 1000px;
2927
}
3028
li {
31-
margin-top: 1em;
32-
margin-bottom: 1em;
33-
margin-right: 1em;
29+
border-radius: 10px;
30+
margin: 0.5em;
31+
padding: 0.5em;
3432
}
3533
h1 {
36-
font-size: 25px;
34+
font-size: 2em;
3735
color: #efefef;
3836
width: 80%;
3937
float: left;
4038
}
4139
ul {
40+
padding: 0.5em;
41+
list-style-type: none; /* Disable bullet points */
4242
border-radius: 10px;
4343
border:1px solid #c0c0c0;
4444
background: #f5f5f5;
@@ -58,6 +58,9 @@ const headerTemplate = `
5858
p {
5959
margin: 0px;
6060
}
61+
#container {
62+
margin: 1em;
63+
}
6164
.author {
6265
color: #666;
6366
}
@@ -96,7 +99,7 @@ const headerTemplate = `
9699
font-size: 12px;
97100
}
98101
:target {
99-
background-color: #f6ba81;
102+
background-color: #ffb772;
100103
}
101104
#left-header {
102105
flex: 4;
@@ -132,6 +135,8 @@ const headerTemplate = `
132135
background: #333 url('assets/open-access.svg') right/25% no-repeat;
133136
}
134137
#censorbib-description {
138+
font-size: 1.15em;
139+
text-align: justify;
135140
padding: 1em;
136141
flex: 5;
137142
}
@@ -168,15 +173,9 @@ const headerTemplate = `
168173
<div class="flex-row">
169174
170175
<div id="censorbib-description">
171-
CensorBib is an online archive of selected research papers in the field
172-
of Internet censorship. Most papers on CensorBib approach the topic
173-
from a technical angle, by proposing designs that circumvent censorship
174-
systems, or by measuring how censorship works. The icons next to each
175-
paper make it easy to download, cite, and link to papers. If you think
176-
I missed a paper,
177-
<a href="https://github.com/NullHypothesis/censorbib">
178-
make a pull request
179-
</a>.
176+
CensorBib is an archive of selected academic research papers on
177+
Internet censorship. If you think I missed a paper,
178+
<a href="https://github.com/NullHypothesis/censorbib">make a pull request</a>.
180179
Finally, the
181180
<a href="https://github.com/net4people/bbs/issues">net4people/bbs forum</a>
182181
has reading groups for many of the papers listed below.
@@ -189,7 +188,7 @@ const headerTemplate = `
189188
</div>
190189
<div class="menu-item">
191190
<img class="top-icon" src="assets/update-icon.svg" alt="update icon">
192-
<a href="https://github.com/NullHypothesis/censorbib/commits/master">Last update: {{.Date}}</a>
191+
<a href="https://github.com/NullHypothesis/censorbib/commits/master">Updated: {{.Date}}</a>
193192
</div>
194193
</div> <!-- censorbib-links -->
195194
@@ -204,7 +203,7 @@ const headerTemplate = `
204203
</div>
205204
206205
<div id="book-info" style="flex: 0 1 auto">
207-
Are you a researcher? If so, you may like my book
206+
Are you a researcher? You may like my book
208207
<a href="http://research-power-tools.com">Research Power Tools</a>.
209208
</div>
210209
</div>

src/main.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -97,9 +97,11 @@ func parseCiteName(line string) string {
9797
}
9898

9999
func run(w io.Writer, bibEntries []bibEntry) {
100+
fmt.Fprintln(w, "<div id='container'>")
100101
fmt.Fprint(w, header())
101102
makeBib(w, bibEntries)
102103
fmt.Fprint(w, footer())
104+
fmt.Fprintln(w, "</div>")
103105
}
104106

105107
func main() {

0 commit comments

Comments
 (0)