@biggive/components 202501031034.0.0 → 202501071646.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/biggive/biggive.esm.js +1 -1
- package/dist/biggive/biggive.esm.js.map +1 -1
- package/dist/biggive/{p-30fe0e7e.entry.js → p-0b1658d6.entry.js} +2 -2
- package/dist/biggive/p-0b1658d6.entry.js.map +1 -0
- package/dist/biggive/{p-a666de04.entry.js → p-11e8755e.entry.js} +2 -2
- package/dist/biggive/p-11e8755e.entry.js.map +1 -0
- package/dist/biggive/p-19b999ee.js +3 -0
- package/dist/biggive/p-19b999ee.js.map +1 -0
- package/dist/biggive/p-1dc33885.entry.js +2 -0
- package/dist/biggive/p-1dc33885.entry.js.map +1 -0
- package/dist/biggive/{p-0eda1345.entry.js → p-277926a0.entry.js} +2 -2
- package/dist/biggive/p-277926a0.entry.js.map +1 -0
- package/dist/biggive/{p-bfaa8a6d.entry.js → p-2d9d24ee.entry.js} +2 -2
- package/dist/biggive/p-2d9d24ee.entry.js.map +1 -0
- package/dist/biggive/{p-b1d82c2f.entry.js → p-48fe25e2.entry.js} +2 -2
- package/dist/biggive/p-48fe25e2.entry.js.map +1 -0
- package/dist/biggive/{p-16da1da1.entry.js → p-6566f4c1.entry.js} +2 -2
- package/dist/biggive/p-6566f4c1.entry.js.map +1 -0
- package/dist/biggive/{p-f0bb3912.entry.js → p-7eed7866.entry.js} +2 -2
- package/dist/biggive/p-7eed7866.entry.js.map +1 -0
- package/dist/biggive/{p-87562be2.entry.js → p-9d99b90f.entry.js} +2 -2
- package/dist/biggive/p-9d99b90f.entry.js.map +1 -0
- package/dist/biggive/{p-ea8d01ca.entry.js → p-a55f75e9.entry.js} +2 -2
- package/dist/biggive/p-a55f75e9.entry.js.map +1 -0
- package/dist/biggive/p-a61421f8.entry.js +2 -0
- package/dist/biggive/{p-f3246097.entry.js → p-ba6693e6.entry.js} +2 -2
- package/dist/biggive/p-ba6693e6.entry.js.map +1 -0
- package/dist/biggive/p-d97ab5b9.entry.js +2 -0
- package/dist/biggive/{p-5262507c.entry.js.map → p-d97ab5b9.entry.js.map} +1 -1
- package/dist/biggive/p-e0611f0e.entry.js +2 -0
- package/dist/biggive/p-e0611f0e.entry.js.map +1 -0
- package/dist/biggive/p-e70a1cb0.entry.js +2 -0
- package/dist/biggive/p-e70a1cb0.entry.js.map +1 -0
- package/dist/biggive/{p-2eb2b970.entry.js → p-fd5a51e6.entry.js} +2 -2
- package/dist/biggive/p-fd5a51e6.entry.js.map +1 -0
- package/dist/cjs/biggive-accordion_38.cjs.entry.js +375 -144
- package/dist/cjs/biggive-accordion_38.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-article-card.cjs.entry.js +1 -13
- package/dist/cjs/biggive-article-card.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-basic-card.cjs.entry.js +1 -8
- package/dist/cjs/biggive-basic-card.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-beneficiary-icon.cjs.entry.js +13 -2
- package/dist/cjs/biggive-beneficiary-icon.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-biography-card.cjs.entry.js +1 -1
- package/dist/cjs/biggive-biography-card.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-boxed-content.cjs.entry.js +16 -1
- package/dist/cjs/biggive-boxed-content.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-category-icon.cjs.entry.js +10 -3
- package/dist/cjs/biggive-category-icon.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-container-card.cjs.entry.js +1 -1
- package/dist/cjs/biggive-container-card.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-cookie-banner.cjs.entry.js +17 -4
- package/dist/cjs/biggive-cookie-banner.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-form.cjs.entry.js +1 -1
- package/dist/cjs/biggive-icon-group.cjs.entry.js +4 -2
- package/dist/cjs/biggive-icon-group.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-image-card.cjs.entry.js +1 -6
- package/dist/cjs/biggive-image-card.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-nav-group.cjs.entry.js +4 -1
- package/dist/cjs/biggive-nav-group.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-nav-item.cjs.entry.js +1 -4
- package/dist/cjs/biggive-nav-item.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-table.cjs.entry.js +1 -1
- package/dist/cjs/biggive-table.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive-video.cjs.entry.js +10 -1
- package/dist/cjs/biggive-video.cjs.entry.js.map +1 -1
- package/dist/cjs/biggive.cjs.js +2 -2
- package/dist/cjs/biggive.cjs.js.map +1 -1
- package/dist/cjs/{index-c0a19159.js → index-c7b6790e.js} +253 -137
- package/dist/cjs/index-c7b6790e.js.map +1 -0
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/collection-manifest.json +1 -1
- package/dist/collection/components/biggive-accordion/biggive-accordion.js +0 -1
- package/dist/collection/components/biggive-accordion/biggive-accordion.js.map +1 -1
- package/dist/collection/components/biggive-accordion-entry/biggive-accordion-entry.js.map +1 -1
- package/dist/collection/components/biggive-article-card/biggive-article-card.js +0 -12
- package/dist/collection/components/biggive-article-card/biggive-article-card.js.map +1 -1
- package/dist/collection/components/biggive-basic-card/biggive-basic-card.js +0 -7
- package/dist/collection/components/biggive-basic-card/biggive-basic-card.js.map +1 -1
- package/dist/collection/components/biggive-beneficiary-icon/biggive-beneficiary-icon.js +12 -1
- package/dist/collection/components/biggive-beneficiary-icon/biggive-beneficiary-icon.js.map +1 -1
- package/dist/collection/components/biggive-biography-card/biggive-biography-card.js.map +1 -1
- package/dist/collection/components/biggive-boxed-content/biggive-boxed-content.js +15 -0
- package/dist/collection/components/biggive-boxed-content/biggive-boxed-content.js.map +1 -1
- package/dist/collection/components/biggive-branded-image/biggive-branded-image.js +9 -4
- package/dist/collection/components/biggive-branded-image/biggive-branded-image.js.map +1 -1
- package/dist/collection/components/biggive-button/biggive-button.js +27 -4
- package/dist/collection/components/biggive-button/biggive-button.js.map +1 -1
- package/dist/collection/components/biggive-call-to-action/biggive-call-to-action.js +36 -8
- package/dist/collection/components/biggive-call-to-action/biggive-call-to-action.js.map +1 -1
- package/dist/collection/components/biggive-campaign-card/biggive-campaign-card.js +24 -15
- package/dist/collection/components/biggive-campaign-card/biggive-campaign-card.js.map +1 -1
- package/dist/collection/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.js +38 -13
- package/dist/collection/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.js.map +1 -1
- package/dist/collection/components/biggive-campaign-highlights/biggive-campaign-highlights.js +6 -12
- package/dist/collection/components/biggive-campaign-highlights/biggive-campaign-highlights.js.map +1 -1
- package/dist/collection/components/biggive-category-icon/biggive-category-icon.js +9 -2
- package/dist/collection/components/biggive-category-icon/biggive-category-icon.js.map +1 -1
- package/dist/collection/components/biggive-container-card/biggive-container-card.js.map +1 -1
- package/dist/collection/components/biggive-cookie-banner/biggive-cookie-banner.js +16 -3
- package/dist/collection/components/biggive-cookie-banner/biggive-cookie-banner.js.map +1 -1
- package/dist/collection/components/biggive-footer/biggive-footer.js +5 -4
- package/dist/collection/components/biggive-footer/biggive-footer.js.map +1 -1
- package/dist/collection/components/biggive-form-field-select/biggive-form-field-select.js +5 -9
- package/dist/collection/components/biggive-form-field-select/biggive-form-field-select.js.map +1 -1
- package/dist/collection/components/biggive-formatted-text/biggive-formatted-text.js +9 -0
- package/dist/collection/components/biggive-formatted-text/biggive-formatted-text.js.map +1 -1
- package/dist/collection/components/biggive-generic-icon/biggive-generic-icon.js +0 -3
- package/dist/collection/components/biggive-generic-icon/biggive-generic-icon.js.map +1 -1
- package/dist/collection/components/biggive-grid/biggive-grid.js +3 -0
- package/dist/collection/components/biggive-grid/biggive-grid.js.map +1 -1
- package/dist/collection/components/biggive-heading/biggive-heading.js.map +1 -1
- package/dist/collection/components/biggive-hero-image/biggive-hero-image.js +31 -8
- package/dist/collection/components/biggive-hero-image/biggive-hero-image.js.map +1 -1
- package/dist/collection/components/biggive-icon-button/biggive-icon-button.js +3 -7
- package/dist/collection/components/biggive-icon-button/biggive-icon-button.js.map +1 -1
- package/dist/collection/components/biggive-icon-group/biggive-icon-group.js +3 -1
- package/dist/collection/components/biggive-icon-group/biggive-icon-group.js.map +1 -1
- package/dist/collection/components/biggive-image/biggive-image.js +21 -0
- package/dist/collection/components/biggive-image/biggive-image.js.map +1 -1
- package/dist/collection/components/biggive-image-button/biggive-image-button.js +3 -6
- package/dist/collection/components/biggive-image-button/biggive-image-button.js.map +1 -1
- package/dist/collection/components/biggive-image-card/biggive-image-card.js +0 -5
- package/dist/collection/components/biggive-image-card/biggive-image-card.js.map +1 -1
- package/dist/collection/components/biggive-image-feature/biggive-image-feature.js +24 -5
- package/dist/collection/components/biggive-image-feature/biggive-image-feature.js.map +1 -1
- package/dist/collection/components/biggive-main-menu/biggive-main-menu.js +13 -5
- package/dist/collection/components/biggive-main-menu/biggive-main-menu.js.map +1 -1
- package/dist/collection/components/biggive-misc-icon/biggive-misc-icon.js +6 -2
- package/dist/collection/components/biggive-misc-icon/biggive-misc-icon.js.map +1 -1
- package/dist/collection/components/biggive-nav-group/biggive-nav-group.js +3 -0
- package/dist/collection/components/biggive-nav-group/biggive-nav-group.js.map +1 -1
- package/dist/collection/components/biggive-nav-item/biggive-nav-item.js +0 -5
- package/dist/collection/components/biggive-nav-item/biggive-nav-item.js.map +1 -1
- package/dist/collection/components/biggive-page-columns/biggive-page-columns.js +3 -0
- package/dist/collection/components/biggive-page-columns/biggive-page-columns.js.map +1 -1
- package/dist/collection/components/biggive-page-section/biggive-page-section.js +15 -1
- package/dist/collection/components/biggive-page-section/biggive-page-section.js.map +1 -1
- package/dist/collection/components/biggive-popup/biggive-popup.js +4 -1
- package/dist/collection/components/biggive-popup/biggive-popup.js.map +1 -1
- package/dist/collection/components/biggive-progress-bar/biggive-progress-bar.js +9 -0
- package/dist/collection/components/biggive-progress-bar/biggive-progress-bar.js.map +1 -1
- package/dist/collection/components/biggive-quote/biggive-quote.js.map +1 -1
- package/dist/collection/components/biggive-sheet/biggive-sheet.js +6 -3
- package/dist/collection/components/biggive-sheet/biggive-sheet.js.map +1 -1
- package/dist/collection/components/biggive-social-icon/biggive-social-icon.js +16 -1
- package/dist/collection/components/biggive-social-icon/biggive-social-icon.js.map +1 -1
- package/dist/collection/components/biggive-tab/biggive-tab.js.map +1 -1
- package/dist/collection/components/biggive-tabbed-content/biggive-tabbed-content.js +7 -7
- package/dist/collection/components/biggive-tabbed-content/biggive-tabbed-content.js.map +1 -1
- package/dist/collection/components/biggive-table/biggive-table.js.map +1 -1
- package/dist/collection/components/biggive-text-input/biggive-text-input.js +0 -2
- package/dist/collection/components/biggive-text-input/biggive-text-input.js.map +1 -1
- package/dist/collection/components/biggive-timeline/biggive-timeline.js +12 -12
- package/dist/collection/components/biggive-timeline/biggive-timeline.js.map +1 -1
- package/dist/collection/components/biggive-timeline-entry/biggive-timeline-entry.js +0 -4
- package/dist/collection/components/biggive-timeline-entry/biggive-timeline-entry.js.map +1 -1
- package/dist/collection/components/biggive-totalizer/biggive-totalizer.js +15 -1
- package/dist/collection/components/biggive-totalizer/biggive-totalizer.js.map +1 -1
- package/dist/collection/components/biggive-totalizer-ticker-item/biggive-totalizer-ticker-item.js +0 -4
- package/dist/collection/components/biggive-totalizer-ticker-item/biggive-totalizer-ticker-item.js.map +1 -1
- package/dist/collection/components/biggive-video/biggive-video.js +9 -0
- package/dist/collection/components/biggive-video/biggive-video.js.map +1 -1
- package/dist/collection/components/biggive-video-feature/biggive-video-feature.js +24 -5
- package/dist/collection/components/biggive-video-feature/biggive-video-feature.js.map +1 -1
- package/dist/components/biggive-accordion-entry.js.map +1 -1
- package/dist/components/biggive-accordion.js +0 -1
- package/dist/components/biggive-accordion.js.map +1 -1
- package/dist/components/biggive-article-card.js +0 -12
- package/dist/components/biggive-article-card.js.map +1 -1
- package/dist/components/biggive-basic-card.js +0 -7
- package/dist/components/biggive-basic-card.js.map +1 -1
- package/dist/components/biggive-beneficiary-icon.js +12 -1
- package/dist/components/biggive-beneficiary-icon.js.map +1 -1
- package/dist/components/biggive-biography-card.js.map +1 -1
- package/dist/components/biggive-boxed-content.js +15 -0
- package/dist/components/biggive-boxed-content.js.map +1 -1
- package/dist/components/biggive-branded-image.js +9 -4
- package/dist/components/biggive-branded-image.js.map +1 -1
- package/dist/components/biggive-button2.js +27 -4
- package/dist/components/biggive-button2.js.map +1 -1
- package/dist/components/biggive-call-to-action.js +36 -8
- package/dist/components/biggive-call-to-action.js.map +1 -1
- package/dist/components/biggive-campaign-card-filter-grid.js +38 -13
- package/dist/components/biggive-campaign-card-filter-grid.js.map +1 -1
- package/dist/components/biggive-campaign-card.js +24 -15
- package/dist/components/biggive-campaign-card.js.map +1 -1
- package/dist/components/biggive-campaign-highlights.js +6 -12
- package/dist/components/biggive-campaign-highlights.js.map +1 -1
- package/dist/components/biggive-category-icon.js +9 -2
- package/dist/components/biggive-category-icon.js.map +1 -1
- package/dist/components/biggive-container-card.js.map +1 -1
- package/dist/components/biggive-cookie-banner.js +16 -3
- package/dist/components/biggive-cookie-banner.js.map +1 -1
- package/dist/components/biggive-footer.js +5 -4
- package/dist/components/biggive-footer.js.map +1 -1
- package/dist/components/biggive-form-field-select2.js +5 -9
- package/dist/components/biggive-form-field-select2.js.map +1 -1
- package/dist/components/biggive-formatted-text.js +9 -0
- package/dist/components/biggive-formatted-text.js.map +1 -1
- package/dist/components/biggive-generic-icon2.js +0 -3
- package/dist/components/biggive-generic-icon2.js.map +1 -1
- package/dist/components/biggive-grid.js +3 -0
- package/dist/components/biggive-grid.js.map +1 -1
- package/dist/components/biggive-heading.js.map +1 -1
- package/dist/components/biggive-hero-image.js +31 -8
- package/dist/components/biggive-hero-image.js.map +1 -1
- package/dist/components/biggive-icon-button.js +3 -7
- package/dist/components/biggive-icon-button.js.map +1 -1
- package/dist/components/biggive-icon-group.js +3 -1
- package/dist/components/biggive-icon-group.js.map +1 -1
- package/dist/components/biggive-image-button.js +3 -6
- package/dist/components/biggive-image-button.js.map +1 -1
- package/dist/components/biggive-image-card.js +0 -5
- package/dist/components/biggive-image-card.js.map +1 -1
- package/dist/components/biggive-image-feature.js +24 -5
- package/dist/components/biggive-image-feature.js.map +1 -1
- package/dist/components/biggive-image.js +21 -0
- package/dist/components/biggive-image.js.map +1 -1
- package/dist/components/biggive-main-menu.js +13 -5
- package/dist/components/biggive-main-menu.js.map +1 -1
- package/dist/components/biggive-misc-icon2.js +6 -2
- package/dist/components/biggive-misc-icon2.js.map +1 -1
- package/dist/components/biggive-nav-group.js +3 -0
- package/dist/components/biggive-nav-group.js.map +1 -1
- package/dist/components/biggive-nav-item.js +0 -3
- package/dist/components/biggive-nav-item.js.map +1 -1
- package/dist/components/biggive-page-columns.js +3 -0
- package/dist/components/biggive-page-columns.js.map +1 -1
- package/dist/components/biggive-page-section.js +15 -1
- package/dist/components/biggive-page-section.js.map +1 -1
- package/dist/components/biggive-popup2.js +4 -1
- package/dist/components/biggive-popup2.js.map +1 -1
- package/dist/components/biggive-progress-bar2.js +9 -0
- package/dist/components/biggive-progress-bar2.js.map +1 -1
- package/dist/components/biggive-quote.js.map +1 -1
- package/dist/components/biggive-sheet.js +6 -3
- package/dist/components/biggive-sheet.js.map +1 -1
- package/dist/components/biggive-social-icon2.js +16 -1
- package/dist/components/biggive-social-icon2.js.map +1 -1
- package/dist/components/biggive-tab.js.map +1 -1
- package/dist/components/biggive-tabbed-content.js +7 -7
- package/dist/components/biggive-tabbed-content.js.map +1 -1
- package/dist/components/biggive-table.js.map +1 -1
- package/dist/components/biggive-text-input.js +0 -2
- package/dist/components/biggive-text-input.js.map +1 -1
- package/dist/components/biggive-timeline-entry.js +0 -2
- package/dist/components/biggive-timeline-entry.js.map +1 -1
- package/dist/components/biggive-timeline.js +12 -12
- package/dist/components/biggive-timeline.js.map +1 -1
- package/dist/components/biggive-totalizer-ticker-item.js +0 -2
- package/dist/components/biggive-totalizer-ticker-item.js.map +1 -1
- package/dist/components/biggive-totalizer.js +15 -1
- package/dist/components/biggive-totalizer.js.map +1 -1
- package/dist/components/biggive-video-feature.js +24 -5
- package/dist/components/biggive-video-feature.js.map +1 -1
- package/dist/components/biggive-video.js +9 -0
- package/dist/components/biggive-video.js.map +1 -1
- package/dist/esm/biggive-accordion_38.entry.js +375 -144
- package/dist/esm/biggive-accordion_38.entry.js.map +1 -1
- package/dist/esm/biggive-article-card.entry.js +1 -13
- package/dist/esm/biggive-article-card.entry.js.map +1 -1
- package/dist/esm/biggive-basic-card.entry.js +1 -8
- package/dist/esm/biggive-basic-card.entry.js.map +1 -1
- package/dist/esm/biggive-beneficiary-icon.entry.js +13 -2
- package/dist/esm/biggive-beneficiary-icon.entry.js.map +1 -1
- package/dist/esm/biggive-biography-card.entry.js +1 -1
- package/dist/esm/biggive-biography-card.entry.js.map +1 -1
- package/dist/esm/biggive-boxed-content.entry.js +16 -1
- package/dist/esm/biggive-boxed-content.entry.js.map +1 -1
- package/dist/esm/biggive-category-icon.entry.js +10 -3
- package/dist/esm/biggive-category-icon.entry.js.map +1 -1
- package/dist/esm/biggive-container-card.entry.js +1 -1
- package/dist/esm/biggive-container-card.entry.js.map +1 -1
- package/dist/esm/biggive-cookie-banner.entry.js +17 -4
- package/dist/esm/biggive-cookie-banner.entry.js.map +1 -1
- package/dist/esm/biggive-form.entry.js +1 -1
- package/dist/esm/biggive-icon-group.entry.js +4 -2
- package/dist/esm/biggive-icon-group.entry.js.map +1 -1
- package/dist/esm/biggive-image-card.entry.js +1 -6
- package/dist/esm/biggive-image-card.entry.js.map +1 -1
- package/dist/esm/biggive-nav-group.entry.js +4 -1
- package/dist/esm/biggive-nav-group.entry.js.map +1 -1
- package/dist/esm/biggive-nav-item.entry.js +1 -4
- package/dist/esm/biggive-nav-item.entry.js.map +1 -1
- package/dist/esm/biggive-table.entry.js +1 -1
- package/dist/esm/biggive-table.entry.js.map +1 -1
- package/dist/esm/biggive-video.entry.js +10 -1
- package/dist/esm/biggive-video.entry.js.map +1 -1
- package/dist/esm/biggive.js +3 -3
- package/dist/esm/biggive.js.map +1 -1
- package/dist/esm/{index-bf4df57a.js → index-ccd7196b.js} +253 -137
- package/dist/esm/index-ccd7196b.js.map +1 -0
- package/dist/esm/loader.js +2 -2
- package/hydrate/index.js +598 -328
- package/hydrate/index.mjs +598 -328
- package/package.json +1 -1
- package/dist/biggive/p-0eda1345.entry.js.map +0 -1
- package/dist/biggive/p-16da1da1.entry.js.map +0 -1
- package/dist/biggive/p-2eb2b970.entry.js.map +0 -1
- package/dist/biggive/p-30fe0e7e.entry.js.map +0 -1
- package/dist/biggive/p-5262507c.entry.js +0 -2
- package/dist/biggive/p-65a08fe3.entry.js +0 -2
- package/dist/biggive/p-65a08fe3.entry.js.map +0 -1
- package/dist/biggive/p-753c50c5.js +0 -3
- package/dist/biggive/p-753c50c5.js.map +0 -1
- package/dist/biggive/p-87562be2.entry.js.map +0 -1
- package/dist/biggive/p-a666de04.entry.js.map +0 -1
- package/dist/biggive/p-b1d82c2f.entry.js.map +0 -1
- package/dist/biggive/p-bfaa8a6d.entry.js.map +0 -1
- package/dist/biggive/p-cf7446f9.entry.js +0 -2
- package/dist/biggive/p-cf7446f9.entry.js.map +0 -1
- package/dist/biggive/p-e3b4412e.entry.js +0 -2
- package/dist/biggive/p-e3b4412e.entry.js.map +0 -1
- package/dist/biggive/p-ea8d01ca.entry.js.map +0 -1
- package/dist/biggive/p-f0bb3912.entry.js.map +0 -1
- package/dist/biggive/p-f3246097.entry.js.map +0 -1
- package/dist/biggive/p-f6b8aae2.entry.js +0 -2
- package/dist/cjs/index-c0a19159.js.map +0 -1
- package/dist/esm/index-bf4df57a.js.map +0 -1
- /package/dist/biggive/{p-f6b8aae2.entry.js.map → p-a61421f8.entry.js.map} +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-biography-card.js","mappings":";;AAAA,MAAM,uBAAuB,GAAG,+6pBAA+6pB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biography-card&encapsulation=shadow","src/components/biggive-biography-card/biggive-biography-card.tsx"],"sourcesContent":["@include image-alignment();\n@include spacers();\n@include backgrounds();\n@include text-colours();\n\n:host {\n display: block;\n}\n\n.container {\n\n @each $key, $colour in $brandColoursIncBrand6Turquoise {\n &.background-colour-#{$key} .image-wrap { background-color: $colour; }\n }\n\n text-align: left;\n &.text-align-center {\n text-align: center;\n }\n &.text-align-right {\n text-align: right;\n }\n\n a {\n text-decoration: none;\n }\n\n h3.full-name {\n font-size: font-size-medium();\n margin: 0;\n }\n\n div.job-title {\n font-size: font-size-small();\n margin: 0; \n }\n \n\n .sleeve {\n\n \n @each $key, $colour in $brandColoursIncBrand6Turquoise {\n\n &.border-width-1.border-colour-#{$key} { border: $spacer-1 solid $colour; }\n &.border-width-2.border-colour-#{$key} { border: $spacer-2 solid $colour; }\n &.border-width-3.border-colour-#{$key} { border: $spacer-3 solid $colour; }\n &.border-width-4.border-colour-#{$key} { border: $spacer-4 solid $colour; }\n &.border-width-5.border-colour-#{$key} { border: $spacer-5 solid $colour; }\n &.border-width-6.border-colour-#{$key} { border: $spacer-6 solid $colour; }\n }\n \n\n margin-bottom: $spacer-2;\n\n &.circle-true {\n overflow: hidden;\n border-radius: 50%;\n }\n\n\n .image-wrap {\n position: relative;\n background-position: center center;\n background-size: cover;\n background-repeat: no-repeat;\n \n &.image-style-cover {\n background-size: cover;\n }\n &.image-style-contain {\n background-size: contain;\n }\n \n &[data-ratio=\"1,1\"] { padding-bottom: 100%; }\n &[data-ratio=\"1,1\"].border-width-1 { padding-bottom: calc(100% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-2 { padding-bottom: calc(100% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-3 { padding-bottom: calc(100% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-4 { padding-bottom: calc(100% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-5 { padding-bottom: calc(100% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-6 { padding-bottom: calc(100% - ( $spacer-6 * 2 )); }\n \n &[data-ratio=\"1,1.5\"] { padding-bottom: 150%; }\n &[data-ratio=\"1,1.5\"].border-width-1 { padding-bottom: calc(150% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-2 { padding-bottom: calc(150% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-3 { padding-bottom: calc(150% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-4 { padding-bottom: calc(150% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-5 { padding-bottom: calc(150% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-6 { padding-bottom: calc(150% - ( $spacer-6 * 2 )); }\n \n &[data-ratio=\"1,2\"] { padding-bottom: 200%; }\n &[data-ratio=\"1,2\"].border-width-1 { padding-bottom: calc(200% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-2 { padding-bottom: calc(200% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-3 { padding-bottom: calc(200% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-4 { padding-bottom: calc(200% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-5 { padding-bottom: calc(200% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-6 { padding-bottom: calc(200% - ( $spacer-6 * 2 )); }\n \n \n \n \n \n \n &.rounded-true {\n overflow: hidden;\n border-radius: 10px;\n }\n \n \n\n \n .circle {\n position: absolute;\n width: 30px;\n height: 30px;\n background-color: #FFFFFF;\n bottom: 15px;\n right: 15px;\n border-radius: 50%;\n text-align: center;\n padding: 6.5px;\n box-sizing: border-box;\n svg path {\n stroke: #000000;\n }\n &.dark {\n background-color: #000000;\n svg path {\n stroke: #FFFFFF;\n }\n }\n svg {\n position: relative;\n display: inline-block;\n top: -1px;\n height: 15px;\n width: 15px;\n }\n }\n \n \n \n img {\n display: none;\n }\n\n\n }\n\n\n\n }\n\n\n}","import { Component, Prop, h } from '@stencil/core';\nimport { brandColour } from '../../globals/brand-colour';\nimport { spacingOption } from '../../globals/spacing-option';\n\n@Component({\n tag: 'biggive-biography-card',\n styleUrl: 'biggive-biography-card.scss',\n shadow: true,\n})\nexport class BiggiveBiographyCard {\n @Prop() spaceBelow: spacingOption = 0;\n\n @Prop() borderWidth: spacingOption = 0;\n\n @Prop() imageUrl: string = '';\n\n @Prop() imageStyle: 'cover' | 'contain' = 'cover';\n\n @Prop() textColour: brandColour = 'black';\n\n @Prop() backgroundColour: brandColour = 'white';\n\n @Prop() fullName: string = '';\n\n @Prop() jobTitle: string = '';\n\n @Prop() textAlign: 'center' | 'left' | 'right' = 'left';\n\n @Prop() ratio: '1,1' | '1,1.5' | '1,2' = '1,1.5';\n\n @Prop() circle: boolean = false;\n\n @Prop() circleColour: 'light' | 'dark' = 'light';\n\n @Prop() rounded: boolean = false;\n\n @Prop() url: string = '';\n\n render() {\n if (this.url != '') {\n return (\n <div class={'container space-below-' + this.spaceBelow + ' text-colour-' + this.textColour + ' text-align-' + this.textAlign}>\n <a href={this.url}>\n <div\n class={\n 'sleeve circle-' +\n this.circle.toString() +\n ' border-colour-' +\n this.backgroundColour +\n ' background-colour-' +\n this.backgroundColour +\n ' border-width-' +\n this.borderWidth\n }\n >\n {this.imageUrl != '' ? (\n <div\n data-ratio={this.ratio}\n class={'image-wrap image-style-' + this.imageStyle + ' rounded-' + this.rounded.toString()}\n style={{ 'background-image': \"url('\" + this.imageUrl + \"')\" }}\n >\n <img src={this.imageUrl} alt={this.fullName} title={this.fullName} />\n <div class={'circle ' + this.circleColour}>\n <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">\n <path stroke-color=\"1\" d=\"M11 11v-11h1v11h11v1h-11v11h-1v-11h-11v-1h11z\" />\n </svg>\n </div>\n </div>\n ) : null}\n </div>\n <h3 class=\"full-name\">{this.fullName}</h3>\n <div class=\"job-title\">{this.jobTitle}</div>\n </a>\n </div>\n );\n } else {\n return (\n <div class={'container space-below-' + this.spaceBelow + ' text-colour-' + this.textColour + ' text-align-' + this.textAlign}>\n <div\n class={\n 'sleeve circle-' +\n this.circle.toString() +\n ' border-colour-' +\n this.backgroundColour +\n ' background-colour-' +\n this.backgroundColour +\n ' border-width-' +\n this.borderWidth\n }\n >\n {this.imageUrl != '' ? (\n <div\n data-ratio={this.ratio}\n class={'image-wrap image-style-' + this.imageStyle + ' rounded-' + this.rounded.toString()}\n style={{ 'background-image': \"url('\" + this.imageUrl + \"')\" }}\n >\n <img src={this.imageUrl} alt={this.fullName} title={this.fullName} />\n </div>\n ) : null}\n </div>\n <h3 class=\"full-name\">{this.fullName}</h3>\n <div class=\"job-title\">{this.jobTitle}</div>\n </div>\n );\n }\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"biggive-biography-card.js","mappings":";;AAAA,MAAM,uBAAuB,GAAG,+6pBAA+6pB,CAAC;AACh9pB,mCAAe,uBAAuB;;MCQzBA,sBAAoB;IALjC;;;;QAMU,eAAU,GAAkB,CAAC,CAAC;QAE9B,gBAAW,GAAkB,CAAC,CAAC;QAE/B,aAAQ,GAAW,EAAE,CAAC;QAEtB,eAAU,GAAwB,OAAO,CAAC;QAE1C,eAAU,GAAgB,OAAO,CAAC;QAElC,qBAAgB,GAAgB,OAAO,CAAC;QAExC,aAAQ,GAAW,EAAE,CAAC;QAEtB,aAAQ,GAAW,EAAE,CAAC;QAEtB,cAAS,GAAgC,MAAM,CAAC;QAEhD,UAAK,GAA4B,OAAO,CAAC;QAEzC,WAAM,GAAY,KAAK,CAAC;QAExB,iBAAY,GAAqB,OAAO,CAAC;QAEzC,YAAO,GAAY,KAAK,CAAC;QAEzB,QAAG,GAAW,EAAE,CAAC;KAsE1B;IApEC,MAAM;QACJ,IAAI,IAA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AAG,IAAI,CAAC,UAAU,GAAG,eAAe,GAAG,IAAI,CAAC,UAAU,GAAG,cAAc,GAAG,IAAI,CAAC,SAAS,IAC1H,WACE,KAAK,EACH,gBAAgB;oBAChB,IAAI,CAAC,MAAM,CAAC,QAAQ,EAAE;oBACtB,iBAAiB;oBACjB,IAAI,CAAC,gBAAgB;oBACrB,qBAAqB;oBACrB,IAAI,CAAC,gBAAgB;oBACrB,gBAAgB;oBAChB,IAAI,CAAC,WAAW,IAGjB,IAAI,CAAC,QAAQ,IAAI,EAAE,IAClB,yBACc,IAAI,CAAC,KAAK,EACtB,KAAK,EAAE,yBAAyB,GAAG,IAAI,CAAC,UAAU,GAAG,WAAW,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,EAC1F,KAAK,EAAE,EAAE,kBAAkB,EAAE,OAAO,GAAG,IAAI,CAAC,QAAQ,GAAG,IAAI,EAAE,IAE7D,WAAK,GAAG,EAAE,IAAI,CAAC,QAAQ,EAAE,GAAG,EAAE,IAAI,CAAC,QAAQ,EAAE,KAAK,EAAE,IAAI,CAAC,QAAQ,GAAI,CACjE,IACJ,IAAI,CACJ,EACN,UAAI,KAAK,EAAC,WAAW,IAAE,IAAI,CAAC,QAAQ,CAAM,EAC1C,WAAK,KAAK,EAAC,WAAW,IAAE,IAAI,CAAC,QAAQ,CAAO,CACxC,EACN;SACH;KACF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveBiographyCard"],"sources":["src/components/biggive-biography-card/biggive-biography-card.scss?tag=biggive-biography-card&encapsulation=shadow","src/components/biggive-biography-card/biggive-biography-card.tsx"],"sourcesContent":["@include image-alignment();\n@include spacers();\n@include backgrounds();\n@include text-colours();\n\n:host {\n display: block;\n}\n\n.container {\n\n @each $key, $colour in $brandColoursIncBrand6Turquoise {\n &.background-colour-#{$key} .image-wrap { background-color: $colour; }\n }\n\n text-align: left;\n &.text-align-center {\n text-align: center;\n }\n &.text-align-right {\n text-align: right;\n }\n\n a {\n text-decoration: none;\n }\n\n h3.full-name {\n font-size: font-size-medium();\n margin: 0;\n }\n\n div.job-title {\n font-size: font-size-small();\n margin: 0; \n }\n \n\n .sleeve {\n\n \n @each $key, $colour in $brandColoursIncBrand6Turquoise {\n\n &.border-width-1.border-colour-#{$key} { border: $spacer-1 solid $colour; }\n &.border-width-2.border-colour-#{$key} { border: $spacer-2 solid $colour; }\n &.border-width-3.border-colour-#{$key} { border: $spacer-3 solid $colour; }\n &.border-width-4.border-colour-#{$key} { border: $spacer-4 solid $colour; }\n &.border-width-5.border-colour-#{$key} { border: $spacer-5 solid $colour; }\n &.border-width-6.border-colour-#{$key} { border: $spacer-6 solid $colour; }\n }\n \n\n margin-bottom: $spacer-2;\n\n &.circle-true {\n overflow: hidden;\n border-radius: 50%;\n }\n\n\n .image-wrap {\n position: relative;\n background-position: center center;\n background-size: cover;\n background-repeat: no-repeat;\n \n &.image-style-cover {\n background-size: cover;\n }\n &.image-style-contain {\n background-size: contain;\n }\n \n &[data-ratio=\"1,1\"] { padding-bottom: 100%; }\n &[data-ratio=\"1,1\"].border-width-1 { padding-bottom: calc(100% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-2 { padding-bottom: calc(100% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-3 { padding-bottom: calc(100% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-4 { padding-bottom: calc(100% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-5 { padding-bottom: calc(100% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,1\"].border-width-6 { padding-bottom: calc(100% - ( $spacer-6 * 2 )); }\n \n &[data-ratio=\"1,1.5\"] { padding-bottom: 150%; }\n &[data-ratio=\"1,1.5\"].border-width-1 { padding-bottom: calc(150% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-2 { padding-bottom: calc(150% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-3 { padding-bottom: calc(150% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-4 { padding-bottom: calc(150% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-5 { padding-bottom: calc(150% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,1.5\"].border-width-6 { padding-bottom: calc(150% - ( $spacer-6 * 2 )); }\n \n &[data-ratio=\"1,2\"] { padding-bottom: 200%; }\n &[data-ratio=\"1,2\"].border-width-1 { padding-bottom: calc(200% - ( $spacer-1 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-2 { padding-bottom: calc(200% - ( $spacer-2 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-3 { padding-bottom: calc(200% - ( $spacer-3 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-4 { padding-bottom: calc(200% - ( $spacer-4 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-5 { padding-bottom: calc(200% - ( $spacer-5 * 2 )); }\n &[data-ratio=\"1,2\"].border-width-6 { padding-bottom: calc(200% - ( $spacer-6 * 2 )); }\n \n \n \n \n \n \n &.rounded-true {\n overflow: hidden;\n border-radius: 10px;\n }\n \n \n\n \n .circle {\n position: absolute;\n width: 30px;\n height: 30px;\n background-color: #FFFFFF;\n bottom: 15px;\n right: 15px;\n border-radius: 50%;\n text-align: center;\n padding: 6.5px;\n box-sizing: border-box;\n svg path {\n stroke: #000000;\n }\n &.dark {\n background-color: #000000;\n svg path {\n stroke: #FFFFFF;\n }\n }\n svg {\n position: relative;\n display: inline-block;\n top: -1px;\n height: 15px;\n width: 15px;\n }\n }\n \n \n \n img {\n display: none;\n }\n\n\n }\n\n\n\n }\n\n\n}","import { Component, Prop, h } from '@stencil/core';\nimport { brandColour } from '../../globals/brand-colour';\nimport { spacingOption } from '../../globals/spacing-option';\n\n@Component({\n tag: 'biggive-biography-card',\n styleUrl: 'biggive-biography-card.scss',\n shadow: true,\n})\nexport class BiggiveBiographyCard {\n @Prop() spaceBelow: spacingOption = 0;\n\n @Prop() borderWidth: spacingOption = 0;\n\n @Prop() imageUrl: string = '';\n\n @Prop() imageStyle: 'cover' | 'contain' = 'cover';\n\n @Prop() textColour: brandColour = 'black';\n\n @Prop() backgroundColour: brandColour = 'white';\n\n @Prop() fullName: string = '';\n\n @Prop() jobTitle: string = '';\n\n @Prop() textAlign: 'center' | 'left' | 'right' = 'left';\n\n @Prop() ratio: '1,1' | '1,1.5' | '1,2' = '1,1.5';\n\n @Prop() circle: boolean = false;\n\n @Prop() circleColour: 'light' | 'dark' = 'light';\n\n @Prop() rounded: boolean = false;\n\n @Prop() url: string = '';\n\n render() {\n if (this.url != '') {\n return (\n <div class={'container space-below-' + this.spaceBelow + ' text-colour-' + this.textColour + ' text-align-' + this.textAlign}>\n <a href={this.url}>\n <div\n class={\n 'sleeve circle-' +\n this.circle.toString() +\n ' border-colour-' +\n this.backgroundColour +\n ' background-colour-' +\n this.backgroundColour +\n ' border-width-' +\n this.borderWidth\n }\n >\n {this.imageUrl != '' ? (\n <div\n data-ratio={this.ratio}\n class={'image-wrap image-style-' + this.imageStyle + ' rounded-' + this.rounded.toString()}\n style={{ 'background-image': \"url('\" + this.imageUrl + \"')\" }}\n >\n <img src={this.imageUrl} alt={this.fullName} title={this.fullName} />\n <div class={'circle ' + this.circleColour}>\n <svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\">\n <path stroke-color=\"1\" d=\"M11 11v-11h1v11h11v1h-11v11h-1v-11h-11v-1h11z\" />\n </svg>\n </div>\n </div>\n ) : null}\n </div>\n <h3 class=\"full-name\">{this.fullName}</h3>\n <div class=\"job-title\">{this.jobTitle}</div>\n </a>\n </div>\n );\n } else {\n return (\n <div class={'container space-below-' + this.spaceBelow + ' text-colour-' + this.textColour + ' text-align-' + this.textAlign}>\n <div\n class={\n 'sleeve circle-' +\n this.circle.toString() +\n ' border-colour-' +\n this.backgroundColour +\n ' background-colour-' +\n this.backgroundColour +\n ' border-width-' +\n this.borderWidth\n }\n >\n {this.imageUrl != '' ? (\n <div\n data-ratio={this.ratio}\n class={'image-wrap image-style-' + this.imageStyle + ' rounded-' + this.rounded.toString()}\n style={{ 'background-image': \"url('\" + this.imageUrl + \"')\" }}\n >\n <img src={this.imageUrl} alt={this.fullName} title={this.fullName} />\n </div>\n ) : null}\n </div>\n <h3 class=\"full-name\">{this.fullName}</h3>\n <div class=\"job-title\">{this.jobTitle}</div>\n </div>\n );\n }\n }\n}\n"],"version":3}
|
|
@@ -8,10 +8,25 @@ const BiggiveBoxedContent$1 = /*@__PURE__*/ proxyCustomElement(class BiggiveBoxe
|
|
|
8
8
|
super();
|
|
9
9
|
this.__registerHost();
|
|
10
10
|
this.__attachShadow();
|
|
11
|
+
/**
|
|
12
|
+
* Space below component
|
|
13
|
+
*/
|
|
11
14
|
this.spaceBelow = 0;
|
|
15
|
+
/**
|
|
16
|
+
* Vertical padding
|
|
17
|
+
*/
|
|
12
18
|
this.verticalPadding = 3;
|
|
19
|
+
/**
|
|
20
|
+
* Horizontal padding
|
|
21
|
+
*/
|
|
13
22
|
this.horizontalPadding = 3;
|
|
23
|
+
/**
|
|
24
|
+
* Background colour
|
|
25
|
+
*/
|
|
14
26
|
this.backgroundColour = 'white';
|
|
27
|
+
/**
|
|
28
|
+
* Shadow
|
|
29
|
+
*/
|
|
15
30
|
this.shadow = true;
|
|
16
31
|
}
|
|
17
32
|
render() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-boxed-content.js","mappings":";;AAAA,MAAM,sBAAsB,GAAG,ujGAAujG,CAAC;AACvlG,kCAAe,sBAAsB;;MCMxBA,qBAAmB
|
|
1
|
+
{"file":"biggive-boxed-content.js","mappings":";;AAAA,MAAM,sBAAsB,GAAG,ujGAAujG,CAAC;AACvlG,kCAAe,sBAAsB;;MCMxBA,qBAAmB;IALhC;;;;;;;QASU,eAAU,GAAW,CAAC,CAAC;;;;QAIvB,oBAAe,GAAW,CAAC,CAAC;;;;QAI5B,sBAAiB,GAAW,CAAC,CAAC;;;;QAI9B,qBAAgB,GAAW,OAAO,CAAC;;;;QAInC,WAAM,GAAY,IAAI,CAAC;KAsBhC;IApBC,MAAM;QACJ,QACE,4DACE,KAAK,EACH,8BAA8B;gBAC9B,IAAI,CAAC,gBAAgB;gBACrB,eAAe;gBACf,IAAI,CAAC,UAAU;gBACf,sBAAsB;gBACtB,IAAI,CAAC,iBAAiB;gBACtB,oBAAoB;gBACpB,IAAI,CAAC,eAAe;gBACpB,UAAU;gBACV,IAAI,CAAC,MAAM,IAGb,8DAAa,CACT,EACN;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveBoxedContent"],"sources":["src/components/biggive-boxed-content/biggive-boxed-content.scss?tag=biggive-boxed-content&encapsulation=shadow","src/components/biggive-boxed-content/biggive-boxed-content.tsx"],"sourcesContent":["@include backgrounds();\n\n:host {\n display: content;\n}\n\n.container {\n @include standard-font();\n &.shadow-true {\n @include lower-shadow();\n } \n}\n\n.horizontal-padding-1 { padding-left: $spacer-1; padding-right: $spacer-1; }\n.horizontal-padding-2 { padding-left: $spacer-2; padding-right: $spacer-2; }\n.horizontal-padding-3 { padding-left: $spacer-3; padding-right: $spacer-3; }\n.horizontal-padding-4 { padding-left: $spacer-4; padding-right: $spacer-4; }\n.horizontal-padding-5 { padding-left: $spacer-5; padding-right: $spacer-5; }\n.horizontal-padding-6 { padding-left: $spacer-6; padding-right: $spacer-6; }\n\n.vertical-padding-1 { padding-top: $spacer-1; padding-bottom: $spacer-1; }\n.vertical-padding-2 { padding-top: $spacer-2; padding-bottom: $spacer-2; }\n.vertical-padding-3 { padding-top: $spacer-3; padding-bottom: $spacer-3; }\n.vertical-padding-4 { padding-top: $spacer-4; padding-bottom: $spacer-4; }\n.vertical-padding-5 { padding-top: $spacer-5; padding-bottom: $spacer-5; }\n.vertical-padding-6 { padding-top: $spacer-6; padding-bottom: $spacer-6; }","import { Component, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'biggive-boxed-content',\n styleUrl: 'biggive-boxed-content.scss',\n shadow: true,\n})\nexport class BiggiveBoxedContent {\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 0;\n /**\n * Vertical padding\n */\n @Prop() verticalPadding: number = 3;\n /**\n * Horizontal padding\n */\n @Prop() horizontalPadding: number = 3;\n /**\n * Background colour\n */\n @Prop() backgroundColour: string = 'white';\n /**\n * Shadow\n */\n @Prop() shadow: boolean = true;\n\n render() {\n return (\n <div\n class={\n 'container background-colour-' +\n this.backgroundColour +\n ' space-below-' +\n this.spaceBelow +\n ' horizontal-padding-' +\n this.horizontalPadding +\n ' vertical-padding-' +\n this.verticalPadding +\n ' shadow-' +\n this.shadow\n }\n >\n <slot></slot>\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -8,13 +8,18 @@ const BiggiveBrandedImage$1 = /*@__PURE__*/ proxyCustomElement(class BiggiveBran
|
|
|
8
8
|
super();
|
|
9
9
|
this.__registerHost();
|
|
10
10
|
this.__attachShadow();
|
|
11
|
+
/**
|
|
12
|
+
* Space below component
|
|
13
|
+
*/
|
|
11
14
|
this.spaceBelow = 0;
|
|
15
|
+
/**
|
|
16
|
+
* Full URL of a image.
|
|
17
|
+
*/
|
|
12
18
|
this.imageUrl = '';
|
|
19
|
+
/**
|
|
20
|
+
* Full URL of the logo.
|
|
21
|
+
*/
|
|
13
22
|
this.logoUrl = '';
|
|
14
|
-
this.slug = undefined;
|
|
15
|
-
this.charityName = undefined;
|
|
16
|
-
this.charityLocation = undefined;
|
|
17
|
-
this.charityUrl = undefined;
|
|
18
23
|
}
|
|
19
24
|
render() {
|
|
20
25
|
return (h("div", { key: '23614f7c92777ff9cc505df3ba05e414266140ae', class: 'container space-below-' + this.spaceBelow }, h("div", { key: 'de69e9303308ff4be55295f6d98c8df514ed1379', class: "slug" }, this.slug), this.imageUrl !== undefined && this.imageUrl !== null ? (h("div", { class: "image-wrap" }, h("img", { src: this.imageUrl }))) : null, this.logoUrl !== undefined && this.logoUrl !== null ? h("div", { class: "logo-wrap", style: { 'background-image': "url('" + this.logoUrl + "')" } }) : null, this.charityName !== undefined && this.charityName !== null ? h("h3", { class: "title" }, this.charityName) : null, this.charityLocation !== undefined && this.charityLocation !== null ? h("div", { class: "charity-info" }, this.charityLocation) : null));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-branded-image.js","mappings":";;AAAA,MAAM,sBAAsB,GAAG,6vDAA6vD,CAAC;AAC7xD,kCAAe,sBAAsB;;MCMxBA,qBAAmB
|
|
1
|
+
{"file":"biggive-branded-image.js","mappings":";;AAAA,MAAM,sBAAsB,GAAG,6vDAA6vD,CAAC;AAC7xD,kCAAe,sBAAsB;;MCMxBA,qBAAmB;IALhC;;;;;;;QASU,eAAU,GAAW,CAAC,CAAC;;;;QAIvB,aAAQ,GAAW,EAAE,CAAC;;;;QAKtB,YAAO,GAAW,EAAE,CAAC;KAuC9B;IAhBC,MAAM;QACJ,QACE,4DAAK,KAAK,EAAE,wBAAwB,GAAG,IAAI,CAAC,UAAU,IACnD,4DAAK,KAAK,EAAC,MAAM,IAAE,IAAI,CAAC,IAAI,CAAO,EACnC,IAAI,CAAC,QAAQ,KAAK,SAAS,IAAI,IAAI,CAAC,QAAQ,KAAK,IAAI,IACpD,WAAK,KAAK,EAAC,YAAY,IACrB,WAAK,GAAG,EAAE,IAAI,CAAC,QAAQ,GAAI,CACvB,IACJ,IAAI,EACP,IAAI,CAAC,OAAO,KAAK,SAAS,IAAI,IAAI,CAAC,OAAO,KAAK,IAAI,GAAG,WAAK,KAAK,EAAC,WAAW,EAAC,KAAK,EAAE,EAAE,kBAAkB,EAAE,OAAO,GAAG,IAAI,CAAC,OAAO,GAAG,IAAI,EAAE,GAAQ,GAAG,IAAI,EAExJ,IAAI,CAAC,WAAW,KAAK,SAAS,IAAI,IAAI,CAAC,WAAW,KAAK,IAAI,GAAG,UAAI,KAAK,EAAC,OAAO,IAAE,IAAI,CAAC,WAAW,CAAM,GAAG,IAAI,EAC9G,IAAI,CAAC,eAAe,KAAK,SAAS,IAAI,IAAI,CAAC,eAAe,KAAK,IAAI,GAAG,WAAK,KAAK,EAAC,cAAc,IAAE,IAAI,CAAC,eAAe,CAAO,GAAG,IAAI,CAChI,EACN;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveBrandedImage"],"sources":["src/components/biggive-branded-image/biggive-branded-image.scss?tag=biggive-branded-image&encapsulation=shadow","src/components/biggive-branded-image/biggive-branded-image.tsx"],"sourcesContent":["@include image-alignment();\n@include spacers();\n\n:host {\n display: contents;\n}\n\n.container {\n @include standard-font();\n position: relative;\n .slug {\n text-align: center;\n font-weight: bold;\n background-color: $colour-secondary-green;\n color: $colour-black;\n padding: $spacer-1 $spacer-3;\n width: 100%;\n margin: -17px auto 17px auto;\n transform: translateY(50%);\n box-sizing: border-box;\n }\n\n img {\n width: 100%;\n }\n\n .logo-wrap {\n border-radius: 50%;\n width: 120px;\n height: 120px;\n transform: translateY(-50%);\n margin-top: 30px;\n margin-bottom: -30px; // Breathing space before charity name etc.\n background-size: contain;\n background-position: center center;\n background-repeat: no-repeat;\n background-color: #FFFFFF;\n\n @media screen and (max-width: $screen-tablet-max) {\n width: 100px;\n height: 100px;\n }\n\n @media screen and (max-width: $screen-mobile-max) {\n width: 70px;\n height: 70px;\n margin-top: 20px;\n }\n }\n\n #charityName {\n color: $colour-primary-blue;\n display: block;\n margin-bottom: 5px;\n width: fit-content; // so link doesn't go full width\n }\n\n #charityName, .charity-info {\n font-size: 17px;\n\n @media screen and (max-width: $screen-tablet-max) {\n font-size: 16px;\n }\n\n @media screen and (max-width: $screen-mobile-max) {\n font-size: 15px;\n }\n\n @media screen and (max-width: $screen-mobile-small) {\n font-size: 14px;\n }\n }\n}\n","import { Component, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'biggive-branded-image',\n styleUrl: 'biggive-branded-image.scss',\n shadow: true,\n})\nexport class BiggiveBrandedImage {\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 0;\n /**\n * Full URL of a image.\n */\n @Prop() imageUrl: string = '';\n\n /**\n * Full URL of the logo.\n */\n @Prop() logoUrl: string = '';\n\n /**\n * Slug\n */\n @Prop() slug: string;\n\n /**\n * Charity name\n */\n @Prop() charityName: string;\n\n /**\n * Charity location\n */\n @Prop() charityLocation: string;\n\n /**\n * Link to the charity's website\n * @deprecated We should stop passing this soon, and will link to charity URLs alongside socials.\n */\n @Prop() charityUrl: string;\n\n render() {\n return (\n <div class={'container space-below-' + this.spaceBelow}>\n {<div class=\"slug\">{this.slug}</div>}\n {this.imageUrl !== undefined && this.imageUrl !== null ? (\n <div class=\"image-wrap\">\n <img src={this.imageUrl} />\n </div>\n ) : null}\n {this.logoUrl !== undefined && this.logoUrl !== null ? <div class=\"logo-wrap\" style={{ 'background-image': \"url('\" + this.logoUrl + \"')\" }}></div> : null}\n\n {this.charityName !== undefined && this.charityName !== null ? <h3 class=\"title\">{this.charityName}</h3> : null}\n {this.charityLocation !== undefined && this.charityLocation !== null ? <div class=\"charity-info\">{this.charityLocation}</div> : null}\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -9,19 +9,42 @@ const BiggiveButton = /*@__PURE__*/ proxyCustomElement(class BiggiveButton exten
|
|
|
9
9
|
this.__registerHost();
|
|
10
10
|
this.__attachShadow();
|
|
11
11
|
this.doButtonClick = createEvent(this, "doButtonClick", 7);
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
/**
|
|
13
|
+
* Space below component
|
|
14
|
+
*/
|
|
15
15
|
this.spaceBelow = 1;
|
|
16
|
+
/**
|
|
17
|
+
* Colour Scheme
|
|
18
|
+
*/
|
|
16
19
|
this.colourScheme = 'primary';
|
|
20
|
+
/**
|
|
21
|
+
* Text
|
|
22
|
+
*/
|
|
17
23
|
this.label = 'Click me';
|
|
18
|
-
|
|
24
|
+
/**
|
|
25
|
+
* New Tab
|
|
26
|
+
*/
|
|
19
27
|
this.openInNewTab = false;
|
|
28
|
+
/**
|
|
29
|
+
* Display full width
|
|
30
|
+
*/
|
|
20
31
|
this.fullWidth = false;
|
|
32
|
+
/**
|
|
33
|
+
* Size
|
|
34
|
+
*/
|
|
21
35
|
this.size = 'medium';
|
|
36
|
+
/**
|
|
37
|
+
* Rounded corners
|
|
38
|
+
*/
|
|
22
39
|
this.rounded = false;
|
|
40
|
+
/**
|
|
41
|
+
* Centered
|
|
42
|
+
*/
|
|
23
43
|
this.centered = false;
|
|
24
44
|
this.buttonId = undefined;
|
|
45
|
+
this.handleButtonClick = (event) => {
|
|
46
|
+
this.doButtonClick.emit({ event: event, url: event.target.parentElement.href });
|
|
47
|
+
};
|
|
25
48
|
}
|
|
26
49
|
render() {
|
|
27
50
|
// We always want to have a href so that browsers will see this as a link and allow clicking with keybard.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-button2.js","mappings":";;AAAA,MAAM,gBAAgB,GAAG,u/UAAu/U,CAAC;AACjhV,4BAAe,gBAAgB;;MCMlB,aAAa
|
|
1
|
+
{"file":"biggive-button2.js","mappings":";;AAAA,MAAM,gBAAgB,GAAG,u/UAAu/U,CAAC;AACjhV,4BAAe,gBAAgB;;MCMlB,aAAa;IAL1B;;;;;;;;QAiBU,eAAU,GAAW,CAAC,CAAC;;;;QAKvB,iBAAY,GAAW,SAAS,CAAC;;;;QAKjC,UAAK,GAAW,UAAU,CAAC;;;;QAU3B,iBAAY,GAAY,KAAK,CAAC;;;;QAK9B,cAAS,GAAY,KAAK,CAAC;;;;QAK3B,SAAI,GAAW,QAAQ,CAAC;;;;QAKxB,YAAO,GAAY,KAAK,CAAC;;;;QAKzB,aAAQ,GAAY,KAAK,CAAC;QAE1B,aAAQ,GAAuB,SAAS,CAAC;QAEzC,sBAAiB,GAAG,CAAC,KAAU;YACrC,IAAI,CAAC,aAAa,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,CAAC,MAAM,CAAC,aAAa,CAAC,IAAI,EAAE,CAAC,CAAC;SACjF,CAAC;KAsBH;IApBC,MAAM;;;;QAIJ,MAAM,IAAI,GAAG,IAAI,CAAC,GAAG,IAAI,qBAAqB,CAAC;QAE/C,QACE,4DAAK,KAAK,EAAE,wBAAwB,GAAG,IAAI,CAAC,UAAU,GAAG,YAAY,GAAG,IAAI,CAAC,QAAQ,IACnF,0DACE,IAAI,EAAC,QAAQ,EACb,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,IAAI,CAAC,YAAY,GAAG,QAAQ,GAAG,OAAO,EAC9C,EAAE,EAAE,IAAI,CAAC,QAAQ,EACjB,KAAK,EAAE,gBAAgB,GAAG,IAAI,CAAC,YAAY,GAAG,cAAc,GAAG,IAAI,CAAC,SAAS,CAAC,QAAQ,EAAE,GAAG,QAAQ,GAAG,IAAI,CAAC,IAAI,GAAG,WAAW,GAAG,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,IAEvJ,6DAAM,OAAO,EAAE,IAAI,CAAC,iBAAiB,IAAG,IAAI,CAAC,KAAK,CAAQ,CACxD,CACA,EACN;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/components/biggive-button/biggive-button.scss?tag=biggive-button&encapsulation=shadow","src/components/biggive-button/biggive-button.tsx"],"sourcesContent":["@include spacers();\n\n:host {\n display: contents;\n}\n\n.container {\n @include standard-font();\n a {\n display: inline-block;\n &.full-width-true {\n display: block;\n }\n }\n &.centered-true {\n text-align: center;\n }\n}\n\n.button {\n @include button();\n &.size-small {\n @include button-small();\n }\n\n &.button.rounded-true {\n @include button-rounded();\n }\n}\n// brand-6 color ambiguity (for now keeping its definition outside of the brand colors loop)\n.button-clear-brand-6 {\n color: $colour-brand-grey;\n background-color: transparent;\n text-decoration: underline;\n border: 0;\n padding-left: 0;\n padding-right: 0;\n &:hover {\n text-decoration: none;\n background-color: transparent;\n }\n}\n\n@each $brand, $colour in $colours {\n .button-#{$brand} {\n color: $colour-white; // may be overridden by following rules. Later CSS rules have priority.\n background-color: $colour;\n border-color: $colour;\n &:hover {\n color: $colour;\n background-color: $colour-white; // may be overriden by following rules\n }\n }\n}\n\n// not part of loop, 6 is deprecated\n.button-brand-6 {\n color: $colour-white;\n background-color: $colour-brand-grey;\n border-color: $colour-brand-grey;\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-secondary {\n color: $colour-black;\n &:hover {\n color: $colour-black;\n background-color: $colour-white;\n border-color: $colour-black;\n }\n}\n\n.button-brand-4 {\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-brand-grey {\n color: $colour-white;\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-brand-mhf-turquoise {\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-brand-afa-pink {\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-white {\n color: $colour-primary-blue;\n &:hover {\n color: $colour-black;\n background-color: $colour-secondary-green;\n }\n}\n\n.button-black {\n color: $colour-white;\n &:hover {\n background-color: $colour-white;\n }\n}\n\n.button-grey-extra-light {\n color: $colour-black;\n &:hover {\n background-color: $colour-black;\n }\n}\n\n.button-grey-light {\n color: $colour-black;\n &:hover {\n background-color: $colour-black;\n }}\n\n.button-grey-medium {\n color: $colour-white;\n &:hover {\n background-color: $colour-white;\n }\n}\n\n.button-grey-dark {\n color: $colour-white;\n &:hover {\n background-color: $colour-white;\n }\n}\n\n.button-rounded {\n @include button-rounded();\n }\n\n @each $brand, $colour in $colours {\n .button-clear-#{$brand} {\n color: $colour;\n background-color: transparent;\n text-decoration: underline;\n border: 0;\n padding-left: 0;\n padding-right: 0;\n &:hover {\n color: $colour;\n text-decoration: none;\n background-color: transparent;\n }\n }\n}\n","import { Component, Event, EventEmitter, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'biggive-button',\n styleUrl: 'biggive-button.scss',\n shadow: true,\n})\nexport class BiggiveButton {\n @Event({\n eventName: 'doButtonClick',\n bubbles: true,\n cancelable: true,\n composed: true,\n })\n doButtonClick: EventEmitter<{ event: object; url: string }>;\n\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 1;\n\n /**\n * Colour Scheme\n */\n @Prop() colourScheme: string = 'primary';\n\n /**\n * Text\n */\n @Prop() label: string = 'Click me';\n\n /**\n * URL\n */\n @Prop() url: string | undefined;\n\n /**\n * New Tab\n */\n @Prop() openInNewTab: boolean = false;\n\n /**\n * Display full width\n */\n @Prop() fullWidth: boolean = false;\n\n /**\n * Size\n */\n @Prop() size: string = 'medium';\n\n /**\n * Rounded corners\n */\n @Prop() rounded: boolean = false;\n\n /**\n * Centered\n */\n @Prop() centered: boolean = false;\n\n @Prop() buttonId: undefined | string = undefined;\n\n private handleButtonClick = (event: any) => {\n this.doButtonClick.emit({ event: event, url: event.target.parentElement.href });\n };\n\n render() {\n // We always want to have a href so that browsers will see this as a link and allow clicking with keybard.\n // If there's no or an empty href then it isn't possible to click by keyboard and we would have to handle keyboard\n // interaction separately.\n const href = this.url || 'javascript:void(0);';\n\n return (\n <div class={'container space-below-' + this.spaceBelow + ' centered-' + this.centered}>\n <a\n role=\"button\"\n href={href}\n target={this.openInNewTab ? '_blank' : '_self'}\n id={this.buttonId}\n class={'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString()}\n >\n <span onClick={this.handleButtonClick}>{this.label}</span>\n </a>\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -9,25 +9,53 @@ const BiggiveCallToAction$1 = /*@__PURE__*/ proxyCustomElement(class BiggiveCall
|
|
|
9
9
|
super();
|
|
10
10
|
this.__registerHost();
|
|
11
11
|
this.__attachShadow();
|
|
12
|
+
/**
|
|
13
|
+
* Space above component
|
|
14
|
+
*/
|
|
12
15
|
this.spaceAbove = 0;
|
|
16
|
+
/**
|
|
17
|
+
* Space below component
|
|
18
|
+
*/
|
|
13
19
|
this.spaceBelow = 0;
|
|
20
|
+
/**
|
|
21
|
+
* Default text colour
|
|
22
|
+
*/
|
|
14
23
|
this.defaultTextColour = 'primary';
|
|
24
|
+
/**
|
|
25
|
+
* Slug size
|
|
26
|
+
*/
|
|
15
27
|
this.slugSize = 4;
|
|
28
|
+
/**
|
|
29
|
+
* Slug colour
|
|
30
|
+
*/
|
|
16
31
|
this.slugColour = '';
|
|
17
|
-
|
|
32
|
+
/**
|
|
33
|
+
* Main title colour
|
|
34
|
+
*/
|
|
18
35
|
this.mainTitleColour = '';
|
|
36
|
+
/**
|
|
37
|
+
* Main title size
|
|
38
|
+
*/
|
|
19
39
|
this.mainTitleSize = 2;
|
|
20
|
-
|
|
40
|
+
/**
|
|
41
|
+
* Main title size
|
|
42
|
+
*/
|
|
21
43
|
this.subtitleSize = 4;
|
|
44
|
+
/**
|
|
45
|
+
* Subtitle colour
|
|
46
|
+
*/
|
|
22
47
|
this.subtitleColour = '';
|
|
23
|
-
|
|
48
|
+
/**
|
|
49
|
+
* Teaser colour
|
|
50
|
+
*/
|
|
24
51
|
this.teaserColour = '';
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
52
|
+
/**
|
|
53
|
+
* Primary button Colour Scheme
|
|
54
|
+
*/
|
|
28
55
|
this.primaryButtonColourScheme = 'primary';
|
|
29
|
-
|
|
30
|
-
|
|
56
|
+
/**
|
|
57
|
+
* Secondary button Colour Scheme
|
|
58
|
+
*/
|
|
31
59
|
this.secondaryButtonColourScheme = 'primary';
|
|
32
60
|
}
|
|
33
61
|
render() {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-call-to-action.js","mappings":";;;AAAA,MAAM,sBAAsB,GAAG,khGAAkhG,CAAC;AACljG,kCAAe,sBAAsB;;MCMxBA,qBAAmB
|
|
1
|
+
{"file":"biggive-call-to-action.js","mappings":";;;AAAA,MAAM,sBAAsB,GAAG,khGAAkhG,CAAC;AACljG,kCAAe,sBAAsB;;MCMxBA,qBAAmB;IALhC;;;;;;;QASU,eAAU,GAAW,CAAC,CAAC;;;;QAI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,IAAI,CAAC,gBAAgB,EAAE,KAAK,EAAE,IAAI,CAAC,kBAAkB,GAAmB,CACxI,IACJ,IAAI,EACP,IAAI,CAAC,oBAAoB,IAAI,IAAI,IAAI,IAAI,CAAC,kBAAkB,IAAI,IAAI,IACnE,WAAK,KAAK,EAAC,aAAa,IACtB,uCAA+B,IAAI,CAAC,2BAA2B,EAAE,GAAG,EAAE,IAAI,CAAC,kBAAkB,EAAE,KAAK,EAAE,IAAI,CAAC,oBAAoB,GAAmB,CAC9I,IACJ,IAAI,CACJ,CACF,CACF,EACN;KACH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveCallToAction"],"sources":["src/components/biggive-call-to-action/biggive-call-to-action.scss?tag=biggive-call-to-action&encapsulation=shadow","src/components/biggive-call-to-action/biggive-call-to-action.tsx"],"sourcesContent":["@include headings();\n@include spacers();\n@include text-colours();\n\n:host {\n display: contents;\n @include standard-font();\n}\n\n.container {\n @include section-container();\n position: relative;\n text-align: center;\n}\n\n\n.content-wrap {\n .slug {\n margin: 0;\n padding: 0;\n }\n h2 {\n margin: 0 0 $spacer-1 0;\n padding: 0;\n }\n .subtitle {\n margin: 0 0 $spacer-1 0;\n padding: 0;\n }\n .teaser {\n margin: $spacer-3 auto $spacer-3 auto;\n max-width: 400px;\n padding: 0;\n }\n}\n\n@media screen and (max-width: $screen-mobile-max) {\n .content-wrap {\n text-align: right\n }\n h2 {\n padding: 40px 0;\n }\n}\n","import { Component, Prop, h } from '@stencil/core';\n\n@Component({\n tag: 'biggive-call-to-action',\n styleUrl: 'biggive-call-to-action.scss',\n shadow: true,\n})\nexport class BiggiveCallToAction {\n /**\n * Space above component\n */\n @Prop() spaceAbove: number = 0;\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 0;\n /**\n * Default text colour\n */\n @Prop() defaultTextColour: string = 'primary';\n\n /**\n * Slug size\n */\n @Prop() slugSize: number = 4;\n /**\n * Slug colour\n */\n @Prop() slugColour: string = '';\n /**\n * Slug\n */\n @Prop() slug: string;\n\n /**\n * Main title colour\n */\n @Prop() mainTitleColour: string = '';\n /**\n * Main title size\n */\n @Prop() mainTitleSize: number = 2;\n /**\n * Main title\n */\n @Prop() mainTitle: string;\n\n /**\n * Main title size\n */\n @Prop() subtitleSize: number = 4;\n /**\n * Subtitle colour\n */\n @Prop() subtitleColour: string = '';\n\n /**\n * Subtitle\n */\n @Prop() subtitle: string;\n\n /**\n * Teaser colour\n */\n @Prop() teaserColour: string = '';\n\n /**\n * Teaser\n */\n @Prop() teaser: string;\n\n /**\n * Primary button Url\n */\n @Prop() primaryButtonUrl: string;\n\n /**\n * Primary button Label\n */\n @Prop() primaryButtonLabel: string;\n\n /**\n * Primary button Colour Scheme\n */\n @Prop() primaryButtonColourScheme: string = 'primary';\n\n /**\n * Secondary button Url\n */\n @Prop() secondaryButtonUrl: string;\n\n /**\n * Secondary button Label\n */\n @Prop() secondaryButtonLabel: string;\n\n /**\n * Secondary button Colour Scheme\n */\n @Prop() secondaryButtonColourScheme: string = 'primary';\n\n render() {\n return (\n <div class={'container text-colour-' + this.defaultTextColour + ' space-above-' + this.spaceAbove + ' space-below-' + this.spaceBelow}>\n <div class=\"sleeve\">\n <div class=\"content-wrap\">\n <div class={'slug heading-' + this.slugSize + ' text-colour-' + this.slugColour}>{this.slug}</div>\n <h2 class={'title heading-' + this.mainTitleSize + ' text-colour-' + this.mainTitleColour}>{this.mainTitle}</h2>\n <div class={'slug heading-' + this.subtitleSize + ' text-colour-' + this.subtitleColour}>{this.subtitle}</div>\n <div class={'teaser text-colour-' + this.teaserColour}>{this.teaser}</div>\n {this.primaryButtonLabel != null && this.primaryButtonUrl != null ? (\n <div class=\"button-wrap\">\n <biggive-button colour-scheme={this.primaryButtonColourScheme} url={this.primaryButtonUrl} label={this.primaryButtonLabel}></biggive-button>\n </div>\n ) : null}\n {this.secondaryButtonLabel != null && this.secondaryButtonUrl != null ? (\n <div class=\"button-wrap\">\n <biggive-button colour-scheme={this.secondaryButtonColourScheme} url={this.secondaryButtonUrl} label={this.secondaryButtonLabel}></biggive-button>\n </div>\n ) : null}\n </div>\n </div>\n </div>\n );\n }\n}\n"],"version":3}
|
|
@@ -30,6 +30,44 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class B
|
|
|
30
30
|
this.newSelectedFilterCategory = null;
|
|
31
31
|
this.newSelectedFilterBeneficiary = null;
|
|
32
32
|
this.newSelectedFilterLocation = null;
|
|
33
|
+
/**
|
|
34
|
+
* Space below component
|
|
35
|
+
*/
|
|
36
|
+
this.spaceBelow = 0;
|
|
37
|
+
/**
|
|
38
|
+
* Intro
|
|
39
|
+
*/
|
|
40
|
+
this.intro = 'Find a charity or project';
|
|
41
|
+
/**
|
|
42
|
+
* Optional search text prop. Useful for pre-populating the search field
|
|
43
|
+
* when the page is loaded with a search term already existing in the URL.
|
|
44
|
+
* This can happen when sharing links, or if a donor goes to a campaign page
|
|
45
|
+
* after searching, and then returns to the search results. In such a case,
|
|
46
|
+
* the search box text will clear, unless we use this prop to populate it on
|
|
47
|
+
* rendering. DON-652.
|
|
48
|
+
*/
|
|
49
|
+
this.searchText = null;
|
|
50
|
+
/**
|
|
51
|
+
* Defines the text displayed as the placeholder in the input field
|
|
52
|
+
* before the user types anything
|
|
53
|
+
*/
|
|
54
|
+
this.placeholderText = 'Search';
|
|
55
|
+
/**
|
|
56
|
+
* Defines the text on the search button
|
|
57
|
+
*/
|
|
58
|
+
this.buttonText = 'Search';
|
|
59
|
+
/**
|
|
60
|
+
* For injecting the chosen category to filter by, as per the comment above for `selectedSortByOption`.
|
|
61
|
+
*/
|
|
62
|
+
this.selectedFilterCategory = null;
|
|
63
|
+
/**
|
|
64
|
+
* For injecting the chosen beneficiary to filter by, as per the comment above for `selectedSortByOption`.
|
|
65
|
+
*/
|
|
66
|
+
this.selectedFilterBeneficiary = null;
|
|
67
|
+
/**
|
|
68
|
+
* For injecting the chosen location to filter by, as per the comment above for `selectedSortByOption`.
|
|
69
|
+
*/
|
|
70
|
+
this.selectedFilterLocation = null;
|
|
33
71
|
this.categoryFilterSelectionChanged = (value) => {
|
|
34
72
|
this.newSelectedFilterCategory = value;
|
|
35
73
|
};
|
|
@@ -119,19 +157,6 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class B
|
|
|
119
157
|
filterLocation: null,
|
|
120
158
|
});
|
|
121
159
|
};
|
|
122
|
-
this.spaceBelow = 0;
|
|
123
|
-
this.intro = 'Find a charity or project';
|
|
124
|
-
this.searchText = null;
|
|
125
|
-
this.placeholderText = 'Search';
|
|
126
|
-
this.buttonText = 'Search';
|
|
127
|
-
this.categoryOptions = undefined;
|
|
128
|
-
this.beneficiaryOptions = undefined;
|
|
129
|
-
this.locationOptions = undefined;
|
|
130
|
-
this.selectedSortByOption = undefined;
|
|
131
|
-
this.selectedFilterCategory = null;
|
|
132
|
-
this.selectedFilterBeneficiary = null;
|
|
133
|
-
this.selectedFilterLocation = null;
|
|
134
|
-
this.filtersApplied = undefined;
|
|
135
160
|
}
|
|
136
161
|
/**
|
|
137
162
|
* Typically on non-negligible scroll away from the search area.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"file":"biggive-campaign-card-filter-grid.js","mappings":";;;;;;AAAA,MAAM,gCAAgC,GAAG,soIAAsoI,CAAC;AAChrI,4CAAe,gCAAgC;;ACE/C,MAAM,gBAAgB,GAAG;IACvB,SAAS,EAAE,WAAW;IACtB,YAAY,EAAE,aAAa;IAC3B,WAAW,EAAE,cAAc;IAC3B,aAAa,EAAE,0BAA0B;IACzC,mBAAmB,EAAE,uBAAuB;CACpC,CAAC;MAUEA,+BAA6B;;;;;;QAChC,0BAAqB,GAAG,SAAS,CAAC;QAClC,iCAA4B,GAAG,oBAAoB,CAAC;QACpD,8BAAyB,GAAG,iBAAiB,CAAC;QAC9C,6BAAwB,GAAG,iBAAiB,CAAC;;;;QAM7C,8BAAyB,GAAkB,IAAI,CAAC;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E;YAC1B,OAAO,OAAO,CAAC,GAAG,CAAC,CAAC,MAAc,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC;SAC5E;QAED,OAAO,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,KAAK,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;KACrF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveCampaignCardFilterGrid"],"sources":["src/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.scss?tag=biggive-campaign-card-filter-grid&encapsulation=shadow","src/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.tsx"],"sourcesContent":["@include spacers();\n\n:host {\n display: content;\n}\n\n// Each select needs a higher z-index than the one below,\n// so that the drop-down part will occlude it.\n.select-wrapper-1, .select-wrapper-2, .select-wrapper-3, .select-wrapper-4 {\n position: relative;\n margin-top: 1em;\n}\n.select-wrapper-1 {\n z-index: 4;\n}\n.select-wrapper-2 {\n z-index: 3;\n}\n.select-wrapper-3 {\n z-index: 2;\n }\n.select-wrapper-4 {\n z-index: 1;\n}\n\n.container {\n @include standard-font();\n position: relative;\n .search-wrap {\n @include lower-shadow();\n background-color: $colour-white;\n padding: $spacer-3 $spacer-4;\n margin-bottom: $spacer-3;\n h4 {\n margin-bottom: $spacer-3;\n }\n .field-wrap {\n @include flex-container-row();\n\n .input-wrap {\n @include flex-container-row();\n padding-bottom: $spacer-1;\n border-bottom: 1px solid $colour-black;\n margin-right: $spacer-4;\n flex-grow: 1;\n input {\n border: 0;\n }\n }\n button {\n padding: 5px 30px;\n }\n }\n }\n}\n.selected-filter-wrap {\n display: flex;\n margin-bottom: 30px;\n padding: 0;\n .button {\n cursor: pointer;\n border-radius: 20px;\n padding: 5px 50px 5px 20px;\n margin-right: 15px;\n background-color: $colour-tertiary-coral;;\n color: $colour-black;\n border: 1px solid $colour-tertiary-coral;\n text-decoration: none;\n background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIKCSB2aWV3Qm94PSIwIDAgMTguNCAxOC40IiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAxOC40IDE4LjQ7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHN0eWxlIHR5cGU9InRleHQvY3NzIj4KCS5zdDB7c3Ryb2tlOiMwMDAwMDA7fQo8L3N0eWxlPgo8cGF0aCBjbGFzcz0ic3QwIiBkPSJNOS4yLDguNUwxNywwLjdsMC43LDAuN0w5LjksOS4ybDcuOCw3LjhMMTcsMTcuN0w5LjIsOS45bC03LjgsNy44TDAuNywxN2w3LjgtNy44TDAuNywxLjRsMC43LTAuN0w5LjIsOC41eiIvPgo8L3N2Zz4K);\n background-repeat: no-repeat;\n background-position: right 20px center;\n background-size: 12px auto;\n &:hover {\n background-color: $colour-white;\n color: $colour-black;\n }\n }\n .clear-all {\n margin-left: auto;\n a {\n cursor: pointer;\n border-radius: 20px;\n padding: 5px 20px;\n background-color: $colour-primary-blue;\n color: $colour-white;\n border: 1px solid $colour-primary-blue;\n text-decoration: none;\n &:hover {\n background-color: $colour-white;\n color: $colour-primary-blue;\n }\n }\n }\n}\n\n.sort-filter-wrap {\n display: flex;\n justify-content: flex-end;\n margin-bottom: $spacer-4;\n padding: 0;\n text-align: right;\n .clear-all {\n cursor: pointer;\n vertical-align: center;\n margin-top: auto;\n margin-bottom: auto;\n }\n\n display: flex;\n .sort-wrap {\n margin-left: 15px;\n }\n\n .filter-wrap {\n background-color: $colour-grey-background; // temp for testing dropdown\n\n margin-left: $spacer-3;\n\n .button.filter {\n padding-left: 60px;\n padding-right: 30px;\n\n .filter-icon {\n content: '';\n display: block;\n position: absolute;\n left: 25px;\n top: 17px;\n width: 13px;\n height: 13px;\n\n svg {\n width: 100%;\n height: auto;\n vertical-align: top;\n\n &:hover {\n fill: $colour-primary-blue;\n }\n }\n }\n }\n }\n}\n\n.icon {\n @include icon();\n margin: auto;\n\n > path {\n fill: $colour-primary-blue;\n }\n}\n\n.icon-clear-all {\n > path {\n fill: $colour-black;\n }\n}\n\n@media screen and (max-width: $screen-mobile-small) {\n .sort-filter-wrap {\n flex-direction: column-reverse;\n .sort-wrap {\n margin-top: 20px;\n margin-bottom: 20px;\n }\n }\n}\n\n@media screen and (max-width: $screen-mobile-x-small) {\n .sort-filter-wrap {\n justify-content: space-between;\n .sort-wrap {\n margin-left: 0px;\n }\n .filter-wrap {\n margin-left: 3px;\n }\n }\n}\n\n.align-right {\n text-align: right;\n}\n\n.input-text {\n @include input-text();\n}\n\n.text-colour-primary {\n color: $colour-primary-blue;\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State } from '@stencil/core';\nimport { faMagnifyingGlass } from '@fortawesome/pro-solid-svg-icons';\n\nconst sortOptionLabels = {\n relevance: 'Relevance',\n amountRaised: 'Most raised',\n leastRaised: 'Least raised',\n closeToTarget: 'Close to campaign target',\n matchFundsRemaining: 'Match funds remaining',\n} as const;\n\nexport type sortOptionKey = keyof typeof sortOptionLabels;\nexport type sortOptionLabel = (typeof sortOptionLabels)[sortOptionKey];\n\n@Component({\n tag: 'biggive-campaign-card-filter-grid',\n styleUrl: 'biggive-campaign-card-filter-grid.scss',\n shadow: true,\n})\nexport class BiggiveCampaignCardFilterGrid {\n private sortByPlaceholderText = 'Sort by';\n private beneficiariesPlaceHolderText = 'Select beneficiary';\n private categoriesPlaceHolderText = 'Select category';\n private locationsPlaceHolderText = 'Select location';\n private initialSortByOption: sortOptionLabel;\n\n /**\n * This and similar properties represent selections made in the popup but not yet applied.\n */\n private newSelectedFilterCategory: string | null = null;\n private newSelectedFilterBeneficiary: string | null = null;\n private newSelectedFilterLocation: string | null = null;\n\n @Element() el: HTMLBiggiveCampaignCardFilterGridElement;\n\n /**\n * This event `doSearchAndFilterUpdate` event is emitted and propogates to the parent\n * component which handles it\n */\n @Event({\n eventName: 'doSearchAndFilterUpdate',\n bubbles: true,\n cancelable: true,\n composed: true,\n })\n doSearchAndFilterUpdate: EventEmitter<{\n searchText: string | null;\n sortBy: string | null;\n filterCategory: string | null;\n filterBeneficiary: string | null;\n filterLocation: string | null;\n }>;\n\n /**\n * Typically on non-negligible scroll away from the search area.\n */\n @Method() async unfocusInputs() {\n this.unfocusTextInput();\n }\n\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 0;\n\n /**\n * Intro\n */\n @Prop() intro: string = 'Find a charity or project';\n\n /**\n * Optional search text prop. Useful for pre-populating the search field\n * when the page is loaded with a search term already existing in the URL.\n * This can happen when sharing links, or if a donor goes to a campaign page\n * after searching, and then returns to the search results. In such a case,\n * the search box text will clear, unless we use this prop to populate it on\n * rendering. DON-652.\n */\n @Prop() searchText: string | null = null;\n\n /**\n * Defines the text displayed as the placeholder in the input field\n * before the user types anything\n */\n @Prop() placeholderText: string = 'Search';\n\n /**\n * Defines the text on the search button\n */\n @Prop() buttonText: string = 'Search';\n\n /**\n * JSON array of category key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() categoryOptions: string | Record<string, string> | string[];\n\n /**\n * JSON array of beneficiary key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() beneficiaryOptions: string | Record<string, string> | string[];\n\n /**\n * JSON array of location key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() locationOptions: string | Record<string, string> | string[];\n\n /**\n * This helps us inject a pre-selected dropdown value from outside of this component.\n * This is especially helpful for the Meta campaign and Explore pages, where searching\n * by text wipes out previous sort options and re-uses Relevance, or where one of those\n * two pages is loaded directly with URL parameters - in such a scenario the dropdown\n * shows that it's pre-selected. DON-558.\n */\n @Prop({ mutable: true })\n selectedSortByOption: sortOptionLabel;\n\n /**\n * For injecting the chosen category to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterCategory: string | null = null;\n\n /**\n * For injecting the chosen beneficiary to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterBeneficiary: string | null = null;\n\n /**\n * For injecting the chosen location to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterLocation: string | null = null;\n\n /**\n * State variable - causes re-render on change\n */\n @State() filtersApplied: boolean;\n\n private categoryFilterSelectionChanged = (value: string) => {\n this.newSelectedFilterCategory = value;\n };\n\n private beneficiarySelectionChanged = (value: string) => {\n this.newSelectedFilterBeneficiary = value;\n };\n\n private locationSelectionChanged = (value: string) => {\n this.newSelectedFilterLocation = value;\n };\n\n private sortBySelectionChanged = (value: sortOptionLabel) => {\n this.selectedSortByOption = value;\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n };\n\n private getSearchAndFilterObject() {\n return {\n searchText: this.searchText,\n sortBy: this.selectedSortByOption,\n filterCategory: this.selectedFilterCategory,\n filterBeneficiary: this.selectedFilterBeneficiary,\n filterLocation: this.selectedFilterLocation,\n };\n }\n\n private handleApplyFilterButtonClick = () => {\n this.selectedFilterCategory = this.newSelectedFilterCategory ?? this.selectedFilterCategory;\n this.selectedFilterBeneficiary = this.newSelectedFilterBeneficiary ?? this.selectedFilterBeneficiary;\n this.selectedFilterLocation = this.newSelectedFilterLocation ?? this.selectedFilterLocation;\n\n const searchAndFilterObj = this.getSearchAndFilterObject();\n this.doSearchAndFilterUpdate.emit(searchAndFilterObj);\n\n const filterPopup = this.el.shadowRoot?.getElementById('filter-popup') as HTMLBiggivePopupElement | undefined;\n if (filterPopup) {\n filterPopup.closeFromOutside();\n }\n\n this.filtersApplied =\n typeof searchAndFilterObj.filterBeneficiary === 'string' || typeof searchAndFilterObj.filterCategory === 'string' || typeof searchAndFilterObj.filterLocation === 'string';\n };\n\n private removeFilter(filterKey: 'locations' | 'categories' | 'beneficiaries') {\n switch (filterKey) {\n case 'beneficiaries':\n this.selectedFilterBeneficiary = null;\n break;\n case 'categories':\n this.selectedFilterCategory = null;\n break;\n case 'locations':\n this.selectedFilterLocation = null;\n break;\n default:\n // This asks the compiler to check that we are in dead code, i.e. we covered all the possible filter keys\n // above. If we missed one we would get a compile error trying to assign a string to a never.\n const exhaustiveSwitch: never = filterKey;\n console.error(exhaustiveSwitch);\n }\n\n const selectEl = this.el.shadowRoot?.getElementById(filterKey) as HTMLBiggiveFormFieldSelectElement | undefined;\n if (!selectEl) {\n return;\n }\n\n selectEl.selectedLabel = null;\n selectEl.selectedValue = null;\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n }\n\n private handleSearchButtonPressed = () => {\n this.unfocusTextInput();\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n\n if (this.hasSearchTerm()) {\n this.selectedSortByOption = 'Relevance';\n }\n };\n\n private handleSearchTextChanged = (event: any) => {\n this.searchText = event.target.value;\n };\n\n private handleEnterPressed = (ev: KeyboardEvent) => {\n if (ev.key === 'Enter') {\n this.unfocusTextInput();\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n }\n };\n\n private handleFilterButtonClick = () => {\n this.newSelectedFilterBeneficiary = this.selectedFilterBeneficiary;\n this.newSelectedFilterCategory = this.selectedFilterCategory;\n this.newSelectedFilterLocation = this.selectedFilterLocation;\n\n const filterPopup = this.el.shadowRoot?.getElementById('filter-popup') as HTMLBiggivePopupElement | undefined;\n if (filterPopup) {\n filterPopup.openFromOutside();\n }\n };\n\n private handleClearAll = () => {\n this.unfocusTextInput();\n\n // Set the 'Filters' button back to the primary background colour\n this.filtersApplied = false;\n\n // Clear all\n this.searchText = null;\n this.selectedSortByOption = this.initialSortByOption;\n this.selectedFilterBeneficiary = null;\n this.selectedFilterCategory = null;\n this.selectedFilterLocation = null;\n\n // Clear <biggive-form-field-select> components' internal selectedValue and selectedLabel. DON-654.\n ['sort-by', 'categories', 'beneficiaries', 'locations', 'funding'].forEach(id => {\n const theEl = this.el.shadowRoot?.getElementById(id) as HTMLBiggiveFormFieldSelectElement | undefined;\n if (!theEl) {\n return;\n }\n\n theEl.selectedValue = null;\n theEl.selectedLabel = null;\n });\n\n const selectedFilters = this.el.shadowRoot?.querySelector('.selected-filters');\n if (selectedFilters) {\n selectedFilters.querySelectorAll('.button').forEach(button => {\n button.remove();\n });\n }\n\n // Emit the doSearchAndFilterUpdate event with null values. DON-654\n this.doSearchAndFilterUpdate.emit({\n searchText: null,\n sortBy: null,\n filterCategory: null,\n filterBeneficiary: null,\n filterLocation: null,\n });\n };\n\n /**\n * We've seen desktop Safari jump to this input when it's focused at times when that's\n * unhelpful, so on a few occasions we proactively blur it.\n */\n private unfocusTextInput() {\n const input = this.el.shadowRoot?.querySelector('.input-text') as HTMLInputElement | undefined;\n input?.blur();\n }\n\n componentWillRender() {\n this.filtersApplied = this.selectedFilterCategory !== null || this.selectedFilterBeneficiary !== null || this.selectedFilterLocation !== null;\n this.initialSortByOption = this.selectedSortByOption;\n }\n\n render() {\n const sortOptions = this.getSortOptions();\n\n return (\n <div class={'container space-below-' + this.spaceBelow}>\n <div class=\"sleeve\">\n <div class=\"search-wrap\">\n <h4>{this.intro}</h4>\n <div class=\"field-wrap\">\n <div class=\"input-wrap\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"icon\" viewBox=\"0 0 512 512\">\n <path d={faMagnifyingGlass.icon[4].toString()} />\n </svg>\n <input\n type=\"text\"\n value={this.searchText ?? ''}\n class=\"input-text\"\n placeholder={this.placeholderText}\n onInput={this.handleSearchTextChanged}\n onKeyDown={this.handleEnterPressed}\n />\n </div>\n <biggive-button onClick={this.handleSearchButtonPressed} label={this.buttonText} />\n </div>\n </div>\n <div class=\"sort-filter-wrap\">\n <div class=\"filter-wrap\">\n <biggive-button class=\"filter\" colourScheme=\"primary\" onClick={this.handleFilterButtonClick} label=\"Filter\" fullWidth={true} space-below=\"0\"></biggive-button>\n <biggive-popup id=\"filter-popup\">\n <h4 class=\"space-above-0 space-below-3 text-colour-primary\">Filters</h4>\n <div class=\"select-wrapper-1\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Category\"\n placeholder={this.categoriesPlaceHolderText}\n selectedLabel={this.selectedFilterCategory}\n selectedValue={this.selectedFilterCategory}\n options={this.optionsToArray(this.categoryOptions || [])}\n selectionChanged={this.categoryFilterSelectionChanged}\n id=\"categories\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"select-wrapper-2\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Beneficiary\"\n placeholder={this.beneficiariesPlaceHolderText}\n selectedLabel={this.selectedFilterBeneficiary}\n selectedValue={this.selectedFilterBeneficiary}\n options={this.optionsToArray(this.beneficiaryOptions || [])}\n selectionChanged={this.beneficiarySelectionChanged}\n id=\"beneficiaries\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"select-wrapper-3\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Location\"\n placeholder={this.locationsPlaceHolderText}\n selectedLabel={this.selectedFilterLocation}\n selectedValue={this.selectedFilterLocation}\n options={this.optionsToArray(this.locationOptions || [])}\n selectionChanged={this.locationSelectionChanged}\n id=\"locations\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"align-right\">\n <biggive-button label=\"Apply filters\" onClick={this.handleApplyFilterButtonClick} />\n </div>\n </biggive-popup>\n </div>\n\n <div class=\"sort-wrap\">\n <biggive-form-field-select\n options={sortOptions}\n prompt={null}\n select-style=\"underlined\"\n placeholder={this.sortByPlaceholderText}\n selectedLabel={this.selectedSortByOption}\n selectedValue={this.getSelectedValue()}\n selectionChanged={this.sortBySelectionChanged}\n id=\"sort-by\"\n >\n <biggive-form-field-select-option value=\"amountRaised\" label=\"Most raised\"></biggive-form-field-select-option>\n <biggive-form-field-select-option value=\"leastRaised\" label=\"Least raised\"></biggive-form-field-select-option>\n <biggive-form-field-select-option value=\"matchFundsRemaining\" label=\"Match funds remaining\"></biggive-form-field-select-option>\n {(this.searchText || '').length > 0 ? <biggive-form-field-select-option value=\"Relevance\" label=\"Relevance\"></biggive-form-field-select-option> : null}\n </biggive-form-field-select>\n </div>\n </div>\n <div class=\"selected-filter-wrap\">\n <div class=\"selected-filters\">\n {this.selectedFilterCategory && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('categories');\n }}\n >\n {this.selectedFilterCategory}\n </span>\n )}\n {this.selectedFilterBeneficiary && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('beneficiaries');\n }}\n >\n {this.selectedFilterBeneficiary}\n </span>\n )}\n {this.selectedFilterLocation && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('locations');\n }}\n >\n {this.selectedFilterLocation}\n </span>\n )}\n </div>\n <div class=\"clear-all\">\n <a onClick={this.handleClearAll}>Clear all</a>\n </div>\n </div>\n <div class=\"campaign-grid\">\n <slot name=\"campaign-grid\"></slot>\n </div>\n </div>\n </div>\n );\n }\n\n // I'm not sure if I understand the reasoning for own-methods-must-be-private. I made the method below public to unit\n // test it. Maybe the idea is that we should move anything with enough logic to test outside the component class? I\n // can do that if people think it's better.\n //\n // eslint-disable-next-line @stencil-community/own-methods-must-be-private\n public getSelectedValue(): undefined | string {\n const sortByOption = this.selectedSortByOption;\n if (sortByOption === undefined) {\n return undefined;\n }\n const sortOptions = this.getSortOptions();\n const selected = sortOptions.filter(option => {\n return option.label.toLowerCase() === sortByOption.toLowerCase();\n })[0];\n\n return selected?.value;\n }\n\n private getSortOptions(): {\n label: sortOptionLabel;\n value: sortOptionKey;\n }[] {\n // @ts-ignore - see https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n const sortOptionKeys: sortOptionKey[] = Object.getOwnPropertyNames(sortOptionLabels);\n const relevantOptionKeys = sortOptionKeys.filter(key => key !== 'relevance' || this.hasSearchTerm());\n\n return relevantOptionKeys.map((key: sortOptionKey) => ({ value: key, label: sortOptionLabels[key] }));\n }\n\n private hasSearchTerm() {\n return typeof this.searchText === 'string' && this.searchText.length > 0;\n }\n\n private optionsToArray(options: string | Record<string, string> | string[]): {\n label: string;\n value: string;\n }[] {\n if (typeof options === 'string') {\n options = JSON.parse(options);\n }\n if (Array.isArray(options)) {\n return options.map((option: string) => ({ value: option, label: option }));\n }\n\n return Object.entries(options).map(entry => ({ value: entry[0], label: entry[1] }));\n }\n}\n"],"version":3}
|
|
1
|
+
{"file":"biggive-campaign-card-filter-grid.js","mappings":";;;;;;AAAA,MAAM,gCAAgC,GAAG,soIAAsoI,CAAC;AAChrI,4CAAe,gCAAgC;;ACE/C,MAAM,gBAAgB,GAAG;IACvB,SAAS,EAAE,WAAW;IACtB,YAAY,EAAE,aAAa;IAC3B,WAAW,EAAE,cAAc;IAC3B,aAAa,EAAE,0BAA0B;IACzC,mBAAmB,EAAE,uBAAuB;CACpC,CAAC;MAUEA,+BAA6B;IAL1C;;;;;QAMU,0BAAqB,GAAG,SAAS,CAAC;QAClC,iCAA4B,GAAG,oBAAoB,CAAC;QACpD,8BAAyB,GAAG,iBAAiB,CAAC;QAC9C,6BAAwB,GAAG,iBAAiB,CAAC;;;;QAM7C,8BAAyB,GAAkB,IAAI,CAAC;QAChD,iCAA4B,GAAkB,IAAI,CAAC;QACnD,8BAAyB,GAAkB,IAAI,CAAC;;;;QAgChD,eAAU,GAAW,CAAC,CAAC;;;;QAKvB,UAAK,GAAW,2BAA2B,CAAC;;;;;;;;;QAU5C,eAAU,GAAkB,IAAI,CAAC;;;;;QAMjC,oBAAe,GAAW,QAAQ,CAAC;;;;QAKnC,eAAU,GAAW,QAAQ,CAAC;;;;QA8Bb,2BAAs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,KAAK,EAAE,MAAM,EAAE,CAAC,CAAC,CAAC;SAC5E;QAED,OAAO,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,KAAK,KAAK,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,KAAK,EAAE,KAAK,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;KACrF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":["BiggiveCampaignCardFilterGrid"],"sources":["src/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.scss?tag=biggive-campaign-card-filter-grid&encapsulation=shadow","src/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.tsx"],"sourcesContent":["@include spacers();\n\n:host {\n display: content;\n}\n\n// Each select needs a higher z-index than the one below,\n// so that the drop-down part will occlude it.\n.select-wrapper-1, .select-wrapper-2, .select-wrapper-3, .select-wrapper-4 {\n position: relative;\n margin-top: 1em;\n}\n.select-wrapper-1 {\n z-index: 4;\n}\n.select-wrapper-2 {\n z-index: 3;\n}\n.select-wrapper-3 {\n z-index: 2;\n }\n.select-wrapper-4 {\n z-index: 1;\n}\n\n.container {\n @include standard-font();\n position: relative;\n .search-wrap {\n @include lower-shadow();\n background-color: $colour-white;\n padding: $spacer-3 $spacer-4;\n margin-bottom: $spacer-3;\n h4 {\n margin-bottom: $spacer-3;\n }\n .field-wrap {\n @include flex-container-row();\n\n .input-wrap {\n @include flex-container-row();\n padding-bottom: $spacer-1;\n border-bottom: 1px solid $colour-black;\n margin-right: $spacer-4;\n flex-grow: 1;\n input {\n border: 0;\n }\n }\n button {\n padding: 5px 30px;\n }\n }\n }\n}\n.selected-filter-wrap {\n display: flex;\n margin-bottom: 30px;\n padding: 0;\n .button {\n cursor: pointer;\n border-radius: 20px;\n padding: 5px 50px 5px 20px;\n margin-right: 15px;\n background-color: $colour-tertiary-coral;;\n color: $colour-black;\n border: 1px solid $colour-tertiary-coral;\n text-decoration: none;\n background-image: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4KPHN2ZyB2ZXJzaW9uPSIxLjEiIGlkPSJMYXllcl8xIiB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHhtbG5zOnhsaW5rPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5L3hsaW5rIiB4PSIwcHgiIHk9IjBweCIKCSB2aWV3Qm94PSIwIDAgMTguNCAxOC40IiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCAxOC40IDE4LjQ7IiB4bWw6c3BhY2U9InByZXNlcnZlIj4KPHN0eWxlIHR5cGU9InRleHQvY3NzIj4KCS5zdDB7c3Ryb2tlOiMwMDAwMDA7fQo8L3N0eWxlPgo8cGF0aCBjbGFzcz0ic3QwIiBkPSJNOS4yLDguNUwxNywwLjdsMC43LDAuN0w5LjksOS4ybDcuOCw3LjhMMTcsMTcuN0w5LjIsOS45bC03LjgsNy44TDAuNywxN2w3LjgtNy44TDAuNywxLjRsMC43LTAuN0w5LjIsOC41eiIvPgo8L3N2Zz4K);\n background-repeat: no-repeat;\n background-position: right 20px center;\n background-size: 12px auto;\n &:hover {\n background-color: $colour-white;\n color: $colour-black;\n }\n }\n .clear-all {\n margin-left: auto;\n a {\n cursor: pointer;\n border-radius: 20px;\n padding: 5px 20px;\n background-color: $colour-primary-blue;\n color: $colour-white;\n border: 1px solid $colour-primary-blue;\n text-decoration: none;\n &:hover {\n background-color: $colour-white;\n color: $colour-primary-blue;\n }\n }\n }\n}\n\n.sort-filter-wrap {\n display: flex;\n justify-content: flex-end;\n margin-bottom: $spacer-4;\n padding: 0;\n text-align: right;\n .clear-all {\n cursor: pointer;\n vertical-align: center;\n margin-top: auto;\n margin-bottom: auto;\n }\n\n display: flex;\n .sort-wrap {\n margin-left: 15px;\n }\n\n .filter-wrap {\n background-color: $colour-grey-background; // temp for testing dropdown\n\n margin-left: $spacer-3;\n\n .button.filter {\n padding-left: 60px;\n padding-right: 30px;\n\n .filter-icon {\n content: '';\n display: block;\n position: absolute;\n left: 25px;\n top: 17px;\n width: 13px;\n height: 13px;\n\n svg {\n width: 100%;\n height: auto;\n vertical-align: top;\n\n &:hover {\n fill: $colour-primary-blue;\n }\n }\n }\n }\n }\n}\n\n.icon {\n @include icon();\n margin: auto;\n\n > path {\n fill: $colour-primary-blue;\n }\n}\n\n.icon-clear-all {\n > path {\n fill: $colour-black;\n }\n}\n\n@media screen and (max-width: $screen-mobile-small) {\n .sort-filter-wrap {\n flex-direction: column-reverse;\n .sort-wrap {\n margin-top: 20px;\n margin-bottom: 20px;\n }\n }\n}\n\n@media screen and (max-width: $screen-mobile-x-small) {\n .sort-filter-wrap {\n justify-content: space-between;\n .sort-wrap {\n margin-left: 0px;\n }\n .filter-wrap {\n margin-left: 3px;\n }\n }\n}\n\n.align-right {\n text-align: right;\n}\n\n.input-text {\n @include input-text();\n}\n\n.text-colour-primary {\n color: $colour-primary-blue;\n}\n","import { Component, Element, Event, EventEmitter, h, Method, Prop, State } from '@stencil/core';\nimport { faMagnifyingGlass } from '@fortawesome/pro-solid-svg-icons';\n\nconst sortOptionLabels = {\n relevance: 'Relevance',\n amountRaised: 'Most raised',\n leastRaised: 'Least raised',\n closeToTarget: 'Close to campaign target',\n matchFundsRemaining: 'Match funds remaining',\n} as const;\n\nexport type sortOptionKey = keyof typeof sortOptionLabels;\nexport type sortOptionLabel = (typeof sortOptionLabels)[sortOptionKey];\n\n@Component({\n tag: 'biggive-campaign-card-filter-grid',\n styleUrl: 'biggive-campaign-card-filter-grid.scss',\n shadow: true,\n})\nexport class BiggiveCampaignCardFilterGrid {\n private sortByPlaceholderText = 'Sort by';\n private beneficiariesPlaceHolderText = 'Select beneficiary';\n private categoriesPlaceHolderText = 'Select category';\n private locationsPlaceHolderText = 'Select location';\n private initialSortByOption: sortOptionLabel;\n\n /**\n * This and similar properties represent selections made in the popup but not yet applied.\n */\n private newSelectedFilterCategory: string | null = null;\n private newSelectedFilterBeneficiary: string | null = null;\n private newSelectedFilterLocation: string | null = null;\n\n @Element() el: HTMLBiggiveCampaignCardFilterGridElement;\n\n /**\n * This event `doSearchAndFilterUpdate` event is emitted and propogates to the parent\n * component which handles it\n */\n @Event({\n eventName: 'doSearchAndFilterUpdate',\n bubbles: true,\n cancelable: true,\n composed: true,\n })\n doSearchAndFilterUpdate: EventEmitter<{\n searchText: string | null;\n sortBy: string | null;\n filterCategory: string | null;\n filterBeneficiary: string | null;\n filterLocation: string | null;\n }>;\n\n /**\n * Typically on non-negligible scroll away from the search area.\n */\n @Method() async unfocusInputs() {\n this.unfocusTextInput();\n }\n\n /**\n * Space below component\n */\n @Prop() spaceBelow: number = 0;\n\n /**\n * Intro\n */\n @Prop() intro: string = 'Find a charity or project';\n\n /**\n * Optional search text prop. Useful for pre-populating the search field\n * when the page is loaded with a search term already existing in the URL.\n * This can happen when sharing links, or if a donor goes to a campaign page\n * after searching, and then returns to the search results. In such a case,\n * the search box text will clear, unless we use this prop to populate it on\n * rendering. DON-652.\n */\n @Prop() searchText: string | null = null;\n\n /**\n * Defines the text displayed as the placeholder in the input field\n * before the user types anything\n */\n @Prop() placeholderText: string = 'Search';\n\n /**\n * Defines the text on the search button\n */\n @Prop() buttonText: string = 'Search';\n\n /**\n * JSON array of category key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() categoryOptions: string | Record<string, string> | string[];\n\n /**\n * JSON array of beneficiary key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() beneficiaryOptions: string | Record<string, string> | string[];\n\n /**\n * JSON array of location key/values, or takes a stringified equiavalent (for Storybook)\n */\n @Prop() locationOptions: string | Record<string, string> | string[];\n\n /**\n * This helps us inject a pre-selected dropdown value from outside of this component.\n * This is especially helpful for the Meta campaign and Explore pages, where searching\n * by text wipes out previous sort options and re-uses Relevance, or where one of those\n * two pages is loaded directly with URL parameters - in such a scenario the dropdown\n * shows that it's pre-selected. DON-558.\n */\n @Prop({ mutable: true })\n selectedSortByOption: sortOptionLabel;\n\n /**\n * For injecting the chosen category to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterCategory: string | null = null;\n\n /**\n * For injecting the chosen beneficiary to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterBeneficiary: string | null = null;\n\n /**\n * For injecting the chosen location to filter by, as per the comment above for `selectedSortByOption`.\n */\n @Prop({ mutable: true }) selectedFilterLocation: string | null = null;\n\n /**\n * State variable - causes re-render on change\n */\n @State() filtersApplied: boolean;\n\n private categoryFilterSelectionChanged = (value: string) => {\n this.newSelectedFilterCategory = value;\n };\n\n private beneficiarySelectionChanged = (value: string) => {\n this.newSelectedFilterBeneficiary = value;\n };\n\n private locationSelectionChanged = (value: string) => {\n this.newSelectedFilterLocation = value;\n };\n\n private sortBySelectionChanged = (value: sortOptionLabel) => {\n this.selectedSortByOption = value;\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n };\n\n private getSearchAndFilterObject() {\n return {\n searchText: this.searchText,\n sortBy: this.selectedSortByOption,\n filterCategory: this.selectedFilterCategory,\n filterBeneficiary: this.selectedFilterBeneficiary,\n filterLocation: this.selectedFilterLocation,\n };\n }\n\n private handleApplyFilterButtonClick = () => {\n this.selectedFilterCategory = this.newSelectedFilterCategory ?? this.selectedFilterCategory;\n this.selectedFilterBeneficiary = this.newSelectedFilterBeneficiary ?? this.selectedFilterBeneficiary;\n this.selectedFilterLocation = this.newSelectedFilterLocation ?? this.selectedFilterLocation;\n\n const searchAndFilterObj = this.getSearchAndFilterObject();\n this.doSearchAndFilterUpdate.emit(searchAndFilterObj);\n\n const filterPopup = this.el.shadowRoot?.getElementById('filter-popup') as HTMLBiggivePopupElement | undefined;\n if (filterPopup) {\n filterPopup.closeFromOutside();\n }\n\n this.filtersApplied =\n typeof searchAndFilterObj.filterBeneficiary === 'string' || typeof searchAndFilterObj.filterCategory === 'string' || typeof searchAndFilterObj.filterLocation === 'string';\n };\n\n private removeFilter(filterKey: 'locations' | 'categories' | 'beneficiaries') {\n switch (filterKey) {\n case 'beneficiaries':\n this.selectedFilterBeneficiary = null;\n break;\n case 'categories':\n this.selectedFilterCategory = null;\n break;\n case 'locations':\n this.selectedFilterLocation = null;\n break;\n default:\n // This asks the compiler to check that we are in dead code, i.e. we covered all the possible filter keys\n // above. If we missed one we would get a compile error trying to assign a string to a never.\n const exhaustiveSwitch: never = filterKey;\n console.error(exhaustiveSwitch);\n }\n\n const selectEl = this.el.shadowRoot?.getElementById(filterKey) as HTMLBiggiveFormFieldSelectElement | undefined;\n if (!selectEl) {\n return;\n }\n\n selectEl.selectedLabel = null;\n selectEl.selectedValue = null;\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n }\n\n private handleSearchButtonPressed = () => {\n this.unfocusTextInput();\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n\n if (this.hasSearchTerm()) {\n this.selectedSortByOption = 'Relevance';\n }\n };\n\n private handleSearchTextChanged = (event: any) => {\n this.searchText = event.target.value;\n };\n\n private handleEnterPressed = (ev: KeyboardEvent) => {\n if (ev.key === 'Enter') {\n this.unfocusTextInput();\n this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());\n }\n };\n\n private handleFilterButtonClick = () => {\n this.newSelectedFilterBeneficiary = this.selectedFilterBeneficiary;\n this.newSelectedFilterCategory = this.selectedFilterCategory;\n this.newSelectedFilterLocation = this.selectedFilterLocation;\n\n const filterPopup = this.el.shadowRoot?.getElementById('filter-popup') as HTMLBiggivePopupElement | undefined;\n if (filterPopup) {\n filterPopup.openFromOutside();\n }\n };\n\n private handleClearAll = () => {\n this.unfocusTextInput();\n\n // Set the 'Filters' button back to the primary background colour\n this.filtersApplied = false;\n\n // Clear all\n this.searchText = null;\n this.selectedSortByOption = this.initialSortByOption;\n this.selectedFilterBeneficiary = null;\n this.selectedFilterCategory = null;\n this.selectedFilterLocation = null;\n\n // Clear <biggive-form-field-select> components' internal selectedValue and selectedLabel. DON-654.\n ['sort-by', 'categories', 'beneficiaries', 'locations', 'funding'].forEach(id => {\n const theEl = this.el.shadowRoot?.getElementById(id) as HTMLBiggiveFormFieldSelectElement | undefined;\n if (!theEl) {\n return;\n }\n\n theEl.selectedValue = null;\n theEl.selectedLabel = null;\n });\n\n const selectedFilters = this.el.shadowRoot?.querySelector('.selected-filters');\n if (selectedFilters) {\n selectedFilters.querySelectorAll('.button').forEach(button => {\n button.remove();\n });\n }\n\n // Emit the doSearchAndFilterUpdate event with null values. DON-654\n this.doSearchAndFilterUpdate.emit({\n searchText: null,\n sortBy: null,\n filterCategory: null,\n filterBeneficiary: null,\n filterLocation: null,\n });\n };\n\n /**\n * We've seen desktop Safari jump to this input when it's focused at times when that's\n * unhelpful, so on a few occasions we proactively blur it.\n */\n private unfocusTextInput() {\n const input = this.el.shadowRoot?.querySelector('.input-text') as HTMLInputElement | undefined;\n input?.blur();\n }\n\n componentWillRender() {\n this.filtersApplied = this.selectedFilterCategory !== null || this.selectedFilterBeneficiary !== null || this.selectedFilterLocation !== null;\n this.initialSortByOption = this.selectedSortByOption;\n }\n\n render() {\n const sortOptions = this.getSortOptions();\n\n return (\n <div class={'container space-below-' + this.spaceBelow}>\n <div class=\"sleeve\">\n <div class=\"search-wrap\">\n <h4>{this.intro}</h4>\n <div class=\"field-wrap\">\n <div class=\"input-wrap\">\n <svg xmlns=\"http://www.w3.org/2000/svg\" class=\"icon\" viewBox=\"0 0 512 512\">\n <path d={faMagnifyingGlass.icon[4].toString()} />\n </svg>\n <input\n type=\"text\"\n value={this.searchText ?? ''}\n class=\"input-text\"\n placeholder={this.placeholderText}\n onInput={this.handleSearchTextChanged}\n onKeyDown={this.handleEnterPressed}\n />\n </div>\n <biggive-button onClick={this.handleSearchButtonPressed} label={this.buttonText} />\n </div>\n </div>\n <div class=\"sort-filter-wrap\">\n <div class=\"filter-wrap\">\n <biggive-button class=\"filter\" colourScheme=\"primary\" onClick={this.handleFilterButtonClick} label=\"Filter\" fullWidth={true} space-below=\"0\"></biggive-button>\n <biggive-popup id=\"filter-popup\">\n <h4 class=\"space-above-0 space-below-3 text-colour-primary\">Filters</h4>\n <div class=\"select-wrapper-1\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Category\"\n placeholder={this.categoriesPlaceHolderText}\n selectedLabel={this.selectedFilterCategory}\n selectedValue={this.selectedFilterCategory}\n options={this.optionsToArray(this.categoryOptions || [])}\n selectionChanged={this.categoryFilterSelectionChanged}\n id=\"categories\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"select-wrapper-2\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Beneficiary\"\n placeholder={this.beneficiariesPlaceHolderText}\n selectedLabel={this.selectedFilterBeneficiary}\n selectedValue={this.selectedFilterBeneficiary}\n options={this.optionsToArray(this.beneficiaryOptions || [])}\n selectionChanged={this.beneficiarySelectionChanged}\n id=\"beneficiaries\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"select-wrapper-3\">\n <biggive-form-field-select\n backgroundColour=\"white\"\n prompt=\"Location\"\n placeholder={this.locationsPlaceHolderText}\n selectedLabel={this.selectedFilterLocation}\n selectedValue={this.selectedFilterLocation}\n options={this.optionsToArray(this.locationOptions || [])}\n selectionChanged={this.locationSelectionChanged}\n id=\"locations\"\n space-below=\"2\"\n ></biggive-form-field-select>\n </div>\n\n <div class=\"align-right\">\n <biggive-button label=\"Apply filters\" onClick={this.handleApplyFilterButtonClick} />\n </div>\n </biggive-popup>\n </div>\n\n <div class=\"sort-wrap\">\n <biggive-form-field-select\n options={sortOptions}\n prompt={null}\n select-style=\"underlined\"\n placeholder={this.sortByPlaceholderText}\n selectedLabel={this.selectedSortByOption}\n selectedValue={this.getSelectedValue()}\n selectionChanged={this.sortBySelectionChanged}\n id=\"sort-by\"\n >\n <biggive-form-field-select-option value=\"amountRaised\" label=\"Most raised\"></biggive-form-field-select-option>\n <biggive-form-field-select-option value=\"leastRaised\" label=\"Least raised\"></biggive-form-field-select-option>\n <biggive-form-field-select-option value=\"matchFundsRemaining\" label=\"Match funds remaining\"></biggive-form-field-select-option>\n {(this.searchText || '').length > 0 ? <biggive-form-field-select-option value=\"Relevance\" label=\"Relevance\"></biggive-form-field-select-option> : null}\n </biggive-form-field-select>\n </div>\n </div>\n <div class=\"selected-filter-wrap\">\n <div class=\"selected-filters\">\n {this.selectedFilterCategory && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('categories');\n }}\n >\n {this.selectedFilterCategory}\n </span>\n )}\n {this.selectedFilterBeneficiary && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('beneficiaries');\n }}\n >\n {this.selectedFilterBeneficiary}\n </span>\n )}\n {this.selectedFilterLocation && (\n <span\n class=\"button\"\n onClick={() => {\n this.removeFilter('locations');\n }}\n >\n {this.selectedFilterLocation}\n </span>\n )}\n </div>\n <div class=\"clear-all\">\n <a onClick={this.handleClearAll}>Clear all</a>\n </div>\n </div>\n <div class=\"campaign-grid\">\n <slot name=\"campaign-grid\"></slot>\n </div>\n </div>\n </div>\n );\n }\n\n // I'm not sure if I understand the reasoning for own-methods-must-be-private. I made the method below public to unit\n // test it. Maybe the idea is that we should move anything with enough logic to test outside the component class? I\n // can do that if people think it's better.\n //\n // eslint-disable-next-line @stencil-community/own-methods-must-be-private\n public getSelectedValue(): undefined | string {\n const sortByOption = this.selectedSortByOption;\n if (sortByOption === undefined) {\n return undefined;\n }\n const sortOptions = this.getSortOptions();\n const selected = sortOptions.filter(option => {\n return option.label.toLowerCase() === sortByOption.toLowerCase();\n })[0];\n\n return selected?.value;\n }\n\n private getSortOptions(): {\n label: sortOptionLabel;\n value: sortOptionKey;\n }[] {\n // @ts-ignore - see https://github.com/microsoft/TypeScript/pull/12253#issuecomment-263132208\n const sortOptionKeys: sortOptionKey[] = Object.getOwnPropertyNames(sortOptionLabels);\n const relevantOptionKeys = sortOptionKeys.filter(key => key !== 'relevance' || this.hasSearchTerm());\n\n return relevantOptionKeys.map((key: sortOptionKey) => ({ value: key, label: sortOptionLabels[key] }));\n }\n\n private hasSearchTerm() {\n return typeof this.searchText === 'string' && this.searchText.length > 0;\n }\n\n private optionsToArray(options: string | Record<string, string> | string[]): {\n label: string;\n value: string;\n }[] {\n if (typeof options === 'string') {\n options = JSON.parse(options);\n }\n if (Array.isArray(options)) {\n return options.map((option: string) => ({ value: option, label: option }));\n }\n\n return Object.entries(options).map(entry => ({ value: entry[0], label: entry[1] }));\n }\n}\n"],"version":3}
|
|
@@ -12,28 +12,37 @@ const BiggiveCampaignCard$1 = /*@__PURE__*/ proxyCustomElement(class BiggiveCamp
|
|
|
12
12
|
this.__registerHost();
|
|
13
13
|
this.__attachShadow();
|
|
14
14
|
this.doCardGeneralClick = createEvent(this, "doCardGeneralClick", 7);
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
/**
|
|
16
|
+
* Space below component
|
|
17
|
+
*/
|
|
18
18
|
this.spaceBelow = 4;
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
this.organisationName = undefined;
|
|
23
|
-
this.primaryFigureLabel = undefined;
|
|
24
|
-
this.primaryFigureAmount = undefined;
|
|
25
|
-
this.secondaryFigureLabel = undefined;
|
|
26
|
-
this.secondaryFigureAmount = undefined;
|
|
27
|
-
this.progressBarCounter = undefined;
|
|
19
|
+
/**
|
|
20
|
+
* Donate button label
|
|
21
|
+
*/
|
|
28
22
|
this.donateButtonLabel = 'Donate now';
|
|
29
|
-
|
|
23
|
+
/**
|
|
24
|
+
* Donate button colour scheme
|
|
25
|
+
*/
|
|
30
26
|
this.donateButtonColourScheme = 'primary';
|
|
27
|
+
/**
|
|
28
|
+
* More information button label
|
|
29
|
+
*/
|
|
31
30
|
this.moreInfoButtonLabel = 'Find out more';
|
|
32
|
-
|
|
31
|
+
/**
|
|
32
|
+
* Donate button colour scheme
|
|
33
|
+
*/
|
|
33
34
|
this.moreInfoButtonColourScheme = 'clear-primary';
|
|
35
|
+
/**
|
|
36
|
+
* Boolean flag telling the component if the campaign is in the future (not open yet).
|
|
37
|
+
*/
|
|
34
38
|
this.isFutureCampaign = false;
|
|
39
|
+
/**
|
|
40
|
+
* Boolean flag telling the component if the campaign is in the future (not open yet).
|
|
41
|
+
*/
|
|
35
42
|
this.isPastCampaign = false;
|
|
36
|
-
this.
|
|
43
|
+
this.handleCardGeneralClick = (event) => {
|
|
44
|
+
this.doCardGeneralClick.emit({ event, url: this.moreInfoButtonUrl });
|
|
45
|
+
};
|
|
37
46
|
}
|
|
38
47
|
isEmpty(value) {
|
|
39
48
|
return value === undefined || value === null || value === '';
|