aboutsummaryrefslogtreecommitdiff
path: root/src/App.scss
diff options
context:
space:
mode:
Diffstat (limited to 'src/App.scss')
-rw-r--r--src/App.scss515
1 files changed, 259 insertions, 256 deletions
diff --git a/src/App.scss b/src/App.scss
index fa2c6a79..7e428407 100644
--- a/src/App.scss
+++ b/src/App.scss
@@ -1,7 +1,51 @@
+// stylelint-disable rscss/class-format
@import './_variables.scss';
+html {
+ font-size: 14px;
+ overflow: hidden;
+ max-height: 100vh;
+}
+
body {
overflow: hidden;
+ max-height: 100vh;
+ max-width: 100vw;
+ font-family: sans-serif;
+ font-family: var(--interfaceFont, sans-serif);
+ margin: 0;
+ color: $fallback--text;
+ color: var(--text, $fallback--text);
+ overflow-x: hidden;
+ -webkit-font-smoothing: antialiased;
+ -moz-osx-font-smoothing: grayscale;
+
+ &.hidden {
+ display: none;
+ }
+}
+
+a {
+ text-decoration: none;
+ color: $fallback--link;
+ color: var(--link, $fallback--link);
+}
+
+h4 {
+ margin: 0;
+}
+
+nav {
+ z-index: 1000;
+ color: var(--topBarText);
+ background-color: $fallback--fg;
+ background-color: var(--topBar, $fallback--fg);
+ color: $fallback--faint;
+ color: var(--faint, $fallback--faint);
+ box-shadow: 0 0 4px rgba(0, 0, 0, 0.6);
+ box-shadow: var(--topBarShadow);
+ box-sizing: border-box;
+ height: var(--navbar-height);
}
#app-loaded {
@@ -12,14 +56,29 @@ body {
--navbar-height: 50px;
}
-.navbar {
- height: var(--navbar-height);
+#content {
+ overscroll-behavior-y: none;
+ overflow-y: auto;
+ position: sticky;
+}
+
+#sidebar {
+ display: grid;
+ grid-template-columns: 100%;
+ row-gap: 1em;
+ grid-area: sidebar;
+ align-content: start;
+}
+
+#main-scroller {
+ grid-area: content;
}
.app-bg-wrapper {
position: fixed;
- z-index: -1;
height: 100%;
+ top: var(--navbar-height);
+ z-index: -1000;
left: 0;
right: -20px;
background-size: cover;
@@ -29,69 +88,66 @@ body {
background-position: 50%;
}
-h4 {
- margin: 0;
-}
-
-#content {
- overflow-y: auto;
- position: sticky;
-}
-
.app-layout {
position: relative;
display: grid;
- grid-template-columns: auto auto;
+ grid-template-columns: auto minmax(auto, 1fr);
+ grid-template-areas: "sidebar content";
grid-template-rows: 1fr;
box-sizing: border-box;
margin: 0 auto;
- height: 100vh;
+ height: calc(100vh - var(--navbar-height));
align-content: flex-start;
flex-wrap: wrap;
padding: 0 10px 0 10px;
- grid-template-columns: auto auto;
justify-content: center;
+
+ &.-reverse {
+ grid-template-columns: minmax(auto, 1fr) auto;
+ grid-template-areas: "content sidebar";
+ }
}
.underlay {
- height: 100%;
- width: 100%;
grid-column-start: 1;
- grid-column-end: 3;
+ grid-column-end: span 2;
grid-row-start: 1;
grid-row-end: 1;
- margin: -0.5em;
- padding: 0.5em;
+ margin: 0 -0.5em;
+ padding: 0 0.5em;
+ pointer-events: none;
+ background-color: rgba(0, 0, 0, 0.15);
+ background-color: var(--underlay, rgba(0, 0, 0, 0.15));
+ z-index: -2000;
}
.column {
+ box-sizing: border-box;
max-width: 615px;
padding-top: 10px;
grid-row-start: 1;
grid-row-end: 1;
-
- &:nth-child(2) {
- grid-column: 1;
- }
-
- &:nth-child(3) {
- grid-column: 2;
- }
+ margin: 0 0.5em;
&.-mini {
max-width: 345px;
}
&.-scrollable {
+ padding-top: 10px;
position: sticky;
top: 0;
- margin-top: calc(-1 * var(--navbar-padding));
- max-height: 100vh;
+ max-height: calc(100vh - var(--navbar-height));
overflow-y: auto;
+ overflow-x: hidden;
+
+ .panel-heading.-sticky {
+ top: -10px;
+ }
}
}
-body,
+#content,
.column.-scrollable {
&::-webkit-scrollbar {
display: block;
@@ -99,42 +155,10 @@ body,
}
}
-.underlay {
- background-color: rgba(0,0,0,0.15);
- background-color: var(--underlay, rgba(0,0,0,0.15));
-}
-
.text-center {
text-align: center;
}
-html {
- font-size: 14px;
-}
-
-body {
- overscroll-behavior-y: none;
- font-family: sans-serif;
- font-family: var(--interfaceFont, sans-serif);
- margin: 0;
- color: $fallback--text;
- color: var(--text, $fallback--text);
- max-width: 100vw;
- overflow-x: hidden;
- -webkit-font-smoothing: antialiased;
- -moz-osx-font-smoothing: grayscale;
-
- &.hidden {
- display: none;
- }
-}
-
-a {
- text-decoration: none;
- color: $fallback--link;
- color: var(--link, $fallback--link);
-}
-
.button-default {
user-select: none;
color: $fallback--text;
@@ -166,12 +190,12 @@ a {
}
&:hover {
- box-shadow: 0px 0px 4px rgba(255, 255, 255, 0.3);
+ box-shadow: 0 0 4px rgba(255, 255, 255, 0.3);
box-shadow: var(--buttonHoverShadow);
}
&:active {
- box-shadow: 0px 0px 4px 0px rgba(255, 255, 255, 0.3), 0px 1px 0px 0px rgba(0, 0, 0, 0.2) inset, 0px -1px 0px 0px rgba(255, 255, 255, 0.2) inset;
+ box-shadow: 0 0 4px 0 rgba(255, 255, 255, 0.3), 0 1px 0 0 rgba(0, 0, 0, 0.2) inset, 0 -1px 0 0 rgba(255, 255, 255, 0.2) inset;
box-shadow: var(--buttonPressedShadow);
color: $fallback--text;
color: var(--btnPressedText, $fallback--text);
@@ -204,7 +228,7 @@ a {
color: var(--btnToggledText, $fallback--text);
background-color: $fallback--fg;
background-color: var(--btnToggled, $fallback--fg);
- box-shadow: 0px 0px 4px 0px rgba(255, 255, 255, 0.3), 0px 1px 0px 0px rgba(0, 0, 0, 0.2) inset, 0px -1px 0px 0px rgba(255, 255, 255, 0.2) inset;
+ box-shadow: 0 0 4px 0 rgba(255, 255, 255, 0.3), 0 1px 0 0 rgba(0, 0, 0, 0.2) inset, 0 -1px 0 0 rgba(255, 255, 255, 0.2) inset;
box-shadow: var(--buttonPressedShadow);
svg,
@@ -254,8 +278,9 @@ a {
}
}
-input, textarea, .input {
-
+input,
+textarea,
+.input {
&.unstyled {
border-radius: 0;
background: none;
@@ -266,7 +291,7 @@ input, textarea, .input {
border: none;
border-radius: $fallback--inputRadius;
border-radius: var(--inputRadius, $fallback--inputRadius);
- box-shadow: 0px 1px 0px 0px rgba(0, 0, 0, 0.2) inset, 0px -1px 0px 0px rgba(255, 255, 255, 0.2) inset, 0px 0px 2px 0px rgba(0, 0, 0, 1) inset;
+ box-shadow: 0 1px 0 0 rgba(0, 0, 0, 0.2) inset, 0 -1px 0 0 rgba(255, 255, 255, 0.2) inset, 0 0 2px 0 rgba(0, 0, 0, 1) inset;
box-shadow: var(--inputShadow);
background-color: $fallback--fg;
background-color: var(--input, $fallback--fg);
@@ -282,9 +307,11 @@ input, textarea, .input {
height: 28px;
line-height: 16px;
hyphens: none;
- padding: 8px .5em;
+ padding: 8px 0.5em;
- &:disabled, &[disabled=disabled], &.disabled {
+ &:disabled,
+ &[disabled=disabled],
+ &.disabled {
cursor: not-allowed;
opacity: 0.5;
}
@@ -299,18 +326,21 @@ input, textarea, .input {
&[type=radio] {
display: none;
+
&:checked + label::before {
- box-shadow: 0px 0px 2px black inset, 0px 0px 0px 4px $fallback--fg inset;
- box-shadow: var(--inputShadow), 0px 0px 0px 4px var(--fg, $fallback--fg) inset;
+ box-shadow: 0 0 2px black inset, 0 0 0 4px $fallback--fg inset;
+ box-shadow: var(--inputShadow), 0 0 0 4px var(--fg, $fallback--fg) inset;
background-color: var(--accent, $fallback--link);
}
+
&:disabled {
&,
& + label,
& + label::before {
- opacity: .5;
+ opacity: 0.5;
}
}
+
+ label::before {
flex-shrink: 0;
display: inline-block;
@@ -319,9 +349,9 @@ input, textarea, .input {
width: 1.1em;
height: 1.1em;
border-radius: 100%; // Radio buttons should always be circle
- box-shadow: 0px 0px 2px black inset;
+ box-shadow: 0 0 2px black inset;
box-shadow: var(--inputShadow);
- margin-right: .5em;
+ margin-right: 0.5em;
background-color: $fallback--fg;
background-color: var(--input, $fallback--fg);
vertical-align: top;
@@ -337,17 +367,20 @@ input, textarea, .input {
&[type=checkbox] {
display: none;
+
&:checked + label::before {
color: $fallback--text;
color: var(--inputText, $fallback--text);
}
+
&:disabled {
&,
& + label,
& + label::before {
- opacity: .5;
+ opacity: 0.5;
}
}
+
+ label::before {
flex-shrink: 0;
display: inline-block;
@@ -357,9 +390,9 @@ input, textarea, .input {
height: 1.1em;
border-radius: $fallback--checkboxRadius;
border-radius: var(--checkboxRadius, $fallback--checkboxRadius);
- box-shadow: 0px 0px 2px black inset;
+ box-shadow: 0 0 2px black inset;
box-shadow: var(--inputShadow);
- margin-right: .5em;
+ margin-right: 0.5em;
background-color: $fallback--fg;
background-color: var(--input, $fallback--fg);
vertical-align: top;
@@ -387,6 +420,7 @@ option {
.hide-number-spinner {
-moz-appearance: textfield;
+
&[type=number]::-webkit-inner-spin-button,
&[type=number]::-webkit-outer-spin-button {
opacity: 0;
@@ -394,7 +428,8 @@ option {
}
}
-i[class*=icon-], .svg-inline--fa {
+i[class*=icon-],
+.svg-inline--fa {
color: $fallback--icon;
color: var(--icon, $fallback--icon);
}
@@ -426,10 +461,6 @@ i[class*=icon-], .svg-inline--fa {
}
.auto-size {
- flex: 1
-}
-
-main-router {
flex: 1;
}
@@ -439,23 +470,21 @@ main-router {
p {
margin: 0;
- font-size: 0.8em
+ font-size: 0.8em;
}
}
/* Panel */
-
.panel {
- display: flex;
position: relative;
-
+ display: flex;
flex-direction: column;
- margin: 0.5em;
-
+ z-index: 0;
background-color: $fallback--bg;
background-color: var(--bg, $fallback--bg);
- &::after, & {
+ &::after,
+ & {
border-radius: $fallback--panelRadius;
border-radius: var(--panelRadius, $fallback--panelRadius);
}
@@ -463,16 +492,14 @@ main-router {
&::after {
content: '';
position: absolute;
-
top: 0;
bottom: 0;
left: 0;
right: 0;
-
- pointer-events: none;
-
- box-shadow: 1px 1px 4px rgba(0,0,0,.6);
+ z-index: 2;
+ box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.6);
box-shadow: var(--panelShadow);
+ pointer-events: none;
}
}
@@ -484,19 +511,67 @@ main-router {
}
.panel-heading {
+ position: relative;
+ box-sizing: border-box;
display: flex;
flex: none;
border-radius: $fallback--panelRadius $fallback--panelRadius 0 0;
border-radius: var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius) 0 0;
background-size: cover;
- padding: .6em .6em;
+ padding: 0.6em 0.6em;
text-align: left;
line-height: 28px;
color: var(--panelText);
- background-color: $fallback--fg;
- background-color: var(--panel, $fallback--fg);
+ background-color: $fallback--bg;
+ background-color: var(--bg, $fallback--bg);
align-items: baseline;
- box-shadow: var(--panelHeaderShadow);
+ height: var(--panelHeadingHeight);
+ z-index: -2;
+
+ --panelHeadingHeight: 45px;
+
+ &.-flexible-height {
+ --panelHeadingHeight: auto;
+
+ &::after,
+ &::before {
+ display: none;
+ }
+ }
+
+ &.-sticky {
+ position: sticky;
+ top: 0;
+ z-index: 2;
+ }
+
+ &::after,
+ &::before {
+ content: '';
+ position: absolute;
+ top: 0;
+ bottom: 0;
+ right: 0;
+ left: 0;
+ pointer-events: none;
+ }
+
+ &::after {
+ background-color: $fallback--fg;
+ background-color: var(--panel, $fallback--fg);
+ z-index: -2;
+ border-radius: $fallback--panelRadius $fallback--panelRadius 0 0;
+ border-radius: var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius) 0 0;
+ box-shadow: var(--panelHeaderShadow);
+ }
+
+ &::before {
+ bottom: -20px;
+ z-index: -1;
+ border-radius: $fallback--panelRadius $fallback--panelRadius 0 0;
+ border-radius: var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius) 0 0;
+ mask: linear-gradient(to bottom, white var(--panelHeadingHeight), transparent var(--panelHeadingHeight));
+ }
.title {
flex: 1 0 auto;
@@ -527,7 +602,7 @@ main-router {
min-height: 0;
box-sizing: border-box;
margin: 0;
- margin-left: .5em;
+ margin-left: 0.5em;
min-width: 1px;
align-self: stretch;
}
@@ -562,7 +637,7 @@ main-router {
a,
.-link {
color: $fallback--link;
- color: var(--panelLink, $fallback--link)
+ color: var(--panelLink, $fallback--link);
}
}
@@ -574,7 +649,7 @@ main-router {
/* TODO Should remove timeline-footer from here when we refactor panels into
* separate component and utilize slots
*/
-.panel-footer, .timeline-footer {
+.panel-footer {
display: flex;
border-radius: 0 0 $fallback--panelRadius $fallback--panelRadius;
border-radius: 0 0 var(--panelRadius, $fallback--panelRadius) var(--panelRadius, $fallback--panelRadius);
@@ -605,37 +680,18 @@ main-router {
margin: 0;
}
-.container > * {
- min-width: 0px;
-}
-
.fa {
color: grey;
}
-nav {
- z-index: 1000;
- color: var(--topBarText);
- background-color: $fallback--fg;
- background-color: var(--topBar, $fallback--fg);
- color: $fallback--faint;
- color: var(--faint, $fallback--faint);
- box-shadow: 0px 0px 4px rgba(0,0,0,.6);
- box-shadow: var(--topBarShadow);
- box-sizing: border-box;
-}
-
-.fade-enter-active, .fade-leave-active {
- transition: opacity .2s
-}
-.fade-enter-from, .fade-leave-active {
- opacity: 0
+.fade-enter-active,
+.fade-leave-active {
+ transition: opacity 0.2s;
}
-.main {
- flex-basis: 50%;
- flex-grow: 1;
- flex-shrink: 1;
+.fade-enter-from,
+.fade-leave-active {
+ opacity: 0;
}
.sidebar-bounds {
@@ -653,34 +709,6 @@ nav {
display: none;
}
-@media all and (min-width: 800px) {
- .sidebar-bounds {
- overflow: hidden;
- max-height: 100vh;
- width: 345px;
- position: fixed;
- margin-top: -10px;
-
- .sidebar-scroller {
- height: 96vh;
- width: 365px;
- padding-top: 10px;
- padding-right: 50px;
- overflow-x: hidden;
- overflow-y: scroll;
- }
-
- .sidebar {
- width: 345px;
- }
- }
- .sidebar-flexer {
- max-height: 96vh;
- flex-shrink: 0;
- flex-grow: 0;
- }
-}
-
.badge {
box-sizing: border-box;
display: inline-block;
@@ -764,7 +792,7 @@ nav {
}
.visibility-notice {
- padding: .5em;
+ padding: 0.5em;
border: 1px solid $fallback--faint;
border: 1px solid var(--faint, $fallback--faint);
border-radius: $fallback--inputRadius;
@@ -779,7 +807,7 @@ nav {
position: absolute;
top: 0;
right: 0;
- padding: .5em;
+ padding: 0.5em;
color: inherit;
}
}
@@ -796,30 +824,57 @@ nav {
}
}
-@keyframes shakeError {
- 0% {
- transform: translateX(0);
- }
- 15% {
- transform: translateX(0.375rem);
- }
- 30% {
- transform: translateX(-0.375rem);
- }
- 45% {
- transform: translateX(0.375rem);
- }
- 60% {
- transform: translateX(-0.375rem);
+.login-hint {
+ text-align: center;
+
+ @media all and (min-width: 801px) {
+ display: none;
}
- 75% {
- transform: translateX(0.375rem);
+
+ a {
+ display: inline-block;
+ padding: 1em 0;
+ width: 100%;
}
- 90% {
- transform: translateX(-0.375rem);
+}
+
+.btn.button-default {
+ min-height: 28px;
+}
+
+.new-status-notification {
+ position: relative;
+ font-size: 1.1em;
+ z-index: 1;
+ flex: 1;
+}
+
+@media all and (min-width: 800px) {
+ .sidebar-bounds {
+ overflow: hidden;
+ max-height: 100vh;
+ width: 345px;
+ position: fixed;
+ margin-top: -10px;
+
+ .sidebar-scroller {
+ height: 96vh;
+ width: 365px;
+ padding-top: 10px;
+ padding-right: 50px;
+ overflow-x: hidden;
+ overflow-y: scroll;
+ }
+
+ .sidebar {
+ width: 345px;
+ }
}
- 100% {
- transform: translateX(0);
+
+ .sidebar-flexer {
+ max-height: 96vh;
+ flex-shrink: 0;
+ flex-grow: 0;
}
}
@@ -832,14 +887,6 @@ nav {
display: flex;
}
- .container {
- padding: 0;
- }
-
- .panel {
- margin: 0.5em 0 0.5em 0;
- }
-
.menu-button {
display: block;
margin-right: 0.8em;
@@ -850,41 +897,6 @@ nav {
}
}
-.setting-list,
-.option-list{
- list-style-type: none;
- padding-left: 2em;
- li {
- margin-bottom: 0.5em;
- }
- .suboptions {
- margin-top: 0.3em
- }
-}
-
-.login-hint {
- text-align: center;
-
- @media all and (min-width: 801px) {
- display: none;
- }
-
- a {
- display: inline-block;
- padding: 1em 0px;
- width: 100%;
- }
-}
-
-.btn.button-default {
- min-height: 28px;
-}
-
-.animate-spin {
- animation: spin 2s infinite linear;
- display: inline-block;
-}
-
@keyframes spin {
0% {
transform: rotate(0deg);
@@ -895,45 +907,36 @@ nav {
}
}
-.new-status-notification {
- position: relative;
- font-size: 1.1em;
- z-index: 1;
- flex: 1;
-}
+@keyframes shakeError {
+ 0% {
+ transform: translateX(0);
+ }
-.chat-layout {
- // Needed for smoother chat navigation in the desktop Safari (otherwise the chat layout "jumps" as the chat opens).
- overflow: hidden;
- height: 100%;
+ 15% {
+ transform: translateX(0.375rem);
+ }
- // Get rid of scrollbar on body as scrolling happens on different element
- // Ensures the fixed position of the mobile browser bars on scroll up / down events.
- // Prevents the mobile browser bars from overlapping or hiding the message posting form.
- @media all and (max-width: 800px) {
- body {
- height: 100%;
- }
+ 30% {
+ transform: translateX(-0.375rem);
+ }
- #app {
- height: 100%;
- overflow: hidden;
- min-height: auto;
- }
+ 45% {
+ transform: translateX(0.375rem);
+ }
- #app_bg_wrapper {
- overflow: hidden;
- }
+ 60% {
+ transform: translateX(-0.375rem);
+ }
- .main {
- overflow: hidden;
- height: 100%;
- }
+ 75% {
+ transform: translateX(0.375rem);
+ }
- #content {
- padding-top: 0;
- height: 100%;
- overflow: visible;
- }
+ 90% {
+ transform: translateX(-0.375rem);
+ }
+
+ 100% {
+ transform: translateX(0);
}
}