From f48dfa33b6ceebbba02fee52cbff6f2c2dd5bb33 Mon Sep 17 00:00:00 2001 From: srinjoy933 Date: Fri, 28 Feb 2025 17:12:11 +0530 Subject: [PATCH 1/4] Contribute element container exceeds screen width on mobile #919 --- frontend/index.html | 91 ++++++++++++++++++++++--- frontend/src/components/MultiSearch.tsx | 6 +- 2 files changed, 84 insertions(+), 13 deletions(-) diff --git a/frontend/index.html b/frontend/index.html index aa57f7f10..05e9adc34 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -1,13 +1,86 @@ - + - - - - + + + + OWASP Nest - - -
+ + + +
+
+

Welcome to OWASP Nest

+
+

Projects

+

Explore various security projects.

+
+
+

Contribute

+

Join and contribute to the community.

+
+
+
- + diff --git a/frontend/src/components/MultiSearch.tsx b/frontend/src/components/MultiSearch.tsx index 90aab9825..0f34a3f12 100644 --- a/frontend/src/components/MultiSearch.tsx +++ b/frontend/src/components/MultiSearch.tsx @@ -88,16 +88,14 @@ const MultiSearchBar: React.FC = ({ if (event.key === 'Escape') { setShowSuggestions(false) } else if (event.key === 'Enter' && highlightedIndex !== null) { - const { index, subIndex } = highlightedIndex - const suggestion = suggestions[index].hits[subIndex] + const { index, subIndex } = highlighted const suggestion = suggestions[index].hits[subIndex] handleSuggestionClick(suggestion, suggestions[index].indexName) } else if (event.key === 'ArrowDown') { event.preventDefault() if (highlightedIndex === null) { setHighlightedIndex({ index: 0, subIndex: 0 }) } else { - const { index, subIndex } = highlightedIndex - if (subIndex < suggestions[index].hits.length - 1) { + const { index, subIndex } = highlighted if (subIndex < suggestions[index].hits.length - 1) { setHighlightedIndex({ index, subIndex: subIndex + 1 }) } else if (index < suggestions.length - 1) { setHighlightedIndex({ index: index + 1, subIndex: 0 }) From 11259fc38703e0f3f76e7eafb51441b831547db2 Mon Sep 17 00:00:00 2001 From: srinjoy933 Date: Sat, 1 Mar 2025 02:01:15 +0530 Subject: [PATCH 2/4] updated changes for the issue#919 --- frontend/index.html | 29 +++++++++++------------------ 1 file changed, 11 insertions(+), 18 deletions(-) diff --git a/frontend/index.html b/frontend/index.html index 05e9adc34..9ec5ccb37 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -6,7 +6,6 @@ OWASP Nest