diff --git a/.changeset/tough-glasses-tan.md b/.changeset/tough-glasses-tan.md new file mode 100644 index 0000000000..4d4e7e9fa9 --- /dev/null +++ b/.changeset/tough-glasses-tan.md @@ -0,0 +1,5 @@ +--- +'@astrojs/starlight': patch +--- + +Prevent list items from overflowing Markdown content diff --git a/packages/starlight/style/markdown.css b/packages/starlight/style/markdown.css index d0e2248eb1..1f065ff9eb 100644 --- a/packages/starlight/style/markdown.css +++ b/packages/starlight/style/markdown.css @@ -18,6 +18,10 @@ margin-top: 0.25rem; } +.sl-markdown-content li:not(:where(.not-content *)) { + overflow-wrap: anywhere; +} + .sl-markdown-content li > :last-child:not(li, ul, ol):not(a, strong, em, del, span, input, :where(.not-content *)) { diff --git a/packages/starlight/user-components/Tabs.astro b/packages/starlight/user-components/Tabs.astro index f93475c17b..806941bcb0 100644 --- a/packages/starlight/user-components/Tabs.astro +++ b/packages/starlight/user-components/Tabs.astro @@ -65,6 +65,7 @@ const { html, panels } = processPanels(panelHtml); border-bottom: 2px solid var(--sl-color-gray-5); color: var(--sl-color-gray-3); outline-offset: var(--sl-outline-offset-inside); + overflow-wrap: initial; } .tab [role='tab'][aria-selected='true'] { color: var(--sl-color-white);