AdguardTeam / AdguardTeam/Scriptlets

Add new scriptlet — 'trusted-add-class'

Open
#430 4 comments 0 reactions 0 assignees View on GitHub
Feature request Priority: P5
Dominant language
JavaScript
Stars
195
Forks
33
PR merge metrics
No merged PRs in 30d

Description

The `trusted-add-class` would provide an opportunity to add any class name to an element. For example, sometimes it happens that a script checks the body class list.
```
example.com#%#//scriptlet('trusted-add-class', selector, classNames[, applying])
```
where
- `classNames` can be a single class or multiple classes separated by commas, e.g. `foo` or `foo,bar`
- `applying` can be `asap`, `complete` and `stay` like in [remove-attr](https://github.com/AdguardTeam/Scriptlets/blob/master/wiki/about-scriptlets.md#-%EF%B8%8F-remove-attr)

- - -

Can be used on:
* myonlineradio.hu - bypass antiadblock.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.