zwirn-0.2.3.1: app/zwirnmill/Keyboard/Draw.hs
module Keyboard.Draw where import Brick (Widget, fill, hBox, txt, vBox) import UI.Core (Keyboard (..), Name) drawKeyboard :: (Int, Int) -> Keyboard -> Widget Name drawKeyboard (sx, _) (KeyB (Just sd)) = vBox (hBox [txt $ "keyboard: " <> sd, fill ' '] : replicate (sx - 1) (fill ' ')) drawKeyboard (sx, _) (KeyB Nothing) = vBox (hBox [txt "Please select an action"] : replicate (sx - 1) (fill ' '))