@coolms/ui-react 0.1.0-alpha.37 → 0.1.0-alpha.38

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.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  All notable changes to `@coolms/ui-react` are listed here. Versions follow [semantic versioning](https://semver.org/).
4
4
 
5
+ ## 0.1.0-alpha.38 (2026-12-02)
6
+
7
+ An action that cannot run says why on hover, on keyboard focus and on a press, and Escape hides that.
8
+
9
+ - `SectionHeader`: a refused action (the primary or a secondary) draws its reason instead of a native title, which only a mouse hover shows. The reason shows on hover with a fine pointer, on keyboard focus and after a press. It is the action's description, centred under the action and moved only as far as keeps it inside the header row, never wider than the row. A refused secondary is named by its label alone, and its reason keeps full contrast. (#149)
10
+ - `SectionHeader` and `PaneToolbar`: Escape hides a drawn reason whichever of hover, focus or a press showed it, until the pointer and the focus have left the action; a press shows it again (WCAG 1.4.13). (#149)
11
+
12
+ Not in the package: ws 8.23.1 in the lockfile clears GHSA-37g9-w4hg-h9qr; it is a development dependency only (#150). The demo's headers screen has a head in a real pane whose actions are refused (#149).
13
+
5
14
  ## 0.1.0-alpha.37 (2026-12-01)
6
15
 
7
16
  A list flung to its end on a phone stays there.
@@ -17,6 +17,11 @@ export type SectionPrimary = {
17
17
  /** The split menu button's accessible name. */
18
18
  readonly menuLabel: string;
19
19
  };
20
+ /**
21
+ * Where a drawn reason starts in its row, in px from the row's left: centred on its action when the row has room, moved
22
+ * only as far as keeps it inside the row.
23
+ */
24
+ export declare function reasonLeft(anchorCentre: number, rowWidth: number, tipWidth: number): number;
20
25
  /** One of the section's other declared actions: a button in row 1 while it fits. */
21
26
  export interface SectionAction {
22
27
  readonly id: string;
@@ -0,0 +1,14 @@
1
+ /**
2
+ * A drawn tip's dismissal (WCAG 1.4.13): Escape hides it whether hover, keyboard focus or a press showed it, and it
3
+ * stays hidden until both the pointer and the focus have left its control. A control is named by an id the caller
4
+ * gives; the control marks itself `data-tip-dismissed` while `dismissed(id)`, and the stylesheet shows no tip there.
5
+ */
6
+ export declare function useTipDismissal(): {
7
+ readonly dismissed: (id: string) => boolean;
8
+ readonly dismiss: (id: string) => void;
9
+ readonly show: (id: string) => void;
10
+ readonly pointerIn: (id: string) => void;
11
+ readonly pointerOut: (id: string) => void;
12
+ readonly focusIn: (id: string) => void;
13
+ readonly focusOut: (id: string) => void;
14
+ };