To add a choice from bright white normal and dark theme if wanted editing the ebuild -IUSE="plasma" +IUSE="plasma dark-theme" and src_prepare() { rm etc/cron.daily/slack \ usr/lib/slack/LICENSE + if use dark-theme; then + eapply "${FILESDIR}"/slack-dark-theme.patch + fi eapply_user } and patch for files/ folder: slack-dark-theme.patch --- /usr/lib/slack/resources/app.asar.unpacked/src/static/ssb-interop.js +++ /usr/lib/slack/resources/app.asar.unpacked/src/static/ssb-interop.js @@ -96,4 +96,14 @@ const isDevMode = loadSettings.devMode && isPrebuilt(); init(resourcePath, mainModule, !isDevMode); + +document.addEventListener('DOMContentLoaded', function() { + $.ajax({ + url: 'https://raw.githubusercontent.com/laCour/slack-night-mode/master/css/raw/black.css', + success: function(css) { + $("<style></style>").appendTo('head').html(css); + } + }); +}); + }
Are you sure adding an official use flag for something downloaded from non-maintainer github account from the master branch is also good from the security perspective?
This is something that normally belongs in configuration, and not in conditional patching. Furthermore, patching software to implicitly load remote resources without any verification is a horrible idea from security PoV.