@silvery/examples 0.17.4 → 0.17.5

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 (62) hide show
  1. package/dist/_banner-A70_y2Vi.mjs +43 -0
  2. package/dist/{ansi-CCE2pVS0.mjs → ansi-0VXlUmNn.mjs} +7 -7
  3. package/dist/apng-B0gRaDVT.mjs +3 -0
  4. package/dist/{apng-HhhBjRGt.mjs → apng-BTRDTfDW.mjs} +2 -2
  5. package/dist/apps/aichat/index.mjs +69 -70
  6. package/dist/apps/app-todo.mjs +19 -20
  7. package/dist/apps/async-data.mjs +40 -41
  8. package/dist/apps/cli-wizard.mjs +51 -52
  9. package/dist/apps/clipboard.mjs +26 -27
  10. package/dist/apps/components.mjs +189 -190
  11. package/dist/apps/data-explorer.mjs +52 -53
  12. package/dist/apps/dev-tools.mjs +39 -40
  13. package/dist/apps/explorer.mjs +73 -74
  14. package/dist/apps/gallery.mjs +61 -62
  15. package/dist/apps/inline-bench.mjs +1 -1
  16. package/dist/apps/kanban.mjs +22 -23
  17. package/dist/apps/layout-ref.mjs +27 -28
  18. package/dist/apps/outline.mjs +35 -36
  19. package/dist/apps/paste-demo.mjs +33 -34
  20. package/dist/apps/scroll.mjs +11 -12
  21. package/dist/apps/search-filter.mjs +23 -24
  22. package/dist/apps/selection.mjs +30 -31
  23. package/dist/apps/spatial-focus-demo.mjs +32 -33
  24. package/dist/apps/task-list.mjs +25 -26
  25. package/dist/apps/terminal-caps-demo.mjs +30 -31
  26. package/dist/apps/terminal.mjs +157 -158
  27. package/dist/apps/text-selection-demo.mjs +62 -63
  28. package/dist/apps/textarea.mjs +21 -22
  29. package/dist/apps/theme.mjs +142 -143
  30. package/dist/apps/transform.mjs +25 -26
  31. package/dist/apps/virtual-10k.mjs +52 -53
  32. package/dist/{backends-Bahh9mKN.mjs → backends-Dj-11kZF.mjs} +1 -1
  33. package/dist/backends-U3QwStfO.mjs +3 -0
  34. package/dist/components/counter.mjs +6 -7
  35. package/dist/components/hello.mjs +5 -6
  36. package/dist/components/progress-bar.mjs +10 -11
  37. package/dist/components/select-list.mjs +8 -9
  38. package/dist/components/spinner.mjs +10 -11
  39. package/dist/components/text-input.mjs +8 -9
  40. package/dist/components/virtual-list.mjs +7 -8
  41. package/dist/{flexily-zero-adapter-UB-ra8fR.mjs → flexily-zero-adapter-ByVzLTFP.mjs} +1 -1
  42. package/dist/gif-B6NGH5gs.mjs +3 -0
  43. package/dist/{gif-BtnXuxLF.mjs → gif-CfkOF-iG.mjs} +2 -2
  44. package/dist/layout/dashboard.mjs +197 -198
  45. package/dist/layout/live-resize.mjs +44 -45
  46. package/dist/layout/overflow.mjs +16 -17
  47. package/dist/layout/text-layout.mjs +67 -68
  48. package/dist/{plugins-D1KtkT4a.mjs → plugins-CT0DdV_E.mjs} +12 -13
  49. package/dist/{src-BTEVGpd9.mjs → src-jO3Zuzjj.mjs} +3 -3
  50. package/dist/{yoga-adapter-BVtQ5OJR.mjs → yoga-adapter-BSQHuMV9.mjs} +1 -1
  51. package/package.json +4 -2
  52. package/dist/_banner-DLPxCqVy.mjs +0 -44
  53. package/dist/apng-mwUQbTTF.mjs +0 -3
  54. package/dist/backends-CCtCDQ94.mjs +0 -3
  55. package/dist/gif-BZaqPPVX.mjs +0 -3
  56. package/dist/jsx-runtime-dMs_8fNu.mjs +0 -241
  57. /package/dist/{UPNG-Cy7ViL8f.mjs → UPNG-ShUlaTDh.mjs} +0 -0
  58. /package/dist/{__vite-browser-external-2447137e-BML7CYau.mjs → __vite-browser-external-2447137e-Bopa5BFR.mjs} +0 -0
  59. /package/dist/{gifenc-CLRW41dk.mjs → gifenc-BI4ihP_T.mjs} +0 -0
  60. /package/dist/{node-NuJ94BWl.mjs → node-nsrAOjH4.mjs} +0 -0
  61. /package/dist/{resvg-js-C_8Wps1F.mjs → resvg-js-Cnk2o49d.mjs} +0 -0
  62. /package/dist/{src-CzfRafCQ.mjs → src-9ZhfQyzD.mjs} +0 -0
@@ -1,10 +1,10 @@
1
- import { W as CapabilityRegistryContext } from "../src-BTEVGpd9.mjs";
1
+ import { W as CapabilityRegistryContext } from "../src-jO3Zuzjj.mjs";
2
2
  import { t as _usingCtx } from "../usingCtx-CsEf0xO3.mjs";
3
- import { a as createApp, i as pipe, n as withTerminal, r as withReact, t as withDomEvents } from "../plugins-D1KtkT4a.mjs";
4
- import { t as require_jsx_runtime } from "../jsx-runtime-dMs_8fNu.mjs";
5
- import { t as ExampleBanner } from "../_banner-DLPxCqVy.mjs";
3
+ import { a as createApp, i as pipe, n as withTerminal, r as withReact, t as withDomEvents } from "../plugins-CT0DdV_E.mjs";
4
+ import { t as ExampleBanner } from "../_banner-A70_y2Vi.mjs";
6
5
  import { useContext, useSyncExternalStore } from "react";
7
6
  import { Box, H1, H2, HR, Kbd, Muted, Small, Strong, Text } from "silvery";
7
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
8
8
  //#region ../packages/ag-react/src/hooks/useSelection.ts
9
9
  /**
10
10
  * useSelection — React hook for accessing the selection feature from the capability registry.
@@ -41,7 +41,6 @@ function useSelection() {
41
41
  }
42
42
  //#endregion
43
43
  //#region apps/text-selection-demo.tsx
44
- var import_jsx_runtime = require_jsx_runtime();
45
44
  const meta = {
46
45
  name: "Text Selection",
47
46
  description: "Real selection via useSelection hook, userSelect modes, live state readout",
@@ -54,20 +53,20 @@ const meta = {
54
53
  ]
55
54
  };
56
55
  function SelectableTextPanel() {
57
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
56
+ return /* @__PURE__ */ jsxs(Box, {
58
57
  flexDirection: "column",
59
58
  borderStyle: "round",
60
59
  borderColor: "$border",
61
60
  paddingX: 1,
62
61
  flexGrow: 1,
63
62
  children: [
64
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(H2, { children: "Selectable Text" }),
65
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Small, { children: "userSelect=\"text\" (default)" }),
66
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
67
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "Drag your mouse over this text to select it." }),
68
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "Multi-line selections work across paragraphs." }),
69
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
70
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
63
+ /* @__PURE__ */ jsx(H2, { children: "Selectable Text" }),
64
+ /* @__PURE__ */ jsx(Small, { children: "userSelect=\"text\" (default)" }),
65
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
66
+ /* @__PURE__ */ jsx(Text, { children: "Drag your mouse over this text to select it." }),
67
+ /* @__PURE__ */ jsx(Text, { children: "Multi-line selections work across paragraphs." }),
68
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
69
+ /* @__PURE__ */ jsx(Text, {
71
70
  color: "$muted",
72
71
  children: "The quick brown fox jumps over the lazy dog. Pack my box with five dozen liquor jugs."
73
72
  })
@@ -75,7 +74,7 @@ function SelectableTextPanel() {
75
74
  });
76
75
  }
77
76
  function NonSelectablePanel() {
78
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
77
+ return /* @__PURE__ */ jsxs(Box, {
79
78
  flexDirection: "column",
80
79
  borderStyle: "round",
81
80
  borderColor: "$border",
@@ -83,47 +82,47 @@ function NonSelectablePanel() {
83
82
  flexGrow: 1,
84
83
  userSelect: "none",
85
84
  children: [
86
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(H2, { children: "Non-Selectable" }),
87
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Small, { children: "userSelect=\"none\"" }),
88
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
89
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "This area cannot be selected by mouse drag." }),
90
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "Click events still work normally here." }),
91
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
92
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Muted, { children: "Hold Alt and drag to override and select anyway." })
85
+ /* @__PURE__ */ jsx(H2, { children: "Non-Selectable" }),
86
+ /* @__PURE__ */ jsx(Small, { children: "userSelect=\"none\"" }),
87
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
88
+ /* @__PURE__ */ jsx(Text, { children: "This area cannot be selected by mouse drag." }),
89
+ /* @__PURE__ */ jsx(Text, { children: "Click events still work normally here." }),
90
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
91
+ /* @__PURE__ */ jsx(Muted, { children: "Hold Alt and drag to override and select anyway." })
93
92
  ]
94
93
  });
95
94
  }
96
95
  function ContainedPanel() {
97
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
96
+ return /* @__PURE__ */ jsxs(Box, {
98
97
  flexDirection: "column",
99
98
  borderStyle: "round",
100
99
  borderColor: "$warning",
101
100
  paddingX: 1,
102
101
  flexGrow: 1,
103
102
  children: [
104
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(H2, {
103
+ /* @__PURE__ */ jsx(H2, {
105
104
  color: "$warning",
106
105
  children: "Contained Selection"
107
106
  }),
108
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Small, { children: "userSelect=\"contain\"" }),
109
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
110
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
107
+ /* @__PURE__ */ jsx(Small, { children: "userSelect=\"contain\"" }),
108
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
109
+ /* @__PURE__ */ jsxs(Box, {
111
110
  flexDirection: "column",
112
111
  borderStyle: "round",
113
112
  borderColor: "$primary",
114
113
  paddingX: 1,
115
114
  userSelect: "contain",
116
115
  children: [
117
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
116
+ /* @__PURE__ */ jsx(Text, {
118
117
  bold: true,
119
118
  color: "$primary",
120
119
  children: "Selection Boundary"
121
120
  }),
122
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
123
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "Selection cannot escape this container." }),
124
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: "Try dragging past the border — it clips." }),
125
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
126
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
121
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
122
+ /* @__PURE__ */ jsx(Text, { children: "Selection cannot escape this container." }),
123
+ /* @__PURE__ */ jsx(Text, { children: "Try dragging past the border — it clips." }),
124
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
125
+ /* @__PURE__ */ jsx(Text, {
127
126
  color: "$success",
128
127
  children: "Useful for modals, side panes, overlays."
129
128
  })
@@ -134,37 +133,37 @@ function ContainedPanel() {
134
133
  }
135
134
  function SelectionStatePanel() {
136
135
  const selection = useSelection();
137
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
136
+ return /* @__PURE__ */ jsxs(Box, {
138
137
  flexDirection: "column",
139
138
  borderStyle: "round",
140
139
  borderColor: "$info",
141
140
  paddingX: 1,
142
141
  flexGrow: 1,
143
142
  children: [
144
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(H2, {
143
+ /* @__PURE__ */ jsx(H2, {
145
144
  color: "$info",
146
145
  children: "Selection State"
147
146
  }),
148
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Small, { children: "Live readout from useSelection()" }),
149
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, { height: 1 }),
150
- !selection ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
147
+ /* @__PURE__ */ jsx(Small, { children: "Live readout from useSelection()" }),
148
+ /* @__PURE__ */ jsx(Box, { height: 1 }),
149
+ !selection ? /* @__PURE__ */ jsx(Text, {
151
150
  color: "$muted",
152
151
  children: "useSelection() returned undefined — feature not installed"
153
- }) : selection.range ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
154
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
152
+ }) : selection.range ? /* @__PURE__ */ jsxs(Fragment, { children: [
153
+ /* @__PURE__ */ jsxs(Box, {
155
154
  gap: 1,
156
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Strong, { children: "Status:" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
155
+ children: [/* @__PURE__ */ jsx(Strong, { children: "Status:" }), /* @__PURE__ */ jsx(Text, {
157
156
  color: "$success",
158
157
  children: selection.selecting ? "Selecting..." : "Selected"
159
158
  })]
160
159
  }),
161
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
160
+ /* @__PURE__ */ jsxs(Box, {
162
161
  gap: 1,
163
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Strong, { children: "Source:" }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: selection.source ?? "unknown" })]
162
+ children: [/* @__PURE__ */ jsx(Strong, { children: "Source:" }), /* @__PURE__ */ jsx(Text, { children: selection.source ?? "unknown" })]
164
163
  }),
165
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
164
+ /* @__PURE__ */ jsxs(Box, {
166
165
  gap: 1,
167
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Strong, { children: "Anchor:" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { children: [
166
+ children: [/* @__PURE__ */ jsx(Strong, { children: "Anchor:" }), /* @__PURE__ */ jsxs(Text, { children: [
168
167
  "(",
169
168
  selection.range.anchor.col,
170
169
  ", ",
@@ -172,9 +171,9 @@ function SelectionStatePanel() {
172
171
  ")"
173
172
  ] })]
174
173
  }),
175
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
174
+ /* @__PURE__ */ jsxs(Box, {
176
175
  gap: 1,
177
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Strong, { children: "Head:" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, { children: [
176
+ children: [/* @__PURE__ */ jsx(Strong, { children: "Head:" }), /* @__PURE__ */ jsxs(Text, { children: [
178
177
  "(",
179
178
  selection.range.head.col,
180
179
  ", ",
@@ -182,7 +181,7 @@ function SelectionStatePanel() {
182
181
  ")"
183
182
  ] })]
184
183
  })
185
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, {
184
+ ] }) : /* @__PURE__ */ jsx(Text, {
186
185
  color: "$muted",
187
186
  children: "No active selection — drag to select text"
188
187
  })
@@ -190,57 +189,57 @@ function SelectionStatePanel() {
190
189
  });
191
190
  }
192
191
  function StatusBar() {
193
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, {
192
+ return /* @__PURE__ */ jsx(Box, {
194
193
  flexDirection: "row",
195
194
  gap: 2,
196
195
  paddingX: 1,
197
196
  flexShrink: 0,
198
197
  userSelect: "none",
199
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Muted, { children: [
200
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Kbd, { children: "Drag" }),
198
+ children: /* @__PURE__ */ jsxs(Muted, { children: [
199
+ /* @__PURE__ */ jsx(Kbd, { children: "Drag" }),
201
200
  " select ",
202
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Kbd, { children: "Alt+Drag" }),
201
+ /* @__PURE__ */ jsx(Kbd, { children: "Alt+Drag" }),
203
202
  " force select ",
204
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Kbd, { children: "Ctrl+C" }),
203
+ /* @__PURE__ */ jsx(Kbd, { children: "Ctrl+C" }),
205
204
  " quit"
206
205
  ] })
207
206
  });
208
207
  }
209
208
  function TextSelectionDemo() {
210
- return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
209
+ return /* @__PURE__ */ jsxs(Box, {
211
210
  flexDirection: "column",
212
211
  padding: 1,
213
212
  gap: 1,
214
213
  height: "100%",
215
214
  children: [
216
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, { children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(H1, {
215
+ /* @__PURE__ */ jsxs(Box, { children: [/* @__PURE__ */ jsx(H1, {
217
216
  color: "$primary",
218
217
  children: "Text Selection Demo"
219
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Muted, { children: " — real selection via useSelection()" })] }),
220
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
218
+ }), /* @__PURE__ */ jsx(Muted, { children: " — real selection via useSelection()" })] }),
219
+ /* @__PURE__ */ jsxs(Box, {
221
220
  flexDirection: "row",
222
221
  gap: 1,
223
222
  flexGrow: 1,
224
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectableTextPanel, {}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(NonSelectablePanel, {})]
223
+ children: [/* @__PURE__ */ jsx(SelectableTextPanel, {}), /* @__PURE__ */ jsx(NonSelectablePanel, {})]
225
224
  }),
226
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
225
+ /* @__PURE__ */ jsxs(Box, {
227
226
  flexDirection: "row",
228
227
  gap: 1,
229
228
  flexGrow: 1,
230
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ContainedPanel, {}), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(SelectionStatePanel, {})]
229
+ children: [/* @__PURE__ */ jsx(ContainedPanel, {}), /* @__PURE__ */ jsx(SelectionStatePanel, {})]
231
230
  }),
232
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(HR, {}),
233
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(StatusBar, {})
231
+ /* @__PURE__ */ jsx(HR, {}),
232
+ /* @__PURE__ */ jsx(StatusBar, {})
234
233
  ]
235
234
  });
236
235
  }
237
236
  async function main() {
238
237
  try {
239
238
  var _usingCtx$1 = _usingCtx();
240
- const app = pipe(createApp(() => () => ({})), withReact(/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ExampleBanner, {
239
+ const app = pipe(createApp(() => () => ({})), withReact(/* @__PURE__ */ jsx(ExampleBanner, {
241
240
  meta,
242
241
  controls: "Drag select Alt+Drag force select Ctrl+C quit",
243
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextSelectionDemo, {})
242
+ children: /* @__PURE__ */ jsx(TextSelectionDemo, {})
244
243
  })), withTerminal(process, { mouse: true }), withDomEvents());
245
244
  await _usingCtx$1.u(await app.run()).waitUntilExit();
246
245
  } catch (_) {
@@ -1,8 +1,8 @@
1
1
  import { t as _usingCtx } from "../usingCtx-CsEf0xO3.mjs";
2
- import { t as require_jsx_runtime } from "../jsx-runtime-dMs_8fNu.mjs";
3
- import { t as ExampleBanner } from "../_banner-DLPxCqVy.mjs";
2
+ import { t as ExampleBanner } from "../_banner-A70_y2Vi.mjs";
4
3
  import { useState } from "react";
5
4
  import { Box, H1, Muted, Strong, Text, TextArea, createTerm, render, useApp, useInput } from "silvery";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
6
  //#region apps/textarea.tsx
7
7
  /**
8
8
  * TextArea Example — Split-Pane Note Editor
@@ -16,7 +16,6 @@ import { Box, H1, Muted, Strong, Text, TextArea, createTerm, render, useApp, use
16
16
  * - Word/character stats in the header
17
17
  * - Submit with Ctrl+Enter to collect notes
18
18
  */
19
- var import_jsx_runtime = require_jsx_runtime();
20
19
  const meta = {
21
20
  name: "TextArea",
22
21
  description: "Split-pane note editor with word wrap, kill ring, and note collection",
@@ -70,25 +69,25 @@ function NoteEditor() {
70
69
  const lines = value.split("\n").length;
71
70
  const chars = value.length;
72
71
  const words = value.split(/\s+/).filter(Boolean).length;
73
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, {
72
+ return /* @__PURE__ */ jsx(Box, {
74
73
  flexDirection: "column",
75
74
  flexGrow: 1,
76
75
  padding: 1,
77
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
76
+ children: /* @__PURE__ */ jsxs(Box, {
78
77
  flexDirection: "row",
79
78
  gap: 1,
80
79
  flexGrow: 1,
81
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
80
+ children: [/* @__PURE__ */ jsxs(Box, {
82
81
  borderStyle: "round",
83
82
  borderColor: focusIndex === 0 ? "$primary" : "$border",
84
83
  flexDirection: "column",
85
84
  flexGrow: 3,
86
85
  flexBasis: 0,
87
86
  children: [
88
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
87
+ /* @__PURE__ */ jsxs(Box, {
89
88
  paddingX: 1,
90
89
  justifyContent: "space-between",
91
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(H1, { children: "Editor" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Muted, { children: [
90
+ children: [/* @__PURE__ */ jsx(H1, { children: "Editor" }), /* @__PURE__ */ jsxs(Muted, { children: [
92
91
  lines,
93
92
  " lines, ",
94
93
  words,
@@ -97,11 +96,11 @@ function NoteEditor() {
97
96
  " chars"
98
97
  ] })]
99
98
  }),
100
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: " " }),
101
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, {
99
+ /* @__PURE__ */ jsx(Text, { children: " " }),
100
+ /* @__PURE__ */ jsx(Box, {
102
101
  paddingX: 1,
103
102
  flexGrow: 1,
104
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextArea, {
103
+ children: /* @__PURE__ */ jsx(TextArea, {
105
104
  value,
106
105
  onChange: setValue,
107
106
  onSubmit: handleSubmit,
@@ -110,41 +109,41 @@ function NoteEditor() {
110
109
  })
111
110
  })
112
111
  ]
113
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
112
+ }), /* @__PURE__ */ jsxs(Box, {
114
113
  borderStyle: "round",
115
114
  borderColor: focusIndex === 1 ? "$primary" : "$border",
116
115
  flexDirection: "column",
117
116
  flexGrow: 2,
118
117
  flexBasis: 0,
119
118
  children: [
120
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
119
+ /* @__PURE__ */ jsxs(Box, {
121
120
  paddingX: 1,
122
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)(H1, { children: "Notes" }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Muted, { children: [
121
+ children: [/* @__PURE__ */ jsx(H1, { children: "Notes" }), /* @__PURE__ */ jsxs(Muted, { children: [
123
122
  " (",
124
123
  notes.length,
125
124
  ")"
126
125
  ] })]
127
126
  }),
128
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Text, { children: " " }),
129
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Box, {
127
+ /* @__PURE__ */ jsx(Text, { children: " " }),
128
+ /* @__PURE__ */ jsx(Box, {
130
129
  flexDirection: "column",
131
130
  paddingX: 1,
132
131
  overflow: "scroll",
133
132
  flexGrow: 1,
134
- children: notes.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Muted, { children: "No notes yet." }) : notes.map((note, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Box, {
133
+ children: notes.length === 0 ? /* @__PURE__ */ jsx(Muted, { children: "No notes yet." }) : notes.map((note, i) => /* @__PURE__ */ jsxs(Box, {
135
134
  flexDirection: "column",
136
135
  marginBottom: 1,
137
- children: [/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Text, {
136
+ children: [/* @__PURE__ */ jsxs(Text, {
138
137
  wrap: "truncate",
139
138
  children: [
140
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Strong, {
139
+ /* @__PURE__ */ jsxs(Strong, {
141
140
  color: "$success",
142
141
  children: ["#", i + 1]
143
142
  }),
144
143
  " ",
145
144
  note.split("\n")[0]
146
145
  ]
147
- }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(Muted, { children: [
146
+ }), /* @__PURE__ */ jsxs(Muted, { children: [
148
147
  note.split("\n").length,
149
148
  " lines, ",
150
149
  note.length,
@@ -161,10 +160,10 @@ async function main() {
161
160
  try {
162
161
  var _usingCtx$1 = _usingCtx();
163
162
  const term = _usingCtx$1.u(createTerm());
164
- const { waitUntilExit } = await render(/* @__PURE__ */ (0, import_jsx_runtime.jsx)(ExampleBanner, {
163
+ const { waitUntilExit } = await render(/* @__PURE__ */ jsx(ExampleBanner, {
165
164
  meta,
166
165
  controls: "Tab switch pane Ctrl+Enter submit Esc quit",
167
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(NoteEditor, {})
166
+ children: /* @__PURE__ */ jsx(NoteEditor, {})
168
167
  }), term);
169
168
  await waitUntilExit();
170
169
  } catch (_) {