SFW Switch

SFW Switch

Features

  • Adds a SFW toggle button to the menu bar.
    • Green = Blur enabled
    • Gray = Blur disabled
  • Toggling the button blurs cover images and other content.
  • Hovering over an image temporarily removes the blur.
  • Optional toggle to also mute audio from scenes.
  • Extends the blurring functionality to some community plugins.
    • Custom selectors should be added to additional_plugins.css file.

Screenshots

image

Credit

  • Original plugin by Belleyy here.
  • Some CSS code used is from here.
2 Likes

Good Idea.

Also, I know it’s just the name of the plugin but it amuses me to no end to think that there are actual dudes who browse their Stash at work. :rofl:

2 Likes

I really like this plugin. Is it possible to add blurs to the thumbnails that are automatically displayed during the scraping process in Tagger view?

1 Like

I submitted a change for this.

1 Like

Nice idea, i do like to develop stuff for stash, and i dont neccecarily want to view anything :stuck_out_tongue:

The last time I tried this plugin, it doesn’t preserve state across tabs or even when navigating between pages. Has this been fixed? IMO it should use the browser’s persistent storage to remember the state (bonus points if it can reset during logout/login). Configuring the default state in settings would also be good to have.

2 Likes

I actually have a note to add this feature but wasn’t sure if the original dev had this in mind. Its incredibly inconvenient to visit plugins to disable it. Ill see what I can come up with.

Hey man I created a pull request that adds this functionality. I have it working locally and it does what you asked. Just waiting on a merge.

2 Likes

Nice work! I’m not sure if there’s an easy way to observe local storage. That way changes in one tab get immediately reflected in other tabs. But this is already a major improvement.

1 Like

It works across tabs per my tests

Edit: but you’ll need to refresh the page for change to take place. It is not real time in that sense.

Yeah, that’s what I expected looking at the code (I’m an Android dev by trade, but not super familiar with web/js stuff).

Ah ok. If someone wants to implement that then more power to them im less motivated as my core issue with the plugin has been resolved as I feel like it now functions as it should.


Added support for Hot or Not and Stash Battle

Come to think about it maybe I should do the text to. If this gets approved I’ll add that this weekend.

New PR featuring better additional plugin support for public\private contribution. Patched additional fields previously not censored.
Now works with hot or not, stash battle, and O stats (by sanjiswe)

Some screens



Submitted a new PR for audio handling. Scenes will now be muted and continue to be muted unless volume is manually toggled or SFW switch is turned off. This feature extends to the Stash Battle plugin. I have also added additional plugin support for the Sprite Tab plugin.

No issues in test environment, works without issue.

Edit:

Updated Yaml description, made the main CSS prettier, accounted for more missed default fields I missed last commit. Everything continues to work as it should. Also corrected a weird bug with the favorite icon on the tags window. Can i get a merge @DogmaDragon ?

Edit 2: Made audio option a boolean value in settings for toggle. Users can either use the plugin with or without audio mute feature.

For Wall view in Images and Galleries, and for performers in Tagger mode, SFW blur is not applied.

Somehow in Wall mode if some scene does not have preview video generated and therefore displays the default cover, then the blur is not applied.

Similarly, in List mode, the blur is not enough! It is very clear that things are NSFW.

And can we have a config to not unblur on hover?

List mode should be easy, good catch on the default cover. I actually just added the functionality for galleries.

I have held off on adding the wall view to the SFW plugin because last time I had issues with the light box. You will also notice light box is not included in the plugin.

I actually dont use the tagger function so that was easily missed. Maybe not to difficult to implement.

Why? What is the use case here? Have you seen what this plugin does blur? Removing unblur as an option would make it unusable. At that point just close the page.

Regardless. Im waiting on a merge before I continue. Current version has enough commits as is.

1 Like

@l34240013
I just dropped a pretty massive patch that is waiting on a merge. Has everything you asked for with improvements. But I did not do tagger mode as I do not have that feature enabled so I cant really test it.

Waiting on a merge

ping @DogmaDragon