lnreader icon indicating copy to clipboard operation
lnreader copied to clipboard

Plugin Specific CSS

Open Batorian opened this issue 1 year ago • 12 comments

Describe your suggested feature

Currently all CSS is set through the app, which makes it difficult to add CSS which is needed for the chapter text from certain plugins to be displayed correctly. The idea is to introduce separate CSS files for each plugin to enable a more dynamic work environment.

Other details

No response

Acknowledgements

  • [X] I have searched the existing issues and this is a new ticket, NOT a duplicate or related to another open or closed issue.
  • [X] I have written a short but informative title.
  • [X] If this is an issue with a source, I should be opening an issue in the sources repository.
  • [X] I have updated the app to version 2.0.0.
  • [X] I will fill out all of the requested information in this form.

Batorian avatar May 29 '24 07:05 Batorian

Yes a major part of the novel I was reading was missing due to this. (Source: Genesis TL)

1-minute-to-midnight avatar May 30 '24 08:05 1-minute-to-midnight

Yes a major part of the novel I was reading was missing due to this. (Source: Genesis TL)

Hey, I'd like you to use my LNReaderTesting if you want. Genisis TL is one of the plugins which should be fixed in my version. I'd appreciate feedback and any missing CSS you encounter.

Batorian avatar May 30 '24 09:05 Batorian

I tried it out and I can't see the CSS elements. (I tried version 1.0.6 of the extension). The novel I tested on is named "The Main Heroines are Trying to Kill me". Chapter 3 (under "System, show clear privilege"). This is a very good novel to test on as this has a lot of custom CSS elements.

1-minute-to-midnight avatar May 30 '24 09:05 1-minute-to-midnight

I tried it out and I can't see the CSS elements. (I tried version 1.0.6 of the extension). The novel I tested on is named "The Main Heroines are Trying to Kill me". Chapter 3 (under "System, show clear privilege"). This is a very good novel to test on as this has a lot of custom CSS elements.

Could you try the same novel and same chapter but under Novel Updates? I think I need to change some stuff in the Genesis TL plugin to make it work directly.

Batorian avatar May 30 '24 09:05 Batorian

Since this will loose the sanitization, will it allow specific classes or all of them?

Palloxin avatar May 30 '24 10:05 Palloxin

@Batorian Some of them come through in plain text but others remain missing in Novel Updates.

Edit: I checked again and it seems to be working fine now.

1-minute-to-midnight avatar May 30 '24 10:05 1-minute-to-midnight

Since this will loose the sanitization, will it allow specific classes or all of them?

The plan is to have it only accept specific classes and their styles right now.

Batorian avatar May 30 '24 10:05 Batorian

Yeah some elements are still missing in Genesis TL.

1-minute-to-midnight avatar Jul 04 '24 17:07 1-minute-to-midnight

Yeah some elements are still missing in Genesis TL.

If you see missing elements, could you press F12 and tell me the class name of the element?

Batorian avatar Jul 05 '24 07:07 Batorian

Here you go: <div class="game-prompt-gold-info-title ta-center">「Traits」</div>

For reference, this is in a novel called "The Villain Who Robbed the Heroines" Chapter 2

1-minute-to-midnight avatar Jul 05 '24 07:07 1-minute-to-midnight

Here you go: <div class="game-prompt-gold-info-title ta-center">「Traits」</div>

For reference, this is in a novel called "The Villain Who Robbed the Heroines" Chapter 2

Screenshot_20240705-095709

Are you really using my app?

Batorian avatar Jul 05 '24 07:07 Batorian

I haven't gotten the latest update yet

is there a new release?

1-minute-to-midnight avatar Jul 05 '24 07:07 1-minute-to-midnight

Is this done with Plugin custom js/css feature?

nyagami avatar Jul 16 '24 08:07 nyagami

Is this done with Plugin custom js/css feature?

Yeah, it is.

Batorian avatar Jul 16 '24 09:07 Batorian

Complete in https://github.com/LNReader/lnreader/commit/867b63af2241e0abb56dab89975441a648f2dde8

nyagami avatar Jul 17 '24 02:07 nyagami