Fork: rename package and applicationId
This commit is contained in:
parent
b0ab7d320a
commit
ad821faecd
577 changed files with 2463 additions and 2379 deletions
84
AGENTS.md
Normal file
84
AGENTS.md
Normal file
|
|
@ -0,0 +1,84 @@
|
||||||
|
# Book's Story — Bookshelf Fork
|
||||||
|
|
||||||
|
> Форк `Acclorite/book-story` под Bookshelf: audiobookshelf + bookshelf-api + TTS + offline.
|
||||||
|
|
||||||
|
## Stack
|
||||||
|
|
||||||
|
- **Язык:** Kotlin 100%
|
||||||
|
- **UI:** Jetpack Compose + Material3
|
||||||
|
- **DI:** Dagger Hilt
|
||||||
|
- **БД:** Room
|
||||||
|
- **Настройки:** DataStore
|
||||||
|
- **Сеть:** Retrofit + OkHttp + Kotlinx Serialization
|
||||||
|
- **Аудио:** ExoPlayer (Media3) + MediaSession
|
||||||
|
- **Фоновые задачи:** WorkManager
|
||||||
|
- **Читалка:** собственная Book's Story (jsoup, pdfbox, commonmark)
|
||||||
|
- **minSdk:** 26 (план — поднять до 31 позже)
|
||||||
|
- **compileSdk/targetSdk:** 36
|
||||||
|
|
||||||
|
## Goal
|
||||||
|
|
||||||
|
- Сохранить Material You reader Book's Story.
|
||||||
|
- Добавить поддержку bookshelf-api: библиотеки, поиск, TTS, подкасты, Яндекс/YouTube.
|
||||||
|
- Добавить аудиоплеер для аудиокниг из Audiobookshelf.
|
||||||
|
- Добавить offline-кэш и синхронизацию прогресса.
|
||||||
|
|
||||||
|
## Layout
|
||||||
|
|
||||||
|
- `app/src/main/java/org/dueattendant149/bookshelf/` — основной код
|
||||||
|
- `core/` — crash handler, typealias, commonmark parser
|
||||||
|
- `data/` — repository, Room, DataStore, mappers, parsers, DI
|
||||||
|
- `domain/` — models, use cases, repository interfaces
|
||||||
|
- `presentation/` — ViewModels, MVI screens, navigator
|
||||||
|
- `ui/` — Compose UI
|
||||||
|
- `bookshelf-api` backend находится в `~/bookshelf/bookshelf-api/` (отдельный проект)
|
||||||
|
- Lissen (который дорабатывается параллельно) — `~/bookshelf/lissen/`
|
||||||
|
|
||||||
|
## API endpoints
|
||||||
|
|
||||||
|
- **bookshelf-api:** `http://bookshelf-api:8073` (или `https://tts.dueattendant149.org` после DNS)
|
||||||
|
- `GET /api/v1/books/libraries`
|
||||||
|
- `GET /api/v1/books/{item_id}`
|
||||||
|
- `GET /api/v1/books/library/{id}/search?q=...`
|
||||||
|
- `POST /api/v1/search`
|
||||||
|
- `POST /api/v1/tts`, `GET /api/v1/tts/{job_id}`, `GET /api/v1/tts/{job_id}/download`
|
||||||
|
- `GET /api/v1/tts/engines`, `GET /api/v1/tts/voices`
|
||||||
|
- `POST /api/v1/download`, `GET /api/v1/download/list`
|
||||||
|
- `POST /api/v1/podcasts`, `POST /api/v1/sources/yandex`
|
||||||
|
- **Audiobookshelf (напрямую):** для аудио файлов и обложек
|
||||||
|
- `GET /api/items/{id}/file/{ino}`
|
||||||
|
- `GET /api/items/{id}/download`
|
||||||
|
- `GET /api/items/{id}/cover`
|
||||||
|
|
||||||
|
## Git
|
||||||
|
|
||||||
|
- **origin:** `https://git.dueattendant149.org/Atte149/book-story.git` (Forgejo)
|
||||||
|
- **upstream:** `https://github.com/Acclorite/book-story.git`
|
||||||
|
- **Лицензия:** GPL-3.0-only (как у оригинала)
|
||||||
|
|
||||||
|
## Build
|
||||||
|
|
||||||
|
```bash
|
||||||
|
./gradlew :app:assembleDebug
|
||||||
|
```
|
||||||
|
|
||||||
|
## Current Status
|
||||||
|
|
||||||
|
- Phase 1: fork + package rename completed.
|
||||||
|
- Next: Phase 2 — network layer (Retrofit + bookshelf-api client).
|
||||||
|
|
||||||
|
## WARNs
|
||||||
|
|
||||||
|
- **Не пушить в `upstream` (Acclorite/book-story).** Только в `origin` (Forgejo).
|
||||||
|
- **Lissen остаётся живым проектом.** Book's Story fork — отдельная ветка развития.
|
||||||
|
- **Секреты** (ABS token, API keys) хранить только в `.env` / `credentials.json` / DataStore, никогда в коде.
|
||||||
|
- **Package:** `org.dueattendant149.bookshelf`. Все ссылки на `ua.acclorite.book_story` в коде заменены; README оставлен с оригинальными F-Droid ссылками.
|
||||||
|
|
||||||
|
## Typical tasks
|
||||||
|
|
||||||
|
- Добавить новый endpoint bookshelf-api
|
||||||
|
- Расширить `Book` / `BookEntity` для remote полей
|
||||||
|
- Добавить аудиоплеер экран
|
||||||
|
- Добавить TTS экран
|
||||||
|
- Поднять minSdk, добавить новые разрешения
|
||||||
|
- Обновить AGENTS.md при существенных изменениях архитектуры
|
||||||
|
|
@ -10,12 +10,12 @@ plugins {
|
||||||
}
|
}
|
||||||
|
|
||||||
android {
|
android {
|
||||||
namespace = "ua.acclorite.book_story"
|
namespace = "org.dueattendant149.bookshelf"
|
||||||
compileSdk = 36
|
compileSdk = 36
|
||||||
|
|
||||||
// Default configuration
|
// Default configuration
|
||||||
defaultConfig {
|
defaultConfig {
|
||||||
applicationId = "ua.acclorite.book_story"
|
applicationId = "org.dueattendant149.bookshelf"
|
||||||
minSdk = 26
|
minSdk = 26
|
||||||
targetSdk = 36
|
targetSdk = 36
|
||||||
versionCode = 14
|
versionCode = 14
|
||||||
|
|
|
||||||
|
|
@ -3,13 +3,13 @@
|
||||||
|
|
||||||
<!-- Removing DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION, which is not used -->
|
<!-- Removing DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION, which is not used -->
|
||||||
<uses-permission
|
<uses-permission
|
||||||
android:name="ua.acclorite.book_story.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
android:name="org.dueattendant149.bookshelf.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
||||||
tools:node="remove" />
|
tools:node="remove" />
|
||||||
<uses-permission
|
<uses-permission
|
||||||
android:name="ua.acclorite.book_story.debug.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
android:name="org.dueattendant149.bookshelf.debug.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
||||||
tools:node="remove" />
|
tools:node="remove" />
|
||||||
<uses-permission
|
<uses-permission
|
||||||
android:name="ua.acclorite.book_story.release.debug.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
android:name="org.dueattendant149.bookshelf.release.debug.DYNAMIC_RECEIVER_NOT_EXPORTED_PERMISSION"
|
||||||
tools:node="remove" />
|
tools:node="remove" />
|
||||||
|
|
||||||
<!-- Removing READ_EXTERNAL_STORAGE and WRITE_EXTERNAL_STORAGE explicitly -->
|
<!-- Removing READ_EXTERNAL_STORAGE and WRITE_EXTERNAL_STORAGE explicitly -->
|
||||||
|
|
|
||||||
|
|
@ -4,11 +4,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story
|
package org.dueattendant149.bookshelf
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import dagger.hilt.android.HiltAndroidApp
|
import dagger.hilt.android.HiltAndroidApp
|
||||||
import ua.acclorite.book_story.core.crash.CrashHandler
|
import org.dueattendant149.bookshelf.core.crash.CrashHandler
|
||||||
|
|
||||||
@HiltAndroidApp
|
@HiltAndroidApp
|
||||||
class Application : Application() {
|
class Application : Application() {
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core
|
package org.dueattendant149.bookshelf.core
|
||||||
|
|
||||||
import android.graphics.Bitmap
|
import android.graphics.Bitmap
|
||||||
|
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.crash
|
package org.dueattendant149.bookshelf.core.crash
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Process
|
import android.os.Process
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.presentation.crash.CrashActivity
|
import org.dueattendant149.bookshelf.presentation.crash.CrashActivity
|
||||||
import kotlin.system.exitProcess
|
import kotlin.system.exitProcess
|
||||||
|
|
||||||
private const val TAG = "CrashHandler"
|
private const val TAG = "CrashHandler"
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.crash
|
package org.dueattendant149.bookshelf.core.crash
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import java.io.BufferedWriter
|
import java.io.BufferedWriter
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.data
|
package org.dueattendant149.bookshelf.core.data
|
||||||
|
|
||||||
import kotlinx.collections.immutable.toPersistentList
|
import kotlinx.collections.immutable.toPersistentList
|
||||||
import ua.acclorite.book_story.core.language.Language
|
import org.dueattendant149.bookshelf.core.language.Language
|
||||||
|
|
||||||
object CoreData {
|
object CoreData {
|
||||||
val defaultLanguage = Language.fromLanguageTag(languageTag = "en") // English
|
val defaultLanguage = Language.fromLanguageTag(languageTag = "en") // English
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.data
|
package org.dueattendant149.bookshelf.core.data
|
||||||
|
|
||||||
import kotlinx.collections.immutable.persistentListOf
|
import kotlinx.collections.immutable.persistentListOf
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.data
|
package org.dueattendant149.bookshelf.core.data
|
||||||
|
|
||||||
object LinkData {
|
object LinkData {
|
||||||
const val RELEASES = "https://www.github.com/Acclorite/book-story/releases/latest"
|
const val RELEASES = "https://www.github.com/Acclorite/book-story/releases/latest"
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.helpers
|
package org.dueattendant149.bookshelf.core.helpers
|
||||||
|
|
||||||
fun <T> MutableList<T>.addAll(calculation: () -> List<T>) {
|
fun <T> MutableList<T>.addAll(calculation: () -> List<T>) {
|
||||||
addAll(calculation())
|
addAll(calculation())
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.helpers
|
package org.dueattendant149.bookshelf.core.helpers
|
||||||
|
|
||||||
fun String.removeTrailingZero(): String {
|
fun String.removeTrailingZero(): String {
|
||||||
if (!this.contains('.'))
|
if (!this.contains('.'))
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.helpers
|
package org.dueattendant149.bookshelf.core.helpers
|
||||||
|
|
||||||
fun <T> compareByWithOrder(
|
fun <T> compareByWithOrder(
|
||||||
descending: Boolean,
|
descending: Boolean,
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.language
|
package org.dueattendant149.bookshelf.core.language
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
import java.util.Locale
|
import java.util.Locale
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.language
|
package org.dueattendant149.bookshelf.core.language
|
||||||
|
|
||||||
import java.util.Locale
|
import java.util.Locale
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.log
|
package org.dueattendant149.bookshelf.core.log
|
||||||
|
|
||||||
import android.util.Log
|
import android.util.Log
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.core.ui
|
package org.dueattendant149.bookshelf.core.ui
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.os.Parcelable
|
import android.os.Parcelable
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.converter
|
package org.dueattendant149.bookshelf.data.converter
|
||||||
|
|
||||||
import androidx.room.TypeConverter
|
import androidx.room.TypeConverter
|
||||||
import kotlinx.serialization.json.Json
|
import kotlinx.serialization.json.Json
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.di
|
package org.dueattendant149.bookshelf.data.di
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import androidx.room.Room
|
import androidx.room.Room
|
||||||
|
|
@ -19,8 +19,8 @@ import org.commonmark.node.HtmlBlock
|
||||||
import org.commonmark.node.IndentedCodeBlock
|
import org.commonmark.node.IndentedCodeBlock
|
||||||
import org.commonmark.node.ThematicBreak
|
import org.commonmark.node.ThematicBreak
|
||||||
import org.commonmark.parser.Parser
|
import org.commonmark.parser.Parser
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.local.room.DatabaseHelper
|
import org.dueattendant149.bookshelf.data.local.room.DatabaseHelper
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
|
|
@ -4,42 +4,42 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.di
|
package org.dueattendant149.bookshelf.data.di
|
||||||
|
|
||||||
import dagger.Binds
|
import dagger.Binds
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import ua.acclorite.book_story.data.local.data_store.DataStore
|
import org.dueattendant149.bookshelf.data.local.data_store.DataStore
|
||||||
import ua.acclorite.book_story.data.local.data_store.DataStoreImpl
|
import org.dueattendant149.bookshelf.data.local.data_store.DataStoreImpl
|
||||||
import ua.acclorite.book_story.data.mapper.book.BookMapper
|
import org.dueattendant149.bookshelf.data.mapper.book.BookMapper
|
||||||
import ua.acclorite.book_story.data.mapper.book.BookMapperImpl
|
import org.dueattendant149.bookshelf.data.mapper.book.BookMapperImpl
|
||||||
import ua.acclorite.book_story.data.mapper.category.CategoryMapper
|
import org.dueattendant149.bookshelf.data.mapper.category.CategoryMapper
|
||||||
import ua.acclorite.book_story.data.mapper.category.CategoryMapperImpl
|
import org.dueattendant149.bookshelf.data.mapper.category.CategoryMapperImpl
|
||||||
import ua.acclorite.book_story.data.mapper.color_preset.ColorPresetMapper
|
import org.dueattendant149.bookshelf.data.mapper.color_preset.ColorPresetMapper
|
||||||
import ua.acclorite.book_story.data.mapper.color_preset.ColorPresetMapperImpl
|
import org.dueattendant149.bookshelf.data.mapper.color_preset.ColorPresetMapperImpl
|
||||||
import ua.acclorite.book_story.data.mapper.file.FileMapper
|
import org.dueattendant149.bookshelf.data.mapper.file.FileMapper
|
||||||
import ua.acclorite.book_story.data.mapper.file.FileMapperImpl
|
import org.dueattendant149.bookshelf.data.mapper.file.FileMapperImpl
|
||||||
import ua.acclorite.book_story.data.mapper.history.HistoryMapper
|
import org.dueattendant149.bookshelf.data.mapper.history.HistoryMapper
|
||||||
import ua.acclorite.book_story.data.mapper.history.HistoryMapperImpl
|
import org.dueattendant149.bookshelf.data.mapper.history.HistoryMapperImpl
|
||||||
import ua.acclorite.book_story.data.parser.cover.CoverParser
|
import org.dueattendant149.bookshelf.data.parser.cover.CoverParser
|
||||||
import ua.acclorite.book_story.data.parser.cover.CoverParserImpl
|
import org.dueattendant149.bookshelf.data.parser.cover.CoverParserImpl
|
||||||
import ua.acclorite.book_story.data.parser.file.FileParser
|
import org.dueattendant149.bookshelf.data.parser.file.FileParser
|
||||||
import ua.acclorite.book_story.data.parser.file.FileParserImpl
|
import org.dueattendant149.bookshelf.data.parser.file.FileParserImpl
|
||||||
import ua.acclorite.book_story.data.parser.text.TextParser
|
import org.dueattendant149.bookshelf.data.parser.text.TextParser
|
||||||
import ua.acclorite.book_story.data.parser.text.TextParserImpl
|
import org.dueattendant149.bookshelf.data.parser.text.TextParserImpl
|
||||||
import ua.acclorite.book_story.data.repository.BookRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.BookRepositoryImpl
|
||||||
import ua.acclorite.book_story.data.repository.CategoryRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.CategoryRepositoryImpl
|
||||||
import ua.acclorite.book_story.data.repository.ColorPresetRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.ColorPresetRepositoryImpl
|
||||||
import ua.acclorite.book_story.data.repository.FileSystemRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.FileSystemRepositoryImpl
|
||||||
import ua.acclorite.book_story.data.repository.HistoryRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.HistoryRepositoryImpl
|
||||||
import ua.acclorite.book_story.data.repository.PermissionRepositoryImpl
|
import org.dueattendant149.bookshelf.data.repository.PermissionRepositoryImpl
|
||||||
import ua.acclorite.book_story.domain.repository.BookRepository
|
import org.dueattendant149.bookshelf.domain.repository.BookRepository
|
||||||
import ua.acclorite.book_story.domain.repository.CategoryRepository
|
import org.dueattendant149.bookshelf.domain.repository.CategoryRepository
|
||||||
import ua.acclorite.book_story.domain.repository.ColorPresetRepository
|
import org.dueattendant149.bookshelf.domain.repository.ColorPresetRepository
|
||||||
import ua.acclorite.book_story.domain.repository.FileSystemRepository
|
import org.dueattendant149.bookshelf.domain.repository.FileSystemRepository
|
||||||
import ua.acclorite.book_story.domain.repository.HistoryRepository
|
import org.dueattendant149.bookshelf.domain.repository.HistoryRepository
|
||||||
import ua.acclorite.book_story.domain.repository.PermissionRepository
|
import org.dueattendant149.bookshelf.domain.repository.PermissionRepository
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
|
|
@ -4,16 +4,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.di
|
package org.dueattendant149.bookshelf.data.di
|
||||||
|
|
||||||
import dagger.Binds
|
import dagger.Binds
|
||||||
import dagger.Module
|
import dagger.Module
|
||||||
import dagger.hilt.InstallIn
|
import dagger.hilt.InstallIn
|
||||||
import dagger.hilt.components.SingletonComponent
|
import dagger.hilt.components.SingletonComponent
|
||||||
import ua.acclorite.book_story.data.service.CoverImageHandlerImpl
|
import org.dueattendant149.bookshelf.data.service.CoverImageHandlerImpl
|
||||||
import ua.acclorite.book_story.data.service.FileProviderImpl
|
import org.dueattendant149.bookshelf.data.service.FileProviderImpl
|
||||||
import ua.acclorite.book_story.domain.service.CoverImageHandler
|
import org.dueattendant149.bookshelf.domain.service.CoverImageHandler
|
||||||
import ua.acclorite.book_story.domain.service.FileProvider
|
import org.dueattendant149.bookshelf.domain.service.FileProvider
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
@Module
|
@Module
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.data_store
|
package org.dueattendant149.bookshelf.data.local.data_store
|
||||||
|
|
||||||
import androidx.datastore.preferences.core.Preferences
|
import androidx.datastore.preferences.core.Preferences
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.data_store
|
package org.dueattendant149.bookshelf.data.local.data_store
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.dto
|
package org.dueattendant149.bookshelf.data.local.dto
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import androidx.room.TypeConverters
|
import androidx.room.TypeConverters
|
||||||
import ua.acclorite.book_story.data.converter.CategoryConverter
|
import org.dueattendant149.bookshelf.data.converter.CategoryConverter
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@TypeConverters(CategoryConverter::class)
|
@TypeConverters(CategoryConverter::class)
|
||||||
|
|
@ -4,12 +4,12 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.dto
|
package org.dueattendant149.bookshelf.data.local.dto
|
||||||
|
|
||||||
import androidx.room.ColumnInfo
|
import androidx.room.ColumnInfo
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
import ua.acclorite.book_story.presentation.library.model.LibrarySortOrder
|
import org.dueattendant149.bookshelf.presentation.library.model.LibrarySortOrder
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
data class CategoryEntity(
|
data class CategoryEntity(
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.dto
|
package org.dueattendant149.bookshelf.data.local.dto
|
||||||
|
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.dto
|
package org.dueattendant149.bookshelf.data.local.dto
|
||||||
|
|
||||||
import androidx.room.Entity
|
import androidx.room.Entity
|
||||||
import androidx.room.PrimaryKey
|
import androidx.room.PrimaryKey
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.dto
|
package org.dueattendant149.bookshelf.data.local.dto
|
||||||
|
|
||||||
import androidx.room.Embedded
|
import androidx.room.Embedded
|
||||||
import androidx.room.Relation
|
import androidx.room.Relation
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.room
|
package org.dueattendant149.bookshelf.data.local.room
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
|
|
@ -12,7 +12,7 @@ import androidx.room.Insert
|
||||||
import androidx.room.OnConflictStrategy
|
import androidx.room.OnConflictStrategy
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Update
|
import androidx.room.Update
|
||||||
import ua.acclorite.book_story.data.local.dto.BookEntity
|
import org.dueattendant149.bookshelf.data.local.dto.BookEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
interface BookDao {
|
interface BookDao {
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.room
|
package org.dueattendant149.bookshelf.data.local.room
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import androidx.room.AutoMigration
|
import androidx.room.AutoMigration
|
||||||
|
|
@ -15,10 +15,10 @@ import androidx.room.RoomDatabase
|
||||||
import androidx.room.migration.AutoMigrationSpec
|
import androidx.room.migration.AutoMigrationSpec
|
||||||
import androidx.room.migration.Migration
|
import androidx.room.migration.Migration
|
||||||
import androidx.sqlite.db.SupportSQLiteDatabase
|
import androidx.sqlite.db.SupportSQLiteDatabase
|
||||||
import ua.acclorite.book_story.data.local.dto.BookEntity
|
import org.dueattendant149.bookshelf.data.local.dto.BookEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.CategoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.CategoryEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.ColorPresetEntity
|
import org.dueattendant149.bookshelf.data.local.dto.ColorPresetEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryEntity
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
||||||
@Database(
|
@Database(
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.room
|
package org.dueattendant149.bookshelf.data.local.room
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
|
|
@ -12,7 +12,7 @@ import androidx.room.Insert
|
||||||
import androidx.room.OnConflictStrategy
|
import androidx.room.OnConflictStrategy
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Update
|
import androidx.room.Update
|
||||||
import ua.acclorite.book_story.data.local.dto.CategoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.CategoryEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
interface CategoryDao {
|
interface CategoryDao {
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.room
|
package org.dueattendant149.bookshelf.data.local.room
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Upsert
|
import androidx.room.Upsert
|
||||||
import ua.acclorite.book_story.data.local.dto.ColorPresetEntity
|
import org.dueattendant149.bookshelf.data.local.dto.ColorPresetEntity
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
interface ColorPresetDao {
|
interface ColorPresetDao {
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.local.room
|
package org.dueattendant149.bookshelf.data.local.room
|
||||||
|
|
||||||
import androidx.room.Dao
|
import androidx.room.Dao
|
||||||
import androidx.room.Delete
|
import androidx.room.Delete
|
||||||
|
|
@ -12,8 +12,8 @@ import androidx.room.Insert
|
||||||
import androidx.room.OnConflictStrategy
|
import androidx.room.OnConflictStrategy
|
||||||
import androidx.room.Query
|
import androidx.room.Query
|
||||||
import androidx.room.Transaction
|
import androidx.room.Transaction
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryWithBook
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryWithBook
|
||||||
|
|
||||||
@Dao
|
@Dao
|
||||||
interface HistoryDao {
|
interface HistoryDao {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.book
|
package org.dueattendant149.bookshelf.data.mapper.book
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.BookEntity
|
import org.dueattendant149.bookshelf.data.local.dto.BookEntity
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
|
|
||||||
interface BookMapper {
|
interface BookMapper {
|
||||||
fun toBookEntity(book: Book): BookEntity
|
fun toBookEntity(book: Book): BookEntity
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.book
|
package org.dueattendant149.bookshelf.data.mapper.book
|
||||||
|
|
||||||
import androidx.core.net.toUri
|
import androidx.core.net.toUri
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.local.dto.BookEntity
|
import org.dueattendant149.bookshelf.data.local.dto.BookEntity
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class BookMapperImpl @Inject constructor() : BookMapper {
|
class BookMapperImpl @Inject constructor() : BookMapper {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.category
|
package org.dueattendant149.bookshelf.data.mapper.category
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.CategoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.CategoryEntity
|
||||||
import ua.acclorite.book_story.domain.model.library.Category
|
import org.dueattendant149.bookshelf.domain.model.library.Category
|
||||||
|
|
||||||
interface CategoryMapper {
|
interface CategoryMapper {
|
||||||
fun toCategoryEntity(category: Category): CategoryEntity
|
fun toCategoryEntity(category: Category): CategoryEntity
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.category
|
package org.dueattendant149.bookshelf.data.mapper.category
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.CategoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.CategoryEntity
|
||||||
import ua.acclorite.book_story.domain.model.library.Category
|
import org.dueattendant149.bookshelf.domain.model.library.Category
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class CategoryMapperImpl @Inject constructor() : CategoryMapper {
|
class CategoryMapperImpl @Inject constructor() : CategoryMapper {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.color_preset
|
package org.dueattendant149.bookshelf.data.mapper.color_preset
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.ColorPresetEntity
|
import org.dueattendant149.bookshelf.data.local.dto.ColorPresetEntity
|
||||||
import ua.acclorite.book_story.domain.model.reader.ColorPreset
|
import org.dueattendant149.bookshelf.domain.model.reader.ColorPreset
|
||||||
|
|
||||||
interface ColorPresetMapper {
|
interface ColorPresetMapper {
|
||||||
fun toColorPresetEntity(colorPreset: ColorPreset, order: Int): ColorPresetEntity
|
fun toColorPresetEntity(colorPreset: ColorPreset, order: Int): ColorPresetEntity
|
||||||
|
|
@ -4,11 +4,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.color_preset
|
package org.dueattendant149.bookshelf.data.mapper.color_preset
|
||||||
|
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
import ua.acclorite.book_story.data.local.dto.ColorPresetEntity
|
import org.dueattendant149.bookshelf.data.local.dto.ColorPresetEntity
|
||||||
import ua.acclorite.book_story.domain.model.reader.ColorPreset
|
import org.dueattendant149.bookshelf.domain.model.reader.ColorPreset
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class ColorPresetMapperImpl @Inject constructor() : ColorPresetMapper {
|
class ColorPresetMapperImpl @Inject constructor() : ColorPresetMapper {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.file
|
package org.dueattendant149.bookshelf.data.mapper.file
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.file.File
|
import org.dueattendant149.bookshelf.domain.model.file.File
|
||||||
|
|
||||||
interface FileMapper {
|
interface FileMapper {
|
||||||
fun toCachedFile(file: File): CachedFile
|
fun toCachedFile(file: File): CachedFile
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.file
|
package org.dueattendant149.bookshelf.data.mapper.file
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import androidx.core.net.toUri
|
import androidx.core.net.toUri
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFileCompat
|
import org.dueattendant149.bookshelf.data.model.file.CachedFileCompat
|
||||||
import ua.acclorite.book_story.domain.model.file.File
|
import org.dueattendant149.bookshelf.domain.model.file.File
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class FileMapperImpl @Inject constructor(
|
class FileMapperImpl @Inject constructor(
|
||||||
|
|
@ -4,11 +4,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.history
|
package org.dueattendant149.bookshelf.data.mapper.history
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryWithBook
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryWithBook
|
||||||
import ua.acclorite.book_story.domain.model.history.History
|
import org.dueattendant149.bookshelf.domain.model.history.History
|
||||||
|
|
||||||
interface HistoryMapper {
|
interface HistoryMapper {
|
||||||
suspend fun toHistoryEntity(history: History): HistoryEntity
|
suspend fun toHistoryEntity(history: History): HistoryEntity
|
||||||
|
|
@ -4,12 +4,12 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.mapper.history
|
package org.dueattendant149.bookshelf.data.mapper.history
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryEntity
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryEntity
|
||||||
import ua.acclorite.book_story.data.local.dto.HistoryWithBook
|
import org.dueattendant149.bookshelf.data.local.dto.HistoryWithBook
|
||||||
import ua.acclorite.book_story.data.mapper.book.BookMapper
|
import org.dueattendant149.bookshelf.data.mapper.book.BookMapper
|
||||||
import ua.acclorite.book_story.domain.model.history.History
|
import org.dueattendant149.bookshelf.domain.model.history.History
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class HistoryMapperImpl @Inject constructor(
|
class HistoryMapperImpl @Inject constructor(
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.model.file
|
package org.dueattendant149.bookshelf.data.model.file
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.model.file
|
package org.dueattendant149.bookshelf.data.model.file
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.model.file
|
package org.dueattendant149.bookshelf.data.model.file
|
||||||
|
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
|
|
||||||
interface CoverParser {
|
interface CoverParser {
|
||||||
suspend fun parse(cachedFile: CachedFile): CoverImage?
|
suspend fun parse(cachedFile: CachedFile): CoverImage?
|
||||||
|
|
@ -4,11 +4,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "CoverParser"
|
private const val TAG = "CoverParser"
|
||||||
|
|
@ -4,16 +4,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import android.graphics.BitmapFactory
|
import android.graphics.BitmapFactory
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import java.net.URLDecoder
|
import java.net.URLDecoder
|
||||||
import java.nio.charset.StandardCharsets
|
import java.nio.charset.StandardCharsets
|
||||||
import java.util.zip.ZipFile
|
import java.util.zip.ZipFile
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class Fb2CoverParser @Inject constructor() : CoverParser {
|
class Fb2CoverParser @Inject constructor() : CoverParser {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class HtmlCoverParser @Inject constructor() : CoverParser {
|
class HtmlCoverParser @Inject constructor() : CoverParser {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class PdfCoverParser @Inject constructor() : CoverParser {
|
class PdfCoverParser @Inject constructor() : CoverParser {
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.cover
|
package org.dueattendant149.bookshelf.data.parser.cover
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class TxtCoverParser @Inject constructor() : CoverParser {
|
class TxtCoverParser @Inject constructor() : CoverParser {
|
||||||
|
|
@ -4,17 +4,17 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.document
|
package org.dueattendant149.bookshelf.data.parser.document
|
||||||
|
|
||||||
import android.graphics.Bitmap
|
import android.graphics.Bitmap
|
||||||
import android.graphics.BitmapFactory
|
import android.graphics.BitmapFactory
|
||||||
import androidx.compose.ui.graphics.asImageBitmap
|
import androidx.compose.ui.graphics.asImageBitmap
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import org.jsoup.nodes.Document
|
import org.jsoup.nodes.Document
|
||||||
import ua.acclorite.book_story.core.helpers.clearAllMarkdown
|
import org.dueattendant149.bookshelf.core.helpers.clearAllMarkdown
|
||||||
import ua.acclorite.book_story.core.helpers.clearMarkdown
|
import org.dueattendant149.bookshelf.core.helpers.clearMarkdown
|
||||||
import ua.acclorite.book_story.core.helpers.containsVisibleText
|
import org.dueattendant149.bookshelf.core.helpers.containsVisibleText
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.net.URLDecoder
|
import java.net.URLDecoder
|
||||||
import java.nio.charset.StandardCharsets
|
import java.nio.charset.StandardCharsets
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.document
|
package org.dueattendant149.bookshelf.data.parser.document
|
||||||
|
|
||||||
import androidx.compose.ui.text.AnnotatedString
|
import androidx.compose.ui.text.AnnotatedString
|
||||||
import androidx.compose.ui.text.LinkAnnotation
|
import androidx.compose.ui.text.LinkAnnotation
|
||||||
|
|
@ -23,7 +23,7 @@ import org.commonmark.node.Node
|
||||||
import org.commonmark.node.StrongEmphasis
|
import org.commonmark.node.StrongEmphasis
|
||||||
import org.commonmark.node.Text
|
import org.commonmark.node.Text
|
||||||
import org.commonmark.parser.Parser
|
import org.commonmark.parser.Parser
|
||||||
import ua.acclorite.book_story.core.helpers.clearMarkdown
|
import org.dueattendant149.bookshelf.core.helpers.clearMarkdown
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class MarkdownParser @Inject constructor(
|
class MarkdownParser @Inject constructor(
|
||||||
|
|
@ -4,17 +4,17 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import java.util.zip.ZipFile
|
import java.util.zip.ZipFile
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
|
|
@ -4,15 +4,15 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "Fb2FileParser"
|
private const val TAG = "Fb2FileParser"
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
|
|
||||||
interface FileParser {
|
interface FileParser {
|
||||||
suspend fun parse(cachedFile: CachedFile): Book?
|
suspend fun parse(cachedFile: CachedFile): Book?
|
||||||
|
|
@ -4,11 +4,11 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "FileParser"
|
private const val TAG = "FileParser"
|
||||||
|
|
@ -4,15 +4,15 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "HtmlFileParser"
|
private const val TAG = "HtmlFileParser"
|
||||||
|
|
@ -4,16 +4,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import com.tom_roush.pdfbox.android.PDFBoxResourceLoader
|
import com.tom_roush.pdfbox.android.PDFBoxResourceLoader
|
||||||
import com.tom_roush.pdfbox.pdmodel.PDDocument
|
import com.tom_roush.pdfbox.pdmodel.PDDocument
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "PdfFileParser"
|
private const val TAG = "PdfFileParser"
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.file
|
package org.dueattendant149.bookshelf.data.parser.file
|
||||||
|
|
||||||
import ua.acclorite.book_story.R
|
import org.dueattendant149.bookshelf.R
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "TxtFileParser"
|
private const val TAG = "TxtFileParser"
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
@file:OptIn(ExperimentalCoroutinesApi::class)
|
@file:OptIn(ExperimentalCoroutinesApi::class)
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import androidx.core.net.toUri
|
import androidx.core.net.toUri
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
|
|
@ -17,15 +17,15 @@ import kotlinx.coroutines.withContext
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.core.data.ExtensionsData
|
import org.dueattendant149.bookshelf.core.data.ExtensionsData
|
||||||
import ua.acclorite.book_story.core.helpers.addAll
|
import org.dueattendant149.bookshelf.core.helpers.addAll
|
||||||
import ua.acclorite.book_story.core.helpers.containsVisibleText
|
import org.dueattendant149.bookshelf.core.helpers.containsVisibleText
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.core.log.logW
|
import org.dueattendant149.bookshelf.core.log.logW
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.document.DocumentParser
|
import org.dueattendant149.bookshelf.data.parser.document.DocumentParser
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import java.io.File
|
import java.io.File
|
||||||
import java.net.URLDecoder
|
import java.net.URLDecoder
|
||||||
import java.nio.charset.StandardCharsets
|
import java.nio.charset.StandardCharsets
|
||||||
|
|
@ -4,16 +4,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.document.DocumentParser
|
import org.dueattendant149.bookshelf.data.parser.document.DocumentParser
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "HtmlTextParser"
|
private const val TAG = "HtmlTextParser"
|
||||||
|
|
@ -4,19 +4,19 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import com.tom_roush.pdfbox.android.PDFBoxResourceLoader
|
import com.tom_roush.pdfbox.android.PDFBoxResourceLoader
|
||||||
import com.tom_roush.pdfbox.pdmodel.PDDocument
|
import com.tom_roush.pdfbox.pdmodel.PDDocument
|
||||||
import com.tom_roush.pdfbox.text.PDFTextStripper
|
import com.tom_roush.pdfbox.text.PDFTextStripper
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import ua.acclorite.book_story.core.helpers.clearAllMarkdown
|
import org.dueattendant149.bookshelf.core.helpers.clearAllMarkdown
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.document.MarkdownParser
|
import org.dueattendant149.bookshelf.data.parser.document.MarkdownParser
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "PdfTextParser"
|
private const val TAG = "PdfTextParser"
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
|
|
||||||
interface TextParser {
|
interface TextParser {
|
||||||
suspend fun parse(cachedFile: CachedFile): List<ReaderText>
|
suspend fun parse(cachedFile: CachedFile): List<ReaderText>
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "TextParser"
|
private const val TAG = "TextParser"
|
||||||
|
|
@ -4,17 +4,17 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import ua.acclorite.book_story.core.helpers.clearAllMarkdown
|
import org.dueattendant149.bookshelf.core.helpers.clearAllMarkdown
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.document.MarkdownParser
|
import org.dueattendant149.bookshelf.data.parser.document.MarkdownParser
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "TxtTextParser"
|
private const val TAG = "TxtTextParser"
|
||||||
|
|
@ -4,16 +4,16 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.parser.text
|
package org.dueattendant149.bookshelf.data.parser.text
|
||||||
|
|
||||||
import kotlinx.coroutines.yield
|
import kotlinx.coroutines.yield
|
||||||
import org.jsoup.Jsoup
|
import org.jsoup.Jsoup
|
||||||
import org.jsoup.parser.Parser
|
import org.jsoup.parser.Parser
|
||||||
import ua.acclorite.book_story.core.log.logE
|
import org.dueattendant149.bookshelf.core.log.logE
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.document.DocumentParser
|
import org.dueattendant149.bookshelf.data.parser.document.DocumentParser
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
private const val TAG = "XmlTextParser"
|
private const val TAG = "XmlTextParser"
|
||||||
|
|
@ -4,21 +4,21 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.mapper.book.BookMapper
|
import org.dueattendant149.bookshelf.data.mapper.book.BookMapper
|
||||||
import ua.acclorite.book_story.data.mapper.file.FileMapper
|
import org.dueattendant149.bookshelf.data.mapper.file.FileMapper
|
||||||
import ua.acclorite.book_story.data.parser.cover.CoverParser
|
import org.dueattendant149.bookshelf.data.parser.cover.CoverParser
|
||||||
import ua.acclorite.book_story.data.parser.text.TextParser
|
import org.dueattendant149.bookshelf.data.parser.text.TextParser
|
||||||
import ua.acclorite.book_story.domain.model.file.File
|
import org.dueattendant149.bookshelf.domain.model.file.File
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import ua.acclorite.book_story.domain.model.reader.ReaderText
|
import org.dueattendant149.bookshelf.domain.model.reader.ReaderText
|
||||||
import ua.acclorite.book_story.domain.repository.BookRepository
|
import org.dueattendant149.bookshelf.domain.repository.BookRepository
|
||||||
import ua.acclorite.book_story.domain.service.FileProvider
|
import org.dueattendant149.bookshelf.domain.service.FileProvider
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,14 +4,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.mapper.category.CategoryMapper
|
import org.dueattendant149.bookshelf.data.mapper.category.CategoryMapper
|
||||||
import ua.acclorite.book_story.domain.model.library.Category
|
import org.dueattendant149.bookshelf.domain.model.library.Category
|
||||||
import ua.acclorite.book_story.domain.repository.CategoryRepository
|
import org.dueattendant149.bookshelf.domain.repository.CategoryRepository
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,14 +4,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.mapper.color_preset.ColorPresetMapper
|
import org.dueattendant149.bookshelf.data.mapper.color_preset.ColorPresetMapper
|
||||||
import ua.acclorite.book_story.domain.model.reader.ColorPreset
|
import org.dueattendant149.bookshelf.domain.model.reader.ColorPreset
|
||||||
import ua.acclorite.book_story.domain.repository.ColorPresetRepository
|
import org.dueattendant149.bookshelf.domain.repository.ColorPresetRepository
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,21 +4,21 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.core.data.ExtensionsData
|
import org.dueattendant149.bookshelf.core.data.ExtensionsData
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.mapper.file.FileMapper
|
import org.dueattendant149.bookshelf.data.mapper.file.FileMapper
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.parser.cover.CoverParser
|
import org.dueattendant149.bookshelf.data.parser.cover.CoverParser
|
||||||
import ua.acclorite.book_story.data.parser.file.FileParser
|
import org.dueattendant149.bookshelf.data.parser.file.FileParser
|
||||||
import ua.acclorite.book_story.domain.model.file.File
|
import org.dueattendant149.bookshelf.domain.model.file.File
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import ua.acclorite.book_story.domain.repository.FileSystemRepository
|
import org.dueattendant149.bookshelf.domain.repository.FileSystemRepository
|
||||||
import ua.acclorite.book_story.domain.service.FileProvider
|
import org.dueattendant149.bookshelf.domain.service.FileProvider
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,14 +4,14 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.data.local.room.BookDatabase
|
import org.dueattendant149.bookshelf.data.local.room.BookDatabase
|
||||||
import ua.acclorite.book_story.data.mapper.history.HistoryMapper
|
import org.dueattendant149.bookshelf.data.mapper.history.HistoryMapper
|
||||||
import ua.acclorite.book_story.domain.model.history.History
|
import org.dueattendant149.bookshelf.domain.model.history.History
|
||||||
import ua.acclorite.book_story.domain.repository.HistoryRepository
|
import org.dueattendant149.bookshelf.domain.repository.HistoryRepository
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,12 +4,12 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.repository
|
package org.dueattendant149.bookshelf.data.repository
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import androidx.core.net.toUri
|
import androidx.core.net.toUri
|
||||||
import ua.acclorite.book_story.domain.repository.PermissionRepository
|
import org.dueattendant149.bookshelf.domain.repository.PermissionRepository
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
import javax.inject.Singleton
|
import javax.inject.Singleton
|
||||||
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.service
|
package org.dueattendant149.bookshelf.data.service
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import android.graphics.Bitmap
|
import android.graphics.Bitmap
|
||||||
|
|
@ -13,8 +13,8 @@ import android.net.Uri
|
||||||
import androidx.core.net.toFile
|
import androidx.core.net.toFile
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.withContext
|
import kotlinx.coroutines.withContext
|
||||||
import ua.acclorite.book_story.core.CoverImage
|
import org.dueattendant149.bookshelf.core.CoverImage
|
||||||
import ua.acclorite.book_story.domain.service.CoverImageHandler
|
import org.dueattendant149.bookshelf.domain.service.CoverImageHandler
|
||||||
import java.io.BufferedOutputStream
|
import java.io.BufferedOutputStream
|
||||||
import java.io.ByteArrayOutputStream
|
import java.io.ByteArrayOutputStream
|
||||||
import java.io.File
|
import java.io.File
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.service
|
package org.dueattendant149.bookshelf.data.service
|
||||||
|
|
||||||
import android.app.Application
|
import android.app.Application
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFile
|
import org.dueattendant149.bookshelf.data.model.file.CachedFile
|
||||||
import ua.acclorite.book_story.data.model.file.CachedFileCompat
|
import org.dueattendant149.bookshelf.data.model.file.CachedFileCompat
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
import ua.acclorite.book_story.domain.service.FileProvider
|
import org.dueattendant149.bookshelf.domain.service.FileProvider
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
||||||
class FileProviderImpl @Inject constructor(
|
class FileProviderImpl @Inject constructor(
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
@file:Suppress("RemoveExplicitTypeArguments")
|
@file:Suppress("RemoveExplicitTypeArguments")
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.settings
|
package org.dueattendant149.bookshelf.data.settings
|
||||||
|
|
||||||
import androidx.datastore.preferences.core.Preferences
|
import androidx.datastore.preferences.core.Preferences
|
||||||
import androidx.datastore.preferences.core.booleanPreferencesKey
|
import androidx.datastore.preferences.core.booleanPreferencesKey
|
||||||
|
|
@ -21,30 +21,30 @@ import kotlinx.coroutines.flow.MutableStateFlow
|
||||||
import kotlinx.coroutines.flow.asStateFlow
|
import kotlinx.coroutines.flow.asStateFlow
|
||||||
import kotlinx.coroutines.flow.update
|
import kotlinx.coroutines.flow.update
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import ua.acclorite.book_story.core.data.CoreData
|
import org.dueattendant149.bookshelf.core.data.CoreData
|
||||||
import ua.acclorite.book_story.core.language.Language
|
import org.dueattendant149.bookshelf.core.language.Language
|
||||||
import ua.acclorite.book_story.core.language.LanguageUtils
|
import org.dueattendant149.bookshelf.core.language.LanguageUtils
|
||||||
import ua.acclorite.book_story.core.log.logI
|
import org.dueattendant149.bookshelf.core.log.logI
|
||||||
import ua.acclorite.book_story.data.local.data_store.DataStore
|
import org.dueattendant149.bookshelf.data.local.data_store.DataStore
|
||||||
import ua.acclorite.book_story.data.settings.model.Setting
|
import org.dueattendant149.bookshelf.data.settings.model.Setting
|
||||||
import ua.acclorite.book_story.presentation.browse.model.BrowseLayout
|
import org.dueattendant149.bookshelf.presentation.browse.model.BrowseLayout
|
||||||
import ua.acclorite.book_story.presentation.browse.model.BrowseSortOrder
|
import org.dueattendant149.bookshelf.presentation.browse.model.BrowseSortOrder
|
||||||
import ua.acclorite.book_story.presentation.library.model.LibraryLayout
|
import org.dueattendant149.bookshelf.presentation.library.model.LibraryLayout
|
||||||
import ua.acclorite.book_story.presentation.library.model.LibrarySortOrder
|
import org.dueattendant149.bookshelf.presentation.library.model.LibrarySortOrder
|
||||||
import ua.acclorite.book_story.presentation.library.model.LibraryTitlePosition
|
import org.dueattendant149.bookshelf.presentation.library.model.LibraryTitlePosition
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderColorEffects
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderColorEffects
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderFontThickness
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderFontThickness
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderHorizontalGesture
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderHorizontalGesture
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderProgressCount
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderProgressCount
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderScreenOrientation
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderScreenOrientation
|
||||||
import ua.acclorite.book_story.presentation.reader.model.ReaderTextAlignment
|
import org.dueattendant149.bookshelf.presentation.reader.model.ReaderTextAlignment
|
||||||
import ua.acclorite.book_story.ui.reader.data.ReaderData
|
import org.dueattendant149.bookshelf.ui.reader.data.ReaderData
|
||||||
import ua.acclorite.book_story.ui.reader.model.FontWithName
|
import org.dueattendant149.bookshelf.ui.reader.model.FontWithName
|
||||||
import ua.acclorite.book_story.ui.theme.model.DarkTheme
|
import org.dueattendant149.bookshelf.ui.theme.model.DarkTheme
|
||||||
import ua.acclorite.book_story.ui.theme.model.HorizontalAlignment
|
import org.dueattendant149.bookshelf.ui.theme.model.HorizontalAlignment
|
||||||
import ua.acclorite.book_story.ui.theme.model.PureDark
|
import org.dueattendant149.bookshelf.ui.theme.model.PureDark
|
||||||
import ua.acclorite.book_story.ui.theme.model.Theme
|
import org.dueattendant149.bookshelf.ui.theme.model.Theme
|
||||||
import ua.acclorite.book_story.ui.theme.model.ThemeContrast
|
import org.dueattendant149.bookshelf.ui.theme.model.ThemeContrast
|
||||||
import java.util.Locale
|
import java.util.Locale
|
||||||
import java.util.concurrent.atomic.AtomicInteger
|
import java.util.concurrent.atomic.AtomicInteger
|
||||||
import javax.inject.Inject
|
import javax.inject.Inject
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.data.settings.model
|
package org.dueattendant149.bookshelf.data.settings.model
|
||||||
|
|
||||||
import androidx.compose.runtime.Composable
|
import androidx.compose.runtime.Composable
|
||||||
import androidx.compose.runtime.Stable
|
import androidx.compose.runtime.Stable
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.domain.model.file
|
package org.dueattendant149.bookshelf.domain.model.file
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
|
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.domain.model.history
|
package org.dueattendant149.bookshelf.domain.model.history
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
import ua.acclorite.book_story.domain.model.library.Book
|
import org.dueattendant149.bookshelf.domain.model.library.Book
|
||||||
|
|
||||||
@Immutable
|
@Immutable
|
||||||
data class History(
|
data class History(
|
||||||
|
|
@ -4,13 +4,13 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.domain.model.library
|
package org.dueattendant149.bookshelf.domain.model.library
|
||||||
|
|
||||||
import android.net.Uri
|
import android.net.Uri
|
||||||
import android.os.Parcelable
|
import android.os.Parcelable
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
import kotlinx.parcelize.Parcelize
|
import kotlinx.parcelize.Parcelize
|
||||||
import ua.acclorite.book_story.core.ui.UIText
|
import org.dueattendant149.bookshelf.core.ui.UIText
|
||||||
|
|
||||||
@Parcelize
|
@Parcelize
|
||||||
@Immutable
|
@Immutable
|
||||||
|
|
@ -4,10 +4,10 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.domain.model.library
|
package org.dueattendant149.bookshelf.domain.model.library
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
import ua.acclorite.book_story.presentation.library.model.LibrarySortOrder
|
import org.dueattendant149.bookshelf.presentation.library.model.LibrarySortOrder
|
||||||
|
|
||||||
@Immutable
|
@Immutable
|
||||||
data class Category(
|
data class Category(
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
* SPDX-License-Identifier: GPL-3.0-only
|
* SPDX-License-Identifier: GPL-3.0-only
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package ua.acclorite.book_story.domain.model.reader
|
package org.dueattendant149.bookshelf.domain.model.reader
|
||||||
|
|
||||||
import androidx.compose.runtime.Immutable
|
import androidx.compose.runtime.Immutable
|
||||||
import androidx.compose.ui.graphics.Color
|
import androidx.compose.ui.graphics.Color
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue