@tasteee/zest 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.
Files changed (142) hide show
  1. package/README.md +204 -0
  2. package/custom-elements.json +15982 -0
  3. package/dist/components/z-accordion.d.ts +13 -0
  4. package/dist/components/z-alert-dialog.d.ts +19 -0
  5. package/dist/components/z-alert.d.ts +19 -0
  6. package/dist/components/z-attachment-chip.d.ts +36 -0
  7. package/dist/components/z-attachment-tray.d.ts +32 -0
  8. package/dist/components/z-aura.d.ts +17 -0
  9. package/dist/components/z-avatar-stack.d.ts +15 -0
  10. package/dist/components/z-avatar.d.ts +28 -0
  11. package/dist/components/z-badge.d.ts +50 -0
  12. package/dist/components/z-bento-grid.d.ts +12 -0
  13. package/dist/components/z-bento-item.d.ts +13 -0
  14. package/dist/components/z-box.d.ts +130 -0
  15. package/dist/components/z-breadcrumbs.d.ts +23 -0
  16. package/dist/components/z-button-group.d.ts +9 -0
  17. package/dist/components/z-button.d.ts +35 -0
  18. package/dist/components/z-callout.d.ts +25 -0
  19. package/dist/components/z-card.d.ts +26 -0
  20. package/dist/components/z-carousel.d.ts +23 -0
  21. package/dist/components/z-center.d.ts +28 -0
  22. package/dist/components/z-chart.d.ts +29 -0
  23. package/dist/components/z-chassis.d.ts +33 -0
  24. package/dist/components/z-chat-header.d.ts +29 -0
  25. package/dist/components/z-chat-shell.d.ts +25 -0
  26. package/dist/components/z-checkbox.d.ts +39 -0
  27. package/dist/components/z-citation.d.ts +25 -0
  28. package/dist/components/z-cluster.d.ts +19 -0
  29. package/dist/components/z-code-block.d.ts +25 -0
  30. package/dist/components/z-collapsible.d.ts +30 -0
  31. package/dist/components/z-color-picker.d.ts +27 -0
  32. package/dist/components/z-combobox.d.ts +32 -0
  33. package/dist/components/z-command.d.ts +19 -0
  34. package/dist/components/z-composer.d.ts +35 -0
  35. package/dist/components/z-container.d.ts +15 -0
  36. package/dist/components/z-context-menu.d.ts +19 -0
  37. package/dist/components/z-conversation-item.d.ts +56 -0
  38. package/dist/components/z-conversation-list.d.ts +9 -0
  39. package/dist/components/z-date-divider.d.ts +13 -0
  40. package/dist/components/z-delivery-status.d.ts +13 -0
  41. package/dist/components/z-dialog.d.ts +33 -0
  42. package/dist/components/z-display.d.ts +22 -0
  43. package/dist/components/z-dock-item.d.ts +16 -0
  44. package/dist/components/z-dock.d.ts +17 -0
  45. package/dist/components/z-drag-drop.d.ts +63 -0
  46. package/dist/components/z-drawer.d.ts +25 -0
  47. package/dist/components/z-dropzone.d.ts +32 -0
  48. package/dist/components/z-editor-canvas.d.ts +90 -0
  49. package/dist/components/z-emoji-picker.d.ts +11 -0
  50. package/dist/components/z-empty-state.d.ts +19 -0
  51. package/dist/components/z-eyebrow.d.ts +22 -0
  52. package/dist/components/z-file-attachment.d.ts +25 -0
  53. package/dist/components/z-filter.d.ts +30 -0
  54. package/dist/components/z-grid.d.ts +19 -0
  55. package/dist/components/z-hover-card.d.ts +26 -0
  56. package/dist/components/z-image-message.d.ts +24 -0
  57. package/dist/components/z-input-otp.d.ts +43 -0
  58. package/dist/components/z-input.d.ts +56 -0
  59. package/dist/components/z-kbd.d.ts +14 -0
  60. package/dist/components/z-line.d.ts +13 -0
  61. package/dist/components/z-link.d.ts +36 -0
  62. package/dist/components/z-list-row.d.ts +13 -0
  63. package/dist/components/z-list.d.ts +14 -0
  64. package/dist/components/z-markdown.d.ts +34 -0
  65. package/dist/components/z-marquee.d.ts +27 -0
  66. package/dist/components/z-menu.d.ts +23 -0
  67. package/dist/components/z-message-actions.d.ts +31 -0
  68. package/dist/components/z-message-bubble.d.ts +21 -0
  69. package/dist/components/z-message-group.d.ts +41 -0
  70. package/dist/components/z-message-list.d.ts +20 -0
  71. package/dist/components/z-model-picker.d.ts +31 -0
  72. package/dist/components/z-nav-menu.d.ts +23 -0
  73. package/dist/components/z-pagination.d.ts +28 -0
  74. package/dist/components/z-panel.d.ts +33 -0
  75. package/dist/components/z-pattern-roll.d.ts +74 -0
  76. package/dist/components/z-piano-roll.d.ts +82 -0
  77. package/dist/components/z-pointer-follow.d.ts +18 -0
  78. package/dist/components/z-popover.d.ts +27 -0
  79. package/dist/components/z-post-meta.d.ts +14 -0
  80. package/dist/components/z-progress.d.ts +29 -0
  81. package/dist/components/z-progressive-blur.d.ts +19 -0
  82. package/dist/components/z-quoted-message.d.ts +32 -0
  83. package/dist/components/z-radio-group.d.ts +21 -0
  84. package/dist/components/z-radio.d.ts +25 -0
  85. package/dist/components/z-range-handle.d.ts +26 -0
  86. package/dist/components/z-range.d.ts +39 -0
  87. package/dist/components/z-reactions.d.ts +21 -0
  88. package/dist/components/z-read-receipt.d.ts +20 -0
  89. package/dist/components/z-relative-time.d.ts +25 -0
  90. package/dist/components/z-resizable-panels.d.ts +36 -0
  91. package/dist/components/z-scroll-area.d.ts +15 -0
  92. package/dist/components/z-scroll.d.ts +22 -0
  93. package/dist/components/z-section.d.ts +10 -0
  94. package/dist/components/z-select.d.ts +40 -0
  95. package/dist/components/z-send-button.d.ts +23 -0
  96. package/dist/components/z-separator.d.ts +14 -0
  97. package/dist/components/z-sheet.d.ts +33 -0
  98. package/dist/components/z-sidebar.d.ts +31 -0
  99. package/dist/components/z-skeleton.d.ts +23 -0
  100. package/dist/components/z-slider.d.ts +47 -0
  101. package/dist/components/z-sortable.d.ts +31 -0
  102. package/dist/components/z-sources.d.ts +24 -0
  103. package/dist/components/z-spacer.d.ts +10 -0
  104. package/dist/components/z-stack.d.ts +31 -0
  105. package/dist/components/z-stat.d.ts +37 -0
  106. package/dist/components/z-status-dot.d.ts +25 -0
  107. package/dist/components/z-streaming-text.d.ts +28 -0
  108. package/dist/components/z-suggestion-chips.d.ts +20 -0
  109. package/dist/components/z-surface.d.ts +37 -0
  110. package/dist/components/z-swap.d.ts +33 -0
  111. package/dist/components/z-switch.d.ts +35 -0
  112. package/dist/components/z-system-message.d.ts +13 -0
  113. package/dist/components/z-table.d.ts +32 -0
  114. package/dist/components/z-tabs.d.ts +27 -0
  115. package/dist/components/z-terminal.d.ts +48 -0
  116. package/dist/components/z-text.d.ts +166 -0
  117. package/dist/components/z-textarea.d.ts +54 -0
  118. package/dist/components/z-thinking.d.ts +28 -0
  119. package/dist/components/z-toast.d.ts +12 -0
  120. package/dist/components/z-toggle-group-item.d.ts +58 -0
  121. package/dist/components/z-toggle-group.d.ts +56 -0
  122. package/dist/components/z-toggle.d.ts +36 -0
  123. package/dist/components/z-tool-call.d.ts +31 -0
  124. package/dist/components/z-toolbar-group.d.ts +13 -0
  125. package/dist/components/z-toolbar.d.ts +21 -0
  126. package/dist/components/z-tooltip.d.ts +28 -0
  127. package/dist/components/z-tree.d.ts +50 -0
  128. package/dist/components/z-typing-indicator.d.ts +17 -0
  129. package/dist/components/z-unread-divider.d.ts +17 -0
  130. package/dist/components/z-virtual-list.d.ts +38 -0
  131. package/dist/index.d.ts +129 -0
  132. package/dist/ink.css +1 -0
  133. package/dist/shared/box-schema.d.ts +261 -0
  134. package/dist/shared/box-styles.d.ts +6 -0
  135. package/dist/shared/highlight.d.ts +6 -0
  136. package/dist/shared/layout-schema.d.ts +20 -0
  137. package/dist/shared/overlay-styles.d.ts +2 -0
  138. package/dist/shared/overlay.d.ts +50 -0
  139. package/dist/shared/toggle-schema.d.ts +52 -0
  140. package/dist/shared/toggle-styles.d.ts +12 -0
  141. package/dist/zest.js +24695 -0
  142. package/package.json +85 -0
package/README.md ADDED
@@ -0,0 +1,204 @@
1
+ # @tasteee/zest
2
+
3
+ > ⚠️ **Pre-release — do not consume yet.** Zest is under active development
4
+ > and published for early testing only. APIs, tag names, attributes, and
5
+ > design tokens may change without notice between versions. Don't depend on
6
+ > it in production until 1.0.
7
+
8
+ A gorgeous, dark-themed, fully-featured, framework-agnostic web component
9
+ library — 135+ custom elements covering layout, forms, overlays, navigation,
10
+ data display, and more. Use it in plain HTML, React, Vue, Svelte, Solid, or
11
+ anywhere else custom elements work (which is everywhere).
12
+
13
+ Zest is built with [Atomico](https://atomicojs.dev) and ships as a **single
14
+ self-contained ESM bundle with zero runtime dependencies** — Atomico and the
15
+ syntax-highlighting libraries are bundled in at build time. There is no
16
+ peer-dependency dance, no plugin, no framework adapter, and no per-component
17
+ imports to manage.
18
+
19
+ ## Install
20
+
21
+ ```sh
22
+ npm install @tasteee/zest
23
+ # or: pnpm add @tasteee/zest
24
+ ```
25
+
26
+ ## Two imports, that's it
27
+
28
+ ```js
29
+ import '@tasteee/zest' // registers every <z-*> element
30
+ import '@tasteee/zest/ink.css' // design tokens: CSS custom properties + fonts
31
+ ```
32
+
33
+ - **`@tasteee/zest`** is a side-effect import. It calls
34
+ `customElements.define(...)` for every element — after that, `<z-button>`,
35
+ `<z-dialog>`, `<z-stack>`, etc. just work as HTML tags. Each component
36
+ carries its own encapsulated styles in its shadow DOM, so nothing leaks in
37
+ or out.
38
+
39
+ - **`@tasteee/zest/ink.css`** defines the document-level design tokens
40
+ (colors, spacing, typography custom properties) that the components read via
41
+ `var(--token)`, and loads the DM Sans / DM Mono fonts.
42
+
43
+ ## A taste
44
+
45
+ Everything is just HTML. Attributes follow one consistent grammar across the
46
+ whole library: `tone` picks the color family, `kind` picks the visual
47
+ treatment, `size` picks the scale, and boolean states are `is-*` flags.
48
+
49
+ ```html
50
+ <z-button tone="primary">Save</z-button>
51
+ <z-button tone="danger" kind="outline">Delete</z-button>
52
+ <z-button kind="ghost" size="small">Cancel</z-button>
53
+ <z-button tone="primary" is-loading>Saving…</z-button>
54
+ ```
55
+
56
+ Layout is declarative — no wrapper CSS required. `gap` and the `inset*` props
57
+ take a size token (`2xs` `xs` `sm` `md` `lg` `xl` `2xl`…) or any CSS length:
58
+
59
+ ```html
60
+ <z-stack gap="md">
61
+ <z-card>One</z-card>
62
+ <z-card>Two</z-card>
63
+ </z-stack>
64
+
65
+ <z-stack is-row gap="sm" aligns-y="center" aligns-x="between">
66
+ <z-text weight="bold">Left</z-text>
67
+ <z-badge tone="success" label="Right"></z-badge>
68
+ </z-stack>
69
+ ```
70
+
71
+ Overlays build on the platform. `z-dialog` wraps the native `<dialog>`
72
+ element, so focus trapping, Esc-to-close, and top-layer stacking come for
73
+ free — wire it up entirely in markup with slots:
74
+
75
+ ```html
76
+ <z-dialog heading="Edit profile" description="Update your details.">
77
+ <z-button slot="trigger">Edit</z-button>
78
+
79
+ <z-input placeholder="Name"></z-input>
80
+
81
+ <div slot="footer">
82
+ <z-button kind="outline" tone="neutral">Cancel</z-button>
83
+ <z-button tone="primary">Save</z-button>
84
+ </div>
85
+ </z-dialog>
86
+ ```
87
+
88
+ Form controls emit `change` events with the value in `event.detail`. Rich
89
+ data (like option lists) is passed as a property:
90
+
91
+ ```html
92
+ <z-select placeholder="Pick a fruit"></z-select>
93
+ <z-switch is-checked></z-switch>
94
+ <z-input placeholder="Email" type="email" is-required></z-input>
95
+ ```
96
+
97
+ ```js
98
+ const select = document.querySelector('z-select')
99
+ select.options = [
100
+ { value: 'apple', label: 'Apple' },
101
+ { value: 'pear', label: 'Pear' }
102
+ ]
103
+ select.addEventListener('change', (e) => console.log(e.detail.value))
104
+ ```
105
+
106
+ ## Features
107
+
108
+ - **Framework-agnostic** — custom elements work natively in every framework
109
+ and in plain HTML. No adapters, no wrappers.
110
+ - **Zero runtime dependencies** — one bundled ESM file; nothing else lands in
111
+ your `node_modules` graph.
112
+ - **One consistent API grammar** — `tone` / `kind` / `size` / `is-*` mean the
113
+ same thing on every component, so learning one component teaches you all of
114
+ them.
115
+ - **A real design system** — a shared token scale (colors, spacing,
116
+ typography) drives every component via CSS custom properties, so overriding
117
+ a token restyles the whole library.
118
+ - **Platform-first** — dialogs use `<dialog>`, popovers and menus follow
119
+ native focus and keyboard conventions (arrow keys, Enter/Space, Esc).
120
+ - **Shadow DOM encapsulation** — component styles can't collide with your
121
+ app's CSS, and vice versa.
122
+ - **TypeScript + editor tooling** — ships `.d.ts` declarations and a
123
+ [Custom Elements Manifest](https://github.com/webcomponents/custom-elements-manifest)
124
+ (`custom-elements.json`), so editors that read the manifest autocomplete
125
+ tag names and attributes.
126
+
127
+ ## Using it everywhere
128
+
129
+ ### React
130
+
131
+ ```jsx
132
+ import '@tasteee/zest'
133
+ import '@tasteee/zest/ink.css'
134
+
135
+ export function App() {
136
+ return (
137
+ <z-button tone="primary" onClick={() => console.log('clicked')}>
138
+ Click me
139
+ </z-button>
140
+ )
141
+ }
142
+ ```
143
+
144
+ ### Plain HTML
145
+
146
+ The bundle is ESM, so the script tag must be `type="module"`:
147
+
148
+ ```html
149
+ <link rel="stylesheet" href="/node_modules/@tasteee/zest/dist/ink.css" />
150
+ <script type="module" src="/node_modules/@tasteee/zest/dist/zest.js"></script>
151
+
152
+ <z-button tone="primary">Click me</z-button>
153
+ ```
154
+
155
+ ### From a CDN (no build step at all)
156
+
157
+ ```html
158
+ <link rel="stylesheet" href="https://esm.sh/@tasteee/zest/ink.css" />
159
+ <script type="module" src="https://esm.sh/@tasteee/zest"></script>
160
+
161
+ <z-button tone="primary">Click me</z-button>
162
+ ```
163
+
164
+ ## Components
165
+
166
+ Foundation `z-box` `z-text` `z-card` `z-line` `z-separator` ·
167
+ Layout `z-stack` `z-grid` `z-cluster` `z-center` `z-container` `z-section`
168
+ `z-surface` `z-scroll` `z-spacer` ·
169
+ Actions `z-button` `z-button-group` `z-toggle` `z-toggle-group` `z-link` ·
170
+ Forms `z-input` `z-textarea` `z-checkbox` `z-switch` `z-radio` `z-radio-group`
171
+ `z-slider` `z-select` `z-combobox` `z-color-picker` `z-input-otp` ·
172
+ Data display `z-badge` `z-avatar` `z-progress` `z-skeleton` `z-table`
173
+ `z-pagination` `z-stat` ·
174
+ Navigation `z-breadcrumbs` `z-tabs` `z-collapsible` `z-accordion` `z-menu`
175
+ `z-nav-menu` `z-sidebar` ·
176
+ Overlays `z-tooltip` `z-popover` `z-hover-card` `z-dialog` `z-alert-dialog`
177
+ `z-alert` `z-sheet` `z-drawer` `z-context-menu` `z-toast` `z-command` ·
178
+ Specialized `z-empty-state` `z-scroll-area` `z-code-block` `z-post-meta`
179
+ `z-carousel` `z-chart` `z-terminal` `z-piano-roll` `z-pattern-roll`
180
+
181
+ …and many more. Every component has a doc page in [`docs/`](./docs) with
182
+ examples, attribute tables, and event references.
183
+
184
+ ## Local development
185
+
186
+ ```sh
187
+ pnpm install
188
+ pnpm dev # rebuilds dist/ on change (vite build --watch)
189
+ pnpm build # dist/zest.js + dist/ink.css + dist/*.d.ts + custom-elements.json
190
+ ```
191
+
192
+ ## Publishing
193
+
194
+ Run from this directory (`packages/zest`):
195
+
196
+ ```sh
197
+ npm publish
198
+ # prepublishOnly runs the full build automatically
199
+ # publishConfig.access is "public"
200
+ ```
201
+
202
+ ## License
203
+
204
+ MIT