Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion plugins/SFWSwitch/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ https://discourse.stashapp.cc/t/sfw-switch/4658
- Gray = Blur disabled
- Toggling the button blurs cover images and other content.
- Hovering over an image temporarily removes the blur.
- Extends the blurring functionality to some community plugins.
- Custom selectors should should be added to `additional_plugins.css` file.

## Screenshots

Expand All @@ -17,4 +19,4 @@ https://discourse.stashapp.cc/t/sfw-switch/4658
## Credit
Original plugin by Belleyy [here](https://github.com/Belleyy/CommunityScripts/tree/pluginUI_SFWSwitch/plugins/SFW%20Switch).

The CSS code used is provided by fl0w#9497 [here](https://discourse.stashapp.cc/t/custom-css-snippets/4043#p-8143-blur-nsfw-images-and-unblur-on-mouse-over-41).
The CSS code used is provided by fl0w#9497 [here](https://discourse.stashapp.cc/t/custom-css-snippets/4043#p-8143-blur-nsfw-images-and-unblur-on-mouse-over-41).
65 changes: 65 additions & 0 deletions plugins/SFWSwitch/additional_plugins.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
/* [Global changes] Blur NSFW images and unblur on mouse over */

/*Credit: fl0w#9497 */

/* === MORE BLUR === */

/* Stash Battle */
.pwr-scene-image-container,
.pwr-scene-image-container,
.pwr-hover-preview,
.pwr-scene-image-container .pwr-scene-image,

/* HotOrNot */
.hon-performer-image,
.hon-scene-image,
.hon-image-image-container,
.hon-image-image,

/* O Stats */
.custom-stats-row .stats-element img,
#on-this-day-section [style*="position: relative; height: 400px"]
{
filter: blur(30px);
}

/* === LESS BLUR === */

/* StashBattle */
.pwr-scene-info,

/* HotOrNot */
.hon-performer-info.hon-scene-info,

/* O Stats */
.custom-stats-row .stats-element,
#on-this-day-section [style*="display: flex"][style*="cursor: pointer"] img,
#on-this-day-section [style*="display: flex"][style*="cursor: pointer"] img + div,
#on-this-day-section > div:last-child
{
filter: blur(2px);
}

/* StashBattle */
.pwr-scene-image-container:hover,
.pwr-scene-image-container:hover .pwr-hover-preview,
.pwr-scene-image-container:hover .pwr-scene-image,
.pwr-scene-info:hover,

/* HotOrNot */
.hon-performer-image:hover,
.hon-scene-image:hover,
.hon-image-image-container:hover,
.hon-image-image:hover,
.hon-performer-info.hon-scene-info:hover,

/* O Stats */
.custom-stats-row .stats-element:hover,
.custom-stats-row .stats-element:hover img,
#on-this-day-section [style*="display: flex"][style*="cursor: pointer"]:hover img,
#on-this-day-section [style*="display: flex"][style*="cursor: pointer"]:hover img + div,
#on-this-day-section > div:last-child:hover,
#on-this-day-section [style*="position: relative; height: 400px"]:hover
{
filter: blur(0px);
}
22 changes: 20 additions & 2 deletions plugins/SFWSwitch/sfw.css
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/*Credit: fl0w#9497 */

/* === MORE BLUR === */

/* scene */
.scene-card-preview,
.vjs-poster,
Expand Down Expand Up @@ -34,11 +35,13 @@ img.performer,
/* tag */
.tag-card-image


{
filter: blur(30px);
}

/* === LESS BLUR === */

/* common */
.card-section-title,

Expand All @@ -48,6 +51,7 @@ filter: blur(30px);
h3.scene-header,
.studio-logo,
.image-thumbnail,
.TruncatedText.scene-card__description,

/* image */
h3.image-header,
Expand All @@ -57,20 +61,26 @@ h3.image-header,

/* gallery */
h3.gallery-header,
.TruncatedText.gallery-card__description,

/* studio */
.studio-details .logo,
.studio-details > div > h2,
.studio-card__details,
.studio-parent-studios,

/* tag */
.logo-container > .logo,
.logo-container > h2
.logo-container > h2,
.TruncatedText.tag-description,
.tag-parent-tags

{
filter: blur(2px);
}

/* === UNBLUR ON HOVER === */

/* common */
.thumbnail-section:hover *,
.card:hover .card-section-title,
Expand All @@ -87,6 +97,7 @@ div:hover > .scene-header,
.scene-card-preview:hover,
.scrubber-item:hover,
.scene-image:hover,
.TruncatedText.scene-card__description:hover,

/* image */
.image-image:hover,
Expand All @@ -100,17 +111,24 @@ div:hover > .image-header,
/* gallery */
div:hover > .gallery-header,
table > tbody > tr > td:hover > a > img.w-100,
.TruncatedText.gallery-card__description:hover,

/* performer */
img.performer:hover,

/* studio */
.studio-details .logo:hover,
.studio-details:hover > div > h2,
.studio-card__details:hover,
.studio-parent-studios:hover,


/* tag */
.logo-container > .logo:hover,
.logo-container:hover > h2
.logo-container:hover > h2,
.TruncatedText.tag-description:hover,
.tag-parent-tags:hover

{
filter: blur(0px);
}
5 changes: 3 additions & 2 deletions plugins/SFWSwitch/sfwswitch.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
name: SFW Switch
description: Add a button to blur covers and images.
version: 1.3
version: 1.4
url: https://discourse.stashapp.cc/t/sfw-switch/4658
ui:
javascript:
- sfw.js
css:
- sfw.css
- sfw.css
- additional_plugins.css