@node-projects/web-component-designer 0.1.2 → 0.1.4
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/documentContainer.js +4 -1
- package/dist/elements/helper/NpmPackageLoader.js +1 -8
- package/dist/elements/services/propertiesService/services/CssCurrentPropertiesService.js +1 -8
- package/dist/elements/services/propertiesService/services/CssPropertiesService.js +1 -8
- package/package.json +1 -1
|
@@ -211,7 +211,7 @@ export class DocumentContainer extends BaseCustomWebComponentLazyAppend {
|
|
|
211
211
|
this._codeDiv.appendChild(this.codeView);
|
|
212
212
|
}
|
|
213
213
|
if (i.newIndex === 0 || i.newIndex === 2)
|
|
214
|
-
this.designerView.parseHTML(this._content);
|
|
214
|
+
this.designerView.parseHTML(this._content, this._firstLoad);
|
|
215
215
|
if (i.newIndex === 1 || i.newIndex === 2) {
|
|
216
216
|
this.codeView.update(this._content);
|
|
217
217
|
if (this._selectionPosition) {
|
|
@@ -229,6 +229,9 @@ export class DocumentContainer extends BaseCustomWebComponentLazyAppend {
|
|
|
229
229
|
if (i.newIndex === 3) {
|
|
230
230
|
this.demoView.display(this._serviceContainer, this.designerView.instanceServiceContainer, this._content, this.additionalStyleString);
|
|
231
231
|
}
|
|
232
|
+
if (this._content) {
|
|
233
|
+
this._firstLoad = false;
|
|
234
|
+
}
|
|
232
235
|
});
|
|
233
236
|
if (this._content) {
|
|
234
237
|
this.content = this._content;
|
|
@@ -5,14 +5,7 @@ import { removeLeading, removeTrailing } from "./Helper.js";
|
|
|
5
5
|
//TODO: remove this code when import asserts are supported
|
|
6
6
|
let packageHacks;
|
|
7
7
|
//@ts-ignore
|
|
8
|
-
|
|
9
|
-
const packageHacksUrl = import.meta.resolve('./NpmPackageHacks.json');
|
|
10
|
-
//@ts-ignore
|
|
11
|
-
packageHacks = await importShim(packageHacksUrl, { assert: { type: 'json' } });
|
|
12
|
-
}
|
|
13
|
-
else
|
|
14
|
-
//@ts-ignore
|
|
15
|
-
packageHacks = await import("./NpmPackageHacks.json", { assert: { type: 'json' } });
|
|
8
|
+
packageHacks = await import("./NpmPackageHacks.json", { assert: { type: 'json' } });
|
|
16
9
|
if (packageHacks.default)
|
|
17
10
|
packageHacks = packageHacks.default;
|
|
18
11
|
export class NpmPackageLoader {
|
|
@@ -6,14 +6,7 @@ import { NodeType } from '../../../item/NodeType.js';
|
|
|
6
6
|
//TODO: remove this code when import asserts are supported
|
|
7
7
|
let cssProperties;
|
|
8
8
|
//@ts-ignore
|
|
9
|
-
|
|
10
|
-
const cssPropertiesUrl = import.meta.resolve('./CssProperties.json');
|
|
11
|
-
//@ts-ignore
|
|
12
|
-
cssProperties = await importShim(cssPropertiesUrl, { assert: { type: 'json' } });
|
|
13
|
-
}
|
|
14
|
-
else
|
|
15
|
-
//@ts-ignore
|
|
16
|
-
cssProperties = await import("./CssProperties.json", { assert: { type: 'json' } });
|
|
9
|
+
cssProperties = await import("./CssProperties.json", { assert: { type: 'json' } });
|
|
17
10
|
if (cssProperties.default)
|
|
18
11
|
cssProperties = cssProperties.default;
|
|
19
12
|
const localName = '<local>';
|
|
@@ -8,14 +8,7 @@ import { MetricsPropertyEditor } from '../propertyEditors/special/MetricsPropert
|
|
|
8
8
|
//TODO: remove this code when import asserts are supported
|
|
9
9
|
let cssProperties;
|
|
10
10
|
//@ts-ignore
|
|
11
|
-
|
|
12
|
-
const cssPropertiesUrl = import.meta.resolve('./CssProperties.json');
|
|
13
|
-
//@ts-ignore
|
|
14
|
-
cssProperties = await importShim(cssPropertiesUrl, { assert: { type: 'json' } });
|
|
15
|
-
}
|
|
16
|
-
else
|
|
17
|
-
//@ts-ignore
|
|
18
|
-
cssProperties = await import("./CssProperties.json", { assert: { type: 'json' } });
|
|
11
|
+
cssProperties = await import("./CssProperties.json", { assert: { type: 'json' } });
|
|
19
12
|
if (cssProperties.default)
|
|
20
13
|
cssProperties = cssProperties.default;
|
|
21
14
|
export class CssPropertiesService extends CommonPropertiesService {
|