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

per site option to hide specific element(s) #1635

Open
jadedgnome opened this issue Dec 2, 2024 · 2 comments
Open

per site option to hide specific element(s) #1635

jadedgnome opened this issue Dec 2, 2024 · 2 comments

Comments

@jadedgnome
Copy link

jadedgnome commented Dec 2, 2024

I often use the SingleFile extension to save webpages, but sometimes I need to hide or remove certain elements (such as sensitive data, advertisements, or other nuisance elements) before saving. Currently, I need to rely on another extension to delete or hide these elements, which can be a bit cumbersome. It would be fantastic if SingleFile could include a per-site option that allows users to specify elements to hide or remove before saving the page. incorporating regex support would be cool too.

Proposed Feature:

A setting in SingleFile where users can define specific elements (using CSS selectors) to be hidden or removed before the page is saved.
This feature could be configured per site to allow different settings for different websites.
A simple UI to add/remove/edit the selectors for each site, or an option to use the browser’s built-in developer tools to pick the elements directly.

Use Case:
This feature would allow users to:

Hide or remove sensitive information (such as personal data or login details).
Avoid saving unnecessary elements like pop-ups, banners, or ads.
Have a more seamless experience without needing to use an additional add-on or manually remove elements.

Additional Considerations:

It would be useful if the configuration could be as simple as a list of CSS selectors for each site that need to be hidden or deleted.
An option to reset the configuration for a site or disable the feature entirely.
@jadedgnome jadedgnome changed the title per site option to hide specified element(s) per site option to hide specific element(s) Dec 2, 2024
@gildas-lormeau
Copy link
Owner

I agree it could be useful. Out of curiosity, have you tried using a user-script to do this? See https://github.com/gildas-lormeau/SingleFile/wiki/How-to-execute-a-user-script-before-a-page-is-saved

@jadedgnome
Copy link
Author

i didn't know about 😮 , i'll try to see if i can get it to work for me. thanks!

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

No branches or pull requests

2 participants