1
0
mirror of https://github.com/Radarr/Radarr.git synced 2026-04-19 21:46:50 -04:00

Fixed: Free space and missing for selected root folder value

This commit is contained in:
Bogdan
2025-04-15 19:46:59 +03:00
parent c52f9c5ec4
commit cfd25e974f
5 changed files with 82 additions and 82 deletions
@@ -8,27 +8,23 @@ import styles from './RootFolderSelectInputSelectedValue.css';
interface RootFolderSelectInputSelectedValueProps {
selectedValue: string;
values: RootFolderSelectInputValue[];
freeSpace?: number;
movieFolder?: string;
isWindows?: boolean;
includeFreeSpace?: boolean;
}
function RootFolderSelectInputSelectedValue(
props: RootFolderSelectInputSelectedValueProps
) {
const {
selectedValue,
values,
freeSpace,
movieFolder,
includeFreeSpace = true,
isWindows,
...otherProps
} = props;
function RootFolderSelectInputSelectedValue({
selectedValue,
values,
movieFolder,
includeFreeSpace = true,
isWindows,
...otherProps
}: RootFolderSelectInputSelectedValueProps) {
const slashCharacter = isWindows ? '\\' : '/';
const value = values.find((v) => v.key === selectedValue)?.value;
const { value, freeSpace, isMissing } = values.find(
(v) => v.key === selectedValue
) as RootFolderSelectInputValue;
return (
<EnhancedSelectInputSelectedValue
@@ -53,6 +49,10 @@ function RootFolderSelectInputSelectedValue(
})}
</div>
) : null}
{isMissing ? (
<div className={styles.isMissing}>{translate('Missing')}</div>
) : null}
</EnhancedSelectInputSelectedValue>
);
}