module UI.Attributes where import Brick import Brick.Forms import Graphics.Vty titleAttr :: AttrName titleAttr :: AttrName titleAttr = String -> AttrName attrName String "title" selectedAttr :: AttrName selectedAttr :: AttrName selectedAttr = String -> AttrName attrName String "selected" textboxAttr :: AttrName textboxAttr :: AttrName textboxAttr = String -> AttrName attrName String "textbox" highlightedChoiceAttr :: AttrName highlightedChoiceAttr :: AttrName highlightedChoiceAttr = String -> AttrName attrName String "highlighted choice" incorrectChoiceAttr :: AttrName incorrectChoiceAttr :: AttrName incorrectChoiceAttr = String -> AttrName attrName String "incorrect choice" correctChoiceAttr :: AttrName correctChoiceAttr :: AttrName correctChoiceAttr = String -> AttrName attrName String "correct choice" highlightedOptAttr :: AttrName highlightedOptAttr :: AttrName highlightedOptAttr = String -> AttrName attrName String "highlighted option" selectedOptAttr :: AttrName selectedOptAttr :: AttrName selectedOptAttr = String -> AttrName attrName String "selected option" correctOptAttr :: AttrName correctOptAttr :: AttrName correctOptAttr = String -> AttrName attrName String "correct option" incorrectOptAttr :: AttrName incorrectOptAttr :: AttrName incorrectOptAttr = String -> AttrName attrName String "incorrect option" gapAttr :: AttrName gapAttr :: AttrName gapAttr = String -> AttrName attrName String "gap" incorrectGapAttr :: AttrName incorrectGapAttr :: AttrName incorrectGapAttr = String -> AttrName attrName String "incorrect gap" correctGapAttr :: AttrName correctGapAttr :: AttrName correctGapAttr = String -> AttrName attrName String "correct gap" highlightedElementAttr :: AttrName highlightedElementAttr :: AttrName highlightedElementAttr = String -> AttrName attrName String "highlighted element" grabbedElementAttr :: AttrName grabbedElementAttr :: AttrName grabbedElementAttr = String -> AttrName attrName String "grabbed element" correctElementAttr :: AttrName correctElementAttr :: AttrName correctElementAttr = String -> AttrName attrName String "correct element" incorrectElementAttr :: AttrName incorrectElementAttr :: AttrName incorrectElementAttr = String -> AttrName attrName String "incorrect element" exceptionAttr :: AttrName exceptionAttr :: AttrName exceptionAttr = String -> AttrName attrName String "exception" shuffledAttr :: AttrName shuffledAttr :: AttrName shuffledAttr = String -> AttrName attrName String "shuffled indicator" yesButtonAttr :: AttrName yesButtonAttr :: AttrName yesButtonAttr = String -> AttrName attrName String "yes button" noButtonAttr :: AttrName noButtonAttr :: AttrName noButtonAttr = String -> AttrName attrName String "no button" selectedYesButtonAttr :: AttrName selectedYesButtonAttr :: AttrName selectedYesButtonAttr = String -> AttrName attrName String "selected yes button" selectedNoButtonAttr :: AttrName selectedNoButtonAttr :: AttrName selectedNoButtonAttr = String -> AttrName attrName String "selected no button" correctAttr :: AttrName correctAttr :: AttrName correctAttr = String -> AttrName attrName String "correct" wrongAttr :: AttrName wrongAttr :: AttrName wrongAttr = String -> AttrName attrName String "incorrect" theMap :: AttrMap theMap :: AttrMap theMap = Attr -> [(AttrName, Attr)] -> AttrMap attrMap Attr defAttr [ (AttrName titleAttr, Color -> Attr fg Color yellow) , (AttrName textboxAttr, Attr defAttr) , (AttrName highlightedChoiceAttr, Color -> Attr fg Color yellow) , (AttrName incorrectChoiceAttr, Color -> Attr fg Color red) , (AttrName correctChoiceAttr, Color -> Attr fg Color green) , (AttrName incorrectGapAttr, Color -> Attr fg Color red Attr -> Style -> Attr `withStyle` Style underline) , (AttrName correctGapAttr, Color -> Attr fg Color green Attr -> Style -> Attr `withStyle` Style underline) , (AttrName highlightedOptAttr, Color -> Attr fg Color yellow) , (AttrName selectedOptAttr, Color -> Attr fg Color blue) , (AttrName incorrectOptAttr, Color -> Attr fg Color red) , (AttrName correctOptAttr, Color -> Attr fg Color green) , (AttrName highlightedElementAttr, Color -> Attr fg Color yellow) , (AttrName grabbedElementAttr, Color -> Attr fg Color blue) , (AttrName correctElementAttr, Color -> Attr fg Color green) , (AttrName incorrectElementAttr, Color -> Attr fg Color red) , (AttrName gapAttr, Attr defAttr Attr -> Style -> Attr `withStyle` Style underline) , (AttrName selectedAttr, Attr defAttr Attr -> Style -> Attr `withStyle` Style underline) , (AttrName exceptionAttr, Color -> Attr fg Color red) , (AttrName focusedFormInputAttr, Attr defAttr Attr -> Style -> Attr `withStyle` Style underline) , (AttrName shuffledAttr, Color -> Attr fg Color red) , (AttrName correctAttr, Color -> Attr fg Color green) , (AttrName wrongAttr, Color -> Attr fg Color red) , (AttrName yesButtonAttr, Color -> Attr fg Color green) , (AttrName noButtonAttr, Color -> Attr fg Color red) , (AttrName selectedYesButtonAttr, Color -> Attr fg Color green Attr -> Style -> Attr `withStyle` Style underline) , (AttrName selectedNoButtonAttr, Color -> Attr fg Color red Attr -> Style -> Attr `withStyle` Style underline) ]