@valyrianjs/terminal 0.1.0 → 0.1.1

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 CHANGED
@@ -1,26 +1,26 @@
1
1
  # valyrianjs-terminal
2
2
 
3
- Adapter terminal-first para `valyrian.js`. Sirve para renderizar pantallas de texto con primitivas propias y, si lo necesitas, montar sesiones interactivas sobre `stdin` y `stdout`.
3
+ Terminal-first adapter for `valyrian.js`. It lets you render text UIs with its own primitives and, when needed, mount interactive sessions on top of `stdin` and `stdout`.
4
4
 
5
- ## Que resuelve
5
+ ## What It Solves
6
6
 
7
- - layout terminal-first con `Screen`, `Box`, `View`, `Text`, `Table`, `Row` y `Td`
8
- - primitivas interactivas con `Input`, `Button`, `List` y `ScrollView`
9
- - render estatico a texto con `renderTerminal()`
10
- - runtime interactivo con `mountTerminal()`
7
+ - terminal-first layout with `Screen`, `Box`, `View`, `Text`, `Table`, `Row`, and `Td`
8
+ - interactive primitives with `Input`, `Button`, `List`, and `ScrollView`
9
+ - static text rendering with `renderTerminal()`
10
+ - interactive runtime with `mountTerminal()`
11
11
 
12
- ## Instalacion
12
+ ## Installation
13
13
 
14
14
  ```bash
15
15
  npm install valyrianjs-terminal valyrian.js
16
16
  ```
17
17
 
18
- ## Elige el entrypoint correcto
18
+ ## Choose the Right Entrypoint
19
19
 
20
- - Usa `renderTerminal()` para snapshots, pruebas o salidas no interactivas.
21
- - Usa `mountTerminal()` cuando necesitas foco, teclado, mouse, clipboard o escritura a `stdout`.
20
+ - Use `renderTerminal()` for snapshots, tests, or non-interactive output.
21
+ - Use `mountTerminal()` when you need focus, keyboard, mouse, clipboard, or writes to `stdout`.
22
22
 
23
- ## Ejemplo minimo
23
+ ## Minimal Example
24
24
 
25
25
  ```tsx
26
26
  /** @jsx v */
@@ -48,21 +48,21 @@ const session = mountTerminal(() => (
48
48
  session.focus("note");
49
49
  ```
50
50
 
51
- ## Mapa de docs
51
+ ## Docs Map
52
52
 
53
- - `docs/getting-started.md` - primer flujo completo, de render estatico a sesion interactiva
54
- - `docs/core-concepts.md` - modelo mental: ids, foco, hitboxes, salida plana, ANSI y cleanup
55
- - `docs/interaction-model.md` - comportamiento por primitiva y eventos de interaccion
56
- - `docs/session-runtime.md` - lifecycle de sesion, streams, clipboard, coordenadas y runtime
57
- - `docs/cookbook.md` - recetas cortas para tareas concretas
58
- - `docs/api-reference.md` - referencia de la superficie publica y subpaths publicados
59
- - `docs/local-demo.md` - demo repo-local, no parte del paquete publicado
53
+ - `docs/getting-started.md` - first complete flow, from static rendering to an interactive session
54
+ - `docs/core-concepts.md` - mental model: ids, focus, hitboxes, plain output, ANSI, and cleanup
55
+ - `docs/interaction-model.md` - behavior of each primitive and interaction events
56
+ - `docs/session-runtime.md` - session lifecycle, streams, clipboard, coordinates, and runtime
57
+ - `docs/cookbook.md` - short recipes for concrete tasks
58
+ - `docs/api-reference.md` - reference for the public surface and published subpaths
59
+ - `docs/local-demo.md` - repo-local demo, not part of the published package
60
60
 
61
- ## Alcance del paquete publicado
61
+ ## Published Package Scope
62
62
 
63
- El paquete publicado incluye el adapter compilado en `dist/`, esta documentacion y metadatos de soporte. Los archivos de `examples/` viven solo en el repo y no forman parte del paquete distribuido.
63
+ The published package includes the compiled adapter in `dist/`, this documentation, and supporting metadata. Files in `examples/` live only in the repo and are not part of the distributed package.
64
64
 
65
- ## Desarrollo local
65
+ ## Local Development
66
66
 
67
67
  ```bash
68
68
  bun test
@@ -1,78 +1,78 @@
1
1
  # API Reference
2
2
 
3
- Referencia de la superficie publica real publicada por `valyrianjs-terminal`.
3
+ Reference for the actual public surface published by `valyrianjs-terminal`.
4
4
 
5
- ## Entrypoints publicados
5
+ ## Published Entrypoints
6
6
 
7
7
  ### `valyrianjs-terminal`
8
8
 
9
- Entrada principal. Expone a alto nivel:
9
+ Main entrypoint. At a high level, it exposes:
10
10
 
11
11
  - `renderTerminal()`
12
12
  - `mountTerminal()`
13
- - primitivas `Screen`, `Box`, `View`, `Text`, `Input`, `Button`, `ScrollView`, `List`, `Table`, `Row`, `Td`
14
- - tipos de props, eventos, nodos y sesion
13
+ - primitives `Screen`, `Box`, `View`, `Text`, `Input`, `Button`, `ScrollView`, `List`, `Table`, `Row`, `Td`
14
+ - prop, event, node, and session types
15
15
 
16
16
  ### `valyrianjs-terminal/render`
17
17
 
18
- Subpath publicado para utilidades de render de bajo nivel.
18
+ Published subpath for lower-level rendering utilities.
19
19
 
20
20
  - `renderTerminal(input): string`
21
21
  - `renderTerminalNode(node): string`
22
22
  - `renderTerminalFrame(node): TerminalFrame`
23
23
 
24
- Usa este subpath cuando solo necesites transformar nodos terminales a texto o `TerminalFrame`, sin montar una sesion interactiva.
24
+ Use this subpath when you only need to transform terminal nodes into text or a `TerminalFrame`, without mounting an interactive session.
25
25
 
26
- ## Funciones principales
26
+ ## Main Functions
27
27
 
28
28
  ### `renderTerminal(input): string`
29
29
 
30
- Resuelve la raiz recibida y devuelve la salida terminal en texto plano.
30
+ Resolves the provided root and returns terminal output as plain text.
31
31
 
32
- Casos de uso respaldados por la implementacion actual:
32
+ Use cases supported by the current implementation:
33
33
 
34
- - snapshots y pruebas
35
- - validacion de layout sin `stdin` ni `stdout`
36
- - inspeccion de contenido en modo no interactivo
34
+ - snapshots and tests
35
+ - layout validation without `stdin` or `stdout`
36
+ - content inspection in non-interactive mode
37
37
 
38
- Notas:
38
+ Notes:
39
39
 
40
- - concatena los nodos raiz con saltos de linea
41
- - elimina solo el whitespace final con `trimEnd()`
42
- - no crea listeners ni estado interactivo
40
+ - concatenates root nodes with newlines
41
+ - removes only trailing whitespace with `trimEnd()`
42
+ - does not create listeners or interactive state
43
43
 
44
44
  ### `mountTerminal(input, options?): TerminalSession`
45
45
 
46
- Monta una sesion interactiva sobre el arbol terminal y devuelve un `TerminalSession`.
46
+ Mounts an interactive session on the terminal tree and returns a `TerminalSession`.
47
47
 
48
- Comportamiento de alto nivel:
48
+ High-level behavior:
49
49
 
50
- - resuelve el arbol actual y lo rerenderiza con `session.update()`
51
- - administra foco por `id`
52
- - procesa teclado, mouse, seleccion y clipboard
53
- - puede escribir automaticamente a `stdout` si se provee
54
- - si recibe `stdin`, activa raw mode al montar y lo revierte en `destroy()`
50
+ - resolves the current tree and re-renders it with `session.update()`
51
+ - manages focus by `id`
52
+ - handles keyboard, mouse, selection, and clipboard interaction
53
+ - can write to `stdout` automatically when provided
54
+ - if it receives `stdin`, it enables raw mode on mount and restores it in `destroy()`
55
55
 
56
56
  ## `TerminalMountOptions`
57
57
 
58
- - `ansi?: boolean` - si hay `stdout`, escribe diffs ANSI en vez de texto plano
59
- - `clipboard?: TerminalClipboardAdapter | false` - adapter custom o desactiva el clipboard del sistema
60
- - `stdin?` - stream con `on("data")`; `off()`, `removeListener()`, `setRawMode()`, `resume()` y `pause()` son opcionales
61
- - `stdout?` - writer con `write(chunk: string)`
58
+ - `ansi?: boolean` - if `stdout` is present, writes ANSI diffs instead of plain text
59
+ - `clipboard?: TerminalClipboardAdapter | false` - custom adapter or disables the system clipboard
60
+ - `stdin?` - stream with `on("data")`; `off()`, `removeListener()`, `setRawMode()`, `resume()`, and `pause()` are optional
61
+ - `stdout?` - writer with `write(chunk: string)`
62
62
 
63
- ## Primitivas de layout
63
+ ## Layout Primitives
64
64
 
65
65
  ### `Screen`
66
66
 
67
- Props de `TerminalScreenProps`:
67
+ `TerminalScreenProps` props:
68
68
 
69
69
  - `title?: string`
70
70
 
71
- Funcion: contenedor raiz. Si `title` existe, se renderiza como primera linea del frame.
71
+ Role: root container. If `title` exists, it renders as the first line of the frame.
72
72
 
73
73
  ### `Box`
74
74
 
75
- Props de `TerminalBoxProps`:
75
+ `TerminalBoxProps` props:
76
76
 
77
77
  - `direction?: "row" | "column"`
78
78
  - `gap?: number`
@@ -83,56 +83,56 @@ Props de `TerminalBoxProps`:
83
83
  - `id?: string`
84
84
  - `focusable?: boolean`
85
85
 
86
- Funcion: contenedor de layout. En `row` compone horizontalmente; en `column`, verticalmente.
86
+ Role: layout container. In `row`, it composes horizontally; in `column`, vertically.
87
87
 
88
88
  ### `View`
89
89
 
90
- Props de `TerminalViewProps`:
90
+ `TerminalViewProps` props:
91
91
 
92
- - todas las props de layout de `Box`
92
+ - all layout props from `Box`
93
93
  - `role?: string`
94
94
 
95
- Funcion: contenedor semantico equivalente a `terminal-view`.
95
+ Role: semantic container equivalent to `terminal-view`.
96
96
 
97
97
  ### `Text`
98
98
 
99
- Props de `TerminalTextProps`:
99
+ `TerminalTextProps` props:
100
100
 
101
101
  - `value?: any`
102
102
 
103
- Funcion: renderiza `value` o el texto concatenado de sus hijos. Si hay saltos de linea, se preservan.
103
+ Role: renders `value` or the concatenated text from its children. If there are line breaks, they are preserved.
104
104
 
105
105
  ### `Table`
106
106
 
107
- Props de `TerminalTableProps`:
107
+ `TerminalTableProps` props:
108
108
 
109
109
  - `v-for?: any[]`
110
110
 
111
- Funcion: compone filas y calcula automaticamente el ancho maximo por columna.
111
+ Role: composes rows and automatically calculates the maximum width for each column.
112
112
 
113
113
  ### `Row`
114
114
 
115
- Props de `TerminalRowProps`:
115
+ `TerminalRowProps` props:
116
116
 
117
117
  - `separator?: string`
118
118
 
119
- Funcion: une celdas usando `separator` o `" | "` por default.
119
+ Role: joins cells using `separator` or `" | "` by default.
120
120
 
121
121
  ### `Td`
122
122
 
123
- Props de `TerminalTdProps`:
123
+ `TerminalTdProps` props:
124
124
 
125
125
  - `padding?: number`
126
126
 
127
- Funcion: envuelve el contenido de la celda y aplica padding interno si se define.
127
+ Role: wraps cell content and applies internal padding when defined.
128
128
 
129
- ## Primitivas interactivas
129
+ ## Interactive Primitives
130
130
 
131
- Todas dependen de `id` para participar completamente en foco, hitboxes, busqueda por coordenadas y varios helpers de `TerminalSession`.
131
+ All of them depend on `id` to fully participate in focus, hitboxes, coordinate lookup, and several `TerminalSession` helpers.
132
132
 
133
133
  ### `Input`
134
134
 
135
- Props de `TerminalInputProps`:
135
+ `TerminalInputProps` props:
136
136
 
137
137
  - `id?: string`
138
138
  - `focusable?: boolean`
@@ -143,22 +143,22 @@ Props de `TerminalInputProps`:
143
143
  - `onsubmit?(event)`
144
144
  - `onChangeText?(value)`
145
145
 
146
- Soporte actual de interaccion:
146
+ Current interaction support:
147
147
 
148
- - cursor y seleccion de texto
148
+ - cursor movement and text selection
149
149
  - `LEFT`, `RIGHT`, `SHIFT_LEFT`, `SHIFT_RIGHT`
150
150
  - `ALT_LEFT`, `ALT_RIGHT`, `HOME`, `END`
151
151
  - `CTRL_A`, `CTRL_C`, `CTRL_X`, `CTRL_V`
152
- - `BACKSPACE`, `DELETE`, escritura de caracteres y `ENTER`
152
+ - `BACKSPACE`, `DELETE`, character input, and `ENTER`
153
153
 
154
- Payloads importantes:
154
+ Important payloads:
155
155
 
156
156
  - `TerminalInputChangeEventPayload` - `{ type: "change" | "input", id, value }`
157
157
  - `TerminalInputSubmitEventPayload` - `{ type: "submit", id, value }`
158
158
 
159
159
  ### `Button`
160
160
 
161
- Props de `TerminalButtonProps`:
161
+ `TerminalButtonProps` props:
162
162
 
163
163
  - `id?: string`
164
164
  - `focusable?: boolean`
@@ -168,19 +168,19 @@ Props de `TerminalButtonProps`:
168
168
  - `action?(event)`
169
169
  - `onPress?(event)`
170
170
 
171
- Activacion actual:
171
+ Current activation paths:
172
172
 
173
173
  - `session.click(id?)`
174
174
  - `session.clickAt(x, y)`
175
- - `dispatchKey("ENTER")` o `dispatchKey("SPACE")` cuando el foco esta en el boton
175
+ - `dispatchKey("ENTER")` or `dispatchKey("SPACE")` when focus is on the button
176
176
 
177
- Payload importante:
177
+ Important payload:
178
178
 
179
179
  - `TerminalButtonPressEventPayload` - `{ type: "press" | "click", id }`
180
180
 
181
181
  ### `List<T>`
182
182
 
183
- Props de `TerminalListProps<T>`:
183
+ `TerminalListProps<T>` props:
184
184
 
185
185
  - `id?: string`
186
186
  - `focusable?: boolean`
@@ -195,14 +195,14 @@ Props de `TerminalListProps<T>`:
195
195
  - `oncapturestart?(event)`
196
196
  - `oncaptureend?(event)`
197
197
 
198
- Interaccion actual:
198
+ Current interaction:
199
199
 
200
- - `UP` y `LEFT` mueven la seleccion hacia arriba
201
- - `DOWN` y `RIGHT` mueven la seleccion hacia abajo
202
- - `ENTER` dispara `onpress`
203
- - el hover por mouse expone fila, indice y valor
200
+ - `UP` and `LEFT` move selection up
201
+ - `DOWN` and `RIGHT` move selection down
202
+ - `ENTER` triggers `onpress`
203
+ - mouse hover exposes row, index, and value
204
204
 
205
- Payloads importantes:
205
+ Important payloads:
206
206
 
207
207
  - `TerminalListChangeEventPayload<T>` - `{ type: "change", id, index, value }`
208
208
  - `TerminalListPressEventPayload<T>` - `{ type: "press", id, index, value }`
@@ -211,9 +211,9 @@ Payloads importantes:
211
211
 
212
212
  ### `ScrollView`
213
213
 
214
- Props de `TerminalScrollViewProps`:
214
+ `TerminalScrollViewProps` props:
215
215
 
216
- - props de layout (`direction`, `gap`, `padding`, `border`, `width`, `height`, `id`, `focusable`)
216
+ - layout props (`direction`, `gap`, `padding`, `border`, `width`, `height`, `id`, `focusable`)
217
217
  - `pointerCapture?: boolean`
218
218
  - `highlightRows?: number[]`
219
219
  - `onhover?(event)`
@@ -222,52 +222,52 @@ Props de `TerminalScrollViewProps`:
222
222
  - `oncapturestart?(event)`
223
223
  - `oncaptureend?(event)`
224
224
 
225
- Interaccion actual:
225
+ Current interaction:
226
226
 
227
- - `UP` y `DOWN` ajustan el offset vertical cuando tiene foco
228
- - el render recorta el contenido visible segun `height`
229
- - `highlightRows` marca filas visibles concretas
230
- - el hover por mouse expone fila visible y texto renderizado
227
+ - `UP` and `DOWN` adjust the vertical offset when it has focus
228
+ - rendering clips visible content based on `height`
229
+ - `highlightRows` marks specific visible rows
230
+ - mouse hover exposes the visible row and rendered text
231
231
 
232
- Payloads importantes:
232
+ Important payloads:
233
233
 
234
234
  - `TerminalScrollPointerEventPayload` - `{ type: "hover" | "rowenter" | "rowleave", id, row, value, x, y }`
235
235
  - `TerminalCaptureEventPayload` - `{ type: "capturestart" | "captureend", id, source, row, x, y }`
236
236
 
237
237
  ## `TerminalSession`
238
238
 
239
- Contrato publico de la sesion interactiva.
240
-
241
- - `update(): string` - vuelve a resolver la raiz y retorna la salida actual en texto plano
242
- - `output(): string` - devuelve el ultimo frame plano renderizado
243
- - `ansiOutput(): string` - devuelve el frame actual serializado con ANSI
244
- - `tree(): TerminalNode[]` - expone el arbol terminal resuelto actual
245
- - `focus(id: string): boolean` - enfoca un nodo interactivo por `id`
246
- - `focusAt(x: number, y: number): boolean` - enfoca por hitbox calculado
247
- - `focusNext(): boolean` - recorre el foco en orden de render
248
- - `focusPrev(): boolean` - recorre el foco hacia atras
249
- - `dispatchKey(key: string): string` - inyecta una tecla normalizada y devuelve la salida actual
250
- - `click(id?: string): string` - activa el boton enfocado o uno especifico por `id`
251
- - `clickAt(x: number, y: number): string` - activa o enfoca usando coordenadas
252
- - `clipboard(): string` - devuelve el ultimo valor de clipboard conocido por la sesion
253
- - `setClipboard(value: string): string` - actualiza el clipboard interno y, si existe, el adapter
254
- - `selectAll(): string` - selecciona todo el contenido del `Input` enfocado
255
- - `destroy(): void` - desmonta listeners de `stdin`, sale de raw mode y pausa el stream si aplica
256
-
257
- ## Tipos utilitarios relevantes
258
-
259
- - `TerminalMountOptions` - opciones para montar la sesion
260
- - `TerminalClipboardAdapter` - contrato minimo para integrar clipboard externo
261
- - `TerminalFrame` - frame renderizado con `lines`, `hitboxes`, `cursor` y `spans`
262
- - `TerminalHitbox` - region interactiva calculada para foco y clicks por coordenadas
263
- - `TerminalStyleSpan` - marca visual como `selection`, `focus` o `highlight`
264
- - `TerminalNode`, `TerminalElementNode`, `TerminalTextNode` - arbol terminal resuelto
265
- - `TerminalLayoutProps` - base comun para `Box`, `View` y `ScrollView`
266
- - `TerminalFocusableProps` - `id` y `focusable`
267
- - `TerminalPointerCaptureProps` - `pointerCapture` para listas y scroll
268
- - `InputInteractionState` - posicion de cursor y ancla de seleccion
269
- - `TerminalChangeEventPayload` - union de cambios de `Input` y `List`
270
- - `TerminalPressEventPayload` - union de presses de `Button` y `List`
271
- - `TerminalPointerCoordinates` - coordenadas `x` y `y` opcionales en payloads de mouse
239
+ Public contract for the interactive session.
240
+
241
+ - `update(): string` - resolves the root again and returns the current plain-text output
242
+ - `output(): string` - returns the last rendered plain frame
243
+ - `ansiOutput(): string` - returns the current frame serialized as ANSI
244
+ - `tree(): TerminalNode[]` - exposes the current resolved terminal tree
245
+ - `focus(id: string): boolean` - focuses an interactive node by `id`
246
+ - `focusAt(x: number, y: number): boolean` - focuses by computed hitbox
247
+ - `focusNext(): boolean` - moves focus forward in render order
248
+ - `focusPrev(): boolean` - moves focus backward in render order
249
+ - `dispatchKey(key: string): string` - injects a normalized key and returns the current output
250
+ - `click(id?: string): string` - activates the focused button or a specific one by `id`
251
+ - `clickAt(x: number, y: number): string` - activates or focuses using coordinates
252
+ - `clipboard(): string` - returns the last clipboard value known by the session
253
+ - `setClipboard(value: string): string` - updates the internal clipboard and, if present, the adapter
254
+ - `selectAll(): string` - selects all content in the focused `Input`
255
+ - `destroy(): void` - removes `stdin` listeners, exits raw mode, and pauses the stream when applicable
256
+
257
+ ## Relevant Utility Types
258
+
259
+ - `TerminalMountOptions` - options for mounting the session
260
+ - `TerminalClipboardAdapter` - minimum contract for integrating an external clipboard
261
+ - `TerminalFrame` - rendered frame with `lines`, `hitboxes`, `cursor`, and `spans`
262
+ - `TerminalHitbox` - computed interactive region for focus and coordinate-based clicks
263
+ - `TerminalStyleSpan` - visual marker such as `selection`, `focus`, or `highlight`
264
+ - `TerminalNode`, `TerminalElementNode`, `TerminalTextNode` - resolved terminal tree
265
+ - `TerminalLayoutProps` - shared base for `Box`, `View`, and `ScrollView`
266
+ - `TerminalFocusableProps` - `id` and `focusable`
267
+ - `TerminalPointerCaptureProps` - `pointerCapture` for lists and scroll views
268
+ - `InputInteractionState` - cursor position and selection anchor
269
+ - `TerminalChangeEventPayload` - union of `Input` and `List` change events
270
+ - `TerminalPressEventPayload` - union of `Button` and `List` press events
271
+ - `TerminalPointerCoordinates` - optional `x` and `y` coordinates in mouse payloads
272
272
  - `TerminalMouseEventType` - `"hover" | "rowenter" | "rowleave"`
273
273
  - `TerminalPointerSource` - `"press" | "drag" | "release"`
package/docs/cookbook.md CHANGED
@@ -1,10 +1,10 @@
1
1
  # Cookbook
2
2
 
3
- Recetas cortas y copiables para `valyrianjs-terminal`. Esta guia complementa `docs/getting-started.md`, `docs/interaction-model.md` y `docs/api-reference.md`.
3
+ Short, copyable recipes for `valyrianjs-terminal`. This guide complements `docs/getting-started.md`, `docs/interaction-model.md`, and `docs/api-reference.md`.
4
4
 
5
- ## Render estatico para snapshots
5
+ ## Static rendering for snapshots
6
6
 
7
- Usalo cuando quieras validar layout o generar texto plano sin abrir una sesion interactiva.
7
+ Use this when you want to validate layout or generate plain text without opening an interactive session.
8
8
 
9
9
  ```tsx
10
10
  /** @jsx v */
@@ -23,9 +23,9 @@ const output = renderTerminal(
23
23
  console.log(output);
24
24
  ```
25
25
 
26
- ## Input controlado con submit
26
+ ## Controlled input with submit
27
27
 
28
- Usalo cuando necesites un campo editable que guarde el valor final al presionar `Enter`.
28
+ Use this when you need an editable field that stores the final value when `Enter` is pressed.
29
29
 
30
30
  ```tsx
31
31
  /** @jsx v */
@@ -62,9 +62,9 @@ console.log(state.submitted);
62
62
  console.log(session.output());
63
63
  ```
64
64
 
65
- ## Boton que muta estado
65
+ ## Button that mutates state
66
66
 
67
- Usalo cuando quieras activar acciones simples desde teclado o click programatico.
67
+ Use this when you want to trigger simple actions from the keyboard or by programmatic click.
68
68
 
69
69
  ```tsx
70
70
  /** @jsx v */
@@ -95,9 +95,9 @@ session.click("increment");
95
95
  console.log(session.output());
96
96
  ```
97
97
 
98
- ## Lista interactiva con `onchange` y `onpress`
98
+ ## Interactive list with `onchange` and `onpress`
99
99
 
100
- Usalo cuando quieras separar el item actualmente seleccionado del item activado con `Enter`.
100
+ Use this when you want to separate the currently selected item from the item activated with `Enter`.
101
101
 
102
102
  ```tsx
103
103
  /** @jsx v */
@@ -134,9 +134,9 @@ console.log(state.selected);
134
134
  console.log(state.opened);
135
135
  ```
136
136
 
137
- ## Scroll view con `height` y `highlightRows`
137
+ ## Scroll view with `height` and `highlightRows`
138
138
 
139
- Usalo para recortar contenido vertical y marcar filas relevantes dentro del viewport.
139
+ Use this to clip vertical content and mark relevant rows inside the viewport.
140
140
 
141
141
  ```tsx
142
142
  /** @jsx v */
@@ -164,9 +164,9 @@ console.log(session.output());
164
164
  console.log(session.ansiOutput());
165
165
  ```
166
166
 
167
- ## Clipboard adapter custom
167
+ ## Custom clipboard adapter
168
168
 
169
- Usalo cuando quieras conectar copiar y pegar con un portapapeles propio en lugar del estado interno de la sesion.
169
+ Use this when you want to connect copy and paste to your own clipboard implementation instead of the session's internal state.
170
170
 
171
171
  ```tsx
172
172
  /** @jsx v */
@@ -212,9 +212,9 @@ console.log(session.clipboard());
212
212
  console.log(state.value);
213
213
  ```
214
214
 
215
- ## Interaccion por coordenadas con `focusAt` y `clickAt`
215
+ ## Coordinate-based interaction with `focusAt` and `clickAt`
216
216
 
217
- Usalo en pruebas o adapters donde el punto de entrada real son coordenadas del frame y no ids conocidos.
217
+ Use this in tests or adapters where the real entry point is frame coordinates rather than known ids.
218
218
 
219
219
  ```tsx
220
220
  /** @jsx v */
@@ -243,9 +243,9 @@ console.log(session.output());
243
243
  console.log(state.clicks);
244
244
  ```
245
245
 
246
- ## Inspeccion de salida ANSI con `ansiOutput`
246
+ ## Inspect ANSI output with `ansiOutput`
247
247
 
248
- Usalo cuando necesites verificar cursor, estilos o secuencias ANSI en pruebas e integraciones.
248
+ Use this when you need to verify cursor position, styles, or ANSI sequences in tests and integrations.
249
249
 
250
250
  ```tsx
251
251
  /** @jsx v */
@@ -277,10 +277,10 @@ console.log(ansi);
277
277
  console.log(/\u001b\[[0-9]+;[0-9]+H/.test(ansi));
278
278
  ```
279
279
 
280
- ## Ver tambien
280
+ ## See also
281
281
 
282
- - `docs/getting-started.md` para el flujo minimo de montaje
283
- - `docs/core-concepts.md` para el modelo mental del paquete
284
- - `docs/interaction-model.md` para foco, teclado, mouse y clipboard
285
- - `docs/session-runtime.md` para lifecycle, streams y runtime de sesion
286
- - `docs/api-reference.md` para la superficie publica completa
282
+ - `docs/getting-started.md` for the minimal mounting flow
283
+ - `docs/core-concepts.md` for the package mental model
284
+ - `docs/interaction-model.md` for focus, keyboard, mouse, and clipboard
285
+ - `docs/session-runtime.md` for lifecycle, streams, and session runtime
286
+ - `docs/api-reference.md` for the full public surface