@bitforgehq/ui 0.3.1 → 0.3.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/CHANGELOG.md +157 -0
  2. package/README.md +9 -8
  3. package/ai/MANIFEST.index.json +18 -0
  4. package/ai/MANIFEST.json +380 -31
  5. package/ai/REFERENCE.index.json +63 -0
  6. package/ai/REFERENCE.json +265 -7
  7. package/ai/UI_GUIDE.md +59 -33
  8. package/ai/components/app-frame.md +335 -0
  9. package/ai/components/card.md +56 -2
  10. package/ai/components/empty-state.md +99 -6
  11. package/ai/components/header.md +14 -1
  12. package/ai/components/sidebar-toggle.md +287 -0
  13. package/ai/components/sidebar.md +188 -10
  14. package/ai/components/stat.md +74 -10
  15. package/ai/components/table.md +152 -5
  16. package/ai/components/tabs.md +5 -1
  17. package/ai/components/toolbar.md +69 -4
  18. package/ai/reference/bf-app-frame-breakpoint.md +27 -0
  19. package/ai/reference/bf-app-frame-content-width.md +29 -0
  20. package/ai/reference/bf-empty-state-heading-level.md +1 -1
  21. package/ai/reference/bf-empty-state-heading.md +33 -0
  22. package/ai/reference/bf-labels.md +7 -0
  23. package/ai/reference/bf-select-harness.md +4 -0
  24. package/ai/reference/bf-sidebar-state-service.md +21 -0
  25. package/ai/reference/bf-sidebar-toggle-harness.md +32 -0
  26. package/ai/reference/bf-size.md +1 -0
  27. package/ai/reference/bf-stat-appearance.md +33 -0
  28. package/ai/reference/bf-stat-variant.md +1 -1
  29. package/ai/reference/bf-table-harness.md +7 -1
  30. package/ai/reference/bf-table-stack.md +29 -0
  31. package/ai/reference/bf_sidebar_state_storage.md +20 -0
  32. package/ai/reference/provide-bf-labels.md +4 -3
  33. package/ai/reference/provide-bf-sidebar-state.md +20 -0
  34. package/bin/bf-ui.js +433 -3
  35. package/fesm2022/bitforgehq-ui-mobile.mjs +11 -2
  36. package/fesm2022/bitforgehq-ui-mobile.mjs.map +1 -1
  37. package/fesm2022/bitforgehq-ui-overlay.mjs +571 -446
  38. package/fesm2022/bitforgehq-ui-overlay.mjs.map +1 -1
  39. package/fesm2022/bitforgehq-ui-testing.mjs +22 -2
  40. package/fesm2022/bitforgehq-ui-testing.mjs.map +1 -1
  41. package/fesm2022/bitforgehq-ui.mjs +777 -127
  42. package/fesm2022/bitforgehq-ui.mjs.map +1 -1
  43. package/llms-full.txt +1605 -43
  44. package/llms.txt +11 -0
  45. package/package.json +1 -1
  46. package/theme.css +13 -0
  47. package/types/bitforgehq-ui-overlay.d.ts +51 -0
  48. package/types/bitforgehq-ui-testing.d.ts +49 -1
  49. package/types/bitforgehq-ui.d.ts +284 -20
package/llms.txt CHANGED
@@ -80,6 +80,7 @@
80
80
 
81
81
  ### Navigation
82
82
 
83
+ - [bf-app-frame](https://bitforge-ui.web.app/ai/components/app-frame.md): Desktop app frame with skip link, sticky sidebar, narrow header and main content ([docs](https://bitforge-ui.web.app/components/app-frame))
83
84
  - [bf-back-button](https://bitforge-ui.web.app/ai/components/back-button.md): Header back button that pops the page stack or falls back to a default route ([docs](https://bitforge-ui.web.app/components/back-button))
84
85
  - [bf-breadcrumb](https://bitforge-ui.web.app/ai/components/breadcrumb.md): Desktop breadcrumb trail of links to the current page, with optional collapsing ([docs](https://bitforge-ui.web.app/components/breadcrumb))
85
86
  - [li[bfBreadcrumbItem]](https://bitforge-ui.web.app/ai/components/breadcrumb-item.md): One level of a breadcrumb trail: a link, or the current page as text ([docs](https://bitforge-ui.web.app/components/breadcrumb-item))
@@ -92,6 +93,7 @@
92
93
  - [bf-pagination](https://bitforge-ui.web.app/ai/components/pagination.md): Previous, next and numbered page buttons for a long list or table ([docs](https://bitforge-ui.web.app/components/pagination))
93
94
  - [bf-refresher](https://bitforge-ui.web.app/ai/components/refresher.md): Pull-to-refresh indicator with haptic feedback, native iOS bounce and an Android-style pull ([docs](https://bitforge-ui.web.app/components/refresher))
94
95
  - [bf-sidebar](https://bitforge-ui.web.app/ai/components/sidebar.md): Vertical app navigation with brand, grouped links, footer and an icon rail mode ([docs](https://bitforge-ui.web.app/components/sidebar))
96
+ - [bf-sidebar-toggle](https://bitforge-ui.web.app/ai/components/sidebar-toggle.md): Icon button inside a sidebar that collapses it to an icon rail and back ([docs](https://bitforge-ui.web.app/components/sidebar-toggle))
95
97
  - [bf-stack-outlet](https://bitforge-ui.web.app/ai/components/stack-outlet.md): Router outlet keeping a live page stack with slide transitions and iOS swipe back ([docs](https://bitforge-ui.web.app/components/stack-outlet))
96
98
  - [bf-tab](https://bitforge-ui.web.app/ai/components/tab.md): One tab bar destination with an icon, a label and an optional count badge ([docs](https://bitforge-ui.web.app/components/tab))
97
99
  - [bf-tab-bar](https://bitforge-ui.web.app/ai/components/tab-bar.md): Floating pill tab bar for mobile apps with arrow-key selection and count badges ([docs](https://bitforge-ui.web.app/components/tab-bar))
@@ -137,11 +139,14 @@
137
139
  - [BF_DEFAULT_VALUES](https://bitforge-ui.web.app/ai/reference/bf_default_values.md): The library's built-in widget defaults, the compact md step everywhere ([docs](https://bitforge-ui.web.app/api/bf_default_values))
138
140
  - [BF_DEFAULTS](https://bitforge-ui.web.app/ai/reference/bf_defaults.md): Injection token holding the widget defaults in effect for an injector ([docs](https://bitforge-ui.web.app/api/bf_defaults))
139
141
  - [BF_LABELS](https://bitforge-ui.web.app/ai/reference/bf_labels.md): Injection token holding the user-facing strings in effect for an injector ([docs](https://bitforge-ui.web.app/api/bf_labels))
142
+ - [BF_SIDEBAR_STATE_STORAGE](https://bitforge-ui.web.app/ai/reference/bf_sidebar_state_storage.md): Injection token for the store that keeps the collapsed sidebar between visits ([docs](https://bitforge-ui.web.app/api/bf_sidebar_state_storage))
140
143
  - [BF_TAB_BAR](https://bitforge-ui.web.app/ai/reference/bf_tab_bar.md): Injection token through which each tab reaches its enclosing tab bar ([docs](https://bitforge-ui.web.app/api/bf_tab_bar))
141
144
  - [BF_TAB_BAR_CONTROLLER](https://bitforge-ui.web.app/ai/reference/bf_tab_bar_controller.md): Injection token through which a parent drives the selection and hiding of its tab bar ([docs](https://bitforge-ui.web.app/api/bf_tab_bar_controller))
142
145
  - [BF_TAB_LINKS](https://bitforge-ui.web.app/ai/reference/bf_tab_links.md): Injection token that turns a projected tab bar into a navigation of links ([docs](https://bitforge-ui.web.app/api/bf_tab_links))
143
146
  - [BfActionDirective](https://bitforge-ui.web.app/ai/reference/bf-action-directive.md): Makes one link or button the click target of a whole card or list row ([docs](https://bitforge-ui.web.app/api/bf-action-directive))
144
147
  - [BfAlertVariant](https://bitforge-ui.web.app/ai/reference/bf-alert-variant.md): The four tones of an alert, from neutral information to a danger message ([docs](https://bitforge-ui.web.app/api/bf-alert-variant))
148
+ - [BfAppFrameBreakpoint](https://bitforge-ui.web.app/ai/reference/bf-app-frame-breakpoint.md): The breakpoint where an app frame switches from its header bar to the sidebar ([docs](https://bitforge-ui.web.app/api/bf-app-frame-breakpoint))
149
+ - [BfAppFrameContentWidth](https://bitforge-ui.web.app/ai/reference/bf-app-frame-content-width.md): The maximum width of an app frame's content column, from medium to full ([docs](https://bitforge-ui.web.app/api/bf-app-frame-content-width))
145
150
  - [BfAutocapitalize](https://bitforge-ui.web.app/ai/reference/bf-autocapitalize.md): How a phone keyboard capitalises the text typed into a field ([docs](https://bitforge-ui.web.app/api/bf-autocapitalize))
146
151
  - [BfAvatarSize](https://bitforge-ui.web.app/ai/reference/bf-avatar-size.md): The three sizes of an avatar, from a list row to a profile header ([docs](https://bitforge-ui.web.app/api/bf-avatar-size))
147
152
  - [BfAvatarVariant](https://bitforge-ui.web.app/ai/reference/bf-avatar-variant.md): The four colour schemes of an avatar behind its initials or icon ([docs](https://bitforge-ui.web.app/api/bf-avatar-variant))
@@ -163,6 +168,7 @@
163
168
  - [BfDefaults](https://bitforge-ui.web.app/ai/reference/bf-defaults.md): The default height steps of text fields and of actions and choice controls ([docs](https://bitforge-ui.web.app/api/bf-defaults))
164
169
  - [BfDefaultsOptions](https://bitforge-ui.web.app/ai/reference/bf-defaults-options.md): The size steps provideBfDefaults sets, each one falling back to the parent ([docs](https://bitforge-ui.web.app/api/bf-defaults-options))
165
170
  - [BfDescriptionListLayout](https://bitforge-ui.web.app/ai/reference/bf-description-list-layout.md): The two description list layouts, divided label-value rows or a grid of tiles ([docs](https://bitforge-ui.web.app/api/bf-description-list-layout))
171
+ - [BfEmptyStateHeading](https://bitforge-ui.web.app/ai/reference/bf-empty-state-heading.md): The heading level of an empty state title, one for a whole page ([docs](https://bitforge-ui.web.app/api/bf-empty-state-heading))
166
172
  - [BfEmptyStateHeadingLevel](https://bitforge-ui.web.app/ai/reference/bf-empty-state-heading-level.md): The heading level of an empty state title, two for a screen or three ([docs](https://bitforge-ui.web.app/api/bf-empty-state-heading-level))
167
173
  - [BfEnterKeyHint](https://bitforge-ui.web.app/ai/reference/bf-enter-key-hint.md): The labels a phone keyboard can put on its Enter key ([docs](https://bitforge-ui.web.app/api/bf-enter-key-hint))
168
174
  - [bfFieldControlClass](https://bitforge-ui.web.app/ai/reference/bf-field-control-class.md): The class list that makes a custom control look like a library text field ([docs](https://bitforge-ui.web.app/api/bf-field-control-class))
@@ -184,9 +190,11 @@
184
190
  - [BfSegmentedSize](https://bitforge-ui.web.app/ai/reference/bf-segmented-size.md): Former name of the shared size scale for segmented controls, kept until 1.0.0 ([docs](https://bitforge-ui.web.app/api/bf-segmented-size))
185
191
  - [BfSegmentOption](https://bitforge-ui.web.app/ai/reference/bf-segment-option.md): One segment of a segmented control with its value, its label and a disabled flag ([docs](https://bitforge-ui.web.app/api/bf-segment-option))
186
192
  - [BfSelectOption](https://bitforge-ui.web.app/ai/reference/bf-select-option.md): One choice of a select with its value, its label and a disabled flag ([docs](https://bitforge-ui.web.app/api/bf-select-option))
193
+ - [BfSidebarStateService](https://bitforge-ui.web.app/ai/reference/bf-sidebar-state-service.md): The sidebar's collapsed state, kept in storage between visits of the app ([docs](https://bitforge-ui.web.app/api/bf-sidebar-state-service))
187
194
  - [BfSize](https://bitforge-ui.web.app/ai/reference/bf-size.md): The three height steps every sized field and control shares ([docs](https://bitforge-ui.web.app/api/bf-size))
188
195
  - [BfSkeletonShape](https://bitforge-ui.web.app/ai/reference/bf-skeleton-shape.md): The three skeleton shapes, text lines, a rectangle or a circle ([docs](https://bitforge-ui.web.app/api/bf-skeleton-shape))
189
196
  - [BfSpinnerSize](https://bitforge-ui.web.app/ai/reference/bf-spinner-size.md): The three spinner diameters, from inline text to a page loading state ([docs](https://bitforge-ui.web.app/api/bf-spinner-size))
197
+ - [BfStatAppearance](https://bitforge-ui.web.app/ai/reference/bf-stat-appearance.md): The three stat surfaces, plain, an outlined card or a sunken tile ([docs](https://bitforge-ui.web.app/api/bf-stat-appearance))
190
198
  - [BfStatTrend](https://bitforge-ui.web.app/ai/reference/bf-stat-trend.md): The three directions of a stat's delta pill, up, down or no change ([docs](https://bitforge-ui.web.app/api/bf-stat-trend))
191
199
  - [BfStatTrendIntent](https://bitforge-ui.web.app/ai/reference/bf-stat-trend-intent.md): Whether a rising or a falling figure is the good news for a stat ([docs](https://bitforge-ui.web.app/api/bf-stat-trend-intent))
192
200
  - [BfStatVariant](https://bitforge-ui.web.app/ai/reference/bf-stat-variant.md): The two stat surfaces, plain on its container or an outlined card tile ([docs](https://bitforge-ui.web.app/api/bf-stat-variant))
@@ -199,6 +207,7 @@
199
207
  - [BfTableRowKey](https://bitforge-ui.web.app/ai/reference/bf-table-row-key.md): Function that returns the unique string key of one table row ([docs](https://bitforge-ui.web.app/api/bf-table-row-key))
200
208
  - [BfTableSort](https://bitforge-ui.web.app/ai/reference/bf-table-sort.md): The column key and direction a table is sorted by, set by its headers ([docs](https://bitforge-ui.web.app/api/bf-table-sort))
201
209
  - [BfTableSortDirection](https://bitforge-ui.web.app/ai/reference/bf-table-sort-direction.md): The direction a sorted table column is in, ascending or descending ([docs](https://bitforge-ui.web.app/api/bf-table-sort-direction))
210
+ - [BfTableStack](https://bitforge-ui.web.app/ai/reference/bf-table-stack.md): When a table stacks its rows into cards: never, when narrow, or under touch ([docs](https://bitforge-ui.web.app/api/bf-table-stack))
202
211
  - [BfTabLinks](https://bitforge-ui.web.app/ai/reference/bf-tab-links.md): The URLs a router-aware parent gives a tab bar to render its tabs as links ([docs](https://bitforge-ui.web.app/api/bf-tab-links))
203
212
  - [BfToggleLabelPosition](https://bitforge-ui.web.app/ai/reference/bf-toggle-label-position.md): Whether a toggle's label sits after or before its switch ([docs](https://bitforge-ui.web.app/api/bf-toggle-label-position))
204
213
  - [bfValidationMessage](https://bitforge-ui.web.app/ai/reference/bf-validation-message.md): Turns one validation error into the text a form field shows under it ([docs](https://bitforge-ui.web.app/api/bf-validation-message))
@@ -206,6 +215,7 @@
206
215
  - [provideBfColorScheme](https://bitforge-ui.web.app/ai/reference/provide-bf-color-scheme.md): Applies the stored colour scheme choice to html, for desktop web apps ([docs](https://bitforge-ui.web.app/api/provide-bf-color-scheme))
207
216
  - [provideBfDefaults](https://bitforge-ui.web.app/ai/reference/provide-bf-defaults.md): Sets the default field and control sizes for an app or a sub-tree ([docs](https://bitforge-ui.web.app/api/provide-bf-defaults))
208
217
  - [provideBfLabels](https://bitforge-ui.web.app/ai/reference/provide-bf-labels.md): Replaces built-in strings for an app or a sub-tree, such as a translation ([docs](https://bitforge-ui.web.app/api/provide-bf-labels))
218
+ - [provideBfSidebarState](https://bitforge-ui.web.app/ai/reference/provide-bf-sidebar-state.md): Remembers the collapsed sidebar between visits, for desktop web apps ([docs](https://bitforge-ui.web.app/api/provide-bf-sidebar-state))
209
219
 
210
220
  ### @bitforgehq/ui/overlay
211
221
 
@@ -409,6 +419,7 @@
409
419
  - [BfRadioGroupHarness](https://bitforge-ui.web.app/ai/reference/bf-radio-group-harness.md): Test harness for the radio group: reads its options and selects one by label ([docs](https://bitforge-ui.web.app/api/bf-radio-group-harness))
410
420
  - [BfSegmentedHarness](https://bitforge-ui.web.app/ai/reference/bf-segmented-harness.md): Test harness for the segmented control: reads its segments and selects one ([docs](https://bitforge-ui.web.app/api/bf-segmented-harness))
411
421
  - [BfSelectHarness](https://bitforge-ui.web.app/ai/reference/bf-select-harness.md): Test harness for the select: reads its label and options and picks one ([docs](https://bitforge-ui.web.app/api/bf-select-harness))
422
+ - [BfSidebarToggleHarness](https://bitforge-ui.web.app/ai/reference/bf-sidebar-toggle-harness.md): Test harness for a sidebar toggle: reads and flips the collapsed sidebar ([docs](https://bitforge-ui.web.app/api/bf-sidebar-toggle-harness))
412
423
  - [BfSidePanelHarness](https://bitforge-ui.web.app/ai/reference/bf-side-panel-harness.md): Test harness for a side panel: its title, its close button and its state ([docs](https://bitforge-ui.web.app/api/bf-side-panel-harness))
413
424
  - [BfTabGroupHarness](https://bitforge-ui.web.app/ai/reference/bf-tab-group-harness.md): Test harness for the tab group: reads its tabs and panel and selects a tab ([docs](https://bitforge-ui.web.app/api/bf-tab-group-harness))
414
425
  - [BfTableHarness](https://bitforge-ui.web.app/ai/reference/bf-table-harness.md): Test harness for the data table: reads rows and cells, sorts and selects rows ([docs](https://bitforge-ui.web.app/api/bf-table-harness))
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bitforgehq/ui",
3
- "version": "0.3.1",
3
+ "version": "0.3.3",
4
4
  "description": "Bitforge UI: Angular 22 widgets (Meadow Sage palette with an indigo default primary to override, Tailwind v4, signals-first) and, from v0.2, a Capacitor app shell.",
5
5
  "license": "MIT",
6
6
  "repository": {
package/theme.css CHANGED
@@ -352,3 +352,16 @@
352
352
  .dark .bf-overlay-backdrop {
353
353
  background: rgb(0 0 0 / 0.6);
354
354
  }
355
+
356
+ /* ---------- Stacked table labels ---------- */
357
+ /*
358
+ * The column label a stacked `bf-table` cell shows before its value (`before:content-data-label`
359
+ * behind a stack variant): the cell's `data-label`, with empty alternative text, so assistive
360
+ * technology reads the header association and not the label twice. A named utility, not
361
+ * `content-[attr(data-label)_/_""]`: the library build escapes the quotes of a class written in a
362
+ * string (`\"\"`), and Tailwind then builds the rule for a class no element carries.
363
+ */
364
+ @utility content-data-label {
365
+ --tw-content: attr(data-label) / '';
366
+ content: var(--tw-content);
367
+ }
@@ -1643,6 +1643,57 @@ export declare class BfThemeMenuButtonComponent {
1643
1643
  "changed": "changed";
1644
1644
  }, never, ["[bfSlot=icon]"], true, never>;
1645
1645
  }
1646
+ /**
1647
+ * The collapse button of a `bf-sidebar`: a text icon button placed inside the sidebar (usually in
1648
+ * its header or footer) that flips the sidebar between full width and an icon rail. Its name and
1649
+ * tooltip say what the next press does ("Collapse sidebar", "Expand sidebar"), `aria-expanded`
1650
+ * follows the sidebar and `aria-controls` points at its `nav`. It shows the `collapse-icon` slot
1651
+ * while expanded and the `expand-icon` slot while collapsed. It reads and writes the sidebar's
1652
+ * `collapsed` model, so `[(collapsed)]` on the sidebar sees every press. Outside a `bf-sidebar`
1653
+ * (in a `bf-top-nav`, or on its own) it renders nothing.
1654
+ *
1655
+ * @example
1656
+ * <bf-sidebar [(collapsed)]="sidebarState.collapsed">
1657
+ * <bf-sidebar-toggle bfSlot="footer">
1658
+ * <bf-icon bfSlot="collapse-icon" [icon]="PanelLeftClose" />
1659
+ * <bf-icon bfSlot="expand-icon" [icon]="PanelLeftOpen" />
1660
+ * </bf-sidebar-toggle>
1661
+ * </bf-sidebar>
1662
+ * @summary Icon button inside a sidebar that collapses it to an icon rail and back
1663
+ * @category Navigation
1664
+ * @since 0.3.2
1665
+ * @slot collapse-icon The icon shown while the sidebar is expanded (a panel closing).
1666
+ * @slot expand-icon The icon shown while the sidebar is an icon rail (a panel opening).
1667
+ */
1668
+ export declare class BfSidebarToggleComponent {
1669
+ private readonly defaults;
1670
+ private readonly labels;
1671
+ private readonly host;
1672
+ /** The enclosing sidebar's context; null outside a sidebar (a top nav never collapses). */
1673
+ protected readonly nav: import("@bitforgehq/ui").ɵBfNavHost | null;
1674
+ /** Height step: sm 32, md 40, lg 48 px (square); unset follows `provideBfDefaults()`
1675
+ * (`controlSize`, `md` by default). */
1676
+ readonly size: import("@angular/core").InputSignal<BfSize | undefined>;
1677
+ /** Whether the sidebar is an icon rail now. */
1678
+ protected readonly collapsed: import("@angular/core").Signal<boolean>;
1679
+ /** What the next press does: `sidebarExpand` while collapsed, else `sidebarCollapse`. */
1680
+ protected readonly name: import("@angular/core").Signal<string>;
1681
+ protected readonly hostClasses: import("@angular/core").Signal<string>;
1682
+ protected readonly classes: import("@angular/core").Signal<string>;
1683
+ /**
1684
+ * Flips the sidebar between full width and an icon rail.
1685
+ * @internal
1686
+ */
1687
+ toggle(): void;
1688
+ static ɵfac: i0.ɵɵFactoryDeclaration<BfSidebarToggleComponent, never>;
1689
+ static ɵcmp: i0.ɵɵComponentDeclaration<BfSidebarToggleComponent, "bf-sidebar-toggle", never, {
1690
+ "size": {
1691
+ "alias": "size";
1692
+ "required": false;
1693
+ "isSignal": true;
1694
+ };
1695
+ }, {}, never, ["[bfSlot=collapse-icon]", "[bfSlot=expand-icon]"], true, never>;
1696
+ }
1646
1697
  /**
1647
1698
  * Layout of a side panel opened with `BfSidePanelService`: a title row with a close button, a
1648
1699
  * scrolling body and a footer of actions kept at the bottom. The panel is labelled by the title,
@@ -495,7 +495,7 @@ export declare class BfDesktopToastHarness extends ComponentHarness {
495
495
  /**
496
496
  * Harness for `bf-table`. It works by column header text and row position, so a test never needs
497
497
  * the column keys or the row keys (except `getSort()`, which returns the column's `key`, as the
498
- * `sort` model holds it).
498
+ * `sort` model holds it). It reads and drives a stacked table (`stack`) the same way.
499
499
  *
500
500
  * @example
501
501
  * const tasks = await loader.getHarness(BfTableHarness.with({ label: 'Tasks' }));
@@ -512,6 +512,7 @@ export declare class BfTableHarness extends ComponentHarness {
512
512
  private readonly rows;
513
513
  private readonly selectAllBox;
514
514
  private readonly rowBoxes;
515
+ private readonly sortSelect;
515
516
  /**
516
517
  * A predicate for a table with the given label.
517
518
  * @param filters The label (text or pattern) and the CDK's selector and ancestor filters.
@@ -551,6 +552,19 @@ export declare class BfTableHarness extends ComponentHarness {
551
552
  * @returns The sort, `null` while no column is sorted.
552
553
  */
553
554
  getSort(): Promise<BfTableSort | null>;
555
+ /**
556
+ * The Sort by select in a stacked table's bar: its first option, Not sorted (`tableSortNone`),
557
+ * sets `sort` to null and shows while it is; then each sortable column ascending and descending.
558
+ *
559
+ * @example
560
+ * const sortBy = await tasks.getSortSelect();
561
+ * await sortBy?.selectOption('Hours, descending');
562
+ * expect(await tasks.getSort()).toEqual({ column: 'hours', direction: 'descending' });
563
+ * @returns The select's harness; `null` when the table cannot stack (`stack="never"`) or has no
564
+ * sortable column.
565
+ * @since 0.3.3
566
+ */
567
+ getSortSelect(): Promise<BfSelectHarness | null>;
554
568
  /**
555
569
  * Checks one row's checkbox, as a user would; a selected row stays selected. Throws when the
556
570
  * table is not selectable or the row does not exist.
@@ -1239,4 +1253,38 @@ export declare class BfChartHarness extends ComponentHarness {
1239
1253
  showData(): Promise<string[][]>;
1240
1254
  private legendButton;
1241
1255
  }
1256
+ /**
1257
+ * Harness for `bf-sidebar-toggle`, the button that collapses a `bf-sidebar` to an icon rail. Its
1258
+ * `label` filter matches the button's name ("Collapse sidebar" or "Expand sidebar").
1259
+ *
1260
+ * @example
1261
+ * const toggle = await loader.getHarness(BfSidebarToggleHarness);
1262
+ * await toggle.toggle();
1263
+ * expect(await toggle.isExpanded()).toBe(false);
1264
+ * @summary Test harness for a sidebar toggle: reads and flips the collapsed sidebar
1265
+ * @since 0.3.2
1266
+ */
1267
+ export declare class BfSidebarToggleHarness extends ComponentHarness {
1268
+ /** The host element's selector. */
1269
+ static hostSelector: string;
1270
+ private readonly button;
1271
+ /**
1272
+ * A predicate for a sidebar toggle with the given name.
1273
+ * @param filters The name (text or pattern) and the CDK's selector and ancestor filters.
1274
+ * @returns The predicate for `getHarness()` and friends.
1275
+ */
1276
+ static with(filters?: BfHarnessFilters): HarnessPredicate<BfSidebarToggleHarness>;
1277
+ /**
1278
+ * The button's name, which says what the next press does.
1279
+ * @returns The `aria-label`.
1280
+ */
1281
+ getLabel(): Promise<string>;
1282
+ /**
1283
+ * Whether the sidebar is at full width (`aria-expanded`).
1284
+ * @returns True while expanded, false while it is an icon rail.
1285
+ */
1286
+ isExpanded(): Promise<boolean>;
1287
+ /** Flips the sidebar with a click. */
1288
+ toggle(): Promise<void>;
1289
+ }
1242
1290
  export type { BfHarnessFilters, BfJsdomShimOptions, BfTestingOptions };