* initialize global state object
()
| 27065 | /** |
| 27066 | * initialize global state object |
| 27067 | */ function initializeThemeState() { |
| 27068 | var state = _root.__themeState__ || { |
| 27069 | theme: undefined, |
| 27070 | lastStyleElement: undefined, |
| 27071 | registeredStyles: [] |
| 27072 | }; |
| 27073 | if (!state.runState) state = __assign(__assign({}, state), { |
| 27074 | perf: { |
| 27075 | count: 0, |
| 27076 | duration: 0 |
| 27077 | }, |
| 27078 | runState: { |
| 27079 | flushTimer: 0, |
| 27080 | mode: 0 /* sync */ , |
| 27081 | buffer: [] |
| 27082 | } |
| 27083 | }); |
| 27084 | if (!state.registeredThemableStyles) state = __assign(__assign({}, state), { |
| 27085 | registeredThemableStyles: [] |
| 27086 | }); |
| 27087 | _root.__themeState__ = state; |
| 27088 | return state; |
| 27089 | } |
| 27090 | function loadStyles(styles, loadAsync) { |
| 27091 | if (loadAsync === void 0) loadAsync = false; |
| 27092 | measure(function() { |
no test coverage detected