@momentum-ui/web-components 2.21.0-dev → 2.22.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/1200.js +4 -4
- package/dist/1625.js +1 -1
- package/dist/2547.js +1 -1
- package/dist/4548.js +1 -1
- package/dist/4974.js +1 -1
- package/dist/5830.js +1 -0
- package/dist/6015.js +1 -1
- package/dist/6273.js +31 -5
- package/dist/6652.js +1 -1
- package/dist/6798.js +1 -1
- package/dist/7719.js +1 -1
- package/dist/8028.js +1 -1
- package/dist/8728.js +1 -1
- package/dist/assets/icons/svg/alphalink.svg +1 -0
- package/dist/assets/icons/svg/apple-business-chat-color.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-bw-gradient.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-bw-outline.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-bw.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-color-gradient.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-color.svg +1 -0
- package/dist/assets/icons/svg/cisco-ai-assistant-symbol.svg +1 -0
- package/dist/assets/icons/svg/cisco-logo-dark-bw.svg +1 -0
- package/dist/assets/icons/svg/cisco-logo-light-bw.svg +1 -0
- package/dist/assets/icons/svg/cisco-logo-light-color.svg +1 -0
- package/dist/assets/icons/svg/citynet-horizontal.svg +1 -0
- package/dist/assets/icons/svg/citynet-mark.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-bw-horizontal.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-bw-mark.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-bw-vertical.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-color-horizontal.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-color-mark.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-dark-color-vertical.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-bw-horizontal.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-bw-mark.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-bw-vertical.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-color-horizontal.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-color-mark.svg +1 -0
- package/dist/assets/icons/svg/creative-direction-logo-light-color-vertical.svg +1 -0
- package/dist/assets/icons/svg/excelcom-horizontal.svg +1 -0
- package/dist/assets/icons/svg/excelcom-mark.svg +1 -0
- package/dist/assets/icons/svg/fedramp-logo.svg +1 -0
- package/dist/assets/icons/svg/google-meet-color.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-bw-horizontal.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-bw-mark.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-bw-vertical.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-color-horizontal.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-color-mark.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-dark-color-vertical.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-bw-horizontal.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-bw-mark.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-bw-vertical.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-color-horizontal.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-color-mark.svg +1 -0
- package/dist/assets/icons/svg/momentum-design-logo-light-color-vertical.svg +1 -0
- package/dist/assets/icons/svg/ms-teams-color.svg +1 -0
- package/dist/assets/icons/svg/northland-horizontal.svg +1 -0
- package/dist/assets/icons/svg/northland-mark.svg +1 -0
- package/dist/assets/icons/svg/slido-color.svg +1 -0
- package/dist/assets/icons/svg/social-alexa-bw.svg +1 -0
- package/dist/assets/icons/svg/social-alexa-color.svg +1 -0
- package/dist/assets/icons/svg/social-facebook-bw.svg +1 -0
- package/dist/assets/icons/svg/social-facebook-color.svg +1 -0
- package/dist/assets/icons/svg/social-fbmessenger-bw.svg +1 -0
- package/dist/assets/icons/svg/social-fbmessenger-color.svg +1 -0
- package/dist/assets/icons/svg/social-instagram.svg +1 -0
- package/dist/assets/icons/svg/social-line-bw.svg +1 -0
- package/dist/assets/icons/svg/social-line-color.svg +1 -0
- package/dist/assets/icons/svg/social-microsoft-bw.svg +1 -0
- package/dist/assets/icons/svg/social-microsoft-color.svg +1 -0
- package/dist/assets/icons/svg/social-rcs-bw.svg +1 -0
- package/dist/assets/icons/svg/social-rcs-color.svg +1 -0
- package/dist/assets/icons/svg/social-telegram-bw.svg +1 -0
- package/dist/assets/icons/svg/social-telegram-color.svg +1 -0
- package/dist/assets/icons/svg/social-viber-bw.svg +1 -0
- package/dist/assets/icons/svg/social-viber-color.svg +1 -0
- package/dist/assets/icons/svg/social-wechat-bw.svg +1 -0
- package/dist/assets/icons/svg/social-wechat-color.svg +1 -0
- package/dist/assets/icons/svg/social-whatsapp-bw.svg +1 -0
- package/dist/assets/icons/svg/social-whatsapp-color.svg +1 -0
- package/dist/assets/icons/svg/social-x.svg +1 -0
- package/dist/assets/icons/svg/swiftmatch-bw.svg +1 -0
- package/dist/assets/icons/svg/swiftmatch-color.svg +1 -0
- package/dist/assets/icons/svg/switchconnect-horizontal.svg +1 -0
- package/dist/assets/icons/svg/switchconnect-mark.svg +1 -0
- package/dist/assets/icons/svg/telus-horizontal.svg +1 -0
- package/dist/assets/icons/svg/telus-mark.svg +1 -0
- package/dist/assets/icons/svg/verizon-horizontal.svg +1 -0
- package/dist/assets/icons/svg/verizon-mark.svg +1 -0
- package/dist/assets/icons/svg/videotron-horizontal.svg +1 -0
- package/dist/assets/icons/svg/videotron-mark.svg +1 -0
- package/dist/assets/icons/svg/webex-app-icon-color-container.svg +1 -0
- package/dist/assets/icons/svg/webex-app-icon-meet-container.svg +1 -0
- package/dist/assets/icons/svg/webex-app-icon-play-container.svg +1 -0
- package/dist/assets/icons/svg/webex-app-icon-record-container.svg +1 -0
- package/dist/assets/icons/svg/webex-app-icon-wda-container.svg +1 -0
- package/dist/assets/icons/svg/webex-design-logo-dark-bw-gradient.svg +1 -0
- package/dist/assets/icons/svg/webex-design-logo-dark-bw-outline.svg +1 -0
- package/dist/assets/icons/svg/webex-design-logo-light-bw-gradient.svg +1 -0
- package/dist/assets/icons/svg/webex-design-logo-light-bw-outline.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-graphic-five.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-graphic-four.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-graphic-one.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-graphic-three.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-graphic-two.svg +1 -0
- package/dist/assets/icons/svg/webex-graphic-element-wx-graphic.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-gradient-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-gradient-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-gradient-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-gradient-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-outline-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-outline-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-outline-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-bw-outline-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-color-gradient-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-color-gradient-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-color-gradient-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-dark-color-gradient-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-gradient-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-gradient-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-gradient-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-gradient-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-outline-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-outline-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-outline-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-bw-outline-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-color-gradient-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-color-gradient-horizontal.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-color-gradient-vertical-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-logo-lockup-light-color-gradient-vertical.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-dark-apple.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-dark-box.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-dark-microsoft.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-dark-ms-teams.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-dark-okta.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-light-apple.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-light-box.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-light-microsoft.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-light-ms-teams.svg +1 -0
- package/dist/assets/icons/svg/webex-partnership-logo-lockup-light-okta.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-bw-outline-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-bw-outline-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-bw-outline-webex.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-bw-outline-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-color-gradient-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-color-gradient-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-color-gradient-webex.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-dark-color-gradient-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-bw-outline-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-bw-outline-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-bw-outline-webex.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-bw-outline-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-color-gradient-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-color-gradient-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-color-gradient-webex.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-icons-light-color-gradient-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-dark-assist.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-dark-bot.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-dark-campaign.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-dark-engage.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-light-assist.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-light-bot.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-light-campaign.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-tiles-light-engage.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-account.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-adoption-methodology.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-ai-agent-studio.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-ambassador.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-analyzer.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-app-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-assist.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-campaign-manager.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-campaign.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-connect-integrations.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-connect.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-contact-center.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-control-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-cx-studio.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-directory-connector.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-ediscovery.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-engage.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-flow-designer.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-for-developers.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-global-service-status.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-interact.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-notify.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-partner-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-placeholder.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-reach.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-settings.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-suite-settings.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-support.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-the-bridge.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-view.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-dark-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-account.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-adoption-methodology.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-ai-agent-studio.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-ambassador.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-analyzer.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-app-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-assist.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-campaign-manager.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-campaign.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-connect-integrations.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-connect.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-contact-center.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-control-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-cx-studio.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-directory-connector.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-ediscovery.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-engage.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-events.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-flow-designer.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-for-developers.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-global-service-status.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-interact.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-notify.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-partner-hub.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-placeholder.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-reach.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-settings.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-suite-settings.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-support.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-the-bridge.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-vidcast.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-view.svg +1 -0
- package/dist/assets/icons/svg/webex-suite-wordmark-light-whiteboard.svg +1 -0
- package/dist/assets/icons/svg/webex-symbol-common-color-gradient.svg +1 -0
- package/dist/assets/icons/svg/webex-symbol-dark-bw-gradient.svg +1 -0
- package/dist/assets/icons/svg/webex-symbol-dark-bw-outline.svg +1 -0
- package/dist/assets/icons/svg/webex-symbol-light-bw-gradient.svg +1 -0
- package/dist/assets/icons/svg/webex-symbol-light-bw-outline.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-dark-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-dark-vertical-bycisco-center.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-dark-vertical-bycisco-right.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-dark-wordmark.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-light-horizontal-bycisco.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-light-vertical-bycisco-center.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-light-vertical-bycisco-right.svg +1 -0
- package/dist/assets/icons/svg/webex-wordmark-light-wordmark.svg +1 -0
- package/dist/assets/icons/svg/zoom-color.svg +1 -0
- package/dist/chunks/md-1786.js +1 -1
- package/dist/comp/md-accordion-item-entry.js +4 -4
- package/dist/comp/md-accordion-item.js +1 -1
- package/dist/comp/md-activity-button-entry.js +2 -2
- package/dist/comp/md-activity-button.js +1 -1
- package/dist/comp/md-alert-banner-entry.js +7 -7
- package/dist/comp/md-alert-banner.js +1 -1
- package/dist/comp/md-alert-entry.js +29 -29
- package/dist/comp/md-alert.js +1 -1
- package/dist/comp/md-audio-player-entry.js +7 -7
- package/dist/comp/md-audio-player.js +1 -1
- package/dist/comp/md-avatar-entry.js +14 -14
- package/dist/comp/md-avatar.js +1 -1
- package/dist/comp/md-button-entry.js +1 -1
- package/dist/comp/md-card-ai-entry.js +16 -16
- package/dist/comp/md-card-ai.js +1 -1
- package/dist/comp/md-card-entry.js +11 -11
- package/dist/comp/md-card-v2-entry.js +6 -6
- package/dist/comp/md-card-v2.js +1 -1
- package/dist/comp/md-card.js +1 -1
- package/dist/comp/md-chat-message-entry.js +2 -2
- package/dist/comp/md-chat-message.js +1 -1
- package/dist/comp/md-coachmark-popover-entry.js +15 -15
- package/dist/comp/md-coachmark-popover.js +1 -1
- package/dist/comp/md-combobox-entry.js +45 -45
- package/dist/comp/md-combobox.js +1 -1
- package/dist/comp/md-date-range-picker-entry.js +1 -1
- package/dist/comp/md-date-range-picker.js +1 -1
- package/dist/comp/md-date-time-picker-entry.js +5 -3
- package/dist/comp/md-date-time-picker.js +1 -1
- package/dist/comp/md-datepicker-calendar-entry.js +9 -9
- package/dist/comp/md-datepicker-calendar.js +1 -1
- package/dist/comp/md-datepicker-day-entry.js +1 -1
- package/dist/comp/md-datepicker-entry.js +30 -4
- package/dist/comp/md-datepicker-month-entry.js +1 -1
- package/dist/comp/md-datepicker-week-entry.js +1 -1
- package/dist/comp/md-datepicker.js +1 -1
- package/dist/comp/md-dropdown-entry.js +12 -11
- package/dist/comp/md-dropdown.js +1 -1
- package/dist/comp/md-editable-field-entry.js +25 -25
- package/dist/comp/md-editable-field.js +1 -1
- package/dist/comp/md-favorite-entry.js +3 -3
- package/dist/comp/md-favorite.js +1 -1
- package/dist/comp/md-floating-minimize-entry.js +6 -6
- package/dist/comp/md-floating-minimize.js +1 -1
- package/dist/comp/md-floating-modal-entry.js +6 -6
- package/dist/comp/md-floating-modal.js +1 -1
- package/dist/comp/md-grabber-entry.js +5 -5
- package/dist/comp/md-grabber.js +1 -1
- package/dist/comp/md-icon-entry.js +9 -9
- package/dist/comp/md-icon.js +1 -1
- package/dist/comp/md-input-entry.js +26 -26
- package/dist/comp/md-input.js +1 -1
- package/dist/comp/md-meeting-alert-entry.js +11 -11
- package/dist/comp/md-meeting-alert.js +1 -1
- package/dist/comp/md-menu-entry.js +2 -2
- package/dist/comp/md-modal-entry.js +4 -4
- package/dist/comp/md-modal.js +1 -1
- package/dist/comp/md-pagination-entry.js +12 -12
- package/dist/comp/md-pagination.js +1 -1
- package/dist/comp/md-phone-input-entry.js +8 -8
- package/dist/comp/md-phone-input.js +1 -1
- package/dist/comp/md-popover-entry.js +6 -6
- package/dist/comp/md-popover.js +1 -1
- package/dist/comp/md-table-advanced-entry.js +28 -28
- package/dist/comp/md-table-advanced.js +1 -1
- package/dist/comp/md-table-entry.js +11 -11
- package/dist/comp/md-table.js +1 -1
- package/dist/comp/md-tabs-entry.js +13 -13
- package/dist/comp/md-tabs.js +1 -1
- package/dist/comp/md-task-item-entry.js +4 -4
- package/dist/comp/md-task-item.js +1 -1
- package/dist/comp/md-timepicker-entry.js +26 -26
- package/dist/comp/md-timepicker.js +1 -1
- package/dist/index-entry.js +165 -162
- package/dist/index.js +1 -1
- package/dist/managers/thememanager-entry.js +1 -1
- package/dist/types/components/combobox/ComboBox.d.ts +1 -1
- package/dist/types/components/date-range-picker/DateRangePicker.d.ts +2 -1
- package/dist/types/components/date-time-picker/DateTimePicker.d.ts +4 -2
- package/dist/types/components/datepicker/DatePicker.d.ts +18 -5
- package/dist/types/components/editable-textfield/EditableTextfield.d.ts +2 -2
- package/dist/types/components/grabber/Grabber.d.ts +1 -1
- package/dist/types/components/icon/Icon.d.ts +3 -9
- package/dist/types/components/icon/Icon.utils.d.ts +8 -0
- package/dist/types/index.d.ts +2 -1
- package/dist/types/managers/IconUrlManager.d.ts +8 -0
- package/dist/types/managers/ThemeManager.d.ts +25 -4
- package/dist/types/utils/dateUtils.d.ts +2 -0
- package/package.json +2 -3
- package/dist/4006.js +0 -1
- package/dist/6248.js +0 -1
- package/dist/types/components/icon/brand-visual-icons.d.ts +0 -1
package/dist/index-entry.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("lit-element"),require("lit-html/directives/style-map"),require("lit-html"),require("lit-html/directives/class-map"),require("lit-html/directives/if-defined"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("lit-virtualizer"),require("lit-html/directives/class-map.js"),require("lit-html/directives/until.js"),require("lit-html/directives/repeat"),require("@popperjs/core/lib/modifiers/arrow"),require("@popperjs/core/lib/modifiers/flip"),require("@popperjs/core/lib/modifiers/offset"),require("@popperjs/core/lib/modifiers/preventOverflow"),require("@popperjs/core/lib/popper-lite"),require("lit-html/directives/if-defined.js"),require("highlight.js/lib/core"),require("luxon"),require("mobx"),require("sortablejs"),require("dompurify"),require("@interactjs/actions/drag"),require("@interactjs/actions/resize"),require("@interactjs/auto-start"),require("@interactjs/interact/index"),require("@interactjs/modifiers"),require("country-codes-list"),require("country-flags-svg"),require("libphonenumber-js"),require("lit-html/directives/repeat.js"),require("lit-html/directives/template-content"),require("papaparse"),require("lit-html/directives/unsafe-html"),require("@popperjs/core/lib"),require("@momentum-design/brand-visuals/dist/logos/svg/webex-app-icon-color-container.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-x.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-whatsapp-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-wechat-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-viber-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-telegram-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-rcs-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-microsoft-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-line-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-fbmessenger-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-facebook-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-alexa-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/cisco-ai-assistant-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/apple-business-chat-color.svg"));else if("function"==typeof define&&define.amd)define(["lit-element","lit-html/directives/style-map","lit-html","lit-html/directives/class-map","lit-html/directives/if-defined","@momentum-ui/icons/data/momentumUiIconsNames.json","@momentum-ui/utils/lib/getColorValue","lit-virtualizer","lit-html/directives/class-map.js","lit-html/directives/until.js","lit-html/directives/repeat","@popperjs/core/lib/modifiers/arrow","@popperjs/core/lib/modifiers/flip","@popperjs/core/lib/modifiers/offset","@popperjs/core/lib/modifiers/preventOverflow","@popperjs/core/lib/popper-lite","lit-html/directives/if-defined.js","highlight.js/lib/core","luxon","mobx","sortablejs","dompurify","@interactjs/actions/drag","@interactjs/actions/resize","@interactjs/auto-start","@interactjs/interact/index","@interactjs/modifiers","country-codes-list","country-flags-svg","libphonenumber-js","lit-html/directives/repeat.js","lit-html/directives/template-content","papaparse","lit-html/directives/unsafe-html","@popperjs/core/lib","@momentum-design/brand-visuals/dist/logos/svg/webex-app-icon-color-container.svg","@momentum-design/brand-visuals/dist/logos/svg/social-x.svg","@momentum-design/brand-visuals/dist/logos/svg/social-whatsapp-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-wechat-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-viber-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-telegram-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-rcs-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-microsoft-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-line-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-fbmessenger-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-facebook-color.svg","@momentum-design/brand-visuals/dist/logos/svg/social-alexa-color.svg","@momentum-design/brand-visuals/dist/logos/svg/cisco-ai-assistant-color.svg","@momentum-design/brand-visuals/dist/logos/svg/apple-business-chat-color.svg"],t);else{var i="object"==typeof exports?t(require("lit-element"),require("lit-html/directives/style-map"),require("lit-html"),require("lit-html/directives/class-map"),require("lit-html/directives/if-defined"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("lit-virtualizer"),require("lit-html/directives/class-map.js"),require("lit-html/directives/until.js"),require("lit-html/directives/repeat"),require("@popperjs/core/lib/modifiers/arrow"),require("@popperjs/core/lib/modifiers/flip"),require("@popperjs/core/lib/modifiers/offset"),require("@popperjs/core/lib/modifiers/preventOverflow"),require("@popperjs/core/lib/popper-lite"),require("lit-html/directives/if-defined.js"),require("highlight.js/lib/core"),require("luxon"),require("mobx"),require("sortablejs"),require("dompurify"),require("@interactjs/actions/drag"),require("@interactjs/actions/resize"),require("@interactjs/auto-start"),require("@interactjs/interact/index"),require("@interactjs/modifiers"),require("country-codes-list"),require("country-flags-svg"),require("libphonenumber-js"),require("lit-html/directives/repeat.js"),require("lit-html/directives/template-content"),require("papaparse"),require("lit-html/directives/unsafe-html"),require("@popperjs/core/lib"),require("@momentum-design/brand-visuals/dist/logos/svg/webex-app-icon-color-container.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-x.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-whatsapp-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-wechat-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-viber-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-telegram-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-rcs-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-microsoft-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-line-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-fbmessenger-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-facebook-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/social-alexa-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/cisco-ai-assistant-color.svg"),require("@momentum-design/brand-visuals/dist/logos/svg/apple-business-chat-color.svg")):t(e["lit-element"],e["lit-html/directives/style-map"],e["lit-html"],e["lit-html/directives/class-map"],e["lit-html/directives/if-defined"],e["@momentum-ui/icons/data/momentumUiIconsNames.json"],e["@momentum-ui/utils/lib/getColorValue"],e["lit-virtualizer"],e["lit-html/directives/class-map.js"],e["lit-html/directives/until.js"],e["lit-html/directives/repeat"],e["@popperjs/core/lib/modifiers/arrow"],e["@popperjs/core/lib/modifiers/flip"],e["@popperjs/core/lib/modifiers/offset"],e["@popperjs/core/lib/modifiers/preventOverflow"],e["@popperjs/core/lib/popper-lite"],e["lit-html/directives/if-defined.js"],e["highlight.js/lib/core"],e.luxon,e.mobx,e.sortablejs,e.dompurify,e["@interactjs/actions/drag"],e["@interactjs/actions/resize"],e["@interactjs/auto-start"],e["@interactjs/interact/index"],e["@interactjs/modifiers"],e["country-codes-list"],e["country-flags-svg"],e["libphonenumber-js"],e["lit-html/directives/repeat.js"],e["lit-html/directives/template-content"],e.papaparse,e["lit-html/directives/unsafe-html"],e["@popperjs/core/lib"],e["@momentum-design/brand-visuals/dist/logos/svg/webex-app-icon-color-container.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-x.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-whatsapp-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-wechat-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-viber-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-telegram-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-rcs-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-microsoft-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-line-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-fbmessenger-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-facebook-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/social-alexa-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/cisco-ai-assistant-color.svg"],e["@momentum-design/brand-visuals/dist/logos/svg/apple-business-chat-color.svg"]);for(var s in i)("object"==typeof exports?exports:e)[s]=i[s]}}(self,((e,t,i,s,o,r,n,a,l,d,h,c,p,u,m,v,b,y,g,f,w,x,C,S,$,E,k,T,I,A,O,L,M,P,D,R,_,F,B,z,V,j,N,U,q,H,K,W,G)=>(()=>{"use strict";var Y,X,Q,Z,J,ee={860:e=>{e.exports=A},1072:(e,t,i)=>{i.d(t,{Theme:()=>s});var s,o=i(77251),r=i(31890),n=i(4893),a=i(4863),l=i(41488),d=i(19130),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this.darkTheme=!1,this.lumos=!1,this.activeTheme=d.dW,this.placement="bottom",this.popperInstance=null,this.handleTooltipRemoved=()=>{this.hideVirtualTooltip()}}setTheme(){return"momentum"===this.theme?this.darkTheme?d.Pm:d.f3:"lumos"===this.theme?this.darkTheme?d.Lu:d.dW:"momentumV2"===this.theme?this.darkTheme?d.Pm:d.f3:this.lumos?this.darkTheme?d.Lu:d.dW:this.darkTheme?d.Pm:d.f3}getStyleElement(){return document.createElement("style")}applyStyle(){const e=this.shadowRoot;if("adoptedStyleSheets"in document){const t=new CSSStyleSheet;t.replaceSync(this.activeTheme),e.adoptedStyleSheets=[t]}else{const t=this.getStyleElement();t.textContent=this.activeTheme.cssText,e.appendChild(t)}}removeChildFromVirtualPopper(){for(;this.virtualWrapper.firstElementChild;)this.virtualWrapper.firstElementChild.remove()}setInitStyleToVirtualReference(){const{style:e}=this.virtualReference;e.top="0",e.bottom="0",e.left="0",e.right="0",e.width="0",e.height="0",e.zIndex="-1"}setStyleToVirtualReference(e){const{style:t}=this.virtualReference,{top:i,bottom:s,left:o,right:r,width:n,height:a}=e;t.position="fixed",t.top=`${i}px`,t.bottom=`${s}px`,t.left=`${o}px`,t.right=`${r}px`,t.width=`${n}px`,t.height=`${a}px`,t.zIndex="-1"}setVirtualReferencePosition(e){const t=e.getBoundingClientRect();this.setStyleToVirtualReference(t)}initVirtualElements(e,t,i){const s=e.cloneNode(!0);this.virtualWrapper.hasChildNodes()&&this.removeChildFromVirtualPopper(),this.virtualWrapper.append(s),i&&this.setVirtualSlotContent(i),this.setVirtualReferencePosition(t)}setVirtualSlotContent(e){if(this.virtualTooltipContent){for(;this.virtualTooltipContent.firstElementChild;)this.virtualTooltipContent.firstElementChild.remove();e.forEach((e=>this.virtualTooltipContent.append(e)))}}updated(e){super.updated(e),(e.has("lumos")||e.has("darkTheme")||e.has("theme"))&&this.dispatchEvent(new CustomEvent("theme-changed",{composed:!0,bubbles:!0,detail:{darkTheme:this.darkTheme,lumos:this.lumos,theme:this.theme}})),this.activeTheme=this.setTheme(),this.applyStyle()}handleVirtualTooltipCreate(e){e.stopPropagation();const{popper:t,placement:i,reference:s,slotContent:o}=e.detail;this.placement=i,this.initVirtualElements(t,s,o),this.showVirtualTooltip()}handleVirtualTooltipDestroy(e){e.stopPropagation(),this.hideVirtualTooltip()}handleVirtualTooltipChangeMessage(e){const{popper:t,reference:i}=e.detail;if(this.virtualReference!==i)return;const s=t.querySelector(".md-tooltip__content"),o=this.virtualWrapper.querySelector(".md-tooltip__content");if(s&&o){const e=s.textContent,t=o.textContent;e&&t&&(o.textContent=e)}}handleVirtualTooltipSlotChange(e){const{slotContent:t}=e.detail;t&&this.setVirtualSlotContent(t)}destroyPopperInstance(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}createPopperInstance(e){if(this.virtualPopper){const t=8,i=4;this.popperInstance=(0,n.createPopper)(this.virtualReference,this.virtualPopper,{placement:e,modifiers:[...a.defaultModifiers,n.flip,n.offset,n.arrow,{name:"offset",options:{offset:({placement:e})=>{const s=t+i;return e.startsWith("left")||e.startsWith("right")||e.startsWith("top")||e.startsWith("bottom")?[0,s]:[8,8]}}},...this.virtualArrow?[{name:"arrow",options:{element:this.virtualArrow,padding:t}}]:[]]})}}get virtualPopper(){return this.shadowRoot.querySelector(".md-tooltip__popper")}get virtualArrow(){return this.shadowRoot.querySelector(".md-tooltip__arrow")}get virtualTooltipContent(){return this.shadowRoot.querySelector(".md-tooltip__content")}showVirtualTooltip(){this.virtualPopper&&(this.virtualPopper.toggleAttribute("data-show",!0),this.createPopperInstance(this.placement))}hideVirtualTooltip(){this.virtualPopper&&(this.virtualPopper.toggleAttribute("data-show",!1),this.destroyPopperInstance(),this.setInitStyleToVirtualReference())}setupEvents(){this.addEventListener("tooltip-create",this.handleVirtualTooltipCreate),this.addEventListener("tooltip-destroy",this.handleVirtualTooltipDestroy),this.addEventListener("tooltip-message",this.handleVirtualTooltipChangeMessage),this.addEventListener("tooltip-slot",this.handleVirtualTooltipSlotChange),document.addEventListener("tooltip-disconnected",this.handleTooltipRemoved,!0)}teardownEvents(){this.removeEventListener("tooltip-create",this.handleVirtualTooltipCreate),this.removeEventListener("tooltip-destroy",this.handleVirtualTooltipDestroy),this.removeEventListener("tooltip-message",this.handleVirtualTooltipChangeMessage),this.removeEventListener("tooltip-slot",this.handleVirtualTooltipSlotChange),document.removeEventListener("tooltip-disconnected",this.handleTooltipRemoved,!0)}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return i=this,s=void 0,r=function*(){t.firstUpdated.call(this,e),yield new Promise((e=>setTimeout(e,0))),this.setupEvents()},new((o=void 0)||(o=Promise))((function(e,t){function n(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(n,a)}l((r=r.apply(i,s||[])).next())}));var i,s,o,r}static get styles(){return[d.dW]}render(){return l.html`
|
|
1
|
+
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("lit-element"),require("lit-html/directives/style-map"),require("lit-html"),require("lit-html/directives/class-map"),require("lit-html/directives/if-defined"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("lit-virtualizer"),require("lit-html/directives/class-map.js"),require("lit-html/directives/until.js"),require("lit-html/directives/repeat"),require("@popperjs/core/lib/modifiers/arrow"),require("@popperjs/core/lib/modifiers/flip"),require("@popperjs/core/lib/modifiers/offset"),require("@popperjs/core/lib/modifiers/preventOverflow"),require("@popperjs/core/lib/popper-lite"),require("lit-html/directives/if-defined.js"),require("highlight.js/lib/core"),require("luxon"),require("sortablejs"),require("dompurify"),require("@interactjs/actions/drag"),require("@interactjs/actions/resize"),require("@interactjs/auto-start"),require("@interactjs/interact/index"),require("@interactjs/modifiers"),require("country-codes-list"),require("country-flags-svg"),require("libphonenumber-js"),require("lit-html/directives/repeat.js"),require("lit-html/directives/template-content"),require("papaparse"),require("lit-html/directives/unsafe-html"),require("@popperjs/core/lib"));else if("function"==typeof define&&define.amd)define(["lit-element","lit-html/directives/style-map","lit-html","lit-html/directives/class-map","lit-html/directives/if-defined","@momentum-ui/icons/data/momentumUiIconsNames.json","@momentum-ui/utils/lib/getColorValue","mobx","lit-virtualizer","lit-html/directives/class-map.js","lit-html/directives/until.js","lit-html/directives/repeat","@popperjs/core/lib/modifiers/arrow","@popperjs/core/lib/modifiers/flip","@popperjs/core/lib/modifiers/offset","@popperjs/core/lib/modifiers/preventOverflow","@popperjs/core/lib/popper-lite","lit-html/directives/if-defined.js","highlight.js/lib/core","luxon","sortablejs","dompurify","@interactjs/actions/drag","@interactjs/actions/resize","@interactjs/auto-start","@interactjs/interact/index","@interactjs/modifiers","country-codes-list","country-flags-svg","libphonenumber-js","lit-html/directives/repeat.js","lit-html/directives/template-content","papaparse","lit-html/directives/unsafe-html","@popperjs/core/lib"],t);else{var i="object"==typeof exports?t(require("lit-element"),require("lit-html/directives/style-map"),require("lit-html"),require("lit-html/directives/class-map"),require("lit-html/directives/if-defined"),require("@momentum-ui/icons/data/momentumUiIconsNames.json"),require("@momentum-ui/utils/lib/getColorValue"),require("mobx"),require("lit-virtualizer"),require("lit-html/directives/class-map.js"),require("lit-html/directives/until.js"),require("lit-html/directives/repeat"),require("@popperjs/core/lib/modifiers/arrow"),require("@popperjs/core/lib/modifiers/flip"),require("@popperjs/core/lib/modifiers/offset"),require("@popperjs/core/lib/modifiers/preventOverflow"),require("@popperjs/core/lib/popper-lite"),require("lit-html/directives/if-defined.js"),require("highlight.js/lib/core"),require("luxon"),require("sortablejs"),require("dompurify"),require("@interactjs/actions/drag"),require("@interactjs/actions/resize"),require("@interactjs/auto-start"),require("@interactjs/interact/index"),require("@interactjs/modifiers"),require("country-codes-list"),require("country-flags-svg"),require("libphonenumber-js"),require("lit-html/directives/repeat.js"),require("lit-html/directives/template-content"),require("papaparse"),require("lit-html/directives/unsafe-html"),require("@popperjs/core/lib")):t(e["lit-element"],e["lit-html/directives/style-map"],e["lit-html"],e["lit-html/directives/class-map"],e["lit-html/directives/if-defined"],e["@momentum-ui/icons/data/momentumUiIconsNames.json"],e["@momentum-ui/utils/lib/getColorValue"],e.mobx,e["lit-virtualizer"],e["lit-html/directives/class-map.js"],e["lit-html/directives/until.js"],e["lit-html/directives/repeat"],e["@popperjs/core/lib/modifiers/arrow"],e["@popperjs/core/lib/modifiers/flip"],e["@popperjs/core/lib/modifiers/offset"],e["@popperjs/core/lib/modifiers/preventOverflow"],e["@popperjs/core/lib/popper-lite"],e["lit-html/directives/if-defined.js"],e["highlight.js/lib/core"],e.luxon,e.sortablejs,e.dompurify,e["@interactjs/actions/drag"],e["@interactjs/actions/resize"],e["@interactjs/auto-start"],e["@interactjs/interact/index"],e["@interactjs/modifiers"],e["country-codes-list"],e["country-flags-svg"],e["libphonenumber-js"],e["lit-html/directives/repeat.js"],e["lit-html/directives/template-content"],e.papaparse,e["lit-html/directives/unsafe-html"],e["@popperjs/core/lib"]);for(var s in i)("object"==typeof exports?exports:e)[s]=i[s]}}(self,((e,t,i,s,o,r,n,a,l,d,h,p,c,u,m,y,b,v,g,f,w,C,x,S,$,E,k,T,I,A,O,L,M,P,D)=>(()=>{"use strict";var R,_,F,B,z,V={860:e=>{e.exports=A},1072:(e,t,i)=>{i.d(t,{Theme:()=>s});var s,o=i(77251),r=i(31890),n=i(4893),a=i(4863),l=i(41488),d=i(19130),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this.darkTheme=!1,this.lumos=!1,this.activeTheme=d.dW,this.placement="bottom",this.popperInstance=null,this.handleTooltipRemoved=()=>{this.hideVirtualTooltip()}}setTheme(){return"momentum"===this.theme?this.darkTheme?d.Pm:d.f3:"lumos"===this.theme?this.darkTheme?d.Lu:d.dW:"momentumV2"===this.theme?this.darkTheme?d.Pm:d.f3:this.lumos?this.darkTheme?d.Lu:d.dW:this.darkTheme?d.Pm:d.f3}getStyleElement(){return document.createElement("style")}applyStyle(){const e=this.shadowRoot;if("adoptedStyleSheets"in document){const t=new CSSStyleSheet;t.replaceSync(this.activeTheme),e.adoptedStyleSheets=[t]}else{const t=this.getStyleElement();t.textContent=this.activeTheme.cssText,e.appendChild(t)}}removeChildFromVirtualPopper(){for(;this.virtualWrapper.firstElementChild;)this.virtualWrapper.firstElementChild.remove()}setInitStyleToVirtualReference(){const{style:e}=this.virtualReference;e.top="0",e.bottom="0",e.left="0",e.right="0",e.width="0",e.height="0",e.zIndex="-1"}setStyleToVirtualReference(e){const{style:t}=this.virtualReference,{top:i,bottom:s,left:o,right:r,width:n,height:a}=e;t.position="fixed",t.top=`${i}px`,t.bottom=`${s}px`,t.left=`${o}px`,t.right=`${r}px`,t.width=`${n}px`,t.height=`${a}px`,t.zIndex="-1"}setVirtualReferencePosition(e){const t=e.getBoundingClientRect();this.setStyleToVirtualReference(t)}initVirtualElements(e,t,i){const s=e.cloneNode(!0);this.virtualWrapper.hasChildNodes()&&this.removeChildFromVirtualPopper(),this.virtualWrapper.append(s),i&&this.setVirtualSlotContent(i),this.setVirtualReferencePosition(t)}setVirtualSlotContent(e){if(this.virtualTooltipContent){for(;this.virtualTooltipContent.firstElementChild;)this.virtualTooltipContent.firstElementChild.remove();e.forEach((e=>this.virtualTooltipContent.append(e)))}}updated(e){super.updated(e),(e.has("lumos")||e.has("darkTheme")||e.has("theme"))&&this.dispatchEvent(new CustomEvent("theme-changed",{composed:!0,bubbles:!0,detail:{darkTheme:this.darkTheme,lumos:this.lumos,theme:this.theme}})),this.activeTheme=this.setTheme(),this.applyStyle()}handleVirtualTooltipCreate(e){e.stopPropagation();const{popper:t,placement:i,reference:s,slotContent:o}=e.detail;this.placement=i,this.initVirtualElements(t,s,o),this.showVirtualTooltip()}handleVirtualTooltipDestroy(e){e.stopPropagation(),this.hideVirtualTooltip()}handleVirtualTooltipChangeMessage(e){const{popper:t,reference:i}=e.detail;if(this.virtualReference!==i)return;const s=t.querySelector(".md-tooltip__content"),o=this.virtualWrapper.querySelector(".md-tooltip__content");if(s&&o){const e=s.textContent,t=o.textContent;e&&t&&(o.textContent=e)}}handleVirtualTooltipSlotChange(e){const{slotContent:t}=e.detail;t&&this.setVirtualSlotContent(t)}destroyPopperInstance(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}createPopperInstance(e){if(this.virtualPopper){const t=8,i=4;this.popperInstance=(0,n.createPopper)(this.virtualReference,this.virtualPopper,{placement:e,modifiers:[...a.defaultModifiers,n.flip,n.offset,n.arrow,{name:"offset",options:{offset:({placement:e})=>{const s=t+i;return e.startsWith("left")||e.startsWith("right")||e.startsWith("top")||e.startsWith("bottom")?[0,s]:[8,8]}}},...this.virtualArrow?[{name:"arrow",options:{element:this.virtualArrow,padding:t}}]:[]]})}}get virtualPopper(){return this.shadowRoot.querySelector(".md-tooltip__popper")}get virtualArrow(){return this.shadowRoot.querySelector(".md-tooltip__arrow")}get virtualTooltipContent(){return this.shadowRoot.querySelector(".md-tooltip__content")}showVirtualTooltip(){this.virtualPopper&&(this.virtualPopper.toggleAttribute("data-show",!0),this.createPopperInstance(this.placement))}hideVirtualTooltip(){this.virtualPopper&&(this.virtualPopper.toggleAttribute("data-show",!1),this.destroyPopperInstance(),this.setInitStyleToVirtualReference())}setupEvents(){this.addEventListener("tooltip-create",this.handleVirtualTooltipCreate),this.addEventListener("tooltip-destroy",this.handleVirtualTooltipDestroy),this.addEventListener("tooltip-message",this.handleVirtualTooltipChangeMessage),this.addEventListener("tooltip-slot",this.handleVirtualTooltipSlotChange),document.addEventListener("tooltip-disconnected",this.handleTooltipRemoved,!0)}teardownEvents(){this.removeEventListener("tooltip-create",this.handleVirtualTooltipCreate),this.removeEventListener("tooltip-destroy",this.handleVirtualTooltipDestroy),this.removeEventListener("tooltip-message",this.handleVirtualTooltipChangeMessage),this.removeEventListener("tooltip-slot",this.handleVirtualTooltipSlotChange),document.removeEventListener("tooltip-disconnected",this.handleTooltipRemoved,!0)}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return i=this,s=void 0,r=function*(){t.firstUpdated.call(this,e),yield new Promise((e=>setTimeout(e,0))),this.setupEvents()},new((o=void 0)||(o=Promise))((function(e,t){function n(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(n,a)}l((r=r.apply(i,s||[])).next())}));var i,s,o,r}static get styles(){return[d.dW]}render(){return l.html`
|
|
2
2
|
<div class="theme-wrapper" part="theme-wrapper">
|
|
3
3
|
<style>
|
|
4
4
|
${o.A} .theme-wrapper {
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
<label part="checkbox-label" class="checkbox-label">
|
|
27
27
|
<slot></slot>
|
|
28
28
|
</label>
|
|
29
|
-
`}};h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"checked",null),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"indeterminate",null),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,l.property)({type:String})],t.prototype,"label",void 0),h([(0,l.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,l.query)(".checkbox-input")],t.prototype,"input",void 0),t=h([(0,a.w)("md-checkbox")],t),e.ELEMENT=t}(s||(s={}))},4863:e=>{e.exports=v},4893:e=>{e.exports=D},4928:(e,t,i)=>{i.d(t,{ComboBox:()=>s}),i(20109),i(61200);var s,o=i(90195),r=i(3001),n=i(31890),a=i(66677),l=i(26272),d=i(41488),h=i(40333),c=i(23968),p=i(97822),u=i(22818),m=i(8229),v=i(86635),b=i(97103),y=i(46795),g=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},f=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){class t{determineMessageType(e){return e.reduce(((e,t)=>"error"===t?e:t.type),"")}filterMessagesByType(e,t){return e.reduce(((e,i)=>i.type===t?e.concat(i.message):e),[])}}e.MessageController=t;let i=class extends((0,r.yC)(d.LitElement)){constructor(){super(...arguments),this._focusedIndex=-1,this._focusedGroupIndex=-1,this.label="Options",this.options=[],this.customOptions=[],this.placeholder="",this.isMulti=!1,this.useVirtualScroll=!1,this.disabled=!1,this.ordered=!1,this.expanded=!1,this.groupExpandedList=[],this.searchItem=!1,this.compact=!1,this.noClearIcon=!1,this.selectWhenInFocus=!1,this.selectedOptions=[],this.visibleOptions=8,this.optionId="",this.optionValue="",this.isCustomContent=!1,this.searchable=!1,this.shape="none",this.value=[],this.inputValue="",this.allowCustomValue=!1,this.autofocus=!1,this.resultsTextLocalization="No Results",this.optionsTextLocalization="No Options",this.trimSpace=!1,this.invalid=!1,this.invalidText="",this.ariaLabel="",this.searchResultAriaLabel="",this.ariaLabelForComboBox="",this.clearAriaLabel="Clear",this.arrowAriaLabel="Expand",this.clearIconHeight="auto",this.allTextLocalization="All",this.selectAllTextLocalization="Select All",this.selectedTextLocalization="Selected",this.allowSelectAll=!1,this.showCustomError=!1,this.showLoader=!1,this.showSelectedCount=!1,this.popupChevronAriaHidden="true",this.newMomentum=!1,this.showFilterIcon=!1,this.preventFilter=!1,this.isDropdownArrow=!1,this.comboboxId="",this.helpText="",this.messageArr=[],this.htmlId="",this.readOnly=!1,this.messageController=new t,this.isOptGroup=!1,this.isSelectAllChecked=!1,this.multiSelectedIndex=-1,this.multiSelected=[],this.customContent=[],this.notifySelectedChange=(0,a.sg)((e=>{this.dispatchEvent(new CustomEvent("change-selected",{composed:!0,bubbles:!0,detail:e}))}),0),this.handleGroupFilter=e=>{const t=e.filter((e=>{if("string"!=typeof e&&"true"===e.isLabel)return e.groupName}));return this.searchItem=!0,this.groupExpandedList=t.map((e=>{if("string"!=typeof e)return e.groupName})),e.filter((t=>"string"==typeof t||"true"!==t.isLabel||!!e.find((e=>{if("string"!=typeof t&&"string"!=typeof e)return t.groupName===e.groupName&&"false"===e.isLabel}))))},this.notifyInputValueChanged=(0,a.sg)((e=>{this.dispatchEvent(new CustomEvent("combobox-input",{composed:!0,bubbles:!0,detail:{value:e}})),this.notifySearchResultCount(),this.focusedGroupIndex=0,requestAnimationFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}),250),this.handleOutsideClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||(this.setVisualListbox(!1),this.unselectedAllMultiTag()))}}get focusedIndex(){return this._focusedIndex}set focusedIndex(e){this.updateFocusedIndex(e)}updateFocusedIndex(e){var t;const i=this._focusedIndex;if(this.checkForVirtualScroll()){let i;i=this.allowSelectAll?0===e?"selectAll":this.getOptionId(this.filteredOptions[e-1]):this.getOptionId(this.filteredOptions[e]);const s=this.lists?null===(t=[...this.lists])||void 0===t?void 0:t.find((e=>0!==e.offsetHeight&&e.id===i)):"";this.lists&&[...this.lists].forEach((e=>{e.toggleAttribute("focused",!1)})),s&&(null==s||s.toggleAttribute("focused",!0))}else if(this.lists){const t=this.lists[i];t&&t.toggleAttribute("focused",!1);const s=this.lists[e];s&&s.toggleAttribute("focused",!0)}this._focusedIndex=e,this.requestUpdate("focusedIndex",i)}get focusedGroupIndex(){return this._focusedGroupIndex}set focusedGroupIndex(e){const t=this._focusedGroupIndex;if(this.labels&&0!==this.labels.length){const i=this.labels[t];i&&i.toggleAttribute("focused",!1);const s=this.labels[e];s&&(s.toggleAttribute("focused",!0),s.focus())}this._focusedGroupIndex=e,this.requestUpdate("focusedGroupIndex",t)}get messageType(){return this.messageArr.length>0?this.messageController.determineMessageType(this.messageArr):null}get messages(){return this.messageType?this.messageController.filterMessagesByType(this.messageArr,this.messageType):null}notifySearchResultCount(){if(this.searchResultAriaLabel){const e=/{{.*?}}/g;this.ariaLabelForComboBox=this.searchResultAriaLabel.replace(e,this.filteredOptions.length.toString())}else this.ariaLabel?this.ariaLabelForComboBox=`${this.ariaLabel}, ${this.filteredOptions.length} results found.`:this.ariaLabelForComboBox=`ComboBox Element, ${this.filteredOptions.length} results found.`}firstUpdated(e){this.ariaLabelForComboBox=this.ariaLabel?this.ariaLabel:"ComboBox Element",super.firstUpdated(e),this.isCustomContent&&(this.optionId="id",this.optionValue="value",this.setOptionCustomContent()),this.setInitialValue()}updated(e){super.updated(e),e.has("expanded")&&(this.expanded?(this.resizeListbox(),this.checkSelectedOptions()):this.unCheckAllOptions()),e.has("focusedIndex")&&this.focusedIndex>=0&&(this.checkForVirtualScroll()||this.scrollToOption()),e.has("value")&&0===this.selectedOptions.length&&this.setInitialValue(),e.has("customOptions")&&this.isCustomContent&&(this.setOptionCustomContent(),this.resizeListbox()),e.has("showCustomError")&&this.resizeListbox(),e.has("showLoader")&&this.resizeListbox(),e.has("searchItem")&&this.resizeListbox()}handleFocusIn(e){this.disabled&&!this.readOnly||(this.noClearIcon&&(requestAnimationFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1})),this.selectWhenInFocus&&this.input.select()),super.handleFocusIn&&super.handleFocusIn(e)),this.dispatchEvent(new CustomEvent("combobox-focus-in",{composed:!0,bubbles:!0}))}handleFocusOut(e){super.handleFocusOut&&super.handleFocusOut(e),this.dispatchEvent(new CustomEvent("combobox-focus-out",{composed:!0,bubbles:!0}))}findFilteredOption(e){return this.isOptionObject(e)?this.filteredOptions.findIndex((t=>this.getOptionId(t)===this.getOptionId(e)&&this.getOptionValue(t)===this.getOptionValue(e))):this.filteredOptions.indexOf(e)}setInitialValue(){var e;if(this.value.length)if(this.isMulti)this.value.forEach((e=>{-1!==this.findFilteredOption(e)&&this.setSelectedOption(e)}));else{const t=this.value[0],i=this.findFilteredOption(t);-1!==i&&(this.setSelectedOption(t),this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.focusedIndex=i,this.focusedGroupIndex=-1)}}isOptionObject(e){return"object"==typeof e&&null!==e}setOptionCustomContent(){if(this.isOptGroup){const e=[...this.querySelectorAll("optgroup")],t=[];for(const i of e){const e=i.getAttribute("label"),s=[...i.querySelectorAll("[slot]")];t.push({isLabel:"true",[this.optionValue]:e,groupName:e});for(const i of s){const s=i.getAttribute("aria-label"),o=i.getAttribute("display-value"),r=i.getAttribute("slot");s&&o&&t.push({[this.optionId]:s,[this.optionValue]:o,isLabel:"false",groupName:e,slot:r})}}this.options=t}else this.customContent=[...this.querySelectorAll("[slot]")],this.customContent&&this.customContent.length?this.options=this.customContent.map((e=>{const t=e.getAttribute("aria-label"),i=e.getAttribute("display-value");if(t&&i)return{[this.optionId]:t,[this.optionValue]:i}})):this.options=[]}getOptionValue(e){return this.isOptionObject(e)?e[this.optionValue]:e}getOptionGroupName(e){return null==e?void 0:e.groupName}getOptionId(e){return this.isOptionObject(e)?e[this.optionId]:e}getFocusedItem(e){if(e>=0)return this.filteredOptions[e]}setupEvents(){document.addEventListener("click",this.handleOutsideClick),this.addEventListener("remove-all-selected",this.removeAllSelected),this.addEventListener("selected-changed",this.selectedChange)}teardownEvents(){document.removeEventListener("click",this.handleOutsideClick),this.removeEventListener("remove-all-selected",this.removeAllSelected),this.removeEventListener("selected-changed",this.selectedChange)}setVisualListbox(e){this.expanded=e}setGroupList(e){this.groupExpandedList.includes(e)?(this.groupExpandedList.splice(this.groupExpandedList.indexOf(e),1),this.groupExpandedList=[...this.groupExpandedList]):this.searchItem?this.groupExpandedList.push(e):this.groupExpandedList=[e]}findSelectedOption(e){return this.optionId&&e?this.selectedOptions.findIndex((t=>t&&t[this.optionId]===e[this.optionId])):this.selectedOptions.indexOf(e)}findOptionIndex(e){const t=e.composedPath();if(this.checkForVirtualScroll()){let e="";return[...this.lists].forEach((i=>{t.includes(i)&&(e=i.id)})),this.filteredOptions.findIndex((t=>this.getOptionId(t)===e))}return[...this.lists].findIndex((e=>t.includes(e)))}checkSelectedOptions(){if(this.checkForVirtualScroll()){const e=this.selectedOptions.map((e=>this.getOptionId(e))),t=[...this.lists].filter((e=>"selectAll"!==e.id));null==t||t.forEach((t=>{e.includes(t.id)?(this.isMulti&&(null==t||t.setAttribute("aria-checked","true")),null==t||t.setAttribute("aria-selected","true")):this.isMulti&&(null==t||t.setAttribute("aria-checked","false"))}))}}unCheckAllOptions(){var e;this.checkForVirtualScroll()&&this.isMulti&&(null===(e=[...this.lists])||void 0===e||e.forEach((e=>{"selectAll"!==(null==e?void 0:e.id)&&(null==e||e.setAttribute("aria-checked","false"))})))}setSelectedOption(e){this.isMulti||(this.selectedOptions=[]);const t=this.findSelectedOption(e);if(-1!==t){const e=this.selectedOptions[t];this.selectedOptions.splice(t,1),this.notifySelectedChange({value:e,selected:this.selectedOptions})}else this.selectedOptions.push(e),this.notifySelectedChange({value:e,selected:this.selectedOptions});this.checkSelectedOptions(),this.isMulti&&this.allowSelectAll&&(this.isSelectAllChecked=this.isSelectAllSelected()),this.requestUpdate()}filterOptions(e){if(this.preventFilter)return this.searchItem=!1,this.options;if(e&&e.length){const t=this.options.filter((t=>this.isOptGroup&&"string"!=typeof t&&"true"===t.isLabel?t:(this.isCustomContent?this.getOptionId(t):this.getOptionValue(t)).toLowerCase().includes(e.toLowerCase())));return this.isOptGroup?this.handleGroupFilter(t):t}return this.searchItem=!1,this.options}getListBoxVerticalPadding(){if(this.listBox){const e=window.getComputedStyle(this.listBox,null),t=parseInt(e.getPropertyValue("padding-top"))+parseInt(e.getPropertyValue("padding-bottom"));if(!isNaN(t))return t+2}return 10}resizeListbox(){this.updateOnNextFrame((()=>{var e;let t=0,i=0,s=0;const o=this.getListBoxVerticalPadding();if(this.lists){const e=this.checkForVirtualScroll()?[...this.lists].filter((e=>0!==e.offsetHeight)):[...this.lists];t=e.slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0),s=this.checkForVirtualScroll()&&this.allowSelectAll?e.slice(1,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0):e.slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)}if(this.labels&&(i=[...this.labels].slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)),this.listBox&&(this.listBox.style.maxHeight=`${t+i+o}px`),this.virtualizer&&(this.virtualizer.style.height=`${s+o}px`),this.showCustomError||this.showLoader){const t=null===(e=this.listBox)||void 0===e?void 0:e.querySelector("[slot]");this.listBox&&t&&(this.listBox.style.height=`${t.clientHeight+o}px`,this.listBox.style.maxHeight=`${t.clientHeight+o}px`)}}))}setInputValue(e=""){this.input.value=e}updateOnNextFrame(e){requestAnimationFrame(e)}unCheckedAllOptions(){this.isMulti&&(this.lists.forEach(((e,t)=>this.unCheckedOption(t))),this.isSelectAllChecked=!1)}unCheckedOption(e){this.isMulti&&(this.lists[e].setAttribute("aria-checked","false"),this.notifySelectedChange({value:this.filteredOptions[e],selected:this.selectedOptions}))}checkAllOptions(){this.isMulti&&this.lists.forEach(((e,t)=>this.checkOption(t)))}checkOption(e){this.isMulti&&(this.lists[e].setAttribute("aria-checked","true"),this.notifySelectedChange({value:this.filteredOptions[e],selected:this.selectedOptions}))}isSelectAllSelected(){return this.selectedOptions.length===this.options.length}setFocusOnHost(e){this.setFocus&&this.setFocus(e)}isOptionFocused(e){return this.focusedIndex===e}getAriaState(e){return this.isOptionFocused(e)}scrollToOption(){var e,t;let i=0;const{top:s,bottom:o}=this.listBox.getBoundingClientRect(),r=this.lists[this.focusedIndex],n=null===(e=this.lists[this.focusedIndex+1]||r)||void 0===e?void 0:e.getBoundingClientRect(),a=null===(t=this.lists[this.focusedIndex-1]||r)||void 0===t?void 0:t.getBoundingClientRect();(null==n?void 0:n.bottom)>o?i=n.bottom-o+2:(null==a?void 0:a.top)<s&&(i=a.top-s-2),this.updateOnNextFrame((()=>{this.listBox.scrollTop+=i}))}getCustomContentName(e){const t=this.options.indexOf(e);if(this.isOptGroup){const e=this.options[t];if(e&&"string"!=typeof e)return e.slot}else if(-1!==t)return this.customContent[t].slot}setInputSelectionRange(e,t){this.input.setSelectionRange(e,t)}isOptionChecked(e){return-1!==this.findSelectedOption(e)?"true":"false"}getInputSelection(){return this.input.selectionStart}canMultiSelect(){return 0===this.getInputSelection()&&0!==this.selectedOptions.length&&this.isMulti}removeMultiTag(){this.selected&&this.multiSelected.forEach((e=>{const t=this.selected[e];t&&t.hasAttribute("selected")&&this.removeSelected(this.selectedOptions[e])}))}unselectedAllMultiTag(){this.selected&&this.selected.forEach((e=>e.removeAttribute("selected"))),this.multiSelectedIndex=-1}findLastMultiSelected(){return this.selected[this.multiSelectedIndex]}toggleMultiSelectedTag(e,t){e&&e.toggleAttribute("selected",t)}selectMultiTag(e){if(this.canMultiSelect()){if(!e){this.multiSelected=[];const e=this.findLastMultiSelected();this.toggleMultiSelectedTag(e,!1)}this.multiSelectedIndex<=0?this.multiSelectedIndex=this.selectedOptions.length-1:this.multiSelectedIndex--,this.multiSelected.push(this.multiSelectedIndex);const t=this.findLastMultiSelected();this.toggleMultiSelectedTag(t,!0)}}handleListClick(e){return f(this,void 0,void 0,(function*(){this.dispatchEvent(new CustomEvent("selected-changed",{detail:{event:e}})),yield this.updateComplete,this.isMulti?this.setVisualListbox(!0):this.setVisualListbox(!1),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}))}handleSelectAll(){return f(this,void 0,void 0,(function*(){this.isSelectAllChecked=!this.isSelectAllChecked,this.isSelectAllChecked?(this.selectedOptions=[...this.options],this.checkAllOptions()):(this.selectedOptions=[],this.unCheckedAllOptions()),yield this.updateComplete,this.setVisualListbox(!0),this.notifySelectedChange({selected:this.selectedOptions})}))}handleInputKeyUp(e){switch(e.code){case o.Uz.Escape:break;case o.Uz.Backspace:this.setFocusOnHost(!0),this.setVisualListbox(!0),this.resizeListbox(),this.removeMultiTag();break;case o.Uz.ArrowLeft:this.isMulti&&(e.shiftKey?this.selectMultiTag(!0):this.selectMultiTag(!1));break;default:this.isMulti&&this.unselectedAllMultiTag()}}handleInput(e){const t=e.target.value;this.inputValue=t.trim(),this.notifyInputValueChanged(t.trim())}removeAllSelected(){var e;this.focusedIndex=-1,this.focusedGroupIndex=-1,this.selectedOptions=[],this.inputValue="",this.setInputValue(),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,""),this.setVisualListbox(!1),this.unCheckedAllOptions(),this.setSelectedAttribute(void 0),this.updateOnNextFrame((()=>{this.input.focus()})),this.notifySelectedChange({selected:this.selectedOptions})}removeSelected(e){const t=this.findSelectedOption(e),i=this.filteredOptions.indexOf(e);-1!==i&&this.unCheckedOption(i),-1!==t&&(this.selectedOptions.splice(t,1),this.requestUpdate()),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}selectedChange(e){var t;const{event:i}=e.detail;let s=this.findOptionIndex(i);if(-1!==s){this.focusedIndex=this.allowSelectAll&&this.checkForVirtualScroll()?s+1:s,this.isMulti&&this.allowSelectAll&&!this.checkForVirtualScroll()&&(s-=1);const e=this.getFocusedItem(s);this.setSelectedAttribute(e),e&&(this.setSelectedOption(e),this.isMulti?this.isMulti&&this.allowSelectAll&&(this.isSelectAllChecked=this.isSelectAllSelected()):(this.setInputValue(this.getOptionValue(e)),null===(t=this.input)||void 0===t||t.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(e))))}}setSelectedAttribute(e){var t;let i="";e&&(i=this.getOptionId(e)),null===(t=this.lists)||void 0===t||t.forEach(((e,t)=>{(null==e?void 0:e.id)===i?null==e||e.setAttribute("selected","true"):null==e||e.setAttribute("selected","false")}))}shouldChangeButton(){const e=this.input&&this.input.value.length>0&&!this.noClearIcon||this.isMulti&&this.selectedOptions.length&&!this.noClearIcon;return e&&document.dispatchEvent(new CustomEvent("on-widget-update")),e}setCustomValue(){this.optionId||this.optionValue||(this.options=[...this.options,this.inputValue],this.setSelectedOption(this.inputValue),this.isMulti||this.updateOnNextFrame((()=>{var e;this.focusedIndex=this.filteredOptions.length-1;const t=this.getFocusedItem(this.focusedIndex);t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))})),this.dispatchEvent(new CustomEvent("custom-value-add",{composed:!0,bubbles:!0,detail:{value:this.inputValue}}))),this.inputValue=""}handleGroupFocus(){this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.filteredGroupOptions.length>0&&-1===this.focusedGroupIndex&&(this.focusedGroupIndex=this.filteredGroupOptions.findIndex((e=>"string"!=typeof e&&e.groupName===this.groupExpandedList[0]))),this.updateOnNextFrame((()=>{-1===this.focusedGroupIndex||!this.allowSelectAll&&this.focusedGroupIndex>=this.filteredGroupOptions.length-1||this.allowSelectAll&&this.focusedGroupIndex>=this.filteredGroupOptions.length?this.focusedGroupIndex=0:this.focusedGroupIndex++})),this.focusedIndex=-1}handleInputKeyDown(e){var t,i;switch(e.code){case o.Uz.Backspace:this.focusedIndex=-1;break;case o.Uz.Tab:case o.Uz.Enter:if(this.setFocusOnHost(!0),this.expanded&&this.updateOnNextFrame((()=>{var e;const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);this.allowCustomValue&&this.input&&this.input.value.length&&-1===this.findFilteredOption(this.inputValue)?this.setCustomValue():(t&&(this.setSelectedAttribute(t),this.setSelectedOption(t),this.showSelectedCount||(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))),this.isMulti&&this.allowSelectAll&&0===this.focusedIndex&&this.handleSelectAll())})),this.setVisualListbox(!1),e.code===o.Uz.Tab&&this.isMulti)return;break;case o.Uz.ArrowDown:if(this.isOptGroup&&0===this.filteredOptions.length)return void this.handleGroupFocus();this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.updateOnNextFrame((()=>{var e;-1===this.focusedIndex||!this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length-1||this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length?this.focusedIndex=0:this.focusedIndex++;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],!this.showSelectedCount&&t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t))),this.focusedGroupIndex=-1}));break;case o.Uz.ArrowUp:if(this.isOptGroup&&0===this.filteredOptions.length)return void this.handleGroupFocus();this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.updateOnNextFrame((()=>{var e;this.focusedIndex<=0?this.focusedIndex=this.allowSelectAll?this.filteredOptions.length:this.filteredOptions.length-1:this.focusedIndex--;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],t&&!this.showSelectedCount&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.focusedGroupIndex=-1)}));break;case o.Uz.ArrowLeft:case o.Uz.ArrowRight:e.stopPropagation();break;case o.Uz.Escape:this.setFocusOnHost(!0),this.expanded?(e.stopPropagation(),this.setVisualListbox(!1)):(this.setInputValue(),null===(t=this.input)||void 0===t||t.setAttribute(o.iw.AriaActivedescendant,""),this.focusedIndex=-1,this.focusedGroupIndex=-1,this.removeAllSelected(),this.setSelectedAttribute(void 0));break;case o.Uz.Home:this.setInputSelectionRange(0,0);break;case o.Uz.End:{const{length:e}=this.inputValue;this.setInputSelectionRange(e,e)}break;case o.Uz.Space:if(this.isMulti&&this.expanded){e.preventDefault();const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);t&&(this.setSelectedOption(t),this.setSelectedAttribute(t),this.showSelectedCount||(this.setInputValue(),null===(i=this.input)||void 0===i||i.setAttribute(o.iw.AriaActivedescendant,""))),0===this.focusedIndex&&this.allowSelectAll&&this.handleSelectAll()}this.expanded=!0}}handleGroupLabelKeyDown(e,t){switch(e.code){case o.Uz.Tab:this.handleGroupFocus();break;case o.Uz.Enter:case o.Uz.Space:-1!==this.focusedGroupIndex?this.toggleGroupListBox(e,t.value):(this.setFocusOnHost(!0),this.setVisualListbox(!1),this.updateOnNextFrame((()=>{var e;const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);t&&(this.setSelectedOption(t),this.showSelectedCount||(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1})))),this.isMulti&&this.allowSelectAll&&0===this.focusedIndex&&this.handleSelectAll()})));break;case o.Uz.ArrowDown:if(0===this.filteredOptions.length)return;this.setFocusOnHost(!1),this.updateOnNextFrame((()=>{var e;-1===this.focusedIndex||!this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length-1||this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length?this.focusedIndex=0:this.focusedIndex++;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],!this.showSelectedCount&&t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t))),this.focusedGroupIndex=-1}));break;case o.Uz.ArrowUp:if(this.isOptGroup&&0===this.filteredOptions.length)return;this.setFocusOnHost(!1),this.updateOnNextFrame((()=>{var e;this.focusedIndex<=0?this.focusedIndex=this.allowSelectAll?this.filteredOptions.length:this.filteredOptions.length-1:this.focusedIndex--;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],t&&!this.showSelectedCount&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))}));break;case o.Uz.Escape:this.focusedGroupIndex=-1,this.setVisualListbox(!1),this.setFocusOnHost(!0),this.input.focus();break;default:this.setVisualListbox(!0)}}toggleVisualListBox(e){var t,i;if(!this.readOnly){if(e.target.classList.contains("md-combobox-listbox"))e.target.focus();else if("md-icon"===e.target.localName){const s=null===(i=null===(t=e.target.parentElement)||void 0===t?void 0:t.parentElement)||void 0===i?void 0:i.parentElement;if(s){const e=s.querySelector(".md-combobox-listbox");(0,b.setTimeout)((()=>{e.focus()}),10)}}this.expanded?this.setVisualListbox(!1):(this.dispatchEvent(new CustomEvent("combobox-on-expand",{composed:!0,bubbles:!0})),this.notifySearchResultCount(),this.setVisualListbox(!0)),this.input.focus(),this.setGroupList(""),this.focusedGroupIndex=-1}}toggleGroupListBox(e,t){e.stopPropagation(),this.focusedGroupIndex=this.filteredGroupOptions.findIndex((e=>"string"!=typeof e&&e.groupName===t)),this.setGroupList(t),this.resizeListbox()}handleRemoveAll(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("remove-all-selected"))}connectedCallback(){super.connectedCallback(),this.setupEvents(),this.querySelector("optgroup")&&(this.isOptGroup=!0)}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}static get styles(){return[l.A,y.A]}get listItemOptionMap(){return{"md-combobox-multiselect":this.isMulti,compact:this.compact,"md-combobox-dropdown-arrow":this.isDropdownArrow}}get filteredOptions(){return this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue).filter((e=>!this.isOptGroup||("string"!=typeof e&&this.groupExpandedList.includes(this.getOptionGroupName(e))?"false"===e.isLabel:void 0)))}get filteredGroupOptions(){return this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue).filter((e=>!this.isOptGroup||("string"!=typeof e?"true"===e.isLabel:void 0)))}get comboBoxTemplateClassMap(){return{[`md-combobox--${this.shape}`]:!!this.shape,"md-combobox-searchable":this.searchable,"md-combobox-has-leading-icon":this.searchable||this.showFilterIcon,"md-new-combobox":this.newMomentum,[`md-${this.messageType}`]:!!this.messageType,"md-combobox-readonly":this.readOnly,"md-combobox-compact":this.compact,"md-combobox-dropdown-arrow":this.isDropdownArrow}}searchIconTemplate(){return this.leadingIconTemplate("search-bold","search-icon")}filterIconTemplate(){return this.leadingIconTemplate("filter-bold","filter-icon")}leadingIconTemplate(e,t){return d.html`
|
|
29
|
+
`}};h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"checked",null),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"indeterminate",null),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,l.property)({type:String})],t.prototype,"label",void 0),h([(0,l.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,l.query)(".checkbox-input")],t.prototype,"input",void 0),t=h([(0,a.w)("md-checkbox")],t),e.ELEMENT=t}(s||(s={}))},4863:e=>{e.exports=b},4893:e=>{e.exports=D},4928:(e,t,i)=>{i.d(t,{ComboBox:()=>s}),i(20109),i(61200);var s,o=i(90195),r=i(3001),n=i(31890),a=i(66677),l=i(26272),d=i(41488),h=i(40333),p=i(23968),c=i(97822),u=i(22818),m=i(8229),y=i(86635),b=i(97103),v=i(46795),g=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},f=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){class t{determineMessageType(e){return e.reduce(((e,t)=>"error"===t?e:t.type),"")}filterMessagesByType(e,t){return e.reduce(((e,i)=>i.type===t?e.concat(i.message):e),[])}}e.MessageController=t;let i=class extends((0,r.yC)(d.LitElement)){constructor(){super(...arguments),this._focusedIndex=-1,this._focusedGroupIndex=-1,this.label="Options",this.options=[],this.customOptions=[],this.placeholder="",this.isMulti=!1,this.useVirtualScroll=!1,this.disabled=!1,this.ordered=!1,this.expanded=!1,this.groupExpandedList=[],this.searchItem=!1,this.compact=!1,this.noClearIcon=!1,this.selectWhenInFocus=!1,this.selectedOptions=[],this.visibleOptions=8,this.optionId="",this.optionValue="",this.isCustomContent=!1,this.searchable=!1,this.shape="none",this.value=[],this.inputValue="",this.allowCustomValue=!1,this.autofocus=!1,this.resultsTextLocalization="No Results",this.optionsTextLocalization="No Options",this.trimSpace=!1,this.invalid=!1,this.invalidText="",this.ariaLabel="",this.searchResultAriaLabel="",this.ariaLabelForComboBox="",this.clearAriaLabel="Clear",this.arrowAriaLabel="Expand",this.clearIconHeight="auto",this.allTextLocalization="All",this.selectAllTextLocalization="Select All",this.selectedTextLocalization="Selected",this.allowSelectAll=!1,this.showCustomError=!1,this.showLoader=!1,this.showSelectedCount=!1,this.popupChevronAriaHidden="true",this.newMomentum=!1,this.showFilterIcon=!1,this.preventFilter=!1,this.isDropdownArrow=!1,this.comboboxId="",this.helpText="",this.messageArr=[],this.htmlId="",this.readOnly=!1,this.messageController=new t,this.isOptGroup=!1,this.isSelectAllChecked=!1,this.multiSelectedIndex=-1,this.multiSelected=[],this.customContent=[],this.notifySelectedChange=(0,a.sg)((e=>{this.dispatchEvent(new CustomEvent("change-selected",{composed:!0,bubbles:!0,detail:e}))}),0),this.handleGroupFilter=e=>{const t=e.filter((e=>{if("string"!=typeof e&&"true"===e.isLabel)return e.groupName}));return this.searchItem=!0,this.groupExpandedList=t.map((e=>{if("string"!=typeof e)return e.groupName})),e.filter((t=>"string"==typeof t||"true"!==t.isLabel||!!e.find((e=>{if("string"!=typeof t&&"string"!=typeof e)return t.groupName===e.groupName&&"false"===e.isLabel}))))},this.notifyInputValueChanged=(0,a.sg)((e=>{this.dispatchEvent(new CustomEvent("combobox-input",{composed:!0,bubbles:!0,detail:{value:e}})),this.notifySearchResultCount(),this.focusedGroupIndex=0,requestAnimationFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}),250),this.handleOutsideClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||(this.setVisualListbox(!1),this.unselectedAllMultiTag()))}}get focusedIndex(){return this._focusedIndex}set focusedIndex(e){this.updateFocusedIndex(e)}updateFocusedIndex(e){var t;const i=this._focusedIndex;if(this.checkForVirtualScroll()){let i;i=this.allowSelectAll?0===e?"selectAll":this.getOptionId(this.filteredOptions[e-1]):this.getOptionId(this.filteredOptions[e]);const s=this.lists?null===(t=[...this.lists])||void 0===t?void 0:t.find((e=>0!==e.offsetHeight&&e.id===i)):"";this.lists&&[...this.lists].forEach((e=>{e.toggleAttribute("focused",!1)})),s&&(null==s||s.toggleAttribute("focused",!0))}else if(this.lists){const t=this.lists[i];t&&t.toggleAttribute("focused",!1);const s=this.lists[e];s&&s.toggleAttribute("focused",!0)}this._focusedIndex=e,this.requestUpdate("focusedIndex",i)}get focusedGroupIndex(){return this._focusedGroupIndex}set focusedGroupIndex(e){const t=this._focusedGroupIndex;if(this.labels&&0!==this.labels.length){const i=this.labels[t];i&&i.toggleAttribute("focused",!1);const s=this.labels[e];s&&(s.toggleAttribute("focused",!0),s.focus())}this._focusedGroupIndex=e,this.requestUpdate("focusedGroupIndex",t)}get messageType(){return this.messageArr.length>0?this.messageController.determineMessageType(this.messageArr):null}get messages(){return this.messageType?this.messageController.filterMessagesByType(this.messageArr,this.messageType):null}notifySearchResultCount(){if(this.searchResultAriaLabel){const e=/{{.*?}}/g;this.ariaLabelForComboBox=this.searchResultAriaLabel.replace(e,this.filteredOptions.length.toString())}else this.ariaLabel?this.ariaLabelForComboBox=`${this.ariaLabel}, ${this.filteredOptions.length} results found.`:this.ariaLabelForComboBox=`ComboBox Element, ${this.filteredOptions.length} results found.`}firstUpdated(e){this.ariaLabelForComboBox=this.ariaLabel?this.ariaLabel:"ComboBox Element",super.firstUpdated(e),this.isCustomContent&&(this.optionId="id",this.optionValue="value",this.setOptionCustomContent()),this.setInitialValue()}updated(e){super.updated(e),e.has("expanded")&&(this.expanded?(this.resizeListbox(),this.checkSelectedOptions()):this.unCheckAllOptions()),e.has("focusedIndex")&&this.focusedIndex>=0&&(this.checkForVirtualScroll()||this.scrollToOption()),e.has("value")&&0===this.selectedOptions.length&&this.setInitialValue(),e.has("customOptions")&&this.isCustomContent&&(this.setOptionCustomContent(),this.resizeListbox()),e.has("showCustomError")&&this.resizeListbox(),e.has("showLoader")&&this.resizeListbox(),e.has("searchItem")&&this.resizeListbox()}handleFocusIn(e){var t;this.disabled&&!this.readOnly||(this.noClearIcon&&(requestAnimationFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1})),this.selectWhenInFocus&&this.input.select()),null===(t=super.handleFocusIn)||void 0===t||t.call(this,e)),this.dispatchEvent(new CustomEvent("combobox-focus-in",{composed:!0,bubbles:!0}))}handleFocusOut(e){var t;null===(t=super.handleFocusOut)||void 0===t||t.call(this,e),this.dispatchEvent(new CustomEvent("combobox-focus-out",{composed:!0,bubbles:!0}))}findFilteredOption(e){return this.isOptionObject(e)?this.filteredOptions.findIndex((t=>this.getOptionId(t)===this.getOptionId(e)&&this.getOptionValue(t)===this.getOptionValue(e))):this.filteredOptions.indexOf(e)}setInitialValue(){var e;if(this.value.length)if(this.isMulti)this.value.forEach((e=>{-1!==this.findFilteredOption(e)&&this.setSelectedOption(e)}));else{const t=this.value[0],i=this.findFilteredOption(t);-1!==i&&(this.setSelectedOption(t),this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.focusedIndex=i,this.focusedGroupIndex=-1)}}isOptionObject(e){return"object"==typeof e&&null!==e}setOptionCustomContent(){if(this.isOptGroup){const e=[...this.querySelectorAll("optgroup")],t=[];for(const i of e){const e=i.getAttribute("label"),s=[...i.querySelectorAll("[slot]")];t.push({isLabel:"true",[this.optionValue]:e,groupName:e});for(const i of s){const s=i.getAttribute("aria-label"),o=i.getAttribute("display-value"),r=i.getAttribute("slot");s&&o&&t.push({[this.optionId]:s,[this.optionValue]:o,isLabel:"false",groupName:e,slot:r})}}this.options=t}else this.customContent=[...this.querySelectorAll("[slot]")],this.customContent&&this.customContent.length?this.options=this.customContent.map((e=>{const t=e.getAttribute("aria-label"),i=e.getAttribute("display-value");if(t&&i)return{[this.optionId]:t,[this.optionValue]:i}})):this.options=[]}getOptionValue(e){return this.isOptionObject(e)?e[this.optionValue]:e}getOptionGroupName(e){return null==e?void 0:e.groupName}getOptionId(e){return this.isOptionObject(e)?e[this.optionId]:e}getFocusedItem(e){if(e>=0)return this.filteredOptions[e]}setupEvents(){document.addEventListener("click",this.handleOutsideClick),this.addEventListener("remove-all-selected",this.removeAllSelected),this.addEventListener("selected-changed",this.selectedChange)}teardownEvents(){document.removeEventListener("click",this.handleOutsideClick),this.removeEventListener("remove-all-selected",this.removeAllSelected),this.removeEventListener("selected-changed",this.selectedChange)}setVisualListbox(e){this.expanded=e}setGroupList(e){this.groupExpandedList.includes(e)?(this.groupExpandedList.splice(this.groupExpandedList.indexOf(e),1),this.groupExpandedList=[...this.groupExpandedList]):this.searchItem?this.groupExpandedList.push(e):this.groupExpandedList=[e]}findSelectedOption(e){return this.optionId&&e?this.selectedOptions.findIndex((t=>t&&t[this.optionId]===e[this.optionId])):this.selectedOptions.indexOf(e)}findOptionIndex(e){const t=e.composedPath();if(this.checkForVirtualScroll()){let e="";return[...this.lists].forEach((i=>{t.includes(i)&&(e=i.id)})),this.filteredOptions.findIndex((t=>this.getOptionId(t)===e))}return[...this.lists].findIndex((e=>t.includes(e)))}checkSelectedOptions(){if(this.checkForVirtualScroll()){const e=this.selectedOptions.map((e=>this.getOptionId(e))),t=[...this.lists].filter((e=>"selectAll"!==e.id));null==t||t.forEach((t=>{e.includes(t.id)?(this.isMulti&&(null==t||t.setAttribute("aria-checked","true")),null==t||t.setAttribute("aria-selected","true")):this.isMulti&&(null==t||t.setAttribute("aria-checked","false"))}))}}unCheckAllOptions(){var e;this.checkForVirtualScroll()&&this.isMulti&&(null===(e=[...this.lists])||void 0===e||e.forEach((e=>{"selectAll"!==(null==e?void 0:e.id)&&(null==e||e.setAttribute("aria-checked","false"))})))}setSelectedOption(e){this.isMulti||(this.selectedOptions=[]);const t=this.findSelectedOption(e);if(-1!==t){const e=this.selectedOptions[t];this.selectedOptions.splice(t,1),this.notifySelectedChange({value:e,selected:this.selectedOptions})}else this.selectedOptions.push(e),this.notifySelectedChange({value:e,selected:this.selectedOptions});this.checkSelectedOptions(),this.isMulti&&this.allowSelectAll&&(this.isSelectAllChecked=this.isSelectAllSelected()),this.requestUpdate()}filterOptions(e){if(this.preventFilter)return this.searchItem=!1,this.options;if(e&&e.length){const t=this.options.filter((t=>this.isOptGroup&&"string"!=typeof t&&"true"===t.isLabel?t:(this.isCustomContent?this.getOptionId(t):this.getOptionValue(t)).toLowerCase().includes(e.toLowerCase())));return this.isOptGroup?this.handleGroupFilter(t):t}return this.searchItem=!1,this.options}getListBoxVerticalPadding(){if(this.listBox){const e=window.getComputedStyle(this.listBox,null),t=parseInt(e.getPropertyValue("padding-top"))+parseInt(e.getPropertyValue("padding-bottom"));if(!isNaN(t))return t+2}return 10}resizeListbox(){this.updateOnNextFrame((()=>{var e;let t=0,i=0,s=0;const o=this.getListBoxVerticalPadding();if(this.lists){const e=this.checkForVirtualScroll()?[...this.lists].filter((e=>0!==e.offsetHeight)):[...this.lists];t=e.slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0),s=this.checkForVirtualScroll()&&this.allowSelectAll?e.slice(1,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0):e.slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)}if(this.labels&&(i=[...this.labels].slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)),this.listBox&&(this.listBox.style.maxHeight=`${t+i+o}px`),this.virtualizer&&(this.virtualizer.style.height=`${s+o}px`),this.showCustomError||this.showLoader){const t=null===(e=this.listBox)||void 0===e?void 0:e.querySelector("[slot]");this.listBox&&t&&(this.listBox.style.height=`${t.clientHeight+o}px`,this.listBox.style.maxHeight=`${t.clientHeight+o}px`)}}))}setInputValue(e=""){this.input.value=e}updateOnNextFrame(e){requestAnimationFrame(e)}unCheckedAllOptions(){this.isMulti&&(this.lists.forEach(((e,t)=>this.unCheckedOption(t))),this.isSelectAllChecked=!1)}unCheckedOption(e){this.isMulti&&(this.lists[e].setAttribute("aria-checked","false"),this.notifySelectedChange({value:this.filteredOptions[e],selected:this.selectedOptions}))}checkAllOptions(){this.isMulti&&this.lists.forEach(((e,t)=>this.checkOption(t)))}checkOption(e){this.isMulti&&(this.lists[e].setAttribute("aria-checked","true"),this.notifySelectedChange({value:this.filteredOptions[e],selected:this.selectedOptions}))}isSelectAllSelected(){return this.selectedOptions.length===this.options.length}setFocusOnHost(e){this.setFocus&&this.setFocus(e)}isOptionFocused(e){return this.focusedIndex===e}getAriaState(e){return this.isOptionFocused(e)}scrollToOption(){var e,t;let i=0;const{top:s,bottom:o}=this.listBox.getBoundingClientRect(),r=this.lists[this.focusedIndex],n=null===(e=this.lists[this.focusedIndex+1]||r)||void 0===e?void 0:e.getBoundingClientRect(),a=null===(t=this.lists[this.focusedIndex-1]||r)||void 0===t?void 0:t.getBoundingClientRect();(null==n?void 0:n.bottom)>o?i=n.bottom-o+2:(null==a?void 0:a.top)<s&&(i=a.top-s-2),this.updateOnNextFrame((()=>{this.listBox.scrollTop+=i}))}getCustomContentName(e){const t=this.options.indexOf(e);if(this.isOptGroup){const e=this.options[t];if(e&&"string"!=typeof e)return e.slot}else if(-1!==t)return this.customContent[t].slot}setInputSelectionRange(e,t){this.input.setSelectionRange(e,t)}isOptionChecked(e){return-1!==this.findSelectedOption(e)?"true":"false"}getInputSelection(){return this.input.selectionStart}canMultiSelect(){return 0===this.getInputSelection()&&0!==this.selectedOptions.length&&this.isMulti}removeMultiTag(){this.selected&&this.multiSelected.forEach((e=>{const t=this.selected[e];t&&t.hasAttribute("selected")&&this.removeSelected(this.selectedOptions[e])}))}unselectedAllMultiTag(){this.selected&&this.selected.forEach((e=>e.removeAttribute("selected"))),this.multiSelectedIndex=-1}findLastMultiSelected(){return this.selected[this.multiSelectedIndex]}toggleMultiSelectedTag(e,t){e&&e.toggleAttribute("selected",t)}selectMultiTag(e){if(this.canMultiSelect()){if(!e){this.multiSelected=[];const e=this.findLastMultiSelected();this.toggleMultiSelectedTag(e,!1)}this.multiSelectedIndex<=0?this.multiSelectedIndex=this.selectedOptions.length-1:this.multiSelectedIndex--,this.multiSelected.push(this.multiSelectedIndex);const t=this.findLastMultiSelected();this.toggleMultiSelectedTag(t,!0)}}handleListClick(e){return f(this,void 0,void 0,(function*(){this.dispatchEvent(new CustomEvent("selected-changed",{detail:{event:e}})),yield this.updateComplete,this.isMulti?this.setVisualListbox(!0):this.setVisualListbox(!1),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}))}handleSelectAll(){return f(this,void 0,void 0,(function*(){this.isSelectAllChecked=!this.isSelectAllChecked,this.isSelectAllChecked?(this.selectedOptions=[...this.options],this.checkAllOptions()):(this.selectedOptions=[],this.unCheckedAllOptions()),yield this.updateComplete,this.setVisualListbox(!0),this.notifySelectedChange({selected:this.selectedOptions})}))}handleInputKeyUp(e){switch(e.code){case o.Uz.Escape:break;case o.Uz.Backspace:this.setFocusOnHost(!0),this.setVisualListbox(!0),this.resizeListbox(),this.removeMultiTag();break;case o.Uz.ArrowLeft:this.isMulti&&(e.shiftKey?this.selectMultiTag(!0):this.selectMultiTag(!1));break;default:this.isMulti&&this.unselectedAllMultiTag()}}handleInput(e){const t=e.target.value;this.inputValue=t.trim(),this.notifyInputValueChanged(t.trim())}removeAllSelected(){var e;this.focusedIndex=-1,this.focusedGroupIndex=-1,this.selectedOptions=[],this.inputValue="",this.setInputValue(),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,""),this.setVisualListbox(!1),this.unCheckedAllOptions(),this.setSelectedAttribute(void 0),this.updateOnNextFrame((()=>{this.input.focus()})),this.notifySelectedChange({selected:this.selectedOptions})}removeSelected(e){const t=this.findSelectedOption(e),i=this.filteredOptions.indexOf(e);-1!==i&&this.unCheckedOption(i),-1!==t&&(this.selectedOptions.splice(t,1),this.requestUpdate()),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1}))}selectedChange(e){var t;const{event:i}=e.detail;let s=this.findOptionIndex(i);if(-1!==s){this.focusedIndex=this.allowSelectAll&&this.checkForVirtualScroll()?s+1:s,this.isMulti&&this.allowSelectAll&&!this.checkForVirtualScroll()&&(s-=1);const e=this.getFocusedItem(s);this.setSelectedAttribute(e),e&&(this.setSelectedOption(e),this.isMulti?this.isMulti&&this.allowSelectAll&&(this.isSelectAllChecked=this.isSelectAllSelected()):(this.setInputValue(this.getOptionValue(e)),null===(t=this.input)||void 0===t||t.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(e))))}}setSelectedAttribute(e){var t;let i="";e&&(i=this.getOptionId(e)),null===(t=this.lists)||void 0===t||t.forEach(((e,t)=>{(null==e?void 0:e.id)===i?null==e||e.setAttribute("selected","true"):null==e||e.setAttribute("selected","false")}))}shouldChangeButton(){const e=this.input&&this.input.value.length>0&&!this.noClearIcon||this.isMulti&&this.selectedOptions.length&&!this.noClearIcon;return e&&document.dispatchEvent(new CustomEvent("on-widget-update")),e}setCustomValue(){this.optionId||this.optionValue||(this.options=[...this.options,this.inputValue],this.setSelectedOption(this.inputValue),this.isMulti||this.updateOnNextFrame((()=>{var e;this.focusedIndex=this.filteredOptions.length-1;const t=this.getFocusedItem(this.focusedIndex);t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))})),this.dispatchEvent(new CustomEvent("custom-value-add",{composed:!0,bubbles:!0,detail:{value:this.inputValue}}))),this.inputValue=""}handleGroupFocus(){this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.filteredGroupOptions.length>0&&-1===this.focusedGroupIndex&&(this.focusedGroupIndex=this.filteredGroupOptions.findIndex((e=>"string"!=typeof e&&e.groupName===this.groupExpandedList[0]))),this.updateOnNextFrame((()=>{-1===this.focusedGroupIndex||!this.allowSelectAll&&this.focusedGroupIndex>=this.filteredGroupOptions.length-1||this.allowSelectAll&&this.focusedGroupIndex>=this.filteredGroupOptions.length?this.focusedGroupIndex=0:this.focusedGroupIndex++})),this.focusedIndex=-1}handleInputKeyDown(e){var t,i;switch(e.code){case o.Uz.Backspace:this.focusedIndex=-1;break;case o.Uz.Tab:case o.Uz.Enter:if(this.setFocusOnHost(!0),this.expanded&&this.updateOnNextFrame((()=>{var e;const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);this.allowCustomValue&&this.input&&this.input.value.length&&-1===this.findFilteredOption(this.inputValue)?this.setCustomValue():(t&&(this.setSelectedAttribute(t),this.setSelectedOption(t),this.showSelectedCount||(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))),this.isMulti&&this.allowSelectAll&&0===this.focusedIndex&&this.handleSelectAll())})),this.setVisualListbox(!1),e.code===o.Uz.Tab&&this.isMulti)return;break;case o.Uz.ArrowDown:if(this.isOptGroup&&0===this.filteredOptions.length)return void this.handleGroupFocus();this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.updateOnNextFrame((()=>{var e;-1===this.focusedIndex||!this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length-1||this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length?this.focusedIndex=0:this.focusedIndex++;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],!this.showSelectedCount&&t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t))),this.focusedGroupIndex=-1}));break;case o.Uz.ArrowUp:if(this.isOptGroup&&0===this.filteredOptions.length)return void this.handleGroupFocus();this.setFocusOnHost(!1),this.expanded||this.setVisualListbox(!0),this.updateOnNextFrame((()=>{var e;this.focusedIndex<=0?this.focusedIndex=this.allowSelectAll?this.filteredOptions.length:this.filteredOptions.length-1:this.focusedIndex--;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],t&&!this.showSelectedCount&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.focusedGroupIndex=-1)}));break;case o.Uz.ArrowLeft:case o.Uz.ArrowRight:e.stopPropagation();break;case o.Uz.Escape:this.setFocusOnHost(!0),this.expanded?(e.stopPropagation(),this.setVisualListbox(!1)):(this.setInputValue(),null===(t=this.input)||void 0===t||t.setAttribute(o.iw.AriaActivedescendant,""),this.focusedIndex=-1,this.focusedGroupIndex=-1,this.removeAllSelected(),this.setSelectedAttribute(void 0));break;case o.Uz.Home:this.setInputSelectionRange(0,0);break;case o.Uz.End:{const{length:e}=this.inputValue;this.setInputSelectionRange(e,e)}break;case o.Uz.Space:if(this.isMulti&&this.expanded){e.preventDefault();const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);t&&(this.setSelectedOption(t),this.setSelectedAttribute(t),this.showSelectedCount||(this.setInputValue(),null===(i=this.input)||void 0===i||i.setAttribute(o.iw.AriaActivedescendant,""))),0===this.focusedIndex&&this.allowSelectAll&&this.handleSelectAll()}this.expanded=!0}}handleGroupLabelKeyDown(e,t){switch(e.code){case o.Uz.Tab:this.handleGroupFocus();break;case o.Uz.Enter:case o.Uz.Space:-1!==this.focusedGroupIndex?this.toggleGroupListBox(e,t.value):(this.setFocusOnHost(!0),this.setVisualListbox(!1),this.updateOnNextFrame((()=>{var e;const t=this.getFocusedItem(this.allowSelectAll?this.focusedIndex-1:this.focusedIndex);t&&(this.setSelectedOption(t),this.showSelectedCount||(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)),this.updateOnNextFrame((()=>{this.input.focus(),this.focusedGroupIndex=-1})))),this.isMulti&&this.allowSelectAll&&0===this.focusedIndex&&this.handleSelectAll()})));break;case o.Uz.ArrowDown:if(0===this.filteredOptions.length)return;this.setFocusOnHost(!1),this.updateOnNextFrame((()=>{var e;-1===this.focusedIndex||!this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length-1||this.allowSelectAll&&this.focusedIndex>=this.filteredOptions.length?this.focusedIndex=0:this.focusedIndex++;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],!this.showSelectedCount&&t&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t))),this.focusedGroupIndex=-1}));break;case o.Uz.ArrowUp:if(this.isOptGroup&&0===this.filteredOptions.length)return;this.setFocusOnHost(!1),this.updateOnNextFrame((()=>{var e;this.focusedIndex<=0?this.focusedIndex=this.allowSelectAll?this.filteredOptions.length:this.filteredOptions.length-1:this.focusedIndex--;const t=this.getFocusedItem(this.focusedIndex);this.groupExpandedList=[this.getOptionGroupName(t)],t&&!this.showSelectedCount&&(this.setInputValue(this.getOptionValue(t)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(t)))}));break;case o.Uz.Escape:this.focusedGroupIndex=-1,this.setVisualListbox(!1),this.setFocusOnHost(!0),this.input.focus();break;default:this.setVisualListbox(!0)}}toggleVisualListBox(e){var t,i;if(!this.readOnly){if(e.target.classList.contains("md-combobox-listbox"))e.target.focus();else if("md-icon"===e.target.localName){const s=null===(i=null===(t=e.target.parentElement)||void 0===t?void 0:t.parentElement)||void 0===i?void 0:i.parentElement;if(s){const e=s.querySelector(".md-combobox-listbox");(0,b.setTimeout)((()=>{e.focus()}),10)}}this.expanded?this.setVisualListbox(!1):(this.dispatchEvent(new CustomEvent("combobox-on-expand",{composed:!0,bubbles:!0})),this.notifySearchResultCount(),this.setVisualListbox(!0)),this.input.focus(),this.setGroupList(""),this.focusedGroupIndex=-1}}toggleGroupListBox(e,t){e.stopPropagation(),this.focusedGroupIndex=this.filteredGroupOptions.findIndex((e=>"string"!=typeof e&&e.groupName===t)),this.setGroupList(t),this.resizeListbox()}handleRemoveAll(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("remove-all-selected"))}connectedCallback(){super.connectedCallback(),this.setupEvents(),this.querySelector("optgroup")&&(this.isOptGroup=!0)}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}static get styles(){return[l.A,v.A]}get listItemOptionMap(){return{"md-combobox-multiselect":this.isMulti,compact:this.compact,"md-combobox-dropdown-arrow":this.isDropdownArrow}}get filteredOptions(){return this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue).filter((e=>!this.isOptGroup||("string"!=typeof e&&this.groupExpandedList.includes(this.getOptionGroupName(e))?"false"===e.isLabel:void 0)))}get filteredGroupOptions(){return this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue).filter((e=>!this.isOptGroup||("string"!=typeof e?"true"===e.isLabel:void 0)))}get comboBoxTemplateClassMap(){return{[`md-combobox--${this.shape}`]:!!this.shape,"md-combobox-searchable":this.searchable,"md-combobox-has-leading-icon":this.searchable||this.showFilterIcon,"md-new-combobox":this.newMomentum,[`md-${this.messageType}`]:!!this.messageType,"md-combobox-readonly":this.readOnly,"md-combobox-compact":this.compact,"md-combobox-dropdown-arrow":this.isDropdownArrow}}searchIconTemplate(){return this.leadingIconTemplate("search-bold","search-icon")}filterIconTemplate(){return this.leadingIconTemplate("filter-bold","filter-icon")}leadingIconTemplate(e,t){return d.html`
|
|
30
30
|
<md-icon
|
|
31
31
|
name=${e}
|
|
32
32
|
class=${t}
|
|
@@ -70,10 +70,10 @@
|
|
|
70
70
|
class="md-combobox-button arrow-down"
|
|
71
71
|
part="combobox-button-arrow"
|
|
72
72
|
aria-expanded=${this.expanded}
|
|
73
|
-
aria-label=${(0,
|
|
73
|
+
aria-label=${(0,c.ifDefined)("true"===this.popupChevronAriaHidden?void 0:this.arrowAriaLabel)}
|
|
74
74
|
aria-controls="md-combobox-listbox"
|
|
75
75
|
tabindex="-1"
|
|
76
|
-
aria-hidden=${(0,
|
|
76
|
+
aria-hidden=${(0,c.ifDefined)("true"===this.popupChevronAriaHidden?"true":void 0)}
|
|
77
77
|
?disabled=${this.disabled}
|
|
78
78
|
?readonly=${this.readOnly}
|
|
79
79
|
@click=${this.toggleVisualListBox}
|
|
@@ -85,7 +85,7 @@
|
|
|
85
85
|
type="button"
|
|
86
86
|
class="md-combobox-button"
|
|
87
87
|
part="combobox-button-arrow"
|
|
88
|
-
aria-label=${(0,
|
|
88
|
+
aria-label=${(0,c.ifDefined)("true"===this.popupChevronAriaHidden?void 0:this.arrowAriaLabel)}
|
|
89
89
|
aria-controls="md-combobox-listbox"
|
|
90
90
|
tabindex="-1"
|
|
91
91
|
aria-hidden=${"true"===this.popupChevronAriaHidden?"true":"false"}
|
|
@@ -101,10 +101,10 @@
|
|
|
101
101
|
<div
|
|
102
102
|
id="selectAll"
|
|
103
103
|
part="combobox-option"
|
|
104
|
-
class="md-combobox-option ${(0,
|
|
104
|
+
class="md-combobox-option ${(0,p.classMap)(this.listItemOptionMap)}"
|
|
105
105
|
@click=${this.handleSelectAll}
|
|
106
106
|
aria-label="${this.selectAllTextLocalization}${e}"
|
|
107
|
-
aria-checked=${(0,
|
|
107
|
+
aria-checked=${(0,c.ifDefined)(this.isSelectAllChecked?"true":void 0)}
|
|
108
108
|
role="checkbox"
|
|
109
109
|
>
|
|
110
110
|
<span class="select-option" aria-hidden="true">
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
</div>
|
|
116
116
|
`}getSelctedCount(){return 0===this.selectedOptions.length?h.nothing:this.isSelectAllSelected()?d.html` <span class="selected-count">${this.allTextLocalization}</span> `:d.html`
|
|
117
117
|
<span class="selected-count">${this.selectedOptions.length} ${this.selectedTextLocalization}</span>
|
|
118
|
-
`}checkForVirtualScroll(){return this.useVirtualScroll&&!this.isOptGroup}rangeChanged(){this.updateFocusedIndex(this.focusedIndex),this.checkSelectedOptions(),this.resizeListbox()}getCustomErrorContent(){const e=this.querySelector("[slot]")||this.shadowRoot.querySelector("[slot]");return document.createRange().createContextualFragment(`${null==e?void 0:e.outerHTML}`)}getCustomContent(e){const t=this.getCustomContentName(e);if(this.isOptGroup){const e=[...this.querySelectorAll("[slot]")].find((e=>e.slot===t));return e?document.createRange().createContextualFragment(`${e.outerHTML}`):d.html``}return d.html` <slot name=${(0,
|
|
118
|
+
`}checkForVirtualScroll(){return this.useVirtualScroll&&!this.isOptGroup}rangeChanged(){this.updateFocusedIndex(this.focusedIndex),this.checkSelectedOptions(),this.resizeListbox()}getCustomErrorContent(){const e=this.querySelector("[slot]")||this.shadowRoot.querySelector("[slot]");return document.createRange().createContextualFragment(`${null==e?void 0:e.outerHTML}`)}getCustomContent(e){const t=this.getCustomContentName(e);if(this.isOptGroup){const e=[...this.querySelectorAll("[slot]")].find((e=>e.slot===t));return e?document.createRange().createContextualFragment(`${e.outerHTML}`):d.html``}return d.html` <slot name=${(0,c.ifDefined)(t)}></slot> `}renderGroupLabelHeader(e,t){return d.html`
|
|
119
119
|
<div
|
|
120
120
|
part="group-label"
|
|
121
121
|
class="group-label"
|
|
@@ -142,7 +142,7 @@
|
|
|
142
142
|
aria-label="${this.isCustomContent?this.getOptionId(e):this.getOptionValue(e)}${o}"
|
|
143
143
|
tabindex="-1"
|
|
144
144
|
@click=${this.handleListClick}
|
|
145
|
-
aria-checked=${(0,
|
|
145
|
+
aria-checked=${(0,c.ifDefined)(this.isMulti?this.isOptionChecked.call(this,e):void 0)}
|
|
146
146
|
>
|
|
147
147
|
${this.isMulti?d.html`
|
|
148
148
|
<span class="select-option" aria-hidden="true">
|
|
@@ -155,7 +155,7 @@
|
|
|
155
155
|
</div>
|
|
156
156
|
`}inputTitle(){return this.isMulti?this.selectedOptions.length>0?`${this.selectedOptions.length} ${this.selectedTextLocalization}`:this.placeholder:this.selectedOptions.length>0?this.getOptionValue(this.selectedOptions[0]):this.placeholder}helpTextTemplate(){return this.helpText?d.html`
|
|
157
157
|
<md-help-text
|
|
158
|
-
class="help-text ${(0,
|
|
158
|
+
class="help-text ${(0,p.classMap)({disabled:this.disabled,newMomentum:this.newMomentum})}"
|
|
159
159
|
.message=${this.helpText}
|
|
160
160
|
style=${(0,m.styleMap)({width:"100%"})}
|
|
161
161
|
></md-help-text>
|
|
@@ -171,13 +171,13 @@
|
|
|
171
171
|
`))}
|
|
172
172
|
</div>
|
|
173
173
|
`:h.nothing}get newArrowButtonTemplate(){return d.html`<div class="md-combobox-right-arrow">${this.arrowButtonTemplate()}</div>`}get renderNewMomentumArrow(){return d.html` ${this.isDropdownArrow?this.arrowButtonTemplate():this.newArrowButtonTemplate} `}get renderTrailingInputControls(){const e=this.shouldChangeButton();return this.newMomentum?e&&this.isDropdownArrow?d.html`${this.clearButtonTemplate()}`:e?d.html`${this.clearButtonTemplate()} ${this.renderNewMomentumArrow}`:this.renderNewMomentumArrow:this.compact?d.html`${h.nothing}`:d.html`${e?this.clearButtonTemplate():this.arrowButtonTemplate()}`}render(){return d.html`
|
|
174
|
-
<div part="combobox" class="md-combobox md-combobox-list ${(0,
|
|
175
|
-
<div part="group" class="group ${(0,
|
|
174
|
+
<div part="combobox" class="md-combobox md-combobox-list ${(0,p.classMap)(this.comboBoxTemplateClassMap)}">
|
|
175
|
+
<div part="group" class="group ${(0,p.classMap)(this.listItemOptionMap)}">
|
|
176
176
|
${this.searchable?this.searchIconTemplate():this.showFilterIcon?this.filterIconTemplate():h.nothing}
|
|
177
177
|
<div class="md-combobox__multiwrap" part="multiwrap">
|
|
178
178
|
${this.isMulti?this.isMulti&&!this.showSelectedCount?(0,u.repeat)(this.selectedOptions,(e=>this.selectedOptionTemplate(e))):this.getSelctedCount():h.nothing}
|
|
179
179
|
<input
|
|
180
|
-
id=${(0,
|
|
180
|
+
id=${(0,c.ifDefined)(this.comboboxId||void 0)}
|
|
181
181
|
class="md-combobox-listbox"
|
|
182
182
|
type="text"
|
|
183
183
|
role="combobox"
|
|
@@ -190,7 +190,7 @@
|
|
|
190
190
|
?readonly=${this.allowSelectAll||this.readOnly}
|
|
191
191
|
?disabled=${this.disabled}
|
|
192
192
|
?autofocus=${this.autofocus}
|
|
193
|
-
title=${(0,
|
|
193
|
+
title=${(0,c.ifDefined)(this.inputTitle())}
|
|
194
194
|
.value=${this.inputValue}
|
|
195
195
|
@click=${this.toggleVisualListBox}
|
|
196
196
|
@input=${this.handleInput}
|
|
@@ -216,12 +216,12 @@
|
|
|
216
216
|
part="combobox-options"
|
|
217
217
|
aria-label=${this.ariaLabel||this.label}
|
|
218
218
|
style=${this.addStyle()}
|
|
219
|
-
role=${(0,
|
|
219
|
+
role=${(0,c.ifDefined)(this.checkForVirtualScroll()?void 0:"list")}
|
|
220
220
|
>
|
|
221
221
|
${this.isMulti&&this.allowSelectAll&&this.expanded?this.getSelectAllOption():h.nothing}
|
|
222
222
|
${this.checkForVirtualScroll()?0!==this.options.length&&this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue).length>0?d.html`
|
|
223
223
|
<div class="virtual-scroll" @rangechange=${this.rangeChanged}>
|
|
224
|
-
${(0,
|
|
224
|
+
${(0,y.scroll)({items:this.filterOptions(this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue),renderItem:(e,t)=>this.renderItem(e,t||0),useShadowDOM:!1,scrollToIndex:{index:this.focusedIndex,position:-1===this.focusedIndex?"start":"center"}})}
|
|
225
225
|
</div>
|
|
226
226
|
`:h.nothing:this.renderWithoutVirtualScroll()}
|
|
227
227
|
${this.options.length&&0===this.filteredOptions.length&&this.inputValue&&!this.allowCustomValue?d.html`
|
|
@@ -238,7 +238,7 @@
|
|
|
238
238
|
`}
|
|
239
239
|
</div>
|
|
240
240
|
${this.invalid?d.html`
|
|
241
|
-
<div part="message" class="md-combobox-error ${(0,
|
|
241
|
+
<div part="message" class="md-combobox-error ${(0,p.classMap)({"md-new-combobox-error":this.newMomentum})}">
|
|
242
242
|
<md-help-text .message=${this.invalidText} messageType="error"></md-help-text>
|
|
243
243
|
</div>
|
|
244
244
|
`:h.nothing}
|
|
@@ -251,7 +251,7 @@
|
|
|
251
251
|
>
|
|
252
252
|
${this.label?n.html` <span>${this.label}</span> `:n.html` <slot></slot> `}
|
|
253
253
|
</label>
|
|
254
|
-
`}};d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"theme",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"radioLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"checkboxLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"toggleSwitchLabel",void 0),d([(0,n.property)({type:String})],t.prototype,"htmlFor",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"active",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"indeterminate",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"secondaryLabel",void 0),t=d([(0,o.w)("md-label")],t),e.ELEMENT=t}(s||(s={}))},6779:(e,t,i)=>{i.d(t,{AccordionItem:()=>s}),i(61200);var s,o=i(3001),r=i(31890),n=i(59164),a=i(26272),l=i(41488),d=i(97822),h=i(33866),
|
|
254
|
+
`}};d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"theme",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"radioLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"checkboxLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"toggleSwitchLabel",void 0),d([(0,n.property)({type:String})],t.prototype,"htmlFor",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"active",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"indeterminate",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"secondaryLabel",void 0),t=d([(0,o.w)("md-label")],t),e.ELEMENT=t}(s||(s={}))},6779:(e,t,i)=>{i.d(t,{AccordionItem:()=>s}),i(61200);var s,o=i(3001),r=i(31890),n=i(59164),a=i(26272),l=i(41488),d=i(97822),h=i(33866),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.yC)(l.LitElement)){constructor(){super(...arguments),this._expanded=!1,this._level=3,this.uniqueId=(0,n.O)("accordion-item"),this.label="",this.disabled=!1}get expanded(){return this._expanded}set expanded(e){const t=this._expanded;this._expanded=e,e?(this.notifyAccordionFocus(),this.notifyExpandedHeader()):this.notifyCollapsedHeader(),this.requestUpdate("expanded",t)}get level(){return this._level}set level(e){const t=this.level;e<1||e>6?(console.warn("Please set appropriate section heading level"),this._level=3):this._level=e,this.requestUpdate("level",t)}notifyExpandedHeader(){this.dispatchEvent(new CustomEvent("accordion-item-expanded",{composed:!0,bubbles:!0,detail:{id:this.uniqueId}}))}notifyCollapsedHeader(){this.dispatchEvent(new CustomEvent("accordion-item-collapsed",{composed:!0,bubbles:!0,detail:{id:this.uniqueId}}))}notifyAccordionFocus(){this.dispatchEvent(new CustomEvent("focus-visible",{composed:!0,bubbles:!0}))}firstUpdated(e){super.firstUpdated(e),this.setAttribute("id",this.uniqueId)}static get styles(){return[a.A,h.A]}handleMouseDown(e){this.disabled||this.dispatchEvent(new CustomEvent("accordion-item-click",{detail:{srcEvent:e},composed:!0,bubbles:!0}))}handleKeyDown(e){this.disabled||this.dispatchEvent(new CustomEvent("accordion-item-keydown",{detail:{srcEvent:e},bubbles:!0,composed:!0}))}render(){return l.html`
|
|
255
255
|
<div class="md-accordion-item">
|
|
256
256
|
<div role="heading" aria-level=${this.level} class="md-accordion-header" part="accordion-header">
|
|
257
257
|
<button
|
|
@@ -288,7 +288,7 @@
|
|
|
288
288
|
<slot></slot>
|
|
289
289
|
</div>
|
|
290
290
|
</div>
|
|
291
|
-
`}};
|
|
291
|
+
`}};p([(0,l.property)({type:String})],t.prototype,"label",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"expanded",null),p([(0,l.property)({type:Number,reflect:!0})],t.prototype,"level",null),p([(0,l.query)(".md-accordion-expander")],t.prototype,"header",void 0),t=p([(0,r.w)("md-accordion-item")],t),e.ELEMENT=t}(s||(s={}))},6963:e=>{e.exports=O},8229:e=>{e.exports=t},10654:(e,t,i)=>{i.d(t,{Card:()=>s}),i(96798),i(99850),i(61200),i(68490),i(66245),i(11323),i(83192);var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(22818),d=i(90195),h=i(70630),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.title="title",this.subtitle="",this.id="",this.info="",this.infoAriaLabel="Card Info",this.menuAriaLabel="Card Menu",this.menuOptions=[]}static get styles(){return[r.A,h.A]}handleCardClick(){this.dispatchEvent(new CustomEvent("card-click",{detail:{id:this.id},bubbles:!0,composed:!0}))}handleCardKeyDown(e){e.code!==d.Uz.Enter&&e.code!==d.Uz.Space||this.dispatchEvent(new CustomEvent("card-keydown",{detail:{id:this.id},bubbles:!0,composed:!0}))}handleCardMenuEvent(e,t){e.stopPropagation();const i=t.toLowerCase();this.dispatchEvent(new CustomEvent("card-menu-click",{detail:{id:this.id,type:i},bubbles:!0,composed:!0}))}handleCardMenuKeyDown(e,t){e.preventDefault(),this.dispatchEvent(new CustomEvent("card-menu-keydown",{detail:{id:this.id,type:t.toLowerCase(),keyCode:e.code},bubbles:!0,composed:!0}))}render(){return n.html`
|
|
292
292
|
<div
|
|
293
293
|
class="md-card"
|
|
294
294
|
id="${this.id}"
|
|
@@ -355,14 +355,14 @@
|
|
|
355
355
|
<slot name="footer"> </slot>
|
|
356
356
|
</div>
|
|
357
357
|
</div>
|
|
358
|
-
`}};
|
|
358
|
+
`}};p([(0,n.property)({type:String})],t.prototype,"title",void 0),p([(0,n.property)({type:String})],t.prototype,"subtitle",void 0),p([(0,n.property)({type:String})],t.prototype,"id",void 0),p([(0,n.property)({type:String})],t.prototype,"info",void 0),p([(0,n.property)({type:String,attribute:"info-aria-label"})],t.prototype,"infoAriaLabel",void 0),p([(0,n.property)({type:String,attribute:"menu-aria-label"})],t.prototype,"menuAriaLabel",void 0),p([(0,n.property)({type:Array})],t.prototype,"menuOptions",void 0),t=p([(0,o.w)("md-card")],t),e.ELEMENT=t}(s||(s={}))},10984:(e,t,i)=>{i.d(t,{DatePickerWeek:()=>s}),i(16754);var s,o=i(31890),r=i(81625),n=i(26272),a=i(41488),l=i(14974),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.startOfWeekDay=(0,r.tB)(),this.viewAnchorMonth=(0,r.tB)().month,this.filterParams=void 0,this.datePickerProps=void 0,this.renderDays=()=>[0,1,2,3,4,5,6].map((e=>{const t=(0,r.fi)(this.startOfWeekDay,e);return a.html`
|
|
359
359
|
<md-datepicker-day
|
|
360
360
|
.viewAnchorMonth=${this.viewAnchorMonth}
|
|
361
361
|
.day=${t}
|
|
362
362
|
.filterParams=${this.filterParams}
|
|
363
363
|
.datePickerProps=${this.datePickerProps}
|
|
364
364
|
></md-datepicker-day>
|
|
365
|
-
`}))}static get styles(){return[n.A,l.A]}render(){return a.html` <div class="md-datepicker__week">${this.renderDays()}</div> `}};d([(0,a.property)({attribute:!1})],t.prototype,"startOfWeekDay",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"viewAnchorMonth",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),t=d([(0,o.w)("md-datepicker-week")],t),e.ELEMENT=t}(s||(s={}))},11323:(e,t,i)=>{i.d(t,{MenuOverlay:()=>o});var s,o,r=i(90195),n=i(31890),a=i(28373),l=i(66677),d=i(22962),h=i.n(d),
|
|
365
|
+
`}))}static get styles(){return[n.A,l.A]}render(){return a.html` <div class="md-datepicker__week">${this.renderDays()}</div> `}};d([(0,a.property)({attribute:!1})],t.prototype,"startOfWeekDay",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"viewAnchorMonth",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),t=d([(0,o.w)("md-datepicker-week")],t),e.ELEMENT=t}(s||(s={}))},11323:(e,t,i)=>{i.d(t,{MenuOverlay:()=>o});var s,o,r=i(90195),n=i(31890),a=i(28373),l=i(66677),d=i(22962),h=i.n(d),p=i(84157),c=i.n(p),u=i(68250),m=i.n(u),y=i(69371),b=i.n(y),v=i(4863),g=i(41488),f=i(97822),w=i(16366),C=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},x=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){e.small="260px",e.large="370px"}(s||(s={})),function(e){let t=class extends((0,a.d)(g.LitElement)){constructor(){super(...arguments),this._isOpen=!1,this.size="large",this.maxHeight="",this.customWidth="",this.showArrow=!1,this.disabled=!1,this.placement="bottom",this.allowHoverToggle=!1,this.ariaRole="menu",this.ariaLabel="",this.isDatePicker=!1,this.overlayOffset=15,this.keepOpenOnWindowBlur=!1,this.popperInstance=null,this.triggerElement=null,this.shouldWrapFocus=()=>"dialog"===this.ariaRole,this.updateActiveMenuOverlayOpened=t=>{var i;this===t.target&&(null===(i=e.ELEMENT.activeOverlay)||void 0===i||i.push(t.target))},this.updateActiveMenuOverlayClosed=t=>{var i,s;const o=e.ELEMENT.activeOverlay.indexOf(t.target);this===t.target&&-1!==o&&(e.ELEMENT.activeOverlay.splice(o,1),e.ELEMENT.activeOverlay.length>0?(null===(i=e.ELEMENT.activeOverlay[e.ELEMENT.activeOverlay.length-1])||void 0===i||i.setFocusableElements(),null===(s=e.ELEMENT.activeOverlay[e.ELEMENT.activeOverlay.length-1])||void 0===s||s.focusOnNestedTrigger(this.triggerElement)):this.setFocusableElements())},this.handleTriggerClick=()=>{this.toggleOverlay()},this.setOverlay=(0,l.sg)((e=>{this.disabled||(this.isOpen=e)}),100),this.expandPopup=()=>{this.setOverlay(!0)},this.collapsePopup=()=>{this.setOverlay(!1)},this.handleOutsideOverlayKeydown=t=>x(this,void 0,void 0,(function*(){let i=!1;const s=t.composedPath();s.length&&(i=!!s.find((e=>e===this)),!i)||!this.overlayContainer||t.code!==r.Uz.Escape||(t.preventDefault(),(e.ELEMENT.activeOverlay.length>0?e.ELEMENT.activeOverlay[e.ELEMENT.activeOverlay.length-1]:void 0)===this&&(this.isOpen=!1,yield this.updateComplete,this.focusOnTrigger()))})),this.handleTriggerKeyDown=e=>x(this,void 0,void 0,(function*(){switch(e.code){case r.Uz.Space:case r.Uz.Enter:e.preventDefault(),this.toggleOverlay(),this.isOpen||(yield this.updateComplete,this.focusOnTrigger())}})),this.handleOutsideOverlayClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||this.preventClickOutside||(this.isOpen=!1))}}get isOpen(){return this._isOpen}set isOpen(e){const t=this._isOpen;this._isOpen=e,this.handleInstance(e),this.overlayContainer&&this.overlayContainer.toggleAttribute("data-show",e),this.requestUpdate("isOpen",t)}renderMaxHeight(){return this.maxHeight?`max-height: ${this.maxHeight};`:"max-height: calc(100vh - 48px);"}renderOverflowY(){return this.isDatePicker?"overflow-y: visible;":"overflow-y: auto;"}renderWidth(){return this.customWidth?`width: ${this.customWidth};`:"small"===this.size?`width: ${s.small};`:`width: ${s.large};`}getStyles(){return g.html`
|
|
366
366
|
<style>
|
|
367
367
|
:host .md-menu-overlay .overlay-content {
|
|
368
368
|
${this.renderMaxHeight()};
|
|
@@ -370,7 +370,7 @@
|
|
|
370
370
|
${this.renderOverflowY()};
|
|
371
371
|
}
|
|
372
372
|
</style>
|
|
373
|
-
`}connectedCallback(){super.connectedCallback(),this.handleWindowBlurEvent=this.handleWindowBlurEvent.bind(this),window.addEventListener("blur",this.handleWindowBlurEvent),document.addEventListener("click",this.handleOutsideOverlayClick),document.addEventListener("keydown",this.handleOutsideOverlayKeydown),this.addEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.addEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.handleOutsideOverlayClick),document.removeEventListener("keydown",this.handleOutsideOverlayKeydown),window.removeEventListener("blur",this.handleWindowBlurEvent),this.removeEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.removeEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed),this.triggerElement&&(this.triggerElement.removeEventListener("click",this.handleTriggerClick),this.triggerElement.removeEventListener("keydown",this.handleTriggerKeyDown),this.allowHoverToggle&&(this.triggerElement.removeEventListener("mouseenter",this.expandPopup),this.triggerElement.removeEventListener("mouseleave",this.collapsePopup),this.overlayContainer.removeEventListener("mouseenter",this.expandPopup),this.overlayContainer.removeEventListener("mouseleave",this.collapsePopup)),this.triggerElement=null)}checkIsInputField(e){var t;return"md-input"===(null===(t=null==e?void 0:e.tagName)||void 0===t?void 0:t.toLowerCase())}updateTriggerElementAriaExpanded(){this.triggerElement&&(this.isOpen?this.triggerElement.setAttribute("aria-expanded","true"):this.triggerElement.removeAttribute("aria-expanded"))}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return
|
|
373
|
+
`}connectedCallback(){super.connectedCallback(),this.handleWindowBlurEvent=this.handleWindowBlurEvent.bind(this),window.addEventListener("blur",this.handleWindowBlurEvent),document.addEventListener("click",this.handleOutsideOverlayClick),document.addEventListener("keydown",this.handleOutsideOverlayKeydown),this.addEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.addEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.handleOutsideOverlayClick),document.removeEventListener("keydown",this.handleOutsideOverlayKeydown),window.removeEventListener("blur",this.handleWindowBlurEvent),this.removeEventListener("menu-overlay-open",this.updateActiveMenuOverlayOpened),this.removeEventListener("menu-overlay-close",this.updateActiveMenuOverlayClosed),this.triggerElement&&(this.triggerElement.removeEventListener("click",this.handleTriggerClick),this.triggerElement.removeEventListener("keydown",this.handleTriggerKeyDown),this.allowHoverToggle&&(this.triggerElement.removeEventListener("mouseenter",this.expandPopup),this.triggerElement.removeEventListener("mouseleave",this.collapsePopup),this.overlayContainer.removeEventListener("mouseenter",this.expandPopup),this.overlayContainer.removeEventListener("mouseleave",this.collapsePopup)),this.triggerElement=null)}checkIsInputField(e){var t;return"md-input"===(null===(t=null==e?void 0:e.tagName)||void 0===t?void 0:t.toLowerCase())}updateTriggerElementAriaExpanded(){this.triggerElement&&(this.isOpen?this.triggerElement.setAttribute("aria-expanded","true"):this.triggerElement.removeAttribute("aria-expanded"))}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return x(this,void 0,void 0,(function*(){t.firstUpdated.call(this,e),yield new Promise((e=>setTimeout(e,0))),this.trigger&&(this.triggerElement=this.trigger[0],this.triggerElement.addEventListener("click",this.handleTriggerClick),this.allowHoverToggle&&(this.triggerElement.addEventListener("mouseenter",this.expandPopup),this.triggerElement.addEventListener("mouseleave",this.collapsePopup),this.overlayContainer.addEventListener("mouseenter",this.expandPopup),this.overlayContainer.addEventListener("mouseleave",this.collapsePopup)),this.checkIsInputField(this.triggerElement)||this.triggerElement.addEventListener("keydown",this.handleTriggerKeyDown),this.triggerElement.setAttribute("aria-haspopup","true")),this.overlayContainer&&this.isOpen&&(this.handleInstance(!0),this.overlayContainer.toggleAttribute("data-show",!0)),this.arrow&&this.showArrow&&this.arrow.toggleAttribute("data-show",!0),e.has("isOpen")&&this.updateTriggerElementAriaExpanded()}))}update(e){super.update(e),e.has("isOpen")&&(this.isOpen?(this.activateFocusTrap(),document.addEventListener("menu-item-click",this.handleTriggerClick)):(this.deactivateFocusTrap(),document.removeEventListener("menu-item-click",this.handleTriggerClick)))}updated(e){super.updated(e),e.has("isOpen")&&(this.isOpen?(this.dispatchMenuOpen(),this.triggerElement&&(this.triggerElement.setAttribute("aria-expanded","true"),this.triggerElement.hasAttribute("ariaexpanded")&&this.triggerElement.setAttribute("ariaexpanded","true"))):(this.dispatchMenuClose(),this.triggerElement&&(this.triggerElement.removeAttribute("aria-expanded"),this.triggerElement.hasAttribute("ariaexpanded")&&this.triggerElement.setAttribute("ariaexpanded","false"))))}dispatchMenuOpen(){this.dispatchEvent(new CustomEvent("menu-overlay-open",{composed:!0,bubbles:!0}))}dispatchMenuClose(){this.dispatchEvent(new CustomEvent("menu-overlay-close",{composed:!0,bubbles:!0}))}handleInstance(e){e?this.create():this.destroy()}create(){this.triggerElement&&(this.popperInstance=(0,v.createPopper)(this.triggerElement,this.overlayContainer,{onFirstUpdate:()=>x(this,void 0,void 0,(function*(){var e;this.isOpen&&(null===(e=this.popperInstance)||void 0===e||e.update(),this.setFocusableElements(),yield this.updateComplete,this.focusInsideOverlay())})),placement:this.placement,modifiers:[...v.defaultModifiers,c(),m(),b(),h(),{name:"preventOverflow",options:{padding:16}},{name:"offset",options:{offset:({placement:e,reference:t})=>"left-end"===e||"right-end"===e?[t.height+t.y+3,14]:[0,this.overlayOffset]}},{name:"arrow",options:{element:this.arrow,padding:5}},{name:"computeStyles",options:{adaptive:!1}}]}))}destroy(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}toggleOverlay(){this.disabled||(this.isOpen=!this.isOpen)}focusOnTrigger(){requestAnimationFrame((()=>{var e;(null===(e=this.focusableElements)||void 0===e?void 0:e.length)&&this.focusableElements[0].focus()}))}focusInsideOverlay(){this.focusableElements&&(this.focusableElements.length>1?this.setInitialFocus(1):this.focusableElements.length&&this.setInitialFocus())}focusOnNestedTrigger(e){var t;null===(t=this.setFocusOnTrigger)||void 0===t||t.call(this,e)}handleWindowBlurEvent(){this._isOpen&&!this.keepOpenOnWindowBlur&&(this.isOpen=!1)}static get styles(){return[w.A]}render(){return g.html`
|
|
374
374
|
${this.getStyles()}
|
|
375
375
|
<div class="md-menu-overlay">
|
|
376
376
|
<slot name="menu-trigger"></slot>
|
|
@@ -387,7 +387,7 @@
|
|
|
387
387
|
</div>
|
|
388
388
|
</div>
|
|
389
389
|
</div>
|
|
390
|
-
`}};t.activeOverlay=[],
|
|
390
|
+
`}};t.activeOverlay=[],C([(0,g.property)({type:Boolean,attribute:"is-open",reflect:!0})],t.prototype,"isOpen",null),C([(0,g.property)({type:String})],t.prototype,"size",void 0),C([(0,g.property)({type:String,attribute:"max-height"})],t.prototype,"maxHeight",void 0),C([(0,g.property)({type:String,attribute:"custom-width"})],t.prototype,"customWidth",void 0),C([(0,g.property)({type:Boolean,attribute:"show-arrow"})],t.prototype,"showArrow",void 0),C([(0,g.property)({type:Boolean})],t.prototype,"disabled",void 0),C([(0,g.property)({type:String})],t.prototype,"placement",void 0),C([(0,g.property)({type:Boolean,attribute:"allow-hover-toggle"})],t.prototype,"allowHoverToggle",void 0),C([(0,g.property)({type:String})],t.prototype,"ariaRole",void 0),C([(0,g.property)({type:String})],t.prototype,"ariaLabel",void 0),C([(0,g.property)({type:Boolean,attribute:"is-date-picker"})],t.prototype,"isDatePicker",void 0),C([(0,g.property)({type:Number,attribute:"overlay-offset"})],t.prototype,"overlayOffset",void 0),C([(0,g.property)({type:Boolean,attribute:"keep-open-on-window-blur"})],t.prototype,"keepOpenOnWindowBlur",void 0),C([(0,g.query)(".overlay-container")],t.prototype,"overlayContainer",void 0),C([(0,g.query)(".overlay-arrow")],t.prototype,"arrow",void 0),C([(0,g.queryAssignedNodes)("menu-trigger",!0)],t.prototype,"trigger",void 0),t=C([(0,n.w)("md-menu-overlay")],t),e.ELEMENT=t}(o||(o={}))},12176:(e,t,i)=>{i.d(t,{Spinner:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(8229),l=i(46325),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.size=56,this.isAnimating=!1,this.animationFrameId=null}static get styles(){return[r.A,l.A]}get spinnerStyleMap(){return{width:`${this.size}px`,height:`${this.size}px`}}firstUpdated(e){super.firstUpdated(e),this.isAnimating=!0,this.startAnimation()}disconnectedCallback(){super.disconnectedCallback(),this.isAnimating=!1,this.stopAnimation()}startAnimation(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector(".md-spinner");if(!t)return;let i=null;const s=e=>{if(!this.isAnimating)return;i||(i=e);const o=e-i,r=o/1e3*360;t.style.transform=`rotate(${r}deg)`,o>=1e3&&(i=e),this.animationFrameId=requestAnimationFrame(s)};this.animationFrameId=requestAnimationFrame(s)}stopAnimation(){var e;null!==this.animationFrameId&&(cancelAnimationFrame(this.animationFrameId),this.animationFrameId=null);const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector(".md-spinner");t&&(t.style.transform="")}render(){return n.html` <i class="md-spinner" part="spinner" style=${(0,a.styleMap)(this.spinnerStyleMap)}></i> `}};d([(0,n.property)({type:Number,reflect:!0})],t.prototype,"size",void 0),d([(0,n.internalProperty)()],t.prototype,"isAnimating",void 0),t=d([(0,o.w)("md-spinner")],t),e.ELEMENT=t}(s||(s={}))},13060:e=>{e.exports=T},16643:(e,t,i)=>{i.d(t,{TAB_CROSS_WIDTH:()=>c,Tab:()=>u});var s=i(90195),o=i(3001),r=i(31890),n=i(26283),a=i(26272),l=i(41488),d=i(23968),h=i(30076),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const c=22;var u;!function(e){let t=class extends((0,o.yC)(l.LitElement)){constructor(){super(...arguments),this.tabIndex=-1,this.ariaLabel="",this.closable="",this.name="",this.isCrossVisible=!1,this.role="tab",this.type="line",this.newMomentum=!1,this.onlyIcon=!1,this.variant="ghost",this._disabled=!1,this._selected=0===this.tabIndex,this.vertical=!1,this.viewportHidden=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,e?this.tabDisabled():this.tabEnabled(),this.requestUpdate("disabled",t)}tabDisabled(){-1!==this.tabIndex&&(this.tabIndex=-1),this.setAttribute("aria-disabled","true")}tabEnabled(){-1===this.tabIndex&&this.selected&&(this.tabIndex=0),this.removeAttribute("aria-disabled")}get selected(){return this._selected}set selected(e){const t=this._selected;this._selected=e,e?(this.setAttribute("aria-selected","true"),this.notifySelectedTab()):this.removeAttribute("aria-selected"),this.requestUpdate("selected",t)}static get styles(){return[a.A,h.A]}handleClick(e){e.preventDefault(),this.id&&this.dispatchEvent(new CustomEvent("tab-click",{detail:{id:this.id},bubbles:!0,composed:!0}))}handleKeydown(e){if((0,n.o)(e.code)){if(this.disabled)return void e.preventDefault();this.handleClick(e)}}handleCrossKeydown(e){e.stopPropagation(),e.code===s.Uz.Enter&&this.handleCrossEventDispatch()}handleCrossClick(e){e.preventDefault(),!0!==this.disabled&&this.handleCrossEventDispatch()}handleCrossEventDispatch(){this.id&&("auto"===this.closable?this.dispatchEvent(new CustomEvent("tab-cross-click",{detail:{id:this.id},bubbles:!0,composed:!0})):"custom"===this.closable&&this.dispatchEvent(new CustomEvent("tab-close-click",{detail:{id:this.id,name:this.name},bubbles:!0,composed:!0})))}notifySelectedTab(){this.dispatchEvent(new CustomEvent("focus-visible",{composed:!0,bubbles:!0}))}update(e){super.update(e),e.has("disabled")&&this.disabled&&(this.selected=!1)}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this.handleClick),this.addEventListener("keydown",this.handleKeydown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("click",this.handleClick),this.removeEventListener("keydown",this.handleKeydown)}firstUpdated(e){super.firstUpdated(e)}renderCrossButton(){return l.html`
|
|
391
391
|
<md-button
|
|
392
392
|
variant="ghost"
|
|
393
393
|
size="size-none"
|
|
@@ -407,7 +407,7 @@
|
|
|
407
407
|
<slot class="tab-slot"></slot>
|
|
408
408
|
${this.isCrossVisible&&this.closable?this.renderCrossButton():""}
|
|
409
409
|
</div>
|
|
410
|
-
`}};
|
|
410
|
+
`}};p([(0,l.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),p([(0,l.property)({type:String,attribute:"aria-label"})],t.prototype,"ariaLabel",void 0),p([(0,l.property)({type:String,attribute:"closable"})],t.prototype,"closable",void 0),p([(0,l.property)({type:String,attribute:"name"})],t.prototype,"name",void 0),p([(0,l.property)({type:Boolean,attribute:"cross-visible"})],t.prototype,"isCrossVisible",void 0),p([(0,l.property)({type:String,attribute:"role",reflect:!0})],t.prototype,"role",void 0),p([(0,l.property)({type:String})],t.prototype,"type",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"newMomentum",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"onlyIcon",void 0),p([(0,l.property)({type:String})],t.prototype,"variant",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"selected",null),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"vertical",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"viewportHidden",void 0),t=p([(0,r.w)("md-tab")],t),e.ELEMENT=t}(u||(u={}))},16754:(e,t,i)=>{i.d(t,{DatePickerDay:()=>s}),i(96798);var s,o=i(31890),r=i(81625),n=i(66677),a=i(26272),l=i(41488),d=i(23968),h=i(97822),p=i(14974),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this.focused=!1,this.selected=!1,this.disabled=!1,this.day=(0,r.tB)(),this.viewAnchorMonth=void 0,this.filterParams=void 0,this.datePickerProps=void 0,this.isOutsideMonth=!1,this.isToday=!1,this.parentRangePicker=null,this.dateIsInRange=!1,this.handleClick=e=>{this.dispatchEvent(new CustomEvent("day-select",{bubbles:!0,composed:!0,detail:{date:this.day,sourceEvent:e}}))},this.isDateInRange=()=>{var e;const t=this.parentRangePicker,i=null==t?void 0:t.startDate,s=null==t?void 0:t.endDate;if(!i||!s)return!1;const o=(null===(e=this.day)||void 0===e?void 0:e.isValid)?this.day.toSQLDate():null;if(!o)return!1;const r=o>i&&o<s,n=o===i,a=o===s;return!this.isPrimarySelection()&&(r||n||a)},this.handleKeyDown=e=>{this.dispatchEvent(new CustomEvent("day-key-event",{bubbles:!0,composed:!0,detail:{date:this.day,sourceEvent:e}}))}}connectedCallback(){super.connectedCallback(),this.disabled=this.filterParams&&(0,r.t_)(this.day,this.filterParams)||!1,this.isOutsideMonth=this.day.month!==this.viewAnchorMonth,this.isToday=(0,r.ro)(this.day,(0,r.tB)()),this.selected=this.datePickerProps&&(0,r.ro)(this.datePickerProps.selected,this.day)||!1,this.focused=this.datePickerProps&&(0,r.ro)(this.datePickerProps.focused,this.day)||!1,this.parentRangePicker=(0,n.QZ)("md-date-range-picker",this)}updated(e){var t,i;super.updated(e),this.disabled=this.filterParams&&(0,r.t_)(this.day,this.filterParams)||!1,this.isOutsideMonth=this.day.month!==this.viewAnchorMonth,this.isToday=(0,r.ro)(this.day,(0,r.tB)()),this.selected=this.datePickerProps&&(0,r.ro)(this.datePickerProps.selected,this.day)||!1,this.focused=this.datePickerProps&&(0,r.ro)(this.datePickerProps.focused,this.day)||!1,this.focused&&this.button&&(null===(i=null===(t=this.button.shadowRoot)||void 0===t?void 0:t.querySelector("button"))||void 0===i||i.focus()),this.parentRangePicker&&(this.dateIsInRange=this.isDateInRange())}isPrimarySelection(){var e;return(null===(e=this.parentRangePicker)||void 0===e?void 0:e.startDate)&&void 0===this.parentRangePicker.endDate}isLeadingRangeEdge(){var e;return this===(null===(e=this.parentNode)||void 0===e?void 0:e.firstElementChild)}isEndingRangeEdge(){var e;return this===(null===(e=this.parentNode)||void 0===e?void 0:e.lastElementChild)}isStartDate(){var e;return(null===(e=this.parentRangePicker)||void 0===e?void 0:e.startDate)===this.day.toSQLDate()&&!this.isPrimarySelection()}isEndDate(){var e;return(null===(e=this.parentRangePicker)||void 0===e?void 0:e.endDate)===this.day.toSQLDate()}get getDayClassMap(){return{"md-datepicker__day--selected":this.selected,"md-datepicker__day--focus":this.focused,"md-datepicker__day--today":this.isToday,"md-datepicker__day--outside-month":this.isOutsideMonth,"md-datepicker__day--in-range":this.dateIsInRange,"md-datepicker__day--week-first":this.isLeadingRangeEdge(),"md-datepicker__day--week-last":this.isEndingRangeEdge(),"md-datepicker__day--start-date":this.isStartDate(),"md-datepicker__day--end-date":this.isEndDate()}}static get styles(){return[a.A,p.A]}render(){var e;const t=(0,r.WV)(this.day,(null===(e=this.datePickerProps)||void 0===e?void 0:e.locale)||"en").toFormat("D, dd MMMM yyyy");return l.html`
|
|
411
411
|
<md-button
|
|
412
412
|
circle
|
|
413
413
|
size=${32}
|
|
@@ -423,14 +423,14 @@
|
|
|
423
423
|
>
|
|
424
424
|
${this.day&&(0,r.pp)(this.day)}
|
|
425
425
|
</md-button>
|
|
426
|
-
`}};
|
|
426
|
+
`}};c([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"focused",void 0),c([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"selected",void 0),c([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",void 0),c([(0,l.property)({attribute:!1})],t.prototype,"day",void 0),c([(0,l.property)({attribute:!1})],t.prototype,"viewAnchorMonth",void 0),c([(0,l.property)({attribute:!1})],t.prototype,"filterParams",void 0),c([(0,l.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),c([(0,l.internalProperty)()],t.prototype,"isOutsideMonth",void 0),c([(0,l.internalProperty)()],t.prototype,"isToday",void 0),c([(0,l.internalProperty)()],t.prototype,"parentRangePicker",void 0),c([(0,l.internalProperty)()],t.prototype,"dateIsInRange",void 0),c([(0,l.query)("md-button")],t.prototype,"button",void 0),t=c([(0,o.w)("md-datepicker-day")],t),e.ELEMENT=t}(s||(s={}))},17518:e=>{e.exports=d},17814:(e,t,i)=>{i.d(t,{DatePickerMonth:()=>s}),i(10984);var s,o=i(31890),r=i(81625),n=i(26272),a=i(41488),l=i(14974),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.day=(0,r.tB)(),this.filterParams=void 0,this.datePickerProps=void 0,this.renderWeeks=()=>{var e;let t=(0,r.mK)((0,r.Mw)(this.day),null===(e=this.datePickerProps)||void 0===e?void 0:e.weekStart);const i=[],s=(0,r.tj)(this.day);do{i.push(a.html`
|
|
427
427
|
<md-datepicker-week
|
|
428
428
|
.viewAnchorMonth=${s}
|
|
429
429
|
.startOfWeekDay=${t}
|
|
430
430
|
.filterParams=${this.filterParams}
|
|
431
431
|
.datePickerProps=${this.datePickerProps}
|
|
432
432
|
></md-datepicker-week>
|
|
433
|
-
`),t=(0,r.J4)(t,1)}while((0,r.tF)(t,this.day)||i.length<6);return i}}static get styles(){return[n.A,l.A]}render(){return a.html` <div class="md-datepicker__month">${this.renderWeeks()}</div> `}};d([(0,a.property)({attribute:!1})],t.prototype,"day",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),t=d([(0,o.w)("md-datepicker-month")],t),e.ELEMENT=t}(s||(s={}))},
|
|
433
|
+
`),t=(0,r.J4)(t,1)}while((0,r.tF)(t,this.day)||i.length<6);return i}}static get styles(){return[n.A,l.A]}render(){return a.html` <div class="md-datepicker__month">${this.renderWeeks()}</div> `}};d([(0,a.property)({attribute:!1})],t.prototype,"day",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),t=d([(0,o.w)("md-datepicker-month")],t),e.ELEMENT=t}(s||(s={}))},19026:(e,t,i)=>{i.d(t,{Link:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(23968),l=i(97822),d=i(73112),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.color="",this.ariaLabel="",this.ariaRole="link",this.disabled=!1,this.inline=!1,this.inlineStyle=void 0,this.inverted=void 0,this.href="",this.tag="a",this.target="_self",this.size=void 0,this._tabIndex=0}get tabIndex(){return this._tabIndex}set tabIndex(e){const t=this._tabIndex;this._tabIndex=e,this.requestUpdate("tabIndex",t)}static get styles(){return[r.A,d.A]}render(){const e={[`md-link--${this.color}`]:this.color,"md-link--inline":this.inline,[`md-link--inline-style-${this.inlineStyle}`]:!!this.inlineStyle,[`${this.size}`]:!!this.size,inverted:!0===this.inverted,disabled:this.disabled};return n.html` ${(()=>{switch(this.tag){case"div":return n.html`
|
|
434
434
|
<div
|
|
435
435
|
class="md-link ${(0,a.classMap)(e)}"
|
|
436
436
|
tabindex=${this.tabIndex}
|
|
@@ -465,7 +465,7 @@
|
|
|
465
465
|
>
|
|
466
466
|
<slot></slot>
|
|
467
467
|
</a>
|
|
468
|
-
`}})()} `}};h([(0,n.property)({type:String,attribute:!1})],t.prototype,"color",void 0),h([(0,n.property)({type:String})],t.prototype,"ariaLabel",void 0),h([(0,n.property)({type:String})],t.prototype,"ariaRole",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inline",void 0),h([(0,n.property)({type:String,attribute:"inline-style"})],t.prototype,"inlineStyle",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inverted",void 0),h([(0,n.property)({type:String})],t.prototype,"href",void 0),h([(0,n.property)({type:String})],t.prototype,"tag",void 0),h([(0,n.property)({type:String})],t.prototype,"target",void 0),h([(0,n.property)({type:String})],t.prototype,"size",void 0),h([(0,n.property)({type:Number,attribute:"tab-index",reflect:!0})],t.prototype,"tabIndex",null),t=h([(0,o.w)("md-link")],t),e.ELEMENT=t}(s||(s={}))},19239:e=>{e.exports=P},19479:(e,t,i)=>{i.d(t,{AlertBanner:()=>s}),i(96798),i(61200);var s,o=i(31890),r=i(26283),n=i(26272),a=i(41488),l=i(40333),d=i(17518),h=i(35467),
|
|
468
|
+
`}})()} `}};h([(0,n.property)({type:String,attribute:!1})],t.prototype,"color",void 0),h([(0,n.property)({type:String})],t.prototype,"ariaLabel",void 0),h([(0,n.property)({type:String})],t.prototype,"ariaRole",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inline",void 0),h([(0,n.property)({type:String,attribute:"inline-style"})],t.prototype,"inlineStyle",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inverted",void 0),h([(0,n.property)({type:String})],t.prototype,"href",void 0),h([(0,n.property)({type:String})],t.prototype,"tag",void 0),h([(0,n.property)({type:String})],t.prototype,"target",void 0),h([(0,n.property)({type:String})],t.prototype,"size",void 0),h([(0,n.property)({type:Number,attribute:"tab-index",reflect:!0})],t.prototype,"tabIndex",null),t=h([(0,o.w)("md-link")],t),e.ELEMENT=t}(s||(s={}))},19239:e=>{e.exports=P},19479:(e,t,i)=>{i.d(t,{AlertBanner:()=>s}),i(96798),i(61200);var s,o=i(31890),r=i(26283),n=i(26272),a=i(41488),l=i(40333),d=i(17518),h=i(35467),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.type="",this.message="",this.closable=!1,this.show=!1,this.closeAriaLabel="Close Banner",this.showBannerTypeIcon=!1,this.showRefreshButton=!1,this.alignment="center"}connectedCallback(){super.connectedCallback(),this.requestUpdate("show")}onHide(){this.show=!this.show,this.dispatchEvent(new CustomEvent("alertBanner-hide")),this.requestUpdate("show")}handleKeyDown(e){const{code:t}=e;(0,r.o)(t)&&this.onHide()}get isLeadingAlignment(){return"leading"===this.alignment}static get styles(){return[n.A,h.A]}getIconForType(){switch(this.type){case"error":return"error-legacy-badge-filled";case"warning":return"warning-filled";case"success":return"check-circle-badge-filled";default:return"info-badge-filled"}}get alertBannerClassMap(){return{"md-alert-banner":!0,[`md-alert-banner--${this.type}`]:this.type,[`md-alert-banner--${this.alignment}`]:this.isLeadingAlignment,closable:this.closable}}get alertBannerTextClassMap(){return{"md-alert-banner__text":!0,leading:this.isLeadingAlignment}}get alertBannerRightClassMap(){return{trailing:this.isLeadingAlignment}}get closeButtonTemplate(){return a.html`
|
|
469
469
|
<div class="close-div">
|
|
470
470
|
<md-button
|
|
471
471
|
class="md-alert-banner__close"
|
|
@@ -500,7 +500,7 @@
|
|
|
500
500
|
${e}
|
|
501
501
|
</div>
|
|
502
502
|
`:null}
|
|
503
|
-
`}};
|
|
503
|
+
`}};p([(0,a.property)({type:String})],t.prototype,"type",void 0),p([(0,a.property)({type:String})],t.prototype,"message",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"closable",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"show",void 0),p([(0,a.property)({type:String,attribute:"close-aria-label"})],t.prototype,"closeAriaLabel",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"showBannerTypeIcon",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"showRefreshButton",void 0),p([(0,a.property)({type:String})],t.prototype,"alignment",void 0),t=p([(0,o.w)("md-alert-banner")],t),e.ELEMENT=t}(s||(s={}))},20109:(e,t,i)=>{i.d(t,{HelpText:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(23968),l=i(24977),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.message="",this.messageType=void 0,this.id="",this.ariaLive="off"}get inputMessageClassMap(){return{[`md-${this.messageType}`]:!!this.messageType}}static get styles(){return[r.A,l.A]}getIconName(){switch(this.messageType){case"success":return"check-circle-badge-filled";case"error":return"error-legacy-badge-filled";case"warning":return"warning-badge-filled";case"priority":return"info-badge-filled";default:return""}}render(){return n.html`
|
|
504
504
|
<div
|
|
505
505
|
class="md-input__message ${(0,a.classMap)(this.inputMessageClassMap)}"
|
|
506
506
|
id=${this.id}
|
|
@@ -510,7 +510,7 @@
|
|
|
510
510
|
<md-icon name="${this.getIconName()}" size="14" iconSet="momentumDesign"></md-icon>
|
|
511
511
|
<slot>${this.message}</slot>
|
|
512
512
|
</div>
|
|
513
|
-
`}};d([(0,n.property)({type:String})],t.prototype,"message",void 0),d([(0,n.property)({type:String})],t.prototype,"messageType",void 0),d([(0,n.property)({type:String})],t.prototype,"id",void 0),d([(0,n.property)({type:String})],t.prototype,"ariaLive",void 0),t=d([(0,o.w)("md-help-text")],t),e.ELEMENT=t}(s||(s={}))},20331:(e,t,i)=>{i.d(t,{ToggleSwitch:()=>
|
|
513
|
+
`}};d([(0,n.property)({type:String})],t.prototype,"message",void 0),d([(0,n.property)({type:String})],t.prototype,"messageType",void 0),d([(0,n.property)({type:String})],t.prototype,"id",void 0),d([(0,n.property)({type:String})],t.prototype,"ariaLive",void 0),t=d([(0,o.w)("md-help-text")],t),e.ELEMENT=t}(s||(s={}))},20331:(e,t,i)=>{i.d(t,{ToggleSwitch:()=>c}),i(6396);var s=i(3001),o=i(26272),r=i(31890),n=i(41488),a=i(23968),l=i(20779),d=i(97822),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const p="md-toggle-switch__accessible-description";var c;!function(e){let t=class extends((0,s.yC)(n.LitElement)){constructor(){super(...arguments),this.htmlId="",this.label="toggle",this.description=void 0,this.checked=!1,this.disabled=!1,this.small=!1,this.smaller=!1,this.alignLabel="right",this.autofocus=!1}handleClick(){this.disabled||(this.checked=!this.checked)}get toggleSwitchClassMap(){return{"md-toggle-switch--small":this.small,"md-toggle-switch--smaller":this.smaller}}switchTemplate(){return"left"===this.alignLabel?n.html`
|
|
514
514
|
<slot></slot>
|
|
515
515
|
<span
|
|
516
516
|
class="md-toggle-switch__label__container md-toggle-switch__label__container__left"
|
|
@@ -534,16 +534,16 @@
|
|
|
534
534
|
?disabled=${this.disabled}
|
|
535
535
|
?autofocus=${this.autofocus}
|
|
536
536
|
tabindex=${this.disabled?-1:0}
|
|
537
|
-
aria-describedby=${(0,d.ifDefined)(this.description?
|
|
537
|
+
aria-describedby=${(0,d.ifDefined)(this.description?p:void 0)}
|
|
538
538
|
/>
|
|
539
539
|
<md-label .htmlFor=${this.htmlId} class="md-toggle-switch__label"> ${this.switchTemplate()} </md-label>
|
|
540
540
|
${this.description&&n.html`
|
|
541
|
-
<div id=${
|
|
541
|
+
<div id=${p} class="md-toggle-switch__accessible-description">
|
|
542
542
|
${this.description}
|
|
543
543
|
</div>
|
|
544
544
|
`}
|
|
545
545
|
</div>
|
|
546
|
-
`}static get styles(){return[o.A,l.A]}};h([(0,n.property)({type:String})],t.prototype,"htmlId",void 0),h([(0,n.property)({type:String})],t.prototype,"label",void 0),h([(0,n.property)({type:String})],t.prototype,"description",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"checked",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"small",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"smaller",void 0),h([(0,n.property)({type:String})],t.prototype,"alignLabel",void 0),h([(0,n.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),t=h([(0,r.w)("md-toggle-switch")],t),e.ELEMENT=t}(
|
|
546
|
+
`}static get styles(){return[o.A,l.A]}};h([(0,n.property)({type:String})],t.prototype,"htmlId",void 0),h([(0,n.property)({type:String})],t.prototype,"label",void 0),h([(0,n.property)({type:String})],t.prototype,"description",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"checked",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"small",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"smaller",void 0),h([(0,n.property)({type:String})],t.prototype,"alignLabel",void 0),h([(0,n.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),t=h([(0,r.w)("md-toggle-switch")],t),e.ELEMENT=t}(c||(c={}))},20727:e=>{e.exports=E},22818:e=>{e.exports=p},22962:e=>{e.exports=c},23026:(e,t,i)=>{i.d(t,{Pagination:()=>s}),i(96798),i(61200);var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(4392),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this._currentPage=1,this.hasDots=!1,this.onlyDots=!1,this.noNavigation=!1,this.totalPage=0,this.visiblePage=3}get currentPage(){return this._currentPage}set currentPage(e){const t=this._currentPage;this._currentPage=e,this.notifyPageChange(t,e),this.requestUpdate("currentPage",t)}static get styles(){return[r.A,l.A]}computePrevious(e){1!==e&&e!==this.currentPage&&(this.currentPage-=1)}computeNext(e){e<=this.totalPage&&e!==this.currentPage&&(this.currentPage+=1)}computeFirst(){this.currentPage>=1&&(this.currentPage=1)}computeLast(){this.currentPage>=1&&(this.currentPage=this.totalPage)}computeCurrent(e){this.currentPage=e}notifyPageChange(e,t){this.dispatchEvent(new CustomEvent("page-change",{composed:!0,bubbles:!0,detail:{oldPage:e,newPage:t}}))}get hasPreviousPage(){return this.currentPage<=1}get hasNextPage(){return this.currentPage>=this.totalPage}computePageList(e){if(this.totalPage>this.visiblePage&&e){const[e,t,i]=[this.currentPage-1,this.currentPage,this.currentPage+1];let s=[];if(t<=this.visiblePage-1)return s=[...Array(this.visiblePage)].map(((e,t)=>1+t)),s.push("..."),s.push(this.totalPage),s;if(this.totalPage-t<=this.visiblePage-2){s=[],s.push(1),s.push("...");const e=[...Array(this.visiblePage)].map(((e,t)=>this.totalPage-this.visiblePage+1+t));return s.concat(e)}return[1,"...",e,t,i,"...",this.totalPage]}return[...Array(this.totalPage)].map(((e,t)=>1+t))}pagesTemplate(e){return this.computePageList(e).map((e=>"..."===e?n.html` <li class="page-ellipsis">${e}</li> `:n.html`
|
|
547
547
|
<li @click=${()=>this.computeCurrent(e)} aria-current=${e===this.currentPage}>
|
|
548
548
|
${e}
|
|
549
549
|
</li>
|
|
@@ -620,7 +620,7 @@
|
|
|
620
620
|
</md-button>
|
|
621
621
|
`}
|
|
622
622
|
</nav>
|
|
623
|
-
`}};d([(0,n.property)({type:Boolean,attribute:"dots"})],t.prototype,"hasDots",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"only-dots"})],t.prototype,"onlyDots",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"no-navigation"})],t.prototype,"noNavigation",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"total-page"})],t.prototype,"totalPage",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"visible-page"})],t.prototype,"visiblePage",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"current-page"})],t.prototype,"currentPage",null),t=d([(0,o.w)("md-pagination")],t),e.ELEMENT=t}(s||(s={}))},23035:e=>{e.exports=G},23184:(e,t,i)=>{i.d(t,{Dropdown:()=>s}),i(61200);var s,o=i(90195),r=i(3001),n=i(66677),a=i(26272),l=i(41488),d=i(40333),h=i(17518),c=i(97822),p=i(22818),u=i(8229),m=i(70573),v=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},b=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){class t{determineMessageType(e){return e.reduce(((e,t)=>"error"===t?e:t.type),"")}filterMessagesByType(e,t){return e.reduce(((e,i)=>i.type===t?e.concat(i.message):e),[])}}e.MessageController=t;let i=class extends((0,r.yC)(l.LitElement)){constructor(){super(...arguments),this.title="Select...",this.options=[],this.optionId="",this.optionValue="",this.defaultOption="",this.disabled=!1,this.customTabIndex=0,this.allowUnselected=!1,this.visibleOptions=8,this.newMomentum=!1,this.compact=!1,this.searchable=!1,this.searchItem=!1,this.inputValue="",this.placeholder="Select...",this.readOnly=!1,this.autofocus=!1,this.leftIcon="",this.trimSpace=!1,this.resultsTextLocalization="No Results",this.pill=!1,this.helpText="",this.messageArr=[],this.htmlId="",this.clearAriaLabel="Clear",this.clearIconHeight="auto",this.arrowAriaLabel="Expand",this.popupChevronAriaHidden="true",this.ariaLabel="",this.searchResultAriaLabel="",this.ariaLabelForDropdown="",this.renderOptions=[],this.selectedKey="",this.expanded=!1,this.focusedIndex=-1,this.messageController=new t,this.lastMaxHeight="",this.onOutsideClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||this.expanded&&this.collapse())},this.onKeyDown=e=>{switch(e.code){case o.Uz.Tab:this.expanded&&(e.stopPropagation(),this.collapse());break;case o.Uz.Space:case o.Uz.Enter:this.expanded?(this.select(),this.collapse()):this.expand();break;case o.Uz.ArrowDown:this.expanded?this.focusNext():this.expand();break;case o.Uz.ArrowUp:this.expanded?this.focusPrev():this.expand();break;case o.Uz.Home:this.expanded?this.focusFirst():this.expand();break;case o.Uz.End:this.expanded?this.focusLast():this.expand();break;case o.Uz.Escape||o.Uz.Backspace:this.expanded&&(e.stopPropagation(),this.collapse())}},this.notifyInputValueChanged=(0,n.sg)((e=>{this.dispatchEvent(new CustomEvent("dropdown-input",{composed:!0,bubbles:!0,detail:{value:e}})),this.notifySearchResultCount(),requestAnimationFrame((()=>{this.input.focus()}))}),250)}connectedCallback(){super.connectedCallback(),this.setupEvents()}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}firstUpdated(e){super.firstUpdated(e),e.forEach(((e,t)=>{if("defaultOption"===t&&this.defaultOption){const{key:e}=this.getOptionKeyValuePair(this.defaultOption);this.selectedKey=e}})),this.searchable&&this.setInitialValue()}updated(e){super.updated(e),e.forEach(((e,t)=>{if("options"===t&&this.updateRenderOptions(),"selectedKey"===t){const e=this.renderOptions.findIndex((e=>e.key===this.selectedKey));-1!==e&&(this.focusToIndex(e),this.searchable&&this.setInitialValue())}if("expanded"===t&&this.updateListDOM(),"focusedIndex"===t&&this.updateListDOM(),"defaultOption"===t&&this.defaultOption){const{key:e}=this.getOptionKeyValuePair(this.defaultOption);this.selectedKey=e}}))}notifySearchResultCount(){if(this.searchResultAriaLabel){const e=/{{.*?}}/g;this.ariaLabelForDropdown=this.searchResultAriaLabel.replace(e,this.filteredOptions.length.toString())}else this.ariaLabel?this.ariaLabelForDropdown=`${this.ariaLabel}, ${this.filteredOptions.length} results found.`:this.ariaLabelForDropdown=`Dropdown Element, ${this.filteredOptions.length} results found.`}setInitialValue(){var e;if(this.options.length){const t=this.renderOptions.find((e=>e.key===this.selectedKey)),i=null==t?void 0:t.option;i&&(this.setInputValue(this.getOptionValue(i)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(i)),this.notifyInputValueChanged(this.getOptionValue(i)),this.requestUpdate())}}getOptionValue(e){return this.isOptionObject(e)&&!this.optionValue?Object.values(e)[0]:this.isOptionObject(e)?e[this.optionValue]:e}getOptionId(e){return this.isOptionObject(e)?e[this.optionId]:e}isOptionObject(e){return"object"==typeof e&&null!==e}updateRenderOptions(){const e=[];this.focusReset();const t=this.options.reduce(((t,i)=>{const{key:s,value:o}=this.getOptionKeyValuePair(i);return-1!==e.indexOf(s)?console.error(`Dropdown already have option key: "${s}". Ignoring `):s?(e.push(s),t.push({key:s,value:o,option:i})):console.error(`Dropdown key is not defined: "${s}". (value: "${o}"). Ignoring `),t}),[]);this.allowUnselected&&t.unshift({key:"",value:this.title}),this.renderOptions=t}updateListDOM(){return b(this,void 0,void 0,(function*(){this.expanded&&(yield this.resizeDropdownList(),yield this.scrollToIndex(this.focusedIndex))}))}resizeDropdownList(){return b(this,void 0,void 0,(function*(){yield new Promise((e=>requestAnimationFrame((()=>{if(this.optionsListItems)if(this.optionsListItems.length>this.visibleOptions){const e=`${[...this.optionsListItems].slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)}px`;this.lastMaxHeight!==e&&(this.optionsList.style.maxHeight=e,this.lastMaxHeight=e)}else{const e="auto";this.lastMaxHeight!==e&&(this.optionsList.style.maxHeight=e,this.lastMaxHeight=e)}e()}))))}))}handleFocusIn(e){this.disabled&&this.readOnly||super.handleFocusIn&&super.handleFocusIn(e),this.dispatchEvent(new CustomEvent("dropdown-focus-in",{composed:!0,bubbles:!0}))}handleFocusOut(e){super.handleFocusOut&&super.handleFocusOut(e),this.dispatchEvent(new CustomEvent("dropdown-focus-out",{composed:!0,bubbles:!0}))}static get styles(){return[a.A,m.A]}get filteredOptions(){const e=this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue;if(!e.trim())return this.renderOptions;const t=this.renderOptions.filter((t=>t.value.toLowerCase().includes(e.toLowerCase())));return 0===t.length?[{key:"no-result",value:"No Result",disabled:!0}]:t}get messageType(){return this.messageArr.length>0?this.messageController.determineMessageType(this.messageArr):null}get messages(){return this.messageType?this.messageController.filterMessagesByType(this.messageArr,this.messageType):null}setVisualListbox(e){this.expanded=e}updateOnNextFrame(e){requestAnimationFrame(e)}setInputValue(e=""){this.input.value=e}shouldChangeButton(){const e=this.input&&this.input.value.length>0;return e&&document.dispatchEvent(new CustomEvent("on-widget-update")),e}toggleVisualListBox(e){var t,i;if(!this.readOnly){if(e.target.classList.contains("md-dropdown-input"))e.target.focus();else if("md-icon"===e.target.localName){const s=null===(i=null===(t=e.target.parentElement)||void 0===t?void 0:t.parentElement)||void 0===i?void 0:i.parentElement;if(s){const e=s.querySelector(".md-dropdown-input");setTimeout((()=>{e.focus()}),10)}}this.expanded?this.setVisualListbox(!1):(this.dispatchEvent(new CustomEvent("combobox-on-expand",{composed:!0,bubbles:!0})),this.notifySearchResultCount(),this.setVisualListbox(!0)),this.input.focus()}}handleRemoveAll(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("remove-all-selected"))}removeAllSelected(){var e;this.focusReset(),this.selectedKey="",this.inputValue="",this.setInputValue(),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,""),this.setVisualListbox(!1),this.updateOnNextFrame((()=>{this.input.focus()})),this.dispatchEvent(new CustomEvent("dropdown-selection-removed",{composed:!0,bubbles:!0,detail:{}}))}setupEvents(){document.addEventListener("click",this.onOutsideClick),this.addEventListener("keydown",this.onKeyDown),this.addEventListener("remove-all-selected",this.removeAllSelected)}teardownEvents(){document.removeEventListener("click",this.onOutsideClick),this.removeEventListener("keydown",this.onKeyDown),this.removeEventListener("remove-all-selected",this.removeAllSelected)}expand(){this.expanded=!0;const e=-1!==this.focusedIndex?`combo-${this.focusedIndex}`:"";document.dispatchEvent(new CustomEvent("on-widget-update")),this.label.setAttribute("aria-activedescendant",e),this.optionsList&&this.optionsList.focus(),-1===this.focusedIndex&&this.focusNext()}collapse(){this.expanded=!1,this.searchable||this.label.setAttribute("aria-activedescendant","")}toggle(){this.expanded?this.collapse():this.expand()}select(){if(-1!==this.focusedIndex){const e=this.renderOptions[this.focusedIndex],t=e.key;t!==this.selectedKey&&(this.selectedKey=t,this.dispatchEvent(new CustomEvent("dropdown-selected",{composed:!0,bubbles:!0,detail:{option:e.option?e.option:e.key}})))}}onLabelClick(){this.label.focus(),this.toggle()}focusFirst(){this.renderOptions.length&&(this.focusedIndex=0)}focusLast(){this.renderOptions.length&&(this.focusedIndex=this.renderOptions.length-1)}focusNext(){this.renderOptions.length&&(-1!==this.focusedIndex&&this.focusedIndex<this.renderOptions.length-1?this.focusedIndex++:this.focusFirst())}focusPrev(){this.renderOptions.length&&(this.focusedIndex>0?this.focusedIndex--:this.focusLast())}focusToIndex(e){this.renderOptions.length&&e>=0&&e<=this.renderOptions.length-1&&(this.focusedIndex=e)}focusToIndexWithOption(e){const t=this.renderOptions.findIndex((t=>t.key===e.key));this.renderOptions.length&&t>=0&&t<=this.renderOptions.length-1&&(this.focusedIndex=t)}focusReset(){this.focusedIndex=-1}scrollToIndex(e){return b(this,void 0,void 0,(function*(){yield new Promise((t=>{requestAnimationFrame((()=>{if(this.optionsListItems&&this.optionsListItems.length>this.visibleOptions&&e>=0&&this.optionsListItems.length>e){let t=0;const{top:i,bottom:s}=this.optionsList.getBoundingClientRect(),o=this.optionsListItems[e],r=this.optionsListItems[e+1]||o,n=this.optionsListItems[e-1]||o,a=r.getBoundingClientRect(),l=n.getBoundingClientRect();a.bottom>s?t=a.bottom-s+2:l.top<i&&(t=l.top-i-2),this.optionsList.scrollTop+=t}t()}))}))}))}getOptionKeyValuePair(e){if("string"==typeof e)return{key:e.trim(),value:e};if(e&&"object"==typeof e){const t=Object.keys(e),i=Object.values(e);if(t.length){if(1===t.length||!this.optionId)return{key:t[0],value:i[0]};if(this.optionId)return{key:e[this.optionId],value:e[this.optionValue||this.optionId]}}}return{key:"undefined",value:"undefined"}}get labelTitle(){if(this.selectedKey){const e=this.renderOptions.find((e=>e.key===this.selectedKey));if(e)return e.value}return this.title}get dropDownClassMap(){return{"md-dropdown__expanded":this.expanded,[`md-${this.messageType}`]:!!this.messageType,"md-new-dropdown":this.newMomentum,"md-dropdown--pill":!0===this.pill}}handleInput(e){const t=e.target.value;this.inputValue=t.trim(),this.notifyInputValueChanged(t.trim())}helpTextTemplate(){return this.helpText?d.html`
|
|
623
|
+
`}};d([(0,n.property)({type:Boolean,attribute:"dots"})],t.prototype,"hasDots",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"only-dots"})],t.prototype,"onlyDots",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"no-navigation"})],t.prototype,"noNavigation",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"total-page"})],t.prototype,"totalPage",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"visible-page"})],t.prototype,"visiblePage",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"current-page"})],t.prototype,"currentPage",null),t=d([(0,o.w)("md-pagination")],t),e.ELEMENT=t}(s||(s={}))},23184:(e,t,i)=>{i.d(t,{Dropdown:()=>s}),i(61200);var s,o=i(90195),r=i(3001),n=i(66677),a=i(26272),l=i(41488),d=i(40333),h=i(17518),p=i(97822),c=i(22818),u=i(8229),m=i(70573),y=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},b=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){class t{determineMessageType(e){return e.reduce(((e,t)=>"error"===t?e:t.type),"")}filterMessagesByType(e,t){return e.reduce(((e,i)=>i.type===t?e.concat(i.message):e),[])}}e.MessageController=t;let i=class extends((0,r.yC)(l.LitElement)){constructor(){super(...arguments),this.title="Select...",this.options=[],this.optionId="",this.optionValue="",this.defaultOption="",this.disabled=!1,this.customTabIndex=0,this.allowUnselected=!1,this.visibleOptions=8,this.newMomentum=!1,this.compact=!1,this.searchable=!1,this.searchItem=!1,this.inputValue="",this.placeholder="Select...",this.readOnly=!1,this.autofocus=!1,this.leftIcon="",this.trimSpace=!1,this.resultsTextLocalization="No Results",this.pill=!1,this.helpText="",this.messageArr=[],this.htmlId="",this.clearAriaLabel="Clear",this.clearIconHeight="auto",this.arrowAriaLabel="Expand",this.popupChevronAriaHidden="true",this.ariaLabel="",this.searchResultAriaLabel="",this.ariaLabelForDropdown="",this.renderOptions=[],this.selectedKey="",this.expanded=!1,this.focusedIndex=-1,this.messageController=new t,this.lastMaxHeight="",this.onOutsideClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||this.expanded&&this.collapse())},this.onKeyDown=e=>{switch(e.code){case o.Uz.Tab:this.expanded&&(e.stopPropagation(),this.collapse());break;case o.Uz.Space:case o.Uz.Enter:this.expanded?(this.select(),this.collapse()):this.expand();break;case o.Uz.ArrowDown:this.expanded?this.focusNext():this.expand();break;case o.Uz.ArrowUp:this.expanded?this.focusPrev():this.expand();break;case o.Uz.Home:this.expanded?this.focusFirst():this.expand();break;case o.Uz.End:this.expanded?this.focusLast():this.expand();break;case o.Uz.Escape||o.Uz.Backspace:this.expanded&&(e.stopPropagation(),this.collapse())}},this.notifyInputValueChanged=(0,n.sg)((e=>{this.dispatchEvent(new CustomEvent("dropdown-input",{composed:!0,bubbles:!0,detail:{value:e}})),this.notifySearchResultCount(),requestAnimationFrame((()=>{this.input.focus()}))}),250)}connectedCallback(){super.connectedCallback(),this.setupEvents()}disconnectedCallback(){super.disconnectedCallback(),this.teardownEvents()}firstUpdated(e){super.firstUpdated(e),e.forEach(((e,t)=>{if("defaultOption"===t&&this.defaultOption){const{key:e}=this.getOptionKeyValuePair(this.defaultOption);this.selectedKey=e}})),this.searchable&&this.setInitialValue()}updated(e){super.updated(e),e.forEach(((e,t)=>{if("options"===t&&this.updateRenderOptions(),"selectedKey"===t){const e=this.renderOptions.findIndex((e=>e.key===this.selectedKey));-1!==e&&(this.focusToIndex(e),this.searchable&&this.setInitialValue())}if("expanded"===t&&this.updateListDOM(),"focusedIndex"===t&&this.updateListDOM(),"defaultOption"===t&&this.defaultOption){const{key:e}=this.getOptionKeyValuePair(this.defaultOption);this.selectedKey=e}}))}notifySearchResultCount(){if(this.searchResultAriaLabel){const e=/{{.*?}}/g;this.ariaLabelForDropdown=this.searchResultAriaLabel.replace(e,this.filteredOptions.length.toString())}else this.ariaLabel?this.ariaLabelForDropdown=`${this.ariaLabel}, ${this.filteredOptions.length} results found.`:this.ariaLabelForDropdown=`Dropdown Element, ${this.filteredOptions.length} results found.`}setInitialValue(){var e;if(this.options.length){const t=this.renderOptions.find((e=>e.key===this.selectedKey)),i=null==t?void 0:t.option;i&&(this.setInputValue(this.getOptionValue(i)),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,this.getOptionId(i)),this.notifyInputValueChanged(this.getOptionValue(i)),this.requestUpdate())}}getOptionValue(e){return this.isOptionObject(e)&&!this.optionValue?Object.values(e)[0]:this.isOptionObject(e)?e[this.optionValue]:e}getOptionId(e){return this.isOptionObject(e)?e[this.optionId]:e}isOptionObject(e){return"object"==typeof e&&null!==e}updateRenderOptions(){const e=[];this.focusReset();const t=this.options.reduce(((t,i)=>{const{key:s,value:o}=this.getOptionKeyValuePair(i);return-1!==e.indexOf(s)?console.error(`Dropdown already have option key: "${s}". Ignoring `):s?(e.push(s),t.push({key:s,value:o,option:i})):console.error(`Dropdown key is not defined: "${s}". (value: "${o}"). Ignoring `),t}),[]);this.allowUnselected&&t.unshift({key:"",value:this.title}),this.renderOptions=t}updateListDOM(){return b(this,void 0,void 0,(function*(){this.expanded&&(yield this.resizeDropdownList(),yield this.scrollToIndex(this.focusedIndex))}))}resizeDropdownList(){return b(this,void 0,void 0,(function*(){yield new Promise((e=>requestAnimationFrame((()=>{if(this.optionsListItems)if(this.optionsListItems.length>this.visibleOptions){const e=`${[...this.optionsListItems].slice(0,this.visibleOptions).reduce(((e,t)=>e+t.offsetHeight),0)}px`;this.lastMaxHeight!==e&&(this.optionsList.style.maxHeight=e,this.lastMaxHeight=e)}else{const e="auto";this.lastMaxHeight!==e&&(this.optionsList.style.maxHeight=e,this.lastMaxHeight=e)}e()}))))}))}handleFocusIn(e){var t;this.disabled&&this.readOnly||null===(t=super.handleFocusIn)||void 0===t||t.call(this,e),this.dispatchEvent(new CustomEvent("dropdown-focus-in",{composed:!0,bubbles:!0}))}handleFocusOut(e){var t;null===(t=super.handleFocusOut)||void 0===t||t.call(this,e),this.dispatchEvent(new CustomEvent("dropdown-focus-out",{composed:!0,bubbles:!0}))}static get styles(){return[a.A,m.A]}get filteredOptions(){const e=this.trimSpace?this.inputValue.replace(/\s+/g,""):this.inputValue;if(!e.trim())return this.renderOptions;const t=this.renderOptions.filter((t=>t.value.toLowerCase().includes(e.toLowerCase())));return 0===t.length?[{key:"no-result",value:"No Result",disabled:!0}]:t}get messageType(){return this.messageArr.length>0?this.messageController.determineMessageType(this.messageArr):null}get messages(){return this.messageType?this.messageController.filterMessagesByType(this.messageArr,this.messageType):null}setVisualListbox(e){this.expanded=e}updateOnNextFrame(e){requestAnimationFrame(e)}setInputValue(e=""){this.input.value=e}shouldChangeButton(){const e=this.input&&this.input.value.length>0;return e&&document.dispatchEvent(new CustomEvent("on-widget-update")),e}toggleVisualListBox(e){var t,i;if(!this.readOnly){if(e.target.classList.contains("md-dropdown-input"))e.target.focus();else if("md-icon"===e.target.localName){const s=null===(i=null===(t=e.target.parentElement)||void 0===t?void 0:t.parentElement)||void 0===i?void 0:i.parentElement;if(s){const e=s.querySelector(".md-dropdown-input");setTimeout((()=>{e.focus()}),10)}}this.expanded?this.setVisualListbox(!1):(this.dispatchEvent(new CustomEvent("combobox-on-expand",{composed:!0,bubbles:!0})),this.notifySearchResultCount(),this.setVisualListbox(!0)),this.input.focus()}}handleRemoveAll(e){e.stopPropagation(),this.dispatchEvent(new CustomEvent("remove-all-selected"))}removeAllSelected(){var e;this.focusReset(),this.selectedKey="",this.inputValue="",this.setInputValue(),null===(e=this.input)||void 0===e||e.setAttribute(o.iw.AriaActivedescendant,""),this.setVisualListbox(!1),this.updateOnNextFrame((()=>{this.input.focus()})),this.dispatchEvent(new CustomEvent("dropdown-selection-removed",{composed:!0,bubbles:!0,detail:{}}))}setupEvents(){document.addEventListener("click",this.onOutsideClick),this.addEventListener("keydown",this.onKeyDown),this.addEventListener("remove-all-selected",this.removeAllSelected)}teardownEvents(){document.removeEventListener("click",this.onOutsideClick),this.removeEventListener("keydown",this.onKeyDown),this.removeEventListener("remove-all-selected",this.removeAllSelected)}expand(){this.expanded=!0;const e=-1!==this.focusedIndex?`combo-${this.focusedIndex}`:"";document.dispatchEvent(new CustomEvent("on-widget-update")),this.label.setAttribute("aria-activedescendant",e),this.optionsList&&this.optionsList.focus(),-1===this.focusedIndex&&this.focusNext()}collapse(){this.expanded=!1,this.searchable||this.label.setAttribute("aria-activedescendant","")}toggle(){this.expanded?this.collapse():this.expand()}select(){if(-1!==this.focusedIndex){const e=this.renderOptions[this.focusedIndex],t=e.key;t!==this.selectedKey&&(this.selectedKey=t,this.dispatchEvent(new CustomEvent("dropdown-selected",{composed:!0,bubbles:!0,detail:{option:e.option?e.option:e.key}})))}}onLabelClick(){this.label.focus(),this.toggle()}focusFirst(){this.renderOptions.length&&(this.focusedIndex=0)}focusLast(){this.renderOptions.length&&(this.focusedIndex=this.renderOptions.length-1)}focusNext(){this.renderOptions.length&&(-1!==this.focusedIndex&&this.focusedIndex<this.renderOptions.length-1?this.focusedIndex++:this.focusFirst())}focusPrev(){this.renderOptions.length&&(this.focusedIndex>0?this.focusedIndex--:this.focusLast())}focusToIndex(e){this.renderOptions.length&&e>=0&&e<=this.renderOptions.length-1&&(this.focusedIndex=e)}focusToIndexWithOption(e){const t=this.renderOptions.findIndex((t=>t.key===e.key));this.renderOptions.length&&t>=0&&t<=this.renderOptions.length-1&&(this.focusedIndex=t)}focusReset(){this.focusedIndex=-1}scrollToIndex(e){return b(this,void 0,void 0,(function*(){yield new Promise((t=>{requestAnimationFrame((()=>{if(this.optionsListItems&&this.optionsListItems.length>this.visibleOptions&&e>=0&&this.optionsListItems.length>e){let t=0;const{top:i,bottom:s}=this.optionsList.getBoundingClientRect(),o=this.optionsListItems[e],r=this.optionsListItems[e+1]||o,n=this.optionsListItems[e-1]||o,a=r.getBoundingClientRect(),l=n.getBoundingClientRect();a.bottom>s?t=a.bottom-s+2:l.top<i&&(t=l.top-i-2),this.optionsList.scrollTop+=t}t()}))}))}))}getOptionKeyValuePair(e){if("string"==typeof e)return{key:e.trim(),value:e};if(e&&"object"==typeof e){const t=Object.keys(e),i=Object.values(e);if(t.length){if(1===t.length||!this.optionId)return{key:t[0],value:i[0]};if(this.optionId)return{key:e[this.optionId],value:e[this.optionValue||this.optionId]}}}return{key:"undefined",value:"undefined"}}get labelTitle(){if(this.selectedKey){const e=this.renderOptions.find((e=>e.key===this.selectedKey));if(e)return e.value}return this.title}get dropDownClassMap(){return{"md-dropdown__expanded":this.expanded,[`md-${this.messageType}`]:!!this.messageType,"md-new-dropdown":this.newMomentum,"md-dropdown--pill":!0===this.pill}}handleInput(e){const t=e.target.value;this.inputValue=t.trim(),this.notifyInputValueChanged(t.trim())}helpTextTemplate(){return this.helpText?d.html`
|
|
624
624
|
<md-help-text
|
|
625
625
|
class="help-text ${(0,h.classMap)({disabled:this.disabled,newMomentum:this.newMomentum})}"
|
|
626
626
|
.message=${this.helpText}
|
|
@@ -628,7 +628,7 @@
|
|
|
628
628
|
></md-help-text>
|
|
629
629
|
`:d.nothing}messagesTemplate(){return this.messages&&this.messages.length?d.html`
|
|
630
630
|
<div id="${this.htmlId}-message" part="message" class="md-dropbox__messages">
|
|
631
|
-
${(0,
|
|
631
|
+
${(0,c.repeat)(this.messages,((e,t)=>d.html`
|
|
632
632
|
<md-help-text
|
|
633
633
|
.message=${e}
|
|
634
634
|
.id=${this.messageArr[t].id||""}
|
|
@@ -669,10 +669,10 @@
|
|
|
669
669
|
type="button"
|
|
670
670
|
class="md-dropdown-button arrow-down"
|
|
671
671
|
aria-expanded=${this.expanded}
|
|
672
|
-
aria-label=${(0,
|
|
672
|
+
aria-label=${(0,p.ifDefined)("true"===this.popupChevronAriaHidden?void 0:this.arrowAriaLabel)}
|
|
673
673
|
aria-controls="md-dropdown-input"
|
|
674
674
|
tabindex="-1"
|
|
675
|
-
aria-hidden=${(0,
|
|
675
|
+
aria-hidden=${(0,p.ifDefined)("true"===this.popupChevronAriaHidden?"true":void 0)}
|
|
676
676
|
?readonly=${this.readOnly}
|
|
677
677
|
?disabled=${this.disabled}
|
|
678
678
|
@click=${this.toggleVisualListBox}
|
|
@@ -717,10 +717,11 @@
|
|
|
717
717
|
part="dropdown-header"
|
|
718
718
|
role="combobox"
|
|
719
719
|
tabindex="0"
|
|
720
|
-
|
|
720
|
+
>
|
|
721
721
|
${this.leftIcon?d.html`<span class="md-dropdown-label--left-icon">${this.iconTemplate()}</span>`:d.nothing}
|
|
722
|
-
<span
|
|
723
|
-
|
|
722
|
+
<span
|
|
723
|
+
class="md-dropdown-label--text ${(0,h.classMap)({"md-new-dropdown-label--text":this.newMomentum})}"
|
|
724
|
+
>
|
|
724
725
|
${this.labelTitle}</span
|
|
725
726
|
>
|
|
726
727
|
<span class="md-dropdown-label--icon">
|
|
@@ -735,14 +736,14 @@
|
|
|
735
736
|
aria-label="${this.labelTitle}"
|
|
736
737
|
aria-hidden="${!this.expanded}"
|
|
737
738
|
part="dropdown-options"
|
|
738
|
-
tabindex=${(0,
|
|
739
|
+
tabindex=${(0,p.ifDefined)(-1===this.customTabIndex?void 0:this.customTabIndex)}
|
|
739
740
|
>
|
|
740
741
|
${this.filteredOptions.map(((e,t)=>d.html`
|
|
741
742
|
<li
|
|
742
743
|
id="combo-${t}"
|
|
743
744
|
class="md-dropdown-option"
|
|
744
745
|
role="option"
|
|
745
|
-
tabindex=${(0,
|
|
746
|
+
tabindex=${(0,p.ifDefined)(-1===this.customTabIndex?void 0:this.customTabIndex)}
|
|
746
747
|
aria-label="${e.value}"
|
|
747
748
|
label="${e.value}"
|
|
748
749
|
aria-selected="${e.key===this.selectedKey}"
|
|
@@ -759,7 +760,7 @@
|
|
|
759
760
|
</ul>
|
|
760
761
|
</div>
|
|
761
762
|
${this.messagesTemplate()} ${this.helpTextTemplate()}
|
|
762
|
-
`}};
|
|
763
|
+
`}};y([(0,l.property)({type:String,attribute:"title"})],i.prototype,"title",void 0),y([(0,l.property)({type:Array})],i.prototype,"options",void 0),y([(0,l.property)({type:String,attribute:"option-id"})],i.prototype,"optionId",void 0),y([(0,l.property)({type:String,attribute:"option-value"})],i.prototype,"optionValue",void 0),y([(0,l.property)({type:Object})],i.prototype,"defaultOption",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"disabled",void 0),y([(0,l.property)({type:Number,attribute:"custom-tab-index",reflect:!0})],i.prototype,"customTabIndex",void 0),y([(0,l.property)({type:Boolean,attribute:"allow-unselected",reflect:!0})],i.prototype,"allowUnselected",void 0),y([(0,l.property)({type:Number,attribute:"visible-option",reflect:!0})],i.prototype,"visibleOptions",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"newMomentum",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"compact",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"searchable",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"searchItem",void 0),y([(0,l.property)({type:String,attribute:"input-value",reflect:!0})],i.prototype,"inputValue",void 0),y([(0,l.property)({type:String})],i.prototype,"placeholder",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"readOnly",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"autofocus",void 0),y([(0,l.property)({type:String,attribute:"left-icon",reflect:!0})],i.prototype,"leftIcon",void 0),y([(0,l.property)({type:Boolean,reflect:!0,attribute:"search-trim-space"})],i.prototype,"trimSpace",void 0),y([(0,l.property)({type:String,attribute:"no-results-i18n"})],i.prototype,"resultsTextLocalization",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"pill",void 0),y([(0,l.property)({type:String})],i.prototype,"helpText",void 0),y([(0,l.property)({type:Array})],i.prototype,"messageArr",void 0),y([(0,l.property)({type:String})],i.prototype,"htmlId",void 0),y([(0,l.property)({type:String,attribute:"clear-aria-label"})],i.prototype,"clearAriaLabel",void 0),y([(0,l.property)({type:String,attribute:"clear-icon-height"})],i.prototype,"clearIconHeight",void 0),y([(0,l.property)({type:String,attribute:"arrow-aria-label"})],i.prototype,"arrowAriaLabel",void 0),y([(0,l.property)({type:String,attribute:"popup-chevron-aria-hidden"})],i.prototype,"popupChevronAriaHidden",void 0),y([(0,l.property)({type:String,reflect:!0})],i.prototype,"ariaLabel",void 0),y([(0,l.property)({type:String,attribute:"search-result-aria-label"})],i.prototype,"searchResultAriaLabel",void 0),y([(0,l.internalProperty)()],i.prototype,"ariaLabelForDropdown",void 0),y([(0,l.internalProperty)()],i.prototype,"renderOptions",void 0),y([(0,l.internalProperty)()],i.prototype,"selectedKey",void 0),y([(0,l.internalProperty)()],i.prototype,"expanded",void 0),y([(0,l.internalProperty)()],i.prototype,"focusedIndex",void 0),y([(0,l.query)("label")],i.prototype,"label",void 0),y([(0,l.query)(".md-dropdown-input")],i.prototype,"input",void 0),y([(0,l.query)("ul.md-dropdown-list")],i.prototype,"optionsList",void 0),y([(0,l.queryAll)("li.md-dropdown-option")],i.prototype,"optionsListItems",void 0),i=y([(0,r.wW)("md-dropdown")],i),e.ELEMENT=i}(s||(s={}))},23779:(e,t,i)=>{i.d(t,{AudioPlayer:()=>u}),i(96798),i(61200),i(83192);var s=i(90195),o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(92984),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const p=[{value:.25,label:"0.25"},{value:.5,label:"0.50"},{value:.75,label:"0.75"},{value:1,label:"Normal"},{value:1.25,label:"1.25"},{value:1.5,label:"1.50"},{value:1.75,label:"1.75"},{value:2,label:"2"}],c={playBtn:{ariaLabel:"Play",tooltipText:"Play"},pauseBtn:{ariaLabel:"Pause",tooltipText:"Pause"},duration:{ariaLabel:"Duration:",tooltipText:"Duration"},timeline:{ariaLabel:"Audio Seekbar",tooltipText:"Audio Seekbar"},volumeBtn:{ariaLabel:"Mute / Unmute Audio",tooltipText:"Mute / Unmute"},volumeSlider:{ariaLabel:"Volume level",tooltipText:"Volume level"},playbackSpeedBtn:{ariaLabel:"Playback speed",tooltipText:"Playback speed"}};var u;!function(e){let t=class extends n.LitElement{constructor(){super(),this.src="",this.events=[],this.isPlaying=!1,this.isMuted=!1,this.duration=0,this.volume=100,this.currentTime=0,this.showSpeedPopup=!1,this.playbackSpeed=1,this.volumeExpanded=!1,this.bufferedRange=0,this.selectedPlaybackSpeed=this.playbackSpeed,this.currentlySelectingPlaybackSpeed=!1,this.onOutsideClick=e=>{let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>"speed-btn"===e.id)),t||(this.showSpeedPopup=!1))},this.handleKeyDown=e=>{const{code:t}=e;switch(t){case s.Uz.ArrowLeft:this.volumeExpanded?this.setVolumeKeydown(this.volume-.01):this.setTimeKeydown(this.currentTime-1);break;case s.Uz.ArrowRight:this.volumeExpanded?this.setVolumeKeydown(this.volume+.01):this.setTimeKeydown(this.currentTime+1);break;case s.Uz.ArrowUp:if(this.showSpeedPopup){this.currentlySelectingPlaybackSpeed=!0;const t=p.findIndex((e=>e.value===this.selectedPlaybackSpeed)),i=Math.max(0,t-1);this.selectedPlaybackSpeed=p[i].value,e.preventDefault(),this.currentlySelectingPlaybackSpeed=!1}break;case s.Uz.ArrowDown:if(this.showSpeedPopup){this.currentlySelectingPlaybackSpeed=!0;const t=p.findIndex((e=>e.value===this.selectedPlaybackSpeed)),i=Math.min(p.length-1,t+1);this.selectedPlaybackSpeed=p[i].value,e.preventDefault(),this.currentlySelectingPlaybackSpeed=!1}break;case s.Uz.Enter:this.showSpeedPopup&&(this.setPlaybackSpeed(this.selectedPlaybackSpeed),e.preventDefault())}},this.audio=new Audio,this.setAudioEventListeners(),this.labelMap=c}firstUpdated(e){super.firstUpdated(e),e.has("src")&&(this.audio.src=this.src)}updated(e){super.updated(e),e.has("src")&&(this.audio.src=this.src)}connectedCallback(){super.connectedCallback(),this.requestUpdate("src"),document.addEventListener("click",this.onOutsideClick),document.addEventListener("keydown",this.handleKeyDown)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.onOutsideClick),document.removeEventListener("keydown",this.handleKeyDown),this.audio.pause(),this.isPlaying=!1}setAudioEventListeners(){this.audio.onloadeddata=()=>{this.duration=this.audio.duration,this.audio.volume=.75},this.audio.onerror=()=>{this.audio.src&&this.dispatchEvent(new CustomEvent("playback-error",{composed:!0,bubbles:!0}))},this.audio.onended=()=>{this.audio.currentTime=0,this.isPlaying=!1},this.audio.ontimeupdate=()=>{this.currentTime=this.audio.currentTime},this.audio.onvolumechange=()=>{this.volume=this.audio.volume},this.audio.onprogress=()=>{this.audio.buffered.length>0&&(this.bufferedRange=this.audio.buffered.end(this.audio.buffered.length-1))}}togglePlay(){this.isPlaying=!this.isPlaying,this.isPlaying?(this.audio.play(),this.dispatchEvent(new CustomEvent("play-clicked",{composed:!0,bubbles:!0}))):this.audio.pause()}toTimecode(e){const t=Math.floor(e);return`${Math.floor(t/60)}:${String(t%60).padStart(2,"0")}`}setTime(e){const t=this.getBarPercentage(e,"timeline"),i=Math.floor(t*this.duration);this.audio.currentTime=i}setVolumeElement(e){this.volumeElement="volume"===e.target.className?e.target:e.target.parentElement}handleVolumeChange(e){let t=!1;this.setVolumeElement(e),this.setVolume(e);const i=e=>{t||(t=!0),this.volumeExpanded?this.setVolume(e):o()},s=()=>{o()},o=()=>{t=!1,window.removeEventListener("mousemove",i),window.removeEventListener("mouseup",s)};window.addEventListener("mousemove",i),window.addEventListener("mouseup",s),e.preventDefault()}getVolumeFromSlider(e){if(null===this.volumeElement)return 0;const t=this.volumeElement.getBoundingClientRect(),i=e.clientX-t.x;return Math.max(0,Math.min(1,i/t.width))}setVolume(e){const t=this.getVolumeFromSlider(e);this.audio.volume=t}getBarPercentage(e,t){const i=(e.target.className===t?e.target:e.target.parentElement).getBoundingClientRect();return(e.clientX-i.x)/i.width}toggleSoundMute(){this.isMuted=!this.isMuted,this.audio.muted=this.isMuted}toggleSpeedPopup(){this.showSpeedPopup=!this.showSpeedPopup}setTimeKeydown(e){e>this.duration?(this.currentTime=this.duration,this.audio.currentTime=this.duration):e<0?(this.currentTime=0,this.audio.currentTime=0):(this.currentTime=e,this.audio.currentTime=e)}setVolumeKeydown(e){e>1?(this.volume=1,this.audio.volume=1):e<0?(this.isMuted||this.toggleSoundMute(),this.volume=0,this.audio.volume=0):(this.isMuted&&this.toggleSoundMute(),this.volume=e,this.audio.volume=e)}get popupClassMap(){return{"popup-open":this.showSpeedPopup}}setPlaybackSpeed(e){this.playbackSpeed=e,this.selectedPlaybackSpeed=e,this.audio.playbackRate=this.playbackSpeed,this.showSpeedPopup=!1}toggleVolumeExpand(e){this.volumeExpanded=e}static get styles(){return[r.A,d.A]}render(){return n.html`
|
|
763
764
|
<div class="md-audio-player">
|
|
764
765
|
<div class="inner-container">
|
|
765
766
|
<div class="play-container">
|
|
@@ -834,7 +835,7 @@
|
|
|
834
835
|
</md-tooltip>
|
|
835
836
|
<div class="speed-popup ${(0,l.classMap)(this.popupClassMap)}">
|
|
836
837
|
<ul id="speed-popup-menu">
|
|
837
|
-
${
|
|
838
|
+
${p.map((e=>{const t=this.selectedPlaybackSpeed==e.value&&!this.currentlySelectingPlaybackSpeed;return n.html`
|
|
838
839
|
<li
|
|
839
840
|
class=${t?"speed-popup-selected-speed":""}
|
|
840
841
|
@click="${()=>this.setPlaybackSpeed(e.value)}"
|
|
@@ -856,7 +857,7 @@
|
|
|
856
857
|
</div>
|
|
857
858
|
</div>
|
|
858
859
|
</div>
|
|
859
|
-
`}};h([(0,n.property)({type:String})],t.prototype,"src",void 0),h([(0,n.property)({type:Object})],t.prototype,"labelMap",void 0),h([(0,n.internalProperty)()],t.prototype,"events",void 0),h([(0,n.internalProperty)()],t.prototype,"audio",void 0),h([(0,n.internalProperty)()],t.prototype,"volumeElement",void 0),h([(0,n.internalProperty)()],t.prototype,"isPlaying",void 0),h([(0,n.internalProperty)()],t.prototype,"isMuted",void 0),h([(0,n.internalProperty)()],t.prototype,"duration",void 0),h([(0,n.internalProperty)()],t.prototype,"volume",void 0),h([(0,n.internalProperty)()],t.prototype,"currentTime",void 0),h([(0,n.internalProperty)()],t.prototype,"showSpeedPopup",void 0),h([(0,n.internalProperty)()],t.prototype,"playbackSpeed",void 0),h([(0,n.internalProperty)()],t.prototype,"volumeExpanded",void 0),h([(0,n.internalProperty)()],t.prototype,"bufferedRange",void 0),h([(0,n.internalProperty)()],t.prototype,"selectedPlaybackSpeed",void 0),h([(0,n.internalProperty)()],t.prototype,"currentlySelectingPlaybackSpeed",void 0),t=h([(0,o.w)("md-audio-player")],t),e.ELEMENT=t}(u||(u={}))},23968:e=>{e.exports=s},24627:(e,t,i)=>{i.d(t,{DraggableItem:()=>s});var s,o=i(3001),r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(23968),h=i(6979),
|
|
860
|
+
`}};h([(0,n.property)({type:String})],t.prototype,"src",void 0),h([(0,n.property)({type:Object})],t.prototype,"labelMap",void 0),h([(0,n.internalProperty)()],t.prototype,"events",void 0),h([(0,n.internalProperty)()],t.prototype,"audio",void 0),h([(0,n.internalProperty)()],t.prototype,"volumeElement",void 0),h([(0,n.internalProperty)()],t.prototype,"isPlaying",void 0),h([(0,n.internalProperty)()],t.prototype,"isMuted",void 0),h([(0,n.internalProperty)()],t.prototype,"duration",void 0),h([(0,n.internalProperty)()],t.prototype,"volume",void 0),h([(0,n.internalProperty)()],t.prototype,"currentTime",void 0),h([(0,n.internalProperty)()],t.prototype,"showSpeedPopup",void 0),h([(0,n.internalProperty)()],t.prototype,"playbackSpeed",void 0),h([(0,n.internalProperty)()],t.prototype,"volumeExpanded",void 0),h([(0,n.internalProperty)()],t.prototype,"bufferedRange",void 0),h([(0,n.internalProperty)()],t.prototype,"selectedPlaybackSpeed",void 0),h([(0,n.internalProperty)()],t.prototype,"currentlySelectingPlaybackSpeed",void 0),t=h([(0,o.w)("md-audio-player")],t),e.ELEMENT=t}(u||(u={}))},23968:e=>{e.exports=s},24627:(e,t,i)=>{i.d(t,{DraggableItem:()=>s});var s,o=i(3001),r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(23968),h=i(6979),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.yC)(a.LitElement)){constructor(){super(...arguments),this.disabled=!1,this.extended=!1,this.editable=!1}static get styles(){return[n.A,h.A]}get draggableItemClassMap(){return{extended:this.extended,default:!this.extended,disabled:this.disabled}}render(){return a.html`
|
|
860
861
|
<div
|
|
861
862
|
class="md-draggable-item ${(0,d.classMap)(this.draggableItemClassMap)}"
|
|
862
863
|
part="draggable-item"
|
|
@@ -866,12 +867,12 @@
|
|
|
866
867
|
<slot></slot>
|
|
867
868
|
${this.extended?a.html` <slot name="extended"></slot> `:l.nothing}
|
|
868
869
|
</div>
|
|
869
|
-
`}};
|
|
870
|
-
<div class="md-slider__hashlabel">${(0,
|
|
870
|
+
`}};p([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",void 0),p([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"extended",void 0),p([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"editable",void 0),t=p([(0,r.w)("md-draggable-item")],t),e.ELEMENT=t}(s||(s={}))},25428:(e,t,i)=>{i.d(t,{Slider:()=>s});var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(40333),h=i(97822),p=i(22818),c=i(8229),u=i(61869),m=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.yC)(l.LitElement)){constructor(){super(...arguments),this._disabled=!1,this._now=0,this.min=0,this.max=100,this.hideValue=!1,this.text=0,this.label="slider",this.step=0,this.dragging=!1}get now(){return this._now}set now(e){const t=this._now;e<this.min||e>this.max?console.warn("Please select correct value"):(this._now=Math.round(e),this.requestUpdate("now",t))}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.setAttribute("aria-disabled",`${e}`),this.tabIndex=e?-1:0,this.requestUpdate("disabled",t)}get pointerPosition(){const e=this.max-this.min;return(this.now-this.min)/e*100}calculateHandlePosition(e){const{width:t,left:i}=this.getBoundingClientRect(),{clientX:s}=e,o=(s-i)/t;return this.min+(this.max-this.min)*o}moveSliderTo(e){this.disabled||(e>this.max?this.now=this.max:e<this.min?this.now=this.min:this.now=e)}trackMouseEvent(){if(!this.currentMouseEvent||!this.dragging)return;const e=this.calculateHandlePosition(this.currentMouseEvent),t=this.now;this.moveSliderTo(e),this.notifyChanging(t,this.now),requestAnimationFrame((()=>{this.trackMouseEvent()}))}ticksTemplate(){const{min:e,max:t,step:i}=this,s=Math.round((t-e)/i),o=new Array(s+1).fill(0,0,s+1).map(((t,s)=>e+s*i)).filter((i=>i>=e&&i<=t));return l.html`
|
|
871
|
+
<div class="md-slider__hashlabel">${(0,p.repeat)(o,(e=>l.html` <div class="tick">${e}</div> `))}</div>
|
|
871
872
|
`}displayValueTemplate(){return l.html` <span class="md-slider__value"> ${this.now} </span> `}notifyChanges(){this.dispatchEvent(new CustomEvent("slider-change",{bubbles:!0,composed:!0,detail:{value:this.now}}))}notifyChanging(e,t){e!==t&&this.dispatchEvent(new CustomEvent("slider-changing",{bubbles:!0,composed:!0,detail:{oldValue:e,newValue:t}}))}handleMouseDown(e){if(e.preventDefault(),this.disabled)return;const t=e=>{this.currentMouseEvent=e},i=e=>{this.focus(),this.currentMouseEvent=e,document.removeEventListener("mousemove",t),document.removeEventListener("mouseup",i),requestAnimationFrame((()=>{this.dragging=!1,this.notifyChanges()}))};document.addEventListener("mousemove",t),document.addEventListener("mouseup",i),this.focus(),this.dragging=!0,this.currentMouseEvent=e,requestAnimationFrame((()=>{this.trackMouseEvent()}))}handleKeyDown(e){const{code:t}=e,i=this.now;switch(t){case o.Uz.ArrowLeft:case o.Uz.ArrowDown:this.moveSliderTo(this.now-1);break;case o.Uz.ArrowRight:case o.Uz.ArrowUp:this.moveSliderTo(this.now+1);break;case o.Uz.Home:this.moveSliderTo(this.min);break;case o.Uz.End:this.moveSliderTo(this.max)}this.notifyChanging(i,this.now);const s=()=>{document.removeEventListener("keyup",s),this.notifyChanges()};document.addEventListener("keyup",s)}get sliderPointerStyleMap(){return{left:`${this.pointerPosition}%`}}get sliderSelectionStyleMap(){return{right:`calc(100% - ${this.pointerPosition}%)`}}static get styles(){return[a.A,u.A]}firstUpdated(e){super.firstUpdated(e),this.setAttribute("tabindex",this.disabled?"-1":"0")}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("mousedown",this.handleMouseDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeyDown),this.removeEventListener("mousedown",this.handleMouseDown)}render(){return l.html`
|
|
872
873
|
<div class="md-slider">
|
|
873
874
|
<span class="md-slider__bar"></span>
|
|
874
|
-
<span class="md-slider__selection" style=${(0,
|
|
875
|
+
<span class="md-slider__selection" style=${(0,c.styleMap)(this.sliderSelectionStyleMap)}></span>
|
|
875
876
|
<span
|
|
876
877
|
class="md-slider__pointer"
|
|
877
878
|
role="slider"
|
|
@@ -880,11 +881,11 @@
|
|
|
880
881
|
aria-valuemax=${this.max}
|
|
881
882
|
aria-valuenow=${this.now}
|
|
882
883
|
aria-label=${(0,h.ifDefined)(this.label)}
|
|
883
|
-
style=${(0,
|
|
884
|
+
style=${(0,c.styleMap)(this.sliderPointerStyleMap)}
|
|
884
885
|
></span>
|
|
885
886
|
${this.step?this.ticksTemplate():d.nothing} ${this.hideValue?d.nothing:this.displayValueTemplate()}
|
|
886
887
|
</div>
|
|
887
|
-
`}};m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"min",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"max",void 0),m([(0,l.property)({type:Boolean,attribute:"hide-value"})],t.prototype,"hideValue",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"now",null),m([(0,l.property)({type:Number})],t.prototype,"text",void 0),m([(0,l.property)({type:String})],t.prototype,"label",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"step",void 0),m([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),m([(0,l.internalProperty)()],t.prototype,"dragging",void 0),t=m([(0,n.w)("md-slider")],t),e.ELEMENT=t}(s||(s={}))},28187:e=>{e.exports=M},28307:(e,t,i)=>{i.d(t,{AdvanceList:()=>s});var s,o=i(90195),r=i(31890),n=i(32972),a=i(26272),l=i(41488),d=i(86635),h=i(61705),
|
|
888
|
+
`}};m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"min",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"max",void 0),m([(0,l.property)({type:Boolean,attribute:"hide-value"})],t.prototype,"hideValue",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"now",null),m([(0,l.property)({type:Number})],t.prototype,"text",void 0),m([(0,l.property)({type:String})],t.prototype,"label",void 0),m([(0,l.property)({type:Number,reflect:!0})],t.prototype,"step",void 0),m([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),m([(0,l.internalProperty)()],t.prototype,"dragging",void 0),t=m([(0,n.w)("md-slider")],t),e.ELEMENT=t}(s||(s={}))},28187:e=>{e.exports=M},28307:(e,t,i)=>{i.d(t,{AdvanceList:()=>s});var s,o=i(90195),r=i(31890),n=i(32972),a=i(26272),l=i(41488),d=i(86635),h=i(61705),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){e.prefixId="item-";let t=class extends((0,n.y)(l.LitElement)){constructor(){super(...arguments),this.items=[],this.isLoading=!1,this.isMulti=!1,this.groupOnMultiSelect=!1,this.value=[],this.ariaRoleList="listbox",this.ariaRoleListItem="option",this.ariaLabelList="",this.isError=!1,this.containerHeight="292px",this.lastSelectedIdByOrder="",this.selectAllItems=!1,this.focusReset=!1,this.disabledItems=[],this.totalRecords=0,this.isNonSelectable=!1,this.scrollIndex=-1,this.activeId="",this.selectedItemsIds=[],this.isUserNavigated=!1,this.handleKeyDown=t=>{var i;const{ArrowDown:s,ArrowUp:r,Tab:n,Space:a,Enter:l}=o.Uz,{code:d}=t,h=d===s,p=d===r,c=d===n,u=d===a,m=d===l;if(h||p){if(t.preventDefault(),this.isUserNavigated=!0,""===this.activeId&&this.value.length>0&&""!==this.value[0])return void(this.activeId=this.value[0]);if(""===this.activeId&&!p&&this.items.length>0)return void(this.activeId=this.items[0].id);const e=this.items.findIndex((e=>e.id===this.activeId));h?e<this.items.length-1&&!this.isNextElemenentStatusIndicator(e)&&(this.scrollIndex=e+1,this.activeId=this.items[this.scrollIndex].id):e>0&&(this.scrollIndex=e-1,this.activeId=this.items[this.scrollIndex].id)}else if(c)""===this.activeId&&this.value.length>0&&(this.activeId=this.value[0]);else if((u||m)&&(t.preventDefault(),this.activeId)){const t=null===(i=this.shadowRoot)||void 0===i?void 0:i.querySelector(`#${e.prefixId}${this.activeId}`);t&&("true"===t.getAttribute("aria-disabled")||t.hasAttribute("disabled")||this.updateItemSelection(t))}},this.handleRangeChange=e=>{const{last:t}=e;this.updateSelectedState(),this.items.length<this.totalRecords&&t>=this.items.length-1&&!this.isLoading&&!this.isError&&this.dispatchEvent(new CustomEvent("load-more",{bubbles:!0,composed:!0})),this.isUserNavigated=!1}}connectedCallback(){super.connectedCallback(),this.addEventListener("click",this.handleClick)}static get styles(){return[a.A,h.A]}getStyles(){return l.html`
|
|
888
889
|
<style>
|
|
889
890
|
:host .virtual-scroll {
|
|
890
891
|
height: ${this.containerHeight};
|
|
@@ -918,7 +919,7 @@
|
|
|
918
919
|
>
|
|
919
920
|
${(0,d.scroll)({items:this.items,renderItem:(e,t)=>this.renderItem(e,t||0),useShadowDOM:!0,scrollToIndex:this.isUserNavigated?{index:this.scrollIndex,position:0===this.scrollIndex?"start":"center"}:void 0})}
|
|
920
921
|
</div>
|
|
921
|
-
`}};
|
|
922
|
+
`}};p([(0,l.property)({type:Array})],t.prototype,"items",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"isLoading",void 0),p([(0,l.property)({type:Boolean,attribute:"is-multi"})],t.prototype,"isMulti",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"groupOnMultiSelect",void 0),p([(0,l.property)({type:Array})],t.prototype,"value",void 0),p([(0,l.property)({type:String})],t.prototype,"ariaRoleList",void 0),p([(0,l.property)({type:String})],t.prototype,"ariaRoleListItem",void 0),p([(0,l.property)({type:String})],t.prototype,"ariaLabelList",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"isError",void 0),p([(0,l.property)({type:String})],t.prototype,"containerHeight",void 0),p([(0,l.property)({type:String})],t.prototype,"lastSelectedIdByOrder",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"selectAllItems",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"focusReset",void 0),p([(0,l.property)({type:Array})],t.prototype,"disabledItems",void 0),p([(0,l.property)({type:Number})],t.prototype,"totalRecords",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"isNonSelectable",void 0),p([(0,l.queryAll)("div.default-wrapper")],t.prototype,"lists",void 0),p([(0,l.query)(".virtual-scroll")],t.prototype,"listContainer",void 0),p([(0,l.internalProperty)()],t.prototype,"scrollIndex",void 0),p([(0,l.internalProperty)()],t.prototype,"activeId",void 0),p([(0,l.internalProperty)()],t.prototype,"selectedItemsIds",void 0),p([(0,l.internalProperty)()],t.prototype,"isUserNavigated",void 0),t=p([(0,r.w)("md-advance-list")],t),e.ELEMENT=t}(s||(s={}))},29895:(e,t,i)=>{i.d(t,{CoachmarkPopover:()=>s}),i(96798),i(61200),i(71128);var s,o=i(31890),r=i(26272),n=i(41488),a=i(23968),l=i(40587),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.placement="bottom",this.headerIconName=void 0,this.header=void 0,this.message=void 0,this.show=!1,this.hideCloseButton=!1,this.href="",this.slotContent=null}static get styles(){return[r.A,l.A]}connectedCallback(){super.connectedCallback()}notifyCustomEvent(e){this.dispatchEvent(new CustomEvent(e,{bubbles:!0,composed:!0,detail:{placement:this.placement,triggerComponent:this.triggerComponent,popper:this.popper}}))}notifyCoachCreate(){this.notifyCustomEvent("coach-create")}notifyPrimaryButtonAction(){this.notifyCustomEvent("primary-button-action")}notifySecondaryButtonAction(){this.notifyCustomEvent("secondary-button-action")}notifyLinkAction(){this.notifyCustomEvent("link-action")}notifyCoachClose(){this.notifyCustomEvent("coachmark-close")}handleSlotChange(e){const t=e.target;if(t){const e=t.assignedElements({flatten:!0});e.length&&(this.slotContent=e)}}updated(e){super.updated(e),e.has("show")&&(this.show?this.notifyCoachCreate():this.notifyCoachClose())}coachmarkContentTemplate(){return n.html`
|
|
922
923
|
<div class="md-coachmark__content">
|
|
923
924
|
${this.message?this.message:n.html` <slot name="coachmark-content" @slotchange=${this.handleSlotChange}></slot> `}
|
|
924
925
|
</div>
|
|
@@ -964,11 +965,11 @@
|
|
|
964
965
|
${this.renderHeader()} ${this.renderBody()} ${this.renderFooter()}
|
|
965
966
|
</div>
|
|
966
967
|
</md-popover>
|
|
967
|
-
`}};d([(0,n.property)({type:String})],t.prototype,"placement",void 0),d([(0,n.property)({type:String})],t.prototype,"headerIconName",void 0),d([(0,n.property)({type:String})],t.prototype,"header",void 0),d([(0,n.property)({type:String})],t.prototype,"message",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"show",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"hide-close-button"})],t.prototype,"hideCloseButton",void 0),d([(0,n.property)({type:String})],t.prototype,"primaryButton",void 0),d([(0,n.property)({type:String})],t.prototype,"secondaryButton",void 0),d([(0,n.property)({type:String})],t.prototype,"linkText",void 0),d([(0,n.property)({type:String})],t.prototype,"href",void 0),d([(0,n.query)(".md-coachmark__trigger-component")],t.prototype,"triggerComponent",void 0),d([(0,n.query)(".md-coachmark__popper")],t.prototype,"popper",void 0),t=d([(0,o.w)("md-coachmark-popover")],t),e.ELEMENT=t}(s||(s={}))},31347:e=>{e.exports=
|
|
968
|
+
`}};d([(0,n.property)({type:String})],t.prototype,"placement",void 0),d([(0,n.property)({type:String})],t.prototype,"headerIconName",void 0),d([(0,n.property)({type:String})],t.prototype,"header",void 0),d([(0,n.property)({type:String})],t.prototype,"message",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"show",void 0),d([(0,n.property)({type:Boolean,reflect:!0,attribute:"hide-close-button"})],t.prototype,"hideCloseButton",void 0),d([(0,n.property)({type:String})],t.prototype,"primaryButton",void 0),d([(0,n.property)({type:String})],t.prototype,"secondaryButton",void 0),d([(0,n.property)({type:String})],t.prototype,"linkText",void 0),d([(0,n.property)({type:String})],t.prototype,"href",void 0),d([(0,n.query)(".md-coachmark__trigger-component")],t.prototype,"triggerComponent",void 0),d([(0,n.query)(".md-coachmark__popper")],t.prototype,"popper",void 0),t=d([(0,o.w)("md-coachmark-popover")],t),e.ELEMENT=t}(s||(s={}))},31347:e=>{e.exports=C},32022:e=>{e.exports=r},32217:(e,t,i)=>{i.d(t,{RadioGroup:()=>s});var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(76067),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.Io)(l.LitElement)){constructor(){super(...arguments),this.label="group",this.checked=-1,this.alignment="vertical",this._disabled=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.requestUpdate("disabled",t)}firstUpdated(e){super.firstUpdated(e),this.setAttribute("role","radiogroup"),this.setAttribute("aria-label",this.label)}updated(e){super.updated(e),(e.has("slotted")||e.has("checked"))&&this.setFirstChecked()}get selectedRadioValue(){return this.slotted[this.selected].value}notifySelectedChange(){this.dispatchEvent(new CustomEvent("radio-change",{detail:{selected:this.selectedRadioValue},bubbles:!0,composed:!0}))}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("click",this.handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeyDown),this.removeEventListener("click",this.handleClick)}setFirstChecked(){-1!==this.checked&&(this.selected=this.checked,this.setChecked(this.checked))}findRadioIndex(e){const t=e.composedPath();return this.slotted.findIndex((e=>t.includes(e)))}findCheckedRadioIndex(){return this.slotted.findIndex((e=>e.checked))}setChecked(e){const t=this.findCheckedRadioIndex();-1!==t&&t!==e&&this.slotted[t]&&(this.slotted[t].checked=!1),this.slotted[e]&&(this.slotted[e].checked=!0)}switchRadioOnArrowPress(e,t=1){const i=super.getAvailableSelectedIndex(e,t);-1!==i&&(this.selected=i,this.setChecked(i),this.notifySelectedChange())}isRadioDisabled(e){return this.slotted[e].disabled}handleClick(e){if(this.disabled)return!1;const t=this.findRadioIndex(e);-1!==t&&(this.isRadioDisabled(t)||(this.selected=t,this.setChecked(t),this.notifySelectedChange()))}handleKeyDown(e){if(this.disabled)return!1;const{code:t}=e;switch(t){case o.Uz.Enter:case o.Uz.Space:this.isRadioDisabled(this.selected)||(this.setChecked(this.selected),this.notifySelectedChange(),e.stopPropagation(),e.preventDefault());break;case o.Uz.ArrowUp:case o.Uz.ArrowLeft:0===this.selected?this.switchRadioOnArrowPress(this.slotted.length-1,-1):this.switchRadioOnArrowPress(this.selected-1,-1),e.stopPropagation(),e.preventDefault();break;case o.Uz.ArrowDown:case o.Uz.ArrowRight:this.selected===this.slotted.length-1?this.switchRadioOnArrowPress(0):this.switchRadioOnArrowPress(this.selected+1),e.stopPropagation(),e.preventDefault()}}get slotElement(){return this.radioSlot}static get styles(){return[a.A,d.A]}clearSelection(){const e=this.findCheckedRadioIndex();-1!=e&&(this.checked=-1,this.slotted[e].checked=!1)}render(){return l.html`
|
|
968
969
|
<div class="radio-group-container" part="radio-group-container">
|
|
969
970
|
<slot name="radio"></slot>
|
|
970
971
|
</div>
|
|
971
|
-
`}};h([(0,l.property)({type:String,attribute:"group-label"})],t.prototype,"label",void 0),h([(0,l.property)({type:Number,reflect:!0})],t.prototype,"checked",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),h([(0,l.query)("slot[name='radio']")],t.prototype,"radioSlot",void 0),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),t=h([(0,n.w)("md-radiogroup")],t),e.ELEMENT=t}(s||(s={}))},32252:(e,t,i)=>{i.d(t,{Modal:()=>s}),i(96798),i(61200);var s,o=i(90195),r=i(37719),n=i(3001),a=i(31890),l=i(26272),d=i(41488),h=i(40333),
|
|
972
|
+
`}};h([(0,l.property)({type:String,attribute:"group-label"})],t.prototype,"label",void 0),h([(0,l.property)({type:Number,reflect:!0})],t.prototype,"checked",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),h([(0,l.query)("slot[name='radio']")],t.prototype,"radioSlot",void 0),h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),t=h([(0,n.w)("md-radiogroup")],t),e.ELEMENT=t}(s||(s={}))},32252:(e,t,i)=>{i.d(t,{Modal:()=>s}),i(96798),i(61200);var s,o=i(90195),r=i(37719),n=i(3001),a=i(31890),l=i(26272),d=i(41488),h=i(40333),p=i(23968),c=i(97822),u=i(48521),m=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,n.dY)(d.LitElement)){constructor(){super(...arguments),this.show=!1,this.headerLabel="",this.headerMessage="",this.htmlId="",this.ariaLabel="modal",this.ariaLabelClose="Close Modal",this.ariaLabelCancel="Cancel Modal",this.ariaLabelSubmit="Submit Modal",this.ariaDescription="",this.showCloseButton=!1,this.backdropClickExit=!1,this.noExitOnEsc=!1,this.size="default",this.closeBtnName="",this.hideFooter=!1,this.hideHeader=!1,this.disableInitialFocus=!1,this.alignment=void 0,this.animating=!1,this.handleCloseOutside=e=>{e.code===o.Uz.Escape&&(e.preventDefault(),this.show&&!this.noExitOnEsc&&(this.show=!1))}}static get styles(){return[l.A,u.A]}connectedCallback(){super.connectedCallback(),document.addEventListener("keydown",this.handleCloseOutside)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("keydown",this.handleCloseOutside)}update(e){super.update(e),e.has("show")&&(this.show?this.modalFadeIn():!0===e.get("show")&&this.modalFadeOut())}get computedAlignment(){return void 0===this.alignment?r.themeManager.isMomentumV2Enabled?"leading":"center":this.alignment}notifyModalClose(){this.dispatchEvent(new CustomEvent("close-modal",{composed:!0,bubbles:!0}))}focusInsideModal(){var e;(null===(e=this.focusableElements)||void 0===e?void 0:e.length)&&this.setInitialFocus()}handleKeyDown(e){e.code!==o.Uz.Enter&&e.code!==o.Uz.Space||this.show&&(this.show=!0)}transitionPromise(e){return new Promise((t=>{const i=()=>{e.removeEventListener("transitionend",i),this.activateFocusTrap(),this.setFocusableElements(),requestAnimationFrame((()=>{t()}))},s=()=>{e.removeEventListener("transitioncancel",s),this.deactivateFocusTrap(),this.modalFadeOut(),t()};e.addEventListener("transitionend",i),e.addEventListener("transitioncancel",s),setTimeout((()=>{this.animating=!0}),13)}))}modalFadeIn(){return e=this,t=void 0,s=function*(){this.backDrop&&(yield this.transitionPromise(this.backDrop),this.disableInitialFocus||this.focusInsideModal())},new((i=void 0)||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}));var e,t,i,s}modalFadeOut(){this.animating=!1,this.deactivateFocusTrap(),this.notifyModalClose()}handleCloseBackdrop(){this.backdropClickExit&&(this.show=!1)}hideModal(){this.animating=!1,this.show=!1}topCloseBtnTemplate(){return d.html`
|
|
972
973
|
${this.showCloseButton?d.html`
|
|
973
974
|
<md-button
|
|
974
975
|
variant="ghost"
|
|
@@ -1017,16 +1018,16 @@
|
|
|
1017
1018
|
</div>
|
|
1018
1019
|
`}get modalBackDropClassMap(){return{in:this.show&&this.animating}}get modalContainerClassMap(){return{in:this.show,[`md-modal--${this.size}`]:!!this.size,[`md-modal--${this.computedAlignment}`]:!!this.computedAlignment}}render(){return d.html`
|
|
1019
1020
|
${this.show?d.html`
|
|
1020
|
-
<div part="modal-backdrop" class="md-modal__backdrop fade ${(0,
|
|
1021
|
+
<div part="modal-backdrop" class="md-modal__backdrop fade ${(0,p.classMap)(this.modalBackDropClassMap)}">
|
|
1021
1022
|
${this.backdropClickExit?d.html` <div class="md-modal_overlay" @click="${this.handleCloseBackdrop}"></div> `:h.nothing}
|
|
1022
1023
|
|
|
1023
1024
|
<div
|
|
1024
1025
|
part="modal-container"
|
|
1025
1026
|
role="dialog"
|
|
1026
1027
|
id="${this.htmlId}"
|
|
1027
|
-
class="md-modal ${(0,
|
|
1028
|
-
aria-label="${(0,
|
|
1029
|
-
aria-describedby=${(0,
|
|
1028
|
+
class="md-modal ${(0,p.classMap)(this.modalContainerClassMap)}"
|
|
1029
|
+
aria-label="${(0,c.ifDefined)(this.headerLabel||this.ariaLabel||void 0)}"
|
|
1030
|
+
aria-describedby=${(0,c.ifDefined)(this.ariaDescription||void 0)}
|
|
1030
1031
|
>
|
|
1031
1032
|
<div part="modal-content" class="md-modal__content">
|
|
1032
1033
|
<div class="md-modal__flex-container" part="modal-flex-container">
|
|
@@ -1040,11 +1041,11 @@
|
|
|
1040
1041
|
</div>
|
|
1041
1042
|
</div>
|
|
1042
1043
|
`:h.nothing}
|
|
1043
|
-
`}};m([(0,d.property)({type:Boolean})],t.prototype,"show",void 0),m([(0,d.property)({type:String})],t.prototype,"headerLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"headerMessage",void 0),m([(0,d.property)({type:String})],t.prototype,"htmlId",void 0),m([(0,d.property)({type:String,attribute:"aria-label"})],t.prototype,"ariaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelClose",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelCancel",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelSubmit",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaDescription",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"showCloseButton",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"backdropClickExit",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"noExitOnEsc",void 0),m([(0,d.property)({type:String})],t.prototype,"size",void 0),m([(0,d.property)({type:String})],t.prototype,"closeBtnName",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"hideFooter",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"hideHeader",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"disableInitialFocus",void 0),m([(0,d.property)({type:String})],t.prototype,"alignment",void 0),m([(0,d.internalProperty)()],t.prototype,"animating",void 0),m([(0,d.query)(".md-modal__backdrop")],t.prototype,"backDrop",void 0),t=m([(0,a.w)("md-modal")],t),e.ELEMENT=t}(s||(s={}))},
|
|
1044
|
+
`}};m([(0,d.property)({type:Boolean})],t.prototype,"show",void 0),m([(0,d.property)({type:String})],t.prototype,"headerLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"headerMessage",void 0),m([(0,d.property)({type:String})],t.prototype,"htmlId",void 0),m([(0,d.property)({type:String,attribute:"aria-label"})],t.prototype,"ariaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelClose",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelCancel",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaLabelSubmit",void 0),m([(0,d.property)({type:String})],t.prototype,"ariaDescription",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"showCloseButton",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"backdropClickExit",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"noExitOnEsc",void 0),m([(0,d.property)({type:String})],t.prototype,"size",void 0),m([(0,d.property)({type:String})],t.prototype,"closeBtnName",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"hideFooter",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"hideHeader",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"disableInitialFocus",void 0),m([(0,d.property)({type:String})],t.prototype,"alignment",void 0),m([(0,d.internalProperty)()],t.prototype,"animating",void 0),m([(0,d.query)(".md-modal__backdrop")],t.prototype,"backDrop",void 0),t=m([(0,a.w)("md-modal")],t),e.ELEMENT=t}(s||(s={}))},33328:(e,t,i)=>{i.d(t,{Accordion:()=>s});var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(33866),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.TS)(l.LitElement)){constructor(){super(...arguments),this.multiple=!1,this.handleAccordionItemFocus=()=>{this.toggleAttribute("focusable",!0)},this.handleAccordionItemBlur=()=>{this.toggleAttribute("focusable",!1)}}get slotItem(){return this.accordionItemSlotElement}filterSlotted(){return this.accordionItemSlotElement.assignedElements()}switchFocusedAccordionItem(e){const t=this.slotted.findIndex((e=>e.hasAttribute("focus-visible"))),i=this.slotted.length;let s=t;for(s=(i+s+e)%i;this.slotted[s].disabled;)s=(i+s+e)%i;this.focusAccordionItem(this.slotted[s])}focusAccordionItem(e){e.hasAttribute("focus-visible")||requestAnimationFrame((()=>e.header.focus()))}setActiveAccordionItem(e){this.multiple?e.expanded=!e.expanded:(this.slotted.forEach((t=>{const i=t;i.expanded&&!t.isEqualNode(e)&&(i.expanded=!1)})),e.expanded=!0)}setupExpandedAccordionItems(){this.multiple||this.slotted.filter((e=>e.expanded)).forEach(((e,t)=>{const i=e;i.expanded&&t>0&&(i.expanded=!1)}))}setupFocusAccordionItems(){this.slotted.forEach((e=>{e.addEventListener("focus",this.handleAccordionItemFocus),e.addEventListener("blur",this.handleAccordionItemBlur)}))}removeFocusAccordionItems(){this.slotted.forEach((e=>{e.removeEventListener("focus",this.handleAccordionItemFocus),e.removeEventListener("blur",this.handleAccordionItemBlur)}))}handleKeyDown(e){const{srcEvent:t}=e.detail,{code:i}=t;switch(i){case o.Uz.Space:case o.Uz.Enter:{const{target:t}=e;t&&this.setActiveAccordionItem(t);break}case o.Uz.ArrowDown:this.switchFocusedAccordionItem(1);break;case o.Uz.ArrowUp:this.switchFocusedAccordionItem(-1);break;case o.Uz.Home:{const e=this.slotted[0];this.focusAccordionItem(e);break}case o.Uz.End:{const e=this.slotted[this.slotted.length-1];this.focusAccordionItem(e);break}}}handleClick(e){const{target:t}=e,i=this.slotted.find((e=>e.isSameNode(t)));i&&this.setActiveAccordionItem(i)}updated(e){super.updated(e),e.has("slotted")&&(this.setupExpandedAccordionItems(),this.setupFocusAccordionItems())}connectedCallback(){super.connectedCallback(),this.addEventListener("accordion-item-keydown",this.handleKeyDown),this.addEventListener("accordion-item-click",this.handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("accordion-item-keydown",this.handleKeyDown),this.removeEventListener("accordion-item-click",this.handleClick),this.removeFocusAccordionItems()}static get styles(){return[a.A,d.A]}render(){return l.html`
|
|
1044
1045
|
<div class="md-accordion" part="accordion">
|
|
1045
1046
|
<slot name="accordion-item"></slot>
|
|
1046
1047
|
</div>
|
|
1047
|
-
`}};h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"multiple",void 0),h([(0,l.query)('slot[name="accordion-item"]')],t.prototype,"accordionItemSlotElement",void 0),t=h([(0,n.w)("md-accordion")],t),e.ELEMENT=t}(s||(s={}))},37719:(e,t,i)=>{i.d(t,{ThemeManager:()=>
|
|
1048
|
+
`}};h([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"multiple",void 0),h([(0,l.query)('slot[name="accordion-item"]')],t.prototype,"accordionItemSlotElement",void 0),t=h([(0,n.w)("md-accordion")],t),e.ELEMENT=t}(s||(s={}))},37719:(e,t,i)=>{i.d(t,{ThemeManager:()=>o,themeManager:()=>r});var s=i(85314);class o{get isMomentumV2Enabled(){return"momentumV2"===this.themeName}constructor(e){this.isDarkMode=!1,this.themeName="lumos",this.isVisualRebrandEnabled=!1,this.isMomentumAvatarEnabled=!1,(0,s.makeObservable)(this,{isDarkMode:s.observable,themeName:s.observable,isVisualRebrandEnabled:s.observable,isMomentumAvatarEnabled:s.observable,isMomentumV2Enabled:s.computed,setDarkMode:s.action,setThemeName:s.action,setVisualRebrandEnabled:s.action,setMomentumAvatar:s.action,update:s.action}),e&&this.update(e)}update(e){void 0!==e.isDarkMode&&(this.isDarkMode=e.isDarkMode),void 0!==e.themeName&&(this.themeName=e.themeName),void 0!==e.isVisualRebrandEnabled&&(this.isVisualRebrandEnabled=e.isVisualRebrandEnabled),void 0!==e.isMomentumAvatarEnabled&&(this.isMomentumAvatarEnabled=e.isMomentumAvatarEnabled)}setDarkMode(e){this.isDarkMode=e}setThemeName(e){this.themeName=e}setVisualRebrandEnabled(e){this.isVisualRebrandEnabled=e}setMomentumAvatar(e){this.isMomentumAvatarEnabled=e}}const r=new o},37782:e=>{e.exports=h},38028:(e,t,i)=>{i.d(t,{Avatar:()=>s}),i(80528),i(61200),i(69788);var s,o=i(31890),r=i(26283),n=i(26272),a=i(41488),l=i(40333),d=i(23968),h=i(97822),p=i(8229),c=i(37782),u=i(22887),m=i(3553),y=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this._tabIndex=0,this.alt="",this.src="",this.label="",this.title="",this.color="",this.decrypting=!1,this.role="img",this.iconName="",this.failurePresence=!1,this.type="",this.newMomentum=!1,this.typing=!1,this.size=40,this.hasNotification=!1,this.clickable=!1,this.avatarStyle="default",this.state="rest",this.imageLoaded=!1,this.imageErrored=!1,this.presenceColor="",this.presenceIcon="",this.iconNameMap={"channel-chat":"chat-filled","channel-social":"sms-message-filled","channel-sms-inbound":"sms-filled","channel-sms-outbound":"sms-outgoing-filled","channel-email-inbound":"email-filled","channel-email-outbound":"email-outgoing-filled","channel-call":"handset-filled","channel-callback":"outgoing-call-legacy-filled","channel-headset":"headset-filled","channel-campaign":"campaign-management-bold","channel-emoji":"emoji-happy-filled","channel-webex":"webex-app-icon-color-container","channel-fb-messenger":"social-fbmessenger-color","channel-apple-chat":"apple-business-chat-color","channel-line":"social-line-color","channel-twitter-x":"social-x","channel-viber":"social-viber-color","channel-whats-app":"social-whatsapp-color","channel-we-chat":"social-wechat-color","channel-spam":"participant-unknown-bold"}}get tabIndex(){return this._tabIndex}set tabIndex(e){const t=this._tabIndex;this._tabIndex=e,this.requestUpdate("tabIndex",t)}static get styles(){return[n.A,m.A]}isPresenceType(e){return u.eO.includes(e)}firstUpdated(){const e=this.presenceType||(this.isPresenceType(this.type)?this.type:"");if(e){const{presenceColor:t,presenceIcon:i}=(0,u.E0)(e,this.failurePresence,this.newMomentum);this.presenceColor=t,this.presenceIcon=i}}updated(e){super.updated(e);const t=this.presenceType||(this.isPresenceType(this.type)?this.type:"");if(t&&(e.has("type")||e.has("presenceType")||e.has("newMomentum"))){const{presenceColor:e,presenceIcon:i}=(0,u.E0)(t,this.failurePresence,this.newMomentum);this.presenceColor=e,this.presenceIcon=i}e.has("role")&&this.style.setProperty("--avatar-cursor","button"===this.role?"pointer":"default")}get avatarClassMap(){return Object.assign(Object.assign({},this.newMomentum&&"bot"!==this.type||!this.type?{}:{[`md-avatar--${this.type}`]:!0}),{[`md-avatar--${this.size}`]:!!this.size,[`md-avatar--${this.color}`]:!!this.color})}get avatarLetterClassMap(){return{"md-decrypting":this.decrypting,[`md-avatar--${this.color}`]:this.color,"new-momentum":this.newMomentum}}get avatarStyleMap(){return{[`md-avatar--${this.color}`]:this.color}}get pretifyTitle(){if(this.title.length){const e=this.title.trim().split(" ");return 1===e.length?e[0].charAt(0):e[0].charAt(0)+e[e.length-1].charAt(0)}return this.title}get chatIconName(){return"chat-filled"}getIconName(e){return this.iconNameMap[e]||""}get chatIconSize(){return this.iconSize}get iconSize(){return(this.size/2).toString()}get renderIsTyping(){return"typing"===this.type||this.typing?a.html` <md-loading></md-loading> `:l.nothing}get avatarLetter(){return this.title?a.html`
|
|
1048
1049
|
<span class="md-avatar__letter ${(0,d.classMap)(this.avatarLetterClassMap)}">
|
|
1049
1050
|
${this.pretifyTitle}
|
|
1050
1051
|
<slot></slot>
|
|
@@ -1059,8 +1060,8 @@
|
|
|
1059
1060
|
></md-icon>
|
|
1060
1061
|
</span>
|
|
1061
1062
|
`}get avatarImage(){return a.html`
|
|
1062
|
-
${(0,
|
|
1063
|
-
`}loadImage(){return e=this,t=void 0,s=function*(){return new Promise(((e,t)=>{const i=document.createElement("img");i.src=this.src,i.alt=this.alt,i.onload=()=>e(i),i.onerror=e=>t(e),i.classList.add("md-avatar__img"),i.classList.toggle("md-avatar__img--hidden",!this.imageLoaded)}))},new((i=void 0)||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}));var e,t,i,s}handleImageLoad(){this.imageLoaded=!0}handleImageError(){this.imageErrored=!0}handleKeyDown(e){if(!this.clickable)return;const{code:t}=e;(0,r.o)(t)&&this.dispatchEvent(new CustomEvent("button-keydown",{composed:!0,bubbles:!0,detail:{srcEvent:e}}))}handleClick(e){this.clickable&&(this.clickFunction
|
|
1063
|
+
${(0,c.until)(this.loadImage().then((e=>(this.handleImageLoad(),a.html` ${e} `))).catch((()=>this.handleImageError())),a.html` ${this.iconName?this.avatarIcon:this.title?a.html` ${this.avatarLetter} `:l.nothing} `)}
|
|
1064
|
+
`}loadImage(){return e=this,t=void 0,s=function*(){return new Promise(((e,t)=>{const i=document.createElement("img");i.src=this.src,i.alt=this.alt,i.onload=()=>e(i),i.onerror=e=>t(e),i.classList.add("md-avatar__img"),i.classList.toggle("md-avatar__img--hidden",!this.imageLoaded)}))},new((i=void 0)||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}));var e,t,i,s}handleImageLoad(){this.imageLoaded=!0}handleImageError(){this.imageErrored=!0}handleKeyDown(e){if(!this.clickable)return;const{code:t}=e;(0,r.o)(t)&&this.dispatchEvent(new CustomEvent("button-keydown",{composed:!0,bubbles:!0,detail:{srcEvent:e}}))}handleClick(e){var t;this.clickable&&(null===(t=this.clickFunction)||void 0===t||t.call(this),this.dispatchEvent(new CustomEvent("button-click",{composed:!0,bubbles:!0,detail:{srcEvent:e}})))}getBrandOrDesignIconSet(e){return new Set(["webex-app-icon-color-container","social-fbmessenger-color","apple-business-chat-color","social-line-color","social-viber-color","social-x","social-whatsapp-color","social-wechat-color"]).has(e)?"momentumBrandVisuals":"momentumDesign"}get avatarContent(){return this.src&&!this.imageErrored?this.avatarImage:this.iconName?this.avatarIcon:this.title?this.avatarLetter:l.nothing}renderPresence(){return this.newMomentum&&(this.presenceType||this.type)&&"self"!==this.type&&this.presenceIcon?a.html`
|
|
1064
1065
|
<md-presence
|
|
1065
1066
|
class="avatar-presence"
|
|
1066
1067
|
name="${this.presenceIcon}"
|
|
@@ -1097,14 +1098,14 @@
|
|
|
1097
1098
|
aria-label=${(0,h.ifDefined)(this.label)}
|
|
1098
1099
|
>
|
|
1099
1100
|
${"self"===this.type?a.html`
|
|
1100
|
-
<span class="md-avatar__self" style=${(0,
|
|
1101
|
+
<span class="md-avatar__self" style=${(0,p.styleMap)(this.avatarStyleMap)}>
|
|
1101
1102
|
<md-icon .name=${this.chatIconName} .iconSet=${"momentumDesign"} .size=${this.chatIconSize}></md-icon>
|
|
1102
1103
|
</span>
|
|
1103
1104
|
`:this.renderAvatarContent()}
|
|
1104
1105
|
${this.hasNotification?a.html` <span class="md-avatar__notification-badge"></span> `:l.nothing}
|
|
1105
1106
|
${this.renderPresence()}
|
|
1106
1107
|
</div>
|
|
1107
|
-
`}};
|
|
1108
|
+
`}};y([(0,a.property)({type:Number,attribute:"tab-index",reflect:!0})],t.prototype,"tabIndex",null),y([(0,a.property)({type:String})],t.prototype,"alt",void 0),y([(0,a.property)({type:String})],t.prototype,"src",void 0),y([(0,a.property)({type:String})],t.prototype,"label",void 0),y([(0,a.property)({type:String})],t.prototype,"title",void 0),y([(0,a.property)({type:String})],t.prototype,"color",void 0),y([(0,a.property)({type:Boolean})],t.prototype,"decrypting",void 0),y([(0,a.property)({type:String})],t.prototype,"role",void 0),y([(0,a.property)({type:String,attribute:"icon-name"})],t.prototype,"iconName",void 0),y([(0,a.property)({type:Boolean})],t.prototype,"failurePresence",void 0),y([(0,a.property)({type:String})],t.prototype,"type",void 0),y([(0,a.property)({type:String,attribute:"presence-type"})],t.prototype,"presenceType",void 0),y([(0,a.property)({type:Boolean})],t.prototype,"newMomentum",void 0),y([(0,a.property)({type:Boolean})],t.prototype,"typing",void 0),y([(0,a.property)({type:Number})],t.prototype,"size",void 0),y([(0,a.property)({type:Boolean,attribute:"has-notification"})],t.prototype,"hasNotification",void 0),y([(0,a.property)({type:Boolean})],t.prototype,"clickable",void 0),y([(0,a.property)({attribute:!1})],t.prototype,"clickFunction",void 0),y([(0,a.property)({type:String,attribute:"avatar-style"})],t.prototype,"avatarStyle",void 0),y([(0,a.property)({type:String})],t.prototype,"state",void 0),y([(0,a.internalProperty)()],t.prototype,"imageLoaded",void 0),y([(0,a.internalProperty)()],t.prototype,"imageErrored",void 0),y([(0,a.internalProperty)()],t.prototype,"presenceColor",void 0),y([(0,a.internalProperty)()],t.prototype,"presenceIcon",void 0),t=y([(0,o.w)("md-avatar")],t),e.ELEMENT=t}(s||(s={}))},40333:e=>{e.exports=i},40428:(e,t,i)=>{i.d(t,{Table:()=>s}),i(61200);var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(17518),d=i(28187),h=i.n(d),p=i(43604),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.tabledata="",this.zebra=!1,this.clean=!1,this.sorting=!1,this.nodata="No data Loaded",this.stickheader=!1,this.label="Table",this.noBorders=!1,this.format="default",this.warning=[],this.errors=[],this.sort={columnName:"",sortting:!1},this.csvData=void 0,this.config={quoteChar:'"',escapeChar:'""',header:!1,preview:0,comments:!1,step:void 0,complete:void 0}}connectedCallback(){super.connectedCallback(),this.results=h().parse(this.tabledata,this.config),this.headerRow=this.results.data[0],this.csvData=this.results.data.slice(1,this.results.data.length),this.requestUpdate("tabledata"),this.linkCellItems()}get rowItem(){return this.rowTable}linkCellItems(){const e=this.rowTable;null==e||e.forEach(((e,t)=>{this.warning.forEach((i=>{t+1===i.row&&e.querySelectorAll('td[role="cell"').forEach(((e,t)=>{t+1===i.col&&(e.classList.add("warning"),e.insertAdjacentHTML("beforeend",'<md-icon name="warning-regular" size="24" iconSet="momentumDesign" color="var(--md-alert-warning-text-color)"></md-icon>'))}))})),this.errors.forEach((i=>{t+1===i.row&&e.querySelectorAll('td[role="cell"').forEach(((e,t)=>{t+1===i.col&&(e.classList.add("error"),e.insertAdjacentHTML("beforeend",'<md-icon name="clear-bold" size="24" iconSet="momentumDesign" color="var(--md-alert-error-text-color)"></md-icon>'))}))}))}))}sortTab(e,t){const i=e.target,s=Array.from(this.csvData),o=this.headerRow.indexOf(t);t!==this.sort.columnName||!0!==this.sort.sortting?(s.sort((function(e,t){const i=e[o].toLowerCase(),s=t[o].toLowerCase();return i>s?1:i<s?-1:0})),this.sort.sortting=!0,i.classList.remove("sortedZyx"),i.classList.add("sortedAbc")):(s.reverse(),this.sort.sortting=!1,i.classList.remove("sortedAbc"),i.classList.add("sortedZyx")),this.sort.columnName=t,this.csvData=s,this.requestUpdate("csvData")}update(e){super.update(e),e.has("tabledata")&&(this.results=h().parse(this.tabledata,this.config),this.headerRow=this.results.data[0],this.csvData=this.results.data.slice(1,this.results.data.length),this.linkCellItems())}static get styles(){return[r.A,p.A]}get tableClassMap(){return{"md-table--clean":this.clean,"md-table--no-borders":this.noBorders,"md-table--stripped":this.zebra,"md-table--sorting":this.sorting}}getSortTemplate(e){return this.sort.columnName!==e?a.nothing:n.html`
|
|
1108
1109
|
<md-icon
|
|
1109
1110
|
name=${this.sort.sortting?"sort-descending-bold":"sort-ascending-bold"}
|
|
1110
1111
|
iconSet="momentumDesign"
|
|
@@ -1146,11 +1147,11 @@
|
|
|
1146
1147
|
</table>
|
|
1147
1148
|
`:n.html` <p>${this.nodata}</p> `}
|
|
1148
1149
|
</div>
|
|
1149
|
-
`}};
|
|
1150
|
+
`}};c([(0,n.property)({type:String})],t.prototype,"tabledata",void 0),c([(0,n.property)({type:Boolean})],t.prototype,"zebra",void 0),c([(0,n.property)({type:Boolean})],t.prototype,"clean",void 0),c([(0,n.property)({type:Boolean})],t.prototype,"sorting",void 0),c([(0,n.property)({type:String})],t.prototype,"nodata",void 0),c([(0,n.property)({type:Boolean})],t.prototype,"stickheader",void 0),c([(0,n.property)({type:String})],t.prototype,"label",void 0),c([(0,n.property)({type:Boolean,attribute:"no-borders"})],t.prototype,"noBorders",void 0),c([(0,n.property)({type:String})],t.prototype,"format",void 0),c([(0,n.property)({type:Array})],t.prototype,"warning",void 0),c([(0,n.property)({type:Array})],t.prototype,"errors",void 0),c([(0,n.internalProperty)()],t.prototype,"sort",void 0),c([(0,n.internalProperty)()],t.prototype,"csvData",void 0),c([(0,n.queryAll)('.md-table__body tr[role="row"]')],t.prototype,"rowTable",void 0),t=c([(0,o.w)("md-table")],t),e.ELEMENT=t}(s||(s={}))},41488:t=>{t.exports=e},41891:e=>{e.exports=w},45001:e=>{e.exports=g},45629:(e,t,i)=>{i.d(t,{ButtonGroup:()=>s});var s,o=i(90195),r=i(3001),n=i(26272),a=i(41488),l=i(71250),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.TS)((0,r.yC)(a.LitElement))){constructor(){super(...arguments),this.active=0,this.tabIndex=0,this._disabled=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.setAttribute("aria-disabled",`${e}`),this.tabIndex=e?-1:0,this.requestUpdate("disabled",t)}get slotElement(){return this.buttonSlot}static get styles(){return[n.A,l.A]}firstUpdated(e){super.firstUpdated(e),this.setAttribute("role","group")}setButtonTabIndex(){this.slotted.forEach((e=>e.tabIndex=-1))}updated(e){super.updated(e),e.has("slotted")&&(this.setButtonTabIndex(),this.setFirstActive())}get selectedBtnValue(){return this.slotted[this.active].value}notifySelectedChange(){this.dispatchEvent(new CustomEvent("button-group-change",{detail:{selected:this.selectedBtnValue},bubbles:!0,composed:!0})),this.dispatchEvent(new CustomEvent("focus-visible",{composed:!0,bubbles:!0}))}setSelected(e){var t,i;const s=this.findSelectedBtnIndex();-1!==s&&s!==e&&(null===(t=this.slotted[s])||void 0===t||t.toggleAttribute("selected",!1)),null===(i=this.slotted[e])||void 0===i||i.toggleAttribute("selected",!0)}setFirstActive(){-1===this.findSelectedBtnIndex()&&this.setSelected(this.active)}findBtnIndex(e){const t=e.composedPath();return this.slotted.findIndex((e=>t.includes(e)))}findSelectedBtnIndex(){return this.slotted.findIndex((e=>e.hasAttribute("selected")))}isBtnDisabled(e){return this.slotted[e].disabled}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("click",this.handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeyDown),this.removeEventListener("click",this.handleClick)}switchBtnOnArrowPress(e,t=1){const i=this.getAvailableSelectedIndex(e,t);-1!==i&&(this.active=i,this.setSelected(i),this.notifySelectedChange())}getAvailableSelectedIndex(e,t=1){const i=this.slotted.length;for(let s=0,o=e;s<i;s+=1,o+=t){o<0?o=i-1:o>=i&&(o=0);const e=this.slotted[o];if(this.isFocusable(e))return o}return-1}isFocusable(e){return!e.hasAttribute("disabled")&&!e.hasAttribute("hidden")}handleClick(e){const t=this.findBtnIndex(e);-1!==t&&(this.isBtnDisabled(t)||(this.active=t,this.setSelected(t),this.notifySelectedChange()))}handleKeyDown(e){const{code:t}=e;switch(t){case o.Uz.Enter:case o.Uz.Space:this.isBtnDisabled(this.active)||(this.setSelected(this.active),this.notifySelectedChange());break;case o.Uz.ArrowLeft:0===this.active?this.switchBtnOnArrowPress(this.slotted.length-1,-1):this.switchBtnOnArrowPress(this.active-1,-1);break;case o.Uz.ArrowRight:this.active===this.slotted.length-1?this.switchBtnOnArrowPress(0):this.switchBtnOnArrowPress(this.active+1)}}render(){return a.html`
|
|
1150
1151
|
<div role="group" class="md-button-group" part="button-group">
|
|
1151
1152
|
<slot name="button"></slot>
|
|
1152
1153
|
</div>
|
|
1153
|
-
`}};d([(0,a.property)({type:Number,reflect:!0})],t.prototype,"active",void 0),d([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),d([(0,a.query)("slot[name='button']")],t.prototype,"buttonSlot",void 0),d([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),t=d([(0,r.wW)("md-button-group")],t),e.ELEMENT=t}(s||(s={}))},
|
|
1154
|
+
`}};d([(0,a.property)({type:Number,reflect:!0})],t.prototype,"active",void 0),d([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),d([(0,a.query)("slot[name='button']")],t.prototype,"buttonSlot",void 0),d([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),t=d([(0,r.wW)("md-button-group")],t),e.ELEMENT=t}(s||(s={}))},46312:(e,t,i)=>{i.d(t,{Coachmark:()=>s}),i(96798);var s,o=i(3001),r=i(31890),n=i(66677),a=i(26272),l=i(41488),d=i(23968),h=i(82043),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.dY)(l.LitElement)){constructor(){super(...arguments),this.message="",this.actionname="Next",this.hidebutton=!1,this.placement="auto",this.show=!1,this.color="default",this.slotContent=null}connectedCallback(){super.connectedCallback()}notifyCoachCreate(){this.dispatchEvent(new CustomEvent("coach-create",{bubbles:!0,composed:!0,detail:{placement:this.placement,reference:this.reference,popper:this.popper}}))}coachAction(){this.dispatchEvent(new CustomEvent("coach-action",{bubbles:!0,composed:!0,detail:{popper:this.popper}}))}handleSlotChange(e){const t=e.target;if(t){const e=t.assignedElements({flatten:!0});e.length&&(this.slotContent=e)}}update(e){var t;super.update(e),e.has("show")&&this.show&&(this.setFocusableElements(),(null===(t=this.focusableElements)||void 0===t?void 0:t.length)&&this.focusableElements[0].focus())}get coachWrapClassMap(){return{"md-coachmark--active":!!this.show}}get coachClassMap(){return{[`md-coachmark__popper--${this.placement}`]:!!this.placement,[`md-coachmark__popper--${this.color}`]:!!this.color}}static get styles(){return[a.A,h.A]}coachmarkContentTemplate(){return l.html`
|
|
1154
1155
|
<div class="md-coachmark__content">
|
|
1155
1156
|
${this.message?this.message:l.html` <slot name="coachmark-content" @slotchange=${this.handleSlotChange}></slot> `}
|
|
1156
1157
|
<div class="md-coachmark__action">
|
|
@@ -1171,19 +1172,19 @@
|
|
|
1171
1172
|
<slot></slot>
|
|
1172
1173
|
</div>
|
|
1173
1174
|
</div>
|
|
1174
|
-
`}};
|
|
1175
|
+
`}};p([(0,l.property)({type:String})],t.prototype,"message",void 0),p([(0,l.property)({type:String})],t.prototype,"actionname",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"hidebutton",void 0),p([(0,l.property)({type:String})],t.prototype,"placement",void 0),p([(0,l.property)({type:Boolean})],t.prototype,"show",void 0),p([(0,l.property)({type:String})],t.prototype,"color",void 0),p([(0,l.query)(".md-coachmark__popper")],t.prototype,"popper",void 0),p([(0,l.query)(".md-coachmark__reference")],t.prototype,"reference",void 0),t=p([(0,r.w)("md-coachmark")],t),e.ELEMENT=t}(s||(s={}))},49256:(e,t,i)=>{i.d(t,{TimePicker:()=>g}),i(4928),i(96408);var s=i(90195),o=i(31890),r=i(81625),n=i(74548),a=i(26272),l=i(41488),d=i(40333),h=i(23968),p=i(97822),c=i(65796),u=i(17875),m=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const y=[s.R5.HOUR,s.R5.MINUTE,s.R5.SECOND,s.R5.AM_PM],b=[s.R5.HOUR,s.R5.MINUTE,s.R5.SECOND],v={[s.R5.HOUR]:"HH",[s.R5.MINUTE]:"MM",[s.R5.SECOND]:"SS",[s.R5.AM_PM]:"AM"};var g;!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this.twoDigitAutoTab=!1,this.twentyFourHourFormat=!1,this.timeSpecificity=s.R5.SECOND,this.locale="en-US",this.value="00:00:00-08:00",this.finalTwentyFourFormat=!1,this.timeObject=(0,r.tB)(),this.tabNext=!1,this.timeValue={[s.R5.HOUR]:"12",[s.R5.MINUTE]:"00",[s.R5.SECOND]:"00",[s.R5.AM_PM]:"AM"},this.timeValidity={[s.R5.HOUR]:!0,[s.R5.MINUTE]:!0,[s.R5.SECOND]:!0,[s.R5.AM_PM]:!0},this.addLeadingZeros=e=>{if(e){if(0===e.length)return"00";if(1===e.length)return`0${e}`}return e},this.formatAndValidate=(e,t)=>{if(e&&(this.updateValidity(e,t),this.timeValidity[t]))return this.addLeadingZeros(e)},this.getLocaleTimeFormat=e=>{const t=e.toFormat("tt"),[,i]=t.split(" ");return!i},this.updateTimeValues=()=>{let e;e=this.finalTwentyFourFormat?this.timeObject.toFormat("HH:mm:ss"):this.timeObject.toFormat("tt");const[t,i]=e.split(" "),o=t.split(":");b.forEach((e=>{const t=this.formatAndValidate(o.shift(),e);t&&(e===s.R5.HOUR&&i&&(this.timeValue[s.R5.AM_PM]=i),this.timeValue[e]=t)}))},this.updateValidity=(e,t)=>{let i=!0;const o=t=>{null===e.match(t)&&(i=!1)};switch(t){case s.R5.HOUR:this.finalTwentyFourFormat?o(new RegExp(n.b.twentyFourHourString)):o(new RegExp(n.b.hourString));break;case s.R5.MINUTE:case s.R5.SECOND:o(new RegExp(n.b.minuteSecondString));break;case s.R5.AM_PM:o(new RegExp(n.b.amPmString))}this.timeValidity[t]=i},this.to12HourFormat=(e,t)=>{if(!this.finalTwentyFourFormat&&this.timeValidity[s.R5.HOUR]&&this.timeValidity[s.R5.AM_PM]){let i=Number(t);return"PM"===e?i=12+i%12:i%=12,i}},this.isEntireTimeValid=()=>Object.values(this.timeValidity).every((e=>e)),this.updateTimeUnit=e=>{var t,i,o;this.updateValidity(this.timeValue[e],e),this.timeObject&&this.timeValidity[e]&&(e!==s.R5.AM_PM?this.timeObject=null===(t=this.timeObject)||void 0===t?void 0:t.set({[e]:this.timeValue[e]}):this.timeObject=null===(i=this.timeObject)||void 0===i?void 0:i.set({hour:this.to12HourFormat(this.timeValue[s.R5.AM_PM],this.timeValue[s.R5.HOUR])}),this.isEntireTimeValid()&&(this.timeObject=null===(o=this.timeObject)||void 0===o?void 0:o.set({hour:this.to12HourFormat(this.timeValue[s.R5.AM_PM],this.timeValue[s.R5.HOUR])}),this.value=this.timeObject.toISOTime({suppressMilliseconds:!0})||this.value,this.dispatchEvent(new CustomEvent("time-selection-change",{bubbles:!0,composed:!0,detail:{time:this.value,data:this.timeObject}}))))},this.formatTimeUnit=e=>{if(1===this.timeValue[e].length)"0"!==this.timeValue[e]&&(this.timeValue[e]="0"+this.timeValue[e]);else if(this.timeValue[e].length>2&&"0"===this.timeValue[e][0]){const t=this.timeValue[e].substring(1);RegExp(n.b.noPrecedingZerosString).test(t)&&(this.timeValue[e]=t)}this.requestUpdate()},this.messageType=e=>e?"":"error",this.generateTimeBox=e=>{const t=(i=this.finalTwentyFourFormat,{[s.R5.HOUR]:{type:"number",min:i?0:1,max:i?23:12},[s.R5.MINUTE]:{type:"number",min:0,max:59},[s.R5.SECOND]:{type:"number",min:0,max:59},[s.R5.AM_PM]:{type:"text",min:void 0,max:void 0}})[e];var i;return l.html`
|
|
1175
1176
|
${e===s.R5.MINUTE||e===s.R5.SECOND?l.html` <span class="colon-separator">:</span> `:d.nothing}
|
|
1176
1177
|
<md-input
|
|
1177
1178
|
newMomentum
|
|
1178
1179
|
select-when-in-focus
|
|
1179
1180
|
class="${`time-input-box ${e}`}"
|
|
1180
|
-
id="time-${
|
|
1181
|
+
id="time-${y.findIndex((t=>t===e))+1}"
|
|
1181
1182
|
value="${this.timeValue[e]}"
|
|
1182
1183
|
type="${t.type}"
|
|
1183
|
-
min=${(0,
|
|
1184
|
-
max=${(0,
|
|
1184
|
+
min=${(0,p.ifDefined)(t.min)}
|
|
1185
|
+
max=${(0,p.ifDefined)(t.max)}
|
|
1185
1186
|
maxLength=${2}
|
|
1186
|
-
placeholder="${
|
|
1187
|
+
placeholder="${v[e]}"
|
|
1187
1188
|
@input-change="${t=>this.handleTimeChange(t,e)}"
|
|
1188
1189
|
@input-keydown="${t=>this.handleTimeKeyDown(t,e)}"
|
|
1189
1190
|
@input-blur="${t=>this.handleTimeBlur(t,e)}"
|
|
@@ -1206,7 +1207,7 @@
|
|
|
1206
1207
|
@change-selected="${e=>this.handleTimeChange(e,s.R5.AM_PM)}"
|
|
1207
1208
|
>
|
|
1208
1209
|
</md-combobox>
|
|
1209
|
-
`}}get timePickerClassMap(){return{"twenty-four-hour-format":this.finalTwentyFourFormat}}updated(e){if(super.updated(e),this.value&&(e.has("value")||e.has("locale")||e.has("twentyFourHourFormat"))){this.timeObject=
|
|
1210
|
+
`}}get timePickerClassMap(){return{"twenty-four-hour-format":this.finalTwentyFourFormat}}updated(e){if(super.updated(e),this.value&&(e.has("value")||e.has("locale")||e.has("twentyFourHourFormat"))){this.timeObject=c.DateTime.fromISO(this.value,{locale:this.locale});const e=this.getLocaleTimeFormat(this.timeObject);this.finalTwentyFourFormat=this.twentyFourHourFormat||e,this.value=this.timeObject.toISOTime({suppressMilliseconds:!0}),this.updateTimeValues()}}handleTimeChange(e,t){var i,o,r;this.timeValue[t]=null===(i=null==e?void 0:e.detail)||void 0===i?void 0:i.value,this.requestUpdate(),this.formatTimeUnit(t);const n=this.timeValue[t];if(this.twoDigitAutoTab&&this.tabNext&&(t!==s.R5.AM_PM&&2===n.length&&"0"!==n[0]||"00"===n)){e.preventDefault();const t=null==e?void 0:e.target,i=null===(o=this.shadowRoot)||void 0===o?void 0:o.querySelectorAll("md-input, md-combobox");if(i){const e=Array.prototype.findIndex.call(i,(e=>null==t?void 0:t.isEqualNode(e))),s=(e+1)%i.length;if(e<i.length-1){const e=null===(r=i[s].shadowRoot)||void 0===r?void 0:r.querySelector("input");null==e||e.focus()}}}else t===s.R5.AM_PM&&this.updateTimeUnit(t);e.stopPropagation(),this.dispatchEvent(new CustomEvent(`${t}-change`,{bubbles:!0,composed:!0,detail:{srcEvent:e,value:`${this.timeValue[t]}`,isValid:this.timeValidity[t]}}))}handleTimeKeyDown(e,t){var i;const o=null===(i=null==e?void 0:e.detail)||void 0===i?void 0:i.srcEvent;if(!o)return void console.warn("srcEvent is undefined");const{key:r}=o;r===s.Uz.ArrowDown||r===s.Uz.ArrowUp?this.tabNext=!1:this.tabNext=!0,this.timeValidity[t]=!0,this.requestUpdate(),e.stopPropagation(),this.dispatchEvent(new CustomEvent(`${t}-keydown`,{bubbles:!0,composed:!0,detail:{srcEvent:e,value:`${this.timeValue[t]}`}}))}handleTimeBlur(e,t){"0"===this.timeValue[t]&&(this.timeValue[t]="00"),this.updateTimeUnit(t),this.requestUpdate(),e.stopPropagation(),this.dispatchEvent(new CustomEvent(`${t}-blur`,{bubbles:!0,composed:!0,detail:{srcEvent:e,time:this.value,isValid:this.timeValidity[t]}}))}static get styles(){return[a.A,u.A]}render(){return l.html`
|
|
1210
1211
|
<div class="md-timepicker ${(0,h.classMap)(this.timePickerClassMap)}">
|
|
1211
1212
|
<div class="time-inputs-wrapper">
|
|
1212
1213
|
${this.generateTimeBox(s.R5.HOUR)}
|
|
@@ -1215,10 +1216,10 @@
|
|
|
1215
1216
|
${this.finalTwentyFourFormat?d.nothing:this.generateAmPmComboBox()}
|
|
1216
1217
|
</div>
|
|
1217
1218
|
</div>
|
|
1218
|
-
`}};m([(0,l.property)({type:Boolean,attribute:"two-digit-auto-tab"})],t.prototype,"twoDigitAutoTab",void 0),m([(0,l.property)({type:Boolean,attribute:"twenty-four-hour-format",reflect:!0})],t.prototype,"twentyFourHourFormat",void 0),m([(0,l.property)({type:String})],t.prototype,"timeSpecificity",void 0),m([(0,l.property)({type:String})],t.prototype,"locale",void 0),m([(0,l.property)({type:String,reflect:!0})],t.prototype,"value",void 0),m([(0,l.internalProperty)()],t.prototype,"finalTwentyFourFormat",void 0),m([(0,l.internalProperty)()],t.prototype,"timeObject",void 0),m([(0,l.internalProperty)()],t.prototype,"tabNext",void 0),m([(0,l.internalProperty)()],t.prototype,"timeValue",void 0),m([(0,l.internalProperty)()],t.prototype,"timeValidity",void 0),t=m([(0,o.w)("md-timepicker")],t),e.ELEMENT=t}(g||(g={}))},50226:(e,t,i)=>{i.d(t,{Tabs:()=>O}),i(61200),i(11323),i(83192);var s=i(90195),o=i(3001),r=i(66677),n=i(59164),a=i(26272),l=i(41488),d=i(40333),h=i(23968),c=i(22818),p=i(8229),u=i(19239),m=i(41891),v=i.n(m),b=i(97103),y=i(30076),g=i(16643),f=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},w=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};const x="tab-more",C="more-menu-copy-",S="visibleToVisible",$="visibleToHidden",E="hiddenToVisible",k="hiddenToHidden",T="previous",I="next",A="fromMoreTabs";var O;!function(e){let t=class extends((0,o.UM)((0,o.Io)((0,o.TS)(l.LitElement)))){constructor(){super(...arguments),this.justified=!1,this.hugTabs=!1,this.overflowLabel="More Tabs",this.draggable=!1,this.direction="horizontal",this.moreItemsScrollLimit=Number.MAX_SAFE_INTEGER,this._selectedIndex=0,this.delay=0,this.animation=100,this.ghostClass="",this.chosenClass="",this.forceFallback=!1,this.fallbackClass="",this.tabsId="",this.persistSelection=!1,this.compUniqueId="",this.type="line",this.newMomentum=!1,this.variant="ghost",this.isMoreTabMenuVisible=!1,this.isMoreTabMenuMeasured=!1,this.isMoreTabMenuOpen=!1,this.isMoreTabMenuSelected=!1,this.isMoreTabMenuScrollable=!1,this.moreTabMenuOffsetWidth=0,this.moreTabMenuMaxHeight=null,this.tabsViewportDataList=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.noTabsVisible=!1,this.defaultTabsOrderArray=[],this.tabsOrderPrefsArray=[],this.isMoreTabTruncated=!1,this.tabs=[],this.panels=[],this.tabsCopy=[],this.tabsHash={},this.tabsCopyHash={},this.tabsIdxHash={},this.tabsVisibleIdxHash={},this.tabsHiddenIdxHash={},this.visibleTabsSortableInstance=null,this.hiddenTabsSortableInstance=null,this.handleOnDragEnd=e=>w(this,void 0,void 0,(function*(){var t,i,s,o,r,n,a,l,d,h;e.stopPropagation();const c=e.oldIndex,p=e.newIndex,u=[...this.tabsFilteredAsVisibleList],m=[...this.tabsFilteredAsHiddenList],v=this.getDragDirection(e);if(void 0!==c&&void 0!==p){switch(v){case $:{null===(i=null===(t=this.hiddenTabsContainerElement)||void 0===t?void 0:t.querySelector("#"+e.item.id))||void 0===i||i.remove();const s=u[c],o=m.slice(-1)[0],r=p===this.tabsFilteredAsHiddenList.length?p-1:p;m.splice(r,0,s),m.pop();const n=u.filter((t=>t.id!==this.getNormalizedTabId(e.item.id)));n.push(o),this.tabsFilteredAsVisibleList=[...n],this.tabsFilteredAsHiddenList=[...m];break}case S:{const e=u[c];u.splice(c,1),u.splice(p,0,e),this.tabsFilteredAsVisibleList=u,p===this.tabsFilteredAsVisibleList.length-1&&(null===(o=null===(s=this.visibleTabsContainerElement)||void 0===s?void 0:s.children[this.visibleTabsContainerElement.children.length-1])||void 0===o||o.remove());const t=this.visibleTabsContainerElement.children[c],i=this.visibleTabsContainerElement.children[p];if(!t||!i)return;null===(r=this.visibleTabsContainerElement)||void 0===r||r.replaceChild(i,t),null===(n=this.visibleTabsContainerElement)||void 0===n||n.insertBefore(t,i);break}case E:{null===(l=null===(a=this.visibleTabsContainerElement)||void 0===a?void 0:a.querySelector("#"+e.item.id))||void 0===l||l.remove();const t=m[c],i=u.slice(-1)[0];m.splice(c,1),m.splice(0,0,i);const s=p===this.tabsFilteredAsVisibleList.length?p-1:p;u.splice(s,0,t),u.pop(),this.tabsFilteredAsVisibleList=u,this.tabsFilteredAsHiddenList=m;break}case k:{const e=m[c];m.splice(c,1),m.splice(p,0,e),this.tabsFilteredAsHiddenList=m,p===this.tabsFilteredAsHiddenList.length-1&&(null===(h=null===(d=this.hiddenTabsContainerElement)||void 0===d?void 0:d.children[this.hiddenTabsContainerElement.children.length-1])||void 0===h||h.remove());break}}if(this.compUniqueId){const e=[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList],t=e.findIndex((e=>e.selected));this.storeSelectedTabIndex(t),this.tabsOrderPrefsArray=e.map((e=>e.name)),localStorage.setItem(this.compUniqueId,this.tabsOrderPrefsArray.join(","))}}}))}get selectedIndex(){return this._selectedIndex}set selectedIndex(e){this._selectedIndex=e}generateOptions(){return{group:"shared",animation:10,swapThreshold:1,draggable:"md-tab",direction:this.direction,forceFallback:this.forceFallback,fallbackClass:this.fallbackClass,ghostClass:this.ghostClass,chosenClass:this.chosenClass,onEnd:this.handleOnDragEnd}}get currentTabsLayout(){return"horizontal"===this.direction?[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList]:this.tabs}getCopyTabId(e){var t;return(null===(t=e.id)||void 0===t?void 0:t.startsWith(C))?`${C}${e.id}`:e.id}getAriaControlId(e){var t,i;return(null===(t=e.id)||void 0===t?void 0:t.startsWith(C))?`${C}${e.id}`:"tab_panel_"+(null===(i=e.id)||void 0===i?void 0:i.substring(4))}getTabIndex(e){var t,i;return this.isMoreTabMenuVisible&&0===this.getCurrentIndex(null==e?void 0:e.id)&&this.selected>(null===(t=this.tabsFilteredAsVisibleList)||void 0===t?void 0:t.length)-1||(null===(i=this.tabsFilteredAsVisibleList[this.selected])||void 0===i?void 0:i.id)===e.id?0:-1}getNormalizedTabId(e){return e.replace(C,"")}static get styles(){return[a.A,y.A]}ensureTabsUpdateComplete(e){return w(this,void 0,void 0,(function*(){const t=e.map((e=>void 0!==e.updateComplete?e.updateComplete:null)).filter((e=>null!==e));t.length&&(yield Promise.all(t))}))}measureTabsOffsetWidth(){return this.justified||"vertical"===this.direction?this.tabs.map((e=>{e.setAttribute("measuringrealwidth","");const t=e.closable?e.offsetWidth+g.TAB_CROSS_WIDTH:e.offsetWidth;return e.removeAttribute("measuringrealwidth"),t})):this.tabs.map((e=>e.closable?e.offsetWidth+g.TAB_CROSS_WIDTH:e.offsetWidth))}updateIsMoreTabTruncated(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector(".md-menu-overlay__overflow-label");if(t){const e=t.scrollWidth>t.clientWidth;this.isMoreTabTruncated!=e&&(this.isMoreTabTruncated=e)}}measureHiddenTabsCopiesOffsetHeight(){return this.tabsCopy.map((e=>e.offsetHeight))}manageOverflow(){return w(this,void 0,void 0,(function*(){var e,t;if("vertical"!==this.direction){let i;i=0===this.tabsFilteredAsVisibleList.length&&0===this.tabsFilteredAsHiddenList.length?[...this.tabs]:[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList],i.forEach((e=>{var t,i,s,o,r;if((null===(t=e.children)||void 0===t?void 0:t.length)&&0===(null===(s=null===(i=e.children[0])||void 0===i?void 0:i.children)||void 0===s?void 0:s.length)){const t=null===(o=null==e?void 0:e.querySelector("slot"))||void 0===o?void 0:o.assignedNodes({flatten:!0})[0].cloneNode(!0);t&&(t.classList.add("tab-content"),null===(r=null==e?void 0:e.children[0])||void 0===r||r.appendChild(t))}}));const s=i.length;if(this.tabsListElement&&s){const o=(null===(e=this.tabsSettingsElement)||void 0===e?void 0:e.offsetWidth)?this.tabsListElement.offsetWidth-(null===(t=this.tabsSettingsElement)||void 0===t?void 0:t.offsetWidth):this.tabsListElement.offsetWidth;yield this.ensureTabsUpdateComplete(this.tabs);const r=this.measureTabsOffsetWidth(),n=i.reduce(((e,t,i)=>e+r[i]),0);if(n){yield this.setupMoreTab();let e=!0;o<n&&(e=!1);const t=[];let a=0;i.forEach(((i,n)=>{a+=r[n];const l=!e&&a+(n<s-1?this.moreTabMenuOffsetWidth:0)>o;t.push({isTabInViewportHidden:l,tabOffsetWidth:r[n]})})),this.tabsViewportDataList=t,this.tabsViewportDataList.forEach(((e,t)=>this.tabs[t].viewportHidden=e.isTabInViewportHidden)),this.isMoreTabMenuVisible=!!this.tabsViewportDataList.find((e=>e.isTabInViewportHidden)),this.tabsFilteredAsVisibleList=i.filter(((e,t)=>!this.tabsViewportDataList[t].isTabInViewportHidden)),this.tabsVisibleIdxHash=this.tabsFilteredAsVisibleList.reduce(((e,t,i)=>(e[t.id]=i,e)),{}),this.tabsFilteredAsHiddenList=i.filter(((e,t)=>this.tabsViewportDataList[t].isTabInViewportHidden)),this.tabsHiddenIdxHash=this.tabsFilteredAsHiddenList.reduce(((e,t,i)=>(e[t.id]=i,e)),{})}}this.updateIsMoreTabMenuSelected();const o=this.tabsFilteredAsHiddenList.find((e=>!e.disabled));this.updateHiddenIdPositiveTabIndex(o)}}))}updateIsMoreTabMenuSelected(){this.isMoreTabMenuSelected=!!this.tabsFilteredAsHiddenList.find((e=>e.selected))}updateHiddenIdPositiveTabIndex(e){this.tabHiddenIdPositiveTabIndex=e?e.id:void 0}sortTabsAndPanes(){if(!this.tabsOrderPrefsArray.length)return;const e=(e,t)=>{var i,s;const o=null!==(i=e.getAttribute("name"))&&void 0!==i?i:"",r=null!==(s=t.getAttribute("name"))&&void 0!==s?s:"";return this.tabsOrderPrefsArray.indexOf(o)-this.tabsOrderPrefsArray.indexOf(r)};this.tabs.sort(e),this.panels.sort(e)}linkPanelsAndTabs(){return w(this,void 0,void 0,(function*(){this.sortTabsAndPanes();const{tabs:e,panels:t}=this;if(0===e.length||0===t.length)return void console.warn("The tabs or panels count should't be equal zero.");e.length!==t.length&&console.warn(`The amount of tabs (${e.length}) doesn't match the amount of panels (${t.length}).`);const i="vertical"===this.direction;e.forEach(((e,s)=>{const o=(0,n.O)("tabs"),r="tab_"+o,a="tab_panel_"+o;e.setAttribute("id",r),e.setAttribute("aria-controls",a),e.selected=this.selected===s,e.vertical!==i&&(e.vertical=i),e.viewportHidden&&i&&(e.viewportHidden=!1);const l=t[s];l?(l.setAttribute("id",a),l.setAttribute("aria-labelledby",r),l.selected=this.selected===s,e.disabled&&(l.hidden=!0,l.selected=!1)):e.disabled=!0}));let s=this.selected;for(;s<e.length&&e[s].disabled;)s++;s=s===e.length?0:s,e[s].selected=!0,t[s].selected=!0,this.tabsHash=this.tabs.reduce(((e,t)=>(e[t.id]=t,e)),{}),this.tabsIdxHash=this.tabs.reduce(((e,t,i)=>(e[t.id]=i,e)),{})}))}get slotItem(){return this.tabSlotElement}filterSlotted(){return this.tabSlotElement.assignedElements()}handleResize(e){var t;null===(t=super.handleResize)||void 0===t||t.call(this,e),this.manageOverflow(),this.updateIsMoreTabTruncated()}getDragDirection(e){return e.from===this.visibleTabsContainerElement&&e.to===this.hiddenTabsContainerElement?$:e.from===this.visibleTabsContainerElement&&e.to===this.visibleTabsContainerElement?S:e.from===this.hiddenTabsContainerElement&&e.to===this.visibleTabsContainerElement?E:e.from===this.hiddenTabsContainerElement&&e.to===this.hiddenTabsContainerElement?k:void 0}makeTabCopyFocus(e){e&&e.focus()}handleTabClick(e){const{id:t}=e.detail;this.handleNewSelectedTab(t)}handleNewSelectedTab(e){const t=this.tabsHash[this.getNormalizedTabId(e)];if(t&&!t.disabled){const e=this.tabsIdxHash[t.id];-1!==e&&this.updateSelectedTab(e);{const e=this.tabsCopyHash[this.getCopyTabId(t)];e&&this.makeTabCopyFocus(e),this.updateHiddenIdPositiveTabIndex(t)}}}handleTabCrossClick(e){const{id:t}=e.detail;this.handleTabCloseEvent(t)}handleTabCloseClick(e){const{id:t}=e.detail;this.handleTabCloseEvent(t)}handleTabCloseEvent(e){var t,i;const s=this.tabsHash[this.getNormalizedTabId(e)];if(s&&!s.disabled&&("auto"===s.closable||"custom"===s.closable)){const s=this.tabsFilteredAsVisibleList.findIndex((t=>this.getNormalizedTabId(t.id)===this.getNormalizedTabId(e)));this.tabsFilteredAsVisibleList=this.tabsFilteredAsVisibleList.filter((t=>this.getNormalizedTabId(t.id)!==this.getNormalizedTabId(e))),null===(i=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.querySelector("#"+e))||void 0===i||i.remove(),0!==this.tabsFilteredAsHiddenList.length&&(this.tabsFilteredAsVisibleList.push(this.tabsFilteredAsHiddenList[0]),this.tabsFilteredAsHiddenList.splice(0,1)),0===this.tabsFilteredAsHiddenList.length&&(this.isMoreTabMenuVisible=!1,this.isMoreTabMenuMeasured=!1),this.handleUpdatedSeletedTabAfterCross(s)}}handleUpdatedSeletedTabAfterCross(e){var t;let i=e;for(;i<this.tabsFilteredAsVisibleList.length&&(null===(t=this.tabsFilteredAsVisibleList[i])||void 0===t?void 0:t.disabled);)i++;if(void 0===this.tabsFilteredAsVisibleList[i]||e===this.tabsFilteredAsVisibleList.length)for(i=e-1;i>=0&&this.tabsFilteredAsVisibleList[i].disabled;)i--;if(-1!==i){const e=this.tabs.findIndex((e=>e.id===this.tabsFilteredAsVisibleList[i].id));this.updateSelectedTab(e)}else this.updateSelectedTab(i);this.noTabsVisible=0===this.tabsFilteredAsVisibleList.length&&0===this.tabsFilteredAsHiddenList.length,this.requestUpdate()}setSelectedAttribute(e,t,i=!1){t&&(t.selected=i),e&&(e.selected=i,i&&(this.isMoreTabMenuSelected=this.isTabInMoreMenu(e)),this.isTabInMoreMenu(e)&&(this.isMoreTabMenuSelected=!0))}isTabInMoreMenu(e){return void 0!==this.tabsFilteredAsHiddenList.find((t=>t.id===e.id))}updateSelectedTab(e){const{tabs:t,panels:i}=this,s=this.tabs.findIndex((e=>e.hasAttribute("selected")));if(t&&i&&(this.setSelectedAttribute((0,r.Qx)(t,s),(0,r.Qx)(i,s),!1),this.setSelectedAttribute((0,r.Qx)(t,e),(0,r.Qx)(i,e),!0)),e>=0){this.dispatchSelectedChangedEvent(e);const i=this.currentTabsLayout.findIndex((i=>i.id===t[e].id));this.changeSelectedTabIdx(i)}}dispatchSelectedChangedEvent(e){const t=this.currentTabsLayout,i=this.tabs[e].id,s=t.findIndex((e=>e.id===i)),o=[];t.forEach((e=>{o.push(e.name)})),this.dispatchEvent(new CustomEvent("selected-changed",{detail:{value:s,tabsOrder:o},composed:!0,bubbles:!0}))}changeSelectedTabIdx(e){this.requestUpdate(),this.selected=e,this.updateComplete.then((()=>{var t,i;if(e<this.tabsFilteredAsVisibleList.length){const e=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.children[this.selected];null==e||e.focus()}else{const e=this.selected-this.tabsFilteredAsVisibleList.length,t=null===(i=this.hiddenTabsContainerElement)||void 0===i?void 0:i.children[e];this.moveFocusToTab(t);const s=this.tabsFilteredAsHiddenList[e];!(null==s?void 0:s.disabled)&&this.updateHiddenIdPositiveTabIndex(s)}})),this.updateIsMoreTabMenuSelected(),this.storeSelectedTabIndex(e)}storeSelectedTabIndex(e){this.persistSelection&&this.tabsId&&e>-1&&""!==this.tabsId.trim()&&sessionStorage.setItem(this.tabsId,`${e}`)}getCurrentIndex(e){var t,i,s;const o=null!==(i=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.children.length)&&void 0!==i?i:0;for(let t=0;t<o;t++)if((null===(s=this.visibleTabsContainerElement)||void 0===s?void 0:s.children[t].id)===e)return t;return this.tabsVisibleIdxHash[e]}moveFocusToAdjacentTab(e,t){var i,s;const o=this.getCurrentIndex(e),r=null===(i=this.visibleTabsContainerElement)||void 0===i?void 0:i.children,n=null!==(s=null==r?void 0:r.length)&&void 0!==s?s:0;if(!r||0===n)return;let a=0;t===T?a=0===o?n-1:o-1:t===I?a=o===n-1?0:o+1:t===A&&(a=this.selected>=n?0:this.selected),this.moveFocusToTab(r[a])}moveFocusToTab(e){(0,b.setTimeout)((()=>null==e?void 0:e.focus()),0)}handleOverlayClose(){(0,b.setTimeout)((()=>{this.menuOverlayElement&&(this.menuOverlayElement.isOpen=!1)}),0)}dispatchKeydownEvent(e,t){t&&this.dispatchEvent(new CustomEvent("tab-keydown",{detail:{id:t,key:e.code,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,srcEvent:e},bubbles:!0,composed:!0}))}handleTabKeydown(e){var t,i,o,r,n,a,l;const d=e.target;if(e.target!=this&&!this.tabs.find((e=>e.id===(null==d?void 0:d.id))))return!1;let h;if((null===(t=e.composedPath())||void 0===t?void 0:t.length)>0?h=e.composedPath()[0].id:e.originalTarget&&(h=e.originalTarget.id),!h)return;const c=this.getNormalizedTabId(h);this.dispatchKeydownEvent(e,c);const p=e.code,{shiftKey:u}=e,m=!!this.isMoreTabMenuVisible&&c===x,v=m&&this.isMoreTabMenuVisible?this.moreTabMenuElement:this.tabsHash[this.getNormalizedTabId(c)],b=!this.isMoreTabMenuVisible||v&&this.tabsVisibleIdxHash[v.id]>-1,y=!!this.isMoreTabMenuVisible&&v&&this.tabsHiddenIdxHash[v.id]>-1,g=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length-1:this.tabs.length-1,f=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length:-1,w=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length+this.tabsFilteredAsHiddenList.length-1:-1;switch(p){case s.Uz.Tab:m&&!this.isMoreTabMenuOpen&&u&&(e.preventDefault(),this.moveFocusToAdjacentTab(h,A));break;case s.Uz.End:m||(b?(e.preventDefault(),this.moveFocusToTab(null===(i=this.visibleTabsContainerElement)||void 0===i?void 0:i.children[(null===(o=this.tabsFilteredAsVisibleList)||void 0===o?void 0:o.length)-1])):this.isMoreTabMenuOpen&&(e.preventDefault(),this.moveFocusToTab(null===(r=this.hiddenTabsContainerElement)||void 0===r?void 0:r.children[(null===(n=this.tabsFilteredAsHiddenList)||void 0===n?void 0:n.length)-1])));break;case s.Uz.Home:b?(e.preventDefault(),this.moveFocusToTab(null===(a=this.visibleTabsContainerElement)||void 0===a?void 0:a.children[0])):this.isMoreTabMenuOpen&&(e.preventDefault(),this.moveFocusToTab(null===(l=this.hiddenTabsContainerElement)||void 0===l?void 0:l.children[0]));break;case s.Uz.ArrowLeft:m||b&&(e.stopPropagation(),this.moveFocusToAdjacentTab(h,T));break;case s.Uz.ArrowRight:m||b&&(e.stopPropagation(),this.moveFocusToAdjacentTab(h,I));break;case s.Uz.ArrowUp:if(m);else if(b&&"vertical"===this.direction)e.preventDefault(),this.changeSelectedTabIdx(0===this.selected?g:this.selected-1);else if(y){e.preventDefault();const t=this.selected===f?w:this.selected-1;this.changeSelectedTabIdx(t)}break;case s.Uz.ArrowDown:if(m);else if(b&&"vertical"===this.direction)e.preventDefault(),this.changeSelectedTabIdx(this.selected===g?0:this.selected+1);else if(y){e.preventDefault();const t=this.selected===w?f:this.selected+1;this.changeSelectedTabIdx(t)}break;case s.Uz.Enter:case s.Uz.NumpadEnter:case s.Uz.Space:if(m){const e=this.tabsFilteredAsHiddenList.filter((e=>!e.disabled)),t=e.length?e.find((e=>e.selected))||e[0]:void 0;if(this.updateHiddenIdPositiveTabIndex(t),t){const e=this.tabsIdxHash[this.getNormalizedTabId(t.id)];-1!==e&&this.updateSelectedTab(e)}}else if(v&&!v.disabled){const t=this.tabsIdxHash[this.getNormalizedTabId(v.id)];-1!==t&&(e.preventDefault(),this.updateSelectedTab(t))}}}setupTabsEvents(){this.addEventListener("tab-click",this.handleTabClick),this.addEventListener("tab-cross-click",this.handleTabCrossClick),this.addEventListener("tab-close-click",this.handleTabCloseClick),this.addEventListener("keydown",this.handleTabKeydown),this.addEventListener("clear-tab-order-prefs",this.clearTabOrderPrefs)}teardownTabsEvents(){this.removeEventListener("tab-click",this.handleTabClick),this.removeEventListener("tab-cross-click",this.handleTabCrossClick),this.removeEventListener("tab-close-click",this.handleTabCloseClick),this.removeEventListener("keydown",this.handleTabKeydown),this.removeEventListener("clear-tab-order-prefs",this.clearTabOrderPrefs)}clearTabOrderPrefs(e){const{compUniqueId:t}=e.detail;t===this.compUniqueId&&(localStorage.removeItem(this.tabsId),sessionStorage.removeItem(this.tabsId),localStorage.removeItem(this.compUniqueId),this.tabsOrderPrefsArray=this.defaultTabsOrderArray,this.selected=0,this.initializeTabs(),this.dispatchSelectedChangedEvent(0))}setupPanelsAndTabs(){this.tabSlotElement&&(this.tabs=this.tabSlotElement.assignedElements()),this.panelSlotElement&&(this.panels=this.panelSlotElement.assignedElements()),this.defaultTabsOrderArray=this.tabs.map((e=>e.name))}setupMoreTab(){return w(this,void 0,void 0,(function*(){"vertical"!==this.direction&&this.moreTabMenuElement&&!this.isMoreTabMenuMeasured&&(this.moreTabMenuElement.classList.add("md-menu-overlay__more_tab--measuring"),yield this.moreTabMenuElement.updateComplete,this.moreTabMenuElement.offsetWidth&&(this.moreTabMenuOffsetWidth=this.moreTabMenuElement.offsetWidth,this.isMoreTabMenuMeasured=!0),this.moreTabMenuElement.classList.remove("md-menu-overlay__more_tab--measuring"))}))}initializeSortable(){this.visibleTabsContainerElement&&this.hiddenTabsContainerElement&&(this.visibleTabsSortableInstance=v().create(this.visibleTabsContainerElement,this.generateOptions()),this.hiddenTabsSortableInstance=v().create(this.hiddenTabsContainerElement,this.generateOptions()))}initializeTabs(){this.tabs=[],this.panels=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.isMoreTabMenuVisible=!1,this.setupPanelsAndTabs(),this.linkPanelsAndTabs(),this.draggable&&this.initializeSortable(),this.manageOverflow(),this.requestUpdate()}connectedCallback(){var e;if(super.connectedCallback(),this.setupTabsEvents(),this.persistSelection){if(!this.tabsId||""===this.tabsId.trim())return void console.error("Unique tabs-id attribute is mandatory for persist the selection of tab");const e=localStorage.getItem(this.tabsId);this.selected=e&&parseInt(e)>-1?parseInt(e):this.selected}this.compUniqueId&&(this.tabsOrderPrefsArray=(null===(e=localStorage.getItem(this.compUniqueId))||void 0===e?void 0:e.split(","))||[])}selectTabFromStorage(){if(this.persistSelection){if(!this.tabsId||""===this.tabsId.trim())return void console.error("Unique tabs-id attribute is mandatory for persist the selection of tab");const e=sessionStorage.getItem(this.tabsId);let t=0;if(e){const i=parseInt(e);t=i>-1?i:this.selected}const i=this.currentTabsLayout;i.length&&i[t].id?(this._selectedIndex=t,this.handleNewSelectedTab(i[t].id)):this.selected=t}}disconnectedCallback(){super.disconnectedCallback(),this.teardownTabsEvents()}firstUpdated(e){super.firstUpdated(e),this.setupPanelsAndTabs(),this.linkPanelsAndTabs(),this.selectTabFromStorage()}onDirectionChanged(){return w(this,void 0,void 0,(function*(){this.tabs=[],this.panels=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.isMoreTabMenuVisible=!1,this.setupPanelsAndTabs(),yield this.linkPanelsAndTabs(),this.draggable&&this.initializeSortable(),"horizontal"===this.direction&&(yield this.manageOverflow()),this.selectTabFromStorage()}))}updated(e){var t;if(super.updated(e),e.has("direction")&&e.get("direction")!==this.direction&&this.onDirectionChanged(),e.has("slotted")&&this.initializeTabs(),!this.draggable||this.visibleTabsSortableInstance||this.hiddenTabsSortableInstance||this.initializeSortable(),e.has("tabsFilteredAsHiddenList")&&(this.tabsCopy=Array.from((null===(t=this.tabsCopyHiddenListElements)||void 0===t?void 0:t.values())||[]),this.tabsCopyHash=this.tabsCopy.reduce(((e,t)=>(e[t.id]=t,e)),{})),(e.has("tabsFilteredAsVisibleList")||e.has("tabsFilteredAsHiddenList"))&&(this.tabsVisibleIdxHash=this.tabsFilteredAsVisibleList.reduce(((e,t,i)=>(e[t.id]=i,e)),{}),this.tabsHiddenIdxHash=this.tabsFilteredAsHiddenList.reduce(((e,t,i)=>(e[t.id]=i,e)),{})),e.has("isMoreTabMenuOpen")&&this.isMoreTabMenuVisible){const t=e.get("isMoreTabMenuOpen");this.isMoreTabMenuOpen&&!t&&(this.moreItemsScrollLimit<this.tabsCopy.length?(this.isMoreTabMenuScrollable=!0,this.moreTabMenuMaxHeight=`${this.measureHiddenTabsCopiesOffsetHeight().slice(0,this.moreItemsScrollLimit).reduce(((e,t)=>e+t),0)}px`):(this.isMoreTabMenuScrollable=!1,this.moreTabMenuMaxHeight=null))}e.has("tabsId")&&this.selectTabFromStorage(),e.has("selectedIndex")&&this.updateSelectedTab(this.selectedIndex),e.has("overflowLabel")&&this.updateIsMoreTabTruncated()}get moreMenuButtonTemplate(){return l.html`
|
|
1219
|
+
`}};m([(0,l.property)({type:Boolean,attribute:"two-digit-auto-tab"})],t.prototype,"twoDigitAutoTab",void 0),m([(0,l.property)({type:Boolean,attribute:"twenty-four-hour-format",reflect:!0})],t.prototype,"twentyFourHourFormat",void 0),m([(0,l.property)({type:String})],t.prototype,"timeSpecificity",void 0),m([(0,l.property)({type:String})],t.prototype,"locale",void 0),m([(0,l.property)({type:String,reflect:!0})],t.prototype,"value",void 0),m([(0,l.internalProperty)()],t.prototype,"finalTwentyFourFormat",void 0),m([(0,l.internalProperty)()],t.prototype,"timeObject",void 0),m([(0,l.internalProperty)()],t.prototype,"tabNext",void 0),m([(0,l.internalProperty)()],t.prototype,"timeValue",void 0),m([(0,l.internalProperty)()],t.prototype,"timeValidity",void 0),t=m([(0,o.w)("md-timepicker")],t),e.ELEMENT=t}(g||(g={}))},50226:(e,t,i)=>{i.d(t,{Tabs:()=>O}),i(61200),i(11323),i(83192);var s=i(90195),o=i(3001),r=i(66677),n=i(59164),a=i(26272),l=i(41488),d=i(40333),h=i(23968),p=i(22818),c=i(8229),u=i(19239),m=i(41891),y=i.n(m),b=i(97103),v=i(30076),g=i(16643),f=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},w=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};const C="tab-more",x="more-menu-copy-",S="visibleToVisible",$="visibleToHidden",E="hiddenToVisible",k="hiddenToHidden",T="previous",I="next",A="fromMoreTabs";var O;!function(e){let t=class extends((0,o.UM)((0,o.Io)((0,o.TS)(l.LitElement)))){constructor(){super(...arguments),this.justified=!1,this.hugTabs=!1,this.overflowLabel="More Tabs",this.draggable=!1,this.direction="horizontal",this.moreItemsScrollLimit=Number.MAX_SAFE_INTEGER,this._selectedIndex=0,this.delay=0,this.animation=100,this.ghostClass="",this.chosenClass="",this.forceFallback=!1,this.fallbackClass="",this.tabsId="",this.persistSelection=!1,this.compUniqueId="",this.type="line",this.newMomentum=!1,this.variant="ghost",this.isMoreTabMenuVisible=!1,this.isMoreTabMenuMeasured=!1,this.isMoreTabMenuOpen=!1,this.isMoreTabMenuSelected=!1,this.isMoreTabMenuScrollable=!1,this.moreTabMenuOffsetWidth=0,this.moreTabMenuMaxHeight=null,this.tabsViewportDataList=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.noTabsVisible=!1,this.defaultTabsOrderArray=[],this.tabsOrderPrefsArray=[],this.isMoreTabTruncated=!1,this.tabs=[],this.panels=[],this.tabsCopy=[],this.tabsHash={},this.tabsCopyHash={},this.tabsIdxHash={},this.tabsVisibleIdxHash={},this.tabsHiddenIdxHash={},this.visibleTabsSortableInstance=null,this.hiddenTabsSortableInstance=null,this.handleOnDragEnd=e=>w(this,void 0,void 0,(function*(){var t,i,s,o,r,n,a,l,d,h;e.stopPropagation();const p=e.oldIndex,c=e.newIndex,u=[...this.tabsFilteredAsVisibleList],m=[...this.tabsFilteredAsHiddenList],y=this.getDragDirection(e);if(void 0!==p&&void 0!==c){switch(y){case $:{null===(i=null===(t=this.hiddenTabsContainerElement)||void 0===t?void 0:t.querySelector("#"+e.item.id))||void 0===i||i.remove();const s=u[p],o=m.slice(-1)[0],r=c===this.tabsFilteredAsHiddenList.length?c-1:c;m.splice(r,0,s),m.pop();const n=u.filter((t=>t.id!==this.getNormalizedTabId(e.item.id)));n.push(o),this.tabsFilteredAsVisibleList=[...n],this.tabsFilteredAsHiddenList=[...m];break}case S:{const e=u[p];u.splice(p,1),u.splice(c,0,e),this.tabsFilteredAsVisibleList=u,c===this.tabsFilteredAsVisibleList.length-1&&(null===(o=null===(s=this.visibleTabsContainerElement)||void 0===s?void 0:s.children[this.visibleTabsContainerElement.children.length-1])||void 0===o||o.remove());const t=this.visibleTabsContainerElement.children[p],i=this.visibleTabsContainerElement.children[c];if(!t||!i)return;null===(r=this.visibleTabsContainerElement)||void 0===r||r.replaceChild(i,t),null===(n=this.visibleTabsContainerElement)||void 0===n||n.insertBefore(t,i);break}case E:{null===(l=null===(a=this.visibleTabsContainerElement)||void 0===a?void 0:a.querySelector("#"+e.item.id))||void 0===l||l.remove();const t=m[p],i=u.slice(-1)[0];m.splice(p,1),m.splice(0,0,i);const s=c===this.tabsFilteredAsVisibleList.length?c-1:c;u.splice(s,0,t),u.pop(),this.tabsFilteredAsVisibleList=u,this.tabsFilteredAsHiddenList=m;break}case k:{const e=m[p];m.splice(p,1),m.splice(c,0,e),this.tabsFilteredAsHiddenList=m,c===this.tabsFilteredAsHiddenList.length-1&&(null===(h=null===(d=this.hiddenTabsContainerElement)||void 0===d?void 0:d.children[this.hiddenTabsContainerElement.children.length-1])||void 0===h||h.remove());break}}if(this.compUniqueId){const e=[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList],t=e.findIndex((e=>e.selected));this.storeSelectedTabIndex(t),this.tabsOrderPrefsArray=e.map((e=>e.name)),localStorage.setItem(this.compUniqueId,this.tabsOrderPrefsArray.join(","))}}}))}get selectedIndex(){return this._selectedIndex}set selectedIndex(e){this._selectedIndex=e}generateOptions(){return{group:"shared",animation:10,swapThreshold:1,draggable:"md-tab",direction:this.direction,forceFallback:this.forceFallback,fallbackClass:this.fallbackClass,ghostClass:this.ghostClass,chosenClass:this.chosenClass,onEnd:this.handleOnDragEnd}}get currentTabsLayout(){return"horizontal"===this.direction?[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList]:this.tabs}getCopyTabId(e){var t;return(null===(t=e.id)||void 0===t?void 0:t.startsWith(x))?`${x}${e.id}`:e.id}getAriaControlId(e){var t,i;return(null===(t=e.id)||void 0===t?void 0:t.startsWith(x))?`${x}${e.id}`:"tab_panel_"+(null===(i=e.id)||void 0===i?void 0:i.substring(4))}getTabIndex(e){var t,i;return this.isMoreTabMenuVisible&&0===this.getCurrentIndex(null==e?void 0:e.id)&&this.selected>(null===(t=this.tabsFilteredAsVisibleList)||void 0===t?void 0:t.length)-1||(null===(i=this.tabsFilteredAsVisibleList[this.selected])||void 0===i?void 0:i.id)===e.id?0:-1}getNormalizedTabId(e){return e.replace(x,"")}static get styles(){return[a.A,v.A]}ensureTabsUpdateComplete(e){return w(this,void 0,void 0,(function*(){const t=e.map((e=>void 0!==e.updateComplete?e.updateComplete:null)).filter((e=>null!==e));t.length&&(yield Promise.all(t))}))}measureTabsOffsetWidth(){return this.justified||"vertical"===this.direction?this.tabs.map((e=>{e.setAttribute("measuringrealwidth","");const t=e.closable?e.offsetWidth+g.TAB_CROSS_WIDTH:e.offsetWidth;return e.removeAttribute("measuringrealwidth"),t})):this.tabs.map((e=>e.closable?e.offsetWidth+g.TAB_CROSS_WIDTH:e.offsetWidth))}updateIsMoreTabTruncated(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector(".md-menu-overlay__overflow-label");if(t){const e=t.scrollWidth>t.clientWidth;this.isMoreTabTruncated!=e&&(this.isMoreTabTruncated=e)}}measureHiddenTabsCopiesOffsetHeight(){return this.tabsCopy.map((e=>e.offsetHeight))}manageOverflow(){return w(this,void 0,void 0,(function*(){var e,t;if("vertical"!==this.direction){let i;i=0===this.tabsFilteredAsVisibleList.length&&0===this.tabsFilteredAsHiddenList.length?[...this.tabs]:[...this.tabsFilteredAsVisibleList,...this.tabsFilteredAsHiddenList],i.forEach((e=>{var t,i,s,o,r;if((null===(t=e.children)||void 0===t?void 0:t.length)&&0===(null===(s=null===(i=e.children[0])||void 0===i?void 0:i.children)||void 0===s?void 0:s.length)){const t=null===(o=null==e?void 0:e.querySelector("slot"))||void 0===o?void 0:o.assignedNodes({flatten:!0})[0].cloneNode(!0);t&&(t.classList.add("tab-content"),null===(r=null==e?void 0:e.children[0])||void 0===r||r.appendChild(t))}}));const s=i.length;if(this.tabsListElement&&s){const o=(null===(e=this.tabsSettingsElement)||void 0===e?void 0:e.offsetWidth)?this.tabsListElement.offsetWidth-(null===(t=this.tabsSettingsElement)||void 0===t?void 0:t.offsetWidth):this.tabsListElement.offsetWidth;yield this.ensureTabsUpdateComplete(this.tabs);const r=this.measureTabsOffsetWidth(),n=i.reduce(((e,t,i)=>e+r[i]),0);if(n){yield this.setupMoreTab();let e=!0;o<n&&(e=!1);const t=[];let a=0;i.forEach(((i,n)=>{a+=r[n];const l=!e&&a+(n<s-1?this.moreTabMenuOffsetWidth:0)>o;t.push({isTabInViewportHidden:l,tabOffsetWidth:r[n]})})),this.tabsViewportDataList=t,this.tabsViewportDataList.forEach(((e,t)=>this.tabs[t].viewportHidden=e.isTabInViewportHidden)),this.isMoreTabMenuVisible=!!this.tabsViewportDataList.find((e=>e.isTabInViewportHidden)),this.tabsFilteredAsVisibleList=i.filter(((e,t)=>!this.tabsViewportDataList[t].isTabInViewportHidden)),this.tabsVisibleIdxHash=this.tabsFilteredAsVisibleList.reduce(((e,t,i)=>(e[t.id]=i,e)),{}),this.tabsFilteredAsHiddenList=i.filter(((e,t)=>this.tabsViewportDataList[t].isTabInViewportHidden)),this.tabsHiddenIdxHash=this.tabsFilteredAsHiddenList.reduce(((e,t,i)=>(e[t.id]=i,e)),{})}}this.updateIsMoreTabMenuSelected();const o=this.tabsFilteredAsHiddenList.find((e=>!e.disabled));this.updateHiddenIdPositiveTabIndex(o)}}))}updateIsMoreTabMenuSelected(){this.isMoreTabMenuSelected=!!this.tabsFilteredAsHiddenList.find((e=>e.selected))}updateHiddenIdPositiveTabIndex(e){this.tabHiddenIdPositiveTabIndex=e?e.id:void 0}sortTabsAndPanes(){if(!this.tabsOrderPrefsArray.length)return;const e=(e,t)=>{var i,s;const o=null!==(i=e.getAttribute("name"))&&void 0!==i?i:"",r=null!==(s=t.getAttribute("name"))&&void 0!==s?s:"";return this.tabsOrderPrefsArray.indexOf(o)-this.tabsOrderPrefsArray.indexOf(r)};this.tabs.sort(e),this.panels.sort(e)}linkPanelsAndTabs(){return w(this,void 0,void 0,(function*(){this.sortTabsAndPanes();const{tabs:e,panels:t}=this;if(0===e.length||0===t.length)return void console.warn("The tabs or panels count should't be equal zero.");e.length!==t.length&&console.warn(`The amount of tabs (${e.length}) doesn't match the amount of panels (${t.length}).`);const i="vertical"===this.direction;e.forEach(((e,s)=>{const o=(0,n.O)("tabs"),r="tab_"+o,a="tab_panel_"+o;e.setAttribute("id",r),e.setAttribute("aria-controls",a),e.selected=this.selected===s,e.vertical!==i&&(e.vertical=i),e.viewportHidden&&i&&(e.viewportHidden=!1);const l=t[s];l?(l.setAttribute("id",a),l.setAttribute("aria-labelledby",r),l.selected=this.selected===s,e.disabled&&(l.hidden=!0,l.selected=!1)):e.disabled=!0}));let s=this.selected;for(;s<e.length&&e[s].disabled;)s++;s=s===e.length?0:s,e[s].selected=!0,t[s].selected=!0,this.tabsHash=this.tabs.reduce(((e,t)=>(e[t.id]=t,e)),{}),this.tabsIdxHash=this.tabs.reduce(((e,t,i)=>(e[t.id]=i,e)),{})}))}get slotItem(){return this.tabSlotElement}filterSlotted(){return this.tabSlotElement.assignedElements()}handleResize(e){var t;null===(t=super.handleResize)||void 0===t||t.call(this,e),this.manageOverflow(),this.updateIsMoreTabTruncated()}getDragDirection(e){return e.from===this.visibleTabsContainerElement&&e.to===this.hiddenTabsContainerElement?$:e.from===this.visibleTabsContainerElement&&e.to===this.visibleTabsContainerElement?S:e.from===this.hiddenTabsContainerElement&&e.to===this.visibleTabsContainerElement?E:e.from===this.hiddenTabsContainerElement&&e.to===this.hiddenTabsContainerElement?k:void 0}makeTabCopyFocus(e){e&&e.focus()}handleTabClick(e){const{id:t}=e.detail;this.handleNewSelectedTab(t)}handleNewSelectedTab(e){const t=this.tabsHash[this.getNormalizedTabId(e)];if(t&&!t.disabled){const e=this.tabsIdxHash[t.id];-1!==e&&this.updateSelectedTab(e);{const e=this.tabsCopyHash[this.getCopyTabId(t)];e&&this.makeTabCopyFocus(e),this.updateHiddenIdPositiveTabIndex(t)}}}handleTabCrossClick(e){const{id:t}=e.detail;this.handleTabCloseEvent(t)}handleTabCloseClick(e){const{id:t}=e.detail;this.handleTabCloseEvent(t)}handleTabCloseEvent(e){var t,i;const s=this.tabsHash[this.getNormalizedTabId(e)];if(s&&!s.disabled&&("auto"===s.closable||"custom"===s.closable)){const s=this.tabsFilteredAsVisibleList.findIndex((t=>this.getNormalizedTabId(t.id)===this.getNormalizedTabId(e)));this.tabsFilteredAsVisibleList=this.tabsFilteredAsVisibleList.filter((t=>this.getNormalizedTabId(t.id)!==this.getNormalizedTabId(e))),null===(i=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.querySelector("#"+e))||void 0===i||i.remove(),0!==this.tabsFilteredAsHiddenList.length&&(this.tabsFilteredAsVisibleList.push(this.tabsFilteredAsHiddenList[0]),this.tabsFilteredAsHiddenList.splice(0,1)),0===this.tabsFilteredAsHiddenList.length&&(this.isMoreTabMenuVisible=!1,this.isMoreTabMenuMeasured=!1),this.handleUpdatedSeletedTabAfterCross(s)}}handleUpdatedSeletedTabAfterCross(e){var t;let i=e;for(;i<this.tabsFilteredAsVisibleList.length&&(null===(t=this.tabsFilteredAsVisibleList[i])||void 0===t?void 0:t.disabled);)i++;if(void 0===this.tabsFilteredAsVisibleList[i]||e===this.tabsFilteredAsVisibleList.length)for(i=e-1;i>=0&&this.tabsFilteredAsVisibleList[i].disabled;)i--;if(-1!==i){const e=this.tabs.findIndex((e=>e.id===this.tabsFilteredAsVisibleList[i].id));this.updateSelectedTab(e)}else this.updateSelectedTab(i);this.noTabsVisible=0===this.tabsFilteredAsVisibleList.length&&0===this.tabsFilteredAsHiddenList.length,this.requestUpdate()}setSelectedAttribute(e,t,i=!1){t&&(t.selected=i),e&&(e.selected=i,i&&(this.isMoreTabMenuSelected=this.isTabInMoreMenu(e)),this.isTabInMoreMenu(e)&&(this.isMoreTabMenuSelected=!0))}isTabInMoreMenu(e){return void 0!==this.tabsFilteredAsHiddenList.find((t=>t.id===e.id))}updateSelectedTab(e){const{tabs:t,panels:i}=this,s=this.tabs.findIndex((e=>e.hasAttribute("selected")));if(t&&i&&(this.setSelectedAttribute((0,r.Qx)(t,s),(0,r.Qx)(i,s),!1),this.setSelectedAttribute((0,r.Qx)(t,e),(0,r.Qx)(i,e),!0)),e>=0){this.dispatchSelectedChangedEvent(e);const i=this.currentTabsLayout.findIndex((i=>i.id===t[e].id));this.changeSelectedTabIdx(i)}}dispatchSelectedChangedEvent(e){const t=this.currentTabsLayout,i=this.tabs[e].id,s=t.findIndex((e=>e.id===i)),o=[];t.forEach((e=>{o.push(e.name)})),this.dispatchEvent(new CustomEvent("selected-changed",{detail:{value:s,tabsOrder:o},composed:!0,bubbles:!0}))}changeSelectedTabIdx(e){this.requestUpdate(),this.selected=e,this.updateComplete.then((()=>{var t,i;if(e<this.tabsFilteredAsVisibleList.length){const e=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.children[this.selected];null==e||e.focus()}else{const e=this.selected-this.tabsFilteredAsVisibleList.length,t=null===(i=this.hiddenTabsContainerElement)||void 0===i?void 0:i.children[e];this.moveFocusToTab(t);const s=this.tabsFilteredAsHiddenList[e];(null==s?void 0:s.disabled)||this.updateHiddenIdPositiveTabIndex(s)}})),this.updateIsMoreTabMenuSelected(),this.storeSelectedTabIndex(e)}storeSelectedTabIndex(e){this.persistSelection&&this.tabsId&&e>-1&&""!==this.tabsId.trim()&&sessionStorage.setItem(this.tabsId,`${e}`)}getCurrentIndex(e){var t,i,s;const o=null!==(i=null===(t=this.visibleTabsContainerElement)||void 0===t?void 0:t.children.length)&&void 0!==i?i:0;for(let t=0;t<o;t++)if((null===(s=this.visibleTabsContainerElement)||void 0===s?void 0:s.children[t].id)===e)return t;return this.tabsVisibleIdxHash[e]}moveFocusToAdjacentTab(e,t){var i,s;const o=this.getCurrentIndex(e),r=null===(i=this.visibleTabsContainerElement)||void 0===i?void 0:i.children,n=null!==(s=null==r?void 0:r.length)&&void 0!==s?s:0;if(!r||0===n)return;let a=0;t===T?a=0===o?n-1:o-1:t===I?a=o===n-1?0:o+1:t===A&&(a=this.selected>=n?0:this.selected),this.moveFocusToTab(r[a])}moveFocusToTab(e){(0,b.setTimeout)((()=>null==e?void 0:e.focus()),0)}handleOverlayClose(){(0,b.setTimeout)((()=>{this.menuOverlayElement&&(this.menuOverlayElement.isOpen=!1)}),0)}dispatchKeydownEvent(e,t){t&&this.dispatchEvent(new CustomEvent("tab-keydown",{detail:{id:t,key:e.code,ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,srcEvent:e},bubbles:!0,composed:!0}))}handleTabKeydown(e){var t,i,o,r,n,a,l;const d=e.target;if(e.target!=this&&!this.tabs.find((e=>e.id===(null==d?void 0:d.id))))return!1;let h;if((null===(t=e.composedPath())||void 0===t?void 0:t.length)>0?h=e.composedPath()[0].id:e.originalTarget&&(h=e.originalTarget.id),!h)return;const p=this.getNormalizedTabId(h);this.dispatchKeydownEvent(e,p);const c=e.code,{shiftKey:u}=e,m=!!this.isMoreTabMenuVisible&&p===C,y=m&&this.isMoreTabMenuVisible?this.moreTabMenuElement:this.tabsHash[this.getNormalizedTabId(p)],b=!this.isMoreTabMenuVisible||y&&this.tabsVisibleIdxHash[y.id]>-1,v=!!this.isMoreTabMenuVisible&&y&&this.tabsHiddenIdxHash[y.id]>-1,g=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length-1:this.tabs.length-1,f=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length:-1,w=this.isMoreTabMenuVisible?this.tabsFilteredAsVisibleList.length+this.tabsFilteredAsHiddenList.length-1:-1;switch(c){case s.Uz.Tab:m&&!this.isMoreTabMenuOpen&&u&&(e.preventDefault(),this.moveFocusToAdjacentTab(h,A));break;case s.Uz.End:m||(b?(e.preventDefault(),this.moveFocusToTab(null===(i=this.visibleTabsContainerElement)||void 0===i?void 0:i.children[(null===(o=this.tabsFilteredAsVisibleList)||void 0===o?void 0:o.length)-1])):this.isMoreTabMenuOpen&&(e.preventDefault(),this.moveFocusToTab(null===(r=this.hiddenTabsContainerElement)||void 0===r?void 0:r.children[(null===(n=this.tabsFilteredAsHiddenList)||void 0===n?void 0:n.length)-1])));break;case s.Uz.Home:b?(e.preventDefault(),this.moveFocusToTab(null===(a=this.visibleTabsContainerElement)||void 0===a?void 0:a.children[0])):this.isMoreTabMenuOpen&&(e.preventDefault(),this.moveFocusToTab(null===(l=this.hiddenTabsContainerElement)||void 0===l?void 0:l.children[0]));break;case s.Uz.ArrowLeft:m||b&&(e.stopPropagation(),this.moveFocusToAdjacentTab(h,T));break;case s.Uz.ArrowRight:m||b&&(e.stopPropagation(),this.moveFocusToAdjacentTab(h,I));break;case s.Uz.ArrowUp:if(m);else if(b&&"vertical"===this.direction)e.preventDefault(),this.changeSelectedTabIdx(0===this.selected?g:this.selected-1);else if(v){e.preventDefault();const t=this.selected===f?w:this.selected-1;this.changeSelectedTabIdx(t)}break;case s.Uz.ArrowDown:if(m);else if(b&&"vertical"===this.direction)e.preventDefault(),this.changeSelectedTabIdx(this.selected===g?0:this.selected+1);else if(v){e.preventDefault();const t=this.selected===w?f:this.selected+1;this.changeSelectedTabIdx(t)}break;case s.Uz.Enter:case s.Uz.NumpadEnter:case s.Uz.Space:if(m){const e=this.tabsFilteredAsHiddenList.filter((e=>!e.disabled)),t=e.length?e.find((e=>e.selected))||e[0]:void 0;if(this.updateHiddenIdPositiveTabIndex(t),t){const e=this.tabsIdxHash[this.getNormalizedTabId(t.id)];-1!==e&&this.updateSelectedTab(e)}}else if(y&&!y.disabled){const t=this.tabsIdxHash[this.getNormalizedTabId(y.id)];-1!==t&&(e.preventDefault(),this.updateSelectedTab(t))}}}setupTabsEvents(){this.addEventListener("tab-click",this.handleTabClick),this.addEventListener("tab-cross-click",this.handleTabCrossClick),this.addEventListener("tab-close-click",this.handleTabCloseClick),this.addEventListener("keydown",this.handleTabKeydown),this.addEventListener("clear-tab-order-prefs",this.clearTabOrderPrefs)}teardownTabsEvents(){this.removeEventListener("tab-click",this.handleTabClick),this.removeEventListener("tab-cross-click",this.handleTabCrossClick),this.removeEventListener("tab-close-click",this.handleTabCloseClick),this.removeEventListener("keydown",this.handleTabKeydown),this.removeEventListener("clear-tab-order-prefs",this.clearTabOrderPrefs)}clearTabOrderPrefs(e){const{compUniqueId:t}=e.detail;t===this.compUniqueId&&(localStorage.removeItem(this.tabsId),sessionStorage.removeItem(this.tabsId),localStorage.removeItem(this.compUniqueId),this.tabsOrderPrefsArray=this.defaultTabsOrderArray,this.selected=0,this.initializeTabs(),this.dispatchSelectedChangedEvent(0))}setupPanelsAndTabs(){this.tabSlotElement&&(this.tabs=this.tabSlotElement.assignedElements()),this.panelSlotElement&&(this.panels=this.panelSlotElement.assignedElements()),this.defaultTabsOrderArray=this.tabs.map((e=>e.name))}setupMoreTab(){return w(this,void 0,void 0,(function*(){"vertical"!==this.direction&&this.moreTabMenuElement&&!this.isMoreTabMenuMeasured&&(this.moreTabMenuElement.classList.add("md-menu-overlay__more_tab--measuring"),yield this.moreTabMenuElement.updateComplete,this.moreTabMenuElement.offsetWidth&&(this.moreTabMenuOffsetWidth=this.moreTabMenuElement.offsetWidth,this.isMoreTabMenuMeasured=!0),this.moreTabMenuElement.classList.remove("md-menu-overlay__more_tab--measuring"))}))}initializeSortable(){this.visibleTabsContainerElement&&this.hiddenTabsContainerElement&&(this.visibleTabsSortableInstance=y().create(this.visibleTabsContainerElement,this.generateOptions()),this.hiddenTabsSortableInstance=y().create(this.hiddenTabsContainerElement,this.generateOptions()))}initializeTabs(){this.tabs=[],this.panels=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.isMoreTabMenuVisible=!1,this.setupPanelsAndTabs(),this.linkPanelsAndTabs(),this.draggable&&this.initializeSortable(),this.manageOverflow(),this.requestUpdate()}connectedCallback(){var e;if(super.connectedCallback(),this.setupTabsEvents(),this.persistSelection){if(!this.tabsId||""===this.tabsId.trim())return void console.error("Unique tabs-id attribute is mandatory for persist the selection of tab");const e=localStorage.getItem(this.tabsId);this.selected=e&&parseInt(e)>-1?parseInt(e):this.selected}this.compUniqueId&&(this.tabsOrderPrefsArray=(null===(e=localStorage.getItem(this.compUniqueId))||void 0===e?void 0:e.split(","))||[])}selectTabFromStorage(){if(this.persistSelection){if(!this.tabsId||""===this.tabsId.trim())return void console.error("Unique tabs-id attribute is mandatory for persist the selection of tab");const e=sessionStorage.getItem(this.tabsId);let t=0;if(e){const i=parseInt(e);t=i>-1?i:this.selected}const i=this.currentTabsLayout;i.length&&i[t].id?(this._selectedIndex=t,this.handleNewSelectedTab(i[t].id)):this.selected=t}}disconnectedCallback(){super.disconnectedCallback(),this.teardownTabsEvents()}firstUpdated(e){super.firstUpdated(e),this.setupPanelsAndTabs(),this.linkPanelsAndTabs(),this.selectTabFromStorage()}onDirectionChanged(){return w(this,void 0,void 0,(function*(){this.tabs=[],this.panels=[],this.tabsFilteredAsVisibleList=[],this.tabsFilteredAsHiddenList=[],this.isMoreTabMenuVisible=!1,this.setupPanelsAndTabs(),yield this.linkPanelsAndTabs(),this.draggable&&this.initializeSortable(),"horizontal"===this.direction&&(yield this.manageOverflow()),this.selectTabFromStorage()}))}updated(e){var t;if(super.updated(e),e.has("direction")&&e.get("direction")!==this.direction&&this.onDirectionChanged(),e.has("slotted")&&this.initializeTabs(),!this.draggable||this.visibleTabsSortableInstance||this.hiddenTabsSortableInstance||this.initializeSortable(),e.has("tabsFilteredAsHiddenList")&&(this.tabsCopy=Array.from((null===(t=this.tabsCopyHiddenListElements)||void 0===t?void 0:t.values())||[]),this.tabsCopyHash=this.tabsCopy.reduce(((e,t)=>(e[t.id]=t,e)),{})),(e.has("tabsFilteredAsVisibleList")||e.has("tabsFilteredAsHiddenList"))&&(this.tabsVisibleIdxHash=this.tabsFilteredAsVisibleList.reduce(((e,t,i)=>(e[t.id]=i,e)),{}),this.tabsHiddenIdxHash=this.tabsFilteredAsHiddenList.reduce(((e,t,i)=>(e[t.id]=i,e)),{})),e.has("isMoreTabMenuOpen")&&this.isMoreTabMenuVisible){const t=e.get("isMoreTabMenuOpen");this.isMoreTabMenuOpen&&!t&&(this.moreItemsScrollLimit<this.tabsCopy.length?(this.isMoreTabMenuScrollable=!0,this.moreTabMenuMaxHeight=`${this.measureHiddenTabsCopiesOffsetHeight().slice(0,this.moreItemsScrollLimit).reduce(((e,t)=>e+t),0)}px`):(this.isMoreTabMenuScrollable=!1,this.moreTabMenuMaxHeight=null))}e.has("tabsId")&&this.selectTabFromStorage(),e.has("selectedIndex")&&this.updateSelectedTab(this.selectedIndex),e.has("overflowLabel")&&this.updateIsMoreTabTruncated()}get moreMenuButtonTemplate(){return l.html`
|
|
1219
1220
|
<md-tab
|
|
1220
1221
|
slot="menu-trigger"
|
|
1221
|
-
id="${
|
|
1222
|
+
id="${C}"
|
|
1222
1223
|
aria-label="${this.overflowLabel}"
|
|
1223
1224
|
aria-haspopup="true"
|
|
1224
1225
|
role="button"
|
|
@@ -1239,7 +1240,7 @@
|
|
|
1239
1240
|
></md-icon>
|
|
1240
1241
|
</md-tab>
|
|
1241
1242
|
`}get moreMenuListTemplate(){return l.html`
|
|
1242
|
-
${(0,
|
|
1243
|
+
${(0,p.repeat)(this.tabsFilteredAsHiddenList,(()=>(0,n.O)("menuitem_tabs")),(e=>l.html`
|
|
1243
1244
|
<md-tab
|
|
1244
1245
|
slot="draggable-item"
|
|
1245
1246
|
?disabled=${e.disabled}
|
|
@@ -1272,7 +1273,7 @@
|
|
|
1272
1273
|
id="tabs-more-list"
|
|
1273
1274
|
part="tabs-more-list"
|
|
1274
1275
|
class="md-tab__list md-menu-overlay__more_list"
|
|
1275
|
-
style="${(0,
|
|
1276
|
+
style="${(0,c.styleMap)(this.isMoreTabMenuScrollable&&this.moreTabMenuMaxHeight?{"overflow-y":"auto",height:this.moreTabMenuMaxHeight,"max-height":this.moreTabMenuMaxHeight}:{})}"
|
|
1276
1277
|
>
|
|
1277
1278
|
${this.moreMenuListTemplate}
|
|
1278
1279
|
</div>
|
|
@@ -1285,7 +1286,7 @@
|
|
|
1285
1286
|
id="visible-tabs-list"
|
|
1286
1287
|
class="visible-tabs-container ${(0,h.classMap)({"md-tab__justified":this.justified&&!this.isMoreTabMenuVisible,"md-tab__hug":this.hugTabs,"visible-new-tabs":this.newMomentum})}"
|
|
1287
1288
|
>
|
|
1288
|
-
${(0,
|
|
1289
|
+
${(0,p.repeat)(this.tabsFilteredAsVisibleList,(()=>(0,n.O)("tabs")),(e=>l.html`
|
|
1289
1290
|
<md-tab
|
|
1290
1291
|
.closable="${e.closable}"
|
|
1291
1292
|
.disabled="${e.disabled}"
|
|
@@ -1323,36 +1324,36 @@
|
|
|
1323
1324
|
>
|
|
1324
1325
|
<slot name="panel"></slot>
|
|
1325
1326
|
</div>
|
|
1326
|
-
`}};f([(0,l.property)({type:Boolean})],t.prototype,"justified",void 0),f([(0,l.property)({type:Boolean,attribute:"hug-tabs"})],t.prototype,"hugTabs",void 0),f([(0,l.property)({type:String})],t.prototype,"overflowLabel",void 0),f([(0,l.property)({type:Boolean,attribute:"draggable"})],t.prototype,"draggable",void 0),f([(0,l.property)({type:String})],t.prototype,"direction",void 0),f([(0,l.property)({type:Number,attribute:"more-items-scroll-limit"})],t.prototype,"moreItemsScrollLimit",void 0),f([(0,l.property)({type:Number,reflect:!0,attribute:"selected-index"})],t.prototype,"selectedIndex",null),f([(0,l.property)({type:Number})],t.prototype,"delay",void 0),f([(0,l.property)({type:Number})],t.prototype,"animation",void 0),f([(0,l.property)({type:String,attribute:"ghost-class"})],t.prototype,"ghostClass",void 0),f([(0,l.property)({type:String,attribute:"chosen-class"})],t.prototype,"chosenClass",void 0),f([(0,l.property)({type:Boolean,attribute:"force-fallback"})],t.prototype,"forceFallback",void 0),f([(0,l.property)({type:String,attribute:"fallback-class"})],t.prototype,"fallbackClass",void 0),f([(0,l.property)({type:String,attribute:"tabs-id"})],t.prototype,"tabsId",void 0),f([(0,l.property)({type:Boolean,attribute:"persist-selection"})],t.prototype,"persistSelection",void 0),f([(0,l.property)({type:String,attribute:"comp-unique-id"})],t.prototype,"compUniqueId",void 0),f([(0,l.property)({type:String})],t.prototype,"type",void 0),f([(0,l.property)({type:Boolean})],t.prototype,"newMomentum",void 0),f([(0,l.property)({type:String})],t.prototype,"variant",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuVisible",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuMeasured",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuOpen",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuSelected",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuScrollable",void 0),f([(0,l.internalProperty)()],t.prototype,"moreTabMenuOffsetWidth",void 0),f([(0,l.internalProperty)()],t.prototype,"moreTabMenuMaxHeight",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsViewportDataList",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsFilteredAsVisibleList",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsFilteredAsHiddenList",void 0),f([(0,l.internalProperty)()],t.prototype,"noTabsVisible",void 0),f([(0,l.internalProperty)()],t.prototype,"defaultTabsOrderArray",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsOrderPrefsArray",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabTruncated",void 0),f([(0,l.query)("slot[name='tab']")],t.prototype,"tabSlotElement",void 0),f([(0,l.query)("slot[name='panel']")],t.prototype,"panelSlotElement",void 0),f([(0,l.query)(".md-tab__list[part='tabs-list']")],t.prototype,"tabsListElement",void 0),f([(0,l.query)(".md-tabs__settings[part='md-tabs__settings']")],t.prototype,"tabsSettingsElement",void 0),f([(0,l.query)(".md-menu-overlay__more_tab")],t.prototype,"moreTabMenuElement",void 0),f([(0,l.query)("md-menu-overlay")],t.prototype,"menuOverlayElement",void 0),f([(0,l.query)(".md-tab__list[part='tabs-more-list']")],t.prototype,"tabsMoreListElement",void 0),f([(0,l.queryAll)(".md-menu-overlay__more_list md-tab")],t.prototype,"tabsCopyHiddenListElements",void 0),f([(0,l.query)("#visible-tabs-list")],t.prototype,"visibleTabsContainerElement",void 0),f([(0,l.query)("#tabs-more-list")],t.prototype,"hiddenTabsContainerElement",void 0),t=f([(0,o.wW)("md-tabs")],t),e.ELEMENT=t}(O||(O={}))},50565:(e,t,i)=>{i.d(t,{EditableTextfield:()=>s});var s,o=i(
|
|
1327
|
+
`}};f([(0,l.property)({type:Boolean})],t.prototype,"justified",void 0),f([(0,l.property)({type:Boolean,attribute:"hug-tabs"})],t.prototype,"hugTabs",void 0),f([(0,l.property)({type:String})],t.prototype,"overflowLabel",void 0),f([(0,l.property)({type:Boolean,attribute:"draggable"})],t.prototype,"draggable",void 0),f([(0,l.property)({type:String})],t.prototype,"direction",void 0),f([(0,l.property)({type:Number,attribute:"more-items-scroll-limit"})],t.prototype,"moreItemsScrollLimit",void 0),f([(0,l.property)({type:Number,reflect:!0,attribute:"selected-index"})],t.prototype,"selectedIndex",null),f([(0,l.property)({type:Number})],t.prototype,"delay",void 0),f([(0,l.property)({type:Number})],t.prototype,"animation",void 0),f([(0,l.property)({type:String,attribute:"ghost-class"})],t.prototype,"ghostClass",void 0),f([(0,l.property)({type:String,attribute:"chosen-class"})],t.prototype,"chosenClass",void 0),f([(0,l.property)({type:Boolean,attribute:"force-fallback"})],t.prototype,"forceFallback",void 0),f([(0,l.property)({type:String,attribute:"fallback-class"})],t.prototype,"fallbackClass",void 0),f([(0,l.property)({type:String,attribute:"tabs-id"})],t.prototype,"tabsId",void 0),f([(0,l.property)({type:Boolean,attribute:"persist-selection"})],t.prototype,"persistSelection",void 0),f([(0,l.property)({type:String,attribute:"comp-unique-id"})],t.prototype,"compUniqueId",void 0),f([(0,l.property)({type:String})],t.prototype,"type",void 0),f([(0,l.property)({type:Boolean})],t.prototype,"newMomentum",void 0),f([(0,l.property)({type:String})],t.prototype,"variant",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuVisible",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuMeasured",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuOpen",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuSelected",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabMenuScrollable",void 0),f([(0,l.internalProperty)()],t.prototype,"moreTabMenuOffsetWidth",void 0),f([(0,l.internalProperty)()],t.prototype,"moreTabMenuMaxHeight",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsViewportDataList",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsFilteredAsVisibleList",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsFilteredAsHiddenList",void 0),f([(0,l.internalProperty)()],t.prototype,"noTabsVisible",void 0),f([(0,l.internalProperty)()],t.prototype,"defaultTabsOrderArray",void 0),f([(0,l.internalProperty)()],t.prototype,"tabsOrderPrefsArray",void 0),f([(0,l.internalProperty)()],t.prototype,"isMoreTabTruncated",void 0),f([(0,l.query)("slot[name='tab']")],t.prototype,"tabSlotElement",void 0),f([(0,l.query)("slot[name='panel']")],t.prototype,"panelSlotElement",void 0),f([(0,l.query)(".md-tab__list[part='tabs-list']")],t.prototype,"tabsListElement",void 0),f([(0,l.query)(".md-tabs__settings[part='md-tabs__settings']")],t.prototype,"tabsSettingsElement",void 0),f([(0,l.query)(".md-menu-overlay__more_tab")],t.prototype,"moreTabMenuElement",void 0),f([(0,l.query)("md-menu-overlay")],t.prototype,"menuOverlayElement",void 0),f([(0,l.query)(".md-tab__list[part='tabs-more-list']")],t.prototype,"tabsMoreListElement",void 0),f([(0,l.queryAll)(".md-menu-overlay__more_list md-tab")],t.prototype,"tabsCopyHiddenListElements",void 0),f([(0,l.query)("#visible-tabs-list")],t.prototype,"visibleTabsContainerElement",void 0),f([(0,l.query)("#tabs-more-list")],t.prototype,"hiddenTabsContainerElement",void 0),t=f([(0,o.wW)("md-tabs")],t),e.ELEMENT=t}(O||(O={}))},50565:(e,t,i)=>{i.d(t,{EditableTextfield:()=>s});var s,o=i(96408),r=i(31890),n=i(74548),a=i(26272),l=i(31347),d=i.n(l),h=i(41488),p=i(40333),c=i(23968),u=i(97822),m=i(18728),y=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends h.LitElement{constructor(){super(...arguments),this.alignment="left",this.disabled=!1,this.isEditing=!1,this.maxLines="",this.content="Click to edit text",this.message={type:"error",message:"That is not a valid input."},this.alert=!1,this.hideMessage=!1,this.pattern="",this.type=null,this.ariaLabel="editable field",this.ariaDescribedBy="",this.messageController=new o.Input.MessageController,this.reportValidity=()=>{this.dispatchEvent(new Event("invalid",{bubbles:!1,cancelable:!0,composed:!0}))},this.checkValidity=e=>{let t=!0;const i=i=>{null===e.match(i)&&(t=!1)};if(this.pattern)i(new RegExp(this.pattern));else if(e&&this.type)switch(this.type){case"integer":i(new RegExp(n.b.integerString));break;case"decimal":i(new RegExp(n.b.decimalString))}return t},this.handleFocus=()=>{this.disabled||(this.isEditing=!0,this.setRange())},this.handleKeydown=e=>{var t;const{key:i,code:s}=e;if(["Tab","Meta","Shift","Delete","Backspace","Arrow"].some((e=>s.includes(e))))return;("integer"===this.type&&i.includes(".")||("integer"===this.type||"decimal"===this.type)&&s.match("Space"))&&e.preventDefault();const o=(null===(t=this.editableField)||void 0===t?void 0:t.innerText.trim())+i;if(this.type)if(isNaN(Number(o)))e.preventDefault();else{if("integer"!==this.type||Number.isInteger(Number(o)))return;e.preventDefault()}},this.handleBlur=()=>{var e,t;this.isEditing=!1,this.maxLines.length>0&&(null===(e=this.editableField)||void 0===e||e.scrollTo(0,0)),this.content=(null===(t=this.editableField)||void 0===t?void 0:t.innerText.trim())||"",this.alert=!1,this.handleValidation()}}connectedCallback(){super.connectedCallback(),this.addEventListener("focus",this.handleFocus)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("focus",this.handleFocus)}firstUpdated(e){super.firstUpdated(e),this.innerText&&this.innerText.length>0?this.content=this.innerText.trim():this.innerText=d().sanitize(this.content)}updated(e){super.updated(e),e.has("content")&&this.editableField&&(this.editableField.innerText=d().sanitize(this.content))}setRange(){var e;if(this.editableField){const t=document.createRange(),i=window.getSelection(),s=null===(e=this.editableField.childNodes[0].nodeValue)||void 0===e?void 0:e.length;if(t.setStart(this.editableField.childNodes[0],s||0),t.collapse(!0),!i||0!==i.toString().length)return;i.removeAllRanges(),i.addRange(t),this.maxLines.length>0&&(this.editableField.scrollTop=this.editableField.scrollHeight)}}handleValidation(){var e;(this.type||this.pattern)&&((null===(e=this.checkValidity)||void 0===e?void 0:e.call(this,this.content))||(this.reportValidity(),this.showAlert()))}showAlert(){this.alert=!0}static get styles(){return[a.A,m.A]}get overflowStyles(){return this.maxLines.length&&this.maxLines.length>0&&`max-height: ${2*parseInt(this.maxLines)}rem; -webkit-line-clamp: ${this.maxLines}; word-break: break-all;`}messagesTemplate(){var e,t,i;return this.alert?h.html`
|
|
1327
1328
|
<div class="md-editable-textfield__messages" style="display: ${this.hideMessage?"none":"block"}">
|
|
1328
1329
|
<md-help-text
|
|
1329
1330
|
id="alert-message"
|
|
1330
1331
|
role="alert"
|
|
1331
1332
|
aria-live="assertive"
|
|
1332
1333
|
.messageType=${null===(e=this.message)||void 0===e?void 0:e.type}
|
|
1333
|
-
aria-errormessage=${(0,
|
|
1334
|
+
aria-errormessage=${(0,u.ifDefined)(null===(t=this.message)||void 0===t?void 0:t.message)}
|
|
1334
1335
|
>
|
|
1335
1336
|
${null===(i=this.message)||void 0===i?void 0:i.message}
|
|
1336
1337
|
</md-help-text>
|
|
1337
1338
|
</div>
|
|
1338
|
-
`:
|
|
1339
|
+
`:p.nothing}render(){var e;const t={[`md-editable-textfield--${this.alignment}`]:this.alignment,"md-editable-textfield--disabled":this.disabled,[`md-editable-textfield--${null===(e=this.message)||void 0===e?void 0:e.type}`]:this.alert&&!!this.message,"md-editable-textfield--textoverflow":this.maxLines.length>0&&!this.isEditing};return h.html`
|
|
1339
1340
|
<div
|
|
1340
1341
|
style="${this.overflowStyles}"
|
|
1341
1342
|
class="md-editable-textfield ${(0,c.classMap)(t)}"
|
|
1342
|
-
role=${(0,
|
|
1343
|
+
role=${(0,u.ifDefined)(this.disabled?void 0:"textbox")}
|
|
1343
1344
|
tabindex=${this.disabled?"-1":"0"}
|
|
1344
1345
|
?contenteditable=${this.isEditing}
|
|
1345
1346
|
@focus=${this.handleFocus}
|
|
1346
1347
|
@blur=${this.handleBlur}
|
|
1347
1348
|
@keydown=${e=>{this.handleKeydown(e)}}
|
|
1348
|
-
aria-invalid=${(0,
|
|
1349
|
-
aria-label=${(0,
|
|
1350
|
-
aria-describedby=${(0,
|
|
1349
|
+
aria-invalid=${(0,u.ifDefined)(this.disabled?void 0:this.alert?"true":"false")}
|
|
1350
|
+
aria-label=${(0,u.ifDefined)(this.disabled?void 0:this.ariaLabel)}
|
|
1351
|
+
aria-describedby=${(0,u.ifDefined)(this.disabled?void 0:this.ariaDescribedBy)}
|
|
1351
1352
|
>
|
|
1352
|
-
${
|
|
1353
|
+
${d().sanitize(this.content)}
|
|
1353
1354
|
</div>
|
|
1354
1355
|
${this.messagesTemplate()}
|
|
1355
|
-
`}};
|
|
1356
|
+
`}};y([(0,h.property)({type:String})],t.prototype,"alignment",void 0),y([(0,h.property)({type:Boolean})],t.prototype,"disabled",void 0),y([(0,h.property)({type:Boolean})],t.prototype,"isEditing",void 0),y([(0,h.property)({type:String,attribute:"max-lines",reflect:!0})],t.prototype,"maxLines",void 0),y([(0,h.property)({type:String,reflect:!0})],t.prototype,"content",void 0),y([(0,h.property)({type:Object})],t.prototype,"message",void 0),y([(0,h.property)({type:Boolean,reflect:!0})],t.prototype,"alert",void 0),y([(0,h.property)({type:Boolean})],t.prototype,"hideMessage",void 0),y([(0,h.property)({type:String})],t.prototype,"pattern",void 0),y([(0,h.property)({type:String})],t.prototype,"type",void 0),y([(0,h.property)({type:String})],t.prototype,"ariaLabel",void 0),y([(0,h.property)({type:String,attribute:"aria-described-by"})],t.prototype,"ariaDescribedBy",void 0),y([(0,h.query)(".md-editable-textfield")],t.prototype,"editableField",void 0),t=y([(0,r.w)("md-editable-field")],t),e.ELEMENT=t}(s||(s={}))},52619:(e,t,i)=>{i.d(t,{InputFile:()=>s}),i(96798);var s,o=i(3001),r=i(26272),n=i(45001),a=i.n(n),l=i(41488),d=i(40333),h=i(97822),p=i(45213),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},u=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this.acceptLanguage="javascript",this.getLocalization="Input File",this.acceptTypes="",this.fileName=""}static get styles(){return[r.A,p.A]}triggerFileLoad(e){e.preventDefault(),this.input.click()}handleFile(e){return u(this,void 0,void 0,(function*(){e.preventDefault();const t=this.input.files;if(t&&0!==t.length)for(const e of t){this.fileName=e.name;try{yield this.readFile(e)}catch(e){console.error("Error reading file",e)}}}))}readFile(e){return new Promise(((t,i)=>{const s=new FileReader;s.onload=e=>{t(e.target.result)},s.onerror=e=>i(e),s.readAsText(e)}))}importLanguage(e){return u(this,void 0,void 0,(function*(){try{const{default:t}=yield i(29599)(`./${e}`);a().registerLanguage(`${e}`,t),this.setAcceptTypes()}catch(e){console.warn("Please set correct language name")}}))}getAllAcceptTypes(){const e=a().listLanguages();return e.length?e.map((e=>a().getLanguage(`${e}`).aliases)).map((e=>e.map((e=>`.${e}`)))).join(","):""}setAcceptTypes(){this.acceptTypes=this.getAllAcceptTypes()}updated(e){super.updated(e),e.has("acceptLanguage")&&this.importLanguage(this.acceptLanguage)}render(){return l.html`
|
|
1356
1357
|
<div class="md-input-file">
|
|
1357
1358
|
<label for="file-input">
|
|
1358
1359
|
<md-button color="blue" class="md-input-file-btn" @click=${this.triggerFileLoad}>
|
|
@@ -1368,11 +1369,11 @@
|
|
|
1368
1369
|
@change=${e=>this.handleFile(e)}
|
|
1369
1370
|
/>
|
|
1370
1371
|
</div>
|
|
1371
|
-
`}};
|
|
1372
|
+
`}};c([(0,l.property)({type:String,attribute:"accept-language"})],t.prototype,"acceptLanguage",void 0),c([(0,l.property)({type:String})],t.prototype,"getLocalization",void 0),c([(0,l.query)("input[type='file']")],t.prototype,"input",void 0),c([(0,l.internalProperty)()],t.prototype,"acceptTypes",void 0),c([(0,l.internalProperty)()],t.prototype,"fileName",void 0),t=c([(0,o.wW)("md-input-file")],t),e.ELEMENT=t}(s||(s={}))},55294:(e,t,i)=>{i.d(t,{CheckboxGroup:()=>s});var s,o=i(90195),r=i(3001),n=i(26272),a=i(31890),l=i(41488),d=i(18841),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.Io)(l.LitElement)){constructor(){super(...arguments),this.label="group",this.alignment="vertical"}static get styles(){return[n.A,d.A]}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleKeyDown)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeyDown)}switchCheckboxOnArrowPress(e,t=1){const i=super.getAvailableSelectedIndex(e,t);-1!==i&&(this.selected=i)}handleKeyDown(e){const{code:t}=e;switch(t){case o.Uz.ArrowUp:case o.Uz.ArrowLeft:0===this.selected?this.switchCheckboxOnArrowPress(this.slotted.length-1,-1):this.switchCheckboxOnArrowPress(this.selected-1,-1);break;case o.Uz.ArrowDown:case o.Uz.ArrowRight:this.selected===this.slotted.length-1?this.switchCheckboxOnArrowPress(0):this.switchCheckboxOnArrowPress(this.selected+1)}}get slotElement(){return this.checkboxSlot}render(){return l.html`
|
|
1372
1373
|
<div role="group" aria-labelledby="id-group-label">
|
|
1373
1374
|
<slot name="checkbox"></slot>
|
|
1374
1375
|
</div>
|
|
1375
|
-
`}};h([(0,l.property)({type:String,attribute:"group-label"})],t.prototype,"label",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),h([(0,l.query)("slot[name='checkbox']")],t.prototype,"checkboxSlot",void 0),t=h([(0,a.w)("md-checkboxgroup")],t),e.ELEMENT=t}(s||(s={}))},57346:e=>{e.exports=S},58088:e=>{e.exports=
|
|
1376
|
+
`}};h([(0,l.property)({type:String,attribute:"group-label"})],t.prototype,"label",void 0),h([(0,l.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),h([(0,l.query)("slot[name='checkbox']")],t.prototype,"checkboxSlot",void 0),t=h([(0,a.w)("md-checkboxgroup")],t),e.ELEMENT=t}(s||(s={}))},57346:e=>{e.exports=S},58088:e=>{e.exports=x},58287:(e,t,i)=>{i.d(t,{ProgressBar:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(23968),l=i(31107),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.dynamic=!1,this.color="",this.label="",this.displayFormat="percentage",this.type="indeterminate",this.min=0,this.max=100,this.value=25,this.adjustedValue=0,this.valueFraction=0,this.meterWidth="100",this.getDisplayFormat=()=>"indeterminate"===this.type?(this.value=100,null):(this.adjustedValue=this.max-this.value<0?this.max:this.value,this.valueFraction=this.adjustedValue/this.max*100||0,this.meterWidth=this.valueFraction.toFixed(0)+"%","none"===this.displayFormat?null:"percentage"===this.displayFormat?this.meterWidth:`${this.adjustedValue} / ${this.max}`),this.getColor=()=>this.color?this.color:this.dynamic?this.valueFraction<25?"success":this.valueFraction<50?"info":this.valueFraction<75?"warning":"danger":void 0}connectedCallback(){super.connectedCallback(),this.requestUpdate("value")}static get styles(){return[r.A,l.A]}render(){const e={[`progress--${this.type}`]:this.type,[`progress--${this.color}`]:this.color};return n.html`
|
|
1376
1377
|
<span>
|
|
1377
1378
|
<div class="progressbar-info" data-key="${this.min}">
|
|
1378
1379
|
<span class="progressbar-label">${this.label}</span>
|
|
@@ -1392,8 +1393,8 @@
|
|
|
1392
1393
|
</span>
|
|
1393
1394
|
</div>
|
|
1394
1395
|
</span>
|
|
1395
|
-
`}};d([(0,n.property)({type:Boolean})],t.prototype,"dynamic",void 0),d([(0,n.property)({type:String})],t.prototype,"color",void 0),d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"displayFormat",void 0),d([(0,n.property)({type:String})],t.prototype,"type",void 0),d([(0,n.property)({type:Number})],t.prototype,"min",void 0),d([(0,n.property)({type:Number})],t.prototype,"max",void 0),d([(0,n.property)({type:Number})],t.prototype,"value",void 0),d([(0,n.property)({type:Number})],t.prototype,"adjustedValue",void 0),d([(0,n.property)({type:Number})],t.prototype,"valueFraction",void 0),d([(0,n.property)({type:String})],t.prototype,"meterWidth",void 0),t=d([(0,o.w)("md-progress-bar")],t),e.ELEMENT=t}(s||(s={}))},58871:(e,t,i)=>{i.d(t,{FloatingMinimizedModal:()=>s}),i(96798),i(61200);var s,o=i(90195),r=i(3001),n=i(31890),a=i(66677),l=i(26272),d=(i(58088),i(57346),i(69e3),i(20727)),h=i.n(d),
|
|
1396
|
-
${this.show?
|
|
1396
|
+
`}};d([(0,n.property)({type:Boolean})],t.prototype,"dynamic",void 0),d([(0,n.property)({type:String})],t.prototype,"color",void 0),d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"displayFormat",void 0),d([(0,n.property)({type:String})],t.prototype,"type",void 0),d([(0,n.property)({type:Number})],t.prototype,"min",void 0),d([(0,n.property)({type:Number})],t.prototype,"max",void 0),d([(0,n.property)({type:Number})],t.prototype,"value",void 0),d([(0,n.property)({type:Number})],t.prototype,"adjustedValue",void 0),d([(0,n.property)({type:Number})],t.prototype,"valueFraction",void 0),d([(0,n.property)({type:String})],t.prototype,"meterWidth",void 0),t=d([(0,o.w)("md-progress-bar")],t),e.ELEMENT=t}(s||(s={}))},58871:(e,t,i)=>{i.d(t,{FloatingMinimizedModal:()=>s}),i(96798),i(61200);var s,o=i(90195),r=i(3001),n=i(31890),a=i(66677),l=i(26272),d=(i(58088),i(57346),i(69e3),i(20727)),h=i.n(d),p=(i(3288),i(41488)),c=i(40333),u=i(97822),m=i(67330),y=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.yC)(p.LitElement)){constructor(){super(...arguments),this.heading="",this.label="",this.show=!1,this.closeAriaLabel="Close Modal",this.minimize=!1,this.dragOccured=!1,this.containerTransform="",this.applyInitialPosition=!0,this.getInitialPosition=()=>{var e,t;return this.applyInitialPosition&&this.minPosition?{initialX:Number(null===(e=this.minPosition)||void 0===e?void 0:e.x),initialY:Number(null===(t=this.minPosition)||void 0===t?void 0:t.y)}:{initialX:0,initialY:0}},this.dragMoveListener=e=>{const{target:t}=e,{x:i,y:s}=this.getTransformValues(e);this.setTargetPosition(t,i,s),this.applyInitialPosition=!1},this.dragEndListener=()=>{this.dragOccured=!0,this.setContainerRect()}}static get styles(){return[l.A,m.A]}connectedCallback(){super.connectedCallback(),window.addEventListener("resize",(0,a.sg)((()=>this.setInteractInstance()),250))}updated(e){super.updated(e),e.has("show")&&(this.container&&this.show?(this.applyInitialPosition=!0,this.setContainerRect(),this.setInteractInstance(),this.setFocusOnContainer()):(this.cleanContainerStyles(),this.destroyInteractInstance())),this.container&&e.has("minPosition")&&!e.has("show")&&this.setInitialTargetPosition(),e.has("minimize")&&void 0!==e.get("minimize")&&this.setFocusOnContainer()}isNewPositionNotSame(){var e,t,i,s;if(this.container)return Number(null===(e=this.container)||void 0===e?void 0:e.getAttribute("data-x"))!==(null===(t=this.minPosition)||void 0===t?void 0:t.x)||Number(null===(i=this.container)||void 0===i?void 0:i.getAttribute("data-y"))!==(null===(s=this.minPosition)||void 0===s?void 0:s.y)}setInitialTargetPosition(){var e,t;this.container&&this.isNewPositionNotSame()&&this.setTargetPosition(this.container,Number(null===(e=this.minPosition)||void 0===e?void 0:e.x),Number(null===(t=this.minPosition)||void 0===t?void 0:t.y))}setFocusOnContainer(){this.container&&(this.container.setAttribute("tabindex","0"),this.container.focus())}cleanContainerStyles(){this.containerTransform=""}getContainerTransform(){const e=this.container.getAttribute("data-x"),t=this.container.getAttribute("data-y");return e&&t?(this.dispatchEvent(new CustomEvent("floating-modal-minimize-location",{composed:!0,bubbles:!0,detail:{transform:{x:e,y:t}}})),`translate(${e}px, ${t}px)`):this.container.style.transform}setContainerRect(){requestAnimationFrame((()=>{return e=this,t=void 0,s=function*(){yield this.updateComplete,this.containerTransform=this.getContainerTransform()},new((i=void 0)||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}));var e,t,i,s}))}setInteractInstance(){requestAnimationFrame((()=>{this.container&&h()(this.container).draggable({autoScroll:!0,allowFrom:this.header,listeners:{move:this.dragMoveListener,end:this.dragEndListener},modifiers:[h().modifiers.restrictRect({restriction:document.body.getBoundingClientRect(),endOnly:!0})]})}))}handleKeyDown(e){e.code!==o.Uz.Enter&&e.code!==o.Uz.Space||this.handleMinimize(e)}handleClose(e){this.show=!1,this.dispatchEvent(new CustomEvent("floating-modal-close",{composed:!0,bubbles:!0,detail:{srcEvent:e}})),e.stopPropagation()}handleMinimize(e){this.dragOccured||this.dispatchEvent(new CustomEvent("floating-min-modal-minimize",{composed:!0,bubbles:!0,detail:{srcEvent:e}})),this.dragOccured=!1}getTransformValues(e){const{target:t,dx:i,dy:s}=e,{initialX:o,initialY:r}=this.getInitialPosition();return{x:(parseFloat(t.getAttribute("data-x"))||0)+i+o,y:(parseFloat(t.getAttribute("data-y"))||0)+s+r}}setTargetPosition(e,t,i){e.style.transform=`translate(${t}px, ${i}px)`,e.setAttribute("data-x",`${t}`),e.setAttribute("data-y",`${i}`)}destroyInteractInstance(){this.container&&h().isSet(this.container)&&h()(this.container).unset()}disconnectedCallback(){super.disconnectedCallback(),this.destroyInteractInstance(),window.removeEventListener("resize",(0,a.sg)((()=>this.setInteractInstance()),250))}render(){return p.html`
|
|
1397
|
+
${this.show?p.html`
|
|
1397
1398
|
<div
|
|
1398
1399
|
class="md-floating ${this.minimize?"":"hide"} md-floating-minimize"
|
|
1399
1400
|
@click=${this.handleMinimize}
|
|
@@ -1407,7 +1408,7 @@
|
|
|
1407
1408
|
>
|
|
1408
1409
|
<div tabindex="-1" class="md-floating__header ${this.minimize?"md-floating__header-minimize":""}">
|
|
1409
1410
|
<div class="md-floating__header-text">
|
|
1410
|
-
${this.heading?
|
|
1411
|
+
${this.heading?p.html` ${this.heading} `:p.html` <slot></slot> `}
|
|
1411
1412
|
</div>
|
|
1412
1413
|
<md-button
|
|
1413
1414
|
color="color-none"
|
|
@@ -1420,8 +1421,8 @@
|
|
|
1420
1421
|
</md-button>
|
|
1421
1422
|
</div>
|
|
1422
1423
|
</div>
|
|
1423
|
-
`:
|
|
1424
|
-
`}};
|
|
1424
|
+
`:c.nothing}
|
|
1425
|
+
`}};y([(0,p.property)({type:String})],t.prototype,"heading",void 0),y([(0,p.property)({type:String})],t.prototype,"label",void 0),y([(0,p.property)({type:Boolean,reflect:!0})],t.prototype,"show",void 0),y([(0,p.property)({type:String,attribute:"close-aria-label"})],t.prototype,"closeAriaLabel",void 0),y([(0,p.property)({type:Boolean,reflect:!0})],t.prototype,"minimize",void 0),y([(0,p.property)({type:Object})],t.prototype,"minPosition",void 0),y([(0,p.query)(".md-floating")],t.prototype,"container",void 0),y([(0,p.query)(".md-floating__header")],t.prototype,"header",void 0),y([(0,p.internalProperty)()],t.prototype,"dragOccured",void 0),y([(0,p.internalProperty)()],t.prototype,"containerTransform",void 0),t=y([(0,n.w)("md-floating-modal-minimized")],t),e.ELEMENT=t}(s||(s={}))},60046:(e,t,i)=>{i.d(t,{Chip:()=>s}),i(58287),i(83192);var s,o=i(90195),r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(23968),h=i(97822),p=i(49618),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.color="",this.bgColor="",this.textColor="",this.height="",this.icon="",this.iconColor="",this.iconSize="",this.role="group",this.id="",this.small=!1,this.readonly=!1,this.selected=!1,this.disabled=!1,this.determinateProgress=0,this.indeterminateProgress=!1,this.tooltipText="",this.tooltipPlacement="auto",this.iconSet="momentumUI",this.suppressDefaultMaxWidth=!1,this.value="",this.textOverflow=!1,this.renderedText="",this.MAX_LENGTH=18,this.PRE_TRUNC_CHARS=6,this.POST_TRUNC_CHARS=9,this.DOT_COUNT=3,this.selectionChange=e=>{this.dispatchEvent(new CustomEvent("chip-selected",{composed:!0,bubbles:!0,detail:{selected:e}}))},this.handleClear=e=>{this.dispatchEvent(new CustomEvent("chip-deleted",{composed:!0,bubbles:!0,detail:{id:e}}))},this.handleSelect=()=>{this.disabled||(this.selected=!0,this.selectionChange(!0))},this.handleDeSelect=()=>{this.selected=!1,this.selectionChange(!1)},this.renderBgColor=()=>this.bgColor?`background-color: ${this.bgColor};`:l.nothing,this.renderTextColor=()=>this.textColor?`color: ${this.textColor};`:l.nothing,this.renderHeight=()=>this.height?`height: ${this.height};`:l.nothing,this.getStyles=()=>this.bgColor||this.textColor||this.height?a.html`
|
|
1425
1426
|
<style>
|
|
1426
1427
|
:host .md-chip {
|
|
1427
1428
|
${this.renderBgColor()};
|
|
@@ -1429,7 +1430,7 @@
|
|
|
1429
1430
|
${this.renderHeight()};
|
|
1430
1431
|
}
|
|
1431
1432
|
</style>
|
|
1432
|
-
`:l.nothing}connectedCallback(){super.connectedCallback(),this.truncStringPortion(this.value),this.setAttribute("role",this.role)}updated(e){super.updated(e),this.truncStringPortion(this.value)}truncStringPortion(e,t=this.PRE_TRUNC_CHARS,i=this.POST_TRUNC_CHARS,s=this.DOT_COUNT){if(this.value.length>this.MAX_LENGTH){let o="";o+=e.substring(0,t),o+=".".repeat(s),o+=e.substring(e.length-i,e.length),this.renderedText=o,this.textOverflow=!0}else this.renderedText=this.value}handleClick(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector("md-tooltip");null==t||t.dispatchEvent(new CustomEvent("tooltip-destroy",{bubbles:!0,composed:!0,detail:{placement:null==t?void 0:t.placement,reference:null==t?void 0:t.reference,popper:null==t?void 0:t.popper}})),this.dispatchEvent(new CustomEvent("chip-interaction",{composed:!0,bubbles:!0,detail:{id:this.id}}))}handleKeydown(e){switch(e.code){case o.Uz.Space:case o.Uz.Enter:this.handleSelect(),this.handleClick()}}static get styles(){return[n.A,
|
|
1433
|
+
`:l.nothing}connectedCallback(){super.connectedCallback(),this.truncStringPortion(this.value),this.setAttribute("role",this.role)}updated(e){super.updated(e),this.truncStringPortion(this.value)}truncStringPortion(e,t=this.PRE_TRUNC_CHARS,i=this.POST_TRUNC_CHARS,s=this.DOT_COUNT){if(this.value.length>this.MAX_LENGTH){let o="";o+=e.substring(0,t),o+=".".repeat(s),o+=e.substring(e.length-i,e.length),this.renderedText=o,this.textOverflow=!0}else this.renderedText=this.value}handleClick(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelector("md-tooltip");null==t||t.dispatchEvent(new CustomEvent("tooltip-destroy",{bubbles:!0,composed:!0,detail:{placement:null==t?void 0:t.placement,reference:null==t?void 0:t.reference,popper:null==t?void 0:t.popper}})),this.dispatchEvent(new CustomEvent("chip-interaction",{composed:!0,bubbles:!0,detail:{id:this.id}}))}handleKeydown(e){switch(e.code){case o.Uz.Space:case o.Uz.Enter:this.handleSelect(),this.handleClick()}}static get styles(){return[n.A,p.A]}loadingTemplate(){return this.determinateProgress||this.indeterminateProgress?this.determinateProgress?a.html`
|
|
1433
1434
|
<md-progress-bar
|
|
1434
1435
|
class="md-chip--loading"
|
|
1435
1436
|
type="determinate"
|
|
@@ -1471,11 +1472,11 @@
|
|
|
1471
1472
|
<slot name="custom-right-content" part="chip-right"> </slot>
|
|
1472
1473
|
</span>
|
|
1473
1474
|
</md-tooltip>
|
|
1474
|
-
`}};
|
|
1475
|
+
`}};c([(0,a.property)({type:String})],t.prototype,"color",void 0),c([(0,a.property)({type:String})],t.prototype,"bgColor",void 0),c([(0,a.property)({type:String})],t.prototype,"textColor",void 0),c([(0,a.property)({type:String})],t.prototype,"height",void 0),c([(0,a.property)({type:String})],t.prototype,"icon",void 0),c([(0,a.property)({type:String})],t.prototype,"iconColor",void 0),c([(0,a.property)({type:String})],t.prototype,"iconSize",void 0),c([(0,a.property)({type:String})],t.prototype,"role",void 0),c([(0,a.property)({type:String,reflect:!0})],t.prototype,"id",void 0),c([(0,a.property)({type:Boolean})],t.prototype,"small",void 0),c([(0,a.property)({type:Boolean})],t.prototype,"readonly",void 0),c([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"selected",void 0),c([(0,a.property)({type:Boolean})],t.prototype,"disabled",void 0),c([(0,a.property)({type:Number})],t.prototype,"determinateProgress",void 0),c([(0,a.property)({type:Boolean})],t.prototype,"indeterminateProgress",void 0),c([(0,a.property)({type:String})],t.prototype,"tooltipText",void 0),c([(0,a.property)({type:String})],t.prototype,"tooltipPlacement",void 0),c([(0,a.property)({type:String})],t.prototype,"iconSet",void 0),c([(0,a.property)({type:Boolean,attribute:"suppress-default-max-width"})],t.prototype,"suppressDefaultMaxWidth",void 0),c([(0,a.property)({type:String,hasChanged:(e,t)=>e!==t})],t.prototype,"value",void 0),c([(0,a.internalProperty)({hasChanged:(e,t)=>e!==t})],t.prototype,"textOverflow",void 0),c([(0,a.internalProperty)()],t.prototype,"renderedText",void 0),t=c([(0,r.w)("md-chip")],t),e.ELEMENT=t}(s||(s={}))},60554:e=>{e.exports=n},61200:(e,t,i)=>{i.d(t,{Icon:()=>s}),i(96798);var s,o=i(31890),r=i(26272),n=i(32022),a=i.n(n),l=i(60554),d=i.n(l),h=i(41488),p=i(40333),c=i(23968),u=i(97822),m=i(8229),y=i(57955),b=i(66873),v=i(81786),g=i(9223),f=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){var t;let i=t=class extends h.LitElement{constructor(){super(...arguments),this.color="",this.description="",this.name="",this.id="",this.size="",this.title="",this.ariaHidden=null,this.type="",this.isActive=!1,this.isComboBoxIcon=!1,this.sizeOverrided=!1,this.iconSet="momentumUI",this.svgIcon=null,this._ariaLabel="",this.consoleHandler=(e,t)=>{switch(e){case"color-warn":console.warn(`[@momentum-ui/web-component] Icon: ${t} may not exist in the design system, please use a color name from https://momentum.design/styles/color/style`);break;case"name-error":console.warn(`[@momentum-ui/web-component] Icon: Icon ${t} does not exist in the design system. Visit https://momentum.design/icons for a list of available icons or to request a new icon.`)}}}isSvgAlreadyLoaded(e){var t,i;return!!this.svgIcon&&(null===(i=null===(t=this.svgIcon)||void 0===t?void 0:t.getAttribute("class"))||void 0===i?void 0:i.includes(e))}loadSvgIcon(e){return t=this,i=void 0,o=function*(){var t,i;if(this.isSvgAlreadyLoaded(e))return;const s="momentumBrandVisuals"===this.iconSet||"svg"===this.iconSet?yield(0,g.Jp)(this.computedSvgPath,e,"svg"):yield(0,g.D6)(e);s&&(this.svgIcon=s,null===(t=this.svgIcon)||void 0===t||t.setAttribute("class",`icon ${e}`),null===(i=this.svgIcon)||void 0===i||i.setAttribute("part","icon"),this.setSvgIconAttributes(),this.requestUpdate())},new((s=void 0)||(s=Promise))((function(e,r){function n(e){try{l(o.next(e))}catch(e){r(e)}}function a(e){try{l(o.throw(e))}catch(e){r(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof s?i:new s((function(e){e(i)}))).then(n,a)}l((o=o.apply(t,i||[])).next())}));var t,i,s,o}setSvgIconAttributes(){this.svgIcon&&(this.iconFontSize&&this.svgIcon.setAttribute("width",`${this.iconFontSize}px`),this.iconFontSize&&this.svgIcon.setAttribute("height",`${this.iconFontSize}px`),this.color?this.svgIcon.setAttribute("fill",this.iconColor):this.svgIcon.setAttribute("fill","currentColor"))}get computedSvgPath(){return this.svgUrl?this.svgUrl:v.O.svgIconUrl}get svgIconName(){if("momentumDesign"===this.iconSet||"momentumBrandVisuals"===this.iconSet||"svg"===this.iconSet)return this.name;const e=this.momentumUIIconLookupName,i=t.designLookup.get(e);return null!=i?i:e}updated(e){if(super.updated(e),this.doesIconSetSupportSVG)if(e.has("name")||e.has("iconSet")){const e=this.svgIconName;e&&"Unknown"!==e&&this.loadSvgIcon(e)}else(e.has("iconFontSize")||e.has("color"))&&this.setSvgIconAttributes()}get ariaLabel(){return this._ariaLabel?this._ariaLabel:this.title&&this.description?`${this.title} ${this.description}`:this.title?this.title:this.description?this.description:"icon"}set ariaLabel(e){const t=this._ariaLabel;this._ariaLabel=e,this.requestUpdate("ariaLabel",t)}get buttonClassMap(){return{[`md-button--icon-${this.type}`]:!!this.type}}get iconFontSize(){const e=this.name.split("_")[1];return this.size||e||16}get iconColor(){return this.color.startsWith("#")?(this.consoleHandler("color-warn",this.color),this.color):this.color.startsWith("var(")?this.color:d()(this.color)}get iconClassMap(){return{"md-combobox-input__icon":this.isComboBoxIcon,"md-combobox-input__icon--active":this.isComboBoxIcon&&this.isActive,[`${this.iconName}`]:!!this.iconName}}get momentumUIIconLookupName(){let e=this.name;return e=e.startsWith("icon-")?e.substring(5):e,e=e.split("_")[0],e}getIconName(){let e=this.name;return e=e.startsWith("icon-")?e.substring(5):e,e}handleSizeOverride(e){return`${e.split("_")[0]}_${this.iconFontSize}`}get iconName(){const e=this.getIconName();return this.sizeOverrided?this.handleSizeOverride(e):a().includes(e)||""===e?`icon-${e}`:this.consoleHandler("name-error",e)}get iconStyleMap(){return Object.assign(Object.assign({},this.iconFontSize&&{"font-size":`${this.iconFontSize}px`}),this.color&&{color:this.iconColor})}static get styles(){return[r.A,b.A]}handleIconClick(e){this.dispatchEvent(new CustomEvent("icon-click",{bubbles:!0,composed:!0,detail:{srcEvent:e}}))}get doesIconSetSupportSVG(){return"momentumDesign"===this.iconSet||"preferMomentumDesign"===this.iconSet||"momentumBrandVisuals"===this.iconSet||"svg"===this.iconSet}get isSVGRender(){return this.svgIcon&&"preferMomentumDesign"===this.iconSet||"momentumDesign"===this.iconSet||"momentumBrandVisuals"===this.iconSet||"svg"===this.iconSet}render(){return this.isSVGRender?this.renderSVGIcon():this.renderFontIcon()}renderFontIcon(){var e;return h.html`
|
|
1475
1476
|
<i
|
|
1476
1477
|
part="icon"
|
|
1477
1478
|
id=${this.id}
|
|
1478
|
-
class="md-icon icon ${(0,
|
|
1479
|
+
class="md-icon icon ${(0,c.classMap)(this.iconClassMap)}"
|
|
1479
1480
|
style=${(0,m.styleMap)(this.iconStyleMap)}
|
|
1480
1481
|
role="img"
|
|
1481
1482
|
aria-label=${this.ariaLabel}
|
|
@@ -1494,9 +1495,9 @@
|
|
|
1494
1495
|
aria-hidden=${(0,u.ifDefined)(null!==(e=this.ariaHidden)&&void 0!==e?e:void 0)}
|
|
1495
1496
|
@click=${e=>this.handleIconClick(e)}
|
|
1496
1497
|
>
|
|
1497
|
-
${this.svgIcon?this.svgIcon:
|
|
1498
|
+
${this.svgIcon?this.svgIcon:p.nothing}
|
|
1498
1499
|
</div>
|
|
1499
|
-
`}};
|
|
1500
|
+
`}};i.designLookup=new Map(Object.entries(y)),f([(0,h.property)({type:String})],i.prototype,"color",void 0),f([(0,h.property)({type:String})],i.prototype,"description",void 0),f([(0,h.property)({type:String})],i.prototype,"name",void 0),f([(0,h.property)({type:String})],i.prototype,"id",void 0),f([(0,h.property)({type:String})],i.prototype,"size",void 0),f([(0,h.property)({type:String})],i.prototype,"title",void 0),f([(0,h.property)({type:String})],i.prototype,"ariaHidden",void 0),f([(0,h.property)({type:String})],i.prototype,"type",void 0),f([(0,h.property)({type:Boolean})],i.prototype,"isActive",void 0),f([(0,h.property)({type:Boolean})],i.prototype,"isComboBoxIcon",void 0),f([(0,h.property)({type:Boolean})],i.prototype,"sizeOverrided",void 0),f([(0,h.property)({type:String})],i.prototype,"iconSet",void 0),f([(0,h.property)({type:String,attribute:"svg-url"})],i.prototype,"svgUrl",void 0),f([(0,h.internalProperty)()],i.prototype,"svgIcon",void 0),f([(0,h.property)({type:String})],i.prototype,"ariaLabel",null),i=t=f([(0,o.w)("md-icon")],i),e.ELEMENT=i}(s||(s={}))},61997:(e,t,i)=>{i.d(t,{MeetingAlert:()=>s}),i(38028),i(96798),i(61200);var s,o=i(90195),r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(48064),h=i(56338),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.attendees=[{title:"Attendee",src:null,alt:"Attendee"}],this.closeAriaLabel="close",this.onKeyDown=null,this.onSnooze=null,this.message="",this.snoozeAriaLabel="snooze",this.role="button",this.show=!1,this.src="",this.status="",this.userStyles="",this.title="",this._onSnooze=e=>{this.dispatchEvent(new CustomEvent("snooze",{composed:!0,detail:{srcEvent:e}}))},this._onClose=e=>{this.dispatchEvent(new CustomEvent("close",{composed:!0,detail:{srcEvent:e}}))},this.handleSnooze=e=>{this.onSnooze?this.onSnooze(e):this._onSnooze(e),e.stopPropagation()},this.handleClose=e=>{this._onClose(e),e.stopPropagation()},this.handleKeyDown=e=>{if(e.code===o.Uz.Escape&&this.handleClose(e),e.code===o.Uz.Enter||e.code===o.Uz.Space){switch(e.target.attributes.getNamedItem("aria-label").value){case"close":this.handleClose(e);break;case"snooze":this.handleSnooze(e)}e.preventDefault()}this.onKeyDown&&this.onKeyDown(e)}}getStyles(){return a.html`
|
|
1500
1501
|
<style>
|
|
1501
1502
|
::slotted(img) {
|
|
1502
1503
|
display: inline-block;
|
|
@@ -1508,9 +1509,9 @@
|
|
|
1508
1509
|
}
|
|
1509
1510
|
${this.userStyles}
|
|
1510
1511
|
</style>
|
|
1511
|
-
`}static get styles(){return[n.A,h.A]}render(){const{attendees:e,message:t,onSnooze:i,role:s,src:o,status:r,title:n,closeAriaLabel:h,show:
|
|
1512
|
+
`}static get styles(){return[n.A,h.A]}render(){const{attendees:e,message:t,onSnooze:i,role:s,src:o,status:r,title:n,closeAriaLabel:h,show:p,snoozeAriaLabel:c}=this;return a.html`
|
|
1512
1513
|
${this.getStyles()}
|
|
1513
|
-
${
|
|
1514
|
+
${p?a.html`
|
|
1514
1515
|
<div
|
|
1515
1516
|
aria-label="Meeting Alert"
|
|
1516
1517
|
class=${"md-alert md-alert--meeting"}
|
|
@@ -1527,7 +1528,7 @@
|
|
|
1527
1528
|
<div class="md-alert__button">
|
|
1528
1529
|
<md-button
|
|
1529
1530
|
variant="secondary"
|
|
1530
|
-
aria-label=${
|
|
1531
|
+
aria-label=${c}
|
|
1531
1532
|
circle
|
|
1532
1533
|
@click=${e=>{this.handleSnooze(e)}}
|
|
1533
1534
|
.size=${40}
|
|
@@ -1550,7 +1551,7 @@
|
|
|
1550
1551
|
</slot>
|
|
1551
1552
|
</div>
|
|
1552
1553
|
`:l.nothing}
|
|
1553
|
-
`}};
|
|
1554
|
+
`}};p([(0,a.property)({type:Array})],t.prototype,"attendees",void 0),p([(0,a.property)({type:String})],t.prototype,"closeAriaLabel",void 0),p([(0,a.property)({attribute:!1})],t.prototype,"onKeyDown",void 0),p([(0,a.property)({attribute:!1})],t.prototype,"onSnooze",void 0),p([(0,a.property)({type:String})],t.prototype,"message",void 0),p([(0,a.property)({type:String})],t.prototype,"snoozeAriaLabel",void 0),p([(0,a.property)({type:String})],t.prototype,"role",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"show",void 0),p([(0,a.property)({type:String})],t.prototype,"src",void 0),p([(0,a.property)({type:String})],t.prototype,"status",void 0),p([(0,a.property)({type:String})],t.prototype,"userStyles",void 0),p([(0,a.property)({type:String})],t.prototype,"title",void 0),t=p([(0,r.w)("md-meeting-alert")],t),e.ELEMENT=t}(s||(s={}))},63208:(e,t,i)=>{i.d(t,{DatePickerCalendar:()=>s}),i(17814),i(61200);var s,o=i(31890),r=i(81625),n=i(26272),a=i(41488),l=i(14974),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.monthFormat="MMMM yyyy",this.filterParams=void 0,this.handleMonthChange=void 0,this.datePickerProps=void 0,this.shortDay=!1,this.viewAnchorDate=(0,r.tB)(),this.localeMonth=void 0,this.setDate=(e,t)=>{this.viewAnchorDate=e,null==t||t()},this.increaseMonth=e=>{const{handleMonthChange:t}=this,{viewAnchorDate:i}=this;this.setDate((0,r.PS)(i,1),(()=>t&&t(e,this.viewAnchorDate)))},this.decreaseMonth=e=>{const{handleMonthChange:t}=this,{viewAnchorDate:i}=this;this.setDate((0,r.SL)(i,1),(()=>t&&t(e,this.viewAnchorDate)))},this.renderMonthName=()=>a.html` <div class="md-datepicker__navigation--current-month" aria-live="polite">${this.localeMonth}</div> `,this.renderPreviousMonthButton=()=>{var e,t;const i=(null===(e=this.filterParams)||void 0===e?void 0:e.minDate)&&(0,r.PD)(this.viewAnchorDate,null===(t=this.filterParams)||void 0===t?void 0:t.minDate);return a.html`
|
|
1554
1555
|
<md-button
|
|
1555
1556
|
variant="ghost"
|
|
1556
1557
|
circle
|
|
@@ -1596,7 +1597,7 @@
|
|
|
1596
1597
|
</div>
|
|
1597
1598
|
`}connectedCallback(){var e,t,i;super.connectedCallback(),this.viewAnchorDate=(null===(e=this.datePickerProps)||void 0===e?void 0:e.focused)||(null===(t=this.datePickerProps)||void 0===t?void 0:t.selected)||(0,r.tB)(),this.localeMonth=(0,r.WV)(this.viewAnchorDate,(null===(i=this.datePickerProps)||void 0===i?void 0:i.locale)||"en").toFormat(this.monthFormat)}updated(e){var t,i,s;super.updated(e),e.has("datePickerProps")&&(null===(null===(t=this.datePickerProps)||void 0===t?void 0:t.selected.invalidReason)&&(this.viewAnchorDate=this.datePickerProps.selected||(0,r.tB)()),this.localeMonth=(0,r.WV)(this.viewAnchorDate,(null===(i=this.datePickerProps)||void 0===i?void 0:i.locale)||"en").toFormat(this.monthFormat)),e.has("viewAnchorDate")&&(this.localeMonth=(0,r.WV)(this.viewAnchorDate,(null===(s=this.datePickerProps)||void 0===s?void 0:s.locale)||"en").toFormat(this.monthFormat))}getWeekDayName(e,t){return this.shortDay?(0,r.XY)(e,t):(0,r.DY)(e,t)}static get styles(){return[n.A,l.A]}render(){return a.html`
|
|
1598
1599
|
<div class="md-datepicker__calendar" id="Datepicker-Calendar">${this.viewAnchorDate&&this.renderMonth()}</div>
|
|
1599
|
-
`}};d([(0,a.property)({attribute:!1})],t.prototype,"monthFormat",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"handleMonthChange",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),d([(0,a.property)({type:Boolean,reflect:!0,attribute:"short-day"})],t.prototype,"shortDay",void 0),d([(0,a.internalProperty)()],t.prototype,"viewAnchorDate",void 0),d([(0,a.internalProperty)()],t.prototype,"localeMonth",void 0),t=d([(0,o.w)("md-datepicker-calendar")],t),e.ELEMENT=t}(s||(s={}))},63704:(e,t,i)=>{i.d(t,{Badge:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(97822),h=i(92019),
|
|
1600
|
+
`}};d([(0,a.property)({attribute:!1})],t.prototype,"monthFormat",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"filterParams",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"handleMonthChange",void 0),d([(0,a.property)({attribute:!1})],t.prototype,"datePickerProps",void 0),d([(0,a.property)({type:Boolean,reflect:!0,attribute:"short-day"})],t.prototype,"shortDay",void 0),d([(0,a.internalProperty)()],t.prototype,"viewAnchorDate",void 0),d([(0,a.internalProperty)()],t.prototype,"localeMonth",void 0),t=d([(0,o.w)("md-datepicker-calendar")],t),e.ELEMENT=t}(s||(s={}))},63704:(e,t,i)=>{i.d(t,{Badge:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(97822),h=i(92019),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.ariaLabel="",this.color="",this.bgColor="",this.textColor="",this.height="",this.width="",this.outlined=!1,this.compact=!1,this.circle=!1,this.small=!1,this.split=!1,this.disabled=!1,this.tabIndexing="",this.ariaHiddenSplits="",this.renderBgColor=()=>this.bgColor?`background-color: ${this.bgColor};`:a.nothing,this.renderTextColor=()=>this.textColor?`color: ${this.textColor};`:a.nothing,this.renderHeight=()=>this.height?`height: ${this.height};`:a.nothing,this.renderWidth=()=>this.width?`width: ${this.width};`:a.nothing,this.getStyles=()=>this.bgColor||this.textColor||this.height||this.width?n.html`
|
|
1600
1601
|
<style>
|
|
1601
1602
|
:host .md-badge {
|
|
1602
1603
|
${this.renderBgColor()};
|
|
@@ -1628,7 +1629,7 @@
|
|
|
1628
1629
|
`)():a.nothing}
|
|
1629
1630
|
<slot></slot>
|
|
1630
1631
|
</span>
|
|
1631
|
-
`}};
|
|
1632
|
+
`}};p([(0,n.property)({type:String})],t.prototype,"ariaLabel",void 0),p([(0,n.property)({type:String})],t.prototype,"color",void 0),p([(0,n.property)({type:String})],t.prototype,"bgColor",void 0),p([(0,n.property)({type:String})],t.prototype,"textColor",void 0),p([(0,n.property)({type:String})],t.prototype,"height",void 0),p([(0,n.property)({type:String})],t.prototype,"width",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"outlined",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"compact",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"circle",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"small",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"split",void 0),p([(0,n.property)({type:Boolean})],t.prototype,"disabled",void 0),p([(0,n.property)({type:String})],t.prototype,"tabIndexing",void 0),p([(0,n.property)({type:String})],t.prototype,"ariaHiddenSplits",void 0),t=p([(0,o.w)("md-badge")],t),e.ELEMENT=t}(s||(s={}))},64311:(e,t,i)=>{i.d(t,{CardAi:()=>o}),i(96798),i(61200);var s,o,r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(17518),h=i(18227),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){e.USER_QUERY="user_query",e.RESPONSE="response"}(s||(s={})),function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.id="",this.title="",this.cardText="",this.timestamp="",this.summariseMoreVisible=!1,this.variant=s.RESPONSE,this.copyChecked=!1,this.thumbsUpChecked=!1,this.thumbsDownChecked=!1}static get styles(){return[n.A,h.A]}thumbsUpToggled(){this.thumbsDownChecked=!1,this.thumbsUpChecked=!this.thumbsUpChecked,this.dispatchEvent(new CustomEvent("thumbs-up-toggled",{detail:{id:this.id},bubbles:!0,composed:!0}))}thumbsDownToggled(){this.thumbsUpChecked=!1,this.thumbsDownChecked=!this.thumbsDownChecked,this.dispatchEvent(new CustomEvent("thumbs-down-toggled",{detail:{id:this.id},bubbles:!0,composed:!0}))}summariseMoreToggled(){this.dispatchEvent(new CustomEvent("summarise-more-toggled",{detail:{id:this.id},bubbles:!0,composed:!0}))}copyToggled(){navigator.clipboard.writeText(this.cardText),this.copyChecked=!0,setTimeout((()=>{this.copyChecked=!1}),2e3)}get bottomBorderRadiusClass(){return this.timestamp?"with-bottom-border-radius":"no-bottom-border-radius"}get cardTextClassMap(){return{"md-card-ai-card-body-user-query":this.variant===s.USER_QUERY,[`md-card-ai-card-body-response-${this.bottomBorderRadiusClass}`]:this.variant===s.RESPONSE}}renderHeader(){return this.variant===s.RESPONSE&&""!==this.title?a.html`
|
|
1632
1633
|
<div class="md-card-ai-header">
|
|
1633
1634
|
<slot name="card-header-aside">
|
|
1634
1635
|
<md-icon name="cisco-ai-assistant-color" iconSet="momentumBrandVisuals"></md-icon>
|
|
@@ -1704,15 +1705,15 @@
|
|
|
1704
1705
|
${this.renderHeader()}
|
|
1705
1706
|
<div class="content-margin">${this.renderCardText()} ${this.renderFooter()}</div>
|
|
1706
1707
|
</div>
|
|
1707
|
-
`}};
|
|
1708
|
+
`}};p([(0,a.property)({type:String})],t.prototype,"id",void 0),p([(0,a.property)({type:String})],t.prototype,"title",void 0),p([(0,a.property)({type:String})],t.prototype,"cardText",void 0),p([(0,a.property)({type:String})],t.prototype,"timestamp",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"summariseMoreVisible",void 0),p([(0,a.property)({type:String})],t.prototype,"variant",void 0),p([(0,a.internalProperty)()],t.prototype,"copyChecked",void 0),p([(0,a.internalProperty)()],t.prototype,"thumbsUpChecked",void 0),p([(0,a.internalProperty)()],t.prototype,"thumbsDownChecked",void 0),t=p([(0,r.w)("md-card-ai")],t),e.ELEMENT=t}(o||(o={}))},65796:e=>{e.exports=f},65875:e=>{e.exports=I},66245:(e,t,i)=>{i.d(t,{ListItem:()=>s});var s,o=i(3001),r=i(31890),n=i(26272),a=i(41488),l=i(23968),d=i(21392),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.yC)(a.LitElement)){constructor(){super(...arguments),this.role="option",this.tabIndex=-1,this.shape="rounded",this._disabled=!1,this._selected=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.setAttribute("aria-disabled",`${e}`),this.requestUpdate("disabled",t)}get selected(){return this._selected}set selected(e){const t=this._selected;this._selected=e,this.requestUpdate("selected",t)}get listItemTemplateClassMap(){return{[`md-list-item--${this.shape}`]:!!this.shape}}static get styles(){return[n.A,d.A]}render(){return a.html`
|
|
1708
1709
|
<li class="md-list-item ${(0,l.classMap)(this.listItemTemplateClassMap)}" part="list-item">
|
|
1709
1710
|
<slot></slot>
|
|
1710
1711
|
</li>
|
|
1711
|
-
`}};h([(0,a.property)({type:String,reflect:!0})],t.prototype,"role",void 0),h([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,a.property)({type:String,reflect:!0})],t.prototype,"shape",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"selected",null),t=h([(0,r.w)("md-list-item")],t),e.ELEMENT=t}(s||(s={}))},66677:(e,t,i)=>{i.d(t,{QZ:()=>r,Qx:()=>n,sg:()=>o,ws:()=>s});const s=(e,t)=>{const i=[];[t].forEach((t=>{i.push(...((e,t)=>{const i=t.length;if(0===i)return[];const s=[],o=e.toLowerCase(),r=t.toLowerCase();let n=0,a=o.indexOf(r,n);for(;a>-1;)n=a+i,s.push([a,n]),a=o.indexOf(r,a+1);return s})(e,t))}));const s=(([...e])=>{if(!e.length)return[];e.sort(((e,t)=>e[0]!==t[0]?e[0]-t[0]:e[1]-t[1]));const t=[];let i=e[0][0],s=e[0][1];return e.shift(),e.forEach((([e,o])=>{e>=s?(t.push([i,s]),i=e,s=o):o>s&&(s=o)})),t.push([i,s]),t})(i),o=[];let r=0;return s.forEach((([t,i])=>{r!==t&&o.push({range:[t,i],matching:!1,text:e.slice(r,t)}),o.push({range:[t,i],matching:!0,text:e.slice(t,i)}),r=i})),r!==e.length&&o.push({range:[r],matching:!1,text:e.slice(r)}),o};function o(e,t,i){let s;return function(...o){const r=this,n=i&&!s;clearTimeout(s),s=setTimeout((function(){s=null,i||e.apply(r,o)}),t),n&&e.apply(r,o)}}function r(e,t){return function t(i){if(!i||i===document||i===window)return null;const s=i.closest(e);return null!=s?s:t(i.getRootNode().host)}(t)}function n(e,t){return t>=0&&t<e.length?e[t]:void 0}},68250:e=>{e.exports=
|
|
1712
|
+
`}};h([(0,a.property)({type:String,reflect:!0})],t.prototype,"role",void 0),h([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,a.property)({type:String,reflect:!0})],t.prototype,"shape",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"selected",null),t=h([(0,r.w)("md-list-item")],t),e.ELEMENT=t}(s||(s={}))},66677:(e,t,i)=>{i.d(t,{QZ:()=>r,Qx:()=>n,sg:()=>o,ws:()=>s});const s=(e,t)=>{const i=[];[t].forEach((t=>{i.push(...((e,t)=>{const i=t.length;if(0===i)return[];const s=[],o=e.toLowerCase(),r=t.toLowerCase();let n=0,a=o.indexOf(r,n);for(;a>-1;)n=a+i,s.push([a,n]),a=o.indexOf(r,a+1);return s})(e,t))}));const s=(([...e])=>{if(!e.length)return[];e.sort(((e,t)=>e[0]!==t[0]?e[0]-t[0]:e[1]-t[1]));const t=[];let i=e[0][0],s=e[0][1];return e.shift(),e.forEach((([e,o])=>{e>=s?(t.push([i,s]),i=e,s=o):o>s&&(s=o)})),t.push([i,s]),t})(i),o=[];let r=0;return s.forEach((([t,i])=>{r!==t&&o.push({range:[t,i],matching:!1,text:e.slice(r,t)}),o.push({range:[t,i],matching:!0,text:e.slice(t,i)}),r=i})),r!==e.length&&o.push({range:[r],matching:!1,text:e.slice(r)}),o};function o(e,t,i){let s;return function(...o){const r=this,n=i&&!s;clearTimeout(s),s=setTimeout((function(){s=null,i||e.apply(r,o)}),t),n&&e.apply(r,o)}}function r(e,t){return function t(i){if(!i||i===document||i===window)return null;const s=i.closest(e);return null!=s?s:t(i.getRootNode().host)}(t)}function n(e,t){return t>=0&&t<e.length?e[t]:void 0}},68250:e=>{e.exports=m},68490:(e,t,i)=>{i.d(t,{List:()=>s});var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(97822),h=i(21392),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.Io)(l.LitElement)){constructor(){super(...arguments),this.alignment="vertical",this.label="option",this.activated=-1,this._role="listbox"}firstUpdated(e){super.firstUpdated(e),this.setAttribute("aria-label",this.label)}notifySelectedChange(){this.dispatchEvent(new CustomEvent("list-item-change",{detail:{selected:this.selected},bubbles:!0,composed:!0}))}isFocusable(e){return!e.hasAttribute("hidden")}connectedCallback(){super.connectedCallback(),this._role=this.getAttribute("role")||"listbox",this.removeAttribute("role"),this.addEventListener("keydown",this.handleKeyDown),this.addEventListener("click",this.handleClick)}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleKeyDown),this.removeEventListener("click",this.handleClick)}findListItemIndex(e){const t=e.composedPath();return this.slotted.findIndex((e=>t.includes(e)))}switchListItemOnArrowPress(e,t=1){const i=super.getAvailableSelectedIndex(e,t);-1!==i&&(this.selected=i)}setActivated(e){-1!==e&&(this.activated=e,this.selected=e,this.setSelected(e))}findSelectedListItemIndex(){return this.slotted.findIndex((e=>e.selected))}setSelected(e){const t=this.findSelectedListItemIndex();-1!==t&&t!==e&&(this.slotted[t].selected=!1),this.slotted[e]&&(this.slotted[e].selected=!0)}updated(e){super.updated(e),e.has("slotted")&&this.setActivated(this.activated),e.has("activated")&&this.setActivated(this.activated),e.has("label")&&this.setAttribute("aria-label",this.label)}isListItemDisabled(e){var t;const i=this.slotted[e];return null===(t=null==i?void 0:i.disabled)||void 0===t||t}handleClick(e){const t=this.findListItemIndex(e);-1!==t&&(this.isListItemDisabled(t)||(this.setActivated(t),this.notifySelectedChange()))}handleKeyDown(e){const{code:t}=e;switch(t){case o.Uz.End:this.switchListItemOnArrowPress(this.slotted.length-1);break;case o.Uz.Home:this.switchListItemOnArrowPress(0);break;case o.Uz.ArrowUp:case o.Uz.ArrowLeft:e.preventDefault(),0===this.selected?this.switchListItemOnArrowPress(this.slotted.length-1,-1):this.switchListItemOnArrowPress(this.selected-1,-1);break;case o.Uz.ArrowDown:case o.Uz.ArrowRight:e.preventDefault(),this.selected===this.slotted.length-1?this.switchListItemOnArrowPress(0):this.switchListItemOnArrowPress(this.selected+1);break;case o.Uz.Enter:case o.Uz.Space:this.isListItemDisabled(this.selected)||(this.setActivated(this.selected),this.notifySelectedChange())}}get slotElement(){return this.listItemSlot}static get styles(){return[a.A,h.A]}render(){return l.html`
|
|
1712
1713
|
<ul role=${(0,d.ifDefined)("list"!==this._role?this._role:void 0)} class="md-list" part="list">
|
|
1713
1714
|
<slot name="list-item"></slot>
|
|
1714
1715
|
</ul>
|
|
1715
|
-
`}};
|
|
1716
|
+
`}};p([(0,l.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),p([(0,l.property)({type:String})],t.prototype,"label",void 0),p([(0,l.property)({type:Number,reflect:!0})],t.prototype,"activated",void 0),p([(0,l.query)("slot[name='list-item']")],t.prototype,"listItemSlot",void 0),t=p([(0,n.w)("md-list")],t),e.ELEMENT=t}(s||(s={}))},69e3:e=>{e.exports=$},69112:(e,t,i)=>{i.d(t,{Grabber:()=>s}),i(61200);var s,o=i(37719),r=i(3001),n=i(31890),a=i(26283),l=i(26272),d=i(41488),h=i(23968),p=i(97822),c=i(42215),u=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.yC)(d.LitElement)){constructor(){super(...arguments),this.label="Expand",this.checkedLabel="Collapse",this.hovered=!1,this.disabled=!1,this.checked=!1,this.visible=!0,this.focused=!1,this.disableClickToggle=!1,this.alignment="leading",this.dragger=!1,this.shadow=!1}connectedCallback(){super.connectedCallback()}disconnectedCallback(){super.disconnectedCallback()}static get styles(){return[l.A,c.A]}toggleGrabber(){this.disabled||(this.checked=!this.checked,this.dispatchEvent(new CustomEvent("grabber-toggled",{detail:{checked:this.checked},bubbles:!0,composed:!0})))}handleMouseDown(){this.disableClickToggle||this.toggleGrabber()}handleKeyDown(e){this.disableClickToggle||(0,a.o)(e.code)&&(e.preventDefault(),this.toggleGrabber())}handleMouseEnter(){this.hovered=!0,this.dispatchHoverEvent()}handleMouseLeave(){this.hovered=!1,this.dispatchHoverEvent()}handleFocus(){this.focused=!0}handleBlur(){this.focused=!1}dispatchHoverEvent(){this.dispatchEvent(new CustomEvent("grabber-hover-changed",{bubbles:!0,composed:!0,detail:{hovered:this.hovered}}))}get collapsed(){return!this.checked}get grabberClassMap(){return{"md-grabber--active":this.checked,"md-grabber--disabled":this.disabled,"md-grabber--dragger":this.dragger,[`md-grabber--${this.alignment}`]:this.alignment,visible:this.visible||this.focused}}get grabberContainerClassMap(){return{[`${this.alignment}`]:!0,shadow:this.shadow&&(this.visible||this.checked)}}get iconName(){return this.dragger?"list-menu-bold":"leading"===this.alignment||"trailing"===this.alignment?this.checked?"arrow-left-bold":"arrow-right-bold":this.checked?"arrow-up-bold":"arrow-down-bold"}get iconSize(){return this.dragger||!1===o.themeManager.isMomentumV2Enabled?"10":"12"}render(){return d.html`
|
|
1716
1717
|
<div class="md-grabber__container ${(0,h.classMap)(this.grabberContainerClassMap)}">
|
|
1717
1718
|
<button
|
|
1718
1719
|
class="md-grabber ${(0,h.classMap)(this.grabberClassMap)}"
|
|
@@ -1720,7 +1721,7 @@
|
|
|
1720
1721
|
aria-pressed=${this.checked}
|
|
1721
1722
|
?disabled=${this.disabled}
|
|
1722
1723
|
tabindex="0"
|
|
1723
|
-
aria-label=${(0,
|
|
1724
|
+
aria-label=${(0,p.ifDefined)(this.label.length?this.label:void 0)}
|
|
1724
1725
|
type="button"
|
|
1725
1726
|
role="button"
|
|
1726
1727
|
@click="${()=>this.handleMouseDown()}"
|
|
@@ -1733,13 +1734,13 @@
|
|
|
1733
1734
|
<md-icon name="${this.iconName}" size="${this.iconSize}" iconSet="momentumDesign"></md-icon>
|
|
1734
1735
|
</button>
|
|
1735
1736
|
</div>
|
|
1736
|
-
`}};u([(0,d.property)({type:String})],t.prototype,"label",void 0),u([(0,d.property)({type:String})],t.prototype,"checkedLabel",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"hovered",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"disabled",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"checked",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"visible",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"focused",void 0),u([(0,d.property)({type:Boolean,attribute:"disable-click-toggle"})],t.prototype,"disableClickToggle",void 0),u([(0,d.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"dragger",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"shadow",void 0),t=u([(0,n.w)("md-grabber")],t),e.ELEMENT=t}(s||(s={}))},69371:e=>{e.exports=
|
|
1737
|
+
`}};u([(0,d.property)({type:String})],t.prototype,"label",void 0),u([(0,d.property)({type:String})],t.prototype,"checkedLabel",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"hovered",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"disabled",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"checked",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"visible",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"focused",void 0),u([(0,d.property)({type:Boolean,attribute:"disable-click-toggle"})],t.prototype,"disableClickToggle",void 0),u([(0,d.property)({type:String,reflect:!0})],t.prototype,"alignment",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"dragger",void 0),u([(0,d.property)({type:Boolean})],t.prototype,"shadow",void 0),t=u([(0,n.w)("md-grabber")],t),e.ELEMENT=t}(s||(s={}))},69371:e=>{e.exports=y},69494:(e,t,i)=>{i.d(t,{DateRangePicker:()=>s});var s,o=i(31890),r=i(81625),n=i(41488),a=i(65796),l=i(38654),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends l.DatePicker.ELEMENT{constructor(){super(...arguments),this.startDate=void 0,this.endDate=void 0,this.updateValue=()=>{this.startDate&&this.endDate&&(this.value=`${(0,r.az)(this.startDate)} - ${(0,r.az)(this.endDate)}`)},this.handleDateSelection=e=>{var t;const i=e.detail.data;i&&(this.startDate?this.endDate?(this.startDate=this.dateToSqlTranslate(i),this.endDate=void 0):i<a.DateTime.fromISO(this.startDate)?(this.endDate=this.startDate,this.startDate=this.dateToSqlTranslate(i)):this.endDate=this.dateToSqlTranslate(i):this.startDate=this.dateToSqlTranslate(i),(null===(t=this.controlButtons)||void 0===t?void 0:t.apply)||(this.emitDateRange(),this.updateValue()))}}connectedCallback(){super.connectedCallback(),super.render(),this.addEventListener("date-pre-selection-change",this.handleDateSelection),this.updateValue()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("date-pre-selection-change",this.handleDateSelection)}setSelected(){}dateToSqlTranslate(e){return e.toSQLDate()}onApplyClick(){this.emitDateRange(),this.updateValue(),this.shouldCloseOnSelect&&this.setOpen(!1)}emitDateRange(){if(!this.startDate||!this.endDate)return;const e=new CustomEvent("date-range-change",{detail:{startDate:this.startDate,endDate:this.endDate}});this.dispatchEvent(e)}};d([(0,n.property)({type:String,attribute:"start-date",reflect:!0})],t.prototype,"startDate",void 0),d([(0,n.property)({type:String,attribute:"end-date",reflect:!0})],t.prototype,"endDate",void 0),t=d([(0,o.w)("md-date-range-picker")],t),e.ELEMENT=t}(s||(s={}))},69788:(e,t,i)=>{i.d(t,{Loading:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(17518),l=i(76700),d=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.size="",this.isAnimating=!1,this.animationFrameId=null}static get styles(){return[r.A,l.A]}firstUpdated(e){super.firstUpdated(e),this.isAnimating=!0,this.startAnimation()}disconnectedCallback(){super.disconnectedCallback(),this.isAnimating=!1,this.stopAnimation()}startAnimation(){var e;const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll(".md-loading__icon");if(!t)return;let i=null;const s=1400,o=e=>{if(!this.isAnimating)return;i||(i=e);const r=(e-i)%s;t.forEach(((e,t)=>{const i=(r-200*t+s)%s;let o=0,n=.1;if(i<280){const e=.1+i/280*.9;o=e,n=e}else if(i<1400){const e=Math.min((i-280)/1120*2,1);o=Math.max(1-.9*e,.9),n=Math.max(1-.9*e,.2)}e.style.transform=`scale(${o})`,e.style.opacity=`${n}`})),this.animationFrameId=requestAnimationFrame(o)};this.animationFrameId=requestAnimationFrame(o)}stopAnimation(){var e;null!==this.animationFrameId&&(cancelAnimationFrame(this.animationFrameId),this.animationFrameId=null);const t=null===(e=this.shadowRoot)||void 0===e?void 0:e.querySelectorAll(".md-loading__icon");t&&t.forEach((e=>{e.style.transform="scale(0, 0)",e.style.opacity="0.1"}))}get loadingClassMap(){return{[`md-loading--${this.size}`]:!!this.size}}get loadingIconClassMap(){return{"md-loading__icon":!0}}render(){return n.html`
|
|
1737
1738
|
<div class="md-loading ${(0,a.classMap)(this.loadingClassMap)}">
|
|
1738
1739
|
<span class=${(0,a.classMap)(this.loadingIconClassMap)}></span>
|
|
1739
1740
|
<span class=${(0,a.classMap)(this.loadingIconClassMap)}></span>
|
|
1740
1741
|
<span class=${(0,a.classMap)(this.loadingIconClassMap)}></span>
|
|
1741
1742
|
</div>
|
|
1742
|
-
`}};d([(0,n.property)({type:String})],t.prototype,"size",void 0),d([(0,n.internalProperty)()],t.prototype,"isAnimating",void 0),t=d([(0,o.w)("md-loading")],t),e.ELEMENT=t}(s||(s={}))},
|
|
1743
|
+
`}};d([(0,n.property)({type:String})],t.prototype,"size",void 0),d([(0,n.internalProperty)()],t.prototype,"isAnimating",void 0),t=d([(0,o.w)("md-loading")],t),e.ELEMENT=t}(s||(s={}))},71128:(e,t,i)=>{i.d(t,{Popover:()=>s}),i(96798),i(61200);var s,o=i(90195),r=i(31890),n=i(28373),a=i(66677),l=i(26283),d=i(22962),h=i.n(d),p=i(84157),c=i.n(p),u=i(68250),m=i.n(u),y=i(69371),b=i.n(y),v=i(4863),g=i(41488),f=i(40333),w=i(73679),C=i(35211),x=i(50325),S=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},$=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){let t=class extends((0,n.d)(g.LitElement)){constructor(){super(...arguments),this.placement="bottom",this.isOpen=!1,this.showArrow=!0,this.showClose=!1,this.interactive=!1,this.shouldWrapFocus=()=>this.interactive,this.role="dialog",this.ariaLabel=null,this.offsetDistance=5,this.trigger="click",this.triggerElement=null,this.popperInstance=null,this.isMouseOver=!1,this.onOutsideOverlayClick=e=>{var t;if(null===(t=this.trigger)||void 0===t?void 0:t.includes("manual"))return;let i=!1;const s=e.composedPath();s.length&&(i=!!s.find((e=>e===this)),i||(this.isOpen=!1))},this.onWindowBlurEvent=()=>{var e;(null===(e=this.trigger)||void 0===e?void 0:e.includes("manual"))||this.isOpen&&(this.isOpen=!1)},this.onOutsideOverlayKeydown=e=>$(this,void 0,void 0,(function*(){this.isOpen&&e.code===o.Uz.Escape&&(e.preventDefault(),this.isOpen=!1,yield this.updateComplete,this.focusOnTrigger())})),this.onTriggerElementClicked=()=>{this.toggleOverlay()},this.onTriggerElementKeydown=e=>$(this,void 0,void 0,(function*(){(0,l.o)(e.code)&&(e.preventDefault(),this.toggleOverlay()),e.code===o.Uz.Escape&&this.isOpen&&(this.isOpen=!1,yield this.updateComplete,this.focusOnTrigger())})),this.onFocusInTrigger=()=>{var e;(null===(e=this.trigger)||void 0===e?void 0:e.includes("focus"))&&(this.isOpen=!0)},this.onFocusOutTrigger=()=>{var e;(null===(e=this.trigger)||void 0===e?void 0:e.includes("focus"))&&!this.isMouseOver&&(this.isOpen=!1)},this.onMouseEnteredTriggerOrPopup=e=>{var t;this.isMouseOver=!0,(null===(t=this.trigger)||void 0===t?void 0:t.includes("mouseenter"))&&this.setIsOpenDebounced(!0)},this.onMouseLeaveTriggerOrPopup=e=>{var t;this.isMouseOver=!1,(null===(t=this.trigger)||void 0===t?void 0:t.includes("mouseenter"))&&!this.shouldStayOpenOnTriggerFocus()&&this.setIsOpenDebounced(!1)},this.setIsOpenDebounced=(0,a.sg)((e=>{this.isOpen=e}),100)}static get styles(){return[x.A]}connectedCallback(){super.connectedCallback()}disconnectedCallback(){var e,t,i,s,o;super.disconnectedCallback(),window.removeEventListener("blur",this.onWindowBlurEvent),document.removeEventListener("click",this.onOutsideOverlayClick),document.removeEventListener("keydown",this.onOutsideOverlayKeydown),this.triggerElement&&((null===(e=this.trigger)||void 0===e?void 0:e.includes("click"))&&(this.triggerElement.removeEventListener("click",this.onTriggerElementClicked),this.triggerElement.removeEventListener("keydown",this.onTriggerElementKeydown)),(null===(t=this.trigger)||void 0===t?void 0:t.includes("mouseenter"))&&(this.triggerElement.removeEventListener("mouseenter",this.onMouseEnteredTriggerOrPopup),this.triggerElement.removeEventListener("mouseleave",this.onMouseLeaveTriggerOrPopup),null===(i=this.popoverContainer)||void 0===i||i.removeEventListener("mouseenter",this.onMouseEnteredTriggerOrPopup),null===(s=this.popoverContainer)||void 0===s||s.removeEventListener("mouseleave",this.onMouseLeaveTriggerOrPopup)),(null===(o=this.trigger)||void 0===o?void 0:o.includes("focus"))&&(this.triggerElement.removeEventListener("focusin",this.onFocusInTrigger),this.triggerElement.removeEventListener("focusout",this.onFocusOutTrigger)))}setupTriggerEvents(){var e,t,i,s,o;this.triggerElement&&((null===(e=this.trigger)||void 0===e?void 0:e.includes("click"))&&(this.triggerElement.addEventListener("click",this.onTriggerElementClicked.bind(this)),this.triggerElement.addEventListener("keydown",this.onTriggerElementKeydown.bind(this))),(null===(t=this.trigger)||void 0===t?void 0:t.includes("mouseenter"))&&(this.triggerElement.addEventListener("mouseenter",this.onMouseEnteredTriggerOrPopup),this.triggerElement.addEventListener("mouseleave",this.onMouseLeaveTriggerOrPopup),null===(i=this.popoverContainer)||void 0===i||i.addEventListener("mouseenter",this.onMouseEnteredTriggerOrPopup),null===(s=this.popoverContainer)||void 0===s||s.addEventListener("mouseleave",this.onMouseLeaveTriggerOrPopup)),(null===(o=this.trigger)||void 0===o?void 0:o.includes("focus"))&&(this.triggerElement.addEventListener("focusin",this.onFocusInTrigger),this.triggerElement.addEventListener("focusout",this.onFocusOutTrigger)))}handleTriggerElementSlotChange(){const e=this.triggerSlot.assignedElements({flatten:!0});this.triggerElement=e.length>0?e[0]:null}onContentSlotChanged(){}shouldStayOpenOnTriggerFocus(){var e;return!!(null===(e=this.trigger)||void 0===e?void 0:e.includes("focus"))&&this.getRootNode().activeElement===this.triggerElement}firstUpdated(e){var t;super.firstUpdated(e),this.handleTriggerElementSlotChange(),this.setupTriggerEvents(),this.popoverContainer&&this.isOpen&&(this.createInstance(),null===(t=this.popoverContainer)||void 0===t||t.setAttribute("data-show",""))}focusInsideOverlay(){var e,t;this.focusableElements&&(this.focusableElements.length>1?null===(e=this.setInitialFocus)||void 0===e||e.call(this,1):this.focusableElements.length&&(null===(t=this.setInitialFocus)||void 0===t||t.call(this)))}focusOnTrigger(){return $(this,void 0,void 0,(function*(){requestAnimationFrame((()=>{var e;(null===(e=this.focusableElements)||void 0===e?void 0:e.length)&&this.focusableElements[0].focus()}))}))}toggleOverlay(){var e;(null===(e=this.triggerElement)||void 0===e?void 0:e.hasAttribute("disabled"))||(this.isOpen=!this.isOpen)}handleCreatePopperFirstUpdate(){return $(this,void 0,void 0,(function*(){var e;this.isOpen&&this.interactive&&(null===(e=this.setFocusableElements)||void 0===e||e.call(this),yield this.updateComplete,this.focusInsideOverlay())}))}createInstance(){this.triggerElement?this.popperInstance=(0,v.createPopper)(this.triggerElement,this.popoverContainer,{onFirstUpdate:()=>{this.isOpen&&this.handleCreatePopperFirstUpdate()},placement:this.placement,modifiers:[...v.defaultModifiers,c(),m(),b(),h(),{name:"preventOverflow",options:{padding:16}},{name:"offset",options:{offset:({placement:e,reference:t})=>"left"===e||"right"===e?[t.height+t.y+this.offsetDistance,C.KC]:[0,this.showArrow?C.KC+this.offsetDistance:this.offsetDistance]}},{name:"arrow",options:{element:this.popoverArrow,padding:C.KC}},{name:"computeStyles",options:{adaptive:!0}}]}):console.warn("No trigger element not creating popper instance")}destroyInstance(){this.popperInstance&&(this.popperInstance.destroy(),this.popperInstance=null)}updated(e){if(super.updated(e),e.has("isOpen")){const t=e.get("isOpen");this.isOpenUpdated(t,this.isOpen)}}isOpenUpdated(e,t){var i,s,o,r,n,a;e!==t&&(t?(this.createInstance(),this.dispatchPopoverIsOpenChanged(t),window.addEventListener("blur",this.onWindowBlurEvent),document.addEventListener("click",this.onOutsideOverlayClick),document.addEventListener("keydown",this.onOutsideOverlayKeydown),this.interactive&&(null===(i=this.activateFocusTrap)||void 0===i||i.call(this)),null===(s=this.triggerElement)||void 0===s||s.setAttribute("aria-expanded","true"),null===(o=this.popoverContainer)||void 0===o||o.setAttribute("data-show","")):(this.destroyInstance(),window.removeEventListener("blur",this.onWindowBlurEvent),document.removeEventListener("click",this.onOutsideOverlayClick),document.removeEventListener("keydown",this.onOutsideOverlayKeydown),this.dispatchPopoverIsOpenChanged(t),null===(r=this.deactivateFocusTrap)||void 0===r||r.call(this),null===(n=this.triggerElement)||void 0===n||n.removeAttribute("aria-expanded"),null===(a=this.popoverContainer)||void 0===a||a.removeAttribute("data-show")))}dispatchPopoverIsOpenChanged(e){this.dispatchEvent(new CustomEvent("popover-open-changed",{detail:{isOpen:e},composed:!0,bubbles:!0}))}render(){var e;return g.html`
|
|
1743
1744
|
<div class="md-popover">
|
|
1744
1745
|
<slot name="triggerElement" aria-expanded=${this.isOpen}></slot>
|
|
1745
1746
|
<div
|
|
@@ -1764,15 +1765,15 @@
|
|
|
1764
1765
|
</div>
|
|
1765
1766
|
</div>
|
|
1766
1767
|
</div>
|
|
1767
|
-
`}};S([(0,g.property)({type:String})],t.prototype,"placement",void 0),S([(0,g.property)({type:Boolean,attribute:"is-open"})],t.prototype,"isOpen",void 0),S([(0,g.property)({type:Boolean,attribute:"show-arrow"})],t.prototype,"showArrow",void 0),S([(0,g.property)({type:Boolean,attribute:"show-close"})],t.prototype,"showClose",void 0),S([(0,g.property)({type:Boolean})],t.prototype,"interactive",void 0),S([(0,g.property)({type:String,attribute:"role"})],t.prototype,"role",void 0),S([(0,g.property)({type:String,attribute:"aria-label"})],t.prototype,"ariaLabel",void 0),S([(0,g.property)({type:Number,attribute:"offset-distance"})],t.prototype,"offsetDistance",void 0),S([(0,g.query)('slot[name="triggerElement"]')],t.prototype,"triggerSlot",void 0),S([(0,g.query)(".popover-container")],t.prototype,"popoverContainer",void 0),S([(0,g.query)(".popover-arrow")],t.prototype,"popoverArrow",void 0),S([(0,g.property)({type:String})],t.prototype,"trigger",void 0),S([(0,g.internalProperty)()],t.prototype,"isMouseOver",void 0),t=S([(0,r.w)("md-popover")],t),e.ELEMENT=t}(s||(s={}))},73093:(e,t,i)=>{i.d(t,{FloatingModal:()=>s}),i(96798),i(61200);var s,o=i(3001),r=i(31890),n=i(26272),a=(i(58088),i(57346),i(69e3),i(20727)),l=i.n(a),d=(i(3288),i(41488)),h=i(40333),
|
|
1768
|
+
`}};S([(0,g.property)({type:String})],t.prototype,"placement",void 0),S([(0,g.property)({type:Boolean,attribute:"is-open"})],t.prototype,"isOpen",void 0),S([(0,g.property)({type:Boolean,attribute:"show-arrow"})],t.prototype,"showArrow",void 0),S([(0,g.property)({type:Boolean,attribute:"show-close"})],t.prototype,"showClose",void 0),S([(0,g.property)({type:Boolean})],t.prototype,"interactive",void 0),S([(0,g.property)({type:String,attribute:"role"})],t.prototype,"role",void 0),S([(0,g.property)({type:String,attribute:"aria-label"})],t.prototype,"ariaLabel",void 0),S([(0,g.property)({type:Number,attribute:"offset-distance"})],t.prototype,"offsetDistance",void 0),S([(0,g.query)('slot[name="triggerElement"]')],t.prototype,"triggerSlot",void 0),S([(0,g.query)(".popover-container")],t.prototype,"popoverContainer",void 0),S([(0,g.query)(".popover-arrow")],t.prototype,"popoverArrow",void 0),S([(0,g.property)({type:String})],t.prototype,"trigger",void 0),S([(0,g.internalProperty)()],t.prototype,"isMouseOver",void 0),t=S([(0,r.w)("md-popover")],t),e.ELEMENT=t}(s||(s={}))},73093:(e,t,i)=>{i.d(t,{FloatingModal:()=>s}),i(96798),i(61200);var s,o=i(3001),r=i(31890),n=i(26272),a=(i(58088),i(57346),i(69e3),i(20727)),l=i.n(a),d=(i(3288),i(41488)),h=i(40333),p=i(97822),c=(i(58871),i(67330)),u=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.yC)((0,o.TS)(d.LitElement))){constructor(){super(...arguments),this.heading="",this.label="",this.show=!1,this.aspectRatio=!1,this.fixed=!1,this.full=!1,this.closeAriaLabel="Close Modal",this.resizeAriaLabel="Resize Modal",this.maximizeScreenLabel="Maximize Modal",this.minimizeAriaLabel="Minimize Modal",this.minimize=!1,this.minimizable=!1,this.containerRect=null,this.dragOccured=!1,this.containerTransform="",this.applyInitialPosition=!0,this.resizeMoveListener=e=>{const{target:t}=e;let i=parseFloat(t.getAttribute("data-x"))||0,s=parseFloat(t.getAttribute("data-y"))||0;t.style.setProperty("width",`${e.rect.width}px`,"important"),t.style.setProperty("height",`${e.rect.height}px`,"important");const{initialX:o,initialY:r}=this.getInitialPosition();i+=e.deltaRect.left+o,s+=e.deltaRect.top+r,this.setTargetPosition(t,i,s),this.applyInitialPosition=!1},this.resizeEndListener=()=>{this.setContainerRect()},this.getInitialPosition=()=>{var e,t;return this.applyInitialPosition&&this.position?{initialX:Number(null===(e=this.position)||void 0===e?void 0:e.x),initialY:Number(null===(t=this.position)||void 0===t?void 0:t.y)}:{initialX:0,initialY:0}},this.dragMoveListener=e=>{const{target:t}=e,{x:i,y:s}=this.getTransformValues(e);this.setTargetPosition(t,i,s),this.applyInitialPosition=!1},this.dragEndListener=()=>{this.dragOccured=!0,this.setContainerRect()}}static get styles(){return[n.A,c.A]}updated(e){super.updated(e),e.has("show")&&(this.container&&this.show?(this.applyInitialPosition=!0,this.setContainerRect(),this.setInteractInstance()):(this.cleanContainerStyles(),this.destroyInteractInstance())),this.container&&e.has("position")&&!e.has("show")&&this.setInitialTargetPosition()}isNewPositionNotSame(){var e,t,i,s;if(this.container)return Number(null===(e=this.container)||void 0===e?void 0:e.getAttribute("data-x"))!==(null===(t=this.position)||void 0===t?void 0:t.x)||Number(null===(i=this.container)||void 0===i?void 0:i.getAttribute("data-y"))!==(null===(s=this.position)||void 0===s?void 0:s.y)}setInitialTargetPosition(){var e,t;this.container&&this.isNewPositionNotSame()&&this.setTargetPosition(this.container,Number(null===(e=this.position)||void 0===e?void 0:e.x),Number(null===(t=this.position)||void 0===t?void 0:t.y))}cleanContainerStyles(){this.containerTransform=""}getContainerTransform(){const e=this.container.getAttribute("data-x"),t=this.container.getAttribute("data-y");return e&&t?(this.dispatchEvent(new CustomEvent("floating-modal-location",{composed:!0,bubbles:!0,detail:{transform:{x:e,y:t}}})),`translate(${e}px, ${t}px)`):this.container.style.transform}setContainerRect(){requestAnimationFrame((()=>{return e=this,t=void 0,s=function*(){yield this.updateComplete,this.containerRect=this.container.getBoundingClientRect(),this.dispatchEvent(new CustomEvent("floating-modal-resize",{composed:!0,bubbles:!0,detail:{size:this.containerRect}})),this.containerTransform=this.getContainerTransform()},new((i=void 0)||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}));var e,t,i,s}))}setInteractInstance(){requestAnimationFrame((()=>{this.container&&l()(this.container).resizable({edges:{left:!0,right:!0,bottom:!0,top:!0},listeners:{end:this.resizeEndListener,move:this.resizeMoveListener},modifiers:this.aspectRatio?[l().modifiers.aspectRatio({ratio:"preserve",equalDelta:!0,modifiers:[l().modifiers.restrictSize({max:"parent"})]})]:void 0}).draggable({autoScroll:!0,allowFrom:this.header,ignoreFrom:this.body,listeners:{move:this.dragMoveListener,end:this.dragEndListener}})}))}handleClose(e){this.show=!1,this.full=!1,this.dispatchEvent(new CustomEvent("floating-modal-close",{composed:!0,bubbles:!0,detail:{srcEvent:e}}))}handleMinimize(){this.minimizable&&(this.dragOccured||(this.minimize=!this.minimize,this.dispatchEvent(new CustomEvent("floating-modal-minimize",{composed:!0,bubbles:!0,detail:{minimize:this.minimize}}))),this.dragOccured=!1)}handleToggleExpandCollapse(){this.full=!this.full}getTransformValues(e){const{target:t,dx:i,dy:s}=e,{initialX:o,initialY:r}=this.getInitialPosition();return{x:(parseFloat(t.getAttribute("data-x"))||0)+i+o,y:(parseFloat(t.getAttribute("data-y"))||0)+s+r}}setTargetPosition(e,t,i){e.style.transform=`translate(${t}px, ${i}px)`,e.setAttribute("data-x",`${t}`),e.setAttribute("data-y",`${i}`)}destroyInteractInstance(){this.container&&l().isSet(this.container)&&l()(this.container).unset()}disconnectedCallback(){super.disconnectedCallback(),this.destroyInteractInstance()}renderedCallback(){this.containerTransform=this.position?`translate(${this.position.x}px, ${this.position.y}px)`:""}render(){return d.html`
|
|
1768
1769
|
${this.show?d.html`
|
|
1769
1770
|
<div
|
|
1770
1771
|
class="md-floating ${this.fixed?"fixed":""} ${this.minimize?"hide":""}"
|
|
1771
1772
|
part="floating"
|
|
1772
1773
|
role="dialog"
|
|
1773
|
-
aria-label=${(0,
|
|
1774
|
+
aria-label=${(0,p.ifDefined)(this.label||void 0)}
|
|
1774
1775
|
aria-modal="true"
|
|
1775
|
-
style=${(0,
|
|
1776
|
+
style=${(0,p.ifDefined)(this.containerRect?`width: ${this.full?"100% !important":`${this.containerRect.width}px !important`};\n height: ${this.full?"100% !important":`${this.containerRect.height}px !important`};\n top: ${this.full?"0 !important":""};\n left: ${this.full?"0 !important":""};\n bottom: ${this.full?"0 !important":""};\n right: ${this.full?"0 !important":""};\n ${this.full?"transform: none !important":""};\n ${this.full?"":`transform: ${this.position?`translate(${this.position.x}px, ${this.position.y}px)`:this.containerTransform} !important`};`:void 0)}
|
|
1776
1777
|
>
|
|
1777
1778
|
<div class="md-floating__header">
|
|
1778
1779
|
<div class="md-floating__header-text">
|
|
@@ -1833,7 +1834,7 @@
|
|
|
1833
1834
|
</md-floating-modal-minimized>
|
|
1834
1835
|
</div>`:h.nothing}
|
|
1835
1836
|
`:h.nothing}
|
|
1836
|
-
`}};u([(0,d.property)({type:String})],t.prototype,"heading",void 0),u([(0,d.property)({type:String})],t.prototype,"label",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"show",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"aspect-ratio"})],t.prototype,"aspectRatio",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"fixed-strategy"})],t.prototype,"fixed",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"full-screen"})],t.prototype,"full",void 0),u([(0,d.property)({type:String,attribute:"close-aria-label"})],t.prototype,"closeAriaLabel",void 0),u([(0,d.property)({type:String,attribute:"resize-aria-label"})],t.prototype,"resizeAriaLabel",void 0),u([(0,d.property)({type:String,attribute:"maximize-aria-label"})],t.prototype,"maximizeScreenLabel",void 0),u([(0,d.property)({type:String,attribute:"minimize-aria-label"})],t.prototype,"minimizeAriaLabel",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"minimize",void 0),u([(0,d.property)({type:Object})],t.prototype,"position",void 0),u([(0,d.property)({type:Object})],t.prototype,"minPosition",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"minimizable",void 0),u([(0,d.property)({type:Object})],t.prototype,"containerRect",void 0),u([(0,d.internalProperty)()],t.prototype,"dragOccured",void 0),u([(0,d.query)(".md-floating")],t.prototype,"container",void 0),u([(0,d.query)(".md-floating__body")],t.prototype,"body",void 0),u([(0,d.query)(".md-floating__header")],t.prototype,"header",void 0),u([(0,d.query)(".md-floating-min-parent")],t.prototype,"minimizedHeader",void 0),u([(0,d.query)('slot[name="header"]')],t.prototype,"headerSlot",void 0),t=u([(0,r.w)("md-floating-modal")],t),e.ELEMENT=t}(s||(s={}))},73679:e=>{e.exports=
|
|
1837
|
+
`}};u([(0,d.property)({type:String})],t.prototype,"heading",void 0),u([(0,d.property)({type:String})],t.prototype,"label",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"show",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"aspect-ratio"})],t.prototype,"aspectRatio",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"fixed-strategy"})],t.prototype,"fixed",void 0),u([(0,d.property)({type:Boolean,reflect:!0,attribute:"full-screen"})],t.prototype,"full",void 0),u([(0,d.property)({type:String,attribute:"close-aria-label"})],t.prototype,"closeAriaLabel",void 0),u([(0,d.property)({type:String,attribute:"resize-aria-label"})],t.prototype,"resizeAriaLabel",void 0),u([(0,d.property)({type:String,attribute:"maximize-aria-label"})],t.prototype,"maximizeScreenLabel",void 0),u([(0,d.property)({type:String,attribute:"minimize-aria-label"})],t.prototype,"minimizeAriaLabel",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"minimize",void 0),u([(0,d.property)({type:Object})],t.prototype,"position",void 0),u([(0,d.property)({type:Object})],t.prototype,"minPosition",void 0),u([(0,d.property)({type:Boolean,reflect:!0})],t.prototype,"minimizable",void 0),u([(0,d.property)({type:Object})],t.prototype,"containerRect",void 0),u([(0,d.internalProperty)()],t.prototype,"dragOccured",void 0),u([(0,d.query)(".md-floating")],t.prototype,"container",void 0),u([(0,d.query)(".md-floating__body")],t.prototype,"body",void 0),u([(0,d.query)(".md-floating__header")],t.prototype,"header",void 0),u([(0,d.query)(".md-floating-min-parent")],t.prototype,"minimizedHeader",void 0),u([(0,d.query)('slot[name="header"]')],t.prototype,"headerSlot",void 0),t=u([(0,r.w)("md-floating-modal")],t),e.ELEMENT=t}(s||(s={}))},73679:e=>{e.exports=v},74896:(e,t,i)=>{i.d(t,{Alert:()=>s}),i(61200),i(19026);var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(62798),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.closable=!1,this.message="",this.show=!1,this.internalClose=!0,this.title="",this.btnlabel="Close",this.type="default",this.inline=!1,this.newMomentum=!1,this.primaryButton="",this.primaryButtonVariant="primary",this.primaryButtonColor="",this.secondaryButton="",this.link=!1,this.showMore=!1,this.href="",this.hasFooterSlotContent=!1,this.renderIconTemplate=()=>{switch(this.type){case"error":return n.html`
|
|
1837
1838
|
<md-icon
|
|
1838
1839
|
name="error-legacy-bold"
|
|
1839
1840
|
size="${this.newMomentum?24:32}"
|
|
@@ -1953,7 +1954,7 @@
|
|
|
1953
1954
|
</div>
|
|
1954
1955
|
${this.primaryButton||this.secondaryButton||this.link?this.renderNewAlertDefaultFooter():this.renderSlottedFooter()}
|
|
1955
1956
|
</div>
|
|
1956
|
-
`}get alertRender(){return this.newMomentum?this.newRender():this.legacyRender()}render(){return n.html` ${this.show?this.alertRender:a.nothing} `}};h([(0,n.property)({type:Boolean})],t.prototype,"closable",void 0),h([(0,n.property)({type:String})],t.prototype,"message",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"show",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"internalClose",void 0),h([(0,n.property)({type:String})],t.prototype,"title",void 0),h([(0,n.property)({type:String})],t.prototype,"btnlabel",void 0),h([(0,n.property)({type:String})],t.prototype,"type",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inline",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"newMomentum",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButton",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButtonVariant",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButtonColor",void 0),h([(0,n.property)()],t.prototype,"primaryButtonClickFunction",void 0),h([(0,n.property)({type:String})],t.prototype,"secondaryButton",void 0),h([(0,n.property)()],t.prototype,"secondaryButtonClickFunction",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"link",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"showMore",void 0),h([(0,n.property)({type:String})],t.prototype,"href",void 0),h([(0,n.query)('slot[name="alert-footer"]')],t.prototype,"alertFooterSlot",void 0),h([(0,n.internalProperty)()],t.prototype,"hasFooterSlotContent",void 0),t=h([(0,o.w)("md-alert")],t),e.ELEMENT=t}(s||(s={}))},77935:(e,t,i)=>{i.d(t,{TableAdvanced:()=>g}),i(96798),i(61200),i(11323);var s=i(31890),o=i(28373),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(97822),h=i(3527),
|
|
1957
|
+
`}get alertRender(){return this.newMomentum?this.newRender():this.legacyRender()}render(){return n.html` ${this.show?this.alertRender:a.nothing} `}};h([(0,n.property)({type:Boolean})],t.prototype,"closable",void 0),h([(0,n.property)({type:String})],t.prototype,"message",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"show",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"internalClose",void 0),h([(0,n.property)({type:String})],t.prototype,"title",void 0),h([(0,n.property)({type:String})],t.prototype,"btnlabel",void 0),h([(0,n.property)({type:String})],t.prototype,"type",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"inline",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"newMomentum",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButton",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButtonVariant",void 0),h([(0,n.property)({type:String})],t.prototype,"primaryButtonColor",void 0),h([(0,n.property)()],t.prototype,"primaryButtonClickFunction",void 0),h([(0,n.property)({type:String})],t.prototype,"secondaryButton",void 0),h([(0,n.property)()],t.prototype,"secondaryButtonClickFunction",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"link",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"showMore",void 0),h([(0,n.property)({type:String})],t.prototype,"href",void 0),h([(0,n.query)('slot[name="alert-footer"]')],t.prototype,"alertFooterSlot",void 0),h([(0,n.internalProperty)()],t.prototype,"hasFooterSlotContent",void 0),t=h([(0,o.w)("md-alert")],t),e.ELEMENT=t}(s||(s={}))},77935:(e,t,i)=>{i.d(t,{TableAdvanced:()=>g}),i(96798),i(61200),i(11323);var s=i(31890),o=i(28373),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(97822),h=i(3527),p=i(28187),c=i.n(p),u=i(87421),m=i(56076),y=i(21796),b=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};const v=document.createElement("img");var g;v.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7",function(e){let t=class extends((0,o.d)(n.LitElement)){constructor(){super(...arguments),this.isRowFocusable="true",this.error="",this.COLS=[],this.ROWS=[],this.updCols=()=>this.requestUpdate("COLS"),this.updRows=()=>this.requestUpdate("ROWS"),this.dragRow=-1,this.dropRow=-1,this.drops=[],this.dragRowElem=null,this.dragCol=-1,this.dropCol=-1,this.isResizing=!1,this.isSelectable=!1,this.selected={},this.expandedRowIdx={},this.dragover=e=>e.preventDefault(),this.eX=0,this.onResize=(e,t)=>{var i;if(-1!=this.dragCol||-1!=this.dragRow)return;this.isResizing=!0;const s=e.target;null===(i=e.dataTransfer)||void 0===i||i.setDragImage(v,0,0);const o=this.COLS.map((e=>this.shadowRoot.querySelector(`th.col-index-${e.index}`)));this.COLS.forEach(((e,t)=>e.width=o[t].offsetWidth+"px")),this.updCols();const r=e.x;this.eX=e.x;let n=-1,a=-1,l=-1;const d=this.COLS[t.index-1],h=o[t.index],p=o[t.index-1],c=h.offsetWidth,u=p.offsetWidth,m=()=>{const e=this.eX;if(n!=e&&0!=e){n=e;const i=n-r;a=c-i,l=u+i,t.width=a+"px",d.width=l+"px",this.updCols()}},y=e=>this.eX=e.x,b=()=>{this.isResizing=!1,s.removeEventListener("drag",m),s.removeEventListener("dragend",b),document.removeEventListener("dragover",y)};s.addEventListener("drag",m),s.addEventListener("dragend",b),document.addEventListener("dragover",y)}}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("dragover",this.dragover)}connectedCallback(){super.connectedCallback(),document.addEventListener("dragover",this.dragover),this.updateTableConfig(),this.updateTableData(),this.populateTable()}update(e){super.update(e),e.has("data")&&(this.updateTableData(),this.updateDataInTable())}updateTableData(){if("string"==typeof this.data)try{this.tableData=JSON.parse(this.data)}catch(e){console.error("[INVALID_JSON_FORMAT] Please recheck the config json")}else this.tableData=Object.assign({},this.data)}updateTableConfig(){if("string"==typeof this.config)try{this.tableConfig=JSON.parse(this.config)}catch(e){console.error("[INVALID_JSON_FORMAT] Please recheck the data json")}else this.tableConfig=Object.assign({},this.config)}populateColumns(){var e;let t=0;const i=(e,i)=>{var s,o,r,n;const a=e.filters||(null===(o=null===(s=this.tableConfig.default)||void 0===s?void 0:s.col)||void 0===o?void 0:o.filters),l=a?"forString"==a?y.d.optionsString:"forNumber"==a?y.d.optionsNumber:a.length?a:null:null;this.COLS.push({options:Object.assign({},e),index:t++,group:i,sort:"default",sorter:e.sorter||(null===(n=null===(r=this.tableConfig.default)||void 0===r?void 0:r.col)||void 0===n?void 0:n.sorter),isCollapsable:this.tableConfig.cols.collapse==e.id,filter:l?{list:l,selectedIndex:0,input:"",active:!1,menuVisible:!1}:void 0})};this.tableConfig.cols.define.forEach((e=>{"children"in e?e.children.forEach((t=>i(t,{name:e.groupName,length:e.children.length}))):i(e)})),this.isSelectable=!!this.tableConfig.rows&&"none"!=(null===(e=this.tableConfig.rows)||void 0===e?void 0:e.selectable)}populateData(){const e=this.COLS.length;if("csv"in this.tableData){const e=c().parse(this.tableData.csv,{skipEmptyLines:!0,transform:e=>e.trim()});if(e.errors)return void(this.error="PARSE ERROR:\n"+JSON.stringify(e.errors,null,2));{const t=e.data;this.ROWS=t.map((e=>e.map((e=>({text:e})))))}}else if("list2d"in this.tableData)this.ROWS=this.tableData.list2d.map((e=>e.map((e=>({text:e})))));else{for(;this.tableData.list.length>e;)this.ROWS.push(this.tableData.list.splice(0,e).map((e=>({text:e}))));0!=this.tableData.list.length&&this.ROWS.push(this.tableData.list.map((e=>({text:e}))))}0!=this.ROWS.length||(this.error="DATA ERROR: Data is empty")}validateData(){const e=this.COLS.length;this.ROWS.reduce(((e,t)=>e+t.length),0)%e==0?this.ROWS.forEach(((t,i)=>{const s=t.length;s!=e&&(this.error=`DATA ERROR: Total number of cols (=${e}) and data[${i}] length (=${s}) mismatch`)})):this.error=this.error="DATA ERROR: Data length mismatch. You must provide (numberOfRows * numberOfColumns) amount of data values."}populateTemplate(){const e=this.tableConfig.cellTemplates,t=Object.keys(e||{});e&&t.length&&this.ROWS.forEach(((t,i)=>{t.forEach(((t,s)=>{for(const o in e){const r=t.text.indexOf(o);if(-1!=r){const n=e[o],a=this.querySelector(`#${n.templateName}`);if(null==a){console.warn(`cellTemplates["${o}"]: Missing '${n.templateName}' template.`);continue}let l=t.text.replace(o,"");n.contentCb&&(l=n.contentCb({col:s,row:i,content:l,insertIndex:r})),this.ROWS[i][s]={text:l,template:{template:a,templateCb:n.templateCb,insertIndex:"replace"==n.contentUse?-1:r}};break}}}))}))}setDefaultFilterAndSort(){var e,t;const i=null===(e=this.tableConfig.default)||void 0===e?void 0:e.sort;if(i){const e=this.COLS.find((e=>e.options.id==i.colId));e?this.sort(e,i.order):console.warn(`Cant find ${i.colId} col - for sorting`)}const s=null===(t=this.tableConfig.default)||void 0===t?void 0:t.filter;if(s){const e=this.COLS.find((e=>e.options.id==s.colId));e?e.filter?(e.filter.selectedIndex=s.selectedIndex,e.filter.input=s.input,this.updCols(),this.filter(e)):console.warn(`Cant find filters on ${s.colId} col`):console.warn(`Cant find ${s.colId} col - for filtering`)}}populateTable(){this.populateColumns(),this.populateData(),this.validateData(),this.setDefaultFilterAndSort(),this.populateTemplate()}updateDataInTable(){this.populateData(),this.validateData(),this.populateTemplate()}onDropRow(){this.dragRow!=this.dropRow&&this.drops.push([this.dragRow,this.dropRow]),this.dragRow=-1,this.dropRow=-1,this.dragRowElem&&(this.dragRowElem.setAttribute("draggable","false"),this.dragRowElem=null)}onDropCol(){if(this.dragCol!=this.dropCol){const e=this.COLS[this.dragCol],t=this.COLS[this.dropCol],i=e.group,s=t.group,o=e.index,r=t.index;e.group=s,t.group=i,e.index=r,t.index=o,this.COLS[this.dragCol]=t,this.COLS[this.dropCol]=e,this.ROWS.forEach((e=>{const t=e[this.dragCol],i=e[this.dropCol];e[this.dragCol]=i,e[this.dropCol]=t})),this.updCols(),this.updRows()}this.dragCol=-1,this.dropCol=-1}sort(e,t){e.sorter&&(this.clearSelection(),this.drops=[],this.COLS.forEach((i=>{i.options.id==e.options.id?i.sort=t||("default"==i.sort?"ascending":"ascending"==i.sort?"descending":"default"):i.sort="default"})),this.updCols(),this.requestUpdate(),this["md-table-advanced-change"].emit({type:"sort",order:e.sort}))}filter(e){if(!e.filter)return;this.clearSelection(),this.drops=[];const t=e.filter.input.trim(),i=e.filter.list[e.filter.selectedIndex];e.filter.active=!!t,this.requestUpdate(),t?this["md-table-advanced-change"].emit({type:"filter-on",filter:i,input:t}):this["md-table-advanced-change"].emit({type:"filter-off",filter:e.filter.list[e.filter.selectedIndex]})}selectRow(e){var t;const i=e.row.idx,s=Object.prototype.hasOwnProperty.call(this.selected,i);"multiple"==(null===(t=this.tableConfig.rows)||void 0===t?void 0:t.selectable)?(e.metaKey?s?delete this.selected[i]:this.selected[i]=!0:e.shiftKey||(this.selected={[i]:!0}),this["md-table-advanced-change"].emit({type:"multi-select",rows:Object.keys(this.selected).map((e=>+e))})):s?this.clearSelection():(this.selected={[i]:!0},this["md-table-advanced-change"].emit({type:"select",index:i})),this.requestUpdate("selected")}clearSelection(){this.selected={},this.requestUpdate("selected")}collapseToggle(e,t){e.stopPropagation(),this.expandedRowIdx[t]?(delete this.expandedRowIdx[t],this["md-table-advanced-change"].emit({type:"collapse",row:t})):(this.expandedRowIdx[t]=!0,this["md-table-advanced-change"].emit({type:"expand",row:t})),this.clearSelection(),this.requestUpdate()}render(){if(this.error)return n.html` <div>${this.error}</div> `;const{head:e}=this.tableConfig,t=(0,l.classMap)({"sticky-header":!!this.tableConfig.isStickyHeader});return n.html`
|
|
1957
1958
|
<div class="md-table-advanced">
|
|
1958
1959
|
<slot></slot>
|
|
1959
1960
|
<table class=${t} summary=${(0,d.ifDefined)(null==e?void 0:e.summary)}>
|
|
@@ -2082,14 +2083,14 @@
|
|
|
2082
2083
|
`:n.html` ${(0,h.templateContent)(d.template)} `,-1!=d.insertIndex&&(l=n.html`
|
|
2083
2084
|
${d.insertIndex>0?i.text.substring(0,d.insertIndex):a.nothing} ${l}
|
|
2084
2085
|
${d.insertIndex<i.text.length-1?i.text.substring(d.insertIndex):a.nothing}
|
|
2085
|
-
`));const
|
|
2086
|
+
`));const p=(null===(o=this.tableConfig.rows)||void 0===o?void 0:o.isDraggable)&&"child"!=e.collapse,c=p&&-1!=this.dragRow&&this.dragRow!=e.idxDrag,u=p&&0==s,y=n.html`
|
|
2086
2087
|
<div
|
|
2087
2088
|
class="inner-cell"
|
|
2088
2089
|
draggable="false"
|
|
2089
2090
|
@dragstart=${()=>{this.isResizing||-1!=this.dragCol||(this.dragRow=e.idxDrag)}}
|
|
2090
2091
|
@dragend=${()=>this.onDropRow()}
|
|
2091
2092
|
>
|
|
2092
|
-
${
|
|
2093
|
+
${c?n.html`
|
|
2093
2094
|
<div
|
|
2094
2095
|
class="drag-area top"
|
|
2095
2096
|
@dragenter=${()=>{if(0==this.dragRow){const t=e.idxDrag-1;this.dropRow=t>=0?t:0}else this.dropRow=e.idxDrag}}
|
|
@@ -2118,13 +2119,13 @@
|
|
|
2118
2119
|
<span>${"child"==e.collapse?a.nothing:l}</span>
|
|
2119
2120
|
`:n.html` <span>${l}</span> `}
|
|
2120
2121
|
</div>
|
|
2121
|
-
`;return r.options.isHeader?n.html` <th part="cell-ishead" scope="row" title="${i.text}">${
|
|
2122
|
+
`;return r.options.isHeader?n.html` <th part="cell-ishead" scope="row" title="${i.text}">${y}</th> `:n.html` <td part=${0===s?"first-cell":"cell"} title="${i.text}">${y}</td> `}))}
|
|
2122
2123
|
</tr>
|
|
2123
|
-
`}static get styles(){return[r.A,u.A]}};b([(0,n.property)({attribute:"config"})],t.prototype,"config",void 0),b([(0,n.property)({attribute:"data"})],t.prototype,"data",void 0),b([(0,n.property)({type:String})],t.prototype,"isRowFocusable",void 0),b([(0,m.Wj)()],t.prototype,"md-table-advanced-change",void 0),b([(0,n.internalProperty)()],t.prototype,"tableConfig",void 0),b([(0,n.internalProperty)()],t.prototype,"tableData",void 0),b([(0,n.internalProperty)()],t.prototype,"error",void 0),b([(0,n.internalProperty)()],t.prototype,"COLS",void 0),b([(0,n.internalProperty)()],t.prototype,"ROWS",void 0),b([(0,n.internalProperty)()],t.prototype,"dragRow",void 0),b([(0,n.internalProperty)()],t.prototype,"dropRow",void 0),b([(0,n.internalProperty)()],t.prototype,"drops",void 0),b([(0,n.internalProperty)()],t.prototype,"dragCol",void 0),b([(0,n.internalProperty)()],t.prototype,"dropCol",void 0),b([(0,n.queryAll)("tr[tabindex]")],t.prototype,"tableRaws",void 0),b([(0,m.sg)(500)],t.prototype,"filter",null),t=b([(0,s.w)("md-table-advanced")],t),e.ELEMENT=t}(g||(g={}))},80072:(e,t,i)=>{i.d(t,{Draggable:()=>s});var s,o=i(41488),r=i(41891),n=i.n(r),a=i(26272),l=i(6979),d=i(66677),h=i(3001),
|
|
2124
|
+
`}static get styles(){return[r.A,u.A]}};b([(0,n.property)({attribute:"config"})],t.prototype,"config",void 0),b([(0,n.property)({attribute:"data"})],t.prototype,"data",void 0),b([(0,n.property)({type:String})],t.prototype,"isRowFocusable",void 0),b([(0,m.Wj)()],t.prototype,"md-table-advanced-change",void 0),b([(0,n.internalProperty)()],t.prototype,"tableConfig",void 0),b([(0,n.internalProperty)()],t.prototype,"tableData",void 0),b([(0,n.internalProperty)()],t.prototype,"error",void 0),b([(0,n.internalProperty)()],t.prototype,"COLS",void 0),b([(0,n.internalProperty)()],t.prototype,"ROWS",void 0),b([(0,n.internalProperty)()],t.prototype,"dragRow",void 0),b([(0,n.internalProperty)()],t.prototype,"dropRow",void 0),b([(0,n.internalProperty)()],t.prototype,"drops",void 0),b([(0,n.internalProperty)()],t.prototype,"dragCol",void 0),b([(0,n.internalProperty)()],t.prototype,"dropCol",void 0),b([(0,n.queryAll)("tr[tabindex]")],t.prototype,"tableRaws",void 0),b([(0,m.sg)(500)],t.prototype,"filter",null),t=b([(0,s.w)("md-table-advanced")],t),e.ELEMENT=t}(g||(g={}))},80072:(e,t,i)=>{i.d(t,{Draggable:()=>s});var s,o=i(41488),r=i(41891),n=i.n(r),a=i(26272),l=i(6979),d=i(66677),h=i(3001),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,h.TS)(o.LitElement)){constructor(){super(...arguments),this.delay=0,this.animation=0,this.handle="",this.filter="",this.easing="",this.direction="vertical",this.group=null,this.draggableItems="md-draggable-item",this.ghostClass="",this.chosenClass="",this.dragClass="",this.fallbackClass="",this.swapThreshold=1,this.touchStartThreshold=0,this.forceFallback=!1,this.sort=!1,this.disabled=!1,this.editable=!1,this.sortableInstance=null,this.handleOnChange=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-change",e)},this.handleOnClone=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-clone",e)},this.handleOnUnchoose=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-unchoose",e)},this.handleOnRemove=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-remove",e)},this.handleOnAdd=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-add",e)},this.handleOnChoose=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-choose",e)},this.handleOnEnd=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-end",e)},this.handleOnMove=(0,d.sg)((e=>{e.stopPropagation(),this.dispatchDragEvent("drag-move",e)}),100),this.handleOnStart=e=>{e.stopPropagation(),this.dispatchDragEvent("drag-start",e)}}static get styles(){return[a.A,l.A]}get slotElement(){return this.draggableSlot}generateOptions(){return Object.assign(Object.assign({},this.group&&{group:this.group}),{disabled:this.disabled,animation:this.animation,sort:this.sort,delay:this.delay,handle:this.handle,easing:this.easing,filter:this.filter,swapThreshold:this.swapThreshold,touchStartThreshold:this.touchStartThreshold,draggable:this.draggableItems,direction:this.direction,ghostClass:this.ghostClass,chosenClass:this.chosenClass,dragClass:this.dragClass,fallbackClass:this.fallbackClass,forceFallback:this.forceFallback,onStart:this.handleOnStart,onMove:this.handleOnMove,onEnd:this.handleOnEnd,onChoose:this.handleOnChoose,onAdd:this.handleOnAdd,onRemove:this.handleOnRemove,onUnchoose:this.handleOnUnchoose,onClone:this.handleOnClone,onChange:this.handleOnChange})}initializeSortable(){this.sortableInstance||(this.sortableInstance=n().create(this,this.generateOptions()))}dispatchDragEvent(e,t){this.dispatchEvent(new CustomEvent(e,{composed:!0,bubbles:!0,detail:{srcEvent:t}}))}cleanupSortable(){this.sortableInstance&&(this.sortableInstance.destroy(),this.sortableInstance=null)}connectedCallback(){super.connectedCallback(),this.initializeSortable()}disconnectedCallback(){super.disconnectedCallback(),this.cleanupSortable()}setSortableOption(e,t){this.sortableInstance&&void 0!==this.sortableInstance.option(e)&&this.sortableInstance.option(e,t)}updateSortableInstance(e){for(const t of e.keys()){const e=this[t];this.setSortableOption(t,e)}}updated(e){super.updated(e),this.updateSortableInstance(e)}slottedChanged(){this.initializeSortable()}render(){return o.html`
|
|
2124
2125
|
<div class="md-draggable" part="draggable" aria-disabled=${this.disabled}>
|
|
2125
2126
|
<slot name="draggable-item"></slot>
|
|
2126
2127
|
</div>
|
|
2127
|
-
`}};
|
|
2128
|
+
`}};p([(0,o.property)({type:Number})],t.prototype,"delay",void 0),p([(0,o.property)({type:Number})],t.prototype,"animation",void 0),p([(0,o.property)({type:String})],t.prototype,"handle",void 0),p([(0,o.property)({type:String})],t.prototype,"filter",void 0),p([(0,o.property)({type:String})],t.prototype,"easing",void 0),p([(0,o.property)({type:String})],t.prototype,"direction",void 0),p([(0,o.property)({type:Object})],t.prototype,"group",void 0),p([(0,o.property)({type:String,attribute:"draggable-items"})],t.prototype,"draggableItems",void 0),p([(0,o.property)({type:String,attribute:"ghost-class"})],t.prototype,"ghostClass",void 0),p([(0,o.property)({type:String,attribute:"chosen-class"})],t.prototype,"chosenClass",void 0),p([(0,o.property)({type:String,attribute:"drag-class"})],t.prototype,"dragClass",void 0),p([(0,o.property)({type:String,attribute:"fallback-class"})],t.prototype,"fallbackClass",void 0),p([(0,o.property)({type:Number,attribute:"swap-threshold"})],t.prototype,"swapThreshold",void 0),p([(0,o.property)({type:Number,attribute:"touch-start-threshold"})],t.prototype,"touchStartThreshold",void 0),p([(0,o.property)({type:Boolean,attribute:"force-fallback"})],t.prototype,"forceFallback",void 0),p([(0,o.property)({type:Boolean,reflect:!0})],t.prototype,"sort",void 0),p([(0,o.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",void 0),p([(0,o.property)({type:Boolean,reflect:!0})],t.prototype,"editable",void 0),p([(0,o.query)("slot[name='draggable-item']")],t.prototype,"draggableSlot",void 0),t=p([(0,h.wW)("md-draggable")],t),e.ELEMENT=t}(s||(s={}))},81144:(e,t,i)=>{i.d(t,{Radio:()=>s});var s,o=i(3001),r=i(31890),n=i(26272),a=i(41488),l=i(97822),d=i(76067),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,o.yC)(a.LitElement)){constructor(){super(...arguments),this.tabIndex=-1,this.label="",this.value="",this.ariaLabel="",this.autofocus=!1,this._disabled=!1,this._checked=!1}get disabled(){return this._disabled}set disabled(e){const t=this._disabled;this._disabled=e,this.setAttribute("aria-disabled",`${e}`),this.tabIndex=e?-1:0,this.requestUpdate("disabled",t)}get checked(){return this._checked}set checked(e){const t=this._checked;this._checked=e,this.setAttribute("aria-checked",`${e}`),this.requestUpdate("checked",t)}firstUpdated(e){super.firstUpdated(e),this.setAttribute("role","radio"),this.label&&this.setAttribute("aria-label",this.label)}static get styles(){return[n.A,d.A]}render(){return a.html`
|
|
2128
2129
|
<div class="md-radio-wrapper" part="radio-wrapper">
|
|
2129
2130
|
<input
|
|
2130
2131
|
class="md-radio-input"
|
|
@@ -2140,7 +2141,7 @@
|
|
|
2140
2141
|
/>
|
|
2141
2142
|
<label for="radio-label" class="md-radio-label" part="radio-label"><slot></slot></label>
|
|
2142
2143
|
</div>
|
|
2143
|
-
`}};h([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,a.property)({type:String})],t.prototype,"label",void 0),h([(0,a.property)({type:String})],t.prototype,"value",void 0),h([(0,a.property)({type:String})],t.prototype,"ariaLabel",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,a.property)({type:Boolean,attribute:!1})],t.prototype,"checked",null),t=h([(0,r.w)("md-radio")],t),e.ELEMENT=t}(s||(s={}))},
|
|
2144
|
+
`}};h([(0,a.property)({type:Number,reflect:!0})],t.prototype,"tabIndex",void 0),h([(0,a.property)({type:String})],t.prototype,"label",void 0),h([(0,a.property)({type:String})],t.prototype,"value",void 0),h([(0,a.property)({type:String})],t.prototype,"ariaLabel",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"autofocus",void 0),h([(0,a.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",null),h([(0,a.property)({type:Boolean,attribute:!1})],t.prototype,"checked",null),t=h([(0,r.w)("md-radio")],t),e.ELEMENT=t}(s||(s={}))},83192:(e,t,i)=>{i.d(t,{Tooltip:()=>s});var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(23968),h=i(77251),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.yC)(l.LitElement)){constructor(){super(...arguments),this.message="",this.placement="auto",this.disabled=!1,this.opened=!1,this.slotContent=null,this._keyDownListener=e=>{this.handleKeyDown(e)},this._wheelListener=e=>{this.opened&&this.notifyTooltipDestroy()}}connectedCallback(){super.connectedCallback(),document.addEventListener("keydown",this._keyDownListener),window.addEventListener("wheel",this._wheelListener,{passive:!0})}disconnectedCallback(){this.notifyTooltipDisconnected(),super.disconnectedCallback(),document.removeEventListener("keydown",this._keyDownListener),window.removeEventListener("wheel",this._wheelListener)}handleFocusIn(e){super.handleFocusIn&&super.handleFocusIn(e),this.notifyTooltipCreate()}handleFocusOut(e){super.handleFocusOut&&super.handleFocusOut(e),this.notifyTooltipDestroy()}openTooltip(){this.dispatchEvent(new CustomEvent("tooltip-create",{bubbles:!0,composed:!0,detail:Object.assign({placement:this.placement,reference:this.reference,popper:this.popper},!this.message&&{slotContent:this.slotContent})}))}notifyTooltipDisconnected(){document.dispatchEvent(new CustomEvent("tooltip-disconnected",{bubbles:!0,composed:!0,detail:{}}))}closeTooltip(){this.dispatchEvent(new CustomEvent("tooltip-destroy",{bubbles:!0,composed:!0,detail:{placement:this.placement,reference:this.reference,popper:this.popper}}))}changeMessage(){this.dispatchEvent(new CustomEvent("tooltip-message",{bubbles:!0,composed:!0,detail:{placement:this.placement,reference:this.reference,popper:this.popper}}))}changeSlotContent(e){this.dispatchEvent(new CustomEvent("tooltip-slot",{bubbles:!0,composed:!0,detail:{placement:this.placement,reference:this.reference,popper:this.popper,slotContent:e}}))}notifyTooltipCreate(){this.disabled||(this.opened=!0)}notifyTooltipDestroy(){this.disabled||(this.opened=!1)}handleKeyDown(e){e.code===o.Uz.Escape&&this.notifyTooltipDestroy()}handleSlotContentChange(e){const t=e.target;if(t){const e=t.assignedElements({flatten:!0});e.length&&(this.slotContent&&this.changeSlotContent(e),this.slotContent=e)}}updated(e){super.updated(e),e.has("opened")&&(this.opened?this.openTooltip():this.closeTooltip()),e.has("message")&&this.changeMessage()}get tooltipClassMap(){return{"md-tooltip--disabled":this.disabled}}render(){return l.html`
|
|
2144
2145
|
<div class="md-tooltip ${(0,d.classMap)(this.tooltipClassMap)}">
|
|
2145
2146
|
<div class="md-tooltip__popper" role="tooltip" part="tooltip-popper">
|
|
2146
2147
|
<div id="md-tooltip__content" class="md-tooltip__content" part="tooltip-content">
|
|
@@ -2162,13 +2163,13 @@
|
|
|
2162
2163
|
<slot></slot>
|
|
2163
2164
|
</div>
|
|
2164
2165
|
</div>
|
|
2165
|
-
`}static get styles(){return[a.A,h.A]}};
|
|
2166
|
-
<nav class="md-menu ${(0,
|
|
2166
|
+
`}static get styles(){return[a.A,h.A]}};p([(0,l.property)({type:String})],t.prototype,"message",void 0),p([(0,l.property)({type:String,reflect:!0})],t.prototype,"placement",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"disabled",void 0),p([(0,l.property)({type:Boolean,reflect:!0})],t.prototype,"opened",void 0),p([(0,l.query)(".md-tooltip__popper")],t.prototype,"popper",void 0),p([(0,l.query)(".md-tooltip__reference")],t.prototype,"reference",void 0),t=p([(0,n.w)("md-tooltip")],t),e.ELEMENT=t}(s||(s={}))},84032:(e,t,i)=>{i.d(t,{Menu:()=>s});var s,o=i(90195),r=i(31890),n=i(84624),a=i(68387),l=i(59164),d=i(26272),h=i(41488),p=i(23968),c=i(48171),u=i(49719),m=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n},y=function(e,t,i,s){return new(i||(i=Promise))((function(o,r){function n(e){try{l(s.next(e))}catch(e){r(e)}}function a(e){try{l(s.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?o(e.value):(t=e.value,t instanceof i?t:new i((function(e){e(t)}))).then(n,a)}l((s=s.apply(e,t||[])).next())}))};!function(e){let t=class extends((0,a.T)((0,n.I)(h.LitElement))){constructor(){super(...arguments),this.justified=!1,this.direction="horizontal",this.items=[],this.itemsHash={},this.itemsIdxHash={}}getNormalizedItemId(e){return e.replace("more-menu-item-","")}static get styles(){return[d.A,u.A]}get slotItem(){return this.menuSlotElement}linkMenuItems(){return y(this,void 0,void 0,(function*(){const{items:e}=this;e.forEach(((e,t)=>{const i=(0,l.O)("menu");e.setAttribute("id",i),e.setAttribute("aria-controls",i),e.selected=this.selected===t})),this.itemsHash=this.items.reduce(((e,t)=>(e[t.id]=t,e)),{}),this.itemsIdxHash=this.items.reduce(((e,t,i)=>(e[t.id]=i,e)),{})}))}setupMenuItems(){if(this.menuSlotElement){const e=this.menuSlotElement.assignedElements({flatten:!0});this.getChildrenFromTree({children:e},this.items)}}getChildrenFromTree(e,t){e.children.forEach((e=>{e instanceof c.MenuItem.ELEMENT&&t.push(e),this.getChildrenFromTree({children:Array.from(e.children)},t)}))}updateSelectedItem(e){const t=this.slotted.findIndex((e=>e.hasAttribute("selected")));t!==e&&(this.items&&[t,e].forEach((e=>{const t=this.items[e];null==t||t.toggleAttribute("selected")})),this.dispatchEvent(new CustomEvent("selected-menu-item",{detail:{value:e},composed:!0,bubbles:!0})),this.changeSelectedItemIdx(e))}changeSelectedItemIdx(e){this.selected=e}handleItemClick(e){const{id:t}=e.detail,i=this.itemsHash[this.getNormalizedItemId(t)];if(i&&!i.disabled){const e=this.itemsIdxHash[i.id];-1!==e&&this.updateSelectedItem(e)}}handleItemKeydown(e){const{key:t,id:i}=e.detail;switch(t){case o.Uz.End:this.changeSelectedItemIdx(this.items.length-1);break;case o.Uz.Home:this.changeSelectedItemIdx(0);break;case o.Uz.ArrowLeft:case o.Uz.ArrowUp:0===this.selected?this.changeSelectedItemIdx(this.items.length-1):this.changeSelectedItemIdx(this.selected-1);break;case o.Uz.ArrowRight:case o.Uz.ArrowDown:this.selected===this.items.length-1?this.changeSelectedItemIdx(0):this.changeSelectedItemIdx(this.selected+1);break;case o.Uz.Enter:case o.Uz.Space:const e=this.slotted.findIndex((e=>e.id===i&&!e.disabled));-1!==e&&this.updateSelectedItem(e)}}connectedCallback(){super.connectedCallback(),this.addEventListener("menu-item-click",this.handleItemClick),this.addEventListener("menu-item-keydown",this.handleItemKeydown)}updated(e){const t=Object.create(null,{updated:{get:()=>super.updated}});return y(this,void 0,void 0,(function*(){t.updated.call(this,e),e.has("slotted")&&(this.setupMenuItems(),this.linkMenuItems())}))}disconnectedCallback(){super.connectedCallback(),this.removeEventListener("menu-item-click",this.handleItemClick),this.removeEventListener("menu-item-keydown",this.handleItemKeydown)}get menuClassMap(){return{[`md-menu--${this.direction}`]:this.direction,justified:this.justified}}render(){return h.html`
|
|
2167
|
+
<nav class="md-menu ${(0,p.classMap)(this.menuClassMap)}">
|
|
2167
2168
|
<ul class="md-menu-list">
|
|
2168
2169
|
<slot></slot>
|
|
2169
2170
|
</ul>
|
|
2170
2171
|
</nav>
|
|
2171
|
-
`}};m([(0,h.property)({type:Boolean})],t.prototype,"justified",void 0),m([(0,h.property)({type:String})],t.prototype,"direction",void 0),m([(0,h.query)("slot")],t.prototype,"menuSlotElement",void 0),m([(0,h.query)("md-menu-overlay")],t.prototype,"menuSubElement",void 0),t=m([(0,r.w)("md-menu")],t),e.ELEMENT=t}(s||(s={}))},84157:e=>{e.exports=
|
|
2172
|
+
`}};m([(0,h.property)({type:Boolean})],t.prototype,"justified",void 0),m([(0,h.property)({type:String})],t.prototype,"direction",void 0),m([(0,h.query)("slot")],t.prototype,"menuSlotElement",void 0),m([(0,h.query)("md-menu-overlay")],t.prototype,"menuSubElement",void 0),t=m([(0,r.w)("md-menu")],t),e.ELEMENT=t}(s||(s={}))},84157:e=>{e.exports=u},84205:(e,t,i)=>{i.d(t,{PhoneInput:()=>s}),i(4928),i(96408);var s,o=i(31890),r=i(26272),n=i(13060),a=i(65875),l=i(860),d=i(41488),h=i(40333),p=i(23968),c=i(6963),u=i(77833),m=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends d.LitElement{constructor(){super(...arguments),this.codePlaceholder="+1",this.numberPlaceholder="Enter Phone Number",this.countryCallingCode="",this.showFlags=!1,this.pill=!1,this.disabled=!1,this.value="",this.errorMessage="",this.showErrorMessage=!1,this.clearIconHeight="auto",this.countryCodeAriaLabel="",this.dialNumberAriaLabel="",this.clearAriaLabel="Clear Input",this.clearCountryCodeAriaLabel="Clear Country Code",this.id="",this.newMomentum=!1,this.countryCode="US",this.codeList=[],this.formattedValue="",this.isValid=!0}connectedCallback(){super.connectedCallback(),this.codeList=(0,n.customArray)({name:"{countryNameEn}",value:"{countryCallingCode}",code:"{countryCode}"}),""===this.id&&(this.id=`md-phone-input-${Math.random().toString(36).substring(2,6)}`),this.validateInput(this.value)}getCountryFlag(e){return d.html`
|
|
2172
2173
|
<span class="flag-svg-wrapper">
|
|
2173
2174
|
<img src="${(0,a.findFlagUrlByIso2Code)(e)}" />
|
|
2174
2175
|
</span>
|
|
@@ -2201,7 +2202,7 @@
|
|
|
2201
2202
|
${this.showFlags?this.getModStyle():h.nothing}
|
|
2202
2203
|
<div class="md-phone-input__container">
|
|
2203
2204
|
${this.showFlags?d.html`
|
|
2204
|
-
<span class="flag-box ${(0,
|
|
2205
|
+
<span class="flag-box ${(0,p.classMap)(this.flagClassMap)}">${this.getCountryFlag(this.countryCode)}</span>
|
|
2205
2206
|
`:h.nothing}
|
|
2206
2207
|
<md-combobox
|
|
2207
2208
|
part="combobox"
|
|
@@ -2217,7 +2218,7 @@
|
|
|
2217
2218
|
is-dropdown-arrow
|
|
2218
2219
|
.clearAriaLabel="${this.clearCountryCodeAriaLabel}"
|
|
2219
2220
|
>
|
|
2220
|
-
${(0,
|
|
2221
|
+
${(0,c.repeat)(this.codeList,(e=>e.name),((e,t)=>this.countryCodeOptionTemplate(e,t)))}
|
|
2221
2222
|
</md-combobox>
|
|
2222
2223
|
<md-input
|
|
2223
2224
|
part="md-input"
|
|
@@ -2238,7 +2239,7 @@
|
|
|
2238
2239
|
.messageArr="${!this.isValid||this.showErrorMessage?[{type:"error",id:this.id,ariaLive:"polite",message:this.errorMessage}]:[]}"
|
|
2239
2240
|
></md-input>
|
|
2240
2241
|
</div>
|
|
2241
|
-
`}};m([(0,d.property)({type:String,reflect:!0})],t.prototype,"codePlaceholder",void 0),m([(0,d.property)({type:String})],t.prototype,"numberPlaceholder",void 0),m([(0,d.property)({type:String,attribute:"country-calling-code"})],t.prototype,"countryCallingCode",void 0),m([(0,d.property)({type:Boolean,attribute:"show-flags"})],t.prototype,"showFlags",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"pill",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"disabled",void 0),m([(0,d.property)({type:String})],t.prototype,"value",void 0),m([(0,d.property)({type:String})],t.prototype,"errorMessage",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"showErrorMessage",void 0),m([(0,d.property)({type:String,attribute:"clear-icon-height"})],t.prototype,"clearIconHeight",void 0),m([(0,d.property)({type:String})],t.prototype,"countryCodeAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"dialNumberAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"clearAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"clearCountryCodeAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"id",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"newMomentum",void 0),m([(0,d.internalProperty)()],t.prototype,"countryCode",void 0),m([(0,d.internalProperty)()],t.prototype,"codeList",void 0),m([(0,d.internalProperty)()],t.prototype,"formattedValue",void 0),m([(0,d.internalProperty)()],t.prototype,"isValid",void 0),m([(0,d.query)("md-combobox")],t.prototype,"combobox",void 0),t=m([(0,o.w)("md-phone-input")],t),e.ELEMENT=t}(s||(s={}))},85314:e=>{e.exports=
|
|
2242
|
+
`}};m([(0,d.property)({type:String,reflect:!0})],t.prototype,"codePlaceholder",void 0),m([(0,d.property)({type:String})],t.prototype,"numberPlaceholder",void 0),m([(0,d.property)({type:String,attribute:"country-calling-code"})],t.prototype,"countryCallingCode",void 0),m([(0,d.property)({type:Boolean,attribute:"show-flags"})],t.prototype,"showFlags",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"pill",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"disabled",void 0),m([(0,d.property)({type:String})],t.prototype,"value",void 0),m([(0,d.property)({type:String})],t.prototype,"errorMessage",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"showErrorMessage",void 0),m([(0,d.property)({type:String,attribute:"clear-icon-height"})],t.prototype,"clearIconHeight",void 0),m([(0,d.property)({type:String})],t.prototype,"countryCodeAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"dialNumberAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"clearAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"clearCountryCodeAriaLabel",void 0),m([(0,d.property)({type:String})],t.prototype,"id",void 0),m([(0,d.property)({type:Boolean})],t.prototype,"newMomentum",void 0),m([(0,d.internalProperty)()],t.prototype,"countryCode",void 0),m([(0,d.internalProperty)()],t.prototype,"codeList",void 0),m([(0,d.internalProperty)()],t.prototype,"formattedValue",void 0),m([(0,d.internalProperty)()],t.prototype,"isValid",void 0),m([(0,d.query)("md-combobox")],t.prototype,"combobox",void 0),t=m([(0,o.w)("md-phone-input")],t),e.ELEMENT=t}(s||(s={}))},85314:e=>{e.exports=a},85416:(e,t,i)=>{i.d(t,{DateTimePicker:()=>s}),i(96408),i(11323);var s,o=i(31890),r=i(81625),n=i(26272),a=i(41488),l=i(97822),d=i(65796),h=i(90195),p=i(33663),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){e.weekStartDays=["Sunday","Monday"];let t=class extends a.LitElement{constructor(){super(...arguments),this.maxDate=void 0,this.minDate=void 0,this.weekStart="Sunday",this.ariaLabel="",this.twoDigitAutoTab=!1,this.shouldCloseOnSelect=!1,this.twentyFourHourFormat=!1,this.timeSpecificity=h.R5.SECOND,this.dateValue=void 0,this.timeValue="00:00:00-08:00",this.value=void 0,this.locale="en-US",this.disabled=!1,this.controlButtons=void 0,this.fullDateTime=void 0,this.selectedTimeObject=void 0,this.selectedDateObject=(0,r.tB)(),this.firstCycle=!0,this.handleDateChange=e=>{var t,i;this.selectedDateObject=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.data,this.dateValue=null===(i=this.selectedDateObject)||void 0===i?void 0:i.toISODate(),this.combineDateAndTimeValues(this.dateValue,this.timeValue)},this.handleTimeChange=e=>{var t,i,s;this.selectedTimeObject=null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.data,this.timeValue=null===(i=this.selectedTimeObject)||void 0===i?void 0:i.startOf("second").toISOTime({suppressMilliseconds:!0}),(null===(s=this.controlButtons)||void 0===s?void 0:s.apply)||this.combineDateAndTimeValues(this.dateValue,this.timeValue)},this.handleDateTimeInputChange=e=>{var t;this.value=(0,r.az)(null===(t=null==e?void 0:e.detail)||void 0===t?void 0:t.value)},this.parseValueForVisuals=e=>{e&&(this.dateValue=e.split("T")[0],this.timeValue=e.split("T")[1])},this.updateDateTimeObject=()=>{this.value?this.fullDateTime=d.DateTime.fromISO(this.value,{locale:this.locale}):this.fullDateTime=d.DateTime.fromISO("",{locale:this.locale}),this.dispatchEvent(new CustomEvent("date-time-change",{bubbles:!0,composed:!0,detail:{dateTimeString:this.value,dateTime:this.fullDateTime,locale:this.locale,twentyFourHourFormat:this.twentyFourHourFormat}}))},this.combineDateAndTimeValues=(e,t)=>{e&&(this.value=t?(0,r.az)(`${e}T${t}`):(0,r.az)(e))}}firstUpdated(e){const t=Object.create(null,{firstUpdated:{get:()=>super.firstUpdated}});return i=this,s=void 0,r=function*(){var i;if(t.firstUpdated.call(this,e),!this.value){const e=null===(i=this.selectedDateObject)||void 0===i?void 0:i.toISODate();this.combineDateAndTimeValues(e,this.timeValue)}yield this.updateComplete,this.addEventListeners()},new((o=void 0)||(o=Promise))((function(e,t){function n(e){try{l(r.next(e))}catch(e){t(e)}}function a(e){try{l(r.throw(e))}catch(e){t(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(n,a)}l((r=r.apply(i,s||[])).next())}));var i,s,o,r}addEventListeners(){this.datePicker&&(this.datePicker.addEventListener("date-selection-change",this.handleDateChange),this.datePicker.addEventListener("date-input-change",this.handleDateTimeInputChange)),this.timePicker&&this.timePicker.addEventListener("time-selection-change",this.handleTimeChange)}updated(e){var t;super.updated(e),e.has("value")&&(this.value&&this.parseValueForVisuals(this.value),this.firstCycle?this.firstCycle=!1:this.updateDateTimeObject()),this.dateValue&&this.timeValue&&!(null===(t=this.controlButtons)||void 0===t?void 0:t.apply)&&(e.has("timeValue")||e.has("dateValue"))&&this.combineDateAndTimeValues(this.dateValue,this.timeValue),this.value&&e.has("locale")&&(this.fullDateTime=d.DateTime.fromISO(this.value,{locale:this.locale}))}disconnectedCallback(){this.datePicker&&(this.datePicker.removeEventListener("date-selection-change",this.handleDateChange),this.datePicker.removeEventListener("date-input-change",this.handleDateTimeInputChange)),this.timePicker&&this.timePicker.removeEventListener("time-selection-change",this.handleTimeChange)}static get styles(){return[n.A,p.A]}render(){var e;return a.html`
|
|
2242
2243
|
<md-datepicker
|
|
2243
2244
|
includes-time
|
|
2244
2245
|
?disabled=${this.disabled}
|
|
@@ -2248,7 +2249,9 @@
|
|
|
2248
2249
|
value=${(0,l.ifDefined)(this.value)}
|
|
2249
2250
|
weekStart=${this.weekStart}
|
|
2250
2251
|
placeholder="YYYY-MM-DDTHH:MM:SS-HH:MM"
|
|
2251
|
-
locale=${(0,l.ifDefined)(this.locale)}
|
|
2252
|
+
locale=${(0,l.ifDefined)(this.locale)}
|
|
2253
|
+
.controlButtons=${this.controlButtons}
|
|
2254
|
+
.shouldCloseOnSelect=${this.shouldCloseOnSelect}>
|
|
2252
2255
|
<div slot="time-picker" class="included-timepicker-wrapper">
|
|
2253
2256
|
<div class="time-picker-separator"></div>
|
|
2254
2257
|
<md-timepicker
|
|
@@ -2261,7 +2264,7 @@
|
|
|
2261
2264
|
</div>
|
|
2262
2265
|
</md-datepicker>
|
|
2263
2266
|
</div>
|
|
2264
|
-
`}};
|
|
2267
|
+
`}};c([(0,a.property)({type:String})],t.prototype,"maxDate",void 0),c([(0,a.property)({type:String})],t.prototype,"minDate",void 0),c([(0,a.property)({type:String})],t.prototype,"weekStart",void 0),c([(0,a.property)({type:String})],t.prototype,"ariaLabel",void 0),c([(0,a.property)({type:Boolean,attribute:"two-digit-auto-tab"})],t.prototype,"twoDigitAutoTab",void 0),c([(0,a.property)({type:Boolean,attribute:"should-close-on-select"})],t.prototype,"shouldCloseOnSelect",void 0),c([(0,a.property)({type:Boolean,attribute:"twenty-four-hour-format"})],t.prototype,"twentyFourHourFormat",void 0),c([(0,a.property)({type:String})],t.prototype,"timeSpecificity",void 0),c([(0,a.property)({type:String,attribute:"date-value"})],t.prototype,"dateValue",void 0),c([(0,a.property)({type:String,attribute:"time-value"})],t.prototype,"timeValue",void 0),c([(0,a.property)({type:String,reflect:!0})],t.prototype,"value",void 0),c([(0,a.property)({type:String})],t.prototype,"locale",void 0),c([(0,a.property)({type:Boolean})],t.prototype,"disabled",void 0),c([(0,a.property)({type:Object,attribute:!1})],t.prototype,"controlButtons",void 0),c([(0,a.internalProperty)()],t.prototype,"fullDateTime",void 0),c([(0,a.internalProperty)()],t.prototype,"selectedTimeObject",void 0),c([(0,a.internalProperty)()],t.prototype,"selectedDateObject",void 0),c([(0,a.query)("md-datepicker")],t.prototype,"datePicker",void 0),c([(0,a.query)("md-timepicker")],t.prototype,"timePicker",void 0),t=c([(0,o.w)("md-date-time-picker")],t),e.ELEMENT=t}(s||(s={}))},86610:(e,t,i)=>{i.d(t,{TaskItem:()=>s}),i(63704),i(61200);var s,o=i(31890),r=i(26272),n=i(41488),a=i(40333),l=i(23968),d=i(50182),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.mediaType="call",this.status="",this.popovertitle="",this.queue="",this.accepted=!1,this.quantity=0,this.lastmessage="",this.selected=!1,this.customAriaLabel="",this.iconSrc="",this.tabIndexForContainer="0",this.displayTitle="",this.titleValue="",this.itemTitleValue="",this.renderTaskType=()=>{switch(this.mediaType.toLowerCase()){case"telephony":return n.html`
|
|
2265
2268
|
<md-badge color="green" circle>
|
|
2266
2269
|
<md-icon name="handset-filled" size="20" iconSet="momentumDesign"></md-icon>
|
|
2267
2270
|
</md-badge>
|
|
@@ -2342,7 +2345,7 @@
|
|
|
2342
2345
|
${this.renderChatCount()}
|
|
2343
2346
|
</div>
|
|
2344
2347
|
</div>
|
|
2345
|
-
`}};h([(0,n.property)({type:String})],t.prototype,"mediaType",void 0),h([(0,n.property)({type:String})],t.prototype,"status",void 0),h([(0,n.property)({type:String})],t.prototype,"popovertitle",void 0),h([(0,n.property)({type:String})],t.prototype,"queue",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"accepted",void 0),h([(0,n.property)({type:Number})],t.prototype,"quantity",void 0),h([(0,n.property)({type:String})],t.prototype,"lastmessage",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"selected",void 0),h([(0,n.property)({type:String})],t.prototype,"customAriaLabel",void 0),h([(0,n.property)({type:String})],t.prototype,"iconSrc",void 0),h([(0,n.property)({type:String})],t.prototype,"tabIndexForContainer",void 0),h([(0,n.property)({type:String,reflect:!0})],t.prototype,"title",null),h([(0,n.property)({type:String,reflect:!0,attribute:"item-title"})],t.prototype,"itemTitle",null),t=h([(0,o.w)("md-task-item")],t),e.ELEMENT=t}(s||(s={}))},86635:e=>{e.exports=
|
|
2348
|
+
`}};h([(0,n.property)({type:String})],t.prototype,"mediaType",void 0),h([(0,n.property)({type:String})],t.prototype,"status",void 0),h([(0,n.property)({type:String})],t.prototype,"popovertitle",void 0),h([(0,n.property)({type:String})],t.prototype,"queue",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"accepted",void 0),h([(0,n.property)({type:Number})],t.prototype,"quantity",void 0),h([(0,n.property)({type:String})],t.prototype,"lastmessage",void 0),h([(0,n.property)({type:Boolean})],t.prototype,"selected",void 0),h([(0,n.property)({type:String})],t.prototype,"customAriaLabel",void 0),h([(0,n.property)({type:String})],t.prototype,"iconSrc",void 0),h([(0,n.property)({type:String})],t.prototype,"tabIndexForContainer",void 0),h([(0,n.property)({type:String,reflect:!0})],t.prototype,"title",null),h([(0,n.property)({type:String,reflect:!0,attribute:"item-title"})],t.prototype,"itemTitle",null),t=h([(0,o.w)("md-task-item")],t),e.ELEMENT=t}(s||(s={}))},86635:e=>{e.exports=l},90195:(e,t,i)=>{var s,o,r,n;i.d(t,{R5:()=>o,Uz:()=>s,iw:()=>n}),function(e){e.ArrowDown="ArrowDown",e.ArrowLeft="ArrowLeft",e.ArrowRight="ArrowRight",e.ArrowUp="ArrowUp",e.Backspace="Backspace",e.Delete="Delete",e.End="End",e.Enter="Enter",e.Escape="Escape",e.Home="Home",e.Space="Space",e.Tab="Tab",e.Digit1="Digit1",e.Digit2="Digit2",e.Digit3="Digit3",e.Digit4="Digit4",e.Digit5="Digit5",e.Digit6="Digit6",e.Digit7="Digit7",e.Digit8="Digit8",e.Digit9="Digit9",e.NumpadEnter="NumpadEnter"}(s||(s={})),function(e){e.HOUR="hour",e.MINUTE="minute",e.SECOND="second",e.AM_PM="am_pm"}(o||(o={})),function(e){e.GRAMMAR="grammar",e.FALSE="false",e.SPELLING="spelling",e.TRUE="true"}(r||(r={})),function(e){e.AriaActivedescendant="aria-activedescendant"}(n||(n={}))},90827:(e,t,i)=>{i.d(t,{CardV2:()=>o}),i(96798),i(61200),i(83192);var s,o,r=i(31890),n=i(26272),a=i(41488),l=i(40333),d=i(23968),h=i(52759),p=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){e.DEFAULT="default",e.ACTIVE="active",e.INACTIVE="inactive"}(s||(s={})),function(e){let t=class extends a.LitElement{constructor(){super(...arguments),this.state=s.DEFAULT,this.identifier=void 0,this.header=void 0,this.info=void 0,this.data=void 0,this.expandable=!1}connectedCallback(){super.connectedCallback()}static get styles(){return[n.A,h.A]}get isActive(){return this.state===s.ACTIVE}expandCardToggled(){var e;this.state=this.isActive?s.DEFAULT:s.ACTIVE,this.dispatchEvent(new CustomEvent("expand-card-toggled",{detail:{identifier:null!==(e=this.identifier)&&void 0!==e?e:"",active:this.isActive},bubbles:!0,composed:!0}))}get cardClassMap(){return{"md-card-v2":!0,[`md-card--${this.state}`]:!0}}get contentClassMap(){return{"md-card-v2-content":!0,inactive:this.state===s.INACTIVE}}get footerClassMap(){return{"md-card-v2-footer":!0,hidden:!this.expandable}}renderHeader(){return a.html`
|
|
2346
2349
|
<div class="md-card-v2-header-title">
|
|
2347
2350
|
<h3>${this.header}</h3>
|
|
2348
2351
|
${this.info?a.html`
|
|
@@ -2373,7 +2376,7 @@
|
|
|
2373
2376
|
</div>
|
|
2374
2377
|
${this.renderFooter()}
|
|
2375
2378
|
</div>
|
|
2376
|
-
`}};
|
|
2379
|
+
`}};p([(0,a.property)({type:String})],t.prototype,"state",void 0),p([(0,a.property)({type:String})],t.prototype,"identifier",void 0),p([(0,a.property)({type:String})],t.prototype,"header",void 0),p([(0,a.property)({type:String})],t.prototype,"info",void 0),p([(0,a.property)({type:String})],t.prototype,"data",void 0),p([(0,a.property)({type:Boolean})],t.prototype,"expandable",void 0),t=p([(0,r.w)("md-card-v2")],t),e.ELEMENT=t}(o||(o={}))},92992:(e,t,i)=>{i.d(t,{Breadcrumb:()=>s});var s,o=i(31890),r=i(26272),n=i(41488),a=i(97822),l=i(22818),d=i(46441),h=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends n.LitElement{constructor(){super(...arguments),this.label="Breadcrumb",this.navCrumbs=[]}static get styles(){return[r.A,d.A]}setLastAnchorCurrent(){var e;(null===(e=this.anchors)||void 0===e?void 0:e.length)&&this.anchors[this.anchors.length-1].setAttribute("aria-current","page")}firstUpdated(e){super.firstUpdated(e),this.setLastAnchorCurrent()}update(e){super.update(e),e.has("navCrumbs")&&this.setLastAnchorCurrent()}handleClick(e){var t;const i=e.target;if(null===(t=this.anchors)||void 0===t?void 0:t.length){const e=Array.from(this.anchors).indexOf(i);-1!==e&&(this.navCrumbs=[...this.navCrumbs.splice(0,e+1)])}}render(){return n.html`
|
|
2377
2380
|
<nav aria-label="${(0,a.ifDefined)(this.label?this.label:void 0)}" class="md-breadcrumb">
|
|
2378
2381
|
<ul @click=${e=>this.handleClick(e)}>
|
|
2379
2382
|
${(0,l.repeat)(this.navCrumbs,(e=>e.link),(e=>n.html`
|
|
@@ -2422,7 +2425,7 @@
|
|
|
2422
2425
|
</div>
|
|
2423
2426
|
</div>
|
|
2424
2427
|
</div>
|
|
2425
|
-
`}};d([(0,n.property)({type:String})],t.prototype,"title",void 0),d([(0,n.property)({type:String})],t.prototype,"src",void 0),d([(0,n.property)({type:String})],t.prototype,"time",void 0),d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"status",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"self-label"})],t.prototype,"selfLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"self",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"avatar-color"})],t.prototype,"avatarColor",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"avatar-type"})],t.prototype,"avatarType",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"avatar-size"})],t.prototype,"avatarSize",void 0),t=d([(0,o.w)("md-chat-message")],t),e.ELEMENT=t}(s||(s={}))},96408:(e,t,i)=>{i.d(t,{Input:()=>s}),i(20109),i(61200),i(6396),i(12176);var s,o=i(90195),r=i(31890),n=i(32972),a=i(26272),l=(i(32022),i(41488)),d=i(40333),h=i(23968),
|
|
2428
|
+
`}};d([(0,n.property)({type:String})],t.prototype,"title",void 0),d([(0,n.property)({type:String})],t.prototype,"src",void 0),d([(0,n.property)({type:String})],t.prototype,"time",void 0),d([(0,n.property)({type:String})],t.prototype,"label",void 0),d([(0,n.property)({type:String})],t.prototype,"status",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"self-label"})],t.prototype,"selfLabel",void 0),d([(0,n.property)({type:Boolean})],t.prototype,"self",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"avatar-color"})],t.prototype,"avatarColor",void 0),d([(0,n.property)({type:String,reflect:!0,attribute:"avatar-type"})],t.prototype,"avatarType",void 0),d([(0,n.property)({type:Number,reflect:!0,attribute:"avatar-size"})],t.prototype,"avatarSize",void 0),t=d([(0,o.w)("md-chat-message")],t),e.ELEMENT=t}(s||(s={}))},96408:(e,t,i)=>{i.d(t,{Input:()=>s}),i(20109),i(61200),i(6396),i(12176);var s,o=i(90195),r=i(31890),n=i(32972),a=i(26272),l=(i(32022),i(41488)),d=i(40333),h=i(23968),p=i(97822),c=i(22818),u=i(8229),m=i(21572),y=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){class t{determineMessageType(e){return e.reduce(((e,t)=>"error"===t?e:t.type),"")}filterMessagesByType(e,t){return e.reduce(((e,i)=>i.type===t?e.concat(i.message):e),[])}}e.MessageController=t;let i=class extends((0,n.y)(l.LitElement)){constructor(){super(...arguments),this.ariaDescribedBy="",this.ariaInvalid="false",this.ariaLabel="input",this.autofocus=!1,this.auxiliaryContentPosition=null,this.clear=!1,this.clearAriaLabel="",this.compact=!1,this.containerSize="small-12",this.disabled=!1,this.id="",this.inputSize="",this.isFilled=!1,this.isLoading=!1,this.label="",this.helpText="",this.hideMessage=!1,this.htmlId="",this.role="",this.messageArr=[],this.min=void 0,this.max=void 0,this.maxLength=void 0,this.multi=!1,this.multiline=!1,this.name="",this.nestedLevel=0,this.placeholder="",this.readOnly=!1,this.required=!1,this.searchable=!1,this.secondaryLabel="",this.selectWhenInFocus=!1,this.shape="",this.type="text",this.value="",this.ariaControls="",this.ariaExpanded="",this.newMomentum=!1,this.isEditing=!1,this.hasRightSlotContent=!1,this.messageController=new t}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.handleOutsideClick)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.handleOutsideClick)}select(){this.input.select()}handleOutsideClick(e){let t=!1;const i=e.composedPath();i.length&&(t=!!i.find((e=>e===this)),t||(this.input.blur(),this.isEditing=!1))}handleKeyDown(e){this.dispatchEvent(new CustomEvent("input-keydown",{bubbles:!0,composed:!0,detail:{srcEvent:e}}))}handleFocus(e){this.disabled||(this.isEditing=!0,this.selectWhenInFocus&&this.select(),this.dispatchEvent(new CustomEvent("input-focus",{bubbles:!0,composed:!0,detail:{srcEvent:e}})))}handleMouseDown(e){this.disabled||(this.isEditing=!0,this.dispatchEvent(new CustomEvent("input-mousedown",{bubbles:!0,composed:!0,detail:{srcEvent:e}})))}handleChange(e){this.value=e.target.value,this.dispatchEvent(new CustomEvent("input-change",{bubbles:!0,composed:!0,detail:{srcEvent:e,value:this.value}}))}handleBlur(e){this.isEditing=!1,this.dispatchEvent(new CustomEvent("input-blur",{bubbles:!0,composed:!0,detail:{srcEvent:e}}))}handleClear(e){if("keydown"===e.type){const{code:t}=e;if(t!==o.Uz.Space&&t!==o.Uz.Enter)return;e.preventDefault(),e.stopPropagation()}else"click"===e.type&&(e.preventDefault(),e.stopPropagation());this.input.focus(),this.dispatchEvent(new CustomEvent("input-clear",{bubbles:!0,composed:!0,detail:{srcEvent:e}})),document.dispatchEvent(new CustomEvent("on-widget-update")),this.handleChange(e)}handleLabelClick(){this.input.focus()}handleRighSlotChange(){var e;this.hasRightSlotContent=(null===(e=this.inputSectionRightSlot)||void 0===e?void 0:e.assignedNodes().length)>0}get messageType(){return this.messageArr.length>0?this.messageController.determineMessageType(this.messageArr):null}get messages(){return this.messageType?this.messageController.filterMessagesByType(this.messageArr,this.messageType):null}get inputClassMap(){return{"md-input--filled":this.isFilled,colums:!!this.containerSize,[`${this.containerSize}`]:!!this.containerSize,"md-read-only":this.readOnly,"md-disabled":this.disabled,[`md-${this.messageType}`]:!!this.messageType,[`md-input--nested-${this.nestedLevel}`]:!!this.nestedLevel,"md-multi":this.multi,"md-new-momentum":this.newMomentum}}get inputWrapperClassMap(){return{columns:!!this.inputSize,[`${this.inputSize}`]:!!this.inputSize}}get inputTemplateClassMap(){return{"md-input--multiline":this.multiline,"md-input--multi":this.multi,[`md-input--${this.shape}`]:!!this.shape,"md-input--compact":this.compact,"md-input--before":"before"===this.auxiliaryContentPosition||this.searchable,"md-input--after":"after"===this.auxiliaryContentPosition,"md-active":this.isEditing,"md-focus":this.isEditing,"md-read-only":this.readOnly,"md-disabled":this.disabled,"md-dirty":!!this.value,"md-has-right-icon":this.hasRightIcon}}get ariaExpandedValue(){return"true"===this.ariaExpanded||"false"===this.ariaExpanded?this.ariaExpanded:"undefined"}get hasRightIcon(){return!(!this.clear||this.disabled||!this.value||this.readOnly)||!this.compact&&this.hasRightSlotContent}inputTemplate(){var e;return this.multiline?l.html`
|
|
2426
2429
|
<textarea
|
|
2427
2430
|
part="input"
|
|
2428
2431
|
class="md-input ${(0,h.classMap)(this.inputTemplateClassMap)}"
|
|
@@ -2439,11 +2442,11 @@
|
|
|
2439
2442
|
aria-label=${this.ariaLabel}
|
|
2440
2443
|
aria-invalid=${this.ariaInvalid}
|
|
2441
2444
|
aria-errormessage="${this.htmlId}-message"
|
|
2442
|
-
aria-disabled=${(0,
|
|
2445
|
+
aria-disabled=${(0,p.ifDefined)(this.disabled||void 0)}
|
|
2443
2446
|
id=${this.htmlId}
|
|
2444
2447
|
placeholder=${this.placeholder}
|
|
2445
2448
|
?readonly=${this.readOnly}
|
|
2446
|
-
maxlength=${(0,
|
|
2449
|
+
maxlength=${(0,p.ifDefined)(this.maxLength)}
|
|
2447
2450
|
></textarea>
|
|
2448
2451
|
`:l.html`
|
|
2449
2452
|
<input
|
|
@@ -2461,18 +2464,18 @@
|
|
|
2461
2464
|
.value=${this.value}
|
|
2462
2465
|
aria-describedby=${this.ariaDescribedBy}
|
|
2463
2466
|
aria-controls=${this.ariaControls}
|
|
2464
|
-
aria-expanded=${(0,
|
|
2467
|
+
aria-expanded=${(0,p.ifDefined)(null!==(e=this.ariaExpandedValue)&&void 0!==e?e:void 0)}
|
|
2465
2468
|
aria-label=${this.ariaLabel}
|
|
2466
2469
|
aria-invalid=${this.ariaInvalid}
|
|
2467
2470
|
aria-errormessage=${`${this.htmlId}-message`}
|
|
2468
|
-
aria-disabled=${(0,
|
|
2471
|
+
aria-disabled=${(0,p.ifDefined)(this.disabled||void 0)}
|
|
2469
2472
|
id=${this.htmlId}
|
|
2470
2473
|
role=${this.role}
|
|
2471
2474
|
placeholder=${this.placeholder}
|
|
2472
2475
|
?readonly=${this.readOnly||this.disabled}
|
|
2473
|
-
min=${(0,
|
|
2474
|
-
max=${(0,
|
|
2475
|
-
maxlength=${(0,
|
|
2476
|
+
min=${(0,p.ifDefined)(this.min)}
|
|
2477
|
+
max=${(0,p.ifDefined)(this.max)}
|
|
2478
|
+
maxlength=${(0,p.ifDefined)(this.maxLength)}
|
|
2476
2479
|
/>
|
|
2477
2480
|
`}inputLeftTemplate(){return this.searchable?l.html`
|
|
2478
2481
|
<div class="md-input__before">
|
|
@@ -2521,7 +2524,7 @@
|
|
|
2521
2524
|
></md-help-text>
|
|
2522
2525
|
`:d.nothing}messagesTemplate(){return!this.hideMessage&&this.messages&&this.messages.length?l.html`
|
|
2523
2526
|
<div id="${this.htmlId}-message" part="message" class="md-input__messages">
|
|
2524
|
-
${(0,
|
|
2527
|
+
${(0,c.repeat)(this.messages,((e,t)=>{var i,s;return l.html`
|
|
2525
2528
|
<md-help-text
|
|
2526
2529
|
.message=${e}
|
|
2527
2530
|
.id=${null!==(i=this.messageArr[t].id)&&void 0!==i?i:""}
|
|
@@ -2545,14 +2548,14 @@
|
|
|
2545
2548
|
</div>
|
|
2546
2549
|
${this.messagesTemplate()} ${this.secondaryLabelTemplate()} ${this.helpTextTemplate()}
|
|
2547
2550
|
</div>
|
|
2548
|
-
`}};
|
|
2551
|
+
`}};y([(0,l.property)({type:String})],i.prototype,"ariaDescribedBy",void 0),y([(0,l.property)({type:String,reflect:!0})],i.prototype,"ariaInvalid",void 0),y([(0,l.property)({type:String})],i.prototype,"ariaLabel",void 0),y([(0,l.property)({type:Boolean,reflect:!0})],i.prototype,"autofocus",void 0),y([(0,l.property)({type:String})],i.prototype,"auxiliaryContentPosition",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"clear",void 0),y([(0,l.property)({type:String})],i.prototype,"clearAriaLabel",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"compact",void 0),y([(0,l.property)({type:String})],i.prototype,"containerSize",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"disabled",void 0),y([(0,l.property)({type:String})],i.prototype,"id",void 0),y([(0,l.property)({type:String})],i.prototype,"inputSize",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"isFilled",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"isLoading",void 0),y([(0,l.property)({type:String})],i.prototype,"label",void 0),y([(0,l.property)({type:String})],i.prototype,"helpText",void 0),y([(0,l.property)({type:Boolean,attribute:"hide-message",reflect:!0})],i.prototype,"hideMessage",void 0),y([(0,l.property)({type:String})],i.prototype,"htmlId",void 0),y([(0,l.property)({type:String})],i.prototype,"role",void 0),y([(0,l.property)({type:Array})],i.prototype,"messageArr",void 0),y([(0,l.property)({type:Number,reflect:!0})],i.prototype,"min",void 0),y([(0,l.property)({type:Number,reflect:!0})],i.prototype,"max",void 0),y([(0,l.property)({type:Number})],i.prototype,"maxLength",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"multi",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"multiline",void 0),y([(0,l.property)({type:String,reflect:!0})],i.prototype,"name",void 0),y([(0,l.property)({type:Number})],i.prototype,"nestedLevel",void 0),y([(0,l.property)({type:String})],i.prototype,"placeholder",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"readOnly",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"required",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"searchable",void 0),y([(0,l.property)({type:String})],i.prototype,"secondaryLabel",void 0),y([(0,l.property)({type:Boolean,attribute:"select-when-in-focus"})],i.prototype,"selectWhenInFocus",void 0),y([(0,l.property)({type:String})],i.prototype,"shape",void 0),y([(0,l.property)({type:String})],i.prototype,"type",void 0),y([(0,l.property)({type:String,reflect:!0})],i.prototype,"value",void 0),y([(0,l.property)({type:String})],i.prototype,"ariaControls",void 0),y([(0,l.property)({type:String})],i.prototype,"ariaExpanded",void 0),y([(0,l.property)({type:Boolean})],i.prototype,"newMomentum",void 0),y([(0,l.query)(".md-input")],i.prototype,"input",void 0),y([(0,l.internalProperty)()],i.prototype,"isEditing",void 0),y([(0,l.query)('slot[name="input-section-right"]')],i.prototype,"inputSectionRightSlot",void 0),y([(0,l.internalProperty)()],i.prototype,"hasRightSlotContent",void 0),i=y([(0,r.w)("md-input")],i),e.ELEMENT=i}(s||(s={}))},96798:(e,t,i)=>{i.d(t,{Button:()=>s});var s,o=i(73940),r=(i(12176),i(31890)),n=i(26283),a=i(26272),l=i(41488),d=i(40333),h=i(23968),p=i(97822),c=i(11740),u=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends l.LitElement{constructor(){super(...arguments),this._active=!1,this._tabIndex=0,this.ariaLabel="",this.ariaLabelledBy="",this.ariaLive="",this.ariaExpanded="",this.ariaHaspopup="false",this.ariaPressed="",this.circle=!1,this.rounded=!1,this.color="",this.containerLarge=!1,this.disabled=!1,this.href="",this.id="",this.value="",this.keyboardKey="",this.label="",this.loading=!1,this.outline=!1,this.hasRemoveStyle=!1,this.size="32",this.tag="button",this.type="button",this.role="button",this.variant="secondary",this.width="",this.maxWidth="",this.activityType="",this.iconActive=!1,this.isActive=!1,this.renderWidth=()=>this.width?`width: ${this.width};`:d.nothing,this.renderMaxWidth=()=>this.maxWidth?`max-width: ${this.maxWidth};`:d.nothing,this.getStyles=()=>{if(this.width||this.maxWidth)return l.html`
|
|
2549
2552
|
<style>
|
|
2550
2553
|
:host .md-button--${this.size} {
|
|
2551
2554
|
${this.renderWidth()};
|
|
2552
2555
|
${this.renderMaxWidth()};
|
|
2553
2556
|
}
|
|
2554
2557
|
</style>
|
|
2555
|
-
`},this.iconTemplate=()=>this.loading?l.html` <md-spinner size="16"></md-spinner> `:l.html` <slot name="icon"></slot> `,this.textTemplate=()=>this.circle&&this.hasIcon?d.nothing:l.html` <slot name="text"></slot> `}get active(){return this._active}set active(e){const t=this._active;this._active=e,this.requestUpdate("active",t)}get tabIndex(){return this._tabIndex}set tabIndex(e){const t=this._tabIndex;this._tabIndex=e,this.requestUpdate("tabIndex",t)}handleKeyDown(e){if(this.disabled)return;const{code:t}=e;(0,n.o)(t)&&this.dispatchEvent(new CustomEvent("button-keydown",{composed:!0,bubbles:!0,detail:{srcEvent:e}}))}handleClick(e){this.disabled||(this.clickFunction
|
|
2558
|
+
`},this.iconTemplate=()=>this.loading?l.html` <md-spinner size="16"></md-spinner> `:l.html` <slot name="icon"></slot> `,this.textTemplate=()=>this.circle&&this.hasIcon?d.nothing:l.html` <slot name="text"></slot> `}get active(){return this._active}set active(e){const t=this._active;this._active=e,this.requestUpdate("active",t)}get tabIndex(){return this._tabIndex}set tabIndex(e){const t=this._tabIndex;this._tabIndex=e,this.requestUpdate("tabIndex",t)}handleKeyDown(e){if(this.disabled)return;const{code:t}=e;(0,n.o)(t)&&this.dispatchEvent(new CustomEvent("button-keydown",{composed:!0,bubbles:!0,detail:{srcEvent:e}}))}handleClick(e){var t;this.disabled||(null===(t=this.clickFunction)||void 0===t||t.call(this),this.dispatchEvent(new CustomEvent("button-click",{composed:!0,bubbles:!0,detail:{srcEvent:e}})))}static get styles(){return[a.A,c.A,o.A]}get buttonClassMap(){return{"md-button--circle":this.circle,"md-button--rounded":this.rounded,"md-button--none":this.hasRemoveStyle,"md-button--outline":this.outline,active:this.active&&!this.disabled,disabled:this.disabled&&!this.active,isActive:this.isActive,[`md-button--${this.size}`]:!this.hasRemoveStyle,[`md-button--${this.color}`]:!this.hasRemoveStyle&&!!this.color,[`md-activity__${this.activityType}`]:!!this.activityType,"md-activity":!!this.activityType,"md-button--icon":this.iconActive,"md-button--onlyicon":this.hasIcon&&!this.slottedText,"md-button--placeholder-text":!0===this.isPlaceholderText}}get slottedText(){var e;return null===(e=this.querySelector("[slot=text]"))||void 0===e?void 0:e.textContent}get hasIcon(){return null!==this.querySelector("[slot=icon]")||this.loading}childrenTemplate(){return l.html`
|
|
2556
2559
|
<span part="button-children" class="md-button__children">
|
|
2557
2560
|
${this.iconTemplate()} ${this.textTemplate()}
|
|
2558
2561
|
<slot></slot>
|
|
@@ -2564,16 +2567,16 @@
|
|
|
2564
2567
|
class="md-button ${(0,h.classMap)(this.buttonClassMap)}"
|
|
2565
2568
|
@click=${e=>this.handleClick(e)}
|
|
2566
2569
|
@keydown=${e=>this.handleKeyDown(e)}
|
|
2567
|
-
tabindex=${(0,
|
|
2568
|
-
aria-label=${(0,
|
|
2569
|
-
aria-labelledby=${(0,
|
|
2570
|
-
aria-live=${(0,
|
|
2571
|
-
aria-expanded=${(0,
|
|
2572
|
-
aria-haspopup=${(0,
|
|
2573
|
-
aria-pressed=${(0,
|
|
2574
|
-
aria-disabled=${(0,
|
|
2570
|
+
tabindex=${(0,p.ifDefined)(this.tabIndex||void 0)}
|
|
2571
|
+
aria-label=${(0,p.ifDefined)(this.ariaLabel||void 0)}
|
|
2572
|
+
aria-labelledby=${(0,p.ifDefined)(this.ariaLabelledBy||void 0)}
|
|
2573
|
+
aria-live=${(0,p.ifDefined)(this.ariaLive||void 0)}
|
|
2574
|
+
aria-expanded=${(0,p.ifDefined)(this.computedAriaExpand)}
|
|
2575
|
+
aria-haspopup=${(0,p.ifDefined)("false"===this.ariaHaspopup?void 0:this.ariaHaspopup)}
|
|
2576
|
+
aria-pressed=${(0,p.ifDefined)(this.ariaPressed||void 0)}
|
|
2577
|
+
aria-disabled=${(0,p.ifDefined)(this.disabled||this.loading||void 0)}
|
|
2575
2578
|
type=${this.type}
|
|
2576
|
-
role=${(0,
|
|
2579
|
+
role=${(0,p.ifDefined)("button"===this.role?void 0:this.role)}
|
|
2577
2580
|
>
|
|
2578
2581
|
${this.childrenTemplate()}
|
|
2579
2582
|
</button>
|
|
@@ -2585,15 +2588,15 @@
|
|
|
2585
2588
|
@click=${e=>this.handleClick(e)}
|
|
2586
2589
|
@keydown=${e=>this.handleKeyDown(e)}
|
|
2587
2590
|
role=${this.role}
|
|
2588
|
-
tabindex=${(0,
|
|
2591
|
+
tabindex=${(0,p.ifDefined)(this.tabIndex||void 0)}
|
|
2589
2592
|
aria-pressed=${"true"===this.ariaPressed}
|
|
2590
|
-
aria-label=${(0,
|
|
2591
|
-
aria-labelledby=${(0,
|
|
2592
|
-
aria-live=${(0,
|
|
2593
|
+
aria-label=${(0,p.ifDefined)(this.ariaLabel||void 0)}
|
|
2594
|
+
aria-labelledby=${(0,p.ifDefined)(this.ariaLabelledBy||void 0)}
|
|
2595
|
+
aria-live=${(0,p.ifDefined)(this.ariaLive||void 0)}
|
|
2593
2596
|
type=${this.type}
|
|
2594
2597
|
alt=${this.label}
|
|
2595
2598
|
value=${this.value}
|
|
2596
|
-
aria-disabled=${(0,
|
|
2599
|
+
aria-disabled=${(0,p.ifDefined)(this.disabled||this.loading||void 0)}
|
|
2597
2600
|
/>
|
|
2598
2601
|
`:"a"===e?l.html`
|
|
2599
2602
|
<a
|
|
@@ -2603,12 +2606,12 @@
|
|
|
2603
2606
|
@click=${e=>this.handleClick(e)}
|
|
2604
2607
|
@keydown=${e=>this.handleKeyDown(e)}
|
|
2605
2608
|
role=${this.role}
|
|
2606
|
-
tabindex=${(0,
|
|
2609
|
+
tabindex=${(0,p.ifDefined)(this.tabIndex||void 0)}
|
|
2607
2610
|
aria-pressed=${"true"===this.ariaPressed?"true":"false"}
|
|
2608
|
-
aria-label=${(0,
|
|
2609
|
-
aria-labelledby=${(0,
|
|
2610
|
-
aria-live=${(0,
|
|
2611
|
-
aria-disabled=${(0,
|
|
2611
|
+
aria-label=${(0,p.ifDefined)(this.ariaLabel||void 0)}
|
|
2612
|
+
aria-labelledby=${(0,p.ifDefined)(this.ariaLabelledBy||void 0)}
|
|
2613
|
+
aria-live=${(0,p.ifDefined)(this.ariaLive||void 0)}
|
|
2614
|
+
aria-disabled=${(0,p.ifDefined)(this.disabled||this.loading||void 0)}
|
|
2612
2615
|
href=${this.href}
|
|
2613
2616
|
>
|
|
2614
2617
|
${this.childrenTemplate()}
|
|
@@ -2639,7 +2642,7 @@
|
|
|
2639
2642
|
>
|
|
2640
2643
|
<slot></slot>
|
|
2641
2644
|
</form>
|
|
2642
|
-
`}};a([(0,r.property)({type:String})],t.prototype,"rel",void 0),a([(0,r.property)({type:String})],t.prototype,"name",void 0),a([(0,r.property)({type:String})],t.prototype,"action",void 0),a([(0,r.property)({type:String})],t.prototype,"label",void 0),a([(0,r.property)({type:String})],t.prototype,"method",void 0),a([(0,r.property)({type:String})],t.prototype,"target",void 0),a([(0,r.property)({type:String})],t.prototype,"enctype",void 0),a([(0,r.property)({type:Boolean,reflect:!0,attribute:"no-validate"})],t.prototype,"novalidate",void 0),a([(0,r.property)({type:String,reflect:!0,attribute:"accept-charset"})],t.prototype,"charset",void 0),a([(0,r.property)({type:Boolean,reflect:!0,attribute:"is-valid"})],t.prototype,"isvalid",void 0),a([(0,r.property)({type:String,attribute:"autofill-token"})],t.prototype,"token",void 0),a([(0,r.property)({type:Boolean,attribute:"allow-redirect"})],t.prototype,"allowRedirect",void 0),a([(0,r.property)({type:String,attribute:"autofill-name"})],t.prototype,"autofillname",void 0),a([(0,r.query)(".md-form")],t.prototype,"form",void 0),t=a([(0,o.wW)("md-form")],t),e.ELEMENT=t}(s||(s={}))},99687:(e,t,i)=>{i.r(t),i.d(t,{Accordion:()=>s.Accordion,AccordionItem:()=>o.AccordionItem,ActivityButton:()=>r.ActivityButton,AdvanceList:()=>n.AdvanceList,Alert:()=>l.Alert,AlertBanner:()=>a.AlertBanner,AudioPlayer:()=>d.AudioPlayer,Avatar:()=>h.Avatar,AvatarType:()=>
|
|
2645
|
+
`}};a([(0,r.property)({type:String})],t.prototype,"rel",void 0),a([(0,r.property)({type:String})],t.prototype,"name",void 0),a([(0,r.property)({type:String})],t.prototype,"action",void 0),a([(0,r.property)({type:String})],t.prototype,"label",void 0),a([(0,r.property)({type:String})],t.prototype,"method",void 0),a([(0,r.property)({type:String})],t.prototype,"target",void 0),a([(0,r.property)({type:String})],t.prototype,"enctype",void 0),a([(0,r.property)({type:Boolean,reflect:!0,attribute:"no-validate"})],t.prototype,"novalidate",void 0),a([(0,r.property)({type:String,reflect:!0,attribute:"accept-charset"})],t.prototype,"charset",void 0),a([(0,r.property)({type:Boolean,reflect:!0,attribute:"is-valid"})],t.prototype,"isvalid",void 0),a([(0,r.property)({type:String,attribute:"autofill-token"})],t.prototype,"token",void 0),a([(0,r.property)({type:Boolean,attribute:"allow-redirect"})],t.prototype,"allowRedirect",void 0),a([(0,r.property)({type:String,attribute:"autofill-name"})],t.prototype,"autofillname",void 0),a([(0,r.query)(".md-form")],t.prototype,"form",void 0),t=a([(0,o.wW)("md-form")],t),e.ELEMENT=t}(s||(s={}))},99687:(e,t,i)=>{i.r(t),i.d(t,{Accordion:()=>s.Accordion,AccordionItem:()=>o.AccordionItem,ActivityButton:()=>r.ActivityButton,AdvanceList:()=>n.AdvanceList,Alert:()=>l.Alert,AlertBanner:()=>a.AlertBanner,AudioPlayer:()=>d.AudioPlayer,Avatar:()=>h.Avatar,AvatarType:()=>c,Badge:()=>m.Badge,Breadcrumb:()=>y.Breadcrumb,Button:()=>v.Button,ButtonGroup:()=>b.ButtonGroup,Card:()=>w.Card,CardAi:()=>g.CardAi,CardV2:()=>f.CardV2,ChatMessage:()=>C.ChatMessage,Checkbox:()=>x.Checkbox,CheckboxGroup:()=>S.CheckboxGroup,Chip:()=>$.Chip,Coachmark:()=>k.Coachmark,CoachmarkPopover:()=>E.CoachmarkPopover,CodeEditor:()=>P,ComboBox:()=>R.ComboBox,CompositeAvatar:()=>u.CompositeAvatar,DatePicker:()=>B.DatePicker,DatePickerCalendar:()=>z.DatePickerCalendar,DatePickerDay:()=>V.DatePickerDay,DatePickerMonth:()=>j.DatePickerMonth,DatePickerWeek:()=>N.DatePickerWeek,DateRangePicker:()=>_.DateRangePicker,DateTimePicker:()=>F.DateTimePicker,Draggable:()=>U.Draggable,DraggableItem:()=>q.DraggableItem,Dropdown:()=>H.Dropdown,EditableTextfield:()=>K.EditableTextfield,Favorite:()=>W.Favorite,FloatingMinimizedModal:()=>G.FloatingMinimizedModal,FloatingModal:()=>Y.FloatingModal,Form:()=>X.Form,Grabber:()=>Q.Grabber,HelpText:()=>Z.HelpText,Icon:()=>p.Icon,Input:()=>ee.Input,InputFile:()=>J.InputFile,Label:()=>te.Label,Link:()=>ie.Link,List:()=>se.List,ListItem:()=>oe.ListItem,Loading:()=>re.Loading,MeetingAlert:()=>ne.MeetingAlert,Menu:()=>le.Menu,MenuItem:()=>de.MenuItem,MenuOverlay:()=>ae.MenuOverlay,Modal:()=>he.Modal,Pagination:()=>pe.Pagination,PhoneInput:()=>ce.PhoneInput,Popover:()=>ue.Popover,ProgressBar:()=>me.ProgressBar,Radio:()=>ye.Radio,RadioGroup:()=>be.RadioGroup,Slider:()=>ve.Slider,Spinner:()=>ge.Spinner,Tab:()=>Ce.Tab,TabPanel:()=>xe.TabPanel,Table:()=>we.Table,TableAdvanced:()=>fe.TableAdvanced,Tabs:()=>Se.Tabs,TaskItem:()=>$e.TaskItem,Theme:()=>Ee.Theme,ThemeManager:()=>Oe.ThemeManager,TimePicker:()=>ke.TimePicker,ToggleSwitch:()=>Te.ToggleSwitch,Tooltip:()=>Ie.Tooltip,iconUrlManager:()=>Ae.O,themeManager:()=>Oe.themeManager});var s=i(33328),o=i(6779),r=i(94891),n=i(28307),a=i(19479),l=i(74896),d=i(23779),h=i(38028),p=i(61200);const c=["bot","group","self","typing","channel-chat","channel-sms-inbound","channel-sms-outbound","channel-email-inbound","channel-email-outbound","channel-call","channel-social","channel-callback","channel-headset","channel-campaign","channel-emoji","channel-webex","channel-fb-messenger","channel-apple-chat","channel-line","channel-twitter-x","channel-viber","channel-whats-app","channel-we-chat","channel-spam","channel-custom",""];var u=i(2207),m=i(63704),y=i(92992),b=i(45629),v=i(96798),g=i(64311),f=i(90827),w=i(10654),C=i(95281),x=i(3664),S=i(55294),$=i(60046),E=i(29895),k=i(46312),T=i(3001),I=i(26272),A=i(45001),O=i.n(A),L=i(41488);const M=L.css`:host(md-code-editor) .md-code-editor{background:#091e26;border-radius:.25rem;color:#fff;min-height:18.75rem;overflow:hidden}:host(md-code-editor) .md-code-editor-header{align-content:center;align-items:center;display:flex;flex-flow:row nowrap;justify-content:space-between;align-items:center;background:#092d3b;flex:0 0 auto;font-size:14px;padding:.625rem}:host(md-code-editor) .md-code-editor-name{align-content:center;align-items:center;display:flex;flex-flow:row nowrap;justify-content:center}:host(md-code-editor) .md-code-editor md-badge::part(badge){border-radius:.25rem;height:1.25rem;margin-right:.625rem;padding:.25rem .375rem;text-transform:capitalize}:host(md-code-editor) .md-code-editor-copy{align-content:center;align-items:center;display:flex;flex-flow:row nowrap;justify-content:center;line-height:1}:host(md-code-editor) .md-code-editor-copy-btn::part(button){background:0 0;color:#00a0d1;margin-left:.625rem}:host(md-code-editor) .md-code-editor-copy-btn[disabled]{cursor:not-allowed;opacity:.5}:host(md-code-editor) .hljs-comment,:host(md-code-editor) .hljs-quote{color:#ffecc2}:host(md-code-editor) .hljs-deletion,:host(md-code-editor) .hljs-name,:host(md-code-editor) .hljs-regexp,:host(md-code-editor) .hljs-selector-class,:host(md-code-editor) .hljs-selector-id,:host(md-code-editor) .hljs-tag,:host(md-code-editor) .hljs-template-variable,:host(md-code-editor) .hljs-variable{color:#ff9d52}:host(md-code-editor) .hljs-built_in,:host(md-code-editor) .hljs-builtin-name,:host(md-code-editor) .hljs-link,:host(md-code-editor) .hljs-literal,:host(md-code-editor) .hljs-meta,:host(md-code-editor) .hljs-number,:host(md-code-editor) .hljs-params,:host(md-code-editor) .hljs-type{color:#fc9d03}:host(md-code-editor) .hljs-attribute{color:#ebd460}:host(md-code-editor) .hljs-addition,:host(md-code-editor) .hljs-bullet,:host(md-code-editor) .hljs-string,:host(md-code-editor) .hljs-symbol{color:#93c437}:host(md-code-editor) .hljs-section,:host(md-code-editor) .hljs-title{color:#22c7d6}:host(md-code-editor) .hljs-keyword,:host(md-code-editor) .hljs-selector-tag{color:#f0e3fc}:host(md-code-editor) .hljs{background:rgba(0,0,0,0);color:#dedede;display:block;overflow-x:auto;padding:.5em}:host(md-code-editor) .hljs-emphasis{font-style:italic}:host(md-code-editor) .hljs-strong{font-weight:700}@media screen and (forced-colors:active){:host(md-code-editor) .hljs-addition,:host(md-code-editor) .hljs-attribute,:host(md-code-editor) .hljs-built_in,:host(md-code-editor) .hljs-builtin-name,:host(md-code-editor) .hljs-bullet,:host(md-code-editor) .hljs-comment,:host(md-code-editor) .hljs-link,:host(md-code-editor) .hljs-literal,:host(md-code-editor) .hljs-meta,:host(md-code-editor) .hljs-number,:host(md-code-editor) .hljs-params,:host(md-code-editor) .hljs-quote,:host(md-code-editor) .hljs-string,:host(md-code-editor) .hljs-symbol,:host(md-code-editor) .hljs-type{color:highlight}:host(md-code-editor) .hljs-keyword,:host(md-code-editor) .hljs-selector-tag{font-weight:700}}@media(forced-colors:active){:host(md-code-editor) .md-code-editor{outline:1px solid CanvasText}:host(md-code-editor) .md-code-editor-header{outline:1px solid CanvasText}}`;var P,D=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends L.LitElement{constructor(){super(...arguments),this.copyLocalization="cURL",this.copiedLocalization="Copied",this.method="get",this.acceptLanguage="javascript",this.url="javascript",this.disableCopyButton=!0,this.acceptTypes="",this.copied=!1}static get styles(){return[I.A,M]}handleSlotChange(){if(this.slotNodes&&this.slotNodes.length){const e=this.slotNodes.find((e=>"CODE"===e.tagName));if(e){const t=e.textContent;t&&this.highlightBlock(t)}}}handleUrlSlotChange(){if(this.copied=!1,this.slotUrl&&this.slotUrl.length){const e=this.slotUrl.find((e=>e));if(e){const t=e.textContent;t&&this.copyUrl(t)}}}highlightBlock(e){e&&(this.codeBlock.innerText=e),O().highlightElement(this.codeBlock)}copyUrl(e){this.codeUrl.innerText=e,this.disableCopyButton=!1}copyClipboard(){this.disableCopyButton||this.selectTarget(this.codeUrl)}copyText(){try{document.execCommand("copy"),this.copied=!0}catch(e){console.warn("Copy text failed"),this.copied=!1}}select(e){const t=window.getSelection(),i=document.createRange();i.selectNodeContents(e),t&&(t.removeAllRanges(),t.addRange(i))}selectTarget(e){this.select(e),this.copyText()}importLanguage(e){return t=this,s=void 0,r=function*(){try{const{default:t}=yield i(29599)(`./${e}`);O().registerLanguage(`${e}`,t),this.setAcceptTypes()}catch(e){console.warn("Please set correct language name")}},new((o=void 0)||(o=Promise))((function(e,i){function n(e){try{l(r.next(e))}catch(e){i(e)}}function a(e){try{l(r.throw(e))}catch(e){i(e)}}function l(t){var i;t.done?e(t.value):(i=t.value,i instanceof o?i:new o((function(e){e(i)}))).then(n,a)}l((r=r.apply(t,s||[])).next())}));var t,s,o,r}getAllAcceptTypes(){const e=O().listLanguages();return e.length?e.map((e=>O().getLanguage(`${e}`).aliases)).map((e=>e.map((e=>`.${e}`)))).join(","):""}setAcceptTypes(){this.acceptTypes=this.getAllAcceptTypes()}updated(e){super.updated(e),e.has("acceptLanguage")&&this.importLanguage(this.acceptLanguage),e.has("acceptTypes")&&this.highlightBlock()}render(){return L.html`
|
|
2643
2646
|
<div class="md-code-editor" part="code-editor">
|
|
2644
2647
|
<div class="md-code-editor-header">
|
|
2645
2648
|
<div class="md-code-editor-name">
|
|
@@ -2672,7 +2675,7 @@
|
|
|
2672
2675
|
</pre>
|
|
2673
2676
|
</div>
|
|
2674
2677
|
</div>
|
|
2675
|
-
`}};D([(0,L.property)({type:String})],t.prototype,"copyLocalization",void 0),D([(0,L.property)({type:String})],t.prototype,"copiedLocalization",void 0),D([(0,L.property)({type:String})],t.prototype,"method",void 0),D([(0,L.property)({type:String,attribute:"accept-language"})],t.prototype,"acceptLanguage",void 0),D([(0,L.property)({type:String})],t.prototype,"url",void 0),D([(0,L.query)("input[type='file']")],t.prototype,"input",void 0),D([(0,L.query)(".md-code-editor-code-block")],t.prototype,"codeBlock",void 0),D([(0,L.query)(".md-code-editor-url")],t.prototype,"codeUrl",void 0),D([(0,L.internalProperty)()],t.prototype,"disableCopyButton",void 0),D([(0,L.internalProperty)()],t.prototype,"acceptTypes",void 0),D([(0,L.internalProperty)()],t.prototype,"copied",void 0),D([(0,L.queryAssignedNodes)("code-block")],t.prototype,"slotNodes",void 0),D([(0,L.queryAssignedNodes)("code-url")],t.prototype,"slotUrl",void 0),t=D([(0,T.wW)("md-code-editor")],t),e.ELEMENT=t}(P||(P={}));var R=i(4928),_=i(69494),F=i(85416),B=i(38654),z=i(63208),V=i(16754),j=i(17814),N=i(10984),U=i(80072),q=i(24627),H=i(23184),K=i(50565),W=i(99850),G=i(58871),Y=i(73093),X=i(97866),Q=i(69112),Z=i(20109),J=i(52619),ee=i(96408),te=i(6396),ie=i(19026),se=i(68490),oe=i(66245),re=i(69788),ne=i(61997),ae=i(11323),le=i(84032),de=i(48171),he=i(32252),
|
|
2678
|
+
`}};D([(0,L.property)({type:String})],t.prototype,"copyLocalization",void 0),D([(0,L.property)({type:String})],t.prototype,"copiedLocalization",void 0),D([(0,L.property)({type:String})],t.prototype,"method",void 0),D([(0,L.property)({type:String,attribute:"accept-language"})],t.prototype,"acceptLanguage",void 0),D([(0,L.property)({type:String})],t.prototype,"url",void 0),D([(0,L.query)("input[type='file']")],t.prototype,"input",void 0),D([(0,L.query)(".md-code-editor-code-block")],t.prototype,"codeBlock",void 0),D([(0,L.query)(".md-code-editor-url")],t.prototype,"codeUrl",void 0),D([(0,L.internalProperty)()],t.prototype,"disableCopyButton",void 0),D([(0,L.internalProperty)()],t.prototype,"acceptTypes",void 0),D([(0,L.internalProperty)()],t.prototype,"copied",void 0),D([(0,L.queryAssignedNodes)("code-block")],t.prototype,"slotNodes",void 0),D([(0,L.queryAssignedNodes)("code-url")],t.prototype,"slotUrl",void 0),t=D([(0,T.wW)("md-code-editor")],t),e.ELEMENT=t}(P||(P={}));var R=i(4928),_=i(69494),F=i(85416),B=i(38654),z=i(63208),V=i(16754),j=i(17814),N=i(10984),U=i(80072),q=i(24627),H=i(23184),K=i(50565),W=i(99850),G=i(58871),Y=i(73093),X=i(97866),Q=i(69112),Z=i(20109),J=i(52619),ee=i(96408),te=i(6396),ie=i(19026),se=i(68490),oe=i(66245),re=i(69788),ne=i(61997),ae=i(11323),le=i(84032),de=i(48171),he=i(32252),pe=i(23026),ce=i(84205),ue=i(71128),me=i(58287),ye=i(81144),be=i(32217),ve=i(25428),ge=i(12176),fe=i(77935),we=i(40428),Ce=i(16643),xe=i(97737),Se=i(50226),$e=i(86610),Ee=i(1072),ke=i(49256),Te=i(20331),Ie=i(83192),Ae=i(81786),Oe=i(37719)},99850:(e,t,i)=>{i.d(t,{Favorite:()=>s}),i(61200);var s,o=i(90195),r=i(3001),n=i(31890),a=i(26272),l=i(41488),d=i(23968),h=i(97822),p=i(27092),c=function(e,t,i,s){var o,r=arguments.length,n=r<3?t:null===s?s=Object.getOwnPropertyDescriptor(t,i):s;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)n=Reflect.decorate(e,t,i,s);else for(var a=e.length-1;a>=0;a--)(o=e[a])&&(n=(r<3?o(n):r>3?o(t,i,n):o(t,i))||n);return r>3&&n&&Object.defineProperty(t,i,n),n};!function(e){let t=class extends((0,r.yC)(l.LitElement)){constructor(){super(...arguments),this.disabled=!1,this.checked=!1,this.value="Select favorite",this.id="",this.label="Favorite",this.customId=""}connectedCallback(){super.connectedCallback(),this.addEventListener("keydown",this.handleElectKeyDown),this.addEventListener("click",this.handleFavorite)}static get styles(){return[a.A,p.A]}handleFavorite(){this.disabled||(this.checked=!this.checked,this.dispatchEvent(new CustomEvent("favorite-toggle",{detail:{active:this.checked,value:this.value},bubbles:!0,composed:!0})))}handleElectKeyDown(e){e.code!==o.Uz.Enter&&e.code!==o.Uz.Space||(this.checked=!this.checked,this.dispatchEvent(new CustomEvent("favorite-keydown",{detail:{active:this.checked,value:this.value},bubbles:!0,composed:!0})))}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this.handleElectKeyDown),this.removeEventListener("click",this.handleFavorite)}get favoriteClassMap(){return{"md-favorite--active":this.checked,"md-favorite--disabled":this.disabled}}render(){return l.html`
|
|
2676
2679
|
<label
|
|
2677
2680
|
for="favorite-checkbox"
|
|
2678
2681
|
id="${this.id}"
|
|
@@ -2694,4 +2697,4 @@
|
|
|
2694
2697
|
size="16"
|
|
2695
2698
|
></md-icon>
|
|
2696
2699
|
</label>
|
|
2697
|
-
`}};
|
|
2700
|
+
`}};c([(0,l.property)({type:Boolean})],t.prototype,"disabled",void 0),c([(0,l.property)({type:Boolean})],t.prototype,"checked",void 0),c([(0,l.property)({type:String})],t.prototype,"value",void 0),c([(0,l.property)({type:String})],t.prototype,"id",void 0),c([(0,l.property)({type:String})],t.prototype,"label",void 0),c([(0,l.internalProperty)()],t.prototype,"customId",void 0),t=c([(0,n.w)("md-favorite")],t),e.ELEMENT=t}(s||(s={}))}},j={};function N(e){var t=j[e];if(void 0!==t)return t.exports;var i=j[e]={exports:{}};return V[e].call(i.exports,i,i.exports,N),i.exports}N.m=V,R=[],N.O=(e,t,i,s)=>{if(!t){var o=1/0;for(l=0;l<R.length;l++){for(var[t,i,s]=R[l],r=!0,n=0;n<t.length;n++)(!1&s||o>=s)&&Object.keys(N.O).every((e=>N.O[e](t[n])))?t.splice(n--,1):(r=!1,s<o&&(o=s));if(r){R.splice(l--,1);var a=i();void 0!==a&&(e=a)}}return e}s=s||0;for(var l=R.length;l>0&&R[l-1][2]>s;l--)R[l]=R[l-1];R[l]=[t,i,s]},N.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return N.d(t,{a:t}),t},F=Object.getPrototypeOf?e=>Object.getPrototypeOf(e):e=>e.__proto__,N.t=function(e,t){if(1&t&&(e=this(e)),8&t)return e;if("object"==typeof e&&e){if(4&t&&e.__esModule)return e;if(16&t&&"function"==typeof e.then)return e}var i=Object.create(null);N.r(i);var s={};_=_||[null,F({}),F([]),F(F)];for(var o=2&t&&e;"object"==typeof o&&!~_.indexOf(o);o=F(o))Object.getOwnPropertyNames(o).forEach((t=>s[t]=()=>e[t]));return s.default=()=>e,N.d(i,s),i},N.d=(e,t)=>{for(var i in t)N.o(t,i)&&!N.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},N.f={},N.e=e=>Promise.all(Object.keys(N.f).reduce(((t,i)=>(N.f[i](e,t),t)),[])),N.u=e=>"chunks/md-"+e+".js",N.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),N.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),B={},z="@momentum-ui/web-components:",N.l=(e,t,i,s)=>{if(B[e])B[e].push(t);else{var o,r;if(void 0!==i)for(var n=document.getElementsByTagName("script"),a=0;a<n.length;a++){var l=n[a];if(l.getAttribute("src")==e||l.getAttribute("data-webpack")==z+i){o=l;break}}o||(r=!0,(o=document.createElement("script")).charset="utf-8",o.timeout=120,N.nc&&o.setAttribute("nonce",N.nc),o.setAttribute("data-webpack",z+i),o.src=e),B[e]=[t];var d=(t,i)=>{o.onerror=o.onload=null,clearTimeout(h);var s=B[e];if(delete B[e],o.parentNode&&o.parentNode.removeChild(o),s&&s.forEach((e=>e(i))),t)return t(i)},h=setTimeout(d.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=d.bind(null,o.onerror),o.onload=d.bind(null,o.onload),r&&document.head.appendChild(o)}},N.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},N.p="/",(()=>{var e={109:0,144:0,195:0,445:0,502:0,555:0,671:0,762:0,984:0,1037:0,1200:0,1266:0,1323:0,1439:0,1459:0,1462:0,1521:0,1528:0,1682:0,1745:0,1788:0,1807:0,2105:0,2139:0,2169:0,2176:0,2330:0,2434:0,2547:0,2576:0,2779:0,2909:0,3001:0,3079:0,3192:0,3413:0,3539:0,3747:0,3938:0,3943:0,4131:0,4139:0,4259:0,4545:0,4908:0,4928:0,4971:0,5156:0,5310:0,5369:0,5382:0,5433:0,5517:0,6029:0,6060:0,6085:0,6132:0,6220:0,6396:0,6408:0,6433:0,6494:0,6587:0,6652:0,6677:0,6724:0,6754:0,6798:0,6834:0,6920:0,7219:0,7455:0,7684:0,7711:0,7719:0,7763:0,7814:0,7927:0,8028:0,8111:0,8115:0,8220:0,8334:0,8339:0,8442:0,8510:0,8654:0,8894:0,9058:0,9237:0,9788:0};N.f.j=(t,i)=>{var s=N.o(e,t)?e[t]:void 0;if(0!==s)if(s)i.push(s[2]);else{var o=new Promise(((i,o)=>s=e[t]=[i,o]));i.push(s[2]=o);var r=N.p+N.u(t),n=new Error;N.l(r,(i=>{if(N.o(e,t)&&(0!==(s=e[t])&&(e[t]=void 0),s)){var o=i&&("load"===i.type?"missing":i.type),r=i&&i.target&&i.target.src;n.message="Loading chunk "+t+" failed.\n("+o+": "+r+")",n.name="ChunkLoadError",n.type=o,n.request=r,s[1](n)}}),"chunk-"+t,t)}},N.O.j=t=>0===e[t];var t=(t,i)=>{var s,o,[r,n,a]=i,l=0;if(r.some((t=>0!==e[t]))){for(s in n)N.o(n,s)&&(N.m[s]=n[s]);if(a)var d=a(N)}for(t&&t(i);l<r.length;l++)o=r[l],N.o(e,o)&&e[o]&&e[o][0](),e[o]=0;return N.O(d)},i=self["momentum-web-components-[id]"]=self["momentum-web-components-[id]"]||[];i.forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i))})();var U=N.O(void 0,[4367,7103,1890,6272,6325,6283,9217,5830,8889,8210,3135,1598,4977,1572,6366,7251,4974,2243,3553,4548,6700,6795,76,528,1392,9164,2019,1625,3625,6067,8841,4663,3112,3866,1107,7330,7092,9719,6979,9130,6273,9618,8521,4400,779,573,5801,2043,8171,2798,182,2984,7919,1869,2215,5467,4392,630,3604,7833,8728,8227,1250,1705,7997,7875,6400,587,6441,6015,3663],(()=>N(99687)));return N.O(U)})()));
|