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

24
.vscode/launch.json vendored
View File

@ -2,28 +2,10 @@
"version": "0.2.0", "version": "0.2.0",
"configurations": [ "configurations": [
{ {
"name": "current file", "command": "npm test",
"type": "node", "name": "Run npm test",
"request": "launch", "request": "launch",
"args": [ "type": "node-terminal"
"${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"
} }
] ]
} }

View File

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

View File

@ -5,7 +5,7 @@
"githost": "gitlab.com", "githost": "gitlab.com",
"gitscope": "designestate", "gitscope": "designestate",
"gitrepo": "dees-element", "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", "npmPackagename": "@designestate/dees-element",
"license": "MIT", "license": "MIT",
"projectDomain": "design.estate" "projectDomain": "design.estate"

View File

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

View File

@ -34,7 +34,7 @@ export class CssManager {
public cssForTablet(contentArg: CSSResult) { public cssForTablet(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForTablet(contentArg)); return unsafeCSS(domtools.breakpoints.cssForTablet(contentArg));
}; }
public cssForPhablet(contentArg: CSSResult) { public cssForPhablet(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForPhablet(contentArg)); return unsafeCSS(domtools.breakpoints.cssForPhablet(contentArg));
@ -42,7 +42,7 @@ export class CssManager {
public cssForPhone(contentArg: CSSResult) { public cssForPhone(contentArg: CSSResult) {
return unsafeCSS(domtools.breakpoints.cssForPhone(contentArg)); return unsafeCSS(domtools.breakpoints.cssForPhone(contentArg));
}; }
public bdTheme(brightValueArg: string, darkValueArg: string): CSSResult { public bdTheme(brightValueArg: string, darkValueArg: string): CSSResult {
let returnCssVar: string; let returnCssVar: string;
@ -61,7 +61,10 @@ export class CssManager {
this.bdVarTripletStore.push(newTriplet); this.bdVarTripletStore.push(newTriplet);
this.domtoolsPromise.then(async (domtoolsArg) => { this.domtoolsPromise.then(async (domtoolsArg) => {
await domtoolsArg.domReady.promise; 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; returnCssVar = newTriplet.cssVarName;
} }

View File

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