@leavittsoftware/web 8.7.2 → 8.7.3
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/leavitt/api-service/HttpError.d.ts +11 -0
- package/leavitt/api-service/HttpError.js +2 -0
- package/leavitt/api-service/HttpError.js.map +1 -0
- package/leavitt/api-service/api-service.d.ts +52 -0
- package/leavitt/api-service/api-service.js +369 -0
- package/leavitt/api-service/api-service.js.map +1 -0
- package/leavitt/api-service/authenticated-token-provider.d.ts +5 -0
- package/leavitt/api-service/authenticated-token-provider.js +7 -0
- package/leavitt/api-service/authenticated-token-provider.js.map +1 -0
- package/leavitt/api-service/bearer-token-provider.d.ts +4 -0
- package/leavitt/api-service/bearer-token-provider.js +2 -0
- package/leavitt/api-service/bearer-token-provider.js.map +1 -0
- package/leavitt/api-service/blob-response.d.ts +8 -0
- package/leavitt/api-service/blob-response.js +8 -0
- package/leavitt/api-service/blob-response.js.map +1 -0
- package/leavitt/api-service/no-authentication-token-provider.d.ts +5 -0
- package/leavitt/api-service/no-authentication-token-provider.js +6 -0
- package/leavitt/api-service/no-authentication-token-provider.js.map +1 -0
- package/leavitt/api-service/object-to-form-data.d.ts +9 -0
- package/leavitt/api-service/object-to-form-data.js +42 -0
- package/leavitt/api-service/object-to-form-data.js.map +1 -0
- package/leavitt/api-service/object-to-form-data.test.d.ts +2 -0
- package/leavitt/api-service/object-to-form-data.test.js +229 -0
- package/leavitt/api-service/object-to-form-data.test.js.map +1 -0
- package/leavitt/api-service/odata-dto.d.ts +6 -0
- package/leavitt/api-service/odata-dto.js +7 -0
- package/leavitt/api-service/odata-dto.js.map +1 -0
- package/leavitt/api-service/odata-model-info.d.ts +5 -0
- package/leavitt/api-service/odata-model-info.js +7 -0
- package/leavitt/api-service/odata-model-info.js.map +1 -0
- package/leavitt/api-service/odata-response.d.ts +15 -0
- package/leavitt/api-service/odata-response.js +50 -0
- package/leavitt/api-service/odata-response.js.map +1 -0
- package/leavitt/api-service/status-codes.d.ts +2 -0
- package/leavitt/api-service/status-codes.js +44 -0
- package/leavitt/api-service/status-codes.js.map +1 -0
- package/leavitt/app/app-logo.d.ts +12 -0
- package/leavitt/app/app-logo.js +142 -0
- package/leavitt/app/app-logo.js.map +1 -0
- package/leavitt/app/app-main-content-container.d.ts +10 -0
- package/leavitt/app/app-main-content-container.js +65 -0
- package/leavitt/app/app-main-content-container.js.map +1 -0
- package/leavitt/app/app-navigation-footer.d.ts +18 -0
- package/leavitt/app/app-navigation-footer.js +142 -0
- package/leavitt/app/app-navigation-footer.js.map +1 -0
- package/leavitt/app/app-navigation-header.d.ts +22 -0
- package/leavitt/app/app-navigation-header.js +239 -0
- package/leavitt/app/app-navigation-header.js.map +1 -0
- package/leavitt/app/app-width-limiter.d.ts +7 -0
- package/leavitt/app/app-width-limiter.js +39 -0
- package/leavitt/app/app-width-limiter.js.map +1 -0
- package/leavitt/app/contexts/main-menu-position-context.d.ts +4 -0
- package/leavitt/app/contexts/main-menu-position-context.js +3 -0
- package/leavitt/app/contexts/main-menu-position-context.js.map +1 -0
- package/leavitt/company-select/company-select.d.ts +53 -0
- package/leavitt/company-select/company-select.js +181 -0
- package/leavitt/company-select/company-select.js.map +1 -0
- package/leavitt/email-history-viewer/email-history-view-list-filter-dialog.d.ts +394 -0
- package/leavitt/email-history-viewer/email-history-view-list-filter-dialog.js +233 -0
- package/leavitt/email-history-viewer/email-history-view-list-filter-dialog.js.map +1 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled-filter-dialog.d.ts +397 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled-filter-dialog.js +244 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled-filter-dialog.js.map +1 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled.d.ts +408 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled.js +381 -0
- package/leavitt/email-history-viewer/email-history-viewer-filled.js.map +1 -0
- package/leavitt/email-history-viewer/email-history-viewer.d.ts +412 -0
- package/leavitt/email-history-viewer/email-history-viewer.js +373 -0
- package/leavitt/email-history-viewer/email-history-viewer.js.map +1 -0
- package/leavitt/email-history-viewer/view-email-template-info-dialog.d.ts +386 -0
- package/leavitt/email-history-viewer/view-email-template-info-dialog.js +154 -0
- package/leavitt/email-history-viewer/view-email-template-info-dialog.js.map +1 -0
- package/leavitt/email-history-viewer/view-sent-email-dialog.d.ts +388 -0
- package/leavitt/email-history-viewer/view-sent-email-dialog.js +145 -0
- package/leavitt/email-history-viewer/view-sent-email-dialog.js.map +1 -0
- package/leavitt/error-page/error-page.d.ts +24 -0
- package/leavitt/error-page/error-page.js +185 -0
- package/leavitt/error-page/error-page.js.map +1 -0
- package/leavitt/file-explorer/add-folder-modal.d.ts +390 -0
- package/leavitt/file-explorer/add-folder-modal.js +135 -0
- package/leavitt/file-explorer/add-folder-modal.js.map +1 -0
- package/leavitt/file-explorer/events/file-explorer-events.d.ts +4 -0
- package/leavitt/file-explorer/events/file-explorer-events.js +5 -0
- package/leavitt/file-explorer/events/file-explorer-events.js.map +1 -0
- package/leavitt/file-explorer/file-explorer-error.d.ts +7 -0
- package/leavitt/file-explorer/file-explorer-error.js +38 -0
- package/leavitt/file-explorer/file-explorer-error.js.map +1 -0
- package/leavitt/file-explorer/file-explorer-image.d.ts +9 -0
- package/leavitt/file-explorer/file-explorer-image.js +54 -0
- package/leavitt/file-explorer/file-explorer-image.js.map +1 -0
- package/leavitt/file-explorer/file-explorer-no-files.d.ts +7 -0
- package/leavitt/file-explorer/file-explorer-no-files.js +38 -0
- package/leavitt/file-explorer/file-explorer-no-files.js.map +1 -0
- package/leavitt/file-explorer/file-explorer-no-permission.d.ts +7 -0
- package/leavitt/file-explorer/file-explorer-no-permission.js +38 -0
- package/leavitt/file-explorer/file-explorer-no-permission.js.map +1 -0
- package/leavitt/file-explorer/file-explorer.d.ts +446 -0
- package/leavitt/file-explorer/file-explorer.js +889 -0
- package/leavitt/file-explorer/file-explorer.js.map +1 -0
- package/leavitt/file-explorer/file-list-item.d.ts +16 -0
- package/leavitt/file-explorer/file-list-item.js +300 -0
- package/leavitt/file-explorer/file-list-item.js.map +1 -0
- package/leavitt/file-explorer/file-modal.d.ts +393 -0
- package/leavitt/file-explorer/file-modal.js +323 -0
- package/leavitt/file-explorer/file-modal.js.map +1 -0
- package/leavitt/file-explorer/folder-list-item.d.ts +15 -0
- package/leavitt/file-explorer/folder-list-item.js +210 -0
- package/leavitt/file-explorer/folder-list-item.js.map +1 -0
- package/leavitt/file-explorer/folder-modal.d.ts +391 -0
- package/leavitt/file-explorer/folder-modal.js +226 -0
- package/leavitt/file-explorer/folder-modal.js.map +1 -0
- package/leavitt/file-explorer/helpers/file-types.d.ts +2 -0
- package/leavitt/file-explorer/helpers/file-types.js +19 -0
- package/leavitt/file-explorer/helpers/file-types.js.map +1 -0
- package/leavitt/file-explorer/helpers/format-bytes.d.ts +2 -0
- package/leavitt/file-explorer/helpers/format-bytes.js +8 -0
- package/leavitt/file-explorer/helpers/format-bytes.js.map +1 -0
- package/leavitt/person-company-select/person-company-select.d.ts +43 -0
- package/leavitt/person-company-select/person-company-select.js +198 -0
- package/leavitt/person-company-select/person-company-select.js.map +1 -0
- package/leavitt/person-group-select/people-group-icons.d.ts +5 -0
- package/leavitt/person-group-select/people-group-icons.js +87 -0
- package/leavitt/person-group-select/people-group-icons.js.map +1 -0
- package/leavitt/person-group-select/person-group-select.d.ts +43 -0
- package/leavitt/person-group-select/person-group-select.js +207 -0
- package/leavitt/person-group-select/person-group-select.js.map +1 -0
- package/leavitt/person-select/person-select.d.ts +46 -0
- package/leavitt/person-select/person-select.js +203 -0
- package/leavitt/person-select/person-select.js.map +1 -0
- package/leavitt/profile-picture/profile-picture-menu.d.ts +48 -0
- package/leavitt/profile-picture/profile-picture-menu.js +248 -0
- package/leavitt/profile-picture/profile-picture-menu.js.map +1 -0
- package/leavitt/profile-picture/profile-picture.d.ts +44 -0
- package/leavitt/profile-picture/profile-picture.js +208 -0
- package/leavitt/profile-picture/profile-picture.js.map +1 -0
- package/leavitt/service-worker-notifier/service-worker-notifier.d.ts +14 -0
- package/leavitt/service-worker-notifier/service-worker-notifier.js +180 -0
- package/leavitt/service-worker-notifier/service-worker-notifier.js.map +1 -0
- package/leavitt/theme/theme-preference-event.d.ts +4 -0
- package/leavitt/theme/theme-preference-event.js +5 -0
- package/leavitt/theme/theme-preference-event.js.map +1 -0
- package/leavitt/theme/theme-preference.d.ts +8 -0
- package/leavitt/theme/theme-preference.js +26 -0
- package/leavitt/theme/theme-preference.js.map +1 -0
- package/leavitt/user-feedback/provide-feedback-dialog.d.ts +386 -0
- package/leavitt/user-feedback/provide-feedback-dialog.js +150 -0
- package/leavitt/user-feedback/provide-feedback-dialog.js.map +1 -0
- package/leavitt/user-feedback/report-a-problem-dialog.d.ts +388 -0
- package/leavitt/user-feedback/report-a-problem-dialog.js +170 -0
- package/leavitt/user-feedback/report-a-problem-dialog.js.map +1 -0
- package/leavitt/user-feedback/user-feedback.d.ts +390 -0
- package/leavitt/user-feedback/user-feedback.js +222 -0
- package/leavitt/user-feedback/user-feedback.js.map +1 -0
- package/leavitt/user-manager/LssJwtToken.d.ts +24 -0
- package/leavitt/user-manager/LssJwtToken.js +2 -0
- package/leavitt/user-manager/LssJwtToken.js.map +1 -0
- package/leavitt/user-manager/auth-zero-lg-access-token.d.ts +15 -0
- package/leavitt/user-manager/auth-zero-lg-access-token.js +2 -0
- package/leavitt/user-manager/auth-zero-lg-access-token.js.map +1 -0
- package/leavitt/user-manager/auth-zero-lg-identity-token.d.ts +24 -0
- package/leavitt/user-manager/auth-zero-lg-identity-token.js +2 -0
- package/leavitt/user-manager/auth-zero-lg-identity-token.js.map +1 -0
- package/leavitt/user-manager/auth-zero-lg-identity.d.ts +24 -0
- package/leavitt/user-manager/auth-zero-lg-identity.js +2 -0
- package/leavitt/user-manager/auth-zero-lg-identity.js.map +1 -0
- package/leavitt/user-manager/auth-zero-lg-user-manager.d.ts +18 -0
- package/leavitt/user-manager/auth-zero-lg-user-manager.js +382 -0
- package/leavitt/user-manager/auth-zero-lg-user-manager.js.map +1 -0
- package/leavitt/user-manager/user-manager-events.d.ts +5 -0
- package/leavitt/user-manager/user-manager-events.js +7 -0
- package/leavitt/user-manager/user-manager-events.js.map +1 -0
- package/leavitt/user-manager/user-manager.d.ts +47 -0
- package/leavitt/user-manager/user-manager.js +443 -0
- package/leavitt/user-manager/user-manager.js.map +1 -0
- package/package.json +2 -2
- package/titanium/access-denied-page/access-denied-page.d.ts +16 -0
- package/titanium/access-denied-page/access-denied-page.js +359 -0
- package/titanium/access-denied-page/access-denied-page.js.map +1 -0
- package/titanium/address-input/address-input.d.ts +31 -0
- package/titanium/address-input/address-input.js +104 -0
- package/titanium/address-input/address-input.js.map +1 -0
- package/titanium/address-input/google-address-input.d.ts +35 -0
- package/titanium/address-input/google-address-input.js +242 -0
- package/titanium/address-input/google-address-input.js.map +1 -0
- package/titanium/address-input/manual-address-dialog.d.ts +39 -0
- package/titanium/address-input/manual-address-dialog.js +350 -0
- package/titanium/address-input/manual-address-dialog.js.map +1 -0
- package/titanium/address-input/types/address-input-address.d.ts +17 -0
- package/titanium/address-input/types/address-input-address.js +2 -0
- package/titanium/address-input/types/address-input-address.js.map +1 -0
- package/titanium/address-input/utils/address-to-string.d.ts +3 -0
- package/titanium/address-input/utils/address-to-string.js +26 -0
- package/titanium/address-input/utils/address-to-string.js.map +1 -0
- package/titanium/address-input/utils/place-result-to-address.d.ts +3 -0
- package/titanium/address-input/utils/place-result-to-address.js +46 -0
- package/titanium/address-input/utils/place-result-to-address.js.map +1 -0
- package/titanium/address-input/utils/validate-street.d.ts +2 -0
- package/titanium/address-input/utils/validate-street.js +8 -0
- package/titanium/address-input/utils/validate-street.js.map +1 -0
- package/titanium/card/card.d.ts +24 -0
- package/titanium/card/card.js +188 -0
- package/titanium/card/card.js.map +1 -0
- package/titanium/chip/chip.d.ts +57 -0
- package/titanium/chip/chip.js +289 -0
- package/titanium/chip/chip.js.map +1 -0
- package/titanium/chip-multi-select/chip-multi-select.d.ts +71 -0
- package/titanium/chip-multi-select/chip-multi-select.js +228 -0
- package/titanium/chip-multi-select/chip-multi-select.js.map +1 -0
- package/titanium/circle-loading-indicator/circle-loading-indicator.d.ts +19 -0
- package/titanium/circle-loading-indicator/circle-loading-indicator.js +122 -0
- package/titanium/circle-loading-indicator/circle-loading-indicator.js.map +1 -0
- package/titanium/collapsible-container/collapsible-container.d.ts +12 -0
- package/titanium/collapsible-container/collapsible-container.js +115 -0
- package/titanium/collapsible-container/collapsible-container.js.map +1 -0
- package/titanium/confirm-dialog/confirm-dialog-open-event.d.ts +10 -0
- package/titanium/confirm-dialog/confirm-dialog-open-event.js +12 -0
- package/titanium/confirm-dialog/confirm-dialog-open-event.js.map +1 -0
- package/titanium/confirm-dialog/confirm-dialog.d.ts +25 -0
- package/titanium/confirm-dialog/confirm-dialog.js +104 -0
- package/titanium/confirm-dialog/confirm-dialog.js.map +1 -0
- package/titanium/confirmation-dialog/confirmation-dialog.d.ts +19 -0
- package/titanium/confirmation-dialog/confirmation-dialog.js +124 -0
- package/titanium/confirmation-dialog/confirmation-dialog.js.map +1 -0
- package/titanium/data-table/data-table-action-bar.d.ts +11 -0
- package/titanium/data-table/data-table-action-bar.js +216 -0
- package/titanium/data-table/data-table-action-bar.js.map +1 -0
- package/titanium/data-table/data-table-content-styles.d.ts +2 -0
- package/titanium/data-table/data-table-content-styles.js +48 -0
- package/titanium/data-table/data-table-content-styles.js.map +1 -0
- package/titanium/data-table/data-table-core-reorder-dialog.d.ts +391 -0
- package/titanium/data-table/data-table-core-reorder-dialog.js +170 -0
- package/titanium/data-table/data-table-core-reorder-dialog.js.map +1 -0
- package/titanium/data-table/data-table-core-reorder-item.d.ts +15 -0
- package/titanium/data-table/data-table-core-reorder-item.js +154 -0
- package/titanium/data-table/data-table-core-reorder-item.js.map +1 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-dialog.d.ts +22 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-dialog.js +164 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-dialog.js.map +1 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-item.d.ts +14 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-item.js +96 -0
- package/titanium/data-table/data-table-core-settings-choose-columns-item.js.map +1 -0
- package/titanium/data-table/data-table-core-settings-sort-dialog.d.ts +22 -0
- package/titanium/data-table/data-table-core-settings-sort-dialog.js +231 -0
- package/titanium/data-table/data-table-core-settings-sort-dialog.js.map +1 -0
- package/titanium/data-table/data-table-core-settings-sort-item.d.ts +17 -0
- package/titanium/data-table/data-table-core-settings-sort-item.js +171 -0
- package/titanium/data-table/data-table-core-settings-sort-item.js.map +1 -0
- package/titanium/data-table/data-table-core.d.ts +458 -0
- package/titanium/data-table/data-table-core.js +745 -0
- package/titanium/data-table/data-table-core.js.map +1 -0
- package/titanium/data-table/data-table-header.d.ts +68 -0
- package/titanium/data-table/data-table-header.js +295 -0
- package/titanium/data-table/data-table-header.js.map +1 -0
- package/titanium/data-table/data-table-item.d.ts +99 -0
- package/titanium/data-table/data-table-item.js +561 -0
- package/titanium/data-table/data-table-item.js.map +1 -0
- package/titanium/data-table/data-table.d.ts +127 -0
- package/titanium/data-table/data-table.js +688 -0
- package/titanium/data-table/data-table.js.map +1 -0
- package/titanium/data-table/draggable-item-base.d.ts +30 -0
- package/titanium/data-table/draggable-item-base.js +324 -0
- package/titanium/data-table/draggable-item-base.js.map +1 -0
- package/titanium/data-table/filter-controller.d.ts +24 -0
- package/titanium/data-table/filter-controller.js +122 -0
- package/titanium/data-table/filter-controller.js.map +1 -0
- package/titanium/data-table/filter.d.ts +8 -0
- package/titanium/data-table/filter.js +11 -0
- package/titanium/data-table/filter.js.map +1 -0
- package/titanium/data-table/page-control.d.ts +59 -0
- package/titanium/data-table/page-control.js +236 -0
- package/titanium/data-table/page-control.js.map +1 -0
- package/titanium/date-input/date-input.d.ts +149 -0
- package/titanium/date-input/date-input.js +548 -0
- package/titanium/date-input/date-input.js.map +1 -0
- package/titanium/date-range-selector/date-range-change-event.d.ts +8 -0
- package/titanium/date-range-selector/date-range-change-event.js +10 -0
- package/titanium/date-range-selector/date-range-change-event.js.map +1 -0
- package/titanium/date-range-selector/date-range-selector.d.ts +71 -0
- package/titanium/date-range-selector/date-range-selector.js +479 -0
- package/titanium/date-range-selector/date-range-selector.js.map +1 -0
- package/titanium/date-range-selector/types/date-range-key.d.ts +2 -0
- package/titanium/date-range-selector/types/date-range-key.js +2 -0
- package/titanium/date-range-selector/types/date-range-key.js.map +1 -0
- package/titanium/date-range-selector/types/date-range-option.d.ts +8 -0
- package/titanium/date-range-selector/types/date-range-option.js +2 -0
- package/titanium/date-range-selector/types/date-range-option.js.map +1 -0
- package/titanium/date-range-selector/types/date-ranges.d.ts +4 -0
- package/titanium/date-range-selector/types/date-ranges.js +133 -0
- package/titanium/date-range-selector/types/date-ranges.js.map +1 -0
- package/titanium/date-range-selector/types/range-label.d.ts +5 -0
- package/titanium/date-range-selector/types/range-label.js +25 -0
- package/titanium/date-range-selector/types/range-label.js.map +1 -0
- package/titanium/drawer/drawer.d.ts +52 -0
- package/titanium/drawer/drawer.js +417 -0
- package/titanium/drawer/drawer.js.map +1 -0
- package/titanium/duration-input/duration-input.d.ts +31 -0
- package/titanium/duration-input/duration-input.js +126 -0
- package/titanium/duration-input/duration-input.js.map +1 -0
- package/titanium/duration-input/filled-duration-input.d.ts +31 -0
- package/titanium/duration-input/filled-duration-input.js +123 -0
- package/titanium/duration-input/filled-duration-input.js.map +1 -0
- package/titanium/duration-input/human-interval.d.ts +19 -0
- package/titanium/duration-input/human-interval.js +73 -0
- package/titanium/duration-input/human-interval.js.map +1 -0
- package/titanium/duration-input/outlined-duration-input.d.ts +30 -0
- package/titanium/duration-input/outlined-duration-input.js +109 -0
- package/titanium/duration-input/outlined-duration-input.js.map +1 -0
- package/titanium/error-page/error-page.d.ts +16 -0
- package/titanium/error-page/error-page.js +95 -0
- package/titanium/error-page/error-page.js.map +1 -0
- package/titanium/event-bus/event-bus.d.ts +10 -0
- package/titanium/event-bus/event-bus.js +52 -0
- package/titanium/event-bus/event-bus.js.map +1 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.d.ts +168 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.js +373 -0
- package/titanium/extendable-outlined-text-field/extendable-outlined-text-field.js.map +1 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.d.ts +17 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.js +121 -0
- package/titanium/full-page-loading-indicator/full-page-loading-indicator.js.map +1 -0
- package/titanium/hacks/dialog-navigation-hack.d.ts +8 -0
- package/titanium/hacks/dialog-navigation-hack.js +22 -0
- package/titanium/hacks/dialog-navigation-hack.js.map +1 -0
- package/titanium/hacks/dialog-overflow-hacks.d.ts +4 -0
- package/titanium/hacks/dialog-overflow-hacks.js +21 -0
- package/titanium/hacks/dialog-overflow-hacks.js.map +1 -0
- package/titanium/hacks/dialog-zindex-hack.d.ts +11 -0
- package/titanium/hacks/dialog-zindex-hack.js +20 -0
- package/titanium/hacks/dialog-zindex-hack.js.map +1 -0
- package/titanium/hacks/report-validity-if-error.d.ts +4 -0
- package/titanium/hacks/report-validity-if-error.js +6 -0
- package/titanium/hacks/report-validity-if-error.js.map +1 -0
- package/titanium/header/header.d.ts +39 -0
- package/titanium/header/header.js +167 -0
- package/titanium/header/header.js.map +1 -0
- package/titanium/helpers/address/country-abbr-to-titlecase.d.ts +5 -0
- package/titanium/helpers/address/country-abbr-to-titlecase.js +243 -0
- package/titanium/helpers/address/country-abbr-to-titlecase.js.map +1 -0
- package/titanium/helpers/address/format-address.d.ts +22 -0
- package/titanium/helpers/address/format-address.js +33 -0
- package/titanium/helpers/address/format-address.js.map +1 -0
- package/titanium/helpers/address/get-country-name.d.ts +2 -0
- package/titanium/helpers/address/get-country-name.js +12 -0
- package/titanium/helpers/address/get-country-name.js.map +1 -0
- package/titanium/helpers/address/states-abbr-to-titlecase.d.ts +9 -0
- package/titanium/helpers/address/states-abbr-to-titlecase.js +117 -0
- package/titanium/helpers/address/states-abbr-to-titlecase.js.map +1 -0
- package/titanium/helpers/csv/convert-array-to-csv.d.ts +2 -0
- package/titanium/helpers/csv/convert-array-to-csv.js +35 -0
- package/titanium/helpers/csv/convert-array-to-csv.js.map +1 -0
- package/titanium/helpers/csv/flatten-object.d.ts +2 -0
- package/titanium/helpers/csv/flatten-object.js +64 -0
- package/titanium/helpers/csv/flatten-object.js.map +1 -0
- package/titanium/helpers/csv/start-csv-download.d.ts +2 -0
- package/titanium/helpers/csv/start-csv-download.js +11 -0
- package/titanium/helpers/csv/start-csv-download.js.map +1 -0
- package/titanium/helpers/debouncer.d.ts +13 -0
- package/titanium/helpers/debouncer.js +33 -0
- package/titanium/helpers/debouncer.js.map +1 -0
- package/titanium/helpers/delay.d.ts +2 -0
- package/titanium/helpers/delay.js +6 -0
- package/titanium/helpers/delay.js.map +1 -0
- package/titanium/helpers/escape-term.d.ts +2 -0
- package/titanium/helpers/escape-term.js +2 -0
- package/titanium/helpers/escape-term.js.map +1 -0
- package/titanium/helpers/find-scrollable-parent.d.ts +2 -0
- package/titanium/helpers/find-scrollable-parent.js +13 -0
- package/titanium/helpers/find-scrollable-parent.js.map +1 -0
- package/titanium/helpers/get-cdn-Inline-url.d.ts +4 -0
- package/titanium/helpers/get-cdn-Inline-url.js +27 -0
- package/titanium/helpers/get-cdn-Inline-url.js.map +1 -0
- package/titanium/helpers/get-cdn-download-url.d.ts +3 -0
- package/titanium/helpers/get-cdn-download-url.js +12 -0
- package/titanium/helpers/get-cdn-download-url.js.map +1 -0
- package/titanium/helpers/get-company-logo-url.d.ts +3 -0
- package/titanium/helpers/get-company-logo-url.js +6 -0
- package/titanium/helpers/get-company-logo-url.js.map +1 -0
- package/titanium/helpers/get-company-mark-url.d.ts +3 -0
- package/titanium/helpers/get-company-mark-url.js +6 -0
- package/titanium/helpers/get-company-mark-url.js.map +1 -0
- package/titanium/helpers/get-search-token.d.ts +2 -0
- package/titanium/helpers/get-search-token.js +17 -0
- package/titanium/helpers/get-search-token.js.map +1 -0
- package/titanium/helpers/group-by.d.ts +2 -0
- package/titanium/helpers/group-by.js +7 -0
- package/titanium/helpers/group-by.js.map +1 -0
- package/titanium/helpers/helpers.d.ts +15 -0
- package/titanium/helpers/helpers.js +15 -0
- package/titanium/helpers/helpers.js.map +1 -0
- package/titanium/helpers/install-media-query-watcher.d.ts +2 -0
- package/titanium/helpers/install-media-query-watcher.js +6 -0
- package/titanium/helpers/install-media-query-watcher.js.map +1 -0
- package/titanium/helpers/is-development.d.ts +3 -0
- package/titanium/helpers/is-development.js +12 -0
- package/titanium/helpers/is-development.js.map +1 -0
- package/titanium/helpers/join.d.ts +2 -0
- package/titanium/helpers/join.js +5 -0
- package/titanium/helpers/join.js.map +1 -0
- package/titanium/helpers/load-while.d.ts +374 -0
- package/titanium/helpers/load-while.js +28 -0
- package/titanium/helpers/load-while.js.map +1 -0
- package/titanium/helpers/middle-ellipsis.d.ts +2 -0
- package/titanium/helpers/middle-ellipsis.js +7 -0
- package/titanium/helpers/middle-ellipsis.js.map +1 -0
- package/titanium/helpers/not-null-or-undefined.d.ts +2 -0
- package/titanium/helpers/not-null-or-undefined.js +4 -0
- package/titanium/helpers/not-null-or-undefined.js.map +1 -0
- package/titanium/helpers/not-null.d.ts +2 -0
- package/titanium/helpers/not-null.js +4 -0
- package/titanium/helpers/not-null.js.map +1 -0
- package/titanium/helpers/not-undefined.d.ts +2 -0
- package/titanium/helpers/not-undefined.js +4 -0
- package/titanium/helpers/not-undefined.js.map +1 -0
- package/titanium/helpers/pending-state-catcher.d.ts +416 -0
- package/titanium/helpers/pending-state-catcher.js +88 -0
- package/titanium/helpers/pending-state-catcher.js.map +1 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dashes.d.ts +2 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dashes.js +9 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dashes.js.map +1 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dots.d.ts +2 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dots.js +9 -0
- package/titanium/helpers/phone-numbers/format-phone-number-dots.js.map +1 -0
- package/titanium/helpers/phone-numbers/format-phone-number-numbers-only.d.ts +2 -0
- package/titanium/helpers/phone-numbers/format-phone-number-numbers-only.js +9 -0
- package/titanium/helpers/phone-numbers/format-phone-number-numbers-only.js.map +1 -0
- package/titanium/helpers/phone-numbers/format-phone-number.d.ts +2 -0
- package/titanium/helpers/phone-numbers/format-phone-number.js +9 -0
- package/titanium/helpers/phone-numbers/format-phone-number.js.map +1 -0
- package/titanium/helpers/phone-numbers/phone-mask.d.ts +2 -0
- package/titanium/helpers/phone-numbers/phone-mask.js +5 -0
- package/titanium/helpers/phone-numbers/phone-mask.js.map +1 -0
- package/titanium/helpers/phone-numbers/try-format-phone-number.d.ts +2 -0
- package/titanium/helpers/phone-numbers/try-format-phone-number.js +9 -0
- package/titanium/helpers/phone-numbers/try-format-phone-number.js.map +1 -0
- package/titanium/icon-picker/icon-picker.d.ts +37 -0
- package/titanium/icon-picker/icon-picker.js +160 -0
- package/titanium/icon-picker/icon-picker.js.map +1 -0
- package/titanium/icon-picker/material-symbols.d.ts +3 -0
- package/titanium/icon-picker/material-symbols.js +3297 -0
- package/titanium/icon-picker/material-symbols.js.map +1 -0
- package/titanium/input-validator/filled-input-validator.d.ts +20 -0
- package/titanium/input-validator/filled-input-validator.js +48 -0
- package/titanium/input-validator/filled-input-validator.js.map +1 -0
- package/titanium/input-validator/input-validator.d.ts +20 -0
- package/titanium/input-validator/input-validator.js +48 -0
- package/titanium/input-validator/input-validator.js.map +1 -0
- package/titanium/input-validator/outlined-input-validator.d.ts +20 -0
- package/titanium/input-validator/outlined-input-validator.js +48 -0
- package/titanium/input-validator/outlined-input-validator.js.map +1 -0
- package/titanium/profile-picture-stack/profile-picture-stack.d.ts +51 -0
- package/titanium/profile-picture-stack/profile-picture-stack.js +212 -0
- package/titanium/profile-picture-stack/profile-picture-stack.js.map +1 -0
- package/titanium/search-input/filled-search-input.d.ts +15 -0
- package/titanium/search-input/filled-search-input.js +111 -0
- package/titanium/search-input/filled-search-input.js.map +1 -0
- package/titanium/search-input/search-input.d.ts +29 -0
- package/titanium/search-input/search-input.js +123 -0
- package/titanium/search-input/search-input.js.map +1 -0
- package/titanium/service-worker-notifier/service-worker-notifier.d.ts +9 -0
- package/titanium/service-worker-notifier/service-worker-notifier.js +58 -0
- package/titanium/service-worker-notifier/service-worker-notifier.js.map +1 -0
- package/titanium/show-hide/show-hide.d.ts +41 -0
- package/titanium/show-hide/show-hide.js +171 -0
- package/titanium/show-hide/show-hide.js.map +1 -0
- package/titanium/single-select-base/single-select-base.d.ts +514 -0
- package/titanium/single-select-base/single-select-base.js +549 -0
- package/titanium/single-select-base/single-select-base.js.map +1 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.d.ts +422 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.js +467 -0
- package/titanium/smart-attachment-input/crop-and-save-image-dialog.js.map +1 -0
- package/titanium/smart-attachment-input/cropper-styles.d.ts +3 -0
- package/titanium/smart-attachment-input/cropper-styles.js +318 -0
- package/titanium/smart-attachment-input/cropper-styles.js.map +1 -0
- package/titanium/smart-attachment-input/image-formats.d.ts +5 -0
- package/titanium/smart-attachment-input/image-formats.js +37 -0
- package/titanium/smart-attachment-input/image-formats.js.map +1 -0
- package/titanium/smart-attachment-input/image-preview-dialog.d.ts +21 -0
- package/titanium/smart-attachment-input/image-preview-dialog.js +96 -0
- package/titanium/smart-attachment-input/image-preview-dialog.js.map +1 -0
- package/titanium/smart-attachment-input/images/duck-loader.gif +0 -0
- package/titanium/smart-attachment-input/images/icon-other-bg.png +0 -0
- package/titanium/smart-attachment-input/images/icon-other.png +0 -0
- package/titanium/smart-attachment-input/images/icon-pdf-bg.png +0 -0
- package/titanium/smart-attachment-input/images/icon-pdf.png +0 -0
- package/titanium/smart-attachment-input/smart-attachment-input.d.ts +133 -0
- package/titanium/smart-attachment-input/smart-attachment-input.js +497 -0
- package/titanium/smart-attachment-input/smart-attachment-input.js.map +1 -0
- package/titanium/smart-attachment-input/type/smart-attachment.d.ts +7 -0
- package/titanium/smart-attachment-input/type/smart-attachment.js +2 -0
- package/titanium/smart-attachment-input/type/smart-attachment.js.map +1 -0
- package/titanium/snackbar/show-snackbar-event.d.ts +9 -0
- package/titanium/snackbar/show-snackbar-event.js +9 -0
- package/titanium/snackbar/show-snackbar-event.js.map +1 -0
- package/titanium/snackbar/snackbar-stack.d.ts +24 -0
- package/titanium/snackbar/snackbar-stack.js +99 -0
- package/titanium/snackbar/snackbar-stack.js.map +1 -0
- package/titanium/snackbar/snackbars/http-error-snackbar.d.ts +28 -0
- package/titanium/snackbar/snackbars/http-error-snackbar.js +155 -0
- package/titanium/snackbar/snackbars/http-error-snackbar.js.map +1 -0
- package/titanium/snackbar/snackbars/simple-snackbar.d.ts +27 -0
- package/titanium/snackbar/snackbars/simple-snackbar.js +140 -0
- package/titanium/snackbar/snackbars/simple-snackbar.js.map +1 -0
- package/titanium/snackbar/types/snackbar-options.d.ts +9 -0
- package/titanium/snackbar/types/snackbar-options.js +2 -0
- package/titanium/snackbar/types/snackbar-options.js.map +1 -0
- package/titanium/styles/a.d.ts +2 -0
- package/titanium/styles/a.js +18 -0
- package/titanium/styles/a.js.map +1 -0
- package/titanium/styles/data-row.d.ts +2 -0
- package/titanium/styles/data-row.js +61 -0
- package/titanium/styles/data-row.js.map +1 -0
- package/titanium/styles/ellipsis.d.ts +2 -0
- package/titanium/styles/ellipsis.js +9 -0
- package/titanium/styles/ellipsis.js.map +1 -0
- package/titanium/styles/h1.d.ts +2 -0
- package/titanium/styles/h1.js +17 -0
- package/titanium/styles/h1.js.map +1 -0
- package/titanium/styles/h2.d.ts +2 -0
- package/titanium/styles/h2.js +17 -0
- package/titanium/styles/h2.js.map +1 -0
- package/titanium/styles/h3.d.ts +2 -0
- package/titanium/styles/h3.js +17 -0
- package/titanium/styles/h3.js.map +1 -0
- package/titanium/styles/h4.d.ts +2 -0
- package/titanium/styles/h4.js +17 -0
- package/titanium/styles/h4.js.map +1 -0
- package/titanium/styles/h5.d.ts +2 -0
- package/titanium/styles/h5.js +19 -0
- package/titanium/styles/h5.js.map +1 -0
- package/titanium/styles/nice-badge.d.ts +2 -0
- package/titanium/styles/nice-badge.js +53 -0
- package/titanium/styles/nice-badge.js.map +1 -0
- package/titanium/styles/p.d.ts +2 -0
- package/titanium/styles/p.js +17 -0
- package/titanium/styles/p.js.map +1 -0
- package/titanium/styles/styles.d.ts +17 -0
- package/titanium/styles/styles.js +17 -0
- package/titanium/styles/styles.js.map +1 -0
- package/titanium/toolbar/toolbar.d.ts +24 -0
- package/titanium/toolbar/toolbar.js +100 -0
- package/titanium/toolbar/toolbar.js.map +1 -0
- package/titanium/types/any-function.d.ts +5 -0
- package/titanium/types/any-function.js +5 -0
- package/titanium/types/any-function.js.map +1 -0
- package/titanium/types/dom-event.d.ts +4 -0
- package/titanium/types/dom-event.js +2 -0
- package/titanium/types/dom-event.js.map +1 -0
- package/titanium/types/identifier-interface.d.ts +4 -0
- package/titanium/types/identifier-interface.js +2 -0
- package/titanium/types/identifier-interface.js.map +1 -0
- package/titanium/types/pending-state-event.d.ts +7 -0
- package/titanium/types/pending-state-event.js +7 -0
- package/titanium/types/pending-state-event.js.map +1 -0
- package/titanium/types/string-map.d.ts +7 -0
- package/titanium/types/string-map.js +5 -0
- package/titanium/types/string-map.js.map +1 -0
- package/titanium/youtube-input/youtube-input.d.ts +19 -0
- package/titanium/youtube-input/youtube-input.js +68 -0
- package/titanium/youtube-input/youtube-input.js.map +1 -0
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import '@material/web/icon/icon';
|
|
3
|
+
import { isDevelopment } from '../../titanium/helpers/helpers';
|
|
4
|
+
import { css, html, LitElement, nothing } from 'lit';
|
|
5
|
+
import { customElement, property } from 'lit/decorators.js';
|
|
6
|
+
/**
|
|
7
|
+
* Displays a Leavitt Group users profile picture
|
|
8
|
+
*
|
|
9
|
+
* @element profile-picture
|
|
10
|
+
*
|
|
11
|
+
*/
|
|
12
|
+
let ProfilePicture = class ProfilePicture extends LitElement {
|
|
13
|
+
#fileName_accessor_storage;
|
|
14
|
+
/**
|
|
15
|
+
* File name of the profile picture on CDN, no extension
|
|
16
|
+
*/
|
|
17
|
+
get fileName() { return this.#fileName_accessor_storage; }
|
|
18
|
+
set fileName(value) { this.#fileName_accessor_storage = value; }
|
|
19
|
+
#shape_accessor_storage = 'circle';
|
|
20
|
+
/**
|
|
21
|
+
* Shape of profile picture
|
|
22
|
+
*/
|
|
23
|
+
get shape() { return this.#shape_accessor_storage; }
|
|
24
|
+
set shape(value) { this.#shape_accessor_storage = value; }
|
|
25
|
+
#showRing_accessor_storage;
|
|
26
|
+
/**
|
|
27
|
+
* Shows a colored ring around the picture
|
|
28
|
+
*/
|
|
29
|
+
get showRing() { return this.#showRing_accessor_storage; }
|
|
30
|
+
set showRing(value) { this.#showRing_accessor_storage = value; }
|
|
31
|
+
#showTestUserIndicator_accessor_storage;
|
|
32
|
+
/**
|
|
33
|
+
* Shows a test user indicator at the bottom of the picture
|
|
34
|
+
*/
|
|
35
|
+
get showTestUserIndicator() { return this.#showTestUserIndicator_accessor_storage; }
|
|
36
|
+
set showTestUserIndicator(value) { this.#showTestUserIndicator_accessor_storage = value; }
|
|
37
|
+
#profilePictureLinkPersonId_accessor_storage;
|
|
38
|
+
/**
|
|
39
|
+
* Makes the image a link to the respective profile page
|
|
40
|
+
*/
|
|
41
|
+
get profilePictureLinkPersonId() { return this.#profilePictureLinkPersonId_accessor_storage; }
|
|
42
|
+
set profilePictureLinkPersonId(value) { this.#profilePictureLinkPersonId_accessor_storage = value; }
|
|
43
|
+
#size_accessor_storage = 120;
|
|
44
|
+
/**
|
|
45
|
+
* Size in pixels of profile picture
|
|
46
|
+
*/
|
|
47
|
+
get size() { return this.#size_accessor_storage; }
|
|
48
|
+
set size(value) { this.#size_accessor_storage = value; }
|
|
49
|
+
#useIntrinsicImageSize_accessor_storage = false;
|
|
50
|
+
/**
|
|
51
|
+
* Setting true will cause the size attribute to only determine what size image to fetch from CDN and not set any CSS size styles on the image. Therefore the image will be displayed at its intrinsic size unless further overridden by the consumer.
|
|
52
|
+
*/
|
|
53
|
+
get useIntrinsicImageSize() { return this.#useIntrinsicImageSize_accessor_storage; }
|
|
54
|
+
set useIntrinsicImageSize(value) { this.#useIntrinsicImageSize_accessor_storage = value; }
|
|
55
|
+
#availableSizes = new Set([32, 64, 128, 256, 512, 1024]);
|
|
56
|
+
#fallbackSrc = 'https://cdn.leavitt.com/icon-user-profile-sq.svg';
|
|
57
|
+
updated(changedProps) {
|
|
58
|
+
if (changedProps.has('size') || changedProps.has('useIntrinsicImageSize')) {
|
|
59
|
+
this.style.width = this.useIntrinsicImageSize || !this.size ? '' : this.size + 'px';
|
|
60
|
+
this.style.height = this.useIntrinsicImageSize || !this.size ? '' : this.size + 'px';
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
#determineSize(size) {
|
|
64
|
+
const availableSizes = [...this.#availableSizes];
|
|
65
|
+
for (let index = 0; index < availableSizes.length; index++) {
|
|
66
|
+
const availableSize = availableSizes[index];
|
|
67
|
+
if (size <= availableSize) {
|
|
68
|
+
return availableSize;
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
return 512;
|
|
72
|
+
}
|
|
73
|
+
#getFilePath(cdnFileName, size) {
|
|
74
|
+
const requestedSize = this.#determineSize(size);
|
|
75
|
+
if (!cdnFileName) {
|
|
76
|
+
return this.#fallbackSrc;
|
|
77
|
+
}
|
|
78
|
+
else {
|
|
79
|
+
return `https://cdn.leavitt.com/${cdnFileName}-${requestedSize}.webp`;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
static { this.styles = css `
|
|
83
|
+
:host {
|
|
84
|
+
display: inline-block;
|
|
85
|
+
white-space: normal;
|
|
86
|
+
flex-shrink: 0;
|
|
87
|
+
position: relative;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
img {
|
|
91
|
+
display: block;
|
|
92
|
+
width: 100%;
|
|
93
|
+
aspect-ratio: 1;
|
|
94
|
+
image-rendering: -webkit-optimize-contrast;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
md-icon {
|
|
98
|
+
position: absolute;
|
|
99
|
+
bottom: -2px;
|
|
100
|
+
right: -2px;
|
|
101
|
+
color: var(--md-sys-color-on-primary);
|
|
102
|
+
background-color: var(--md-sys-color-primary);
|
|
103
|
+
border-radius: 50%;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
:host([shape='circle']) a:after,
|
|
107
|
+
:host([shape='circle']) img {
|
|
108
|
+
border-radius: 50%;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
:host([show-ring]) {
|
|
112
|
+
justify-self: center;
|
|
113
|
+
border: 3px solid var(--profile-picture-ring-color, var(--app-accent-color-blue, #4285f4));
|
|
114
|
+
padding: 3px;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
:host([show-ring][shape='circle']) {
|
|
118
|
+
border-radius: 50%;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
a:after,
|
|
122
|
+
a:before {
|
|
123
|
+
position: absolute;
|
|
124
|
+
opacity: 0;
|
|
125
|
+
transition: all 0.5s;
|
|
126
|
+
-webkit-transition: all 0.5s;
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
a:after {
|
|
130
|
+
content: '';
|
|
131
|
+
width: 100%;
|
|
132
|
+
height: 100%;
|
|
133
|
+
top: 0;
|
|
134
|
+
left: 0;
|
|
135
|
+
background: rgba(0, 0, 0, 0.2);
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
a:before {
|
|
139
|
+
content: '↗';
|
|
140
|
+
width: 100%;
|
|
141
|
+
color: #fff;
|
|
142
|
+
z-index: 1;
|
|
143
|
+
bottom: 0;
|
|
144
|
+
text-align: center;
|
|
145
|
+
box-sizing: border-box;
|
|
146
|
+
-moz-box-sizing: border-box;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
a:hover:before,
|
|
150
|
+
a:hover:after {
|
|
151
|
+
opacity: 1;
|
|
152
|
+
}
|
|
153
|
+
`; }
|
|
154
|
+
renderProfilePicture() {
|
|
155
|
+
return html `
|
|
156
|
+
<img
|
|
157
|
+
loading="lazy"
|
|
158
|
+
draggable="false"
|
|
159
|
+
alt="User profile picture"
|
|
160
|
+
src=${this.#getFilePath(this.fileName, this.size)}
|
|
161
|
+
@error=${(e) => {
|
|
162
|
+
if (e.target.src !== this.#fallbackSrc) {
|
|
163
|
+
e.target.src = this.#fallbackSrc;
|
|
164
|
+
}
|
|
165
|
+
}}
|
|
166
|
+
/>
|
|
167
|
+
${this.showTestUserIndicator
|
|
168
|
+
? html `<md-icon part="test-user-indicator" style="--md-icon-size: calc(${this.size}px * 0.35);padding: calc(${this.size}px * 0.05)" title="Test user"
|
|
169
|
+
>bug_report</md-icon
|
|
170
|
+
>`
|
|
171
|
+
: nothing}
|
|
172
|
+
`;
|
|
173
|
+
}
|
|
174
|
+
render() {
|
|
175
|
+
if (this.profilePictureLinkPersonId) {
|
|
176
|
+
return html `<a target="_blank" href="https://${isDevelopment ? 'dev' : ''}workforce.leavitt.com/user/${this.profilePictureLinkPersonId}/view"
|
|
177
|
+
>${this.renderProfilePicture()}</a
|
|
178
|
+
> `;
|
|
179
|
+
}
|
|
180
|
+
return this.renderProfilePicture();
|
|
181
|
+
}
|
|
182
|
+
};
|
|
183
|
+
__decorate([
|
|
184
|
+
property({ reflect: true, type: String })
|
|
185
|
+
], ProfilePicture.prototype, "fileName", null);
|
|
186
|
+
__decorate([
|
|
187
|
+
property({ reflect: true, type: String })
|
|
188
|
+
], ProfilePicture.prototype, "shape", null);
|
|
189
|
+
__decorate([
|
|
190
|
+
property({ reflect: true, type: Boolean, attribute: 'show-ring' })
|
|
191
|
+
], ProfilePicture.prototype, "showRing", null);
|
|
192
|
+
__decorate([
|
|
193
|
+
property({ reflect: true, type: Boolean, attribute: 'show-test-user-indicator' })
|
|
194
|
+
], ProfilePicture.prototype, "showTestUserIndicator", null);
|
|
195
|
+
__decorate([
|
|
196
|
+
property({ reflect: true, type: Number, attribute: 'profile-picture-link-person-id' })
|
|
197
|
+
], ProfilePicture.prototype, "profilePictureLinkPersonId", null);
|
|
198
|
+
__decorate([
|
|
199
|
+
property({ type: Number })
|
|
200
|
+
], ProfilePicture.prototype, "size", null);
|
|
201
|
+
__decorate([
|
|
202
|
+
property({ type: Boolean })
|
|
203
|
+
], ProfilePicture.prototype, "useIntrinsicImageSize", null);
|
|
204
|
+
ProfilePicture = __decorate([
|
|
205
|
+
customElement('profile-picture')
|
|
206
|
+
], ProfilePicture);
|
|
207
|
+
export { ProfilePicture };
|
|
208
|
+
//# sourceMappingURL=profile-picture.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"profile-picture.js","sourceRoot":"","sources":["profile-picture.ts"],"names":[],"mappings":";AAAA,OAAO,yBAAyB,CAAC;AAGjC,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAC/D,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,OAAO,EAAkB,MAAM,KAAK,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAE5D;;;;;GAKG;AAEI,IAAM,cAAc,GAApB,MAAM,cAAe,SAAQ,UAAU;IAIQ,2BAAwB;IAH5E;;OAEG;IACiD,IAAA,QAAQ,8CAAgB;IAAxB,IAAA,QAAQ,oDAAgB;IAKxB,0BAA6B,QAAQ,CAAC;IAH1F;;OAEG;IACiD,IAAA,KAAK,2CAAiC;IAAtC,IAAA,KAAK,iDAAiC;IAKb,2BAAkB;IAH/F;;OAEG;IAC0E,IAAA,QAAQ,8CAAU;IAAlB,IAAA,QAAQ,oDAAU;IAKH,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ACjI,IAAI,CAAC,oBAAoB,EAAE;SAC7B,CAAC;QACN,CAAC;QACD,OAAO,IAAI,CAAC,oBAAoB,EAAE,CAAC;IACrC,CAAC;;AApKmD;IAAnD,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;8CAAkC;AAKxB;IAAnD,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;2CAAgD;AAKb;IAA5E,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,WAAW,EAAE,CAAC;8CAA4B;AAKH;IAA3F,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,SAAS,EAAE,0BAA0B,EAAE,CAAC;2DAAyC;AAK1B;IAAhG,QAAQ,CAAC,EAAE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,gCAAgC,EAAE,CAAC;gEAAoD;AAKtG;IAApC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;0CAA6B;AAKlB;IAArC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,CAAC;2DAAiD;AAlClE,cAAc;IAD1B,aAAa,CAAC,iBAAiB,CAAC;GACpB,cAAc,CAyK1B"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
import '@material/web/progress/circular-progress';
|
|
3
|
+
declare const LeavittServiceWorkerNotifier_base: import("../theme/theme-preference").Constructor<import("../theme/theme-preference").ThemePreferenceInterface> & typeof LitElement;
|
|
4
|
+
export declare class LeavittServiceWorkerNotifier extends LeavittServiceWorkerNotifier_base {
|
|
5
|
+
#private;
|
|
6
|
+
private accessor main;
|
|
7
|
+
private accessor isLoading;
|
|
8
|
+
connectedCallback(): Promise<void>;
|
|
9
|
+
static styles: import("lit").CSSResult[];
|
|
10
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
11
|
+
handleClick(): Promise<void>;
|
|
12
|
+
}
|
|
13
|
+
export {};
|
|
14
|
+
//# sourceMappingURL=service-worker-notifier.d.ts.map
|
|
@@ -0,0 +1,180 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { css, html, LitElement } from 'lit';
|
|
3
|
+
import { customElement, query, state } from 'lit/decorators.js';
|
|
4
|
+
import { ThemePreference } from '../theme/theme-preference';
|
|
5
|
+
import '@material/web/progress/circular-progress';
|
|
6
|
+
let LeavittServiceWorkerNotifier = class LeavittServiceWorkerNotifier extends ThemePreference(LitElement) {
|
|
7
|
+
#main_accessor_storage;
|
|
8
|
+
get main() { return this.#main_accessor_storage; }
|
|
9
|
+
set main(value) { this.#main_accessor_storage = value; }
|
|
10
|
+
#isLoading_accessor_storage = false;
|
|
11
|
+
get isLoading() { return this.#isLoading_accessor_storage; }
|
|
12
|
+
set isLoading(value) { this.#isLoading_accessor_storage = value; }
|
|
13
|
+
#newWorker;
|
|
14
|
+
#refreshing = false;
|
|
15
|
+
async connectedCallback() {
|
|
16
|
+
super.connectedCallback();
|
|
17
|
+
if ('serviceWorker' in navigator) {
|
|
18
|
+
const originalSW = navigator.serviceWorker.controller;
|
|
19
|
+
const reg = await navigator.serviceWorker.getRegistration();
|
|
20
|
+
if (reg) {
|
|
21
|
+
reg.addEventListener('updatefound', () => {
|
|
22
|
+
this.#newWorker = reg.installing;
|
|
23
|
+
this.#newWorker?.addEventListener('statechange', () => {
|
|
24
|
+
if (this.#newWorker?.state === 'installed' && navigator.serviceWorker.controller) {
|
|
25
|
+
this.#newWorker?.postMessage({ type: 'SKIP_WAITING' });
|
|
26
|
+
}
|
|
27
|
+
});
|
|
28
|
+
});
|
|
29
|
+
if (reg.waiting && navigator.serviceWorker.controller) {
|
|
30
|
+
this.#newWorker = reg.waiting;
|
|
31
|
+
this.#newWorker?.postMessage({ type: 'SKIP_WAITING' });
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
navigator.serviceWorker.addEventListener('controllerchange', () => {
|
|
35
|
+
if (this.#refreshing) {
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
if (originalSW) {
|
|
39
|
+
this.main.showPopover();
|
|
40
|
+
this.#refreshing = true;
|
|
41
|
+
}
|
|
42
|
+
else {
|
|
43
|
+
//This is due to a SW taking control for the first time
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
static { this.styles = [
|
|
49
|
+
css `
|
|
50
|
+
:host {
|
|
51
|
+
display: block;
|
|
52
|
+
container-type: inline-size;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
main {
|
|
56
|
+
display: none;
|
|
57
|
+
position: fixed;
|
|
58
|
+
background-color: var(--app-background-color);
|
|
59
|
+
color: var(--md-sys-color-on-background);
|
|
60
|
+
|
|
61
|
+
cursor: pointer;
|
|
62
|
+
|
|
63
|
+
user-select: none;
|
|
64
|
+
-webkit-user-select: none;
|
|
65
|
+
-moz-user-select: none;
|
|
66
|
+
-ms-user-select: none;
|
|
67
|
+
|
|
68
|
+
grid: 'image text' / auto 1fr;
|
|
69
|
+
align-items: center;
|
|
70
|
+
gap: 16px 12px;
|
|
71
|
+
|
|
72
|
+
border: 0;
|
|
73
|
+
padding: 8px;
|
|
74
|
+
|
|
75
|
+
@container (max-width: 500px) {
|
|
76
|
+
grid:
|
|
77
|
+
'image' auto
|
|
78
|
+
'text' 1fr / auto;
|
|
79
|
+
|
|
80
|
+
justify-items: center;
|
|
81
|
+
text-align: center;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
main::backdrop {
|
|
86
|
+
background-color: var(--app-background-color);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
main:popover-open {
|
|
90
|
+
display: grid;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
md-circular-progress,
|
|
94
|
+
img {
|
|
95
|
+
grid-area: image;
|
|
96
|
+
width: 48px;
|
|
97
|
+
height: 48px;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
h1 {
|
|
101
|
+
font-family: var(--titanium-styles-h1-font-family, Metropolis, Roboto, Noto, sans-serif);
|
|
102
|
+
-webkit-font-smoothing: antialiased;
|
|
103
|
+
font-size: 32px;
|
|
104
|
+
line-height: 34px;
|
|
105
|
+
font-weight: 700;
|
|
106
|
+
letter-spacing: -1px;
|
|
107
|
+
|
|
108
|
+
margin: 0;
|
|
109
|
+
padding: 0;
|
|
110
|
+
|
|
111
|
+
@container (max-width: 500px) {
|
|
112
|
+
font-size: 24px;
|
|
113
|
+
line-height: 26px;
|
|
114
|
+
|
|
115
|
+
margin-bottom: 6px;
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
h3 {
|
|
120
|
+
font-family: var(--titanium-styles-h2-font-family, Metropolis, Roboto, Noto, sans-serif);
|
|
121
|
+
-webkit-font-smoothing: antialiased;
|
|
122
|
+
font-size: 16px;
|
|
123
|
+
line-height: 18px;
|
|
124
|
+
font-weight: 300;
|
|
125
|
+
letter-spacing: 0.6px;
|
|
126
|
+
|
|
127
|
+
margin: 0;
|
|
128
|
+
padding: 0;
|
|
129
|
+
margin-left: 6px;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
click-blocker {
|
|
133
|
+
display: none;
|
|
134
|
+
position: fixed;
|
|
135
|
+
width: 100vw;
|
|
136
|
+
height: 100vh;
|
|
137
|
+
z-index: 9999;
|
|
138
|
+
left: 0;
|
|
139
|
+
right: 0;
|
|
140
|
+
background: transparent;
|
|
141
|
+
cursor: pointer;
|
|
142
|
+
pointer-events: all;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
main:popover-open + click-blocker {
|
|
146
|
+
display: block;
|
|
147
|
+
}
|
|
148
|
+
`,
|
|
149
|
+
]; }
|
|
150
|
+
render() {
|
|
151
|
+
return html `<main popover="manual" @click=${this.handleClick}>
|
|
152
|
+
${this.isLoading
|
|
153
|
+
? html `<md-circular-progress indeterminate></md-circular-progress>`
|
|
154
|
+
: html `<img
|
|
155
|
+
src=${this.themePreference === 'dark' ? 'https://cdn.leavitt.com/company-mark-57-dark.svg' : 'https://cdn.leavitt.com/company-mark-57.svg'}
|
|
156
|
+
/>`}
|
|
157
|
+
<div>
|
|
158
|
+
<h1>This site has been updated!</h1>
|
|
159
|
+
<h3>Please click to reload</h3>
|
|
160
|
+
</div>
|
|
161
|
+
</main>
|
|
162
|
+
<click-blocker @click=${this.handleClick}></click-blocker>`;
|
|
163
|
+
}
|
|
164
|
+
async handleClick() {
|
|
165
|
+
this.isLoading = true;
|
|
166
|
+
await this.updateComplete;
|
|
167
|
+
window.location.reload();
|
|
168
|
+
}
|
|
169
|
+
};
|
|
170
|
+
__decorate([
|
|
171
|
+
query('main')
|
|
172
|
+
], LeavittServiceWorkerNotifier.prototype, "main", null);
|
|
173
|
+
__decorate([
|
|
174
|
+
state()
|
|
175
|
+
], LeavittServiceWorkerNotifier.prototype, "isLoading", null);
|
|
176
|
+
LeavittServiceWorkerNotifier = __decorate([
|
|
177
|
+
customElement('leavitt-service-worker-notifier')
|
|
178
|
+
], LeavittServiceWorkerNotifier);
|
|
179
|
+
export { LeavittServiceWorkerNotifier };
|
|
180
|
+
//# sourceMappingURL=service-worker-notifier.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"service-worker-notifier.js","sourceRoot":"","sources":["service-worker-notifier.ts"],"names":[],"mappings":";AAAA,OAAO,EAAE,GAAG,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,KAAK,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAChE,OAAO,EAAE,eAAe,EAAE,MAAM,2BAA2B,CAAC;AAE5D,OAAO,0CAA0C,CAAC;AAG3C,IAAM,4BAA4B,GAAlC,MAAM,4BAA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,EAAE,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AAC9D,MAAM,oBAAoB,GAAG,IAAI,QAAQ,EAAgC,CAAC;AAC1E,MAAM,CAAC,MAAM,CAAC,oBAAoB,CAAC,CAAC;AACpC,eAAe,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { LitElement } from 'lit';
|
|
2
|
+
export type Constructor<T = {}> = new (...args: any[]) => T;
|
|
3
|
+
export type ThemePreferenceOption = 'light' | 'dark';
|
|
4
|
+
export declare class ThemePreferenceInterface {
|
|
5
|
+
themePreference: 'light' | 'dark';
|
|
6
|
+
}
|
|
7
|
+
export declare const ThemePreference: <T extends Constructor<LitElement>>(superClass: T) => Constructor<ThemePreferenceInterface> & T;
|
|
8
|
+
//# sourceMappingURL=theme-preference.d.ts.map
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { __decorate } from "tslib";
|
|
2
|
+
import { property } from 'lit/decorators.js';
|
|
3
|
+
import themePreferenceEvent from './theme-preference-event';
|
|
4
|
+
/*
|
|
5
|
+
Adds reflected attribute / property (theme-preference) to host that reflects
|
|
6
|
+
users currently selected theme preference
|
|
7
|
+
|
|
8
|
+
ex. css :host([theme-preference='dark'])
|
|
9
|
+
*/
|
|
10
|
+
export const ThemePreference = (superClass) => {
|
|
11
|
+
class ThemePreference extends superClass {
|
|
12
|
+
connectedCallback() {
|
|
13
|
+
super.connectedCallback();
|
|
14
|
+
themePreferenceEvent.subscribe('theme-preference', 'change', (themePreference) => {
|
|
15
|
+
this.themePreference = themePreference;
|
|
16
|
+
});
|
|
17
|
+
this.themePreference = document.firstElementChild?.getAttribute('data-theme') === 'light' ? 'light' : 'dark';
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
__decorate([
|
|
21
|
+
property({ attribute: 'theme-preference', reflect: true })
|
|
22
|
+
], ThemePreference.prototype, "themePreference", void 0);
|
|
23
|
+
// Cast return type to your mixin's interface intersected with the superClass type
|
|
24
|
+
return ThemePreference;
|
|
25
|
+
};
|
|
26
|
+
//# sourceMappingURL=theme-preference.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme-preference.js","sourceRoot":"","sources":["theme-preference.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,oBAAoB,MAAM,0BAA0B,CAAC;AAW5D;;;;;EAKE;AACF,MAAM,CAAC,MAAM,eAAe,GAAG,CAAoC,UAAa,EAAE,EAAE;IAClF,MAAM,eAAgB,SAAQ,UAAU;QAGtC,iBAAiB;YACf,KAAK,CAAC,iBAAiB,EAAE,CAAC;YAC1B,oBAAoB,CAAC,SAAS,CAAC,kBAAkB,EAAE,QAAQ,EAAE,CAAC,eAAsC,EAAE,EAAE;gBACtG,IAAI,CAAC,eAAe,GAAG,eAAe,CAAC;YACzC,CAAC,CAAC,CAAC;YACH,IAAI,CAAC,eAAe,GAAG,QAAQ,CAAC,iBAAiB,EAAE,YAAY,CAAC,YAAY,CAAC,KAAK,OAAO,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC;QAC/G,CAAC;KACF;IAT6D;QAA3D,QAAQ,CAAC,EAAE,SAAS,EAAE,kBAAkB,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;4DAAwC;IAUrG,kFAAkF;IAClF,OAAO,eAA4D,CAAC;AACtE,CAAC,CAAC"}
|