Skip to content

Commit b830fba

Browse files
authored
Merge pull request #12 from Semantic-Org/bug/docs-mobile-import
Bug: Fix Import Line Overflow on Mobile
2 parents 1e81fb6 + 839e22f commit b830fba

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

‎docs/src/layouts/Docs.astro‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ const source = JSON.stringify(entry.body).replace(/</g, '\\u003c');
4747
<slot />
4848

4949
<div class="doc-foot" data-pagefind-ignore>
50-
<a href={`https://github.com/nav-router/nav-router/edit/main/docs/src/content/docs/${entry.id}.md`}>Edit this page</a>
50+
<a href={`https://github.com/Semantic-Org/Nav-Router/edit/main/docs/src/content/docs/${entry.id}.md`}>Edit this page</a>
5151
<span>Updated {updatedLabel}</span>
5252
</div>
5353
<nav class="pager" aria-label="Pages" data-pagefind-ignore>

‎docs/src/styles/docs.css‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,11 @@
147147
border: 1px solid var(--line-2); border-radius: var(--r-2);
148148
background: var(--code-bg); font-size: var(--fs-xs); color: var(--text);
149149
}
150-
.import-chip .copy { width: 26px; height: 26px; }
150+
.import-chip .copy { flex: none; width: 26px; height: 26px; }
151+
/* a long import never pushes past the column: the code scrolls inside the chip, the copy stays put */
152+
.import-chip { max-width: 100%; min-width: 0; }
153+
.import-chip code { min-width: 0; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
154+
.import-chip code::-webkit-scrollbar { display: none; }
151155
.meta-badge {
152156
display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 10px;
153157
border: 1px solid var(--line); border-radius: var(--r-2);

0 commit comments

Comments
 (0)