mirror of
https://github.com/easydiffusion/easydiffusion.git
synced 2024-11-22 16:23:28 +01:00
Merge pull request #354 from madrang/beta
Fixed theme loading with extensions.
This commit is contained in:
commit
b6ef18b0d8
@ -1757,7 +1757,7 @@ function getThemeName(theme) {
|
||||
// init themefield
|
||||
function initTheme() {
|
||||
Array.from(document.styleSheets)
|
||||
.filter(sheet => sheet.href.startsWith(window.location.origin))
|
||||
.filter(sheet => sheet.href?.startsWith(window.location.origin))
|
||||
.flatMap(sheet => Array.from(sheet.cssRules))
|
||||
.forEach(rule => {
|
||||
var selector = rule.selectorText; // TODO: also do selector == ":root", re-run un-set props
|
||||
|
Loading…
Reference in New Issue
Block a user