migrate ReaderNavbar to Mui 5 (#84)

* migrate ReaderNavbar to Mui 5

* cleanup, show loading text when loading.
This commit is contained in:
Aria Moradi
2021-12-01 03:03:52 +03:30
committed by GitHub
parent a3fe748c90
commit c214406546
2 changed files with 121 additions and 141 deletions

View File

@@ -58,7 +58,12 @@ const getReaderComponent = (readerType: ReaderType) => {
};
const range = (n:number) => Array.from({ length: n }, (value, key) => key);
const initialChapter = () => ({ pageCount: -1, index: -1, chapterCount: 0 });
const initialChapter = () => ({
pageCount: -1,
index: -1,
chapterCount: 0,
name: 'Loading...',
});
export default function Reader() {
const [settings, setSettings] = useLocalStorage<IReaderSettings>('readerSettings', defaultReaderSettings);