Skip to content

Commit 5fccc63

Browse files
fix: change to keydown and change type to search (#1714)
* change type and move to keypress * add fix test * fix prettier
1 parent d78a0f3 commit 5fccc63

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

src/components/SocialMediaList/SocialMediaList.container.test.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ describe('Social Media List Container', () => {
1717
nonce: 123,
1818
id: 'sample-id-user',
1919
instanceURL: 'https://api.testnet.myriad.com',
20+
username: 'jest',
21+
loginType: '',
2022
},
2123
};
2224
(useSession as jest.Mock).mockReturnValue([mockSession, false]);

src/components/atoms/Search/SearchBox.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,13 @@ const SearchBox: React.FC<SearchBoxProps> = ({
6868
<SearchIcon />
6969
</IconButton>
7070
<InputBase
71-
onKeyUp={submitSearch}
71+
onKeyDown={submitSearch}
7272
className={classes.input}
7373
value={input}
7474
onChange={handleChange}
7575
placeholder={textPlaceholder}
7676
inputProps={{'aria-label': ariaLabel}}
77+
type="search"
7778
{...props}
7879
/>
7980
</Grid>

0 commit comments

Comments
 (0)