@getflip/swirl-components 0.119.0 → 0.120.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/components.json +17 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/cjs/swirl-components.cjs.js +1 -1
- package/dist/cjs/swirl-image-grid.cjs.entry.js +2 -1
- package/dist/cjs/swirl-popover_2.cjs.entry.js +2 -2
- package/dist/collection/assets/pdfjs/pdf.worker.min.js +1 -1
- package/dist/collection/components/swirl-image-grid/swirl-image-grid.js +19 -1
- package/dist/collection/components/swirl-popover/swirl-popover.js +2 -2
- package/dist/components/assets/pdfjs/pdf.worker.min.js +1 -1
- package/dist/components/swirl-image-grid.js +3 -1
- package/dist/components/swirl-popover2.js +2 -2
- package/dist/esm/loader.js +1 -1
- package/dist/esm/swirl-components.js +1 -1
- package/dist/esm/swirl-image-grid.entry.js +2 -1
- package/dist/esm/swirl-popover_2.entry.js +2 -2
- package/dist/swirl-components/p-1a68d9db.entry.js +1 -0
- package/dist/swirl-components/p-83fcdae0.entry.js +1 -0
- package/dist/swirl-components/swirl-components.esm.js +1 -1
- package/dist/types/components/swirl-image-grid/swirl-image-grid.d.ts +1 -0
- package/dist/types/components.d.ts +2 -0
- package/package.json +1 -1
- package/vscode-data.json +4 -0
- package/dist/swirl-components/p-4345e137.entry.js +0 -1
- package/dist/swirl-components/p-944f33d4.entry.js +0 -1
|
@@ -9,6 +9,7 @@ export class SwirlImageGrid {
|
|
|
9
9
|
}
|
|
10
10
|
};
|
|
11
11
|
this.aspectRatio = "1/1";
|
|
12
|
+
this.label = undefined;
|
|
12
13
|
this.items = [];
|
|
13
14
|
}
|
|
14
15
|
componentWillLoad() {
|
|
@@ -16,7 +17,7 @@ export class SwirlImageGrid {
|
|
|
16
17
|
}
|
|
17
18
|
render() {
|
|
18
19
|
const className = classnames("image-grid", `image-grid--item-count-${Math.min(4, this.items.length)}`);
|
|
19
|
-
return (h(Host, null, h("div", { class: className, role: "list", style: { aspectRatio: this.aspectRatio } }, h("slot", { onSlotchange: this.updateItems }))));
|
|
20
|
+
return (h(Host, null, h("div", { "aria-label": this.label, class: className, role: "list", style: { aspectRatio: this.aspectRatio } }, h("slot", { onSlotchange: this.updateItems }))));
|
|
20
21
|
}
|
|
21
22
|
static get is() { return "swirl-image-grid"; }
|
|
22
23
|
static get encapsulation() { return "shadow"; }
|
|
@@ -49,6 +50,23 @@ export class SwirlImageGrid {
|
|
|
49
50
|
"attribute": "aspect-ratio",
|
|
50
51
|
"reflect": false,
|
|
51
52
|
"defaultValue": "\"1/1\""
|
|
53
|
+
},
|
|
54
|
+
"label": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"mutable": false,
|
|
57
|
+
"complexType": {
|
|
58
|
+
"original": "string",
|
|
59
|
+
"resolved": "string",
|
|
60
|
+
"references": {}
|
|
61
|
+
},
|
|
62
|
+
"required": false,
|
|
63
|
+
"optional": true,
|
|
64
|
+
"docs": {
|
|
65
|
+
"tags": [],
|
|
66
|
+
"text": ""
|
|
67
|
+
},
|
|
68
|
+
"attribute": "label",
|
|
69
|
+
"reflect": false
|
|
52
70
|
}
|
|
53
71
|
};
|
|
54
72
|
}
|
|
@@ -225,14 +225,14 @@ export class SwirlPopover {
|
|
|
225
225
|
}
|
|
226
226
|
lockBodyScroll() {
|
|
227
227
|
const mobile = isMobileViewport();
|
|
228
|
-
if (!mobile || this.disableScrollLock) {
|
|
228
|
+
if (!mobile || this.disableScrollLock || !Boolean(this.scrollContainer)) {
|
|
229
229
|
return;
|
|
230
230
|
}
|
|
231
231
|
disableBodyScroll(this.scrollContainer);
|
|
232
232
|
}
|
|
233
233
|
unlockBodyScroll() {
|
|
234
234
|
const mobile = isMobileViewport();
|
|
235
|
-
if (!mobile || this.disableScrollLock) {
|
|
235
|
+
if (!mobile || this.disableScrollLock || !Boolean(this.scrollContainer)) {
|
|
236
236
|
return;
|
|
237
237
|
}
|
|
238
238
|
enableBodyScroll(this.scrollContainer);
|