@lilydesignsystem/react-headless-identifiers 0.0.0-stage → 0.1.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 +10 -0
- package/LICENSE.md +64 -0
- package/README.md +30 -2
- package/dist/index.d.ts +2139 -0
- package/dist/index.js +4699 -0
- package/index.md +31 -0
- package/package.json +80 -4
package/index.md
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Lily Design System™ React 19 headless identifiers
|
|
2
|
+
|
|
3
|
+
`@lilydesignsystem/react-headless-identifiers`: the 164 national personal identifier components of the Lily Design System catalog for React 19, an `-input` and
|
|
4
|
+
a `-view` for each of 82 identifier types across more than 50 countries (health numbers, national identity numbers, tax
|
|
5
|
+
numbers, passports). It is the add-on to [`@lilydesignsystem/react-headless`](../lily-design-system-react-headless/), which
|
|
6
|
+
has the other 473 components.
|
|
7
|
+
|
|
8
|
+
```sh
|
|
9
|
+
pnpm add @lilydesignsystem/react-headless-identifiers
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
```tsx
|
|
13
|
+
import { UnitedKingdomNationalHealthServiceNumberInput } from "@lilydesignsystem/react-headless-identifiers";
|
|
14
|
+
|
|
15
|
+
<UnitedKingdomNationalHealthServiceNumberInput
|
|
16
|
+
label="NHS number"
|
|
17
|
+
value={nhs}
|
|
18
|
+
onChange={setNhs}
|
|
19
|
+
/>;
|
|
20
|
+
```
|
|
21
|
+
|
|
22
|
+
Like the headless library it is unstyled: semantic HTML, ARIA and behaviour only. Each input renders
|
|
23
|
+
`autocomplete="off"` and `spellcheck="false"`, so the browser neither saves the value nor sends it to a spellchecker.
|
|
24
|
+
The formats, normalisation and validation rules are in [spec/national-identifiers](../spec/national-identifiers/index.md).
|
|
25
|
+
|
|
26
|
+
Why a separate package: [spec/headless-identifiers](../spec/headless-identifiers/index.md). Spec:
|
|
27
|
+
[spec/index.md](spec/index.md). Agents: [AGENTS.md](AGENTS.md).
|
|
28
|
+
|
|
29
|
+
---
|
|
30
|
+
|
|
31
|
+
Lily™ and Lily Design System™ are trademarks.
|
package/package.json
CHANGED
|
@@ -1,6 +1,82 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lilydesignsystem/react-headless-identifiers",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
|
|
6
|
-
}
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"engines": {
|
|
5
|
+
"node": ">=26"
|
|
6
|
+
},
|
|
7
|
+
"description": "Headless, accessible, unstyled React 19 components for national personal identifiers (164: an input and a view for each of 82 identifier types across 50+ countries), the add-on to @lilydesignsystem/react-headless.",
|
|
8
|
+
"main": "./dist/index.js",
|
|
9
|
+
"scripts": {
|
|
10
|
+
"build": "node build.mjs",
|
|
11
|
+
"prepublishOnly": "node build.mjs",
|
|
12
|
+
"test": "vitest run",
|
|
13
|
+
"test:ui": "vitest --ui",
|
|
14
|
+
"test:watch": "vitest",
|
|
15
|
+
"storybook": "storybook dev -p 6006",
|
|
16
|
+
"build-storybook": "storybook build",
|
|
17
|
+
"check": "tsc --noEmit"
|
|
18
|
+
},
|
|
19
|
+
"repository": {
|
|
20
|
+
"type": "git",
|
|
21
|
+
"url": "git+https://github.com/LilyDesignSystem/lily-design-system.git",
|
|
22
|
+
"directory": "lily-design-system-react-headless-identifiers"
|
|
23
|
+
},
|
|
24
|
+
"keywords": [
|
|
25
|
+
"react",
|
|
26
|
+
"headless",
|
|
27
|
+
"design-system",
|
|
28
|
+
"components",
|
|
29
|
+
"accessible",
|
|
30
|
+
"wcag",
|
|
31
|
+
"aria",
|
|
32
|
+
"a11y",
|
|
33
|
+
"unstyled",
|
|
34
|
+
"typescript",
|
|
35
|
+
"national-identifier",
|
|
36
|
+
"healthcare"
|
|
37
|
+
],
|
|
38
|
+
"author": "Joel Parker Henderson <joel@joelparkerhenderson.com>",
|
|
39
|
+
"license": "MIT OR Apache-2.0 OR GPL-2.0-only OR GPL-3.0-only OR BSD-3-Clause",
|
|
40
|
+
"bugs": {
|
|
41
|
+
"url": "https://github.com/LilyDesignSystem/lily-design-system/issues"
|
|
42
|
+
},
|
|
43
|
+
"homepage": "https://lilydesignsystem.com/",
|
|
44
|
+
"devDependencies": {
|
|
45
|
+
"@storybook/react-vite": "^10.6.7",
|
|
46
|
+
"@testing-library/react": "^16.3.3",
|
|
47
|
+
"@testing-library/user-event": "^14.6.11",
|
|
48
|
+
"@types/node": "^26.6.6",
|
|
49
|
+
"@types/react": "^19.3.0",
|
|
50
|
+
"@types/react-dom": "^19.3.0",
|
|
51
|
+
"@vitejs/plugin-react": "^6.3.0",
|
|
52
|
+
"@vitest/ui": "^5.1.0",
|
|
53
|
+
"jsdom": "^31.0.1",
|
|
54
|
+
"react": "^19.3.1",
|
|
55
|
+
"react-dom": "^19.3.1",
|
|
56
|
+
"storybook": "^10.6.7",
|
|
57
|
+
"tsup": "^9.0.0",
|
|
58
|
+
"typescript": "^5.9.3",
|
|
59
|
+
"vitest": "^5.1.0"
|
|
60
|
+
},
|
|
61
|
+
"peerDependencies": {
|
|
62
|
+
"react": "^18.0.0 || ^19.0.0",
|
|
63
|
+
"react-dom": "^18.0.0 || ^19.0.0"
|
|
64
|
+
},
|
|
65
|
+
"type": "module",
|
|
66
|
+
"module": "./dist/index.js",
|
|
67
|
+
"types": "./dist/index.d.ts",
|
|
68
|
+
"exports": {
|
|
69
|
+
".": {
|
|
70
|
+
"types": "./dist/index.d.ts",
|
|
71
|
+
"import": "./dist/index.js",
|
|
72
|
+
"default": "./dist/index.js"
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"files": [
|
|
76
|
+
"dist",
|
|
77
|
+
"index.md",
|
|
78
|
+
"README.md",
|
|
79
|
+
"CHANGELOG.md"
|
|
80
|
+
],
|
|
81
|
+
"sideEffects": false
|
|
82
|
+
}
|