fix(core): update

This commit is contained in:
Philipp Kunz 2022-03-16 15:00:10 +01:00
parent 9b30853a56
commit b8ced9a991
9 changed files with 25 additions and 41 deletions

View File

@ -12,6 +12,9 @@ stages:
- release
- metadata
before_script:
- npm install -g @shipzone/npmci
# ====================
# security stage
# ====================
@ -36,6 +39,7 @@ auditProductionDependencies:
- npmci command npm audit --audit-level=high --only=prod --production
tags:
- docker
allow_failure: true
auditDevDependencies:
image: registry.gitlab.com/hosttoday/ht-docker-node:npmci

24
.vscode/launch.json vendored
View File

@ -2,28 +2,10 @@
"version": "0.2.0",
"configurations": [
{
"name": "current file",
"type": "node",
"command": "npm test",
"name": "Run npm test",
"request": "launch",
"args": [
"${relativeFile}"
],
"runtimeArgs": ["-r", "@gitzone/tsrun"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart"
},
{
"name": "test.ts",
"type": "node",
"request": "launch",
"args": [
"test/test.ts"
],
"runtimeArgs": ["-r", "@gitzone/tsrun"],
"cwd": "${workspaceRoot}",
"protocol": "inspector",
"internalConsoleOptions": "openOnSessionStart"
"type": "node-terminal"
}
]
}

View File

@ -22,5 +22,6 @@
}
}
}
]
],
"typescript.tsdk": "node_modules/typescript/lib"
}

View File

@ -5,7 +5,7 @@
"githost": "gitlab.com",
"gitscope": "designestate",
"gitrepo": "dees-element",
"shortDescription": "a custom element class extending lit element class",
"description": "a custom element class extending lit element class",
"npmPackagename": "@designestate/dees-element",
"license": "MIT",
"projectDomain": "design.estate"

View File

@ -11,12 +11,12 @@ tap.test('should create a static element', async () => {
.buttonClass {
background: ${deesElement.cssManager.bdTheme('blue', 'black')};
}
`
`,
];
// INSTANCE
render() {
return deesElement.html`<div class="buttonClass">My Button</div>`
return deesElement.html`<div class="buttonClass">My Button</div>`;
}
}
});

View File

@ -28,13 +28,13 @@ export class CssManager {
});
}
public get defaultStyles () {
public get defaultStyles() {
return domtools.elementBasic.staticStyles;
}
public cssForTablet(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForTablet(contentArg));
};
}
public cssForPhablet(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForPhablet(contentArg));
@ -42,7 +42,7 @@ export class CssManager {
public cssForPhone(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForPhone(contentArg));
};
}
public bdTheme(brightValueArg: string, darkValueArg: string): CSSResult {
let returnCssVar: string;
@ -61,7 +61,10 @@ export class CssManager {
this.bdVarTripletStore.push(newTriplet);
this.domtoolsPromise.then(async (domtoolsArg) => {
await domtoolsArg.domReady.promise;
document.body.style.setProperty(newTriplet.cssVarName, this.goBright ? newTriplet.brightValue : newTriplet.darkValue);
document.body.style.setProperty(
newTriplet.cssVarName,
this.goBright ? newTriplet.brightValue : newTriplet.darkValue
);
});
returnCssVar = newTriplet.cssVarName;
}

View File

@ -2,10 +2,7 @@
import * as isounique from '@pushrocks/isounique';
import * as smartrx from '@pushrocks/smartrx';
export {
isounique,
smartrx
};
export { isounique, smartrx };
// third party scope
import { css, unsafeCSS, LitElement } from 'lit';
@ -19,7 +16,4 @@ const lit = {
import * as domtools from '@designestate/dees-domtools';
export {
lit,
domtools
};
export { lit, domtools };