AI media harness for planning, generating, and editing locally
TypeScript
/* ============================================================================
export.css — the Export screen: a docked form, not a page.
The layout every Windows editor uses for its export step (Clipchamp's export
page, Premiere's Export tab): the picture on the stage at the left, and a
resizable settings pane on the right (usePaneSize → --pane-export-settings)
that opens straight on its first section and keeps the run's status and
Cancel / Export pinned at its foot. No hero title, no cards, no stat tiles —
labels in the --prop-label column, values beside them.
Dense scale, shared with the timeline (see timeline.css), except the
transport: 32px buttons in a bar as tall as the settings pane's foot.
========================================================================== */
.export-view {
--pane-export-settings: var(--pane-side-default); /* usePaneSize sets the real width inline */
/* The settings pane's foot at rest (a 32px button, 12px above and below,
its divider): the transport bar under the picture is the same height,
so the two strips line up across the splitter. */
--export-foot-height: calc(var(--control-md) + 2 * var(--space-3) + 1px);
height: 100%;
min-height: 0;
container: export-view / inline-size;
display: grid;
grid-template-rows: minmax(0, 1fr);
background: var(--surface-pane);
}
.export-body {
min-height: 0;
display: grid;
grid-template-columns: minmax(0, 1fr) auto var(--pane-export-settings);
}
/* --- Preview -----------------------------------------------------------------
The preview IS the stage: edge to edge on --surface-stage, no inset, no
border. The frame is fitted inside the screen above the transport bar — full
width whenever the frame's shape allows, letterboxed by the stage colour —
and the bar runs the full width under it. */
.export-preview {
min-width: 0;
min-height: 0;
display: flex;
flex-direction: column;
background: var(--surface-stage);
}
/* An image project's image bar runs under the stage, on chrome, where the
video export has its transport bar. */
.export-preview > .image-results {
flex: none;
background: var(--surface-chrome);
}
.music-export-library { flex: 1; min-height: 0; overflow: auto; padding: var(--space-3); }
.export-preview > .music-player { flex: none; }
/* The stage is the screen plus its transport bar. It is also the element that
goes fullscreen, so the bar comes along. */
.export-stage {
position: relative;
flex: 1 1 auto;
min-width: 0;
min-height: 0;
display: flex;
flex-direction: column;
overflow: hidden;
/* Black in both themes: the frame paints the project's own background, and
a matching surround would hide where the picture ends. Everything painted
on it uses the --stage-* tokens. */
background: var(--surface-stage);
}
/* Everything above the transport bar. A size container, so the frame inside
can be fitted against both its width and its height. */
.export-screen {
position: relative;
flex: 1 1 auto;
min-height: 0;
display: grid;
place-items: center;
overflow: hidden;
container-type: size;
}
/* The project's frame, at the project's shape: `aspect-ratio` and
`--frame-aspect` are set inline from the export plan (see ExportView). It
never takes the shape of whatever is under the playhead — the export writes
ONE frame size for the whole file. Contained: the full width of the screen,
unless that would make it taller than the screen. */
.export-picture {
position: relative;
width: min(100cqw, 100cqh * var(--frame-aspect, 1.7778));
max-width: 100%;
max-height: 100%;
display: grid;
place-items: center;
overflow: hidden;
}
.export-picture .program-picture {
width: 100%;
height: 100%;
}
.export-stage__caption {
position: absolute;
inset: auto 0 var(--space-3);
margin: 0;
color: var(--on-stage);
font-size: var(--text-xs);
line-height: var(--leading-snug);
text-align: center;
pointer-events: none;
}
/* The image project's Export tab: the image itself, contained in the screen
with the stage colour around it. The file is the export, so there is no
frame box — just the picture at its own shape. */
.export-image {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
object-fit: contain;
}
img.export-image {
display: block;
}
.export-image.reference-image-fallback {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: var(--space-2);
color: var(--on-stage);
font-size: var(--text-xs);
}
/* Nothing to show: the shared empty state, in stage ink — the stage is dark
in both themes. */
.export-empty.ui-empty-state {
height: 100%;
}
.export-empty .ui-empty-state__icon,
.export-empty .ui-empty-state__description {
color: color-mix(in srgb, var(--on-stage) 62%, transparent);
}
.export-empty .ui-empty-state__title {
color: var(--on-stage);
}
/* --- Transport ----------------------------------------------------------------
Windowed: a static chrome bar under the picture, as tall as the settings
pane's foot (--export-foot-height) — flat 32px buttons, a Fluent slider, and "00:00:12:05 / 00:01:30:00". No
scrim, no shadows, no scale. */
.export-transport {
height: var(--export-foot-height);
flex: none;
display: flex;
align-items: center;
gap: var(--space-1);
padding: 0 var(--space-3);
border-top: 1px solid var(--stroke-divider);
color: var(--text-primary);
background: var(--surface-chrome);
}
.export-transport__button {
width: var(--control-md);
height: var(--control-md);
flex: none;
display: grid;
place-items: center;
padding: 0;
border: 0;
border-radius: var(--radius-sm);
color: var(--text-primary);
background: transparent;
transition: var(--transition-control);
}
.export-transport__button:hover:not(:disabled) { background: var(--fill-subtle-hover); }
.export-transport__button:active:not(:disabled) { background: var(--fill-subtle-pressed); }
.export-transport__button:disabled { color: var(--text-disabled); }
.export-transport__scrub {
flex: 1 1 auto;
min-width: 0;
margin: 0 var(--space-2);
}
.export-transport__time {
flex: none;
color: var(--text-secondary);
font-size: var(--text-base);
font-variant-numeric: tabular-nums;
white-space: nowrap;
}
.export-transport__time span:first-child {
color: var(--text-primary);
}
/* Fullscreen: the picture takes the screen and the same bar floats over its
foot, revealed by a moving pointer and hidden again when it rests — the one
place an auto-hiding overlay belongs. */
.export-stage:fullscreen {
background: var(--stage-bg);
}
.export-stage:fullscreen .export-transport {
position: absolute;
inset: auto 0 0;
border-top: 0;
color: var(--on-stage);
background: color-mix(in srgb, var(--stage-bg) 72%, transparent);
opacity: 0;
visibility: hidden;
transition: opacity var(--motion-normal) linear, visibility 0s linear var(--motion-normal);
}
.export-stage:fullscreen .export-transport__button,
.export-stage:fullscreen .export-transport__time,
.export-stage:fullscreen .export-transport__time span:first-child {
color: var(--on-stage);
}
.export-stage--fullscreen.export-stage--controls-visible .export-transport,
.export-stage:fullscreen:focus-within .export-transport {
opacity: 1;
visibility: visible;
transition-delay: 0s;
}
.export-stage--fullscreen:not(.export-stage--controls-visible):not(:focus-within) {
cursor: none;
}
@media (prefers-reduced-motion: reduce) {
.export-stage:fullscreen .export-transport {
transition: none;
}
}
/* --- Settings pane ---------------------------------------------------------------
Sections scroll; the foot with the actions stays put under them. */
.export-settings {
min-width: 0;
min-height: 0;
display: flex;
flex-direction: column;
background: var(--surface-pane);
}
.export-settings__scroll {
flex: 1 1 auto;
min-height: 0;
overflow-y: auto;
}
/* Inspector side padding: 12px, the same as every PropSection's rows. */
.export-settings .ui-prop-section__content {
padding-inline: var(--space-3);
}
.export-settings .ui-prop-row .ui-combo {
width: 100%;
}
.export-destination {
flex: 1;
min-width: 0;
display: flex;
align-items: center;
gap: var(--space-2);
}
.export-destination__path {
flex: 1 1 auto;
min-width: 0;
overflow: hidden;
color: var(--text-primary);
font-size: var(--text-xs);
line-height: var(--leading-snug);
text-overflow: ellipsis;
white-space: nowrap;
direction: rtl;
text-align: left;
}
/* Compact, like the 24px combo boxes in the rows under it. */
.export-destination__browse.secondary-button {
flex: none;
min-height: var(--control-sm);
height: var(--control-sm);
}
/* The summary as a label/value list, one line per fact, on the PropRow grid:
the --prop-label column, the value, and the empty reset column. */
/* The image export's JPG quality, read out beside its slider. */
.export-quality__value {
min-width: 32px;
flex: none;
color: var(--text-primary);
font-size: var(--text-xs);
font-variant-numeric: tabular-nums;
text-align: right;
}
.export-summary {
margin: 0;
display: grid;
gap: var(--space-1);
padding-block: var(--space-1);
}
.export-summary > div {
min-width: 0;
display: grid;
grid-template-columns: var(--prop-label) minmax(0, 1fr) 20px;
column-gap: var(--space-2);
}
.export-summary dt {
color: var(--text-secondary);
font-size: var(--text-xs);
line-height: var(--leading-snug);
}
.export-summary dd {
min-width: 0;
margin: 0;
color: var(--text-primary);
font-size: var(--text-xs);
line-height: var(--leading-snug);
font-variant-numeric: tabular-nums;
}
.export-summary dd small {
display: block;
color: var(--text-muted);
font-size: var(--text-xs);
line-height: var(--leading-snug);
}
.export-messages {
display: grid;
gap: var(--space-2);
padding: var(--space-3);
}
.export-messages:empty {
display: none;
}
.export-reasons {
margin: var(--space-1) 0 0;
padding-left: var(--space-4);
font-size: var(--text-xs);
line-height: var(--leading-snug);
}
.export-reasons li + li {
margin-top: var(--space-1);
}
/* --- Pane foot ---------------------------------------------------------------------
On chrome under a divider, like a pane footer: progress or the outcome,
then Cancel / Export at the trailing edge. */
.export-settings__foot {
min-height: var(--export-foot-height);
flex: none;
display: grid;
gap: var(--space-3);
padding: var(--space-3);
border-top: 1px solid var(--stroke-divider);
background: var(--surface-chrome);
}
.export-settings__status:empty {
display: none;
}
.export-outcome {
display: grid;
grid-template-columns: auto minmax(0, 1fr) auto;
grid-template-areas: "icon text close" ". actions .";
align-items: start;
row-gap: var(--space-2);
padding-block: var(--space-3);
}
.export-outcome > .ui-severity-glyph { grid-area: icon; }
.export-outcome > .ui-infobar__close { grid-area: close; }
.export-outcome > .ui-infobar__text {
grid-area: text;
flex-direction: column;
padding-block: 0;
}
.export-outcome > .ui-infobar__action {
grid-area: actions;
flex-wrap: wrap;
}
.export-settings__actions {
display: flex;
justify-content: center;
gap: var(--space-2);
}
.export-settings__actions .primary-button,
.export-settings__actions .secondary-button {
flex: 0 1 var(--inspector-action-width);
margin-inline: 0;
}
.export-progress {
display: grid;
gap: var(--space-2);
}
.export-progress__line {
color: var(--text-primary);
font-size: var(--text-xs);
line-height: var(--leading-snug);
font-variant-numeric: tabular-nums;
}
/* Stacked only when the VIEW is narrow (agent pane open in a small window) —
a 900px window without the agent still has room for both columns. The
picture gets at most 45% of the height so the settings stay reachable. */
@container export-view (max-width: 620px) {
.export-body {
grid-template-columns: minmax(0, 1fr);
grid-template-rows: minmax(0, 45%) minmax(0, 1fr);
}
/* Stacked there is no width to drag. */
.export-body > .ui-splitter {
display: none;
}
.export-settings {
border-top: 1px solid var(--stroke-divider);
}
}