@node-projects/web-component-designer 0.0.247 → 0.0.249
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/elements/helper/NpmPackageLoader.js +12 -8
- package/dist/elements/services/propertiesService/services/CssPropertiesService.js +2 -1
- package/dist/elements/services/stylesheetService/AbstractStylesheetService.js +3 -1
- package/dist/elements/widgets/designerView/designerCanvas.js +7 -1
- package/package.json +1 -1
|
@@ -194,14 +194,18 @@ export class NpmPackageLoader {
|
|
|
194
194
|
this.addToImportmap(baseUrl, packageJsonObj);
|
|
195
195
|
}
|
|
196
196
|
async addToImportmap(baseUrl, packageJsonObj) {
|
|
197
|
-
//todo - use exports of package.json for importMap
|
|
198
|
-
const importMap = { imports: {}, scopes: {} };
|
|
199
|
-
let mainImport = packageJsonObj.main;
|
|
200
|
-
if (packageJsonObj.module)
|
|
201
|
-
mainImport = packageJsonObj.module;
|
|
202
|
-
importMap.imports[packageJsonObj.name] = baseUrl + removeTrailing(mainImport, '/');
|
|
203
|
-
importMap.imports[packageJsonObj.name + '/'] = baseUrl;
|
|
204
197
|
//@ts-ignore
|
|
205
|
-
importShim.
|
|
198
|
+
const map = importShim.getImportMap().imports;
|
|
199
|
+
if (!map.hasOwnProperty(packageJsonObj.name)) {
|
|
200
|
+
//todo - use exports of package.json for importMap
|
|
201
|
+
const importMap = { imports: {}, scopes: {} };
|
|
202
|
+
let mainImport = packageJsonObj.main;
|
|
203
|
+
if (packageJsonObj.module)
|
|
204
|
+
mainImport = packageJsonObj.module;
|
|
205
|
+
importMap.imports[packageJsonObj.name] = baseUrl + removeTrailing(mainImport, '/');
|
|
206
|
+
importMap.imports[packageJsonObj.name + '/'] = baseUrl;
|
|
207
|
+
//@ts-ignore
|
|
208
|
+
importShim.addImportMap(importMap);
|
|
209
|
+
}
|
|
206
210
|
}
|
|
207
211
|
}
|
|
@@ -103,7 +103,9 @@ export class AbstractStylesheetService {
|
|
|
103
103
|
let parts = rule.selectorText.split(',');
|
|
104
104
|
let sel = "";
|
|
105
105
|
for (let p of parts) {
|
|
106
|
-
if (p
|
|
106
|
+
if (p == ':host')
|
|
107
|
+
sel += DesignerCanvas.cssprefixConstant;
|
|
108
|
+
else if (p.includes(DesignerCanvas.cssprefixConstant)) {
|
|
107
109
|
sel += p;
|
|
108
110
|
continue;
|
|
109
111
|
}
|
|
@@ -229,6 +229,12 @@ export class DesignerCanvas extends BaseCustomWebComponentLazyAppend {
|
|
|
229
229
|
#node-projects-designer-search-container > #node-projects-designer-search-close::after {
|
|
230
230
|
transform: translate(-50%, -50%) rotate(-45deg);
|
|
231
231
|
}
|
|
232
|
+
|
|
233
|
+
#node-projects-designer-canvas-canvas {
|
|
234
|
+
margin: 0;
|
|
235
|
+
padding: 0;
|
|
236
|
+
border: none;
|
|
237
|
+
}
|
|
232
238
|
`;
|
|
233
239
|
static template = html `
|
|
234
240
|
<div style="display: flex;flex-direction: column;width: 100%;height: 100%; margin: 0 !important; padding: 0 !important; border: none !important;">
|
|
@@ -236,7 +242,7 @@ export class DesignerCanvas extends BaseCustomWebComponentLazyAppend {
|
|
|
236
242
|
<div id="node-projects-designer-canvas-outercanvas2" style="width:100%;height:100%;position:relative; margin: 0 !important; padding: 0 !important; border: none !important; isolation: isolate !important;">
|
|
237
243
|
<div id="node-projects-designer-canvas-canvasContainer"
|
|
238
244
|
style="width: 100%;height: 100%;position: absolute;top: 0;left: 0;user-select: none; margin: 0 !important; padding: 0 !important; border: none !important;">
|
|
239
|
-
<div id="node-projects-designer-canvas-canvas" part="canvas"
|
|
245
|
+
<div id="node-projects-designer-canvas-canvas" part="canvas"></div>
|
|
240
246
|
</div>
|
|
241
247
|
</div>
|
|
242
248
|
<div id="node-projects-designer-canvas-clickOverlay" tabindex="0" style="pointer-events: auto; margin: 0 !important; padding: 0 !important; border: none !important;"></div>
|