diff --git a/frontend/app/common/fetcher.test.ts b/frontend/app/common/fetcher.test.ts index ef7626bc..3035837e 100644 --- a/frontend/app/common/fetcher.test.ts +++ b/frontend/app/common/fetcher.test.ts @@ -108,14 +108,11 @@ describe('fetcher', () => { // Check if `activeJwtToken` saved and clean mockFetch({ headers, status: 401 }); - await apiFetcher - .get(apiUri) - .then(() => { + await expect( + apiFetcher.get(apiUri).then(() => { throw Error('apiFether shoud throw error on 401 responce'); }) - .catch((e) => { - expect(e.message).toBe('Not authorized.'); - }); + ).rejects.toEqual(new Error('Not authorized.')); expect(window.fetch).toHaveBeenCalledWith(apiUrl, { method: 'get', diff --git a/frontend/app/components/auth-panel/auth-panel.tsx b/frontend/app/components/auth-panel/auth-panel.tsx index 50004549..3970ec13 100644 --- a/frontend/app/components/auth-panel/auth-panel.tsx +++ b/frontend/app/components/auth-panel/auth-panel.tsx @@ -197,7 +197,7 @@ export class AuthPanel extends Component { onBlur={this.onSortBlur} > {sortArray.map((sort) => ( - ))} diff --git a/frontend/app/components/auth/components/oauth.tsx b/frontend/app/components/auth/components/oauth.tsx index 6752ae9f..7b46a02a 100644 --- a/frontend/app/components/auth/components/oauth.tsx +++ b/frontend/app/components/auth/components/oauth.tsx @@ -45,7 +45,7 @@ export default function OAuthProviders({ providers }: Props) { const { name, icon } = getProviderData(p, theme); return ( -
  • +
  • = ({ u theme={theme} > {items.map(([href, label]) => ( - + {label} diff --git a/frontend/app/components/comment-form/text-expander.tsx b/frontend/app/components/comment-form/text-expander.tsx index b11a683b..bd59b138 100644 --- a/frontend/app/components/comment-form/text-expander.tsx +++ b/frontend/app/components/comment-form/text-expander.tsx @@ -19,18 +19,17 @@ function SuggestionList({ items, theme }: { items: Array; theme: Theme }) return (
      - {items.map(({ key, emoji }: Emoji) => { - return ( -
    • - {emoji} {key} -
    • - ); - })} + {items.map(({ key, emoji }: Emoji) => ( + // eslint-disable-next-line jsx-a11y/role-has-required-aria-props +
    • + {emoji} {key} +
    • + ))}
    ); } diff --git a/frontend/app/components/comment/comment.tsx b/frontend/app/components/comment/comment.tsx index 8b303d39..106a6a06 100644 --- a/frontend/app/components/comment/comment.tsx +++ b/frontend/app/components/comment/comment.tsx @@ -507,7 +507,9 @@ class Comment extends Component { {blockingDurations.map((block) => ( - + ))} @@ -791,6 +793,7 @@ class Comment extends Component { (editable || isEditing) && props.view === 'main' && [ , !isAdmin && (