mirror of
https://github.com/storytold/craft-libs.git
synced 2026-11-17 05:14:24 +00:00
Along a height its parent sizes from its content, a container that fills takes its content height, at most the room it is offered. When the content is taller, the measuring run is taken back and the container is laid out as given the room, so its list and the bar under it share it; a record of the content height lets later runs and kept transcripts lay it out the same. room_height only offers a finite room inside a scroll: a gallery card is as tall as its story's content, at most the view, as the old gallery's tiles were. layout_memory::draft runs a measuring run whose hand-forwards can be taken back once its result is seen: records, kept transcripts, the open transcript's items, leaves and inputs, and each contribution (Contribution::undo for column widths, label control minimums and reads). steps::id::draft takes the Auto id ordinals back with it. The shrinking row's least probe is a draft taken back that reads nothing from outside. A scrolling collection that fills keeps to its measured height in the real run under a body sized from its content, so a footer under it stays below its rows. The PlacesTree story keeps the old 380 pt box.
craft-browse
Browsing for Craft apps: folders and volumes, linked files, file thumbnails, and the widgets that show them. The app supplies its items through small read-only traits and gets events back; every listing, status check, search and decode runs as a job on craft_host::queue::JobQueue.
| Module | What it gives the app |
|---|---|
places |
The roots of a folder tree (standard folders, volumes, favourites, recents, the folder being browsed), the hidden and kept lists as one settings section (PlacesSettings), and FolderCache, lazy folder listings refreshed when FileWatch reports a change. Folder access goes through Directories (SystemDirectories on desktop, FakeDirectories in stories). |
links |
LinkMonitor: link statuses kept current as files change, each change reported once. The link rules themselves are craft_docpath::links. |
thumbs |
File thumbnails: the app implements ThumbDecoder (and optionally ThumbStore); with ui, FileThumbSource is a ThumbSource over files for craft_ui::canvas::textures::Thumbnails. |
ui::grid |
craft-ui's list::TileGrid and ThumbnailSlider, re-exported with the grid's stories: a virtualised thumbnail grid with groups, badges, rating, selection, check mode, reorder, rename (start_rename), marquee, hover scrub, keys and drag, over the app's TileSource; paint_tile draws one tile for widgets that lay out their own. |
ui::bin |
MediaBin: the project or media panel with List, Icon and Freeform views, search, sort, rename (start_rename), bin drops and a footer (BinEvent::Footer and FooterDrop), over the app's BinModel; the List view is a craft_ui::list::Table. |
ui::places |
PlacesTree: the folder tree with lazy children, reveal of the browsed folder and the keep, hide and reveal menu, and the app's own rows through row_menu (PlacesEvent::Menu). |
ui::compare |
CompareTile: one fitted image with zoom and pan shared across tiles and a caption strip; the two-pane and survey arrangements. |
ui::relink |
LinkList::new(id_salt, links, statuses, &mut LinkListState) (the Links panel; its sort, filter and columns are LinkListSettings) and RelinkDialog (find missing files, match options, folder search, candidates; the table layout comes back in RelinkOutcome::layout). |
places, links and thumbs work without egui; the ui feature adds the widgets and root re-exports of each widget, its labels and its style.