-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
427 additions
and
127 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
39 changes: 39 additions & 0 deletions
39
src/renderer/components/settings/app/NextAiringEpisodeMainList.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
import { Box, FormControl, InputLabel, NativeSelect } from '@mui/material'; | ||
import { useAtom } from 'jotai'; | ||
import React from 'react'; | ||
import { nextAiringEpisodeAtom } from 'renderer/store'; | ||
|
||
function NextAiringEpisodeMainList() { | ||
const [nextAiringEpisode, setNextAiringEpisode] = useAtom( | ||
nextAiringEpisodeAtom, | ||
); | ||
|
||
const handleChange = (event: any) => { | ||
setNextAiringEpisode(event.target.value as string); | ||
window.electron.store.set('nextAiringEpisode', event.target.value); | ||
window.electron.ipcRenderer.sendMessage('updateMainFromSettings', [ | ||
'nextAiringEpisode', | ||
event.target.value, | ||
]); | ||
}; | ||
|
||
return ( | ||
<Box> | ||
<FormControl fullWidth> | ||
<InputLabel variant="standard"> | ||
Show next airing episode on the user's anime list | ||
</InputLabel> | ||
<NativeSelect | ||
id="defaultNextAiringEpisode" | ||
value={nextAiringEpisode} | ||
onChange={handleChange} | ||
> | ||
<option value="Show">Show</option> | ||
<option value="Hide">Hide</option> | ||
</NativeSelect> | ||
</FormControl> | ||
</Box> | ||
); | ||
} | ||
|
||
export default NextAiringEpisodeMainList; |
Oops, something went wrong.