@kerfjs/ui 5.0.0-beta.121 → 5.0.0-beta.122
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/ai/component-catalog.json +2 -2
- package/ai/components/document-baseline.md +2 -2
- package/ai/public-api-signatures-v1.md +1 -1
- package/ai/skill.md +1 -1
- package/ai/webawesome-jsx-signatures-v1.md +1 -1
- package/dist/styles/document.css +9 -0
- package/docs/document-baseline.md +5 -0
- package/docs/webawesome-migration.md +10 -2
- package/llms.txt +2 -1
- package/package.json +1 -1
|
@@ -503,12 +503,12 @@
|
|
|
503
503
|
"category": "Foundation",
|
|
504
504
|
"kind": "composition",
|
|
505
505
|
"source": "kerf",
|
|
506
|
-
"description": "Opt-in document-level defaults: border-box sizing, body margin/font/surface, native table-cell and form-control font metrics, semantic control cursors, link color, and the html → body → .kui-app-root full-height chain.",
|
|
506
|
+
"description": "Opt-in document-level defaults: border-box sizing, body margin/font/surface/smoothing, text-size adjustment, strong weight, native table-cell and form-control font metrics, semantic control cursors, link color, and the html → body → .kui-app-root full-height chain.",
|
|
507
507
|
"uses": [],
|
|
508
508
|
"purpose": "Let an application opt into Kerf UI-owned document defaults and a definite full-height chain for a percentage-height application shell.",
|
|
509
509
|
"publicExports": [],
|
|
510
510
|
"useWhen": [
|
|
511
|
-
"An application wants Kerf UI to own document-level box sizing, body typography, native table-cell and form-control font metrics, surface, and link color.",
|
|
511
|
+
"An application wants Kerf UI to own document-level box sizing, body typography and font smoothing, text-size adjustment, strong weight, native table-cell and form-control font metrics, surface, and link color.",
|
|
512
512
|
"A full-height shell (Workbench, SplitView, NavStack, or TabNavigator) mounts into one direct container: put .kui-app-root on that container."
|
|
513
513
|
],
|
|
514
514
|
"avoidWhen": [
|
|
@@ -4,13 +4,13 @@
|
|
|
4
4
|
|
|
5
5
|
`@kerfjs/ui:document-baseline` · Kerf UI · CSS composition · Foundation
|
|
6
6
|
|
|
7
|
-
Opt-in document-level defaults: border-box sizing, body margin/font/surface, native table-cell and form-control font metrics, semantic control cursors, link color, and the html → body → .kui-app-root full-height chain.
|
|
7
|
+
Opt-in document-level defaults: border-box sizing, body margin/font/surface/smoothing, text-size adjustment, strong weight, native table-cell and form-control font metrics, semantic control cursors, link color, and the html → body → .kui-app-root full-height chain.
|
|
8
8
|
|
|
9
9
|
## When to use
|
|
10
10
|
|
|
11
11
|
Let an application opt into Kerf UI-owned document defaults and a definite full-height chain for a percentage-height application shell.
|
|
12
12
|
|
|
13
|
-
- An application wants Kerf UI to own document-level box sizing, body typography, native table-cell and form-control font metrics, surface, and link color.
|
|
13
|
+
- An application wants Kerf UI to own document-level box sizing, body typography and font smoothing, text-size adjustment, strong weight, native table-cell and form-control font metrics, surface, and link color.
|
|
14
14
|
- A full-height shell (Workbench, SplitView, NavStack, or TabNavigator) mounts into one direct container: put .kui-app-root on that container.
|
|
15
15
|
|
|
16
16
|
**Not when:**
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Public API signatures for the UI authoring corpus
|
|
2
2
|
|
|
3
|
-
Generated from emitted declarations for `@kerfjs/ui@5.0.0-beta.
|
|
3
|
+
Generated from emitted declarations for `@kerfjs/ui@5.0.0-beta.122` and `kerfjs@5.0.0-beta.122`. This bounded reference covers only APIs used by the seven-task corpus. It is interface evidence, not an implementation or runtime guarantee.
|
|
4
4
|
|
|
5
5
|
## `@kerfjs/ui/css-values`
|
|
6
6
|
|
package/ai/skill.md
CHANGED
|
@@ -500,7 +500,7 @@ Use `Toolbar responsive="trailing-priority"` when an expanded trailing search ne
|
|
|
500
500
|
For a 40px header embedded in a panel or card, pass `Toolbar density="compact"` (a 34px control band with 3px block insets) and give its groups `size="compact"`; never shrink a Toolbar with CSS. Workbench, CollapsiblePanel, NavStack, and SplitView toolbars take `density` through their `ToolbarConfig` and size the groups they compose (panel toggles, the back button) to match; pass `density` to `CollapsiblePanelRelocated` when the destination toolbar is compact. Set `--kui-toolbar-inset: 0px` on an embedded Toolbar to remove its outer padding while retaining `--kui-toolbar-gap` between zones. The same inset token controls the minimum-height allowance; safe-area padding still applies at claimed edges.
|
|
501
501
|
|
|
502
502
|
For compact dialog copy, use `Text flush lineHeight="tight"`; center short status copy with `Text align="center"` (or end-align a value with `align="end"`) rather than setting `text-align` on `.kui-text`; for compact metadata, use `ValueTable density="compact"` and its public row columns/padding/gap tokens. `ToolbarText size="xsmall"` fits a dense rail heading. A `SearchField` editor shrinks inside a narrow group by default; set `--kui-search-field-editor-min-width` when a minimum is needed. A full-height shell uses the one `.kui-app-root` mount container documented in `docs/document-baseline.md`.
|
|
503
|
-
When importing the opt-in `@kerfjs/ui/document.css` baseline, native `th`, `td`, `button`, `input`, `select`, and `textarea` inherit the surrounding font family, size, and line height; table headers retain their native emphasis. The baseline also gives native controls zero-specificity semantic cursors (pointer on enabled buttons, links, role=button, checkbox/radio inputs, and selects; not-allowed on disabled controls and a disabled `wa-button`; text on text inputs), so do not ship an app-wide cursor stylesheet. A full-viewport shell whose document must never scroll adds `data-viewport="locked"` to its body-child `.kui-app-root` (100dvh plus `overflow: clip` on `html`, `body`, and the root) instead of app CSS. Load application typography overrides after the baseline.
|
|
503
|
+
When importing the opt-in `@kerfjs/ui/document.css` baseline, the body gets Web Awesome-compatible font smoothing and disabled automatic text inflation, and native `strong`/`b` get weight 600 (or `--wa-font-weight-bold`). Native `th`, `td`, `button`, `input`, `select`, and `textarea` inherit the surrounding font family, size, and line height; table headers retain their native emphasis. The baseline also gives native controls zero-specificity semantic cursors (pointer on enabled buttons, links, role=button, checkbox/radio inputs, and selects; not-allowed on disabled controls and a disabled `wa-button`; text on text inputs), so do not ship an app-wide cursor stylesheet. A full-viewport shell whose document must never scroll adds `data-viewport="locked"` to its body-child `.kui-app-root` (100dvh plus `overflow: clip` on `html`, `body`, and the root) instead of app CSS. Load application typography overrides after the baseline.
|
|
504
504
|
|
|
505
505
|
For a read-only field preview that replaces a Web Awesome input, use `FieldLabel` from `@kerfjs/ui/text` above the preview. Put it in `ListInsetControl sides="trl"` beside a `ContentItem` value; give it an id and use `aria-labelledby` on the preview group. The app owns preview/edit state and hint copy.
|
|
506
506
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Web Awesome JSX signatures for the UI authoring corpus
|
|
2
2
|
|
|
3
|
-
Generated from the emitted `@kerfjs/ui@5.0.0-beta.
|
|
3
|
+
Generated from the emitted `@kerfjs/ui@5.0.0-beta.122` declaration boundary. Import `@kerfjs/ui/webawesome` for type effects when authoring direct `wa-*` JSX. The module emits no runtime behavior and does not register custom elements.
|
|
4
4
|
|
|
5
5
|
```ts
|
|
6
6
|
import { KerfCustomElement } from 'kerfjs/jsx-runtime';
|
package/dist/styles/document.css
CHANGED
|
@@ -20,6 +20,15 @@ body {
|
|
|
20
20
|
background: var(--kui-color-surface-lowered);
|
|
21
21
|
font-family: var(--kui-font-sans);
|
|
22
22
|
line-height: 1.45;
|
|
23
|
+
-webkit-font-smoothing: antialiased;
|
|
24
|
+
-moz-osx-font-smoothing: grayscale;
|
|
25
|
+
text-size-adjust: none;
|
|
26
|
+
-webkit-text-size-adjust: none;
|
|
27
|
+
-moz-text-size-adjust: none;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
:where(strong, b) {
|
|
31
|
+
font-weight: var(--wa-font-weight-bold, 600);
|
|
23
32
|
}
|
|
24
33
|
|
|
25
34
|
/* Opt-in viewport lock for a full-viewport application shell: the dynamic
|
|
@@ -17,6 +17,11 @@ The opt-in stylesheet applies `border-box` sizing to every element and
|
|
|
17
17
|
pseudo-element, removes the body margin, and gives the body the foundation
|
|
18
18
|
font, foreground, lowered surface, and `1.45` line height. Plain links use the
|
|
19
19
|
semantic `--kui-color-text-link` token with zero selector specificity.
|
|
20
|
+
The body also uses antialiased font smoothing on WebKit, grayscale smoothing
|
|
21
|
+
on macOS Firefox, and disables automatic text-size inflation on mobile browsers,
|
|
22
|
+
matching Web Awesome's former `native.css` defaults. Native `strong` and `b`
|
|
23
|
+
use weight 600 (or `--wa-font-weight-bold` when a Web Awesome theme supplies it)
|
|
24
|
+
through a zero-specificity selector, so application typography can override it.
|
|
20
25
|
Native table cells (`th`, `td`) and form controls (`button`, `input`, `select`,
|
|
21
26
|
`textarea`) inherit the surrounding font family, size, and line height through
|
|
22
27
|
zero-specificity selectors. Table headers keep their native bold weight and
|
|
@@ -76,8 +76,16 @@ Once no `wa-*` element remains in the application:
|
|
|
76
76
|
4. Keep `@kerfjs/ui/foundation.css` (or your theme entry). Its tokens fall back
|
|
77
77
|
to the same values the Web Awesome theme gave them. Kerf's `Text` and
|
|
78
78
|
`ValueTable` styles also own their native heading, paragraph, and label
|
|
79
|
-
typography
|
|
80
|
-
|
|
79
|
+
typography.
|
|
80
|
+
5. If Web Awesome's `native.css` supplied the application's document defaults,
|
|
81
|
+
import `@kerfjs/ui/document.css`. It preserves body font smoothing and
|
|
82
|
+
text-size adjustment, plus the 600-weight `strong`/`b` rule used inside
|
|
83
|
+
`Text` and application prose. `foundation.css` supplies tokens, not these global rules.
|
|
84
|
+
If the host page owns its document styles, carry these rules into that
|
|
85
|
+
baseline instead of importing Kerf's opt-in baseline.
|
|
86
|
+
|
|
87
|
+
With the document baseline in place, Kerf components retain their typography
|
|
88
|
+
when Web Awesome is removed.
|
|
81
89
|
|
|
82
90
|
If the application keeps a few specialized elements (Tree, Carousel, Rating,
|
|
83
91
|
and so on), keep steps 1–3 only for those elements; the integration's theme
|
package/llms.txt
CHANGED
|
@@ -269,7 +269,8 @@ headingLevel`, `SearchField clearIcon`, `ContentItem frame="framed"` for a
|
|
|
269
269
|
container padding on top of a content-item's own margin — pick one owner. Use
|
|
270
270
|
`.kui-content` for 24px major vertical rhythm.
|
|
271
271
|
- **Opt into document globals explicitly.** Import `@kerfjs/ui/document.css`
|
|
272
|
-
once for border-box sizing, token-backed body/link presentation,
|
|
272
|
+
once for border-box sizing, token-backed body/link presentation, Web Awesome-compatible
|
|
273
|
+
font smoothing, text-size adjustment and strong weight, inherited
|
|
273
274
|
native table-cell and form-control font metrics, zero body margin, and
|
|
274
275
|
zero-specificity semantic cursors for native controls (pointer, not-allowed
|
|
275
276
|
when disabled, text on text inputs). Put `.kui-app-root` on the one direct mount container only when a
|