Skip to content

Commit 4477633

Browse files
authored
Merge branch 'develop' into issue_1474
2 parents fde6bb2 + 4212e61 commit 4477633

File tree

40 files changed

+2497
-2865
lines changed

40 files changed

+2497
-2865
lines changed

Dockerfile

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,11 @@ ARG CONTENTFUL_TOPGEAR_PREVIEW_API_KEY
2626

2727
ARG FILESTACK_API_KEY
2828
ARG FILESTACK_SUBMISSION_CONTAINER
29+
30+
# Credentials for Mailchimp service
31+
ARG MAILCHIMP_API_KEY
32+
ARG MAILCHIMP_BASE_URL
33+
2934
ARG NODE_CONFIG_ENV
3035
ARG OPEN_EXCHANGE_RATES_KEY
3136
ARG SEGMENT_IO_API_KEY
@@ -49,6 +54,11 @@ ENV CONTENTFUL_TOPGEAR_PREVIEW_API_KEY=$CONTENTFUL_TOPGEAR_PREVIEW_API_KEY
4954

5055
ENV FILESTACK_API_KEY=$FILESTACK_API_KEY
5156
ENV FILESTACK_SUBMISSION_CONTAINER=$FILESTACK_SUBMISSION_CONTAINER
57+
58+
# Credentials for Mailchimp service
59+
ENV MAILCHIMP_API_KEY=$MAILCHIMP_API_KEY
60+
ENV MAILCHIMP_BASE_URL=$MAILCHIMP_BASE_URL
61+
5262
ENV NODE_CONFIG_ENV=$NODE_CONFIG_ENV
5363
ENV OPEN_EXCHANGE_RATES_KEY=$OPEN_EXCHANGE_RATES_KEY
5464
ENV SEGMENT_IO_API_KEY=$SEGMENT_IO_API_KEY

build.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ docker build -t $TAG \
4848
--build-arg CONTENTFUL_TOPGEAR_SPACE_ID=$CONTENTFUL_TOPGEAR_SPACE_ID \
4949
--build-arg FILESTACK_API_KEY=$FILESTACK_API_KEY \
5050
--build-arg FILESTACK_SUBMISSION_CONTAINER=$FILESTACK_SUBMISSION_CONTAINER \
51+
--build-arg MAILCHIMP_API_KEY=$MAILCHIMP_API_KEY \
52+
--build-arg MAILCHIMP_BASE_URL=$MAILCHIMP_BASE_URL \
5153
--build-arg NODE_CONFIG_ENV=$NODE_CONFIG_ENV \
5254
--build-arg OPEN_EXCHANGE_RATES_KEY=$OPEN_EXCHANGE_RATES_KEY \
5355
--build-arg SEGMENT_IO_API_KEY=$SEGMENT_IO_API_KEY \

config/custom-environment-variables.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,13 @@ module.exports = {
4646
},
4747
},
4848

49+
MAILCHIMP: {
50+
default: {
51+
API_KEY: 'MAILCHIMP_API_KEY',
52+
MAILCHIMP_BASE_URL: 'MAILCHIMP_BASE_URL',
53+
},
54+
},
55+
4956
OPEN_EXCHANGE_RATES_KEY: 'OPEN_EXCHANGE_RATES_KEY',
5057
},
5158
};

config/default.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,13 @@ module.exports = {
172172
},
173173
},
174174

175+
MAILCHIMP: {
176+
default: {
177+
API_KEY: '',
178+
MAILCHIMP_BASE_URL: '',
179+
},
180+
},
181+
175182
OPEN_EXCHANGE_RATES_KEY: '',
176183
},
177184
};

docs/contentful/custom-inline-components-in-markdown-fields.md

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -44,33 +44,31 @@ the same way).
4444
member of the community. It automatically shows necessary confirmation modals.
4545

4646
- #### NewsletterSignup
47-
**Sample Use:** `<NewsletterSignup listId="LIST_ID" apiKey="API_KEY" mailchimpBaseUrl="BASE_URL"/>`
47+
**Sample Use:** `<NewsletterSignup listId="LIST_ID" />`
4848

4949
Renders
5050
email input field, along with subscription button, that subscribes given email
5151
for a newsletter list. The component handles verification of emails, and modal
5252
UI windows shown on success and failure of subscription.
5353

54-
| Param | Default | Description |
55-
| --- | --- | --- |
56-
| apiKey | | MailChimp API key. |
57-
| label | Subscribe for Newsletter | Optional. Custom label to show on the button. |
58-
| listId | | ID of MailChimp list to subscribe. |
59-
| mailchimpBaseUrl | | Base URL of MailChimp API, associated with the API key and list ID. |
54+
| Param | Default | Description |
55+
| --- | --- | --- |
56+
| label | Subscribe for Newsletter | Optional. Custom label to show on the button. |
57+
| listId | | ID of MailChimp list to subscribe. |
58+
| interests | empty string | Optional. commas separated string of group ids to which user should be subscribed |
6059

6160
- #### NewsletterSignupForMembers
62-
**Sample use:** `<NewsletterSignupForMembers listId="LIST_ID" apiKey="API_KEY" mailchimpBaseUrl="BASE_URL"/>`
61+
**Sample use:** `<NewsletterSignupForMembers listId="LIST_ID" />`
6362

6463
Renders a newsletter signup button that takes user email from his profile
6564
information. If the user is not-authenticated, it gets him to the login or
6665
registration page, and subscribes him on return. Accepts the following props:
6766

68-
| Param | Default | Description |
69-
| --- | --- | --- |
70-
| apiKey | | MailChimp API key. |
71-
| label | Subscribe for Newsletter | Optional. Custom label to show on the button. |
72-
| listId | | ID of MailChimp list to subscribe. |
73-
| mailchimpBaseUrl | | Base URL of MailChimp API, associated with the API key and list ID. |
67+
| Param | Default | Description |
68+
| --- | --- | --- |
69+
| label | Subscribe for Newsletter | Optional. Custom label to show on the button. |
70+
| listId | | ID of MailChimp list to subscribe. |
71+
| interests | empty string | Optional. commas separated string of group ids to which user should be subscribed |
7472

7573

7674
- #### VideoModalButton

0 commit comments

Comments
 (0)