From 2cfa6a20a0031e2d1d317fe80f27a0a8a5d0d20c Mon Sep 17 00:00:00 2001 From: CodeVoyager Date: Thu, 15 Dec 2022 14:50:22 +0100 Subject: [PATCH 1/6] chore: supported node version update --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 9a72fee1..64cce53b 100644 --- a/package.json +++ b/package.json @@ -80,7 +80,7 @@ } ], "engines": { - "node": ">=14.19.3 <=17.x.x", + "node": ">=14.19.3 <=18.x.x", "npm": ">=7.x.x" }, "nodemonConfig": { From 748c176ff6c3050b513d33a5a97bb81761319417 Mon Sep 17 00:00:00 2001 From: Mateusz Ziarko Date: Fri, 16 Dec 2022 09:13:59 +0100 Subject: [PATCH 2/6] Merge pull request #293 from VirtusLab-Open-Source/chore/supported-node-version chore: supported node version update From 03b359f8df364eaf76116ed4594ccdd5d89cceb0 Mon Sep 17 00:00:00 2001 From: Mateusz Ziarko Date: Fri, 16 Dec 2022 09:11:38 +0100 Subject: [PATCH 3/6] [CU-862hxegk3] Search should be case insensitive --- admin/src/pages/View/index.js | 2 +- package.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/admin/src/pages/View/index.js b/admin/src/pages/View/index.js index 169548b8..0c134bfd 100644 --- a/admin/src/pages/View/index.js +++ b/admin/src/pages/View/index.js @@ -149,7 +149,7 @@ const View = () => { else return [...subItems, ...acc]; }, []); - const filteredList = !isSearchEmpty ? filteredListFactory(changedActiveNavigation.items, (item) => item?.title.includes(searchValue)) : []; + const filteredList = !isSearchEmpty ? filteredListFactory(changedActiveNavigation.items, (item) => (item?.title || '').toLowerCase().includes(searchValue.toLowerCase())) : []; const changeCollapseItemDeep = (item, isCollapsed) => { if (item.collapsed !== isCollapsed) { diff --git a/package.json b/package.json index 64cce53b..fed7eea5 100644 --- a/package.json +++ b/package.json @@ -23,7 +23,7 @@ }, "dependencies": { "@sindresorhus/slugify": "1.1.0", - "@strapi/utils": "^4.3.8", + "@strapi/utils": "^4.5.4", "lodash": "^4.17.11", "pluralize": "^8.0.0", "react": "^16.9.0", @@ -80,7 +80,7 @@ } ], "engines": { - "node": ">=14.19.3 <=18.x.x", + "node": ">=14.19.1 <=18.x.x", "npm": ">=7.x.x" }, "nodemonConfig": { From e65f24777b3f2f5ef77b3d39a597e1b3cb758886 Mon Sep 17 00:00:00 2001 From: Mateusz Ziarko Date: Fri, 23 Dec 2022 09:07:33 +0100 Subject: [PATCH 4/6] Update admin/src/pages/View/index.js Co-authored-by: Tomasz Puch --- admin/src/pages/View/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/admin/src/pages/View/index.js b/admin/src/pages/View/index.js index 0c134bfd..4ce32399 100644 --- a/admin/src/pages/View/index.js +++ b/admin/src/pages/View/index.js @@ -149,7 +149,7 @@ const View = () => { else return [...subItems, ...acc]; }, []); - const filteredList = !isSearchEmpty ? filteredListFactory(changedActiveNavigation.items, (item) => (item?.title || '').toLowerCase().includes(searchValue.toLowerCase())) : []; + const filteredList = !isSearchEmpty ? filteredListFactory(changedActiveNavigation.items, (item) => (item?.title || '').toLowerCase().includes(normalisedSearchValue)) : []; const changeCollapseItemDeep = (item, isCollapsed) => { if (item.collapsed !== isCollapsed) { From c0b755ace9227f3e9cf58aba133a60700c1b12f7 Mon Sep 17 00:00:00 2001 From: Mateusz Ziarko Date: Fri, 23 Dec 2022 09:11:52 +0100 Subject: [PATCH 5/6] refactor: reworks from comments --- admin/src/pages/View/index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/admin/src/pages/View/index.js b/admin/src/pages/View/index.js index 4ce32399..21a4b917 100644 --- a/admin/src/pages/View/index.js +++ b/admin/src/pages/View/index.js @@ -83,6 +83,7 @@ const View = () => { const [searchValue, setSearchValue] = useState(''); const [structureChanged, setStructureChanged] = useState(false); const isSearchEmpty = isEmpty(searchValue); + const normalisedSearchValue = (searchValue || '').toLowerCase(); const structureHasErrors = !validateNavigationStructure((changedActiveNavigation || {}).items); From 13ca49cd4fd6f04d22a033f493d971721f57510a Mon Sep 17 00:00:00 2001 From: Mateusz Ziarko Date: Fri, 23 Dec 2022 09:15:13 +0100 Subject: [PATCH 6/6] Merge pull request #294 from VirtusLab-Open-Source/feat/issue-276-case-insensitive-search [CU-862hxegk3] Case insensitive search