From e8e6416b6f7bdda1b08eae426ac4af56449ccf9e Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Tue, 15 Sep 2020 20:56:33 +0000 Subject: [PATCH] fix(core): update --- ts/domtools.classes.domtools.ts | 4 ---- ts/domtools.css.theme.ts | 8 -------- ts/domtools.elementbasic.ts | 7 ++++++- 3 files changed, 6 insertions(+), 13 deletions(-) diff --git a/ts/domtools.classes.domtools.ts b/ts/domtools.classes.domtools.ts index 253af52..6dd3235 100644 --- a/ts/domtools.classes.domtools.ts +++ b/ts/domtools.classes.domtools.ts @@ -5,7 +5,6 @@ import { TViewport } from './domtools.breakpoints'; import { Scroller } from './domtools.classes.scroller'; import { delayForRandom } from '@pushrocks/smartdelay'; -import { setupGlobalTheme } from './domtools.css.theme'; export interface IDomToolsState { virtualViewport: TViewport; @@ -24,9 +23,6 @@ export class DomTools { globalThis.deesDomTools = new DomTools(); domToolsInstance = globalThis.deesDomTools; - // lets setup theming - setupGlobalTheme(domToolsInstance); - // lets make sure the dom is ready const readyStateChangedFunc = () => { if (document.readyState === 'interactive' || document.readyState === 'complete') { diff --git a/ts/domtools.css.theme.ts b/ts/domtools.css.theme.ts index 109b563..9c54fbb 100644 --- a/ts/domtools.css.theme.ts +++ b/ts/domtools.css.theme.ts @@ -26,11 +26,3 @@ export const scrollBarStyles = (() => { } ` : ``; })(); - -export const setupGlobalTheme = (domToolsInstance: DomTools) => { - const styles = ` - ${scrollBarStyles} -`; - - domToolsInstance.setGlobalStyles(styles); -}; diff --git a/ts/domtools.elementbasic.ts b/ts/domtools.elementbasic.ts index 7eb1a0a..0fc8d22 100644 --- a/ts/domtools.elementbasic.ts +++ b/ts/domtools.elementbasic.ts @@ -46,7 +46,12 @@ export const setup = async () => { // Roboto Font domTools.setGlobalStyles(` - @import url('https://fonts.googleapis.com/css?family=Roboto'); + @import url('https://fonts.googleapis.com/css?family=Roboto:100,300,400'); + `); + + // scrollbars + domTools.setGlobalStyles(` + ${scrollBarStyles} `); }); };