packages feed

digestive-functors-blaze 0.1.0.1 → 0.1.1.0

raw patch · 2 files changed

+15/−4 lines, 2 filesdep +textPVP: major bump suggested

API removals or changes: PVP suggests a major version bump

Dependencies added: text

API changes (from Hackage documentation)

- Text.Digestive.Blaze.Html5: inputText :: (Monad m, Functor m, FormInput i f) => Formlet m i e BlazeFormHtml String
+ Text.Digestive.Blaze.Html5: inputText :: (Monad m, Functor m, FormInput i f) => Formlet m i e BlazeFormHtml Text

Files

digestive-functors-blaze.cabal view
@@ -1,5 +1,5 @@ Name:          digestive-functors-blaze-Version:       0.1.0.1+Version:       0.1.1.0 Synopsis:      Blaze frontend for the digestive-functors library Description:   This is a blaze frontend for the digestive-functors library. @@ -21,4 +21,5 @@   Build-depends:     base               >= 4     && < 5,     digestive-functors >= 0.1.0 && < 0.2,-    blaze-html         >= 0.4   && < 0.6+    blaze-html         >= 0.4   && < 0.6,+    text               >= 0.11  && < 0.12
src/Text/Digestive/Blaze/Html5.hs view
@@ -21,6 +21,7 @@ import Control.Monad (forM_, unless, when) import Data.Maybe (fromMaybe) import Data.Monoid (mempty)+import Data.Text (Text)  import Text.Blaze.Html5 (Html, (!), toValue, toHtml) import qualified Text.Blaze.Html5 as H@@ -51,9 +52,18 @@ checked False x = x checked True  x = x ! A.checked "checked" +inputString :: (Monad m, Functor m, FormInput i f)+            => Formlet m i e BlazeFormHtml String+inputString = Forms.inputString $ \id' inp -> createFormHtml $ \cfg ->+    applyClasses' [htmlInputClasses] cfg $+        H.input ! A.type_ "text"+                ! A.name (toValue $ show id')+                ! A.id (toValue $ show id')+                ! A.value (toValue $ fromMaybe "" inp)+ inputText :: (Monad m, Functor m, FormInput i f)-          => Formlet m i e BlazeFormHtml String-inputText = Forms.inputString $ \id' inp -> createFormHtml $ \cfg ->+          => Formlet m i e BlazeFormHtml Text+inputText = Forms.inputText $ \id' inp -> createFormHtml $ \cfg ->     applyClasses' [htmlInputClasses] cfg $         H.input ! A.type_ "text"                 ! A.name (toValue $ show id')