From 218ae9f108e18c101d5d4a909a490a3c01dec787 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Sat, 28 Sep 2024 14:58:16 -0400 Subject: [PATCH 1/3] use wordmark --- .../src/lib/branding/svelte-wordmark.svg | 1 + packages/site-kit/src/lib/branding/svelte.svg | 1 + packages/site-kit/src/lib/nav/Nav.svelte | 35 ++++--------------- 3 files changed, 9 insertions(+), 28 deletions(-) create mode 100644 packages/site-kit/src/lib/branding/svelte-wordmark.svg create mode 100644 packages/site-kit/src/lib/branding/svelte.svg diff --git a/packages/site-kit/src/lib/branding/svelte-wordmark.svg b/packages/site-kit/src/lib/branding/svelte-wordmark.svg new file mode 100644 index 0000000000..5778069e49 --- /dev/null +++ b/packages/site-kit/src/lib/branding/svelte-wordmark.svg @@ -0,0 +1 @@ + diff --git a/packages/site-kit/src/lib/branding/svelte.svg b/packages/site-kit/src/lib/branding/svelte.svg new file mode 100644 index 0000000000..1788877c0f --- /dev/null +++ b/packages/site-kit/src/lib/branding/svelte.svg @@ -0,0 +1 @@ + diff --git a/packages/site-kit/src/lib/nav/Nav.svelte b/packages/site-kit/src/lib/nav/Nav.svelte index 16fe00353c..623976c2c1 100644 --- a/packages/site-kit/src/lib/nav/Nav.svelte +++ b/packages/site-kit/src/lib/nav/Nav.svelte @@ -69,9 +69,7 @@ Top navigation bar for the application. It provides a slot for the left side, th style:z-index={$overlay_open && ($searching || $on_this_page_open) ? 80 : null} aria-label="Primary" > - - svelte - + {#if title}
@@ -184,7 +182,7 @@ Top navigation bar for the application. It provides a slot for the left side, th .menu :global(a) { color: var(--sk-text-2); line-height: 1; - padding: 0 0.3em; + padding: 0.1rem 0.5rem 0 0.5rem; white-space: nowrap; height: 100%; display: flex; @@ -202,31 +200,12 @@ Top navigation bar for the application. It provides a slot for the left side, th } .home-link { - max-width: max-content; + --padding-right: 2rem; + width: 18rem; height: 100%; - display: flex; - background-image: url(../branding/svelte-logo.svg); - background-position: calc(var(--sk-page-padding-side) - 1rem) 50%; - background-repeat: no-repeat; - background-size: auto 70%; - align-items: center; - padding-left: calc(var(--sk-page-padding-side) + 4rem); - padding-right: 2rem; - text-decoration: none; - text-transform: uppercase; - letter-spacing: 0.05em; - font-size: 1.8rem; - color: var(--sk-text-4); - - strong { - position: relative; - color: var(--sk-text-1); - font-weight: inherit; - - @media (min-width: 800px) { - top: 1px; - } - } + background: url(../branding/svelte.svg) no-repeat var(--sk-page-padding-side) 50% / + calc(100% - var(--sk-page-padding-side) - var(--padding-right)) auto; + padding: 0 var(--padding-right) 0 calc(var(--sk-page-padding-side) + 0rem); } .mobile-menu { From ecac163c0c0d42a302cf9d438a850f6854adf456 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Sat, 28 Sep 2024 15:01:27 -0400 Subject: [PATCH 2/3] fix mobile --- packages/site-kit/src/lib/nav/Nav.svelte | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/packages/site-kit/src/lib/nav/Nav.svelte b/packages/site-kit/src/lib/nav/Nav.svelte index 623976c2c1..b3cb289233 100644 --- a/packages/site-kit/src/lib/nav/Nav.svelte +++ b/packages/site-kit/src/lib/nav/Nav.svelte @@ -73,7 +73,7 @@ Top navigation bar for the application. It provides a slot for the left side, th {#if title}
- | {title} + {title}
{/if} @@ -165,6 +165,7 @@ Top navigation bar for the application. It provides a slot for the left side, th font-size: 0.8em; color: var(--sk-text-3); margin-left: 0.4em; + padding: 0.1rem 0 0 0; } @media (max-width: 800px) { @@ -200,8 +201,8 @@ Top navigation bar for the application. It provides a slot for the left side, th } .home-link { - --padding-right: 2rem; - width: 18rem; + --padding-right: 1rem; + width: 13rem; height: 100%; background: url(../branding/svelte.svg) no-repeat var(--sk-page-padding-side) 50% / calc(100% - var(--sk-page-padding-side) - var(--padding-right)) auto; @@ -285,6 +286,11 @@ Top navigation bar for the application. It provides a slot for the left side, th } @media (min-width: 800px) { + .home-link { + --padding-right: 2rem; + width: 18rem; + } + nav { display: grid; grid-template-columns: auto 1fr 1fr; From be9eae6f094b76860aca4b6a81ef1dff64cfbf7b Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Sat, 28 Sep 2024 15:02:50 -0400 Subject: [PATCH 3/3] remove unused file --- packages/site-kit/src/lib/branding/svelte-wordmark.svg | 1 - 1 file changed, 1 deletion(-) delete mode 100644 packages/site-kit/src/lib/branding/svelte-wordmark.svg diff --git a/packages/site-kit/src/lib/branding/svelte-wordmark.svg b/packages/site-kit/src/lib/branding/svelte-wordmark.svg deleted file mode 100644 index 5778069e49..0000000000 --- a/packages/site-kit/src/lib/branding/svelte-wordmark.svg +++ /dev/null @@ -1 +0,0 @@ -