Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

E-Book support #35

Open
gh0sti opened this issue Jan 30, 2024 · 14 comments
Open

E-Book support #35

gh0sti opened this issue Jan 30, 2024 · 14 comments

Comments

@gh0sti
Copy link

gh0sti commented Jan 30, 2024

image

Was looking at my comic/ebook library and noticed that it has play clock time and probably needs to be logically looked at how to present and manage ebooks and comics. Are you looking to do something like komga to stream pages to the client?

@gh0sti
Copy link
Author

gh0sti commented Jan 30, 2024

I would maybe make this a feature dev flag to disable for the time being if ebooks and comics aren't going to be supported for the time being.

@rasmuslos
Copy link
Owner

I would wait until ebooks / comics are fully supported in ABS until I consider implementing them. But I am not sure if they will ever be supported, because I would consider them out of scope for an app primarily aimed at playing audio

@gh0sti
Copy link
Author

gh0sti commented Feb 3, 2024

I would wait until ebooks / comics are fully supported in ABS until I consider implementing them. But I am not sure if they will ever be supported, because I would consider them out of scope for an app primarily aimed at playing audio

They actually are supported on ABS

"Basic ebook support and ereader
Epub, pdf, cbr, cbz
Send ebook to device (i.e. Kindle)"

https://github.com/advplyr/audiobookshelf?tab=readme-ov-file#about

@rasmuslos rasmuslos changed the title [Enhancement] look at how to handle/manage ebooks/comics in GUI E-Book support Feb 6, 2024
@rasmuslos
Copy link
Owner

Well as far as I can tell there is an API endpoint to get the pub / pdf / ... file, but not much more. This is very likely to change and become a more fully fledged solution.

I will reopen this to have something to go back to, but not until the ebook support is more than just basic

@rasmuslos rasmuslos reopened this Feb 6, 2024
@lkjfdsaofmc
Copy link

If possible when EBook support is looked at again, it would be nice to have a feature to simply download the ebook file (such as epub) directly in the app in a way that allows you to then share it out the same as if you access ABS via a web browser on your phone. This feature allows you to share it to something such as a kindle e-reader which would be a more convenient method for loading my ebooks to an e-reader than through my computer or phones web browser.

@rasmuslos
Copy link
Owner

If possible when EBook support is looked at again, it would be nice to have a feature to simply download the ebook file (such as epub) directly in the app in a way that allows you to then share it out the same as if you access ABS via a web browser on your phone. This feature allows you to share it to something such as a kindle e-reader which would be a more convenient method for loading my ebooks to an e-reader than through my computer or phones web browser.

This would actually be a good (temporary) solution. I have looked at some other apps like Smart Comic Reader and looked for some libraries to handle the actual comic rendering and it seems like it would have to reinvent the wheel for this to work natively in ShelfPlayer. But I am pretty sure there is no way to sync progress back to ShelfPlayer...

@gh0sti
Copy link
Author

gh0sti commented Mar 28, 2024

If possible when EBook support is looked at again, it would be nice to have a feature to simply download the ebook file (such as epub) directly in the app in a way that allows you to then share it out the same as if you access ABS via a web browser on your phone. This feature allows you to share it to something such as a kindle e-reader which would be a more convenient method for loading my ebooks to an e-reader than through my computer or phones web browser.

This would actually be a good (temporary) solution. I have looked at some other apps like Smart Comic Reader and looked for some libraries to handle the actual comic rendering and it seems like it would have to reinvent the wheel for this to work natively in ShelfPlayer. But I am pretty sure there is no way to sync progress back to ShelfPlayer...

Looking at the current commits in ABS server and app they added comic book support.

advplyr/audiobookshelf-app@9b67037
advplyr/audiobookshelf-app@9b67037

@rasmuslos
Copy link
Owner

Can a e-book exist without an audiobook?

@rasmuslos
Copy link
Owner

Also putting this here for future reference: https://developer.apple.com/documentation/uikit/uidocumentinteractioncontroller

@lkjfdsaofmc
Copy link

An e-book can exist in ABS without an audiobook, but ABS doesn't read much of the metadata from the epub files beyond title. My work-around thus far has been to create a 1 second blank audio file to hold the metadata for the e-book and keep that with the epub so ABS thinks there's an audiobook, but if you used online matching/metadata sources (which I have turned off completely) it would probably be fine having epub's alone.

@rasmuslos
Copy link
Owner

To give you some context why this takes so long: to use the document interaction controller and present a menu you have to specify the bounds and a view, but both are UIKit components. The app is written in SwiftUI, so I have to create an UIViewRepresentable, but I don't really know how this works and how to get the bounds.

@danielraffel
Copy link

It looks like epub support is enabled in the official client apps. Are there plans to add support soon?

https://github.com/advplyr/audiobookshelf-app

For now, I've disabled indexing non-audio files since they don't render nicely in this client (I get a play icon which shouldn't appear.) Thanks for making a nice, clean app!

rasmuslos added a commit that referenced this issue Apr 26, 2024
@rasmuslos
Copy link
Owner

For now ebooks will be filtered, so they don't show up in your library. I check the numAudioFiles property for this, not ideal, but it should work until I find a better way to do this. The problem is that audiobooks and ebooks are virtually the same thing in ABS, but in ShelfPlayer they will most likely be their own thing.

@rasmuslos
Copy link
Owner

This API should allow ShelfPlayer to export documents

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants