feat: make metadata window sticky
This commit is contained in:
parent
e76d8fba3c
commit
ea9bdc15ef
@ -2,6 +2,7 @@
|
|||||||
export let title: string;
|
export let title: string;
|
||||||
export let iconUri: string = '';
|
export let iconUri: string = '';
|
||||||
export let id: string = '';
|
export let id: string = '';
|
||||||
|
export let sticky: boolean = false;
|
||||||
|
|
||||||
const scaleKeyframes = [
|
const scaleKeyframes = [
|
||||||
"window-open",
|
"window-open",
|
||||||
@ -19,7 +20,7 @@
|
|||||||
|
|
||||||
<div
|
<div
|
||||||
class="
|
class="
|
||||||
flex flex-col
|
flex flex-col {sticky ? 'md:sticky md:-top-9' : ''}
|
||||||
max-w-screen-md xl:max-w-screen-lg 2xl:max-w-screen-xl min-w-[30ch] lg:min-w-[40ch] w-full md:w-fit [height:fit-content]
|
max-w-screen-md xl:max-w-screen-lg 2xl:max-w-screen-xl min-w-[30ch] lg:min-w-[40ch] w-full md:w-fit [height:fit-content]
|
||||||
border-ralsei-white border-ridge border-8 border-t-[12px]
|
border-ralsei-white border-ridge border-8 border-t-[12px]
|
||||||
bg-ralsei-black
|
bg-ralsei-black
|
||||||
|
@ -17,14 +17,14 @@
|
|||||||
<meta property="og:title" content={title} />
|
<meta property="og:title" content={title} />
|
||||||
</svelte:head>
|
</svelte:head>
|
||||||
|
|
||||||
<article class="flex flex-wrap gap-4 h-entry">
|
<article class="flex flex-wrap md:flex-nowrap gap-4 h-entry">
|
||||||
<Window {title} iconUri="/icons/entry.png">
|
<Window {title} iconUri="/icons/entry.png">
|
||||||
<div class="prose prose-ralsei max-w-[80ch] e-content">
|
<div class="prose prose-ralsei max-w-[80ch] e-content">
|
||||||
<slot />
|
<slot />
|
||||||
</div>
|
</div>
|
||||||
</Window>
|
</Window>
|
||||||
{#if showMetadata}
|
{#if showMetadata}
|
||||||
<Window title="metadata">
|
<Window title="metadata" sticky>
|
||||||
<div class="prose prose-ralsei">
|
<div class="prose prose-ralsei">
|
||||||
<ul>
|
<ul>
|
||||||
<link class="u-url" href="{PUBLIC_BASE_URL}{$page.url.pathname}" />
|
<link class="u-url" href="{PUBLIC_BASE_URL}{$page.url.pathname}" />
|
||||||
|
Loading…
Reference in New Issue
Block a user