revite/src/pages/settings/Settings.module.scss

280 lines
5.5 KiB
SCSS
Raw Normal View History

2021-08-03 11:07:02 -04:00
/* Settings animations */
2021-06-19 17:37:12 -04:00
@keyframes open {
2021-08-05 18:25:49 -04:00
0% {
transform: scale(1.2);
opacity: 0;
}
100% {
transform: scale(1);
opacity: 1;
}
2021-06-19 17:37:12 -04:00
}
2021-07-05 16:50:55 -04:00
@keyframes close {
2021-08-05 18:25:49 -04:00
0% {
transform: scale(1);
opacity: 1;
}
100% {
transform: scale(1.2);
opacity: 0;
}
2021-07-05 16:50:55 -04:00
}
2021-06-19 17:37:12 -04:00
@keyframes opacity {
2021-08-05 18:25:49 -04:00
0% {
opacity: 0;
}
20% {
opacity: 0.5;
}
50% {
opacity: 1;
}
2021-06-19 17:37:12 -04:00
}
2021-08-03 11:07:02 -04:00
/* Settings CSS */
.settings[data-mobile="true"] {
2021-06-19 17:37:12 -04:00
flex-direction: column;
background: var(--primary-header);
2021-08-05 18:25:49 -04:00
.sidebar,
.content {
background: var(--primary-background);
}
2021-08-03 11:07:02 -04:00
.scrollbox {
2021-08-02 10:21:16 -04:00
&::-webkit-scrollbar-thumb {
border-top: none;
}
}
2021-08-03 11:07:02 -04:00
/* Sidebar */
2021-06-19 17:37:12 -04:00
.sidebar {
2021-08-03 11:07:02 -04:00
overflow-y: auto;
2021-08-02 10:21:16 -04:00
2021-06-19 17:37:12 -04:00
.container {
2021-08-02 10:21:16 -04:00
padding: 20px 8px calc(var(--bottom-navigation-height) + 30px);
2021-06-19 17:37:12 -04:00
min-width: 218px;
}
2021-08-05 18:25:49 -04:00
.scrollbox {
width: 100%;
}
.version {
place-items: center;
}
2021-06-19 17:37:12 -04:00
}
2021-08-03 11:07:02 -04:00
/* Content */
2021-06-19 17:37:12 -04:00
.content {
2021-08-02 10:21:16 -04:00
padding: 0;
2021-08-05 18:25:49 -04:00
.scrollbox {
overflow: auto;
}
2021-08-03 11:07:02 -04:00
.contentcontainer {
max-width: unset !important;
2021-08-03 11:51:35 -04:00
padding: 16px 12px var(--bottom-navigation-height) !important;
2021-08-03 11:07:02 -04:00
}
2021-06-19 17:37:12 -04:00
}
}
.settings:not([data-mobile="true"]) {
2021-06-19 17:37:12 -04:00
top: 0;
left: 0;
z-index: 10;
width: 100%;
height: 100%;
position: fixed;
animation: open 0.18s ease-out, opacity 0.18s;
2021-08-01 16:08:42 -04:00
2021-08-05 18:25:49 -04:00
&.closing {
animation: close 0.18s ease-in;
}
2021-06-19 17:37:12 -04:00
}
.settings {
height: 100%;
display: flex;
user-select: none;
flex-direction: row;
background: var(--primary-background);
2021-08-02 06:22:39 -04:00
.scrollbox {
overflow-y: scroll;
2021-08-02 06:22:39 -04:00
visibility: hidden;
transition: visibility 0.1s;
2021-08-02 06:22:39 -04:00
}
.container,
.contentcontainer,
2021-08-02 06:22:39 -04:00
.scrollbox:hover,
.scrollbox:focus {
visibility: visible;
2021-08-02 06:22:39 -04:00
}
2021-08-05 18:25:49 -04:00
// All children receive custom scrollbar.
> * > ::-webkit-scrollbar-thumb {
2021-08-03 05:51:40 -04:00
width: 4px;
2021-08-02 06:22:39 -04:00
background-clip: content-box;
border-top: 80px solid transparent;
}
2021-06-19 17:37:12 -04:00
.sidebar {
2021-08-01 14:41:53 -04:00
flex: 1 0 218px;
2021-06-19 17:37:12 -04:00
display: flex;
justify-content: flex-end;
background: var(--secondary-background);
.container {
2021-08-02 11:55:49 -04:00
min-width: 218px;
2021-08-07 16:24:28 -04:00
max-width: 300px;
2021-08-02 06:22:39 -04:00
padding: 80px 8px;
2021-08-01 14:41:53 -04:00
display: flex;
gap: 2px;
flex-direction: column;
2021-06-19 17:37:12 -04:00
}
2021-08-05 18:25:49 -04:00
.divider {
height: 30px;
}
2021-06-19 17:37:12 -04:00
2021-08-05 18:25:49 -04:00
.donate {
color: goldenrod !important;
}
.logOut {
color: var(--error) !important;
}
2021-06-19 17:37:12 -04:00
.version {
margin: 1rem 12px 0;
2021-08-05 18:25:49 -04:00
font-size: 0.625rem;
2021-06-19 17:37:12 -04:00
color: var(--secondary-foreground);
font-family: var(--monospace-font), monospace;
2021-06-19 17:37:12 -04:00
user-select: text;
display: grid;
> div {
gap: 2px;
display: flex;
flex-direction: column;
}
2021-06-22 08:47:47 -04:00
2021-08-03 11:07:02 -04:00
a:hover {
2021-06-22 08:47:47 -04:00
text-decoration: underline;
}
2021-06-19 17:37:12 -04:00
}
}
.content {
flex: 1 1 800px;
display: flex;
overflow-y: auto;
2021-06-19 17:37:12 -04:00
.scrollbox {
display: flex;
flex-grow: 1;
}
.contentcontainer {
display: flex;
2021-08-02 10:21:16 -04:00
gap: 13px;
2021-08-02 11:55:49 -04:00
height: fit-content;
max-width: 740px;
2021-08-03 11:07:02 -04:00
padding: 80px 32px;
2021-08-02 10:21:16 -04:00
width: 100%;
flex-direction: column;
}
2021-06-19 17:37:12 -04:00
details {
margin: 14px 0;
}
h1 {
2021-08-02 10:21:16 -04:00
margin: 0;
2021-08-03 11:07:02 -04:00
line-height: 1rem;
font-size: 1.2rem;
2021-06-19 17:37:12 -04:00
font-weight: 600;
}
h3 {
2021-08-05 18:25:49 -04:00
font-size: 0.8125rem;
2021-06-19 17:37:12 -04:00
text-transform: uppercase;
color: var(--secondary-foreground);
2021-08-02 10:21:16 -04:00
&:first-child {
margin-top: 0;
}
2021-06-19 17:37:12 -04:00
}
h4 {
margin: 4px 2px;
2021-08-05 18:25:49 -04:00
font-size: 0.8125rem;
2021-06-19 17:37:12 -04:00
color: var(--tertiary-foreground);
text-transform: uppercase;
}
2021-07-05 17:49:57 -04:00
h5 {
margin-top: 0;
2021-08-05 18:25:49 -04:00
font-size: 0.75rem;
2021-07-05 17:49:57 -04:00
font-weight: 400;
}
2021-06-19 17:37:12 -04:00
.footer {
border-top: 1px solid;
margin: 0;
padding-top: 5px;
2021-08-05 18:25:49 -04:00
font-size: 0.875rem;
2021-06-19 17:37:12 -04:00
color: var(--secondary-foreground);
}
}
2021-08-02 10:21:16 -04:00
.action {
2021-08-02 11:55:49 -04:00
flex-grow: 1;
2021-08-02 06:22:39 -04:00
padding: 80px 8px;
visibility: visible;
position: sticky;
top: 0;
2021-06-19 17:37:12 -04:00
&:after {
content: "ESC";
2021-07-05 18:20:55 -04:00
margin-top: 4px;
2021-06-19 17:37:12 -04:00
display: flex;
justify-content: center;
2021-07-05 18:20:55 -04:00
width: 40px;
2021-08-05 18:25:49 -04:00
opacity: 0.5;
font-size: 0.75rem;
2021-06-19 17:37:12 -04:00
}
2021-07-05 18:20:55 -04:00
.closeButton {
display: flex;
align-items: center;
justify-content: center;
border-radius: var(--border-radius-half);
2021-07-05 18:20:55 -04:00
height: 40px;
width: 40px;
border: 3px solid var(--tertiary-background);
cursor: pointer;
2021-08-05 18:25:49 -04:00
svg {
color: var(--secondary-foreground);
}
&:hover {
background: var(--secondary-header);
}
&:active {
transform: translateY(2px);
}
2021-07-05 18:20:55 -04:00
}
2021-08-02 10:21:16 -04:00
}
2021-06-19 17:37:12 -04:00
}
2021-08-03 11:07:02 -04:00
@media (pointer: coarse) {
.scrollbox {
visibility: visible !important;
overflow-y: auto;
2021-06-19 17:37:12 -04:00
}
2021-08-05 18:25:49 -04:00
}