mirror of
https://github.com/minio/docs.git
synced 2025-04-24 06:05:11 +03:00
- Fixed the sidebar scroll - with this fix, you'll be able to scroll to the end of the left sidebar at any given screen height. - Renamed content-navigation component and CSS class names for better consistency. - Changed the footer style by including it as part of the main content area. This change is required to have the scroll fix mentioned at point no. 1. - Reduced the hero height by a small margin, in order to have more sidebar scroll room on smaller devices such as 13 inch laptop and all. - Used higher contrast color on search modal's bg and scrollbar thumb to have better color consistency. - Made scrollbar thumbs visible by default. - Set sidebar scroll position to match the active doc item. - Added custom scrollbars for code blocks.
156 lines
3.6 KiB
SCSS
156 lines
3.6 KiB
SCSS
div.topic {
|
|
all: revert;
|
|
}
|
|
|
|
.content__toc {
|
|
position: sticky;
|
|
top: 0;
|
|
|
|
@include breakpoint-min(breakpoints(lg)) {
|
|
flex-shrink: 0;
|
|
order: 2;
|
|
width: 14rem;
|
|
height: calc(100vh - 6.0625rem); // 6.0625rem = header height
|
|
padding: var(--content-padding) var(--content-padding) var(--content-padding) 0;
|
|
overflow-y: auto;
|
|
|
|
.icon {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
@include breakpoint-max(breakpoints(lg)) {
|
|
display: flex;
|
|
gap: 0.75rem;
|
|
align-items: center;
|
|
padding: var(--content-padding);
|
|
background-color: var(--body-bg);
|
|
z-index: $z-index-header - 2;
|
|
}
|
|
|
|
.icon {
|
|
height: 2.5rem;
|
|
width: 2.5rem;
|
|
padding: 0.7rem;
|
|
border: 1px solid var(--theme-light-bg);
|
|
cursor: pointer;
|
|
|
|
&:last-child {
|
|
margin-left: auto;
|
|
}
|
|
}
|
|
|
|
&.active {
|
|
#table-of-contents {
|
|
& > ul {
|
|
display: block;
|
|
}
|
|
|
|
.topic-title {
|
|
border-radius: $border-radius $border-radius 0 0;
|
|
|
|
&:after {
|
|
transform: rotate(180deg);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
.content__toc--empty {
|
|
@include breakpoint-min(breakpoints(lg)) {
|
|
display: none;
|
|
}
|
|
}
|
|
|
|
#table-of-contents {
|
|
flex: 1;
|
|
position: relative;
|
|
|
|
.topic-title {
|
|
color: var(--headings-color);
|
|
margin: 0;
|
|
line-height: 1;
|
|
font-size: $font-size-md;
|
|
|
|
@include breakpoint-max(breakpoints(lg)) {
|
|
padding: 0.85rem 1rem;
|
|
background-color: var(--theme-light-bg);
|
|
border-radius: $border-radius;
|
|
display: block;
|
|
position: relative;
|
|
font-size: $font-size-sm;
|
|
cursor: pointer;
|
|
|
|
&:after {
|
|
content: "";
|
|
height: 1rem;
|
|
width: 1rem;
|
|
position: absolute;
|
|
right: 1rem;
|
|
top: 0.8rem;
|
|
background: var(--toc-caret-icon) no-repeat center;
|
|
background-size: 0.8rem;
|
|
transform-origin: center;
|
|
}
|
|
}
|
|
}
|
|
|
|
ul {
|
|
list-style: none;
|
|
padding: 0;
|
|
margin: 0;
|
|
font-size: $font-size-sm;
|
|
color: var(--text-muted-color);
|
|
|
|
ul {
|
|
margin-left: 0.75rem;
|
|
}
|
|
}
|
|
|
|
& > ul {
|
|
@include breakpoint-min(breakpoints(lg)) {
|
|
position: relative;
|
|
padding-left: 1rem;
|
|
margin-top: 1rem;
|
|
|
|
&:before {
|
|
content: "";
|
|
width: 2px;
|
|
height: calc(100% - 0.8rem);
|
|
position: absolute;
|
|
left: 0.2rem;
|
|
top: 0.5rem;
|
|
background-color: var(--theme-light-bg);
|
|
}
|
|
}
|
|
|
|
@include breakpoint-max(breakpoints(lg)) {
|
|
position: absolute;
|
|
left: 0;
|
|
top: 100%;
|
|
width: 100%;
|
|
background-color: var(--toc-dropdown-bg);
|
|
display: none;
|
|
border-radius: 0 0 $border-radius $border-radius;
|
|
z-index: 1;
|
|
padding: 0.65rem 1rem 1rem;
|
|
max-height: 12rem;
|
|
overflow-y: auto;
|
|
}
|
|
|
|
a {
|
|
display: block;
|
|
color: var(--text-muted-color);
|
|
padding: 0.15rem 0;
|
|
|
|
code {
|
|
display: none;
|
|
}
|
|
|
|
&:hover {
|
|
color: var(--text-color);
|
|
}
|
|
}
|
|
}
|
|
} |