Compare commits
103 Commits
v4.6.3.751
...
v4.7.2.768
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
41e95ef98c | ||
|
|
d8ba7f4d67 | ||
|
|
97a28fee3b | ||
|
|
e6b782aa20 | ||
|
|
7aa72b30cb | ||
|
|
490a0cb2fb | ||
|
|
fa50f60e6b | ||
|
|
b5c9c996a5 | ||
|
|
9b69d3b051 | ||
|
|
c8a1e49b7b | ||
|
|
0b300eee1c | ||
|
|
ed107cadac | ||
|
|
a2216f23ec | ||
|
|
faaef80a80 | ||
|
|
5f70581a59 | ||
|
|
8369a77365 | ||
|
|
00f4176dad | ||
|
|
056c224431 | ||
|
|
d84230d4cc | ||
|
|
a6197ba70d | ||
|
|
31a16ab571 | ||
|
|
79c9225b00 | ||
|
|
dd6be39063 | ||
|
|
668797b406 | ||
|
|
7bb9250877 | ||
|
|
6ad9ebb19e | ||
|
|
f8cbca7958 | ||
|
|
f65835b874 | ||
|
|
59ea905e06 | ||
|
|
d8eda4d089 | ||
|
|
e4eb8f63bb | ||
|
|
d936591b66 | ||
|
|
c61cca7952 | ||
|
|
f38077aac7 | ||
|
|
3055ed5336 | ||
|
|
164625a0b2 | ||
|
|
09ca0a1c0a | ||
|
|
bef881a9e2 | ||
|
|
f7e36581e1 | ||
|
|
20a8f1cbe7 | ||
|
|
3da8396b7e | ||
|
|
d61f914bd7 | ||
|
|
25837adfc7 | ||
|
|
5516d7e3cd | ||
|
|
e2647deea3 | ||
|
|
8c34946134 | ||
|
|
4a66a832b3 | ||
|
|
2d18e4f89e | ||
|
|
d6c1721f51 | ||
|
|
99709d6445 | ||
|
|
916d43d70d | ||
|
|
bc004b3b5b | ||
|
|
7a222dcd9f | ||
|
|
48b9c1e8b9 | ||
|
|
7dde88387a | ||
|
|
0eddf76622 | ||
|
|
f69a847d9a | ||
|
|
97ed820575 | ||
|
|
0ee94a4624 | ||
|
|
3b7914f63b | ||
|
|
0005fa57ac | ||
|
|
bbde1dc7a6 | ||
|
|
1c99ce8876 | ||
|
|
7a5ae56a96 | ||
|
|
ae8820178d | ||
|
|
c214a6b67b | ||
|
|
b3f6774820 | ||
|
|
8fd4e41c85 | ||
|
|
8984fd735b | ||
|
|
3321123043 | ||
|
|
23a13b5c23 | ||
|
|
304a07e23f | ||
|
|
1e0ec4aefb | ||
|
|
5c46c75ce7 | ||
|
|
1c26dd4aca | ||
|
|
6fae00f51c | ||
|
|
653ef0a501 | ||
|
|
e606ff05a4 | ||
|
|
dd3ac26604 | ||
|
|
122d0056ea | ||
|
|
fe41aada06 | ||
|
|
bd1844030d | ||
|
|
148ee5983d | ||
|
|
372d15ecf3 | ||
|
|
b95431500d | ||
|
|
3da72f54ef | ||
|
|
7cfff20cad | ||
|
|
d3895dec8f | ||
|
|
690bab3264 | ||
|
|
986128e100 | ||
|
|
dda0885f91 | ||
|
|
7e218a886d | ||
|
|
77cde138dc | ||
|
|
239109e3dd | ||
|
|
4804eb0769 | ||
|
|
60a55dfdac | ||
|
|
cd82865303 | ||
|
|
439adb4ac6 | ||
|
|
fd0ff78791 | ||
|
|
cbae355402 | ||
|
|
fed98a648f | ||
|
|
e1c5656cff | ||
|
|
e3f88e1711 |
@@ -270,7 +270,7 @@ dotnet_diagnostic.CA5397.severity = suggestion
|
||||
|
||||
dotnet_diagnostic.SYSLIB0006.severity = none
|
||||
|
||||
[*.{js,html,js,hbs,less,css}]
|
||||
[*.{js,html,hbs,less,css,ts,tsx}]
|
||||
charset = utf-8
|
||||
trim_trailing_whitespace = true
|
||||
insert_final_newline = true
|
||||
|
||||
4
.github/ISSUE_TEMPLATE/bug_report.yml
vendored
@@ -76,7 +76,7 @@ body:
|
||||
- type: checkboxes
|
||||
attributes:
|
||||
label: Trace Logs have been provided as applicable. Reports may be closed if the required logs are not provided.
|
||||
description: Trace logs are generally required for all bug reports
|
||||
description: Trace logs are generally required for all bug reports and contain `trace`. Info logs are invalid for bug reports and do not contain `debug` nor `trace`
|
||||
options:
|
||||
- label: I have followed the steps in the wiki link above and provided the required trace logs that are relevant and show this issue.
|
||||
- label: I have read and followed the steps in the wiki link above and provided the required trace logs - the logs contain `trace` - that are relevant and show this issue.
|
||||
required: true
|
||||
|
||||
BIN
Logo/1024.png
|
Before Width: | Height: | Size: 49 KiB After Width: | Height: | Size: 36 KiB |
BIN
Logo/128.png
|
Before Width: | Height: | Size: 4.1 KiB After Width: | Height: | Size: 2.4 KiB |
BIN
Logo/16.png
|
Before Width: | Height: | Size: 577 B After Width: | Height: | Size: 331 B |
BIN
Logo/256.png
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 6.0 KiB |
BIN
Logo/32.png
|
Before Width: | Height: | Size: 1.1 KiB After Width: | Height: | Size: 666 B |
BIN
Logo/400.png
|
Before Width: | Height: | Size: 17 KiB After Width: | Height: | Size: 10 KiB |
BIN
Logo/48.png
|
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 987 B |
BIN
Logo/512.png
|
Before Width: | Height: | Size: 21 KiB After Width: | Height: | Size: 14 KiB |
BIN
Logo/64.png
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.1 KiB |
BIN
Logo/800.png
|
Before Width: | Height: | Size: 49 KiB After Width: | Height: | Size: 31 KiB |
BIN
Logo/text256.png
|
Before Width: | Height: | Size: 32 KiB After Width: | Height: | Size: 21 KiB |
@@ -9,7 +9,7 @@ variables:
|
||||
testsFolder: './_tests'
|
||||
yarnCacheFolder: $(Pipeline.Workspace)/.yarn
|
||||
nugetCacheFolder: $(Pipeline.Workspace)/.nuget/packages
|
||||
majorVersion: '4.6.3'
|
||||
majorVersion: '4.7.2'
|
||||
minorVersion: $[counter('minorVersion', 2000)]
|
||||
radarrVersion: '$(majorVersion).$(minorVersion)'
|
||||
buildName: '$(Build.SourceBranchName).$(radarrVersion)'
|
||||
@@ -363,7 +363,7 @@ stages:
|
||||
- bash: |
|
||||
echo "Uploading source maps to sentry"
|
||||
curl -sL https://sentry.io/get-cli/ | bash
|
||||
RELEASENAME="${RADARRVERSION}-${BUILD_SOURCEBRANCHNAME}"
|
||||
RELEASENAME="Radarr@${RADARRVERSION}-${BUILD_SOURCEBRANCHNAME}"
|
||||
sentry-cli releases new --finalize -p radarr -p radarr-ui -p radarr-update "${RELEASENAME}"
|
||||
sentry-cli releases -p radarr-ui files "${RELEASENAME}" upload-sourcemaps _output/UI/ --rewrite
|
||||
sentry-cli releases set-commits --auto "${RELEASENAME}"
|
||||
|
||||
@@ -66,23 +66,23 @@ module.exports = (env) => {
|
||||
output: {
|
||||
path: distFolder,
|
||||
publicPath: '/',
|
||||
filename: '[name].js',
|
||||
filename: '[name]-[contenthash].js',
|
||||
sourceMapFilename: '[file].map'
|
||||
},
|
||||
|
||||
optimization: {
|
||||
moduleIds: 'deterministic',
|
||||
chunkIds: 'named',
|
||||
splitChunks: {
|
||||
chunks: 'initial',
|
||||
name: 'vendors'
|
||||
}
|
||||
chunkIds: isProduction ? 'deterministic' : 'named'
|
||||
},
|
||||
|
||||
performance: {
|
||||
hints: false
|
||||
},
|
||||
|
||||
experiments: {
|
||||
topLevelAwait: true
|
||||
},
|
||||
|
||||
plugins: [
|
||||
new webpack.DefinePlugin({
|
||||
__DEV__: !isProduction,
|
||||
@@ -90,7 +90,8 @@ module.exports = (env) => {
|
||||
}),
|
||||
|
||||
new MiniCssExtractPlugin({
|
||||
filename: 'Content/styles.css'
|
||||
filename: 'Content/styles.css',
|
||||
chunkFilename: 'Content/[id]-[chunkhash].css'
|
||||
}),
|
||||
|
||||
new HtmlWebpackPlugin({
|
||||
@@ -233,6 +234,7 @@ module.exports = (env) => {
|
||||
{
|
||||
loader: 'url-loader',
|
||||
options: {
|
||||
limit: 10240,
|
||||
mimetype: 'application/font-woff',
|
||||
emitFile: false,
|
||||
name: 'Content/Fonts/[name].[ext]'
|
||||
|
||||
@@ -4,7 +4,8 @@ import IconButton from 'Components/Link/IconButton';
|
||||
import RelativeDateCellConnector from 'Components/Table/Cells/RelativeDateCellConnector';
|
||||
import TableRowCell from 'Components/Table/Cells/TableRowCell';
|
||||
import TableRow from 'Components/Table/TableRow';
|
||||
import { icons } from 'Helpers/Props';
|
||||
import Tooltip from 'Components/Tooltip/Tooltip';
|
||||
import { icons, tooltipPositions } from 'Helpers/Props';
|
||||
import MovieFormats from 'Movie/MovieFormats';
|
||||
import MovieLanguage from 'Movie/MovieLanguage';
|
||||
import MovieQuality from 'Movie/MovieQuality';
|
||||
@@ -176,7 +177,14 @@ class HistoryRow extends Component {
|
||||
key={name}
|
||||
className={styles.customFormatScore}
|
||||
>
|
||||
{formatCustomFormatScore(customFormatScore)}
|
||||
<Tooltip
|
||||
anchor={formatCustomFormatScore(
|
||||
customFormatScore,
|
||||
customFormats.length
|
||||
)}
|
||||
tooltip={<MovieFormats formats={customFormats} />}
|
||||
position={tooltipPositions.BOTTOM}
|
||||
/>
|
||||
</TableRowCell>
|
||||
);
|
||||
}
|
||||
@@ -257,4 +265,8 @@ HistoryRow.propTypes = {
|
||||
onMarkAsFailedPress: PropTypes.func.isRequired
|
||||
};
|
||||
|
||||
HistoryRow.defaultProps = {
|
||||
customFormats: []
|
||||
};
|
||||
|
||||
export default HistoryRow;
|
||||
|
||||
@@ -16,6 +16,12 @@
|
||||
width: 150px;
|
||||
}
|
||||
|
||||
.customFormatScore {
|
||||
composes: cell from '~Components/Table/Cells/TableRowCell.css';
|
||||
|
||||
width: 55px;
|
||||
}
|
||||
|
||||
.actions {
|
||||
composes: cell from '~Components/Table/Cells/TableRowCell.css';
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'actions': string;
|
||||
'customFormatScore': string;
|
||||
'progress': string;
|
||||
'protocol': string;
|
||||
'quality': string;
|
||||
|
||||
@@ -8,13 +8,15 @@ import ProgressBar from 'Components/ProgressBar';
|
||||
import TableRowCell from 'Components/Table/Cells/TableRowCell';
|
||||
import TableSelectCell from 'Components/Table/Cells/TableSelectCell';
|
||||
import TableRow from 'Components/Table/TableRow';
|
||||
import { icons, kinds } from 'Helpers/Props';
|
||||
import Tooltip from 'Components/Tooltip/Tooltip';
|
||||
import { icons, kinds, tooltipPositions } from 'Helpers/Props';
|
||||
import InteractiveImportModal from 'InteractiveImport/InteractiveImportModal';
|
||||
import MovieFormats from 'Movie/MovieFormats';
|
||||
import MovieLanguage from 'Movie/MovieLanguage';
|
||||
import MovieQuality from 'Movie/MovieQuality';
|
||||
import MovieTitleLink from 'Movie/MovieTitleLink';
|
||||
import formatBytes from 'Utilities/Number/formatBytes';
|
||||
import formatCustomFormatScore from 'Utilities/Number/formatCustomFormatScore';
|
||||
import translate from 'Utilities/String/translate';
|
||||
import QueueStatusCell from './QueueStatusCell';
|
||||
import RemoveQueueItemModal from './RemoveQueueItemModal';
|
||||
@@ -42,14 +44,14 @@ class QueueRow extends Component {
|
||||
this.setState({ isRemoveQueueItemModalOpen: true });
|
||||
};
|
||||
|
||||
onRemoveQueueItemModalConfirmed = (blocklist) => {
|
||||
onRemoveQueueItemModalConfirmed = (blocklist, skipRedownload) => {
|
||||
const {
|
||||
onRemoveQueueItemPress,
|
||||
onQueueRowModalOpenOrClose
|
||||
} = this.props;
|
||||
|
||||
onQueueRowModalOpenOrClose(false);
|
||||
onRemoveQueueItemPress(blocklist);
|
||||
onRemoveQueueItemPress(blocklist, skipRedownload);
|
||||
|
||||
this.setState({ isRemoveQueueItemModalOpen: false });
|
||||
};
|
||||
@@ -88,6 +90,7 @@ class QueueRow extends Component {
|
||||
movie,
|
||||
quality,
|
||||
customFormats,
|
||||
customFormatScore,
|
||||
languages,
|
||||
protocol,
|
||||
indexer,
|
||||
@@ -201,6 +204,24 @@ class QueueRow extends Component {
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'customFormatScore') {
|
||||
return (
|
||||
<TableRowCell
|
||||
key={name}
|
||||
className={styles.customFormatScore}
|
||||
>
|
||||
<Tooltip
|
||||
anchor={formatCustomFormatScore(
|
||||
customFormatScore,
|
||||
customFormats.length
|
||||
)}
|
||||
tooltip={<MovieFormats formats={customFormats} />}
|
||||
position={tooltipPositions.BOTTOM}
|
||||
/>
|
||||
</TableRowCell>
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'protocol') {
|
||||
return (
|
||||
<TableRowCell key={name}>
|
||||
@@ -365,6 +386,7 @@ QueueRow.propTypes = {
|
||||
movie: PropTypes.object,
|
||||
quality: PropTypes.object.isRequired,
|
||||
customFormats: PropTypes.arrayOf(PropTypes.object),
|
||||
customFormatScore: PropTypes.number.isRequired,
|
||||
languages: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||
protocol: PropTypes.string.isRequired,
|
||||
indexer: PropTypes.string,
|
||||
@@ -390,6 +412,7 @@ QueueRow.propTypes = {
|
||||
};
|
||||
|
||||
QueueRow.defaultProps = {
|
||||
customFormats: [],
|
||||
isGrabbing: false,
|
||||
isRemoving: false
|
||||
};
|
||||
|
||||
@@ -22,7 +22,8 @@ class RemoveQueueItemModal extends Component {
|
||||
|
||||
this.state = {
|
||||
remove: true,
|
||||
blocklist: false
|
||||
blocklist: false,
|
||||
skipRedownload: false
|
||||
};
|
||||
}
|
||||
|
||||
@@ -32,7 +33,8 @@ class RemoveQueueItemModal extends Component {
|
||||
resetState = function() {
|
||||
this.setState({
|
||||
remove: true,
|
||||
blocklist: false
|
||||
blocklist: false,
|
||||
skipRedownload: false
|
||||
});
|
||||
};
|
||||
|
||||
@@ -47,6 +49,10 @@ class RemoveQueueItemModal extends Component {
|
||||
this.setState({ blocklist: value });
|
||||
};
|
||||
|
||||
onSkipRedownloadChange = ({ value }) => {
|
||||
this.setState({ skipRedownload: value });
|
||||
};
|
||||
|
||||
onRemoveConfirmed = () => {
|
||||
const state = this.state;
|
||||
|
||||
@@ -70,7 +76,7 @@ class RemoveQueueItemModal extends Component {
|
||||
isPending
|
||||
} = this.props;
|
||||
|
||||
const { remove, blocklist } = this.state;
|
||||
const { remove, blocklist, skipRedownload } = this.state;
|
||||
|
||||
return (
|
||||
<Modal
|
||||
@@ -118,6 +124,20 @@ class RemoveQueueItemModal extends Component {
|
||||
/>
|
||||
</FormGroup>
|
||||
|
||||
{
|
||||
blocklist ?
|
||||
<FormGroup>
|
||||
<FormLabel>{translate('SkipRedownload')}</FormLabel>
|
||||
<FormInputGroup
|
||||
type={inputTypes.CHECK}
|
||||
name="skipRedownload"
|
||||
value={skipRedownload}
|
||||
helpText={translate('SkipRedownloadHelpText')}
|
||||
onChange={this.onSkipRedownloadChange}
|
||||
/>
|
||||
</FormGroup> :
|
||||
null
|
||||
}
|
||||
</ModalBody>
|
||||
|
||||
<ModalFooter>
|
||||
|
||||
@@ -23,7 +23,8 @@ class RemoveQueueItemsModal extends Component {
|
||||
|
||||
this.state = {
|
||||
remove: true,
|
||||
blocklist: false
|
||||
blocklist: false,
|
||||
skipRedownload: false
|
||||
};
|
||||
}
|
||||
|
||||
@@ -33,7 +34,8 @@ class RemoveQueueItemsModal extends Component {
|
||||
resetState = function() {
|
||||
this.setState({
|
||||
remove: true,
|
||||
blocklist: false
|
||||
blocklist: false,
|
||||
skipRedownload: false
|
||||
});
|
||||
};
|
||||
|
||||
@@ -48,6 +50,10 @@ class RemoveQueueItemsModal extends Component {
|
||||
this.setState({ blocklist: value });
|
||||
};
|
||||
|
||||
onSkipRedownloadChange = ({ value }) => {
|
||||
this.setState({ skipRedownload: value });
|
||||
};
|
||||
|
||||
onRemoveConfirmed = () => {
|
||||
const state = this.state;
|
||||
|
||||
@@ -71,7 +77,7 @@ class RemoveQueueItemsModal extends Component {
|
||||
allPending
|
||||
} = this.props;
|
||||
|
||||
const { remove, blocklist } = this.state;
|
||||
const { remove, blocklist, skipRedownload } = this.state;
|
||||
|
||||
return (
|
||||
<Modal
|
||||
@@ -122,6 +128,20 @@ class RemoveQueueItemsModal extends Component {
|
||||
/>
|
||||
</FormGroup>
|
||||
|
||||
{
|
||||
blocklist ?
|
||||
<FormGroup>
|
||||
<FormLabel>{translate('SkipRedownload')}</FormLabel>
|
||||
<FormInputGroup
|
||||
type={inputTypes.CHECK}
|
||||
name="skipRedownload"
|
||||
value={skipRedownload}
|
||||
helpText={translate('SkipRedownloadHelpText')}
|
||||
onChange={this.onSkipRedownloadChange}
|
||||
/>
|
||||
</FormGroup> :
|
||||
null
|
||||
}
|
||||
</ModalBody>
|
||||
|
||||
<ModalFooter>
|
||||
|
||||
@@ -7,13 +7,13 @@ import PageConnector from 'Components/Page/PageConnector';
|
||||
import ApplyTheme from './ApplyTheme';
|
||||
import AppRoutes from './AppRoutes';
|
||||
|
||||
function App({ store, history }) {
|
||||
function App({ store, history, hasTranslationsError }) {
|
||||
return (
|
||||
<DocumentTitle title={window.Radarr.instanceName}>
|
||||
<Provider store={store}>
|
||||
<ConnectedRouter history={history}>
|
||||
<ApplyTheme>
|
||||
<PageConnector>
|
||||
<PageConnector hasTranslationsError={hasTranslationsError}>
|
||||
<AppRoutes app={App} />
|
||||
</PageConnector>
|
||||
</ApplyTheme>
|
||||
@@ -25,7 +25,8 @@ function App({ store, history }) {
|
||||
|
||||
App.propTypes = {
|
||||
store: PropTypes.object.isRequired,
|
||||
history: PropTypes.object.isRequired
|
||||
history: PropTypes.object.isRequired,
|
||||
hasTranslationsError: PropTypes.bool.isRequired
|
||||
};
|
||||
|
||||
export default App;
|
||||
|
||||
@@ -13,7 +13,7 @@ import Switch from 'Components/Router/Switch';
|
||||
import DiscoverMovieConnector from 'DiscoverMovie/DiscoverMovieConnector';
|
||||
import MovieDetailsPageConnector from 'Movie/Details/MovieDetailsPageConnector';
|
||||
import MovieIndex from 'Movie/Index/MovieIndex';
|
||||
import CustomFormatSettingsConnector from 'Settings/CustomFormats/CustomFormatSettingsConnector';
|
||||
import CustomFormatSettingsPage from 'Settings/CustomFormats/CustomFormatSettingsPage';
|
||||
import DownloadClientSettingsConnector from 'Settings/DownloadClients/DownloadClientSettingsConnector';
|
||||
import GeneralSettingsConnector from 'Settings/General/GeneralSettingsConnector';
|
||||
import ImportListSettingsConnector from 'Settings/ImportLists/ImportListSettingsConnector';
|
||||
@@ -148,7 +148,7 @@ function AppRoutes(props) {
|
||||
|
||||
<Route
|
||||
path="/settings/customformats"
|
||||
component={CustomFormatSettingsConnector}
|
||||
component={CustomFormatSettingsPage}
|
||||
/>
|
||||
|
||||
<Route
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import InteractiveImportAppState from 'App/State/InteractiveImportAppState';
|
||||
import MovieFilesAppState from './MovieFilesAppState';
|
||||
import MoviesAppState, { MovieIndexAppState } from './MoviesAppState';
|
||||
import ParseAppState from './ParseAppState';
|
||||
import QueueAppState from './QueueAppState';
|
||||
import SettingsAppState from './SettingsAppState';
|
||||
import TagsAppState from './TagsAppState';
|
||||
@@ -41,6 +42,7 @@ interface AppState {
|
||||
movieFiles: MovieFilesAppState;
|
||||
interactiveImport: InteractiveImportAppState;
|
||||
movieIndex: MovieIndexAppState;
|
||||
parse: ParseAppState;
|
||||
settings: SettingsAppState;
|
||||
movies: MoviesAppState;
|
||||
tags: TagsAppState;
|
||||
|
||||
34
frontend/src/App/State/ParseAppState.ts
Normal file
@@ -0,0 +1,34 @@
|
||||
import ModelBase from 'App/ModelBase';
|
||||
import { AppSectionItemState } from 'App/State/AppSectionState';
|
||||
import Language from 'Language/Language';
|
||||
import Movie from 'Movie/Movie';
|
||||
import { QualityModel } from 'Quality/Quality';
|
||||
import CustomFormat from 'typings/CustomFormat';
|
||||
|
||||
export interface ParsedMovieInfo {
|
||||
releaseTitle: string;
|
||||
originalTitle: string;
|
||||
movieTitle: string;
|
||||
movieTitles: string[];
|
||||
year: number;
|
||||
quality: QualityModel;
|
||||
languages: Language[];
|
||||
releaseHash: string;
|
||||
releaseGroup?: string;
|
||||
edition?: string;
|
||||
tmdbId?: number;
|
||||
imdbId?: string;
|
||||
}
|
||||
|
||||
export interface ParseModel extends ModelBase {
|
||||
title: string;
|
||||
parsedMovieInfo: ParsedMovieInfo;
|
||||
movie?: Movie;
|
||||
languages?: Language[];
|
||||
customFormats?: CustomFormat[];
|
||||
customFormatScore?: number;
|
||||
}
|
||||
|
||||
type ParseAppState = AppSectionItemState<ParseModel>;
|
||||
|
||||
export default ParseAppState;
|
||||
@@ -28,7 +28,7 @@ function createMapStateToProps() {
|
||||
qualityProfileId: collection.qualityProfileId,
|
||||
minimumAvailability: collection.minimumAvailability,
|
||||
searchForMovie: collection.searchOnAdd,
|
||||
tags: []
|
||||
tags: collection.tags || []
|
||||
};
|
||||
|
||||
const {
|
||||
|
||||
@@ -2,17 +2,12 @@ import PropTypes from 'prop-types';
|
||||
import React, { Component } from 'react';
|
||||
import { connect } from 'react-redux';
|
||||
import { createSelector } from 'reselect';
|
||||
import createAllMoviesSelector from 'Store/Selectors/createAllMoviesSelector';
|
||||
import createCollectionSelector from 'Store/Selectors/createCollectionSelector';
|
||||
|
||||
function createMapStateToProps() {
|
||||
return createSelector(
|
||||
createCollectionSelector(),
|
||||
createAllMoviesSelector(),
|
||||
(
|
||||
collection,
|
||||
allMovies
|
||||
) => {
|
||||
(collection) => {
|
||||
// If a movie is deleted this selector may fire before the parent
|
||||
// selecors, which will result in an undefined movie, if that happens
|
||||
// we want to return early here and again in the render function to avoid
|
||||
@@ -22,21 +17,11 @@ function createMapStateToProps() {
|
||||
return {};
|
||||
}
|
||||
|
||||
let allGenres = [];
|
||||
let libraryMovies = 0;
|
||||
|
||||
collection.movies.forEach((movie) => {
|
||||
allGenres = allGenres.concat(movie.genres);
|
||||
|
||||
if (allMovies.find((libraryMovie) => libraryMovie.tmdbId === movie.tmdbId)) {
|
||||
libraryMovies++;
|
||||
}
|
||||
});
|
||||
const allGenres = collection.movies.flatMap((movie) => movie.genres);
|
||||
|
||||
return {
|
||||
...collection,
|
||||
genres: Array.from(new Set(allGenres)).slice(0, 3),
|
||||
missingMovies: collection.movies.length - libraryMovies
|
||||
genres: Array.from(new Set(allGenres)).slice(0, 3)
|
||||
};
|
||||
}
|
||||
);
|
||||
|
||||
@@ -50,6 +50,7 @@ class EditCollectionModalContent extends Component {
|
||||
minimumAvailability,
|
||||
// Id,
|
||||
rootFolderPath,
|
||||
tags,
|
||||
searchOnAdd
|
||||
} = item;
|
||||
|
||||
@@ -126,6 +127,17 @@ class EditCollectionModalContent extends Component {
|
||||
/>
|
||||
</FormGroup>
|
||||
|
||||
<FormGroup>
|
||||
<FormLabel>{translate('Tags')}</FormLabel>
|
||||
|
||||
<FormInputGroup
|
||||
type={inputTypes.TAG}
|
||||
name="tags"
|
||||
onChange={onInputChange}
|
||||
{...tags}
|
||||
/>
|
||||
</FormGroup>
|
||||
|
||||
<FormGroup>
|
||||
<FormLabel>{translate('SearchOnAdd')}</FormLabel>
|
||||
|
||||
|
||||
@@ -42,6 +42,7 @@ function createMapStateToProps() {
|
||||
qualityProfileId: collection.qualityProfileId,
|
||||
minimumAvailability: collection.minimumAvailability,
|
||||
rootFolderPath: collection.rootFolderPath,
|
||||
tags: collection.tags,
|
||||
searchOnAdd: collection.searchOnAdd
|
||||
};
|
||||
|
||||
|
||||
@@ -28,6 +28,14 @@ function CollectionSortMenu(props) {
|
||||
>
|
||||
{translate('Title')}
|
||||
</SortMenuItem>
|
||||
<SortMenuItem
|
||||
name="missingMovies"
|
||||
sortKey={sortKey}
|
||||
sortDirection={sortDirection}
|
||||
onPress={onSortSelect}
|
||||
>
|
||||
{translate('Missing')}
|
||||
</SortMenuItem>
|
||||
</MenuContent>
|
||||
</SortMenu>
|
||||
);
|
||||
|
||||
@@ -102,7 +102,7 @@ $hoverScale: 1.05;
|
||||
|
||||
position: relative;
|
||||
display: block;
|
||||
background-color: var(--defaultColor);
|
||||
background-color: var(--black);
|
||||
}
|
||||
|
||||
.monitorToggleButton {
|
||||
|
||||
@@ -580,7 +580,7 @@ EnhancedSelectInput.propTypes = {
|
||||
className: PropTypes.string,
|
||||
disabledClassName: PropTypes.string,
|
||||
name: PropTypes.string.isRequired,
|
||||
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number, PropTypes.arrayOf(PropTypes.number)]).isRequired,
|
||||
value: PropTypes.oneOfType([PropTypes.string, PropTypes.number, PropTypes.arrayOf(PropTypes.string), PropTypes.arrayOf(PropTypes.number)]).isRequired,
|
||||
values: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||
isDisabled: PropTypes.bool.isRequired,
|
||||
isFetching: PropTypes.bool.isRequired,
|
||||
|
||||
@@ -69,7 +69,7 @@ class QualityProfileSelectInputConnector extends Component {
|
||||
// Listeners
|
||||
|
||||
onChange = ({ name, value }) => {
|
||||
this.props.onChange({ name, value: parseInt(value) });
|
||||
this.props.onChange({ name, value: value === 'noChange' ? value : parseInt(value) });
|
||||
};
|
||||
|
||||
//
|
||||
|
||||
@@ -7,6 +7,7 @@ function ErrorPage(props) {
|
||||
const {
|
||||
version,
|
||||
isLocalStorageSupported,
|
||||
hasTranslationsError,
|
||||
moviesError,
|
||||
customFiltersError,
|
||||
tagsError,
|
||||
@@ -20,6 +21,8 @@ function ErrorPage(props) {
|
||||
|
||||
if (!isLocalStorageSupported) {
|
||||
errorMessage = 'Local Storage is not supported or disabled. A plugin or private browsing may have disabled it.';
|
||||
} else if (hasTranslationsError) {
|
||||
errorMessage = 'Failed to load translations from API';
|
||||
} else if (moviesError) {
|
||||
errorMessage = getErrorMessage(moviesError, 'Failed to load movie from API');
|
||||
} else if (customFiltersError) {
|
||||
@@ -52,6 +55,7 @@ function ErrorPage(props) {
|
||||
ErrorPage.propTypes = {
|
||||
version: PropTypes.string.isRequired,
|
||||
isLocalStorageSupported: PropTypes.bool.isRequired,
|
||||
hasTranslationsError: PropTypes.bool.isRequired,
|
||||
moviesError: PropTypes.object,
|
||||
customFiltersError: PropTypes.object,
|
||||
tagsError: PropTypes.object,
|
||||
|
||||
@@ -232,6 +232,7 @@ class PageConnector extends Component {
|
||||
|
||||
render() {
|
||||
const {
|
||||
hasTranslationsError,
|
||||
isPopulated,
|
||||
hasError,
|
||||
dispatchFetchMovies,
|
||||
@@ -246,11 +247,12 @@ class PageConnector extends Component {
|
||||
...otherProps
|
||||
} = this.props;
|
||||
|
||||
if (hasError || !this.state.isLocalStorageSupported) {
|
||||
if (hasTranslationsError || hasError || !this.state.isLocalStorageSupported) {
|
||||
return (
|
||||
<ErrorPage
|
||||
{...this.state}
|
||||
{...otherProps}
|
||||
hasTranslationsError={hasTranslationsError}
|
||||
/>
|
||||
);
|
||||
}
|
||||
@@ -271,6 +273,7 @@ class PageConnector extends Component {
|
||||
}
|
||||
|
||||
PageConnector.propTypes = {
|
||||
hasTranslationsError: PropTypes.bool.isRequired,
|
||||
isPopulated: PropTypes.bool.isRequired,
|
||||
hasError: PropTypes.bool.isRequired,
|
||||
isSidebarVisible: PropTypes.bool.isRequired,
|
||||
|
||||
@@ -5,8 +5,8 @@ import { isLocked } from 'Utilities/scrollLock';
|
||||
import styles from './PageContentBody.css';
|
||||
|
||||
interface PageContentBodyProps {
|
||||
className: string;
|
||||
innerClassName: string;
|
||||
className?: string;
|
||||
innerClassName?: string;
|
||||
children: ReactNode;
|
||||
initialScrollTop?: number;
|
||||
onScroll?: (payload: OnScroll) => void;
|
||||
|
||||
|
Before Width: | Height: | Size: 101 KiB After Width: | Height: | Size: 100 KiB |
|
Before Width: | Height: | Size: 8.7 KiB After Width: | Height: | Size: 4.8 KiB |
|
Before Width: | Height: | Size: 28 KiB After Width: | Height: | Size: 17 KiB |
|
Before Width: | Height: | Size: 9.3 KiB After Width: | Height: | Size: 5.7 KiB |
|
Before Width: | Height: | Size: 1.4 KiB After Width: | Height: | Size: 611 B |
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 549 B After Width: | Height: | Size: 337 B |
|
Before Width: | Height: | Size: 1.0 KiB After Width: | Height: | Size: 623 B |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.3 KiB |
|
Before Width: | Height: | Size: 2.4 KiB After Width: | Height: | Size: 1.8 KiB |
|
Before Width: | Height: | Size: 2.6 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 1.3 KiB After Width: | Height: | Size: 1.2 KiB |
|
Before Width: | Height: | Size: 1.9 KiB After Width: | Height: | Size: 1.4 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 7.0 KiB |
|
Before Width: | Height: | Size: 9.5 KiB After Width: | Height: | Size: 6.5 KiB |
|
Before Width: | Height: | Size: 10 KiB After Width: | Height: | Size: 7.2 KiB |
|
Before Width: | Height: | Size: 22 KiB After Width: | Height: | Size: 16 KiB |
|
Before Width: | Height: | Size: 6.7 KiB After Width: | Height: | Size: 4.5 KiB |
|
Before Width: | Height: | Size: 160 KiB After Width: | Height: | Size: 115 KiB |
|
Before Width: | Height: | Size: 29 KiB After Width: | Height: | Size: 18 KiB |
|
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 5.2 KiB |
|
Before Width: | Height: | Size: 953 B After Width: | Height: | Size: 592 B |
@@ -39,6 +39,12 @@
|
||||
flex: 0 0 90px;
|
||||
}
|
||||
|
||||
.popularity {
|
||||
composes: headerCell from '~Components/Table/VirtualTableHeaderCell.css';
|
||||
|
||||
flex: 0 0 100px;
|
||||
}
|
||||
|
||||
.lists {
|
||||
composes: headerCell from '~Components/Table/VirtualTableHeaderCell.css';
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ interface CssExports {
|
||||
'lists': string;
|
||||
'originalLanguage': string;
|
||||
'physicalRelease': string;
|
||||
'popularity': string;
|
||||
'ratings': string;
|
||||
'runtime': string;
|
||||
'sortTitle': string;
|
||||
|
||||
@@ -64,6 +64,12 @@
|
||||
flex: 0 0 90px;
|
||||
}
|
||||
|
||||
.popularity {
|
||||
composes: cell;
|
||||
|
||||
flex: 0 0 100px;
|
||||
}
|
||||
|
||||
.lists {
|
||||
composes: cell;
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@ interface CssExports {
|
||||
'lists': string;
|
||||
'originalLanguage': string;
|
||||
'physicalRelease': string;
|
||||
'popularity': string;
|
||||
'ratings': string;
|
||||
'runtime': string;
|
||||
'sortTitle': string;
|
||||
|
||||
@@ -13,6 +13,7 @@ import AddNewDiscoverMovieModal from 'DiscoverMovie/AddNewDiscoverMovieModal';
|
||||
import ExcludeMovieModal from 'DiscoverMovie/Exclusion/ExcludeMovieModal';
|
||||
import { icons } from 'Helpers/Props';
|
||||
import MovieDetailsLinks from 'Movie/Details/MovieDetailsLinks';
|
||||
import MoviePopularityIndex from 'Movie/MoviePopularityIndex';
|
||||
import formatRuntime from 'Utilities/Date/formatRuntime';
|
||||
import translate from 'Utilities/String/translate';
|
||||
import ListMovieStatusCell from './ListMovieStatusCell';
|
||||
@@ -73,6 +74,7 @@ class DiscoverMovieRow extends Component {
|
||||
images,
|
||||
genres,
|
||||
ratings,
|
||||
popularity,
|
||||
certification,
|
||||
collection,
|
||||
columns,
|
||||
@@ -261,6 +263,14 @@ class DiscoverMovieRow extends Component {
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'popularity') {
|
||||
return (
|
||||
<VirtualTableRowCell key={name} className={styles[name]}>
|
||||
<MoviePopularityIndex popularity={popularity} />
|
||||
</VirtualTableRowCell>
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'certification') {
|
||||
return (
|
||||
<VirtualTableRowCell
|
||||
@@ -384,6 +394,7 @@ DiscoverMovieRow.propTypes = {
|
||||
runtime: PropTypes.number,
|
||||
genres: PropTypes.arrayOf(PropTypes.string).isRequired,
|
||||
ratings: PropTypes.object.isRequired,
|
||||
popularity: PropTypes.number.isRequired,
|
||||
certification: PropTypes.string,
|
||||
collection: PropTypes.object,
|
||||
columns: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||
|
||||
@@ -34,6 +34,7 @@ import {
|
||||
faBug as fasBug,
|
||||
faBuilding as fasBuilding,
|
||||
faBullhorn as fasBullhorn,
|
||||
faCalculator as fasCalculator,
|
||||
faCalendarAlt as fasCalendarAlt,
|
||||
faCaretDown as fasCaretDown,
|
||||
faCheck as fasCheck,
|
||||
@@ -61,6 +62,7 @@ import {
|
||||
faFileInvoice as farFileInvoice,
|
||||
faFilm as fasFilm,
|
||||
faFilter as fasFilter,
|
||||
faFire as fasFire,
|
||||
faFlag as fasFlag,
|
||||
faFolderOpen as fasFolderOpen,
|
||||
faForward as fasForward,
|
||||
@@ -188,10 +190,12 @@ export const PAGE_PREVIOUS = fasBackward;
|
||||
export const PAGE_NEXT = fasForward;
|
||||
export const PAGE_LAST = fasFastForward;
|
||||
export const PARENT = fasLevelUpAlt;
|
||||
export const PARSE = fasCalculator;
|
||||
export const PAUSED = fasPause;
|
||||
export const PENDING = farClock;
|
||||
export const PLAY = fasPlay;
|
||||
export const PROFILE = fasUser;
|
||||
export const POPULAR = fasFire;
|
||||
export const POSTER = fasTh;
|
||||
export const QUEUED = fasCloud;
|
||||
export const QUICK = fasRocket;
|
||||
|
||||
@@ -4,12 +4,8 @@
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.filteredMessage {
|
||||
.alert {
|
||||
composes: alert from '~Components/Alert.css';
|
||||
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.blankpad {
|
||||
padding-top: 10px;
|
||||
padding-bottom: 10px;
|
||||
padding-left: 2em;
|
||||
}
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'blankpad': string;
|
||||
'alert': string;
|
||||
'filterMenuContainer': string;
|
||||
'filteredMessage': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import PropTypes from 'prop-types';
|
||||
import React from 'react';
|
||||
import Alert from 'Components/Alert';
|
||||
import Icon from 'Components/Icon';
|
||||
import LoadingIndicator from 'Components/Loading/LoadingIndicator';
|
||||
import Table from 'Components/Table/Table';
|
||||
import TableBody from 'Components/Table/TableBody';
|
||||
import { icons, sortDirections } from 'Helpers/Props';
|
||||
import { icons, kinds, sortDirections } from 'Helpers/Props';
|
||||
import translate from 'Utilities/String/translate';
|
||||
import InteractiveSearchRowConnector from './InteractiveSearchRowConnector';
|
||||
import styles from './InteractiveSearchContent.css';
|
||||
@@ -127,23 +128,23 @@ function InteractiveSearchContent(props) {
|
||||
|
||||
{
|
||||
!isFetching && !!error &&
|
||||
<div className={styles.blankpad}>
|
||||
<Alert kind={kinds.DANGER} className={styles.alert}>
|
||||
{translate('UnableToLoadResultsIntSearch')}
|
||||
</div>
|
||||
</Alert>
|
||||
}
|
||||
|
||||
{
|
||||
!isFetching && isPopulated && !totalReleasesCount &&
|
||||
<div className={styles.blankpad}>
|
||||
<Alert kind={kinds.INFO} className={styles.alert}>
|
||||
{translate('NoResultsFound')}
|
||||
</div>
|
||||
</Alert>
|
||||
}
|
||||
|
||||
{
|
||||
!!totalReleasesCount && isPopulated && !items.length &&
|
||||
<div className={styles.blankpad}>
|
||||
<Alert kind={kinds.WARNING} className={styles.alert}>
|
||||
{translate('AllResultsHiddenFilter')}
|
||||
</div>
|
||||
</Alert>
|
||||
}
|
||||
|
||||
{
|
||||
@@ -175,9 +176,9 @@ function InteractiveSearchContent(props) {
|
||||
|
||||
{
|
||||
totalReleasesCount !== items.length && !!items.length &&
|
||||
<div className={styles.filteredMessage}>
|
||||
<Alert kind={kinds.INFO} className={styles.alert}>
|
||||
{translate('SomeResultsHiddenFilter')}
|
||||
</div>
|
||||
</Alert>
|
||||
}
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -31,6 +31,7 @@ function createMapDispatchToProps(dispatch, props) {
|
||||
dispatch(
|
||||
deleteMovie({
|
||||
id: props.movieId,
|
||||
collectionTmdbId: this.collection?.tmdbId,
|
||||
deleteFiles,
|
||||
addImportExclusion
|
||||
})
|
||||
|
||||
@@ -303,6 +303,7 @@ class MovieDetails extends Component {
|
||||
selectedTabIndex
|
||||
} = this.state;
|
||||
|
||||
const fanartUrl = getFanartUrl(images);
|
||||
const marqueeWidth = isSmallScreen ? titleWidth : (titleWidth - 150);
|
||||
|
||||
return (
|
||||
@@ -361,9 +362,11 @@ class MovieDetails extends Component {
|
||||
<div className={styles.header}>
|
||||
<div
|
||||
className={styles.backdrop}
|
||||
style={{
|
||||
backgroundImage: `url(${getFanartUrl(images)})`
|
||||
}}
|
||||
style={
|
||||
fanartUrl ?
|
||||
{ backgroundImage: `url(${fanartUrl})` } :
|
||||
null
|
||||
}
|
||||
>
|
||||
<div className={styles.backdropOverlay} />
|
||||
</div>
|
||||
|
||||
10
frontend/src/Movie/History/MovieHistoryTable.css
Normal file
@@ -0,0 +1,10 @@
|
||||
.container {
|
||||
margin-top: 20px;
|
||||
border: 1px solid var(--borderColor);
|
||||
border-radius: 4px;
|
||||
background-color: var(--inputBackgroundColor);
|
||||
|
||||
&:last-of-type {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
7
frontend/src/Movie/History/MovieHistoryTable.css.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'container': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||
@@ -1,5 +1,6 @@
|
||||
import React from 'react';
|
||||
import MovieHistoryTableContentConnector from './MovieHistoryTableContentConnector';
|
||||
import styles from './MovieHistoryTable.css';
|
||||
|
||||
function MovieHistoryTable(props) {
|
||||
const {
|
||||
@@ -7,9 +8,11 @@ function MovieHistoryTable(props) {
|
||||
} = props;
|
||||
|
||||
return (
|
||||
<MovieHistoryTableContentConnector
|
||||
{...otherProps}
|
||||
/>
|
||||
<div className={styles.container}>
|
||||
<MovieHistoryTableContentConnector
|
||||
{...otherProps}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -118,6 +118,15 @@ function MovieIndexSortMenu(props: MovieIndexSortMenuProps) {
|
||||
{translate('TmdbRating')}
|
||||
</SortMenuItem>
|
||||
|
||||
<SortMenuItem
|
||||
name="popularity"
|
||||
sortKey={sortKey}
|
||||
sortDirection={sortDirection}
|
||||
onPress={onSortSelect}
|
||||
>
|
||||
{translate('Popularity')}
|
||||
</SortMenuItem>
|
||||
|
||||
<SortMenuItem
|
||||
name="path"
|
||||
sortKey={sortKey}
|
||||
|
||||
@@ -71,6 +71,9 @@ function MovieIndexOverview(props: MovieIndexOverviewProps) {
|
||||
isAvailable,
|
||||
tmdbId,
|
||||
imdbId,
|
||||
studio,
|
||||
sizeOnDisk,
|
||||
added,
|
||||
youTubeTrailerId,
|
||||
} = movie;
|
||||
|
||||
@@ -219,6 +222,9 @@ function MovieIndexOverview(props: MovieIndexOverviewProps) {
|
||||
height={overviewHeight}
|
||||
monitored={monitored}
|
||||
qualityProfile={qualityProfile}
|
||||
studio={studio}
|
||||
sizeOnDisk={sizeOnDisk}
|
||||
added={added}
|
||||
path={path}
|
||||
sortKey={sortKey}
|
||||
{...overviewOptions}
|
||||
|
||||
@@ -56,7 +56,7 @@ const rows = [
|
||||
{
|
||||
name: 'qualityProfileId',
|
||||
showProp: 'showQualityProfile',
|
||||
valueProp: 'qualityProfileId',
|
||||
valueProp: 'qualityProfile',
|
||||
},
|
||||
{
|
||||
name: 'added',
|
||||
|
||||
@@ -203,7 +203,7 @@ function EditMoviesModalContent(props: EditMoviesModalContentProps) {
|
||||
<Button onPress={onModalClose}>{translate('Cancel')}</Button>
|
||||
|
||||
<Button onPress={onSavePressWrapper}>
|
||||
{translate('Apply Changes')}
|
||||
{translate('ApplyChanges')}
|
||||
</Button>
|
||||
</div>
|
||||
</ModalFooter>
|
||||
|
||||
@@ -65,7 +65,7 @@ function OrganizeMoviesModalContent(props: OrganizeMoviesModalContentProps) {
|
||||
</Alert>
|
||||
|
||||
<div className={styles.message}>
|
||||
{translate('OrganizeConfirm', movieTitles.length)}
|
||||
{translate('OrganizeConfirm', [movieTitles.length])}
|
||||
</div>
|
||||
|
||||
<ul>
|
||||
|
||||
@@ -98,10 +98,10 @@ function TagsModalContent(props: TagsModalContentProps) {
|
||||
value={applyTags}
|
||||
values={applyTagsOptions}
|
||||
helpTexts={[
|
||||
translate('ApplyTagsHelpTexts1'),
|
||||
translate('ApplyTagsHelpTexts2'),
|
||||
translate('ApplyTagsHelpTexts3'),
|
||||
translate('ApplyTagsHelpTexts4'),
|
||||
translate('ApplyTagsHelpTextHowToApplyMovies'),
|
||||
translate('ApplyTagsHelpTextAdd'),
|
||||
translate('ApplyTagsHelpTextRemove'),
|
||||
translate('ApplyTagsHelpTextReplace'),
|
||||
]}
|
||||
onChange={onApplyTagsChange}
|
||||
/>
|
||||
|
||||
@@ -48,6 +48,7 @@
|
||||
}
|
||||
|
||||
.added,
|
||||
.popularity,
|
||||
.runtime {
|
||||
composes: cell;
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@ interface CssExports {
|
||||
'originalTitle': string;
|
||||
'path': string;
|
||||
'physicalRelease': string;
|
||||
'popularity': string;
|
||||
'qualityProfileId': string;
|
||||
'rottenTomatoesRating': string;
|
||||
'runtime': string;
|
||||
|
||||
@@ -19,6 +19,7 @@ import DeleteMovieModal from 'Movie/Delete/DeleteMovieModal';
|
||||
import MovieDetailsLinks from 'Movie/Details/MovieDetailsLinks';
|
||||
import EditMovieModalConnector from 'Movie/Edit/EditMovieModalConnector';
|
||||
import createMovieIndexItemSelector from 'Movie/Index/createMovieIndexItemSelector';
|
||||
import MoviePopularityIndex from 'Movie/MoviePopularityIndex';
|
||||
import MovieTitleLink from 'Movie/MovieTitleLink';
|
||||
import { executeCommand } from 'Store/Actions/commandActions';
|
||||
import createUISettingsSelector from 'Store/Selectors/createUISettingsSelector';
|
||||
@@ -69,6 +70,7 @@ function MovieIndexRow(props: MovieIndexRowProps) {
|
||||
sizeOnDisk,
|
||||
genres = [],
|
||||
ratings,
|
||||
popularity,
|
||||
certification,
|
||||
tags = [],
|
||||
tmdbId,
|
||||
@@ -362,6 +364,14 @@ function MovieIndexRow(props: MovieIndexRowProps) {
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'popularity') {
|
||||
return (
|
||||
<VirtualTableRowCell key={name} className={styles[name]}>
|
||||
<MoviePopularityIndex popularity={popularity} />
|
||||
</VirtualTableRowCell>
|
||||
);
|
||||
}
|
||||
|
||||
if (name === 'certification') {
|
||||
return (
|
||||
<VirtualTableRowCell key={name} className={styles[name]}>
|
||||
|
||||
@@ -1,3 +1,11 @@
|
||||
.tableScroller {
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.row {
|
||||
transition: background-color 500ms;
|
||||
|
||||
&:hover {
|
||||
background-color: var(--tableRowHoverBackgroundColor);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'row': string;
|
||||
'tableScroller': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
|
||||
@@ -64,6 +64,7 @@ const Row: React.FC<ListChildComponentProps<RowItemData>> = ({
|
||||
justifyContent: 'space-between',
|
||||
...style,
|
||||
}}
|
||||
className={styles.row}
|
||||
>
|
||||
<MovieIndexRow
|
||||
movieId={movie.id}
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
}
|
||||
|
||||
.added,
|
||||
.popularity,
|
||||
.runtime {
|
||||
composes: headerCell from '~Components/Table/VirtualTableHeaderCell.css';
|
||||
|
||||
|
||||
@@ -15,6 +15,7 @@ interface CssExports {
|
||||
'originalTitle': string;
|
||||
'path': string;
|
||||
'physicalRelease': string;
|
||||
'popularity': string;
|
||||
'qualityProfileId': string;
|
||||
'rottenTomatoesRating': string;
|
||||
'runtime': string;
|
||||
|
||||
@@ -49,6 +49,7 @@ interface Movie extends ModelBase {
|
||||
sizeOnDisk: number;
|
||||
genres: string[];
|
||||
ratings: Ratings;
|
||||
popularity: number;
|
||||
certification: string;
|
||||
tags: number[];
|
||||
images: Image[];
|
||||
|
||||
5
frontend/src/Movie/MoviePopularityIndex.css
Normal file
@@ -0,0 +1,5 @@
|
||||
.popularityIcon {
|
||||
margin-right: 2px;
|
||||
width: 12px !important;
|
||||
text-align: center;
|
||||
}
|
||||
7
frontend/src/Movie/MoviePopularityIndex.css.d.ts
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'popularityIcon': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||
23
frontend/src/Movie/MoviePopularityIndex.tsx
Normal file
@@ -0,0 +1,23 @@
|
||||
import React from 'react';
|
||||
import Icon from 'Components/Icon';
|
||||
import Label from 'Components/Label';
|
||||
import { icons, kinds } from 'Helpers/Props';
|
||||
import translate from 'Utilities/String/translate';
|
||||
import styles from './MoviePopularityIndex.css';
|
||||
|
||||
interface MoviePopularityIndexProps {
|
||||
popularity: number;
|
||||
}
|
||||
|
||||
function MoviePopularityIndex(props: MoviePopularityIndexProps) {
|
||||
const { popularity } = props;
|
||||
|
||||
return (
|
||||
<Label kind={kinds.INVERSE} title={translate('PopularityIndex')}>
|
||||
<Icon className={styles.popularityIcon} name={icons.POPULAR} size={11} />
|
||||
{popularity.toFixed()}
|
||||
</Label>
|
||||
);
|
||||
}
|
||||
|
||||
export default MoviePopularityIndex;
|
||||
@@ -7,7 +7,8 @@ class MovieTitleLink extends PureComponent {
|
||||
render() {
|
||||
const {
|
||||
titleSlug,
|
||||
title
|
||||
title,
|
||||
year
|
||||
} = this.props;
|
||||
|
||||
const link = `/movie/${titleSlug}`;
|
||||
@@ -17,7 +18,7 @@ class MovieTitleLink extends PureComponent {
|
||||
to={link}
|
||||
title={title}
|
||||
>
|
||||
{title}
|
||||
{title}{year > 0 ? ` (${year})` : ''}
|
||||
</Link>
|
||||
);
|
||||
}
|
||||
@@ -25,7 +26,8 @@ class MovieTitleLink extends PureComponent {
|
||||
|
||||
MovieTitleLink.propTypes = {
|
||||
titleSlug: PropTypes.string.isRequired,
|
||||
title: PropTypes.string.isRequired
|
||||
title: PropTypes.string.isRequired,
|
||||
year: PropTypes.number
|
||||
};
|
||||
|
||||
export default MovieTitleLink;
|
||||
|
||||
45
frontend/src/Parse/Parse.css
Normal file
@@ -0,0 +1,45 @@
|
||||
.inputContainer {
|
||||
display: flex;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.inputIconContainer {
|
||||
width: 58px;
|
||||
height: 46px;
|
||||
border: 1px solid var(--inputBorderColor);
|
||||
border-right: none;
|
||||
border-radius: 4px;
|
||||
border-top-right-radius: 0;
|
||||
border-bottom-right-radius: 0;
|
||||
background-color: var(--inputIconContainerBackgroundColor);
|
||||
text-align: center;
|
||||
line-height: 46px;
|
||||
}
|
||||
|
||||
.input {
|
||||
composes: input from '~Components/Form/TextInput.css';
|
||||
|
||||
height: 46px;
|
||||
border-radius: 0;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.clearButton {
|
||||
border: 1px solid var(--inputBorderColor);
|
||||
border-left: none;
|
||||
border-top-right-radius: 4px;
|
||||
border-bottom-right-radius: 4px;
|
||||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
|
||||
.message {
|
||||
margin-top: 30px;
|
||||
text-align: center;
|
||||
font-weight: 300;
|
||||
font-size: $largeFontSize;
|
||||
}
|
||||
|
||||
.helpText {
|
||||
margin-bottom: 10px;
|
||||
font-size: 24px;
|
||||
}
|
||||
12
frontend/src/Parse/Parse.css.d.ts
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'clearButton': string;
|
||||
'helpText': string;
|
||||
'input': string;
|
||||
'inputContainer': string;
|
||||
'inputIconContainer': string;
|
||||
'message': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||
111
frontend/src/Parse/Parse.tsx
Normal file
@@ -0,0 +1,111 @@
|
||||
import React, { useCallback, useEffect, useState } from 'react';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import TextInput from 'Components/Form/TextInput';
|
||||
import Icon from 'Components/Icon';
|
||||
import Button from 'Components/Link/Button';
|
||||
import LoadingIndicator from 'Components/Loading/LoadingIndicator';
|
||||
import PageContent from 'Components/Page/PageContent';
|
||||
import PageContentBody from 'Components/Page/PageContentBody';
|
||||
import { icons } from 'Helpers/Props';
|
||||
import { clear, fetch } from 'Store/Actions/parseActions';
|
||||
import getErrorMessage from 'Utilities/Object/getErrorMessage';
|
||||
import ParseResult from './ParseResult';
|
||||
import parseStateSelector from './parseStateSelector';
|
||||
import styles from './Parse.css';
|
||||
|
||||
function Parse() {
|
||||
const { isFetching, error, item } = useSelector(parseStateSelector());
|
||||
|
||||
const [title, setTitle] = useState('');
|
||||
const dispatch = useDispatch();
|
||||
|
||||
const onInputChange = useCallback(
|
||||
({ value }: { value: string }) => {
|
||||
const trimmedValue = value.trim();
|
||||
|
||||
setTitle(value);
|
||||
|
||||
if (trimmedValue === '') {
|
||||
dispatch(clear());
|
||||
} else {
|
||||
dispatch(fetch({ title: trimmedValue }));
|
||||
}
|
||||
},
|
||||
[setTitle, dispatch]
|
||||
);
|
||||
|
||||
const onClearPress = useCallback(() => {
|
||||
setTitle('');
|
||||
dispatch(clear());
|
||||
}, [setTitle, dispatch]);
|
||||
|
||||
useEffect(
|
||||
() => {
|
||||
return () => {
|
||||
dispatch(clear());
|
||||
};
|
||||
},
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
[]
|
||||
);
|
||||
|
||||
return (
|
||||
<PageContent title="Parse">
|
||||
<PageContentBody>
|
||||
<div className={styles.inputContainer}>
|
||||
<div className={styles.inputIconContainer}>
|
||||
<Icon name={icons.PARSE} size={20} />
|
||||
</div>
|
||||
|
||||
<TextInput
|
||||
className={styles.input}
|
||||
name="title"
|
||||
value={title}
|
||||
placeholder="eg. Movie.Title.2020.720p.HDTV-RlsGroup"
|
||||
autoFocus={true}
|
||||
onChange={onInputChange}
|
||||
/>
|
||||
|
||||
<Button className={styles.clearButton} onPress={onClearPress}>
|
||||
<Icon name={icons.REMOVE} size={20} />
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
{isFetching ? <LoadingIndicator /> : null}
|
||||
|
||||
{!isFetching && !!error ? (
|
||||
<div className={styles.message}>
|
||||
<div className={styles.helpText}>
|
||||
Error parsing, please try again.
|
||||
</div>
|
||||
<div>{getErrorMessage(error)}</div>
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
{!isFetching && title && !error && !item.parsedMovieInfo ? (
|
||||
<div className={styles.message}>
|
||||
Unable to parse the provided title, please try again.
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
{!isFetching && !error && item.parsedMovieInfo ? (
|
||||
<ParseResult item={item} />
|
||||
) : null}
|
||||
|
||||
{title ? null : (
|
||||
<div className={styles.message}>
|
||||
<div className={styles.helpText}>
|
||||
Enter a release title in the input above
|
||||
</div>
|
||||
<div>
|
||||
Radarr will attempt to parse the title and show you details about
|
||||
it
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</PageContentBody>
|
||||
</PageContent>
|
||||
);
|
||||
}
|
||||
|
||||
export default Parse;
|
||||
20
frontend/src/Parse/ParseModal.tsx
Normal file
@@ -0,0 +1,20 @@
|
||||
import React from 'react';
|
||||
import Modal from 'Components/Modal/Modal';
|
||||
import ParseModalContent from './ParseModalContent';
|
||||
|
||||
interface ParseModalProps {
|
||||
isOpen: boolean;
|
||||
onModalClose: () => void;
|
||||
}
|
||||
|
||||
function ParseModal(props: ParseModalProps) {
|
||||
const { isOpen, onModalClose } = props;
|
||||
|
||||
return (
|
||||
<Modal isOpen={isOpen} onModalClose={onModalClose}>
|
||||
<ParseModalContent onModalClose={onModalClose} />
|
||||
</Modal>
|
||||
);
|
||||
}
|
||||
|
||||
export default ParseModal;
|
||||
45
frontend/src/Parse/ParseModalContent.css
Normal file
@@ -0,0 +1,45 @@
|
||||
.inputContainer {
|
||||
display: flex;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.inputIconContainer {
|
||||
width: 58px;
|
||||
height: 46px;
|
||||
border: 1px solid var(--inputBorderColor);
|
||||
border-right: none;
|
||||
border-radius: 4px;
|
||||
border-top-right-radius: 0;
|
||||
border-bottom-right-radius: 0;
|
||||
background-color: var(--inputIconContainerBackgroundColor);
|
||||
text-align: center;
|
||||
line-height: 46px;
|
||||
}
|
||||
|
||||
.input {
|
||||
composes: input from '~Components/Form/TextInput.css';
|
||||
|
||||
height: 46px;
|
||||
border-radius: 0;
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
.clearButton {
|
||||
border: 1px solid var(--inputBorderColor);
|
||||
border-left: none;
|
||||
border-top-right-radius: 4px;
|
||||
border-bottom-right-radius: 4px;
|
||||
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
|
||||
}
|
||||
|
||||
.message {
|
||||
margin-top: 30px;
|
||||
text-align: center;
|
||||
font-weight: 300;
|
||||
font-size: $largeFontSize;
|
||||
}
|
||||
|
||||
.helpText {
|
||||
margin-bottom: 10px;
|
||||
font-size: 24px;
|
||||
}
|
||||
12
frontend/src/Parse/ParseModalContent.css.d.ts
vendored
Normal file
@@ -0,0 +1,12 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'clearButton': string;
|
||||
'helpText': string;
|
||||
'input': string;
|
||||
'inputContainer': string;
|
||||
'inputIconContainer': string;
|
||||
'message': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||
125
frontend/src/Parse/ParseModalContent.tsx
Normal file
@@ -0,0 +1,125 @@
|
||||
import React, { useCallback, useEffect, useState } from 'react';
|
||||
import { useDispatch, useSelector } from 'react-redux';
|
||||
import TextInput from 'Components/Form/TextInput';
|
||||
import Icon from 'Components/Icon';
|
||||
import Button from 'Components/Link/Button';
|
||||
import LoadingIndicator from 'Components/Loading/LoadingIndicator';
|
||||
import ModalBody from 'Components/Modal/ModalBody';
|
||||
import ModalContent from 'Components/Modal/ModalContent';
|
||||
import ModalFooter from 'Components/Modal/ModalFooter';
|
||||
import ModalHeader from 'Components/Modal/ModalHeader';
|
||||
import { icons } from 'Helpers/Props';
|
||||
import { clear, fetch } from 'Store/Actions/parseActions';
|
||||
import getErrorMessage from 'Utilities/Object/getErrorMessage';
|
||||
import translate from 'Utilities/String/translate';
|
||||
import ParseResult from './ParseResult';
|
||||
import parseStateSelector from './parseStateSelector';
|
||||
import styles from './ParseModalContent.css';
|
||||
|
||||
interface ParseModalContentProps {
|
||||
onModalClose: () => void;
|
||||
}
|
||||
|
||||
function ParseModalContent(props: ParseModalContentProps) {
|
||||
const { onModalClose } = props;
|
||||
const { isFetching, error, item } = useSelector(parseStateSelector());
|
||||
|
||||
const [title, setTitle] = useState('');
|
||||
const dispatch = useDispatch();
|
||||
|
||||
const onInputChange = useCallback(
|
||||
({ value }: { value: string }) => {
|
||||
const trimmedValue = value.trim();
|
||||
|
||||
setTitle(value);
|
||||
|
||||
if (trimmedValue === '') {
|
||||
dispatch(clear());
|
||||
} else {
|
||||
dispatch(fetch({ title: trimmedValue }));
|
||||
}
|
||||
},
|
||||
[setTitle, dispatch]
|
||||
);
|
||||
|
||||
const onClearPress = useCallback(() => {
|
||||
setTitle('');
|
||||
dispatch(clear());
|
||||
}, [setTitle, dispatch]);
|
||||
|
||||
useEffect(
|
||||
() => {
|
||||
return () => {
|
||||
dispatch(clear());
|
||||
};
|
||||
},
|
||||
// eslint-disable-next-line react-hooks/exhaustive-deps
|
||||
[]
|
||||
);
|
||||
|
||||
return (
|
||||
<ModalContent onModalClose={onModalClose}>
|
||||
<ModalHeader>{translate('TestParsing')}</ModalHeader>
|
||||
|
||||
<ModalBody>
|
||||
<div className={styles.inputContainer}>
|
||||
<div className={styles.inputIconContainer}>
|
||||
<Icon name={icons.PARSE} size={20} />
|
||||
</div>
|
||||
|
||||
<TextInput
|
||||
className={styles.input}
|
||||
name="title"
|
||||
value={title}
|
||||
placeholder="eg. Movie.Title.2020.720p.HDTV-RlsGroup"
|
||||
autoFocus={true}
|
||||
onChange={onInputChange}
|
||||
/>
|
||||
|
||||
<Button className={styles.clearButton} onPress={onClearPress}>
|
||||
<Icon name={icons.REMOVE} size={20} />
|
||||
</Button>
|
||||
</div>
|
||||
|
||||
{isFetching ? <LoadingIndicator /> : null}
|
||||
|
||||
{!isFetching && !!error ? (
|
||||
<div className={styles.message}>
|
||||
<div className={styles.helpText}>
|
||||
Error parsing, please try again.
|
||||
</div>
|
||||
<div>{getErrorMessage(error)}</div>
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
{!isFetching && title && !error && !item.parsedMovieInfo ? (
|
||||
<div className={styles.message}>
|
||||
Unable to parse the provided title, please try again.
|
||||
</div>
|
||||
) : null}
|
||||
|
||||
{!isFetching && !error && item.parsedMovieInfo ? (
|
||||
<ParseResult item={item} />
|
||||
) : null}
|
||||
|
||||
{title ? null : (
|
||||
<div className={styles.message}>
|
||||
<div className={styles.helpText}>
|
||||
Enter a release title in the input above
|
||||
</div>
|
||||
<div>
|
||||
Radarr will attempt to parse the title and show you details about
|
||||
it
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
</ModalBody>
|
||||
|
||||
<ModalFooter>
|
||||
<Button onPress={onModalClose}>{translate('Close')}</Button>
|
||||
</ModalFooter>
|
||||
</ModalContent>
|
||||
);
|
||||
}
|
||||
|
||||
export default ParseModalContent;
|
||||
8
frontend/src/Parse/ParseResult.css
Normal file
@@ -0,0 +1,8 @@
|
||||
.container {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.column {
|
||||
flex: 0 0 50%;
|
||||
}
|
||||
8
frontend/src/Parse/ParseResult.css.d.ts
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
// This file is automatically generated.
|
||||
// Please do not change this file!
|
||||
interface CssExports {
|
||||
'column': string;
|
||||
'container': string;
|
||||
}
|
||||
export const cssExports: CssExports;
|
||||
export default cssExports;
|
||||