Skip to content

Commit

Permalink
ui: add sort dropdown default value
Browse files Browse the repository at this point in the history
  • Loading branch information
karolina-siemieniuk-morawska authored and drjova committed Dec 13, 2023
1 parent 982ea9c commit ebd4555
Showing 1 changed file with 13 additions and 10 deletions.
23 changes: 13 additions & 10 deletions ui/src/components/search/SearchResults.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,16 +49,19 @@ const SearchResults: React.FC<SearchResultsProps> = ({
<SearchPagination count={count} params={params} />
<div className="sort flex items-center">
{count > 0 && (
<Select
options={sortOptions}
placeholder="Sort by"
className="sort-dropdown"
onChange={sortResults}
>
<div>
Sort by <DownOutlined />
</div>
</Select>
<div>
Sort by
<Select
options={sortOptions}
className="sort-dropdown ml-3"
onChange={sortResults}
defaultValue="_updated_at"
>
<div>
<DownOutlined />
</div>
</Select>
</div>
)}
</div>
</div>
Expand Down

0 comments on commit ebd4555

Please sign in to comment.