mirror of
https://github.com/jtdaugherty/brick.git
synced 2024-12-29 08:55:13 +03:00
Types: re-export state monad functions as part of API
This commit is contained in:
parent
a5b3240758
commit
f2f8013d63
@ -203,7 +203,6 @@ executable brick-form-demo
|
||||
text,
|
||||
microlens,
|
||||
microlens-th,
|
||||
mtl,
|
||||
vty
|
||||
|
||||
executable brick-text-wrap-demo
|
||||
|
@ -3,7 +3,6 @@
|
||||
{-# LANGUAGE OverloadedStrings #-}
|
||||
module Main where
|
||||
|
||||
import Control.Monad.State (gets, modify)
|
||||
import qualified Data.Text as T
|
||||
import Lens.Micro ((^.))
|
||||
import Lens.Micro.TH
|
||||
|
@ -86,7 +86,6 @@ module Brick.Forms
|
||||
)
|
||||
where
|
||||
|
||||
import Control.Monad.State (gets, get, put, modify)
|
||||
import Graphics.Vty hiding (showCursor)
|
||||
#if !(MIN_VERSION_base(4,11,0))
|
||||
import Data.Monoid
|
||||
|
@ -93,6 +93,12 @@ module Brick.Types
|
||||
|
||||
-- * Renderer internals (for benchmarking)
|
||||
, RenderState
|
||||
|
||||
-- * Re-exports for convenience
|
||||
, get
|
||||
, gets
|
||||
, put
|
||||
, modify
|
||||
)
|
||||
where
|
||||
|
||||
|
@ -37,7 +37,6 @@ module Brick.Widgets.Dialog
|
||||
where
|
||||
|
||||
import Lens.Micro
|
||||
import Control.Monad.State (modify)
|
||||
#if !(MIN_VERSION_base(4,11,0))
|
||||
import Data.Monoid
|
||||
#endif
|
||||
|
@ -48,8 +48,6 @@ import Data.Monoid
|
||||
import Lens.Micro
|
||||
import Graphics.Vty (Event(..), Key(..), Modifier(..))
|
||||
|
||||
import Control.Monad.State (get, put)
|
||||
|
||||
import qualified Data.ByteString as BS
|
||||
import qualified Data.Text as T
|
||||
import qualified Data.Text.Encoding as T
|
||||
|
@ -143,7 +143,6 @@ where
|
||||
import qualified Control.Exception as E
|
||||
import Control.Monad (forM)
|
||||
import Control.Monad.IO.Class (liftIO)
|
||||
import Control.Monad.State (put, get, modify)
|
||||
import Data.Char (toLower, isPrint)
|
||||
import Data.Maybe (fromMaybe, isJust, fromJust)
|
||||
import qualified Data.Foldable as F
|
||||
|
@ -79,7 +79,7 @@ import Prelude hiding (reverse, splitAt)
|
||||
|
||||
import Control.Applicative ((<|>))
|
||||
import Data.Foldable (find, toList)
|
||||
import Control.Monad.State (evalState, modify, get, put)
|
||||
import Control.Monad.State (evalState)
|
||||
|
||||
import Lens.Micro ((^.), (^?), (&), (.~), (%~), _2, _head, set)
|
||||
import Data.Functor (($>))
|
||||
|
Loading…
Reference in New Issue
Block a user