@close-by/clay 0.2.9 → 0.2.10
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/docs/elements.md +7 -0
- package/docs/examples.md +1 -0
- package/package.json +5 -5
- package/src/index.ts +64 -0
package/docs/elements.md
CHANGED
|
@@ -31,6 +31,13 @@ Each factory creates an `Element` with a wire `type` string. The React client ma
|
|
|
31
31
|
| `field` | `field` | Label + description + error wrapper for one control |
|
|
32
32
|
| `nativeSelect` | `nativeSelect` | Styled native `<select>` |
|
|
33
33
|
| `navigationMenu` | `navigationmenu` (+ sub/link children) | Top nav mega-menu |
|
|
34
|
+
| `inputGroup` | `inputGroup` | Input with prefix/suffix addons |
|
|
35
|
+
| `toggle` | `toggle` | Pressed toolbar toggle |
|
|
36
|
+
| `descriptionList` | `descriptionList` | Key-value detail rows |
|
|
37
|
+
| `staticTable` | `staticTable` | Read-only HTML table |
|
|
38
|
+
| `aspectRatio` | `aspectRatio` | Fixed-ratio child wrapper |
|
|
39
|
+
| `itemList` | `itemList` | Settings / notification rows |
|
|
40
|
+
| `checkboxGroup` | `checkboxGroup` | Multi-select checkboxes |
|
|
34
41
|
| `notice` | `notice` | Dismissible app banner |
|
|
35
42
|
| `eventCalendar` | `eventCalendar` | Month grid + day event list (`events` API → wire `items`) |
|
|
36
43
|
| `timeline` | `timeline` | Vertical or horizontal event timeline |
|
package/docs/examples.md
CHANGED
|
@@ -19,6 +19,7 @@ After `bun run build:client && bun run demo` (or `bun run demo:cli`), open http:
|
|
|
19
19
|
| `/examples/datatable` | `DataTableDemo.ts` | Multi-sort (Shift+click / badges), footer aggregates + a11y hints, column pin, remote filter/sort + pagination; density/zebra, editors (Enter/Esc + focus restore), resize, virtualization (≥40, coexists with reorder via windowed drop targets); facets, bulk, collapse/expand, loading/empty; `ui.table` sugar |
|
|
20
20
|
| `/examples/composed` | `ComposedDemo.ts` | ReUI batch 1: `ui.timeline`, `ui.stepper`, `ui.dateRange`, `ui.feedList`/`ui.feedRow`, `ui.sparkline` |
|
|
21
21
|
| `/examples/reui-batches` | `ReuiBatchesDemo.ts` | ReUI batches 3–6: `buttonGroup`, `empty`, `pagination`, `filterBar`, form inputs, `navigationMenu`, `notice`, `stat`+sparkline, `eventCalendar`, datatable `showFilterChips` |
|
|
22
|
+
| `/examples/reui-batch-7` | `ReuiBatch7Demo.ts` | ReUI batch 7: `inputGroup`, `toggle`, `descriptionList`, `staticTable`, `aspectRatio`, `itemList`, `checkboxGroup` |
|
|
22
23
|
| `/examples/charts` | `ChartDemo.ts` | `ui.chart.*`, `ui.sparkline`, composed/scatter charts |
|
|
23
24
|
| `/examples/slider-demo` | `SliderDemo.ts` | Slider, checkbox, select + bindings |
|
|
24
25
|
| `/examples/feedback` | `FeedbackDemo.ts` | Alerts, progress, timer, `ui.theme`, `ui.runJavaScript` / `ui.scroll` |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@close-by/clay",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.10",
|
|
4
4
|
"description": "NiceGUI-like ui.* facade for Clay apps",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -37,10 +37,10 @@
|
|
|
37
37
|
"access": "public"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@close-by/clay-compiler": "0.2.
|
|
41
|
-
"@close-by/clay-core": "0.2.
|
|
42
|
-
"@close-by/clay-components": "0.2.
|
|
43
|
-
"@close-by/clay-server": "0.2.
|
|
40
|
+
"@close-by/clay-compiler": "0.2.10",
|
|
41
|
+
"@close-by/clay-core": "0.2.10",
|
|
42
|
+
"@close-by/clay-components": "0.2.10",
|
|
43
|
+
"@close-by/clay-server": "0.2.10",
|
|
44
44
|
"@tailwindcss/cli": "^4.3.3",
|
|
45
45
|
"tailwindcss": "^4.3.3"
|
|
46
46
|
}
|
package/src/index.ts
CHANGED
|
@@ -43,6 +43,13 @@ import {
|
|
|
43
43
|
notice as noticeFactory,
|
|
44
44
|
eventCalendar as eventCalendarFactory,
|
|
45
45
|
stat as statFactory,
|
|
46
|
+
inputGroup as inputGroupFactory,
|
|
47
|
+
toggleControl as toggleControlFactory,
|
|
48
|
+
descriptionList as descriptionListFactory,
|
|
49
|
+
staticTable as staticTableFactory,
|
|
50
|
+
aspectRatio as aspectRatioFactory,
|
|
51
|
+
itemList as itemListFactory,
|
|
52
|
+
checkboxGroup as checkboxGroupFactory,
|
|
46
53
|
dataTable as dataTableFactory,
|
|
47
54
|
areaChart as areaChartFactory,
|
|
48
55
|
barChart as barChartFactory,
|
|
@@ -166,6 +173,19 @@ import {
|
|
|
166
173
|
type NoticeVariant,
|
|
167
174
|
type EventCalendarProps,
|
|
168
175
|
type EventCalendarEvent,
|
|
176
|
+
type InputGroupProps,
|
|
177
|
+
type ToggleControlProps,
|
|
178
|
+
type ToggleControlVariant,
|
|
179
|
+
type ToggleControlSize,
|
|
180
|
+
type DescriptionListProps,
|
|
181
|
+
type DescriptionListItem,
|
|
182
|
+
type StaticTableProps,
|
|
183
|
+
type StaticTableColumn,
|
|
184
|
+
type AspectRatioProps,
|
|
185
|
+
type ItemListProps,
|
|
186
|
+
type ItemListEntry,
|
|
187
|
+
type CheckboxGroupProps,
|
|
188
|
+
type CheckboxGroupOption,
|
|
169
189
|
type StatItem,
|
|
170
190
|
type DataTableProps,
|
|
171
191
|
type DataTableAction,
|
|
@@ -972,6 +992,43 @@ export function eventCalendar(props?: EventCalendarProps): Element {
|
|
|
972
992
|
return eventCalendarFactory(props);
|
|
973
993
|
}
|
|
974
994
|
|
|
995
|
+
/** Input with prefix/suffix addons. See {@link InputGroupProps}. */
|
|
996
|
+
export function inputGroup(props?: InputGroupProps): Element {
|
|
997
|
+
return inputGroupFactory(props);
|
|
998
|
+
}
|
|
999
|
+
|
|
1000
|
+
/** Toolbar pressed toggle. See {@link ToggleControlProps}. */
|
|
1001
|
+
export function toggle(props?: ToggleControlProps): Element {
|
|
1002
|
+
return toggleControlFactory(props);
|
|
1003
|
+
}
|
|
1004
|
+
|
|
1005
|
+
/** Key-value detail rows. See {@link DescriptionListProps}. */
|
|
1006
|
+
export function descriptionList(props: DescriptionListProps): Element {
|
|
1007
|
+
return descriptionListFactory(props);
|
|
1008
|
+
}
|
|
1009
|
+
|
|
1010
|
+
/** Read-only HTML table. See {@link StaticTableProps}. */
|
|
1011
|
+
export function staticTable(props: StaticTableProps): Element {
|
|
1012
|
+
return staticTableFactory(props);
|
|
1013
|
+
}
|
|
1014
|
+
|
|
1015
|
+
/** Fixed aspect ratio wrapper. See {@link AspectRatioProps}. */
|
|
1016
|
+
export function aspectRatio(fn: () => void, props?: AspectRatioProps): Element;
|
|
1017
|
+
export function aspectRatio(props: AspectRatioProps, fn: () => void): Element;
|
|
1018
|
+
export function aspectRatio(a: any, b?: any): Element {
|
|
1019
|
+
return aspectRatioFactory(a, b);
|
|
1020
|
+
}
|
|
1021
|
+
|
|
1022
|
+
/** Settings / notification list rows. See {@link ItemListProps}. */
|
|
1023
|
+
export function itemList(props: ItemListProps): Element {
|
|
1024
|
+
return itemListFactory(props);
|
|
1025
|
+
}
|
|
1026
|
+
|
|
1027
|
+
/** Multi-select checkbox group. See {@link CheckboxGroupProps}. */
|
|
1028
|
+
export function checkboxGroup(props: CheckboxGroupProps): Element {
|
|
1029
|
+
return checkboxGroupFactory(props);
|
|
1030
|
+
}
|
|
1031
|
+
|
|
975
1032
|
/** Render markdown to HTML. Prefer `ui.markdown`. See {@link MarkdownProps}. */
|
|
976
1033
|
export function markdown(text?: string, props?: MarkdownProps): Element {
|
|
977
1034
|
return markdownFactory(text, props);
|
|
@@ -1741,6 +1798,13 @@ export const ui = {
|
|
|
1741
1798
|
navigationMenu,
|
|
1742
1799
|
notice,
|
|
1743
1800
|
eventCalendar,
|
|
1801
|
+
inputGroup,
|
|
1802
|
+
toggle,
|
|
1803
|
+
descriptionList,
|
|
1804
|
+
staticTable,
|
|
1805
|
+
aspectRatio,
|
|
1806
|
+
itemList,
|
|
1807
|
+
checkboxGroup,
|
|
1744
1808
|
markdown,
|
|
1745
1809
|
html,
|
|
1746
1810
|
image,
|