@fluid-topics/ft-modal 1.3.46 → 1.3.48
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/build/ft-modal.d.ts +1 -0
- package/build/ft-modal.js +9 -2
- package/build/ft-modal.light.js +157 -96
- package/build/ft-modal.min.js +148 -87
- package/build/ft-modal.styles.js +61 -1
- package/package.json +4 -4
package/build/ft-modal.d.ts
CHANGED
package/build/ft-modal.js
CHANGED
|
@@ -33,6 +33,7 @@ class FtModal extends withI18n(FtdsBase) {
|
|
|
33
33
|
super();
|
|
34
34
|
this.buttonLabel = "";
|
|
35
35
|
this.heading = "";
|
|
36
|
+
this.drawer = false;
|
|
36
37
|
this.size = DesignSystemSize.small;
|
|
37
38
|
this.intersectionObserver = new IntersectionObserver(() => {
|
|
38
39
|
if (this.dialog && !this.dialog.checkVisibility()) {
|
|
@@ -45,6 +46,9 @@ class FtModal extends withI18n(FtdsBase) {
|
|
|
45
46
|
const classes = {
|
|
46
47
|
"ft-modal": true,
|
|
47
48
|
};
|
|
49
|
+
const drawerClasses = {
|
|
50
|
+
"drawer": this.drawer,
|
|
51
|
+
};
|
|
48
52
|
return html `
|
|
49
53
|
<div class="${classMap(classes)}" part="container">
|
|
50
54
|
<slot @click=${this.onTriggerClick} name="trigger">
|
|
@@ -54,9 +58,9 @@ class FtModal extends withI18n(FtdsBase) {
|
|
|
54
58
|
</slot>
|
|
55
59
|
<dialog part="dialog" aria-labelledby="heading" @close=${this.onClose}>
|
|
56
60
|
<div part="overlay" @click=${this.onOverlayClick}></div>
|
|
57
|
-
<div part="inner-container">
|
|
61
|
+
<div part="inner-container" class="${classMap(drawerClasses)}">
|
|
58
62
|
<div part="header">
|
|
59
|
-
${when(!!this.icon, () => html `
|
|
63
|
+
${when(!!this.icon && !this.drawer, () => html `
|
|
60
64
|
<ft-icon part="icon" value="${this.icon}"></ft-icon>
|
|
61
65
|
`)}
|
|
62
66
|
<ft-typography id="heading" part="heading" role="heading" variant="${FtTypographyVariants.title}">
|
|
@@ -131,6 +135,9 @@ __decorate([
|
|
|
131
135
|
__decorate([
|
|
132
136
|
property()
|
|
133
137
|
], FtModal.prototype, "icon", void 0);
|
|
138
|
+
__decorate([
|
|
139
|
+
property()
|
|
140
|
+
], FtModal.prototype, "drawer", void 0);
|
|
134
141
|
__decorate([
|
|
135
142
|
query("dialog")
|
|
136
143
|
], FtModal.prototype, "dialog", void 0);
|