mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-15 09:33:52 -07:00
New: Search library by MusicBrainz ID
(cherry picked from commit 377e5f7fc7bb070a2f6e55a6bc8f2bdad733c308) Closes #3813
This commit is contained in:
parent
4ee3d581dd
commit
82cb0f1889
3 changed files with 12 additions and 0 deletions
|
@ -25,6 +25,7 @@ function createCleanArtistSelector() {
|
||||||
sortName,
|
sortName,
|
||||||
foreignArtistId,
|
foreignArtistId,
|
||||||
images,
|
images,
|
||||||
|
firstCharacter: artistName.charAt(0).toLowerCase(),
|
||||||
tags: tags.reduce((acc, id) => {
|
tags: tags.reduce((acc, id) => {
|
||||||
const matchingTag = allTags.find((tag) => tag.id === id);
|
const matchingTag = allTags.find((tag) => tag.id === id);
|
||||||
|
|
||||||
|
|
|
@ -10,6 +10,7 @@ function ArtistSearchResult(props) {
|
||||||
match,
|
match,
|
||||||
artistName,
|
artistName,
|
||||||
images,
|
images,
|
||||||
|
foreignArtistId,
|
||||||
tags
|
tags
|
||||||
} = props;
|
} = props;
|
||||||
|
|
||||||
|
@ -34,6 +35,14 @@ function ArtistSearchResult(props) {
|
||||||
{artistName}
|
{artistName}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
{
|
||||||
|
match.key === 'foreignArtistId' && foreignArtistId ?
|
||||||
|
<div className={styles.alternateTitle}>
|
||||||
|
MbId: {foreignArtistId}
|
||||||
|
</div> :
|
||||||
|
null
|
||||||
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
tag ?
|
tag ?
|
||||||
<div className={styles.tagContainer}>
|
<div className={styles.tagContainer}>
|
||||||
|
@ -54,6 +63,7 @@ function ArtistSearchResult(props) {
|
||||||
ArtistSearchResult.propTypes = {
|
ArtistSearchResult.propTypes = {
|
||||||
artistName: PropTypes.string.isRequired,
|
artistName: PropTypes.string.isRequired,
|
||||||
images: PropTypes.arrayOf(PropTypes.object).isRequired,
|
images: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||||
|
foreignArtistId: PropTypes.string.isRequired,
|
||||||
tags: PropTypes.arrayOf(PropTypes.object).isRequired,
|
tags: PropTypes.arrayOf(PropTypes.object).isRequired,
|
||||||
match: PropTypes.object.isRequired
|
match: PropTypes.object.isRequired
|
||||||
};
|
};
|
||||||
|
|
|
@ -9,6 +9,7 @@ const fuseOptions = {
|
||||||
minMatchCharLength: 1,
|
minMatchCharLength: 1,
|
||||||
keys: [
|
keys: [
|
||||||
'artistName',
|
'artistName',
|
||||||
|
'foreignArtistId',
|
||||||
'tags.label'
|
'tags.label'
|
||||||
]
|
]
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue