()
| 26928 | var _onThemeChangeCallbacks = []; |
| 26929 | var ThemeSettingName = "theme"; |
| 26930 | function initializeThemeInCustomizations() { |
| 26931 | var _a; |
| 26932 | var _b, _c, _d, _e; |
| 26933 | // eslint-disable-next-line @typescript-eslint/no-explicit-any |
| 26934 | var win = (0, _utilities.getWindow)(); |
| 26935 | if ((_c = (_b = win) === null || _b === void 0 ? void 0 : _b.FabricConfig) === null || _c === void 0 ? void 0 : _c.legacyTheme) // does everything the `else` clause does and more, such as invoke legacy theming |
| 26936 | loadTheme(win.FabricConfig.legacyTheme); |
| 26937 | else if (!(0, _utilities.Customizations).getSettings([ |
| 26938 | ThemeSettingName |
| 26939 | ]).theme) { |
| 26940 | if ((_e = (_d = win) === null || _d === void 0 ? void 0 : _d.FabricConfig) === null || _e === void 0 ? void 0 : _e.theme) _theme = (0, _createTheme.createTheme)(win.FabricConfig.theme); |
| 26941 | // Set the default theme. |
| 26942 | (0, _utilities.Customizations).applySettings((_a = {}, _a[ThemeSettingName] = _theme, _a)); |
| 26943 | } |
| 26944 | } |
| 26945 | initializeThemeInCustomizations(); |
| 26946 | function getTheme(depComments) { |
| 26947 | if (depComments === void 0) depComments = false; |
no test coverage detected