Skip to content

Commit 9c25904

Browse files
committed
Merge branch 'main' into refactor/primer-design-system
Signed-off-by: Adam Setch <[email protected]>
1 parent ba4d064 commit 9c25904

File tree

2 files changed

+46
-47
lines changed

2 files changed

+46
-47
lines changed

src/renderer/routes/Filters.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@ export const FiltersRoute: FC = () => {
3939
<Header fetchOnBack={true} icon={FilterIcon}>
4040
Filters
4141
</Header>
42+
4243
<div className="flex-grow overflow-x-auto px-8">
4344
<fieldset className="mb-3">
4445
<Legend icon={FeedPersonIcon}>Users</Legend>

src/renderer/routes/Settings.tsx

Lines changed: 45 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -21,55 +21,53 @@ export const SettingsRoute: FC = () => {
2121
}, [resetSettings]);
2222

2323
return (
24-
<>
25-
<div className="flex h-screen flex-col" data-testid="settings">
26-
<Header fetchOnBack icon={GearIcon}>
27-
Settings
28-
</Header>
24+
<div className="flex h-screen flex-col" data-testid="settings">
25+
<Header fetchOnBack icon={GearIcon}>
26+
Settings
27+
</Header>
2928

30-
<div className="overflow-x-auto px-8 pb-4">
31-
<Stack direction="vertical" gap="spacious">
32-
<AppearanceSettings />
33-
<NotificationSettings />
34-
<SystemSettings />
35-
</Stack>
36-
<Stack align="center">
37-
<Button
38-
variant="danger"
39-
onClick={() => setIsOpen(!isOpen)}
40-
data-testid="settings-reset"
41-
sx={{ width: '200px' }} // Set the width of the button
29+
<div className="overflow-x-auto px-8 pb-4">
30+
<Stack direction="vertical" gap="spacious">
31+
<AppearanceSettings />
32+
<NotificationSettings />
33+
<SystemSettings />
34+
</Stack>
35+
<Stack align="center">
36+
<Button
37+
variant="danger"
38+
onClick={() => setIsOpen(!isOpen)}
39+
data-testid="settings-reset"
40+
sx={{ width: '200px' }} // Set the width of the button
41+
>
42+
Reset Settings
43+
</Button>
44+
{isOpen && (
45+
<Dialog
46+
title="Reset Settings"
47+
width="large"
48+
onClose={onDialogClose}
49+
footerButtons={[
50+
{
51+
buttonType: 'default',
52+
content: 'Cancel',
53+
onClick: onDialogClose,
54+
},
55+
{
56+
buttonType: 'danger',
57+
content: 'Reset',
58+
onClick: onDialogProceed,
59+
},
60+
]}
61+
data-testid="reset-dialog"
4262
>
43-
Reset Settings
44-
</Button>
45-
{isOpen && (
46-
<Dialog
47-
title="Reset Settings"
48-
width="large"
49-
onClose={onDialogClose}
50-
footerButtons={[
51-
{
52-
buttonType: 'default',
53-
content: 'Cancel',
54-
onClick: onDialogClose,
55-
},
56-
{
57-
buttonType: 'danger',
58-
content: 'Reset',
59-
onClick: onDialogProceed,
60-
},
61-
]}
62-
data-testid="reset-dialog"
63-
>
64-
Please confirm that you want to reset all settings to the{' '}
65-
<strong>Gitify defaults</strong>
66-
</Dialog>
67-
)}
68-
</Stack>
69-
</div>
70-
71-
<SettingsFooter />
63+
Please confirm that you want to reset all settings to the{' '}
64+
<strong>Gitify defaults</strong>
65+
</Dialog>
66+
)}
67+
</Stack>
7268
</div>
73-
</>
69+
70+
<SettingsFooter />
71+
</div>
7472
);
7573
};

0 commit comments

Comments
 (0)