8d5b92bc9e
* update depedencies (buidable) * fix: init db once * upgrade react navigation v7 * better deeplink handler * upgrade react naitve vector icons * updated sql querries (may need further adjustments) * fix: added type for icon name * update react-native-reanimated, react-native-gesture-handler * update google signin * update tabivew & bottom sheet * make all repository queries synchroniuously * update categoryqueries * import db in categoryqueries * update chapter queries * update import novel * updated LibraryUpdateQueries * fix download chapter * fixed stats * update history queries * improved updates tab logic * update LibraryQueries * update NovelQueries * improved import novel * fixed notifications for android 14 and up * fix Cant parse on first opening * fixed loss of precision error * Partial Loading of NovelScreen * NovelScreenButtonGroup animation * NovelScreen appbar animations * update migrate novel * feat: rewrite VolumeButtonListener to turbor module * minor: clean up * fixed type errors * Novelscreen updates * fix: better material-design-icons for react-native-paper * migrate react-native to 0.77, good bye metro console streaming * replace elevation with boxShadow * rewrite FileManager -> NativeFile in TurborModule * rewrite ZipArchive -> NativeZipArchive * rewrite EpubUtil -> NativeEpubUtil * dev improvement: active arch only for ndk and run launch debug id * experimental React compiler (works but no significant improvements) * ReaderBotttomSheet rewrite * remove db from all query helper functions * simplified db helper types * better helper functions * switch to native-stack * removed console.log * Change loading in UpdatesScreen * pass novelcover on opening novel * cleanup UpdateNovelCard * fixed lint errors * changed novelscreen animation behaviour * fix UpdatesScreen * fix lint errors * fix unwanted downloadbutton behaviour * fix: wrong key for multi * fix: react-native-screens override * remove abi filters for debug * fix selecting chapters not working correctly * adjust novelappbar animation * preserve Layout when opening novel image * added SafeAreaViews * set Modal shadow to transparent * replace rn paper modal with @components modal * fix go prev chapter goes to first chapter * fix open drawer with button * fix SafeAreaView * fix LibraryScreen * improve BottomSheet performance * SafeAreaView for global search * fix NovelScreen SafeArea * restructure useNovel * remove useNovel from NovelScreenList due to possible db lock * fix NovelCover not showing on first opening * fix library not updating changes to novels * fix menu covering taskbar * added FadeIn transition to appbar elements * added SafeSnapPoints to keep bottomsheet inside of the safe area * upgrade packages * maybe round download button for jacubb * fix space after autoscroll * fix ReaderBottomSheet switch * fix Jump to Chapter style * fix Jump to chapter behaviour * add Loading state to novelcover * insertChapters performance improvement * getChapter and getNovel db optimization * updated db indexes * New Skeleton for NovelScreen * smoother FAB button * add fetching state to useNovel * fix paged novel chapter navigation * fix type issues * fix expanded novelCover on rotation * add batched loading for chapters * fix download button * fix novelScreen loading state * upgrade react native 0.78 * update to LegendList and fixed type errors * fix chapter drawer * added novel context + moved chapter & novel into ReaderStack * fix lint * improved chapterlist performance * improved ChapterListSkeleton performance * improved updates skeleton * reworked onboading screen * fix chapter drawer render error * add NovelContext [unstable] * fix filter compatibility * upgrade eslint + add tanstack query * eslint auto fix * fix eslint errors * upgrade expo 53, react native 0.79.1 * remove console * remove unused package * fix: exact vesion for core packages * update contributing versions --------- Co-authored-by: CD-Z <p_loser_Austria@gmx.at>
38 lines
1.0 KiB
TypeScript
38 lines
1.0 KiB
TypeScript
import { TurboModule, TurboModuleRegistry } from 'react-native';
|
|
|
|
interface ReadDirResult {
|
|
name: string;
|
|
path: string;
|
|
isDirectory: boolean; // int
|
|
}
|
|
|
|
export interface Spec extends TurboModule {
|
|
writeFile: (path: string, content: string) => void;
|
|
readFile: (path: string) => string;
|
|
copyFile: (sourcePath: string, destPath: string) => void;
|
|
moveFile: (sourcePath: string, destPath: string) => void;
|
|
exists: (filePath: string) => boolean;
|
|
/**
|
|
* @description create parents, and do nothing if exists;
|
|
*/
|
|
mkdir: (filePath: string) => void;
|
|
/**
|
|
* @description remove recursively
|
|
*/
|
|
unlink: (filePath: string) => void;
|
|
readDir: (dirPath: string) => ReadDirResult[];
|
|
downloadFile: (
|
|
url: string,
|
|
destPath: string,
|
|
method: string,
|
|
headers: { [key: string]: string } | Headers,
|
|
body?: string,
|
|
) => Promise<void>;
|
|
getConstants: () => {
|
|
ExternalDirectoryPath: string;
|
|
ExternalCachesDirectoryPath: string;
|
|
};
|
|
}
|
|
|
|
export default TurboModuleRegistry.getEnforcing<Spec>('NativeFile');
|