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

Find a way to pass css into url web views #1335

Open
Sebastian-ubs opened this issue Nov 22, 2024 · 2 comments
Open

Find a way to pass css into url web views #1335

Sebastian-ubs opened this issue Nov 22, 2024 · 2 comments
Labels
enhancement New feature or request ux UX design needed

Comments

@Sebastian-ubs
Copy link
Contributor

User Story
As an extension developer, I want to pass custom css to a url web view so that I can only show the relevant information and hide other parts (e.g. headers, footers, ...).

Description
Be able to pass in css to customize a website that is shown in a tab, so that it fits into the available space and does not show superfluous ui elements.
See example

Implementation idea
It seems rather not likely based on the technical restrictions of an iframe (or need to use a CORS header, which not every public website out there would have), but maybe there still is a way...

Testing ideas

@Sebastian-ubs Sebastian-ubs added enhancement New feature or request ux UX design needed labels Nov 22, 2024
@Sebastian-ubs
Copy link
Contributor Author

according to the electron docs, web views allow some more control than iframes (but should not be used for they are not officially supported and my change without notice 🤔)

@Sebastian-ubs
Copy link
Contributor Author

Sebastian-ubs commented Dec 9, 2024

There seem to be ways to pass in js into arbitrary webviews so that adding css would be possible (as well as extracting the current url, which supports scrolling with a reference selected on a website that changes their url accordingly, see step 3 of https://github.com/paranext/roadmap/issues/87)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request ux UX design needed
Projects
Status: No status
Development

No branches or pull requests

1 participant