@helvetia-design/react 0.0.6 → 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/README.md +10 -10
- package/dist/generated/components.server.js +2 -3
- package/dist/hooks/use-modal.js +6 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -46,7 +46,7 @@ Explore all available components, design tokens, and examples in the [component
|
|
|
46
46
|
|
|
47
47
|
## Contributing
|
|
48
48
|
|
|
49
|
-
We welcome contributions! Please read our [CONTRIBUTING.md](https://github.com/helvetia-design/system/blob/
|
|
49
|
+
We welcome contributions! Please read our [CONTRIBUTING.md](https://github.com/helvetia-design/system/blob/main/CONTRIBUTING.md) guide to learn about:
|
|
50
50
|
|
|
51
51
|
- Reporting bugs and requesting features
|
|
52
52
|
- Development setup and workflow
|
|
@@ -54,21 +54,21 @@ We welcome contributions! Please read our [CONTRIBUTING.md](https://github.com/h
|
|
|
54
54
|
- Testing and code quality standards
|
|
55
55
|
- Semantic versioning and changesets
|
|
56
56
|
|
|
57
|
-
Follow our [Code of Conduct](https://github.com/helvetia-design/system/blob/
|
|
57
|
+
Follow our [Code of Conduct](https://github.com/helvetia-design/system/blob/main/CODE_OF_CONDUCT.md) for all interactions.
|
|
58
58
|
|
|
59
59
|
## Learn More
|
|
60
60
|
|
|
61
61
|
- **[Documentation](https://helvetia-design.vercel.app)** — Component library, design tokens, and interactive examples in Storybook
|
|
62
62
|
- **[Quick Start](https://helvetia-design.vercel.app/?path=/docs/development-getting-started--documentation)** — Get started with the design system in your project
|
|
63
63
|
- **[llms.txt](https://helvetia-design.vercel.app/llms.txt)** / **[llms-full.txt](https://helvetia-design.vercel.app/llms-full.txt)** — Machine-readable component API and usage docs for AI coding tools ([llmstxt.org](https://llmstxt.org))
|
|
64
|
-
- **[CHANGELOG.md](https://github.com/helvetia-design/system/blob/
|
|
65
|
-
- **[ARCHITECTURE.md](https://github.com/helvetia-design/system/blob/
|
|
66
|
-
- **[DEVELOPMENT.md](https://github.com/helvetia-design/system/blob/
|
|
67
|
-
- **[CONTRIBUTING.md](https://github.com/helvetia-design/system/blob/
|
|
68
|
-
- **[STYLE_GUIDE.md](https://github.com/helvetia-design/system/blob/
|
|
69
|
-
- **[SECURITY.md](https://github.com/helvetia-design/system/blob/
|
|
70
|
-
- **[CODE_OF_CONDUCT.md](https://github.com/helvetia-design/system/blob/
|
|
64
|
+
- **[CHANGELOG.md](https://github.com/helvetia-design/system/blob/main/CHANGELOG.md)** — Release notes, version history, and changes for each version
|
|
65
|
+
- **[ARCHITECTURE.md](https://github.com/helvetia-design/system/blob/main/docs/ARCHITECTURE.md)** — System design, workspace structure, component lifecycle, web components patterns, CSS variables, testing strategy
|
|
66
|
+
- **[DEVELOPMENT.md](https://github.com/helvetia-design/system/blob/main/docs/DEVELOPMENT.md)** — Local setup, dev servers, building, testing, troubleshooting
|
|
67
|
+
- **[CONTRIBUTING.md](https://github.com/helvetia-design/system/blob/main/CONTRIBUTING.md)** — Contribution workflow, PR process, component checklist, accessibility requirements
|
|
68
|
+
- **[STYLE_GUIDE.md](https://github.com/helvetia-design/system/blob/main/docs/STYLE_GUIDE.md)** — Code standards, naming conventions, best practices
|
|
69
|
+
- **[SECURITY.md](https://github.com/helvetia-design/system/blob/main/SECURITY.md)** — Security policy, vulnerability reporting, and compliance guidelines
|
|
70
|
+
- **[CODE_OF_CONDUCT.md](https://github.com/helvetia-design/system/blob/main/CODE_OF_CONDUCT.md)** — Community standards and expectations
|
|
71
71
|
|
|
72
72
|
## License
|
|
73
73
|
|
|
74
|
-
This project is licensed under the Apache License 2.0. See [LICENSE](https://github.com/helvetia-design/system/blob/
|
|
74
|
+
This project is licensed under the Apache License 2.0. See [LICENSE](https://github.com/helvetia-design/system/blob/main/LICENSE) for details.
|
|
@@ -115,6 +115,7 @@ export const DsButton = /*@__PURE__*/ createComponent({
|
|
|
115
115
|
name: 'name',
|
|
116
116
|
value: 'value',
|
|
117
117
|
a11yControls: 'a-1-1y-controls',
|
|
118
|
+
a11yCurrent: 'a-1-1y-current',
|
|
118
119
|
a11yTitle: 'a-1-1y-title',
|
|
119
120
|
a11yLabel: 'a-1-1y-label',
|
|
120
121
|
a11yHaspopup: 'a-1-1y-haspopup'
|
|
@@ -179,8 +180,7 @@ export const DsCardSubtitle = /*@__PURE__*/ createComponent({
|
|
|
179
180
|
tagName: 'ds-card-subtitle',
|
|
180
181
|
properties: {
|
|
181
182
|
inverted: 'inverted',
|
|
182
|
-
bold: 'bold'
|
|
183
|
-
color: 'color'
|
|
183
|
+
bold: 'bold'
|
|
184
184
|
},
|
|
185
185
|
hydrateModule: typeof window === 'undefined' ? import('@helvetia-design/core/hydrate') : undefined,
|
|
186
186
|
clientModule: clientComponents.DsCardSubtitle,
|
|
@@ -453,7 +453,6 @@ export const DsHeading = /*@__PURE__*/ createComponent({
|
|
|
453
453
|
noWrap: 'no-wrap',
|
|
454
454
|
subtitle: 'subtitle',
|
|
455
455
|
space: 'space',
|
|
456
|
-
color: 'color',
|
|
457
456
|
inverted: 'inverted',
|
|
458
457
|
shadow: 'shadow'
|
|
459
458
|
},
|
package/dist/hooks/use-modal.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { dsModalController } from '@helvetia-design/core';
|
|
3
|
+
import { defineCustomElement as defineDsModal } from '@helvetia-design/core/components/ds-modal.js';
|
|
3
4
|
import { useCallback, useRef } from 'react';
|
|
4
5
|
import { flushSync } from 'react-dom';
|
|
5
6
|
import { createRoot } from 'react-dom/client';
|
|
@@ -8,6 +9,11 @@ import { createRoot } from 'react-dom/client';
|
|
|
8
9
|
* and hands it to the modal controller via `ModalOptions.component`.
|
|
9
10
|
*/
|
|
10
11
|
export function useModal() {
|
|
12
|
+
// `dsModalController.create()` builds the element with `document.createElement('ds-modal')`,
|
|
13
|
+
// which leaves it un-upgraded unless `ds-modal` is registered. Nothing else in this path
|
|
14
|
+
// registers it — an app that only ever presents modals imperatively never renders a `<Modal>`
|
|
15
|
+
// or `<DsModal>` wrapper — so the hook has to, the same way `useAlertController` does.
|
|
16
|
+
defineDsModal();
|
|
11
17
|
const modalRef = useRef(null);
|
|
12
18
|
const rootRef = useRef(null);
|
|
13
19
|
const containerRef = useRef(null);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@helvetia-design/react",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "The Helvetia Design System is an open source project for styling awesome web applications that follow the Helvetia corporate styling guidelines.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"react-dom": "^18.0.0 || ^19.0.0"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@helvetia-design/core": "0.0
|
|
37
|
+
"@helvetia-design/core": "0.1.0",
|
|
38
38
|
"@stencil/react-output-target": "1.6.5"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|