Merge branch 'theme-by-url' of https://github.com/rianadon/CyberChef into rianadon-theme-by-url

This commit is contained in:
n1474335 2019-10-27 14:43:59 +00:00
commit 6659174f88
2 changed files with 11 additions and 0 deletions

View file

@ -453,6 +453,7 @@ class App {
* Searches the URI parameters for recipe and input parameters.
* If recipe is present, replaces the current recipe with the recipe provided in the URI.
* If input is present, decodes and sets the input to the one provided in the URI.
* If theme is present, uses the theme.
*
* @fires Manager#statechange
*/
@ -491,6 +492,10 @@ class App {
} catch (err) {}
}
if (this.uriParams.theme) {
document.querySelector(":root").className = this.uriParams.theme;
}
this.autoBakePause = false;
window.dispatchEvent(this.manager.statechange);
}