MultitabController<T> is a Flutter-free ChangeNotifier owning the tab list, active selection, and reorder/close invariants: - pinned (non-reorderable) entries form barriers that other tabs cannot cross - non-closeable entries silently no-op on remove() so hosts don't need to gate the call site - closing the active tab falls right, then left, then to null - duplicate ids are rejected MultitabPane<T> is the widget shell: a horizontal tab strip followed by the active entry's body. Active tab gets the panelHeader background and a panelActiveBorder top accent; inactive tabs blend into the tab bar. Close × is hidden until hover. Add button only renders when onAddRequested is wired. Hosts route the user's add/close intent through callbacks so the widget stays domain-free — for the Claude pane, add will spawn a new tmux session and close will kill one. Drag-to-reorder is controller-side only for now (the gesture wiring lands with T-24). 19 controller tests + 9 widget tests. Co-Authored-By: Claude <noreply@anthropic.com>
44 lines
1.4 KiB
Dart
44 lines
1.4 KiB
Dart
/// clide widget primitives.
|
|
///
|
|
/// Hand-rolled, theme-token-consuming building blocks. No Material or
|
|
/// Cupertino. Feature code composes these; it never reaches down into
|
|
/// Flutter chrome widgets directly.
|
|
library;
|
|
|
|
export 'src/clide_accordion.dart';
|
|
export 'src/clide_button.dart';
|
|
export 'src/clide_column_hat.dart';
|
|
export 'src/clide_code_block.dart';
|
|
export 'src/clide_divider.dart';
|
|
export 'src/clide_filter_box.dart';
|
|
export 'src/clide_markdown.dart';
|
|
export 'src/clide_svg_view.dart';
|
|
export 'src/clide_icon.dart';
|
|
export 'src/clide_icon_rail.dart';
|
|
export 'src/clide_palette.dart';
|
|
export 'src/clide_pane_chrome.dart';
|
|
export 'src/clide_resize_border.dart';
|
|
export 'src/clide_pty_view.dart';
|
|
export 'src/clide_scrollbar.dart';
|
|
export 'src/clide_spine.dart';
|
|
export 'src/clide_surface.dart';
|
|
export 'src/clide_tab_bar.dart';
|
|
export 'src/multitab_controller.dart';
|
|
export 'src/multitab_pane.dart';
|
|
export 'src/clide_tappable.dart';
|
|
export 'src/clide_text.dart';
|
|
export 'src/clide_tooltip.dart';
|
|
export 'src/typography.dart';
|
|
export 'src/icons/check.dart';
|
|
export 'src/icons/chevron.dart';
|
|
export 'src/icons/dot.dart';
|
|
export 'src/icons/folder.dart';
|
|
export 'src/icons/gear.dart';
|
|
export 'src/icons/plug.dart';
|
|
export 'src/icons/git_branch.dart';
|
|
export 'src/icons/search.dart';
|
|
export 'src/icons/terminal_icon.dart';
|
|
export 'src/icons/warning.dart';
|
|
export 'src/icons/x.dart';
|
|
export 'src/icons/phosphor.dart';
|