mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-04-24 22:07:32 -04:00
Fixed: Add redirect to legend
This commit is contained in:
parent
c836b3c43c
commit
be61fb40fd
3 changed files with 26 additions and 35 deletions
|
@ -18,31 +18,25 @@
|
|||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.queue {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $queueColor;
|
||||
}
|
||||
|
||||
.continuing {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $primaryColor;
|
||||
}
|
||||
|
||||
.availNotMonitored {
|
||||
.disabled {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $darkGray;
|
||||
}
|
||||
|
||||
.ended {
|
||||
.enabled {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $successColor;
|
||||
}
|
||||
|
||||
.missingMonitored {
|
||||
.redirected {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $infoColor;
|
||||
}
|
||||
|
||||
.error {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $dangerColor;
|
||||
|
@ -52,16 +46,6 @@
|
|||
}
|
||||
}
|
||||
|
||||
.missingUnmonitored {
|
||||
composes: legendItemColor;
|
||||
|
||||
background-color: $warningColor;
|
||||
|
||||
&:global(.colorImpaired) {
|
||||
background: repeating-linear-gradient(45deg, $warningColor, $warningColor 5px, color($warningColor tint(15%)) 5px, color($warningColor tint(15%)) 10px);
|
||||
}
|
||||
}
|
||||
|
||||
.statistics {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
|
|
|
@ -10,15 +10,15 @@ class IndexerIndexFooter extends PureComponent {
|
|||
|
||||
render() {
|
||||
const {
|
||||
movies,
|
||||
indexers,
|
||||
colorImpairedMode
|
||||
} = this.props;
|
||||
|
||||
const count = movies.length;
|
||||
const count = indexers.length;
|
||||
let enabled = 0;
|
||||
let torrent = 0;
|
||||
|
||||
movies.forEach((s) => {
|
||||
indexers.forEach((s) => {
|
||||
|
||||
if (s.enable) {
|
||||
enabled += 1;
|
||||
|
@ -33,14 +33,21 @@ class IndexerIndexFooter extends PureComponent {
|
|||
<div className={styles.footer}>
|
||||
<div>
|
||||
<div className={styles.legendItem}>
|
||||
<div className={styles.ended} />
|
||||
<div className={styles.enabled} />
|
||||
<div>
|
||||
Enabled
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.legendItem}>
|
||||
<div className={styles.availNotMonitored} />
|
||||
<div className={styles.redirected} />
|
||||
<div>
|
||||
Enabled, Redirected
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.legendItem}>
|
||||
<div className={styles.disabled} />
|
||||
<div>
|
||||
Disabled
|
||||
</div>
|
||||
|
@ -48,7 +55,7 @@ class IndexerIndexFooter extends PureComponent {
|
|||
|
||||
<div className={styles.legendItem}>
|
||||
<div className={classNames(
|
||||
styles.missingMonitored,
|
||||
styles.error,
|
||||
colorImpairedMode && 'colorImpaired'
|
||||
)}
|
||||
/>
|
||||
|
@ -89,7 +96,7 @@ class IndexerIndexFooter extends PureComponent {
|
|||
}
|
||||
|
||||
IndexerIndexFooter.propTypes = {
|
||||
movies: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||
indexers: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||
colorImpairedMode: PropTypes.bool.isRequired
|
||||
};
|
||||
|
||||
|
|
|
@ -29,7 +29,7 @@ function createUnoptimizedSelector() {
|
|||
function createMoviesSelector() {
|
||||
return createDeepEqualSelector(
|
||||
createUnoptimizedSelector(),
|
||||
(movies) => movies
|
||||
(indexers) => indexers
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -37,9 +37,9 @@ function createMapStateToProps() {
|
|||
return createSelector(
|
||||
createMoviesSelector(),
|
||||
createUISettingsSelector(),
|
||||
(movies, uiSettings) => {
|
||||
(indexers, uiSettings) => {
|
||||
return {
|
||||
movies,
|
||||
indexers,
|
||||
colorImpairedMode: uiSettings.enableColorImpairedMode
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue