diff options
Diffstat (limited to 'background.js')
-rw-r--r-- | background.js | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/background.js b/background.js index b187850..2b5dc1d 100644 --- a/background.js +++ b/background.js @@ -26,10 +26,13 @@ browser.runtime.onMessage.addListener(function(message) { var url = new URL(details.url); if (url.hostname === message.domain) { - browser.tabs.insertCSS( - details.tabId, - { file: '/css/' + message.domain + '.css' } - ); + wildcard_domains(message.domain) + .forEach(function(domain) { + browser.tabs.insertCSS( + details.tabId, + { file: '/css/' + domain + '.css' } + ); + }); } }); }); |