Skip to content
This repository has been archived by the owner on Jun 2, 2022. It is now read-only.

Commit

Permalink
Change attribute className to classes
Browse files Browse the repository at this point in the history
Co-authored-by: Fanny Chien <fannychienn@gmail.com>
  • Loading branch information
Heitor Carvalho and hellofanny committed Feb 2, 2022
1 parent 6923a1f commit 9f6df2d
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/components/search/Sort/Sort.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ function Sort() {

return (
<Select
className="sort / title-small"
classes="sort / title-small"
labelText="Sort by"
options={OptionsMap}
onChange={(e) => setSort(keys[e.target.selectedIndex])}
Expand Down
8 changes: 6 additions & 2 deletions src/components/ui/Select/Select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ type SelectOptions = {
}

interface UISelectProps extends SelectProps {
/*
* Defines the CSS class string that will be forwarded to the wrapping div "className" prop.
*/
classes?: string
/*
* Defines the options available in the select. The SelectOptions object
* keys are the property names, while the values correspond to the text that
Expand All @@ -29,11 +33,11 @@ export default function Select({
labelText,
value,
'aria-label': ariaLabel,
className,
classes,
testId,
}: UISelectProps) {
return (
<div data-select className={className}>
<div data-select className={classes}>
{labelText && <label htmlFor="ui-select">{labelText}</label>}
<UISelect
data-testid={testId}
Expand Down

0 comments on commit 9f6df2d

Please sign in to comment.