diff --git a/frontend/src/Components/Page/Header/ArtistSearchInputConnector.js b/frontend/src/Components/Page/Header/ArtistSearchInputConnector.js index b7294c382..3325649f8 100644 --- a/frontend/src/Components/Page/Header/ArtistSearchInputConnector.js +++ b/frontend/src/Components/Page/Header/ArtistSearchInputConnector.js @@ -25,6 +25,7 @@ function createCleanArtistSelector() { sortName, foreignArtistId, images, + firstCharacter: artistName.charAt(0).toLowerCase(), tags: tags.reduce((acc, id) => { const matchingTag = allTags.find((tag) => tag.id === id); diff --git a/frontend/src/Components/Page/Header/ArtistSearchResult.js b/frontend/src/Components/Page/Header/ArtistSearchResult.js index 1b59e569b..7305d121b 100644 --- a/frontend/src/Components/Page/Header/ArtistSearchResult.js +++ b/frontend/src/Components/Page/Header/ArtistSearchResult.js @@ -10,6 +10,7 @@ function ArtistSearchResult(props) { match, artistName, images, + foreignArtistId, tags } = props; @@ -34,6 +35,14 @@ function ArtistSearchResult(props) { {artistName} + { + match.key === 'foreignArtistId' && foreignArtistId ? +
+ MbId: {foreignArtistId} +
: + null + } + { tag ?
@@ -54,6 +63,7 @@ function ArtistSearchResult(props) { ArtistSearchResult.propTypes = { artistName: PropTypes.string.isRequired, images: PropTypes.arrayOf(PropTypes.object).isRequired, + foreignArtistId: PropTypes.string.isRequired, tags: PropTypes.arrayOf(PropTypes.object).isRequired, match: PropTypes.object.isRequired }; diff --git a/frontend/src/Components/Page/Header/fuse.worker.js b/frontend/src/Components/Page/Header/fuse.worker.js index 3b4b13161..d90262ff6 100644 --- a/frontend/src/Components/Page/Header/fuse.worker.js +++ b/frontend/src/Components/Page/Header/fuse.worker.js @@ -9,6 +9,7 @@ const fuseOptions = { minMatchCharLength: 1, keys: [ 'artistName', + 'foreignArtistId', 'tags.label' ] };