move messages to content

jh-changes
Shin'ya Ueoka 7 years ago
parent 1145eb3478
commit 6551420e1a
  1. 2
      src/actions/operation.js
  2. 2
      src/background/index.js
  3. 0
      src/content/console-frame.scss
  4. 0
      src/content/console-frames.js
  5. 6
      src/content/index.js
  6. 0
      src/content/messages.js
  7. 0
      src/pages/completion.js
  8. 0
      src/pages/console.html
  9. 2
      src/pages/console.js
  10. 0
      src/pages/console.scss
  11. 0
      src/pages/settings.html
  12. 2
      src/pages/settings.js
  13. 0
      src/pages/settings.scss
  14. 2
      test/pages/completion.test.js
  15. 8
      webpack.config.js

@ -1,5 +1,5 @@
import operations from '../operations'; import operations from '../operations';
import messages from '../messages'; import messages from '../content/messages';
import * as consoleActions from './console'; import * as consoleActions from './console';
import * as tabs from '../background/tabs'; import * as tabs from '../background/tabs';
import * as zooms from '../background/zooms'; import * as zooms from '../background/zooms';

@ -5,7 +5,7 @@ import * as commandActions from '../actions/command';
import * as consoleActions from '../actions/console'; import * as consoleActions from '../actions/console';
import * as tabActions from '../actions/tab'; import * as tabActions from '../actions/tab';
import reducers from '../reducers'; import reducers from '../reducers';
import messages from '../messages'; import messages from '../content/messages';
import * as store from '../store'; import * as store from '../store';
let prevInput = []; let prevInput = [];

@ -1,10 +1,10 @@
import '../console/console-frame.scss'; import './console-frame.scss';
import * as consoleFrames from '../console/frames'; import * as consoleFrames from './console-frames';
import * as scrolls from '../content/scrolls'; import * as scrolls from '../content/scrolls';
import * as navigates from '../content/navigates'; import * as navigates from '../content/navigates';
import Follow from '../content/follow'; import Follow from '../content/follow';
import operations from '../operations'; import operations from '../operations';
import messages from '../messages'; import messages from './messages';
consoleFrames.initialize(window.document); consoleFrames.initialize(window.document);

@ -1,6 +1,6 @@
import './console.scss'; import './console.scss';
import Completion from './completion'; import Completion from './completion';
import messages from '../messages'; import messages from '../content/messages';
// TODO consider object-oriented // TODO consider object-oriented
let prevValue = ''; let prevValue = '';

@ -1,5 +1,5 @@
import './settings.scss'; import './settings.scss';
import messages from '../messages'; import messages from '../content/messages';
document.addEventListener('DOMContentLoaded', () => { document.addEventListener('DOMContentLoaded', () => {
let form = document.getElementById('vimvixen-settings-form'); let form = document.getElementById('vimvixen-settings-form');

@ -1,5 +1,5 @@
import { expect } from "chai"; import { expect } from "chai";
import Completion from '../../src/console/completion'; import Completion from '../../src/pages/completion';
describe('Completion class', () => { describe('Completion class', () => {
describe('#constructor', () => { describe('#constructor', () => {

@ -7,9 +7,9 @@ const dist = path.resolve(__dirname, 'build');
module.exports = { module.exports = {
entry: { entry: {
index: path.join(src, 'content'), index: path.join(src, 'content'),
settings: path.join(src, 'settings'), settings: path.join(src, 'pages/settings'),
background: path.join(src, 'background'), background: path.join(src, 'background'),
console: path.join(src, 'console', 'console.js') console: path.join(src, 'pages', 'console.js')
}, },
output: { output: {
@ -44,12 +44,12 @@ module.exports = {
plugins: [ plugins: [
new HtmlWebpackPlugin({ new HtmlWebpackPlugin({
template: path.join(src, 'console', 'console.html'), template: path.join(src, 'pages', 'console.html'),
filename: path.join(dist, 'console.html'), filename: path.join(dist, 'console.html'),
inject: false inject: false
}), }),
new HtmlWebpackPlugin({ new HtmlWebpackPlugin({
template: path.join(src, 'settings', 'settings.html'), template: path.join(src, 'pages', 'settings.html'),
filename: path.join(dist, 'settings.html'), filename: path.join(dist, 'settings.html'),
inject: false inject: false
}) })