fix(core): update
This commit is contained in:
parent
570a026cf8
commit
0de00cb2c1
@ -143,6 +143,14 @@ export class DomTools {
|
|||||||
this.elements.headElement.appendChild(styleElement);
|
this.elements.headElement.appendChild(styleElement);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public async setExternalCss(cssLinkArg: string) {
|
||||||
|
const cssTag = document.createElement('link');
|
||||||
|
cssTag.rel = 'stylesheet';
|
||||||
|
cssTag.crossOrigin = 'anonymous';
|
||||||
|
cssTag.href = cssLinkArg;
|
||||||
|
document.head.append(cssTag);
|
||||||
|
}
|
||||||
|
|
||||||
public setVirtualViewport(environmentArg: TViewport) {
|
public setVirtualViewport(environmentArg: TViewport) {
|
||||||
this.domToolsStatePart.dispatchAction(this.actionSetVirtualViewport, environmentArg);
|
this.domToolsStatePart.dispatchAction(this.actionSetVirtualViewport, environmentArg);
|
||||||
}
|
}
|
||||||
|
@ -56,6 +56,9 @@ export const setup = async (elementArg?: LitElement): Promise<DomTools> => {
|
|||||||
@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@100;300;400');
|
@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@100;300;400');
|
||||||
`);
|
`);
|
||||||
|
|
||||||
|
// font awesome brands
|
||||||
|
domTools.setExternalCss('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.1/css/brands.min.css');
|
||||||
|
|
||||||
// scrollbars
|
// scrollbars
|
||||||
domTools.setGlobalStyles(`
|
domTools.setGlobalStyles(`
|
||||||
${scrollBarStyles}
|
${scrollBarStyles}
|
||||||
|
Loading…
Reference in New Issue
Block a user