soapbox/app/styles/basics.scss

232 wiersze
4.3 KiB
SCSS
Czysty Zwykły widok Historia

2020-03-27 20:59:38 +00:00
@function hex-color($color) {
@if type-of($color) == 'color' {
$color: str-slice(ie-hex-str($color), 4);
}
2020-05-29 00:58:37 +00:00
@return '%23' + unquote($color);
2020-03-27 20:59:38 +00:00
}
html {
2020-05-29 00:58:37 +00:00
@include font-roboto;
2020-03-27 20:59:38 +00:00
@include font-weight(normal);
font-size: 62.5%;
text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
-webkit-text-size-adjust: 100%;
}
body {
@include font-size(16);
@include line-height(19);
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-rendering: optimizelegibility;
font-feature-settings: "kern";
2020-05-29 00:58:37 +00:00
-webkit-tap-highlight-color: rgba(0, 0, 0, 0);
2020-03-27 20:59:38 +00:00
-webkit-tap-highlight-color: transparent;
2020-06-01 02:05:00 +00:00
color: var(--primary-text-color);
background-color: var(--background-color);
2020-03-27 20:59:38 +00:00
&.system-font {
// system-ui => standard property (Chrome/Android WebView 56+, Opera 43+, Safari 11+)
// -apple-system => Safari <11 specific
// BlinkMacSystemFont => Chrome <56 on macOS specific
// Segoe UI => Windows 7/8/10
// Oxygen => KDE
// Ubuntu => Unity/Ubuntu
// Cantarell => GNOME
// Fira Sans => Firefox OS
// Droid Sans => Older Androids (<4.0)
// Helvetica Neue => Older macOS <10.11
2020-06-02 22:42:09 +00:00
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", "Oxygen", "Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue", sans-serif;
2020-03-27 20:59:38 +00:00
}
&.app-body {
position: absolute;
width: 100%;
padding: 0;
overflow: hidden;
overflow-y: scroll;
&.with-modals--active {
overflow-y: hidden;
}
}
&.lighter {
2020-06-07 03:55:00 +00:00
background: var(--brand-color--med);
2020-03-27 20:59:38 +00:00
}
&.with-modals {
overflow-x: hidden;
overflow-y: scroll;
&--active {
overflow-y: hidden;
margin-right: 13px;
}
}
&.player {
text-align: center;
}
&.embed {
2020-06-07 03:55:00 +00:00
background: var(--brand-color--faint);
2020-03-27 20:59:38 +00:00
margin: 0;
padding-bottom: 0;
.container {
position: absolute;
width: 100%;
height: 100%;
overflow: hidden;
}
}
&.admin {
2020-06-07 03:55:00 +00:00
background: var(--brand-color--med);
2020-03-27 20:59:38 +00:00
position: fixed;
width: 100%;
height: 100%;
padding: 0;
}
&.error {
position: absolute;
text-align: center;
2020-06-07 03:55:00 +00:00
color: var(--primary-text-color--faint);
background: var(--brand-color--med);
2020-03-27 20:59:38 +00:00
width: 100%;
height: 100%;
padding: 0;
display: flex;
justify-content: center;
align-items: center;
.dialog {
vertical-align: middle;
margin: 20px;
&__illustration {
img {
display: block;
max-width: 470px;
width: 100%;
height: auto;
margin-top: -120px;
}
}
h1 {
font-size: 20px;
line-height: 28px;
font-weight: 400;
}
}
}
}
2020-06-03 02:11:01 +00:00
.app-body {
-webkit-overflow-scrolling: touch;
-ms-overflow-style: -ms-autohiding-scrollbar;
2020-03-27 20:59:38 +00:00
}
.app-holder {
&,
& > div {
display: flex;
width: 100%;
height: 100%;
align-items: flex-start;
2020-03-27 20:59:38 +00:00
justify-content: center;
outline: 0 !important;
}
}
.visuallyhidden {
border: 0 !important;
2020-05-29 00:58:37 +00:00
clip: rect(1px, 1px, 1px, 1px) !important;
2020-03-27 20:59:38 +00:00
font-size: 1px !important;
height: 1px !important;
overflow: hidden !important;
padding: 0 !important;
position: absolute !important;
width: 1px !important;
}
::selection {
2020-06-02 23:49:50 +00:00
background: var(--highlight-text-color);
2020-05-31 23:49:48 +00:00
color: #ffffff;
2020-03-27 20:59:38 +00:00
}
.explanation-box {
2020-05-31 23:44:20 +00:00
color: var(--primary-text-color);
2020-03-27 20:59:38 +00:00
padding: 15px 20px;
font-size: 14px;
2020-06-07 03:55:00 +00:00
background-color: var(--brand-color--faint);
2020-03-27 20:59:38 +00:00
margin: 5px 20px;
border-radius: 8px;
&__title {
font-weight: bold;
font-size: 16px;
}
&__explanation {
margin-top: 1em;
2020-03-27 20:59:38 +00:00
}
&__dismiss {
display: inline-block;
text-transform: uppercase;
margin-left: 5px;
font-size: 13px;
}
a {
2020-06-07 03:55:00 +00:00
color: var(--brand-color--hicontrast);
text-decoration: underline;
2020-03-27 20:59:38 +00:00
&:hover {
text-decoration: none;
2020-03-27 20:59:38 +00:00
}
}
}
2020-06-03 02:11:01 +00:00
noscript {
text-align: center;
img {
width: 200px;
opacity: 0.5;
animation: flicker 4s infinite;
}
div {
font-size: 14px;
margin: 30px auto;
2020-06-07 03:55:00 +00:00
color: var(--primary-text-color--faint);
2020-06-03 02:11:01 +00:00
max-width: 400px;
a {
color: var(--highlight-text-color);
text-decoration: underline;
&:hover {
text-decoration: none;
}
}
}
}
.floating-link {
width: 100%;
height: 100%;
top: 0;
right: 0;
bottom: 0;
left: 0;
position: absolute;
z-index: 9999;
}