diff options
| author | gdh1995 | 2018-10-28 11:53:27 +0800 | 
|---|---|---|
| committer | gdh1995 | 2018-10-28 11:53:27 +0800 | 
| commit | 5307f07729f2a35debbee6ef8c5f09493a8b81bf (patch) | |
| tree | 6b9d1f696be61d6e13a077756df9407d6f2fc803 | |
| parent | acf09d2285b47d5849b4315ac698182dad7e9c13 (diff) | |
| download | vimium-5307f07729f2a35debbee6ef8c5f09493a8b81bf.tar.bz2 | |
fix a small typo that attachShadow needs an argument
| -rw-r--r-- | content_scripts/ui_component.coffee | 3 | ||||
| -rw-r--r-- | content_scripts/vimium_frontend.coffee | 2 | 
2 files changed, 3 insertions, 2 deletions
| diff --git a/content_scripts/ui_component.coffee b/content_scripts/ui_component.coffee index f0815d08..d3145eb3 100644 --- a/content_scripts/ui_component.coffee +++ b/content_scripts/ui_component.coffee @@ -27,7 +27,8 @@ class UIComponent          seamless: "seamless"        shadowWrapper = DomUtils.createElement "div"        # PhantomJS doesn't support createShadowRoot, so guard against its non-existance. -      @shadowDOM = shadowWrapper.attachShadow?() ? shadowWrapper.createShadowRoot?() ? shadowWrapper +      @shadowDOM = shadowWrapper.attachShadow?( mode: "open" ) ? +        shadowWrapper.createShadowRoot?() ? shadowWrapper        @shadowDOM.appendChild styleSheet        @shadowDOM.appendChild @iframeElement        @toggleIframeElementClasses "vimiumUIComponentVisible", "vimiumUIComponentHidden" diff --git a/content_scripts/vimium_frontend.coffee b/content_scripts/vimium_frontend.coffee index 2eb4a0cd..0f5d05f2 100644 --- a/content_scripts/vimium_frontend.coffee +++ b/content_scripts/vimium_frontend.coffee @@ -247,7 +247,7 @@ flashFrame = do ->        # PhantomJS doesn't support createShadowRoot, so guard against its non-existance.        # https://hacks.mozilla.org/2018/10/firefox-63-tricks-and-treats/ says        # Firefox 63 has enabled Shadow DOM v1 by default -      _shadowDOM = highlightedFrameElement.attachShadow?() ? +      _shadowDOM = highlightedFrameElement.attachShadow?( mode: "open" ) ?          highlightedFrameElement.createShadowRoot?() ? highlightedFrameElement        # Inject stylesheet. | 
