@rlabs-inc/create-tui 0.1.2 → 0.1.3

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rlabs-inc/create-tui",
3
- "version": "0.1.2",
3
+ "version": "0.1.3",
4
4
  "description": "Create TUI Framework applications - The Terminal UI Framework for TypeScript/Bun",
5
5
  "type": "module",
6
6
  "bin": {
@@ -260,14 +260,10 @@ const APP_TUI = `<script lang="ts">
260
260
  `
261
261
 
262
262
  const COUNTER_TUI = `<script lang="ts">
263
- import { keyboard } from '@rlabs-inc/tui'
264
-
265
263
  const count = signal(0)
266
264
 
267
- keyboard.onKey((e) => {
268
- if (e.key === '+' || e.key === 'ArrowUp') count.value++
269
- if (e.key === '-' || e.key === 'ArrowDown') count.value--
270
- })
265
+ keyboard.onKey(['+', 'ArrowUp'], () => count.value++)
266
+ keyboard.onKey(['-', 'ArrowDown'], () => count.value--)
271
267
  </script>
272
268
 
273
269
  <box
package/src/index.ts CHANGED
@@ -12,7 +12,7 @@ import { parseArgs } from 'util'
12
12
  import { c, symbols } from './utils/colors'
13
13
  import { create } from './commands/create'
14
14
 
15
- const VERSION = '0.1.2'
15
+ const VERSION = '0.1.3'
16
16
 
17
17
  const HELP = `
18
18
  ${c.bold('@rlabs-inc/create-tui')} ${c.muted(`v${VERSION}`)}