Skip to content

Commit e32be8c

Browse files
committed
tweak css
* unify style by using shared variables instead of endless re-definitions * drop unused features to minimize size
1 parent b0b1fe0 commit e32be8c

File tree

12 files changed

+126
-114
lines changed

12 files changed

+126
-114
lines changed

_includes/header.html

+10-9
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,15 @@
11
<header id="site-header">
22
<div class="container d-lg-flex" style="padding-top: 3rem; padding-bottom: 3rem;">
3-
<div class="site-branding text-center text-lg-start me-auto align-self-md-center" style="padding: 4rem 0">
3+
<div class="text-center text-lg-start me-auto align-self-md-center" style="padding: 4rem 0">
4+
<div class="site-branding">
5+
<h1 class="site-title">
6+
<a href="{% link index.md %}" rel="home">{{ site.title }}</a>
7+
</h1>
48

5-
<h1 class="site-title">
6-
<a href="{% link index.md %}" rel="home">{{ site.title }}</a>
7-
</h1>
8-
9-
<p class="site-description">
10-
<span>{{ site.description }}</span>
11-
</p>
9+
<p class="site-description">
10+
<span>{{ site.description }}</span>
11+
</p>
12+
</div>
1213
</div>
1314

1415
<div class="d-none d-lg-block align-self-md-center">
@@ -26,7 +27,7 @@ <h1 class="site-title">
2627
<a href="{{ entry.items[0].url | relative_url }}">{{ entry.title }}</a>
2728
<div class="sub-menu-wrapper">
2829
<div class="container">
29-
<ul class="sub-menu navbar-nav">
30+
<ul class="sub-menu">
3031
{% for item in entry.items %}
3132
<li>
3233
<a class="menu-item{% if item.url == page.url %} current-menu-item current_page_item current_page_parent{% endif %}"

_includes/sidebar/alex.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@ <h2 class="widget-title">ALEX</h2>
1616
</thead>
1717
<tbody>
1818
<tr>
19-
<td><span class="badge bg-secondary text-light align-text-top">3.0.0</span> May 24, 2022</td>
19+
<td><span class="badge bg-secondary align-text-top">3.0.0</span> May 24, 2022</td>
2020
<td><a href="https://github.com/LearnLib/alex/releases/download/v3.0.0/docker-compose.alex-3.0.0.yml">Download</a></td>
2121
</tr>
2222
<tr>
23-
<td><span class="badge bg-secondary text-light align-text-top">2.1.1</span> Apr 21, 2021</td>
23+
<td><span class="badge bg-secondary align-text-top">2.1.1</span> Apr 21, 2021</td>
2424
<td><a href="https://github.com/LearnLib/alex/releases/download/v2.1.1/docker-compose.alex-2.1.1.yml">Download</a></td>
2525
</tr>
2626
<tr>
27-
<td><span class="badge bg-secondary text-light align-text-top">2.0.0</span> Jun 12, 2020</td>
27+
<td><span class="badge bg-secondary align-text-top">2.0.0</span> Jun 12, 2020</td>
2828
<td><a href="https://github.com/LearnLib/alex/releases/download/v2.0.0/alex-2.0.0.war">Download</a></td>
2929
</tr>
3030
</tbody>

_includes/sidebar/automatalib.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@ <h2 class="widget-title">AutomataLib</h2>
1616
</thead>
1717
<tbody>
1818
<tr>
19-
<td><span class="badge bg-secondary text-light align-text-top">0.11.0</span> Nov 6, 2023</td>
19+
<td><span class="badge bg-secondary align-text-top">0.11.0</span> Nov 6, 2023</td>
2020
<td><a href="http://learnlib.github.io/automatalib/maven-site/0.11.0/">API</a></td>
2121
</tr>
2222
<tr>
23-
<td><span class="badge bg-secondary text-light align-text-top">0.10.0</span> Oct 11, 2020</td>
23+
<td><span class="badge bg-secondary align-text-top">0.10.0</span> Oct 11, 2020</td>
2424
<td><a href="http://learnlib.github.io/automatalib/maven-site/0.10.0/">API</a></td>
2525
</tr>
2626
<tr>
27-
<td><span class="badge bg-secondary text-light align-text-top">0.9.0</span> Feb 5, 2020</td>
27+
<td><span class="badge bg-secondary align-text-top">0.9.0</span> Feb 5, 2020</td>
2828
<td><a href="http://learnlib.github.io/automatalib/maven-site/0.9.0/">API</a></td>
2929
</tr>
3030
</tbody>

_includes/sidebar/learnlib.html

+3-3
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,15 @@ <h2 class="widget-title">LearnLib</h2>
1616
</thead>
1717
<tbody>
1818
<tr>
19-
<td><span class="badge bg-secondary text-light align-text-top">0.17.0</span> Nov 15, 2023</td>
19+
<td><span class="badge bg-secondary align-text-top">0.17.0</span> Nov 15, 2023</td>
2020
<td><a href="http://learnlib.github.io/learnlib/maven-site/0.17.0/">API</a></td>
2121
</tr>
2222
<tr>
23-
<td><span class="badge bg-secondary text-light align-text-top">0.16.0</span> Oct 12, 2020</td>
23+
<td><span class="badge bg-secondary align-text-top">0.16.0</span> Oct 12, 2020</td>
2424
<td><a href="http://learnlib.github.io/learnlib/maven-site/0.16.0/">API</a></td>
2525
</tr>
2626
<tr>
27-
<td><span class="badge bg-secondary text-light align-text-top">0.15.0</span> Feb 6, 2020</td>
27+
<td><span class="badge bg-secondary align-text-top">0.15.0</span> Feb 6, 2020</td>
2828
<td><a href="http://learnlib.github.io/learnlib/maven-site/0.15.0/">API</a></td>
2929
</tr>
3030
</tbody>

_layouts/default.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!DOCTYPE html>
2-
<html lang="{{ page.lang | default: site.lang | default: 'en' }}">
2+
<html dir="ltr" lang="{{ page.lang | default: site.lang | default: 'en' }}">
33

44
{%- include head.html -%}
55

_sass/base.scss

+29-14
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,5 @@
1-
html {
2-
font-family: sans-serif;
3-
line-height: 1.15;
4-
}
5-
61
body {
7-
color: #3e3e3e;
8-
background: #202831;
2+
background: $tertiary;
93
}
104

115
a {
@@ -38,13 +32,30 @@ img {
3832
@extend .img-fluid;
3933
}
4034

35+
pre {
36+
padding: 0.5rem;
37+
background-color: $gray-200;
38+
@extend .rounded;
39+
}
40+
41+
pre > code {
42+
padding: 0;
43+
}
44+
45+
code {
46+
padding: 0.2rem 0.4rem;
47+
background-color: $gray-200;
48+
@extend .highlight;
49+
@extend .rounded;
50+
}
51+
4152
#site-header {
4253
background: url("/assets/images/header-soft.jpg");
4354
background-size: cover;
4455
}
4556

4657
#content {
47-
background: #fff;
58+
background: $body-bg;
4859
padding: 3rem 0;
4960
}
5061

@@ -54,21 +65,25 @@ img {
5465

5566
#content h2:not(:first-of-type) {
5667
padding-top: 2rem;
57-
border-top: 2px solid #eaecef;
68+
border-top: 2px solid $border-color;
5869
margin-top: 2.5rem;
5970
}
6071

6172
#site-footer {
62-
background: #262f38;
63-
color: #89939e;
73+
background: lighten($tertiary, 3%);
74+
color: $gray-600;
6475
}
6576

6677
#site-footer nav {
6778
padding: 1rem 0;
6879
}
6980

7081
#site-footer a {
71-
color: #ccc;
82+
color: $gray-400;
83+
}
84+
85+
#site-footer p {
86+
margin-bottom: 0;
7287
}
7388

7489
#site-footer .tu-link {
@@ -80,6 +95,6 @@ img {
8095
}
8196

8297
#copyright {
83-
padding: 1rem 0;
84-
background: #202831;
98+
padding: 1.5rem 0;
99+
background: $tertiary;
85100
}

_sass/branding.scss

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,21 +13,21 @@
1313
display: inline-block;
1414
font-weight: 700;
1515
font-size: 2.4rem;
16-
color: #fff;
16+
color: $light;
1717
padding: .25rem .75rem;
1818
background: $primary;
1919
text-decoration: none;
2020
}
2121

2222
.site-branding .site-description {
23-
color: #fff;
23+
color: $light;
2424
margin-bottom: 0;
2525
}
2626

2727
.site-branding .site-description span {
2828
border-radius: 0.25rem;
2929
padding: .1rem .75rem;
30-
background: #c3456d;
30+
background: $secondary;
3131
display: inline-block;
3232
margin-top: .15rem;
3333
}

_sass/features.scss

+2-5
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
@import "bootstrap/variables";
22

33
// Variables
4-
$box-shadow: 0px 2px 2px rgba(0, 0, 0, 0.5);
5-
$border-radius: 0.5rem;
6-
74
$purple-gradient: linear-gradient(0deg, rgba(117, 60, 199, 1) 0%, rgba(191, 139, 230, 1) 100%);
85
$green-gradient: linear-gradient(0deg, rgba(84, 166, 33, 1) 0%, rgba(161, 217, 64, 1) 100%);
96
$orange-gradient: linear-gradient(0deg, rgba(227, 138, 16, 1) 0%, rgba(240, 173, 9, 1) 100%);
@@ -59,8 +56,8 @@ $orange-gradient: linear-gradient(0deg, rgba(227, 138, 16, 1) 0%, rgba(240, 173,
5956
.feature-header,
6057
.feature-item {
6158
display: flex;
62-
color: #fff;
63-
box-shadow: $box-shadow;
59+
color: $light;
60+
box-shadow: $box-shadow-sm;
6461
font-weight: 700;
6562
border-radius: $border-radius;
6663
font-size: 1rem;

_sass/navigation.scss

+30-34
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,28 @@
22
@import "bootstrap/mixins";
33

44
#site-navigation {
5-
background: #212125;
6-
border-bottom: 3px solid #5979d8;
5+
background: $tertiary;
6+
border-bottom: 3px solid $primary;
7+
}
8+
9+
#site-navigation a {
10+
text-decoration: none;
11+
}
12+
13+
#site-navigation ul {
14+
list-style-type: none;
15+
padding: 0;
16+
margin: 0;
17+
}
18+
19+
#site-navigation ul li {
20+
display: inline-block;
21+
}
22+
23+
#site-navigation ul li a {
24+
display: inline-block;
25+
padding: 1rem 1rem;
26+
color: $light;
727
}
828

929
#site-navigation .menu {
@@ -23,11 +43,7 @@
2343
}
2444

2545
#site-navigation .current_page_ancestor .current-menu-item a {
26-
color: #fff;
27-
}
28-
29-
#site-navigation .navbar-toggler {
30-
border: none;
46+
color: $light;
3147
}
3248

3349
#site-navigation .menu-item-has-children > a:after {
@@ -43,36 +59,16 @@
4359

4460
#site-navigation .current_page_ancestor > a, #site-navigation .current_page_parent > a {
4561
position: relative;
46-
background: #4968c5;
62+
background: darken($primary, 5%);
4763
}
4864

4965
#site-navigation .current_page_ancestor > a:after, #site-navigation .current_page_parent > a:after {
5066
transform: rotate(90deg);
5167
}
5268

53-
#site-navigation a {
54-
text-decoration: none;
55-
}
56-
57-
#site-navigation ul {
58-
list-style-type: none;
59-
padding: 0;
60-
margin: 0;
61-
}
62-
63-
#site-navigation ul li {
64-
display: inline-block;
65-
}
66-
67-
#site-navigation ul li a {
68-
display: inline-block;
69-
padding: 1rem 1rem;
70-
color: #dcdcdc;
71-
}
72-
7369
#site-navigation .sub-menu-wrapper {
7470
position: absolute;
75-
background: #5979d8;
71+
background: $primary;
7672
left: 0;
7773
width: 100%;
7874
}
@@ -84,10 +80,11 @@
8480
#site-navigation .sub-menu-wrapper .sub-menu a {
8581
padding: .5rem .75rem;
8682
display: block;
83+
@extend .rounded;
8784
}
8885

8986
#site-navigation .sub-menu-wrapper .sub-menu a:hover {
90-
background: rgba(0, 0, 0, 0.05);
87+
background: rgba(0, 0, 0, 0.1);
9188
}
9289

9390
@include media-breakpoint-down(lg) {
@@ -115,11 +112,11 @@
115112

116113
@include media-breakpoint-up(lg) {
117114
#site-navigation .menu-item-has-children:not(.current-menu-ancestor):hover {
118-
background: #fff;
115+
background: $light;
119116
}
120117

121118
#site-navigation .menu-item-has-children:not(.current-menu-ancestor):hover a {
122-
color: #202831;
119+
color: $body-color;
123120
}
124121

125122
#site-navigation .menu-item-has-children:not(.current-menu-ancestor):hover a:after {
@@ -132,7 +129,7 @@
132129
z-index: 2;
133130
left: auto;
134131
width: auto;
135-
background: #fff;
132+
background: $light;
136133
box-shadow: 0 3px 3px rgba(0, 0, 0, 0.4);
137134
}
138135

@@ -150,7 +147,6 @@
150147
}
151148

152149
#site-navigation .menu-item-has-children:not(.current-menu-ancestor):hover .sub-menu-wrapper .sub-menu li a {
153-
color: #202831;
154150
padding: 1rem 1.5rem;
155151
}
156152
}

_sass/syntax.scss

-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,7 @@
11
.highlight table td { padding: 5px; }
22
.highlight table pre { margin: 0; }
3-
.highlight pre {
4-
padding: 1rem;
5-
}
63
.highlight, .highlight .w {
74
color: #24292f;
8-
background-color: #f6f8fa;
95
}
106
.highlight .k, .highlight .kd, .highlight .kn, .highlight .kp, .highlight .kr, .highlight .kt, .highlight .kv {
117
color: #cf222e;

0 commit comments

Comments
 (0)