diff options
| author | tv <tv@krebsco.de> | 2026-03-19 22:09:58 +0100 |
|---|---|---|
| committer | tv <tv@krebsco.de> | 2026-03-19 22:39:41 +0100 |
| commit | fdeb641fde5f82c3ad617c5c801ab40955fe62af (patch) | |
| tree | 3b741944473738fb79f4f50943b3975c20a6e9a1 /src/Much/Action.hs | |
| parent | 131e4f0ccf655095d13b05f69acdaa1c22b9e6d4 (diff) | |
blessings: 2 -> 3
Diffstat (limited to 'src/Much/Action.hs')
| -rw-r--r-- | src/Much/Action.hs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/Much/Action.hs b/src/Much/Action.hs index e798357..102bc2c 100644 --- a/src/Much/Action.hs +++ b/src/Much/Action.hs @@ -3,8 +3,9 @@ module Much.Action where -import Blessings.String.WCWidth +import Blessings (Blessings(SGR)) import Data.Maybe +import Data.String (fromString) import Data.Tree.Extra (setSubForest) import Data.Tree.Zipper qualified as Z import Much.State @@ -19,12 +20,12 @@ import Scanner displayKey :: String -> State -> IO State -displayKey s q = return q { flashMessage = Plain $ show s } +displayKey s q = return q { flashMessage = fromString (show s) } displayMouse :: Scan -> State -> IO State displayMouse info q = - return q { flashMessage = SGR [38,5,202] $ Plain $ show info } + return q { flashMessage = SGR [38,5,202] $ fromString (show info) } defaultMouse1Click :: Monad m => Int -> State -> m State defaultMouse1Click y q@State{..} = do @@ -36,7 +37,7 @@ defaultMouse1Click y q@State{..} = do case linearClickPos of Nothing -> return q - { flashMessage = Plain "nothing to click" + { flashMessage = "nothing to click" } Just i -> return q @@ -163,7 +164,7 @@ openFold q@State{..} = where handle = \case Left err -> - q { flashMessage = SGR [31] $ Plain err } + q { flashMessage = SGR [31] $ fromString err } Right sf -> q { cursor = Z.modifyTree (setSubForest sf) cursor } |
