diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..674d1eee --- /dev/null +++ b/.editorconfig @@ -0,0 +1,17 @@ +# VS Code user, install: https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig +# Sublime Text user, install: https://github.com/sindresorhus/editorconfig-sublime#readme +# See https://editorconfig.org/ for more information. + +# top-most EditorConfig file +root = true + +# Unix-style newlines with a newline ending every file +[*] +charset = utf-8 +end_of_line = lf +indent_style = space +insert_final_newline = true + +[*.md] +indent_size = 2 +trim_trailing_whitespace = false diff --git a/docs/CODE_STYLE.md b/docs/CODE_STYLE.md index bd38fa30..5e909bbb 100644 --- a/docs/CODE_STYLE.md +++ b/docs/CODE_STYLE.md @@ -1,8 +1,11 @@ ### Code style: + - [Standard JS](https://standardjs.com/rules.html) + [Prettier](https://prettier.io/) - Unix EOL (LF) - Newline at end of file ### How to set this up on VScode/Codium: -- Extension: [VSCode marketplace](https://marketplace.visualstudio.com/items?itemName=numso.prettier-standard-vscode) -- Newline at end of file: [stackoverflow.com/a/44704969](https://stackoverflow.com/a/44704969) + +Install these extensions: +- [EditorConfig for VS Code](https://marketplace.visualstudio.com/items?itemName=EditorConfig.EditorConfig "See on Visual Studio Code Marketplace") +- [Prettier-Standard - JavaScript formatter](https://marketplace.visualstudio.com/items?itemName=numso.prettier-standard-vscode "See on Visual Studio Code Marketplace") diff --git a/src/bypasses/link1s.js b/src/bypasses/link1s.js new file mode 100644 index 00000000..b010df01 --- /dev/null +++ b/src/bypasses/link1s.js @@ -0,0 +1,35 @@ +import BypassDefinition from './BypassDefinition.js' + +export default class Link1s extends BypassDefinition { + constructor () { + super() + } + execute () { + switch (window.location.hostname) { + case 'anhdep24.com': + this.helpers.watchForElement('.footer', () => + clearInterval(window.counter) // skip timer + ) + this.helpers.watchForElement('#link1s[href]', a => + this.helpers.safelyNavigate(a.href) // step 1 & 3 + ) + this.helpers.watchForElement('#link1s-snp', () => window.link1sgo()) // step 2 & 4 + break + case 'link1s.com': + this.helpers.ensureDomLoaded(() => { + // skip all shit + window.app_vars.counter_value = 0 + window.app_vars.enable_captcha = 'no' + window.app_vars.force_disable_adblock = '0' + }) + this.helpers.watchForElement('.skip-ad a.btn', a => { + setInterval(() => { + this.helpers.safelyNavigate(a.href) + }, 10) // wait for a moment for url to be updated + }) + break + } + } +} + +export const matches = ['link1s.com', 'anhdep24.com'] diff --git a/src/bypasses/lootlinks.js b/src/bypasses/lootlinks.js new file mode 100644 index 00000000..0a1808c5 --- /dev/null +++ b/src/bypasses/lootlinks.js @@ -0,0 +1,13 @@ +import BypassDefinition from './BypassDefinition.js' + +export default class Lootlinks extends BypassDefinition { + constructor () { + super() + this.ensure_dom = true + } + execute () { + this.helpers.safelyNavigate(p['PUBLISHER_LINK']) // ignore the error + } +} + +export const matches = ['loot-links.com'] diff --git a/src/bypasses/shst.js b/src/bypasses/shst.js new file mode 100644 index 00000000..39e81890 --- /dev/null +++ b/src/bypasses/shst.js @@ -0,0 +1,19 @@ +import BypassDefinition from './BypassDefinition.js' + +export default class Shst extends BypassDefinition { + constructor () { + super() + } + execute () { + this.helpers.watchForElement('#timer', () => { + window.app.options.intermediate.timerPageVisibilityChecking = false + window.app.options.intermediate.displayCaptcha = false + window.app.options.intermediate.timeToWait = 0 + }) + this.helpers.watchForElement('.skip-btn.show', () => { + this.helpers.safelyNavigate(window.app.options.intermediate.destinationUrl) + }) + } +} + +export const matches = ['sh.st']