-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: migration of demo to svelte 5 (#961)
* feat: migration of demo to svelte 5 * feat: real svelte versions
- Loading branch information
1 parent
916ee07
commit e8ad145
Showing
97 changed files
with
1,220 additions
and
718 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,13 @@ | ||
<script lang="ts"> | ||
import Code from '$lib/layout/Code.svelte'; | ||
export let lang: string; | ||
export let text: string; | ||
let { | ||
lang, | ||
text, | ||
}: { | ||
lang: string; | ||
text: string; | ||
} = $props(); | ||
</script> | ||
|
||
<Code language={lang.trim() || 'text'} code={text.trim()} noCopy /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
<script> | ||
export let raw; | ||
/** @type {{raw: any, text: any, children: import('svelte').Snippet}} */ | ||
let {raw, text, children} = $props(); | ||
// eslint-disable-next-line @typescript-eslint/no-unused-expressions | ||
raw; | ||
export let text; | ||
// eslint-disable-next-line @typescript-eslint/no-unused-expressions | ||
text; | ||
</script> | ||
|
||
<p><slot /></p> | ||
<p>{@render children()}</p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
<script> | ||
export let depth; | ||
/** @type {{depth: number, children: import('svelte').Snippet}} */ | ||
let {depth, children} = $props(); | ||
</script> | ||
|
||
<section class={depth === 2 ? 'my-4' : 'my-3 mx-3'}><slot /></section> | ||
<section class={depth === 2 ? 'my-4' : 'my-3 mx-3'}>{@render children()}</section> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.