Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 9 additions & 1 deletion packages/theme/src/styles/components.css
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ a.rp-edit-link::before {
margin-left: -1em !important;
}

.rp-header-anchor:hover {
border-bottom: none !important;
}

/* doc page header */
.rp-doc.rspress-doc > h1.rp-toc-include {
margin-bottom: 1.5rem !important;
Expand Down Expand Up @@ -52,14 +56,18 @@ a.rp-edit-link::before {
color: var(--rp-c-text-2) !important;
}

.rp-outline__action-row.rp-edit-link {
display: none !important;
}

.rp-doc p > code {
padding: 0.1em 0.2em;
font-size: 1em !important;
border-radius: 4px !important;
}

.rp-code-button-group {
top: 8px !important;
top: 14px !important;
right: 8px !important;
}

Expand Down
6 changes: 3 additions & 3 deletions packages/theme/src/styles/links.css
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ p > .rp-link {
border-bottom: 1px solid var(--rp-c-text-1);
}

/* remove arrow from links */
.rp-link:after {
/* remove arrow from links except external ones */
.rp-link:not(.rp-sidebar-item--active):not([target="_blank"]):after {
content: none !important;
}
}
19 changes: 18 additions & 1 deletion packages/theme/src/styles/nav.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
/* we want full width sidebar highlights on hover */
padding-left: 0 !important;
padding-right: 0 !important;
scrollbar-width: thin;
scrollbar-width: none;
}

/* Nav items */
Expand All @@ -24,13 +24,30 @@
margin-top: 0 !important;
}

.rp-sidebar-item:not(:last-child),
.rp-sidebar-item--active:not(:last-child) {
margin-bottom: 8px !important;
}

.rp-sidebar-item:hover {
background-color: var(--ck-foreground-primary) !important;
}

.rp-sidebar-item--active {
color: var(--rp-c-brand) !important;
font-weight: 400 !important;
position: relative !important;
}

.rp-sidebar-item--active::after {
content: "";
background-color: var(--rp-c-brand);
width: 1px;
height: 100%;
position: absolute;
top: 0;
right: 0;
z-index: 1;
}

/* Section header text */
Expand Down
20 changes: 18 additions & 2 deletions packages/theme/src/styles/toc.css
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ aside.rp-doc-layout__outline > div.rp-outline {
line-height: 1.5 !important;
color: var(--rp-c-text-1) !important;
border-left: none !important;
height: auto !important;
}

.rp-outline__title {
padding-left: 12px !important;
}

/* spacing between toc items */
Expand All @@ -21,6 +26,11 @@ aside.rp-doc-layout__outline > div.rp-outline {
margin-top: 0 !important;
}

.rp-toc-item__text {
font-size: 13px !important;
}


/* hide progress circle */
svg.rp-progress-circle {
display: none !important;
Expand All @@ -35,10 +45,16 @@ svg.rp-progress-circle {
.rp-toc-item {
margin-left: -20px !important;
margin-right: -20px !important;
padding-left: 20px !important;
padding-right: 20px !important;
padding-left: 12px !important;
padding-right: 12px !important;
}

.rp-toc-item--active:before {
left: 0 !important;
background-color: var(--rp-c-text-1) !important;
width: 1px !important;
}

.rp-outline__divider {
margin-left: 12px !important;
}
2 changes: 2 additions & 0 deletions packages/theme/src/styles/variables.css
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@
/* rspress code colors */
--rp-code-title-bg: rgba(233, 231, 238, 1) !important;
--rp-code-block-bg: rgba(249, 248, 253, 1) !important;
--rp-code-block-border: none !important;
/* rspress inline code colors */
--rp-c-text-code: var(--rp-c-text-1) !important;
--rp-c-text-code-bg: var(--ck-border-secondary) !important;
Expand Down Expand Up @@ -174,6 +175,7 @@
/* rspress code colors */
--rp-code-title-bg: rgba(54, 53, 57, 1) !important;
--rp-code-block-bg: rgba(43, 42, 47, 1) !important;
--rp-code-block-border: none !important;
/* rspress inline code colors */
--rp-c-text-code-bg: var(--ck-border-primary) !important;
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,23 +30,23 @@
}

.pagerLink:hover,
.pagerLink:focus {
.pagerLink:focus-visible {
border-color: var(--ck-accent);
background-position: left bottom;
}

.pagerLink:hover .title,
.pagerLink:focus .title {
.pagerLink:focus-visible .title {
color: var(--ck-accent);
}

.pagerLink:hover .iconBox,
.pagerLink:focus .iconBox {
.pagerLink:focus-visible .iconBox {
background-color: var(--ck-accent);
}

.pagerLink:hover .icon,
.pagerLink:focus .icon {
.pagerLink:focus-visible .icon {
color: #ffffff;
}

Expand Down
Loading