From a99ffed200859f4c41fe744c7462452ccf24d23c Mon Sep 17 00:00:00 2001 From: Martok Date: Mon, 19 Sep 2022 00:26:48 +0200 Subject: [PATCH] add: Google Drive --- lib/builtin-rules.js | 5 +++++ lib/main.js | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/lib/builtin-rules.js b/lib/builtin-rules.js index c8b45a0..0eee2ad 100644 --- a/lib/builtin-rules.js +++ b/lib/builtin-rules.js @@ -37,6 +37,11 @@ godbolt.org static.ce-cdn.net/vendor.v*.js$script $script-content,godbolt-script ! -- +drive.google.com + std-PerformanceObserver +drive.google.com/_/drive_fe/_/js/k=drive_fe.main.*$script + $script-content,google-regexp +! -- www.ikea.com std-customElements,std-FunctionToString,ikea-mustard ! -- diff --git a/lib/main.js b/lib/main.js index 5d59612..2693c62 100644 --- a/lib/main.js +++ b/lib/main.js @@ -131,6 +131,10 @@ function evaluateFix(fix, script, csp, contentReplace) { contentReplace.push([`{signatureHelpTriggerCharacters=["(",","];`, `{`]); break; + case "google-regexp": + contentReplace.push([String.raw`(\\p{Ll})(?=\\p{Lu})|(\\p{Ll}|\\p{Lu})(?=\\p{Nd})|(\\p{Nd})(?=\\p{Ll}|\\p{Lu})`, + `([a-z])(?=[A-Z])|([a-z]|[A-Z])(?=[0-9])|([0-9])(?=[a-z]|[A-Z])`]); + break; case "ikea-mustard": contentReplace.push(["if (didCutTheMustardBox)", "if (true)"]); contentReplace.push(["if (didCutTheMustardSERP)", "if (true)"]);