@nurvus/ui 0.1.0-alpha.18 → 0.1.0-alpha.19

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/README.md CHANGED
@@ -30,15 +30,15 @@ Or pin the range in `package.json`:
30
30
  ### Usage
31
31
  Use the following example after installation:
32
32
  ```jsx static
33
- import React from 'react';
34
- import ReactDOM from 'react-dom';
33
+ import { createRoot } from 'react-dom/client';
35
34
  import { Button } from '@nurvus/ui';
36
35
 
37
36
  function App() {
38
37
  return <Button type="primary">Hello, world!</Button>;
39
38
  }
40
39
 
41
- ReactDOM.render(<App />, document.querySelector('#root'));
40
+ createRoot(document.getElementById('root')).render(<App />);
41
+ // React 16.8 or 17: ReactDOM.render(<App />, document.getElementById('root'));
42
42
  ```
43
43
 
44
44
  ### Themes
@@ -78,6 +78,11 @@ Themes nest (`<nav data-theme="tokyo-neon">` inside a light page), and your own
78
78
  ### New in 0.1.0-alpha.15
79
79
  - **`Icon`**: icons drawn for NURVUS on a 24-unit grid, in the text color, **1em by default** so an icon is as big as the text it sits in (`<Icon name="search" />`; `label` for an icon that stands alone). Names are typed (`IconName`); `ICONS` / `ICON_NAMES` list them. Same markup in `@nurvus/ui/respawn`.
80
80
 
81
+ ### New in 0.1.0-alpha.19
82
+ - **`Menu` nested groups**: any navigation item can have its own `items`, as deep as you like (Tree's shape). A group opens and closes like a section (its chevron between the guide line and the words, its title lined up with the items around it, its own guide line); with an `href` its title is a link too. → opens a group, ← closes it or goes up; the current page opens every group it is in. Same markup in Respawn.
83
+ - **`Menu`: Space follows a link** as Enter does (the WAI-ARIA navigation tree), so every row answers both keys; a section title that is the current page is now `aria-current="page"` too.
84
+ - Quick start: `createRoot` (React 18 and 19; `ReactDOM.render` is gone in React 19).
85
+
81
86
  ### New in 0.1.0-alpha.18
82
87
  - **`NavToggle`**: the button that shows and hides navigation. The hamburger (even or asymmetric lines; eight ways to turn into a close mark: slide, cross, squeeze, elastic, spin, arrow, chevron, collapse) or the sidebar icon (its pane fills while the sidebar shows; closed, it shrinks away and the divider slides left). Says what it will do and whether it is open.
83
88
  - **`Tooltip`**: a short label for a control, on hover (after a short rest) and keyboard focus, with an optional shortcut as key caps. WCAG 1.4.13: Esc hides it, the pointer can move onto it, it stays while hovered or focused. Describes the control (`aria-describedby`).