FrostCo / AdvancedProfanityFilter

A browser extension to filter profanity from webpages
GNU General Public License v3.0
163 stars 26 forks source link

Audio Muting Site Request: Podscribe #457

Open richardfrost opened 1 year ago

richardfrost commented 1 year ago

:movie_camera: The Site

app.podscribe.ai

:speech_balloon: Subtitle Element/Node

Example:

<span data-slate-node="text">
  <span data-slate-leaf="true" class="jss110 jss113" style="border-radius: 4px; background-color: rgba(0, 255, 55, 0.8);">
    <span data-slate-string="true">Welcome </span>
  </span>
</span>

:pencil: Additional notes

This site has transcripts of podcasts. Although these aren't videos and captions, it would still be useful for listening.

richardfrost commented 1 year ago

This isn't finished yet, but I do think I got something working that we can build from. To test it, follow these steps:

  1. Add this custom audio config:
    {
      "app.podscribe.ai": [
        {
          "mode": "watcher",
          "videoSelector": "audio",
          "subtitleSelector": "div#transcriptContainerContainer span[data-slate-node='text'] span[style*='background-color:']",
          "filterSubtitles": false
        }
      ]
    }
    • To use this config, paste it into the Custom Sites area (Options page > Audio tab) and click the blue "SAVE" button underneath it. Then, make sure to refresh the tab for the video site (if you have it open still) and it will load this new configuration.
  2. Change the filter method to "Off". This will prevent the filter from filtering text everywhere, so just be aware that you may want to turn it back on when not using the filter with Podscribe. It needs to be there right now to stop it from filtering the transcript text. It can be changed in the popup (click on the extension icon) or in the main options page.

If you get a chance to test it I'd love to hear feedback on it.