@biggive/components 1.0.137 → 1.0.139
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/p-abbadeba.entry.js +1 -0
- package/dist/cjs/biggive-back-to-top_26.cjs.entry.js +20 -14
- package/dist/cjs/biggive.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/biggive-button/biggive-button.js +1 -22
- package/dist/collection/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.js +35 -6
- package/dist/collection/components/biggive-form-field-select/biggive-form-field-select.js +2 -3
- package/dist/components/biggive-button2.js +2 -6
- package/dist/components/biggive-campaign-card-filter-grid.js +19 -7
- package/dist/components/biggive-form-field-select2.js +2 -3
- package/dist/esm/biggive-back-to-top_26.entry.js +20 -14
- package/dist/esm/biggive.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/biggive-button/biggive-button.d.ts +0 -3
- package/dist/types/components/biggive-campaign-card-filter-grid/biggive-campaign-card-filter-grid.d.ts +10 -2
- package/dist/types/components.d.ts +8 -5
- package/hydrate/index.js +22 -15
- package/package.json +1 -1
- package/dist/biggive/p-9bee4580.entry.js +0 -1
|
@@ -42,7 +42,6 @@ const biggiveButtonCss = "body{background-color:#D7D7D7}h1,h3,h4,h5,h6{margin-bo
|
|
|
42
42
|
const BiggiveButton = class {
|
|
43
43
|
constructor(hostRef) {
|
|
44
44
|
index.registerInstance(this, hostRef);
|
|
45
|
-
this.doButtonClick = index.createEvent(this, "doButtonClick", 7);
|
|
46
45
|
this.spaceBelow = 1;
|
|
47
46
|
this.colourScheme = 'primary';
|
|
48
47
|
this.label = 'Click me';
|
|
@@ -51,11 +50,8 @@ const BiggiveButton = class {
|
|
|
51
50
|
this.size = 'medium';
|
|
52
51
|
this.rounded = false;
|
|
53
52
|
}
|
|
54
|
-
handleButtonClick() {
|
|
55
|
-
this.doButtonClick.emit(this.url);
|
|
56
|
-
}
|
|
57
53
|
render() {
|
|
58
|
-
return (index.h("div", { class: 'container space-below-' + this.spaceBelow }, index.h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() },
|
|
54
|
+
return (index.h("div", { class: 'container space-below-' + this.spaceBelow }, index.h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() }, this.label)));
|
|
59
55
|
}
|
|
60
56
|
};
|
|
61
57
|
BiggiveButton.style = biggiveButtonCss;
|
|
@@ -132,10 +128,7 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
132
128
|
this.filterBeneficiary = null;
|
|
133
129
|
this.filterLocation = null;
|
|
134
130
|
this.filterFunding = null;
|
|
135
|
-
this.
|
|
136
|
-
this.sortBy = event.target.value;
|
|
137
|
-
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
138
|
-
};
|
|
131
|
+
this.sortByPlaceholderText = 'Sort by';
|
|
139
132
|
this.handleApplyFilterButtonClick = () => {
|
|
140
133
|
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
141
134
|
};
|
|
@@ -161,6 +154,7 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
161
154
|
this.beneficiaryOptions = [];
|
|
162
155
|
this.locationOptions = [];
|
|
163
156
|
this.fundingOptions = [];
|
|
157
|
+
this.selectedLabel = null;
|
|
164
158
|
}
|
|
165
159
|
getSearchAndFilterObject() {
|
|
166
160
|
const event = {
|
|
@@ -173,15 +167,28 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
173
167
|
};
|
|
174
168
|
return event;
|
|
175
169
|
}
|
|
176
|
-
doOptionSelectCompletedHandler() {
|
|
170
|
+
doOptionSelectCompletedHandler(event) {
|
|
177
171
|
this.sortBy = this.el.shadowRoot.getElementById('sort-by').selectedValue;
|
|
178
172
|
this.filterCategory = this.el.shadowRoot.getElementById('categories').selectedValue;
|
|
179
173
|
this.filterBeneficiary = this.el.shadowRoot.getElementById('beneficiaries').selectedValue;
|
|
180
174
|
this.filterLocation = this.el.shadowRoot.getElementById('locations').selectedValue;
|
|
181
175
|
this.filterFunding = this.el.shadowRoot.getElementById('funding').selectedValue;
|
|
176
|
+
// If this method was trigerred by the selection of a 'Sort by' dropdown option, then
|
|
177
|
+
// emit an event to search, but do NOT emit an event for example when filter options
|
|
178
|
+
// are selected, until the 'Apply filters' button is pressed which is handled separately
|
|
179
|
+
// by `handleApplyFilterButtonClick()`.
|
|
180
|
+
// Additional note -> we could, instead, do this:
|
|
181
|
+
// `<biggive-form-field-select placeholder="Sort by" id="sort-by" onDoSelectChange={this.someHandleMethod}>`
|
|
182
|
+
// but the problem with that is that `someHandleMethod` gets called first and then this
|
|
183
|
+
// method gets called, leading to two calls and more risk for error. DON-570.
|
|
184
|
+
if (event.detail.placeholder === this.sortByPlaceholderText) {
|
|
185
|
+
console.log('emitting event:');
|
|
186
|
+
console.log(this.getSearchAndFilterObject());
|
|
187
|
+
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
188
|
+
}
|
|
182
189
|
}
|
|
183
190
|
render() {
|
|
184
|
-
return (index.h("div", { class: 'container space-below-' + this.spaceBelow }, index.h("div", { class: "sleeve" }, index.h("div", { class: "search-wrap" }, index.h("h4", null, this.intro), index.h("div", { class: "field-wrap" }, index.h("div", { class: "input-wrap" }, index.h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, index.h("path", { d: index$1.faMagnifyingGlass.icon[4].toString() })), index.h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), index.h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), index.h("div", { class: "sort-filter-wrap" }, index.h("div", { class: "sort-wrap" }, index.h("biggive-form-field-select", { placeholder: "Sort by", id: "sort-by"
|
|
191
|
+
return (index.h("div", { class: 'container space-below-' + this.spaceBelow }, index.h("div", { class: "sleeve" }, index.h("div", { class: "search-wrap" }, index.h("h4", null, this.intro), index.h("div", { class: "field-wrap" }, index.h("div", { class: "input-wrap" }, index.h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, index.h("path", { d: index$1.faMagnifyingGlass.icon[4].toString() })), index.h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), index.h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), index.h("div", { class: "sort-filter-wrap" }, index.h("div", { class: "sort-wrap" }, index.h("biggive-form-field-select", { placeholder: "Sort by", selectedLabel: this.selectedLabel, id: "sort-by" }, index.h("biggive-form-field-select-option", { value: "amountRaised", label: "Most raised" }), index.h("biggive-form-field-select-option", { value: "matchFundsRemaining", label: "Match funds remaining" }), index.h("biggive-form-field-select-option", { value: "Relevance", label: "Relevance" }))), index.h("div", { class: "filter-wrap" }, index.h("biggive-button", { class: "filter", onClick: this.handleFilterButtonClick, label: "Filters" }), index.h("biggive-popup", { id: "filter-popup" }, index.h("h4", { class: "space-above-0 space-below-3 colour-primary" }, "Filters"), index.h("biggive-form-field-select", { placeholder: "Category", id: "categories", "space-below": "2" }, this.categoryOptions.length === 0
|
|
185
192
|
? undefined
|
|
186
193
|
: this.categoryOptions.map(option => index.h("biggive-form-field-select-option", { value: option, label: option }))), index.h("biggive-form-field-select", { placeholder: "Beneficiary", id: "beneficiaries", "space-below": "2" }, this.beneficiaryOptions.length === 0
|
|
187
194
|
? undefined
|
|
@@ -258,8 +265,7 @@ const BiggiveFormFieldSelect = class {
|
|
|
258
265
|
doOptionSelectCompletedHandler(event) {
|
|
259
266
|
this.selectedValue = event.detail.value;
|
|
260
267
|
this.selectedLabel = event.detail.label;
|
|
261
|
-
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel });
|
|
262
|
-
console.log({ value: this.selectedValue, label: this.selectedLabel });
|
|
268
|
+
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel, placeholder: this.placeholder });
|
|
263
269
|
if (this.el.shadowRoot !== null && this.el.shadowRoot !== undefined) {
|
|
264
270
|
const dropdown = this.el.shadowRoot.querySelector('.dropdown');
|
|
265
271
|
if (dropdown !== null && dropdown !== undefined) {
|
|
@@ -281,7 +287,7 @@ const BiggiveFormFieldSelect = class {
|
|
|
281
287
|
}
|
|
282
288
|
}
|
|
283
289
|
render() {
|
|
284
|
-
return (index.h("div", { class: 'dropdown space-below-' + this.spaceBelow }, index.h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, index.h("span", { class: "placeholder" }, this.selectedLabel
|
|
290
|
+
return (index.h("div", { class: 'dropdown space-below-' + this.spaceBelow }, index.h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, index.h("span", { class: "placeholder" }, this.selectedLabel === null ? this.placeholder : this.selectedLabel)), index.h("div", { class: "options" }, index.h("slot", null))));
|
|
285
291
|
}
|
|
286
292
|
get el() { return index.getElement(this); }
|
|
287
293
|
};
|
package/dist/cjs/biggive.cjs.js
CHANGED
|
@@ -15,5 +15,5 @@ const patchBrowser = () => {
|
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
patchBrowser().then(options => {
|
|
18
|
-
return index.bootstrapLazy([["biggive-back-to-top_26.cjs",[[1,"biggive-campaign-card-filter-grid",{"spaceBelow":[2,"space-below"],"intro":[1],"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"categoryOptions":[16],"beneficiaryOptions":[16],"locationOptions":[16],"fundingOptions":[16]},[[0,"doSelectChange","doOptionSelectCompletedHandler"]]],[1,"biggive-campaign-card",{"spaceBelow":[2,"space-below"],"campaignType":[1,"campaign-type"],"banner":[1],"campaignTitle":[1,"campaign-title"],"organisationName":[1,"organisation-name"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"donateButtonLabel":[1,"donate-button-label"],"donateButtonUrl":[1,"donate-button-url"],"donateButtonColourScheme":[1,"donate-button-colour-scheme"],"moreInfoButtonLabel":[1,"more-info-button-label"],"moreInfoButtonUrl":[1,"more-info-button-url"],"moreInfoButtonColourScheme":[1,"more-info-button-colour-scheme"]}],[1,"biggive-campaign-highlights",{"spaceBelow":[2,"space-below"],"banner":[1],"campaignTitle":[1,"campaign-title"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"primaryStatIcon":[1,"primary-stat-icon"],"primaryStatText":[1,"primary-stat-text"],"secondaryStatIcon":[1,"secondary-stat-icon"],"secondaryStatText":[1,"secondary-stat-text"]}],[1,"biggive-call-to-action",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"slugSize":[2,"slug-size"],"slugColour":[1,"slug-colour"],"slug":[1],"mainTitleColour":[1,"main-title-colour"],"mainTitleSize":[2,"main-title-size"],"mainTitle":[1,"main-title"],"subtitleSize":[2,"subtitle-size"],"subtitleColour":[1,"subtitle-colour"],"subtitle":[1],"teaserColour":[1,"teaser-colour"],"teaser":[1],"primaryButtonUrl":[1,"primary-button-url"],"primaryButtonLabel":[1,"primary-button-label"],"primaryButtonColourScheme":[1,"primary-button-colour-scheme"],"secondaryButtonUrl":[1,"secondary-button-url"],"secondaryButtonLabel":[1,"secondary-button-label"],"secondaryButtonColourScheme":[1,"secondary-button-colour-scheme"]}],[1,"biggive-footer"],[1,"biggive-hero-image",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"slug":[1],"slugColour":[1,"slug-colour"],"logo":[1],"mainImage":[1,"main-image"],"mainImageAlignHorizontal":[1,"main-image-align-horizontal"],"mainImageAlignVertical":[1,"main-image-align-vertical"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-image-feature",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"imageUrl":[1,"image-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-video-feature",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"videoUrl":[1,"video-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-back-to-top"],[1,"biggive-branded-image",{"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"logoUrl":[1,"logo-url"],"slug":[1],"charityName":[1,"charity-name"],"charityLocation":[1,"charity-location"]}],[1,"biggive-grid",{"spaceBelow":[2,"space-below"],"columnCount":[2,"column-count"],"columnGap":[2,"column-gap"]}],[1,"biggive-header",{"spaceBelow":[2,"space-below"],"logoUrl":[1,"logo-url"]}],[1,"biggive-heading",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"colour":[1],"htmlElement":[1,"html-element"],"size":[2],"align":[1],"text":[1]}],[1,"biggive-page-column"],[1,"biggive-page-columns",{"spaceBelow":[2,"space-below"]}],[1,"biggive-page-section",{"spaceBelow":[2,"space-below"],"sectionStyleTop":[1,"section-style-top"],"sectionStyleBottom":[1,"section-style-bottom"],"colourScheme":[1,"colour-scheme"]}],[1,"biggive-quote",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"quote":[1],"attribution":[1]}],[0,"biggive-social-icon",{"service":[1],"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"url":[1]}],[1,"biggive-totalizer",{"spaceBelow":[2,"space-below"],"primaryColour":[1,"primary-colour"],"primaryTextColour":[1,"primary-text-colour"],"secondaryColour":[1,"secondary-colour"],"secondaryTextColour":[1,"secondary-text-colour"],"mainMessage":[1,"main-message"]}],[1,"biggive-totalizer-ticker-item",{"figure":[1],"label":[1]}],[1,"biggive-form-field-select",{"selectedValue":[1,"selected-value"],"selectedLabel":[1,"selected-label"],"spaceBelow":[2,"space-below"],"placeholder":[1]},[[0,"doOptionSelect","doOptionSelectCompletedHandler"]]],[1,"biggive-form-field-select-option",{"label":[1],"value":[1],"selectedValue":[32],"selectedLabel":[32]}],[0,"biggive-misc-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"url":[1]}],[1,"biggive-popup",{"open":[64]}],[1,"biggive-progress-bar",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"counter":[2]}],[1,"biggive-button",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"label":[1],"url":[1],"fullWidth":[4,"full-width"],"size":[1],"rounded":[4]}]]],["biggive-article-card.cjs",[[1,"biggive-article-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundColourHover":[1,"background-colour-hover"],"textColour":[1,"text-colour"],"slug":[1],"date":[1],"mainTitle":[1,"main-title"],"imageUrl":[1,"image-url"],"imageLabel":[1,"image-label"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"]}]]],["biggive-basic-card.cjs",[[1,"biggive-basic-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundImageUrl":[1,"background-image-url"],"cardColour":[1,"card-colour"],"textColour":[1,"text-colour"],"mainTitle":[1,"main-title"],"subtitle":[1],"iconColour":[1,"icon-colour"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"],"buttonColourScheme":[1,"button-colour-scheme"]}]]],["biggive-search.cjs",[[1,"biggive-search",{"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"searchText":[32]}]]],["biggive-beneficiary-icon.cjs",[[0,"biggive-beneficiary-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-boxed-content.cjs",[[1,"biggive-boxed-content",{"spaceBelow":[2,"space-below"],"verticalPadding":[2,"vertical-padding"],"horizontalPadding":[2,"horizontal-padding"],"backgroundColour":[1,"background-colour"],"shadow":[4]}]]],["biggive-category-icon.cjs",[[0,"biggive-category-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-form.cjs",[[1,"biggive-form"]]],["biggive-formatted-text.cjs",[[1,"biggive-formatted-text",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-icon-group.cjs",[[1,"biggive-icon-group",{"spaceBelow":[2,"space-below"],"label":[1]}]]],["biggive-image.cjs",[[1,"biggive-image",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"width":[2],"height":[2],"sizeUnit":[1,"size-unit"]}]]],["biggive-nav-group.cjs",[[1,"biggive-nav-group",{"inline":[4]}]]],["biggive-nav-item.cjs",[[1,"biggive-nav-item",{"url":[1],"label":[1],"iconColour":[1,"icon-colour"]}]]],["biggive-popup-standalone.cjs",[[1,"biggive-popup-standalone"]]],["biggive-tab.cjs",[[1,"biggive-tab",{"tabTitle":[1,"tab-title"]}]]],["biggive-tabbed-content.cjs",[[1,"biggive-tabbed-content",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-text-input.cjs",[[1,"biggive-text-input"]]],["biggive-video.cjs",[[1,"biggive-video",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"videoUrl":[1,"video-url"]}]]]], options);
|
|
18
|
+
return index.bootstrapLazy([["biggive-back-to-top_26.cjs",[[1,"biggive-campaign-card-filter-grid",{"spaceBelow":[2,"space-below"],"intro":[1],"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"categoryOptions":[16],"beneficiaryOptions":[16],"locationOptions":[16],"fundingOptions":[16],"selectedLabel":[1,"selected-label"]},[[0,"doSelectChange","doOptionSelectCompletedHandler"]]],[1,"biggive-campaign-card",{"spaceBelow":[2,"space-below"],"campaignType":[1,"campaign-type"],"banner":[1],"campaignTitle":[1,"campaign-title"],"organisationName":[1,"organisation-name"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"donateButtonLabel":[1,"donate-button-label"],"donateButtonUrl":[1,"donate-button-url"],"donateButtonColourScheme":[1,"donate-button-colour-scheme"],"moreInfoButtonLabel":[1,"more-info-button-label"],"moreInfoButtonUrl":[1,"more-info-button-url"],"moreInfoButtonColourScheme":[1,"more-info-button-colour-scheme"]}],[1,"biggive-campaign-highlights",{"spaceBelow":[2,"space-below"],"banner":[1],"campaignTitle":[1,"campaign-title"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"primaryStatIcon":[1,"primary-stat-icon"],"primaryStatText":[1,"primary-stat-text"],"secondaryStatIcon":[1,"secondary-stat-icon"],"secondaryStatText":[1,"secondary-stat-text"]}],[1,"biggive-call-to-action",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"slugSize":[2,"slug-size"],"slugColour":[1,"slug-colour"],"slug":[1],"mainTitleColour":[1,"main-title-colour"],"mainTitleSize":[2,"main-title-size"],"mainTitle":[1,"main-title"],"subtitleSize":[2,"subtitle-size"],"subtitleColour":[1,"subtitle-colour"],"subtitle":[1],"teaserColour":[1,"teaser-colour"],"teaser":[1],"primaryButtonUrl":[1,"primary-button-url"],"primaryButtonLabel":[1,"primary-button-label"],"primaryButtonColourScheme":[1,"primary-button-colour-scheme"],"secondaryButtonUrl":[1,"secondary-button-url"],"secondaryButtonLabel":[1,"secondary-button-label"],"secondaryButtonColourScheme":[1,"secondary-button-colour-scheme"]}],[1,"biggive-footer"],[1,"biggive-hero-image",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"slug":[1],"slugColour":[1,"slug-colour"],"logo":[1],"mainImage":[1,"main-image"],"mainImageAlignHorizontal":[1,"main-image-align-horizontal"],"mainImageAlignVertical":[1,"main-image-align-vertical"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-image-feature",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"imageUrl":[1,"image-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-video-feature",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"videoUrl":[1,"video-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-back-to-top"],[1,"biggive-branded-image",{"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"logoUrl":[1,"logo-url"],"slug":[1],"charityName":[1,"charity-name"],"charityLocation":[1,"charity-location"]}],[1,"biggive-grid",{"spaceBelow":[2,"space-below"],"columnCount":[2,"column-count"],"columnGap":[2,"column-gap"]}],[1,"biggive-header",{"spaceBelow":[2,"space-below"],"logoUrl":[1,"logo-url"]}],[1,"biggive-heading",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"colour":[1],"htmlElement":[1,"html-element"],"size":[2],"align":[1],"text":[1]}],[1,"biggive-page-column"],[1,"biggive-page-columns",{"spaceBelow":[2,"space-below"]}],[1,"biggive-page-section",{"spaceBelow":[2,"space-below"],"sectionStyleTop":[1,"section-style-top"],"sectionStyleBottom":[1,"section-style-bottom"],"colourScheme":[1,"colour-scheme"]}],[1,"biggive-quote",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"quote":[1],"attribution":[1]}],[0,"biggive-social-icon",{"service":[1],"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"url":[1]}],[1,"biggive-totalizer",{"spaceBelow":[2,"space-below"],"primaryColour":[1,"primary-colour"],"primaryTextColour":[1,"primary-text-colour"],"secondaryColour":[1,"secondary-colour"],"secondaryTextColour":[1,"secondary-text-colour"],"mainMessage":[1,"main-message"]}],[1,"biggive-totalizer-ticker-item",{"figure":[1],"label":[1]}],[1,"biggive-form-field-select",{"selectedValue":[1,"selected-value"],"selectedLabel":[1,"selected-label"],"spaceBelow":[2,"space-below"],"placeholder":[1]},[[0,"doOptionSelect","doOptionSelectCompletedHandler"]]],[1,"biggive-form-field-select-option",{"label":[1],"value":[1],"selectedValue":[32],"selectedLabel":[32]}],[0,"biggive-misc-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"url":[1]}],[1,"biggive-popup",{"open":[64]}],[1,"biggive-progress-bar",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"counter":[2]}],[1,"biggive-button",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"label":[1],"url":[1],"fullWidth":[4,"full-width"],"size":[1],"rounded":[4]}]]],["biggive-article-card.cjs",[[1,"biggive-article-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundColourHover":[1,"background-colour-hover"],"textColour":[1,"text-colour"],"slug":[1],"date":[1],"mainTitle":[1,"main-title"],"imageUrl":[1,"image-url"],"imageLabel":[1,"image-label"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"]}]]],["biggive-basic-card.cjs",[[1,"biggive-basic-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundImageUrl":[1,"background-image-url"],"cardColour":[1,"card-colour"],"textColour":[1,"text-colour"],"mainTitle":[1,"main-title"],"subtitle":[1],"iconColour":[1,"icon-colour"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"],"buttonColourScheme":[1,"button-colour-scheme"]}]]],["biggive-search.cjs",[[1,"biggive-search",{"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"searchText":[32]}]]],["biggive-beneficiary-icon.cjs",[[0,"biggive-beneficiary-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-boxed-content.cjs",[[1,"biggive-boxed-content",{"spaceBelow":[2,"space-below"],"verticalPadding":[2,"vertical-padding"],"horizontalPadding":[2,"horizontal-padding"],"backgroundColour":[1,"background-colour"],"shadow":[4]}]]],["biggive-category-icon.cjs",[[0,"biggive-category-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-form.cjs",[[1,"biggive-form"]]],["biggive-formatted-text.cjs",[[1,"biggive-formatted-text",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-icon-group.cjs",[[1,"biggive-icon-group",{"spaceBelow":[2,"space-below"],"label":[1]}]]],["biggive-image.cjs",[[1,"biggive-image",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"width":[2],"height":[2],"sizeUnit":[1,"size-unit"]}]]],["biggive-nav-group.cjs",[[1,"biggive-nav-group",{"inline":[4]}]]],["biggive-nav-item.cjs",[[1,"biggive-nav-item",{"url":[1],"label":[1],"iconColour":[1,"icon-colour"]}]]],["biggive-popup-standalone.cjs",[[1,"biggive-popup-standalone"]]],["biggive-tab.cjs",[[1,"biggive-tab",{"tabTitle":[1,"tab-title"]}]]],["biggive-tabbed-content.cjs",[[1,"biggive-tabbed-content",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-text-input.cjs",[[1,"biggive-text-input"]]],["biggive-video.cjs",[[1,"biggive-video",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"videoUrl":[1,"video-url"]}]]]], options);
|
|
19
19
|
});
|
package/dist/cjs/loader.cjs.js
CHANGED
|
@@ -14,7 +14,7 @@ const patchEsm = () => {
|
|
|
14
14
|
const defineCustomElements = (win, options) => {
|
|
15
15
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
16
16
|
return patchEsm().then(() => {
|
|
17
|
-
return index.bootstrapLazy([["biggive-back-to-top_26.cjs",[[1,"biggive-campaign-card-filter-grid",{"spaceBelow":[2,"space-below"],"intro":[1],"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"categoryOptions":[16],"beneficiaryOptions":[16],"locationOptions":[16],"fundingOptions":[16]},[[0,"doSelectChange","doOptionSelectCompletedHandler"]]],[1,"biggive-campaign-card",{"spaceBelow":[2,"space-below"],"campaignType":[1,"campaign-type"],"banner":[1],"campaignTitle":[1,"campaign-title"],"organisationName":[1,"organisation-name"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"donateButtonLabel":[1,"donate-button-label"],"donateButtonUrl":[1,"donate-button-url"],"donateButtonColourScheme":[1,"donate-button-colour-scheme"],"moreInfoButtonLabel":[1,"more-info-button-label"],"moreInfoButtonUrl":[1,"more-info-button-url"],"moreInfoButtonColourScheme":[1,"more-info-button-colour-scheme"]}],[1,"biggive-campaign-highlights",{"spaceBelow":[2,"space-below"],"banner":[1],"campaignTitle":[1,"campaign-title"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"primaryStatIcon":[1,"primary-stat-icon"],"primaryStatText":[1,"primary-stat-text"],"secondaryStatIcon":[1,"secondary-stat-icon"],"secondaryStatText":[1,"secondary-stat-text"]}],[1,"biggive-call-to-action",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"slugSize":[2,"slug-size"],"slugColour":[1,"slug-colour"],"slug":[1],"mainTitleColour":[1,"main-title-colour"],"mainTitleSize":[2,"main-title-size"],"mainTitle":[1,"main-title"],"subtitleSize":[2,"subtitle-size"],"subtitleColour":[1,"subtitle-colour"],"subtitle":[1],"teaserColour":[1,"teaser-colour"],"teaser":[1],"primaryButtonUrl":[1,"primary-button-url"],"primaryButtonLabel":[1,"primary-button-label"],"primaryButtonColourScheme":[1,"primary-button-colour-scheme"],"secondaryButtonUrl":[1,"secondary-button-url"],"secondaryButtonLabel":[1,"secondary-button-label"],"secondaryButtonColourScheme":[1,"secondary-button-colour-scheme"]}],[1,"biggive-footer"],[1,"biggive-hero-image",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"slug":[1],"slugColour":[1,"slug-colour"],"logo":[1],"mainImage":[1,"main-image"],"mainImageAlignHorizontal":[1,"main-image-align-horizontal"],"mainImageAlignVertical":[1,"main-image-align-vertical"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-image-feature",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"imageUrl":[1,"image-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-video-feature",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"videoUrl":[1,"video-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-back-to-top"],[1,"biggive-branded-image",{"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"logoUrl":[1,"logo-url"],"slug":[1],"charityName":[1,"charity-name"],"charityLocation":[1,"charity-location"]}],[1,"biggive-grid",{"spaceBelow":[2,"space-below"],"columnCount":[2,"column-count"],"columnGap":[2,"column-gap"]}],[1,"biggive-header",{"spaceBelow":[2,"space-below"],"logoUrl":[1,"logo-url"]}],[1,"biggive-heading",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"colour":[1],"htmlElement":[1,"html-element"],"size":[2],"align":[1],"text":[1]}],[1,"biggive-page-column"],[1,"biggive-page-columns",{"spaceBelow":[2,"space-below"]}],[1,"biggive-page-section",{"spaceBelow":[2,"space-below"],"sectionStyleTop":[1,"section-style-top"],"sectionStyleBottom":[1,"section-style-bottom"],"colourScheme":[1,"colour-scheme"]}],[1,"biggive-quote",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"quote":[1],"attribution":[1]}],[0,"biggive-social-icon",{"service":[1],"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"url":[1]}],[1,"biggive-totalizer",{"spaceBelow":[2,"space-below"],"primaryColour":[1,"primary-colour"],"primaryTextColour":[1,"primary-text-colour"],"secondaryColour":[1,"secondary-colour"],"secondaryTextColour":[1,"secondary-text-colour"],"mainMessage":[1,"main-message"]}],[1,"biggive-totalizer-ticker-item",{"figure":[1],"label":[1]}],[1,"biggive-form-field-select",{"selectedValue":[1,"selected-value"],"selectedLabel":[1,"selected-label"],"spaceBelow":[2,"space-below"],"placeholder":[1]},[[0,"doOptionSelect","doOptionSelectCompletedHandler"]]],[1,"biggive-form-field-select-option",{"label":[1],"value":[1],"selectedValue":[32],"selectedLabel":[32]}],[0,"biggive-misc-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"url":[1]}],[1,"biggive-popup",{"open":[64]}],[1,"biggive-progress-bar",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"counter":[2]}],[1,"biggive-button",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"label":[1],"url":[1],"fullWidth":[4,"full-width"],"size":[1],"rounded":[4]}]]],["biggive-article-card.cjs",[[1,"biggive-article-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundColourHover":[1,"background-colour-hover"],"textColour":[1,"text-colour"],"slug":[1],"date":[1],"mainTitle":[1,"main-title"],"imageUrl":[1,"image-url"],"imageLabel":[1,"image-label"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"]}]]],["biggive-basic-card.cjs",[[1,"biggive-basic-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundImageUrl":[1,"background-image-url"],"cardColour":[1,"card-colour"],"textColour":[1,"text-colour"],"mainTitle":[1,"main-title"],"subtitle":[1],"iconColour":[1,"icon-colour"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"],"buttonColourScheme":[1,"button-colour-scheme"]}]]],["biggive-search.cjs",[[1,"biggive-search",{"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"searchText":[32]}]]],["biggive-beneficiary-icon.cjs",[[0,"biggive-beneficiary-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-boxed-content.cjs",[[1,"biggive-boxed-content",{"spaceBelow":[2,"space-below"],"verticalPadding":[2,"vertical-padding"],"horizontalPadding":[2,"horizontal-padding"],"backgroundColour":[1,"background-colour"],"shadow":[4]}]]],["biggive-category-icon.cjs",[[0,"biggive-category-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-form.cjs",[[1,"biggive-form"]]],["biggive-formatted-text.cjs",[[1,"biggive-formatted-text",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-icon-group.cjs",[[1,"biggive-icon-group",{"spaceBelow":[2,"space-below"],"label":[1]}]]],["biggive-image.cjs",[[1,"biggive-image",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"width":[2],"height":[2],"sizeUnit":[1,"size-unit"]}]]],["biggive-nav-group.cjs",[[1,"biggive-nav-group",{"inline":[4]}]]],["biggive-nav-item.cjs",[[1,"biggive-nav-item",{"url":[1],"label":[1],"iconColour":[1,"icon-colour"]}]]],["biggive-popup-standalone.cjs",[[1,"biggive-popup-standalone"]]],["biggive-tab.cjs",[[1,"biggive-tab",{"tabTitle":[1,"tab-title"]}]]],["biggive-tabbed-content.cjs",[[1,"biggive-tabbed-content",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-text-input.cjs",[[1,"biggive-text-input"]]],["biggive-video.cjs",[[1,"biggive-video",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"videoUrl":[1,"video-url"]}]]]], options);
|
|
17
|
+
return index.bootstrapLazy([["biggive-back-to-top_26.cjs",[[1,"biggive-campaign-card-filter-grid",{"spaceBelow":[2,"space-below"],"intro":[1],"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"categoryOptions":[16],"beneficiaryOptions":[16],"locationOptions":[16],"fundingOptions":[16],"selectedLabel":[1,"selected-label"]},[[0,"doSelectChange","doOptionSelectCompletedHandler"]]],[1,"biggive-campaign-card",{"spaceBelow":[2,"space-below"],"campaignType":[1,"campaign-type"],"banner":[1],"campaignTitle":[1,"campaign-title"],"organisationName":[1,"organisation-name"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"donateButtonLabel":[1,"donate-button-label"],"donateButtonUrl":[1,"donate-button-url"],"donateButtonColourScheme":[1,"donate-button-colour-scheme"],"moreInfoButtonLabel":[1,"more-info-button-label"],"moreInfoButtonUrl":[1,"more-info-button-url"],"moreInfoButtonColourScheme":[1,"more-info-button-colour-scheme"]}],[1,"biggive-campaign-highlights",{"spaceBelow":[2,"space-below"],"banner":[1],"campaignTitle":[1,"campaign-title"],"primaryFigureLabel":[1,"primary-figure-label"],"primaryFigureAmount":[1,"primary-figure-amount"],"secondaryFigureLabel":[1,"secondary-figure-label"],"secondaryFigureAmount":[1,"secondary-figure-amount"],"progressBarCounter":[2,"progress-bar-counter"],"primaryStatIcon":[1,"primary-stat-icon"],"primaryStatText":[1,"primary-stat-text"],"secondaryStatIcon":[1,"secondary-stat-icon"],"secondaryStatText":[1,"secondary-stat-text"]}],[1,"biggive-call-to-action",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"slugSize":[2,"slug-size"],"slugColour":[1,"slug-colour"],"slug":[1],"mainTitleColour":[1,"main-title-colour"],"mainTitleSize":[2,"main-title-size"],"mainTitle":[1,"main-title"],"subtitleSize":[2,"subtitle-size"],"subtitleColour":[1,"subtitle-colour"],"subtitle":[1],"teaserColour":[1,"teaser-colour"],"teaser":[1],"primaryButtonUrl":[1,"primary-button-url"],"primaryButtonLabel":[1,"primary-button-label"],"primaryButtonColourScheme":[1,"primary-button-colour-scheme"],"secondaryButtonUrl":[1,"secondary-button-url"],"secondaryButtonLabel":[1,"secondary-button-label"],"secondaryButtonColourScheme":[1,"secondary-button-colour-scheme"]}],[1,"biggive-footer"],[1,"biggive-hero-image",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"slug":[1],"slugColour":[1,"slug-colour"],"logo":[1],"mainImage":[1,"main-image"],"mainImageAlignHorizontal":[1,"main-image-align-horizontal"],"mainImageAlignVertical":[1,"main-image-align-vertical"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-image-feature",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"imageUrl":[1,"image-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-video-feature",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"videoUrl":[1,"video-url"],"slug":[1],"slugColour":[1,"slug-colour"],"mainTitle":[1,"main-title"],"mainTitleColour":[1,"main-title-colour"],"teaser":[1],"teaserColour":[1,"teaser-colour"],"buttonUrl":[1,"button-url"],"buttonLabel":[1,"button-label"],"buttonColourScheme":[1,"button-colour-scheme"]}],[1,"biggive-back-to-top"],[1,"biggive-branded-image",{"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"logoUrl":[1,"logo-url"],"slug":[1],"charityName":[1,"charity-name"],"charityLocation":[1,"charity-location"]}],[1,"biggive-grid",{"spaceBelow":[2,"space-below"],"columnCount":[2,"column-count"],"columnGap":[2,"column-gap"]}],[1,"biggive-header",{"spaceBelow":[2,"space-below"],"logoUrl":[1,"logo-url"]}],[1,"biggive-heading",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"colour":[1],"htmlElement":[1,"html-element"],"size":[2],"align":[1],"text":[1]}],[1,"biggive-page-column"],[1,"biggive-page-columns",{"spaceBelow":[2,"space-below"]}],[1,"biggive-page-section",{"spaceBelow":[2,"space-below"],"sectionStyleTop":[1,"section-style-top"],"sectionStyleBottom":[1,"section-style-bottom"],"colourScheme":[1,"colour-scheme"]}],[1,"biggive-quote",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"],"quote":[1],"attribution":[1]}],[0,"biggive-social-icon",{"service":[1],"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"url":[1]}],[1,"biggive-totalizer",{"spaceBelow":[2,"space-below"],"primaryColour":[1,"primary-colour"],"primaryTextColour":[1,"primary-text-colour"],"secondaryColour":[1,"secondary-colour"],"secondaryTextColour":[1,"secondary-text-colour"],"mainMessage":[1,"main-message"]}],[1,"biggive-totalizer-ticker-item",{"figure":[1],"label":[1]}],[1,"biggive-form-field-select",{"selectedValue":[1,"selected-value"],"selectedLabel":[1,"selected-label"],"spaceBelow":[2,"space-below"],"placeholder":[1]},[[0,"doOptionSelect","doOptionSelectCompletedHandler"]]],[1,"biggive-form-field-select-option",{"label":[1],"value":[1],"selectedValue":[32],"selectedLabel":[32]}],[0,"biggive-misc-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"url":[1]}],[1,"biggive-popup",{"open":[64]}],[1,"biggive-progress-bar",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"counter":[2]}],[1,"biggive-button",{"spaceBelow":[2,"space-below"],"colourScheme":[1,"colour-scheme"],"label":[1],"url":[1],"fullWidth":[4,"full-width"],"size":[1],"rounded":[4]}]]],["biggive-article-card.cjs",[[1,"biggive-article-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundColourHover":[1,"background-colour-hover"],"textColour":[1,"text-colour"],"slug":[1],"date":[1],"mainTitle":[1,"main-title"],"imageUrl":[1,"image-url"],"imageLabel":[1,"image-label"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"]}]]],["biggive-basic-card.cjs",[[1,"biggive-basic-card",{"spaceBelow":[2,"space-below"],"backgroundColour":[1,"background-colour"],"backgroundImageUrl":[1,"background-image-url"],"cardColour":[1,"card-colour"],"textColour":[1,"text-colour"],"mainTitle":[1,"main-title"],"subtitle":[1],"iconColour":[1,"icon-colour"],"buttonLabel":[1,"button-label"],"buttonUrl":[1,"button-url"],"buttonColourScheme":[1,"button-colour-scheme"]}]]],["biggive-search.cjs",[[1,"biggive-search",{"placeholderText":[1,"placeholder-text"],"buttonText":[1,"button-text"],"searchText":[32]}]]],["biggive-beneficiary-icon.cjs",[[0,"biggive-beneficiary-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-boxed-content.cjs",[[1,"biggive-boxed-content",{"spaceBelow":[2,"space-below"],"verticalPadding":[2,"vertical-padding"],"horizontalPadding":[2,"horizontal-padding"],"backgroundColour":[1,"background-colour"],"shadow":[4]}]]],["biggive-category-icon.cjs",[[0,"biggive-category-icon",{"backgroundColour":[1,"background-colour"],"iconColour":[1,"icon-colour"],"icon":[1],"label":[1],"url":[1]}]]],["biggive-form.cjs",[[1,"biggive-form"]]],["biggive-formatted-text.cjs",[[1,"biggive-formatted-text",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-icon-group.cjs",[[1,"biggive-icon-group",{"spaceBelow":[2,"space-below"],"label":[1]}]]],["biggive-image.cjs",[[1,"biggive-image",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"imageUrl":[1,"image-url"],"width":[2],"height":[2],"sizeUnit":[1,"size-unit"]}]]],["biggive-nav-group.cjs",[[1,"biggive-nav-group",{"inline":[4]}]]],["biggive-nav-item.cjs",[[1,"biggive-nav-item",{"url":[1],"label":[1],"iconColour":[1,"icon-colour"]}]]],["biggive-popup-standalone.cjs",[[1,"biggive-popup-standalone"]]],["biggive-tab.cjs",[[1,"biggive-tab",{"tabTitle":[1,"tab-title"]}]]],["biggive-tabbed-content.cjs",[[1,"biggive-tabbed-content",{"spaceBelow":[2,"space-below"],"defaultTextColour":[1,"default-text-colour"]}]]],["biggive-text-input.cjs",[[1,"biggive-text-input"]]],["biggive-video.cjs",[[1,"biggive-video",{"spaceAbove":[2,"space-above"],"spaceBelow":[2,"space-below"],"videoUrl":[1,"video-url"]}]]]], options);
|
|
18
18
|
});
|
|
19
19
|
};
|
|
20
20
|
|
|
@@ -9,11 +9,8 @@ export class BiggiveButton {
|
|
|
9
9
|
this.size = 'medium';
|
|
10
10
|
this.rounded = false;
|
|
11
11
|
}
|
|
12
|
-
handleButtonClick() {
|
|
13
|
-
this.doButtonClick.emit(this.url);
|
|
14
|
-
}
|
|
15
12
|
render() {
|
|
16
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() },
|
|
13
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() }, this.label)));
|
|
17
14
|
}
|
|
18
15
|
static get is() { return "biggive-button"; }
|
|
19
16
|
static get encapsulation() { return "shadow"; }
|
|
@@ -157,22 +154,4 @@ export class BiggiveButton {
|
|
|
157
154
|
}
|
|
158
155
|
};
|
|
159
156
|
}
|
|
160
|
-
static get events() {
|
|
161
|
-
return [{
|
|
162
|
-
"method": "doButtonClick",
|
|
163
|
-
"name": "doButtonClick",
|
|
164
|
-
"bubbles": true,
|
|
165
|
-
"cancelable": true,
|
|
166
|
-
"composed": true,
|
|
167
|
-
"docs": {
|
|
168
|
-
"tags": [],
|
|
169
|
-
"text": ""
|
|
170
|
-
},
|
|
171
|
-
"complexType": {
|
|
172
|
-
"original": "string",
|
|
173
|
-
"resolved": "string",
|
|
174
|
-
"references": {}
|
|
175
|
-
}
|
|
176
|
-
}];
|
|
177
|
-
}
|
|
178
157
|
}
|
|
@@ -8,10 +8,7 @@ export class BiggiveCampaignCardFilterGrid {
|
|
|
8
8
|
this.filterBeneficiary = null;
|
|
9
9
|
this.filterLocation = null;
|
|
10
10
|
this.filterFunding = null;
|
|
11
|
-
this.
|
|
12
|
-
this.sortBy = event.target.value;
|
|
13
|
-
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
14
|
-
};
|
|
11
|
+
this.sortByPlaceholderText = 'Sort by';
|
|
15
12
|
this.handleApplyFilterButtonClick = () => {
|
|
16
13
|
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
17
14
|
};
|
|
@@ -37,6 +34,7 @@ export class BiggiveCampaignCardFilterGrid {
|
|
|
37
34
|
this.beneficiaryOptions = [];
|
|
38
35
|
this.locationOptions = [];
|
|
39
36
|
this.fundingOptions = [];
|
|
37
|
+
this.selectedLabel = null;
|
|
40
38
|
}
|
|
41
39
|
getSearchAndFilterObject() {
|
|
42
40
|
const event = {
|
|
@@ -49,15 +47,28 @@ export class BiggiveCampaignCardFilterGrid {
|
|
|
49
47
|
};
|
|
50
48
|
return event;
|
|
51
49
|
}
|
|
52
|
-
doOptionSelectCompletedHandler() {
|
|
50
|
+
doOptionSelectCompletedHandler(event) {
|
|
53
51
|
this.sortBy = this.el.shadowRoot.getElementById('sort-by').selectedValue;
|
|
54
52
|
this.filterCategory = this.el.shadowRoot.getElementById('categories').selectedValue;
|
|
55
53
|
this.filterBeneficiary = this.el.shadowRoot.getElementById('beneficiaries').selectedValue;
|
|
56
54
|
this.filterLocation = this.el.shadowRoot.getElementById('locations').selectedValue;
|
|
57
55
|
this.filterFunding = this.el.shadowRoot.getElementById('funding').selectedValue;
|
|
56
|
+
// If this method was trigerred by the selection of a 'Sort by' dropdown option, then
|
|
57
|
+
// emit an event to search, but do NOT emit an event for example when filter options
|
|
58
|
+
// are selected, until the 'Apply filters' button is pressed which is handled separately
|
|
59
|
+
// by `handleApplyFilterButtonClick()`.
|
|
60
|
+
// Additional note -> we could, instead, do this:
|
|
61
|
+
// `<biggive-form-field-select placeholder="Sort by" id="sort-by" onDoSelectChange={this.someHandleMethod}>`
|
|
62
|
+
// but the problem with that is that `someHandleMethod` gets called first and then this
|
|
63
|
+
// method gets called, leading to two calls and more risk for error. DON-570.
|
|
64
|
+
if (event.detail.placeholder === this.sortByPlaceholderText) {
|
|
65
|
+
console.log('emitting event:');
|
|
66
|
+
console.log(this.getSearchAndFilterObject());
|
|
67
|
+
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
68
|
+
}
|
|
58
69
|
}
|
|
59
70
|
render() {
|
|
60
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", id: "sort-by"
|
|
71
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", selectedLabel: this.selectedLabel, id: "sort-by" }, h("biggive-form-field-select-option", { value: "amountRaised", label: "Most raised" }), h("biggive-form-field-select-option", { value: "matchFundsRemaining", label: "Match funds remaining" }), h("biggive-form-field-select-option", { value: "Relevance", label: "Relevance" }))), h("div", { class: "filter-wrap" }, h("biggive-button", { class: "filter", onClick: this.handleFilterButtonClick, label: "Filters" }), h("biggive-popup", { id: "filter-popup" }, h("h4", { class: "space-above-0 space-below-3 colour-primary" }, "Filters"), h("biggive-form-field-select", { placeholder: "Category", id: "categories", "space-below": "2" }, this.categoryOptions.length === 0
|
|
61
72
|
? undefined
|
|
62
73
|
: this.categoryOptions.map(option => h("biggive-form-field-select-option", { value: option, label: option }))), h("biggive-form-field-select", { placeholder: "Beneficiary", id: "beneficiaries", "space-below": "2" }, this.beneficiaryOptions.length === 0
|
|
63
74
|
? undefined
|
|
@@ -216,6 +227,24 @@ export class BiggiveCampaignCardFilterGrid {
|
|
|
216
227
|
"text": "JSON array of funding key/values"
|
|
217
228
|
},
|
|
218
229
|
"defaultValue": "[]"
|
|
230
|
+
},
|
|
231
|
+
"selectedLabel": {
|
|
232
|
+
"type": "string",
|
|
233
|
+
"mutable": false,
|
|
234
|
+
"complexType": {
|
|
235
|
+
"original": "'Most raised' | 'Match funds remaining' | 'Relevance'",
|
|
236
|
+
"resolved": "\"Match funds remaining\" | \"Most raised\" | \"Relevance\"",
|
|
237
|
+
"references": {}
|
|
238
|
+
},
|
|
239
|
+
"required": false,
|
|
240
|
+
"optional": false,
|
|
241
|
+
"docs": {
|
|
242
|
+
"tags": [],
|
|
243
|
+
"text": "This helps us inject a pre-selected dropdown value from outside of this component.\nThis is especially helpful for the Meta campaign and Explore pages, where searching\nby text whipes out previous sort options and re-uses Relevance, or where one of those\ntwo pages is loaded directly with URL parameters - in such a scenario the dropdown\nshows that it's pre-selected. DON-558."
|
|
244
|
+
},
|
|
245
|
+
"attribute": "selected-label",
|
|
246
|
+
"reflect": false,
|
|
247
|
+
"defaultValue": "null"
|
|
219
248
|
}
|
|
220
249
|
};
|
|
221
250
|
}
|
|
@@ -9,8 +9,7 @@ export class BiggiveFormFieldSelect {
|
|
|
9
9
|
doOptionSelectCompletedHandler(event) {
|
|
10
10
|
this.selectedValue = event.detail.value;
|
|
11
11
|
this.selectedLabel = event.detail.label;
|
|
12
|
-
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel });
|
|
13
|
-
console.log({ value: this.selectedValue, label: this.selectedLabel });
|
|
12
|
+
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel, placeholder: this.placeholder });
|
|
14
13
|
if (this.el.shadowRoot !== null && this.el.shadowRoot !== undefined) {
|
|
15
14
|
const dropdown = this.el.shadowRoot.querySelector('.dropdown');
|
|
16
15
|
if (dropdown !== null && dropdown !== undefined) {
|
|
@@ -32,7 +31,7 @@ export class BiggiveFormFieldSelect {
|
|
|
32
31
|
}
|
|
33
32
|
}
|
|
34
33
|
render() {
|
|
35
|
-
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel
|
|
34
|
+
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel === null ? this.placeholder : this.selectedLabel)), h("div", { class: "options" }, h("slot", null))));
|
|
36
35
|
}
|
|
37
36
|
static get is() { return "biggive-form-field-select"; }
|
|
38
37
|
static get encapsulation() { return "shadow"; }
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { proxyCustomElement, HTMLElement,
|
|
1
|
+
import { proxyCustomElement, HTMLElement, h } from '@stencil/core/internal/client';
|
|
2
2
|
|
|
3
3
|
const biggiveButtonCss = "body{background-color:#D7D7D7}h1,h3,h4,h5,h6{margin-bottom:0}h1,.heading-1{font-size:47px;line-height:60px;font-weight:bold}h2,.heading-2{font-size:38px;line-height:45px;font-weight:bold}h3,.heading-3{font-size:25px;line-height:32px;font-weight:bold}h4,.heading-4{font-size:20px;line-height:24px;font-weight:bold}h5,.heading-5{font-size:17px;line-height:24px;font-weight:bold}a{color:inherit;text-decoration:underline}a:hover{text-decoration:none}.colour-primary{color:#2C089B}.colour-secondary{color:#2AF135}.colour-tertiary{color:#FF7272}.colour-white{color:#FFFFFF}.colour-black{color:#000000}.text-colour-hover-primary:hover,.text-colour-primary{color:#2C089B}.text-colour-hover-secondary:hover,.text-colour-secondary{color:#2AF135}.text-colour-hover-tertiary:hover,.text-colour-tertiary{color:#FF7272}.text-colour-hover-white:hover,.text-colour-white{color:#FFFFFF}.text-colour-hover-black:hover,.text-colour-black{color:#000000}.fill-primary{fill:#2C089B}.fill-secondary{fill:#2AF135}.fill-tertiary{fill:#FF7272}.fill-white{fill:#FFFFFF}.fill-black{fill:#000000}.fill-red{fill:red}.background-colour-hover-primary:hover,.background-colour-primary{background-color:#2C089B}.background-colour-hover-secondary:hover,.background-colour-secondary{background-color:#2AF135}.background-colour-hover-tertiary:hover,.background-colour-tertiary{background-color:#FF7272}.background-colour-hover-white:hover,.background-colour-white{background-color:#FFFFFF}.background-colour-hover-black:hover,.background-colour-black{background-color:#000000}.input-wrap{display:flex;justify-content:space-between}.input-text{font-family:\"Euclid Triangle\", sans-serif;font-size:17px;line-height:24px;color:#000000;padding:5px 10px;box-sizing:border-box;width:100%}.input-text:focus{outline:0}.input-text:placeholder{color:#4A4A4A}.button{font-size:17px;line-height:24px;padding:10px 30px;border-radius:5px;border:1px solid #000000;background-color:#000000;filter:drop-shadow(0px 8px 20px rgba(0, 0, 0, 0.22));color:#FFFFFF;display:inline-block;text-decoration:none;text-align:center;transition:all ease-in-out 0.5s;cursor:pointer}.button:hover{background-color:#FFFFFF;color:#000000}.button.size-small{font-size:13px;line-height:17px;padding:5px 15px}.button.button.rounded-true{border-radius:27.5px}.button.button.rounded-true.size-small{border-radius:20px}.button-primary{color:#FFFFFF;background-color:#2C089B;border-color:#2C089B}.button-primary:hover{color:#2C089B;background-color:#FFFFFF}.button-secondary{color:#2C089B;background-color:#2AF135;border-color:#2AF135}.button-secondary:hover{background-color:#FFFFFF}.button-tertiary{color:#FFFFFF;background-color:#FF7272;border-color:#FF7272}.button-tertiary:hover{background-color:#FFFFFF}.button-white{color:#2C089B;background-color:#FFFFFF;border-color:#FFFFFF}.button-white:hover{color:#FFFFFF;background-color:#2C089B}.button-black{color:#FFFFFF;background-color:#000000;border-color:#000000}.button-black:hover{color:#000000;background-color:#FFFFFF}.button-clear-primary{color:#2C089B;background-color:transparent;text-decoration:underline;box-shadow:none;border:0;padding-left:0;padding-right:0}.button-clear-primary:hover{text-decoration:none;background-color:transparent}.button-clear-secondary{color:#2AF135;background-color:transparent;text-decoration:underline;box-shadow:none;border:0;padding-left:0;padding-right:0}.button-clear-secondary:hover{text-decoration:none;background-color:transparent}.button-clear-tertiary{color:#FF7272;background-color:transparent;text-decoration:underline;box-shadow:none;border:0;padding-left:0;padding-right:0}.button-clear-tertiary:hover{text-decoration:none;background-color:transparent}.button-clear-white{color:#FFFFFF;background-color:transparent;text-decoration:underline;box-shadow:none;border:0;padding-left:0;padding-right:0}.button-clear-white:hover{color:#FFFFFF;text-decoration:none;background-color:transparent}.button-rounded{border-radius:27.5px}.button-rounded.size-small{border-radius:20px}.progress-bar{display:flex}.progress-bar .slider{margin:auto 15px auto 0;position:relative;flex-grow:1}.progress-bar .slider:before{content:\"\";position:absolute;display:block;top:0;left:0;bottom:0;right:0;background-color:#E8E8E8;border-radius:4px}.progress-bar .slider .progress{position:relative;border-radius:4px;background-color:#000000;height:8px}.progress-bar .counter{font-weight:700;color:#000000;font-size:14px;line-height:18px}.progress-bar-primary .slider .progress{background-color:#2C089B}.progress-bar-primary .counter{color:#2C089B}.progress-bar-secondary .slider .progress{background-color:#2AF135}.progress-bar-secondary .counter{color:#2AF135}.video-wrap{position:relative;padding-bottom:56.25%}.video-wrap iframe,.video-wrap video{position:absolute;border:0;display:block;left:0;right:0;top:0;bottom:0;width:100%;height:100%}.image-wrap img{width:100%;height:auto}.align-left{text-align:left}.align-right{text-align:right}.align-center{text-align:center}.align-justify{text-align:justify}.space-below-0{margin-bottom:0}.space-below-1{margin-bottom:5px}.space-below-2{margin-bottom:10px}.space-below-3{margin-bottom:15px}.space-below-4{margin-bottom:30px}.space-below-5{margin-bottom:45px}.space-below-6{margin-bottom:60px}.space-above-0{margin-top:0}.space-above-1{margin-top:5px}.space-above-2{margin-top:10px}.space-above-3{margin-top:15px}.space-above-4{margin-top:30px}.space-above-5{margin-top:45px}.space-above-6{margin-top:60px}.horizontal-padding-1{padding-left:5px;padding-right:5px}.horizontal-padding-2{padding-left:10px;padding-right:10px}.horizontal-padding-3{padding-left:15px;padding-right:15px}.horizontal-padding-4{padding-left:30px;padding-right:30px}.horizontal-padding-5{padding-left:45px;padding-right:45px}.horizontal-padding-6{padding-left:60px;padding-right:60px}.vertical-padding-1{padding-top:5px;padding-bottom:5px}.vertical-padding-2{padding-top:10px;padding-bottom:10px}.vertical-padding-3{padding-top:15px;padding-bottom:15px}.vertical-padding-4{padding-top:30px;padding-bottom:30px}.vertical-padding-5{padding-top:45px;padding-bottom:45px}.vertical-padding-6{padding-top:60px;padding-bottom:60px}:host{display:contents}.container{font-family:\"Euclid Triangle\", sans-serif;font-size:17px;line-height:24px}.container a{display:inline-block}.container a.full-width-true{display:block}";
|
|
4
4
|
|
|
@@ -7,7 +7,6 @@ const BiggiveButton = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
7
7
|
super();
|
|
8
8
|
this.__registerHost();
|
|
9
9
|
this.__attachShadow();
|
|
10
|
-
this.doButtonClick = createEvent(this, "doButtonClick", 7);
|
|
11
10
|
this.spaceBelow = 1;
|
|
12
11
|
this.colourScheme = 'primary';
|
|
13
12
|
this.label = 'Click me';
|
|
@@ -16,11 +15,8 @@ const BiggiveButton = /*@__PURE__*/ proxyCustomElement(class extends HTMLElement
|
|
|
16
15
|
this.size = 'medium';
|
|
17
16
|
this.rounded = false;
|
|
18
17
|
}
|
|
19
|
-
handleButtonClick() {
|
|
20
|
-
this.doButtonClick.emit(this.url);
|
|
21
|
-
}
|
|
22
18
|
render() {
|
|
23
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() },
|
|
19
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() }, this.label)));
|
|
24
20
|
}
|
|
25
21
|
static get style() { return biggiveButtonCss; }
|
|
26
22
|
}, [1, "biggive-button", {
|
|
@@ -19,10 +19,7 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class e
|
|
|
19
19
|
this.filterBeneficiary = null;
|
|
20
20
|
this.filterLocation = null;
|
|
21
21
|
this.filterFunding = null;
|
|
22
|
-
this.
|
|
23
|
-
this.sortBy = event.target.value;
|
|
24
|
-
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
25
|
-
};
|
|
22
|
+
this.sortByPlaceholderText = 'Sort by';
|
|
26
23
|
this.handleApplyFilterButtonClick = () => {
|
|
27
24
|
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
28
25
|
};
|
|
@@ -48,6 +45,7 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class e
|
|
|
48
45
|
this.beneficiaryOptions = [];
|
|
49
46
|
this.locationOptions = [];
|
|
50
47
|
this.fundingOptions = [];
|
|
48
|
+
this.selectedLabel = null;
|
|
51
49
|
}
|
|
52
50
|
getSearchAndFilterObject() {
|
|
53
51
|
const event = {
|
|
@@ -60,15 +58,28 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class e
|
|
|
60
58
|
};
|
|
61
59
|
return event;
|
|
62
60
|
}
|
|
63
|
-
doOptionSelectCompletedHandler() {
|
|
61
|
+
doOptionSelectCompletedHandler(event) {
|
|
64
62
|
this.sortBy = this.el.shadowRoot.getElementById('sort-by').selectedValue;
|
|
65
63
|
this.filterCategory = this.el.shadowRoot.getElementById('categories').selectedValue;
|
|
66
64
|
this.filterBeneficiary = this.el.shadowRoot.getElementById('beneficiaries').selectedValue;
|
|
67
65
|
this.filterLocation = this.el.shadowRoot.getElementById('locations').selectedValue;
|
|
68
66
|
this.filterFunding = this.el.shadowRoot.getElementById('funding').selectedValue;
|
|
67
|
+
// If this method was trigerred by the selection of a 'Sort by' dropdown option, then
|
|
68
|
+
// emit an event to search, but do NOT emit an event for example when filter options
|
|
69
|
+
// are selected, until the 'Apply filters' button is pressed which is handled separately
|
|
70
|
+
// by `handleApplyFilterButtonClick()`.
|
|
71
|
+
// Additional note -> we could, instead, do this:
|
|
72
|
+
// `<biggive-form-field-select placeholder="Sort by" id="sort-by" onDoSelectChange={this.someHandleMethod}>`
|
|
73
|
+
// but the problem with that is that `someHandleMethod` gets called first and then this
|
|
74
|
+
// method gets called, leading to two calls and more risk for error. DON-570.
|
|
75
|
+
if (event.detail.placeholder === this.sortByPlaceholderText) {
|
|
76
|
+
console.log('emitting event:');
|
|
77
|
+
console.log(this.getSearchAndFilterObject());
|
|
78
|
+
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
79
|
+
}
|
|
69
80
|
}
|
|
70
81
|
render() {
|
|
71
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", id: "sort-by"
|
|
82
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", selectedLabel: this.selectedLabel, id: "sort-by" }, h("biggive-form-field-select-option", { value: "amountRaised", label: "Most raised" }), h("biggive-form-field-select-option", { value: "matchFundsRemaining", label: "Match funds remaining" }), h("biggive-form-field-select-option", { value: "Relevance", label: "Relevance" }))), h("div", { class: "filter-wrap" }, h("biggive-button", { class: "filter", onClick: this.handleFilterButtonClick, label: "Filters" }), h("biggive-popup", { id: "filter-popup" }, h("h4", { class: "space-above-0 space-below-3 colour-primary" }, "Filters"), h("biggive-form-field-select", { placeholder: "Category", id: "categories", "space-below": "2" }, this.categoryOptions.length === 0
|
|
72
83
|
? undefined
|
|
73
84
|
: this.categoryOptions.map(option => h("biggive-form-field-select-option", { value: option, label: option }))), h("biggive-form-field-select", { placeholder: "Beneficiary", id: "beneficiaries", "space-below": "2" }, this.beneficiaryOptions.length === 0
|
|
74
85
|
? undefined
|
|
@@ -88,7 +99,8 @@ const BiggiveCampaignCardFilterGrid$1 = /*@__PURE__*/ proxyCustomElement(class e
|
|
|
88
99
|
"categoryOptions": [16],
|
|
89
100
|
"beneficiaryOptions": [16],
|
|
90
101
|
"locationOptions": [16],
|
|
91
|
-
"fundingOptions": [16]
|
|
102
|
+
"fundingOptions": [16],
|
|
103
|
+
"selectedLabel": [1, "selected-label"]
|
|
92
104
|
}, [[0, "doSelectChange", "doOptionSelectCompletedHandler"]]]);
|
|
93
105
|
function defineCustomElement$1() {
|
|
94
106
|
if (typeof customElements === "undefined") {
|
|
@@ -16,8 +16,7 @@ const BiggiveFormFieldSelect = /*@__PURE__*/ proxyCustomElement(class extends HT
|
|
|
16
16
|
doOptionSelectCompletedHandler(event) {
|
|
17
17
|
this.selectedValue = event.detail.value;
|
|
18
18
|
this.selectedLabel = event.detail.label;
|
|
19
|
-
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel });
|
|
20
|
-
console.log({ value: this.selectedValue, label: this.selectedLabel });
|
|
19
|
+
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel, placeholder: this.placeholder });
|
|
21
20
|
if (this.el.shadowRoot !== null && this.el.shadowRoot !== undefined) {
|
|
22
21
|
const dropdown = this.el.shadowRoot.querySelector('.dropdown');
|
|
23
22
|
if (dropdown !== null && dropdown !== undefined) {
|
|
@@ -39,7 +38,7 @@ const BiggiveFormFieldSelect = /*@__PURE__*/ proxyCustomElement(class extends HT
|
|
|
39
38
|
}
|
|
40
39
|
}
|
|
41
40
|
render() {
|
|
42
|
-
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel
|
|
41
|
+
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel === null ? this.placeholder : this.selectedLabel)), h("div", { class: "options" }, h("slot", null))));
|
|
43
42
|
}
|
|
44
43
|
get el() { return this; }
|
|
45
44
|
static get style() { return biggiveFormFieldSelectCss; }
|
|
@@ -38,7 +38,6 @@ const biggiveButtonCss = "body{background-color:#D7D7D7}h1,h3,h4,h5,h6{margin-bo
|
|
|
38
38
|
const BiggiveButton = class {
|
|
39
39
|
constructor(hostRef) {
|
|
40
40
|
registerInstance(this, hostRef);
|
|
41
|
-
this.doButtonClick = createEvent(this, "doButtonClick", 7);
|
|
42
41
|
this.spaceBelow = 1;
|
|
43
42
|
this.colourScheme = 'primary';
|
|
44
43
|
this.label = 'Click me';
|
|
@@ -47,11 +46,8 @@ const BiggiveButton = class {
|
|
|
47
46
|
this.size = 'medium';
|
|
48
47
|
this.rounded = false;
|
|
49
48
|
}
|
|
50
|
-
handleButtonClick() {
|
|
51
|
-
this.doButtonClick.emit(this.url);
|
|
52
|
-
}
|
|
53
49
|
render() {
|
|
54
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() },
|
|
50
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("a", { href: this.url, class: 'button button-' + this.colourScheme + ' full-width-' + this.fullWidth.toString() + ' size-' + this.size + ' rounded-' + this.rounded.toString() }, this.label)));
|
|
55
51
|
}
|
|
56
52
|
};
|
|
57
53
|
BiggiveButton.style = biggiveButtonCss;
|
|
@@ -128,10 +124,7 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
128
124
|
this.filterBeneficiary = null;
|
|
129
125
|
this.filterLocation = null;
|
|
130
126
|
this.filterFunding = null;
|
|
131
|
-
this.
|
|
132
|
-
this.sortBy = event.target.value;
|
|
133
|
-
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
134
|
-
};
|
|
127
|
+
this.sortByPlaceholderText = 'Sort by';
|
|
135
128
|
this.handleApplyFilterButtonClick = () => {
|
|
136
129
|
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
137
130
|
};
|
|
@@ -157,6 +150,7 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
157
150
|
this.beneficiaryOptions = [];
|
|
158
151
|
this.locationOptions = [];
|
|
159
152
|
this.fundingOptions = [];
|
|
153
|
+
this.selectedLabel = null;
|
|
160
154
|
}
|
|
161
155
|
getSearchAndFilterObject() {
|
|
162
156
|
const event = {
|
|
@@ -169,15 +163,28 @@ const BiggiveCampaignCardFilterGrid = class {
|
|
|
169
163
|
};
|
|
170
164
|
return event;
|
|
171
165
|
}
|
|
172
|
-
doOptionSelectCompletedHandler() {
|
|
166
|
+
doOptionSelectCompletedHandler(event) {
|
|
173
167
|
this.sortBy = this.el.shadowRoot.getElementById('sort-by').selectedValue;
|
|
174
168
|
this.filterCategory = this.el.shadowRoot.getElementById('categories').selectedValue;
|
|
175
169
|
this.filterBeneficiary = this.el.shadowRoot.getElementById('beneficiaries').selectedValue;
|
|
176
170
|
this.filterLocation = this.el.shadowRoot.getElementById('locations').selectedValue;
|
|
177
171
|
this.filterFunding = this.el.shadowRoot.getElementById('funding').selectedValue;
|
|
172
|
+
// If this method was trigerred by the selection of a 'Sort by' dropdown option, then
|
|
173
|
+
// emit an event to search, but do NOT emit an event for example when filter options
|
|
174
|
+
// are selected, until the 'Apply filters' button is pressed which is handled separately
|
|
175
|
+
// by `handleApplyFilterButtonClick()`.
|
|
176
|
+
// Additional note -> we could, instead, do this:
|
|
177
|
+
// `<biggive-form-field-select placeholder="Sort by" id="sort-by" onDoSelectChange={this.someHandleMethod}>`
|
|
178
|
+
// but the problem with that is that `someHandleMethod` gets called first and then this
|
|
179
|
+
// method gets called, leading to two calls and more risk for error. DON-570.
|
|
180
|
+
if (event.detail.placeholder === this.sortByPlaceholderText) {
|
|
181
|
+
console.log('emitting event:');
|
|
182
|
+
console.log(this.getSearchAndFilterObject());
|
|
183
|
+
this.doSearchAndFilterUpdate.emit(this.getSearchAndFilterObject());
|
|
184
|
+
}
|
|
178
185
|
}
|
|
179
186
|
render() {
|
|
180
|
-
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", id: "sort-by"
|
|
187
|
+
return (h("div", { class: 'container space-below-' + this.spaceBelow }, h("div", { class: "sleeve" }, h("div", { class: "search-wrap" }, h("h4", null, this.intro), h("div", { class: "field-wrap" }, h("div", { class: "input-wrap" }, h("svg", { xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: faMagnifyingGlass.icon[4].toString() })), h("input", { type: "text", value: this.searchText, class: "input-text", placeholder: this.placeholderText, onInput: this.handleSearchTextChanged, onKeyDown: this.handleEnterPressed })), h("biggive-button", { onClick: this.handleSearchButtonPressed, label: this.buttonText }))), h("div", { class: "sort-filter-wrap" }, h("div", { class: "sort-wrap" }, h("biggive-form-field-select", { placeholder: "Sort by", selectedLabel: this.selectedLabel, id: "sort-by" }, h("biggive-form-field-select-option", { value: "amountRaised", label: "Most raised" }), h("biggive-form-field-select-option", { value: "matchFundsRemaining", label: "Match funds remaining" }), h("biggive-form-field-select-option", { value: "Relevance", label: "Relevance" }))), h("div", { class: "filter-wrap" }, h("biggive-button", { class: "filter", onClick: this.handleFilterButtonClick, label: "Filters" }), h("biggive-popup", { id: "filter-popup" }, h("h4", { class: "space-above-0 space-below-3 colour-primary" }, "Filters"), h("biggive-form-field-select", { placeholder: "Category", id: "categories", "space-below": "2" }, this.categoryOptions.length === 0
|
|
181
188
|
? undefined
|
|
182
189
|
: this.categoryOptions.map(option => h("biggive-form-field-select-option", { value: option, label: option }))), h("biggive-form-field-select", { placeholder: "Beneficiary", id: "beneficiaries", "space-below": "2" }, this.beneficiaryOptions.length === 0
|
|
183
190
|
? undefined
|
|
@@ -254,8 +261,7 @@ const BiggiveFormFieldSelect = class {
|
|
|
254
261
|
doOptionSelectCompletedHandler(event) {
|
|
255
262
|
this.selectedValue = event.detail.value;
|
|
256
263
|
this.selectedLabel = event.detail.label;
|
|
257
|
-
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel });
|
|
258
|
-
console.log({ value: this.selectedValue, label: this.selectedLabel });
|
|
264
|
+
this.doSelectChange.emit({ value: this.selectedValue, label: this.selectedLabel, placeholder: this.placeholder });
|
|
259
265
|
if (this.el.shadowRoot !== null && this.el.shadowRoot !== undefined) {
|
|
260
266
|
const dropdown = this.el.shadowRoot.querySelector('.dropdown');
|
|
261
267
|
if (dropdown !== null && dropdown !== undefined) {
|
|
@@ -277,7 +283,7 @@ const BiggiveFormFieldSelect = class {
|
|
|
277
283
|
}
|
|
278
284
|
}
|
|
279
285
|
render() {
|
|
280
|
-
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel
|
|
286
|
+
return (h("div", { class: 'dropdown space-below-' + this.spaceBelow }, h("div", { class: "sleeve", onClick: this.toggleFocus, onMouseLeave: this.toggleFocus }, h("span", { class: "placeholder" }, this.selectedLabel === null ? this.placeholder : this.selectedLabel)), h("div", { class: "options" }, h("slot", null))));
|
|
281
287
|
}
|
|
282
288
|
get el() { return getElement(this); }
|
|
283
289
|
};
|