300 lines
5.5 KiB
CSS
300 lines
5.5 KiB
CSS
:root {
|
|
color-scheme: light;
|
|
font-family:
|
|
Inter,
|
|
ui-sans-serif,
|
|
system-ui,
|
|
-apple-system,
|
|
BlinkMacSystemFont,
|
|
"Segoe UI",
|
|
sans-serif;
|
|
}
|
|
|
|
* {
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
html,
|
|
body,
|
|
#root {
|
|
margin: 0;
|
|
height: 100%;
|
|
}
|
|
|
|
body {
|
|
background: #f5f5f4;
|
|
color: #18181b;
|
|
}
|
|
|
|
button,
|
|
input {
|
|
font: inherit;
|
|
}
|
|
|
|
.app-shell {
|
|
height: 100%;
|
|
color: var(--app-text-color, #18181b);
|
|
--app-sidebar-font-size: 0.875rem;
|
|
--app-island-bg: #ffffff;
|
|
--app-sidebar-bg: #ffffff;
|
|
--app-sidebar-border: #e4e4e7;
|
|
--app-sidebar-shadow: 0 24px 80px rgba(24, 24, 27, 0.22);
|
|
--app-surface-lowest: #ffffff;
|
|
--app-surface-low: #f4f4f5;
|
|
--app-selected-bg: #f4f4f5;
|
|
--app-text-color: #18181b;
|
|
--app-selected-text-color: #18181b;
|
|
--app-disabled-color: #a1a1aa;
|
|
--app-input-bg: #ffffff;
|
|
--app-input-border: #d4d4d8;
|
|
--app-input-color: #18181b;
|
|
--app-button-border: #d4d4d8;
|
|
--app-button-hover-bg: #f4f4f5;
|
|
--app-button-active-bg: #e4e4e7;
|
|
--app-button-active-border: #5b8def;
|
|
--app-overlay-bg: rgba(255, 255, 255, 0.88);
|
|
}
|
|
|
|
.sidebar {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
z-index: 40;
|
|
display: flex;
|
|
height: 100%;
|
|
width: min(340px, calc(100vw - 32px));
|
|
flex-direction: column;
|
|
border-right: 1px solid var(--app-sidebar-border);
|
|
background: var(--app-sidebar-bg);
|
|
box-shadow: var(--app-sidebar-shadow);
|
|
transform: translateX(calc(-100% - 24px));
|
|
transition:
|
|
transform 180ms ease,
|
|
box-shadow 180ms ease;
|
|
}
|
|
|
|
.sidebar-open {
|
|
transform: translateX(0);
|
|
}
|
|
|
|
.sidebar-header {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: space-between;
|
|
gap: 12px;
|
|
border-bottom: 1px solid var(--app-sidebar-border);
|
|
padding: 16px;
|
|
}
|
|
|
|
.sidebar-header h1 {
|
|
margin: 0;
|
|
font-size: var(--app-sidebar-font-size);
|
|
font-weight: 600;
|
|
color: var(--app-text-color);
|
|
}
|
|
|
|
.sidebar-actions {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
}
|
|
|
|
.sidebar-actions .primary-button,
|
|
.sidebar-actions .icon-button {
|
|
height: 32px;
|
|
}
|
|
|
|
.drawing-list {
|
|
flex: 1;
|
|
overflow: auto;
|
|
padding: 8px;
|
|
}
|
|
|
|
.drawing-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 4px;
|
|
border-radius: 8px;
|
|
padding: 4px 12px;
|
|
}
|
|
|
|
.drawing-item-active {
|
|
background: var(--app-selected-bg);
|
|
color: var(--app-selected-text-color);
|
|
}
|
|
|
|
.drawing-link {
|
|
flex: 1 1 auto;
|
|
min-width: 0;
|
|
border: 0;
|
|
background: transparent;
|
|
color: inherit;
|
|
padding: 8px 0;
|
|
text-align: left;
|
|
font-size: var(--app-sidebar-font-size);
|
|
}
|
|
|
|
.drawing-title,
|
|
.title-input {
|
|
display: block;
|
|
width: 100%;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.title-input {
|
|
border: 1px solid var(--app-input-border);
|
|
border-radius: 6px;
|
|
background: var(--app-input-bg);
|
|
color: var(--app-input-color);
|
|
font-size: var(--app-sidebar-font-size);
|
|
padding: 6px 8px;
|
|
}
|
|
|
|
.editor-shell {
|
|
position: relative;
|
|
height: 100%;
|
|
}
|
|
|
|
.app-actions {
|
|
position: fixed;
|
|
right: max(16px, calc(env(safe-area-inset-right) + 16px));
|
|
bottom: calc(max(16px, env(safe-area-inset-bottom)) + 48px);
|
|
z-index: 20;
|
|
display: flex;
|
|
}
|
|
|
|
.app-actions-toggle {
|
|
display: inline-flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 2.25rem;
|
|
height: 2.25rem;
|
|
padding: 0;
|
|
border: none;
|
|
border-radius: 8px;
|
|
box-shadow: none;
|
|
background: var(--app-surface-low);
|
|
color: var(--app-text-color);
|
|
cursor: pointer;
|
|
transition: background-color 120ms ease, box-shadow 120ms ease;
|
|
}
|
|
|
|
.app-actions-toggle svg {
|
|
width: 1rem;
|
|
height: 1rem;
|
|
overflow: visible;
|
|
transform: translateY(0.5px) scale(1.08);
|
|
transform-origin: center;
|
|
}
|
|
|
|
.primary-button,
|
|
.secondary-button,
|
|
.icon-button {
|
|
border: 1px solid var(--app-button-border);
|
|
border-radius: 8px;
|
|
background: var(--app-island-bg);
|
|
color: var(--app-text-color);
|
|
transition:
|
|
background-color 120ms ease,
|
|
border-color 120ms ease,
|
|
color 120ms ease,
|
|
box-shadow 120ms ease;
|
|
}
|
|
|
|
.primary-button,
|
|
.secondary-button {
|
|
cursor: pointer;
|
|
font-size: var(--app-sidebar-font-size);
|
|
font-weight: 500;
|
|
padding: 8px 12px;
|
|
}
|
|
|
|
.primary-button:hover,
|
|
.secondary-button:hover,
|
|
.icon-button:hover {
|
|
background: var(--app-button-hover-bg);
|
|
}
|
|
|
|
.primary-button:active,
|
|
.secondary-button:active,
|
|
.icon-button:active {
|
|
background: var(--app-button-active-bg);
|
|
border-color: var(--app-button-active-border);
|
|
}
|
|
|
|
.secondary-button:disabled {
|
|
cursor: not-allowed;
|
|
opacity: 0.6;
|
|
color: var(--app-disabled-color);
|
|
}
|
|
|
|
.icon-button {
|
|
display: inline-flex;
|
|
flex: 0 0 32px;
|
|
align-items: center;
|
|
justify-content: center;
|
|
width: 32px;
|
|
height: 32px;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.sidebar-backdrop {
|
|
position: fixed;
|
|
inset: 0;
|
|
z-index: 30;
|
|
background: color-mix(in srgb, var(--app-overlay-bg) 72%, #000000);
|
|
opacity: 0;
|
|
pointer-events: none;
|
|
transition: opacity 180ms ease;
|
|
}
|
|
|
|
.sidebar-backdrop-open {
|
|
opacity: 1;
|
|
pointer-events: auto;
|
|
}
|
|
|
|
.editor-frame,
|
|
.editor-loading {
|
|
height: 100%;
|
|
}
|
|
|
|
.editor-loading {
|
|
display: grid;
|
|
place-items: center;
|
|
color: var(--app-text-color);
|
|
}
|
|
|
|
.app-actions-toggle:hover {
|
|
background-color: var(--app-button-hover-bg);
|
|
}
|
|
|
|
.app-actions-toggle:active {
|
|
background-color: var(--app-button-active-bg);
|
|
box-shadow: none;
|
|
}
|
|
|
|
.sr-only {
|
|
position: absolute;
|
|
width: 1px;
|
|
height: 1px;
|
|
padding: 0;
|
|
margin: -1px;
|
|
overflow: hidden;
|
|
clip: rect(0, 0, 0, 0);
|
|
white-space: nowrap;
|
|
border: 0;
|
|
}
|
|
|
|
@media (max-width: 900px) {
|
|
.sidebar {
|
|
width: min(300px, calc(100vw - 20px));
|
|
}
|
|
|
|
.app-actions {
|
|
right: max(16px, calc(env(safe-area-inset-right) + 16px));
|
|
bottom: calc(max(16px, env(safe-area-inset-bottom)) + 56px);
|
|
}
|
|
}
|