twntyx-css 1.0.0 → 1.0.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 +16 -1
- package/fonts/GazpachoBold.otf +0 -0
- package/fonts/GazpachoBoldItalic.otf +0 -0
- package/fonts/GazpachoMedium.otf +0 -0
- package/fonts/GazpachoMediumItalic.otf +0 -0
- package/fonts/GazpachoRegular.otf +0 -0
- package/fonts/GazpachoRegularItalic.otf +0 -0
- package/fonts/GeistMonoVF.woff +0 -0
- package/fonts/GeistVF.woff +0 -0
- package/fonts/InstrumentSans-Italic-VariableFont_wdth,wght.ttf +0 -0
- package/fonts/InstrumentSans-VariableFont_wdth,wght.ttf +0 -0
- package/llm/assistants/README.md +28 -0
- package/llm/assistants/claude/CLAUDE.md +48 -0
- package/llm/assistants/codex/AGENTS.md +48 -0
- package/llm/components/chat-ai.json +89 -0
- package/llm/components/chat-footer.json +99 -0
- package/llm/components/chat-person-to-person.json +157 -0
- package/llm/components/chat.json +11 -80
- package/llm/components/demo.json +88 -0
- package/llm/components/getting-started.json +14 -5
- package/llm/components/icons-reference.json +1 -1
- package/llm/components/loader.json +2 -1
- package/llm/components/menu.json +10 -0
- package/llm/components/popover.json +2 -4
- package/llm/examples/chat-ai.html +1 -0
- package/llm/examples/chat-footer.html +1 -0
- package/llm/examples/chat-person-to-person.html +1 -0
- package/llm/examples/chat.html +1 -1
- package/llm/examples/demo.html +1 -0
- package/llm/examples/getting-started.html +1 -1
- package/llm/index.json +84 -11
- package/llm/llms.txt +3 -0
- package/package.json +3 -1
- package/styles/button.css +3 -6
- package/styles/chat.css +207 -0
- package/styles/font.css +59 -0
- package/styles/globals.css +1 -0
- package/styles/loader.css +8 -0
- package/styles/popover.css +1 -37
- package/styles/typography.css +0 -56
package/README.md
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-

|
|
2
2
|
|
|
3
3
|
👉 A **CSS Framework** built on [Tailwind CSS](https://www.npmjs.com/package/tailwindcss) to bring consistency and speed to **twntyX products**.
|
|
4
4
|
|
|
@@ -86,6 +86,21 @@ Available machine-readable exports:
|
|
|
86
86
|
|
|
87
87
|
Maintenance workflow for keeping this metadata current lives in `LLM_MAINTENANCE.md`.
|
|
88
88
|
|
|
89
|
+
## Assistant guides (Codex + Claude, no skills)
|
|
90
|
+
|
|
91
|
+
The package also includes tool-native guidance files that tell coding assistants to use the canonical `twntyx-css/llm/*` metadata contract.
|
|
92
|
+
|
|
93
|
+
- `node_modules/twntyx-css/llm/assistants/codex/AGENTS.md`
|
|
94
|
+
- `node_modules/twntyx-css/llm/assistants/claude/CLAUDE.md`
|
|
95
|
+
- `node_modules/twntyx-css/llm/assistants/README.md`
|
|
96
|
+
|
|
97
|
+
Copy into your consumer repo:
|
|
98
|
+
|
|
99
|
+
```bash
|
|
100
|
+
cp node_modules/twntyx-css/llm/assistants/codex/AGENTS.md ./AGENTS.md
|
|
101
|
+
cp node_modules/twntyx-css/llm/assistants/claude/CLAUDE.md ./CLAUDE.md
|
|
102
|
+
```
|
|
103
|
+
|
|
89
104
|
## Publishing
|
|
90
105
|
|
|
91
106
|
From the repository root:
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
# Assistant Guides (No Skills)
|
|
2
|
+
|
|
3
|
+
Use these templates to configure Codex and Claude Code to follow the canonical twntyx-css metadata contract.
|
|
4
|
+
|
|
5
|
+
## Available Templates
|
|
6
|
+
- `./codex/AGENTS.md`
|
|
7
|
+
- `./claude/CLAUDE.md`
|
|
8
|
+
|
|
9
|
+
## Copy Into a Consumer Repo
|
|
10
|
+
Codex:
|
|
11
|
+
```bash
|
|
12
|
+
cp node_modules/twntyx-css/llm/assistants/codex/AGENTS.md ./AGENTS.md
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Claude Code:
|
|
16
|
+
```bash
|
|
17
|
+
cp node_modules/twntyx-css/llm/assistants/claude/CLAUDE.md ./CLAUDE.md
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Canonical Package Metadata Paths
|
|
21
|
+
- `node_modules/twntyx-css/llm/index.json`
|
|
22
|
+
- `node_modules/twntyx-css/llm/rules.json`
|
|
23
|
+
- `node_modules/twntyx-css/llm/components/<id>.json`
|
|
24
|
+
- `node_modules/twntyx-css/llm/tokens.json`
|
|
25
|
+
- `node_modules/twntyx-css/llm/patterns.json`
|
|
26
|
+
- `node_modules/twntyx-css/llm/schema.json`
|
|
27
|
+
|
|
28
|
+
No skills are required for this setup.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# twntyx-css Metadata Contract (Claude Code, No Skills)
|
|
2
|
+
|
|
3
|
+
Generated from `twntyx-css/llm/index.json` and `twntyx-css/llm/rules.json`. Do not hand-edit.
|
|
4
|
+
|
|
5
|
+
Use the installed package metadata as the single source of truth:
|
|
6
|
+
|
|
7
|
+
- `node_modules/twntyx-css/llm/index.json`
|
|
8
|
+
- `node_modules/twntyx-css/llm/rules.json`
|
|
9
|
+
- `node_modules/twntyx-css/llm/components/<id>.json`
|
|
10
|
+
- `node_modules/twntyx-css/llm/tokens.json`
|
|
11
|
+
- `node_modules/twntyx-css/llm/patterns.json`
|
|
12
|
+
- `node_modules/twntyx-css/llm/schema.json`
|
|
13
|
+
|
|
14
|
+
Programmatic import paths:
|
|
15
|
+
- `twntyx-css/llm`
|
|
16
|
+
- `twntyx-css/llm/components/<id>.json`
|
|
17
|
+
- `twntyx-css/llm/tokens`
|
|
18
|
+
- `twntyx-css/llm/patterns`
|
|
19
|
+
- `twntyx-css/llm/rules`
|
|
20
|
+
|
|
21
|
+
## Component Lookup Workflow
|
|
22
|
+
1. Load `twntyx-css/llm` (`index.json`).
|
|
23
|
+
2. Resolve component using priority: `id -> name -> keywords`.
|
|
24
|
+
3. Load `twntyx-css/llm/components/<id>.json`.
|
|
25
|
+
4. Generate minimal valid HTML first, then layer only documented variants/sizes/states.
|
|
26
|
+
5. Enforce `a11y`, `dos`, `donts`, and `tokenUsage` exactly.
|
|
27
|
+
|
|
28
|
+
## Unknown Component Contract
|
|
29
|
+
If no supported component matches, return:
|
|
30
|
+
- `code`: `UNSUPPORTED_COMPONENT`
|
|
31
|
+
- `message`: "The requested component is not part of this design-system contract. Use index.json to find the nearest supported component."
|
|
32
|
+
- `suggestedActions`: use `queryBehavior.unsupportedComponent.suggestedActions` from `twntyx-css/llm`.
|
|
33
|
+
|
|
34
|
+
## Hard Constraints
|
|
35
|
+
Do:
|
|
36
|
+
- Use component base classes exactly as documented in component metadata.
|
|
37
|
+
- Prefer semantic token classes (`text-*`, `bg-*`, `line-*`) for color intent.
|
|
38
|
+
- Generate minimal valid HTML before layering variants and states.
|
|
39
|
+
|
|
40
|
+
Don't:
|
|
41
|
+
- Do not invent undocumented classes or variant names.
|
|
42
|
+
- Do not remove accessibility attributes from interactive elements.
|
|
43
|
+
- Do not mix conflicting state classes on one root element.
|
|
44
|
+
|
|
45
|
+
## Output Requirements
|
|
46
|
+
- Never invent classes, variants, attributes, roles, or ARIA requirements.
|
|
47
|
+
- Prefer stable components when multiple matches are possible.
|
|
48
|
+
- Include a short compliance note that cites critical a11y and token decisions.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# twntyx-css Metadata Contract (Codex, No Skills)
|
|
2
|
+
|
|
3
|
+
Generated from `twntyx-css/llm/index.json` and `twntyx-css/llm/rules.json`. Do not hand-edit.
|
|
4
|
+
|
|
5
|
+
Use the installed package metadata as the single source of truth:
|
|
6
|
+
|
|
7
|
+
- `node_modules/twntyx-css/llm/index.json`
|
|
8
|
+
- `node_modules/twntyx-css/llm/rules.json`
|
|
9
|
+
- `node_modules/twntyx-css/llm/components/<id>.json`
|
|
10
|
+
- `node_modules/twntyx-css/llm/tokens.json`
|
|
11
|
+
- `node_modules/twntyx-css/llm/patterns.json`
|
|
12
|
+
- `node_modules/twntyx-css/llm/schema.json`
|
|
13
|
+
|
|
14
|
+
Programmatic import paths:
|
|
15
|
+
- `twntyx-css/llm`
|
|
16
|
+
- `twntyx-css/llm/components/<id>.json`
|
|
17
|
+
- `twntyx-css/llm/tokens`
|
|
18
|
+
- `twntyx-css/llm/patterns`
|
|
19
|
+
- `twntyx-css/llm/rules`
|
|
20
|
+
|
|
21
|
+
## Component Lookup Workflow
|
|
22
|
+
1. Load `twntyx-css/llm` (`index.json`).
|
|
23
|
+
2. Resolve component using priority: `id -> name -> keywords`.
|
|
24
|
+
3. Load `twntyx-css/llm/components/<id>.json`.
|
|
25
|
+
4. Generate minimal valid HTML first, then layer only documented variants/sizes/states.
|
|
26
|
+
5. Enforce `a11y`, `dos`, `donts`, and `tokenUsage` exactly.
|
|
27
|
+
|
|
28
|
+
## Unknown Component Contract
|
|
29
|
+
If no supported component matches, return:
|
|
30
|
+
- `code`: `UNSUPPORTED_COMPONENT`
|
|
31
|
+
- `message`: "The requested component is not part of this design-system contract. Use index.json to find the nearest supported component."
|
|
32
|
+
- `suggestedActions`: use `queryBehavior.unsupportedComponent.suggestedActions` from `twntyx-css/llm`.
|
|
33
|
+
|
|
34
|
+
## Hard Constraints
|
|
35
|
+
Do:
|
|
36
|
+
- Use component base classes exactly as documented in component metadata.
|
|
37
|
+
- Prefer semantic token classes (`text-*`, `bg-*`, `line-*`) for color intent.
|
|
38
|
+
- Generate minimal valid HTML before layering variants and states.
|
|
39
|
+
|
|
40
|
+
Don't:
|
|
41
|
+
- Do not invent undocumented classes or variant names.
|
|
42
|
+
- Do not remove accessibility attributes from interactive elements.
|
|
43
|
+
- Do not mix conflicting state classes on one root element.
|
|
44
|
+
|
|
45
|
+
## Output Requirements
|
|
46
|
+
- Never invent classes, variants, attributes, roles, or ARIA requirements.
|
|
47
|
+
- Prefer stable components when multiple matches are possible.
|
|
48
|
+
- Include a short compliance note that cites critical a11y and token decisions.
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "chat-ai",
|
|
3
|
+
"name": "AI chat structure",
|
|
4
|
+
"status": "stable",
|
|
5
|
+
"summary": "AI chat conversation patterns with text, media, MCP bubbles, loading, and assistant response loop simulations.",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"ai chat",
|
|
8
|
+
"assistant",
|
|
9
|
+
"chat",
|
|
10
|
+
"chat ai",
|
|
11
|
+
"chat-ai",
|
|
12
|
+
"chatbot",
|
|
13
|
+
"loading state",
|
|
14
|
+
"mcp fallback",
|
|
15
|
+
"mcp result",
|
|
16
|
+
"mcp tool action",
|
|
17
|
+
"new message state"
|
|
18
|
+
],
|
|
19
|
+
"sourcePaths": [
|
|
20
|
+
"app/design-system/chat-ai/page.js"
|
|
21
|
+
],
|
|
22
|
+
"apiModel": "html-class",
|
|
23
|
+
"baseClass": "chat-ai",
|
|
24
|
+
"variants": [],
|
|
25
|
+
"sizes": [],
|
|
26
|
+
"states": [],
|
|
27
|
+
"structure": {
|
|
28
|
+
"rootElement": "div",
|
|
29
|
+
"requiredClasses": [
|
|
30
|
+
"chat-ai"
|
|
31
|
+
],
|
|
32
|
+
"optionalClasses": [],
|
|
33
|
+
"requiredChildren": [],
|
|
34
|
+
"optionalChildren": []
|
|
35
|
+
},
|
|
36
|
+
"attributes": {
|
|
37
|
+
"allowed": [
|
|
38
|
+
"class"
|
|
39
|
+
],
|
|
40
|
+
"required": [],
|
|
41
|
+
"dataAttributes": [
|
|
42
|
+
"data-loading"
|
|
43
|
+
],
|
|
44
|
+
"roles": [
|
|
45
|
+
"status"
|
|
46
|
+
],
|
|
47
|
+
"aria": [
|
|
48
|
+
"aria-label"
|
|
49
|
+
]
|
|
50
|
+
},
|
|
51
|
+
"a11y": {
|
|
52
|
+
"interactive": false,
|
|
53
|
+
"requiredRoles": [
|
|
54
|
+
"status"
|
|
55
|
+
],
|
|
56
|
+
"requiredAria": [
|
|
57
|
+
"aria-label"
|
|
58
|
+
],
|
|
59
|
+
"keyboardSupport": [],
|
|
60
|
+
"focusBehavior": "No keyboard interaction is required unless nested interactive children are introduced."
|
|
61
|
+
},
|
|
62
|
+
"dos": [
|
|
63
|
+
"Apply the base class 'chat-ai' on the root element.",
|
|
64
|
+
"Use documented modifiers for visual variants instead of ad-hoc custom classes.",
|
|
65
|
+
"Keep semantic color usage aligned with token classes for light/dark support."
|
|
66
|
+
],
|
|
67
|
+
"donts": [
|
|
68
|
+
"Do not combine conflicting state classes on the same element.",
|
|
69
|
+
"Do not rely on undocumented internal classes in production templates.",
|
|
70
|
+
"Do not remove required accessibility attributes when component is interactive."
|
|
71
|
+
],
|
|
72
|
+
"tokenUsage": [],
|
|
73
|
+
"examples": [
|
|
74
|
+
{
|
|
75
|
+
"id": "canonical",
|
|
76
|
+
"file": "examples/chat-ai.html",
|
|
77
|
+
"description": "Minimal canonical AI chat structure usage."
|
|
78
|
+
}
|
|
79
|
+
],
|
|
80
|
+
"composition": {
|
|
81
|
+
"patterns": [],
|
|
82
|
+
"relatedComponents": [],
|
|
83
|
+
"notes": []
|
|
84
|
+
},
|
|
85
|
+
"breakingChangePolicy": {
|
|
86
|
+
"classContract": "Base class, documented modifiers, and state class names are semver-protected for consumer markup.",
|
|
87
|
+
"a11yContract": "Documented role and aria requirements are semver-protected for generated markup."
|
|
88
|
+
}
|
|
89
|
+
}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "chat-footer",
|
|
3
|
+
"name": "Chat footer",
|
|
4
|
+
"status": "stable",
|
|
5
|
+
"summary": "Chat composer/footer patterns including the current footer and a full variant with file upload trigger, model selector, and dictation simulation.",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"attachment",
|
|
8
|
+
"chat",
|
|
9
|
+
"chat footer",
|
|
10
|
+
"chat input",
|
|
11
|
+
"chat-footer",
|
|
12
|
+
"composer",
|
|
13
|
+
"dictation",
|
|
14
|
+
"footer",
|
|
15
|
+
"ghost select",
|
|
16
|
+
"model selector"
|
|
17
|
+
],
|
|
18
|
+
"sourcePaths": [
|
|
19
|
+
"app/design-system/chat-footer/page.js",
|
|
20
|
+
"assets/styles/chat.css",
|
|
21
|
+
"assets/styles/panel.css"
|
|
22
|
+
],
|
|
23
|
+
"apiModel": "html-class",
|
|
24
|
+
"baseClass": "chat-footer",
|
|
25
|
+
"variants": [],
|
|
26
|
+
"sizes": [],
|
|
27
|
+
"states": [],
|
|
28
|
+
"structure": {
|
|
29
|
+
"rootElement": "div",
|
|
30
|
+
"requiredClasses": [
|
|
31
|
+
"chat-footer"
|
|
32
|
+
],
|
|
33
|
+
"optionalClasses": [],
|
|
34
|
+
"requiredChildren": [],
|
|
35
|
+
"optionalChildren": []
|
|
36
|
+
},
|
|
37
|
+
"attributes": {
|
|
38
|
+
"allowed": [
|
|
39
|
+
"class"
|
|
40
|
+
],
|
|
41
|
+
"required": [],
|
|
42
|
+
"dataAttributes": [],
|
|
43
|
+
"roles": [],
|
|
44
|
+
"aria": [
|
|
45
|
+
"aria-label"
|
|
46
|
+
]
|
|
47
|
+
},
|
|
48
|
+
"a11y": {
|
|
49
|
+
"interactive": false,
|
|
50
|
+
"requiredRoles": [],
|
|
51
|
+
"requiredAria": [
|
|
52
|
+
"aria-label"
|
|
53
|
+
],
|
|
54
|
+
"keyboardSupport": [],
|
|
55
|
+
"focusBehavior": "No keyboard interaction is required unless nested interactive children are introduced."
|
|
56
|
+
},
|
|
57
|
+
"dos": [
|
|
58
|
+
"Apply the base class 'chat-footer' on the root element.",
|
|
59
|
+
"Use documented modifiers for visual variants instead of ad-hoc custom classes.",
|
|
60
|
+
"Keep semantic color usage aligned with token classes for light/dark support."
|
|
61
|
+
],
|
|
62
|
+
"donts": [
|
|
63
|
+
"Do not combine conflicting state classes on the same element.",
|
|
64
|
+
"Do not rely on undocumented internal classes in production templates.",
|
|
65
|
+
"Do not remove required accessibility attributes when component is interactive."
|
|
66
|
+
],
|
|
67
|
+
"tokenUsage": [
|
|
68
|
+
"background-error",
|
|
69
|
+
"background-page",
|
|
70
|
+
"background-surface",
|
|
71
|
+
"background-surface-elevated",
|
|
72
|
+
"background-surface-sunken",
|
|
73
|
+
"core-black",
|
|
74
|
+
"core-white",
|
|
75
|
+
"line-default",
|
|
76
|
+
"line-strong",
|
|
77
|
+
"text-default",
|
|
78
|
+
"text-link",
|
|
79
|
+
"text-link-hover",
|
|
80
|
+
"text-secondary",
|
|
81
|
+
"text-tertiary"
|
|
82
|
+
],
|
|
83
|
+
"examples": [
|
|
84
|
+
{
|
|
85
|
+
"id": "canonical",
|
|
86
|
+
"file": "examples/chat-footer.html",
|
|
87
|
+
"description": "Minimal canonical Chat footer usage."
|
|
88
|
+
}
|
|
89
|
+
],
|
|
90
|
+
"composition": {
|
|
91
|
+
"patterns": [],
|
|
92
|
+
"relatedComponents": [],
|
|
93
|
+
"notes": []
|
|
94
|
+
},
|
|
95
|
+
"breakingChangePolicy": {
|
|
96
|
+
"classContract": "Base class, documented modifiers, and state class names are semver-protected for consumer markup.",
|
|
97
|
+
"a11yContract": "Documented role and aria requirements are semver-protected for generated markup."
|
|
98
|
+
}
|
|
99
|
+
}
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "chat-person-to-person",
|
|
3
|
+
"name": "Person to person chat structure",
|
|
4
|
+
"status": "stable",
|
|
5
|
+
"summary": "Conversation patterns between people, including text, image attachments, MCP content, loading and new-message simulation states.",
|
|
6
|
+
"keywords": [
|
|
7
|
+
"chat",
|
|
8
|
+
"chat person to person",
|
|
9
|
+
"chat structure",
|
|
10
|
+
"chat-person-to-person",
|
|
11
|
+
"conversation",
|
|
12
|
+
"human chat",
|
|
13
|
+
"loading state",
|
|
14
|
+
"mcp",
|
|
15
|
+
"message attachments",
|
|
16
|
+
"messages",
|
|
17
|
+
"person to person"
|
|
18
|
+
],
|
|
19
|
+
"sourcePaths": [
|
|
20
|
+
"app/design-system/chat-person-to-person/page.js",
|
|
21
|
+
"assets/styles/button.css",
|
|
22
|
+
"assets/styles/chat.css",
|
|
23
|
+
"assets/styles/form-text-select.css",
|
|
24
|
+
"assets/styles/panel.css",
|
|
25
|
+
"assets/styles/toast.css"
|
|
26
|
+
],
|
|
27
|
+
"apiModel": "html-class",
|
|
28
|
+
"baseClass": "chat",
|
|
29
|
+
"variants": [],
|
|
30
|
+
"sizes": [],
|
|
31
|
+
"states": [
|
|
32
|
+
{
|
|
33
|
+
"name": "is-owner",
|
|
34
|
+
"className": "is-owner",
|
|
35
|
+
"description": "Indicates messages from the current user"
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"name": "is-loading",
|
|
39
|
+
"className": "is-loading",
|
|
40
|
+
"description": "Loading state that reveals"
|
|
41
|
+
}
|
|
42
|
+
],
|
|
43
|
+
"structure": {
|
|
44
|
+
"rootElement": "div",
|
|
45
|
+
"requiredClasses": [
|
|
46
|
+
"chat"
|
|
47
|
+
],
|
|
48
|
+
"optionalClasses": [
|
|
49
|
+
"is-owner",
|
|
50
|
+
"is-loading"
|
|
51
|
+
],
|
|
52
|
+
"requiredChildren": [],
|
|
53
|
+
"optionalChildren": []
|
|
54
|
+
},
|
|
55
|
+
"attributes": {
|
|
56
|
+
"allowed": [
|
|
57
|
+
"class"
|
|
58
|
+
],
|
|
59
|
+
"required": [],
|
|
60
|
+
"dataAttributes": [
|
|
61
|
+
"data-loading"
|
|
62
|
+
],
|
|
63
|
+
"roles": [
|
|
64
|
+
"status"
|
|
65
|
+
],
|
|
66
|
+
"aria": [
|
|
67
|
+
"aria-label"
|
|
68
|
+
]
|
|
69
|
+
},
|
|
70
|
+
"a11y": {
|
|
71
|
+
"interactive": false,
|
|
72
|
+
"requiredRoles": [
|
|
73
|
+
"status"
|
|
74
|
+
],
|
|
75
|
+
"requiredAria": [
|
|
76
|
+
"aria-label"
|
|
77
|
+
],
|
|
78
|
+
"keyboardSupport": [],
|
|
79
|
+
"focusBehavior": "No keyboard interaction is required unless nested interactive children are introduced."
|
|
80
|
+
},
|
|
81
|
+
"dos": [
|
|
82
|
+
"Apply the base class 'chat' on the root element.",
|
|
83
|
+
"Use documented modifiers for visual variants instead of ad-hoc custom classes.",
|
|
84
|
+
"Keep semantic color usage aligned with token classes for light/dark support."
|
|
85
|
+
],
|
|
86
|
+
"donts": [
|
|
87
|
+
"Do not combine conflicting state classes on the same element.",
|
|
88
|
+
"Do not rely on undocumented internal classes in production templates.",
|
|
89
|
+
"Do not remove required accessibility attributes when component is interactive."
|
|
90
|
+
],
|
|
91
|
+
"tokenUsage": [
|
|
92
|
+
"background-brand",
|
|
93
|
+
"background-brand-active",
|
|
94
|
+
"background-error",
|
|
95
|
+
"background-error-active",
|
|
96
|
+
"background-info",
|
|
97
|
+
"background-info-active",
|
|
98
|
+
"background-inverted",
|
|
99
|
+
"background-page",
|
|
100
|
+
"background-success",
|
|
101
|
+
"background-success-active",
|
|
102
|
+
"background-surface",
|
|
103
|
+
"background-surface-elevated",
|
|
104
|
+
"background-surface-sunken",
|
|
105
|
+
"background-warning",
|
|
106
|
+
"background-warning-active",
|
|
107
|
+
"brand-default",
|
|
108
|
+
"brand-moderate",
|
|
109
|
+
"brand-strong",
|
|
110
|
+
"core-black",
|
|
111
|
+
"core-ui-100",
|
|
112
|
+
"core-ui-50",
|
|
113
|
+
"core-ui-700",
|
|
114
|
+
"core-ui-800",
|
|
115
|
+
"core-ui-900",
|
|
116
|
+
"core-white",
|
|
117
|
+
"line-default",
|
|
118
|
+
"line-error",
|
|
119
|
+
"line-focus",
|
|
120
|
+
"line-highlight",
|
|
121
|
+
"line-info",
|
|
122
|
+
"line-strong",
|
|
123
|
+
"line-success",
|
|
124
|
+
"line-warning",
|
|
125
|
+
"text-attention",
|
|
126
|
+
"text-brand",
|
|
127
|
+
"text-brand-active",
|
|
128
|
+
"text-brand-hover",
|
|
129
|
+
"text-default",
|
|
130
|
+
"text-disabled",
|
|
131
|
+
"text-error",
|
|
132
|
+
"text-info",
|
|
133
|
+
"text-inverted",
|
|
134
|
+
"text-link",
|
|
135
|
+
"text-link-hover",
|
|
136
|
+
"text-secondary",
|
|
137
|
+
"text-success",
|
|
138
|
+
"text-tertiary",
|
|
139
|
+
"text-warning"
|
|
140
|
+
],
|
|
141
|
+
"examples": [
|
|
142
|
+
{
|
|
143
|
+
"id": "canonical",
|
|
144
|
+
"file": "examples/chat-person-to-person.html",
|
|
145
|
+
"description": "Minimal canonical Person to person chat structure usage."
|
|
146
|
+
}
|
|
147
|
+
],
|
|
148
|
+
"composition": {
|
|
149
|
+
"patterns": [],
|
|
150
|
+
"relatedComponents": [],
|
|
151
|
+
"notes": []
|
|
152
|
+
},
|
|
153
|
+
"breakingChangePolicy": {
|
|
154
|
+
"classContract": "Base class, documented modifiers, and state class names are semver-protected for consumer markup.",
|
|
155
|
+
"a11yContract": "Documented role and aria requirements are semver-protected for generated markup."
|
|
156
|
+
}
|
|
157
|
+
}
|
package/llm/components/chat.json
CHANGED
|
@@ -1,56 +1,27 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "chat",
|
|
3
3
|
"name": "Chat",
|
|
4
|
-
"status": "
|
|
5
|
-
"summary": "
|
|
4
|
+
"status": "preview",
|
|
5
|
+
"summary": "Documentation and contract metadata for Chat in the twntyX design system.",
|
|
6
6
|
"keywords": [
|
|
7
|
-
"
|
|
8
|
-
"chat",
|
|
9
|
-
"chatbot",
|
|
10
|
-
"communication",
|
|
11
|
-
"conversation",
|
|
12
|
-
"messages"
|
|
7
|
+
"chat"
|
|
13
8
|
],
|
|
14
9
|
"sourcePaths": [
|
|
15
10
|
"app/design-system/chat/page.js",
|
|
16
|
-
"assets/styles/button.css",
|
|
17
11
|
"assets/styles/chat.css",
|
|
18
|
-
"assets/styles/
|
|
19
|
-
"assets/styles/panel.css",
|
|
20
|
-
"assets/styles/toast.css"
|
|
12
|
+
"assets/styles/panel.css"
|
|
21
13
|
],
|
|
22
14
|
"apiModel": "html-class",
|
|
23
15
|
"baseClass": "chat",
|
|
24
|
-
"variants": [
|
|
25
|
-
{
|
|
26
|
-
"name": "chat-secondary",
|
|
27
|
-
"className": "chat-secondary",
|
|
28
|
-
"description": "Alternative styling for AI chat"
|
|
29
|
-
}
|
|
30
|
-
],
|
|
16
|
+
"variants": [],
|
|
31
17
|
"sizes": [],
|
|
32
|
-
"states": [
|
|
33
|
-
{
|
|
34
|
-
"name": "is-owner",
|
|
35
|
-
"className": "is-owner",
|
|
36
|
-
"description": "Indicates messages from the current user"
|
|
37
|
-
},
|
|
38
|
-
{
|
|
39
|
-
"name": "is-loading",
|
|
40
|
-
"className": "is-loading",
|
|
41
|
-
"description": "Loading state that reveals"
|
|
42
|
-
}
|
|
43
|
-
],
|
|
18
|
+
"states": [],
|
|
44
19
|
"structure": {
|
|
45
20
|
"rootElement": "div",
|
|
46
21
|
"requiredClasses": [
|
|
47
22
|
"chat"
|
|
48
23
|
],
|
|
49
|
-
"optionalClasses": [
|
|
50
|
-
"chat-secondary",
|
|
51
|
-
"is-owner",
|
|
52
|
-
"is-loading"
|
|
53
|
-
],
|
|
24
|
+
"optionalClasses": [],
|
|
54
25
|
"requiredChildren": [],
|
|
55
26
|
"optionalChildren": []
|
|
56
27
|
},
|
|
@@ -59,19 +30,13 @@
|
|
|
59
30
|
"class"
|
|
60
31
|
],
|
|
61
32
|
"required": [],
|
|
62
|
-
"dataAttributes": [
|
|
63
|
-
|
|
64
|
-
],
|
|
65
|
-
"roles": [
|
|
66
|
-
"status"
|
|
67
|
-
],
|
|
33
|
+
"dataAttributes": [],
|
|
34
|
+
"roles": [],
|
|
68
35
|
"aria": []
|
|
69
36
|
},
|
|
70
37
|
"a11y": {
|
|
71
38
|
"interactive": false,
|
|
72
|
-
"requiredRoles": [
|
|
73
|
-
"status"
|
|
74
|
-
],
|
|
39
|
+
"requiredRoles": [],
|
|
75
40
|
"requiredAria": [],
|
|
76
41
|
"keyboardSupport": [],
|
|
77
42
|
"focusBehavior": "No keyboard interaction is required unless nested interactive children are introduced."
|
|
@@ -87,54 +52,20 @@
|
|
|
87
52
|
"Do not remove required accessibility attributes when component is interactive."
|
|
88
53
|
],
|
|
89
54
|
"tokenUsage": [
|
|
90
|
-
"background-brand",
|
|
91
|
-
"background-brand-active",
|
|
92
55
|
"background-error",
|
|
93
|
-
"background-error-active",
|
|
94
|
-
"background-info",
|
|
95
|
-
"background-info-active",
|
|
96
|
-
"background-inverted",
|
|
97
56
|
"background-page",
|
|
98
|
-
"background-success",
|
|
99
|
-
"background-success-active",
|
|
100
57
|
"background-surface",
|
|
101
58
|
"background-surface-elevated",
|
|
102
59
|
"background-surface-sunken",
|
|
103
|
-
"background-warning",
|
|
104
|
-
"background-warning-active",
|
|
105
|
-
"brand-default",
|
|
106
|
-
"brand-moderate",
|
|
107
|
-
"brand-strong",
|
|
108
60
|
"core-black",
|
|
109
|
-
"core-ui-100",
|
|
110
|
-
"core-ui-50",
|
|
111
|
-
"core-ui-700",
|
|
112
|
-
"core-ui-800",
|
|
113
|
-
"core-ui-900",
|
|
114
61
|
"core-white",
|
|
115
62
|
"line-default",
|
|
116
|
-
"line-error",
|
|
117
|
-
"line-focus",
|
|
118
|
-
"line-highlight",
|
|
119
|
-
"line-info",
|
|
120
63
|
"line-strong",
|
|
121
|
-
"line-success",
|
|
122
|
-
"line-warning",
|
|
123
|
-
"text-attention",
|
|
124
|
-
"text-brand",
|
|
125
|
-
"text-brand-active",
|
|
126
|
-
"text-brand-hover",
|
|
127
64
|
"text-default",
|
|
128
|
-
"text-disabled",
|
|
129
|
-
"text-error",
|
|
130
|
-
"text-info",
|
|
131
|
-
"text-inverted",
|
|
132
65
|
"text-link",
|
|
133
66
|
"text-link-hover",
|
|
134
67
|
"text-secondary",
|
|
135
|
-
"text-
|
|
136
|
-
"text-tertiary",
|
|
137
|
-
"text-warning"
|
|
68
|
+
"text-tertiary"
|
|
138
69
|
],
|
|
139
70
|
"examples": [
|
|
140
71
|
{
|