diff --git a/ui/v2.5/src/components/Performers/PerformerSelect.tsx b/ui/v2.5/src/components/Performers/PerformerSelect.tsx index de1cf6771a9..d37b8fe375a 100644 --- a/ui/v2.5/src/components/Performers/PerformerSelect.tsx +++ b/ui/v2.5/src/components/Performers/PerformerSelect.tsx @@ -122,7 +122,14 @@ export const PerformerSelect: React.FC< thisOptionProps = { ...optionProps, - children: object.name, + children: ( + <> + {object.name} + {object.disambiguation && ( + {` (${object.disambiguation})`} + )} + + ), }; return ; diff --git a/ui/v2.5/src/components/Tagger/scenes/PerformerResult.tsx b/ui/v2.5/src/components/Tagger/scenes/PerformerResult.tsx index 6afbc442730..9d58f1f6ff2 100755 --- a/ui/v2.5/src/components/Tagger/scenes/PerformerResult.tsx +++ b/ui/v2.5/src/components/Tagger/scenes/PerformerResult.tsx @@ -11,6 +11,41 @@ import { Performer, PerformerSelect, } from "src/components/Performers/PerformerSelect"; +import { getStashboxBase } from "src/utils/stashbox"; + +interface IPerformerName { + performer: GQL.ScrapedPerformer | Performer; + className?: string; + baseURL: string | undefined; + id: string | undefined | null; +} + +const PerformerName: React.FC = ({ + performer, + className, + baseURL, + id, +}) => { + const name = + baseURL && id ? ( + + {performer.name} + + ) : ( + performer.name + ); + + return ( + + {name} + {performer.disambiguation && ( + + {` (${performer.disambiguation})`} + + )} + + ); +}; interface IPerformerResultProps { performer: GQL.ScrapedPerformer; @@ -44,6 +79,11 @@ const PerformerResult: React.FC = ({ const [selectedPerformer, setSelectedPerformer] = useState(); + const stashboxPerformerPrefix = endpoint + ? `${getStashboxBase(endpoint)}performers/` + : undefined; + const performerURLPrefix = "/performers/"; + function selectPerformer(selected: Performer | undefined) { setSelectedPerformer(selected); setSelectedID(selected?.id); @@ -77,7 +117,12 @@ const PerformerResult: React.FC = ({
: - {performer.name} +
= ({ : - {matchedPerformer.name} +
@@ -119,7 +169,12 @@ const PerformerResult: React.FC = ({
: - {performer.name} +