-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #389 from thepolicylab-projectportals/feat-search-bar
feat: search bar
- Loading branch information
Showing
17 changed files
with
213 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"question": "012 345 6789 ab cd efg hij klmn 24 chars/7 spaces", | ||
"title": "Open Project 4", | ||
"mainContact": "first-contact", | ||
"projectTeam": [ | ||
"first-contact", | ||
"second-contact" | ||
], | ||
"agency": "example agency", | ||
"deliverable": "example deliverable", | ||
"description": "No topics", | ||
"emailContent": "example emailContent", | ||
"endDate": "2016-12-15", | ||
"expertise": "example expertise", | ||
"fundingInfo": "example fundingInfo", | ||
"keyDates": "example keyDates", | ||
"lastModified": "2022-08-31T20:33:19.394Z", | ||
"opportunityCloses": "2022-10-28", | ||
"purpose": "example purpose", | ||
"requirement": "example requirement", | ||
"startDate": "2022-06-17", | ||
"status": "open", | ||
"statusOfData": "example statusOfData", | ||
"summary": "example summary", | ||
"topics": ["example-topic-4"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"question": "0123456789 abcdefghijklmnop 26 chars/1 space", | ||
"title": "Open Project 5", | ||
"mainContact": "first-contact", | ||
"projectTeam": [ | ||
"first-contact", | ||
"second-contact" | ||
], | ||
"agency": "example agency", | ||
"deliverable": "example deliverable", | ||
"description": "No topics", | ||
"emailContent": "example emailContent", | ||
"endDate": "2016-12-15", | ||
"expertise": "example expertise", | ||
"fundingInfo": "example fundingInfo", | ||
"keyDates": "example keyDates", | ||
"lastModified": "2022-08-31T20:33:19.394Z", | ||
"opportunityCloses": "2022-10-28", | ||
"purpose": "example purpose", | ||
"requirement": "example requirement", | ||
"startDate": "2022-06-17", | ||
"status": "open", | ||
"statusOfData": "example statusOfData", | ||
"summary": "example summary", | ||
"topics": ["example-topic", "example-topic-3"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"question": "012 3 45 67 89 ab cd efg hij klm 23 chars/9 spaces", | ||
"title": "Open Project 6", | ||
"mainContact": "first-contact", | ||
"projectTeam": [ | ||
"first-contact", | ||
"second-contact" | ||
], | ||
"agency": "example agency", | ||
"deliverable": "example deliverable", | ||
"description": "No topics", | ||
"emailContent": "example emailContent", | ||
"endDate": "2016-12-15", | ||
"expertise": "example expertise", | ||
"fundingInfo": "example fundingInfo", | ||
"keyDates": "example keyDates", | ||
"lastModified": "2022-08-31T20:33:19.394Z", | ||
"opportunityCloses": "2022-10-28", | ||
"purpose": "example purpose", | ||
"requirement": "example requirement", | ||
"startDate": "2022-06-17", | ||
"status": "open", | ||
"statusOfData": "example statusOfData", | ||
"summary": "example summary", | ||
"topics": ["ccv-settings", "example-topic-4", "example-topic-2"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"title": "Military", | ||
"lastModified": "2022-11-10T13:16:39.563Z" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"title": "Public Health", | ||
"lastModified": "2022-11-10T13:17:39.563Z" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"title": "Security", | ||
"lastModified": "2022-11-10T13:33:39.563Z" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
packages/gatsby-theme-project-portal/src/components/SearchBar.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import React, {ChangeEventHandler, Dispatch, FunctionComponent, SetStateAction} from "react" | ||
|
||
interface SearchBarProps { | ||
label: string | ||
onChange: any | ||
} | ||
|
||
export const SearchBar: FunctionComponent<SearchBarProps> = ({ | ||
label, | ||
onChange, | ||
}) => { | ||
return ( | ||
<> | ||
<label id="search-label" className="font-bold" htmlFor="filter"> | ||
{label} | ||
</label> | ||
<input | ||
className="rounded border-gray-300 hover:border-gray-400" | ||
style={{height: "62%"}} | ||
type="text" | ||
aria-label="Search" | ||
placeholder="Type to filter posts..." | ||
onChange={onChange} | ||
/> | ||
</> | ||
) | ||
} |
Oops, something went wrong.