mirror of
https://github.com/Stirling-Tools/Stirling-PDF.git
synced 2026-09-03 05:10:16 +03:00
## Overview First part of the move over to the new designs. This lays the groundwork (shared brand components, button/nav styling, theme tokens) and applies it across the editor and the processor. Later parts will build on top of it. ## What's changed **Branding** - Shared `Logo` and `BrandMark` components used everywhere, so the mark and wordmark are identical across the editor, processor, auth pages and the chat FAB. - The sidebar logo doubles as the editor to processor switcher, morphing into a chevron on hover. It only appears for users who can actually reach the processor. **Navigation and layout** - Both sidebars restructured onto the floating nav surface treatment, with rounded panels sitting on the app canvas. - The editor file sidebar is now three sections (controls, PDF Library, settings) and the workbench top bar and tools panel match. - Added a collapse toggle to both sidebars, with an animated expand and collapse and a tidy icon rail when collapsed. The processor did not have a desktop collapse before. **Components** - Buttons and action icons now share one styling system, so both react to the same tokens. - Secondary buttons in dark mode use a neutral fill and border instead of inheriting the primary colour. - Status badges default to a clean dot with no background, with a filled pill as the alternative. - Metric strips gained a row layout with an optional leading icon. **Theme** - Colour tokens consolidated. Literal colours live only in the palette file, everything else references the semantic `--c-*` tokens. - `saas-theme.css` removed and the parts that were genuinely needed moved into the shared theme, so all builds get them. - The colour linter enforces this across the app and runs in CI. ## Notes - Nothing functional should change here, it is styling plus the sidebar collapse feature. - Main has been merged in. The Sources and billing pages picked up changes from main during that merge and are worth a look alongside the new styling. --------- Co-authored-by: Reece Browne <74901996+reecebrowne@users.noreply.github.com>
68 lines
2.0 KiB
CSS
68 lines
2.0 KiB
CSS
/* Fixed-height shell so the MAIN COLUMN scrolls, not the document. With
|
|
min-height:100vh the shell grows with content and the document scrolls, which
|
|
means .portal-shell__view's overflow-y never engages and any `position:sticky`
|
|
inside it (e.g. a page header) rides away with the document. Pinning the shell
|
|
to the viewport (+ min-height:0 on the flex descendants so they can shrink
|
|
below content) makes .portal-shell__view the scroll container, so sticky
|
|
page headers stick under the global header. */
|
|
.portal-shell {
|
|
display: flex;
|
|
height: 100vh;
|
|
height: 100dvh; /* mobile browser chrome shrinks the viewport; dvh tracks it */
|
|
overflow: hidden;
|
|
background: var(--c-bg);
|
|
color: var(--c-text-muted);
|
|
}
|
|
|
|
.portal-shell__main {
|
|
flex: 1 1 auto;
|
|
display: flex;
|
|
flex-direction: column;
|
|
min-width: 0; /* prevent grid blowout on narrow content */
|
|
min-height: 0; /* allow the column to bound its children */
|
|
}
|
|
|
|
.portal-shell__view {
|
|
flex: 1 1 auto;
|
|
min-height: 0; /* scroll instead of growing past the viewport */
|
|
overflow-y: auto;
|
|
animation: fadeInUp var(--motion-enter) both;
|
|
}
|
|
|
|
/* Mobile topbar — hidden on desktop, where the sidebar is always visible.
|
|
Height matches the sidebar's logo row so the brand sits at the same level. */
|
|
.portal-shell__topbar {
|
|
display: none;
|
|
height: 3.1875rem;
|
|
flex-shrink: 0;
|
|
align-items: center;
|
|
gap: 0.375rem;
|
|
padding: 0 0.625rem;
|
|
background: var(--color-sidebar-bg);
|
|
border-bottom: 1px solid var(--color-sidebar-border);
|
|
}
|
|
|
|
.portal-shell__topbar-wordmark {
|
|
margin-right: auto;
|
|
}
|
|
|
|
/* Scrim behind the mobile nav drawer (below SUI modals at z-index 100). */
|
|
.portal-shell__scrim {
|
|
display: none;
|
|
position: fixed;
|
|
inset: 0;
|
|
z-index: 75;
|
|
background: var(--c-overlay);
|
|
}
|
|
|
|
@media (max-width: 48rem) {
|
|
.portal-shell__topbar {
|
|
display: flex;
|
|
}
|
|
.portal-shell__scrim {
|
|
display: block;
|
|
/* fadeIn keyframes come from core tokens.css */
|
|
animation: fadeIn var(--motion-fast) both;
|
|
}
|
|
}
|