From d65e2a7a0081087f29a1210059d0fd26a941b678 Mon Sep 17 00:00:00 2001 From: Sofia Bilous Date: Tue, 17 Oct 2023 14:11:22 +0300 Subject: [PATCH] fix comments, delete index.js --- .../header/navbar/SearchBox.module.css | 57 ------------------- FrontEnd/src/components/SearchPage/index.js | 17 ------ .../SearchPage/search_field/SearchResults.js | 24 ++++---- .../search_field/companies/Companies.js | 8 --- 4 files changed, 11 insertions(+), 95 deletions(-) delete mode 100644 FrontEnd/src/components/SearchPage/index.js diff --git a/FrontEnd/src/components/HeaderFooter/header/navbar/SearchBox.module.css b/FrontEnd/src/components/HeaderFooter/header/navbar/SearchBox.module.css index 990641f2a..e289630f6 100644 --- a/FrontEnd/src/components/HeaderFooter/header/navbar/SearchBox.module.css +++ b/FrontEnd/src/components/HeaderFooter/header/navbar/SearchBox.module.css @@ -1,60 +1,3 @@ -/* .header-search-box { - display: flex; - align-items: center; - flex-shrink: 0; - width: 264px; - - border-radius: 2px; - border: 1px solid #D9D9D9; - background: #FFF; -} - -.header-search-form { - display: flex; - padding: 4px 12px; - align-items: flex-start; - gap: 10px; - flex: 1 0 0; -} - -.header-search-form__input { - display: flex; - padding: 1px 0px; - align-items: flex-start; - gap: 10px; - flex: 1 0 0; - border: none; -} - -.header-search-form__addon { - display: flex; - padding: 9px; - width: 14px; - height: 14px; - justify-content: center; - align-items: center; - gap: 8px; - align-self: stretch; - border-left: 1px solid #D9D9D9;; -} - -.header-search-form__input::placeholder { - color: rgba(0, 0, 0, 0.25); - font-feature-settings: 'calt' off; - - font-family: Inter; - font-size: 14px; - font-style: normal; - font-weight: 400; - line-height: 20px; - letter-spacing: -0.14px; -} - -textarea:focus, .header-search-form__input:focus{ - border: none; - outline: none; -} */ - .header-search-box { display: flex; align-items: center; diff --git a/FrontEnd/src/components/SearchPage/index.js b/FrontEnd/src/components/SearchPage/index.js deleted file mode 100644 index d563c0fb1..000000000 --- a/FrontEnd/src/components/SearchPage/index.js +++ /dev/null @@ -1,17 +0,0 @@ -import React from 'react'; -import ReactDOM from 'react-dom/client'; -import './index.css'; -import App from './App'; -import reportWebVitals from './reportWebVitals'; - -const root = ReactDOM.createRoot(document.getElementById('root')); -root.render( - - - -); - -// If you want to start measuring performance in your app, pass a function -// to log results (for example: reportWebVitals(console.log)) -// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals -reportWebVitals(); diff --git a/FrontEnd/src/components/SearchPage/search_field/SearchResults.js b/FrontEnd/src/components/SearchPage/search_field/SearchResults.js index 8dc01cbaa..3623fd432 100644 --- a/FrontEnd/src/components/SearchPage/search_field/SearchResults.js +++ b/FrontEnd/src/components/SearchPage/search_field/SearchResults.js @@ -11,20 +11,18 @@ const SearchResults = ({ results, displayedResults, isAuthorized }) => { return (
{!error && ( - <> -
-
- {displayedResults.map((result, resultIndex) => ( -
- -
- ))} -
+
+
+ {displayedResults.map((result, resultIndex) => ( +
+ +
+ ))}
- +
)}
); diff --git a/FrontEnd/src/components/SearchPage/search_field/companies/Companies.js b/FrontEnd/src/components/SearchPage/search_field/companies/Companies.js index b2a20acbf..0ec3448c8 100644 --- a/FrontEnd/src/components/SearchPage/search_field/companies/Companies.js +++ b/FrontEnd/src/components/SearchPage/search_field/companies/Companies.js @@ -7,16 +7,8 @@ const MainCompanies = ({ companyData, isAuthorized }) => { const currentDate = new Date(); const currentYear = currentDate.getFullYear(); - // those variables we would use for axios to get data from beckend - // get saved list code here const usersSavedList = []; - // add company to saved list code here - // const addToSavedList = (profile_id) => {}; - - // del company from saved list code here - // const delFromSavedList = (profile_id) => {}; - return (