@genexus/genexus-ide-ui 1.0.43 → 1.0.45
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/cjs/genexus-ide-ui.cjs.js +1 -1
- package/dist/cjs/gx-ide-design-import.cjs.entry.js +39 -6
- package/dist/cjs/gx-ide-design-import.cjs.entry.js.map +1 -1
- package/dist/cjs/gx-ide-entity-selector.cjs.entry.js +3 -1
- package/dist/cjs/gx-ide-entity-selector.cjs.entry.js.map +1 -1
- package/dist/cjs/gx-ide-ww-attributes.cjs.entry.js +244 -0
- package/dist/cjs/gx-ide-ww-attributes.cjs.entry.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/_helpers/entity-selector/entity-selector.js +4 -2
- package/dist/collection/components/_helpers/entity-selector/entity-selector.js.map +1 -1
- package/dist/collection/components/design-import/design-import.js +39 -6
- package/dist/collection/components/design-import/design-import.js.map +1 -1
- package/dist/collection/components/ww-attributes/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.en.json +30 -0
- package/dist/collection/components/ww-attributes/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.ja.json +30 -0
- package/dist/collection/components/ww-attributes/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.zh.json +30 -0
- package/dist/collection/components/ww-attributes/helpers.js +11 -0
- package/dist/collection/components/ww-attributes/helpers.js.map +1 -0
- package/dist/collection/components/ww-attributes/ww-attributes.css +70 -0
- package/dist/collection/components/ww-attributes/ww-attributes.js +468 -0
- package/dist/collection/components/ww-attributes/ww-attributes.js.map +1 -0
- package/dist/collection/testing/locale.e2e.js +1 -0
- package/dist/collection/testing/locale.e2e.js.map +1 -1
- package/dist/components/entity-selector.js +3 -1
- package/dist/components/entity-selector.js.map +1 -1
- package/dist/components/gx-ide-design-import.js +39 -6
- package/dist/components/gx-ide-design-import.js.map +1 -1
- package/dist/components/gx-ide-ww-attributes.d.ts +11 -0
- package/dist/components/gx-ide-ww-attributes.js +294 -0
- package/dist/components/gx-ide-ww-attributes.js.map +1 -0
- package/dist/esm/genexus-ide-ui.js +1 -1
- package/dist/esm/gx-ide-design-import.entry.js +39 -6
- package/dist/esm/gx-ide-design-import.entry.js.map +1 -1
- package/dist/esm/gx-ide-entity-selector.entry.js +3 -1
- package/dist/esm/gx-ide-entity-selector.entry.js.map +1 -1
- package/dist/esm/gx-ide-ww-attributes.entry.js +240 -0
- package/dist/esm/gx-ide-ww-attributes.entry.js.map +1 -0
- package/dist/esm/loader.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js +1 -1
- package/dist/genexus-ide-ui/genexus-ide-ui.esm.js.map +1 -1
- package/dist/genexus-ide-ui/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.en.json +30 -0
- package/dist/genexus-ide-ui/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.ja.json +30 -0
- package/dist/genexus-ide-ui/gx-ide-assets/ww-attributes/langs/ww-attributes.lang.zh.json +30 -0
- package/dist/genexus-ide-ui/{p-04d7f44c.entry.js → p-1693a2d1.entry.js} +4 -2
- package/dist/genexus-ide-ui/p-1693a2d1.entry.js.map +1 -0
- package/dist/genexus-ide-ui/{p-512147a8.entry.js → p-2b4b1dfc.entry.js} +225 -192
- package/dist/genexus-ide-ui/p-2b4b1dfc.entry.js.map +1 -0
- package/dist/genexus-ide-ui/p-5619120d.entry.js +341 -0
- package/dist/genexus-ide-ui/p-5619120d.entry.js.map +1 -0
- package/dist/types/components/_helpers/entity-selector/entity-selector.d.ts +1 -1
- package/dist/types/components/design-import/design-import.d.ts +5 -1
- package/dist/types/components/ww-attributes/helpers.d.ts +3 -0
- package/dist/types/components/ww-attributes/ww-attributes.d.ts +95 -0
- package/dist/types/components.d.ts +99 -12
- package/package.json +1 -1
- package/dist/genexus-ide-ui/p-04d7f44c.entry.js.map +0 -1
- package/dist/genexus-ide-ui/p-512147a8.entry.js.map +0 -1
|
@@ -39,7 +39,7 @@ const r = {
|
|
|
39
39
|
}
|
|
40
40
|
};
|
|
41
41
|
|
|
42
|
-
const
|
|
42
|
+
const h = {
|
|
43
43
|
panels: [ {
|
|
44
44
|
id: r.composition.id,
|
|
45
45
|
name: r.composition.caption
|
|
@@ -77,7 +77,7 @@ const l = {
|
|
|
77
77
|
} ]
|
|
78
78
|
};
|
|
79
79
|
|
|
80
|
-
const
|
|
80
|
+
const l = new Map([ [ "panels", h.panels ], [ "stencils", h.stencils ], [ "images", h.images ], [ "design_system", h.designSystem ], [ "fonts", h.fonts ] ]);
|
|
81
81
|
|
|
82
82
|
const c = '@keyframes spin{0%{transform:rotate(0deg)}100%{transform:rotate(360deg)}}:host{display:grid;block-size:100%;overflow:auto;grid-template-rows:max-content 1fr max-content}.section{display:contents}.header{display:grid;grid-auto-rows:max-content;grid-template-columns:minmax(88px, max-content) 1fr !important}.header--show-access-token{grid-template-areas:"path-url-label path-url-wrapper" "access-token-label access-token" "style-label style" "module-label module" "checkboxes-options checkboxes-options"}.header--hide-access-token{grid-template-areas:"path-url-label path-url-wrapper" "style-label style" "module-label module" "checkboxes-options checkboxes-options"}.path-url-wrapper{grid-template-columns:1fr max-content}.path-url-label{grid-area:path-url-label}.path-url-control{flex-grow:1}.select-load-button{min-inline-size:80px}.access-token-label{grid-area:access-token-label}.access-token{grid-area:access-token}.style-label{grid-area:style-label}.style{grid-area:style}.module-label{grid-area:module-label}.module{grid-area:module}.checkboxes-options{grid-area:checkboxes-options;grid-template-columns:max-content max-content;justify-content:space-between}.main{display:grid;grid-template-columns:250px 1fr;block-size:100%;overflow:auto}.main--loading{grid-template-columns:1fr}.panel-tab{block-size:100%;display:grid;grid-template-columns:1fr 300px}.panel-tab .panel-item{overflow:auto}.panel-tab:has(>:only-child){grid-template-columns:1fr}.tree-view{padding-block:var(--mer-spacing--2xs)}.tree-view-panel-item{border-inline-start:var(--section-common-border)}.checker-board{--white-square-color:#fff1;--black-square-color:#0000;background:linear-gradient(45deg, var(--white-square-color) 25%, var(--black-square-color) 25%), linear-gradient(-45deg, var(--white-square-color) 25%, var(--black-square-color) 25%), linear-gradient(45deg, var(--black-square-color) 75%, var(--white-square-color) 75%), linear-gradient(-45deg, var(--black-square-color) 75%, var(--white-square-color) 75%);background-size:20px 20px;background-position:0 0, 0 10px, 10px -10px, -10px 0px}.tab{border-width:0 !important}.tab.fit-images .composition-tab-slot{font-size:0}.tab.fit-images img{object-fit:scale-down;object-position:left top;max-height:100%}.tab--hidden{display:none}.button-cancel,.button-ok{min-inline-size:var(--mer-spacing--4xl)}.messages-slot-container{block-size:100%}.composition-tab-slot{block-size:100%;overflow:auto}.empty-state{overflow:auto}.empty-state-button{transform:translateY(-12px)}.message{animation:fadeIn var(--mer-timing--fast) ease-in-out forwards}.message--info{color:var(--mer-text__on-surface)}.message--warning{color:var(--mer-text__warning)}.message--error{color:var(--mer-text__error)}@keyframes fadeIn{from{opacity:0}to{opacity:1}}.combo-box.ch-disabled{--control__bg-color:var(--control__background-color--disabled);--control__border-color:var(--control__border-color--disabled);--control__color:var(--control__color--disabled);--ch-placeholder-color:var(--control-placeholder__color--disabled)}.tree-view::part(item__header){min-inline-size:var(--tree-view__min-inline-size)}';
|
|
83
83
|
|
|
@@ -94,54 +94,54 @@ var p = undefined && undefined.__classPrivateFieldSet || function(t, e, s, i, a)
|
|
|
94
94
|
return i === "a" ? a.call(t, s) : a ? a.value = s : e.set(t, s), s;
|
|
95
95
|
};
|
|
96
96
|
|
|
97
|
-
var f, u, m, b, g, k, w, v, y, x, M, W, _, I, C, $, j, D, S, T, z, P, q, A, E, F, V, G, L, O, B, H, N, Y, J, K, Q,
|
|
97
|
+
var f, u, m, b, g, k, w, v, y, x, M, W, _, I, C, $, j, D, S, T, z, P, q, A, E, F, V, G, L, O, B, H, R, N, Y, J, K, Q, U, X, Z, tt, et, st, it, at, ot, nt, rt, ht, lt, ct, dt, pt, ft, ut;
|
|
98
98
|
|
|
99
|
-
const
|
|
99
|
+
const mt = "panels";
|
|
100
100
|
|
|
101
|
-
const
|
|
101
|
+
const bt = "stencils";
|
|
102
102
|
|
|
103
|
-
const
|
|
103
|
+
const gt = "images";
|
|
104
104
|
|
|
105
|
-
const
|
|
105
|
+
const kt = "design_system";
|
|
106
106
|
|
|
107
|
-
const
|
|
107
|
+
const wt = "fonts";
|
|
108
108
|
|
|
109
|
-
const
|
|
109
|
+
const vt = "@@@";
|
|
110
110
|
|
|
111
111
|
// ch-checkbox
|
|
112
|
-
const
|
|
112
|
+
const yt = "on";
|
|
113
113
|
|
|
114
114
|
// Icons
|
|
115
|
-
const
|
|
115
|
+
const xt = a({
|
|
116
116
|
category: "menus",
|
|
117
117
|
name: "delete",
|
|
118
118
|
colorType: "primary"
|
|
119
119
|
});
|
|
120
120
|
|
|
121
|
-
const
|
|
121
|
+
const Mt = a({
|
|
122
122
|
category: "objects",
|
|
123
123
|
name: "design"
|
|
124
124
|
});
|
|
125
125
|
|
|
126
|
-
const
|
|
126
|
+
const Wt = a({
|
|
127
127
|
category: "controls",
|
|
128
128
|
name: "file-upload"
|
|
129
129
|
});
|
|
130
130
|
|
|
131
131
|
// For empty states
|
|
132
|
-
const
|
|
132
|
+
const _t = a({
|
|
133
133
|
category: "objects",
|
|
134
134
|
name: "webpanel"
|
|
135
135
|
});
|
|
136
136
|
|
|
137
|
-
const
|
|
137
|
+
const It = a({
|
|
138
138
|
category: "objects",
|
|
139
139
|
name: "panel-for-sd"
|
|
140
140
|
});
|
|
141
141
|
|
|
142
|
-
const
|
|
142
|
+
const Ct = [ "resets/box-sizing", "utils/form", "utils/layout", "utils/typography", "utils/spacing", "components/button", "components/checkbox", "components/edit", "components/tree-view", "components/combo-box", "components/tab", "components/tooltip", "chameleon/scrollbar" ];
|
|
143
143
|
|
|
144
|
-
const
|
|
144
|
+
const $t = class {
|
|
145
145
|
constructor(s) {
|
|
146
146
|
t(this, s);
|
|
147
147
|
f.add(this);
|
|
@@ -161,17 +161,34 @@ const _t = class {
|
|
|
161
161
|
m.set(this, new Map);
|
|
162
162
|
b.set(this, false);
|
|
163
163
|
g.set(this, void 0);
|
|
164
|
-
|
|
165
|
-
|
|
164
|
+
k.set(this, {
|
|
165
|
+
all: [],
|
|
166
|
+
none: [ "-" ]
|
|
167
|
+
});
|
|
168
|
+
/* References needed to collect data */ w.set(this, void 0);
|
|
166
169
|
v.set(this, void 0);
|
|
167
170
|
y.set(this, void 0);
|
|
168
|
-
x.set(this,
|
|
171
|
+
x.set(this, void 0);
|
|
169
172
|
M.set(this, []);
|
|
170
173
|
W.set(this, []);
|
|
171
174
|
_.set(this, []);
|
|
172
|
-
I.set(this,
|
|
175
|
+
I.set(this, []);
|
|
173
176
|
C.set(this, void 0);
|
|
174
|
-
$.set(this,
|
|
177
|
+
$.set(this, void 0);
|
|
178
|
+
j.set(this, (t => {
|
|
179
|
+
let e = 0;
|
|
180
|
+
function countItemsRecursively(t) {
|
|
181
|
+
for (const s of t) {
|
|
182
|
+
e++;
|
|
183
|
+
if (s.variants && Array.isArray(s.variants)) {
|
|
184
|
+
countItemsRecursively(s.variants);
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
countItemsRecursively(t);
|
|
189
|
+
return e;
|
|
190
|
+
}));
|
|
191
|
+
D.set(this, (t => [ {
|
|
175
192
|
leaf: true,
|
|
176
193
|
caption: `Warning: ${t}`,
|
|
177
194
|
startImgSrc: a({
|
|
@@ -183,43 +200,43 @@ const _t = class {
|
|
|
183
200
|
checkbox: false,
|
|
184
201
|
disabled: true
|
|
185
202
|
} ]));
|
|
186
|
-
|
|
187
|
-
this.activeTabs.set("panels",
|
|
188
|
-
this.activeTabs.set("stencils",
|
|
189
|
-
this.activeTabs.set("images",
|
|
190
|
-
this.activeTabs.set("fonts",
|
|
191
|
-
this.activeTabs.set("design_system",
|
|
203
|
+
T.set(this, (() => {
|
|
204
|
+
this.activeTabs.set("panels", h.panels[0].id);
|
|
205
|
+
this.activeTabs.set("stencils", h.stencils[0].id);
|
|
206
|
+
this.activeTabs.set("images", h.images[0].id);
|
|
207
|
+
this.activeTabs.set("fonts", h.fonts[0].id);
|
|
208
|
+
this.activeTabs.set("design_system", h.designSystem[0].id);
|
|
192
209
|
}));
|
|
193
|
-
|
|
210
|
+
z.set(this, (async () => {
|
|
194
211
|
this.requiresAccessToken = await this.requiresAccessTokenCallback(this.path);
|
|
195
212
|
// evaluate access token error
|
|
196
213
|
if (this.accessToken.length) {
|
|
197
214
|
this.accessTokenHasError = false;
|
|
198
215
|
}
|
|
199
216
|
}));
|
|
200
|
-
|
|
217
|
+
P.set(this, (async () => {
|
|
201
218
|
const t = this.isLoaded && this.reactiveSettings.path && this.pathIsValid && this.path !== this.lastLoadCallbackSettingValues.path;
|
|
202
219
|
const e = !this.requiresAccessToken || this.requiresAccessToken && this.accessToken.length > 0;
|
|
203
220
|
if (t && e) {
|
|
204
|
-
d(this,
|
|
221
|
+
d(this, B, "f").call(this);
|
|
205
222
|
}
|
|
206
223
|
}));
|
|
207
|
-
|
|
224
|
+
A.set(this, (async t => {
|
|
208
225
|
var e;
|
|
209
226
|
if (t.detail.length) {
|
|
210
227
|
const s = (e = t.detail[0]) === null || e === void 0 ? void 0 : e.item;
|
|
211
228
|
const i = s.id;
|
|
212
|
-
const a = i.split(
|
|
229
|
+
const a = i.split(vt);
|
|
213
230
|
const o = a[0];
|
|
214
231
|
const n = a[1];
|
|
215
232
|
const r = o && o !== "parent";
|
|
216
|
-
const
|
|
217
|
-
if (r ||
|
|
218
|
-
this.tabsModel =
|
|
233
|
+
const h = n === "design_system";
|
|
234
|
+
if (r || h) {
|
|
235
|
+
this.tabsModel = l.get(n);
|
|
219
236
|
this.selectedDesignType = n;
|
|
220
|
-
const t = d(this,
|
|
237
|
+
const t = d(this, E, "f").call(this, i);
|
|
221
238
|
if (!t) {
|
|
222
|
-
const t = await d(this,
|
|
239
|
+
const t = await d(this, R, "f").call(this, o, this.selectedDesignType);
|
|
223
240
|
d(this, m, "f").set(i, {
|
|
224
241
|
designType: this.selectedDesignType,
|
|
225
242
|
designDataDetail: t
|
|
@@ -228,19 +245,19 @@ const _t = class {
|
|
|
228
245
|
// Item has been queried already. The item content exists already.
|
|
229
246
|
this.selectedDesignType = t.designType;
|
|
230
247
|
this.selectedDesignItem = t.designDataDetail;
|
|
231
|
-
d(this, f, "m",
|
|
232
|
-
d(this, f, "m",
|
|
248
|
+
d(this, f, "m", N).call(this, t.designType);
|
|
249
|
+
d(this, f, "m", nt).call(this, t.designType);
|
|
233
250
|
}
|
|
234
251
|
this.renderedTabs.clear();
|
|
235
252
|
this.renderedTabs.add(this.activeTabs.get(this.selectedDesignType));
|
|
236
253
|
}
|
|
237
254
|
}
|
|
238
255
|
}));
|
|
239
|
-
|
|
256
|
+
E.set(this, (t => {
|
|
240
257
|
var e;
|
|
241
258
|
return (e = d(this, m, "f")) === null || e === void 0 ? void 0 : e.get(t);
|
|
242
259
|
}));
|
|
243
|
-
|
|
260
|
+
F.set(this, (t => {
|
|
244
261
|
const e = /^(\/|\.\/|(\w:))[^:*?"<>|]*\.(sketch|gxsketch)$/i;
|
|
245
262
|
// Match valid file paths
|
|
246
263
|
const s = /^https?:\/\/(www\.)?figma\.com/;
|
|
@@ -250,18 +267,18 @@ const _t = class {
|
|
|
250
267
|
const a = e.test(t) || s.test(t) || i.test(t);
|
|
251
268
|
return a;
|
|
252
269
|
}));
|
|
253
|
-
|
|
270
|
+
V.set(this, (t => {
|
|
254
271
|
const e = Array.from(t.detail.values());
|
|
255
272
|
let s = null;
|
|
256
273
|
const i = {};
|
|
257
274
|
for (const t of e) {
|
|
258
|
-
if (t.item.id.startsWith(`parent${
|
|
259
|
-
s = t.item.id.split(
|
|
275
|
+
if (t.item.id.startsWith(`parent${vt}`)) {
|
|
276
|
+
s = t.item.id.split(vt)[1];
|
|
260
277
|
i[s] = [];
|
|
261
278
|
} else if (t.item.checked && s) {
|
|
262
|
-
const e = t.item.id.split(
|
|
279
|
+
const e = t.item.id.split(vt)[1];
|
|
263
280
|
if (e === s) {
|
|
264
|
-
const e = t.item.id.split(
|
|
281
|
+
const e = t.item.id.split(vt)[0];
|
|
265
282
|
i[s].push(e);
|
|
266
283
|
}
|
|
267
284
|
}
|
|
@@ -269,37 +286,37 @@ const _t = class {
|
|
|
269
286
|
// const { designSystem, fonts, images, panels, stencils } = result;
|
|
270
287
|
const {fonts: a, panels: o, stencils: n, images: r} = i;
|
|
271
288
|
// this.designSystemSelected = designSystem;
|
|
272
|
-
p(this,
|
|
273
|
-
p(this,
|
|
274
|
-
p(this,
|
|
275
|
-
p(this,
|
|
289
|
+
p(this, M, o, "f");
|
|
290
|
+
p(this, W, n, "f");
|
|
291
|
+
p(this, _, r, "f");
|
|
292
|
+
p(this, I, a, "f");
|
|
276
293
|
}));
|
|
277
|
-
|
|
278
|
-
d(this,
|
|
294
|
+
G.set(this, (() => {
|
|
295
|
+
d(this, C, "f").click();
|
|
279
296
|
}));
|
|
280
|
-
|
|
297
|
+
L.set(this, (t => {
|
|
281
298
|
this.styleValue = t.target.value;
|
|
282
299
|
if (this.reactiveSettings.style && this.styleValue !== this.lastLoadCallbackSettingValues.style) {
|
|
283
|
-
d(this,
|
|
300
|
+
d(this, B, "f").call(this);
|
|
284
301
|
}
|
|
285
302
|
}));
|
|
286
|
-
|
|
303
|
+
O.set(this, (t => {
|
|
287
304
|
if (this.reactiveSettings.module && this.defaultModule.id !== t.detail.id && this.pathIsValid) {
|
|
288
|
-
d(this,
|
|
305
|
+
d(this, B, "f").call(this);
|
|
289
306
|
}
|
|
290
307
|
}));
|
|
291
|
-
|
|
308
|
+
B.set(this, (async () => {
|
|
292
309
|
var t, e;
|
|
293
310
|
this.isLoading = true;
|
|
294
311
|
const s = this.selectedFile ? this.selectedFile : this.path;
|
|
295
|
-
const i = d(this,
|
|
312
|
+
const i = d(this, w, "f") ? d(this, w, "f").value : undefined;
|
|
296
313
|
const a = this.styleValue;
|
|
297
|
-
const o = d(this,
|
|
298
|
-
const n = await this.loadCallback(s, a, o, i, d(this,
|
|
314
|
+
const o = d(this, v, "f").value === yt;
|
|
315
|
+
const n = await this.loadCallback(s, a, o, i, d(this, H, "f"));
|
|
299
316
|
// clear
|
|
300
|
-
p(this,
|
|
301
|
-
p(this,
|
|
302
|
-
p(this,
|
|
317
|
+
p(this, M, [], "f");
|
|
318
|
+
p(this, W, [], "f");
|
|
319
|
+
p(this, I, [], "f");
|
|
303
320
|
this.selectedDesignType = undefined;
|
|
304
321
|
this.selectedDesignItem = undefined;
|
|
305
322
|
this.messages = [];
|
|
@@ -318,32 +335,32 @@ const _t = class {
|
|
|
318
335
|
this.lastLoadCallbackSettingValues.style = a;
|
|
319
336
|
}
|
|
320
337
|
if (this.reactiveSettings.module) {
|
|
321
|
-
this.lastLoadCallbackSettingValues.moduleId = d(this,
|
|
338
|
+
this.lastLoadCallbackSettingValues.moduleId = d(this, y, "f").value.id;
|
|
322
339
|
}
|
|
323
340
|
if (this.reactiveSettings.importAsWebPanels) {
|
|
324
341
|
this.lastLoadCallbackSettingValues.importAsWebPanels = o;
|
|
325
342
|
}
|
|
326
343
|
}));
|
|
327
|
-
|
|
344
|
+
H.set(this, (t => {
|
|
328
345
|
this.messages = [ ...this.messages, t ];
|
|
329
346
|
}));
|
|
330
|
-
|
|
347
|
+
R.set(this, (async (t, e) => {
|
|
331
348
|
let s;
|
|
332
349
|
switch (e) {
|
|
333
|
-
case
|
|
350
|
+
case gt:
|
|
334
351
|
s = this.loadImageCallback;
|
|
335
352
|
break;
|
|
336
353
|
|
|
337
|
-
case
|
|
354
|
+
case kt:
|
|
338
355
|
s = this.loadDesignSystemCallback;
|
|
339
356
|
break;
|
|
340
357
|
|
|
341
|
-
case
|
|
358
|
+
case wt:
|
|
342
359
|
s = this.loadFontCallback;
|
|
343
360
|
break;
|
|
344
361
|
|
|
345
|
-
case
|
|
346
|
-
case
|
|
362
|
+
case mt:
|
|
363
|
+
case bt:
|
|
347
364
|
s = this.loadPanelDataCallback;
|
|
348
365
|
break;
|
|
349
366
|
}
|
|
@@ -351,46 +368,61 @@ const _t = class {
|
|
|
351
368
|
await s(t).then((t => {
|
|
352
369
|
this.selectedDesignType = e;
|
|
353
370
|
this.selectedDesignItem = t;
|
|
354
|
-
d(this, f, "m",
|
|
355
|
-
d(this, f, "m",
|
|
371
|
+
d(this, f, "m", N).call(this, e);
|
|
372
|
+
d(this, f, "m", nt).call(this, e);
|
|
356
373
|
i = t;
|
|
357
374
|
}));
|
|
358
375
|
return i;
|
|
359
376
|
}));
|
|
360
|
-
|
|
377
|
+
Y.set(this, ((t, e) => {
|
|
378
|
+
let s = e;
|
|
379
|
+
const i = d(this, j, "f").call(this, t);
|
|
380
|
+
const a = e.length;
|
|
381
|
+
if (i === a) {
|
|
382
|
+
s = d(this, k, "f").all;
|
|
383
|
+
} else if (a === 0) {
|
|
384
|
+
s = d(this, k, "f").none;
|
|
385
|
+
}
|
|
386
|
+
return s;
|
|
387
|
+
}));
|
|
388
|
+
J.set(this, (() => {
|
|
361
389
|
var t, e;
|
|
390
|
+
const s = d(this, Y, "f").call(this, this.designData.panels, d(this, M, "f"));
|
|
391
|
+
const i = d(this, Y, "f").call(this, this.designData.stencils, d(this, W, "f"));
|
|
392
|
+
const a = d(this, Y, "f").call(this, this.designData.images, d(this, _, "f"));
|
|
393
|
+
const o = d(this, Y, "f").call(this, this.designData.fonts, d(this, I, "f"));
|
|
362
394
|
this.confirmCallback({
|
|
363
|
-
panels:
|
|
364
|
-
stencils:
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
moduleId: (e = (t = d(this,
|
|
395
|
+
panels: s,
|
|
396
|
+
stencils: i,
|
|
397
|
+
images: a,
|
|
398
|
+
fonts: o,
|
|
399
|
+
moduleId: (e = (t = d(this, y, "f")) === null || t === void 0 ? void 0 : t.value) === null || e === void 0 ? void 0 : e.id,
|
|
368
400
|
styleName: this.styleValue,
|
|
369
|
-
importAsWebPanels: d(this,
|
|
401
|
+
importAsWebPanels: d(this, v, "f").value === yt
|
|
370
402
|
});
|
|
371
403
|
}));
|
|
372
|
-
|
|
404
|
+
K.set(this, (() => {
|
|
373
405
|
this.cancelCallback();
|
|
374
406
|
this.isLoading = false;
|
|
375
407
|
}));
|
|
376
|
-
|
|
377
|
-
this.fitImages = t.detail ===
|
|
408
|
+
Q.set(this, (t => {
|
|
409
|
+
this.fitImages = t.detail === yt;
|
|
378
410
|
}));
|
|
379
|
-
|
|
380
|
-
|
|
411
|
+
U.set(this, (t => t.reduce(((t, e, s, i) => i[t].name <= e.name ? t : s), 0)));
|
|
412
|
+
X.set(this, (() => {
|
|
381
413
|
const t = this.reactiveSettings.importAsWebPanels && this.pathIsValid;
|
|
382
414
|
if (t) {
|
|
383
|
-
d(this,
|
|
415
|
+
d(this, B, "f").call(this);
|
|
384
416
|
}
|
|
385
417
|
}));
|
|
386
|
-
|
|
418
|
+
Z.set(this, (() => {
|
|
387
419
|
this.selectedFile = null;
|
|
388
420
|
this.path = "";
|
|
389
421
|
this.accessToken = "";
|
|
390
422
|
this.selectedFile = null;
|
|
391
|
-
d(this,
|
|
423
|
+
d(this, C, "f").value = null;
|
|
392
424
|
}));
|
|
393
|
-
|
|
425
|
+
tt.set(this, (t => {
|
|
394
426
|
var e;
|
|
395
427
|
const s = t.target;
|
|
396
428
|
if (((e = s.files) === null || e === void 0 ? void 0 : e.length) > 0) {
|
|
@@ -399,40 +431,40 @@ const _t = class {
|
|
|
399
431
|
// we know the path is valid because the extensions are restricted by "extensions" Prop.
|
|
400
432
|
}
|
|
401
433
|
}));
|
|
402
|
-
|
|
434
|
+
et.set(this, (t => {
|
|
403
435
|
const e = t.target;
|
|
404
436
|
e.type = "text";
|
|
405
437
|
// display token on focus
|
|
406
438
|
}));
|
|
407
|
-
|
|
439
|
+
st.set(this, (t => {
|
|
408
440
|
const e = t.target;
|
|
409
441
|
e.type = "password";
|
|
410
442
|
// hide token on blur
|
|
411
443
|
this.accessTokenChanged(e.value);
|
|
412
444
|
}));
|
|
413
|
-
|
|
445
|
+
it.set(this, (async t => {
|
|
414
446
|
this.path = t.detail;
|
|
415
|
-
d(this,
|
|
447
|
+
d(this, z, "f").call(this);
|
|
416
448
|
this.selectedFile = null;
|
|
417
449
|
if (!this.path.length) {
|
|
418
450
|
this.designData = null;
|
|
419
451
|
}
|
|
420
452
|
}));
|
|
421
|
-
|
|
453
|
+
at.set(this, (() => {
|
|
422
454
|
const t = this.isLoading || this.pathIsValid && this.requiresAccessToken && this.accessToken.length === 0;
|
|
423
455
|
const s = this.isLoading || this.path.length === 0;
|
|
424
456
|
const i = this.isLoading;
|
|
425
457
|
const a = this.isLoading;
|
|
426
458
|
const n = !this.pathIsValid && this.path.length > 0;
|
|
427
459
|
const r = !this.pathIsValid && this.path.length > 0;
|
|
428
|
-
const
|
|
429
|
-
let
|
|
460
|
+
const h = this.isLoading || !this.designDataTreeDataModel.length || this.selectedDesignType === "stencils" || this.selectedDesignType === "design_system";
|
|
461
|
+
let l;
|
|
430
462
|
if (this.pathIsValid && this.path === this.lastLoadCallbackSettingValues.path) {
|
|
431
|
-
|
|
463
|
+
l = d(this, u, "f").header.btnReload;
|
|
432
464
|
} else if (this.pathIsValid) {
|
|
433
|
-
|
|
465
|
+
l = d(this, u, "f").header.btnLoad;
|
|
434
466
|
} else {
|
|
435
|
-
|
|
467
|
+
l = d(this, u, "f").header.selectFileButton;
|
|
436
468
|
}
|
|
437
469
|
return e("header", {
|
|
438
470
|
class: {
|
|
@@ -461,15 +493,15 @@ const _t = class {
|
|
|
461
493
|
part: "option-path",
|
|
462
494
|
type: "text",
|
|
463
495
|
value: this.path,
|
|
464
|
-
onInput: d(this,
|
|
465
|
-
onBlur: this.reactiveSettings.path && d(this,
|
|
496
|
+
onInput: d(this, it, "f"),
|
|
497
|
+
onBlur: this.reactiveSettings.path && d(this, P, "f"),
|
|
466
498
|
disabled: this.isLoading,
|
|
467
499
|
placeholder: `${d(this, u, "f").header.pathPlaceholder}`,
|
|
468
|
-
startImgSrc:
|
|
469
|
-
ref: t => p(this,
|
|
500
|
+
startImgSrc: Wt,
|
|
501
|
+
ref: t => p(this, $, t, "f")
|
|
470
502
|
}), r && e("ch-tooltip", {
|
|
471
503
|
class: "tooltip",
|
|
472
|
-
actionElement: d(this,
|
|
504
|
+
actionElement: d(this, $, "f"),
|
|
473
505
|
blockAlign: o.tooltipSettings.blockAlign,
|
|
474
506
|
inlineAlign: o.tooltipSettings.inlineAlign,
|
|
475
507
|
delay: o.tooltipSettings.delay
|
|
@@ -477,8 +509,8 @@ const _t = class {
|
|
|
477
509
|
hidden: true,
|
|
478
510
|
type: "file",
|
|
479
511
|
accept: d(this, g, "f"),
|
|
480
|
-
onChange: d(this,
|
|
481
|
-
ref: t => p(this,
|
|
512
|
+
onChange: d(this, tt, "f"),
|
|
513
|
+
ref: t => p(this, C, t, "f")
|
|
482
514
|
}), e("div", {
|
|
483
515
|
class: "buttons-spacer"
|
|
484
516
|
}, e("button", {
|
|
@@ -488,16 +520,16 @@ const _t = class {
|
|
|
488
520
|
class: "button-tertiary button-icon-only",
|
|
489
521
|
part: "reset-all-button",
|
|
490
522
|
disabled: s,
|
|
491
|
-
onClick: !s && d(this,
|
|
523
|
+
onClick: !s && d(this, Z, "f")
|
|
492
524
|
}, e("ch-image", {
|
|
493
525
|
class: "icon-md",
|
|
494
|
-
src:
|
|
526
|
+
src: xt,
|
|
495
527
|
disabled: s
|
|
496
528
|
})), e("button", {
|
|
497
529
|
// load file button
|
|
498
530
|
id: "button-load",
|
|
499
531
|
type: "primary-text-only",
|
|
500
|
-
onClick: this.pathIsValid ? d(this,
|
|
532
|
+
onClick: this.pathIsValid ? d(this, B, "f") : d(this, G, "f"),
|
|
501
533
|
part: "button button--load",
|
|
502
534
|
disabled: t,
|
|
503
535
|
class: {
|
|
@@ -505,7 +537,7 @@ const _t = class {
|
|
|
505
537
|
"button-secondary": !this.pathIsValid,
|
|
506
538
|
"select-load-button": true
|
|
507
539
|
}
|
|
508
|
-
},
|
|
540
|
+
}, l))), this.requiresAccessToken && [ e("label", {
|
|
509
541
|
// access token label
|
|
510
542
|
class: "label access-token-label"
|
|
511
543
|
}, d(this, u, "f").header.accessToken), e("div", null, e("ch-edit", {
|
|
@@ -514,17 +546,17 @@ const _t = class {
|
|
|
514
546
|
"access-token": true,
|
|
515
547
|
"input-error": this.accessTokenHasError
|
|
516
548
|
},
|
|
517
|
-
ref: t => p(this,
|
|
549
|
+
ref: t => p(this, w, t, "f"),
|
|
518
550
|
value: this.accessToken,
|
|
519
551
|
placeholder: d(this, u, "f").header.accessTokenPlaceholder,
|
|
520
|
-
onFocus: d(this,
|
|
521
|
-
onBlur: d(this,
|
|
552
|
+
onFocus: d(this, et, "f"),
|
|
553
|
+
onBlur: d(this, st, "f"),
|
|
522
554
|
part: "access-token",
|
|
523
555
|
disabled: this.isLoading,
|
|
524
556
|
type: "password"
|
|
525
557
|
}), this.accessTokenHasError && e("ch-tooltip", {
|
|
526
558
|
class: "tooltip",
|
|
527
|
-
actionElement: d(this,
|
|
559
|
+
actionElement: d(this, w, "f"),
|
|
528
560
|
blockAlign: o.tooltipSettings.blockAlign,
|
|
529
561
|
inlineAlign: o.tooltipSettings.inlineAlign,
|
|
530
562
|
delay: o.tooltipSettings.delay
|
|
@@ -540,7 +572,7 @@ const _t = class {
|
|
|
540
572
|
disabled: i,
|
|
541
573
|
model: this.stylesAsComboBoxModel,
|
|
542
574
|
value: this.styleValue,
|
|
543
|
-
onInput: d(this,
|
|
575
|
+
onInput: d(this, L, "f"),
|
|
544
576
|
part: "option-style",
|
|
545
577
|
class: "combo-box style"
|
|
546
578
|
}), e("label", {
|
|
@@ -552,8 +584,8 @@ const _t = class {
|
|
|
552
584
|
value: this.defaultModule,
|
|
553
585
|
defaultValue: this.defaultModule,
|
|
554
586
|
selectEntityCallback: this.selectModuleCallback,
|
|
555
|
-
ref: t => p(this,
|
|
556
|
-
onValueChanged: this.reactiveSettings.module && d(this,
|
|
587
|
+
ref: t => p(this, y, t, "f"),
|
|
588
|
+
onValueChanged: this.reactiveSettings.module && d(this, O, "f"),
|
|
557
589
|
disabled: a,
|
|
558
590
|
class: "module"
|
|
559
591
|
}), e("div", {
|
|
@@ -561,13 +593,13 @@ const _t = class {
|
|
|
561
593
|
class: "checkboxes-options field-group"
|
|
562
594
|
}, e("ch-checkbox", {
|
|
563
595
|
caption: d(this, u, "f").header.importAs,
|
|
564
|
-
checkedValue:
|
|
596
|
+
checkedValue: yt,
|
|
565
597
|
class: "checkbox import-as-web-panels",
|
|
566
|
-
ref: t => p(this,
|
|
567
|
-
value: this.importAsWebPanels ?
|
|
598
|
+
ref: t => p(this, v, t, "f"),
|
|
599
|
+
value: this.importAsWebPanels ? yt : undefined,
|
|
568
600
|
part: "option-import-as-web-panels",
|
|
569
601
|
disabled: this.isLoading,
|
|
570
|
-
onInput: d(this,
|
|
602
|
+
onInput: d(this, X, "f")
|
|
571
603
|
}), e("div", {
|
|
572
604
|
class: {
|
|
573
605
|
"field-group-inline": true,
|
|
@@ -576,27 +608,27 @@ const _t = class {
|
|
|
576
608
|
}, e("ch-checkbox", {
|
|
577
609
|
// fit images
|
|
578
610
|
caption: d(this, u, "f").header.fitImages,
|
|
579
|
-
checkedValue:
|
|
611
|
+
checkedValue: yt,
|
|
580
612
|
class: "checkbox",
|
|
581
613
|
part: "fit-images-checkbox",
|
|
582
|
-
disabled:
|
|
583
|
-
onInput: d(this,
|
|
614
|
+
disabled: h,
|
|
615
|
+
onInput: d(this, Q, "f")
|
|
584
616
|
}))));
|
|
585
617
|
}));
|
|
586
|
-
|
|
618
|
+
ot.set(this, (() => this.messages.length > 0 && this.messages.map((t => e("p", {
|
|
587
619
|
class: {
|
|
588
620
|
"text-body-regular-m": true,
|
|
589
621
|
message: true,
|
|
590
622
|
[`message--${t.type}`]: true
|
|
591
623
|
}
|
|
592
624
|
}, t.type, ": ", t.text)))));
|
|
593
|
-
|
|
625
|
+
rt.set(this, (() => {
|
|
594
626
|
var t, s;
|
|
595
627
|
if (this.isLoading || ((t = this.designData) === null || t === void 0 ? void 0 : t.success) === false) {
|
|
596
628
|
return e("div", {
|
|
597
629
|
class: "main main--loading scrollable",
|
|
598
|
-
ref: t => p(this,
|
|
599
|
-
}, d(this,
|
|
630
|
+
ref: t => p(this, x, t, "f")
|
|
631
|
+
}, d(this, ot, "f").call(this), e("div", {
|
|
600
632
|
class: "text-body-regular-m spacing-body"
|
|
601
633
|
}, e("slot", {
|
|
602
634
|
name: "messages"
|
|
@@ -605,22 +637,22 @@ const _t = class {
|
|
|
605
637
|
/* #main*/
|
|
606
638
|
return e("div", {
|
|
607
639
|
class: "main"
|
|
608
|
-
}, [ d(this,
|
|
640
|
+
}, [ d(this, ht, "f").call(this), d(this, ut, "f").call(this) ]);
|
|
609
641
|
} else {
|
|
610
642
|
return e("gx-ide-empty-state", {
|
|
611
643
|
class: "empty-state scrollable",
|
|
612
|
-
stateIconSrc:
|
|
644
|
+
stateIconSrc: Mt,
|
|
613
645
|
isAnimated: d(this, b, "f"),
|
|
614
646
|
stateTitle: d(this, u, "f").messages.noDesignSelected,
|
|
615
647
|
key: "no-objects-empty-state"
|
|
616
648
|
}, e("button", {
|
|
617
649
|
// begin by selecting a file
|
|
618
650
|
class: "button-tertiary empty-state-button",
|
|
619
|
-
onClick: d(this,
|
|
651
|
+
onClick: d(this, G, "f")
|
|
620
652
|
}, d(this, u, "f").messages.selectDesign));
|
|
621
653
|
}
|
|
622
654
|
}));
|
|
623
|
-
|
|
655
|
+
ht.set(this, (() => e("ch-tree-view-render", {
|
|
624
656
|
part: "data-tree",
|
|
625
657
|
class: "tree-view",
|
|
626
658
|
id: "data-tree",
|
|
@@ -633,10 +665,10 @@ const _t = class {
|
|
|
633
665
|
toggleCheckboxes: true,
|
|
634
666
|
checkbox: true,
|
|
635
667
|
checked: true,
|
|
636
|
-
onCheckedItemsChange: d(this,
|
|
637
|
-
onSelectedItemsChange: d(this,
|
|
668
|
+
onCheckedItemsChange: d(this, V, "f"),
|
|
669
|
+
onSelectedItemsChange: d(this, A, "f")
|
|
638
670
|
})));
|
|
639
|
-
|
|
671
|
+
lt.set(this, (() => {
|
|
640
672
|
var t;
|
|
641
673
|
const s = ((t = this.designData) === null || t === void 0 ? void 0 : t.success) !== true || this.isLoading;
|
|
642
674
|
return e("footer", {
|
|
@@ -648,7 +680,7 @@ const _t = class {
|
|
|
648
680
|
id: "button-cancel",
|
|
649
681
|
class: "button-secondary button-cancel",
|
|
650
682
|
type: "outlined",
|
|
651
|
-
onClick: d(this,
|
|
683
|
+
onClick: d(this, K, "f"),
|
|
652
684
|
part: "button button--cancel",
|
|
653
685
|
slot: "footer-end"
|
|
654
686
|
}, d(this, u, "f").footer.btnCancel), e("button", {
|
|
@@ -656,13 +688,13 @@ const _t = class {
|
|
|
656
688
|
id: "button-ok",
|
|
657
689
|
class: "button-primary button-ok",
|
|
658
690
|
type: "primary-text-only",
|
|
659
|
-
onClick: !s && d(this,
|
|
691
|
+
onClick: !s && d(this, J, "f"),
|
|
660
692
|
part: "button button--ok",
|
|
661
693
|
disabled: s,
|
|
662
694
|
slot: "footer-end"
|
|
663
695
|
}, d(this, u, "f").footer.btnOk)));
|
|
664
696
|
}));
|
|
665
|
-
|
|
697
|
+
ct.set(this, (() => {
|
|
666
698
|
var t, s;
|
|
667
699
|
if (this.selectedDesignType === "panels") {
|
|
668
700
|
return ((s = (t = this.selectedDesignItem) === null || t === void 0 ? void 0 : t.composition) === null || s === void 0 ? void 0 : s.preview) ? e("div", {
|
|
@@ -674,20 +706,20 @@ const _t = class {
|
|
|
674
706
|
})) : e("gx-ide-empty-state", {
|
|
675
707
|
class: "panel-tab__empty-state",
|
|
676
708
|
stateTitle: d(this, u, "f").messages.noPanelPreviewAvailable,
|
|
677
|
-
stateIconSrc: d(this,
|
|
709
|
+
stateIconSrc: d(this, v, "f").value === yt ? _t : It
|
|
678
710
|
});
|
|
679
711
|
}
|
|
680
712
|
return null;
|
|
681
713
|
}));
|
|
682
|
-
|
|
683
|
-
const t = (this.selectedDesignType ===
|
|
714
|
+
dt.set(this, (() => {
|
|
715
|
+
const t = (this.selectedDesignType === mt || this.selectedDesignType === bt) && this.detailTreeModel.length > 0;
|
|
684
716
|
return e("div", {
|
|
685
717
|
class: {
|
|
686
718
|
"panel-tab": true,
|
|
687
719
|
"panel-tab--controls-tree": t
|
|
688
720
|
},
|
|
689
721
|
part: "data-panel-composition-container"
|
|
690
|
-
}, d(this,
|
|
722
|
+
}, d(this, ct, "f").call(this), t ? e("ch-tree-view-render", {
|
|
691
723
|
part: "data-panel-composition-tree",
|
|
692
724
|
class: "tree-view tree-view-panel-item scrollable",
|
|
693
725
|
showLines: "last",
|
|
@@ -696,7 +728,7 @@ const _t = class {
|
|
|
696
728
|
dropDisabled: true
|
|
697
729
|
}) : null);
|
|
698
730
|
}));
|
|
699
|
-
|
|
731
|
+
pt.set(this, (() => e("div", {
|
|
700
732
|
part: "data-panel-composition-preview",
|
|
701
733
|
class: "data-preview",
|
|
702
734
|
style: {
|
|
@@ -705,15 +737,15 @@ const _t = class {
|
|
|
705
737
|
}, e("img", {
|
|
706
738
|
src: this.selectedDesignItem ? this.selectedDesignItem : undefined,
|
|
707
739
|
alt: "Preview",
|
|
708
|
-
class: this.selectedDesignType ===
|
|
740
|
+
class: this.selectedDesignType === gt ? "checker-board" : undefined
|
|
709
741
|
}))));
|
|
710
|
-
|
|
742
|
+
ft.set(this, (t => {
|
|
711
743
|
this.renderedTabs.clear();
|
|
712
744
|
this.renderedTabs.add(t.detail.newSelectedId);
|
|
713
745
|
this.reRenderCounter++;
|
|
714
746
|
this.activeTabs.set(this.selectedDesignType, t.detail.newSelectedId);
|
|
715
747
|
}));
|
|
716
|
-
|
|
748
|
+
ut.set(this, (() => e("ch-tab-render", {
|
|
717
749
|
// main section
|
|
718
750
|
class: {
|
|
719
751
|
tab: true,
|
|
@@ -725,7 +757,7 @@ const _t = class {
|
|
|
725
757
|
selectedId: this.activeTabs.get(this.selectedDesignType),
|
|
726
758
|
overflow: "auto",
|
|
727
759
|
contain: "size",
|
|
728
|
-
onSelectedItemChange: d(this,
|
|
760
|
+
onSelectedItemChange: d(this, ft, "f")
|
|
729
761
|
}, e("div", {
|
|
730
762
|
slot: r.tokens.slot,
|
|
731
763
|
class: "spacing-body",
|
|
@@ -748,7 +780,7 @@ const _t = class {
|
|
|
748
780
|
style: {
|
|
749
781
|
display: this.renderedTabs.has(r.composition.id) ? "" : "none"
|
|
750
782
|
}
|
|
751
|
-
}, this.selectedDesignType ===
|
|
783
|
+
}, this.selectedDesignType === gt || this.selectedDesignType === wt ? d(this, pt, "f").call(this) : d(this, dt, "f").call(this)), e("div", {
|
|
752
784
|
slot: r.layout.slot,
|
|
753
785
|
class: "spacing-body",
|
|
754
786
|
style: {
|
|
@@ -816,7 +848,7 @@ const _t = class {
|
|
|
816
848
|
}
|
|
817
849
|
pathIsValidChanged(t) {
|
|
818
850
|
if (t) {
|
|
819
|
-
d(this,
|
|
851
|
+
d(this, z, "f").call(this);
|
|
820
852
|
} else {
|
|
821
853
|
// hide access token input if path is not valid
|
|
822
854
|
this.requiresAccessToken = false;
|
|
@@ -825,24 +857,24 @@ const _t = class {
|
|
|
825
857
|
designDataChanged(t) {
|
|
826
858
|
if (t) {
|
|
827
859
|
// panels
|
|
828
|
-
const t = d(this,
|
|
829
|
-
const e = d(this,
|
|
860
|
+
const t = d(this, U, "f").call(this, this.designData.panels);
|
|
861
|
+
const e = d(this, v, "f").value === yt;
|
|
830
862
|
const s = e ? "objects/webpanel" : "objects/panel-for-sd";
|
|
831
863
|
// images
|
|
832
864
|
const i = "objects/image";
|
|
833
865
|
this.designDataTreeDataModel = [ {
|
|
834
866
|
order: 0,
|
|
835
|
-
id: `parent${
|
|
867
|
+
id: `parent${vt}${mt}`,
|
|
836
868
|
leaf: false,
|
|
837
869
|
caption: e ? d(this, u, "f").tree.webPanels : d(this, u, "f").tree.panels,
|
|
838
870
|
startImgSrc: s,
|
|
839
871
|
checkbox: true,
|
|
840
872
|
checked: true,
|
|
841
873
|
expanded: true,
|
|
842
|
-
items: d(this, f, "m",
|
|
874
|
+
items: d(this, f, "m", S).call(this, this.designData.panels, mt, s, t)
|
|
843
875
|
}, {
|
|
844
876
|
order: 1,
|
|
845
|
-
id: `parent${
|
|
877
|
+
id: `parent${vt}${bt}`,
|
|
846
878
|
leaf: false,
|
|
847
879
|
caption: d(this, u, "f").tree.stencils,
|
|
848
880
|
startImgSrc: "objects/stencil",
|
|
@@ -850,7 +882,7 @@ const _t = class {
|
|
|
850
882
|
checked: true,
|
|
851
883
|
expanded: true,
|
|
852
884
|
items: this.designData.stencils.map((t => ({
|
|
853
|
-
id: `${t.id}${
|
|
885
|
+
id: `${t.id}${vt}${bt}`,
|
|
854
886
|
class: "object tree-view-item",
|
|
855
887
|
leaf: !t.warning,
|
|
856
888
|
caption: t.name,
|
|
@@ -858,21 +890,21 @@ const _t = class {
|
|
|
858
890
|
checkbox: true,
|
|
859
891
|
checked: true,
|
|
860
892
|
expanded: true,
|
|
861
|
-
items: t.warning && d(this,
|
|
893
|
+
items: t.warning && d(this, D, "f").call(this, t.warning)
|
|
862
894
|
})))
|
|
863
895
|
}, {
|
|
864
896
|
order: 2,
|
|
865
|
-
id: `parent${
|
|
897
|
+
id: `parent${vt}${gt}`,
|
|
866
898
|
leaf: false,
|
|
867
899
|
caption: d(this, u, "f").tree.images,
|
|
868
900
|
startImgSrc: i,
|
|
869
901
|
checkbox: true,
|
|
870
902
|
checked: true,
|
|
871
903
|
expanded: true,
|
|
872
|
-
items: d(this, f, "m",
|
|
904
|
+
items: d(this, f, "m", S).call(this, this.designData.images, gt, i)
|
|
873
905
|
}, {
|
|
874
906
|
order: 3,
|
|
875
|
-
id: `parent${
|
|
907
|
+
id: `parent${vt}${wt}`,
|
|
876
908
|
leaf: false,
|
|
877
909
|
caption: d(this, u, "f").tree.fonts,
|
|
878
910
|
startImgSrc: "controls/font",
|
|
@@ -880,18 +912,18 @@ const _t = class {
|
|
|
880
912
|
checked: true,
|
|
881
913
|
expanded: true,
|
|
882
914
|
items: this.designData.fonts.map((t => ({
|
|
883
|
-
id: `${t.id}${
|
|
915
|
+
id: `${t.id}${vt}${wt}`,
|
|
884
916
|
leaf: !t.warning,
|
|
885
917
|
caption: t.name,
|
|
886
918
|
startImgSrc: "controls/font",
|
|
887
919
|
checkbox: true,
|
|
888
920
|
checked: true,
|
|
889
921
|
expanded: true,
|
|
890
|
-
items: t.warning && d(this,
|
|
922
|
+
items: t.warning && d(this, D, "f").call(this, t.warning)
|
|
891
923
|
})))
|
|
892
924
|
}, {
|
|
893
925
|
order: 4,
|
|
894
|
-
id: `${this.designData.designSystem.length > 0 ? this.designData.designSystem[0].id : "parent"}${
|
|
926
|
+
id: `${this.designData.designSystem.length > 0 ? this.designData.designSystem[0].id : "parent"}${vt}${kt}`,
|
|
895
927
|
leaf: true,
|
|
896
928
|
caption: d(this, u, "f").tree.designSystem,
|
|
897
929
|
startImgSrc: "objects/dso",
|
|
@@ -903,7 +935,7 @@ const _t = class {
|
|
|
903
935
|
pathChanged(t) {
|
|
904
936
|
var e;
|
|
905
937
|
const s = ((e = this.selectedFile) === null || e === void 0 ? void 0 : e.size) > 0;
|
|
906
|
-
const i = d(this,
|
|
938
|
+
const i = d(this, F, "f").call(this, t) || s;
|
|
907
939
|
this.pathIsValid = i;
|
|
908
940
|
}
|
|
909
941
|
accessTokenChanged(t) {
|
|
@@ -922,14 +954,14 @@ const _t = class {
|
|
|
922
954
|
p(this, u, await n.getComponentStrings(this.el), "f");
|
|
923
955
|
p(this, g, this.extensions.map((t => `.${t}`)).join(", "), "f");
|
|
924
956
|
this.stylesChanged(this.styles);
|
|
925
|
-
d(this,
|
|
957
|
+
d(this, T, "f").call(this);
|
|
926
958
|
this.pathChanged(this.path);
|
|
927
959
|
this.styleValue = ((t = this.stylesAsComboBoxModel) === null || t === void 0 ? void 0 : t.length) > 0 ? (e = this.stylesAsComboBoxModel[0]) === null || e === void 0 ? void 0 : e.value : "";
|
|
928
960
|
}
|
|
929
961
|
watchMessagesHandler(t, e) {
|
|
930
962
|
if (t !== e) {
|
|
931
|
-
if (d(this,
|
|
932
|
-
d(this,
|
|
963
|
+
if (d(this, x, "f")) {
|
|
964
|
+
d(this, x, "f").scrollTop = d(this, x, "f").scrollHeight;
|
|
933
965
|
}
|
|
934
966
|
}
|
|
935
967
|
}
|
|
@@ -937,10 +969,10 @@ const _t = class {
|
|
|
937
969
|
return e(s, {
|
|
938
970
|
class: "widget"
|
|
939
971
|
}, e("ch-theme", {
|
|
940
|
-
model:
|
|
972
|
+
model: Ct
|
|
941
973
|
}), e("section", {
|
|
942
974
|
class: "section"
|
|
943
|
-
}, d(this,
|
|
975
|
+
}, d(this, at, "f").call(this), d(this, rt, "f").call(this), d(this, lt, "f").call(this)));
|
|
944
976
|
}
|
|
945
977
|
static get assetsDirs() {
|
|
946
978
|
return [ "gx-ide-assets/design-import" ];
|
|
@@ -963,33 +995,34 @@ const _t = class {
|
|
|
963
995
|
u = new WeakMap, m = new WeakMap, b = new WeakMap, g = new WeakMap, k = new WeakMap,
|
|
964
996
|
w = new WeakMap, v = new WeakMap, y = new WeakMap, x = new WeakMap, M = new WeakMap,
|
|
965
997
|
W = new WeakMap, _ = new WeakMap, I = new WeakMap, C = new WeakMap, $ = new WeakMap,
|
|
966
|
-
|
|
998
|
+
j = new WeakMap, D = new WeakMap, T = new WeakMap, z = new WeakMap, P = new WeakMap,
|
|
967
999
|
A = new WeakMap, E = new WeakMap, F = new WeakMap, V = new WeakMap, G = new WeakMap,
|
|
968
|
-
L = new WeakMap, O = new WeakMap, B = new WeakMap,
|
|
969
|
-
|
|
1000
|
+
L = new WeakMap, O = new WeakMap, B = new WeakMap, H = new WeakMap, R = new WeakMap,
|
|
1001
|
+
Y = new WeakMap, J = new WeakMap, K = new WeakMap, Q = new WeakMap, U = new WeakMap,
|
|
970
1002
|
X = new WeakMap, Z = new WeakMap, tt = new WeakMap, et = new WeakMap, st = new WeakMap,
|
|
971
|
-
|
|
972
|
-
|
|
1003
|
+
it = new WeakMap, at = new WeakMap, ot = new WeakMap, rt = new WeakMap, ht = new WeakMap,
|
|
1004
|
+
lt = new WeakMap, ct = new WeakMap, dt = new WeakMap, pt = new WeakMap, ft = new WeakMap,
|
|
1005
|
+
ut = new WeakMap, f = new WeakSet, S = function _GxIdeImportFromDesign_recursiveDesignTreeItems(t, e, s, i = undefined) {
|
|
973
1006
|
return t.map(((t, a) => {
|
|
974
1007
|
var o;
|
|
975
|
-
const n = `${t.id}${
|
|
1008
|
+
const n = `${t.id}${vt}${e}`;
|
|
976
1009
|
const r = ((o = t.variants) === null || o === void 0 ? void 0 : o.length) > 0;
|
|
977
|
-
const
|
|
978
|
-
const
|
|
1010
|
+
const h = t.warning ? d(this, D, "f").call(this, t.warning) : [];
|
|
1011
|
+
const l = !r && !t.warning;
|
|
979
1012
|
return {
|
|
980
1013
|
id: n,
|
|
981
|
-
leaf:
|
|
1014
|
+
leaf: l,
|
|
982
1015
|
caption: t.name,
|
|
983
1016
|
startImgSrc: s,
|
|
984
1017
|
checkbox: true,
|
|
985
1018
|
checked: true,
|
|
986
|
-
expanded: !
|
|
1019
|
+
expanded: !l,
|
|
987
1020
|
selected: i === a,
|
|
988
1021
|
order: a,
|
|
989
|
-
items: [ ...
|
|
1022
|
+
items: [ ...h, ...r ? d(this, f, "m", _GxIdeImportFromDesign_recursiveDesignTreeItems).call(this, t.variants, e, s) : [] ]
|
|
990
1023
|
};
|
|
991
1024
|
}));
|
|
992
|
-
},
|
|
1025
|
+
}, q = function _GxIdeImportFromDesign_loadTreeItemCompositionModel(t) {
|
|
993
1026
|
const e = [];
|
|
994
1027
|
for (const s of t) {
|
|
995
1028
|
let t = {
|
|
@@ -1008,29 +1041,29 @@ ht = new WeakMap, ct = new WeakMap, dt = new WeakMap, f = new WeakSet, j = funct
|
|
|
1008
1041
|
e.push(t);
|
|
1009
1042
|
}
|
|
1010
1043
|
return e;
|
|
1011
|
-
},
|
|
1044
|
+
}, N = function _GxIdeImportFromDesign_getCodeFactory(t) {
|
|
1012
1045
|
switch (t) {
|
|
1013
|
-
case
|
|
1014
|
-
case
|
|
1046
|
+
case mt:
|
|
1047
|
+
case bt:
|
|
1015
1048
|
this.textEditorFactoryCallback("code", r.code.slot, this.selectedDesignItem.code);
|
|
1016
1049
|
this.textEditorFactoryCallback("html", r.layout.slot, this.selectedDesignItem.layout);
|
|
1017
1050
|
break;
|
|
1018
1051
|
|
|
1019
|
-
case
|
|
1052
|
+
case kt:
|
|
1020
1053
|
this.textEditorFactoryCallback("tokens", r.tokens.slot, this.selectedDesignItem.tokens);
|
|
1021
1054
|
this.textEditorFactoryCallback("styles", r.styles.slot, this.selectedDesignItem.styles);
|
|
1022
1055
|
break;
|
|
1023
1056
|
}
|
|
1024
|
-
},
|
|
1057
|
+
}, nt = function _GxIdeImportFromDesign_renderDetailDataTree(t) {
|
|
1025
1058
|
switch (t) {
|
|
1026
|
-
case
|
|
1027
|
-
case
|
|
1028
|
-
this.detailTreeModel = d(this, f, "m",
|
|
1059
|
+
case mt:
|
|
1060
|
+
case bt:
|
|
1061
|
+
this.detailTreeModel = d(this, f, "m", q).call(this, this.selectedDesignItem.composition.controls);
|
|
1029
1062
|
break;
|
|
1030
1063
|
}
|
|
1031
1064
|
};
|
|
1032
1065
|
|
|
1033
|
-
|
|
1066
|
+
$t.style = c;
|
|
1034
1067
|
|
|
1035
|
-
export {
|
|
1036
|
-
//# sourceMappingURL=p-
|
|
1068
|
+
export { $t as gx_ide_design_import };
|
|
1069
|
+
//# sourceMappingURL=p-2b4b1dfc.entry.js.map
|