@hgdc/ui 0.17.1 → 0.17.2
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 +14 -14
- package/dist/email.js +1 -1
- package/dist/family-svg.d.ts +1 -1
- package/dist/family-svg.js +1 -1
- package/package.json +2 -2
- package/styles.css +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @hgdc/ui
|
|
2
2
|
|
|
3
|
-
Interface de la H
|
|
3
|
+
Interface de la H Collection : jetons de la DA, thèmes clair et sombre, polices, composants de base et coque des consoles, pour une application React 19 + Tailwind v4.
|
|
4
4
|
|
|
5
5
|
```sh
|
|
6
6
|
bun add @hgdc/ui
|
|
@@ -65,7 +65,7 @@ Une seule règle dans les sept produits, posée par la coque :
|
|
|
65
65
|
- **États vides** : `<Empty variant="card">` pour une page vide, icône monochrome (`EmptyMedia variant="icon"`), sans teinte de couleur.
|
|
66
66
|
- **Rôles et initiales** : `RoleBadge` (neutre), `MemberItem`, `initials`. Jamais une fonction d'initiales ou un badge de rôle dans un produit.
|
|
67
67
|
|
|
68
|
-
## Identité H
|
|
68
|
+
## Identité H Collection
|
|
69
69
|
|
|
70
70
|
| Import | Rôle |
|
|
71
71
|
| ------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
@@ -158,18 +158,18 @@ const { html, text } = await renderEmail(
|
|
|
158
158
|
)
|
|
159
159
|
```
|
|
160
160
|
|
|
161
|
-
| Bloc | Rôle
|
|
162
|
-
| -------------- |
|
|
163
|
-
| `EmailLayout` | Icône et nom du produit, carte, pied « Envoyé avec Mail de la H
|
|
164
|
-
| `EmailHeading` | Titre
|
|
165
|
-
| `EmailText` | Paragraphe ; `small` pour une note secondaire
|
|
166
|
-
| `EmailButton` | Lien direct, jamais réécrit ; absolu (`https:`, `mailto:`) ou erreur
|
|
167
|
-
| `EmailLink` | Lien dans le texte
|
|
168
|
-
| `EmailCode` | Code à usage unique, en deux groupes à l'œil, d'un bloc au copier
|
|
169
|
-
| `EmailCallout` | Encadré `neutral`, `info`, `success`, `warning`, `danger`, avec titre
|
|
170
|
-
| `EmailDivider` | Séparateur
|
|
171
|
-
| `EmailDetails` | Liste clé / valeur
|
|
172
|
-
| `renderEmail` | `{ html, text }` : HTML pour clients mail, texte tiré du même rendu
|
|
161
|
+
| Bloc | Rôle |
|
|
162
|
+
| -------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
163
|
+
| `EmailLayout` | Icône et nom du produit, carte, pied « Envoyé avec Mail de la H Collection » et mentions légales ; `footer` (désabonnement), `name`, `iconSrc`, `accent` |
|
|
164
|
+
| `EmailHeading` | Titre |
|
|
165
|
+
| `EmailText` | Paragraphe ; `small` pour une note secondaire |
|
|
166
|
+
| `EmailButton` | Lien direct, jamais réécrit ; absolu (`https:`, `mailto:`) ou erreur |
|
|
167
|
+
| `EmailLink` | Lien dans le texte |
|
|
168
|
+
| `EmailCode` | Code à usage unique, en deux groupes à l'œil, d'un bloc au copier |
|
|
169
|
+
| `EmailCallout` | Encadré `neutral`, `info`, `success`, `warning`, `danger`, avec titre |
|
|
170
|
+
| `EmailDivider` | Séparateur |
|
|
171
|
+
| `EmailDetails` | Liste clé / valeur |
|
|
172
|
+
| `renderEmail` | `{ html, text }` : HTML pour clients mail, texte tiré du même rendu |
|
|
173
173
|
|
|
174
174
|
L'accent vient du catalogue (`accent` de `@hgdc/ui/products`), les icônes de `https://hgdc.ch/email/<mot>.png` (fichiers dans `@hgdc/ui/email-icons/`, tirés des pastilles par `bun scripts/family.ts`). Un exemple par type : `scripts/email-showcase.tsx`.
|
|
175
175
|
|
package/dist/email.js
CHANGED
|
@@ -85,7 +85,7 @@ export function EmailLayout({ product: ref, preview, children, name, iconSrc, ac
|
|
|
85
85
|
border: `1px solid ${l.border}`,
|
|
86
86
|
borderRadius: 16,
|
|
87
87
|
padding: "32px 28px",
|
|
88
|
-
}, children: children }), _jsxs(Section, { style: { padding: "20px 4px 0" }, children: [footer ? (_jsx(Text, { className: "hg-muted", style: { ...muted, margin: "0 0 12px" }, children: footer })) : null, _jsxs(Text, { className: "hg-muted", style: muted, children: [_jsx(Img, { src: emailIconUrl("mail"), width: 16, height: 16, alt: "", style: { display: "inline-block", verticalAlign: "middle", borderRadius: 8, marginRight: 6 } }), _jsxs("span", { style: { verticalAlign: "middle" }, children: ["Envoy\u00E9 avec", " ", _jsx(Link, { href: MAIL_HREF, className: "hg-muted", style: { color: l.muted, textDecoration: "underline" }, children: "Mail de la H
|
|
88
|
+
}, children: children }), _jsxs(Section, { style: { padding: "20px 4px 0" }, children: [footer ? (_jsx(Text, { className: "hg-muted", style: { ...muted, margin: "0 0 12px" }, children: footer })) : null, _jsxs(Text, { className: "hg-muted", style: muted, children: [_jsx(Img, { src: emailIconUrl("mail"), width: 16, height: 16, alt: "", style: { display: "inline-block", verticalAlign: "middle", borderRadius: 8, marginRight: 6 } }), _jsxs("span", { style: { verticalAlign: "middle" }, children: ["Envoy\u00E9 avec", " ", _jsx(Link, { href: MAIL_HREF, className: "hg-muted", style: { color: l.muted, textDecoration: "underline" }, children: "Mail de la H Collection" })] })] }), _jsx(Text, { className: "hg-muted", style: { ...muted, margin: "4px 0 0" }, children: LEGAL })] })] }) }) })] }));
|
|
89
89
|
}
|
|
90
90
|
export function EmailHeading({ children }) {
|
|
91
91
|
return (_jsx(Heading, { as: "h1", className: "hg-ink hg-heading", style: { color: EMAIL_LIGHT.ink, fontSize: 22, fontWeight: 600, lineHeight: "28px", margin: "0 0 12px" }, children: children }));
|
package/dist/family-svg.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/** Les produits de la H
|
|
1
|
+
/** Les produits de la H Collection qui ont une pastille, par leur mot en minuscules. */
|
|
2
2
|
export declare const FAMILY_PRODUCTS: readonly ["account", "host", "mail", "portal", "status", "analytics", "docs"];
|
|
3
3
|
export type FamilyProduct = (typeof FAMILY_PRODUCTS)[number];
|
|
4
4
|
/** Vrai si le mot en minuscules (« host ») désigne un produit qui a une pastille. */
|
package/dist/family-svg.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// Généré par `bun scripts/family.ts` depuis `packages/ui/family/`. Ne pas modifier à la main.
|
|
2
|
-
/** Les produits de la H
|
|
2
|
+
/** Les produits de la H Collection qui ont une pastille, par leur mot en minuscules. */
|
|
3
3
|
export const FAMILY_PRODUCTS = ["account", "host", "mail", "portal", "status", "analytics", "docs"];
|
|
4
4
|
/** Vrai si le mot en minuscules (« host ») désigne un produit qui a une pastille. */
|
|
5
5
|
export function isFamilyProduct(word) {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hgdc/ui",
|
|
3
|
-
"version": "0.17.
|
|
4
|
-
"description": "Interface de la H
|
|
3
|
+
"version": "0.17.2",
|
|
4
|
+
"description": "Interface de la H Collection : jetons de la DA, thèmes, polices et composants.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"homepage": "https://github.com/hugogebel-boop/hgdc-kit/tree/main/packages/ui#readme",
|
|
7
7
|
"bugs": "https://github.com/hugogebel-boop/hgdc-kit/security/advisories/new",
|
package/styles.css
CHANGED
|
@@ -228,7 +228,7 @@
|
|
|
228
228
|
--inverse: oklch(0.1 0 0);
|
|
229
229
|
}
|
|
230
230
|
|
|
231
|
-
/* Identité H
|
|
231
|
+
/* Identité H Collection, la même en clair et en sombre. Dégradé de chaque pastille produit
|
|
232
232
|
(`ProductBadge`, `family/<mot>.svg`) et palette du H tricolore. Réservés aux visuels de marque
|
|
233
233
|
(pastille, carte de produit), jamais au chrome. Couleurs pleines ; pour éclaircir, mélanger au
|
|
234
234
|
blanc `in oklab`, jamais `in oklch` (la teinte du blanc s'y mêle, tout vire au rose). */
|