Skip to content

Commit 510a001

Browse files
authored
insert <wbr> elements to break package names (#1241)
* insert `<wbr>` elements to break package names * drive-by * oops
1 parent ce8edeb commit 510a001

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

apps/svelte.dev/src/routes/_home/Footer.svelte

+3-3
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44

55
<Section>
66
<p class="copyright">
7-
© {new Date().getFullYear()} Svelte contributors. Svelte is <a href="https://github.com/sveltejs/svelte"
8-
>free and open source software</a
9-
> released under the MIT license.
7+
© {new Date().getFullYear()} Svelte contributors. Svelte is
8+
<a href="https://github.com/sveltejs/svelte">free and open source software</a> released under the
9+
MIT license.
1010
</p>
1111
</Section>
1212

apps/svelte.dev/src/routes/docs/[...path]/+page.svelte

+2-1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import Breadcrumbs from './Breadcrumbs.svelte';
88
import PageControls from '$lib/components/PageControls.svelte';
99
import { goto } from '$app/navigation';
10+
import { escape_html } from '$lib/utils/escape';
1011
1112
let { data } = $props();
1213
@@ -69,7 +70,7 @@
6970
<div id="docs-content" use:legacy_details>
7071
<header>
7172
<Breadcrumbs breadcrumbs={data.document.breadcrumbs.slice(1)} />
72-
<h1>{data.document.metadata.title}</h1>
73+
<h1>{@html escape_html(data.document.metadata.title).replaceAll('/', '/<wbr>')}</h1>
7374
</header>
7475

7576
<OnThisPage {content} document={data.document} />

0 commit comments

Comments
 (0)