~lucasemmoreira/hitter

16eed6e186e98eb1dffd87b5a1156d7eb3bc8012 — Lucas Moreira 2 years ago 67786fd
fix: tui with status
1 files changed, 3 insertions(+), 7 deletions(-)

M src/tui.janet
M src/tui.janet => src/tui.janet +3 -7
@@ 1,11 1,6 @@
(import janet-ncurses :as nc)

(def choices (array "Option 1" "Option 2" "Option 3"))

(def choices2 (array "Description 1" "Description 2" "Description 3"))

(defn run-ui [[names urls]]
  (printf "%P" urls)
(defn run-ui [[names statuses]]
  (nc/initscr)

  (nc/cbreak)


@@ 14,7 9,8 @@

  (nc/keypad (nc/stdscr) true)
  
  (def items (nc/items names urls))
  (def statuses (map (fn [status] (string status)) statuses))
  (def items (nc/items names statuses))

  (def menu (nc/new_menu items))