server auth

This commit is contained in:
2026-05-28 08:35:50 -04:00
parent 3d44a392f1
commit fc63f9c44a
37 changed files with 3877 additions and 74 deletions

View File

@@ -152,6 +152,229 @@ code {
height: calc(100vh - 64px);
}
.auth-shell,
.account-shell {
min-height: 100%;
overflow: auto;
padding: clamp(1rem, 3vw, 2.5rem);
}
.auth-shell {
display: grid;
align-items: start;
justify-items: center;
}
.auth-panel,
.account-section {
width: min(100%, 920px);
border: 1px solid var(--border);
border-radius: var(--radius-sm);
background: var(--panel);
box-shadow: var(--shadow);
}
.auth-panel {
padding: clamp(1rem, 3vw, 2rem);
}
.auth-panel__header,
.account-header {
margin-bottom: 1.25rem;
}
.auth-panel h1,
.account-header h1 {
margin: 0.1rem 0 0;
font-size: clamp(2rem, 4vw, 3.25rem);
line-height: 1;
}
.eyebrow {
margin: 0;
color: var(--muted);
font: 700 0.72rem/1.2 ui-monospace, SFMono-Regular, monospace;
letter-spacing: 0;
text-transform: uppercase;
}
.auth-grid,
.account-grid {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
gap: 1rem;
}
.auth-form {
display: grid;
gap: 0.75rem;
}
.auth-form h2,
.account-section h2 {
margin: 0;
font-size: 1.05rem;
}
.auth-form label,
.scope-grid {
display: grid;
gap: 0.35rem;
color: var(--muted);
font-size: 0.9rem;
}
.auth-form input,
.auth-form select,
.user-row select {
width: 100%;
padding: 0.55rem 0.65rem;
border: 1px solid var(--border);
border-radius: 0;
background: var(--panel-strong);
color: var(--text);
font: inherit;
}
.auth-form button,
.account-header button,
.token-list button,
.user-row button {
min-height: 2.35rem;
padding: 0.45rem 0.75rem;
border: 1px solid var(--border);
border-radius: var(--radius-sm);
background: var(--panel-strong);
color: var(--text);
font: inherit;
cursor: pointer;
}
.auth-form button[type="submit"],
.account-header button {
border-color: color-mix(in srgb, var(--accent) 50%, var(--border));
background: var(--accent);
color: white;
}
.auth-details {
margin-top: 1rem;
padding-top: 1rem;
border-top: 1px solid var(--border);
}
.auth-details summary {
cursor: pointer;
color: var(--accent);
font-weight: 700;
}
.form-status {
min-height: 1.2rem;
margin: 0;
color: var(--muted);
font-size: 0.88rem;
}
.form-status[data-state="error"] {
color: #b42318;
}
.form-status[data-state="ok"] {
color: #067647;
}
.auth-note {
margin: 1rem 0 0;
color: var(--muted);
}
.account-header {
display: flex;
align-items: center;
justify-content: space-between;
gap: 1rem;
width: min(100%, 1120px);
}
.account-header p {
margin: 0.35rem 0 0;
color: var(--muted);
}
.account-grid {
width: min(100%, 1120px);
}
.account-section {
padding: 1rem;
}
.account-section--danger {
border-color: color-mix(in srgb, #b42318 40%, var(--border));
}
.scope-grid {
grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
margin: 0;
padding: 0.75rem;
border: 1px solid var(--border);
}
.scope-grid legend {
padding: 0 0.25rem;
color: var(--text);
}
.scope-grid label {
display: flex;
align-items: center;
gap: 0.4rem;
}
.token-output {
max-width: 100%;
overflow: auto;
padding: 0.75rem;
border: 1px solid var(--border);
background: var(--panel-strong);
white-space: pre-wrap;
overflow-wrap: anywhere;
}
.token-list,
.user-list {
display: grid;
gap: 0.6rem;
margin: 1rem 0 0;
padding: 0;
list-style: none;
}
.token-list li,
.user-row {
display: grid;
grid-template-columns: minmax(0, 1fr) auto;
gap: 0.75rem;
align-items: center;
padding: 0.75rem;
border: 1px solid var(--border);
background: var(--panel-strong);
}
.user-row {
grid-template-columns: minmax(0, 1fr) minmax(8rem, 10rem) auto;
}
.user-row span {
display: grid;
gap: 0.15rem;
}
.user-row small {
color: var(--muted);
}
/* Workspace layout - adaptive grid */
.workspace-shell {
display: grid;
@@ -583,7 +806,9 @@ code {
}
.markdown-body img {
max-width: 100%;
display: block;
max-width: min(85%, 100%);
height: auto;
}
.version-notice {
@@ -640,6 +865,96 @@ code {
display: none;
}
.sync-queue {
position: fixed;
left: 1rem;
bottom: 7.9rem;
z-index: 30;
display: grid;
gap: 0.65rem;
width: min(28rem, calc(100vw - 2rem));
padding: 0.75rem 0.85rem;
border: 1px solid rgba(146, 64, 14, 0.24);
background: rgba(255, 251, 235, 0.97);
color: #78350f;
box-shadow: 0 18px 48px rgba(24, 32, 42, 0.12);
font-size: 0.9rem;
}
.sync-queue[hidden] {
display: none;
}
.sync-queue__header {
display: flex;
align-items: flex-start;
justify-content: space-between;
gap: 0.75rem;
}
.sync-queue__header strong,
.sync-queue__header p {
margin: 0;
}
.sync-queue__header p {
color: #92400e;
font-size: 0.84rem;
}
.sync-queue button {
min-height: 2rem;
flex: 0 0 auto;
padding: 0 0.65rem;
border: 1px solid rgba(146, 64, 14, 0.25);
background: #fff;
color: #78350f;
cursor: pointer;
font: 700 0.82rem/1 ui-monospace, SFMono-Regular, monospace;
}
.sync-queue button:disabled {
cursor: not-allowed;
opacity: 0.55;
}
.sync-queue ul {
display: grid;
gap: 0.35rem;
margin: 0;
padding: 0;
list-style: none;
}
.sync-queue li {
display: flex;
align-items: center;
justify-content: space-between;
gap: 0.75rem;
min-width: 0;
color: #78350f;
}
.sync-queue li span:first-child {
min-width: 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-family: ui-monospace, SFMono-Regular, monospace;
}
.sync-queue li span:last-child {
flex: 0 0 auto;
color: #92400e;
font-size: 0.78rem;
font-weight: 700;
text-transform: uppercase;
}
.sync-queue li[data-state="conflict"] span:last-child {
color: #b91c1c;
}
.offline-icon {
display: inline-block;
width: 0.6rem;
@@ -1231,6 +1546,29 @@ code {
background: oklch(0.60 0.15 250);
}
.sync-queue {
border-color: oklch(0.65 0.12 75 / 0.32);
background: oklch(0.21 0.035 75 / 0.96);
color: oklch(0.75 0.12 75);
box-shadow: 0 18px 48px oklch(0.08 0.02 55 / 0.32);
}
.sync-queue__header p,
.sync-queue li,
.sync-queue li span:last-child {
color: oklch(0.72 0.11 75);
}
.sync-queue button {
border-color: oklch(0.65 0.12 75 / 0.28);
background: oklch(0.17 0.018 55);
color: oklch(0.75 0.12 75);
}
.sync-queue li[data-state="conflict"] span:last-child {
color: oklch(0.68 0.16 25);
}
.version-notice button {
background: var(--accent);
}