@umriss-ui/core 0.34.0 → 0.35.0

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
@@ -26,6 +26,32 @@ package stood at `0.1.0` the whole time, because it had exactly one caller and t
26
26
  caller lay in the same repository — and are grouped by unit of delivery, not by
27
27
  commit.
28
28
 
29
+ ## 0.35.0 – React 19 is the floor, and an import pays for what it uses (Oct. 2026)
30
+
31
+ ### Changed
32
+
33
+ - **React 19 is required.** The peers `react` and `react-dom` are `>=19`; `0.34.0` is the last version that serves React 18 (ADR-0062).
34
+
35
+ - **`ref` is a prop of every component, and none is a `forwardRef` object.** A component is a plain function that takes `ref` with its props, and its props type says so: it extends the new exported type `RefProp<Element>`, with the element the component renders at its root. A `ref` works as it did; a `ref` of the wrong element type is now a type error, and code that looked for `$$typeof` on a component no longer finds one.
36
+
37
+ - **The package ships ES2022 syntax.** An application that serves older browsers transpiles it itself.
38
+
39
+ ### Fixed
40
+
41
+ - **A virtualised tree that was scrolled stays where it was scrolled.** Once its active node had been moved by key, the tree pulled the view back to that node on every render, so a wheel could not leave it. The view now follows the active node only when the node moves.
42
+
43
+ - **A virtualised tree scrolls its whole length inside a container of fixed height.** Its filler rows were squeezed to nothing there, and the scroll area was only as high as its window.
44
+
45
+ ### Otherwise
46
+
47
+ - **An import pays for what it uses.** Every component was a call at the top of its module, which a bundler has to keep with everything it reaches, so one `Button` brought the package. Minified and gzipped, `Button` alone is now 5.2 kB where it was 43.5 kB, `Select` 9.4 kB, and an import that uses nothing leaves 1.1 kB. A check on the built package holds it.
48
+
49
+ - **A key in a large tree costs what it costs in a small one.** The flattening was computed again for every move of the active node; at 100,000 nodes a key took 14 ms and now takes 0.3 ms.
50
+
51
+ - **`useVirtual` renders its caller only when the window of rows changes.** It used to render on every scroll event.
52
+
53
+ ---
54
+
29
55
  ## 0.34.0 – The Dock and the alarm list's words leave (Oct. 2026)
30
56
 
31
57
  From this version all five packages carry one number and are released
package/README.md CHANGED
@@ -30,14 +30,26 @@ In an application:
30
30
  import { Button, Card } from "@umriss-ui/core";
31
31
  ```
32
32
 
33
- Nothing else is required. React 18 or 19 as a peer; the unit tests run against
34
- 18.3 and 19 in CI.
33
+ Nothing else is required. React 19 or newer as a peer.
34
+
35
+ The package ships ES2022 syntax; an application that serves older browsers
36
+ transpiles it itself.
35
37
 
36
38
  Every entry, `./wording/de` included, begins with `"use client"`, the directive a framework
37
39
  with Server Components reads to treat a module as client code. No test runs
38
40
  inside such a framework: the package is rendered to a string in a test,
39
41
  and the fields' widths a server writes into the markup are checked there.
40
42
 
43
+ ### What an import costs
44
+
45
+ An application whose bundler shakes the tree pays for what it imports, not for
46
+ the package. Minified and gzipped, the stylesheet not counted: an import that
47
+ uses nothing 1.1 kB, `Button` 5.2 kB, `Select` 9.4 kB, `DatePicker` 10.4 kB,
48
+ everything 50.7 kB. The figures come from bundling an entry that imports from
49
+ the built `dist/core.js` with Rollup - the peers external, the stylesheet
50
+ resolved to nothing - then minifying with esbuild and gzipping. `check:dist`
51
+ holds the first of them under 1.5 kB in every package.
52
+
41
53
  ## Styles
42
54
 
43
55
  **They load themselves.** `dist/core.js` imports its stylesheet, and the
@@ -178,7 +190,7 @@ The table is not part of this package. It lives in
178
190
 
179
191
  ## Principles for new components
180
192
 
181
- 1. Pass `forwardRef`, `className` and `...rest` through to the root element –
193
+ 1. Pass `ref`, `className` and `...rest` through to the root element –
182
194
  every component that renders a root element. Excepted are the wrappers that
183
195
  have none: `Popover` renders into a portal, `Tooltip` around the caller's
184
196
  child, `Menu`, `ContextMenu` and `ToastProvider` are composed of other