Skip to content

Commit

Permalink
Revert "Docs design refresh (#3244)"
Browse files Browse the repository at this point in the history
This reverts commit 2eda281.
  • Loading branch information
SimonDanisch committed Oct 12, 2023
1 parent fc30801 commit 15b67e6
Show file tree
Hide file tree
Showing 8 changed files with 133 additions and 220 deletions.
206 changes: 47 additions & 159 deletions docs/_css/makie.css
Original file line number Diff line number Diff line change
@@ -1,8 +1,5 @@
:root {
--text-color: #494e52;
--masthead-height-desktop: 3rem;
--grid-gap: 2rem;
--content-table-top-margin: 2rem;
}

html {
Expand Down Expand Up @@ -284,11 +281,11 @@ th {
/* masthead */

img.masthead-icon {
height: 1.5rem;
height: 1.5em;
}

.title-icon img {
height: 2rem;
height: 2em;
}

a.title-icon {
Expand Down Expand Up @@ -451,85 +448,30 @@ a.boxlink:hover {
margin-top: 0;
}

#makiesearch {
margin-bottom: 0.5rem;
}

#content-table {
max-height: 33vh;
overflow-y: auto;
}

#content-table ul li {
margin: 0;
}

#content-table a {
text-decoration: none;
color: #83898f;
display: block;
}

#content-table a.active {
color: black;
}

#content-table a:hover {
color: black;
}

#content-table ul {
list-style: none;
padding: 0;
}

#content-table ul ul {
padding-left: 0.5rem;
}

#content-table li ul {
margin-top: 0;
}

#content-table-container.content-table-hidden #on-this-page {
border-radius: 0.5rem;
}

#on-this-page {
width: 100%;
border: 0;
border-radius: 0.5rem 0.5rem 0 0;
padding: 0.4rem;
transition: 0.2s;
}

#content-table {
background-color: rgb(244, 244, 244);
max-height: 66vh;
transition: 0.4s;
}

#content-table .page-content {
padding: 0.2rem 0.5rem;
}
/* #navbar ul ul.collapsed {
display: none;
} */

#content-table-container.content-table-hidden #content-table {
height: 0px !important;
/* #navbar ul li a::after {
font-family: "Font Awesome 5 Free";
font-weight: 900;
content: "\f078";
}
#navbar ul.collapsed li a::after {
content: "\f054";
} */

.franklin-content {
grid-column: 2;
grid-row: 1;
overflow-x: scroll;
}

#main {
width: 100%;
max-width: none;
display: block;
margin-bottom: 1em;
padding-top: 1rem;
}

#navbar-container {
Expand All @@ -552,35 +494,6 @@ a.boxlink:hover {
overflow-y: auto;
}

#makiesearch-overlay-container {
height: 100vh;
width: 100vw;
background: rgba(0, 0, 0, 0.3);
position: fixed;
top: 0;
left: 0;
z-index: 25;
transition: 0.3s;
padding: 5rem;
}

#makiesearch-overlay-container.hidden {
display: none;
opacity: 0;
}

#makiesearch-overlay-container-inner {
opacity: 1;
background-color: white;
border-radius: 1rem;
padding: 3rem;
max-width: 80ch;
margin: 0 auto;
overflow-y: scroll;
max-height: calc(100vh - 10rem);
}


#overlay {
height: 100vh;
width: 100vw;
Expand Down Expand Up @@ -609,10 +522,6 @@ a.boxlink:hover {
display: none;
}

#masthead-search-button {
display: none;
}

.greedy-nav__toggle {
display: block;
margin-left: auto;
Expand Down Expand Up @@ -642,85 +551,38 @@ a.boxlink:hover {

@media (min-width: 1200px) {
#main {
max-width: 1800px;
width: 100%;
width: 1150px;
display: grid;
grid-template-columns: 1fr 4fr 1fr;
grid-gap: var(--grid-gap);
padding: 0 1rem;
}
.franklin-content h1 {
margin-top: 0rem;
grid-template-columns: 800px 300px;
grid-gap: 50px;
}
.masthead__inner-wrap {
max-width: 1800px;
width: 100%;
padding-left: 1rem;
padding-right: 1rem;
}
#masthead-search-button {
display: inline;
}
#masthead-search-button button {
border-radius: 0.5rem;
border: 0;
padding: 0.3rem 0.5rem;
}
#makiesearch {
display: none;
width: 1150px;
}
#navbar-container {
/* float: left; */
float: left;
background: transparent;
position: static;
grid-column: 1;
grid-column: 2;
grid-row: 1;
width: 100%;
padding: 0;
z-index: 0;
border-right: 1px solid #f2f3f3;
padding-right: var(--grid-gap);
padding-top: 0.5rem;
}
#navbar {
position: sticky;
top: calc(var(--masthead-height-desktop) + 1px);
top: 4em;
height: auto;
max-height: calc(100vh - var(--masthead-height-desktop));
max-height: calc(100vh - 4em);
min-height: calc(100vh - 16em);
padding: 0;
}
.greedy-nav__toggle {
display: none;
}
.franklin-content {
grid-column: 2;
grid-row: 1;
}
#content-table-container {
grid-column: 3;
grid-column: 1;
grid-row: 1;
position: static;
width: 100%;
padding: var(--content-table-top-margin) 0 0 0;
z-index: 0;
}
#content-table {
position: sticky;
top: calc(var(--masthead-height-desktop) + var(--content-table-top-margin) + 1px);
background-color: transparent;
max-height: calc(100vh - var(--masthead-height-desktop));
padding: 0;
font-size: .85rem;
border-left: 1px solid #f2f3f3;
padding-left: calc(var(--grid-gap) / 3);
}
#on-this-page {
display: none;
}
#content-table-container.content-table-hidden #content-table {
height: fit-content !important;
background-color: transparent;
}
}

Expand Down Expand Up @@ -760,6 +622,15 @@ input.collapse-toggle {
display: none;
}

#navbar ul.page-content {
display: block;
font-size: 0.85em;
}

#navbar ul.page-content ul {
display: block;
}

#navbar input:checked~ul {
display: block;
}
Expand Down Expand Up @@ -797,6 +668,23 @@ input.collapse-toggle {
font-weight: bold;
}

#lunrSearchForm {
margin: 1em 0;
padding: 0;
background-color: transparent;
}

#lunrSearchForm input {
box-shadow: inset 0px 0px 3px 0px rgba(0, 0, 0, 0.04);
padding: 0.25em 0.5em;
border-radius: 1em;
border: 1px solid #ddd;
}

#lunrSearchForm input:focus {
border: 1px solid #7192e1;
}

.banner-container {
margin-bottom: -1em;
margin-top: 1em;
Expand Down
10 changes: 8 additions & 2 deletions docs/_css/minimal-mistakes.css
Original file line number Diff line number Diff line change
Expand Up @@ -491,6 +491,13 @@ screen and (max-height: 300px) {
padding-top: 0;
}

a:focus,
button:focus {
outline: thin dotted #6f777d;
outline: 5px auto #6f777d;
outline-offset: -2px;
}

* {
box-sizing: border-box;
}
Expand Down Expand Up @@ -1850,11 +1857,10 @@ th {
}

.masthead__menu-item {
display: flex;
display: block;
list-style-type: none;
white-space: nowrap;
margin-left: 2rem;
align-items: center;
}

.masthead__menu-item--lg {
Expand Down
28 changes: 4 additions & 24 deletions docs/_layout/body_layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,37 +6,17 @@
{{end}}
<div id="main" role="main">
<div id="overlay"></div>
{{if searchpage}}
{{else}}
<div id="makiesearch-overlay-container" class="hidden">
<div id="makiesearch-overlay-container-inner">
<div id="makiesearch-overlay">
</div>
</div>
</div>
{{end}}
<div id="content-table-container" class="content-table-hidden">
<button id="on-this-page" onclick="toggle_content_table_visibility()">On this page</button>
<script>
function toggle_content_table_visibility(){
const c = document.querySelector("#content-table-container");
const ct = c.querySelector("#content-table");
const vh = window.visualViewport.height;
ct.style.height = `${Math.min(ct.scrollHeight, 0.66*vh)}px`;
c.classList.toggle("content-table-hidden");
}
</script>
<div id="content-table">
{{ contenttable }}
</div>
</div>
<div id="navbar-container">
<div id="navbar">
<!-- <form id="lunrSearchForm" name="lunrSearchForm" action="/search/index.html">
<input class="search-input" name="q" placeholder="Search docs" type="text">
</form> -->
{{if searchpage}}
{{else}}
<div id="makiesearch">
</div>
{{end}}
<h1>Navigation</h1>
{{ navigation }}
</div>
</div>
4 changes: 0 additions & 4 deletions docs/_layout/foot.html
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,6 @@
element: "#makiesearch",
showImages: false
});
new PagefindUI({
element: "#makiesearch-overlay",
showImages: false
});
});
</script>

Expand Down
Loading

0 comments on commit 15b67e6

Please sign in to comment.