Skip to content

Commit 7878aec

Browse files
added cross-browser compatibility for gekko and blink based browsers
1 parent 378540a commit 7878aec

File tree

7 files changed

+572
-560
lines changed

7 files changed

+572
-560
lines changed

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
"tailwindcss": "^4.1.4"
3030
},
3131
"dependencies": {
32-
"@tailwindcss/cli": "^4.1.3"
32+
"@tailwindcss/cli": "^4.1.3",
33+
"browser-polyfill": "^3.20.2"
3334
}
34-
}
35+
}

src/manifest.json

Lines changed: 13 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,21 +11,29 @@
1111
"96": "icons/icon.png",
1212
"48": "icons/icon.png"
1313
},
14-
"background": {
15-
"service_worker": "scripts/background.js"
14+
"browser_specific_settings": {
15+
"gecko": {
16+
17+
"strict_min_version": "109.0"
18+
}
1619
},
1720
"content_scripts": [
1821
{
1922
"matches": [
20-
"*://groups.google.com/forum/*",
23+
"*://groups.google.com/forum/*",
2124
"*://groups.google.com/g/*",
2225
"*://groups.google.com/u/*/g/*",
2326
"*://mail.google.com/*",
2427
"*://outlook.live.com/*",
2528
"*://outlook.office.com/*",
26-
"*://mail.yahoo.com/*"
29+
"*://mail.yahoo.com/*"
2730
],
28-
"js": ["scripts/jquery-3.2.1.min.js", "scripts/emailClientAdapter.js", "scripts/scrumHelper.js"]
31+
"js": [
32+
"scripts/browser-polyfill.js",
33+
"scripts/jquery-3.2.1.min.js",
34+
"scripts/emailClientAdapter.js",
35+
"scripts/scrumHelper.js"
36+
]
2937
}
3038
],
3139

src/popup.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,7 @@ <h4 class="font-semibold text-xl">Note:</h4>
260260
</div>
261261
</div>
262262
</div>
263+
<script src="scripts/browser-polyfill.js"></script>
263264
<script src="scripts/jquery-3.2.1.min.js"></script>
264265
<script type="text/javascript" type="text/javascript" src="materialize/js/materialize.min.js"></script>
265266
<script src="scripts/main.js"></script>

src/scripts/browser-polyfill.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
if (typeof browser === "undefined") {
2+
window.browser = typeof chrome !== "undefined" ? chrome : {};
3+
// Create global browser reference
4+
if (typeof chrome !== "undefined") {
5+
var browser = chrome;
6+
}
7+
}

0 commit comments

Comments
 (0)