├── .extension └── uBlock │ ├── 1p-filters.html │ ├── 3p-filters.html │ ├── LICENSE.txt │ ├── _locales │ ├── am │ │ └── messages.json │ ├── ar │ │ └── messages.json │ ├── az │ │ └── messages.json │ ├── be │ │ └── messages.json │ ├── bg │ │ └── messages.json │ ├── bn │ │ └── messages.json │ ├── bs │ │ └── messages.json │ ├── ca │ │ └── messages.json │ ├── cs │ │ └── messages.json │ ├── cv │ │ └── messages.json │ ├── da │ │ └── messages.json │ ├── de │ │ └── messages.json │ ├── el │ │ └── messages.json │ ├── en │ │ └── messages.json │ ├── en_GB │ │ └── messages.json │ ├── eo │ │ └── messages.json │ ├── es │ │ └── messages.json │ ├── et │ │ └── messages.json │ ├── eu │ │ └── messages.json │ ├── fa │ │ └── messages.json │ ├── fi │ │ └── messages.json │ ├── fil │ │ └── messages.json │ ├── fr │ │ └── messages.json │ ├── fy │ │ └── messages.json │ ├── ga │ │ └── messages.json │ ├── gl │ │ └── messages.json │ ├── gu │ │ └── messages.json │ ├── he │ │ └── messages.json │ ├── hi │ │ └── messages.json │ ├── hr │ │ └── messages.json │ ├── hu │ │ └── messages.json │ ├── hy │ │ └── messages.json │ ├── id │ │ └── messages.json │ ├── it │ │ └── messages.json │ ├── ja │ │ └── messages.json │ ├── ka │ │ └── messages.json │ ├── kk │ │ └── messages.json │ ├── kn │ │ └── messages.json │ ├── ko │ │ └── messages.json │ ├── lt │ │ └── messages.json │ ├── lv │ │ └── messages.json │ ├── mk │ │ └── messages.json │ ├── ml │ │ └── messages.json │ ├── mr │ │ └── messages.json │ ├── ms │ │ └── messages.json │ ├── nb │ │ └── messages.json │ ├── nl │ │ └── messages.json │ ├── no │ │ └── messages.json │ ├── oc │ │ └── messages.json │ ├── pl │ │ └── messages.json │ ├── pt_BR │ │ └── messages.json │ ├── pt_PT │ │ └── messages.json │ ├── ro │ │ └── messages.json │ ├── ru │ │ └── messages.json │ ├── si │ │ └── messages.json │ ├── sk │ │ └── messages.json │ ├── sl │ │ └── messages.json │ ├── so │ │ └── messages.json │ ├── sq │ │ └── messages.json │ ├── sr │ │ └── messages.json │ ├── sv │ │ └── messages.json │ ├── sw │ │ └── messages.json │ ├── ta │ │ └── messages.json │ ├── te │ │ └── messages.json │ ├── th │ │ └── messages.json │ ├── tr │ │ └── messages.json │ ├── uk │ │ └── messages.json │ ├── ur │ │ └── messages.json │ ├── vi │ │ └── messages.json │ ├── zh_CN │ │ └── messages.json │ └── zh_TW │ │ └── messages.json │ ├── about.html │ ├── advanced-settings.html │ ├── asset-viewer.html │ ├── assets │ ├── assets.json │ ├── resources │ │ └── scriptlets.js │ ├── thirdparties │ │ ├── easylist │ │ │ ├── easylist.txt │ │ │ └── easyprivacy.txt │ │ ├── pgl.yoyo.org │ │ │ └── as │ │ │ │ ├── README.md │ │ │ │ └── serverlist │ │ ├── publicsuffix.org │ │ │ └── list │ │ │ │ └── effective_tld_names.dat │ │ └── urlhaus-filter │ │ │ ├── LICENSE.md │ │ │ └── urlhaus-filter-online.txt │ └── ublock │ │ ├── badlists.txt │ │ ├── badware.txt │ │ ├── filters-2020.txt │ │ ├── filters-2021.txt │ │ ├── filters-2022.txt │ │ ├── filters-2023.txt │ │ ├── filters.txt │ │ ├── legacy.txt │ │ ├── privacy.txt │ │ ├── quick-fixes.txt │ │ ├── resource-abuse.txt │ │ └── unbreak.txt │ ├── background.html │ ├── cloud-ui.html │ ├── code-viewer.html │ ├── css │ ├── 1p-filters.css │ ├── 3p-filters.css │ ├── about.css │ ├── advanced-settings.css │ ├── asset-viewer.css │ ├── click2load.css │ ├── cloud-ui.css │ ├── code-viewer.css │ ├── codemirror.css │ ├── common.css │ ├── dashboard-common.css │ ├── dashboard.css │ ├── devtools.css │ ├── document-blocked.css │ ├── dyna-rules.css │ ├── epicker-ui.css │ ├── fa-icons.css │ ├── fonts │ │ ├── Inter │ │ │ ├── Inter-Regular.woff2 │ │ │ ├── Inter-SemiBold.woff2 │ │ │ └── LICENSE.txt │ │ └── Metropolis │ │ │ ├── Metropolis-Regular.woff2 │ │ │ ├── Metropolis-SemiBold.woff2 │ │ │ ├── README.md │ │ │ └── UNLICENSE │ ├── logger-ui-inspector.css │ ├── logger-ui.css │ ├── popup-fenix.css │ ├── settings.css │ ├── support.css │ ├── themes │ │ └── default.css │ └── whitelist.css │ ├── dashboard.html │ ├── devtools.html │ ├── document-blocked.html │ ├── dyna-rules.html │ ├── img │ ├── cloud.png │ ├── fontawesome │ │ ├── LICENSE.txt │ │ └── fontawesome-defs.svg │ ├── help16.png │ ├── icon_128.png │ ├── icon_16-loading.png │ ├── icon_16-off.png │ ├── icon_16.png │ ├── icon_32-loading.png │ ├── icon_32-off.png │ ├── icon_32.png │ ├── icon_64-loading.png │ ├── icon_64-off.png │ ├── icon_64.png │ ├── material-design.svg │ ├── photon.svg │ ├── ublock-defs.svg │ └── ublock.svg │ ├── is-webrtc-supported.html │ ├── js │ ├── 1p-filters.js │ ├── 3p-filters.js │ ├── about.js │ ├── advanced-settings.js │ ├── asset-viewer.js │ ├── assets.js │ ├── background.js │ ├── base64-custom.js │ ├── benchmarks.js │ ├── biditrie.js │ ├── cachestorage.js │ ├── click2load.js │ ├── cloud-ui.js │ ├── code-viewer.js │ ├── codemirror │ │ ├── search-thread.js │ │ ├── search.js │ │ ├── ubo-dynamic-filtering.js │ │ └── ubo-static-filtering.js │ ├── commands.js │ ├── console.js │ ├── contentscript-extra.js │ ├── contentscript.js │ ├── contextmenu.js │ ├── cosmetic-filtering.js │ ├── dashboard-common.js │ ├── dashboard.js │ ├── devtools.js │ ├── document-blocked.js │ ├── dom.js │ ├── dyna-rules.js │ ├── dynamic-net-filtering.js │ ├── epicker-ui.js │ ├── fa-icons.js │ ├── filtering-context.js │ ├── filtering-engines.js │ ├── hnswitches.js │ ├── hntrie.js │ ├── html-filtering.js │ ├── httpheader-filtering.js │ ├── i18n.js │ ├── is-webrtc-supported.js │ ├── logger-ui-inspector.js │ ├── logger-ui.js │ ├── logger.js │ ├── lz4.js │ ├── messaging.js │ ├── pagestore.js │ ├── popup-fenix.js │ ├── redirect-engine.js │ ├── redirect-resources.js │ ├── reverselookup-worker.js │ ├── reverselookup.js │ ├── scriptlet-filtering.js │ ├── scriptlets │ │ ├── cosmetic-logger.js │ │ ├── cosmetic-off.js │ │ ├── cosmetic-on.js │ │ ├── cosmetic-report.js │ │ ├── dom-inspector.js │ │ ├── dom-survey-elements.js │ │ ├── dom-survey-scripts.js │ │ ├── epicker.js │ │ ├── load-3p-css.js │ │ ├── load-large-media-all.js │ │ ├── load-large-media-interactive.js │ │ ├── noscript-spoof.js │ │ ├── should-inject-contentscript.js │ │ └── subscriber.js │ ├── settings.js │ ├── start.js │ ├── static-dnr-filtering.js │ ├── static-ext-filtering-db.js │ ├── static-ext-filtering.js │ ├── static-filtering-io.js │ ├── static-filtering-parser.js │ ├── static-net-filtering.js │ ├── storage.js │ ├── support.js │ ├── tab.js │ ├── tasks.js │ ├── text-encode.js │ ├── text-utils.js │ ├── theme.js │ ├── traffic.js │ ├── ublock.js │ ├── uri-utils.js │ ├── url-net-filtering.js │ ├── utils.js │ ├── vapi-background-ext.js │ ├── vapi-background.js │ ├── vapi-client-extra.js │ ├── vapi-client.js │ ├── vapi-common.js │ ├── vapi.js │ ├── wasm │ │ ├── README.md │ │ ├── biditrie.wasm │ │ ├── biditrie.wat │ │ ├── hntrie.wasm │ │ └── hntrie.wat │ ├── webext.js │ └── whitelist.js │ ├── lib │ ├── codemirror │ │ ├── LICENSE │ │ ├── README.md │ │ ├── addon │ │ │ ├── comment │ │ │ │ └── comment.js │ │ │ ├── display │ │ │ │ └── panel.js │ │ │ ├── edit │ │ │ │ ├── closebrackets.js │ │ │ │ └── matchbrackets.js │ │ │ ├── fold │ │ │ │ ├── foldcode.js │ │ │ │ ├── foldgutter.css │ │ │ │ └── foldgutter.js │ │ │ ├── hint │ │ │ │ ├── show-hint.css │ │ │ │ └── show-hint.js │ │ │ ├── merge │ │ │ │ ├── merge.css │ │ │ │ └── merge.js │ │ │ ├── scroll │ │ │ │ └── annotatescrollbar.js │ │ │ ├── search │ │ │ │ ├── matchesonscrollbar.css │ │ │ │ └── searchcursor.js │ │ │ └── selection │ │ │ │ └── active-line.js │ │ ├── lib │ │ │ ├── codemirror.css │ │ │ └── codemirror.js │ │ ├── mode │ │ │ ├── css │ │ │ │ └── css.js │ │ │ ├── htmlmixed │ │ │ │ └── htmlmixed.js │ │ │ ├── javascript │ │ │ │ └── javascript.js │ │ │ └── xml │ │ │ │ └── xml.js │ │ └── theme │ │ │ └── night.css │ ├── csstree │ │ ├── LICENSE │ │ └── css-tree.js │ ├── diff │ │ ├── README.md │ │ └── swatinem_diff.js │ ├── hsluv │ │ ├── LICENSE │ │ ├── README │ │ └── hsluv-0.1.0.min.js │ ├── js-beautify │ │ ├── LICENSE │ │ ├── README │ │ └── beautifier.min.js │ ├── lz4 │ │ ├── README.md │ │ ├── lz4-block-codec-any.js │ │ ├── lz4-block-codec-js.js │ │ ├── lz4-block-codec-wasm.js │ │ ├── lz4-block-codec.wasm │ │ └── lz4-block-codec.wat │ ├── publicsuffixlist │ │ ├── publicsuffixlist.js │ │ └── wasm │ │ │ ├── README.md │ │ │ ├── publicsuffixlist.wasm │ │ │ └── publicsuffixlist.wat │ ├── punycode.js │ └── regexanalyzer │ │ ├── CHANGES.md │ │ ├── README.md │ │ └── regex.js │ ├── logger-ui.html │ ├── managed_storage.json │ ├── manifest.json │ ├── no-dashboard.html │ ├── popup-fenix.html │ ├── settings.html │ ├── support.html │ ├── web_accessible_resources │ ├── 1x1.gif │ ├── 2x2.png │ ├── 32x32.png │ ├── 3x2.png │ ├── README.txt │ ├── addthis_widget.js │ ├── amazon_ads.js │ ├── amazon_apstag.js │ ├── ampproject_v0.js │ ├── chartbeat.js │ ├── click2load.html │ ├── doubleclick_instream_ad_status.js │ ├── empty │ ├── epicker-ui.html │ ├── fingerprint2.js │ ├── fingerprint3.js │ ├── google-analytics_analytics.js │ ├── google-analytics_cx_api.js │ ├── google-analytics_ga.js │ ├── google-analytics_inpage_linkid.js │ ├── google-ima.js │ ├── googlesyndication_adsbygoogle.js │ ├── googletagmanager_gtm.js │ ├── googletagservices_gpt.js │ ├── hd-main.js │ ├── ligatus_angular-tag.js │ ├── monkeybroker.js │ ├── mxpnl_mixpanel.js │ ├── nobab.js │ ├── nobab2.js │ ├── noeval-silent.js │ ├── noeval.js │ ├── nofab.js │ ├── noop-0.1s.mp3 │ ├── noop-0.5s.mp3 │ ├── noop-1s.mp4 │ ├── noop-vmap1.0.xml │ ├── noop.css │ ├── noop.html │ ├── noop.js │ ├── noop.txt │ ├── outbrain-widget.js │ ├── popads-dummy.js │ ├── popads.js │ ├── prebid-ads.js │ ├── scorecardresearch_beacon.js │ └── window.open-defuser.js │ └── whitelist.html ├── .gitignore ├── LICENSE ├── README.md ├── bin └── index.ts ├── images ├── administrator.png └── user.png ├── package.json ├── pnpm-lock.yaml ├── src ├── apis │ └── index.ts ├── app.ts ├── config │ ├── api.ts │ ├── pup.ts │ ├── push.ts │ ├── schedule.ts │ ├── study.ts │ └── url.ts ├── controller │ ├── exam.ts │ ├── login.ts │ ├── user.ts │ └── watch.ts ├── cookie │ └── .gitkeep ├── logs │ └── .gitkeep ├── qrcode │ └── .gitkeep ├── shared │ └── index.ts └── utils │ ├── cookieCache.ts │ ├── fomat.ts │ ├── html.ts │ ├── job.ts │ ├── logs.ts │ ├── push.ts │ ├── random.ts │ └── utils.ts ├── test ├── api.test.ts ├── error.test.ts ├── exam.test.ts ├── extension.test.ts ├── log.test.ts ├── login.test.ts └── watch.test.ts ├── tsconfig.json └── vitest.config.ts /.extension/uBlock/1p-filters.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock — Your filters 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 |
25 | 26 |

question-circle

27 |

28 | 29 | 30 |   31 | 32 | 33 |

34 |
35 |
36 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | -------------------------------------------------------------------------------- /.extension/uBlock/advanced-settings.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 |
21 |

info-circle 22 |

23 |   24 |

25 | 26 |
27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /.extension/uBlock/asset-viewer.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 |
19 | 20 | 21 | spinner 22 | 23 |
24 | 25 |
26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | -------------------------------------------------------------------------------- /.extension/uBlock/assets/thirdparties/pgl.yoyo.org/as/README.md: -------------------------------------------------------------------------------- 1 | : 2 | 3 | Site does encourage use of the list for noncommercial uses only, as per 4 | https://pgl.yoyo.org/ ("everything licensed under the McRae General Public 5 | License (version 4.r53) ") 6 | 7 | Licence can be found at https://pgl.yoyo.org/license/, and is copied below 8 | for brevity: 9 | 10 | 11 | Preamble 12 | -------- 13 | Your GRAN. 14 | 15 | 16 | MCRAE GENERAL PUBLIC LICENSE (version 4.r53) 17 | -------------------------------------------- 18 | This license applies to any work containing a notice placed by the 19 | copyright holder (that would be ME) saying it is uses the McRae 20 | General Public License. "The work" refers to any such work. 21 | 22 | This license stipulates that it is strictly forbidden to redistribute 23 | or use the work in any manner that could possibly be construed as 24 | making anybody any money, or I'll sue you. No! You will NOT do that! 25 | Okee? And if you don't agree with these terms, you can print out the 26 | source to the work and stick it up your ARSE. 27 | 28 | Aye, but otherwise feel free to take "the work" and do what you like. 29 | If you're TOO BLOODY LAZY to do it yourself, I cannae help it. OK? 30 | -------------------------------------------------------------------------------- /.extension/uBlock/assets/ublock/badlists.txt: -------------------------------------------------------------------------------- 1 | # The lists below are known to create issues in uBO. 2 | 3 | # Reek's Anti-Adblock Killer 4 | https://raw.github.com/reek/anti-adblock-killer/master/anti-adblock-killer-filters.txt 5 | https://raw.githubusercontent.com/reek/anti-adblock-killer/master/anti-adblock-killer-filters.txt 6 | 7 | # ABP anti-circumvention filter lists 8 | https://easylist-downloads.adblockplus.org/abp-filters-anti-cv.txt 9 | https://easylist-msie.adblockplus.org/abp-filters-anti-cv.txt 10 | https://raw.githubusercontent.com/abp-filters/abp-filters-anti-cv/master/english.txt 11 | https://easylist-msie.adblockplus.org/antiadblockfilters.txt 12 | 13 | # https://github.com/uBlockOrigin/uBlock-issues/issues/971 14 | https://hosts-file.net/.%5Cad_servers.txt remove 15 | http://hosts-file.net/.%5Cad_servers.txt remove 16 | 17 | # https://github.com/uBlockOrigin/uAssets/issues/8738 18 | https://raw.githubusercontent.com/k2jp/abp-japanese-filters/master/abpjf.txt 19 | 20 | # https://github.com/uBlockOrigin/uAssets/issues/13566 21 | # https://twitter.com/gorhill/status/1352651716265713665 22 | https://www.joinhoney.com/whitelist/honey-smart-shopping.txt 23 | 24 | # whitelisting lists 25 | https://slickdeals.net/attachment/extension/allowlist.txt 26 | https://easylist-downloads.adblockplus.org/exceptionrules.txt 27 | https://letyshops.com/adblock.txt 28 | https://work.ink/adblock-whitelist.txt 29 | https://www.ebates.com/whitelist/ebates-cash-back-shopping.txt 30 | https://www.rakuten.com/whitelist/ebates-cash-back-shopping.txt 31 | https://www.topcashback.co.uk/misc/AdBlockWhiteList.aspx 32 | https://www.topcashback.co.uk/Misc/AdBlockWhiteList.aspx 33 | https://ads-for-open-source.readthedocs.io/en/latest/_static/lists/opensource-ads.txt 34 | https://ads-for-open-source.readthedocs.io/en/latest/_static/lists/readthedocs-ads.txt 35 | 36 | # obsolete lists 37 | https://cdn.rawgit.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoAnnoyance.txt 38 | https://cdn.rawgit.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoBase.txt 39 | https://cdn.rawgit.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoWhitelist.txt 40 | https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoFilters/NanoBase.txt 41 | https://gitcdn.xyz/repo/NanoAdblocker/NanoFilters/master/NanoMirror/NanoDefender.txt 42 | https://raw.githubusercontent.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoAnnoyance.txt 43 | https://raw.githubusercontent.com/NanoAdblocker/NanoFilters/master/NanoFilters/NanoWhitelist.txt 44 | https://raw.githubusercontent.com/NanoAdblocker/NanoFilters/master/NanoFiltersSource/NanoAnnoyance.txt 45 | https://raw.githubusercontent.com/NanoAdblocker/NanoFilters/master/NanoFiltersSource/NanoBase.txt 46 | https://raw.githubusercontent.com/NanoAdblocker/NanoFilters/master/NanoFiltersSource/NanoWhitelist.txt 47 | https://raw.githubusercontent.com/jspenguin2017/uBlockProtector/master/uBlockProtectorList.txt 48 | 49 | # outdated prebake list 50 | https://raw.githubusercontent.com/liamja/Prebake/master/obtrusive.txt 51 | 52 | # The following entries can be removed once a majority of users are 53 | # upgraded to uBO 1.30.0. 54 | 55 | # AdBlock Warning Removal List 56 | https://easylist-downloads.adblockplus.org/antiadblockfilters.txt remove 57 | 58 | # https://github.com/gorhill/uBlock/commit/a13ac920892d25ba0bf431ea1410fd3c8612b2d6 59 | https://gitcdn.xyz/repo/NanoMeow/MDLMirror/master/hosts.txt remove 60 | https://mirror.cedia.org.ec/malwaredomains/justdomains remove 61 | 62 | # https://github.com/uBlockOrigin/uBlock-issues/discussions/2022#discussioncomment-2293515 63 | # https://github.com/gorhill/uBlock/commit/34cca8349b78ca34ca9b385e26defeea2c829a58 64 | https://raw.githubusercontent.com/uBlockOrigin/uAssets/master/filters/resource-abuse.txt 65 | -------------------------------------------------------------------------------- /.extension/uBlock/background.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | uBlock Origin Background Page 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /.extension/uBlock/cloud-ui.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 |
10 | 11 | 12 | 13 | 14 |
15 |
cog
16 |
17 |   18 |
19 |
20 |
21 |
22 | 23 | 24 | -------------------------------------------------------------------------------- /.extension/uBlock/code-viewer.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | Code viewer 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 26 |
27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | -------------------------------------------------------------------------------- /.extension/uBlock/css/1p-filters.css: -------------------------------------------------------------------------------- 1 | html { 2 | height: 100vh; 3 | overflow: hidden; 4 | width: 100vw; 5 | } 6 | body { 7 | display: flex; 8 | flex-direction: column; 9 | height: 100%; 10 | justify-content: stretch; 11 | overflow: hidden; 12 | width: 100%; 13 | } 14 | .body { 15 | flex-shrink: 0; 16 | } 17 | .codeMirrorContainer { 18 | flex-grow: 1; 19 | } 20 | #userFilters { 21 | text-align: left; 22 | word-wrap: normal; 23 | } 24 | -------------------------------------------------------------------------------- /.extension/uBlock/css/about.css: -------------------------------------------------------------------------------- 1 | body { 2 | margin-bottom: 6rem; 3 | } 4 | -------------------------------------------------------------------------------- /.extension/uBlock/css/advanced-settings.css: -------------------------------------------------------------------------------- 1 | html { 2 | height: 100vh; 3 | overflow: hidden; 4 | width: 100vw; 5 | } 6 | body { 7 | display: flex; 8 | flex-direction: column; 9 | height: 100%; 10 | justify-content: stretch; 11 | overflow: hidden; 12 | width: 100%; 13 | } 14 | .body { 15 | flex-shrink: 0; 16 | } 17 | .codeMirrorContainer { 18 | flex-grow: 1; 19 | } 20 | #advancedSettings { 21 | border: var(--default-gap-xxsmall) solid var(--surface-2); 22 | text-align: left; 23 | } 24 | .CodeMirror-wrap pre { 25 | word-break: break-all; 26 | } 27 | -------------------------------------------------------------------------------- /.extension/uBlock/css/asset-viewer.css: -------------------------------------------------------------------------------- 1 | /** 2 | uBlock Origin - a browser extension to block requests. 3 | Copyright (C) 2014-present Raymond Hill 4 | 5 | This program is free software: you can redistribute it and/or modify 6 | it under the terms of the GNU General Public License as published by 7 | the Free Software Foundation, either version 3 of the License, or 8 | (at your option) any later version. 9 | 10 | This program is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | GNU General Public License for more details. 14 | 15 | You should have received a copy of the GNU General Public License 16 | along with this program. If not, see {http://www.gnu.org/licenses/}. 17 | 18 | Home: https://github.com/gorhill/uBlock 19 | */ 20 | 21 | body { 22 | border: 0; 23 | display: flex; 24 | flex-direction: column; 25 | height: 100vh; 26 | margin: 0; 27 | overflow: hidden; 28 | padding: 0; 29 | width: 100vw; 30 | } 31 | #subscribe { 32 | display: flex; 33 | flex-shrink: 0; 34 | justify-content: space-between; 35 | max-height: 6em; 36 | padding-inline-end: 0.5em; 37 | } 38 | #subscribe.hide { 39 | display: none; 40 | } 41 | .logo { 42 | background-color: #fffa; 43 | flex-shrink: 0; 44 | width: 2em; 45 | } 46 | #subscribePrompt { 47 | display: inline-flex; 48 | flex-direction: column; 49 | padding: 0.5em; 50 | } 51 | #subscribePrompt > span { 52 | font-weight: bold; 53 | } 54 | #subscribePrompt > a { 55 | font-size: 14px; 56 | word-break: break-all; 57 | } 58 | #subscribe > button { 59 | align-self: center; 60 | } 61 | #subscribe > .fa-icon { 62 | color: var(--accent-ink-1); 63 | fill: var(--accent-ink-1); 64 | font-size: 20px; 65 | } 66 | body.loading #subscribe > button, 67 | body:not(.loading) #subscribe > .fa-icon { 68 | display: none; 69 | } 70 | @keyframes spin { 71 | 0% { transform: rotate(0deg); } 72 | 100% { transform: rotate(360deg); } 73 | } 74 | body.loading #subscribe > .fa-icon > svg { 75 | animation: spin 1s steps(8) infinite; 76 | } 77 | #content { 78 | flex-grow: 1; 79 | } 80 | -------------------------------------------------------------------------------- /.extension/uBlock/css/click2load.css: -------------------------------------------------------------------------------- 1 | /** 2 | uBlock Origin - a browser extension to block requests. 3 | Copyright (C) 2014-present Raymond Hill 4 | 5 | This program is free software: you can redistribute it and/or modify 6 | it under the terms of the GNU General Public License as published by 7 | the Free Software Foundation, either version 3 of the License, or 8 | (at your option) any later version. 9 | 10 | This program is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | GNU General Public License for more details. 14 | 15 | You should have received a copy of the GNU General Public License 16 | along with this program. If not, see {http://www.gnu.org/licenses/}. 17 | 18 | Home: https://github.com/gorhill/uBlock 19 | */ 20 | 21 | body { 22 | align-items: center; 23 | border: 1px solid var(--ubo-red); 24 | box-sizing: border-box; 25 | display: flex; 26 | flex-direction: column; 27 | height: 100vh; 28 | padding: 0 2px; 29 | position: relative; 30 | width: 100vw; 31 | } 32 | 33 | .logo { 34 | left: 0; 35 | padding: 2px 1px; 36 | position: absolute; 37 | top: 0; 38 | } 39 | 40 | #frameURL { 41 | font-family: monospace; 42 | font-size: 90%; 43 | overflow-y: auto; 44 | word-break: break-all; 45 | } 46 | #frameURL > a { 47 | font-size: 1rem; 48 | } 49 | 50 | #clickToLoad { 51 | cursor: default; 52 | margin-bottom: 1em; 53 | } 54 | -------------------------------------------------------------------------------- /.extension/uBlock/css/cloud-ui.css: -------------------------------------------------------------------------------- 1 | #cloudWidget { 2 | background-color: var(--surface-2); 3 | margin: 0.5em 0; 4 | min-width: max-content; 5 | position: relative; 6 | } 7 | #cloudWidget.hide { 8 | display: none; 9 | } 10 | #cloudWidget div { 11 | display: flex; 12 | } 13 | #cloudToolbar { 14 | align-items: flex-start; 15 | flex-wrap: nowrap; 16 | justify-content: space-between; 17 | } 18 | #cloudToolbar > div:first-of-type { 19 | margin: 0.5em; 20 | } 21 | #cloudToolbar button { 22 | padding: 0 0.25em; 23 | position: relative; 24 | } 25 | #cloudToolbar button .fa-icon { 26 | font-size: 180%; 27 | } 28 | #cloudToolbar button[disabled] { 29 | visibility: hidden; 30 | } 31 | #cloudToolbar button.error { 32 | color: var(--info3-ink); 33 | } 34 | #cloudPullAndMerge { 35 | margin-left: 0.25em; 36 | } 37 | #cloudPullAndMerge > span:nth-of-type(2) { 38 | font-size: 90%; 39 | position: absolute; 40 | right: 0; 41 | top: 0; 42 | } 43 | #cloudInfo { 44 | flex-shrink: 0; 45 | font-size: 90%; 46 | margin: 0 1em; 47 | overflow: hidden; 48 | padding: 0; 49 | white-space: pre-line; 50 | } 51 | #cloudCapacity { 52 | background-color: var(--surface-3); 53 | height: 4px; 54 | } 55 | #cloudCapacity > div { 56 | background-color: var(--cloud-total-used-surface); 57 | } 58 | #cloudCapacity > div > div { 59 | background-color: var(--cloud-used-surface); 60 | } 61 | #cloudError { 62 | color: var(--info3-ink); 63 | flex-grow: 1; 64 | flex-shrink: 2; 65 | font-size: small; 66 | margin: 0 0.5em 0.5em 0.5em; 67 | } 68 | #cloudError:empty { 69 | display: none; 70 | } 71 | #cloudCog { 72 | color: var(--ink-3); 73 | fill: var(--ink-3); 74 | cursor: pointer; 75 | font-size: 110%; 76 | justify-content: flex-end; 77 | padding: 0.4em; 78 | } 79 | #cloudCog:hover { 80 | color: inherit; 81 | fill: inherit; 82 | } 83 | #cloudWidget #cloudOptions { 84 | align-items: center; 85 | background-color: var(--surface-1); 86 | bottom: 2px; 87 | display: none; 88 | font-size: small; 89 | padding: 0.5em; 90 | position: absolute; 91 | right: 2px; 92 | text-align: center; 93 | top: 2px; 94 | z-index: 10; 95 | } 96 | #cloudWidget #cloudOptions label { 97 | display: inline-flex; 98 | flex-direction: column; 99 | align-items: flex-start; 100 | } 101 | #cloudWidget #cloudOptions.show { 102 | display: flex; 103 | white-space: nowrap; 104 | } 105 | -------------------------------------------------------------------------------- /.extension/uBlock/css/code-viewer.css: -------------------------------------------------------------------------------- 1 | body { 2 | border: 0; 3 | display: flex; 4 | flex-direction: column; 5 | height: 100vh; 6 | margin: 0; 7 | overflow: hidden; 8 | padding: 0; 9 | width: 100vw; 10 | } 11 | #header { 12 | background-color: var(--cm-gutter-surface); 13 | border-bottom: 1px solid var(--surface-1); 14 | padding: var(--default-gap-xsmall); 15 | position: relative; 16 | z-index: 1000000; 17 | } 18 | #header input[type="url"] { 19 | box-sizing: border-box; 20 | font-size: var(--font-size-smaller); 21 | width: 100%; 22 | } 23 | #header:focus-within #pastURLs { 24 | display: flex; 25 | } 26 | #currentURL { 27 | display: flex; 28 | gap: 0.5rem; 29 | } 30 | #currentURL > .fa-icon { 31 | padding: 0 0.5rem; 32 | } 33 | #currentURL > .fa-icon:hover { 34 | background-color: var(--surface-3); 35 | } 36 | #pastURLs { 37 | background-color: var(--surface-0); 38 | border: 1px solid var(--border-1); 39 | display: none; 40 | flex-direction: column; 41 | font-size: var(--font-size-smaller); 42 | position: absolute; 43 | } 44 | #pastURLs > span { 45 | cursor: pointer; 46 | overflow: hidden; 47 | padding: 2px 4px; 48 | text-overflow: ellipsis; 49 | white-space: nowrap; 50 | width: 75vw; 51 | } 52 | #pastURLs > span.selected { 53 | font-weight: bold; 54 | } 55 | #pastURLs > span:hover { 56 | background-color: var(--surface-1); 57 | } 58 | #content { 59 | flex-grow: 1; 60 | } 61 | 62 | .cm-href { 63 | cursor: pointer; 64 | } 65 | .cm-href:hover { 66 | text-decoration: underline; 67 | } 68 | -------------------------------------------------------------------------------- /.extension/uBlock/css/dashboard-common.css: -------------------------------------------------------------------------------- 1 | body > div.body { 2 | padding: 0 0.5em; 3 | } 4 | h2, h3 { 5 | margin: 1em 0; 6 | } 7 | h2 { 8 | font-size: 18px; 9 | } 10 | h3 { 11 | font-size: 16px; 12 | } 13 | a { 14 | text-decoration: none; 15 | } 16 | .fa-icon.info { 17 | color: var(--info0-ink); 18 | fill: var(--info0-ink); 19 | font-size: 115%; 20 | } 21 | .fa-icon.info:hover { 22 | transform: scale(1.25); 23 | } 24 | .fa-icon.info.important { 25 | color: var(--info2-ink); 26 | fill: var(--info2-ink); 27 | } 28 | .fa-icon.info.very-important { 29 | color: var(--info3-ink); 30 | fill: var(--info3-ink); 31 | } 32 | input[type="number"] { 33 | width: 5em; 34 | } 35 | @media (max-height: 640px), (max-height: 800px) and (max-width: 480px) { 36 | .body > p, 37 | .body > ul { 38 | margin: 0.5em 0; 39 | } 40 | .vverbose { 41 | display: none !important; 42 | } 43 | } 44 | /** 45 | On mobile device, the on-screen keyboard may take up 46 | so much space that it overlaps the content being edited. 47 | The rule below makes it possible to scroll the edited 48 | content within view. 49 | */ 50 | :root.mobile { 51 | overflow: auto; 52 | } 53 | :root.mobile body { 54 | min-height: 600px; 55 | } 56 | -------------------------------------------------------------------------------- /.extension/uBlock/css/dashboard.css: -------------------------------------------------------------------------------- 1 | html, body { 2 | display: flex; 3 | flex-direction: column; 4 | height: 100vh; 5 | justify-content: stretch; 6 | overflow: hidden; 7 | position: relative; 8 | width: 100vw; 9 | } 10 | body.notReady { 11 | display: none; 12 | } 13 | #dashboard-nav { 14 | border: 0; 15 | border-bottom: 1px solid var(--border-1); 16 | display: flex; 17 | flex-shrink: 0; 18 | flex-wrap: wrap; 19 | overflow-x: hidden; 20 | padding: 0; 21 | position: sticky; 22 | top: 0; 23 | width: 100%; 24 | z-index: 10; 25 | } 26 | .tabButton { 27 | background-color: transparent; 28 | border: 0; 29 | border-bottom: 3px solid transparent; 30 | border-radius: 0; 31 | color: var(--dashboard-tab-ink); 32 | fill: var(--dashboard-tab-ink); 33 | font-family: var(--font-family); 34 | font-size: var(--font-size); 35 | padding: 0.7em 1.4em calc(0.7em - 3px); 36 | text-decoration: none; 37 | white-space: nowrap; 38 | } 39 | .tabButton:focus { 40 | outline: 0; 41 | } 42 | /* 43 | * TODO: support keyboard-driven navigation 44 | * 45 | .tabButton:not(:active):focus { 46 | background-color: var(--dashboard-tab-focus-surface); 47 | } 48 | */ 49 | .tabButton.selected { 50 | background-color: var(--dashboard-tab-active-surface); 51 | border-bottom: 3px solid var(--dashboard-tab-active-ink); 52 | color: var(--dashboard-tab-active-ink); 53 | fill: var(--dashboard-tab-active-ink); 54 | } 55 | iframe { 56 | background-color: transparent; 57 | border: 0; 58 | flex-grow: 1; 59 | margin: 0; 60 | padding: 0; 61 | width: 100%; 62 | } 63 | #unsavedWarning { 64 | display: none; 65 | left: 0; 66 | position: absolute; 67 | width: 100%; 68 | z-index: 20; 69 | } 70 | #unsavedWarning.on { 71 | display: initial; 72 | } 73 | #unsavedWarning > div:first-of-type { 74 | padding: 0.5em; 75 | } 76 | #unsavedWarning > div:last-of-type { 77 | height: 100vh; 78 | position: absolute; 79 | width: 100vw; 80 | } 81 | 82 | body .tabButton[data-pane="no-dashboard.html"] { 83 | display: none; 84 | } 85 | body.noDashboard #dashboard-nav { 86 | display: none; 87 | } 88 | 89 | /* high dpi devices */ 90 | :root.hidpi .tabButton { 91 | font-family: Metropolis, sans-serif; 92 | font-weight: 600; 93 | letter-spacing: 0.5px; 94 | } 95 | 96 | /* hover-able devices */ 97 | :root.desktop .tabButton { 98 | cursor: default; 99 | } 100 | :root.desktop .tabButton:not(.selected) { 101 | cursor: pointer; 102 | } 103 | :root.desktop .tabButton:not(.selected):hover { 104 | background-color: var(--dashboard-tab-hover-surface); 105 | border-bottom-color: var(--dashboard-tab-hover-border); 106 | } 107 | 108 | /* touch-screen devices */ 109 | :root.mobile #dashboard-nav { 110 | flex-wrap: nowrap; 111 | overflow-x: auto; 112 | } 113 | :root.mobile #dashboard-nav .logo { 114 | display: none; 115 | } 116 | -------------------------------------------------------------------------------- /.extension/uBlock/css/devtools.css: -------------------------------------------------------------------------------- 1 | html { 2 | height: 100vh; 3 | overflow: hidden; 4 | width: 100vw; 5 | } 6 | body { 7 | display: flex; 8 | flex-direction: column; 9 | height: 100%; 10 | justify-content: stretch; 11 | overflow: hidden; 12 | width: 100%; 13 | } 14 | .body { 15 | flex-shrink: 0; 16 | } 17 | .codeMirrorContainer { 18 | flex-grow: 1; 19 | } 20 | #console { 21 | text-align: left; 22 | } 23 | -------------------------------------------------------------------------------- /.extension/uBlock/css/document-blocked.css: -------------------------------------------------------------------------------- 1 | /** 2 | uBlock Origin - a browser extension to block requests. 3 | Copyright (C) 2018-present Raymond Hill 4 | 5 | This program is free software: you can redistribute it and/or modify 6 | it under the terms of the GNU General Public License as published by 7 | the Free Software Foundation, either version 3 of the License, or 8 | (at your option) any later version. 9 | 10 | This program is distributed in the hope that it will be useful, 11 | but WITHOUT ANY WARRANTY; without even the implied warranty of 12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 | GNU General Public License for more details. 14 | 15 | You should have received a copy of the GNU General Public License 16 | along with this program. If not, see {http://www.gnu.org/licenses/}. 17 | 18 | Home: https://github.com/gorhill/uBlock 19 | */ 20 | 21 | body { 22 | display: flex; 23 | padding: var(--default-gap-xxlarge) var(--default-gap-small); 24 | justify-content: center; 25 | } 26 | :root.mobile body { 27 | padding: var(--default-gap-small); 28 | } 29 | 30 | #rootContainer { 31 | width: min(100vw, 640px); 32 | } 33 | #rootContainer > * { 34 | margin: 0 0 var(--default-gap-xxlarge) 0; 35 | } 36 | 37 | a { 38 | text-decoration: none; 39 | } 40 | .code { 41 | font-size: 13px; 42 | word-break: break-all; 43 | } 44 | #warningSign { 45 | width: 100%; 46 | } 47 | #warningSign > a { 48 | font-size: 96px; 49 | } 50 | #theURL { 51 | color: var(--ink-2); 52 | padding: 0; 53 | } 54 | #theURL > * { 55 | margin: 0; 56 | } 57 | #theURL > p { 58 | position: relative; 59 | z-index: 10; 60 | } 61 | #theURL #toggleParse { 62 | background-color: transparent; 63 | top: 100%; 64 | box-sizing: border-box; 65 | color: var(--ink-3); 66 | fill: var(--ink-3); 67 | cursor: pointer; 68 | font-size: 1.2rem; 69 | padding: var(--default-gap-xxsmall); 70 | position: absolute; 71 | transform: translate(0, -50%); 72 | } 73 | #theURL:not(.collapsed) #toggleParse > span:first-of-type { 74 | display: none; 75 | } 76 | #theURL.collapsed #toggleParse > span:last-of-type { 77 | display: none; 78 | } 79 | body[dir="ltr"] #toggleParse { 80 | right: 0; 81 | } 82 | body[dir="rtl"] #toggleParse { 83 | left: 0; 84 | } 85 | #theURL > p:hover #toggleParse { 86 | transform: translate(0, -50%) scale(1.15); 87 | } 88 | #parsed { 89 | background-color: var(--surface-1); 90 | border: 4px solid var(--surface-2); 91 | font-size: small; 92 | overflow-x: auto; 93 | padding: var(--default-gap-xxsmall); 94 | text-align: initial; 95 | text-overflow: ellipsis; 96 | } 97 | #theURL.collapsed > #parsed { 98 | display: none; 99 | } 100 | #parsed ul, #parsed li { 101 | list-style-type: none; 102 | } 103 | #parsed li { 104 | white-space: nowrap; 105 | } 106 | #parsed span { 107 | display: inline-block; 108 | } 109 | #parsed span:first-of-type { 110 | font-weight: bold; 111 | } 112 | 113 | #whyex a { 114 | white-space: nowrap; 115 | } 116 | #whyex ul { 117 | display: flex; 118 | flex-direction: column; 119 | margin: 0; 120 | padding-inline-start: var(--default-gap-xsmall); 121 | } 122 | 123 | #actionContainer { 124 | display: flex; 125 | justify-content: space-between; 126 | } 127 | :root.mobile #actionContainer { 128 | justify-content: center; 129 | display: flex; 130 | flex-direction: column; 131 | } 132 | #actionContainer > button { 133 | margin-bottom: 2rem 134 | } 135 | 136 | .filterList { 137 | display: flex; 138 | } 139 | .filterList .filterListSupport[href=""] { 140 | display: none; 141 | } 142 | 143 | /* Small-screen devices */ 144 | :root.mobile button { 145 | width: 100%; 146 | } 147 | -------------------------------------------------------------------------------- /.extension/uBlock/css/dyna-rules.css: -------------------------------------------------------------------------------- 1 | html { 2 | height: 100vh; 3 | overflow: hidden; 4 | width: 100vw; 5 | } 6 | body { 7 | display: flex; 8 | flex-direction: column; 9 | height: 100%; 10 | justify-content: stretch; 11 | overflow: hidden; 12 | width: 100%; 13 | } 14 | .body { 15 | flex-shrink: 0; 16 | } 17 | #diff { 18 | border: 0; 19 | white-space: nowrap; 20 | } 21 | #diff .tools > * { 22 | margin-bottom: 1em; 23 | } 24 | #diff .ruleActions { 25 | border: 0; 26 | box-sizing: border-box; 27 | display: inline-block; 28 | padding: 0; 29 | text-align: center; 30 | vertical-align: top; 31 | width: 50%; 32 | white-space: nowrap; 33 | } 34 | #diff .ruleActions .fieldset-header { 35 | margin: 0.5em 0; 36 | } 37 | 38 | #ruleFilter { 39 | align-items: center; 40 | background-color: var(--surface-2); 41 | direction: ltr; 42 | display: flex; 43 | justify-content: center; 44 | padding: 0.5em 0; 45 | } 46 | #ruleFilter #diffCollapse { 47 | padding: 0 0.5em; 48 | font-size: 150%; 49 | } 50 | #ruleFilter #diffCollapse.active { 51 | transform: scale(1, -1); 52 | } 53 | 54 | .codeMirrorContainer { 55 | flex-grow: 1; 56 | } 57 | .codeMirrorContainer .CodeMirror { 58 | background-color: var(--surface-1); 59 | } 60 | .CodeMirror-merge, .CodeMirror-merge-pane, .CodeMirror-merge .CodeMirror { 61 | box-sizing: border-box; 62 | height: 100%; 63 | } 64 | body.editing .CodeMirror-merge-copy, 65 | body.editing .CodeMirror-merge-copy-reverse { 66 | display: none; 67 | } 68 | body.editing .CodeMirror-merge-editor .CodeMirror { 69 | background-color: var(--surface-0); 70 | } 71 | body[dir="rtl"] .CodeMirror-merge-pane-rightmost { 72 | right: unset; 73 | left: 0; 74 | } 75 | 76 | /* mobile devices */ 77 | :root.mobile #diff .tools { 78 | overflow: auto; 79 | } 80 | -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Inter/Inter-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/css/fonts/Inter/Inter-Regular.woff2 -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Inter/Inter-SemiBold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/css/fonts/Inter/Inter-SemiBold.woff2 -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Metropolis/Metropolis-Regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/css/fonts/Metropolis/Metropolis-Regular.woff2 -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Metropolis/Metropolis-SemiBold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/css/fonts/Metropolis/Metropolis-SemiBold.woff2 -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Metropolis/README.md: -------------------------------------------------------------------------------- 1 | # Metropolis 2 | 3 | A modern, geometric typeface. Influenced by other popular geometric, minimalist sans-serif typefaces of the new millennium. Designed for optimal readability at small point sizes while beautiful at large point sizes. 4 | 5 | ![Metropolis](./Specimens/Metro-1.png) 6 | 7 | --- 8 | 9 | ![Metropolis](./Specimens/Metro-2.png) 10 | 11 | ### Where am I? 12 | 13 | See [Documentation](./Documentation/Documentation.md). 14 | 15 | ### The Unlicense 16 | 17 | Contributions welcome. 18 | 19 | ### Contact 20 | 21 | Reachable via chris.m.simpson [at] icloud.com or tweet @ChrisMSimpson. 22 | 23 | ### Support 24 | 25 | There is none. Oh, you meant support me? I dare you to click the sponsor button above. 26 | -------------------------------------------------------------------------------- /.extension/uBlock/css/fonts/Metropolis/UNLICENSE: -------------------------------------------------------------------------------- 1 | This is free and unencumbered software released into the public domain. 2 | 3 | Anyone is free to copy, modify, publish, use, compile, sell, or 4 | distribute this software, either in source code form or as a compiled 5 | binary, for any purpose, commercial or non-commercial, and by any 6 | means. 7 | 8 | In jurisdictions that recognize copyright laws, the author or authors 9 | of this software dedicate any and all copyright interest in the 10 | software to the public domain. We make this dedication for the benefit 11 | of the public at large and to the detriment of our heirs and 12 | successors. We intend this dedication to be an overt act of 13 | relinquishment in perpetuity of all present and future rights to this 14 | software under copyright law. 15 | 16 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 17 | EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 18 | MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 19 | IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY CLAIM, DAMAGES OR 20 | OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, 21 | ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR 22 | OTHER DEALINGS IN THE SOFTWARE. 23 | 24 | For more information, please refer to 25 | -------------------------------------------------------------------------------- /.extension/uBlock/css/logger-ui-inspector.css: -------------------------------------------------------------------------------- 1 | #domInspector { 2 | display: none; 3 | } 4 | #inspectors.dom #domInspector { 5 | display: flex; 6 | } 7 | #domInspector .permatoolbar .highlightMode.invert { 8 | transform: rotate(180deg); 9 | } 10 | #domInspector .vscrollable { 11 | overflow-x: auto; 12 | } 13 | #domInspector > ul:first-of-type { 14 | padding-left: 0.5em; 15 | } 16 | #domInspector ul { 17 | background-color: var(--surface-1); 18 | margin: 0; 19 | padding-left: 1em; 20 | } 21 | #domInspector li { 22 | list-style-type: none; 23 | white-space: nowrap; 24 | } 25 | #domInspector li.isCosmeticHide, 26 | #domInspector li.isCosmeticHide ul, 27 | #domInspector li.isCosmeticHide li { 28 | background-color: var(--surface-2); 29 | } 30 | #domInspector li > * { 31 | display: inline-block; 32 | line-height: 1.2; 33 | margin-right: 1em; 34 | vertical-align: middle; 35 | } 36 | #domInspector li > span { 37 | color: #aaa; 38 | } 39 | #domInspector li > span:first-child { 40 | color: var(--ink-1); 41 | cursor: default; 42 | font-size: 1rem; 43 | margin-right: 0; 44 | opacity: 0.5; 45 | padding: 0 4px 0 1px; 46 | visibility: hidden; 47 | } 48 | #domInspector li > span:first-child:hover { 49 | opacity: 1; 50 | } 51 | #domInspector li > *:last-child { 52 | margin-right: 0; 53 | } 54 | #domInspector li > span:first-child:before { 55 | content: '\a0'; 56 | } 57 | #domInspector li.branch > span:first-child:before { 58 | content: '\25b8'; 59 | visibility: visible; 60 | } 61 | #domInspector li.branch.show > span:first-child:before { 62 | content: '\25be'; 63 | } 64 | #domInspector li.branch.hasCosmeticHide > span:first-child:before { 65 | color: red; 66 | } 67 | #domInspector li > code { 68 | cursor: pointer; 69 | font-family: monospace; 70 | overflow: hidden; 71 | text-overflow: ellipsis; 72 | } 73 | #domInspector li > code.off { 74 | text-decoration: line-through; 75 | } 76 | #domInspector li > code.filter { 77 | color: var(--cm-negative); 78 | } 79 | 80 | #domInspector li > ul { 81 | display: block; 82 | } 83 | #domInspector li:not(.hasCosmeticHide):not(.isCosmeticHide):not(.show) > ul { 84 | display: none; 85 | } 86 | 87 | #domInspector:not(.vExpanded) li:not(.hasCosmeticHide):not(.isCosmeticHide) { 88 | display: none; 89 | } 90 | #domInspector #domTree > li { 91 | display: block; 92 | } 93 | #domInspector:not(.vExpanded) ul { 94 | display: block; 95 | } 96 | #domInspector li > ul > li:not(.hasCosmeticHide):not(.isCosmeticHide) { 97 | display: none; 98 | } 99 | #domInspector li.show > ul > li:not(.hasCosmeticHide):not(.isCosmeticHide) { 100 | display: block; 101 | } 102 | #domInspector li:not(.hasCosmeticHide):not(.isCosmeticHide) { 103 | display: block; 104 | } 105 | #domInspector.hCompact li > code:first-of-type { 106 | max-width: 12em; 107 | } 108 | 109 | #cosmeticFilteringDialog .dialog { 110 | text-align: center; 111 | } 112 | #cosmeticFilteringDialog .dialog textarea { 113 | height: 40vh; 114 | white-space: pre; 115 | word-wrap: normal; 116 | } 117 | -------------------------------------------------------------------------------- /.extension/uBlock/css/settings.css: -------------------------------------------------------------------------------- 1 | body { 2 | margin-bottom: 6rem; 3 | } 4 | 5 | .synopsis { 6 | color: var(--ink-0); 7 | font-size: var(--font-size-smaller); 8 | opacity: var(--medium-em); 9 | } 10 | 11 | /* surface/ink */ 12 | #themeMood { 13 | align-items: stretch; 14 | align-self: stretch; 15 | display: inline-flex; 16 | justify-content: stretch; 17 | user-select: none; 18 | } 19 | #themeMood > span { 20 | border: 1px solid var(--ink-1); 21 | color: var(--ink-1); 22 | display: inline-flex; 23 | background-color: var(--surface-1); 24 | display: inline-block; 25 | padding: 0 0.5em; 26 | text-align: center; 27 | user-select: none; 28 | } 29 | 30 | /* primary color */ 31 | #themePrimary { 32 | align-items: stretch; 33 | align-self: stretch; 34 | display: inline-flex; 35 | justify-content: stretch; 36 | position: relative; 37 | } 38 | #themePrimary > span { 39 | background-color: rgb(var(--primary-50)); 40 | display: inline-flex; 41 | width: 2em; 42 | } 43 | 44 | [href="advanced-settings.html"] { 45 | display: none; 46 | } 47 | body.advancedUser [href="advanced-settings.html"] { 48 | display: inline-flex; 49 | } 50 | 51 | #localData > div { 52 | margin-bottom: var(--default-gap-small); 53 | } 54 | #localData > div:last-of-type { 55 | align-items: flex-start; 56 | display: flex; 57 | flex-direction: column; 58 | } 59 | #localData > div:last-of-type > button { 60 | margin-bottom: var(--default-gap-small); 61 | min-width: 280px; 62 | } 63 | 64 | /* Mobile devices */ 65 | 66 | :root.mobile #localData { 67 | max-width: 100vw; 68 | } 69 | :root.mobile #localData > div:last-of-type { 70 | align-items: stretch; 71 | } 72 | :root.mobile #localData > div:last-of-type > button { 73 | min-width: unset; 74 | } 75 | -------------------------------------------------------------------------------- /.extension/uBlock/css/support.css: -------------------------------------------------------------------------------- 1 | body { 2 | margin-bottom: 6rem; 3 | } 4 | 5 | .body > div { 6 | max-width: 800px; 7 | } 8 | h3 { 9 | color: var(--fieldset-header-ink); 10 | margin-bottom: 0; 11 | } 12 | .supportEntry { 13 | display: flex; 14 | } 15 | :root.mobile .supportEntry { 16 | flex-direction: column; 17 | } 18 | .supportEntry > * { 19 | min-width: 6em; 20 | } 21 | .supportEntry > div:first-of-type { 22 | flex-grow: 1; 23 | } 24 | :root:not(.mobile) .supportEntry > div:first-of-type { 25 | margin-inline-end: 2em; 26 | } 27 | .supportEntry h3 { 28 | margin: 1em 0; 29 | } 30 | 31 | .e > .supportEntry { 32 | flex-direction: column; 33 | } 34 | .e > .supportEntry > div:not(:first-of-type) { 35 | margin-top: 1em; 36 | } 37 | .e > .supportEntry select { 38 | min-width: 50%; 39 | max-width: calc(100% - 1em); 40 | } 41 | body:not(.filterIssue) .body > div.e { 42 | display: none; 43 | } 44 | body.filterIssue .body > div:not(.e) { 45 | display: none; 46 | } 47 | body.filterIssue #moreButton { 48 | display: none; 49 | } 50 | 51 | button { 52 | align-self: center; 53 | } 54 | span[data-url] { 55 | color: var(--link-ink); 56 | cursor: pointer; 57 | } 58 | 59 | body.redacted #redactButton { 60 | display: none; 61 | } 62 | #unredactButton { 63 | display: none; 64 | } 65 | body.redacted #unredactButton { 66 | display: inline; 67 | } 68 | 69 | .cm-string.cm-property { 70 | color: black; 71 | } 72 | -------------------------------------------------------------------------------- /.extension/uBlock/css/whitelist.css: -------------------------------------------------------------------------------- 1 | html { 2 | height: 100vh; 3 | overflow: hidden; 4 | width: 100vw; 5 | } 6 | body { 7 | display: flex; 8 | flex-direction: column; 9 | height: 100%; 10 | justify-content: stretch; 11 | overflow: hidden; 12 | width: 100%; 13 | } 14 | .body { 15 | flex-shrink: 0; 16 | } 17 | .codeMirrorContainer { 18 | flex-grow: 1; 19 | } 20 | #whitelist { 21 | text-align: left; 22 | } 23 | -------------------------------------------------------------------------------- /.extension/uBlock/dashboard.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 25 |
26 |
27 |
28 |   29 |   30 | 31 |
32 |
33 |
34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /.extension/uBlock/devtools.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock — Dev tools 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 |
24 |

25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 |

33 |
34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | -------------------------------------------------------------------------------- /.extension/uBlock/document-blocked.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 18 | 19 |
20 |

_

21 | 25 |
26 | 27 |
28 |

_

29 |

 

30 | 34 |
35 | 36 |
37 | 38 |
39 | 40 |
41 | 42 | 43 | 44 |
45 | 46 | 52 |
53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | -------------------------------------------------------------------------------- /.extension/uBlock/dyna-rules.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock — Dynamic filtering rules 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 |
23 |

info-circle

24 |
25 |
26 |
27 |
28 | 29 | 30 |
31 |
32 |
33 | 34 | 35 | 36 |
37 |
38 |
39 |
40 |
41 | filter  double-angle-up 42 |
43 |
44 | 45 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | -------------------------------------------------------------------------------- /.extension/uBlock/img/cloud.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/cloud.png -------------------------------------------------------------------------------- /.extension/uBlock/img/fontawesome/LICENSE.txt: -------------------------------------------------------------------------------- 1 | # [Font Awesome v4.7.0](http://fontawesome.io) 2 | ### The iconic font and CSS framework 3 | 4 | Font Awesome is a full suite of 675 pictographic icons for easy scalable vector graphics on websites, 5 | created and maintained by [Dave Gandy](https://twitter.com/davegandy). 6 | Stay up to date with the latest release and announcements on Twitter: 7 | [@fontawesome](http://twitter.com/fontawesome). 8 | 9 | Get started at http://fontawesome.io! 10 | 11 | ## License 12 | - The Font Awesome font is licensed under the SIL OFL 1.1: 13 | - http://scripts.sil.org/OFL 14 | - Font Awesome CSS, LESS, and Sass files are licensed under the MIT License: 15 | - https://opensource.org/licenses/mit-license.html 16 | - The Font Awesome documentation is licensed under the CC BY 3.0 License: 17 | - http://creativecommons.org/licenses/by/3.0/ 18 | - Attribution is no longer required as of Font Awesome 3.0, but much appreciated: 19 | - `Font Awesome by Dave Gandy - http://fontawesome.io` 20 | - Full details: http://fontawesome.io/license/ 21 | 22 | ## Author 23 | - Email: dave@fontawesome.io 24 | - Twitter: http://twitter.com/davegandy 25 | - GitHub: https://github.com/davegandy 26 | -------------------------------------------------------------------------------- /.extension/uBlock/img/help16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/help16.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_128.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_128.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_16-loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_16-loading.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_16-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_16-off.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_16.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_16.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_32-loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_32-loading.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_32-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_32-off.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_32.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_64-loading.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_64-loading.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_64-off.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_64-off.png -------------------------------------------------------------------------------- /.extension/uBlock/img/icon_64.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/img/icon_64.png -------------------------------------------------------------------------------- /.extension/uBlock/img/material-design.svg: -------------------------------------------------------------------------------- 1 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | -------------------------------------------------------------------------------- /.extension/uBlock/img/ublock-defs.svg: -------------------------------------------------------------------------------- 1 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /.extension/uBlock/img/ublock.svg: -------------------------------------------------------------------------------- 1 | 2 | 13 | 15 | 18 | 21 | 24 | 25 | 26 | 29 | 36 | 39 | 42 | 43 | 44 | 45 | -------------------------------------------------------------------------------- /.extension/uBlock/is-webrtc-supported.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /.extension/uBlock/js/about.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | import { dom } from './dom.js'; 25 | 26 | /******************************************************************************/ 27 | 28 | (async ( ) => { 29 | const appData = await vAPI.messaging.send('dashboard', { 30 | what: 'getAppData', 31 | }); 32 | 33 | dom.text('#aboutNameVer', appData.name + ' ' + appData.version); 34 | })(); 35 | -------------------------------------------------------------------------------- /.extension/uBlock/js/click2load.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | /******************************************************************************/ 26 | 27 | (( ) => { 28 | 29 | /******************************************************************************/ 30 | 31 | if ( typeof vAPI !== 'object' ) { return; } 32 | 33 | const url = new URL(self.location.href); 34 | const actualURL = url.searchParams.get('url'); 35 | const frameURL = url.searchParams.get('aliasURL') || actualURL; 36 | const frameURLElem = document.getElementById('frameURL'); 37 | 38 | frameURLElem.children[0].textContent = actualURL; 39 | 40 | frameURLElem.children[1].href = frameURL; 41 | frameURLElem.children[1].title = frameURL; 42 | 43 | document.body.setAttribute('title', actualURL); 44 | 45 | document.body.addEventListener('click', ev => { 46 | if ( ev.isTrusted === false ) { return; } 47 | if ( ev.target.closest('#frameURL') !== null ) { return; } 48 | vAPI.messaging.send('default', { 49 | what: 'clickToLoad', 50 | frameURL, 51 | }).then(ok => { 52 | if ( ok ) { 53 | self.location.replace(frameURL); 54 | } 55 | }); 56 | }); 57 | 58 | /******************************************************************************/ 59 | 60 | })(); 61 | -------------------------------------------------------------------------------- /.extension/uBlock/js/console.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | function ubologSet(state = false) { 27 | if ( state ) { 28 | if ( ubolog.process instanceof Function ) { 29 | ubolog.process(); 30 | } 31 | ubolog = ubologDo; 32 | } else { 33 | ubolog = ubologIgnore; 34 | } 35 | } 36 | 37 | function ubologDo(...args) { 38 | console.info('[uBO]', ...args); 39 | } 40 | 41 | function ubologIgnore() { 42 | } 43 | 44 | let ubolog = (( ) => { 45 | const pending = []; 46 | const store = function(...args) { 47 | pending.push(args); 48 | }; 49 | store.process = function() { 50 | for ( const args of pending ) { 51 | ubologDo(...args); 52 | } 53 | }; 54 | return store; 55 | })(); 56 | 57 | /******************************************************************************/ 58 | 59 | export { ubolog, ubologSet }; 60 | -------------------------------------------------------------------------------- /.extension/uBlock/js/filtering-engines.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | import DynamicHostRuleFiltering from './dynamic-net-filtering.js'; 27 | import DynamicSwitchRuleFiltering from './hnswitches.js'; 28 | import DynamicURLRuleFiltering from './url-net-filtering.js'; 29 | 30 | /******************************************************************************/ 31 | 32 | const permanentFirewall = new DynamicHostRuleFiltering(); 33 | const sessionFirewall = new DynamicHostRuleFiltering(); 34 | 35 | const permanentURLFiltering = new DynamicURLRuleFiltering(); 36 | const sessionURLFiltering = new DynamicURLRuleFiltering(); 37 | 38 | const permanentSwitches = new DynamicSwitchRuleFiltering(); 39 | const sessionSwitches = new DynamicSwitchRuleFiltering(); 40 | 41 | /******************************************************************************/ 42 | 43 | export { 44 | permanentFirewall, 45 | sessionFirewall, 46 | permanentURLFiltering, 47 | sessionURLFiltering, 48 | permanentSwitches, 49 | sessionSwitches, 50 | }; 51 | -------------------------------------------------------------------------------- /.extension/uBlock/js/is-webrtc-supported.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015 Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | // https://github.com/gorhill/uBlock/issues/533#issuecomment-164292868 23 | // If WebRTC is supported, there won't be an exception if we 24 | // try to instanciate a peer connection object. 25 | 26 | // https://github.com/gorhill/uBlock/issues/533#issuecomment-168097594 27 | // Because Chromium leaks WebRTC connections after they have been closed 28 | // and forgotten, we need to test for WebRTC support inside an iframe, this 29 | // way the closed and forgottetn WebRTC connections are properly garbage 30 | // collected. 31 | 32 | (function() { 33 | 'use strict'; 34 | 35 | var pc = null; 36 | try { 37 | var PC = self.RTCPeerConnection || self.webkitRTCPeerConnection; 38 | if ( PC ) { 39 | pc = new PC(null); 40 | } 41 | } catch (ex) { 42 | console.error(ex); 43 | } 44 | if ( pc !== null ) { 45 | pc.close(); 46 | } 47 | 48 | window.top.postMessage( 49 | pc !== null ? 'webRTCSupported' : 'webRTCNotSupported', 50 | window.location.origin 51 | ); 52 | })(); 53 | -------------------------------------------------------------------------------- /.extension/uBlock/js/logger.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | let buffer = null; 27 | let lastReadTime = 0; 28 | let writePtr = 0; 29 | 30 | // After 30 seconds without being read, the logger buffer will be considered 31 | // unused, and thus disabled. 32 | const logBufferObsoleteAfter = 30 * 1000; 33 | 34 | const janitorTimer = vAPI.defer.create(( ) => { 35 | if ( buffer === null ) { return; } 36 | if ( lastReadTime >= (Date.now() - logBufferObsoleteAfter) ) { 37 | return janitorTimer.on(logBufferObsoleteAfter); 38 | } 39 | logger.enabled = false; 40 | buffer = null; 41 | writePtr = 0; 42 | logger.ownerId = undefined; 43 | vAPI.messaging.broadcast({ what: 'loggerDisabled' }); 44 | }); 45 | 46 | const boxEntry = function(details) { 47 | if ( details.tstamp === undefined ) { 48 | details.tstamp = Date.now(); 49 | } 50 | return JSON.stringify(details); 51 | }; 52 | 53 | const logger = { 54 | enabled: false, 55 | ownerId: undefined, 56 | writeOne: function(details) { 57 | if ( buffer === null ) { return; } 58 | const box = boxEntry(details); 59 | if ( writePtr === buffer.length ) { 60 | buffer.push(box); 61 | } else { 62 | buffer[writePtr] = box; 63 | } 64 | writePtr += 1; 65 | }, 66 | readAll: function(ownerId) { 67 | this.ownerId = ownerId; 68 | if ( buffer === null ) { 69 | this.enabled = true; 70 | buffer = []; 71 | janitorTimer.on(logBufferObsoleteAfter); 72 | } 73 | const out = buffer.slice(0, writePtr); 74 | writePtr = 0; 75 | lastReadTime = Date.now(); 76 | return out; 77 | }, 78 | }; 79 | 80 | /******************************************************************************/ 81 | 82 | export default logger; 83 | 84 | /******************************************************************************/ 85 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/cosmetic-off.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015-2018 Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | if ( typeof vAPI === 'object' && vAPI.domFilterer ) { 27 | vAPI.domFilterer.toggle(false); 28 | } 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | /******************************************************************************* 38 | 39 | DO NOT: 40 | - Remove the following code 41 | - Add code beyond the following code 42 | Reason: 43 | - https://github.com/gorhill/uBlock/pull/3721 44 | - uBO never uses the return value from injected content scripts 45 | 46 | **/ 47 | 48 | void 0; 49 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/cosmetic-on.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015-2018 Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | if ( typeof vAPI === 'object' && vAPI.domFilterer ) { 27 | vAPI.domFilterer.toggle(true); 28 | } 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | /******************************************************************************* 38 | 39 | DO NOT: 40 | - Remove the following code 41 | - Add code beyond the following code 42 | Reason: 43 | - https://github.com/gorhill/uBlock/pull/3721 44 | - uBO never uses the return value from injected content scripts 45 | 46 | **/ 47 | 48 | void 0; 49 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/dom-survey-elements.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | // https://github.com/uBlockOrigin/uBlock-issues/issues/756 27 | // Keep in mind CPU usage with large DOM and/or filterset. 28 | 29 | (( ) => { 30 | if ( typeof vAPI !== 'object' ) { return; } 31 | 32 | const t0 = Date.now(); 33 | 34 | if ( vAPI.domSurveyElements instanceof Object === false ) { 35 | vAPI.domSurveyElements = { 36 | busy: false, 37 | hiddenElementCount: Number.NaN, 38 | surveyTime: t0, 39 | }; 40 | } 41 | const surveyResults = vAPI.domSurveyElements; 42 | 43 | if ( surveyResults.busy ) { return; } 44 | surveyResults.busy = true; 45 | 46 | if ( surveyResults.surveyTime < vAPI.domMutationTime ) { 47 | surveyResults.hiddenElementCount = Number.NaN; 48 | } 49 | surveyResults.surveyTime = t0; 50 | 51 | if ( isNaN(surveyResults.hiddenElementCount) ) { 52 | surveyResults.hiddenElementCount = (( ) => { 53 | if ( vAPI.domFilterer instanceof Object === false ) { return 0; } 54 | const details = vAPI.domFilterer.getAllSelectors(0b11); 55 | if ( 56 | Array.isArray(details.declarative) === false || 57 | details.declarative.length === 0 58 | ) { 59 | return 0; 60 | } 61 | return document.querySelectorAll( 62 | details.declarative.join(',\n') 63 | ).length; 64 | })(); 65 | } 66 | 67 | surveyResults.busy = false; 68 | 69 | // IMPORTANT: This is returned to the injector, so this MUST be 70 | // the last statement. 71 | return surveyResults.hiddenElementCount; 72 | })(); 73 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/load-3p-css.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2020-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | (( ) => { 27 | if ( typeof vAPI !== 'object' ) { return; } 28 | 29 | if ( vAPI.dynamicReloadToken === undefined ) { 30 | vAPI.dynamicReloadToken = vAPI.randomToken(); 31 | } 32 | 33 | for ( const sheet of Array.from(document.styleSheets) ) { 34 | let loaded = false; 35 | try { 36 | loaded = sheet.rules.length !== 0; 37 | } catch(ex) { 38 | } 39 | if ( loaded ) { continue; } 40 | const link = sheet.ownerNode || null; 41 | if ( link === null || link.localName !== 'link' ) { continue; } 42 | if ( link.hasAttribute(vAPI.dynamicReloadToken) ) { continue; } 43 | const clone = link.cloneNode(true); 44 | clone.setAttribute(vAPI.dynamicReloadToken, ''); 45 | link.replaceWith(clone); 46 | } 47 | })(); 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | /******************************************************************************* 57 | 58 | DO NOT: 59 | - Remove the following code 60 | - Add code beyond the following code 61 | Reason: 62 | - https://github.com/gorhill/uBlock/pull/3721 63 | - uBO never uses the return value from injected content scripts 64 | 65 | **/ 66 | 67 | void 0; 68 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/load-large-media-all.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2015-2018 Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | (( ) => { 27 | 28 | /******************************************************************************/ 29 | 30 | if ( 31 | typeof vAPI !== 'object' || 32 | vAPI.loadAllLargeMedia instanceof Function === false 33 | ) { 34 | return; 35 | } 36 | 37 | vAPI.loadAllLargeMedia(); 38 | vAPI.loadAllLargeMedia = undefined; 39 | 40 | /******************************************************************************/ 41 | 42 | })(); 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | /******************************************************************************* 52 | 53 | DO NOT: 54 | - Remove the following code 55 | - Add code beyond the following code 56 | Reason: 57 | - https://github.com/gorhill/uBlock/pull/3721 58 | - uBO never uses the return value from injected content scripts 59 | 60 | **/ 61 | 62 | void 0; 63 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/noscript-spoof.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | // Code below has been imported from uMatrix and modified to fit uBO: 23 | // https://github.com/gorhill/uMatrix/blob/3f8794dd899a05e066c24066c6c0a2515d5c60d2/src/js/contentscript.js#L464-L531 24 | 25 | 'use strict'; 26 | 27 | /******************************************************************************/ 28 | 29 | // https://github.com/gorhill/uMatrix/issues/232 30 | // Force `display` property, Firefox is still affected by the issue. 31 | 32 | (( ) => { 33 | const noscripts = document.querySelectorAll('noscript'); 34 | if ( noscripts.length === 0 ) { return; } 35 | 36 | const reMetaContent = /^\s*(\d+)\s*;\s*url=(?:"([^"]+)"|'([^']+)'|(.+))/i; 37 | const reSafeURL = /^https?:\/\//; 38 | let redirectTimer; 39 | 40 | const autoRefresh = function(root) { 41 | const meta = root.querySelector('meta[http-equiv="refresh"][content]'); 42 | if ( meta === null ) { return; } 43 | const match = reMetaContent.exec(meta.getAttribute('content')); 44 | if ( match === null ) { return; } 45 | const refreshURL = (match[2] || match[3] || match[4] || '').trim(); 46 | let url; 47 | try { 48 | url = new URL(refreshURL, document.baseURI); 49 | } catch(ex) { 50 | return; 51 | } 52 | if ( reSafeURL.test(url.href) === false ) { return; } 53 | redirectTimer = setTimeout(( ) => { 54 | location.assign(url.href); 55 | }, 56 | parseInt(match[1], 10) * 1000 + 1 57 | ); 58 | meta.parentNode.removeChild(meta); 59 | }; 60 | 61 | const morphNoscript = function(from) { 62 | if ( /^application\/(?:xhtml\+)?xml/.test(document.contentType) ) { 63 | const to = document.createElement('span'); 64 | while ( from.firstChild !== null ) { 65 | to.appendChild(from.firstChild); 66 | } 67 | return to; 68 | } 69 | const parser = new DOMParser(); 70 | const doc = parser.parseFromString( 71 | '' + from.textContent + '', 72 | 'text/html' 73 | ); 74 | return document.adoptNode(doc.querySelector('span')); 75 | }; 76 | 77 | for ( const noscript of noscripts ) { 78 | const parent = noscript.parentNode; 79 | if ( parent === null ) { continue; } 80 | const span = morphNoscript(noscript); 81 | span.style.setProperty('display', 'inline', 'important'); 82 | if ( redirectTimer === undefined ) { 83 | autoRefresh(span); 84 | } 85 | parent.replaceChild(span, noscript); 86 | } 87 | })(); 88 | 89 | /******************************************************************************/ 90 | -------------------------------------------------------------------------------- /.extension/uBlock/js/scriptlets/should-inject-contentscript.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2018-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | // If content scripts are already injected, we need to respond with `false`, 25 | // to "should inject content scripts?" 26 | // 27 | // https://github.com/uBlockOrigin/uBlock-issues/issues/403 28 | // If the content script was not boostrapped, give it another try. 29 | 30 | (( ) => { 31 | try { 32 | let status = vAPI.uBO !== true; 33 | if ( status === false && vAPI.bootstrap ) { 34 | self.requestIdleCallback(( ) => vAPI && vAPI.bootstrap()); 35 | } 36 | return status; 37 | } catch(ex) { 38 | } 39 | return true; 40 | })(); 41 | -------------------------------------------------------------------------------- /.extension/uBlock/js/tasks.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | /* globals requestIdleCallback, cancelIdleCallback */ 23 | 24 | 'use strict'; 25 | 26 | /******************************************************************************/ 27 | 28 | export function queueTask(func, timeout = 5000) { 29 | if ( typeof requestIdleCallback === 'undefined' ) { 30 | return setTimeout(func, 1); 31 | } 32 | 33 | return requestIdleCallback(func, { timeout }); 34 | } 35 | 36 | export function dropTask(id) { 37 | if ( typeof cancelIdleCallback === 'undefined' ) { 38 | return clearTimeout(id); 39 | } 40 | 41 | return cancelIdleCallback(id); 42 | } 43 | -------------------------------------------------------------------------------- /.extension/uBlock/js/text-utils.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /******************************************************************************/ 25 | 26 | // https://bugs.chromium.org/p/v8/issues/detail?id=2869 27 | // orphanizeString is to work around String.slice() potentially causing 28 | // the whole raw filter list to be held in memory just because we cut out 29 | // the title as a substring. 30 | 31 | function orphanizeString(s) { 32 | return JSON.parse(JSON.stringify(s)); 33 | } 34 | 35 | /******************************************************************************/ 36 | 37 | class LineIterator { 38 | constructor(text, offset) { 39 | this.text = text; 40 | this.textLen = this.text.length; 41 | this.offset = offset || 0; 42 | } 43 | next(offset) { 44 | if ( offset !== undefined ) { 45 | this.offset += offset; 46 | } 47 | let lineEnd = this.text.indexOf('\n', this.offset); 48 | if ( lineEnd === -1 ) { 49 | lineEnd = this.text.indexOf('\r', this.offset); 50 | if ( lineEnd === -1 ) { 51 | lineEnd = this.textLen; 52 | } 53 | } 54 | const line = this.text.slice(this.offset, lineEnd); 55 | this.offset = lineEnd + 1; 56 | return line; 57 | } 58 | peek(n) { 59 | const offset = this.offset; 60 | return this.text.slice(offset, offset + n); 61 | } 62 | charCodeAt(offset) { 63 | return this.text.charCodeAt(this.offset + offset); 64 | } 65 | eot() { 66 | return this.offset >= this.textLen; 67 | } 68 | } 69 | 70 | /******************************************************************************/ 71 | 72 | // The field iterator is less CPU-intensive than when using native 73 | // String.split(). 74 | 75 | class FieldIterator { 76 | constructor(sep) { 77 | this.text = ''; 78 | this.sep = sep; 79 | this.sepLen = sep.length; 80 | this.offset = 0; 81 | } 82 | first(text) { 83 | this.text = text; 84 | this.offset = 0; 85 | return this.next(); 86 | } 87 | next() { 88 | let end = this.text.indexOf(this.sep, this.offset); 89 | if ( end === -1 ) { 90 | end = this.text.length; 91 | } 92 | const field = this.text.slice(this.offset, end); 93 | this.offset = end + this.sepLen; 94 | return field; 95 | } 96 | remainder() { 97 | return this.text.slice(this.offset); 98 | } 99 | } 100 | 101 | /******************************************************************************/ 102 | 103 | export { 104 | FieldIterator, 105 | LineIterator, 106 | orphanizeString, 107 | }; 108 | -------------------------------------------------------------------------------- /.extension/uBlock/js/vapi.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2017-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | 'use strict'; 23 | 24 | /* global HTMLDocument, XMLDocument */ 25 | 26 | // For background page, auxiliary pages, and content scripts. 27 | 28 | /******************************************************************************/ 29 | 30 | if ( 31 | self.browser instanceof Object && 32 | self.browser instanceof Element === false 33 | ) { 34 | self.chrome = self.browser; 35 | } else { 36 | self.browser = self.chrome; 37 | } 38 | 39 | /******************************************************************************/ 40 | 41 | // https://bugzilla.mozilla.org/show_bug.cgi?id=1408996#c9 42 | var vAPI = self.vAPI; // jshint ignore:line 43 | 44 | // https://github.com/chrisaljoudi/uBlock/issues/464 45 | // https://github.com/chrisaljoudi/uBlock/issues/1528 46 | // A XMLDocument can be a valid HTML document. 47 | 48 | // https://github.com/gorhill/uBlock/issues/1124 49 | // Looks like `contentType` is on track to be standardized: 50 | // https://dom.spec.whatwg.org/#concept-document-content-type 51 | 52 | // https://forums.lanik.us/viewtopic.php?f=64&t=31522 53 | // Skip text/plain documents. 54 | 55 | if ( 56 | ( 57 | document instanceof HTMLDocument || 58 | document instanceof XMLDocument && 59 | document.createElement('div') instanceof HTMLDivElement 60 | ) && 61 | ( 62 | /^image\/|^text\/plain/.test(document.contentType || '') === false 63 | ) && 64 | ( 65 | self.vAPI instanceof Object === false || vAPI.uBO !== true 66 | ) 67 | ) { 68 | vAPI = self.vAPI = { uBO: true }; 69 | } 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | /******************************************************************************* 79 | 80 | DO NOT: 81 | - Remove the following code 82 | - Add code beyond the following code 83 | Reason: 84 | - https://github.com/gorhill/uBlock/pull/3721 85 | - uBO never uses the return value from injected content scripts 86 | 87 | **/ 88 | 89 | void 0; 90 | -------------------------------------------------------------------------------- /.extension/uBlock/js/wasm/README.md: -------------------------------------------------------------------------------- 1 | ### For code reviewers 2 | 3 | All `wasm` files in that directory where created by compiling the 4 | corresponding `wat` file using the command (using `hntrie.wat`/`hntrie.wasm` 5 | as example): 6 | 7 | wat2wasm hntrie.wat -o hntrie.wasm 8 | 9 | Assuming: 10 | 11 | - The command is executed from within the present directory. 12 | 13 | ### `wat2wasm` tool 14 | 15 | The `wat2wasm` tool can be downloaded from an official WebAssembly project: 16 | . 17 | 18 | ### `wat2wasm` tool online 19 | 20 | You can also use the following online `wat2wasm` tool: 21 | . 22 | 23 | Just paste the whole content of the `wat` file to compile into the WAT pane. 24 | Click "Download" button to retrieve the resulting `wasm` file. -------------------------------------------------------------------------------- /.extension/uBlock/js/wasm/biditrie.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/js/wasm/biditrie.wasm -------------------------------------------------------------------------------- /.extension/uBlock/js/wasm/hntrie.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/js/wasm/hntrie.wasm -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (C) 2017 by Marijn Haverbeke and others 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in 13 | all copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 21 | THE SOFTWARE. 22 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/README.md: -------------------------------------------------------------------------------- 1 | # CodeMirror 2 | 3 | [![Build Status](https://travis-ci.org/codemirror/CodeMirror.svg)](https://travis-ci.org/codemirror/CodeMirror) 4 | [![NPM version](https://img.shields.io/npm/v/codemirror.svg)](https://www.npmjs.org/package/codemirror) 5 | 6 | CodeMirror is a versatile text editor implemented in JavaScript for 7 | the browser. It is specialized for editing code, and comes with over 8 | 100 language modes and various addons that implement more advanced 9 | editing functionality. Every language comes with fully-featured code 10 | and syntax highlighting to help with reading and editing complex code. 11 | 12 | A rich programming API and a CSS theming system are available for 13 | customizing CodeMirror to fit your application, and extending it with 14 | new functionality. 15 | 16 | You can find more information (and the 17 | [manual](https://codemirror.net/doc/manual.html)) on the [project 18 | page](https://codemirror.net). For questions and discussion, use the 19 | [discussion forum](https://discuss.codemirror.net/). 20 | 21 | See 22 | [CONTRIBUTING.md](https://github.com/codemirror/CodeMirror/blob/master/CONTRIBUTING.md) 23 | for contributing guidelines. 24 | 25 | The CodeMirror community aims to be welcoming to everybody. We use the 26 | [Contributor Covenant 27 | (1.1)](http://contributor-covenant.org/version/1/1/0/) as our code of 28 | conduct. 29 | 30 | ### Installation 31 | 32 | Either get the [zip file](https://codemirror.net/codemirror.zip) with 33 | the latest version, or make sure you have [Node](https://nodejs.org/) 34 | installed and run: 35 | 36 | npm install codemirror 37 | 38 | **NOTE**: This is the source repository for the library, and not the 39 | distribution channel. Cloning it is not the recommended way to install 40 | the library, and will in fact not work unless you also run the build 41 | step. 42 | 43 | ### Quickstart 44 | 45 | To build the project, make sure you have Node.js installed (at least version 6) 46 | and then `npm install`. To run, just open `index.html` in your 47 | browser (you don't need to run a webserver). Run the tests with `npm test`. 48 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/addon/fold/foldgutter.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-foldmarker { 2 | color: blue; 3 | text-shadow: #b9f 1px 1px 2px, #b9f -1px -1px 2px, #b9f 1px -1px 2px, #b9f -1px 1px 2px; 4 | font-family: arial; 5 | line-height: .3; 6 | cursor: pointer; 7 | } 8 | .CodeMirror-foldgutter { 9 | width: .7em; 10 | } 11 | .CodeMirror-foldgutter-open, 12 | .CodeMirror-foldgutter-folded { 13 | cursor: pointer; 14 | } 15 | .CodeMirror-foldgutter-open:after { 16 | content: "\25BE"; 17 | } 18 | .CodeMirror-foldgutter-folded:after { 19 | content: "\25B8"; 20 | } 21 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/addon/hint/show-hint.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-hints { 2 | position: absolute; 3 | z-index: 10; 4 | overflow: hidden; 5 | list-style: none; 6 | 7 | margin: 0; 8 | padding: 2px; 9 | 10 | -webkit-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 11 | -moz-box-shadow: 2px 3px 5px rgba(0,0,0,.2); 12 | box-shadow: 2px 3px 5px rgba(0,0,0,.2); 13 | border-radius: 3px; 14 | border: 1px solid silver; 15 | 16 | background: white; 17 | font-size: 90%; 18 | font-family: monospace; 19 | 20 | max-height: 20em; 21 | overflow-y: auto; 22 | } 23 | 24 | .CodeMirror-hint { 25 | margin: 0; 26 | padding: 0 4px; 27 | border-radius: 2px; 28 | white-space: pre; 29 | color: black; 30 | cursor: pointer; 31 | } 32 | 33 | li.CodeMirror-hint-active { 34 | background: #08f; 35 | color: white; 36 | } 37 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/addon/search/matchesonscrollbar.css: -------------------------------------------------------------------------------- 1 | .CodeMirror-search-match { 2 | background: gold; 3 | border-top: 1px solid orange; 4 | border-bottom: 1px solid orange; 5 | -moz-box-sizing: border-box; 6 | box-sizing: border-box; 7 | opacity: .5; 8 | } 9 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/addon/selection/active-line.js: -------------------------------------------------------------------------------- 1 | // CodeMirror, copyright (c) by Marijn Haverbeke and others 2 | // Distributed under an MIT license: https://codemirror.net/LICENSE 3 | 4 | (function(mod) { 5 | if (typeof exports == "object" && typeof module == "object") // CommonJS 6 | mod(require("../../lib/codemirror")); 7 | else if (typeof define == "function" && define.amd) // AMD 8 | define(["../../lib/codemirror"], mod); 9 | else // Plain browser env 10 | mod(CodeMirror); 11 | })(function(CodeMirror) { 12 | "use strict"; 13 | var WRAP_CLASS = "CodeMirror-activeline"; 14 | var BACK_CLASS = "CodeMirror-activeline-background"; 15 | var GUTT_CLASS = "CodeMirror-activeline-gutter"; 16 | 17 | CodeMirror.defineOption("styleActiveLine", false, function(cm, val, old) { 18 | var prev = old == CodeMirror.Init ? false : old; 19 | if (val == prev) return 20 | if (prev) { 21 | cm.off("beforeSelectionChange", selectionChange); 22 | clearActiveLines(cm); 23 | delete cm.state.activeLines; 24 | } 25 | if (val) { 26 | cm.state.activeLines = []; 27 | updateActiveLines(cm, cm.listSelections()); 28 | cm.on("beforeSelectionChange", selectionChange); 29 | } 30 | }); 31 | 32 | function clearActiveLines(cm) { 33 | for (var i = 0; i < cm.state.activeLines.length; i++) { 34 | cm.removeLineClass(cm.state.activeLines[i], "wrap", WRAP_CLASS); 35 | cm.removeLineClass(cm.state.activeLines[i], "background", BACK_CLASS); 36 | cm.removeLineClass(cm.state.activeLines[i], "gutter", GUTT_CLASS); 37 | } 38 | } 39 | 40 | function sameArray(a, b) { 41 | if (a.length != b.length) return false; 42 | for (var i = 0; i < a.length; i++) 43 | if (a[i] != b[i]) return false; 44 | return true; 45 | } 46 | 47 | function updateActiveLines(cm, ranges) { 48 | var active = []; 49 | for (var i = 0; i < ranges.length; i++) { 50 | var range = ranges[i]; 51 | var option = cm.getOption("styleActiveLine"); 52 | if (typeof option == "object" && option.nonEmpty ? range.anchor.line != range.head.line : !range.empty()) 53 | continue 54 | var line = cm.getLineHandleVisualStart(range.head.line); 55 | if (active[active.length - 1] != line) active.push(line); 56 | } 57 | if (sameArray(cm.state.activeLines, active)) return; 58 | cm.operation(function() { 59 | clearActiveLines(cm); 60 | for (var i = 0; i < active.length; i++) { 61 | cm.addLineClass(active[i], "wrap", WRAP_CLASS); 62 | cm.addLineClass(active[i], "background", BACK_CLASS); 63 | cm.addLineClass(active[i], "gutter", GUTT_CLASS); 64 | } 65 | cm.state.activeLines = active; 66 | }); 67 | } 68 | 69 | function selectionChange(cm, sel) { 70 | updateActiveLines(cm, sel.ranges); 71 | } 72 | }); 73 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/codemirror/theme/night.css: -------------------------------------------------------------------------------- 1 | /* Loosely based on the Midnight Textmate theme */ 2 | 3 | .cm-s-night.CodeMirror { background: #0a001f; color: #f8f8f8; } 4 | .cm-s-night div.CodeMirror-selected { background: #447; } 5 | .cm-s-night .CodeMirror-line::selection, .cm-s-night .CodeMirror-line > span::selection, .cm-s-night .CodeMirror-line > span > span::selection { background: rgba(68, 68, 119, .99); } 6 | .cm-s-night .CodeMirror-line::-moz-selection, .cm-s-night .CodeMirror-line > span::-moz-selection, .cm-s-night .CodeMirror-line > span > span::-moz-selection { background: rgba(68, 68, 119, .99); } 7 | .cm-s-night .CodeMirror-gutters { background: #0a001f; border-right: 1px solid #aaa; } 8 | .cm-s-night .CodeMirror-guttermarker { color: white; } 9 | .cm-s-night .CodeMirror-guttermarker-subtle { color: #bbb; } 10 | .cm-s-night .CodeMirror-linenumber { color: #f8f8f8; } 11 | .cm-s-night .CodeMirror-cursor { border-left: 1px solid white; } 12 | 13 | .cm-s-night span.cm-comment { color: #8900d1; } 14 | .cm-s-night span.cm-atom { color: #845dc4; } 15 | .cm-s-night span.cm-number, .cm-s-night span.cm-attribute { color: #ffd500; } 16 | .cm-s-night span.cm-keyword { color: #599eff; } 17 | .cm-s-night span.cm-string { color: #37f14a; } 18 | .cm-s-night span.cm-meta { color: #7678e2; } 19 | .cm-s-night span.cm-variable-2, .cm-s-night span.cm-tag { color: #99b2ff; } 20 | .cm-s-night span.cm-variable-3, .cm-s-night span.cm-def, .cm-s-night span.cm-type { color: white; } 21 | .cm-s-night span.cm-bracket { color: #8da6ce; } 22 | .cm-s-night span.cm-builtin, .cm-s-night span.cm-special { color: #ff9e59; } 23 | .cm-s-night span.cm-link { color: #845dc4; } 24 | .cm-s-night span.cm-error { color: #9d1e15; } 25 | 26 | .cm-s-night .CodeMirror-activeline-background { background: #1C005A; } 27 | .cm-s-night .CodeMirror-matchingbracket { outline:1px solid grey; color:white !important; } 28 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/csstree/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (C) 2016-2022 by Roman Dvornov 2 | 3 | Permission is hereby granted, free of charge, to any person obtaining a copy 4 | of this software and associated documentation files (the "Software"), to deal 5 | in the Software without restriction, including without limitation the rights 6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 7 | copies of the Software, and to permit persons to whom the Software is 8 | furnished to do so, subject to the following conditions: 9 | 10 | The above copyright notice and this permission notice shall be included in 11 | all copies or substantial portions of the Software. 12 | 13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 19 | THE SOFTWARE. 20 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/diff/README.md: -------------------------------------------------------------------------------- 1 | # diff 2 | 3 | implementation of myers diff algorithm 4 | 5 | [![Build Status](https://travis-ci.org/Swatinem/diff.png?branch=master)](https://travis-ci.org/Swatinem/diff) 6 | [![Coverage Status](https://coveralls.io/repos/Swatinem/diff/badge.png?branch=master)](https://coveralls.io/r/Swatinem/diff) 7 | [![Dependency Status](https://gemnasium.com/Swatinem/diff.png)](https://gemnasium.com/Swatinem/diff) 8 | 9 | 10 | This uses the [*An O(ND) Difference Algorithm and Its Variations*](http://www.xmailserver.org/diff2.pdf) 11 | Also see http://simplygenius.net/Article/DiffTutorial2 and 12 | http://www.mathertel.de/Diff/ViewSrc.aspx for more inspiration 13 | 14 | ## Installation 15 | 16 | $ npm install diff 17 | $ component install Swatinem/diff 18 | 19 | ## Usage 20 | 21 | ### diff(a, b, [eql(a, b)]) 22 | 23 | Given two arrays (or array-likes, such as strings) `a` and `b` and an optional 24 | equal function `eql`, this will return an array with the following operations: 25 | * *nop* the element is in both arrays 26 | * *ins* the element is only in array `b` and will be inserted 27 | * *del* the element in only in array `a` and will be removed 28 | * *rep* the element from `a` will be replaced by the element from `b`. 29 | This is essentially the same as a del+ins 30 | 31 | ## License 32 | 33 | LGPLv3 34 | 35 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/hsluv/LICENSE: -------------------------------------------------------------------------------- 1 | Copyright (c) 2012-2021 Alexei Boronine 2 | Copyright (c) 2016 Florian Dormont 3 | 4 | Permission is hereby granted, free of charge, to any person obtaining a copy 5 | of this software and associated documentation files (the "Software"), to deal 6 | in the Software without restriction, including without limitation the rights 7 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | copies of the Software, and to permit persons to whom the Software is 9 | furnished to do so, subject to the following conditions: 10 | 11 | The above copyright notice and this permission notice shall be included in all 12 | copies or substantial portions of the Software. 13 | 14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 20 | SOFTWARE. 21 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/hsluv/README: -------------------------------------------------------------------------------- 1 | Source: 2 | 3 | https://github.com/hsluv/hsluv/blob/9cd8574fad8874828b3a8119843527d62d79887a/javascript/dist/hsluv-0.1.0.min.js 4 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/hsluv/hsluv-0.1.0.min.js: -------------------------------------------------------------------------------- 1 | (function() {function f(a){var c=[],b=Math.pow(a+16,3)/1560896;b=b>g?b:a/k;for(var d=0;3>d;){var e=d++,h=l[e][0],w=l[e][1];e=l[e][2];for(var x=0;2>x;){var y=x++,z=(632260*e-126452*w)*b+126452*y;c.push({b:(284517*h-94839*e)*b/z,a:((838422*e+769860*w+731718*h)*a*b-769860*y*a)/z})}}return c}function m(a){a=f(a);for(var c=Infinity,b=0;b=a?12.92*a:1.055*Math.pow(a,.4166666666666667)-.055}function r(a){return.04045=c?B*c/k:B*Math.pow((c+16)/116,3);b=0-9*c*b/((b-4)*a-b*a);return[b,c,(9*c-15*a*c-a*b)/(3*a)]} 4 | function F(a){var c=a[0],b=a[1],d=a[2];a=Math.sqrt(b*b+d*d);1E-8>a?b=0:(b=180*Math.atan2(d,b)/Math.PI,0>b&&(b=360+b));return[c,a,b]}function G(a){var c=a[1],b=a[2]/360*2*Math.PI;return[a[0],Math.cos(b)*c,Math.sin(b)*c]}function H(a){var c=a[0],b=a[1];a=a[2];if(99.9999999a)return[0,0,c];b=n(a,c)/100*b;return[a,b,c]}function I(a){var c=a[0],b=a[1];a=a[2];if(99.9999999c)return[a,0,0];var d=n(c,a);return[a,b/d*100,c]} 5 | function J(a){var c=a[0],b=a[1];a=a[2];if(99.9999999a)return[0,0,c];b=m(a)/100*b;return[a,b,c]}function K(a){var c=a[0],b=a[1];a=a[2];if(99.9999999c)return[a,0,0];var d=m(c);return[a,b/d*100,c]}function L(a){for(var c="#",b=0;3>b;){var d=b++;d=Math.round(255*a[d]);var e=d%16;c+=M.charAt((d-e)/16|0)+M.charAt(e)}return c} 6 | function N(a){a=a.toLowerCase();for(var c=[],b=0;3>b;){var d=b++;c.push((16*M.indexOf(a.charAt(2*d+1))+M.indexOf(a.charAt(2*d+2)))/255)}return c}function O(a){return t(E(G(a)))}function P(a){return F(A(u(a)))}function Q(a){return O(H(a))}function R(a){return I(P(a))}function S(a){return O(J(a))}function T(a){return K(P(a))} 7 | var l=[[3.240969941904521,-1.537383177570093,-.498610760293],[-.96924363628087,1.87596750150772,.041555057407175],[.055630079696993,-.20397695888897,1.056971514242878]],v=[[.41239079926595,.35758433938387,.18048078840183],[.21263900587151,.71516867876775,.072192315360733],[.019330818715591,.11919477979462,.95053215224966]],B=1,C=.19783000664283,D=.46831999493879,k=903.2962962,g=.0088564516,M="0123456789abcdef"; 8 | window.hsluv={hsluvToRgb:Q,rgbToHsluv:R,hpluvToRgb:S,rgbToHpluv:T,hsluvToHex:function(a){return L(Q(a))},hexToHsluv:function(a){return R(N(a))},hpluvToHex:function(a){return L(S(a))},hexToHpluv:function(a){return T(N(a))},lchToHpluv:K,hpluvToLch:J,lchToHsluv:I,hsluvToLch:H,lchToLuv:G,luvToLch:F,xyzToLuv:A,luvToXyz:E,xyzToRgb:t,rgbToXyz:u,lchToRgb:O,rgbToLch:P};})(); 9 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/js-beautify/LICENSE: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2007-2018 Einar Lielmanis, Liam Newman, and contributors. 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | 7 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/js-beautify/README: -------------------------------------------------------------------------------- 1 | Project repo: 2 | https://github.com/beautify-web/js-beautify 3 | 4 | Source: 5 | https://cdnjs.cloudflare.com/ajax/libs/js-beautify/1.14.7/beautifier.min.js 6 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/lz4/README.md: -------------------------------------------------------------------------------- 1 | ## Purpose 2 | 3 | The purpose of this library is to implement LZ4 compression/decompression, 4 | as documented at the official LZ4 repository: 5 | 6 | https://github.com/lz4/lz4/blob/dev/doc/lz4_Block_format.md 7 | 8 | The files in this directory are developed as a separate project at: 9 | 10 | https://github.com/gorhill/lz4-wasm 11 | 12 | ## Files 13 | 14 | ### `lz4-block-codec-any.js` 15 | 16 | The purpose is to instanciate a WebAssembly- or pure javascript-based 17 | LZ4 block codec. 18 | 19 | If the chosen implementation is not specified, there will be an attempt to 20 | create a WebAssembly-based instance. If for whatever reason this fails, a 21 | pure javascript-based instance will be created. 22 | 23 | The script for either instance are dynamically loaded and only when needed, 24 | such that no resources are wasted by keeping in memory code which won't be 25 | used. 26 | 27 | ### `lz4-block-codec-wasm.js` 28 | 29 | This contains the code to instanciate WebAssembly-based LZ4 block codec. Note 30 | that the WebAssembly module is loaded using a `same-origin` fetch, hence 31 | ensuring that no code outside the package is loaded. 32 | 33 | ### `lz4-block-codec-js.js` 34 | 35 | This contains the code to instanciate pure javascript-based LZ4 block codec. 36 | 37 | This is used as a fallback implementation should WebAssembly not be available 38 | for whatever reason. 39 | 40 | ### `lz4-block-codec.wasm` 41 | 42 | This is the WebAssembly module, loaded by `lz4-block-codec-wasm.js` using a 43 | `same-origin` fetch. 44 | 45 | ### `lz4-block-codec.wat` 46 | 47 | The WebAssembly source code used to generate the WebAssembly module `lz4-block-codec.wasm`. 48 | 49 | wat2wasm ./lz4-block-codec.wat -o ./lz4-block-codec.wasm 50 | wasm-opt ./lz4-block-codec.wasm -O4 -o ./lz4-block-codec.wasm 51 | 52 | You can get `wat2wasm` at , and `wasm-opt` at . 53 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/lz4/lz4-block-codec.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/lib/lz4/lz4-block-codec.wasm -------------------------------------------------------------------------------- /.extension/uBlock/lib/publicsuffixlist/wasm/README.md: -------------------------------------------------------------------------------- 1 | ### For code reviewers 2 | 3 | All `wasm` files in that directory where created by compiling the 4 | corresponding `wat` file using the command (using 5 | `publicsuffixlist.wat`/`publicsuffixlist.wasm` as example): 6 | 7 | wat2wasm publicsuffixlist.wat -o publicsuffixlist.wasm 8 | 9 | Assuming: 10 | 11 | - The command is executed from within the present directory. 12 | 13 | ### `wat2wasm` tool 14 | 15 | The `wat2wasm` tool can be downloaded from an official WebAssembly project: 16 | . 17 | 18 | ### `wat2wasm` tool online 19 | 20 | You can also use the following online `wat2wasm` tool: 21 | . 22 | 23 | Just paste the whole content of the `wat` file to compile into the WAT pane. 24 | Click "Download" button to retrieve the resulting `wasm` file. 25 | 26 | ### See also 27 | 28 | For the curious, the following online tool allows you to find out the machine 29 | code as a result from the WASM code: https://mbebenita.github.io/WasmExplorer/ 30 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/publicsuffixlist/wasm/publicsuffixlist.wasm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/lib/publicsuffixlist/wasm/publicsuffixlist.wasm -------------------------------------------------------------------------------- /.extension/uBlock/lib/regexanalyzer/CHANGES.md: -------------------------------------------------------------------------------- 1 | # Regex Analyzer 2 | 3 | Imported from: 4 | Author: Nikos M. 5 | 6 | ## Changes to the imported library 7 | 8 | #### Date 9 | 10 | 2023-01-01 11 | 12 | Imported version 1.2.0 of the library from 13 | https://github.com/foo123/RegexAnalyzer/blob/1.2.0/src/js/Regex.js 14 | 15 | Minimally modified the code to make it ECMAscript `export`-/`import`-friendly. 16 | -------------------------------------------------------------------------------- /.extension/uBlock/lib/regexanalyzer/README.md: -------------------------------------------------------------------------------- 1 | https://github.com/foo123/RegexAnalyzer/issues/1#issuecomment-750039255 2 | 3 | > The (implied) license is as free as it can get. You can modify it and use 4 | > it anywhere you want if it suits you. 5 | > 6 | > An attribution to original author would be appreciated but even this is not 7 | > mandatory. 8 | > 9 | > Copy Left 10 | 11 | References: 12 | 13 | - https://en.wikipedia.org/wiki/Copyleft 14 | - http://gplv3.fsf.org/wiki/index.php/Compatible_licenses 15 | -------------------------------------------------------------------------------- /.extension/uBlock/managed_storage.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://json-schema.org/draft-03/schema#", 3 | "type": "object", 4 | "properties": { 5 | "adminSettings": { 6 | "title": "A valid JSON string compliant with uBO's backup format", 7 | "description": "All entries present will overwrite local settings.", 8 | "type": "string" 9 | }, 10 | "advancedSettings": { 11 | "title": "A list of [name,value] pairs to populate advanced settings", 12 | "type": "array", 13 | "items": { 14 | "title": "A [name,value] pair", 15 | "type": "array", 16 | "items": { "type": "string" } 17 | } 18 | }, 19 | "userSettings": { 20 | "title": "A list of [name,value] pairs to populate user settings", 21 | "type": "array", 22 | "items": { 23 | "title": "A [name,value] pair", 24 | "type": "array", 25 | "items": { "type": "string" } 26 | } 27 | }, 28 | "disableDashboard": { 29 | "title": "Set to true to prevent access to configuration options", 30 | "type": "boolean" 31 | }, 32 | "disabledPopupPanelParts": { 33 | "title": "An array of strings used to remove parts of the popup panel", 34 | "type": "array", 35 | "items": { "type": "string" } 36 | }, 37 | "toAdd": { 38 | "title": "Settings to add at launch time", 39 | "type": "object", 40 | "properties": { 41 | "trustedSiteDirectives": { 42 | "title": "A list of trusted-site directives", 43 | "description": "Trusted-site directives to always add at launch time.", 44 | "type": "array", 45 | "items": { "type": "string" } 46 | } 47 | } 48 | }, 49 | "toOverwrite": { 50 | "title": "Settings to overwrite at launch time", 51 | "type": "object", 52 | "properties": { 53 | "filters": { 54 | "title": "A collection of filters", 55 | "description": "The set of user filters to use at launch time -- where each entry is a distinct line.", 56 | "type": "array", 57 | "items": { "type": "string" } 58 | }, 59 | "filterLists": { 60 | "title": "A collection of list identifiers and/or list URLs", 61 | "description": "The set of filter lists to use at launch time.", 62 | "type": "array", 63 | "items": { "type": "string" } 64 | }, 65 | "trustedSiteDirectives": { 66 | "title": "A list of trusted-site directives", 67 | "type": "array", 68 | "items": { "type": "string" } 69 | } 70 | } 71 | } 72 | } 73 | } 74 | -------------------------------------------------------------------------------- /.extension/uBlock/manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "author": "Raymond Hill & contributors", 3 | "background": { 4 | "page": "background.html" 5 | }, 6 | "browser_action": { 7 | "default_icon": { 8 | "16": "img/icon_16.png", 9 | "32": "img/icon_32.png", 10 | "64": "img/icon_64.png" 11 | }, 12 | "default_popup": "popup-fenix.html", 13 | "default_title": "uBlock Origin" 14 | }, 15 | "commands": { 16 | "launch-element-picker": { 17 | "description": "__MSG_popupTipPicker__" 18 | }, 19 | "launch-element-zapper": { 20 | "description": "__MSG_popupTipZapper__" 21 | }, 22 | "launch-logger": { 23 | "description": "__MSG_popupTipLog__" 24 | }, 25 | "open-dashboard": { 26 | "description": "__MSG_popupTipDashboard__" 27 | }, 28 | "relax-blocking-mode": { 29 | "description": "__MSG_relaxBlockingMode__" 30 | }, 31 | "toggle-cosmetic-filtering": { 32 | "description": "__MSG_toggleCosmeticFiltering__" 33 | } 34 | }, 35 | "content_scripts": [ { 36 | "all_frames": true, 37 | "js": [ "/js/vapi.js", "/js/vapi-client.js", "/js/contentscript.js" ], 38 | "match_about_blank": true, 39 | "matches": [ "http://*/*", "https://*/*" ], 40 | "run_at": "document_start" 41 | }, { 42 | "all_frames": false, 43 | "js": [ "/js/scriptlets/subscriber.js" ], 44 | "matches": [ "https://easylist.to/*", "https://*.fanboy.co.nz/*", "https://filterlists.com/*", "https://forums.lanik.us/*", "https://github.com/*", "https://*.github.io/*", "https://*.letsblock.it/*" ], 45 | "run_at": "document_idle" 46 | } ], 47 | "content_security_policy": "script-src 'self'; object-src 'self'", 48 | "default_locale": "en", 49 | "description": "__MSG_extShortDesc__", 50 | "icons": { 51 | "128": "img/icon_128.png", 52 | "16": "img/icon_16.png", 53 | "32": "img/icon_32.png", 54 | "64": "img/icon_64.png" 55 | }, 56 | "incognito": "split", 57 | "key": "MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEAtej8nZ6GDzzNjLD1WCjkbCf15gZlrgzMn9To0ef+6Tiyk6uDSePSaaiMG+8rNgTCQM1ES6Hy8XzTJf8o19ldg1GXHE4MAdjjzDNv3ya05Vj71r/dzI9OyL45DnshMYdW7lyzHp7nt1L5uWtmZs4MiOO43RrWzrGuvhhUdQm9rz4nOgu9q7FWqZP6kUYL42TJgQ6Sc0Qu25TshDdJME3uK5z/kV3BNlmQFDhuAXQZKP/KCV2ogG7R/VcHj1a2ETjRFMQxtQUaWtCmpDYw7URD4CuRNy9LBTylNASfFCHLAEc9MWqFD1Alj63o+WsqBP/h81Vs7nH6PnXQg9+fOCpMyQIDAQAB", 58 | "manifest_version": 2, 59 | "minimum_chrome_version": "73.0", 60 | "name": "uBlock Origin", 61 | "options_ui": { 62 | "open_in_tab": true, 63 | "page": "dashboard.html" 64 | }, 65 | "permissions": [ "contextMenus", "privacy", "storage", "tabs", "unlimitedStorage", "webNavigation", "webRequest", "webRequestBlocking", "\u003Call_urls>" ], 66 | "short_name": "uBlock₀", 67 | "storage": { 68 | "managed_schema": "managed_storage.json" 69 | }, 70 | "update_url": "https://edge.microsoft.com/extensionwebstorebase/v1/crx", 71 | "version": "1.49.2", 72 | "web_accessible_resources": [ "/web_accessible_resources/*" ] 73 | } 74 | -------------------------------------------------------------------------------- /.extension/uBlock/no-dashboard.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock — About 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | Your administrator removed the ability to access the dashboard 16 |
17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/1x1.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/1x1.gif -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/2x2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/2x2.png -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/32x32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/32x32.png -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/3x2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/3x2.png -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/README.txt: -------------------------------------------------------------------------------- 1 | IMPORTANT 2 | 3 | Content of this folder cannot be accessed without the internal secret token 4 | created for each request to any of the "web accessible resources". 5 | 6 | Any fetch operation made without uBlock Origin's internal secret will result 7 | in failure. This means that despite the content of the folder here declared as 8 | "web accessible resources", it still cannot be seen by the outside world. 9 | 10 | Only uBlock Origin knows the secret token at runtime and hence only 11 | uBlock Origin can access the content of this folder. 12 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/addthis_widget.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | window.addthis = { 27 | addEventListener: noopfn, 28 | button: noopfn, 29 | counter: noopfn, 30 | init: noopfn, 31 | layers: noopfn, 32 | ready: noopfn, 33 | sharecounters: { 34 | getShareCounts: noopfn 35 | }, 36 | toolbox: noopfn, 37 | update: noopfn 38 | }; 39 | })(); 40 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/amazon_ads.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | if ( amznads ) { 25 | return; 26 | } 27 | var w = window; 28 | var noopfn = function() { 29 | ; 30 | }.bind(); 31 | var amznads = { 32 | appendScriptTag: noopfn, 33 | appendTargetingToAdServerUrl: noopfn, 34 | appendTargetingToQueryString: noopfn, 35 | clearTargetingFromGPTAsync: noopfn, 36 | doAllTasks: noopfn, 37 | doGetAdsAsync: noopfn, 38 | doTask: noopfn, 39 | detectIframeAndGetURL: noopfn, 40 | getAds: noopfn, 41 | getAdsAsync: noopfn, 42 | getAdForSlot: noopfn, 43 | getAdsCallback: noopfn, 44 | getDisplayAds: noopfn, 45 | getDisplayAdsAsync: noopfn, 46 | getDisplayAdsCallback: noopfn, 47 | getKeys: noopfn, 48 | getReferrerURL: noopfn, 49 | getScriptSource: noopfn, 50 | getTargeting: noopfn, 51 | getTokens: noopfn, 52 | getValidMilliseconds: noopfn, 53 | getVideoAds: noopfn, 54 | getVideoAdsAsync: noopfn, 55 | getVideoAdsCallback: noopfn, 56 | handleCallBack: noopfn, 57 | hasAds: noopfn, 58 | renderAd: noopfn, 59 | saveAds: noopfn, 60 | setTargeting: noopfn, 61 | setTargetingForGPTAsync: noopfn, 62 | setTargetingForGPTSync: noopfn, 63 | tryGetAdsAsync: noopfn, 64 | updateAds: noopfn 65 | }; 66 | w.amznads = amznads; 67 | w.amzn_ads = w.amzn_ads || noopfn; 68 | w.aax_write = w.aax_write || noopfn; 69 | w.aax_render_ad = w.aax_render_ad || noopfn; 70 | })(); 71 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/amazon_apstag.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | // https://www.reddit.com/r/uBlockOrigin/comments/ghjqph/ 23 | // https://github.com/NanoMeow/QuickReports/issues/3717 24 | // https://www.reddit.com/r/uBlockOrigin/comments/qyx7en/ 25 | 26 | // https://searchfox.org/mozilla-central/source/browser/extensions/webcompat/shims/apstag.js 27 | // Import queue-related initialization code. 28 | 29 | (function() { 30 | 'use strict'; 31 | const w = window; 32 | const noopfn = function() { 33 | ; // jshint ignore:line 34 | }.bind(); 35 | const _Q = w.apstag && w.apstag._Q || []; 36 | const apstag = { 37 | _Q, 38 | fetchBids: function(a, b) { 39 | if ( typeof b === 'function' ) { 40 | b([]); 41 | } 42 | }, 43 | init: noopfn, 44 | setDisplayBids: noopfn, 45 | targetingKeys: noopfn, 46 | }; 47 | w.apstag = apstag; 48 | _Q.push = function(prefix, args) { 49 | try { 50 | switch (prefix) { 51 | case 'f': 52 | apstag.fetchBids(...args); 53 | break; 54 | } 55 | } catch (e) { 56 | console.trace(e); 57 | } 58 | }; 59 | for ( const cmd of _Q ) { 60 | _Q.push(cmd); 61 | } 62 | })(); 63 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/ampproject_v0.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const head = document.head; 25 | if ( !head ) { return; } 26 | const style = document.createElement('style'); 27 | style.textContent = [ 28 | 'body {', 29 | ' animation: none !important;', 30 | ' overflow: unset !important;', 31 | '}' 32 | ].join('\n'); 33 | head.appendChild(style); 34 | })(); 35 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/chartbeat.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | window.pSUPERFLY = { 27 | activity: noopfn, 28 | virtualPage: noopfn 29 | }; 30 | })(); 31 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/click2load.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock Origin Click-to-Load 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/doubleclick_instream_ad_status.js: -------------------------------------------------------------------------------- 1 | window.google_ad_status = 1; 2 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/empty: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/empty -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/epicker-ui.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | uBlock Origin Element Picker 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/fingerprint2.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2014-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | let browserId = ''; 25 | for ( let i = 0; i < 8; i++ ) { 26 | browserId += (Math.random() * 0x10000 + 0x1000 | 0).toString(16).slice(-4); 27 | } 28 | const fp2 = function(){}; 29 | fp2.get = function(opts, cb) { 30 | if ( !cb ) { cb = opts; } 31 | setTimeout(( ) => { cb(browserId, []); }, 1); 32 | }; 33 | fp2.prototype = { 34 | get: fp2.get 35 | }; 36 | window.Fingerprint2 = fp2; 37 | })(); 38 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/fingerprint3.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2022-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const visitorId = (( ) => { 25 | let id = ''; 26 | for ( let i = 0; i < 8; i++ ) { 27 | id += (Math.random() * 0x10000 + 0x1000 | 0).toString(16).slice(-4); 28 | } 29 | return id; 30 | })(); 31 | const FingerprintJS = class { 32 | static hashComponents() { 33 | return visitorId; 34 | } 35 | static load() { 36 | return Promise.resolve(new FingerprintJS()); 37 | } 38 | get() { 39 | return Promise.resolve({ 40 | visitorId, 41 | }); 42 | } 43 | }; 44 | window.FingerprintJS = FingerprintJS; 45 | })(); 46 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/google-analytics_cx_api.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | window.cxApi = { 27 | chooseVariation: function() { 28 | return 0; 29 | }, 30 | getChosenVariation: noopfn, 31 | setAllowHash: noopfn, 32 | setChosenVariation: noopfn, 33 | setCookiePath: noopfn, 34 | setDomainName: noopfn 35 | }; 36 | })(); 37 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/google-analytics_inpage_linkid.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | window._gaq = window._gaq || { 25 | push: function() { 26 | } 27 | }; 28 | })(); 29 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/googlesyndication_adsbygoogle.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const init = ( ) => { 25 | window.adsbygoogle = { 26 | loaded: true, 27 | push: function() { 28 | } 29 | }; 30 | const phs = document.querySelectorAll('.adsbygoogle'); 31 | const css = 'height:1px!important;max-height:1px!important;max-width:1px!important;width:1px!important;'; 32 | for ( let i = 0; i < phs.length; i++ ) { 33 | const id = `aswift_${i}`; 34 | if ( document.querySelector(`iframe#${id}`) !== null ) { continue; } 35 | const fr = document.createElement('iframe'); 36 | fr.id = id; 37 | fr.style = css; 38 | const cfr = document.createElement('iframe'); 39 | cfr.id = `google_ads_frame${i}`; 40 | fr.appendChild(cfr); 41 | phs[i].appendChild(fr); 42 | } 43 | }; 44 | if ( 45 | document.querySelectorAll('.adsbygoogle').length === 0 && 46 | document.readyState === 'loading' 47 | ) { 48 | window.addEventListener('DOMContentLoaded', init, { once: true }); 49 | } else { 50 | init(); 51 | } 52 | })(); 53 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/googletagmanager_gtm.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | const w = window; 27 | w.ga = w.ga || noopfn; 28 | const dl = w.dataLayer; 29 | if ( dl instanceof Object === false ) { return; } 30 | if ( dl.hide instanceof Object && typeof dl.hide.end === 'function' ) { 31 | dl.hide.end(); 32 | } 33 | if ( typeof dl.push === 'function' ) { 34 | dl.push = function(o) { 35 | if ( 36 | o instanceof Object && 37 | typeof o.eventCallback === 'function' 38 | ) { 39 | setTimeout(o.eventCallback, 1); 40 | } 41 | }; 42 | } 43 | })(); 44 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/hd-main.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const l = {}; 25 | const noopfn = function() { 26 | }; 27 | const props = [ 28 | "$j","Ad","Bd","Cd","Dd","Ed","Fd","Gd","Hd","Id","Jd","Nj","Oc","Pc","Pe", 29 | "Qc","Qe","Rc","Re","Ri","Sc","Tc","Uc","Vc","Wc","Wg","Xc","Xg","Yc","Yd", 30 | "ad","ae","bd","bf","cd","dd","ed","ef","ek","fd","fg","fh","fk","gd","hd", 31 | "ig","ij","jd","kd","ke","ld","md","mi","nd","od","oh","pd","pf","qd","rd", 32 | "sd","td","ud","vd","wd","wg","xd","xh","yd","zd", 33 | "$d","$e","$k","Ae","Af","Aj","Be","Ce","De","Ee","Ek","Eo","Ep","Fe","Fo", 34 | "Ge","Gh","Hk","Ie","Ip","Je","Ke","Kk","Kq","Le","Lh","Lk","Me","Mm","Ne", 35 | "Oe","Pe","Qe","Re","Rp","Se","Te","Ue","Ve","Vp","We","Xd","Xe","Yd","Ye", 36 | "Zd","Ze","Zf","Zk","ae","af","al","be","bf","bg","ce","cp","df","di","ee", 37 | "ef","fe","ff","gf","gm","he","hf","ie","je","jf","ke","kf","kl","le","lf", 38 | "lk","mf","mg","mn","nf","oe","of","pe","pf","pg","qe","qf","re","rf","se", 39 | "sf","te","tf","ti","ue","uf","ve","vf","we","wf","wg","wi","xe","ye","yf", 40 | "yk","yl","ze","zf","zk" 41 | ]; 42 | for ( let i = 0; i < props.length; i++ ) { 43 | l[props[i]] = noopfn; 44 | } 45 | window.L = window.J = l; 46 | })(); 47 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/ligatus_angular-tag.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | self.adProtect = true; 25 | Object.defineProperties(window, { 26 | uabpdl: { value: true }, 27 | uabDetect: { value: true } 28 | }); 29 | })(); 30 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/monkeybroker.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | window.pbjs = { libLoaded: true }; 27 | const mb = window.MonkeyBroker || { 28 | addAttribute: noopfn, 29 | addSlot: function(a) { 30 | this.slots[a.slot] = {}; 31 | }, 32 | defineSlot: noopfn, 33 | fillSlot: noopfn, 34 | go: noopfn, 35 | inventoryConditionalPlacement: noopfn, 36 | registerSizeCallback: noopfn, 37 | registerSlotCallback: noopfn, 38 | slots: {}, 39 | version: '' 40 | }; 41 | mb.regSlotsMap = mb.slots; 42 | window.MonkeyBroker = mb; 43 | })(); 44 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/mxpnl_mixpanel.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2021-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | // https://developer.mixpanel.com/docs/javascript-full-api-reference 25 | const mixpanel = { 26 | get_distinct_id() { 27 | return ''; 28 | }, 29 | init(t, cfg) { 30 | if ( cfg instanceof Object === false ) { return; } 31 | if ( 'loaded' in cfg === false ) { return; } 32 | if ( cfg.loaded instanceof Function === false ) { return; } 33 | cfg.loaded(); 34 | }, 35 | register() { 36 | }, 37 | register_once() { 38 | }, 39 | track() { 40 | const cb = Array.from(arguments).pop(); 41 | if ( cb instanceof Function === false ) { return; } 42 | cb(); 43 | }, 44 | }; 45 | const q = self.mixpanel && self.mixpanel._i || []; 46 | self.mixpanel = mixpanel; 47 | for ( const i of q ) { 48 | if ( Array.isArray(i) === false ) { continue; } 49 | mixpanel.init(...i); 50 | } 51 | })(); 52 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/nobab.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const signatures = [ 25 | [ 'blockadblock' ], 26 | [ 'babasbm' ], 27 | [ /getItem\('babn'\)/ ], 28 | [ 29 | 'getElementById', 30 | 'String.fromCharCode', 31 | 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789', 32 | 'charAt', 33 | 'DOMContentLoaded', 34 | 'AdBlock', 35 | 'addEventListener', 36 | 'doScroll', 37 | 'fromCharCode', 38 | '<<2|r>>4', 39 | 'sessionStorage', 40 | 'clientWidth', 41 | 'localStorage', 42 | 'Math', 43 | 'random' 44 | ], 45 | ]; 46 | const check = function(s) { 47 | for ( let i = 0; i < signatures.length; i++ ) { 48 | const tokens = signatures[i]; 49 | let match = 0; 50 | for ( let j = 0; j < tokens.length; j++ ) { 51 | const token = tokens[j]; 52 | const pos = token instanceof RegExp 53 | ? s.search(token) 54 | : s.indexOf(token); 55 | if ( pos !== -1 ) { match += 1; } 56 | } 57 | if ( (match / tokens.length) >= 0.8 ) { return true; } 58 | } 59 | return false; 60 | }; 61 | window.eval = new Proxy(window.eval, { // jshint ignore: line 62 | apply: function(target, thisArg, args) { 63 | const a = args[0]; 64 | if ( typeof a !== 'string' || !check(a) ) { 65 | return target.apply(thisArg, args); 66 | } 67 | if ( document.body ) { 68 | document.body.style.removeProperty('visibility'); 69 | } 70 | let el = document.getElementById('babasbmsgx'); 71 | if ( el ) { 72 | el.parentNode.removeChild(el); 73 | } 74 | } 75 | }); 76 | window.setTimeout = new Proxy(window.setTimeout, { 77 | apply: function(target, thisArg, args) { 78 | const a = args[0]; 79 | if ( 80 | typeof a !== 'string' || 81 | /\.bab_elementid.$/.test(a) === false 82 | ) { 83 | return target.apply(thisArg, args); 84 | } 85 | } 86 | }); 87 | })(); 88 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/nobab2.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2021-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const script = document.currentScript; 25 | if ( script === null ) { return; } 26 | const src = script.src; 27 | if ( typeof src !== 'string' ) { return; } 28 | // The scriplet is meant to act ONLY when it's being used as a redirection 29 | // for specific domains. 30 | const re = new RegExp( 31 | '^https?://[\\w-]+\\.(' + 32 | [ 33 | 'adclixx\\.net', 34 | 'adnetasia\\.com', 35 | 'adtrackers\\.net', 36 | 'bannertrack\\.net', 37 | ].join('|') + 38 | ')/.' 39 | ); 40 | if ( re.test(src) === false ) { return; } 41 | window.nH7eXzOsG = 858; 42 | })(); 43 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noeval-silent.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | window.eval = new Proxy(window.eval, { // jshint ignore: line 25 | apply: function() { 26 | } 27 | }); 28 | })(); 29 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noeval.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const log = console.log.bind(console); 25 | window.eval = new Proxy(window.eval, { // jshint ignore: line 26 | apply: function(target, thisArg, args) { 27 | log(`Document tried to eval... ${args[0]}\n`); 28 | } 29 | }); 30 | })(); 31 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/nofab.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | const Fab = function() {}; 27 | Fab.prototype.check = noopfn; 28 | Fab.prototype.clearEvent = noopfn; 29 | Fab.prototype.emitEvent = noopfn; 30 | Fab.prototype.on = function(a, b) { 31 | if ( !a ) { b(); } 32 | return this; 33 | }; 34 | Fab.prototype.onDetected = function() { 35 | return this; 36 | }; 37 | Fab.prototype.onNotDetected = function(a) { 38 | a(); 39 | return this; 40 | }; 41 | Fab.prototype.setOption = noopfn; 42 | Fab.prototype.options = { 43 | set: noopfn, 44 | get: noopfn, 45 | }; 46 | const fab = new Fab(); 47 | const getSetFab = { 48 | get: function() { return Fab; }, 49 | set: function() {} 50 | }; 51 | const getsetfab = { 52 | get: function() { return fab; }, 53 | set: function() {} 54 | }; 55 | if ( window.hasOwnProperty('FuckAdBlock') ) { window.FuckAdBlock = Fab; } 56 | else { Object.defineProperty(window, 'FuckAdBlock', getSetFab); } 57 | if ( window.hasOwnProperty('BlockAdBlock') ) { window.BlockAdBlock = Fab; } 58 | else { Object.defineProperty(window, 'BlockAdBlock', getSetFab); } 59 | if ( window.hasOwnProperty('SniffAdBlock') ) { window.SniffAdBlock = Fab; } 60 | else { Object.defineProperty(window, 'SniffAdBlock', getSetFab); } 61 | if ( window.hasOwnProperty('fuckAdBlock') ) { window.fuckAdBlock = fab; } 62 | else { Object.defineProperty(window, 'fuckAdBlock', getsetfab); } 63 | if ( window.hasOwnProperty('blockAdBlock') ) { window.blockAdBlock = fab; } 64 | else { Object.defineProperty(window, 'blockAdBlock', getsetfab); } 65 | if ( window.hasOwnProperty('sniffAdBlock') ) { window.sniffAdBlock = fab; } 66 | else { Object.defineProperty(window, 'sniffAdBlock', getsetfab); } 67 | })(); 68 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop-0.1s.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/noop-0.1s.mp3 -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop-0.5s.mp3: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/noop-0.5s.mp3 -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop-1s.mp4: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/.extension/uBlock/web_accessible_resources/noop-1s.mp4 -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop-vmap1.0.xml: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop.css: -------------------------------------------------------------------------------- 1 | /* */ 2 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop.js: -------------------------------------------------------------------------------- 1 | (function() { 2 | 'use strict'; 3 | })(); 4 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/noop.txt: -------------------------------------------------------------------------------- 1 | 2 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/outbrain-widget.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const noopfn = function() { 25 | }; 26 | const obr = {}; 27 | const methods = [ 28 | 'callClick', 29 | 'callLoadMore', 30 | 'callRecs', 31 | 'callUserZapping', 32 | 'callWhatIs', 33 | 'cancelRecommendation', 34 | 'cancelRecs', 35 | 'closeCard', 36 | 'closeModal', 37 | 'closeTbx', 38 | 'errorInjectionHandler', 39 | 'getCountOfRecs', 40 | 'getStat', 41 | 'imageError', 42 | 'manualVideoClicked', 43 | 'onOdbReturn', 44 | 'onVideoClick', 45 | 'pagerLoad', 46 | 'recClicked', 47 | 'refreshSpecificWidget', 48 | 'renderSpaWidgets', 49 | 'refreshWidget', 50 | 'reloadWidget', 51 | 'researchWidget', 52 | 'returnedError', 53 | 'returnedHtmlData', 54 | 'returnedIrdData', 55 | 'returnedJsonData', 56 | 'scrollLoad', 57 | 'showDescription', 58 | 'showRecInIframe', 59 | 'userZappingMessage', 60 | 'zappingFormAction' 61 | ]; 62 | obr.extern = { 63 | video: { 64 | getVideoRecs: noopfn, 65 | videoClicked: noopfn 66 | } 67 | }; 68 | methods.forEach(function(a) { 69 | obr.extern[a] = noopfn; 70 | }); 71 | window.OBR = window.OBR || obr; 72 | })(); 73 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/popads-dummy.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | delete window.PopAds; 25 | delete window.popns; 26 | Object.defineProperties(window, { 27 | PopAds: { value: {} }, 28 | popns: { value: {} } 29 | }); 30 | })(); 31 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/popads.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | const magic = String.fromCharCode(Date.now() % 26 + 97) + 25 | Math.floor(Math.random() * 982451653 + 982451653).toString(36); 26 | const oe = window.onerror; 27 | window.onerror = function(msg, src, line, col, error) { 28 | if ( typeof msg === 'string' && msg.indexOf(magic) !== -1 ) { return true; } 29 | if ( oe instanceof Function ) { 30 | return oe(msg, src, line, col, error); 31 | } 32 | }.bind(); 33 | const throwMagic = function() { throw magic; }; 34 | delete window.PopAds; 35 | delete window.popns; 36 | Object.defineProperties(window, { 37 | PopAds: { set: throwMagic }, 38 | popns: { set: throwMagic } 39 | }); 40 | })(); 41 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/prebid-ads.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2022-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | window.canRunAds = true; 25 | window.isAdBlockActive = false; 26 | })(); 27 | -------------------------------------------------------------------------------- /.extension/uBlock/web_accessible_resources/scorecardresearch_beacon.js: -------------------------------------------------------------------------------- 1 | /******************************************************************************* 2 | 3 | uBlock Origin - a browser extension to block requests. 4 | Copyright (C) 2019-present Raymond Hill 5 | 6 | This program is free software: you can redistribute it and/or modify 7 | it under the terms of the GNU General Public License as published by 8 | the Free Software Foundation, either version 3 of the License, or 9 | (at your option) any later version. 10 | 11 | This program is distributed in the hope that it will be useful, 12 | but WITHOUT ANY WARRANTY; without even the implied warranty of 13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 | GNU General Public License for more details. 15 | 16 | You should have received a copy of the GNU General Public License 17 | along with this program. If not, see {http://www.gnu.org/licenses/}. 18 | 19 | Home: https://github.com/gorhill/uBlock 20 | */ 21 | 22 | (function() { 23 | 'use strict'; 24 | window.COMSCORE = { 25 | purge: function() { 26 | window._comscore = []; 27 | }, 28 | beacon: function() { 29 | } 30 | }; 31 | })(); 32 | -------------------------------------------------------------------------------- /.extension/uBlock/whitelist.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | uBlock — Whitelist 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 |
24 | 25 |

info-circle 26 |

27 |

28 | 29 | 30 |    31 | 32 | 33 |

34 |
35 |
36 | 37 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | .local_chromium 2 | node_modules -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Xu Zhengze 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /images/administrator.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/images/administrator.png -------------------------------------------------------------------------------- /images/user.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/images/user.png -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "tech-study-node", 3 | "version": "1.0.0", 4 | "description": "", 5 | "main": "bin/index.ts", 6 | "scripts": { 7 | "start": "ts-node bin/index.ts", 8 | "dev": "nodemon bin/index.ts", 9 | "test": "vitest" 10 | }, 11 | "keywords": [], 12 | "author": "", 13 | "license": "ISC", 14 | "devDependencies": { 15 | "@types/blueimp-md5": "^2.18.0", 16 | "@types/node": "^18.16.18", 17 | "@types/node-schedule": "^2.1.0", 18 | "vite": "^4.3.9", 19 | "vitest": "^0.22.1" 20 | }, 21 | "dependencies": { 22 | "axios": "^0.27.2", 23 | "blueimp-md5": "^2.19.0", 24 | "chalk": "4.1.2", 25 | "cron-parser": "^4.8.1", 26 | "jimp": "^0.16.13", 27 | "jsqr": "^1.4.0", 28 | "node-schedule": "^2.1.1", 29 | "nodemon": "^2.0.22", 30 | "ora": "^5.4.1", 31 | "puppeteer-core": "^20.7.3", 32 | "ts-node": "^10.9.1", 33 | "typescript": "^4.9.5" 34 | } 35 | } -------------------------------------------------------------------------------- /src/config/api.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description API 配置 3 | */ 4 | const API_CONFIG = { 5 | /** 6 | * @description 用户信息 7 | */ 8 | userInfo: 'https://pc-api.xuexi.cn/open/api/user/info', 9 | /** 10 | * @description 总分 11 | */ 12 | totalScore: 'https://pc-proxy-api.xuexi.cn/delegate/score/get', 13 | /** 14 | * @description 当天分数 15 | */ 16 | todayScore: 'https://pc-proxy-api.xuexi.cn/delegate/score/today/query', 17 | /** 18 | * @description 任务列表 19 | */ 20 | taskList: 21 | 'https://pc-proxy-api.xuexi.cn/delegate/score/days/listScoreProgress?sence=score&deviceType=2', 22 | /** 23 | * @description 新闻数据 24 | */ 25 | news: [ 26 | 'https://www.xuexi.cn/lgdata/35il6fpn0ohq.json', 27 | 'https://www.xuexi.cn/lgdata/1ap1igfgdn2.json', 28 | 'https://www.xuexi.cn/lgdata/vdppiu92n1.json', 29 | 'https://www.xuexi.cn/lgdata/152mdtl3qn1.json', 30 | ], 31 | /** 32 | * @description 视频数据 33 | */ 34 | video: [ 35 | 'https://www.xuexi.cn/lgdata/525pi8vcj24p.json', 36 | 'https://www.xuexi.cn/lgdata/11vku6vt6rgom.json', 37 | 'https://www.xuexi.cn/lgdata/2qfjjjrprmdh.json', 38 | 'https://www.xuexi.cn/lgdata/3o3ufqgl8rsn.json', 39 | 'https://www.xuexi.cn/lgdata/591ht3bc22pi.json', 40 | 'https://www.xuexi.cn/lgdata/1742g60067k.json', 41 | 'https://www.xuexi.cn/lgdata/1novbsbi47k.json', 42 | ], 43 | /** 44 | * @description 专项练习列表 45 | */ 46 | paperList: 'https://pc-proxy-api.xuexi.cn/api/exam/service/paper/pc/list', 47 | /** 48 | * @description 文本服务器保存答案 49 | */ 50 | answerSave: 'https://a6.qikekeji.com/txt/data/save', 51 | /** 52 | * @description 答案搜素 53 | */ 54 | answerSearch: 'https://a6.qikekeji.com/txt/data/detail', 55 | /** 56 | * @description 推送 57 | */ 58 | push: 'http://www.pushplus.plus/send', 59 | }; 60 | 61 | export default API_CONFIG; 62 | -------------------------------------------------------------------------------- /src/config/pup.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | 3 | // 扩展路径 4 | const pathToExtension = '../.extension/uBlock'; 5 | 6 | /** 7 | * @description puppeteer 配置 8 | * @link {@link https://pptr.dev/api/puppeteer.launchoptions puppeteer 官方配置文档} 9 | */ 10 | const PUP_CONFIG: pup.PuppeteerLaunchOptions = { 11 | /** 12 | * @description 无头模式 13 | * @example new 非图形界面 false 图形界面 14 | */ 15 | headless: 'new', 16 | /** 17 | * @description 开发工具 18 | */ 19 | devtools: false, 20 | /** 21 | * @description 默认视口大小 22 | */ 23 | defaultViewport: { 24 | width: 1200, 25 | height: 900, 26 | }, 27 | /** 28 | * @description 传递给浏览器实例的其他参数 29 | */ 30 | args: [ 31 | '--no-sandbox', 32 | '--disable-setuid-sandbox', 33 | '--disable-blink-features=AutomationControlled', 34 | `--disable-extensions-except=${pathToExtension}`, 35 | `--load-extension=${pathToExtension}`, 36 | ], 37 | /** 38 | * @description 显示浏览器进程信息 39 | */ 40 | // dumpio: true, 41 | /** 42 | * @description 可执行文件的路径 43 | * @example 'google-chrome' for linux, '.local_chromium/chrome.exe' from win 44 | */ 45 | executablePath: '.local_chromium/chrome.exe', 46 | /** 47 | * @description 忽略默认配置 48 | */ 49 | ignoreDefaultArgs: ['--enable-automation'], 50 | /** 51 | * @description 导航期间忽略 HTTPS 错误 52 | */ 53 | ignoreHTTPSErrors: true, 54 | /** 55 | * @description 等待浏览器实例启动的最长时间 56 | */ 57 | timeout: 10000, 58 | }; 59 | export default PUP_CONFIG; 60 | -------------------------------------------------------------------------------- /src/config/push.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description pushplus 推送配置 3 | * @link {@link https://www.pushplus.plus/ PushPlus 官网} 4 | */ 5 | const PUSH_CONFIG = { 6 | /** 7 | * @description 启用推送 8 | * @example true 启用推送 false 禁用推送 9 | */ 10 | enabled: false, 11 | /** 12 | * @description 发送服务消息昵称 13 | */ 14 | nick: '管理员', 15 | /** 16 | * @description 发送服务消息来源 17 | */ 18 | from: 'tech-study-node', 19 | /** 20 | * @description 管理员的token 21 | */ 22 | token: 'xxxxxxxxxxxxxxxxxxxxxxxxxx', 23 | }; 24 | export default PUSH_CONFIG; 25 | -------------------------------------------------------------------------------- /src/config/schedule.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description 定时任务 3 | */ 4 | export type Schedule = { 5 | /** 6 | * @description 用户昵称 7 | */ 8 | nick: string; 9 | /** 10 | * @description 用户token 11 | * @link {@link https://www.pushplus.plus/liaison.html 好友消息} 12 | */ 13 | token: string; 14 | /** 15 | * @description 定时时间 16 | */ 17 | cron: string; 18 | /** 19 | * @description 学习任务配置 20 | * @example [文章选读, 视听学习, 每日答题] 21 | */ 22 | taskConfig: [boolean, boolean, boolean]; 23 | /** 24 | * @description 刷新页面 cookie 的随机时间间隔,单位为分钟页面 cookie 过期时间大概是 4 个小时,设置小于 4 个小时都行 25 | * @example [60, 120] 则表示随机取 60 ~ 120 分钟刷新一次 26 | */ 27 | refreshCookieInterval: [number, number]; 28 | }; 29 | 30 | /** 31 | * @description 定时任务配置 32 | */ 33 | export const SCHEDULE_CONFIG: Schedule[] = [ 34 | { 35 | nick: 'xxx', 36 | token: 'xxxxxxxxxxxxxxxxxxxxxxxxxx', 37 | cron: '0 0 12 * * ?', 38 | taskConfig: [true, true, true], 39 | refreshCookieInterval: [60, 120], 40 | }, 41 | ]; 42 | -------------------------------------------------------------------------------- /src/config/study.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description 学习配置 3 | */ 4 | const STUDY_CONFIG = { 5 | /** 6 | * @description 通用超时 7 | */ 8 | timeout: 10000, 9 | /** 10 | * @description 最大登录尝试次数 11 | */ 12 | maxTryLoginCount: 10, 13 | /** 14 | * @description 最大登录等待时间 15 | */ 16 | loginTimeout: 80000, 17 | /** 18 | * @description 登录二维码本地存储(开启推送后,自行关闭) 19 | */ 20 | qrcodeLocalEnabled: true, 21 | /** 22 | * @description 登录二维码保存路径 23 | */ 24 | qrcodePath: 'src/qrcode/', 25 | /** 26 | * @description 登录结束自动清理二维码 27 | */ 28 | qrcodeAutoClean: true, 29 | /** 30 | * @description 日志保存路径 31 | */ 32 | logsPath: 'src/logs/', 33 | /** 34 | * @description 登录后 cookie 缓存路径 35 | */ 36 | cookieCachePath: 'src/cookie/', 37 | /** 38 | * @description 日志自动清理间隔天数 39 | */ 40 | logsAutoCleanInterval: 7, 41 | /** 42 | * @description 单次最大新闻数 43 | */ 44 | maxNewsNum: 6, 45 | /** 46 | * @description 单次最大视频数 47 | */ 48 | maxVideoNum: 6, 49 | /** 50 | * @description 限制请求速率 51 | */ 52 | rateLimit: 3000, 53 | /** 54 | * @description 专项练习的开启逆序 55 | * @example true 逆序 false 顺序 56 | */ 57 | paperReverse: true, 58 | }; 59 | 60 | export default STUDY_CONFIG; 61 | -------------------------------------------------------------------------------- /src/config/url.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description URL 配置 3 | */ 4 | const URL_CONFIG = { 5 | /** 6 | * 首页 7 | */ 8 | home: 'https://www.xuexi.cn/index.html', 9 | /** 10 | * @description 登录页面 11 | */ 12 | login: 13 | 'https://login.xuexi.cn/login/xuexiWeb?appid=dingoankubyrfkttorhpou&goto=https%3A%2F%2Foa.xuexi.cn&type=1&state=f6bc5df911df4142Y0NK5sXKipkJJL1BpZKBXsXDx4RbKCm-nSVFMgALG4dk2raOLCRPc0wgQ%2FxWP6U3&check_login=https%3A%2F%2Fpc-api.xuexi.cn', 14 | /** 15 | * @description 每日答题页面 16 | */ 17 | examPractice: 'https://pc.xuexi.cn/points/exam-practice.html', 18 | /** 19 | * @description 专项练习页面 20 | */ 21 | examPaper: 'https://pc.xuexi.cn/points/exam-paper-detail.html', 22 | }; 23 | 24 | export default URL_CONFIG; 25 | -------------------------------------------------------------------------------- /src/cookie/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/src/cookie/.gitkeep -------------------------------------------------------------------------------- /src/logs/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/src/logs/.gitkeep -------------------------------------------------------------------------------- /src/qrcode/.gitkeep: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Xu22Web/tech-study-node/2a9fc65b752e9af704a217c67e2987485e5809f6/src/qrcode/.gitkeep -------------------------------------------------------------------------------- /src/utils/cookieCache.ts: -------------------------------------------------------------------------------- 1 | import fs from 'fs'; 2 | import path from 'path'; 3 | import * as pup from 'puppeteer-core'; 4 | import STUDY_CONFIG from '../config/study'; 5 | import { getCookieIncludesDomain } from './utils'; 6 | 7 | // 缓存路径 8 | const { cookieCachePath } = STUDY_CONFIG; 9 | 10 | /** 11 | * @description 读取 cookie 缓存 12 | * @param cookieId 13 | */ 14 | export const readCookieCache = async (cookieId: string) => { 15 | // 缓存是否存在 16 | const exists = existsCookieCache(cookieId); 17 | if (!exists) { 18 | return null; 19 | } 20 | // 检查文件路径 21 | const cookieFileCachePath = path.join(cookieCachePath, `${cookieId}.json`); 22 | // 读取 json 文件 23 | const cookiesJSON = await fs.promises.readFile(cookieFileCachePath, 'utf-8'); 24 | // 转换为 cookie 25 | const cookies = JSON.parse(cookiesJSON); 26 | return cookies; 27 | }; 28 | 29 | /** 30 | * @description 写入 cookie 缓存 31 | * @param page 32 | * @param cookieId 33 | */ 34 | export const writeCookieCache = async (page: pup.Page, cookieId: string) => { 35 | // 创建文件夹 36 | if (!fs.existsSync(cookieCachePath)) { 37 | await fs.promises.mkdir(cookieCachePath); 38 | } 39 | // 获取 cookies 40 | const cookies = await getCookieIncludesDomain(page, 'xuexi.cn'); 41 | // 写入文件路径 42 | const cookieFileCachePath = path.join(cookieCachePath, `${cookieId}.json`); 43 | // 写入文件 44 | await fs.promises.writeFile(cookieFileCachePath, JSON.stringify(cookies)); 45 | return true; 46 | }; 47 | 48 | /** 49 | * @description 存在 cookie 缓存 50 | * @param cookieId 51 | */ 52 | export const existsCookieCache = (cookieId: string) => { 53 | // 检查文件夹 54 | if (!fs.existsSync(cookieCachePath)) { 55 | return false; 56 | } 57 | // 检查文件路径 58 | const cookieFileCachePath = path.join(cookieCachePath, `${cookieId}.json`); 59 | if (!fs.existsSync(cookieFileCachePath)) { 60 | return false; 61 | } 62 | return true; 63 | }; 64 | -------------------------------------------------------------------------------- /src/utils/fomat.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description 格式化日期时间数字 3 | * @param num 4 | * @returns 5 | */ 6 | export const formatDateNum = (num: number) => { 7 | return num < 10 ? `0${num}` : `${num}`; 8 | }; 9 | 10 | /** 11 | * @description 格式化日期时间 12 | * @param time 13 | * @returns 14 | * @example 15 | * formatDateTime() -> "2022-09-01 08:00:00" 16 | * formatDateTime(new Date()) -> "2022-09-01 08:00:00" 17 | * formatDateTime(Date.now()) -> "2022-09-01 08:00:00" 18 | */ 19 | export const formatDateTime = (time: Date | string | number = Date.now()) => { 20 | const date = new Date(time); 21 | const s = date.getSeconds(); 22 | const min = date.getMinutes(); 23 | const h = date.getHours(); 24 | const d = date.getDate(); 25 | const m = date.getMonth() + 1; 26 | const y = date.getFullYear(); 27 | // 日期 28 | const dateText = [y, m, d].map(formatDateNum).join('-'); 29 | // 时间 30 | const timeText = [h, min, s].map(formatDateNum).join(':'); 31 | // 日期时间 32 | const dateTimeText = `${dateText} ${timeText}`; 33 | return dateTimeText; 34 | }; 35 | 36 | /** 37 | * @description 格式化时间日期 38 | * @param time 39 | * @returns 40 | * @example 41 | * formatDate() -> "2022-09-01" 42 | * formatDate(new Date()) -> "2022-09-01" 43 | * formatDate(Date.now()) -> "2022-09-01" 44 | */ 45 | export const formatDate = (time: Date | string | number = Date.now()) => { 46 | const date = new Date(time); 47 | const d = date.getDate(); 48 | const m = date.getMonth() + 1; 49 | const y = date.getFullYear(); 50 | // 日期 51 | const dateText = [y, m, d].map(formatDateNum).join('-'); 52 | return dateText; 53 | }; 54 | 55 | /** 56 | * @description 格式化时间 57 | * @param time 58 | * @returns 59 | * @example 60 | * formatTime() -> "08:00:00" 61 | * formatTime(new Date()) -> "08:00:00" 62 | * formatTime(Date.now()) -> "08:00:00" 63 | */ 64 | export const formatTime = (time: Date | string | number = Date.now()) => { 65 | const date = new Date(time); 66 | const s = date.getSeconds(); 67 | const min = date.getMinutes(); 68 | const h = date.getHours(); 69 | // 时间 70 | const timeText = [h, min, s].map(formatDateNum).join(':'); 71 | return timeText; 72 | }; 73 | -------------------------------------------------------------------------------- /src/utils/html.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @description html进度条 3 | * @param title 4 | * @param percent 5 | * @returns 6 | */ 7 | export const getProgressHTML = ( 8 | title: string, 9 | current: number, 10 | total: number 11 | ) => { 12 | // html 13 | const progressHTML = `
21 | ${title} 22 | ${getHighlightHTML(current)} / ${total} 23 |
24 |
33 |
41 |
`; 42 | return progressHTML; 43 | }; 44 | 45 | /** 46 | * @description 创建表格 47 | * @param theadData 48 | * @param tbodyData 49 | * @returns 50 | */ 51 | export const getTableHTML = (theadData: string[], tbodyData: string[][]) => { 52 | // 表头 53 | const thead = theadData 54 | .map( 55 | (head) => ` 62 | ${head} 63 | ` 64 | ) 65 | .join(''); 66 | // 表身 67 | const tbody = tbodyData 68 | .map( 69 | (body) => ` 70 | ${body 71 | .map( 72 | (b) => ` 79 | ${b} 80 | ` 81 | ) 82 | .join('')} 83 | ` 84 | ) 85 | .join(''); 86 | // 表 87 | const table = ` 102 | 103 | 104 | ${thead} 105 | 106 | 107 | 108 | ${tbody} 109 | 110 |
`; 111 | return table; 112 | }; 113 | 114 | /** 115 | * @description html高亮文本 116 | * @param text 117 | * @returns 118 | */ 119 | export const getHighlightHTML = (text: string | number) => { 120 | // html 121 | const highlightHTML = `${text}`; 122 | return highlightHTML; 123 | }; 124 | -------------------------------------------------------------------------------- /src/utils/random.ts: -------------------------------------------------------------------------------- 1 | import { Bounds } from './utils'; 2 | 3 | /** 4 | * @description 点 5 | */ 6 | export type Point = { x: number; y: number }; 7 | 8 | /** 9 | * @description 创建随机点 10 | * @param bounds 范围 11 | * @returns 12 | */ 13 | export const createRandomPoint = (bounds: Bounds): Point => { 14 | // 范围 15 | const { x, y, width, height } = bounds; 16 | // 横坐标 17 | const randX = x + Math.random() * width * 0.5 + width * 0.25; 18 | // 纵坐标 19 | const randY = y + Math.random() * height * 0.5 + height * 0.25; 20 | return { 21 | x: randX, 22 | y: randY, 23 | }; 24 | }; 25 | 26 | /** 27 | * @description 生成随机路径 28 | * @param start 29 | * @param end 30 | * @param steps 31 | * @returns 32 | */ 33 | export const createRandomPath = (start: Point, end: Point, steps: number) => { 34 | // 最小水平增量 35 | const minDeltaX = (end.x - start.x) / steps; 36 | // 最大垂直增量 37 | const maxDeltaY = (end.y - start.y) / steps; 38 | // 路径 39 | const path: Point[] = []; 40 | // 开始节点 41 | path.push(start); 42 | // 插入点 43 | for (let i = 0; i < steps; i++) { 44 | // 横坐标 45 | const x = path[i].x + Math.random() * 5 + minDeltaX; 46 | // 纵坐标 47 | const y = 48 | path[i].y + 49 | Math.random() * 5 * Math.pow(-1, ~~(Math.random() * 2 + 1)) + 50 | maxDeltaY; 51 | path.push({ 52 | x, 53 | y, 54 | }); 55 | } 56 | return path; 57 | }; 58 | -------------------------------------------------------------------------------- /test/error.test.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | import { describe, expect, it } from 'vitest'; 3 | import PUP_CONFIG from '../src/config/pup'; 4 | import shared from '../src/shared'; 5 | 6 | describe('error', () => { 7 | it.skip('goto', async () => { 8 | const browser = await pup.launch(PUP_CONFIG); 9 | shared.setBrowser(browser); 10 | await shared.openPage(); 11 | try { 12 | const res = await shared.gotoPage('https://www.baidu.com/'); 13 | expect(res).toMatchInlineSnapshot('true'); 14 | } catch (e) {} 15 | }); 16 | }); 17 | -------------------------------------------------------------------------------- /test/exam.test.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | import { describe, expect, it } from 'vitest'; 3 | import PUP_CONFIG from '../src/config/pup'; 4 | import handleExam from '../src/controller/exam'; 5 | import handleLogin from '../src/controller/login'; 6 | import shared from '../src/shared'; 7 | import { sleep } from '../src/utils/utils'; 8 | 9 | // 答题 10 | describe('exam', async () => { 11 | // 每日答题 12 | it.skip('practice', async () => { 13 | const broswer = await pup.launch(PUP_CONFIG); 14 | // 等待浏览器准备完成 15 | await sleep(2000); 16 | shared.setBrowser(broswer); 17 | await shared.openPage(); 18 | shared.log.start(); 19 | // 登录 20 | await handleLogin(); 21 | const res = await handleExam(); 22 | shared.log.finish(); 23 | expect(res).toMatchInlineSnapshot('true'); 24 | }); 25 | }); 26 | -------------------------------------------------------------------------------- /test/extension.test.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | import { describe, it } from 'vitest'; 3 | import PUP_CONFIG from '../src/config/pup'; 4 | import shared from '../src/shared'; 5 | 6 | // 登录 7 | describe('extension', async () => { 8 | // uBlock 9 | it.skip('uBlock', async () => { 10 | const broswer = await pup.launch(PUP_CONFIG); 11 | shared.setBrowser(broswer); 12 | }); 13 | }); 14 | -------------------------------------------------------------------------------- /test/log.test.ts: -------------------------------------------------------------------------------- 1 | import { describe, it } from 'vitest'; 2 | import shared from '../src/shared'; 3 | 4 | describe('log', () => { 5 | it.skip('info', () => { 6 | shared.log.start(); 7 | shared.log.info('测试'); 8 | shared.log.finish(); 9 | }); 10 | it.skip('success', () => { 11 | shared.log.start(); 12 | shared.log.success('测试'); 13 | shared.log.finish(); 14 | }); 15 | it.skip('loading', () => { 16 | shared.log.start(); 17 | shared.log.loading('测试'); 18 | shared.log.finish(); 19 | }); 20 | it.skip('loaded', () => { 21 | shared.log.start(); 22 | shared.log.loaded('测试'); 23 | shared.log.finish(); 24 | }); 25 | it.skip('fail', () => { 26 | shared.log.start(); 27 | shared.log.fail('测试'); 28 | shared.log.finish(); 29 | }); 30 | it.skip('warn', () => { 31 | shared.log.start(); 32 | shared.log.warn('测试'); 33 | shared.log.finish(); 34 | }); 35 | it.skip('clear', () => { 36 | shared.log.clear(); 37 | }); 38 | it.skip('autoClean', () => { 39 | shared.log.autoClean(); 40 | }); 41 | }); 42 | -------------------------------------------------------------------------------- /test/login.test.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | import { describe, expect, it } from 'vitest'; 3 | import PUP_CONFIG from '../src/config/pup'; 4 | import handleLogin from '../src/controller/login'; 5 | import shared from '../src/shared'; 6 | import { sleep } from '../src/utils/utils'; 7 | 8 | // 登录 9 | describe('login', async () => { 10 | // 登录 11 | it.skip('login', async () => { 12 | const broswer = await pup.launch(PUP_CONFIG); 13 | // 等待浏览器准备完成 14 | await sleep(2000); 15 | shared.setBrowser(broswer); 16 | await shared.openPage(); 17 | // 推送参数 18 | await shared.setPushOptions({ nick: '', token: '' }); 19 | const res = await handleLogin(); 20 | expect(res).toMatchInlineSnapshot('true'); 21 | }); 22 | }); 23 | -------------------------------------------------------------------------------- /test/watch.test.ts: -------------------------------------------------------------------------------- 1 | import * as pup from 'puppeteer-core'; 2 | import { describe, expect, it } from 'vitest'; 3 | import PUP_CONFIG from '../src/config/pup'; 4 | import handleLogin from '../src/controller/login'; 5 | import handleWatch from '../src/controller/watch'; 6 | import shared from '../src/shared'; 7 | import { sleep } from '../src/utils/utils'; 8 | 9 | // 看视频 | 读文章 10 | describe('watch', async () => { 11 | // 读文章 12 | it.skip('news', async () => { 13 | const broswer = await pup.launch(PUP_CONFIG); 14 | // 等待浏览器准备完成 15 | await sleep(2000); 16 | shared.setBrowser(broswer); 17 | await shared.openPage(); 18 | // 推送参数 19 | await shared.setPushOptions({ nick: '', token: '' }); 20 | // 登录 21 | await handleLogin(); 22 | const res = await handleWatch(0); 23 | expect(res).toMatchInlineSnapshot('true'); 24 | }); 25 | // 看视频 26 | it.skip('video', async () => { 27 | const broswer = await pup.launch(PUP_CONFIG); 28 | // 等待浏览器准备完成 29 | await sleep(2000); 30 | shared.setBrowser(broswer); 31 | await shared.openPage(); 32 | // 推送参数 33 | await shared.setPushOptions({ nick: '', token: '' }); 34 | // 登录 35 | await handleLogin(); 36 | const res = await handleWatch(1); 37 | expect(res).toMatchInlineSnapshot('true'); 38 | }); 39 | }); 40 | -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "ESNext", 4 | "lib": ["DOM", "ESNext"], 5 | "module": "commonjs", 6 | "esModuleInterop": true, 7 | "forceConsistentCasingInFileNames": true, 8 | "strict": true, 9 | "skipLibCheck": true 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | export default defineConfig({ 4 | test: { 5 | testTimeout: 300000, 6 | }, 7 | }); 8 | --------------------------------------------------------------------------------