diff --git a/packages/strapi-helper-plugin/lib/src/components/LeftMenuList/index.js b/packages/strapi-helper-plugin/lib/src/components/LeftMenuList/index.js index 8e6f51944f..ff5825c90c 100644 --- a/packages/strapi-helper-plugin/lib/src/components/LeftMenuList/index.js +++ b/packages/strapi-helper-plugin/lib/src/components/LeftMenuList/index.js @@ -1,6 +1,6 @@ import React, { isValidElement, useState } from 'react'; import PropTypes from 'prop-types'; -import { get, isEmpty, isObject } from 'lodash'; +import { get, isEmpty, isObject, toLower } from 'lodash'; import { useGlobalContext } from '../../contexts/GlobalContext'; import matchSorter from 'match-sorter'; import LeftMenuLink from '../LeftMenuLink'; @@ -54,12 +54,13 @@ function LeftMenuList({ customLink, links, title, searchable }) { return links.map(link => { return { ...link, - links: matchSorter(link.links, search, { keys: ['title'] }), + links: matchSorter(link.links, toLower(search), { + keys: [item => toLower(item.title)], + }), }; }); } - - return matchSorter(links, search, { keys: ['title'] }); + return matchSorter(links, toLower(search), { keys: [item => toLower(item.title)] }); }; const renderCompo = (link, i) => {