Generative: the video strip scrolls and reveals; tags wrap in their row

The timeline's scroll box is the flex row itself, so its reach is its
shots; a focused shot brings itself whole into view through
layout::bring_into_view, which table headers now share; Extend sits
with the caption under the strip. A voice's tags cap at the row's
width and wrap inside it.
This commit is contained in:
ZacharyZhang-NY committed 2026-09-26 13:32:44 -04:00
1 parent a4f101f7b3
commit 396531c075
7 files changed
+189 -38

No files matched your search

+3 -12
View File
@@ -1,12 +1,12 @@
use gpui::{
App, Bounds, Div, DragMoveEvent, ElementId, Entity, EntityId, FocusHandle, FontWeight,
InteractiveElement, IntoElement, MouseButton, ParentElement, Pixels, Rems, SharedString,
Stateful, StatefulInteractiveElement, Styled, Window, canvas, div, point, prelude::*,
Stateful, StatefulInteractiveElement, Styled, Window, canvas, div, prelude::*,
transparent_black,
};
use super::{Column, table::View};
use crate::layout::seeded::Seeded;
use crate::layout::{bring_into_view, seeded::Seeded};
use crate::{
primitives::{DragGhost, FocusRing, Icon, IconName},
theme::{ActiveTheme, IconSize, TextSize},
@@ -96,17 +96,8 @@ fn reveal(
return;
}
let scroll = view.read(cx).sideways.clone();
let (frame, offset) = (scroll.bounds(), scroll.offset());
let shift = if head.left() < frame.left() {
frame.left() - head.left()
} else if head.right() > frame.right() {
(frame.right() - head.right()).max(frame.left() - head.left())
} else {
Pixels::ZERO
};
view.update(cx, |view, _| view.revealed = Some(key.clone()));
if shift != Pixels::ZERO {
scroll.set_offset(point(offset.x + shift, offset.y));
if bring_into_view(&scroll, head) {
log::info!("data table: header {key} scrolled into view");
window.request_animation_frame();
}