module JSDOM.Generated.Element
(hasAttributes, hasAttributes_, getAttributeNames,
getAttributeNames_, getAttribute, getAttribute_,
getAttributeUnsafe, getAttributeUnchecked, getAttributeNS,
getAttributeNS_, getAttributeNSUnsafe, getAttributeNSUnchecked,
setAttribute, setAttributeNS, removeAttribute, removeAttributeNS,
hasAttribute, hasAttribute_, hasAttributeNS, hasAttributeNS_,
getAttributeNode, getAttributeNode_, getAttributeNodeUnsafe,
getAttributeNodeUnchecked, getAttributeNodeNS, getAttributeNodeNS_,
getAttributeNodeNSUnsafe, getAttributeNodeNSUnchecked,
setAttributeNode, setAttributeNode_, setAttributeNodeUnsafe,
setAttributeNodeUnchecked, setAttributeNodeNS, setAttributeNodeNS_,
setAttributeNodeNSUnsafe, setAttributeNodeNSUnchecked,
removeAttributeNode, removeAttributeNode_, attachShadow,
attachShadow_, closest, closest_, closestUnsafe, closestUnchecked,
matches, matches_, webkitMatchesSelector, webkitMatchesSelector_,
getElementsByTagName, getElementsByTagName_,
getElementsByTagNameNS, getElementsByTagNameNS_,
getElementsByClassName, getElementsByClassName_,
insertAdjacentElement, insertAdjacentElement_,
insertAdjacentElementUnsafe, insertAdjacentElementUnchecked,
insertAdjacentText, getClientRects, getClientRects_,
getBoundingClientRect, getBoundingClientRect_, scrollIntoView,
scrollOpt, scroll, scrollToOpt, scrollTo, scrollByOpt, scrollBy,
insertAdjacentHTML, webkitRequestFullScreen,
webkitRequestFullscreen, requestPointerLock,
webkitGetRegionFlowRanges, webkitGetRegionFlowRanges_,
scrollIntoViewIfNeeded, getNamespaceURI, getNamespaceURIUnsafe,
getNamespaceURIUnchecked, getPrefix, getPrefixUnsafe,
getPrefixUnchecked, getLocalName, getTagName, setId, getId,
setClassName, getClassName, getClassList, setSlot, getSlot,
getAttributes, getShadowRoot, getShadowRootUnsafe,
getShadowRootUnchecked, setScrollTop, getScrollTop, setScrollLeft,
getScrollLeft, getScrollWidth, getScrollHeight, getClientTop,
getClientLeft, getClientWidth, getClientHeight, setInnerHTML,
getInnerHTML, setOuterHTML, getOuterHTML, getWebkitRegionOverset,
selectStart, gestureChange, gestureEnd, gestureStart,
webKitAnimationEnd, webKitAnimationIteration, webKitAnimationStart,
webKitTransitionEnd, webKitFullscreenChange, webKitFullscreenError,
focusin, focusout, beforeload, webKitNeedKey,
webKitPresentationModeChanged,
webKitCurrentPlaybackTargetIsWirelessChanged,
webKitPlaybackTargetAvailabilityChanged, Element(..), gTypeElement,
IsElement, toElement)
where
import Prelude ((.), (==), (>>=), return, IO, Int, Float, Double, Bool(..), Maybe, maybe, fromIntegral, round, realToFrac, fmap, Show, Read, Eq, Ord, Maybe(..))
import qualified Prelude (error)
import Data.Typeable (Typeable)
import Data.Traversable (mapM)
import Language.Javascript.JSaddle (JSM(..), JSVal(..), JSString, strictEqual, toJSVal, valToStr, valToNumber, valToBool, js, jss, jsf, jsg, function, asyncFunction, new, array, jsUndefined, (!), (!!))
import Data.Int (Int64)
import Data.Word (Word, Word64)
import JSDOM.Types
import Control.Applicative ((<$>))
import Control.Monad (void)
import Control.Lens.Operators ((^.))
import JSDOM.EventTargetClosures (EventName, unsafeEventName)
import JSDOM.Enums
hasAttributes :: (MonadDOM m, IsElement self) => self -> m Bool
hasAttributes self
= liftDOM
(((toElement self) ^. jsf "hasAttributes" ()) >>= valToBool)
hasAttributes_ :: (MonadDOM m, IsElement self) => self -> m ()
hasAttributes_ self
= liftDOM (void ((toElement self) ^. jsf "hasAttributes" ()))
getAttributeNames ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m [result]
getAttributeNames self
= liftDOM
(((toElement self) ^. jsf "getAttributeNames" ()) >>=
fromJSArrayUnchecked)
getAttributeNames_ :: (MonadDOM m, IsElement self) => self -> m ()
getAttributeNames_ self
= liftDOM (void ((toElement self) ^. jsf "getAttributeNames" ()))
getAttribute ::
(MonadDOM m, IsElement self, ToJSString qualifiedName,
FromJSString result) =>
self -> qualifiedName -> m (Maybe result)
getAttribute self qualifiedName
= liftDOM
(((toElement self) ^. jsf "getAttribute" [toJSVal qualifiedName])
>>= fromJSVal)
getAttribute_ ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m ()
getAttribute_ self qualifiedName
= liftDOM
(void
((toElement self) ^. jsf "getAttribute" [toJSVal qualifiedName]))
getAttributeUnsafe ::
(MonadDOM m, IsElement self, ToJSString qualifiedName,
HasCallStack, FromJSString result) =>
self -> qualifiedName -> m result
getAttributeUnsafe self qualifiedName
= liftDOM
((((toElement self) ^. jsf "getAttribute" [toJSVal qualifiedName])
>>= fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
getAttributeUnchecked ::
(MonadDOM m, IsElement self, ToJSString qualifiedName,
FromJSString result) =>
self -> qualifiedName -> m result
getAttributeUnchecked self qualifiedName
= liftDOM
(((toElement self) ^. jsf "getAttribute" [toJSVal qualifiedName])
>>= fromJSValUnchecked)
getAttributeNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName, FromJSString result) =>
self -> Maybe namespaceURI -> localName -> m (Maybe result)
getAttributeNS self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "getAttributeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSVal)
getAttributeNS_ ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m ()
getAttributeNS_ self namespaceURI localName
= liftDOM
(void
((toElement self) ^. jsf "getAttributeNS"
[toJSVal namespaceURI, toJSVal localName]))
getAttributeNSUnsafe ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName, HasCallStack, FromJSString result) =>
self -> Maybe namespaceURI -> localName -> m result
getAttributeNSUnsafe self namespaceURI localName
= liftDOM
((((toElement self) ^. jsf "getAttributeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
getAttributeNSUnchecked ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName, FromJSString result) =>
self -> Maybe namespaceURI -> localName -> m result
getAttributeNSUnchecked self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "getAttributeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSValUnchecked)
setAttribute ::
(MonadDOM m, IsElement self, ToJSString qualifiedName,
ToJSString value) =>
self -> qualifiedName -> value -> m ()
setAttribute self qualifiedName value
= liftDOM
(void
((toElement self) ^. jsf "setAttribute"
[toJSVal qualifiedName, toJSVal value]))
setAttributeNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString qualifiedName, ToJSString value) =>
self -> Maybe namespaceURI -> qualifiedName -> value -> m ()
setAttributeNS self namespaceURI qualifiedName value
= liftDOM
(void
((toElement self) ^. jsf "setAttributeNS"
[toJSVal namespaceURI, toJSVal qualifiedName, toJSVal value]))
removeAttribute ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m ()
removeAttribute self qualifiedName
= liftDOM
(void
((toElement self) ^. jsf "removeAttribute"
[toJSVal qualifiedName]))
removeAttributeNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m ()
removeAttributeNS self namespaceURI localName
= liftDOM
(void
((toElement self) ^. jsf "removeAttributeNS"
[toJSVal namespaceURI, toJSVal localName]))
hasAttribute ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m Bool
hasAttribute self qualifiedName
= liftDOM
(((toElement self) ^. jsf "hasAttribute" [toJSVal qualifiedName])
>>= valToBool)
hasAttribute_ ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m ()
hasAttribute_ self qualifiedName
= liftDOM
(void
((toElement self) ^. jsf "hasAttribute" [toJSVal qualifiedName]))
hasAttributeNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m Bool
hasAttributeNS self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "hasAttributeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= valToBool)
hasAttributeNS_ ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m ()
hasAttributeNS_ self namespaceURI localName
= liftDOM
(void
((toElement self) ^. jsf "hasAttributeNS"
[toJSVal namespaceURI, toJSVal localName]))
getAttributeNode ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m (Maybe Attr)
getAttributeNode self qualifiedName
= liftDOM
(((toElement self) ^. jsf "getAttributeNode"
[toJSVal qualifiedName])
>>= fromJSVal)
getAttributeNode_ ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m ()
getAttributeNode_ self qualifiedName
= liftDOM
(void
((toElement self) ^. jsf "getAttributeNode"
[toJSVal qualifiedName]))
getAttributeNodeUnsafe ::
(MonadDOM m, IsElement self, ToJSString qualifiedName,
HasCallStack) =>
self -> qualifiedName -> m Attr
getAttributeNodeUnsafe self qualifiedName
= liftDOM
((((toElement self) ^. jsf "getAttributeNode"
[toJSVal qualifiedName])
>>= fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
getAttributeNodeUnchecked ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m Attr
getAttributeNodeUnchecked self qualifiedName
= liftDOM
(((toElement self) ^. jsf "getAttributeNode"
[toJSVal qualifiedName])
>>= fromJSValUnchecked)
getAttributeNodeNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m (Maybe Attr)
getAttributeNodeNS self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "getAttributeNodeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSVal)
getAttributeNodeNS_ ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m ()
getAttributeNodeNS_ self namespaceURI localName
= liftDOM
(void
((toElement self) ^. jsf "getAttributeNodeNS"
[toJSVal namespaceURI, toJSVal localName]))
getAttributeNodeNSUnsafe ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName, HasCallStack) =>
self -> Maybe namespaceURI -> localName -> m Attr
getAttributeNodeNSUnsafe self namespaceURI localName
= liftDOM
((((toElement self) ^. jsf "getAttributeNodeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
getAttributeNodeNSUnchecked ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m Attr
getAttributeNodeNSUnchecked self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "getAttributeNodeNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSValUnchecked)
setAttributeNode ::
(MonadDOM m, IsElement self) => self -> Attr -> m (Maybe Attr)
setAttributeNode self attr
= liftDOM
(((toElement self) ^. jsf "setAttributeNode" [toJSVal attr]) >>=
fromJSVal)
setAttributeNode_ ::
(MonadDOM m, IsElement self) => self -> Attr -> m ()
setAttributeNode_ self attr
= liftDOM
(void ((toElement self) ^. jsf "setAttributeNode" [toJSVal attr]))
setAttributeNodeUnsafe ::
(MonadDOM m, IsElement self, HasCallStack) =>
self -> Attr -> m Attr
setAttributeNodeUnsafe self attr
= liftDOM
((((toElement self) ^. jsf "setAttributeNode" [toJSVal attr]) >>=
fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
setAttributeNodeUnchecked ::
(MonadDOM m, IsElement self) => self -> Attr -> m Attr
setAttributeNodeUnchecked self attr
= liftDOM
(((toElement self) ^. jsf "setAttributeNode" [toJSVal attr]) >>=
fromJSValUnchecked)
setAttributeNodeNS ::
(MonadDOM m, IsElement self) => self -> Attr -> m (Maybe Attr)
setAttributeNodeNS self attr
= liftDOM
(((toElement self) ^. jsf "setAttributeNodeNS" [toJSVal attr]) >>=
fromJSVal)
setAttributeNodeNS_ ::
(MonadDOM m, IsElement self) => self -> Attr -> m ()
setAttributeNodeNS_ self attr
= liftDOM
(void
((toElement self) ^. jsf "setAttributeNodeNS" [toJSVal attr]))
setAttributeNodeNSUnsafe ::
(MonadDOM m, IsElement self, HasCallStack) =>
self -> Attr -> m Attr
setAttributeNodeNSUnsafe self attr
= liftDOM
((((toElement self) ^. jsf "setAttributeNodeNS" [toJSVal attr]) >>=
fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
setAttributeNodeNSUnchecked ::
(MonadDOM m, IsElement self) => self -> Attr -> m Attr
setAttributeNodeNSUnchecked self attr
= liftDOM
(((toElement self) ^. jsf "setAttributeNodeNS" [toJSVal attr]) >>=
fromJSValUnchecked)
removeAttributeNode ::
(MonadDOM m, IsElement self) => self -> Attr -> m Attr
removeAttributeNode self attr
= liftDOM
(((toElement self) ^. jsf "removeAttributeNode" [toJSVal attr]) >>=
fromJSValUnchecked)
removeAttributeNode_ ::
(MonadDOM m, IsElement self) => self -> Attr -> m ()
removeAttributeNode_ self attr
= liftDOM
(void
((toElement self) ^. jsf "removeAttributeNode" [toJSVal attr]))
attachShadow ::
(MonadDOM m, IsElement self) =>
self -> ShadowRootInit -> m ShadowRoot
attachShadow self init
= liftDOM
(((toElement self) ^. jsf "attachShadow" [toJSVal init]) >>=
fromJSValUnchecked)
attachShadow_ ::
(MonadDOM m, IsElement self) => self -> ShadowRootInit -> m ()
attachShadow_ self init
= liftDOM
(void ((toElement self) ^. jsf "attachShadow" [toJSVal init]))
closest ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m (Maybe Element)
closest self selectors
= liftDOM
(((toElement self) ^. jsf "closest" [toJSVal selectors]) >>=
fromJSVal)
closest_ ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m ()
closest_ self selectors
= liftDOM
(void ((toElement self) ^. jsf "closest" [toJSVal selectors]))
closestUnsafe ::
(MonadDOM m, IsElement self, ToJSString selectors, HasCallStack) =>
self -> selectors -> m Element
closestUnsafe self selectors
= liftDOM
((((toElement self) ^. jsf "closest" [toJSVal selectors]) >>=
fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
closestUnchecked ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m Element
closestUnchecked self selectors
= liftDOM
(((toElement self) ^. jsf "closest" [toJSVal selectors]) >>=
fromJSValUnchecked)
matches ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m Bool
matches self selectors
= liftDOM
(((toElement self) ^. jsf "matches" [toJSVal selectors]) >>=
valToBool)
matches_ ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m ()
matches_ self selectors
= liftDOM
(void ((toElement self) ^. jsf "matches" [toJSVal selectors]))
webkitMatchesSelector ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m Bool
webkitMatchesSelector self selectors
= liftDOM
(((toElement self) ^. jsf "webkitMatchesSelector"
[toJSVal selectors])
>>= valToBool)
webkitMatchesSelector_ ::
(MonadDOM m, IsElement self, ToJSString selectors) =>
self -> selectors -> m ()
webkitMatchesSelector_ self selectors
= liftDOM
(void
((toElement self) ^. jsf "webkitMatchesSelector"
[toJSVal selectors]))
getElementsByTagName ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m HTMLCollection
getElementsByTagName self qualifiedName
= liftDOM
(((toElement self) ^. jsf "getElementsByTagName"
[toJSVal qualifiedName])
>>= fromJSValUnchecked)
getElementsByTagName_ ::
(MonadDOM m, IsElement self, ToJSString qualifiedName) =>
self -> qualifiedName -> m ()
getElementsByTagName_ self qualifiedName
= liftDOM
(void
((toElement self) ^. jsf "getElementsByTagName"
[toJSVal qualifiedName]))
getElementsByTagNameNS ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m HTMLCollection
getElementsByTagNameNS self namespaceURI localName
= liftDOM
(((toElement self) ^. jsf "getElementsByTagNameNS"
[toJSVal namespaceURI, toJSVal localName])
>>= fromJSValUnchecked)
getElementsByTagNameNS_ ::
(MonadDOM m, IsElement self, ToJSString namespaceURI,
ToJSString localName) =>
self -> Maybe namespaceURI -> localName -> m ()
getElementsByTagNameNS_ self namespaceURI localName
= liftDOM
(void
((toElement self) ^. jsf "getElementsByTagNameNS"
[toJSVal namespaceURI, toJSVal localName]))
getElementsByClassName ::
(MonadDOM m, IsElement self, ToJSString name) =>
self -> name -> m HTMLCollection
getElementsByClassName self name
= liftDOM
(((toElement self) ^. jsf "getElementsByClassName" [toJSVal name])
>>= fromJSValUnchecked)
getElementsByClassName_ ::
(MonadDOM m, IsElement self, ToJSString name) =>
self -> name -> m ()
getElementsByClassName_ self name
= liftDOM
(void
((toElement self) ^. jsf "getElementsByClassName" [toJSVal name]))
insertAdjacentElement ::
(MonadDOM m, IsElement self, ToJSString where',
IsElement element) =>
self -> where' -> element -> m (Maybe Element)
insertAdjacentElement self where' element
= liftDOM
(((toElement self) ^. jsf "insertAdjacentElement"
[toJSVal where', toJSVal element])
>>= fromJSVal)
insertAdjacentElement_ ::
(MonadDOM m, IsElement self, ToJSString where',
IsElement element) =>
self -> where' -> element -> m ()
insertAdjacentElement_ self where' element
= liftDOM
(void
((toElement self) ^. jsf "insertAdjacentElement"
[toJSVal where', toJSVal element]))
insertAdjacentElementUnsafe ::
(MonadDOM m, IsElement self, ToJSString where', IsElement element,
HasCallStack) =>
self -> where' -> element -> m Element
insertAdjacentElementUnsafe self where' element
= liftDOM
((((toElement self) ^. jsf "insertAdjacentElement"
[toJSVal where', toJSVal element])
>>= fromJSVal)
>>= maybe (Prelude.error "Nothing to return") return)
insertAdjacentElementUnchecked ::
(MonadDOM m, IsElement self, ToJSString where',
IsElement element) =>
self -> where' -> element -> m Element
insertAdjacentElementUnchecked self where' element
= liftDOM
(((toElement self) ^. jsf "insertAdjacentElement"
[toJSVal where', toJSVal element])
>>= fromJSValUnchecked)
insertAdjacentText ::
(MonadDOM m, IsElement self, ToJSString where',
ToJSString data') =>
self -> where' -> data' -> m ()
insertAdjacentText self where' data'
= liftDOM
(void
((toElement self) ^. jsf "insertAdjacentText"
[toJSVal where', toJSVal data']))
getClientRects ::
(MonadDOM m, IsElement self) => self -> m [DOMRect]
getClientRects self
= liftDOM
(((toElement self) ^. jsf "getClientRects" ()) >>=
fromJSArrayUnchecked)
getClientRects_ :: (MonadDOM m, IsElement self) => self -> m ()
getClientRects_ self
= liftDOM (void ((toElement self) ^. jsf "getClientRects" ()))
getBoundingClientRect ::
(MonadDOM m, IsElement self) => self -> m DOMRect
getBoundingClientRect self
= liftDOM
(((toElement self) ^. jsf "getBoundingClientRect" ()) >>=
fromJSValUnchecked)
getBoundingClientRect_ ::
(MonadDOM m, IsElement self) => self -> m ()
getBoundingClientRect_ self
= liftDOM
(void ((toElement self) ^. jsf "getBoundingClientRect" ()))
scrollIntoView ::
(MonadDOM m, IsElement self) => self -> Bool -> m ()
scrollIntoView self alignWithTop
= liftDOM
(void
((toElement self) ^. jsf "scrollIntoView" [toJSVal alignWithTop]))
scrollOpt ::
(MonadDOM m, IsElement self) =>
self -> Maybe ScrollToOptions -> m ()
scrollOpt self options
= liftDOM
(void ((toElement self) ^. jsf "scroll" [toJSVal options]))
scroll ::
(MonadDOM m, IsElement self) => self -> Double -> Double -> m ()
scroll self x y
= liftDOM
(void ((toElement self) ^. jsf "scroll" [toJSVal x, toJSVal y]))
scrollToOpt ::
(MonadDOM m, IsElement self) =>
self -> Maybe ScrollToOptions -> m ()
scrollToOpt self options
= liftDOM
(void ((toElement self) ^. jsf "scrollTo" [toJSVal options]))
scrollTo ::
(MonadDOM m, IsElement self) => self -> Double -> Double -> m ()
scrollTo self x y
= liftDOM
(void ((toElement self) ^. jsf "scrollTo" [toJSVal x, toJSVal y]))
scrollByOpt ::
(MonadDOM m, IsElement self) =>
self -> Maybe ScrollToOptions -> m ()
scrollByOpt self option
= liftDOM
(void ((toElement self) ^. jsf "scrollBy" [toJSVal option]))
scrollBy ::
(MonadDOM m, IsElement self) => self -> Double -> Double -> m ()
scrollBy self x y
= liftDOM
(void ((toElement self) ^. jsf "scrollBy" [toJSVal x, toJSVal y]))
insertAdjacentHTML ::
(MonadDOM m, IsElement self, ToJSString position,
ToJSString text) =>
self -> position -> text -> m ()
insertAdjacentHTML self position text
= liftDOM
(void
((toElement self) ^. jsf "insertAdjacentHTML"
[toJSVal position, toJSVal text]))
webkitRequestFullScreen ::
(MonadDOM m, IsElement self) => self -> m ()
webkitRequestFullScreen self
= liftDOM
(void ((toElement self) ^. jsf "webkitRequestFullScreen" ()))
webkitRequestFullscreen ::
(MonadDOM m, IsElement self) => self -> m ()
webkitRequestFullscreen self
= liftDOM
(void ((toElement self) ^. jsf "webkitRequestFullscreen" ()))
requestPointerLock :: (MonadDOM m, IsElement self) => self -> m ()
requestPointerLock self
= liftDOM (void ((toElement self) ^. jsf "requestPointerLock" ()))
webkitGetRegionFlowRanges ::
(MonadDOM m, IsElement self) => self -> m (Maybe [Range])
webkitGetRegionFlowRanges self
= liftDOM
(((toElement self) ^. jsf "webkitGetRegionFlowRanges" ()) >>=
maybeNullOrUndefined' fromJSArrayUnchecked)
webkitGetRegionFlowRanges_ ::
(MonadDOM m, IsElement self) => self -> m ()
webkitGetRegionFlowRanges_ self
= liftDOM
(void ((toElement self) ^. jsf "webkitGetRegionFlowRanges" ()))
scrollIntoViewIfNeeded ::
(MonadDOM m, IsElement self) => self -> Bool -> m ()
scrollIntoViewIfNeeded self centerIfNeeded
= liftDOM
(void
((toElement self) ^. jsf "scrollIntoViewIfNeeded"
[toJSVal centerIfNeeded]))
getNamespaceURI ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m (Maybe result)
getNamespaceURI self
= liftDOM (((toElement self) ^. js "namespaceURI") >>= fromJSVal)
getNamespaceURIUnsafe ::
(MonadDOM m, IsElement self, HasCallStack, FromJSString result) =>
self -> m result
getNamespaceURIUnsafe self
= liftDOM
((((toElement self) ^. js "namespaceURI") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getNamespaceURIUnchecked ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getNamespaceURIUnchecked self
= liftDOM
(((toElement self) ^. js "namespaceURI") >>= fromJSValUnchecked)
getPrefix ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m (Maybe result)
getPrefix self
= liftDOM (((toElement self) ^. js "prefix") >>= fromJSVal)
getPrefixUnsafe ::
(MonadDOM m, IsElement self, HasCallStack, FromJSString result) =>
self -> m result
getPrefixUnsafe self
= liftDOM
((((toElement self) ^. js "prefix") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getPrefixUnchecked ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getPrefixUnchecked self
= liftDOM
(((toElement self) ^. js "prefix") >>= fromJSValUnchecked)
getLocalName ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getLocalName self
= liftDOM
(((toElement self) ^. js "localName") >>= fromJSValUnchecked)
getTagName ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getTagName self
= liftDOM
(((toElement self) ^. js "tagName") >>= fromJSValUnchecked)
setId ::
(MonadDOM m, IsElement self, ToJSString val) => self -> val -> m ()
setId self val
= liftDOM ((toElement self) ^. jss "id" (toJSVal val))
getId ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getId self
= liftDOM (((toElement self) ^. js "id") >>= fromJSValUnchecked)
setClassName ::
(MonadDOM m, IsElement self, ToJSString val) => self -> val -> m ()
setClassName self val
= liftDOM ((toElement self) ^. jss "className" (toJSVal val))
getClassName ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getClassName self
= liftDOM
(((toElement self) ^. js "className") >>= fromJSValUnchecked)
getClassList ::
(MonadDOM m, IsElement self) => self -> m DOMTokenList
getClassList self
= liftDOM
(((toElement self) ^. js "classList") >>= fromJSValUnchecked)
setSlot ::
(MonadDOM m, IsElement self, ToJSString val) => self -> val -> m ()
setSlot self val
= liftDOM ((toElement self) ^. jss "slot" (toJSVal val))
getSlot ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getSlot self
= liftDOM (((toElement self) ^. js "slot") >>= fromJSValUnchecked)
getAttributes ::
(MonadDOM m, IsElement self) => self -> m NamedNodeMap
getAttributes self
= liftDOM
(((toElement self) ^. js "attributes") >>= fromJSValUnchecked)
getShadowRoot ::
(MonadDOM m, IsElement self) => self -> m (Maybe ShadowRoot)
getShadowRoot self
= liftDOM (((toElement self) ^. js "shadowRoot") >>= fromJSVal)
getShadowRootUnsafe ::
(MonadDOM m, IsElement self, HasCallStack) => self -> m ShadowRoot
getShadowRootUnsafe self
= liftDOM
((((toElement self) ^. js "shadowRoot") >>= fromJSVal) >>=
maybe (Prelude.error "Nothing to return") return)
getShadowRootUnchecked ::
(MonadDOM m, IsElement self) => self -> m ShadowRoot
getShadowRootUnchecked self
= liftDOM
(((toElement self) ^. js "shadowRoot") >>= fromJSValUnchecked)
setScrollTop :: (MonadDOM m, IsElement self) => self -> Int -> m ()
setScrollTop self val
= liftDOM ((toElement self) ^. jss "scrollTop" (toJSVal val))
getScrollTop :: (MonadDOM m, IsElement self) => self -> m Int
getScrollTop self
= liftDOM
(round <$> (((toElement self) ^. js "scrollTop") >>= valToNumber))
setScrollLeft ::
(MonadDOM m, IsElement self) => self -> Int -> m ()
setScrollLeft self val
= liftDOM ((toElement self) ^. jss "scrollLeft" (toJSVal val))
getScrollLeft :: (MonadDOM m, IsElement self) => self -> m Int
getScrollLeft self
= liftDOM
(round <$> (((toElement self) ^. js "scrollLeft") >>= valToNumber))
getScrollWidth :: (MonadDOM m, IsElement self) => self -> m Int
getScrollWidth self
= liftDOM
(round <$>
(((toElement self) ^. js "scrollWidth") >>= valToNumber))
getScrollHeight :: (MonadDOM m, IsElement self) => self -> m Int
getScrollHeight self
= liftDOM
(round <$>
(((toElement self) ^. js "scrollHeight") >>= valToNumber))
getClientTop :: (MonadDOM m, IsElement self) => self -> m Double
getClientTop self
= liftDOM (((toElement self) ^. js "clientTop") >>= valToNumber)
getClientLeft :: (MonadDOM m, IsElement self) => self -> m Double
getClientLeft self
= liftDOM (((toElement self) ^. js "clientLeft") >>= valToNumber)
getClientWidth :: (MonadDOM m, IsElement self) => self -> m Double
getClientWidth self
= liftDOM (((toElement self) ^. js "clientWidth") >>= valToNumber)
getClientHeight :: (MonadDOM m, IsElement self) => self -> m Double
getClientHeight self
= liftDOM (((toElement self) ^. js "clientHeight") >>= valToNumber)
setInnerHTML ::
(MonadDOM m, IsElement self, ToJSString val) => self -> val -> m ()
setInnerHTML self val
= liftDOM ((toElement self) ^. jss "innerHTML" (toJSVal val))
getInnerHTML ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getInnerHTML self
= liftDOM
(((toElement self) ^. js "innerHTML") >>= fromJSValUnchecked)
setOuterHTML ::
(MonadDOM m, IsElement self, ToJSString val) => self -> val -> m ()
setOuterHTML self val
= liftDOM ((toElement self) ^. jss "outerHTML" (toJSVal val))
getOuterHTML ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getOuterHTML self
= liftDOM
(((toElement self) ^. js "outerHTML") >>= fromJSValUnchecked)
getWebkitRegionOverset ::
(MonadDOM m, IsElement self, FromJSString result) =>
self -> m result
getWebkitRegionOverset self
= liftDOM
(((toElement self) ^. js "webkitRegionOverset") >>=
fromJSValUnchecked)
selectStart ::
(IsElement self, IsEventTarget self) => EventName self Event
selectStart = unsafeEventName (toJSString "selectstart")
gestureChange ::
(IsElement self, IsEventTarget self) => EventName self UIEvent
gestureChange = unsafeEventName (toJSString "gesturechange")
gestureEnd ::
(IsElement self, IsEventTarget self) => EventName self UIEvent
gestureEnd = unsafeEventName (toJSString "gestureend")
gestureStart ::
(IsElement self, IsEventTarget self) => EventName self UIEvent
gestureStart = unsafeEventName (toJSString "gesturestart")
webKitAnimationEnd ::
(IsElement self, IsEventTarget self) =>
EventName self AnimationEvent
webKitAnimationEnd
= unsafeEventName (toJSString "webkitanimationend")
webKitAnimationIteration ::
(IsElement self, IsEventTarget self) =>
EventName self AnimationEvent
webKitAnimationIteration
= unsafeEventName (toJSString "webkitanimationiteration")
webKitAnimationStart ::
(IsElement self, IsEventTarget self) =>
EventName self AnimationEvent
webKitAnimationStart
= unsafeEventName (toJSString "webkitanimationstart")
webKitTransitionEnd ::
(IsElement self, IsEventTarget self) =>
EventName self TransitionEvent
webKitTransitionEnd
= unsafeEventName (toJSString "webkittransitionend")
webKitFullscreenChange ::
(IsElement self, IsEventTarget self) => EventName self Event
webKitFullscreenChange
= unsafeEventName (toJSString "webkitfullscreenchange")
webKitFullscreenError ::
(IsElement self, IsEventTarget self) => EventName self Event
webKitFullscreenError
= unsafeEventName (toJSString "webkitfullscreenerror")
focusin ::
(IsElement self, IsEventTarget self) => EventName self onfocusin
focusin = unsafeEventName (toJSString "focusin")
focusout ::
(IsElement self, IsEventTarget self) => EventName self onfocusout
focusout = unsafeEventName (toJSString "focusout")
beforeload ::
(IsElement self, IsEventTarget self) => EventName self onbeforeload
beforeload = unsafeEventName (toJSString "beforeload")
webKitNeedKey ::
(IsElement self, IsEventTarget self) => EventName self Event
webKitNeedKey = unsafeEventName (toJSString "webkitneedkey")
webKitPresentationModeChanged ::
(IsElement self, IsEventTarget self) => EventName self Event
webKitPresentationModeChanged
= unsafeEventName (toJSString "webkitpresentationmodechanged")
webKitCurrentPlaybackTargetIsWirelessChanged ::
(IsElement self, IsEventTarget self) =>
EventName self Event
webKitCurrentPlaybackTargetIsWirelessChanged
= unsafeEventName
(toJSString "webkitcurrentplaybacktargetiswirelesschanged")
webKitPlaybackTargetAvailabilityChanged ::
(IsElement self, IsEventTarget self) => EventName self Event
webKitPlaybackTargetAvailabilityChanged
= unsafeEventName
(toJSString "webkitplaybacktargetavailabilitychanged")