2021-03-26 00:47:02 +01:00
|
|
|
/*
|
|
|
|
* Copyright (C) Contributors to the Suwayomi project
|
|
|
|
*
|
|
|
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
2021-01-26 21:02:12 +01:00
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
|
|
|
|
2020-12-24 16:50:50 +01:00
|
|
|
interface IExtension {
|
|
|
|
name: string
|
2021-03-28 22:05:21 +02:00
|
|
|
pkgName: string
|
2020-12-24 16:50:50 +01:00
|
|
|
versionName: string
|
2021-03-28 22:05:21 +02:00
|
|
|
versionCode: number
|
|
|
|
lang: string
|
|
|
|
isNsfw: boolean
|
2020-12-25 00:38:08 +01:00
|
|
|
apkName: string
|
2021-03-28 22:05:21 +02:00
|
|
|
iconUrl: string
|
2021-03-29 00:17:51 +02:00
|
|
|
installed: boolean
|
2021-03-28 22:05:21 +02:00
|
|
|
hasUpdate: boolean
|
2021-03-29 00:17:51 +02:00
|
|
|
obsolete: boolean
|
2020-12-24 16:50:50 +01:00
|
|
|
}
|
2020-12-25 04:06:34 +01:00
|
|
|
|
|
|
|
interface ISource {
|
2020-12-25 19:44:54 +01:00
|
|
|
id: string
|
2020-12-25 04:06:34 +01:00
|
|
|
name: string
|
|
|
|
lang: string
|
|
|
|
iconUrl: string
|
|
|
|
supportsLatest: boolean
|
2020-12-25 19:44:54 +01:00
|
|
|
history: any
|
2020-12-25 04:06:34 +01:00
|
|
|
}
|
2020-12-25 17:42:22 +01:00
|
|
|
|
2021-03-17 16:47:03 +01:00
|
|
|
interface IMangaCard {
|
|
|
|
id: number
|
|
|
|
title: string
|
|
|
|
thumbnailUrl: string
|
|
|
|
}
|
|
|
|
|
2020-12-25 17:42:22 +01:00
|
|
|
interface IManga {
|
2021-01-19 17:50:28 +01:00
|
|
|
id: number
|
2021-03-17 16:47:03 +01:00
|
|
|
sourceId: string
|
|
|
|
|
|
|
|
url: string
|
2020-12-25 19:44:54 +01:00
|
|
|
title: string
|
|
|
|
thumbnailUrl: string
|
2021-03-17 16:47:03 +01:00
|
|
|
|
|
|
|
artist: string
|
|
|
|
author: string
|
|
|
|
description: string
|
|
|
|
genre: string
|
|
|
|
status: string
|
|
|
|
|
|
|
|
inLibrary: boolean
|
|
|
|
source: ISource
|
2021-05-15 11:13:26 +02:00
|
|
|
|
|
|
|
freshData: boolean
|
2020-12-25 17:42:22 +01:00
|
|
|
}
|
2021-01-19 18:32:57 +01:00
|
|
|
|
|
|
|
interface IChapter {
|
|
|
|
url: string
|
|
|
|
name: string
|
2021-05-11 16:15:53 +02:00
|
|
|
uploadDate: number
|
|
|
|
chapterNumber: number
|
2021-01-19 18:32:57 +01:00
|
|
|
scanlator: String
|
2021-01-19 21:34:12 +01:00
|
|
|
mangaId: number
|
2021-05-11 16:15:53 +02:00
|
|
|
read: boolean
|
|
|
|
bookmarked: boolean
|
|
|
|
lastPageRead: number
|
2021-05-14 15:01:07 +02:00
|
|
|
index: number
|
2021-03-23 00:20:55 +01:00
|
|
|
chapterCount: number
|
2021-02-04 01:12:30 +01:00
|
|
|
pageCount: number
|
2021-01-19 18:32:57 +01:00
|
|
|
}
|
2021-02-19 22:53:52 +01:00
|
|
|
|
2021-05-27 14:43:22 +02:00
|
|
|
interface IEpisode {
|
|
|
|
url: string
|
|
|
|
name: string
|
|
|
|
uploadDate: number
|
|
|
|
episodeNumber: number
|
|
|
|
scanlator: String
|
|
|
|
animeId: number
|
|
|
|
read: boolean
|
|
|
|
bookmarked: boolean
|
|
|
|
lastPageRead: number
|
|
|
|
index: number
|
|
|
|
episodeCount: number
|
2021-05-27 16:07:45 +02:00
|
|
|
linkUrl: string
|
2021-05-27 14:43:22 +02:00
|
|
|
}
|
|
|
|
|
2021-03-23 00:20:55 +01:00
|
|
|
interface IPartialChpter {
|
|
|
|
pageCount: number
|
2021-05-14 15:01:07 +02:00
|
|
|
index: number
|
2021-03-23 00:20:55 +01:00
|
|
|
chapterCount: number
|
|
|
|
}
|
|
|
|
|
2021-05-27 16:07:45 +02:00
|
|
|
interface IPartialEpisode {
|
|
|
|
linkUrl: string
|
|
|
|
index: number
|
|
|
|
episodeCount: number
|
|
|
|
}
|
|
|
|
|
2021-02-19 22:53:52 +01:00
|
|
|
interface ICategory {
|
|
|
|
id: number
|
|
|
|
order: number
|
|
|
|
name: String
|
2021-05-23 12:58:46 +02:00
|
|
|
default: boolean
|
2021-02-19 22:53:52 +01:00
|
|
|
}
|
2021-03-18 19:16:24 +01:00
|
|
|
|
|
|
|
interface INavbarOverride {
|
|
|
|
status: boolean
|
|
|
|
value: any
|
2021-03-29 00:17:51 +02:00
|
|
|
}
|
2021-05-15 14:48:57 +02:00
|
|
|
|
2021-05-15 20:52:37 +02:00
|
|
|
type ReaderType =
|
|
|
|
'ContinuesVertical'|
|
|
|
|
'Webtoon' |
|
|
|
|
'SingleVertical' |
|
|
|
|
'SingleRTL' |
|
|
|
|
'SingleLTR' |
|
2021-05-28 14:36:55 +02:00
|
|
|
'DoubleVertical' |
|
|
|
|
'DoubleRTL' |
|
|
|
|
'DoubleLTR' |
|
2021-05-15 20:52:37 +02:00
|
|
|
'ContinuesHorizontal';
|
|
|
|
|
2021-05-15 14:48:57 +02:00
|
|
|
interface IReaderSettings{
|
|
|
|
staticNav: boolean
|
|
|
|
showPageNumber: boolean
|
2021-05-17 09:57:14 +02:00
|
|
|
loadNextonEnding: boolean
|
2021-05-15 20:52:37 +02:00
|
|
|
readerType: ReaderType
|
2021-05-15 14:48:57 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
interface IReaderPage {
|
|
|
|
index: number
|
|
|
|
src: string
|
|
|
|
}
|
2021-05-15 20:52:37 +02:00
|
|
|
|
|
|
|
interface IReaderProps {
|
|
|
|
pages: Array<IReaderPage>
|
|
|
|
pageCount: number
|
|
|
|
setCurPage: React.Dispatch<React.SetStateAction<number>>
|
|
|
|
curPage: number
|
|
|
|
settings: IReaderSettings
|
2021-05-17 09:57:14 +02:00
|
|
|
manga: IMangaCard | IManga
|
|
|
|
chapter: IChapter | IPartialChpter
|
2021-05-17 22:40:28 +02:00
|
|
|
nextChapter: () => void
|
2021-05-25 10:44:07 +02:00
|
|
|
prevChapter: () => void
|
2021-05-15 20:52:37 +02:00
|
|
|
}
|
2021-05-25 18:36:27 +02:00
|
|
|
|
|
|
|
interface IAbout {
|
|
|
|
name: string
|
|
|
|
version: string
|
|
|
|
revision: string
|
|
|
|
buildType: 'Stable' | 'Preview'
|
|
|
|
buildTime: number
|
|
|
|
github: string
|
|
|
|
discord: string
|
|
|
|
}
|