summaryrefslogtreecommitdiff
path: root/ext/client.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2016-03-31 20:03:39 -0700
committerAlex Yatskov <alex@foosoft.net>2016-03-31 20:03:39 -0700
commit7eadff3457690074c5c0140a6e9ffd6164021176 (patch)
treead8ba8c31cba11f54ca8cab186d1d36090e070c0 /ext/client.js
parentb97e75ba32781341c221f549780f3444d0916714 (diff)
Moving large files to CSV format, deleting unused kradfile
Diffstat (limited to 'ext/client.js')
-rw-r--r--ext/client.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/ext/client.js b/ext/client.js
index 2d9a470f..1c8c0a9f 100644
--- a/ext/client.js
+++ b/ext/client.js
@@ -27,7 +27,9 @@ class Client {
this.popup.classList.add('yomichan-popup');
this.popup.addEventListener('mousedown', (e) => e.stopPropagation());
this.popup.addEventListener('scroll', (e) => e.stopPropagation());
- document.body.appendChild(this.popup);
+
+ const base = document.body.appendChild('div');
+ base.createShadowRoot().appendChild(this.popup);
chrome.runtime.onMessage.addListener(this.onMessage.bind(this));
window.addEventListener('mousedown', this.onMouseDown.bind(this));