diff --git a/src/lib/Codeblock.svelte b/src/lib/Codeblock.svelte new file mode 100644 index 0000000..0537b6b --- /dev/null +++ b/src/lib/Codeblock.svelte @@ -0,0 +1,9 @@ + + +

Hello world!

+
+    
+
diff --git a/src/lib/Sidenote.svelte b/src/lib/Sidenote.svelte index c47f206..2058604 100644 --- a/src/lib/Sidenote.svelte +++ b/src/lib/Sidenote.svelte @@ -70,7 +70,7 @@ bottom: 0; // since headings have relative position, any that come after // the current sidenote in the DOM get stacked on top by default - z-index: 1; + z-index: 10; // give us a horizontal buffer for the counter and dismiss button --padding-x: calc(var(--content-padding) + 1.5rem); @@ -80,9 +80,13 @@ // show the sidenote only when the corresponding checkbox is checked transform: translateY(calc(100% + 2rem)); - transition: transform 100ms; + transition: transform 125ms; + // when moving from shown -> hidden, ease-in + transition-timing-function: ease-in; .sidenote-toggle:checked + & { transform: translateY(0); + // when moving hidden -> shown, ease-out + transition-timing-function: ease-out; } } } diff --git a/src/lib/Toc.svelte b/src/lib/Toc.svelte index 547a1bc..0e12b0e 100644 --- a/src/lib/Toc.svelte +++ b/src/lib/Toc.svelte @@ -55,15 +55,15 @@ position: sticky; top: 1.5rem; margin-left: 1rem; - margin-right: 2.5rem; + margin-right: 4rem; max-width: 18rem; color: var(--content-color-faded); // minimum desirable TOC width is 8rem - // add 3rem for margins, giving total gutter width of 11.5rem + // add 4rem for margins, giving total gutter width of 12.5rem // multiply by 2 since there are two equally-sized gutters, then add content-width (52.5rem) - @media(max-width: 75.5rem) { + @media(max-width: 77.5rem) { display: none; } } diff --git a/src/projects/fantasy/BookPreview.svelte b/src/projects/fantasy/BookPreview.svelte new file mode 100644 index 0000000..cdafad3 --- /dev/null +++ b/src/projects/fantasy/BookPreview.svelte @@ -0,0 +1,169 @@ + + + + + + + + + +
+ +
+

{title}

+

+ {description} + More +

+
+
\ No newline at end of file diff --git a/src/projects/fantasy/books.json b/src/projects/fantasy/books.json new file mode 100644 index 0000000..ae0f2af --- /dev/null +++ b/src/projects/fantasy/books.json @@ -0,0 +1,23 @@ +{ + "lotr": { + "type": "trilogy", + "title": "The Lord of the Rings", + "author": "J. R. R. Tolkien", + "description": "Epic fantasy trilogy written by Oxford professor and linguist J. R. R. Tolkien. Considered by many to be the major trend-setter for the modern fantasy genre.", + "url": "https://www.goodreads.com/series/66175-the-lord-of-the-rings" + }, + "neverwhere": { + "type": "book", + "title": "Neverwhere", + "author": "Neil Gaiman", + "description": "Under the streets of London there's a world most people could never dream of. A city of monsters and saints, murderers and angels, knights in armour and pale girls in black velvet. \"Neverwhere\" is the London of the people who have fallen between the cracks.", + "url": "https://www.goodreads.com/book/show/14497.Neverwhere" + }, + "earthsea": { + "type": "series", + "title": "Earthsea Cycle", + "author": "Ursula K. Le Guin", + "description": "Series of high fantasy stories set in an archipelago world where names are power and dragons roam the skies.", + "url": "https://www.goodreads.com/series/40909-earthsea-cycle" + } +} diff --git a/src/projects/fantasy/images/earthsea.jpg b/src/projects/fantasy/images/earthsea.jpg new file mode 100644 index 0000000..69d2738 Binary files /dev/null and b/src/projects/fantasy/images/earthsea.jpg differ diff --git a/src/projects/fantasy/images/lotr.jpg b/src/projects/fantasy/images/lotr.jpg new file mode 100644 index 0000000..5bc8d08 Binary files /dev/null and b/src/projects/fantasy/images/lotr.jpg differ diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index 85db546..70b2a58 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -1,6 +1,6 @@