git.iko.soy/typeable/inflections-hs
on master help sign in
Merge pull request #46 from rcook/rcook-fix-typo
f103a07Juan Paucar
Text/Inflections/Titleize.hs+2−2
@@ -17,7 +17,7 @@ import Data.Text (Text)
17import Text.Inflections.Types
17import Text.Inflections.Types
18import qualified Data.Text as T
18import qualified Data.Text as T
19
19
20−-- | Capitalize all the Words in the input list.
20+-- | Capitalize all the 'SomeWord' words in the input list.
21--
21--
22-- >>> foo <- SomeWord <$> mkWord "foo"
22-- >>> foo <- SomeWord <$> mkWord "foo"
23-- >>> bar <- SomeWord <$> mkAcronym "bar"
23-- >>> bar <- SomeWord <$> mkAcronym "bar"
@@ -25,6 +25,6 @@ import qualified Data.Text as T
25-- >>> titleize [foo,bar,bazz]
25-- >>> titleize [foo,bar,bazz]
26-- "Foo bar Bazz"
26-- "Foo bar Bazz"
27titleize
27titleize
28− :: [SomeWord] -- ^ List of words, first of which will be capitalized
28+ :: [SomeWord] -- ^ List of words, of which all 'SomeWord' words will be capitalized and all acronyms will be left as is
29 -> Text -- ^ The titleized 'Text'
29 -> Text -- ^ The titleized 'Text'
30titleize = T.unwords . fmap (unSomeWord T.toTitle)
30titleize = T.unwords . fmap (unSomeWord T.toTitle)