mirror of
https://github.com/captbaritone/webamp.git
synced 2026-07-28 20:40:39 +00:00
Autoload jsx files
This commit is contained in:
parent
eef1df833d
commit
8dce934f62
12 changed files with 40 additions and 37 deletions
|
|
@ -1,7 +1,7 @@
|
|||
import {
|
||||
spriteNumber,
|
||||
spriteOffsets
|
||||
} from '../components/Band.jsx';
|
||||
} from '../components/Band';
|
||||
|
||||
describe('spriteNumber', () => {
|
||||
it('gives the first sprite', () => {
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
import {
|
||||
roundToEven
|
||||
} from '../components/EqGraph.jsx';
|
||||
} from '../components/EqGraph';
|
||||
|
||||
describe('roundToEven', () => {
|
||||
it('leaves even numbers as is', () => {
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@ import {
|
|||
stepOffset,
|
||||
negativePixels,
|
||||
loopText
|
||||
} from '../components/Marquee.jsx';
|
||||
} from '../components/Marquee';
|
||||
|
||||
describe('getBalanceText', () => {
|
||||
it('treats negative numbers as left', () => {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import React from 'react';
|
||||
import Character from './Character.jsx';
|
||||
import Character from './Character';
|
||||
|
||||
module.exports = (props) => {
|
||||
const text = `${props.children}`;
|
||||
|
|
|
|||
|
|
@ -15,10 +15,10 @@ import {
|
|||
SET_FOCUSED_WINDOW
|
||||
} from '../actionTypes';
|
||||
|
||||
import Band from './Band.jsx';
|
||||
import EqOn from './EqOn.jsx';
|
||||
import EqAuto from './EqAuto.jsx';
|
||||
import EqGraph from './EqGraph.jsx';
|
||||
import Band from './Band';
|
||||
import EqOn from './EqOn';
|
||||
import EqAuto from './EqAuto';
|
||||
import EqGraph from './EqGraph';
|
||||
|
||||
import '../../css/equalizer-window.css';
|
||||
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import React from 'react';
|
||||
import {connect} from 'react-redux';
|
||||
|
||||
import CharacterString from './CharacterString.jsx';
|
||||
import CharacterString from './CharacterString';
|
||||
|
||||
|
||||
const Kbps = (props) => <CharacterString id='kbps'>
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import React from 'react';
|
||||
import {connect} from 'react-redux';
|
||||
|
||||
import CharacterString from './CharacterString.jsx';
|
||||
import CharacterString from './CharacterString';
|
||||
|
||||
|
||||
const Khz = (props) => <CharacterString id='khz'>
|
||||
|
|
|
|||
|
|
@ -4,26 +4,26 @@ import classnames from 'classnames';
|
|||
|
||||
import {WINDOWS} from '../constants';
|
||||
|
||||
import ActionButtons from './ActionButtons.jsx';
|
||||
import Balance from './Balance.jsx';
|
||||
import Close from './Close.jsx';
|
||||
import ClutterBar from './ClutterBar.jsx';
|
||||
import ContextMenu from './ContextMenu.jsx';
|
||||
//import DragTarget from './DragTarget.jsx';
|
||||
import Eject from './Eject.jsx';
|
||||
import EqToggleButton from './EqToggleButton.jsx';
|
||||
import Kbps from './Kbps.jsx';
|
||||
import Khz from './Khz.jsx';
|
||||
import Marquee from './Marquee.jsx';
|
||||
import MonoStereo from './MonoStereo.jsx';
|
||||
import Position from './Position.jsx';
|
||||
import Repeat from './Repeat.jsx';
|
||||
import Shade from './Shade.jsx';
|
||||
import ShadeTime from './ShadeTime.jsx';
|
||||
import Shuffle from './Shuffle.jsx';
|
||||
import Time from './Time.jsx';
|
||||
import Visualizer from './Visualizer.jsx';
|
||||
import Volume from './Volume.jsx';
|
||||
import ActionButtons from './ActionButtons';
|
||||
import Balance from './Balance';
|
||||
import Close from './Close';
|
||||
import ClutterBar from './ClutterBar';
|
||||
import ContextMenu from './ContextMenu';
|
||||
//import DragTarget from './DragTarget';
|
||||
import Eject from './Eject';
|
||||
import EqToggleButton from './EqToggleButton';
|
||||
import Kbps from './Kbps';
|
||||
import Khz from './Khz';
|
||||
import Marquee from './Marquee';
|
||||
import MonoStereo from './MonoStereo';
|
||||
import Position from './Position';
|
||||
import Repeat from './Repeat';
|
||||
import Shade from './Shade';
|
||||
import ShadeTime from './ShadeTime';
|
||||
import Shuffle from './Shuffle';
|
||||
import Time from './Time';
|
||||
import Visualizer from './Visualizer';
|
||||
import Volume from './Volume';
|
||||
|
||||
import {
|
||||
SET_FOCUSED_WINDOW
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ const negativePixels = (pixels) => `-${pixels}px`;
|
|||
// If text is wider than the marquee, it needs to loop
|
||||
const loopText = (text) => isLong(text) ? text + text : text;
|
||||
|
||||
import CharacterString from './CharacterString.jsx';
|
||||
import CharacterString from './CharacterString';
|
||||
|
||||
class Marquee extends React.Component {
|
||||
constructor(props) {
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
import React from 'react';
|
||||
import {connect} from 'react-redux';
|
||||
import {getTimeObj} from '../utils';
|
||||
import Character from './Character.jsx';
|
||||
import Character from './Character';
|
||||
|
||||
import {TOGGLE_TIME_MODE} from '../actionTypes';
|
||||
|
||||
|
|
|
|||
10
js/index.js
10
js/index.js
|
|
@ -3,14 +3,14 @@ import {render} from 'react-dom';
|
|||
import {Provider} from 'react-redux';
|
||||
|
||||
import getStore from './store';
|
||||
import WindowManager from './components/WindowManager.jsx';
|
||||
import WindowManager from './components/WindowManager';
|
||||
import Browser from './browser';
|
||||
import MainWindow from './components/MainWindow.jsx';
|
||||
import PlaylistWindow from './components/PlaylistWindow.jsx';
|
||||
import EqualizerWindow from './components/EqualizerWindow.jsx';
|
||||
import MainWindow from './components/MainWindow';
|
||||
import PlaylistWindow from './components/PlaylistWindow';
|
||||
import EqualizerWindow from './components/EqualizerWindow';
|
||||
import Winamp from './winamp';
|
||||
import Hotkeys from './hotkeys';
|
||||
import Skin from './components/Skin.jsx';
|
||||
import Skin from './components/Skin';
|
||||
|
||||
if (new Browser(window).isCompatible) {
|
||||
const hash = window.location.hash;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,9 @@
|
|||
const path = require('path');
|
||||
|
||||
module.exports = {
|
||||
resolve: {
|
||||
extensions: ['', '.js', '.jsx']
|
||||
},
|
||||
module: {
|
||||
loaders: [
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue