implemented rendering of left side of abacus widget
This commit is contained in:
@@ -36,11 +36,21 @@ module Abacus.App.Widgets.Internal (
|
||||
abacusRight,
|
||||
) where
|
||||
|
||||
import Lens.Micro.Platform ((^.))
|
||||
|
||||
import Abacus
|
||||
import Abacus.App.Types
|
||||
|
||||
abacusLeft :: AppState -> [String]
|
||||
abacusLeft = undefined
|
||||
abacusLeft s =
|
||||
" " : map
|
||||
(\n -> mark n : show n)
|
||||
[0..pred (getNumRungs $ s^.abacus)]
|
||||
++ [" "]
|
||||
where
|
||||
mark n = if n == s^.rungNum
|
||||
then '>'
|
||||
else ' '
|
||||
|
||||
beads :: Abacus -> [(String, String)]
|
||||
beads = undefined
|
||||
|
||||
Reference in New Issue
Block a user