[Docs] Tweak sidebar titles (#2706)
This PR adjusts the way that sidebar titles look. ### Change Type - [x] `documentation` — Changes to the documentation only[^2]
This commit is contained in:
parent
b76d7b3db1
commit
53698bed70
3 changed files with 22 additions and 20 deletions
1
.ignore
1
.ignore
|
@ -16,5 +16,6 @@ yarn.lock
|
|||
apps/example/www/index.css
|
||||
**/dist/*
|
||||
*.cjs
|
||||
apps/docs/.next
|
||||
|
||||
packages/tldraw/tldraw.css
|
|
@ -200,7 +200,7 @@ function SidebarArticle({
|
|||
|
||||
return (
|
||||
<li className="sidebar__article">
|
||||
<Link href={url} className="sidebar__link" data-active={isActive}>
|
||||
<Link href={url} title={title} className="sidebar__link" data-active={isActive}>
|
||||
{title}
|
||||
</Link>
|
||||
|
||||
|
@ -213,7 +213,7 @@ function SidebarArticle({
|
|||
key={heading.slug}
|
||||
data-heading-level={heading.title === 'Constructor' ? 2 : heading.level}
|
||||
>
|
||||
<Link href={`#${heading.slug}`} className="sidebar__link">
|
||||
<Link href={`#${heading.slug}`} title={heading.title} className="sidebar__link">
|
||||
{heading.isCode ? (
|
||||
<code>{heading.title.replace(/\[([^\]]+)\]\([^)]+\)/g, '$1')}</code>
|
||||
) : (
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
|
||||
/* Light theme */
|
||||
--color-text: #1d1d1d;
|
||||
--color-text-secondary: #999;
|
||||
--color-text-secondary: #666;
|
||||
--color-background: #ffffff;
|
||||
--color-contrast: #ffffff;
|
||||
--color-accent: #2f80ed;
|
||||
|
@ -820,19 +820,19 @@ body {
|
|||
font-size: 13px;
|
||||
}
|
||||
|
||||
.sidebar__list li .sidebar__category li[data-heading-level="3"] a,
|
||||
.sidebar__list li .sidebar__article li[data-heading-level="3"] a {
|
||||
.sidebar__list li .sidebar__category li[data-heading-level='3'] a,
|
||||
.sidebar__list li .sidebar__article li[data-heading-level='3'] a {
|
||||
padding-left: 16px;
|
||||
}
|
||||
|
||||
.sidebar__list li .sidebar__category .sidebar__group li[data-heading-level="2"] a,
|
||||
.sidebar__list li .sidebar__article .sidebar__group li[data-heading-level="2"] a {
|
||||
.sidebar__list li .sidebar__category .sidebar__group li[data-heading-level='2'] a,
|
||||
.sidebar__list li .sidebar__article .sidebar__group li[data-heading-level='2'] a {
|
||||
padding-left: 16px;
|
||||
color: var(--color-text-secondary);
|
||||
}
|
||||
|
||||
.sidebar__list li .sidebar__category .sidebar__group li[data-heading-level="3"] a,
|
||||
.sidebar__list li .sidebar__article .sidebar__group li[data-heading-level="3"] a {
|
||||
.sidebar__list li .sidebar__category .sidebar__group li[data-heading-level='3'] a,
|
||||
.sidebar__list li .sidebar__article .sidebar__group li[data-heading-level='3'] a {
|
||||
padding-left: 24px;
|
||||
}
|
||||
|
||||
|
@ -880,10 +880,11 @@ body {
|
|||
}
|
||||
|
||||
.sidebar__section__title {
|
||||
font-size: 14px;
|
||||
font-weight: normal;
|
||||
font-size: 12px;
|
||||
font-weight: 500;
|
||||
margin-bottom: 4px;
|
||||
position: relative;
|
||||
letter-spacing: 0.5px;
|
||||
height: 40px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
Loading…
Reference in a new issue