This module defines foreign types and functions for working with the jQuery library.
data JQuery :: *The type of collections of jQuery-wrapped nodes.
data JQueryEvent :: *Type of jQuery event objects.
type Selector = StringA type synonym to help readability of type signatures.
ready :: forall eff a. Eff (dom :: DOM | eff) a -> Eff (dom :: DOM | eff) JQueryRun a function when the document is loaded.
select :: forall eff. Selector -> Eff (dom :: DOM | eff) JQueryWrapper function for jQuery selection $('..')
find :: forall eff. Selector -> JQuery -> Eff (dom :: DOM | eff) JQueryFind child nodes matching a selector
parent :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryGet the parent elements.
closest :: forall eff. Selector -> JQuery -> Eff (dom :: DOM | eff) JQueryFind the closest element matching the selector.
create :: forall eff. String -> Eff (dom :: DOM | eff) JQueryCreate an element.
setAttr :: forall eff a. String -> a -> JQuery -> Eff (dom :: DOM | eff) JQuerySet a single attribute.
attr :: forall eff attr. { | attr } -> JQuery -> Eff (dom :: DOM | eff) JQuerySet multiple attributes.
css :: forall eff css. { | css } -> JQuery -> Eff (dom :: DOM | eff) JQuerySet CSS properties.
hasClass :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) BooleanTest if an element has a CSS class.
toggleClass :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) JQueryToggle the specified CSS class.
setClass :: forall eff. String -> Boolean -> JQuery -> Eff (dom :: DOM | eff) JQuerySet the specified CSS class.
addClass :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) JQueryAdd the specified CSS class.
removeClass :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) JQueryRemove the specified CSS class.
setProp :: forall a eff. String -> a -> JQuery -> Eff (dom :: DOM | eff) JQuerySet a single property.
getProp :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) ForeignGet a property value.
append :: forall eff. JQuery -> JQuery -> Eff (dom :: DOM | eff) JQueryAppend the first node as a child node of the second.
remove :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryRemove selected elements.
clear :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryRemove child elements.
before :: forall eff. JQuery -> JQuery -> Eff (dom :: DOM | eff) JQueryInsert an element before another.
appendText :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) JQueryAppend text as a child node.
body :: forall eff. Eff (dom :: DOM | eff) JQueryGet the document body node.
getText :: forall eff. JQuery -> Eff (dom :: DOM | eff) StringGet the text content of an element.
setText :: forall eff. String -> JQuery -> Eff (dom :: DOM | eff) JQuerySet the text content of an element.
getValue :: forall eff. JQuery -> Eff (dom :: DOM | eff) ForeignGet the value of a form element.
setValue :: forall eff a. a -> JQuery -> Eff (dom :: DOM | eff) JQuerySet the value of a form element.
toggle :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryToggle visibility of an element.
setVisible :: forall eff. Boolean -> JQuery -> Eff (dom :: DOM | eff) JQuerySet the visibility of an element.
hide :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryHide elements.
display :: forall eff. JQuery -> Eff (dom :: DOM | eff) JQueryShow elements.
on :: forall eff a. String -> (JQueryEvent -> JQuery -> Eff (dom :: DOM | eff) a) -> JQuery -> Eff (dom :: DOM | eff) JQueryRegister an event handler.
on' :: forall eff a. String -> Selector -> (JQueryEvent -> JQuery -> Eff (dom :: DOM | eff) a) -> JQuery -> Eff (dom :: DOM | eff) JQueryRegister an event handler for elements matching a selector.
preventDefault :: forall eff. JQueryEvent -> Eff (dom :: DOM | eff) UnitPrevent the default action for an event.
stopPropagation :: forall eff. JQueryEvent -> Eff (dom :: DOM | eff) UnitStop propagation an event.
stopImmediatePropagation :: forall eff. JQueryEvent -> Eff (dom :: DOM | eff) UnitStop immediate propagation an event.