@internetarchive/elements 1.11.0-webdev-9043.0 → 1.11.1-webdev-10162.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/README.md +4 -43
- package/dist/src/elements/ia-book-actions/assets/styles/collapsible-action-group.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/assets/styles/collapsible-action-group.js +39 -42
- package/dist/src/elements/ia-book-actions/assets/styles/collapsible-action-group.js.map +1 -1
- package/dist/src/elements/ia-book-actions/assets/styles/ia-button.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/assets/styles/ia-button.js +21 -27
- package/dist/src/elements/ia-book-actions/assets/styles/ia-button.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.js +1 -2
- package/dist/src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-info-icon.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-info-icon.js +21 -25
- package/dist/src/elements/ia-book-actions/ia-book-actions-info-icon.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-text-group.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-text-group.js +16 -20
- package/dist/src/elements/ia-book-actions/ia-book-actions-text-group.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-timer-countdown.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-timer-countdown.js +26 -30
- package/dist/src/elements/ia-book-actions/ia-book-actions-timer-countdown.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-title-bar.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions-title-bar.js +29 -33
- package/dist/src/elements/ia-book-actions/ia-book-actions-title-bar.js.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions.d.ts +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions.d.ts.map +1 -1
- package/dist/src/elements/ia-book-actions/ia-book-actions.js +22 -28
- package/dist/src/elements/ia-book-actions/ia-book-actions.js.map +1 -1
- package/dist/src/elements/ia-button/ia-button.d.ts +34 -21
- package/dist/src/elements/ia-button/ia-button.d.ts.map +1 -1
- package/dist/src/elements/ia-button/ia-button.js +176 -277
- package/dist/src/elements/ia-button/ia-button.js.map +1 -1
- package/dist/src/elements/ia-clearable-text-input/ia-clearable-text-input.d.ts +1 -1
- package/dist/src/elements/ia-clearable-text-input/ia-clearable-text-input.d.ts.map +1 -1
- package/dist/src/elements/ia-clearable-text-input/ia-clearable-text-input.js +102 -131
- package/dist/src/elements/ia-clearable-text-input/ia-clearable-text-input.js.map +1 -1
- package/dist/src/elements/ia-combo-box/ia-combo-box.d.ts.map +1 -1
- package/dist/src/elements/ia-combo-box/ia-combo-box.js +20 -40
- package/dist/src/elements/ia-combo-box/ia-combo-box.js.map +1 -1
- package/dist/src/elements/ia-donation-form/flow-handlers/donation-flow-modal-manager.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/flow-handlers/donation-flow-modal-manager.js +3 -9
- package/dist/src/elements/ia-donation-form/flow-handlers/donation-flow-modal-manager.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/contact-form/ia-donation-contact-form.d.ts +0 -5
- package/dist/src/elements/ia-donation-form/form-elements/contact-form/ia-donation-contact-form.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/contact-form/ia-donation-contact-form.js +5 -10
- package/dist/src/elements/ia-donation-form/form-elements/contact-form/ia-donation-contact-form.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-badged-input.js +4 -4
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-badged-input.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-credit-card-fields.d.ts +0 -5
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-credit-card-fields.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-credit-card-fields.js +3 -11
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-credit-card-fields.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-edit-donation.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-edit-donation.js +16 -19
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-edit-donation.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-payment-selector.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-payment-selector.js +11 -12
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-payment-selector.js.map +1 -1
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-section.js +5 -5
- package/dist/src/elements/ia-donation-form/form-elements/ia-donation-section.js.map +1 -1
- package/dist/src/elements/ia-donation-form/ia-donation-form-controller.d.ts +0 -5
- package/dist/src/elements/ia-donation-form/ia-donation-form-controller.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/ia-donation-form-controller.js +6 -14
- package/dist/src/elements/ia-donation-form/ia-donation-form-controller.js.map +1 -1
- package/dist/src/elements/ia-donation-form/ia-donation-form.d.ts.map +1 -1
- package/dist/src/elements/ia-donation-form/ia-donation-form.js +4 -6
- package/dist/src/elements/ia-donation-form/ia-donation-form.js.map +1 -1
- package/dist/src/elements/ia-donation-form/modals/ia-donation-confirm-modal.js +4 -4
- package/dist/src/elements/ia-donation-form/modals/ia-donation-confirm-modal.js.map +1 -1
- package/dist/src/elements/ia-donation-form/modals/ia-donation-upsell-modal-content.js +10 -10
- package/dist/src/elements/ia-donation-form/modals/ia-donation-upsell-modal-content.js.map +1 -1
- package/dist/src/elements/ia-donation-thermometer/ia-donation-thermometer.js +13 -13
- package/dist/src/elements/ia-donation-thermometer/ia-donation-thermometer.js.map +1 -1
- package/dist/src/elements/ia-dropdown/ia-dropdown.d.ts.map +1 -1
- package/dist/src/elements/ia-dropdown/ia-dropdown.js +27 -113
- package/dist/src/elements/ia-dropdown/ia-dropdown.js.map +1 -1
- package/dist/src/elements/ia-dropdown/ia-icon-label.d.ts.map +1 -1
- package/dist/src/elements/ia-dropdown/ia-icon-label.js +5 -11
- package/dist/src/elements/ia-dropdown/ia-icon-label.js.map +1 -1
- package/dist/src/elements/ia-dropdown-search-bar/ia-dropdown-search-bar.d.ts.map +1 -1
- package/dist/src/elements/ia-dropdown-search-bar/ia-dropdown-search-bar.js +35 -79
- package/dist/src/elements/ia-dropdown-search-bar/ia-dropdown-search-bar.js.map +1 -1
- package/dist/src/elements/ia-expandable-search-bar/ia-expandable-search-bar.d.ts.map +1 -1
- package/dist/src/elements/ia-expandable-search-bar/ia-expandable-search-bar.js +141 -156
- package/dist/src/elements/ia-expandable-search-bar/ia-expandable-search-bar.js.map +1 -1
- package/dist/src/elements/ia-expandable-search-bar/ia-quick-search.d.ts.map +1 -1
- package/dist/src/elements/ia-expandable-search-bar/ia-quick-search.js +43 -47
- package/dist/src/elements/ia-expandable-search-bar/ia-quick-search.js.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-comment.d.ts.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-comment.js +34 -39
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-comment.js.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-vote.d.ts.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-vote.js +112 -118
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey-vote.js.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey.d.ts.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey.js +42 -45
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback-survey.js.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback.d.ts.map +1 -1
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback.js +239 -245
- package/dist/src/elements/ia-feature-feedback/ia-feature-feedback.js.map +1 -1
- package/dist/src/elements/ia-histogram-date-range/ia-histogram-date-range.d.ts.map +1 -1
- package/dist/src/elements/ia-histogram-date-range/ia-histogram-date-range.js +17 -24
- package/dist/src/elements/ia-histogram-date-range/ia-histogram-date-range.js.map +1 -1
- package/dist/src/elements/ia-image-viewer/ia-image-viewer.js +1 -1
- package/dist/src/elements/ia-image-viewer/ia-image-viewer.js.map +1 -1
- package/dist/src/elements/ia-image-viewer/ia-imgview-controls.d.ts.map +1 -1
- package/dist/src/elements/ia-image-viewer/ia-imgview-controls.js +7 -8
- package/dist/src/elements/ia-image-viewer/ia-imgview-controls.js.map +1 -1
- package/dist/src/elements/ia-image-viewer/ia-imgview-slide.js +7 -7
- package/dist/src/elements/ia-image-viewer/ia-imgview-slide.js.map +1 -1
- package/dist/src/elements/ia-infinite-scroller/ia-infinite-scroller.d.ts.map +1 -1
- package/dist/src/elements/ia-infinite-scroller/ia-infinite-scroller.js +65 -72
- package/dist/src/elements/ia-infinite-scroller/ia-infinite-scroller.js.map +1 -1
- package/dist/src/elements/ia-infinite-scroller/story-support/ia-infinite-scroller-demo-tile.js +1 -1
- package/dist/src/elements/ia-infinite-scroller/story-support/ia-infinite-scroller-demo-tile.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-item-navigator.d.ts.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-item-navigator.js +5 -8
- package/dist/src/elements/ia-item-navigator/ia-item-navigator.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-itemnav-menu-button.js +5 -5
- package/dist/src/elements/ia-item-navigator/ia-itemnav-menu-button.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-itemnav-menu-slider.js +6 -6
- package/dist/src/elements/ia-item-navigator/ia-itemnav-menu-slider.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-itemnav-no-theater-available.d.ts.map +1 -1
- package/dist/src/elements/ia-item-navigator/ia-itemnav-no-theater-available.js +4 -5
- package/dist/src/elements/ia-item-navigator/ia-itemnav-no-theater-available.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-share-panel.js +13 -13
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-share-panel.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-sort-files-button.js +1 -1
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-sort-files-button.js.map +1 -1
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-viewable-files-panel.js +11 -11
- package/dist/src/elements/ia-item-navigator/menus/ia-itemnav-viewable-files-panel.js.map +1 -1
- package/dist/src/elements/ia-otp-form/ia-otp-form.js +4 -4
- package/dist/src/elements/ia-otp-form/ia-otp-form.js.map +1 -1
- package/dist/src/elements/ia-otp-input/ia-otp-input.d.ts.map +1 -1
- package/dist/src/elements/ia-otp-input/ia-otp-input.js +4 -21
- package/dist/src/elements/ia-otp-input/ia-otp-input.js.map +1 -1
- package/dist/src/elements/ia-playback-controls/ia-playback-controls.d.ts.map +1 -1
- package/dist/src/elements/ia-playback-controls/ia-playback-controls.js +81 -85
- package/dist/src/elements/ia-playback-controls/ia-playback-controls.js.map +1 -1
- package/dist/src/elements/ia-radio-player/ia-radio-player.d.ts.map +1 -1
- package/dist/src/elements/ia-radio-player/ia-radio-player.js +140 -146
- package/dist/src/elements/ia-radio-player/ia-radio-player.js.map +1 -1
- package/dist/src/elements/ia-radio-player/ia-search-results-switcher.d.ts.map +1 -1
- package/dist/src/elements/ia-radio-player/ia-search-results-switcher.js +30 -37
- package/dist/src/elements/ia-radio-player/ia-search-results-switcher.js.map +1 -1
- package/dist/src/elements/ia-reviews/ia-review-form.d.ts.map +1 -1
- package/dist/src/elements/ia-reviews/ia-review-form.js +21 -28
- package/dist/src/elements/ia-reviews/ia-review-form.js.map +1 -1
- package/dist/src/elements/ia-reviews/ia-review.d.ts.map +1 -1
- package/dist/src/elements/ia-reviews/ia-review.js +66 -70
- package/dist/src/elements/ia-reviews/ia-review.js.map +1 -1
- package/dist/src/elements/ia-reviews/ia-reviews.d.ts.map +1 -1
- package/dist/src/elements/ia-reviews/ia-reviews.js +12 -24
- package/dist/src/elements/ia-reviews/ia-reviews.js.map +1 -1
- package/dist/src/elements/ia-scrubber-bar/ia-scrubber-bar.d.ts.map +1 -1
- package/dist/src/elements/ia-scrubber-bar/ia-scrubber-bar.js +132 -155
- package/dist/src/elements/ia-scrubber-bar/ia-scrubber-bar.js.map +1 -1
- package/dist/src/elements/ia-scrubber-bar/ia-section-marker.d.ts.map +1 -1
- package/dist/src/elements/ia-scrubber-bar/ia-section-marker.js +56 -63
- package/dist/src/elements/ia-scrubber-bar/ia-section-marker.js.map +1 -1
- package/dist/src/elements/ia-topnav/dropdown-menu.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/dropdown-menu.js +10 -41
- package/dist/src/elements/ia-topnav/dropdown-menu.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-desktop-subnav.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-desktop-subnav.js +2 -3
- package/dist/src/elements/ia-topnav/ia-topnav-desktop-subnav.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-icon-hamburger.d.ts +2 -2
- package/dist/src/elements/ia-topnav/ia-topnav-icon-hamburger.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-icon-hamburger.js +10 -23
- package/dist/src/elements/ia-topnav/ia-topnav-icon-hamburger.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-login-button.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-login-button.js +4 -2
- package/dist/src/elements/ia-topnav/ia-topnav-login-button.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-button.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-button.js +12 -18
- package/dist/src/elements/ia-topnav/ia-topnav-media-button.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-menu.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-menu.js +4 -2
- package/dist/src/elements/ia-topnav/ia-topnav-media-menu.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-slider.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-slider.js +0 -2
- package/dist/src/elements/ia-topnav/ia-topnav-media-slider.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-subnav.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-media-subnav.js +0 -2
- package/dist/src/elements/ia-topnav/ia-topnav-media-subnav.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-more-slider.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-more-slider.js +0 -2
- package/dist/src/elements/ia-topnav/ia-topnav-more-slider.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-primary-nav.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-primary-nav.js +13 -12
- package/dist/src/elements/ia-topnav/ia-topnav-primary-nav.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-save-page-form.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-save-page-form.js +0 -2
- package/dist/src/elements/ia-topnav/ia-topnav-save-page-form.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-search.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-search.js +3 -10
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-search.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-slider.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-slider.js +2 -2
- package/dist/src/elements/ia-topnav/ia-topnav-wayback-slider.js.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/ia-topnav.js +42 -45
- package/dist/src/elements/ia-topnav/ia-topnav.js.map +1 -1
- package/dist/src/elements/ia-topnav/lib/register-topnav-unit.d.ts +25 -13
- package/dist/src/elements/ia-topnav/lib/register-topnav-unit.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/lib/register-topnav-unit.js +32 -17
- package/dist/src/elements/ia-topnav/lib/register-topnav-unit.js.map +1 -1
- package/dist/src/elements/ia-topnav/subnav-list-styles.d.ts.map +1 -1
- package/dist/src/elements/ia-topnav/subnav-list-styles.js +1 -8
- package/dist/src/elements/ia-topnav/subnav-list-styles.js.map +1 -1
- package/dist/src/elements/ia-transcript-view/ia-transcript-view.d.ts.map +1 -1
- package/dist/src/elements/ia-transcript-view/ia-transcript-view.js +173 -192
- package/dist/src/elements/ia-transcript-view/ia-transcript-view.js.map +1 -1
- package/dist/src/elements/ia-userlist-settings/ia-userlist-settings.d.ts +70 -0
- package/dist/src/elements/ia-userlist-settings/ia-userlist-settings.d.ts.map +1 -0
- package/dist/src/elements/ia-userlist-settings/ia-userlist-settings.js +314 -0
- package/dist/src/elements/ia-userlist-settings/ia-userlist-settings.js.map +1 -0
- package/dist/src/elements/ia-userlist-settings/mocks/mock-userlist-service.d.ts +37 -0
- package/dist/src/elements/ia-userlist-settings/mocks/mock-userlist-service.d.ts.map +1 -0
- package/dist/src/elements/ia-userlist-settings/mocks/mock-userlist-service.js +71 -0
- package/dist/src/elements/ia-userlist-settings/mocks/mock-userlist-service.js.map +1 -0
- package/dist/src/elements/ia-userlist-settings/models.d.ts +10 -0
- package/dist/src/elements/ia-userlist-settings/models.d.ts.map +1 -0
- package/dist/src/elements/ia-userlist-settings/models.js +2 -0
- package/dist/src/elements/ia-userlist-settings/models.js.map +1 -0
- package/dist/src/elements/ia-waveform-progress/ia-waveform-progress.d.ts.map +1 -1
- package/dist/src/elements/ia-waveform-progress/ia-waveform-progress.js +47 -56
- package/dist/src/elements/ia-waveform-progress/ia-waveform-progress.js.map +1 -1
- package/dist/src/elements/ia-wayback-search-form/ia-wayback-search-form.d.ts.map +1 -1
- package/dist/src/elements/ia-wayback-search-form/ia-wayback-search-form.js +27 -46
- package/dist/src/elements/ia-wayback-search-form/ia-wayback-search-form.js.map +1 -1
- package/dist/src/elements/modal-manager/ia-modal-manager-template.d.ts.map +1 -1
- package/dist/src/elements/modal-manager/ia-modal-manager-template.js +48 -66
- package/dist/src/elements/modal-manager/ia-modal-manager-template.js.map +1 -1
- package/dist/src/elements/modal-manager/modal-manager.d.ts.map +1 -1
- package/dist/src/elements/modal-manager/modal-manager.js +2 -7
- package/dist/src/elements/modal-manager/modal-manager.js.map +1 -1
- package/dist/src/services/userlist-service/mocks/sample-lists-backend.d.ts +29 -0
- package/dist/src/services/userlist-service/mocks/sample-lists-backend.d.ts.map +1 -0
- package/dist/src/services/userlist-service/mocks/sample-lists-backend.js +173 -0
- package/dist/src/services/userlist-service/mocks/sample-lists-backend.js.map +1 -0
- package/dist/src/services/userlist-service/userlist-service.d.ts +13 -3
- package/dist/src/services/userlist-service/userlist-service.d.ts.map +1 -1
- package/dist/src/services/userlist-service/userlist-service.js +25 -3
- package/dist/src/services/userlist-service/userlist-service.js.map +1 -1
- package/dist/src/themes/theme-styles.d.ts.map +1 -1
- package/dist/src/themes/theme-styles.js +50 -98
- package/dist/src/themes/theme-styles.js.map +1 -1
- package/package.json +5 -23
- package/dist/src/elements/ia-topnav/focus-styles.d.ts +0 -11
- package/dist/src/elements/ia-topnav/focus-styles.d.ts.map +0 -1
- package/dist/src/elements/ia-topnav/focus-styles.js +0 -22
- package/dist/src/elements/ia-topnav/focus-styles.js.map +0 -1
- package/dist/src/themes/tokens.d.ts +0 -14
- package/dist/src/themes/tokens.d.ts.map +0 -1
- package/dist/src/themes/tokens.js +0 -267
- package/dist/src/themes/tokens.js.map +0 -1
- package/dist/src/themes/unit.d.ts +0 -16
- package/dist/src/themes/unit.d.ts.map +0 -1
- package/dist/src/themes/unit.js +0 -70
- package/dist/src/themes/unit.js.map +0 -1
package/README.md
CHANGED
|
@@ -4,26 +4,6 @@
|
|
|
4
4
|
|
|
5
5
|
<https://internetarchive.github.io/elements>
|
|
6
6
|
|
|
7
|
-
Alongside the elements, the demo shows the design system they implement: its
|
|
8
|
-
principles, foundations and tokens, a reference spec for every component, whole
|
|
9
|
-
screens, icons and stress tests. The docs behind it are in [docs/](docs/README.md).
|
|
10
|
-
|
|
11
|
-
## Design system
|
|
12
|
-
|
|
13
|
-
elements implements archive.org's design system: the tokens (colors, type, spacing, sizes, motion), the foundations they come from, a spec for each component, and page-level patterns. Components target **WCAG 2.2 level AA**; [accessibility.md](docs/foundations/accessibility.md) has the rules.
|
|
14
|
-
|
|
15
|
-
| Part | Where |
|
|
16
|
-
| --- | --- |
|
|
17
|
-
| See it rendered | The [demo](https://internetarchive.github.io/elements)'s Principles, Foundations, Specs, Screens, Icons and Playground tabs |
|
|
18
|
-
| Foundations, component specs, patterns | [docs/](docs/README.md), which also lists which components follow the system so far |
|
|
19
|
-
| Token values | [tokens/tokens.json](tokens/tokens.json) |
|
|
20
|
-
|
|
21
|
-
**Using components on a page.** They follow the tokens with no setup. To change one, set its public name, such as `--ia-color-text-link`, on `:root` or any ancestor; a component's own `--ia-theme-*` hooks still win over the tokens. Add the `ia-inverse` class for a dark surface, and set `--ia-unit` to scale sizes. [Design tokens](#design-tokens) has the details. A page can't yet read the tokens in its own CSS: they're private to each component.
|
|
22
|
-
|
|
23
|
-
**Building a component.** Read the tokens as [Design tokens](#design-tokens) describes, preferring the semantic roles (`text`, `surface`, `border`, `action`, `status`) over the palette. A value the tokens don't have becomes a new token in `tokens/tokens.json`: a length goes in a group with a scale flag, and a color the component pairs with another gets that pairing in `src/themes/tokens.node.test.ts`. Write or update the component's spec in [docs/components/](docs/components/).
|
|
24
|
-
|
|
25
|
-
**Changing the system.** Change `tokens/tokens.json` and the spec in one PR, and say why in the PR; [docs/README.md](docs/README.md#changing-the-system) has the two checks it needs.
|
|
26
|
-
|
|
27
7
|
## Installation
|
|
28
8
|
|
|
29
9
|
```zsh
|
|
@@ -46,10 +26,6 @@ Services (code with no UI, like a metadata fetcher or a parser) import the same
|
|
|
46
26
|
import { FoobarService } from "@internetarchive/elements/services/foobar-service/foobar-service";
|
|
47
27
|
```
|
|
48
28
|
|
|
49
|
-
Sizes from the design tokens don't depend on the page's root font size, so a component looks the same on archive.org's 10px root and on a page with the browser's default 16px. Text, spacing, control heights, icons and containers grow with the user's browser font-size setting; borders, focus rings, corners, the 44px touch minimum, shadows and breakpoints stay fixed. elements does this by setting `--ia-unit` on `<html>` when it loads: `1px` at the browser's default 16px, `1.25px` at 20px. A page can set `--ia-unit` itself, on `:root` or on one element, to scale components on its own.
|
|
50
|
-
|
|
51
|
-
Components don't use `rem`. The demo and the stories do, sized for archive.org's 10px root font size, which the demo page sets.
|
|
52
|
-
|
|
53
29
|
## Build Dependencies
|
|
54
30
|
|
|
55
31
|
We use SVGs in this repo, which not all build systems support out of the box. Here's how to support SVGs:
|
|
@@ -270,21 +246,6 @@ For styling, our components use a series of rational CSS variable fallbacks to e
|
|
|
270
246
|
2. Customizable styles can be adjusted by the consumer by setting a CSS variable at the component or global level
|
|
271
247
|
3. The available variables are easy to find in the component file and visible in the story
|
|
272
248
|
|
|
273
|
-
#### Design tokens
|
|
274
|
-
|
|
275
|
-
The design system's values (colors, type, spacing, radius, sizing, motion and more) are design tokens, defined in [tokens/tokens.json](tokens/tokens.json). `pnpm run tokens` generates `src/themes/tokens.ts` from it; `dev`, `build`, `test` and `typecheck` run it first. Never edit the generated file.
|
|
276
|
-
|
|
277
|
-
`tokenStyles` (`@src/themes/tokens`) declares every token as a private alias on `:host`, named after the token with a trailing `--`. `themeStyles` includes `tokenStyles` and adds the older `--ia-theme-*` defaults, so a component that reads only tokens takes `tokenStyles`, and one that also reads a `--ia-theme-*` default takes `themeStyles`. Put either one in the component's `styles` array; pasting it into a `css` template with `${}` copies the whole token sheet into that component's stylesheet. Read the alias, never the token itself:
|
|
278
|
-
```
|
|
279
|
-
color: var(--ia-color-text-primary--);
|
|
280
|
-
padding: var(--ia-space-2--);
|
|
281
|
-
```
|
|
282
|
-
A page overrides a token by setting its public name, e.g. `--ia-color-text-link`, on `:root` or any ancestor. Setting a palette value such as `--ia-color-palette-navy-700` changes every role that points at it. Use the semantic roles (`text`, `surface`, `border`, `action`, `status`, ...) in components, not the palette.
|
|
283
|
-
|
|
284
|
-
For a dark surface, add the `ia-inverse` class, either inside the shadow root or on the element itself. It re-points the text, border, focus, surface, hover and selected aliases to values that clear contrast on dark backgrounds. It reaches only that element's own shadow root: a nested elements component sets its aliases afresh, so it needs the class too. Inside a shadow root it flips only what reads the `--ia-*--` aliases directly; on the element itself (`:host(.ia-inverse)`), the `--ia-theme-*` defaults built on them flip as well.
|
|
285
|
-
|
|
286
|
-
Length tokens are px at the browser's default font size. Each group of lengths in `tokens/tokens.json` sets `$extensions.ia.scale`: `true` builds as `calc(N * var(--ia-unit, 1px))`, `false` as plain px, and a length outside either fails the build. `src/themes/tokens.node.test.ts` checks every color pairing the system recommends against its WCAG contrast minimum, so a token change that breaks one fails the tests.
|
|
287
|
-
|
|
288
249
|
#### Setting up styles
|
|
289
250
|
|
|
290
251
|
1. In the component's CSS, include the elements-wide `themeStyles` defaults
|
|
@@ -296,7 +257,7 @@ static get styles(): CSSResultGroup {
|
|
|
296
257
|
themeStyles,
|
|
297
258
|
css`
|
|
298
259
|
```
|
|
299
|
-
2. Check the theme styles
|
|
260
|
+
2. Check the theme styles to see if an existing theme variable exists you can use as a default, i.e. for an error message color you could use `--color-danger` if no variable exists but the style you want seems fairly reusable, see [Creating a new theme style](#creating-a-new-theme-style) below. If the variable is _not_ reusable, see [Non-reusable styles](#non-reusable-styles) below.
|
|
300
261
|
3. In the component, create a private CSS variable in the top-level `:host` section to make your chosen variable obvious to consumers, and then use this private variable wherever you need the value
|
|
301
262
|
```
|
|
302
263
|
css`
|
|
@@ -313,16 +274,16 @@ const styleInputSettings: StyleInputSettings[] = [
|
|
|
313
274
|
{
|
|
314
275
|
label: 'Error color',
|
|
315
276
|
cssVariable: '--ia-theme-color-danger',
|
|
316
|
-
defaultValue: '#
|
|
277
|
+
defaultValue: '#e51c23',
|
|
317
278
|
inputType: 'color',
|
|
318
279
|
},
|
|
319
280
|
```
|
|
320
281
|
|
|
321
282
|
#### Creating a new theme style
|
|
322
283
|
While working on a component, you may realize that a customizable style you need doesn't already have an associated variable in `theme-styles.ts`. If this happens, you can follow the following steps to add one:
|
|
323
|
-
1. Select a rational default value for the style
|
|
284
|
+
1. Select a rational default value for the style, and add it to the defaults section at the top of the file:
|
|
324
285
|
```
|
|
325
|
-
--default-font-size-xs:
|
|
286
|
+
--default-font-size-xs: 0.625rem /* 10px with 16px root font size */
|
|
326
287
|
```
|
|
327
288
|
2. Name the variable and add it to the adjustable styles list with the following structure:
|
|
328
289
|
```
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapsible-action-group.d.ts","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/collapsible-action-group.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"collapsible-action-group.d.ts","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/collapsible-action-group.ts"],"names":[],"mappings":";AAMA,wBAiKE"}
|
|
@@ -1,19 +1,16 @@
|
|
|
1
1
|
import { css } from 'lit';
|
|
2
|
-
const
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
const blackFill = css `var(--primaryBGColor, var(--ia-color-surface-theater--))`;
|
|
6
|
-
const blackText = css `var(--primaryBGColor, var(--ia-color-text-primary--))`;
|
|
7
|
-
const dropdownBGColor = css `var(--iaBookActionsDropdownBGColor, var(--ia-color-surface-inverse--))`;
|
|
2
|
+
const whiteColor = css `var(--white, #fff)`;
|
|
3
|
+
const blackColor = css `var(--primaryBGColor, #000)`;
|
|
4
|
+
const dropdownBGColor = css `var(--iaBookActionsDropdownBGColor, #2d2d2d)`;
|
|
8
5
|
export default css `
|
|
9
6
|
:host {
|
|
10
7
|
display: inline-flex;
|
|
11
|
-
height:
|
|
12
|
-
padding:
|
|
8
|
+
height: 3.5rem;
|
|
9
|
+
padding: 1rem 0;
|
|
13
10
|
}
|
|
14
11
|
.actiongroup {
|
|
15
12
|
display: flex;
|
|
16
|
-
margin-right:
|
|
13
|
+
margin-right: 10px;
|
|
17
14
|
}
|
|
18
15
|
.action-buttons {
|
|
19
16
|
display: inline-flex;
|
|
@@ -21,30 +18,30 @@ export default css `
|
|
|
21
18
|
}
|
|
22
19
|
.action-buttons .ia-button {
|
|
23
20
|
margin: 0;
|
|
24
|
-
height:
|
|
25
|
-
padding: 0
|
|
21
|
+
height: 3.5rem;
|
|
22
|
+
padding: 0 2rem;
|
|
26
23
|
}
|
|
27
24
|
.action-buttons .desktop {
|
|
28
|
-
background-color: ${
|
|
29
|
-
border-radius:
|
|
25
|
+
background-color: ${whiteColor};
|
|
26
|
+
border-radius: 10px;
|
|
30
27
|
}
|
|
31
28
|
.action-buttons .desktop.purchase {
|
|
32
|
-
margin-left:
|
|
29
|
+
margin-left: 5px;
|
|
33
30
|
}
|
|
34
31
|
.action-buttons .mobile.purchase.dark {
|
|
35
32
|
padding-left: 0;
|
|
36
33
|
}
|
|
37
34
|
.primary {
|
|
38
|
-
background-color: ${
|
|
35
|
+
background-color: ${whiteColor};
|
|
39
36
|
margin-right: 4px;
|
|
40
37
|
}
|
|
41
38
|
.primary,
|
|
42
39
|
.secondary {
|
|
43
40
|
position: relative;
|
|
44
|
-
border-radius:
|
|
41
|
+
border-radius: 5px;
|
|
45
42
|
}
|
|
46
43
|
.primary .initial {
|
|
47
|
-
border-radius:
|
|
44
|
+
border-radius: 4px 0 0 4px;
|
|
48
45
|
margin-right: 0;
|
|
49
46
|
}
|
|
50
47
|
.primary svg {
|
|
@@ -52,44 +49,44 @@ export default css `
|
|
|
52
49
|
}
|
|
53
50
|
|
|
54
51
|
.secondary .ia-button.purchase {
|
|
55
|
-
padding: 2px
|
|
52
|
+
padding: 2px 10px 2px 35px;
|
|
56
53
|
position: relative;
|
|
57
54
|
display: inline-block;
|
|
58
55
|
vertical-align: middle;
|
|
59
56
|
}
|
|
60
57
|
.secondary .ia-button.exit-admin {
|
|
61
|
-
background-color: ${
|
|
62
|
-
border:
|
|
58
|
+
background-color: ${blackColor};
|
|
59
|
+
border: 1px solid ${whiteColor};
|
|
63
60
|
}
|
|
64
61
|
|
|
65
62
|
.dropdown-content {
|
|
66
63
|
position: absolute;
|
|
67
|
-
min-width:
|
|
64
|
+
min-width: 14rem;
|
|
68
65
|
margin: 0;
|
|
69
66
|
padding: 0;
|
|
70
67
|
background: ${dropdownBGColor};
|
|
71
|
-
border-radius:
|
|
72
|
-
border:
|
|
73
|
-
top:
|
|
68
|
+
border-radius: 4px;
|
|
69
|
+
border: 1px solid var(--primaryCTABorder);
|
|
70
|
+
top: 3.4rem;
|
|
74
71
|
left: 50%;
|
|
75
72
|
-webkit-transform: translateX(-50%);
|
|
76
73
|
transform: translateX(-50%);
|
|
77
74
|
}
|
|
78
75
|
.dropdown-content li {
|
|
79
|
-
color: ${
|
|
76
|
+
color: ${blackColor};
|
|
80
77
|
list-style: none;
|
|
81
|
-
height:
|
|
78
|
+
height: 3rem;
|
|
82
79
|
}
|
|
83
80
|
.dropdown-content .ia-button {
|
|
84
81
|
background: none;
|
|
85
|
-
color: ${
|
|
82
|
+
color: ${whiteColor};
|
|
86
83
|
border: none;
|
|
87
84
|
box-sizing: border-box;
|
|
88
85
|
width: 100%;
|
|
89
86
|
text-align: left;
|
|
90
|
-
height:
|
|
87
|
+
height: 3rem;
|
|
91
88
|
position: relative;
|
|
92
|
-
padding:
|
|
89
|
+
padding: 0.6rem 1.2rem;
|
|
93
90
|
margin: 0;
|
|
94
91
|
}
|
|
95
92
|
.dropdown-content .ia-button:is(:focus-visible, :hover) {
|
|
@@ -99,37 +96,37 @@ export default css `
|
|
|
99
96
|
border-radius: 0;
|
|
100
97
|
}
|
|
101
98
|
.dropdown-content li .ia-button:hover {
|
|
102
|
-
background: ${
|
|
103
|
-
color:
|
|
99
|
+
background: ${whiteColor};
|
|
100
|
+
color: rgb(45, 45, 45);
|
|
104
101
|
}
|
|
105
102
|
.dropdown-content li:first-child .ia-button {
|
|
106
|
-
border-radius:
|
|
103
|
+
border-radius: 0.3rem 0.3rem 0 0;
|
|
107
104
|
}
|
|
108
105
|
.dropdown-content li:last-child .ia-button {
|
|
109
106
|
border-radius: 0;
|
|
110
|
-
border-radius: 0 0
|
|
107
|
+
border-radius: 0 0 0.3rem 0.3rem;
|
|
111
108
|
}
|
|
112
109
|
.dropdown-content .purchase:hover svg g {
|
|
113
|
-
fill:
|
|
110
|
+
fill: black;
|
|
114
111
|
}
|
|
115
112
|
.dropdown-content .purchase {
|
|
116
|
-
padding-left:
|
|
113
|
+
padding-left: 35px;
|
|
117
114
|
margin: 0;
|
|
118
115
|
}
|
|
119
116
|
.dropdown-content .purchase small {
|
|
120
117
|
display: initial;
|
|
121
|
-
font-size:
|
|
118
|
+
font-size: 1.4rem;
|
|
122
119
|
}
|
|
123
120
|
|
|
124
121
|
.ia-button.down-arrow {
|
|
125
|
-
border-radius: 0
|
|
126
|
-
padding: 0
|
|
122
|
+
border-radius: 0 0.4rem 0.4rem 0;
|
|
123
|
+
padding: 0 0.6rem;
|
|
127
124
|
margin-left: 0;
|
|
128
125
|
}
|
|
129
126
|
.actionloader {
|
|
130
127
|
vertical-align: middle;
|
|
131
128
|
visibility: hidden;
|
|
132
|
-
padding:
|
|
129
|
+
padding: 0.9rem 0.2rem;
|
|
133
130
|
}
|
|
134
131
|
.close {
|
|
135
132
|
display: none;
|
|
@@ -143,18 +140,18 @@ export default css `
|
|
|
143
140
|
}
|
|
144
141
|
.btn:hover,
|
|
145
142
|
.dropdown:hover .btn {
|
|
146
|
-
background-color: ${
|
|
143
|
+
background-color: ${whiteColor};
|
|
147
144
|
}
|
|
148
145
|
a {
|
|
149
146
|
text-decoration: none;
|
|
150
147
|
}
|
|
151
148
|
.purchase small {
|
|
152
149
|
display: block;
|
|
153
|
-
font-size:
|
|
150
|
+
font-size: 1rem;
|
|
154
151
|
}
|
|
155
152
|
.purchase svg {
|
|
156
153
|
position: absolute;
|
|
157
|
-
left:
|
|
154
|
+
left: 10px;
|
|
158
155
|
top: 20%;
|
|
159
156
|
}
|
|
160
157
|
.unavailable {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"collapsible-action-group.js","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/collapsible-action-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,MAAM,
|
|
1
|
+
{"version":3,"file":"collapsible-action-group.js","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/collapsible-action-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,MAAM,UAAU,GAAG,GAAG,CAAA,oBAAoB,CAAC;AAC3C,MAAM,UAAU,GAAG,GAAG,CAAA,6BAA6B,CAAC;AACpD,MAAM,eAAe,GAAG,GAAG,CAAA,8CAA8C,CAAC;AAE1E,eAAe,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;wBAoBM,UAAU;;;;;;;;;;wBAUV,UAAU;;;;;;;;;;;;;;;;;;;;;;;wBAuBV,UAAU;wBACV,UAAU;;;;;;;;kBAQhB,eAAe;;;;;;;;;aASpB,UAAU;;;;;;aAMV,UAAU;;;;;;;;;;;;;;;;;kBAiBL,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBA4CJ,UAAU;;;;;;;;;;;;;;;;;;;;;;;CAuBjC,CAAC","sourcesContent":["import { css } from 'lit';\n\nconst whiteColor = css`var(--white, #fff)`;\nconst blackColor = css`var(--primaryBGColor, #000)`;\nconst dropdownBGColor = css`var(--iaBookActionsDropdownBGColor, #2d2d2d)`;\n\nexport default css`\n :host {\n display: inline-flex;\n height: 3.5rem;\n padding: 1rem 0;\n }\n .actiongroup {\n display: flex;\n margin-right: 10px;\n }\n .action-buttons {\n display: inline-flex;\n align-items: center;\n }\n .action-buttons .ia-button {\n margin: 0;\n height: 3.5rem;\n padding: 0 2rem;\n }\n .action-buttons .desktop {\n background-color: ${whiteColor};\n border-radius: 10px;\n }\n .action-buttons .desktop.purchase {\n margin-left: 5px;\n }\n .action-buttons .mobile.purchase.dark {\n padding-left: 0;\n }\n .primary {\n background-color: ${whiteColor};\n margin-right: 4px;\n }\n .primary,\n .secondary {\n position: relative;\n border-radius: 5px;\n }\n .primary .initial {\n border-radius: 4px 0 0 4px;\n margin-right: 0;\n }\n .primary svg {\n vertical-align: middle;\n }\n\n .secondary .ia-button.purchase {\n padding: 2px 10px 2px 35px;\n position: relative;\n display: inline-block;\n vertical-align: middle;\n }\n .secondary .ia-button.exit-admin {\n background-color: ${blackColor};\n border: 1px solid ${whiteColor};\n }\n\n .dropdown-content {\n position: absolute;\n min-width: 14rem;\n margin: 0;\n padding: 0;\n background: ${dropdownBGColor};\n border-radius: 4px;\n border: 1px solid var(--primaryCTABorder);\n top: 3.4rem;\n left: 50%;\n -webkit-transform: translateX(-50%);\n transform: translateX(-50%);\n }\n .dropdown-content li {\n color: ${blackColor};\n list-style: none;\n height: 3rem;\n }\n .dropdown-content .ia-button {\n background: none;\n color: ${whiteColor};\n border: none;\n box-sizing: border-box;\n width: 100%;\n text-align: left;\n height: 3rem;\n position: relative;\n padding: 0.6rem 1.2rem;\n margin: 0;\n }\n .dropdown-content .ia-button:is(:focus-visible, :hover) {\n background: unset;\n }\n .dropdown-content li .ia-button {\n border-radius: 0;\n }\n .dropdown-content li .ia-button:hover {\n background: ${whiteColor};\n color: rgb(45, 45, 45);\n }\n .dropdown-content li:first-child .ia-button {\n border-radius: 0.3rem 0.3rem 0 0;\n }\n .dropdown-content li:last-child .ia-button {\n border-radius: 0;\n border-radius: 0 0 0.3rem 0.3rem;\n }\n .dropdown-content .purchase:hover svg g {\n fill: black;\n }\n .dropdown-content .purchase {\n padding-left: 35px;\n margin: 0;\n }\n .dropdown-content .purchase small {\n display: initial;\n font-size: 1.4rem;\n }\n\n .ia-button.down-arrow {\n border-radius: 0 0.4rem 0.4rem 0;\n padding: 0 0.6rem;\n margin-left: 0;\n }\n .actionloader {\n vertical-align: middle;\n visibility: hidden;\n padding: 0.9rem 0.2rem;\n }\n .close {\n display: none;\n }\n .open {\n display: block;\n z-index: 2;\n }\n .visible {\n display: inline-block;\n }\n .btn:hover,\n .dropdown:hover .btn {\n background-color: ${whiteColor};\n }\n a {\n text-decoration: none;\n }\n .purchase small {\n display: block;\n font-size: 1rem;\n }\n .purchase svg {\n position: absolute;\n left: 10px;\n top: 20%;\n }\n .unavailable {\n opacity: 0.7;\n pointer-events: none;\n }\n .disabled {\n opacity: 0.8;\n pointer-events: none;\n visibility: visible;\n }\n`;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ia-button.d.ts","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/ia-button.ts"],"names":[],"mappings":";
|
|
1
|
+
{"version":3,"file":"ia-button.d.ts","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/ia-button.ts"],"names":[],"mappings":";AAqBA,wBAqFE"}
|
|
@@ -1,30 +1,28 @@
|
|
|
1
1
|
import { css } from 'lit';
|
|
2
|
-
const
|
|
3
|
-
const
|
|
4
|
-
const
|
|
5
|
-
const
|
|
6
|
-
const primaryButtonFillColor = css `var(--primaryCTAFill, var(--ia-color-action-primary-fill--))`;
|
|
2
|
+
const whiteColor = css `var(--white, #fff)`;
|
|
3
|
+
const disabledButtonFillColor = css `var(--primaryDisableCTAFill, #767676)`;
|
|
4
|
+
const disabledButtonBorderColor = css `var(--secondaryCTABorder, #999)`;
|
|
5
|
+
const primaryButtonFillColor = css `var(--primaryCTAFill, #194880)`;
|
|
7
6
|
const primaryButtonFillColorRGB = css `var(--primaryCTAFillRGB, 25, 72, 128)`; // RBG format of --primaryCTAFill
|
|
8
|
-
const primaryButtonBorderColor = css `var(--primaryCTABorder,
|
|
9
|
-
const dangerButtonFillColor = css `var(--primaryErrorCTAFill,
|
|
7
|
+
const primaryButtonBorderColor = css `var(--primaryCTABorder, #c5d1df)`;
|
|
8
|
+
const dangerButtonFillColor = css `var(--primaryErrorCTAFill, #d9534f)`;
|
|
10
9
|
const dangerButtonFillColorRGB = css `var(--primaryErrorCTAFillRGB, 229, 28, 38)`; // RBG format of --primaryErrorCTAFill
|
|
11
|
-
const dangerButtonBorderColor = css `var(--primaryErrorCTABorder,
|
|
12
|
-
const darkButtonFillColor = css `var(--secondaryCTAFill,
|
|
10
|
+
const dangerButtonBorderColor = css `var(--primaryErrorCTABorder, #d43f3a)`;
|
|
11
|
+
const darkButtonFillColor = css `var(--secondaryCTAFill, #333)`;
|
|
13
12
|
const darkButtonFillColorRGB = css `var(--secondaryCTAFillRGB, 51, 51, 51)`; // RBG format of --secondaryCTAFill
|
|
14
|
-
const darkButtonBorderColor = css `var(--primaryCTABorder,
|
|
15
|
-
const warningButtonBGColor = css
|
|
16
|
-
const warningButtonBorderColor = css
|
|
17
|
-
const warningButtonTextColor = css `var(--ia-color-action-warning-text--)`;
|
|
13
|
+
const darkButtonBorderColor = css `var(--primaryCTABorder, #979797)`;
|
|
14
|
+
const warningButtonBGColor = css `#ee8950`;
|
|
15
|
+
const warningButtonBorderColor = css `#ec7939`;
|
|
18
16
|
export default css `
|
|
19
17
|
.ia-button {
|
|
20
|
-
min-height:
|
|
18
|
+
min-height: 3rem;
|
|
21
19
|
cursor: pointer;
|
|
22
|
-
color: ${
|
|
20
|
+
color: ${whiteColor};
|
|
23
21
|
line-height: normal;
|
|
24
|
-
border-radius:
|
|
25
|
-
font-size:
|
|
22
|
+
border-radius: 0.4rem;
|
|
23
|
+
font-size: 1.4rem;
|
|
26
24
|
font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
|
|
27
|
-
border:
|
|
25
|
+
border: 1px solid transparent;
|
|
28
26
|
white-space: nowrap;
|
|
29
27
|
appearance: auto;
|
|
30
28
|
box-sizing: border-box;
|
|
@@ -32,9 +30,9 @@ export default css `
|
|
|
32
30
|
align-items: center;
|
|
33
31
|
transition: all 0.1s ease 0s;
|
|
34
32
|
vertical-align: middle;
|
|
35
|
-
padding: 0
|
|
36
|
-
outline-color: ${
|
|
37
|
-
outline-offset:
|
|
33
|
+
padding: 0 1rem;
|
|
34
|
+
outline-color: ${whiteColor};
|
|
35
|
+
outline-offset: -4px;
|
|
38
36
|
user-select: none;
|
|
39
37
|
text-decoration: none;
|
|
40
38
|
width: fit-content;
|
|
@@ -49,18 +47,14 @@ export default css `
|
|
|
49
47
|
.ia-button:disabled {
|
|
50
48
|
cursor: not-allowed;
|
|
51
49
|
background-color: ${disabledButtonFillColor};
|
|
52
|
-
border:
|
|
50
|
+
border: 1px solid ${disabledButtonBorderColor};
|
|
53
51
|
}
|
|
54
52
|
.ia-button.transparent {
|
|
55
53
|
background-color: transparent;
|
|
56
54
|
}
|
|
57
|
-
/* Dark text: white on the amber fill is about 1.9:1. The white focus ring
|
|
58
|
-
would vanish against it too, so it takes the light-surface ring. */
|
|
59
55
|
.ia-button.warning {
|
|
60
|
-
background-color: ${warningButtonBGColor}
|
|
56
|
+
background-color: ${warningButtonBGColor}
|
|
61
57
|
border-color: ${warningButtonBorderColor};
|
|
62
|
-
color: ${warningButtonTextColor};
|
|
63
|
-
outline-color: var(--ia-color-border-focus--);
|
|
64
58
|
}
|
|
65
59
|
|
|
66
60
|
.ia-button.primary {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ia-button.js","sourceRoot":"","sources":["../../../../../../src/elements/ia-book-actions/assets/styles/ia-button.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,KAAK,CAAC;AAE1B,MAAM,
|
|
1
|
+
{"version":3,"file":"ia-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AwB;;;6BAGxB,wBAAwB;;;;wBAI7B,mBAAmB;oBACvB,qBAAqB;;;6BAGZ,sBAAsB;;;6BAGtB,sBAAsB;;;6BAGtB,sBAAsB;;CAElD,CAAC","sourcesContent":["import { css } from 'lit';\n\nconst whiteColor = css`var(--white, #fff)`;\nconst disabledButtonFillColor = css`var(--primaryDisableCTAFill, #767676)`;\nconst disabledButtonBorderColor = css`var(--secondaryCTABorder, #999)`;\n\nconst primaryButtonFillColor = css`var(--primaryCTAFill, #194880)`;\nconst primaryButtonFillColorRGB = css`var(--primaryCTAFillRGB, 25, 72, 128)`; // RBG format of --primaryCTAFill\nconst primaryButtonBorderColor = css`var(--primaryCTABorder, #c5d1df)`;\n\nconst dangerButtonFillColor = css`var(--primaryErrorCTAFill, #d9534f)`;\nconst dangerButtonFillColorRGB = css`var(--primaryErrorCTAFillRGB, 229, 28, 38)`; // RBG format of --primaryErrorCTAFill\nconst dangerButtonBorderColor = css`var(--primaryErrorCTABorder, #d43f3a)`;\n\nconst darkButtonFillColor = css`var(--secondaryCTAFill, #333)`;\nconst darkButtonFillColorRGB = css`var(--secondaryCTAFillRGB, 51, 51, 51)`; // RBG format of --secondaryCTAFill\nconst darkButtonBorderColor = css`var(--primaryCTABorder, #979797)`;\n\nconst warningButtonBGColor = css`#ee8950`;\nconst warningButtonBorderColor = css`#ec7939`;\n\nexport default css`\n .ia-button {\n min-height: 3rem;\n cursor: pointer;\n color: ${whiteColor};\n line-height: normal;\n border-radius: 0.4rem;\n font-size: 1.4rem;\n font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;\n border: 1px solid transparent;\n white-space: nowrap;\n appearance: auto;\n box-sizing: border-box;\n display: flex;\n align-items: center;\n transition: all 0.1s ease 0s;\n vertical-align: middle;\n padding: 0 1rem;\n outline-color: ${whiteColor};\n outline-offset: -4px;\n user-select: none;\n text-decoration: none;\n width: fit-content;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n -o-user-select: none;\n }\n .ia-button:focus-visible {\n outline-style: double;\n }\n .ia-button:disabled {\n cursor: not-allowed;\n background-color: ${disabledButtonFillColor};\n border: 1px solid ${disabledButtonBorderColor};\n }\n .ia-button.transparent {\n background-color: transparent;\n }\n .ia-button.warning {\n background-color: ${warningButtonBGColor}\n border-color: ${warningButtonBorderColor};\n }\n\n .ia-button.primary {\n background-color: ${primaryButtonFillColor};\n border-color: ${primaryButtonBorderColor};\n }\n .ia-button.primary:hover {\n background-color: rgba(${primaryButtonFillColorRGB}, 0.9);\n }\n .ia-button.primary:focus-visible {\n background-color: rgba(${primaryButtonFillColorRGB}, 0.8);\n }\n .ia-button.primary:active {\n background-color: rgba(${primaryButtonFillColorRGB}, 0.7);\n }\n\n .ia-button.danger {\n background-color: ${dangerButtonFillColor};\n border-color: ${dangerButtonBorderColor};\n }\n .ia-button.danger:hover {\n background-color: rgba(${dangerButtonFillColorRGB}, 0.9);\n }\n .ia-button.danger:focus-visible {\n background-color: rgba(${dangerButtonFillColorRGB}, 0.8);\n }\n .ia-button.danger:active {\n background-color: rgba(${dangerButtonFillColorRGB}, 0.7);\n }\n\n .ia-button.dark {\n background-color: ${darkButtonFillColor};\n border-color: ${darkButtonBorderColor};\n }\n .ia-button.dark:hover {\n background-color: rgba(${darkButtonFillColorRGB}, 0.9);\n }\n .ia-button.dark:focus-visible {\n background-color: rgba(${darkButtonFillColorRGB}, 0.8);\n }\n .ia-button.dark:active {\n background-color: rgba(${darkButtonFillColorRGB}, 0.7);\n }\n`;\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ia-book-actions-collapsible-action-group.d.ts","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,OAAO,EACP,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,KAAK,CAAC;AAKb,OAAO,cAAc,MAAM,iDAAiD,CAAC;AAQ7E,OAAO,KAAK,EAEV,YAAY,EACZ,cAAc,EACd,UAAU,EACX,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"ia-book-actions-collapsible-action-group.d.ts","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,OAAO,EACP,KAAK,cAAc,EACnB,KAAK,cAAc,EACnB,KAAK,cAAc,EACpB,MAAM,KAAK,CAAC;AAKb,OAAO,cAAc,MAAM,iDAAiD,CAAC;AAQ7E,OAAO,KAAK,EAEV,YAAY,EACZ,cAAc,EACd,UAAU,EACX,MAAM,UAAU,CAAC;AAElB,qBACa,mCAAoC,SAAQ,cAAc;IACzC,MAAM,SAAM;IAEZ,UAAU,SAAM;IAEjB,cAAc,EAAE,YAAY,EAAE,CAAM;IAEpC,gBAAgB,EAAE,YAAY,EAAE,CAAM;IAErC,YAAY,SAAM;IAElB,aAAa,EAAE,MAAM,GAAG,OAAO,CAAW;IAE1C,KAAK,SAAK;IAET,cAAc,UAAS;IAEpB,aAAa,EAAE,cAAc,CAC5C;IAEY,QAAQ,UAAS;IAElB,SAAS,SAAM;IAEd,SAAS,UAAS;IAEnB,aAAa,SAAM;IAElB,UAAU,UAAS;IAEnB,SAAS,UAAS;IAE/C,sDAAsD;IAC1B,UAAU,SACiB;IAEvD,iCAAiC;IACjC,UAAU,CAAC,EAAE,UAAU,GAAG,IAAI,CAAC;IAE/B,aAAa,UAAS;IAEtB,OAAO,CAAC,OAAO,EAAE,cAAc,CAAC,IAAI,CAAC,GAAG,IAAI;IAsB5C;;;;;;OAMG;IACH,iBAAiB,CACf,KAAK,EAAE,WAAW,GAAG,YAAY,GAAG,WAAW,EAC/C,MAAM,CAAC,EAAE;QAAE,SAAS,CAAC,EAAE,MAAM,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,CAAA;KAAE,GACnD,IAAI;IAIP;;OAEG;IACH,YAAY,IAAI,IAAI;IAgBpB;;OAEG;IACH,qBAAqB,IAAI,IAAI;IAkB7B,MAAM;IAmBN,IAAI,oBAAoB,uCAyBvB;IAED,IAAI,sBAAsB,yCAMzB;IAED;;;;OAIG;IACH,gBAAgB,CAAC,MAAM,EAAE,YAAY,EAAE,aAAa,UAAQ;IAoB5D;;;;OAIG;IACH,kBAAkB,CAAC,MAAM,EAAE,YAAY,EAAE,aAAa,UAAQ;IAa9D;;;;;;OAMG;IACH,YAAY,CACV,SAAS,EAAE,MAAM,EACjB,OAAO,CAAC,EAAE,cAAc,EACxB,UAAU,SAAK,GACd,IAAI;IAgBP;;OAEG;IACH,IAAI,qBAAqB,sBAOxB;IAED,IAAI,eAAe,wBAOlB;IAED;;OAEG;IACH,IAAI,aAAa,sBAShB;IAED;;OAEG;IACH,IAAI,sBAAsB,IAAI,OAAO,CAEpC;IAED;;;OAGG;IACH,IAAI,aAAa,IAAI,QAAQ,GAAG,SAAS,CAExC;IAED;;OAEG;IACH,cAAc,IAAI,IAAI;IAYtB,MAAM,KAAK,MAAM,IAAI,cAAc,CAElC;CACF;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,0CAA0C,EAAE,mCAAmC,CAAC;KACjF;CACF"}
|
|
@@ -9,7 +9,6 @@ import CollapsibleActionGroupStyle from './assets/styles/collapsible-action-grou
|
|
|
9
9
|
import { tabletContainerWidth } from './core/config/constants.js';
|
|
10
10
|
import { purchaseIcon } from './assets/data/purchase.js';
|
|
11
11
|
import { dropdownOpened, dropdownClosed } from './assets/data/dropdown-arrow.js';
|
|
12
|
-
import { tokenStyles } from '../../themes/tokens.js';
|
|
13
12
|
let IABookActionsCollapsibleActionGroup = class IABookActionsCollapsibleActionGroup extends ActionsHandler {
|
|
14
13
|
constructor() {
|
|
15
14
|
super(...arguments);
|
|
@@ -251,7 +250,7 @@ let IABookActionsCollapsibleActionGroup = class IABookActionsCollapsibleActionGr
|
|
|
251
250
|
}
|
|
252
251
|
}
|
|
253
252
|
static get styles() {
|
|
254
|
-
return [
|
|
253
|
+
return [buttonBaseStyle, CollapsibleActionGroupStyle];
|
|
255
254
|
}
|
|
256
255
|
};
|
|
257
256
|
__decorate([
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ia-book-actions-collapsible-action-group.js","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,IAAI,EACJ,OAAO,GAIR,MAAM,KAAK,CAAC;AACb,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,cAAc,MAAM,iDAAiD,CAAC;AAE7E,OAAO,eAAe,MAAM,2BAA2B,CAAC;AACxD,OAAO,2BAA2B,MAAM,0CAA0C,CAAC;AAEnF,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AAO9E,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAG1C,IAAM,mCAAmC,GAAzC,MAAM,mCAAoC,SAAQ,cAAc;IAAhE;;QACuB,WAAM,GAAG,EAAE,CAAC;QAEZ,eAAU,GAAG,EAAE,CAAC;QAEjB,mBAAc,GAAmB,EAAE,CAAC;QAEpC,qBAAgB,GAAmB,EAAE,CAAC;QAErC,iBAAY,GAAG,EAAE,CAAC;QAElB,kBAAa,GAAqB,OAAO,CAAC;QAE1C,UAAK,GAAG,CAAC,CAAC;QAET,mBAAc,GAAG,KAAK,CAAC;QAEpB,kBAAa,GAC3C,cAAc,CAAC;QAEY,aAAQ,GAAG,KAAK,CAAC;QAElB,cAAS,GAAG,EAAE,CAAC;QAEd,cAAS,GAAG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AAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;uEAC4B;AAlC5C,mCAAmC;IAD/C,aAAa,CAAC,0CAA0C,CAAC;GAC7C,mCAAmC,CAqT/C","sourcesContent":["import {\n html,\n nothing,\n type CSSResultGroup,\n type PropertyValues,\n type TemplateResult,\n} from 'lit';\nimport { property } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { customElement } from '@src/utils/custom-element';\n\nimport ActionsHandler from './core/services/actions-handler/actions-handler';\n\nimport buttonBaseStyle from './assets/styles/ia-button';\nimport CollapsibleActionGroupStyle from './assets/styles/collapsible-action-group';\n\nimport { tabletContainerWidth } from './core/config/constants';\nimport { purchaseIcon } from './assets/data/purchase';\nimport { dropdownOpened, dropdownClosed } from './assets/data/dropdown-arrow';\nimport type {\n ActionClickDetail,\n ActionConfig,\n AnalyticsEvent,\n BorrowType,\n} from './models';\nimport { tokenStyles } from '@src/themes/tokens';\n\n@customElement('ia-book-actions-collapsible-action-group')\nexport class IABookActionsCollapsibleActionGroup extends ActionsHandler {\n @property({ type: String }) userid = '';\n\n @property({ type: String }) identifier = '';\n\n @property({ type: Array }) primaryActions: ActionConfig[] = [];\n\n @property({ type: Array }) secondaryActions: ActionConfig[] = [];\n\n @property({ type: String }) primaryColor = '';\n\n @property({ type: String }) dropdownState: 'open' | 'close' = 'close';\n\n @property({ type: Number }) width = 0;\n\n @property({ type: Boolean }) hasAdminAccess = false;\n\n @property({ attribute: false }) dropdownArrow: TemplateResult =\n dropdownClosed;\n\n @property({ type: Boolean }) disabled = false;\n\n @property({ type: String }) returnUrl = '';\n\n @property({ type: Boolean }) autoRenew = false;\n\n @property({ type: String }) loanRenewType = '';\n\n @property({ type: Boolean }) autoReturn = false;\n\n @property({ type: Boolean }) returnNow = false;\n\n /** The image shown while an action is in progress. */\n @property({ type: String }) loaderIcon =\n 'https://archive.org/upload/images/tree/loading.gif';\n\n /** Set by the parent element. */\n borrowType?: BorrowType | null;\n\n initialButton = false;\n\n updated(changed: PropertyValues<this>): void {\n if (\n (changed.has('width') || changed.has('disabled')) &&\n this.isBelowTabletContainer\n ) {\n this.resetActions();\n }\n\n if (changed.has('autoRenew') && this.autoRenew) {\n this.dispatchLoanEvent('autoRenew', { renewType: this.loanRenewType });\n }\n\n const requestingAutoreturn = changed.has('autoReturn') && this.autoReturn;\n if (requestingAutoreturn) {\n this.dispatchLoanEvent('autoReturn');\n }\n\n if (changed.has('returnNow') && this.returnNow && !requestingAutoreturn) {\n this.dispatchLoanEvent('returnNow', { borrowType: 'browse' });\n }\n }\n\n /**\n * dispatch event when book is auto auto-renewed / auto-returned / returned\n * listen these events in actions-handler.ts to execute ajax call on petabox.\n * @see ActionsHandler\n *\n * @param event - autoRenew|autoReturn|returnNow\n */\n dispatchLoanEvent(\n event: 'autoRenew' | 'autoReturn' | 'returnNow',\n detail?: { renewType?: string; borrowType?: string },\n ): void {\n this.dispatchEvent(new CustomEvent(event, { detail }));\n }\n\n /**\n * merge primaryActions and secondaryActions into dropdown\n */\n resetActions(): void {\n // concat primaryActions and secondaryActions to draw in dropdown list\n if (this.primaryActions.length) {\n this.primaryActions = this.primaryActions.concat(this.secondaryActions);\n\n this.primaryColor = this.primaryActions[0].className;\n\n if (this.hasAdminAccess) {\n this.sortActionButtonOrder();\n }\n\n // remove secondaryActions\n this.secondaryActions = [];\n }\n }\n\n /**\n * re-sort primaryActions action list to show dropdown-only/mobile mode\n */\n sortActionButtonOrder(): void {\n let fromIndex = 1;\n const toIndex = 0;\n if (this.secondaryActions.length === 2) {\n fromIndex = 2;\n }\n\n fromIndex = this.primaryActions.length - fromIndex;\n\n const element = this.primaryActions[fromIndex];\n const current = this.primaryActions;\n\n current.splice(fromIndex, 1);\n current.splice(toIndex, 0, element);\n\n this.primaryActions = current;\n }\n\n render() {\n return html`\n <div\n class=\"${classMap({\n actiongroup: true,\n disabled: this.disabled,\n })}\"\n >\n ${this.getLoaderIcon}\n <section class=\"action-buttons primary\">\n ${this.renderPrimaryActions}\n </section>\n <section class=\"action-buttons secondary\">\n ${this.renderSecondaryActions}\n </section>\n </div>\n `;\n }\n\n get renderPrimaryActions() {\n if (this.primaryActions.length === 0) return nothing;\n\n if (this.dropdownState === 'close') {\n this.primaryColor = this.primaryActions[0].className;\n }\n\n // If its single action, let just not show dropdown list\n if (this.primaryActions.length === 1) {\n return this.initialActionTemplate;\n }\n\n return html`\n ${this.initialActionTemplate}\n <button\n class=\"ia-button ${this.primaryColor} down-arrow\"\n @click=${this.toggleDropdown}\n >\n ${this.dropdownArrow}\n </button>\n\n <ul class=\"dropdown-content ${this.dropdownState}\">\n ${this.getPrimaryItems}\n </ul>\n `;\n }\n\n get renderSecondaryActions() {\n if (!this.secondaryActions.length) return nothing;\n\n return this.secondaryActions.map((action) =>\n this.renderActionButton(action),\n );\n }\n\n /**\n * Render action as a link for secondary actions like admin, printdisability links.\n * @param action\n * @param initialButton\n */\n renderActionLink(action: ActionConfig, initialButton = false) {\n return html`<span class=\"${this.getDeviceType} ${action.className}\">\n <a\n class=\"ia-button ${action.className} ${initialButton ? 'initial' : ''}\"\n href=\"${action.url}\"\n target=${action.target}\n @click=${() => {\n this.clickHandler(\n action.id,\n action.analyticsEvent,\n action?.borrowType,\n );\n }}\n >\n ${action.id === 'purchaseBook' ? purchaseIcon : ''} ${action.text}\n <small>${action.subText}</small>\n </a>\n </span>`;\n }\n\n /**\n * Render action as a button for primary actions like browse, borrow, join waitlist etc...\n * @param action\n * @param initialButton\n */\n renderActionButton(action: ActionConfig, initialButton = false) {\n if (action.url) return this.renderActionLink(action, initialButton);\n const { analyticsEvent } = action;\n return html`<button\n class=\"ia-button ${action.className} ${initialButton ? 'initial' : ''}\"\n @click=${() => {\n this.clickHandler(action.id, analyticsEvent, action?.borrowType);\n }}\n >\n ${action.text}\n </button>`;\n }\n\n /**\n * Dispatches click events when patron clicks on action buttons\n * @param eventName actions like 'browseBook', 'borrowBook' etc...\n * @param gaEvent contains analytics event action and category\n * @param borrowType browse|borrow\n * @fires CollapsibleActionGroup#{eventName} - (will be browseBook, borrowBook etc...)\n */\n clickHandler(\n eventName: string,\n gaEvent?: AnalyticsEvent,\n borrowType = '',\n ): void {\n this.dropdownState = 'close';\n this.dropdownArrow = dropdownClosed;\n\n if (!gaEvent || !eventName) return;\n const { category, action } = gaEvent;\n this.dispatchEvent(\n new CustomEvent<ActionClickDetail>(eventName, {\n detail: {\n event: { category, action },\n borrowType,\n },\n }),\n );\n }\n\n /**\n * get first primary action to render just before dropdown button\n */\n get initialActionTemplate() {\n this.initialButton = false;\n if (this.primaryActions.length > 1) {\n this.initialButton = true;\n }\n\n return this.renderActionButton(this.primaryActions[0], this.initialButton);\n }\n\n get getPrimaryItems() {\n return this.primaryActions\n .slice(1)\n .map(\n (action) =>\n html`<li>${this.renderActionButton(action, this.initialButton)}</li>`,\n );\n }\n\n /**\n * get loader icon when task is in-progress\n */\n get getLoaderIcon() {\n return html`<img\n class=\"${classMap({\n actionloader: true,\n disabled: this.disabled,\n })}\"\n alt=\"\"\n src=\"${this.loaderIcon}\"\n />`;\n }\n\n /**\n * check if device is below tablet\n */\n get isBelowTabletContainer(): boolean {\n return this.width <= tabletContainerWidth;\n }\n\n /**\n * get device type as per container width\n * @returns mobile | desktop\n */\n get getDeviceType(): 'mobile' | 'desktop' {\n return this.isBelowTabletContainer ? 'mobile' : 'desktop';\n }\n\n /**\n * toggle dropdown and its icon state\n */\n toggleDropdown(): void {\n if (this.dropdownState === 'open') {\n this.dropdownState = 'close';\n this.dropdownArrow = dropdownClosed;\n this.primaryColor = this.primaryActions[0].className;\n } else {\n this.dropdownState = 'open';\n this.dropdownArrow = dropdownOpened;\n this.primaryColor = 'dark';\n }\n }\n\n static get styles(): CSSResultGroup {\n return [tokenStyles, buttonBaseStyle, CollapsibleActionGroupStyle];\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'ia-book-actions-collapsible-action-group': IABookActionsCollapsibleActionGroup;\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"ia-book-actions-collapsible-action-group.js","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-collapsible-action-group.ts"],"names":[],"mappings":";AAAA,OAAO,EACL,IAAI,EACJ,OAAO,GAIR,MAAM,KAAK,CAAC;AACb,OAAO,EAAE,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAC7C,OAAO,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AACvD,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,cAAc,MAAM,iDAAiD,CAAC;AAE7E,OAAO,eAAe,MAAM,2BAA2B,CAAC;AACxD,OAAO,2BAA2B,MAAM,0CAA0C,CAAC;AAEnF,OAAO,EAAE,oBAAoB,EAAE,MAAM,yBAAyB,CAAC;AAC/D,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,8BAA8B,CAAC;AASvE,IAAM,mCAAmC,GAAzC,MAAM,mCAAoC,SAAQ,cAAc;IAAhE;;QACuB,WAAM,GAAG,EAAE,CAAC;QAEZ,eAAU,GAAG,EAAE,CAAC;QAEjB,mBAAc,GAAmB,EAAE,CAAC;QAEpC,qBAAgB,GAAmB,EAAE,CAAC;QAErC,iBAAY,GAAG,EAAE,CAAC;QAElB,kBAAa,GAAqB,OAAO,CAAC;QAE1C,UAAK,GAAG,CAAC,CAAC;QAET,mBAAc,GAAG,KAAK,CAAC;QAEpB,kBAAa,GAC3C,cAAc,CAAC;QAEY,aAAQ,GAAG,KAAK,CAAC;QAElB,cAAS,GAAG,EAAE,CAAC;QAEd,cAAS,GAAG,KAAK,CAAC;QAEnB,kBAAa,GAAG,EAAE,CAAC;QAElB,eAAU,GAAG,KAAK,CAAC;QAEnB,cAAS,GAAG,KAAK,CAAC;QAE/C,sDAAsD;QAC1B,eAAU,GACpC,oDAAoD,CAAC;QAKvD,kBAAa,GAAG,KAAK,CAAC;IA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';\nimport { property } from 'lit/decorators.js';\nimport { classMap } from 'lit/directives/class-map.js';\nimport { customElement } from '@src/utils/custom-element';\n\nimport ActionsHandler from './core/services/actions-handler/actions-handler';\n\nimport buttonBaseStyle from './assets/styles/ia-button';\nimport CollapsibleActionGroupStyle from './assets/styles/collapsible-action-group';\n\nimport { tabletContainerWidth } from './core/config/constants';\nimport { purchaseIcon } from './assets/data/purchase';\nimport { dropdownOpened, dropdownClosed } from './assets/data/dropdown-arrow';\nimport type {\n ActionClickDetail,\n ActionConfig,\n AnalyticsEvent,\n BorrowType,\n} from './models';\n\n@customElement('ia-book-actions-collapsible-action-group')\nexport class IABookActionsCollapsibleActionGroup extends ActionsHandler {\n @property({ type: String }) userid = '';\n\n @property({ type: String }) identifier = '';\n\n @property({ type: Array }) primaryActions: ActionConfig[] = [];\n\n @property({ type: Array }) secondaryActions: ActionConfig[] = [];\n\n @property({ type: String }) primaryColor = '';\n\n @property({ type: String }) dropdownState: 'open' | 'close' = 'close';\n\n @property({ type: Number }) width = 0;\n\n @property({ type: Boolean }) hasAdminAccess = false;\n\n @property({ attribute: false }) dropdownArrow: TemplateResult =\n dropdownClosed;\n\n @property({ type: Boolean }) disabled = false;\n\n @property({ type: String }) returnUrl = '';\n\n @property({ type: Boolean }) autoRenew = false;\n\n @property({ type: String }) loanRenewType = '';\n\n @property({ type: Boolean }) autoReturn = false;\n\n @property({ type: Boolean }) returnNow = false;\n\n /** The image shown while an action is in progress. */\n @property({ type: String }) loaderIcon =\n 'https://archive.org/upload/images/tree/loading.gif';\n\n /** Set by the parent element. */\n borrowType?: BorrowType | null;\n\n initialButton = false;\n\n updated(changed: PropertyValues<this>): void {\n if (\n (changed.has('width') || changed.has('disabled')) &&\n this.isBelowTabletContainer\n ) {\n this.resetActions();\n }\n\n if (changed.has('autoRenew') && this.autoRenew) {\n this.dispatchLoanEvent('autoRenew', { renewType: this.loanRenewType });\n }\n\n const requestingAutoreturn = changed.has('autoReturn') && this.autoReturn;\n if (requestingAutoreturn) {\n this.dispatchLoanEvent('autoReturn');\n }\n\n if (changed.has('returnNow') && this.returnNow && !requestingAutoreturn) {\n this.dispatchLoanEvent('returnNow', { borrowType: 'browse' });\n }\n }\n\n /**\n * dispatch event when book is auto auto-renewed / auto-returned / returned\n * listen these events in actions-handler.ts to execute ajax call on petabox.\n * @see ActionsHandler\n *\n * @param event - autoRenew|autoReturn|returnNow\n */\n dispatchLoanEvent(\n event: 'autoRenew' | 'autoReturn' | 'returnNow',\n detail?: { renewType?: string; borrowType?: string },\n ): void {\n this.dispatchEvent(new CustomEvent(event, { detail }));\n }\n\n /**\n * merge primaryActions and secondaryActions into dropdown\n */\n resetActions(): void {\n // concat primaryActions and secondaryActions to draw in dropdown list\n if (this.primaryActions.length) {\n this.primaryActions = this.primaryActions.concat(this.secondaryActions);\n\n this.primaryColor = this.primaryActions[0].className;\n\n if (this.hasAdminAccess) {\n this.sortActionButtonOrder();\n }\n\n // remove secondaryActions\n this.secondaryActions = [];\n }\n }\n\n /**\n * re-sort primaryActions action list to show dropdown-only/mobile mode\n */\n sortActionButtonOrder(): void {\n let fromIndex = 1;\n const toIndex = 0;\n if (this.secondaryActions.length === 2) {\n fromIndex = 2;\n }\n\n fromIndex = this.primaryActions.length - fromIndex;\n\n const element = this.primaryActions[fromIndex];\n const current = this.primaryActions;\n\n current.splice(fromIndex, 1);\n current.splice(toIndex, 0, element);\n\n this.primaryActions = current;\n }\n\n render() {\n return html`\n <div\n class=\"${classMap({\n actiongroup: true,\n disabled: this.disabled,\n })}\"\n >\n ${this.getLoaderIcon}\n <section class=\"action-buttons primary\">\n ${this.renderPrimaryActions}\n </section>\n <section class=\"action-buttons secondary\">\n ${this.renderSecondaryActions}\n </section>\n </div>\n `;\n }\n\n get renderPrimaryActions() {\n if (this.primaryActions.length === 0) return nothing;\n\n if (this.dropdownState === 'close') {\n this.primaryColor = this.primaryActions[0].className;\n }\n\n // If its single action, let just not show dropdown list\n if (this.primaryActions.length === 1) {\n return this.initialActionTemplate;\n }\n\n return html`\n ${this.initialActionTemplate}\n <button\n class=\"ia-button ${this.primaryColor} down-arrow\"\n @click=${this.toggleDropdown}\n >\n ${this.dropdownArrow}\n </button>\n\n <ul class=\"dropdown-content ${this.dropdownState}\">\n ${this.getPrimaryItems}\n </ul>\n `;\n }\n\n get renderSecondaryActions() {\n if (!this.secondaryActions.length) return nothing;\n\n return this.secondaryActions.map((action) =>\n this.renderActionButton(action),\n );\n }\n\n /**\n * Render action as a link for secondary actions like admin, printdisability links.\n * @param action\n * @param initialButton\n */\n renderActionLink(action: ActionConfig, initialButton = false) {\n return html`<span class=\"${this.getDeviceType} ${action.className}\">\n <a\n class=\"ia-button ${action.className} ${initialButton ? 'initial' : ''}\"\n href=\"${action.url}\"\n target=${action.target}\n @click=${() => {\n this.clickHandler(\n action.id,\n action.analyticsEvent,\n action?.borrowType,\n );\n }}\n >\n ${action.id === 'purchaseBook' ? purchaseIcon : ''} ${action.text}\n <small>${action.subText}</small>\n </a>\n </span>`;\n }\n\n /**\n * Render action as a button for primary actions like browse, borrow, join waitlist etc...\n * @param action\n * @param initialButton\n */\n renderActionButton(action: ActionConfig, initialButton = false) {\n if (action.url) return this.renderActionLink(action, initialButton);\n const { analyticsEvent } = action;\n return html`<button\n class=\"ia-button ${action.className} ${initialButton ? 'initial' : ''}\"\n @click=${() => {\n this.clickHandler(action.id, analyticsEvent, action?.borrowType);\n }}\n >\n ${action.text}\n </button>`;\n }\n\n /**\n * Dispatches click events when patron clicks on action buttons\n * @param eventName actions like 'browseBook', 'borrowBook' etc...\n * @param gaEvent contains analytics event action and category\n * @param borrowType browse|borrow\n * @fires CollapsibleActionGroup#{eventName} - (will be browseBook, borrowBook etc...)\n */\n clickHandler(\n eventName: string,\n gaEvent?: AnalyticsEvent,\n borrowType = '',\n ): void {\n this.dropdownState = 'close';\n this.dropdownArrow = dropdownClosed;\n\n if (!gaEvent || !eventName) return;\n const { category, action } = gaEvent;\n this.dispatchEvent(\n new CustomEvent<ActionClickDetail>(eventName, {\n detail: {\n event: { category, action },\n borrowType,\n },\n }),\n );\n }\n\n /**\n * get first primary action to render just before dropdown button\n */\n get initialActionTemplate() {\n this.initialButton = false;\n if (this.primaryActions.length > 1) {\n this.initialButton = true;\n }\n\n return this.renderActionButton(this.primaryActions[0], this.initialButton);\n }\n\n get getPrimaryItems() {\n return this.primaryActions\n .slice(1)\n .map(\n (action) =>\n html`<li>${this.renderActionButton(action, this.initialButton)}</li>`,\n );\n }\n\n /**\n * get loader icon when task is in-progress\n */\n get getLoaderIcon() {\n return html`<img\n class=\"${classMap({\n actionloader: true,\n disabled: this.disabled,\n })}\"\n alt=\"\"\n src=\"${this.loaderIcon}\"\n />`;\n }\n\n /**\n * check if device is below tablet\n */\n get isBelowTabletContainer(): boolean {\n return this.width <= tabletContainerWidth;\n }\n\n /**\n * get device type as per container width\n * @returns mobile | desktop\n */\n get getDeviceType(): 'mobile' | 'desktop' {\n return this.isBelowTabletContainer ? 'mobile' : 'desktop';\n }\n\n /**\n * toggle dropdown and its icon state\n */\n toggleDropdown(): void {\n if (this.dropdownState === 'open') {\n this.dropdownState = 'close';\n this.dropdownArrow = dropdownClosed;\n this.primaryColor = this.primaryActions[0].className;\n } else {\n this.dropdownState = 'open';\n this.dropdownArrow = dropdownOpened;\n this.primaryColor = 'dark';\n }\n }\n\n static get styles(): CSSResultGroup {\n return [buttonBaseStyle, CollapsibleActionGroupStyle];\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'ia-book-actions-collapsible-action-group': IABookActionsCollapsibleActionGroup;\n }\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ia-book-actions-info-icon.d.ts","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-info-icon.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,UAAU,EAAE,KAAK,cAAc,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"ia-book-actions-info-icon.d.ts","sourceRoot":"","sources":["../../../../src/elements/ia-book-actions/ia-book-actions-info-icon.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,UAAU,EAAE,KAAK,cAAc,EAAE,MAAM,KAAK,CAAC;AAIjE,OAAO,yCAAyC,CAAC;AAEjD,qBAEa,qBAAsB,SAAQ,UAAU;IACvB,SAAS,SAAM;IAE3C,OAAO,SAAsE;IAE7E,MAAM;IAcN,MAAM,KAAK,MAAM,IAAI,cAAc,CAsBlC;CACF;AAED,OAAO,CAAC,MAAM,CAAC;IACb,UAAU,qBAAqB;QAC7B,2BAA2B,EAAE,qBAAqB,CAAC;KACpD;CACF"}
|
|
@@ -3,7 +3,6 @@ import { css, html, LitElement } from 'lit';
|
|
|
3
3
|
import { property } from 'lit/decorators.js';
|
|
4
4
|
import { localized, msg } from '@lit/localize';
|
|
5
5
|
import { customElement } from '../../utils/custom-element.js';
|
|
6
|
-
import { tokenStyles } from '../../themes/tokens.js';
|
|
7
6
|
import '@internetarchive/icon-info/icon-info.js';
|
|
8
7
|
let IABookActionsInfoIcon = class IABookActionsInfoIcon extends LitElement {
|
|
9
8
|
constructor() {
|
|
@@ -25,30 +24,27 @@ let IABookActionsInfoIcon = class IABookActionsInfoIcon extends LitElement {
|
|
|
25
24
|
`;
|
|
26
25
|
}
|
|
27
26
|
static get styles() {
|
|
28
|
-
return
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
`,
|
|
51
|
-
];
|
|
27
|
+
return css `
|
|
28
|
+
ia-icon-info {
|
|
29
|
+
display: inline-block;
|
|
30
|
+
width: 18px;
|
|
31
|
+
height: 20px;
|
|
32
|
+
vertical-align: middle;
|
|
33
|
+
--iconFillColor: white;
|
|
34
|
+
}
|
|
35
|
+
.more-info-icon img {
|
|
36
|
+
width: 24px;
|
|
37
|
+
height: 24px;
|
|
38
|
+
vertical-align: middle;
|
|
39
|
+
background: white;
|
|
40
|
+
}
|
|
41
|
+
.hidden {
|
|
42
|
+
display: none;
|
|
43
|
+
}
|
|
44
|
+
.visible {
|
|
45
|
+
display: inline-block;
|
|
46
|
+
}
|
|
47
|
+
`;
|
|
52
48
|
}
|
|
53
49
|
};
|
|
54
50
|
__decorate([
|