2022-06-29 10:49:01 +08:00
|
|
|
:root {
|
2022-07-20 10:56:41 +08:00
|
|
|
--d-sidebar-width: #{$d-sidebar-width};
|
2022-07-07 01:31:06 +08:00
|
|
|
--d-sidebar-animation-time: 0.25s;
|
|
|
|
--d-sidebar-animation-ease: ease-in-out;
|
2022-09-29 12:28:01 +08:00
|
|
|
--d-sidebar-row-height: 30px;
|
|
|
|
// 1.25rem gets text left-aligned with the hamburger icon
|
|
|
|
--d-sidebar-row-horizontal-padding: 1.25rem;
|
|
|
|
--d-sidebar-row-vertical-padding: 0.33rem;
|
|
|
|
--d-sidebar-row-font-size: var(--font-down-1);
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidebar-row {
|
|
|
|
box-sizing: border-box;
|
|
|
|
height: var(--d-sidebar-row-height);
|
|
|
|
padding: var(--d-sidebar-row-vertical-padding)
|
|
|
|
var(--d-sidebar-row-horizontal-padding);
|
|
|
|
align-items: center;
|
|
|
|
font-size: var(--d-sidebar-row-font-size);
|
2022-06-29 10:49:01 +08:00
|
|
|
}
|
|
|
|
|
2022-08-18 15:03:28 +08:00
|
|
|
.sidebar-wrapper {
|
2022-08-25 01:26:25 +08:00
|
|
|
display: flex;
|
2022-08-18 15:03:28 +08:00
|
|
|
--d-sidebar-highlight-color: var(--primary-low);
|
2022-09-29 12:28:01 +08:00
|
|
|
background-color: var(--primary-50);
|
2022-08-18 15:03:28 +08:00
|
|
|
grid-area: sidebar;
|
|
|
|
position: sticky;
|
|
|
|
top: var(--header-offset);
|
2022-08-24 09:33:15 +08:00
|
|
|
|
2022-08-18 15:03:28 +08:00
|
|
|
.footer-nav-ipad & {
|
|
|
|
top: calc(var(--header-offset) + var(--footer-nav-height));
|
|
|
|
}
|
2022-08-25 01:26:25 +08:00
|
|
|
height: calc(100vh - var(--header-offset, 0));
|
2022-08-18 15:03:28 +08:00
|
|
|
align-self: start;
|
|
|
|
overflow-y: auto;
|
|
|
|
|
2022-05-05 14:35:08 +08:00
|
|
|
.sidebar-container {
|
2022-07-22 13:06:47 +08:00
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
2022-05-05 14:35:08 +08:00
|
|
|
box-sizing: border-box;
|
|
|
|
height: 100%;
|
2022-08-25 01:26:25 +08:00
|
|
|
width: 100%;
|
2022-08-24 09:33:15 +08:00
|
|
|
padding: 0;
|
2022-07-01 04:14:29 +08:00
|
|
|
overflow-x: hidden;
|
2022-08-25 01:26:25 +08:00
|
|
|
// allows sidebar to scroll to the bottom when the composer is open
|
|
|
|
height: calc(100% - var(--composer-height, 0));
|
2022-08-19 10:51:55 +08:00
|
|
|
}
|
|
|
|
|
2022-08-25 01:26:25 +08:00
|
|
|
.sidebar-sections {
|
|
|
|
display: flex;
|
|
|
|
flex-direction: column;
|
|
|
|
box-sizing: border-box;
|
|
|
|
flex: 1;
|
2022-09-29 12:28:01 +08:00
|
|
|
padding: 1.5em 0 1em;
|
2022-08-19 10:51:55 +08:00
|
|
|
overflow-x: hidden;
|
|
|
|
overflow-y: overlay;
|
2022-07-01 04:14:29 +08:00
|
|
|
|
|
|
|
// custom scrollbar styling
|
|
|
|
--scrollbarBg: transparent;
|
|
|
|
--scrollbarThumbBg: var(--primary-low);
|
2022-08-25 03:46:01 +08:00
|
|
|
--scrollbarWidth: 0.5em;
|
2022-07-01 04:14:29 +08:00
|
|
|
|
|
|
|
scrollbar-color: transparent var(--scrollbarBg);
|
2022-07-12 00:58:48 +08:00
|
|
|
transition: scrollbar-color 0.25s ease-in-out;
|
|
|
|
transition-delay: 0.5s;
|
|
|
|
|
2022-08-25 03:46:01 +08:00
|
|
|
&::-webkit-scrollbar {
|
|
|
|
width: var(--scrollbarWidth);
|
|
|
|
}
|
|
|
|
|
2022-07-01 04:14:29 +08:00
|
|
|
&::-webkit-scrollbar-thumb {
|
|
|
|
background-color: transparent;
|
|
|
|
border-radius: calc(var(--scrollbarWidth) / 2);
|
2022-08-24 09:33:15 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
&::-webkit-scrollbar-track {
|
|
|
|
background-color: transparent;
|
2022-07-01 04:14:29 +08:00
|
|
|
}
|
2022-08-18 15:03:28 +08:00
|
|
|
|
2022-07-01 04:14:29 +08:00
|
|
|
&:hover {
|
|
|
|
scrollbar-color: var(--scrollbarThumbBg) var(--scrollbarBg);
|
2022-08-19 10:51:55 +08:00
|
|
|
|
2022-07-01 04:14:29 +08:00
|
|
|
&::-webkit-scrollbar-thumb {
|
|
|
|
background-color: var(--scrollbarThumbBg);
|
|
|
|
}
|
2022-08-19 10:51:55 +08:00
|
|
|
|
2022-07-12 00:58:48 +08:00
|
|
|
transition-delay: 0s;
|
2022-07-01 04:14:29 +08:00
|
|
|
}
|
2022-08-24 09:33:15 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidebar-hamburger-dropdown {
|
|
|
|
.discourse-no-touch & {
|
|
|
|
.sidebar-section-wrapper .sidebar-section-header-wrapper:hover,
|
|
|
|
.sidebar-section-wrapper .sidebar-section-header-wrapper:focus-within {
|
|
|
|
background: transparent;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
.sidebar-footer-wrapper {
|
|
|
|
margin-top: 1em;
|
|
|
|
.sidebar-footer-container {
|
|
|
|
background: var(--secondary);
|
|
|
|
&:before {
|
|
|
|
background: linear-gradient(
|
|
|
|
to bottom,
|
|
|
|
transparent,
|
|
|
|
rgba(var(--secondary-rgb), 1)
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|
2022-05-05 14:35:08 +08:00
|
|
|
}
|
2022-07-18 12:03:37 +08:00
|
|
|
}
|