-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Convert English words to title case
--
-- Capitalize all English words except articles (a, an, the),
-- coordinating conjunctions (for, and, nor, but, or, yet, so), and
-- prepositions (unless they begin or end the title). The prepositions
-- are taken from this list:
-- https://en.wikipedia.org/wiki/List_of_English_prepositions.
@package titlecase
@version 0.1.0.1
-- | As the name implies, this module is meant to be used only if you want
-- to get access to the internals, say, if you're unhappy with the
-- provided titlecase function.
-- Data.Text.Titlecase.Internal doesn't prevent you from creating
-- improperly capitalized Titlecase values. In any other case,
-- Data.Text.Titlecase is what you're looking for.
module Data.Text.Titlecase.Internal
newtype Titlecase
Titlecase :: Text -> Titlecase
unTitlecase :: Titlecase -> Text
newtype Article
Article :: Text -> Article
unArticle :: Article -> Text
newtype Conjunction
Conjunction :: Text -> Conjunction
unConjunction :: Conjunction -> Text
data Preposition
OneWordPreposition :: Text -> Preposition
TwoWordPreposition :: Text -> Text -> Preposition
ThreeWordPreposition :: Text -> Text -> Text -> Preposition
FourWordPreposition :: Text -> Text -> Text -> Text -> Preposition
-- | Capitalize the first character. Note that this function behaves
-- differently than toTitle.
toTitle :: Text -> Text
(<#>) :: Text -> Text -> Text
uncurry3 :: (a -> b -> c -> d) -> (a, b, c) -> d
uncurry4 :: (a -> b -> c -> d -> e) -> (a, b, c, d) -> e
isElem :: (a -> Text) -> NonEmpty a -> Text -> Bool
isArticle :: Text -> Bool
isOneWordPreposition :: Text -> Bool
isConjunction :: Text -> Bool
isTwoWordPreposition :: Text -> Text -> Bool
isThreeWordPreposition :: Text -> Text -> Text -> Bool
isFourWordPreposition :: Text -> Text -> Text -> Text -> Bool
unPreposition :: Preposition -> Text
articles :: NonEmpty Article
conjunctions :: NonEmpty Conjunction
prepositions :: NonEmpty Preposition
oneWordPrepositions :: NonEmpty Preposition
twoWordPrepositions :: NonEmpty Preposition
threeWordPrepositions :: NonEmpty Preposition
fourWordPrepositions :: NonEmpty Preposition
instance Eq Titlecase
instance Show Titlecase
instance Eq Article
instance Show Article
instance Eq Conjunction
instance Show Conjunction
instance Eq Preposition
instance Show Preposition
instance ToMarkup Titlecase
module Data.Text.Titlecase
data Titlecase
-- | Capitalize all English words except articles (a, an, the),
-- coordinating conjunctions (for, and, nor, but, or, yet, so),
-- and prepositions (unless they begin or end the title). The
-- prepositions are taken from this list:
-- https://en.wikipedia.org/wiki/List_of_English_prepositions.
titlecase :: Text -> Titlecase