{-# LANGUAGE CPP #-}
module Colourista.Short
( b
, i
, u
) where
import Data.ByteString (ByteString)
#if __GLASGOW_HASKELL__ < 804
import Data.Semigroup (Semigroup)
#endif
import Data.String (IsString)
import Data.Text (Text)
import Colourista.Pure (bold, formatWith, italic, underline)
b :: (IsString str, Semigroup str) => str -> str
b :: str -> str
b = [str] -> str -> str
forall str. (IsString str, Semigroup str) => [str] -> str -> str
formatWith [str
forall str. IsString str => str
bold]
{-# SPECIALIZE b :: String -> String #-}
{-# SPECIALIZE b :: Text -> Text #-}
{-# SPECIALIZE b :: ByteString -> ByteString #-}
i :: (IsString str, Semigroup str) => str -> str
i :: str -> str
i = [str] -> str -> str
forall str. (IsString str, Semigroup str) => [str] -> str -> str
formatWith [str
forall str. IsString str => str
italic]
{-# SPECIALIZE i :: String -> String #-}
{-# SPECIALIZE i :: Text -> Text #-}
{-# SPECIALIZE i :: ByteString -> ByteString #-}
u :: (IsString str, Semigroup str) => str -> str
u :: str -> str
u = [str] -> str -> str
forall str. (IsString str, Semigroup str) => [str] -> str -> str
formatWith [str
forall str. IsString str => str
underline]
{-# SPECIALIZE u :: String -> String #-}
{-# SPECIALIZE u :: Text -> Text #-}
{-# SPECIALIZE u :: ByteString -> ByteString #-}