Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/renderer/components/filters/ReasonFilter.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { FC } from 'react';
import { type FC, useId } from 'react';

import { NoteIcon } from '@primer/octicons-react';
import { Text } from '@primer/react';
Expand All @@ -7,12 +7,14 @@ import { reasonFilter } from '../../utils/notifications/filters';
import { FilterSection } from './FilterSection';

export const ReasonFilter: FC = () => {
const id = useId();

return (
<FilterSection
filter={reasonFilter}
filterSetting="filterReasons"
icon={NoteIcon}
id="filter-reasons"
id={id}
title="Reason"
tooltip={<Text>Filter notifications by reason.</Text>}
/>
Expand Down
6 changes: 4 additions & 2 deletions src/renderer/components/filters/StateFilter.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { FC } from 'react';
import { type FC, useId } from 'react';

import { IssueOpenedIcon } from '@primer/octicons-react';
import { Text } from '@primer/react';
Expand All @@ -7,12 +7,14 @@ import { stateFilter } from '../../utils/notifications/filters';
import { FilterSection } from './FilterSection';

export const StateFilter: FC = () => {
const id = useId();

return (
<FilterSection
filter={stateFilter}
filterSetting="filterStates"
icon={IssueOpenedIcon}
id="filter-state"
id={id}
title="State"
tooltip={<Text>Filter notifications by state.</Text>}
/>
Expand Down
6 changes: 4 additions & 2 deletions src/renderer/components/filters/SubjectTypeFilter.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { FC } from 'react';
import { type FC, useId } from 'react';

import { BellIcon } from '@primer/octicons-react';
import { Text } from '@primer/react';
Expand All @@ -7,12 +7,14 @@ import { subjectTypeFilter } from '../../utils/notifications/filters';
import { FilterSection } from './FilterSection';

export const SubjectTypeFilter: FC = () => {
const id = useId();

return (
<FilterSection
filter={subjectTypeFilter}
filterSetting="filterSubjectTypes"
icon={BellIcon}
id="filter-subject-type"
id={id}
title="Type"
tooltip={<Text>Filter notifications by type.</Text>}
/>
Expand Down
6 changes: 4 additions & 2 deletions src/renderer/components/filters/UserTypeFilter.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import type { FC } from 'react';
import { type FC, useId } from 'react';

import {
DependabotIcon,
Expand All @@ -13,12 +13,14 @@ import { userTypeFilter } from '../../utils/notifications/filters';
import { FilterSection } from './FilterSection';

export const UserTypeFilter: FC = () => {
const id = useId();

return (
<FilterSection
filter={userTypeFilter}
filterSetting="filterUserTypes"
icon={FeedPersonIcon}
id="filter-user-types"
id={id}
layout="horizontal"
title="User Type"
tooltip={
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

12 changes: 6 additions & 6 deletions src/renderer/routes/__snapshots__/Filters.test.tsx.snap

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.