@biggive/components 0.0.5 → 0.0.8
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-e6a690fb.entry.js → p-59970be1.entry.js} +2 -2
- package/dist/cjs/biggive-campaign-card_3.cjs.entry.js +34 -27
- package/dist/cjs/biggive.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/biggive-campaign-card/biggive-campaign-card.css +11 -44
- package/dist/collection/components/biggive-campaign-card/biggive-campaign-card.js +83 -105
- package/dist/collection/components/biggive-grid/biggive-grid.css +1 -6
- package/dist/collection/components/demo-campaign-cards/demo-campaign-cards.js +1 -1
- package/dist/components/biggive-campaign-card2.js +35 -27
- package/dist/components/biggive-grid2.js +1 -1
- package/dist/components/demo-campaign-cards.js +1 -1
- package/dist/esm/biggive-campaign-card_3.entry.js +34 -27
- package/dist/esm/biggive.js +1 -1
- package/dist/esm/loader.js +1 -1
- package/dist/types/components/biggive-campaign-card/biggive-campaign-card.d.ts +23 -17
- package/dist/types/components.d.ts +36 -28
- package/package.json +5 -4
- package/readme.md +3 -1
|
@@ -318,82 +318,89 @@ class CampaignGroupsService {
|
|
|
318
318
|
}
|
|
319
319
|
}
|
|
320
320
|
|
|
321
|
-
const biggiveCampaignCardCss = ":host{display:block;margin-bottom:30px}
|
|
321
|
+
const biggiveCampaignCardCss = ":host{display:block;margin-bottom:30px}.container{font-family:\"Euclid Triangle\", sans-serif;filter:drop-shadow(-1px 6px 3px rgba(0, 0, 0, 0.25))}.sleeve{clip-path:polygon(0% 0%, 0% 0%, 100% 0%, 100% 0%, 100% 100%, 100% 100%, 10% 100%, 0 90%)}.content{padding:15px;background-color:#FFFFFF}.campaign-type{margin-left:15px;width:0;height:0;border-style:inset;border-width:85px 45px 0 45px;border-color:#2AF135 transparent transparent transparent;float:left;transform:rotate(360deg)}.campaign-type span{display:block;text-align:center;top:-85px;left:-25px;position:relative;width:45px;height:45px;margin:0;color:#2C089B;font-size:0.9rem}.banner{padding-bottom:30%;background-repeat:no-repeat;background-position:center center;background-size:cover}.banner img{display:none}.meta-wrap.style-1{display:flex;font-size:16px;line-height:20px;margin-bottom:20px}.meta-wrap.style-1 .meta-item{width:50%}.meta-wrap.style-1 .meta-item .label{font-weight:bold}.meta-wrap.style-1 .meta-item .text{color:#2C089B}header{margin-bottom:20px}header .slug{text-transform:uppercase;font-size:12px;line-height:14px}header h3{margin:0;padding:0;font-size:24px;line-height:28px}.meta-wrap.style-2{display:flex;font-size:12px;line-height:14px;margin-bottom:40px}.meta-wrap.style-2 .meta-item{width:50%}.meta-wrap.style-2 .meta-item .label{font-weight:bold;display:block;margin-bottom:10px}.meta-wrap.style-2 .meta-item .text{display:block;font-size:16px;line-height:18px}.meta-wrap.style-2 .meta-item .text i{margin-right:10px}.meta-wrap.style-3{display:flex;font-size:16px;line-height:20px;margin-bottom:20px}.meta-wrap.style-3 .meta-item{margin-right:60px}.meta-wrap.style-3 .meta-item .label{font-weight:bold;display:block;font-size:12px;line-height:14px;margin-bottom:10px}.meta-wrap.style-3 .meta-item .text{display:block;font-size:36px;line-height:40px;font-weight:bold}.meta-wrap.style-3 .meta-item:last-child .text{color:#2C089B}.button-wrap{text-align:right}.button-wrap a{display:inline-block;padding:15px 30px;color:#FFFFFF;background-color:#2C089B;cursor:pointer;text-transform:uppercase;font-size:12px;text-decoration:none}.icon{height:1rem;width:2rem;vertical-align:-0.125rem}";
|
|
322
322
|
|
|
323
323
|
const BiggiveCampaignCard = class {
|
|
324
324
|
constructor(hostRef) {
|
|
325
325
|
registerInstance(this, hostRef);
|
|
326
326
|
/**
|
|
327
|
-
*
|
|
327
|
+
* Full URL of a banner image.
|
|
328
328
|
*/
|
|
329
329
|
this.banner = '';
|
|
330
330
|
/**
|
|
331
|
-
*
|
|
331
|
+
* (Ceiling of) whole number of days until campaign end.
|
|
332
332
|
*/
|
|
333
333
|
this.daysRemaining = null;
|
|
334
334
|
/**
|
|
335
|
-
*
|
|
336
|
-
*
|
|
335
|
+
* Target for the campaign including matching but excluding any
|
|
336
|
+
* tax relief, in major unit of currency e.g. pounds GBP.
|
|
337
337
|
*/
|
|
338
338
|
this.target = null;
|
|
339
339
|
/**
|
|
340
|
-
*
|
|
340
|
+
* Display name of the charity or non-profit.
|
|
341
341
|
*/
|
|
342
342
|
this.organisationName = null;
|
|
343
343
|
/**
|
|
344
|
-
*
|
|
344
|
+
* Display name of the charity's specific time-bound fundraising campaign.
|
|
345
345
|
*/
|
|
346
346
|
this.campaignTitle = null;
|
|
347
347
|
/**
|
|
348
|
-
*
|
|
348
|
+
* e.g. "Match Funded".
|
|
349
349
|
*/
|
|
350
350
|
this.campaignType = null;
|
|
351
351
|
/**
|
|
352
|
-
*
|
|
352
|
+
* Array of full beneficiary labels.
|
|
353
353
|
*/
|
|
354
|
-
this.beneficiaries =
|
|
354
|
+
this.beneficiaries = [];
|
|
355
355
|
/**
|
|
356
|
-
*
|
|
356
|
+
* Array of full category labels.
|
|
357
357
|
*/
|
|
358
|
-
this.categories =
|
|
358
|
+
this.categories = [];
|
|
359
359
|
/**
|
|
360
|
-
*
|
|
361
|
-
* e.g. pounds GBP.
|
|
360
|
+
* Match funds not yet used or reserved, in major unit of currency e.g. pounds GBP.
|
|
362
361
|
*/
|
|
363
362
|
this.matchFundsRemaining = null;
|
|
364
363
|
/**
|
|
365
|
-
*
|
|
366
|
-
*
|
|
364
|
+
* Total the campaign has raised so far including matching but excluding any
|
|
365
|
+
* tax relief, in major unit of currency e.g. pounds GBP.
|
|
367
366
|
*/
|
|
368
367
|
this.totalFundsRaised = null;
|
|
369
368
|
/**
|
|
370
|
-
*
|
|
369
|
+
* Full URL of a call to action.
|
|
371
370
|
*/
|
|
372
371
|
this.callToActionUrl = null;
|
|
373
372
|
/**
|
|
374
|
-
*
|
|
373
|
+
* Text for the link to `callToActionUrl`.
|
|
375
374
|
*/
|
|
376
375
|
this.callToActionLabel = null;
|
|
377
376
|
}
|
|
378
377
|
getBeneficiaryIcons() {
|
|
379
|
-
return this.beneficiaries.
|
|
378
|
+
return this.beneficiaries.map(beneficiary => CampaignGroupsService.getBeneficiaryIcon(beneficiary));
|
|
380
379
|
}
|
|
381
380
|
getCategoryIcons() {
|
|
382
|
-
return this.categories.
|
|
381
|
+
return this.categories.map(category => CampaignGroupsService.getCategoryIcon(category));
|
|
383
382
|
}
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
383
|
+
/**
|
|
384
|
+
* @returns Whole large currency units (e.g. pounds) formatted with symbol.
|
|
385
|
+
*/
|
|
386
|
+
formatCurrency(currencyCode, amount) {
|
|
387
|
+
if (amount === null || isNaN(amount)) {
|
|
388
|
+
return '–';
|
|
387
389
|
}
|
|
388
|
-
return
|
|
390
|
+
return Intl.NumberFormat('en-GB', {
|
|
391
|
+
style: 'currency',
|
|
392
|
+
currency: currencyCode,
|
|
393
|
+
currencyDisplay: 'symbol',
|
|
394
|
+
maximumFractionDigits: 0,
|
|
395
|
+
}).format(amount);
|
|
389
396
|
}
|
|
390
397
|
render() {
|
|
391
|
-
return (h("div", { class: "container" }, h("div", { class: "sleeve" }, h("div", { class: "campaign-type" }, h("span", null, this.campaignType)), this.banner.length > 0 ? (h("div", { class: "image-wrap banner", style: { 'background-image': 'url(' + this.banner + ')' } }, h("img", { src: this.banner, class: "banner" }))) : null, h("div", { class: "content" }, h("div", { class: "meta-wrap style-1" }, h("div", { class: "meta-item" }, h("span", { class: "label" }, "Days Remaining:"), " ", h("span", { class: "text" }, this.daysRemaining)), h("div", { class: "meta-item" }, h("span", { class: "label" }, "Target:"), " ", h("span", { class: "text" },
|
|
398
|
+
return (h("div", { class: "container" }, h("div", { class: "sleeve" }, h("div", { class: "campaign-type" }, h("span", null, this.campaignType)), this.banner.length > 0 ? (h("div", { class: "image-wrap banner", style: { 'background-image': 'url(' + this.banner + ')' } }, h("img", { src: this.banner, class: "banner" }))) : null, h("div", { class: "content" }, h("div", { class: "meta-wrap style-1" }, h("div", { class: "meta-item" }, h("span", { class: "label" }, "Days Remaining:"), " ", h("span", { class: "text" }, this.daysRemaining)), h("div", { class: "meta-item" }, h("span", { class: "label" }, "Target:"), " ", h("span", { class: "text" }, this.formatCurrency(this.currencyCode, this.target)))), h("header", null, h("div", { class: "slug" }, this.organisationName), h("h3", null, this.campaignTitle)), h("div", { class: "meta-wrap style-2" }, h("div", { class: "meta-item" }, h("span", { class: "label" }, "Categories"), h("span", { class: "text" }, this.getCategoryIcons().map((iconDefinition) => (h("svg", { width: "512", height: "512", xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: iconDefinition.icon[4].toString() })))))), h("div", { class: "meta-item" }, h("span", { class: "label" }, "Helping"), h("span", { class: "text" }, this.getBeneficiaryIcons().map(iconDefinition => (h("svg", { width: "512", height: "512", xmlns: "http://www.w3.org/2000/svg", class: "icon", viewBox: "0 0 512 512" }, h("path", { d: iconDefinition.icon[4].toString() }))))))), h("div", { class: "meta-wrap style-3" }, h("div", { class: "meta-item" }, h("span", { class: "label" }, "Match", h("br", null), "Funds Remaining"), h("span", { class: "text" }, this.formatCurrency(this.currencyCode, this.matchFundsRemaining))), h("div", { class: "meta-item" }, h("span", { class: "label" }, "Total", h("br", null), "Funds Received"), h("span", { class: "text" }, this.formatCurrency(this.currencyCode, this.totalFundsRaised)))), h("div", { class: "button-wrap" }, h("a", { href: this.callToActionUrl, class: "call-to-action" }, this.callToActionLabel))))));
|
|
392
399
|
}
|
|
393
400
|
};
|
|
394
401
|
BiggiveCampaignCard.style = biggiveCampaignCardCss;
|
|
395
402
|
|
|
396
|
-
const biggiveGridCss = ":host{display:block}.grid{display
|
|
403
|
+
const biggiveGridCss = ":host{display:block}.grid{display:flex;flex-flow:row wrap;justify-content:space-between}";
|
|
397
404
|
|
|
398
405
|
const BiggiveGrid = class {
|
|
399
406
|
constructor(hostRef) {
|
|
@@ -412,7 +419,7 @@ const DemoCampaignCards = class {
|
|
|
412
419
|
registerInstance(this, hostRef);
|
|
413
420
|
}
|
|
414
421
|
render() {
|
|
415
|
-
return (h("biggive-grid", null, [...Array(12)].map(() => (h("biggive-campaign-card", { banner: getAssetPath('/assets/images/banner.png'),
|
|
422
|
+
return (h("biggive-grid", null, [...Array(12)].map(() => (h("biggive-campaign-card", { banner: getAssetPath('/assets/images/banner.png'), daysRemaining: 50, currencyCode: "GBP", target: 50000, organisationName: "Ardent Theatre Company", campaignType: "Match Funded", campaignTitle: "Strike! A play by Tracy Ryan", categories: ['Arts/Culture/Heritage', 'Environment/Conservation', 'Health/Wellbeing'], beneficiaries: ['General Public/Humankind'], matchFundsRemaining: 17424, totalFundsRaised: 15424, callToActionUrl: "#", callToActionLabel: "Donate" })))));
|
|
416
423
|
}
|
|
417
424
|
};
|
|
418
425
|
DemoCampaignCards.style = demoCampaignCardsCss;
|
package/dist/esm/biggive.js
CHANGED
|
@@ -13,5 +13,5 @@ const patchBrowser = () => {
|
|
|
13
13
|
};
|
|
14
14
|
|
|
15
15
|
patchBrowser().then(options => {
|
|
16
|
-
return bootstrapLazy([["biggive-campaign-card_3",[[1,"demo-campaign-cards"],[1,"biggive-campaign-card",{"banner":[1],"daysRemaining":[2,"days-remaining"],"target":[2],"organisationName":[1,"organisation-name"],"campaignTitle":[1,"campaign-title"],"campaignType":[1,"campaign-type"],"beneficiaries":[
|
|
16
|
+
return bootstrapLazy([["biggive-campaign-card_3",[[1,"demo-campaign-cards"],[1,"biggive-campaign-card",{"banner":[1],"daysRemaining":[2,"days-remaining"],"currencyCode":[1,"currency-code"],"target":[2],"organisationName":[1,"organisation-name"],"campaignTitle":[1,"campaign-title"],"campaignType":[1,"campaign-type"],"beneficiaries":[16],"categories":[16],"matchFundsRemaining":[2,"match-funds-remaining"],"totalFundsRaised":[2,"total-funds-raised"],"callToActionUrl":[1,"call-to-action-url"],"callToActionLabel":[1,"call-to-action-label"]}],[1,"biggive-grid"]]]], options);
|
|
17
17
|
});
|
package/dist/esm/loader.js
CHANGED
|
@@ -10,7 +10,7 @@ const patchEsm = () => {
|
|
|
10
10
|
const defineCustomElements = (win, options) => {
|
|
11
11
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
12
12
|
return patchEsm().then(() => {
|
|
13
|
-
return bootstrapLazy([["biggive-campaign-card_3",[[1,"demo-campaign-cards"],[1,"biggive-campaign-card",{"banner":[1],"daysRemaining":[2,"days-remaining"],"target":[2],"organisationName":[1,"organisation-name"],"campaignTitle":[1,"campaign-title"],"campaignType":[1,"campaign-type"],"beneficiaries":[
|
|
13
|
+
return bootstrapLazy([["biggive-campaign-card_3",[[1,"demo-campaign-cards"],[1,"biggive-campaign-card",{"banner":[1],"daysRemaining":[2,"days-remaining"],"currencyCode":[1,"currency-code"],"target":[2],"organisationName":[1,"organisation-name"],"campaignTitle":[1,"campaign-title"],"campaignType":[1,"campaign-type"],"beneficiaries":[16],"categories":[16],"matchFundsRemaining":[2,"match-funds-remaining"],"totalFundsRaised":[2,"total-funds-raised"],"callToActionUrl":[1,"call-to-action-url"],"callToActionLabel":[1,"call-to-action-label"]}],[1,"biggive-grid"]]]], options);
|
|
14
14
|
});
|
|
15
15
|
};
|
|
16
16
|
|
|
@@ -3,58 +3,64 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export declare class BiggiveCampaignCard {
|
|
5
5
|
/**
|
|
6
|
-
*
|
|
6
|
+
* Full URL of a banner image.
|
|
7
7
|
*/
|
|
8
8
|
banner: string;
|
|
9
9
|
/**
|
|
10
|
-
*
|
|
10
|
+
* (Ceiling of) whole number of days until campaign end.
|
|
11
11
|
*/
|
|
12
12
|
daysRemaining: number;
|
|
13
13
|
/**
|
|
14
|
-
*
|
|
15
|
-
|
|
14
|
+
* e.g. 'GBP'.
|
|
15
|
+
*/
|
|
16
|
+
currencyCode: string;
|
|
17
|
+
/**
|
|
18
|
+
* Target for the campaign including matching but excluding any
|
|
19
|
+
* tax relief, in major unit of currency e.g. pounds GBP.
|
|
16
20
|
*/
|
|
17
21
|
target: number;
|
|
18
22
|
/**
|
|
19
|
-
*
|
|
23
|
+
* Display name of the charity or non-profit.
|
|
20
24
|
*/
|
|
21
25
|
organisationName: string;
|
|
22
26
|
/**
|
|
23
|
-
*
|
|
27
|
+
* Display name of the charity's specific time-bound fundraising campaign.
|
|
24
28
|
*/
|
|
25
29
|
campaignTitle: string;
|
|
26
30
|
/**
|
|
27
|
-
*
|
|
31
|
+
* e.g. "Match Funded".
|
|
28
32
|
*/
|
|
29
33
|
campaignType: string;
|
|
30
34
|
/**
|
|
31
|
-
*
|
|
35
|
+
* Array of full beneficiary labels.
|
|
32
36
|
*/
|
|
33
|
-
beneficiaries: string;
|
|
37
|
+
beneficiaries: string[];
|
|
34
38
|
/**
|
|
35
|
-
*
|
|
39
|
+
* Array of full category labels.
|
|
36
40
|
*/
|
|
37
|
-
categories: string;
|
|
41
|
+
categories: string[];
|
|
38
42
|
/**
|
|
39
|
-
*
|
|
40
|
-
* e.g. pounds GBP.
|
|
43
|
+
* Match funds not yet used or reserved, in major unit of currency e.g. pounds GBP.
|
|
41
44
|
*/
|
|
42
45
|
matchFundsRemaining: number;
|
|
43
46
|
/**
|
|
44
|
-
*
|
|
45
|
-
*
|
|
47
|
+
* Total the campaign has raised so far including matching but excluding any
|
|
48
|
+
* tax relief, in major unit of currency e.g. pounds GBP.
|
|
46
49
|
*/
|
|
47
50
|
totalFundsRaised: number;
|
|
48
51
|
/**
|
|
49
|
-
*
|
|
52
|
+
* Full URL of a call to action.
|
|
50
53
|
*/
|
|
51
54
|
callToActionUrl: string;
|
|
52
55
|
/**
|
|
53
|
-
*
|
|
56
|
+
* Text for the link to `callToActionUrl`.
|
|
54
57
|
*/
|
|
55
58
|
callToActionLabel: string;
|
|
56
59
|
private getBeneficiaryIcons;
|
|
57
60
|
private getCategoryIcons;
|
|
61
|
+
/**
|
|
62
|
+
* @returns Whole large currency units (e.g. pounds) formatted with symbol.
|
|
63
|
+
*/
|
|
58
64
|
private formatCurrency;
|
|
59
65
|
render(): any;
|
|
60
66
|
}
|
|
@@ -8,51 +8,55 @@ import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
|
|
|
8
8
|
export namespace Components {
|
|
9
9
|
interface BiggiveCampaignCard {
|
|
10
10
|
/**
|
|
11
|
-
*
|
|
11
|
+
* Full URL of a banner image.
|
|
12
12
|
*/
|
|
13
13
|
"banner": string;
|
|
14
14
|
/**
|
|
15
|
-
*
|
|
15
|
+
* Array of full beneficiary labels.
|
|
16
16
|
*/
|
|
17
|
-
"beneficiaries": string;
|
|
17
|
+
"beneficiaries": string[];
|
|
18
18
|
/**
|
|
19
|
-
*
|
|
19
|
+
* Text for the link to `callToActionUrl`.
|
|
20
20
|
*/
|
|
21
21
|
"callToActionLabel": string;
|
|
22
22
|
/**
|
|
23
|
-
*
|
|
23
|
+
* Full URL of a call to action.
|
|
24
24
|
*/
|
|
25
25
|
"callToActionUrl": string;
|
|
26
26
|
/**
|
|
27
|
-
*
|
|
27
|
+
* Display name of the charity's specific time-bound fundraising campaign.
|
|
28
28
|
*/
|
|
29
29
|
"campaignTitle": string;
|
|
30
30
|
/**
|
|
31
|
-
*
|
|
31
|
+
* e.g. "Match Funded".
|
|
32
32
|
*/
|
|
33
33
|
"campaignType": string;
|
|
34
34
|
/**
|
|
35
|
-
*
|
|
35
|
+
* Array of full category labels.
|
|
36
36
|
*/
|
|
37
|
-
"categories": string;
|
|
37
|
+
"categories": string[];
|
|
38
38
|
/**
|
|
39
|
-
*
|
|
39
|
+
* e.g. 'GBP'.
|
|
40
|
+
*/
|
|
41
|
+
"currencyCode": string;
|
|
42
|
+
/**
|
|
43
|
+
* (Ceiling of) whole number of days until campaign end.
|
|
40
44
|
*/
|
|
41
45
|
"daysRemaining": number;
|
|
42
46
|
/**
|
|
43
|
-
*
|
|
47
|
+
* Match funds not yet used or reserved, in major unit of currency e.g. pounds GBP.
|
|
44
48
|
*/
|
|
45
49
|
"matchFundsRemaining": number;
|
|
46
50
|
/**
|
|
47
|
-
*
|
|
51
|
+
* Display name of the charity or non-profit.
|
|
48
52
|
*/
|
|
49
53
|
"organisationName": string;
|
|
50
54
|
/**
|
|
51
|
-
*
|
|
55
|
+
* Target for the campaign including matching but excluding any tax relief, in major unit of currency e.g. pounds GBP.
|
|
52
56
|
*/
|
|
53
57
|
"target": number;
|
|
54
58
|
/**
|
|
55
|
-
*
|
|
59
|
+
* Total the campaign has raised so far including matching but excluding any tax relief, in major unit of currency e.g. pounds GBP.
|
|
56
60
|
*/
|
|
57
61
|
"totalFundsRaised": number;
|
|
58
62
|
}
|
|
@@ -89,51 +93,55 @@ declare global {
|
|
|
89
93
|
declare namespace LocalJSX {
|
|
90
94
|
interface BiggiveCampaignCard {
|
|
91
95
|
/**
|
|
92
|
-
*
|
|
96
|
+
* Full URL of a banner image.
|
|
93
97
|
*/
|
|
94
98
|
"banner"?: string;
|
|
95
99
|
/**
|
|
96
|
-
*
|
|
100
|
+
* Array of full beneficiary labels.
|
|
97
101
|
*/
|
|
98
|
-
"beneficiaries"?: string;
|
|
102
|
+
"beneficiaries"?: string[];
|
|
99
103
|
/**
|
|
100
|
-
*
|
|
104
|
+
* Text for the link to `callToActionUrl`.
|
|
101
105
|
*/
|
|
102
106
|
"callToActionLabel"?: string;
|
|
103
107
|
/**
|
|
104
|
-
*
|
|
108
|
+
* Full URL of a call to action.
|
|
105
109
|
*/
|
|
106
110
|
"callToActionUrl"?: string;
|
|
107
111
|
/**
|
|
108
|
-
*
|
|
112
|
+
* Display name of the charity's specific time-bound fundraising campaign.
|
|
109
113
|
*/
|
|
110
114
|
"campaignTitle"?: string;
|
|
111
115
|
/**
|
|
112
|
-
*
|
|
116
|
+
* e.g. "Match Funded".
|
|
113
117
|
*/
|
|
114
118
|
"campaignType"?: string;
|
|
115
119
|
/**
|
|
116
|
-
*
|
|
120
|
+
* Array of full category labels.
|
|
121
|
+
*/
|
|
122
|
+
"categories"?: string[];
|
|
123
|
+
/**
|
|
124
|
+
* e.g. 'GBP'.
|
|
117
125
|
*/
|
|
118
|
-
"
|
|
126
|
+
"currencyCode"?: string;
|
|
119
127
|
/**
|
|
120
|
-
*
|
|
128
|
+
* (Ceiling of) whole number of days until campaign end.
|
|
121
129
|
*/
|
|
122
130
|
"daysRemaining"?: number;
|
|
123
131
|
/**
|
|
124
|
-
*
|
|
132
|
+
* Match funds not yet used or reserved, in major unit of currency e.g. pounds GBP.
|
|
125
133
|
*/
|
|
126
134
|
"matchFundsRemaining"?: number;
|
|
127
135
|
/**
|
|
128
|
-
*
|
|
136
|
+
* Display name of the charity or non-profit.
|
|
129
137
|
*/
|
|
130
138
|
"organisationName"?: string;
|
|
131
139
|
/**
|
|
132
|
-
*
|
|
140
|
+
* Target for the campaign including matching but excluding any tax relief, in major unit of currency e.g. pounds GBP.
|
|
133
141
|
*/
|
|
134
142
|
"target"?: number;
|
|
135
143
|
/**
|
|
136
|
-
*
|
|
144
|
+
* Total the campaign has raised so far including matching but excluding any tax relief, in major unit of currency e.g. pounds GBP.
|
|
137
145
|
*/
|
|
138
146
|
"totalFundsRaised"?: number;
|
|
139
147
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@biggive/components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.8",
|
|
4
4
|
"description": "Big Give Components",
|
|
5
5
|
"main": "dist/index.cjs.js",
|
|
6
6
|
"module": "dist/index.js",
|
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
],
|
|
21
21
|
"scripts": {
|
|
22
22
|
"build": "stencil build --docs",
|
|
23
|
-
"start": "stencil build --dev --watch --serve
|
|
23
|
+
"start": "stencil build --dev --watch --serve",
|
|
24
24
|
"lint": "eslint src/**/*{.ts,.tsx}",
|
|
25
25
|
"lint:fix": "eslint --fix src/**/*{.ts,.tsx}",
|
|
26
|
-
"test": "stencil test --spec --e2e
|
|
27
|
-
"test.watch": "stencil test --spec --e2e --watchAll
|
|
26
|
+
"test": "stencil test --spec --e2e",
|
|
27
|
+
"test.watch": "stencil test --spec --e2e --watchAll",
|
|
28
28
|
"generate": "stencil generate",
|
|
29
29
|
"prepare": "husky install",
|
|
30
30
|
"pre-commit": "lint-staged"
|
|
@@ -39,6 +39,7 @@
|
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@stencil/eslint-plugin": "^0.4.0",
|
|
42
|
+
"@stencil/sass": "^1.5.2",
|
|
42
43
|
"@types/jest": "^27.0.3",
|
|
43
44
|
"eslint-config-prettier": "^8.5.0",
|
|
44
45
|
"eslint-plugin-prettier": "^4.2.1",
|
package/readme.md
CHANGED
|
@@ -66,7 +66,9 @@ For now:
|
|
|
66
66
|
folder as the app's own images. This is the approach taken on [this proof of concept branch](https://github.com/thebiggive/donate-frontend/tree/COM-5-proof-of-concept).
|
|
67
67
|
Should we find managing image assets messy in apps generally, an alternative approach we might
|
|
68
68
|
try is importing images to component style and adding [`@rollup/plugin-image`](https://github.com/rollup/plugins/tree/master/packages/image/#readme)
|
|
69
|
-
to Stencil's build config.
|
|
69
|
+
to Stencil's build config. Or if there are only a few, we could also investigate
|
|
70
|
+
whether `assetsDirs` on a `@Component` folds in what's needed in a way that works
|
|
71
|
+
in Angular et al.
|
|
70
72
|
|
|
71
73
|
### Make any required changes to the sample web components
|
|
72
74
|
|