1
0
mirror of https://github.com/Sonarr/Sonarr.git synced 2026-04-20 21:54:58 -04:00

New: Ability to change root folder when editing series

Closes #5544
This commit is contained in:
Mark McDowall
2024-11-23 20:21:24 -08:00
parent 4491df3ae7
commit 417af2b915
14 changed files with 269 additions and 8 deletions
+9 -3
View File
@@ -1,3 +1,4 @@
import classNames from 'classnames';
import React, {
KeyboardEvent,
SyntheticEvent,
@@ -29,6 +30,7 @@ interface PathInputProps {
value?: string;
placeholder?: string;
includeFiles: boolean;
hasButton?: boolean;
hasFileBrowser?: boolean;
onChange: (change: InputChanged<string>) => void;
}
@@ -96,6 +98,7 @@ export function PathInputInternal(props: PathInputInternalProps) {
value: inputValue = '',
paths,
includeFiles,
hasButton,
hasFileBrowser = true,
onChange,
onFetchPaths,
@@ -229,9 +232,12 @@ export function PathInputInternal(props: PathInputInternalProps) {
/>
{hasFileBrowser ? (
<div>
<>
<FormInputButton
className={styles.fileBrowserButton}
className={classNames(
styles.fileBrowserButton,
hasButton && styles.fileBrowserMiddleButton
)}
onPress={handleFileBrowserOpenPress}
>
<Icon name={icons.FOLDER_OPEN} />
@@ -245,7 +251,7 @@ export function PathInputInternal(props: PathInputInternalProps) {
onChange={onChange}
onModalClose={handleFileBrowserModalClose}
/>
</div>
</>
) : null}
</div>
);