refactor styles

This commit is contained in:
2025-11-10 11:30:16 +01:00
parent b4a1821a55
commit 585caaee58
31 changed files with 4873 additions and 4867 deletions
+108
View File
@@ -0,0 +1,108 @@
.view-toggle {
display: inline-flex;
align-items: center;
gap: 0.25rem;
}
.view-toggle__button {
border: 1px solid var(--border);
background: transparent;
color: var(--muted);
padding: 0.3rem 0.6rem;
border-radius: 4px;
cursor: pointer;
transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.view-toggle__button:hover,
.view-toggle__button:focus-visible {
background: var(--surface-subtle);
color: var(--fg);
outline: none;
}
.view-toggle__button.active {
background: var(--accent);
color: var(--on-accent);
border-color: var(--accent);
}
.view-toggle__icon {
width: 1.4rem;
height: 1.4rem;
}
.documents-actions__sort-group {
display: inline-flex;
align-items: center;
gap: 0.35rem;
}
.documents-sort {
display: inline-flex;
align-items: center;
position: relative;
}
.documents-sort__trigger {
display: inline-flex;
align-items: center;
gap: 0.35rem;
font-size: 0.85rem;
white-space: nowrap;
padding: 0.25rem 0.5rem;
min-height: 2.1rem;
}
.documents-sort__label {
display: inline-flex;
align-items: center;
line-height: 1.1;
}
.documents-sort__trigger-content {
display: inline-flex;
align-items: center;
gap: 0.35rem;
}
.documents-sort__quickmenu .menu__item,
.documents-sort__quickmenu .menu__item.active {
font-weight: 400;
}
.documents-toolbar__toggle {
border: 1px solid var(--border);
border-radius: 4px;
padding: 0.3rem;
background: transparent;
color: var(--muted);
transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.documents-toolbar__toggle:hover:not([disabled]) {
color: var(--fg);
border-color: var(--border);
}
.documents-toolbar__toggle[aria-pressed='true'] {
border-color: var(--accent);
color: var(--accent);
background: var(--surface-subtle);
}
.documents-sort__direction {
padding: 0.3rem 0.45rem;
}
.documents-sort__direction[aria-pressed='true'] {
border-color: var(--border);
color: var(--muted);
background: transparent;
}
.documents-sort__direction svg {
width: 1.1rem;
height: 1.1rem;
}
+736
View File
@@ -0,0 +1,736 @@
.documents-panel {
padding: 0 0.75rem 0.75rem 0.75rem;
display: flex;
flex-direction: column;
min-height: 0;
}
.tags-panel,
.correspondents-panel {
padding: 1.25rem;
display: flex;
flex-direction: column;
min-height: 0;
}
.folder-row.is-drop-target {
outline: 2px dashed var(--accent);
outline-offset: 2px;
}
.documents-panel .panel-section__header {
display: flex;
align-items: center;
justify-content: space-between;
position: relative;
}
.documents-panel .panel-section__header .header-actions {
display: flex;
gap: 0.5rem;
}
.documents-panel__title {
display: flex;
align-items: center;
gap: 0.35rem;
margin: 0;
font-size: 0.9rem;
font-weight: 600;
min-width: 0;
white-space: nowrap;
overflow: hidden;
}
.documents-panel__breadcrumbs {
flex: 1 1 auto;
overflow: hidden;
}
.documents-panel .panel-section__body {
display: flex;
flex-direction: column;
gap: 0.5rem;
}
.panel-floating {
position: absolute;
top: calc(50% + 0.25rem);
left: 50%;
transform: translate(-50%, -50%);
background: color-mix(in oklch, var(--surface) 100%, transparent);
border: 1px solid color-mix(in oklch, var(--border) 95%, transparent);
padding: 0.45rem 0.85rem;
border-radius: 1rem;
font-size: 0.95rem;
font-weight: 400;
color: var(--fg);
box-shadow: 0 2px 6px color-mix(in oklch, var(--shadow-soft) 60%, transparent);
pointer-events: auto;
display: flex;
align-items: center;
justify-content: center;
flex-wrap: nowrap;
gap: 0.75rem;
z-index: 2000000;
}
.panel-floating__label {
white-space: nowrap;
pointer-events: none;
font-size: 0.95rem;
color: var(--fg);
}
.selection-summary {
display: inline-flex;
align-items: center;
gap: 0.4rem;
}
.selection-summary__token {
display: inline-flex;
align-items: center;
gap: 0.3rem;
}
.selection-summary__count {
font-weight: 600;
font-variant-numeric: tabular-nums;
}
.selection-summary__icon {
width: 1rem;
height: 1rem;
}
.selection-summary--text {
font-weight: 600;
}
.selection-summary__separator {
opacity: 0.45;
}
.panel-floating-actions {
display: inline-flex;
align-items: center;
gap: 0.4rem;
flex-wrap: nowrap;
pointer-events: auto;
}
.panel-floating-actions .quick-add {
pointer-events: auto;
}
.panel-floating-actions .quick-add__trigger {
pointer-events: auto;
}
.panel-floating-actions .quick-add__trigger[disabled] {
opacity: 0.45;
cursor: not-allowed;
}
.panel-floating-actions__button {
display: inline-flex;
align-items: center;
gap: 0;
pointer-events: auto;
font-size: 1.35rem;
}
.panel-floating-actions__button .icon-inline {
display: inline-flex;
width: 1.35rem;
height: 1.35rem;
}
.documents-panel .documents-scroll {
overflow-y: auto;
background: transparent;
min-height: 0;
padding-right: 0.3rem;
flex-grow: 1;
}
.documents-panel .documents-scroll:focus-visible {
outline: 2px solid var(--selection-ring);
outline-offset: 2px;
border-radius: 0.25rem;
}
.documents-panel table {
max-width: 100%;
border-collapse: collapse;
font-size: 0.88rem;
margin-top: 0.4rem;
}
.documents-panel thead th {
background-color: var(--surface);
position: sticky;
top: 0;
z-index: 1;
padding: 0.45rem 0.6rem;
color: var(--muted);
}
.documents-panel th,
.documents-panel td {
padding: 0.45rem 0.6rem;
text-align: left;
}
.documents-panel--view-grid .documents-scroll {
padding: 0.35rem 0.5rem 1rem;
}
.documents-panel th.thumb-column,
.documents-panel td.thumb-cell {
width: 54px;
text-align: center;
}
.documents-panel--view-grid .document-thumbnail-wrapper {
width: var(--documents-grid-icon-size);
height: var(--documents-grid-icon-size);
padding: 8px;
border-radius: 10px;
display: flex;
justify-content: center;
align-items: center;
}
.documents-panel--view-grid .folder-card__icon {
width: var(--documents-grid-icon-size);
height: var(--documents-grid-icon-size);
padding: 8px;
border-radius: 10px;
display: flex;
justify-content: center;
align-items: center;
}
.document-thumbnail-inner {
position: relative;
display: inline-flex;
align-items: center;
justify-content: center;
}
.document-thumbnail-inner--multipage::after {
content: '';
position: absolute;
top: 0;
right: 0;
width: 24px;
height: 24px;
background-image: url('../../assets/papercorner.svg');
background-repeat: no-repeat;
background-size: contain;
pointer-events: none;
}
.documents-panel--view-grid .document-thumbnail-inner--multipage::after {
width: 28px;
height: 28px;
}
.document-thumbnail {
max-width: 100%;
max-height: 100%;
box-shadow: 0 1px 6px var(--shadow-medium);
}
.documents-panel--view-grid .document-thumbnail {
box-shadow: 0 1px 12px var(--shadow-medium);
}
.thumb-placeholder {
width: 100%;
height: 100%;
border-radius: 1px;
background: var(--surface-subtle);
color: var(--muted);
display: inline-flex;
align-items: center;
justify-content: center;
font-size: 0.68rem;
font-weight: 600;
letter-spacing: 0.08em;
box-shadow: 0 1px 3px var(--shadow-medium);
}
.documents-panel--view-grid .thumb-placeholder {
font-size: 1.1rem;
letter-spacing: 0.12em;
display: inline-flex;
width: 100%;
height: 100%;
}
.thumb-icon {
width: 100%;
height: 100%;
display: inline-flex;
align-items: center;
justify-content: center;
}
.thumb-icon__image {
width: 32px;
height: 32px;
display: block;
}
.documents-panel th.actions-column,
.documents-panel td.actions {
width: 1%;
white-space: nowrap;
}
.documents-panel td.doc-list__name {
width: 100%;
}
.doc-title-edit {
display: inline-flex;
align-items: center;
gap: 0.35rem;
flex-wrap: nowrap;
}
.doc-title-edit input[type='text'] {
padding: 0.3rem 0.55rem;
border-radius: 4px;
border: 1px solid var(--border);
background: var(--surface);
color: var(--fg);
min-width: 8rem;
}
.doc-title-edit input[type='text']:focus-visible {
outline: 2px solid var(--selection-ring);
outline-offset: 1px;
}
.doc-title-edit .icon-button {
flex-shrink: 0;
}
.documents-panel .doc-name__primary {
display: inline-flex;
align-items: center;
gap: 0.35rem;
flex-wrap: wrap;
}
.documents-panel .doc-name__primary-text {
overflow-wrap: anywhere;
}
.doc-entry {
display: flex;
align-items: center;
gap: 0.6rem;
}
.doc-entry--with-thumb .doc-entry__thumb {
flex: 0 0 auto;
display: flex;
align-items: center;
justify-content: center;
}
.doc-entry__thumb .document-thumbnail-wrapper {
display: flex;
align-items: center;
justify-content: center;
}
.doc-entry__main {
display: flex;
flex-direction: column;
gap: 0.35rem;
min-width: 0;
}
.doc-entry__name {
font-weight: 600;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
max-width: 100%;
}
.doc-entry__tags {
display: flex;
flex-wrap: wrap;
gap: 0.3rem;
}
.documents-panel td.actions .action-buttons {
display: inline-flex;
align-items: center;
gap: 0.3rem;
}
.documents-panel tbody tr {
background: transparent;
transition: background 0.15s ease;
}
.documents-panel tbody tr.folder {
cursor: pointer;
}
.documents-panel tbody tr.folder.focused {
box-shadow: inset 2px 0 0 var(--accent-outline);
background: var(--sidebar-hover-bg);
}
.documents-panel tbody tr.document {
cursor: pointer;
}
.documents-panel tbody tr.document.selected,
.documents-panel tbody tr.folder.selected {
background: var(--selection-soft);
box-shadow: inset 2px 0 0 var(--accent-outline-strong);
}
.documents-panel tbody tr.document,
.documents-panel tbody tr.document * {
user-select: none;
-webkit-user-select: none;
-moz-user-select: none;
}
.documents-panel tbody tr.document.focused:not(.selected) {
box-shadow: inset 2px 0 0 var(--accent-outline);
}
.doc-name {
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.documents-grid {
display: grid;
grid-template-columns: repeat(auto-fill, minmax(var(--documents-grid-icon-size), 1fr));
gap: 0.3rem 1.3rem;
padding: 0;
}
.document-card {
padding: 0rem;
display: flex;
flex-direction: column;
gap: 0.3rem;
cursor: pointer;
align-items: center;
text-align: center;
}
.document-card.selected .document-thumbnail-wrapper,
.folder-card.selected .folder-card__icon {
background-color: var(--selection-soft);
}
.document-card:focus-visible .document-thumbnail-wrapper {
background-color: var(--selection-ring);
}
.document-card.is-dragging {
opacity: 0.55;
}
.document-card__meta {
display: flex;
flex-direction: column;
align-items: center;
gap: 0.35rem;
width: 100%;
}
.document-card__title {
display: flex;
flex-direction: column;
align-items: center;
gap: 0.35rem;
color: var(--fg);
}
.document-card__title-row {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 0.35rem;
flex-wrap: wrap;
}
.document-card__title-badge {
padding: 0.2rem 0.7rem;
border-radius: 1rem;
max-width: 100%;
word-break: break-word;
font-size: var(--documents-grid-title-size);
color: inherit;
}
.document-card .doc-correspondent-link {
font-size: var(--documents-grid-title-size);
}
.document-card.selected .document-card__title-badge {
background-color: var(--accent);
color: var(--on-accent);
}
.document-card__subtitle {
font-size: 0.78rem;
color: var(--muted);
}
.document-card__tags {
display: flex;
flex-wrap: wrap;
gap: 0.25rem;
justify-content: center;
}
.folder-card {
align-items: center;
text-align: center;
}
.folder-card__icon {
display: flex;
align-items: center;
justify-content: center;
width: var(--documents-grid-icon-size);
height: var(--documents-grid-icon-size);
}
.folder-card__icon-svg {
width: 100%;
height: 100%;
object-fit: contain;
}
.folder-card__meta {
display: flex;
flex-direction: column;
gap: 0.28rem;
padding-top: 0.35rem;
}
.folder-card__label-row {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 0.35rem;
flex-wrap: wrap;
}
.folder-card__name {
color: var(--fg);
overflow: hidden;
text-overflow: ellipsis;
white-space: break-word;
font-size: var(--documents-grid-title-size);
padding: 0.2rem 0.7rem;
border-radius: 1rem;
}
.folder-card__edit {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 0.35rem;
}
.folder-card.selected .folder-card__name {
background-color: var(--accent);
color: var(--on-accent);
}
.doc-name__title {
max-width: 100%;
word-break: break-word;
}
.doc-name__tags {
display: flex;
flex-wrap: wrap;
gap: 0.25rem;
}
.doc-correspondents {
display: inline;
color: inherit;
}
.doc-correspondent-link {
background: none;
background-color: transparent;
border: none;
padding: 0;
margin: 0;
color: var(--accent);
text-decoration: none;
font: inherit;
cursor: pointer;
box-shadow: none;
appearance: none;
}
.doc-correspondent-link:not(.is-static):hover,
.doc-correspondent-link:not(.is-static):focus-visible {
color: var(--accent-strong, var(--accent));
text-decoration: underline;
text-decoration-thickness: 1.5px;
background-color: transparent;
}
.doc-correspondent-link:not(.is-static):focus-visible {
outline: 2px solid currentColor;
outline-offset: 2px;
}
.documents-panel tbody tr.document.selected .doc-correspondents,
.documents-panel tbody tr.document.selected .doc-correspondent-link,
.document-card.selected .doc-correspondent-link {
color: inherit;
}
.document-card.selected .doc-correspondents {
color: inherit;
}
.doc-correspondent-link.is-active {
font-weight: 600;
}
.doc-correspondent-link.is-static {
color: inherit;
cursor: default;
text-decoration: none;
}
.doc-correspondent-link__separator {
color: inherit;
}
.documents-panel tbody tr.document.dragging {
opacity: 0.4;
}
.documents-panel tbody tr.document.tag-drop-target {
background: var(--accent-soft);
box-shadow: inset 0 0 0 2px var(--accent);
}
.document-card.tag-drop-target {
box-shadow: 0 0 0 2px var(--accent);
border-color: var(--accent);
}
.document-card.tag-drop-target .document-card__title {
color: var(--accent);
}
.filter-bar {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 0.32rem;
margin-bottom: 0.5rem;
}
.filter-bar input[type='search'] {
flex: 1;
min-width: 180px;
}
.filter-actions {
display: flex;
gap: 0.32rem;
}
.search-hint {
margin-top: 0.75rem;
font-size: 0.85rem;
color: var(--muted);
}
.badge {
display: inline-flex;
align-items: center;
padding: 0.15rem 0.35rem;
border-radius: 2px;
background: var(--surface-subtle);
color: var(--fg);
font-size: 0.74rem;
}
.tag-chip {
gap: 0.25rem;
border-radius: 1rem;
padding: 0.2rem 0.4rem;
font-weight: 600;
}
.tag-chip--more {
background: transparent;
border-color: var(--border-strong);
color: var(--muted);
}
.tag-chip--removable {
gap: 0.35rem;
}
.tag-chip__remove {
background: none;
border: none;
color: inherit;
padding: 0;
display: inline-flex;
align-items: center;
justify-content: center;
line-height: 1;
cursor: pointer;
opacity: 0.8;
}
.tag-chip__remove:hover,
.tag-chip__remove:focus-visible {
opacity: 1;
}
.tag-chip__remove:focus-visible {
outline: 2px solid currentColor;
outline-offset: 2px;
border-radius: 50%;
}
.empty-state {
border: 1px dashed var(--border);
border-radius: 0;
text-align: center;
padding: 1.1rem 0.9rem;
color: var(--muted);
margin-top: 0.75rem;
background: var(--surface-subtle);
}
.empty-state--global {
border-style: solid;
}
@@ -0,0 +1,133 @@
.document-viewer__message {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
color: var(--on-accent);
background: var(--overlay-dark);
padding: 0.5rem 1rem;
border-radius: 999px;
font-size: 0.9rem;
}
.panel-section__header {
display: flex;
align-items: center;
justify-content: space-between;
gap: 0.5rem;
padding: 0 0 0.5rem;
}
.panel-section__titles {
display: flex;
flex-direction: column;
gap: 0.3rem;
}
.panel-section__header h2 {
margin: 0;
font-size: 0.9rem;
font-weight: 600;
}
.documents-panel__title {
display: flex;
align-items: center;
gap: 0.35rem;
margin: 0;
font-size: 0.9rem;
font-weight: 600;
min-width: 0;
flex-wrap: nowrap;
overflow: hidden;
}
.panel-section__subtitle {
margin-top: 0.25rem;
font-size: 0.78rem;
color: var(--muted);
}
.breadcrumb-trail {
display: flex;
align-items: center;
gap: 0.35rem;
flex-wrap: nowrap;
min-width: 0;
flex: 1 1 auto;
max-width: 100%;
overflow: hidden;
}
.breadcrumb-trail--measure {
position: absolute;
visibility: hidden;
pointer-events: none;
left: -9999px;
top: -9999px;
max-width: none;
overflow: visible;
}
.breadcrumb-trail__link {
display: inline-flex;
align-items: center;
max-width: 100%;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
border: none;
background: none;
padding: 0;
font: inherit;
color: inherit;
cursor: default;
}
.breadcrumb-trail__link:not(.is-current) {
cursor: pointer;
color: var(--accent);
}
.breadcrumb-trail__link:not(.is-current):hover,
.breadcrumb-trail__link:not(.is-current):focus-visible {
text-decoration: underline;
}
.breadcrumb-trail__separator {
color: var(--muted);
margin: 0 0.2rem;
}
.breadcrumb-trail__ellipsis {
position: relative;
display: inline-flex;
}
.breadcrumb-trail__ellipsis-button {
cursor: pointer;
}
.documents-panel__breadcrumbs {
flex: 1 1 auto;
min-width: 0;
max-width: 100%;
overflow: hidden;
}
.documents-panel__breadcrumbs {
max-width: 22rem;
}
.panel-section__body {
flex: 1;
display: flex;
flex-direction: column;
min-height: 0;
}
.panel-section__body--scrollable,
.panel-section__body.scrollable {
overflow-y: auto;
}
@@ -0,0 +1,26 @@
.doc-list__name {
width: 100%;
}
.doc-list__name-content {
display: inline-flex;
align-items: center;
gap: 0.22rem;
max-width: 100%;
}
.doc-list__name-content span {
max-width: 100%;
overflow-wrap: anywhere;
word-break: break-word;
}
.preview-pane__nav-button svg {
width: 100%;
height: 100%;
}
.panel-header .icon-button svg {
width: 1.41rem;
height: 1.41rem;
}
@@ -0,0 +1,173 @@
.tags-panel__body {
overflow-y: auto;
}
.tags-table {
width: 100%;
overflow: auto;
}
.tags-table table {
width: 100%;
border-collapse: collapse;
min-width: 320px;
}
.tags-table th,
.tags-table td {
padding: 0.45rem 0.6rem;
text-align: left;
font-size: 0.85rem;
}
.tags-table th.numeric,
.tags-table td.numeric {
text-align: right;
}
.tags-table th.actions,
.tags-table td.actions {
text-align: right;
width: 0;
}
.tags-table tbody tr:hover {
background: var(--surface-subtle);
}
.tags-table tr.editing {
background: var(--sidebar-hover-bg);
}
.tags-table__label {
max-width: 24rem;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.tags-table__swatch {
display: inline-block;
width: 1rem;
height: 1rem;
border-radius: 2px;
box-shadow: inset 0 0 0 1px var(--shadow-faint);
}
.tags-panel__error {
margin: 0.5rem 0;
color: var(--danger);
font-size: 0.8rem;
}
.tags-table__label-input {
width: 100%;
}
.tags-table__color-editor {
display: flex;
align-items: center;
gap: 0.4rem;
}
.tags-table__color-picker {
width: 2.25rem;
height: 2.25rem;
padding: 0;
background: none;
cursor: pointer;
}
.tags-table__edit-controls {
display: flex;
justify-content: flex-start;
padding: 0.25rem;
gap: 0.4rem;
}
.tags-table__row-actions {
display: flex;
justify-content: flex-start;
padding: 0.25rem;
gap: 0.4rem;
}
.correspondents-panel .header-actions {
gap: 0.5rem;
}
.tags-actions {
display: flex;
flex-wrap: wrap;
gap: 0.6rem;
align-items: center;
}
.tags-actions__form {
display: flex;
flex-wrap: wrap;
align-items: center;
gap: 0.4rem;
}
.tags-actions__form input[type='text'] {
min-width: 14rem;
}
.correspondents-actions__form {
display: flex;
gap: 0.4rem;
}
.correspondents-actions__form input {
min-width: 14rem;
}
.correspondent-pill {
display: inline-flex;
align-items: center;
gap: 0.35rem;
background: var(--surface-subtle);
border-radius: 999px;
padding: 0.15rem 0.5rem;
font-size: 0.9rem;
border: none;
}
.correspondent-pill__label {
line-height: 1.2;
}
.correspondent-pill__label strong {
font-size: 0.8rem;
text-transform: capitalize;
color: var(--muted);
}
.correspondent-pill__remove {
border: none;
background: none;
cursor: pointer;
display: inline-flex;
align-items: center;
justify-content: center;
color: var(--muted);
padding: 0;
}
.correspondent-pill__remove:hover {
color: var(--danger);
}
.correspondent-form {
display: flex;
gap: 0.4rem;
align-items: center;
}
.correspondent-form input,
.correspondent-form select {
min-height: 32px;
}
+335
View File
@@ -0,0 +1,335 @@
.document-viewer {
flex: 1;
display: grid;
grid-template-columns: minmax(0, 30em) minmax(0, 1fr);
gap: 1rem;
min-height: 0;
padding: 1rem 1rem;
}
.document-drag-preview {
position: fixed;
pointer-events: none;
top: -9999px;
left: -9999px;
width: var(--drag-preview-size, 96px);
height: var(--drag-preview-size, 96px);
z-index: 9999;
}
.document-drag-preview__thumb {
position: absolute;
top: 50%;
left: 50%;
width: 64px;
height: 64px;
border-radius: 6px;
box-shadow: 0 6px 12px var(--shadow-pop);
overflow: hidden;
background-color: var(--overlay-dim);
display: flex;
align-items: center;
justify-content: center;
color: #fff;
font-weight: 600;
font-size: 0.8rem;
text-transform: uppercase;
transform: translate(-50%, -50%) rotate(var(--rotation-deg, 0deg));
transform-origin: center;
}
.document-drag-preview__thumb--image {
background-color: #000;
background-repeat: no-repeat;
background-size: contain;
background-position: center;
}
.document-drag-preview__thumb .document-thumbnail,
.document-drag-preview__thumb img {
width: 100%;
height: 100%;
object-fit: cover;
pointer-events: none;
}
.document-drag-preview__thumb .thumb-placeholder,
.document-drag-preview__thumb .thumb-placeholder * {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
pointer-events: none;
}
.document-drag-preview__folder-thumb {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
pointer-events: none;
}
.document-drag-preview__folder-thumb svg {
width: 48px;
height: 48px;
color: var(--accent-strong, var(--accent));
}
.document-drag-preview__folder-placeholder {
width: 100%;
height: 100%;
display: flex;
align-items: center;
justify-content: center;
font-size: 0.75rem;
font-weight: 600;
text-transform: uppercase;
letter-spacing: 0.04em;
color: var(--text-on-dark);
}
.document-drag-preview__count {
position: absolute;
bottom: 4px;
right: 4px;
background-color: var(--accent);
color: var(--on-accent);
border-radius: 999px;
padding: 0.25rem 0.5rem;
font-size: 0.75rem;
font-weight: 600;
box-shadow: 0 4px 8px var(--shadow-pop);
pointer-events: none;
}
.document-viewer__details {
display: flex;
flex-direction: column;
gap: 0.5rem;
min-height: 0;
flex: 1;
}
.document-viewer__details-pane {
display: flex;
flex-direction: column;
min-height: 0;
overflow: auto;
flex: 1;
}
.document-viewer__tabs-wrapper {
display: flex;
flex-direction: column;
flex: 1;
min-height: 0;
}
.document-viewer__section {
display: flex;
flex-direction: column;
flex: 1;
min-height: 0;
padding-top: 1rem;
}
.document-viewer__section-title {
margin: 0;
font-size: 0.95rem;
font-weight: 600;
letter-spacing: 0.01em;
}
.document-viewer__section-list {
margin: 0;
padding: 0;
list-style: none;
display: grid;
grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
gap: 0.75rem 1.25rem;
}
.document-viewer__section-item {
display: flex;
flex-direction: column;
gap: 0.25rem;
}
.document-viewer__section-item dt {
font-size: 0.75rem;
color: var(--muted);
}
.document-viewer__section-item dd {
margin: 0;
font-size: 0.9rem;
font-weight: 500;
word-break: break-word;
}
.document-viewer__section-placeholder {
margin: 0;
font-size: 0.9rem;
color: var(--muted);
}
.document-viewer__section-payload {
font-size: 0.85rem;
}
.document-viewer__section-payload summary {
cursor: pointer;
font-weight: 500;
color: var(--accent-strong, var(--accent));
}
.document-viewer__section-payload pre {
margin: 0.75rem 0 0;
padding: 0.75rem;
background: var(--surface);
max-height: 280px;
overflow: auto;
font-size: 0.8rem;
}
.document-viewer__section--metadata-json {
overflow: auto;
}
.document-viewer__metadata-json {
margin: 0;
padding: 0.75rem;
background: var(--surface);
border-radius: 0.5rem;
font-size: 0.85rem;
line-height: 1.35;
overflow: auto;
}
.document-viewer__tabs {
display: inline-flex;
align-items: center;
gap: 0.5rem;
border-bottom: 1px solid var(--outline-subtle);
}
.document-viewer__tab {
appearance: none;
border: none;
background: transparent;
padding: 0.4rem 0.75rem;
font-size: 0.85rem;
font-weight: 500;
color: var(--muted);
cursor: pointer;
border-bottom: 2px solid transparent;
transition:
color 120ms ease,
border-color 120ms ease;
}
.document-viewer__tab:hover,
.document-viewer__tab:focus-visible {
color: var(--accent);
}
.document-viewer__tab.is-active {
color: var(--accent);
border-color: var(--accent);
}
.document-viewer__tabpanes {
flex: 1;
min-height: 0;
display: flex;
}
.document-viewer__tabpanes--single {
flex: 1;
min-height: 0;
}
.document-viewer__tabpanel {
flex: 1;
min-height: 0;
display: flex;
position: relative;
}
.document-viewer__object--ocr {
width: 100%;
height: 100%;
}
.document-viewer__object--ocr-text {
width: 100%;
height: 100%;
margin: 0;
padding: 1rem 0;
font-size: 1rem;
white-space: pre-wrap;
font-family: inherit;
}
.document-viewer__message--error {
color: var(--danger);
}
.document-viewer__viewport {
flex: 1;
min-width: 0;
display: flex;
position: relative;
overflow: hidden;
align-items: flex-start;
}
.document-viewer__object {
width: 100%;
height: 100%;
border: none;
}
.document-viewer__object--image {
width: auto;
height: auto;
max-width: 100%;
max-height: 100%;
object-fit: contain;
align-self: flex-start;
}
.document-viewer__unsupported {
height: 100%;
width: 100%;
padding: 2rem;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 0.75rem;
text-align: center;
background: var(--surface-subtle);
}
.document-viewer__unsupported-filename {
font-size: 0.9rem;
color: var(--muted);
}
.document-viewer__unsupported-message {
font-size: 0.95rem;
color: var(--fg);
}
.document-viewer__unsupported-download {
font-weight: 600;
}
.document-viewer__unsupported-download svg {
width: 1rem;
height: 1rem;
}