This repository was archived by the owner on Oct 4, 2020. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Expand file tree Collapse file tree 2 files changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -85,3 +85,9 @@ exports._contentDocument = function (iframe) {
85
85
return iframe . contentDocument ;
86
86
} ;
87
87
} ;
88
+
89
+ exports . _contentWindow = function ( iframe ) {
90
+ return function ( ) {
91
+ return iframe . contentWindow ;
92
+ } ;
93
+ } ;
Original file line number Diff line number Diff line change @@ -10,6 +10,7 @@ module DOM.HTML.HTMLIFrameElement
10
10
, height
11
11
, setHeight
12
12
, contentDocument
13
+ , contentWindow
13
14
) where
14
15
15
16
import Prelude
@@ -20,7 +21,7 @@ import Data.Maybe (Maybe)
20
21
import Data.Nullable (Nullable , toMaybe )
21
22
22
23
import DOM (DOM )
23
- import DOM.HTML.Types (HTMLIFrameElement )
24
+ import DOM.HTML.Types (Window , HTMLIFrameElement )
24
25
import DOM.Node.Types (Document )
25
26
26
27
foreign import src :: forall eff . HTMLIFrameElement -> Eff (dom :: DOM | eff ) String
@@ -41,8 +42,10 @@ foreign import height :: forall eff. HTMLIFrameElement -> Eff (dom :: DOM | eff)
41
42
foreign import setHeight :: forall eff . String -> HTMLIFrameElement -> Eff (dom :: DOM | eff ) Unit
42
43
43
44
foreign import _contentDocument :: forall eff . HTMLIFrameElement -> Eff (dom :: DOM | eff ) (Nullable Document )
45
+ foreign import _contentWindow :: forall eff . HTMLIFrameElement -> Eff (dom :: DOM | eff ) (Nullable Window )
44
46
45
47
contentDocument :: forall eff . HTMLIFrameElement -> Eff (dom :: DOM | eff ) (Maybe Document )
46
48
contentDocument = map toMaybe <<< _contentDocument
47
49
48
- -- readonly attribute WindowProxy? contentWindow;
50
+ contentWindow :: forall eff . HTMLIFrameElement -> Eff (dom :: DOM | eff ) (Maybe Window )
51
+ contentWindow = map toMaybe <<< _contentWindow
You can’t perform that action at this time.
0 commit comments