-
Notifications
You must be signed in to change notification settings - Fork 95
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
[Tutorial/Workflow] Firefox Devtools in Zotero #32
Comments
Holy crap! That's amazing! We can take the theme to the next level now. |
Thank you very much for your kind words. The issue concerning the styling of the PDF reader/viewer (both terms are used ambigously in the code base for some reason) might also apply to the new(er) note editor. The code of both components is developed in reposititories exclusive to each of them. Same (seems) to apply to the way how there treated in Zotero at runtime. From a cyber sec point of view this sounds reasonable to me. It's a lot of JavaScript after all. Think XSS leading to access to the file system, etc. However I'd like to highlight that I lack the knowledge required to express a qualified comment on this. English is unfortunately not my mother tongue so I might end up putting my thoughts in false leading terms. I'd be very grateful if someone of the Zotero maintainers or dev community could step in to give some insights on the following questions:
|
I'd like to extend my first comment on top. (I'll stick to the abbreviation 'devtools' for 'developer tools' in the following.) For legal reasons I'd like to highlight that when proceeding you act on your risk. Possible damages or losses caused to you personally or anyone else by following this tutorial or using legacy software in general might occur. As noted above I'm not a qualified IT professional or a lawyer but an average daily user of Zotero. Concerning the init and prep of the remote debugging session: First of all when reading the following links do not forget that Firefox and Mozilla both moved on and changed significantly since the release of version 60. So many statements in the docs are not (fully) applicable to the described setup. Witch heavly relies on legacy software components. I'd like to emphasize that I highly encourage the reader to not used multiple machines for the following but instead run everything on the same PC. If you prefer to take the risk you should search for devtools.debugger.force-local in the Zotero config later on. Disconnecting from the internet before using an aged browser might also be a good idea if your not prepared to take risks. I highly recommend to make Firefox' top-left menu bar visible (by checking in the section for modifing the 'appearance' of Firefox) if not already done. This is not mandatory but it should ease the following steps.
|
Short update: the note editor runs in an |
Thanks man, this really helped me! I did figure out a way to style the pdf/viewer, you need to do some JS, see https://github.com/ThomasFKJorna/zotero-night |
Interesting. I wonder if certain Firefox extensions could be adapted for zotero. |
How does one install your theme to test it? |
Ah I haven't really set up proper CD, gimme a sec |
Otherwise you need to install it as a dev which is honestly a pain in the ass |
Ooof, I won't be able to do anything like what you did. That looks awesome by the way. |
You can try it out now! See https://github.com/ThomasFKJorna/zotero-night/releases Still slightly jank but less so |
If anyone here wants to help out cssing/create more themes/test drive I'd love your help! :) |
That looks awesome!
How did you theme the PDF reader and note editor? Was it javascript? |
Thank you so much for the kind words, really appreciate them and the work you already put into the CSS file! Good points, I am on a Mac so I don't see the Menubar on the window, but I should add that. The tags is something I still need to fix, I don't use them that much myself so I hadn't noticed them yet haha. And yes, you do need to use javascript in order to theme the PDF reader. They are in separate I think I just removed the border by doing Ideally I'd like zotero-night to kind of turn into a theming platform for Zotero as it has very little support for it atm, so if you have any suggestions for what you think would be a good way to use such a platform (e.g. would just being able to change colors enough, or loading custom css, or injecting custom js at specific places?) let me know! There's lots of other things I'd like to be able to change about the look of Zotero, not all of which are probably possible. If you have any other suggestions lemme know! I'm just trying stuff haha |
Also being able to change the scrollbars would be sick but that does not seem possible in the old version of firefox that Zotero is using (only 8 versions later and we could have 😭). Custom scrollbars could probably be done with some custom JS, but I'm not sure if that is doable without manually targeting every single scrollable object, which seems a bit much haha |
On which parameter? .tabs? .tab? That doesn't seem to work on my end. :(
I think what you did is already great. I would love to see alternative color themes. :) |
Ah I see it's just the * {
border: 0 !important
} that I took from your file! Otherwise look into Otherwise I'm not sure which border you are referring to! |
Hi @Rosmaninho
first of all 👍 for compiling and maintaining these informations.
I figured how to use the Firefox devtools (DOM tree Inspector, Network requests, ...) in Zotero and thought it might be helpful for someone else:
(The following applies to Windows 10) -> Edit: please do see my comment below before proceeding
about:config
(preferences -> advanced) in Zotero for the keyword 'devtools' to prepare remote debuggingI'd like to highlight that I was not able to style the PDF reader (pdf.js) CSS styles seem to be dynamically inserted using JavaScript within the Zotero GUI (-> react app). However I could style everything else (e.g. window actions menu -> File, Edit, View, ...).
I'm happy to help with questions concering the workflow above. Hope this might be helpful to anyone. I had quite a hard time figuring this out. Unfortunately there's very little information on this so far.
Regards, Alex
The text was updated successfully, but these errors were encountered: