Embed style by script

jh-changes
Shin'ya Ueoka 6 years ago
parent 9efd8f8abf
commit 8f2b786177
  1. 10
      src/content/components/common/hint.css
  2. 1
      src/content/components/common/hint.js
  3. 13
      src/content/console-frame.scss
  4. 1
      src/content/console-frames.js
  5. 6
      src/content/index.js
  6. 26
      src/content/site-style.js

@ -1,10 +0,0 @@
.vimvixen-hint {
background-color: yellow;
border: 1px solid gold;
font-weight: bold;
position: absolute;
text-transform: uppercase;
z-index: 2147483647;
font-size: 12px;
color: black;
}

@ -1,4 +1,3 @@
import './hint.css';
import * as dom from 'shared/utils/dom';
const hintPosition = (element) => {

@ -1,13 +0,0 @@
.vimvixen-console-frame {
margin: 0;
padding: 0;
bottom: 0;
left: 0;
width: 100%;
height: 100%;
position: fixed;
z-index: 2147483647;
border: none;
background-color: unset;
pointer-events:none;
}

@ -1,4 +1,3 @@
import './console-frame.scss';
import messages from 'shared/messages';
const initialize = (doc) => {

@ -1,9 +1,9 @@
import './console-frame.scss';
import { createStore, applyMiddleware } from 'redux';
import promise from 'redux-promise';
import reducers from 'content/reducers';
import TopContentComponent from './components/top-content';
import FrameContentComponent from './components/frame-content';
import consoleFrameStyle from './site-style';
const store = createStore(
reducers,
@ -15,3 +15,7 @@ if (window.self === window.top) {
} else {
new FrameContentComponent(window, store); // eslint-disable-line no-new
}
let style = window.document.createElement('style');
style.textContent = consoleFrameStyle.default;
window.document.head.appendChild(style);

@ -0,0 +1,26 @@
exports.default = `
.vimvixen-console-frame {
margin: 0;
padding: 0;
bottom: 0;
left: 0;
width: 100%;
height: 100%;
position: fixed;
z-index: 2147483647;
border: none;
background-color: unset;
pointer-events:none;
}
.vimvixen-hint {
background-color: yellow;
border: 1px solid gold;
font-weight: bold;
position: absolute;
text-transform: uppercase;
z-index: 2147483647;
font-size: 12px;
color: black;
}
`;