Safe Haskell | None |
---|---|
Language | Haskell98 |
Synopsis
- resizeDetector :: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) => m a -> m (Event t (Maybe Double, Maybe Double), a)
- resizeDetectorWithStyle :: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) => Text -> m a -> m (Event t (Maybe Double, Maybe Double), a)
- resizeDetectorWithAttrs :: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) => Map Text Text -> m a -> m (Event t (Maybe Double, Maybe Double), a)
Documentation
resizeDetector :: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) => m a -> m (Event t (Maybe Double, Maybe Double), a) Source #
A widget that wraps the given widget in a div and fires an event when resized.
Adapted from github.com/marcj/css-element-queries
This function can cause strange scrollbars to appear in some circumstances. These can be hidden with pseudo selectors, for example, in webkit browsers: .wrapper *::-webkit-scrollbar { width: 0px; background: transparent; }
resizeDetectorWithStyle Source #
:: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) | |
=> Text | A css style string. Warning: It should not contain the "position" style attribute. |
-> m a | The embedded widget |
-> m (Event t (Maybe Double, Maybe Double), a) | An |
resizeDetectorWithAttrs Source #
:: (MonadJSM m, DomBuilder t m, PostBuild t m, TriggerEvent t m, PerformEvent t m, MonadHold t m, DomBuilderSpace m ~ GhcjsDomSpace, MonadJSM (Performable m), MonadFix m) | |
=> Map Text Text | A map of attributes. Warning: It should not modify the "position" style attribute. |
-> m a | The embedded widget |
-> m (Event t (Maybe Double, Maybe Double), a) | An |