New: Cleanup UI tooling, Update to Webpack 4, Gulp 4 (#655)

* New: Webpack 4

* New: Gulp 4

* New: Transpile UI for old browsers

Co-Authored-By: Mark McDowall <markus101@users.noreply.github.com>
This commit is contained in:
Qstick 2019-03-08 21:10:23 -05:00 committed by GitHub
parent fe3761fc2e
commit 0a6f552d5b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
217 changed files with 2265 additions and 2625 deletions

View file

@ -1,5 +1,5 @@
.modal {
composes: modal from 'Components/Modal/Modal.css';
composes: modal from '~Components/Modal/Modal.css';
height: 600px;
}

View file

@ -1,12 +1,12 @@
.modalBody {
composes: modalBody from 'Components/Modal/ModalBody.css';
composes: modalBody from '~Components/Modal/ModalBody.css';
display: flex;
flex-direction: column;
}
.mappedDrivesWarning {
composes: alert from 'Components/Alert.css';
composes: alert from '~Components/Alert.css';
margin: 0;
margin-bottom: 20px;
@ -18,7 +18,7 @@
}
.pathInput {
composes: pathInputWrapper from 'Components/Form/PathInput.css';
composes: pathInputWrapper from '~Components/Form/PathInput.css';
flex: 0 0 auto;
}

View file

@ -1,5 +1,5 @@
.type {
composes: cell from 'Components/Table/Cells/TableRowCell.css';
composes: cell from '~Components/Table/Cells/TableRowCell.css';
width: 32px;
}

View file

@ -3,13 +3,13 @@
}
.numberInput {
composes: input from 'Components/Form/TextInput.css';
composes: input from '~Components/Form/TextInput.css';
margin-right: 3px;
}
.selectInput {
composes: select from 'Components/Form/SelectInput.css';
composes: select from '~Components/Form/SelectInput.css';
margin-left: 3px;
}

View file

@ -3,7 +3,8 @@ import React, { Component } from 'react';
import convertToBytes from 'Utilities/Number/convertToBytes';
import formatBytes from 'Utilities/Number/formatBytes';
import { kinds, filterBuilderTypes, filterBuilderValueTypes } from 'Helpers/Props';
import TagInput, { tagShape } from 'Components/Form/TagInput';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import TagInput from 'Components/Form/TagInput';
import FilterBuilderRowValueTag from './FilterBuilderRowValueTag';
export const NAME = 'value';

View file

@ -7,7 +7,7 @@
}
.label {
composes: label from 'Components/Label.css';
composes: label from '~Components/Label.css';
border-style: none;
font-size: 13px;

View file

@ -2,8 +2,8 @@ import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import { fetchIndexers } from 'Store/Actions/settingsActions';
import { tagShape } from 'Components/Form/TagInput';
import FilterBuilderRowValue from './FilterBuilderRowValue';
function createMapStateToProps() {

View file

@ -3,8 +3,8 @@ import React, { Component } from 'react';
import { connect } from 'react-redux';
import { createSelector } from 'reselect';
import getQualities from 'Utilities/Quality/getQualities';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import { fetchQualityProfileSchema } from 'Store/Actions/settingsActions';
import { tagShape } from 'Components/Form/TagInput';
import FilterBuilderRowValue from './FilterBuilderRowValue';
function createMapStateToProps() {

View file

@ -1,13 +1,13 @@
.input {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.inputWrapper {

View file

@ -3,19 +3,19 @@
}
.input {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.hasButton {
composes: hasButton from 'Components/Form/Input.css';
composes: hasButton from '~Components/Form/Input.css';
}
.recaptchaWrapper {

View file

@ -94,7 +94,7 @@
}
.helpText {
composes: helpText from 'Components/Form/FormInputHelpText.css';
composes: helpText from '~Components/Form/FormInputHelpText.css';
margin-top: 8px;
margin-left: 5px;

View file

@ -3,6 +3,6 @@
}
.inputContainer {
composes: inputContainer from './TagInput.css';
composes: hasButton from 'Components/Form/Input.css';
composes: inputContainer from '~./TagInput.css';
composes: hasButton from '~Components/Form/Input.css';
}

View file

@ -1,9 +1,10 @@
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { icons } from 'Helpers/Props';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import Icon from 'Components/Icon';
import FormInputButton from './FormInputButton';
import TagInput, { tagShape } from './TagInput';
import TagInput from './TagInput';
import styles from './DeviceInput.css';
class DeviceInput extends Component {

View file

@ -3,8 +3,8 @@
}
.enhancedSelect {
composes: input from 'Components/Form/Input.css';
composes: link from 'Components/Link/Link.css';
composes: input from '~Components/Form/Input.css';
composes: link from '~Components/Link/Link.css';
position: relative;
display: flex;
@ -21,11 +21,11 @@
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.isDisabled {
@ -62,7 +62,7 @@
}
.optionsModalBody {
composes: modalBody from 'Components/Modal/ModalBody.css';
composes: modalBody from '~Components/Modal/ModalBody.css';
display: flex;
justify-content: center;
@ -71,7 +71,7 @@
}
.optionsModalScroller {
composes: scroller from 'Components/Scroller/Scroller.css';
composes: scroller from '~Components/Scroller/Scroller.css';
border: 1px solid $inputBorderColor;
border-radius: 4px;

View file

@ -1,5 +1,5 @@
.button {
composes: button from 'Components/Link/Button.css';
composes: button from '~Components/Link/Button.css';
border-left: none;
border-top-left-radius: 0;

View file

@ -33,7 +33,7 @@
}
.link {
composes: link from 'Components/Link/Link.css';
composes: link from '~Components/Link/Link.css';
margin-left: 5px;
}

View file

@ -1,5 +1,5 @@
.inputContainer {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
position: relative;
min-height: 35px;
@ -13,9 +13,9 @@
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}

View file

@ -1,5 +1,5 @@
.input {
composes: input from 'Components/Form/TextInput.css';
composes: input from '~Components/Form/TextInput.css';
font-family: $passwordFamily;
}

View file

@ -1,17 +1,17 @@
.path {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.hasFileBrowser {
composes: hasButton from 'Components/Form/Input.css';
composes: hasButton from '~Components/Form/Input.css';
}
.pathInputWrapper {
@ -62,7 +62,7 @@
}
.fileBrowserButton {
composes: button from './FormInputButton.css';
composes: button from '~./FormInputButton.css';
height: 35px;
}

View file

@ -1,5 +1,5 @@
.selectedValue {
composes: selectedValue from './EnhancedSelectInputSelectedValue.css';
composes: selectedValue from '~./EnhancedSelectInputSelectedValue.css';
display: flex;
align-items: center;

View file

@ -1,15 +1,15 @@
.select {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
padding: 0 11px;
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.isDisabled {

View file

@ -1,5 +1,5 @@
.inputContainer {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
position: relative;
padding: 0;
@ -14,11 +14,11 @@
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.tags {

View file

@ -4,6 +4,7 @@ import React, { Component } from 'react';
import Autosuggest from 'react-autosuggest';
import classNames from 'classnames';
import { kinds } from 'Helpers/Props';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import TagInputInput from './TagInputInput';
import TagInputTag from './TagInputTag';
import styles from './TagInput.css';
@ -266,11 +267,6 @@ class TagInput extends Component {
}
}
export const tagShape = {
id: PropTypes.oneOfType([PropTypes.bool, PropTypes.number, PropTypes.string]).isRequired,
name: PropTypes.oneOfType([PropTypes.number, PropTypes.string]).isRequired
};
TagInput.propTypes = {
className: PropTypes.string.isRequired,
inputClassName: PropTypes.string.isRequired,

View file

@ -1,7 +1,7 @@
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { kinds } from 'Helpers/Props';
import { tagShape } from './TagInput';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import styles from './TagInputInput.css';
class TagInputInput extends Component {

View file

@ -1,9 +1,9 @@
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import { kinds } from 'Helpers/Props';
import tagShape from 'Helpers/Props/Shapes/tagShape';
import Label from 'Components/Label';
import Link from 'Components/Link/Link';
import { tagShape } from './TagInput';
class TagInputTag extends Component {

View file

@ -1,5 +1,5 @@
.input {
composes: input from 'Components/Form/Input.css';
composes: input from '~Components/Form/Input.css';
}
.readOnly {
@ -7,13 +7,13 @@
}
.hasError {
composes: hasError from 'Components/Form/Input.css';
composes: hasError from '~Components/Form/Input.css';
}
.hasWarning {
composes: hasWarning from 'Components/Form/Input.css';
composes: hasWarning from '~Components/Form/Input.css';
}
.hasButton {
composes: hasButton from 'Components/Form/Input.css';
composes: hasButton from '~Components/Form/Input.css';
}

View file

@ -1,5 +1,5 @@
.button {
composes: link from './Link.css';
composes: link from '~./Link.css';
overflow: hidden;
border: 1px solid;

View file

@ -1,5 +1,5 @@
.button {
composes: button from 'Components/Form/FormInputButton.css';
composes: button from '~Components/Form/FormInputButton.css';
position: relative;
}

View file

@ -1,5 +1,5 @@
.button {
composes: link from 'Components/Link/Link.css';
composes: link from '~Components/Link/Link.css';
display: inline-block;
margin: 0 2px;

View file

@ -1,5 +1,5 @@
.button {
composes: button from 'Components/Link/Button.css';
composes: button from '~Components/Link/Button.css';
position: relative;
}

View file

@ -1,5 +1,5 @@
.iconContainer {
composes: spinnerContainer from 'Components/Link/SpinnerButton.css';
composes: spinnerContainer from '~Components/Link/SpinnerButton.css';
}
.icon {
@ -7,7 +7,7 @@
}
.label {
composes: label from 'Components/Link/SpinnerButton.css';
composes: label from '~Components/Link/SpinnerButton.css';
}
.showIcon {

View file

@ -1,5 +1,5 @@
.filterMenu {
composes: menu from './Menu.css';
composes: menu from '~./Menu.css';
}
@media only screen and (max-width: $breakpointSmall) {

View file

@ -1,5 +1,5 @@
.menuButton {
composes: menuButton from './MenuButton.css';
composes: menuButton from '~./MenuButton.css';
&:hover {
color: #666;

View file

@ -1,5 +1,5 @@
.menuButton {
composes: menuButton from './MenuButton.css';
composes: menuButton from '~./MenuButton.css';
width: $toolbarButtonWidth;
height: $toolbarHeight;
@ -7,5 +7,5 @@
}
.label {
composes: label from 'Components/Page/Toolbar/PageToolbarButton.css';
composes: label from '~Components/Page/Toolbar/PageToolbarButton.css';
}

View file

@ -1,5 +1,5 @@
.message {
composes: message from 'Components/Error/ErrorBoundaryError.css';
composes: message from '~Components/Error/ErrorBoundaryError.css';
margin: 0;
margin-bottom: 30px;
@ -8,7 +8,7 @@
}
.details {
composes: details from 'Components/Error/ErrorBoundaryError.css';
composes: details from '~Components/Error/ErrorBoundaryError.css';
margin: 0;
margin-top: 20px;

View file

@ -1,5 +1,5 @@
.toggleButton {
composes: button from 'Components/Link/IconButton.css';
composes: button from '~Components/Link/IconButton.css';
padding: 0;
font-size: inherit;

View file

@ -1,5 +1,5 @@
.page {
composes: page from './Page.css';
composes: page from '~./Page.css';
margin-top: 20px;
text-align: center;

View file

@ -38,7 +38,7 @@
}
.donate {
composes: link from 'Components/Link/Link.css';
composes: link from '~Components/Link/Link.css';
width: 30px;
color: $themeRed;

View file

@ -1,3 +1,3 @@
.page {
composes: page from './Page.css';
composes: page from '~./Page.css';
}

View file

@ -1,3 +1,3 @@
.content {
composes: content from './PageContent.css';
composes: content from '~./PageContent.css';
}

View file

@ -1,3 +1,3 @@
.status {
composes: label from 'Components/Label.css';
composes: label from '~Components/Label.css';
}

View file

@ -1,5 +1,5 @@
.toolbarButton {
composes: link from 'Components/Link/Link.css';
composes: link from '~Components/Link/Link.css';
width: $toolbarButtonWidth;
text-align: center;

View file

@ -23,7 +23,7 @@
}
.overflowMenuButton {
composes: menuButton from 'Components/Menu/ToolbarMenuButton.css';
composes: menuButton from '~Components/Menu/ToolbarMenuButton.css';
}
.overflowMenuItemIcon {

View file

@ -94,7 +94,9 @@ class SignalRConnector extends Component {
componentDidMount() {
console.log('Starting signalR');
this.signalRconnection = $.connection('/signalr', { apiKey: window.Lidarr.apiKey });
const url = `${window.Lidarr.urlBase}/signalr`;
this.signalRconnection = $.connection(url, { apiKey: window.Lidarr.apiKey });
this.signalRconnection.stateChanged(this.onStateChanged);
this.signalRconnection.received(this.onReceived);

View file

@ -1,5 +1,5 @@
.cell {
composes: cell from './TableRowCell.css';
composes: cell from '~./TableRowCell.css';
width: 180px;
}

View file

@ -1,4 +1,4 @@
.cell {
composes: cell from './TableRowCell.css';
composes: link from 'Components/Link/Link.css';
composes: cell from '~./TableRowCell.css';
composes: link from '~Components/Link/Link.css';
}

View file

@ -1,11 +1,11 @@
.selectCell {
composes: cell from 'Components/Table/Cells/TableRowCell.css';
composes: cell from '~Components/Table/Cells/TableRowCell.css';
width: 30px;
}
.input {
composes: input from 'Components/Form/CheckInput.css';
composes: input from '~Components/Form/CheckInput.css';
margin: 0;
}

View file

@ -1,6 +1,6 @@
.cell {
@add-mixin truncate;
composes: cell from 'Components/Table/Cells/TableRowCell.css';
composes: cell from '~Components/Table/Cells/TableRowCell.css';
flex-grow: 0;
flex-shrink: 1;

View file

@ -1,11 +1,11 @@
.cell {
composes: cell from 'Components/Table/Cells/VirtualTableRowCell.css';
composes: cell from '~Components/Table/Cells/VirtualTableRowCell.css';
flex: 0 0 36px;
}
.input {
composes: input from 'Components/Form/CheckInput.css';
composes: input from '~Components/Form/CheckInput.css';
margin: 0;
}

View file

@ -21,7 +21,7 @@
}
.loading {
composes: loading from 'Components/Loading/LoadingIndicator.css';
composes: loading from '~Components/Loading/LoadingIndicator.css';
margin: 0;
margin-left: 5px;
@ -54,7 +54,7 @@
}
.pageSelect {
composes: select from 'Components/Form/SelectInput.css';
composes: select from '~Components/Form/SelectInput.css';
padding: 0 2px;
height: 25px;

View file

@ -1,4 +1,4 @@
.row {
composes: link from 'Components/Link/Link.css';
composes: row from './TableRow.css';
composes: link from '~Components/Link/Link.css';
composes: row from '~./TableRow.css';
}

View file

@ -1,11 +1,11 @@
.selectAllHeaderCell {
composes: headerCell from 'Components/Table/VirtualTableHeaderCell.css';
composes: headerCell from '~Components/Table/VirtualTableHeaderCell.css';
width: 30px;
}
.input {
composes: input from 'Components/Form/CheckInput.css';
composes: input from '~Components/Form/CheckInput.css';
margin: 0;
}

View file

@ -1,11 +1,11 @@
.selectAllHeaderCell {
composes: headerCell from 'Components/Table/TableHeaderCell.css';
composes: headerCell from '~Components/Table/TableHeaderCell.css';
flex: 0 0 36px;
}
.input {
composes: input from 'Components/Form/CheckInput.css';
composes: input from '~Components/Form/CheckInput.css';
margin: 0;
}