fix(core): update

This commit is contained in:
Philipp Kunz 2021-11-21 16:14:27 +01:00
parent a1bd7f74a7
commit 1747afe04a

View File

@ -90,7 +90,7 @@ export class DomTools {
}); // TODO: switch to scroller class }); // TODO: switch to scroller class
public themeManager = new ThemeManager(this); public themeManager = new ThemeManager(this);
private actionSetVirtualViewport = this.domToolsStatePart.createAction<TViewport>( /* private actionSetVirtualViewport = this.domToolsStatePart.createAction<TViewport>(
async (statePart, payload) => { async (statePart, payload) => {
const currentState = statePart.getState(); const currentState = statePart.getState();
currentState.virtualViewport = payload; currentState.virtualViewport = payload;
@ -98,6 +98,10 @@ export class DomTools {
} }
); );
public setVirtualViewport(environmentArg: TViewport) {
this.domToolsStatePart.dispatchAction(this.actionSetVirtualViewport, environmentArg);
} */
public domToolsReady = plugins.smartpromise.defer(); public domToolsReady = plugins.smartpromise.defer();
public domReady = plugins.smartpromise.defer(); public domReady = plugins.smartpromise.defer();
public globalStylesReady = plugins.smartpromise.defer(); public globalStylesReady = plugins.smartpromise.defer();
@ -148,9 +152,7 @@ export class DomTools {
document.head.append(cssTag); document.head.append(cssTag);
} }
public setVirtualViewport(environmentArg: TViewport) {
this.domToolsStatePart.dispatchAction(this.actionSetVirtualViewport, environmentArg);
}
public async setWebsiteInfo(optionsArg: plugins.websetup.IWebSetupConstructorOptions) { public async setWebsiteInfo(optionsArg: plugins.websetup.IWebSetupConstructorOptions) {
await this.websetup.setup(optionsArg); await this.websetup.setup(optionsArg);