Skip to content

Commit 5d2c0e1

Browse files
authored
Merge #350 from saitheninja/update-deps
Related issue: #228 Things done in this pull request: - Update Bootstrap from 5.0 beta to 5.3.3. - Remove old normalize.css. Bootstrap already includes its own [reboot](https://getbootstrap.com/docs/5.3/content/reboot/). - Remove jquery. It isn't a dependency of Bootstrap in v5. The bootstrap.bundle.js includes popper.js as a replacement. - Update nix-shell, because the ruby version was too old to build. - Update navbar to match previous styling. There's also some new CSS classes to target things better. - Update fonts. Serif fonts weren't being used at all, and Inter wasn't being loaded in some places. Also Lato isn't being used at all anymore, so I removed the old files. - Clean up some CSS. TODO: There's some scripts that need to get their references updated to the correct filenames: - core: https://github.com/neovim/neovim/blob/40ce8577977fcdce8ad76863c70eb522e4cefd4d/scripts/gen_help_html.lua#L829 - docs: https://github.com/neovim/doc/blob/6f805e0d6085bd29ef881dcfe907638c943aac75/templates/report-header.sh.html#L11
2 parents e4dc3c1 + a23406f commit 5d2c0e1

27 files changed

+91
-255
lines changed

_includes/nav.html

Lines changed: 28 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -6,50 +6,51 @@
66
</a>
77

88
<button
9+
class="navbar-toggler"
910
type="button"
1011
data-bs-toggle="collapse"
11-
data-bs-target="#neovim-navbar"
12-
class="navbar-toggler"
12+
data-bs-target="#navbarNav"
1313
aria-expanded="false"
1414
aria-label="Main menu"
1515
>
16-
<span class="navbar-toggler-icon">
17-
<svg
18-
xmlns="http://www.w3.org/2000/svg"
19-
width="24"
20-
height="24"
21-
viewBox="0 0 24 24"
22-
fill="none"
23-
stroke="currentColor"
24-
stroke-width="2"
25-
stroke-linecap="round"
26-
stroke-linejoin="round"
27-
class="feather feather-menu"
28-
>
29-
<line x1="3" y1="12" x2="21" y2="12"></line>
30-
<line x1="3" y1="6" x2="21" y2="6"></line>
31-
<line x1="3" y1="18" x2="21" y2="18"></line>
32-
</svg>
33-
</span>
16+
<svg
17+
xmlns="http://www.w3.org/2000/svg"
18+
width="24"
19+
height="24"
20+
viewBox="0 0 24 24"
21+
fill="none"
22+
stroke="currentColor"
23+
stroke-width="2"
24+
stroke-linecap="round"
25+
stroke-linejoin="round"
26+
>
27+
<line x1="3" y1="12" x2="21" y2="12"></line>
28+
<line x1="3" y1="6" x2="21" y2="6"></line>
29+
<line x1="3" y1="18" x2="21" y2="18"></line>
30+
</svg>
3431
</button>
32+
3533
<div
3634
class="collapse navbar-collapse justify-content-end"
37-
id="neovim-navbar"
35+
id="navbarNav"
3836
>
3937
<ul class="navbar-nav">
40-
{% for nav in site.data.nav %} {% assign active = include.active %} {%
41-
assign has_sections = nav.sections != null %} {% if has_sections %}
38+
{% for nav in site.data.nav %}
39+
{% assign active = include.active %}
40+
{% assign has_sections = nav.sections != null %}
41+
{% if has_sections %}
42+
4243
<li class="nav-item dropdown">
4344
<a
44-
href="#"
4545
class="nav-link dropdown-toggle"
46+
href="#"
47+
role="button"
4648
data-bs-toggle="dropdown"
4749
aria-expanded="false"
48-
id="neovim-dropdown"
49-
role="button"
50+
id="neovimDropdown"
5051
>{{ nav.title }}</a
5152
>
52-
<ul class="dropdown-menu" aria-labelledby="neovim-dropdown">
53+
<ul class="dropdown-menu" aria-labelledby="neovimDropdown">
5354
{% for section in nav.sections %}
5455

5556
<li>

_layouts/default.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3" />
1313
<link rel="preconnect" href="https://X185E15FPG-dsn.algolia.net" crossorigin />
1414

15-
<link href="/css/normalize.min.css" rel="stylesheet">
1615
<link href="/css/bootstrap.min.css" rel="stylesheet">
16+
1717
<link href="/css/main.css" rel="stylesheet">
1818
<link href="/css/neovim-hi.css" rel="stylesheet">
1919
<link rel="canonical" href="{{ site.url }}{% if page.canonical_url %}{{ page.canonical_url }}{% else %}{{ page.url }}{% endif %}" />
@@ -24,7 +24,7 @@
2424

2525
{% include footer.html %}
2626

27-
<script src="/js/bootstrap.min.js"></script>
27+
<script src="/js/bootstrap.bundle.min.js"></script>
2828

2929
<!-- algolia docsearch https://docsearch.algolia.com/docs/docsearch-v3/ -->
3030
<script src="https://cdn.jsdelivr.net/npm/@docsearch/js@3"></script>

css/bootstrap.css

Lines changed: 0 additions & 7 deletions
This file was deleted.

css/bootstrap.min.css

Lines changed: 3 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

css/bootstrap.min.css.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

css/lato.css

Lines changed: 0 additions & 136 deletions
This file was deleted.

css/main.css

Lines changed: 33 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,6 @@
33
:root {
44
--main-breakpoint: 60em;
55

6-
/* Serif fonts for body text. Easier to read for larger chunks */
7-
--serif-fonts: "Inter", var(--bs-font-serif);
8-
/* Sans-serif for smoother fonts. Useful for titles and shorter chunks */
96
--sans-serif-fonts: "Inter", var(--bs-font-sans-serif);
107

118
/* Colors */
@@ -14,9 +11,9 @@
1411
--fg-color: #29332f;
1512
--inverse-fg-color: #a9d5c4; /* Dark-mode fg color. */
1613
--bg-color: #e7eee8;
14+
--accent-bg-color: #d3e4db;
1715
--link-color: #195174;
1816
--accent-color: #000;
19-
--accent-bg-color: #d3e4db;
2017
--border-color: #658fac;
2118
}
2219

@@ -26,12 +23,9 @@
2623
--inverse-fg-color: #29332f; /* Light-mode fg color. */
2724
--bg-color: #0f191f;
2825
--accent-bg-color: #0b151b;
29-
--border-color: #1174b1;
30-
--link-color: #78d55b;
31-
--accent-color: #61ff00;
32-
3326
--link-color: #5fb950;
3427
--accent-color: #61ff00;
28+
--border-color: #1174b1;
3529
}
3630
}
3731

@@ -49,15 +43,12 @@
4943

5044
@supports (font-variation-settings: normal) {
5145
:root {
52-
--sans-serif-fonts: "Inter var", var(--sans-serif-fonts),
53-
var(--bs-font-sans-serif);
54-
--serif-fonts: "Inter var", var(--serif-fonts), var(--bs-font-serif);
46+
--sans-serif-fonts: "Inter var", var(--bs-font-sans-serif);
5547
}
5648
}
5749

5850
body {
59-
/* font-family: "Helvetica Neue", Helvetica, Calibri, Arial, sans-serif; */
60-
font-family: var(--serif-fonts);
51+
font-family: var(--sans-serif-fonts);
6152
font-size: initial;
6253
line-height: 1.6;
6354
color: var(--fg-color);
@@ -72,9 +63,8 @@ body {
7263

7364
a {
7465
color: var(--link-color);
75-
transition: all ease-in-out 140ms;
76-
/* text-decoration: underline var(--link-color); */
7766
text-decoration: underline var(--border-color);
67+
transition: all ease-in-out 140ms;
7868
}
7969

8070
/* Ensure that the hover border is sized correctly for <a><img…></a>. #295 */
@@ -100,9 +90,9 @@ h3,
10090
h4,
10191
h5 {
10292
font-family: var(--sans-serif-fonts);
93+
font-weight: bold;
10394
line-height: 1.6;
10495
margin: 0.66em 0;
105-
font-weight: bold;
10696
}
10797

10898
h1 {
@@ -235,52 +225,50 @@ samp {
235225
* Logo and navigation at the top of the page
236226
*/
237227

238-
.nav {
239-
background-color: var(--accent-bg-color);
240-
border-color: var(--link-color);
228+
.nav-link {
229+
color: var(--link-color);
241230
}
242-
243-
.nav > li > a:focus,
244-
.nav > li > a:hover {
245-
background-color: var(--bg-color);
231+
.nav-link:hover,
232+
.nav-link:focus,
233+
.nav-link:active {
234+
color: var(--accent-color);
246235
}
247236

248-
.nav .open > a:focus,
249-
.nav .open > a:hover {
250-
background-color: var(--accent-bg-color);
237+
.navbar-toggler {
238+
border-width: 0;
239+
color: var(--fg-color);
251240
}
252241

253-
#navbar-logo {
254-
height: 2.5em;
242+
/**
243+
* Logo
244+
*/
245+
.navbar-brand {
246+
color: var(--link-color);
247+
}
248+
.navbar-brand:hover,
249+
.navbar-brand:focus,
250+
.navbar-brand:active {
251+
color: var(--accent-color);
255252
}
256-
257-
/* .navbar-top-align { */
258-
/* margin-top: 1em; */
259-
/* } */
260-
261-
/* .navbar-brand { */
262-
/* float: none; */
263-
/* height: auto; */
264-
/* padding: 0; */
265-
/* font-size: inherit; */
266-
/* line-height: inherit; */
267-
/* } */
268253

269254
/**
270255
* Menu dropdown
271256
*/
272257

258+
#neovimDropdown.show {
259+
color: var(--accent-color);
260+
}
261+
273262
.dropdown-menu {
274263
background-color: var(--accent-bg-color);
275264
}
276265

277-
.dropdown-menu > li > a {
266+
.dropdown-item {
278267
color: var(--link-color);
279268
}
280-
281-
.dropdown-menu > li > a:focus,
282-
.dropdown-menu > li > a:hover,
283-
.dropdown-menu > li > a:active {
269+
.dropdown-item:focus,
270+
.dropdown-item:hover,
271+
.dropdown-item:active {
284272
color: var(--bg-color);
285273
background-color: var(--link-color);
286274
}

css/normalize.min.css

Lines changed: 0 additions & 1 deletion
This file was deleted.

fonts/lato-v17-latin-300.woff

-29.3 KB
Binary file not shown.

fonts/lato-v17-latin-300.woff2

-22.7 KB
Binary file not shown.

0 commit comments

Comments
 (0)