summaryrefslogtreecommitdiff
path: root/docs/public
diff options
context:
space:
mode:
authorGravatar Fred K. Schott <fkschott@gmail.com> 2021-07-16 13:39:48 -0400
committerGravatar Fred K. Schott <fkschott@gmail.com> 2021-07-16 13:39:48 -0400
commitdc4ba25b01254ed1c2088c081e8c861172ae58a4 (patch)
treee8424c9266de0886e8fb3c133da7f87e2eeacb11 /docs/public
parent94fdd0db1b0a8ba2f109c5a240dc5770fdf784b8 (diff)
downloadastro-dc4ba25b01254ed1c2088c081e8c861172ae58a4.tar.gz
astro-dc4ba25b01254ed1c2088c081e8c861172ae58a4.tar.zst
astro-dc4ba25b01254ed1c2088c081e8c861172ae58a4.zip
Revert "New getting started guide (#715)"
This reverts commit 2827f077baab6674a8ee47f3006e82ce991118b8.
Diffstat (limited to 'docs/public')
-rw-r--r--docs/public/code.css175
-rw-r--r--docs/public/index.css151
-rw-r--r--docs/public/nav.js37
-rw-r--r--docs/public/theme.css24
4 files changed, 177 insertions, 210 deletions
diff --git a/docs/public/code.css b/docs/public/code.css
index 58a631e57..76b44bd24 100644
--- a/docs/public/code.css
+++ b/docs/public/code.css
@@ -8,91 +8,148 @@
opacity: 0.7;
}
-.token.plain-text,
-[class*="language-bash"] span.token,
-[class*="language-shell"] span.token {
- color: var(--color-gray-200);
+.token.atrule {
+ color: #c792ea;
}
-[class*="language-bash"] span.token,
-[class*="language-shell"] span.token {
- font-style: bold;
+.token.attr-name {
+ color: #ffcb6b;
+}
+
+.token.attr-value {
+ color: #a5e844;
+}
+
+.token.attribute {
+ color: #a5e844;
+}
+
+.token.boolean {
+ color: #c792ea;
+}
+
+.token.builtin {
+ color: #ffcb6b;
+}
+
+.token.cdata {
+ color: #80cbc4;
+}
+
+.token.char {
+ color: #80cbc4;
+}
+
+.token.class {
+ color: #ffcb6b;
}
-.token.prolog,
-.token.comment,
-[class*="language-bash"] span.token.comment,
-[class*="language-shell"] span.token.comment {
- color: var(--color-gray-400);
+.token.class-name {
+ color: #f2ff00;
+}
+
+.token.comment {
+ color: #999;
+}
+
+.token.constant {
+ color: #c792ea;
}
-.token.selector,
-.token.tag,
-.token.unit,
-.token.url,
-.token.variable,
-.token.entity,
.token.deleted {
- color: #FA5E5B;
-}
-
-.token.boolean,
-.token.constant,
-.token.doctype,
-.token.number,
-.token.regex,
-.token.builtin,
-.token.class,
-.token.hexcode,
-.token.class-name,
-.token.attr-name {
- color: var(--color-yellow);
+ color: #ff6666;
}
-.token.atrule,
-.token.attribute,
-.token.attr-value .token.punctuation,
-.token.attr-value,
-.token.pseudo-class,
-.token.pseudo-element,
-.token.string {
- color: var(--color-green);
+.token.doctype {
+ color: #999;
}
-.token.symbol,
-.token.function,
-.token.id,
-.token.important
- {
- color: var(--color-blue);
+.token.entity {
+ color: #ff6666;
}
-.token.important,
-.token.id {
- font-weight: bold;
+.token.function {
+ color: #c792ea;
}
+.token.hexcode {
+ color: #f2ff00;
+}
-.token.cdata,
-.token.char,
-.token.property {
- color: #23B1AF;
+.token.id {
+ color: #c792ea;
+ font-weight: bold;
+}
+
+.token.important {
+ color: #c792ea;
+ font-weight: bold;
}
.token.inserted {
- color: var(--color-green);
+ color: #80cbc4;
}
.token.keyword {
- color: #FF657C;
- font-style: italic;
+ color: #c792ea;
+}
+
+.token.number {
+ color: #fd9170;
}
.token.operator {
- color: var(--color-gray-300);
+ color: #89ddff;
+}
+
+.token.prolog {
+ color: #999;
+}
+
+.token.property {
+ color: #80cbc4;
+}
+
+.token.pseudo-class {
+ color: #a5e844;
+}
+
+.token.pseudo-element {
+ color: #a5e844;
}
-.token.attr-value .token.attr-equals,
.token.punctuation {
- color: var(--color-gray-200);
+ color: #89ddff;
+}
+
+.token.regex {
+ color: #f2ff00;
+}
+
+.token.selector {
+ color: #ff6666;
+}
+
+.token.string {
+ color: #a5e844;
+}
+
+.token.symbol {
+ color: #c792ea;
+}
+
+.token.tag {
+ color: #ff6666;
+}
+
+.token.unit {
+ color: #fd9170;
+}
+
+.token.url {
+ color: #ff6666;
+}
+
+.token.variable {
+ color: #ff6666;
}
diff --git a/docs/public/index.css b/docs/public/index.css
index 14f7e3518..2b41accad 100644
--- a/docs/public/index.css
+++ b/docs/public/index.css
@@ -5,7 +5,7 @@
:root {
--user-font-scale: 1rem - 16px;
- --max-width: calc(100% - 1rem);
+ --max-width: calc(100% - 2rem);
}
@media (min-width: 50em) {
@@ -20,8 +20,12 @@ body {
min-height: 100vh;
font-family: var(--font-body);
font-size: 1rem;
- font-size: clamp(0.9rem, 0.7500rem + 0.3750vw + var(--user-font-scale), 1rem);
- line-height: 1.5;
+ font-size: clamp(
+ 0.875rem,
+ 0.4626rem + 1.0309vw + var(--user-font-scale),
+ 1.125rem
+ );
+ line-height: 1.625;
}
nav ul {
@@ -33,15 +37,11 @@ nav ul {
margin-top: 1rem;
}
-.content main > :first-child {
- margin-top: 0;
-}
-
/* Typography */
:is(h1, h2, h3, h4, h5, h6) {
- margin-bottom: 1rem;
+ margin-bottom: 1.38rem;
font-weight: 400;
- line-height: 1.25;
+ line-height: 1.3;
}
:is(h1, h2) {
@@ -53,26 +53,27 @@ nav ul {
}
h1 {
- font-size: 2.5rem;
+ font-size: 3.5rem;
font-weight: bold;
}
h2 {
- font-size: 1.75rem;
+ font-size: 32px;
font-weight: bold;
}
h3 {
- font-size: 1.25rem;
+ font-size: 24px;
+ font-weight: bold;
}
h4 {
font-size: 1rem;
+ font-weight: bold;
}
h5 {
- font-size: 0.8rem;
- font-weight: bold;
+ font-size: clamp(1.2rem, 1.15rem + 0.125vw, 1.25rem);
}
p,
@@ -94,20 +95,6 @@ a {
gap: 0.5rem;
}
-article :is(ul, ol) > * + *,
-article li > * + * {
- margin-top: 0.75rem;
-}
-
-article :is(ul, ol) {
- padding-left: 0;
-}
-
-article ::marker {
- font-weight: bold;
- color: var(--theme-text-light);
-}
-
a > code:not([class*='language']) {
position: relative;
color: var(--theme-text-accent);
@@ -175,26 +162,16 @@ pre {
--padding-inline: 2rem;
padding: var(--padding-block) var(--padding-inline);
padding-right: calc(var(--padding-inline) * 2);
- margin-left: calc(var(--padding-inline) * -1);
- margin-right: calc(var(--padding-inline) * -1);
- font-family: var(--font-mono);
- line-height: 1.5;
- font-size: 0.85rem;
+ line-height: 1.414;
overflow-y: hidden;
overflow-x: auto;
}
-pre code {
- font: inherit;
-}
-
@media (min-width: 37.75em) {
pre {
--padding-inline: 1.25rem;
border-radius: 8px;
- margin-left: 0;
- margin-right: 0;
}
}
@@ -216,30 +193,6 @@ img {
align-items: center;
}
-header {
- position: relative;
- transition: transform 300ms 200ms cubic-bezier(0.23, 1, 0.320, 1);
-}
-
-header::after {
- content: '';
- display: block;
- position: absolute;
- top: 100%;
- left: 0;
- right: 0;
- height: 0.5rem;
- background: var(--theme-navbar-bg);
-}
-
-header.hidden {
- transform: translateY(calc(-100% - 1px));
- transition: transform 200ms 100ms cubic-bezier(0.755, 0.05, 0.855, 0.06);
-}
-header.hidden:is(:hover, :focus, :focus-within) {
- transform: translateY(0);
-}
-
header button {
background-color: var(--theme-bg);
}
@@ -305,7 +258,7 @@ button {
}
#theme-toggle .checked {
- color: var(--theme-navbar-bg);
+ color: var(--theme-accent);
transform: scale(1.125);
opacity: 1;
}
@@ -323,13 +276,13 @@ input[name='theme-toggle'] {
.sidebar-nav {
width: 100%;
position: sticky;
- min-height: calc(100vh - var(--theme-navbar-height));
- height: calc(100vh - var(--theme-navbar-height));
- top: var(--theme-navbar-height);
+ min-height: calc(100vh - 3.5rem);
+ height: calc(100vh - 3.5rem);
+ top: 3.5rem;
}
.sidebar-nav-inner {
height: 100%;
- padding: 0;
+ padding: 2rem 0;
overflow: auto;
}
@@ -349,8 +302,7 @@ h2.heading {
.header-link:hover,
.header-link:focus {
- border-left-color: var(--theme-accent);
- color: var(--theme-accent);
+ border-left-color: var(--color-gray-300);
}
.header-link:focus-within {
color: var(--theme-text-light);
@@ -383,6 +335,36 @@ h2.heading {
font-size: 1rem;
}
+/* Scrollbar */
+
+/* width */
+::-webkit-scrollbar {
+ width: 0.5rem;
+}
+
+/* Track */
+::-webkit-scrollbar-track {
+ background: var(--theme-divider);
+ border-radius: 1rem;
+}
+
+/* Handle */
+::-webkit-scrollbar-thumb {
+ background: var(--theme-text-lighter);
+ border-radius: 1rem;
+}
+
+/* Handle on hover */
+::-webkit-scrollbar-thumb:hover {
+ background: var(--theme-text-light);
+}
+
+/* Buttons */
+::-webkit-scrollbar-button {
+ display: none;
+}
+/* Scrollbar - End */
+
/* Screenreader Only Text */
.sr-only {
position: absolute;
@@ -400,32 +382,3 @@ h2.heading {
:target {
scroll-margin-top: 4rem;
}
-
-#site-title {
- display: flex;
- align-items: center;
- gap: 0.25em;
- font-size: 1.5rem;
- font-weight: 700;
- margin: 0;
- line-height: 1;
- color: var(--color-white);
- text-decoration: none;
-}
-
-#site-title svg {
- width: 118px;
- height: 48px;
- display: block;
-}
-
-#site-title:hover,
-#site-title:focus {
- opacity: 0.8;
-}
-
-#site-title h1 {
- font: inherit;
- color: inherit;
- margin: 0;
-}
diff --git a/docs/public/nav.js b/docs/public/nav.js
deleted file mode 100644
index 93fadcd61..000000000
--- a/docs/public/nav.js
+++ /dev/null
@@ -1,37 +0,0 @@
-const nav = document.querySelector('body > header');
-
-if (!window.matchMedia('(prefers-reduced-motion)').matches) {
- window.addEventListener('scroll', onScroll, { passive: true });
-}
-
-let prev = -1;
-let prevDir = 0;
-let threshold = 32;
-
-function onScroll() {
- const curr = window.scrollY;
- const dir = curr > prev ? 1 : -1;
-
- if (curr < threshold) {
- show();
- document.documentElement.classList.add('initial');
- } else if (dir !== prevDir) {
- if (dir === 1) {
- hide();
- } else {
- show();
- }
- }
-
- prev = curr;
-}
-
-const hide = () => {
- nav.classList.add('hidden')
- document.documentElement.classList.add('scrolled');
- document.documentElement.classList.remove('initial');
-};
-const show = () => {
- nav.classList.remove('hidden');
- document.documentElement.classList.remove('scrolled');
-}
diff --git a/docs/public/theme.css b/docs/public/theme.css
index f5db78d1f..22d765714 100644
--- a/docs/public/theme.css
+++ b/docs/public/theme.css
@@ -2,7 +2,8 @@
--font-fallback: -apple-system, BlinkMacSystemFont, Segoe UI, Helvetica, Arial,
sans-serif, Apple Color Emoji, Segoe UI Emoji;
--font-body: system-ui, var(--font-fallback);
- --font-mono: "IBM Plex Mono", Consolas, "Andale Mono WT", "Andale Mono", "Lucida Console", "Lucida Sans Typewriter", "DejaVu Sans Mono", "Bitstream Vera Sans Mono", "Liberation Mono", "Nimbus Mono L", Monaco, "Courier New", Courier, monospace;
+ --font-mono: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
+ monospace;
--color-white: #fff;
--color-black: #000014;
@@ -36,14 +37,14 @@
:root {
color-scheme: light;
- --theme-accent: var(--color-purple);
- --theme-accent-rgb: var(--color-purple-rgb);
+ --theme-accent: var(--color-blue);
+ --theme-accent-rgb: var(--color-blue-rgb);
--theme-accent-opacity: 0.1;
--theme-divider: var(--color-gray-100);
--theme-text: var(--color-gray-800);
--theme-text-light: var(--color-gray-600);
--theme-text-lighter: var(--color-gray-400);
- --theme-text-accent: var(--color-purple);
+ --theme-text-accent: var(--color-blue);
--theme-bg: var(--color-white);
--theme-bg-hover: var(--color-gray-50);
--theme-bg-offset: var(--color-gray-100);
@@ -52,9 +53,6 @@
--theme-code-inline-text: var(--theme-text);
--theme-code-bg: var(--color-gray-700);
--theme-code-text: var(--color-gray-100);
- --theme-navbar-bg: var(--color-green);
- --theme-navbar-height: 3.5rem;
- --theme-sidebar-offset: var(--theme-navbar-height);
}
body {
@@ -62,10 +60,6 @@ body {
color: var(--theme-text);
}
-:root.scrolled {
- --theme-sidebar-offset: 0;
-}
-
:root.theme-dark {
color-scheme: dark;
--theme-accent-opacity: 0.3;
@@ -73,17 +67,17 @@ body {
--theme-text: var(--color-gray-200);
--theme-text-light: var(--color-gray-300);
--theme-text-lighter: var(--color-gray-600);
- --theme-text-accent: #A550FF;
+ --theme-text-accent: var(--color-white);
--theme-bg: var(--color-gray-800);
--theme-bg-hover: var(--color-gray-600);
--theme-bg-offset: var(--color-gray-950);
- --theme-code-inline-bg: var(--color-gray-900);
+ --theme-code-inline-bg: var(--color-gray-600);
--theme-code-inline-text: var(--color-white);
--theme-code-bg: var(--color-gray-950);
--theme-code-text: var(--color-white);
}
::selection {
- color: var(--color-green);
- background-color: rgba(var(--color-green-rgb), var(--theme-accent-opacity));
+ color: var(--theme-text-accent);
+ background-color: rgba(var(--theme-accent-rgb), var(--theme-accent-opacity));
}