@helixui/icons 1.0.0 → 1.0.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.
- package/README.md +26 -13
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -5,13 +5,13 @@ web component library.
|
|
|
5
5
|
|
|
6
6
|
## Status
|
|
7
7
|
|
|
8
|
-
| Phase | Scope | Status
|
|
9
|
-
| ----- | ---------------------------------------------------- |
|
|
10
|
-
| 1 | Package scaffold, exports map, type surface | Done
|
|
11
|
-
| 2 | Registry runtime (`registerIconLibrary` and friends) | Done
|
|
12
|
-
| 3 | `helix` + `fa-free` libraries with auto-registration | Done
|
|
13
|
-
| 4 | `<hx-icon>` upgrade in `@helixui/library` + P0 cert |
|
|
14
|
-
| 5 | Internal SVG migration
|
|
8
|
+
| Phase | Scope | Status |
|
|
9
|
+
| ----- | ---------------------------------------------------- | ------ |
|
|
10
|
+
| 1 | Package scaffold, exports map, type surface | Done |
|
|
11
|
+
| 2 | Registry runtime (`registerIconLibrary` and friends) | Done |
|
|
12
|
+
| 3 | `helix` + `fa-free` libraries with auto-registration | Done |
|
|
13
|
+
| 4 | `<hx-icon>` upgrade in `@helixui/library` + P0 cert | Done — hx-icon ships in 3.9.0 with AAA verdicts recorded in `packages/hx-library/aaa-verdicts.json` |
|
|
14
|
+
| 5 | Internal SVG migration + 1.0.0 public release | Done — `@helixui/icons` 1.0.0 published, internal components consume the registry |
|
|
15
15
|
|
|
16
16
|
## Why a registry
|
|
17
17
|
|
|
@@ -53,6 +53,11 @@ Register a custom library (e.g. Font Awesome Pro Medical):
|
|
|
53
53
|
```ts
|
|
54
54
|
import { registerIconLibrary } from '@helixui/icons';
|
|
55
55
|
|
|
56
|
+
// External resolvers must be allow-listed by the consumer page via the
|
|
57
|
+
// `allowed-origins` attribute on every <hx-icon> that targets the
|
|
58
|
+
// library (or via the global allowlist on the page-level <hx-icon>
|
|
59
|
+
// default), or the icon fetch will be blocked by the registry's
|
|
60
|
+
// origin guard.
|
|
56
61
|
registerIconLibrary('fa-pro-medical', {
|
|
57
62
|
resolver: (name) =>
|
|
58
63
|
`https://kit.fontawesome.com/your-kit/icons/medical/${name}.svg`,
|
|
@@ -65,7 +70,11 @@ registerIconLibrary('fa-pro-medical', {
|
|
|
65
70
|
```
|
|
66
71
|
|
|
67
72
|
```html
|
|
68
|
-
<hx-icon
|
|
73
|
+
<hx-icon
|
|
74
|
+
library="fa-pro-medical"
|
|
75
|
+
name="stethoscope"
|
|
76
|
+
allowed-origins="https://kit.fontawesome.com"
|
|
77
|
+
></hx-icon>
|
|
69
78
|
```
|
|
70
79
|
|
|
71
80
|
## Tree-shake imports
|
|
@@ -89,16 +98,20 @@ glyphs are painted:
|
|
|
89
98
|
- `'stroke'` — outline glyphs (e.g. Lucide, Phosphor Thin)
|
|
90
99
|
- `'mixed'` — per-glyph fill + stroke (e.g. Phosphor Duotone)
|
|
91
100
|
|
|
92
|
-
The
|
|
93
|
-
|
|
94
|
-
|
|
101
|
+
The formal AAA contrast harness measures rendered `<hx-icon>` color/background samples on the
|
|
102
|
+
audit story and records the verdict in `packages/hx-library/aaa-verdicts.json`. `paintMode`
|
|
103
|
+
is a registry hint that drives how a library's glyphs are painted (and how third-party
|
|
104
|
+
tooling can reason about them); the cert verdict itself comes from the rendered measurement,
|
|
105
|
+
not from `paintMode` dispatch.
|
|
95
106
|
|
|
96
107
|
## Attribution
|
|
97
108
|
|
|
98
109
|
Bundled icon libraries carry their own licenses. **Font Awesome Free Solid
|
|
99
110
|
icons are licensed under CC BY 4.0; attribution is required.** See
|
|
100
|
-
[`NOTICE.md`](./NOTICE.md) for the canonical attribution text
|
|
101
|
-
|
|
111
|
+
[`NOTICE.md`](./NOTICE.md) for the canonical attribution text covering the
|
|
112
|
+
bundled libraries (the file is an attribution / license disclosure, not an
|
|
113
|
+
asset-level inventory — see the `helix` / `fa-free` library directories
|
|
114
|
+
under `dist/` for the actual glyph filenames).
|
|
102
115
|
|
|
103
116
|
## License
|
|
104
117
|
|
package/package.json
CHANGED