@bluevolt-tech/lumen 1.4.1 → 1.5.0
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/components/bv-button/bv-button.js +1 -1
- package/dist/components/bv-course-detail-modal/bv-course-detail-modal.js +1 -1
- package/dist/components/bv-course-grid-card/bv-course-grid-card.d.ts +4 -0
- package/dist/components/bv-course-grid-card/bv-course-grid-card.js +29 -1
- package/dist/components/bv-course-list-card/bv-course-list-card.d.ts +4 -0
- package/dist/components/bv-course-list-card/bv-course-list-card.js +29 -1
- package/dist/components/bv-empty-state/bv-empty-state.js +1 -1
- package/dist/components/bv-portal-header/bv-portal-header.js +1 -1
- package/dist/components/bv-user-row/bv-user-row.js +1 -1
- package/dist/themes/base.css +1 -1
- package/package.json +1 -1
- package/themes/base.css +1 -1
|
@@ -183,7 +183,7 @@ var BvButton = class extends HTMLElement {
|
|
|
183
183
|
}
|
|
184
184
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
185
185
|
const iconName = this.getAttribute("icon");
|
|
186
|
-
if (iconName) {
|
|
186
|
+
if (iconName && !this.loading) {
|
|
187
187
|
const svg = getIconSvg(iconName, 16);
|
|
188
188
|
if (svg) {
|
|
189
189
|
const iconEl = document.createElement("span");
|
|
@@ -1041,7 +1041,7 @@ var BvButton = class extends HTMLElement {
|
|
|
1041
1041
|
}
|
|
1042
1042
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
1043
1043
|
const iconName = this.getAttribute("icon");
|
|
1044
|
-
if (iconName) {
|
|
1044
|
+
if (iconName && !this.loading) {
|
|
1045
1045
|
const svg = getIconSvg(iconName, 16);
|
|
1046
1046
|
if (svg) {
|
|
1047
1047
|
const iconEl = document.createElement("span");
|
|
@@ -7,6 +7,10 @@ export declare class BvCourseGridCard extends HTMLElement {
|
|
|
7
7
|
set disableSelection(v: boolean);
|
|
8
8
|
get hideSecondary(): boolean;
|
|
9
9
|
set hideSecondary(v: boolean);
|
|
10
|
+
get primaryLoading(): boolean;
|
|
11
|
+
set primaryLoading(v: boolean);
|
|
12
|
+
get primaryDisabled(): boolean;
|
|
13
|
+
set primaryDisabled(v: boolean);
|
|
10
14
|
get loading(): boolean;
|
|
11
15
|
set loading(v: boolean);
|
|
12
16
|
private _rendered;
|
|
@@ -186,7 +186,7 @@ var BvButton = class extends HTMLElement {
|
|
|
186
186
|
}
|
|
187
187
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
188
188
|
const iconName = this.getAttribute("icon");
|
|
189
|
-
if (iconName) {
|
|
189
|
+
if (iconName && !this.loading) {
|
|
190
190
|
const svg = getIconSvg(iconName, 16);
|
|
191
191
|
if (svg) {
|
|
192
192
|
const iconEl = document.createElement("span");
|
|
@@ -227,6 +227,8 @@ var BvCourseGridCard = class extends HTMLElement {
|
|
|
227
227
|
"primary-label",
|
|
228
228
|
"primary-variant",
|
|
229
229
|
"primary-icon",
|
|
230
|
+
"primary-loading",
|
|
231
|
+
"primary-disabled",
|
|
230
232
|
"secondary-label",
|
|
231
233
|
"secondary-icon",
|
|
232
234
|
"selected",
|
|
@@ -255,6 +257,20 @@ var BvCourseGridCard = class extends HTMLElement {
|
|
|
255
257
|
if (v) this.setAttribute("hide-secondary", "");
|
|
256
258
|
else this.removeAttribute("hide-secondary");
|
|
257
259
|
}
|
|
260
|
+
get primaryLoading() {
|
|
261
|
+
return this.hasAttribute("primary-loading");
|
|
262
|
+
}
|
|
263
|
+
set primaryLoading(v) {
|
|
264
|
+
if (v) this.setAttribute("primary-loading", "");
|
|
265
|
+
else this.removeAttribute("primary-loading");
|
|
266
|
+
}
|
|
267
|
+
get primaryDisabled() {
|
|
268
|
+
return this.hasAttribute("primary-disabled");
|
|
269
|
+
}
|
|
270
|
+
set primaryDisabled(v) {
|
|
271
|
+
if (v) this.setAttribute("primary-disabled", "");
|
|
272
|
+
else this.removeAttribute("primary-disabled");
|
|
273
|
+
}
|
|
258
274
|
get loading() {
|
|
259
275
|
return this.hasAttribute("loading");
|
|
260
276
|
}
|
|
@@ -317,6 +333,16 @@ var BvCourseGridCard = class extends HTMLElement {
|
|
|
317
333
|
var _a2;
|
|
318
334
|
(_a2 = this._els.primaryBtn) == null ? void 0 : _a2.setAttribute("icon", val ?? "");
|
|
319
335
|
},
|
|
336
|
+
"primary-loading": () => {
|
|
337
|
+
var _a2, _b;
|
|
338
|
+
if (val === null) (_a2 = this._els.primaryBtn) == null ? void 0 : _a2.removeAttribute("loading");
|
|
339
|
+
else (_b = this._els.primaryBtn) == null ? void 0 : _b.setAttribute("loading", "");
|
|
340
|
+
},
|
|
341
|
+
"primary-disabled": () => {
|
|
342
|
+
var _a2, _b;
|
|
343
|
+
if (val === null) (_a2 = this._els.primaryBtn) == null ? void 0 : _a2.removeAttribute("disabled");
|
|
344
|
+
else (_b = this._els.primaryBtn) == null ? void 0 : _b.setAttribute("disabled", "");
|
|
345
|
+
},
|
|
320
346
|
"secondary-label": () => {
|
|
321
347
|
this._syncSecondaryLabel();
|
|
322
348
|
},
|
|
@@ -394,6 +420,8 @@ var BvCourseGridCard = class extends HTMLElement {
|
|
|
394
420
|
primaryBtn.setAttribute("full-width", "");
|
|
395
421
|
primaryBtn.className = "primary-action";
|
|
396
422
|
primaryBtn.textContent = this.getAttribute("primary-label") ?? "Enroll Now";
|
|
423
|
+
if (this.primaryLoading) primaryBtn.setAttribute("loading", "");
|
|
424
|
+
if (this.primaryDisabled) primaryBtn.setAttribute("disabled", "");
|
|
397
425
|
primaryBtn.addEventListener("click", () => {
|
|
398
426
|
this.dispatchEvent(new CustomEvent("bv-primary-action", { bubbles: true, composed: true }));
|
|
399
427
|
});
|
|
@@ -7,6 +7,10 @@ export declare class BvCourseListCard extends HTMLElement {
|
|
|
7
7
|
set disableSelection(v: boolean);
|
|
8
8
|
get hideSecondary(): boolean;
|
|
9
9
|
set hideSecondary(v: boolean);
|
|
10
|
+
get primaryLoading(): boolean;
|
|
11
|
+
set primaryLoading(v: boolean);
|
|
12
|
+
get primaryDisabled(): boolean;
|
|
13
|
+
set primaryDisabled(v: boolean);
|
|
10
14
|
get loading(): boolean;
|
|
11
15
|
set loading(v: boolean);
|
|
12
16
|
private _rendered;
|
|
@@ -186,7 +186,7 @@ var BvButton = class extends HTMLElement {
|
|
|
186
186
|
}
|
|
187
187
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
188
188
|
const iconName = this.getAttribute("icon");
|
|
189
|
-
if (iconName) {
|
|
189
|
+
if (iconName && !this.loading) {
|
|
190
190
|
const svg = getIconSvg(iconName, 16);
|
|
191
191
|
if (svg) {
|
|
192
192
|
const iconEl = document.createElement("span");
|
|
@@ -227,6 +227,8 @@ var BvCourseListCard = class extends HTMLElement {
|
|
|
227
227
|
"primary-label",
|
|
228
228
|
"primary-variant",
|
|
229
229
|
"primary-icon",
|
|
230
|
+
"primary-loading",
|
|
231
|
+
"primary-disabled",
|
|
230
232
|
"secondary-label",
|
|
231
233
|
"secondary-icon",
|
|
232
234
|
"selected",
|
|
@@ -255,6 +257,20 @@ var BvCourseListCard = class extends HTMLElement {
|
|
|
255
257
|
if (v) this.setAttribute("hide-secondary", "");
|
|
256
258
|
else this.removeAttribute("hide-secondary");
|
|
257
259
|
}
|
|
260
|
+
get primaryLoading() {
|
|
261
|
+
return this.hasAttribute("primary-loading");
|
|
262
|
+
}
|
|
263
|
+
set primaryLoading(v) {
|
|
264
|
+
if (v) this.setAttribute("primary-loading", "");
|
|
265
|
+
else this.removeAttribute("primary-loading");
|
|
266
|
+
}
|
|
267
|
+
get primaryDisabled() {
|
|
268
|
+
return this.hasAttribute("primary-disabled");
|
|
269
|
+
}
|
|
270
|
+
set primaryDisabled(v) {
|
|
271
|
+
if (v) this.setAttribute("primary-disabled", "");
|
|
272
|
+
else this.removeAttribute("primary-disabled");
|
|
273
|
+
}
|
|
258
274
|
get loading() {
|
|
259
275
|
return this.hasAttribute("loading");
|
|
260
276
|
}
|
|
@@ -317,6 +333,16 @@ var BvCourseListCard = class extends HTMLElement {
|
|
|
317
333
|
var _a2;
|
|
318
334
|
(_a2 = this._els.primaryBtn) == null ? void 0 : _a2.setAttribute("icon", val ?? "");
|
|
319
335
|
},
|
|
336
|
+
"primary-loading": () => {
|
|
337
|
+
var _a2, _b;
|
|
338
|
+
if (val === null) (_a2 = this._els.primaryBtn) == null ? void 0 : _a2.removeAttribute("loading");
|
|
339
|
+
else (_b = this._els.primaryBtn) == null ? void 0 : _b.setAttribute("loading", "");
|
|
340
|
+
},
|
|
341
|
+
"primary-disabled": () => {
|
|
342
|
+
var _a2, _b;
|
|
343
|
+
if (val === null) (_a2 = this._els.primaryBtn) == null ? void 0 : _a2.removeAttribute("disabled");
|
|
344
|
+
else (_b = this._els.primaryBtn) == null ? void 0 : _b.setAttribute("disabled", "");
|
|
345
|
+
},
|
|
320
346
|
"secondary-label": () => {
|
|
321
347
|
if (this._els.secondaryBtn) this._els.secondaryBtn.textContent = val ?? "";
|
|
322
348
|
},
|
|
@@ -398,6 +424,8 @@ var BvCourseListCard = class extends HTMLElement {
|
|
|
398
424
|
primaryBtn.setAttribute("icon", this.getAttribute("primary-icon") ?? "");
|
|
399
425
|
primaryBtn.setAttribute("full-width", "");
|
|
400
426
|
primaryBtn.textContent = this.getAttribute("primary-label") ?? "Enroll Now";
|
|
427
|
+
if (this.primaryLoading) primaryBtn.setAttribute("loading", "");
|
|
428
|
+
if (this.primaryDisabled) primaryBtn.setAttribute("disabled", "");
|
|
401
429
|
primaryBtn.addEventListener("click", () => {
|
|
402
430
|
this.dispatchEvent(new CustomEvent("bv-primary-action", { bubbles: true, composed: true }));
|
|
403
431
|
});
|
|
@@ -269,7 +269,7 @@ var BvButton = class extends HTMLElement {
|
|
|
269
269
|
}
|
|
270
270
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
271
271
|
const iconName = this.getAttribute("icon");
|
|
272
|
-
if (iconName) {
|
|
272
|
+
if (iconName && !this.loading) {
|
|
273
273
|
const svg = getIconSvg(iconName, 16);
|
|
274
274
|
if (svg) {
|
|
275
275
|
const iconEl = document.createElement("span");
|
|
@@ -268,7 +268,7 @@ var BvButton = class extends HTMLElement {
|
|
|
268
268
|
}
|
|
269
269
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
270
270
|
const iconName = this.getAttribute("icon");
|
|
271
|
-
if (iconName) {
|
|
271
|
+
if (iconName && !this.loading) {
|
|
272
272
|
const svg = getIconSvg(iconName, 16);
|
|
273
273
|
if (svg) {
|
|
274
274
|
const iconEl = document.createElement("span");
|
|
@@ -265,7 +265,7 @@ var BvButton = class extends HTMLElement {
|
|
|
265
265
|
}
|
|
266
266
|
btn.querySelectorAll(".btn-icon").forEach((el) => el.remove());
|
|
267
267
|
const iconName = this.getAttribute("icon");
|
|
268
|
-
if (iconName) {
|
|
268
|
+
if (iconName && !this.loading) {
|
|
269
269
|
const svg = getIconSvg(iconName, 16);
|
|
270
270
|
if (svg) {
|
|
271
271
|
const iconEl = document.createElement("span");
|
package/dist/themes/base.css
CHANGED
package/package.json
CHANGED