@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.
@@ -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.addImportMap(importMap);
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
  }
@@ -35,7 +35,8 @@ export class CssPropertiesService extends CommonPropertiesService {
35
35
  "inset",
36
36
  "margin",
37
37
  "border",
38
- "padding"
38
+ "padding",
39
+ "overflow"
39
40
  ];
40
41
  grid = [
41
42
  "display",
@@ -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.includes(DesignerCanvas.cssprefixConstant)) {
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" style=" margin: 0 !important; padding: 0 !important; border: none !important;"></div>
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>
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "description": "A UI designer for Polymer apps",
3
3
  "name": "@node-projects/web-component-designer",
4
- "version": "0.0.247",
4
+ "version": "0.0.249",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
7
7
  "author": "",