phonograph/sass/main.scss

250 lines
4.2 KiB
SCSS
Raw Normal View History

2025-08-09 00:14:58 -07:00
@use 'sass:color';
@use 'basic-dropdown';
2025-08-04 13:59:42 -07:00
@use 'globals';
@use 'modern-normalize';
2025-09-08 15:56:57 -07:00
@use 'forms';
@use 'collapsible_menu';
2025-10-01 22:36:19 -07:00
@use 'condition-editor';
2025-10-24 18:21:40 +00:00
@use 'tabler-icons' with (
$ti-font-path: '../tabler-icons/webfont/fonts'
);
2025-09-25 14:51:09 -07:00
@use 'workspace-nav';
2025-07-16 22:03:04 -07:00
2025-08-04 13:59:42 -07:00
html {
2025-09-25 14:51:09 -07:00
font-family: globals.$font-family-default;
2025-08-04 13:59:42 -07:00
}
button, input[type="submit"] {
2025-08-24 23:24:01 -07:00
@include globals.reset-button;
2025-08-04 13:59:42 -07:00
}
@font-face {
font-family: "Averia Serif Libre";
src: url("../averia_serif_libre/averia_serif_libre_regular.ttf");
}
@font-face {
font-family: "Averia Serif Libre";
src: url("../averia_serif_libre/averia_serif_libre_bold.ttf");
font-weight: 700;
}
@font-face {
font-family: "Averia Serif Libre";
src: url("../averia_serif_libre/averia_serif_libre_light.ttf");
font-weight: 300;
}
@font-face {
font-family: "Funnel Sans";
src: url("../funnel_sans/funnel_sans_variable.ttf");
}
@view-transitions {
navigation: auto;
}
2025-08-09 00:14:58 -07:00
// https://css-tricks.com/inclusively-hidden/
.sr-only:not(:focus):not(:active) {
clip: rect(0 0 0 0);
clip-path: inset(50%);
height: 1px;
overflow: hidden;
position: absolute;
white-space: nowrap;
width: 1px;
}
2025-08-24 23:24:01 -07:00
.button {
&--primary {
@include globals.button-primary;
}
&--secondary {
@include globals.button-secondary;
}
2025-09-08 15:56:57 -07:00
&--clear {
@include globals.button-clear;
}
&--small {
@include globals.button-small;
}
2025-08-24 23:24:01 -07:00
}
.padded {
padding: 8px;
&--lg {
padding: 32px;
}
}
2025-08-04 13:59:42 -07:00
.page-grid {
height: 100vh;
width: 100vw;
display: grid;
grid-template:
'sidebar toolbar' 4rem
'sidebar main' 1fr / max-content 1fr;
&__toolbar {
2025-08-24 23:24:01 -07:00
align-items: center;
2025-08-04 13:59:42 -07:00
border-bottom: globals.$default-border;
2025-08-24 23:24:01 -07:00
display: grid;
grid-area: toolbar;
grid-template:
'utilities user' 1fr / 1fr max-content;
2025-08-04 13:59:42 -07:00
}
2025-10-01 22:36:19 -07:00
&__toolbar-utilities {
align-items: center;
display: flex;
2025-10-25 05:32:22 +00:00
gap: 12px;
2025-10-01 22:36:19 -07:00
grid-area: utilities;
justify-content: flex-start;
2025-10-25 05:32:22 +00:00
padding: 0 12px;
}
&__toolbar-user {
align-items: center;
display: flex;
gap: 12px;
grid-area: user;
justify-content: flex-end;
padding: 0 12px;
2025-10-01 22:36:19 -07:00
}
2025-08-04 13:59:42 -07:00
&__sidebar {
grid-area: sidebar;
width: 15rem;
max-height: 100vh;
overflow: auto;
border-right: globals.$default-border;
}
&__main {
grid-area: main;
2025-10-01 22:36:19 -07:00
overflow: auto;
2025-08-04 13:59:42 -07:00
}
}
2025-08-09 00:14:58 -07:00
2025-08-24 23:24:01 -07:00
.toolbar-item {
flex: 0;
}
2025-08-09 00:14:58 -07:00
.section {
padding: 1rem 2rem;
}
.notice {
@include globals.rounded;
margin: 1rem 0rem;
padding: 1rem;
max-width: 40rem;
&--info {
border: solid 1px globals.$notice-color-info;
background: color.scale(globals.$notice-color-info, $lightness: 90%, $space: hsl);
color: color.scale(globals.$notice-color-info, $lightness: -80%, $space: hsl);
}
}
.role-tree {
font-family: globals.$font-family-data;
&--no-inherit {
opacity: 0.6;
font-style: italic;
}
&__branches {
border-left: solid 1px #000;
list-style-type: none;
margin: 0;
margin-top: 0.25rem;
padding: 0;
}
&__branch {
padding-top: 0.25rem;
padding-left: 1rem;
}
}
2025-08-24 23:24:01 -07:00
// TODO: can this be removed?
2025-08-24 23:24:01 -07:00
.button-menu {
&__toggle-button {
@include globals.button-outline;
align-items: center;
display: flex;
&-icon {
display: flex;
svg path {
stroke: currentColor;
}
}
}
&__popover {
&:popover-open {
2025-09-08 15:56:57 -07:00
@include globals.popover;
2025-08-24 23:24:01 -07:00
width: 16rem;
// FIXME: This makes button border radius work correctly, but also hides
// the outline that appears when each button is focused, particularly
// when there is only one button present.
overflow: hidden;
}
}
// Palindrome humor! Anyone? No? Okay nvm.
&__unem-nottub {
@include globals.button-clear;
border-radius: 0;
padding: 1rem;
text-align: left;
}
}
2025-09-08 15:56:57 -07:00
.combobox {
&__popover:popover-open {
@include globals.popover;
padding: 0;
}
&__completion {
@include globals.reset-button;
display: block;
padding: 0.5rem;
font-weight: normal;
text-align: left;
width: 100%;
&:hover, &:focus {
background: #0000001f;
}
}
}
.table {
border-collapse: collapse;
th, td {
border: globals.$default-border;
padding: 8px;
}
th {
background: #eee;
}
&__message {
opacity: 0.5;
text-align: center;
}
}