From f91b85bf013f244e1d3c4ea5b06069438bd8991a Mon Sep 17 00:00:00 2001 From: Simon H <5968653+dummdidumm@users.noreply.github.com> Date: Thu, 7 Dec 2023 16:44:03 +0100 Subject: [PATCH 01/31] docs: site hero img dimensions (#9840) prevents layout shift --- sites/svelte.dev/src/routes/_components/Hero.svelte | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sites/svelte.dev/src/routes/_components/Hero.svelte b/sites/svelte.dev/src/routes/_components/Hero.svelte index f317b060b..66309b70e 100644 --- a/sites/svelte.dev/src/routes/_components/Hero.svelte +++ b/sites/svelte.dev/src/routes/_components/Hero.svelte @@ -23,12 +23,12 @@ - - - - - - + + + + + + The Svelte compiler packaging up your component code From ed9ecca0dc94cb5ba8de2d6dcd5c3f4adf74a1a1 Mon Sep 17 00:00:00 2001 From: Puru Vijay <47742487+PuruVJ@users.noreply.github.com> Date: Thu, 7 Dec 2023 21:51:13 +0530 Subject: [PATCH 02/31] Fix hero image (#9845) --- .../src/routes/_components/Hero.svelte | 26 ++++++++++++++++--- 1 file changed, 23 insertions(+), 3 deletions(-) diff --git a/sites/svelte.dev/src/routes/_components/Hero.svelte b/sites/svelte.dev/src/routes/_components/Hero.svelte index 66309b70e..d8d6183b0 100644 --- a/sites/svelte.dev/src/routes/_components/Hero.svelte +++ b/sites/svelte.dev/src/routes/_components/Hero.svelte @@ -23,9 +23,27 @@ - - - + + + @@ -44,6 +62,8 @@ .machine img { position: absolute; pointer-events: none; + width: 100%; + height: auto; } .hero-content { From b1795a88ad51f1536fd68b4ab80082691d52c3d4 Mon Sep 17 00:00:00 2001 From: Fabian Date: Thu, 7 Dec 2023 17:32:32 +0100 Subject: [PATCH 03/31] feat: OpenSearch (#9780) * added OpenSearch * prettier stuff * moved opensearch to layout * Fix build errors * Revert "moved opensearch to layout" * Add trailing space --------- Co-authored-by: Puru --- sites/svelte.dev/src/app.html | 7 +++++++ sites/svelte.dev/static/opensearch.xml | 10 ++++++++++ 2 files changed, 17 insertions(+) create mode 100644 sites/svelte.dev/static/opensearch.xml diff --git a/sites/svelte.dev/src/app.html b/sites/svelte.dev/src/app.html index bc2a51cc8..14594cf75 100644 --- a/sites/svelte.dev/src/app.html +++ b/sites/svelte.dev/src/app.html @@ -11,6 +11,13 @@ + + diff --git a/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.js b/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.js deleted file mode 100644 index b27fec14d..000000000 --- a/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.js +++ /dev/null @@ -1,8 +0,0 @@ -export function load({ url }) { - const query = url.searchParams; - return { - version: query.get('version') || '3', - gist: query.get('gist'), - example: query.get('example') - }; -} diff --git a/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.server.js b/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.server.js new file mode 100644 index 000000000..d6f8ab11b --- /dev/null +++ b/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.server.js @@ -0,0 +1,14 @@ +import { redirect } from '@sveltejs/kit'; + +export function load({ url }) { + if (!url.searchParams.has('gist')) { + throw redirect(301, '/repl/hello-world/embed'); + } else { + const searchParamsWithoutGist = new URLSearchParams(url.searchParams); + searchParamsWithoutGist.delete('gist'); + throw redirect( + 301, + `/repl/${url.searchParams.get('gist')}/embed?${searchParamsWithoutGist.toString()}` + ); + } +} diff --git a/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.svelte b/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.svelte deleted file mode 100644 index 43fed8a1c..000000000 --- a/sites/svelte.dev/src/routes/(authed)/repl/embed/+page.svelte +++ /dev/null @@ -1,36 +0,0 @@ - - - - REPL • Svelte - - - - - - -
- {#if browser} - - {/if} -
- - diff --git a/sites/svelte.dev/src/routes/+layout.svelte b/sites/svelte.dev/src/routes/+layout.svelte index ab931bcd7..9d1e6bdff 100644 --- a/sites/svelte.dev/src/routes/+layout.svelte +++ b/sites/svelte.dev/src/routes/+layout.svelte @@ -33,7 +33,10 @@
- +