@getflip/swirl-components 0.213.0 → 0.213.1

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 CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "timestamp": "2024-07-12T08:47:06",
2
+ "timestamp": "2024-07-12T09:32:31",
3
3
  "compiler": {
4
4
  "name": "@stencil/core",
5
5
  "version": "4.18.1",
@@ -151,7 +151,7 @@ const SwirlLightbox = class {
151
151
  },
152
152
  },
153
153
  });
154
- this.focusTrap.activate();
154
+ this.focusTrap?.activate();
155
155
  });
156
156
  }
157
157
  /**
@@ -264,7 +264,7 @@ const SwirlLightbox = class {
264
264
  "lightbox--hide-menu": !hasMenuItems,
265
265
  "lightbox--hide-toolbar": !hasToolbar,
266
266
  });
267
- return (index.h(index.Host, { key: '012891b0db835105a7580bad43bccce2b389769d', onKeydown: this.onKeyDown }, index.h("section", { key: 'b293082c033d560d15dc78118f95b4bca5bca954', "aria-hidden": String(!this.isOpen), "aria-label": this.label, "aria-modal": "true", class: className, id: "lightbox", onMouseDown: this.onPointerDown, onMouseMove: this.onPointerMove, onMouseOut: this.onPointerUp, onMouseUp: this.onPointerUp, onTouchEnd: this.onPointerUp, onTouchMove: this.onPointerMove, onTouchStart: this.onPointerDown, ref: (el) => (this.modalEl = el), role: "dialog", tabIndex: this.isOpen ? 0 : -1 }, index.h("div", { key: '5fe1877d3e6c56db2277b1d4de02f5471a81435e', class: "lightbox__body", role: "document" }, index.h("header", { key: '53ee69774f4525b937758d1614991a8e508a41b2', class: "lightbox__header" }, index.h("button", { key: '6bc6027025c29da201e60326f60b0287a5ed25f6', "aria-label": this.closeButtonLabel, class: "lightbox__close-button", onClick: this.onCloseButtonClick }, index.h("swirl-icon-close", { key: '1e1c5a418da66c5aab172142c660365631c80db8' })), index.h("div", { key: 'b4a31f60db6fe4bc738527a25f1dcfc239619748', class: "lightbox__toolbar" }, index.h("slot", { key: '3d7d99d8f63701dbc8c7f091d388eacbf30288da', name: "toolbar" })), !this.hideMenu && (index.h("swirl-popover-trigger", { key: 'd7a17fcf78810181ae21e979f652152f8842afae', swirlPopover: this.menu }, index.h("button", { key: '9836e1a84fda8ab4419486051a402eb928ea8914', "aria-label": this.menuTriggerLabel, class: "lightbox__menu-button" }, index.h("swirl-icon-more-vertikal", { key: 'ddf16aee28f502ec5eb960833533f1bec6e667e3' }))))), index.h("div", { key: 'b7448e6187d1b97439fcbbd70c03f2a01ebeca18', "aria-roledescription": "carousel", class: "lightbox__content", role: "group" }, index.h("div", { key: 'c65b7f37ef28a0cf7f2744cb0f5d64b8872a1990', "aria-atomic": "false", "aria-live": "polite", class: "lightbox__slides", onClick: this.onBackdropClick, onContextMenu: this.onContextMenu, ref: (el) => (this.slidesContainer = el) }, index.h("slot", { key: 'df683e35aa1750cb69424d4b83ce70d3946faf84', onSlotchange: this.registerSlides }))), index.h("div", { key: '9ff646ddac7774be9ed4f668470f54cf0d0113cc', class: "lightbox__controls" }, index.h("button", { key: 'b07e6b6c8708394d826791f216f7bc7b0f307839', "aria-label": this.previousSlideButtonLabel, class: "lightbox__previous-slide-button", disabled: this.activeSlideIndex === 0, onClick: this.onPreviousSlideClick }, index.h("swirl-icon-arrow-left", { key: 'af25abff2e4ca1cf6d5b16b43a77ea028b90e571' })), index.h("button", { key: '3a22bfdfa042251d74ecdbc4d87516ea300c5ced', "aria-label": this.nextSlideButtonLabel, class: "lightbox__next-slide-button", disabled: this.activeSlideIndex === this.slides.length - 1, onClick: this.onNextSlideClick }, index.h("swirl-icon-arrow-right", { key: '248a0b730aacf7381b20134253c41984a9b91a24' }))), showPagination && (index.h("span", { key: '1807b6f0d21fb2410772a682373678458329ac38', class: "lightbox__pagination" }, index.h("span", { key: '23376bbf8611300e5d4d158975d23796191b02ea', "aria-current": "page" }, this.activeSlideIndex + 1), " /", " ", this.slides.length))), !this.hideMenu && (index.h("swirl-popover", { key: '519bf63ab4ee728ba357637db647e8e7abeb9fbf', animation: "scale-in-y", disableScrollLock: true, id: "slide-menu", label: this.menuLabel, placement: "bottom-end", ref: (el) => (this.menu = el) }, index.h("swirl-stack", { key: '023c442075b900f00d50523213dfc466f813de23' }, index.h("div", { key: '0dc758f7b9eb51c23e95c6338dfe31327e190be0', class: "lightbox__meta" }, currentThumbnailUrl && (index.h("div", { key: 'e703f937124d3698d3404d0da19adbaceba4cf58', class: "lightbox__thumbnail" }, index.h("swirl-thumbnail", { key: 'f97ae890ec3497533f7272eb0b973e3e04a79b3a', alt: "", src: currentThumbnailUrl }))), index.h("div", { key: '4a53904b0f1b9760b5fe796e9fa7ad141c87fae0', class: "lightbox__file-info" }, index.h("swirl-text", { key: 'f98d773d89087ac30d6b74db1d65fb86ce8e880e', truncate: true, weight: "semibold" }, currentFileName), index.h("swirl-text", { key: '8df08e6b94f940fb13029bd31b19a9af7b22eea8', color: "subdued", size: "sm", truncate: true }, currentFileType))), hasMenuItems && index.h("swirl-separator", { key: '44dd5efecd57e94cab79ef012929f208c46b1158' }), index.h("swirl-action-list", { key: '77fd5492f4e037cb8ea2a2d840967b520baed782' }, this.downloadButtonEnabled && (index.h("swirl-action-list-item", { key: '1c7650890e90b283eed2746eaa22e2e72d951418', icon: "<swirl-icon-download></swirl-icon-download>", label: this.downloadButtonLabel, onClick: this.onDownloadButtonClick })), index.h("slot", { key: '7955b578c31f23970abe13f46b25b53d5ae5cf50', name: "menu-items" }))))))));
267
+ return (index.h(index.Host, { key: '8cec4d231dec35e90b6d3b3c54bbf1b1e4fcd364', onKeydown: this.onKeyDown }, index.h("section", { key: '212e15751c9842b7a81f87c4d3c8f4ad601c52e6', "aria-hidden": String(!this.isOpen), "aria-label": this.label, "aria-modal": "true", class: className, id: "lightbox", onMouseDown: this.onPointerDown, onMouseMove: this.onPointerMove, onMouseOut: this.onPointerUp, onMouseUp: this.onPointerUp, onTouchEnd: this.onPointerUp, onTouchMove: this.onPointerMove, onTouchStart: this.onPointerDown, ref: (el) => (this.modalEl = el), role: "dialog", tabIndex: this.isOpen ? 0 : -1 }, index.h("div", { key: '134ec9aaa142401f165781af108715260f5fe32b', class: "lightbox__body", role: "document" }, index.h("header", { key: '6bc11ff79e3a17adfffc99fdab5e3750847388b4', class: "lightbox__header" }, index.h("button", { key: '52d3a58620374ed27ddcabbef709641139a35fa7', "aria-label": this.closeButtonLabel, class: "lightbox__close-button", onClick: this.onCloseButtonClick }, index.h("swirl-icon-close", { key: 'a6a57ac17788fb71a29722b0834a85544943abf9' })), index.h("div", { key: '1e02044a040920ccda9178be647e44e4dc5d158e', class: "lightbox__toolbar" }, index.h("slot", { key: 'e412a8198a090255c6f6f3be26f000f9a71cda2a', name: "toolbar" })), !this.hideMenu && (index.h("swirl-popover-trigger", { key: '0eedb89f9e659030ef6f9ba7114fc8954d164c5f', swirlPopover: this.menu }, index.h("button", { key: '633a48d1a460ec83cfcea48a552b9cae3fc636d9', "aria-label": this.menuTriggerLabel, class: "lightbox__menu-button" }, index.h("swirl-icon-more-vertikal", { key: '52f05b468eb36ed77c192fef0047cd41118e1e39' }))))), index.h("div", { key: 'c2b313e5b2fa3184007bb8e3d71037216f82bc25', "aria-roledescription": "carousel", class: "lightbox__content", role: "group" }, index.h("div", { key: '9f67aa3142ead468f41a99eb6d974f6676d135c4', "aria-atomic": "false", "aria-live": "polite", class: "lightbox__slides", onClick: this.onBackdropClick, onContextMenu: this.onContextMenu, ref: (el) => (this.slidesContainer = el) }, index.h("slot", { key: '86c833d3fa242b7f98522f7eee12fad8f301ca02', onSlotchange: this.registerSlides }))), index.h("div", { key: '966d8708ec3f444d2854b960c792033cf4be4541', class: "lightbox__controls" }, index.h("button", { key: '5413d867e329cc80e25a2eb879f4ebd0efe272bc', "aria-label": this.previousSlideButtonLabel, class: "lightbox__previous-slide-button", disabled: this.activeSlideIndex === 0, onClick: this.onPreviousSlideClick }, index.h("swirl-icon-arrow-left", { key: '222f6399158b27123641b61a320c06c7ce46fa68' })), index.h("button", { key: 'be498e47d9140e912448899abb112b379dfc0ff4', "aria-label": this.nextSlideButtonLabel, class: "lightbox__next-slide-button", disabled: this.activeSlideIndex === this.slides.length - 1, onClick: this.onNextSlideClick }, index.h("swirl-icon-arrow-right", { key: 'a3dad756c6d1052504c98576e44e34ffd6793f3c' }))), showPagination && (index.h("span", { key: '893b6ae4cac0ebb15e47b79506aaf4c1074cdf85', class: "lightbox__pagination" }, index.h("span", { key: 'd3cdc7805bfddf426eb67b6682e365198d850de6', "aria-current": "page" }, this.activeSlideIndex + 1), " /", " ", this.slides.length))), !this.hideMenu && (index.h("swirl-popover", { key: 'aa3db469a7f9926d573c64a165e491d4b6ef1c29', animation: "scale-in-y", disableScrollLock: true, id: "slide-menu", label: this.menuLabel, placement: "bottom-end", ref: (el) => (this.menu = el) }, index.h("swirl-stack", { key: '124ab8fb29f24c4dc29bb27680b2cdab28fe3554' }, index.h("div", { key: 'f2a3220011af94da43bd0bffc94ed95731d45b02', class: "lightbox__meta" }, currentThumbnailUrl && (index.h("div", { key: '6a6eb5063e7c27e1df4f086e9f0a5dbd79378082', class: "lightbox__thumbnail" }, index.h("swirl-thumbnail", { key: 'ebdc1427141cb8ea7f905b30394110e202a69eff', alt: "", src: currentThumbnailUrl }))), index.h("div", { key: '2f329517b4dc0a1603331f38a9febdd9a473c485', class: "lightbox__file-info" }, index.h("swirl-text", { key: '44b6e8ddb2ca98d0d8b967634737449bd0ba86f8', truncate: true, weight: "semibold" }, currentFileName), index.h("swirl-text", { key: 'b15159d27d94693f70ecd8acb9db02b1a64168aa', color: "subdued", size: "sm", truncate: true }, currentFileType))), hasMenuItems && index.h("swirl-separator", { key: '5d5899ba624cdf0cddd44cd208cf500ca5a13a60' }), index.h("swirl-action-list", { key: 'be2fd718a93cf326b0f5f86d8d5eaa8dbdb795e3' }, this.downloadButtonEnabled && (index.h("swirl-action-list-item", { key: '1fdc3fe61ae7fcff9e4553edddd04eef3ff1713d', icon: "<swirl-icon-download></swirl-icon-download>", label: this.downloadButtonLabel, onClick: this.onDownloadButtonClick })), index.h("slot", { key: '561c958a3e809fbfcf4f28105f81f5ecf2bf7403', name: "menu-items" }))))))));
268
268
  }
269
269
  get el() { return index.getElement(this); }
270
270
  };