(updater: StateUpdater<S>)
| 797 | }, |
| 798 | |
| 799 | update(updater: StateUpdater<S>): void { |
| 800 | guards.assertOperational("update"); |
| 801 | guards.assertLifecycleIdle("update"); |
| 802 | if (inCommit) guards.throwCode("ZRUI_REENTRANT_CALL", "update: called during commit"); |
| 803 | if (inRender) { |
| 804 | guards.throwCode("ZRUI_UPDATE_DURING_RENDER", guards.updateDuringRenderDetail("update")); |
| 805 | } |
| 806 | |
| 807 | updates.enqueue(updater); |
| 808 | if (sm.state === "Running" && inEventHandlerDepth === 0 && !userCommitScheduled) { |
| 809 | userCommitScheduled = true; |
| 810 | enqueueWorkItem({ kind: "userCommit" }); |
| 811 | } |
| 812 | }, |
| 813 | |
| 814 | setTheme(next: ThemeDefinition): void { |
| 815 | guards.assertOperational("setTheme"); |
no test coverage detected