@ordergroove/offers 2.35.8-alpha-PR-831-1.26 → 2.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist/bundle-report.html +1 -1
- package/dist/offers.js +1 -1
- package/dist/offers.js.map +2 -2
- package/package.json +2 -2
- package/src/components/Offer.js +2 -1
- package/src/core/actions.js +3 -0
- package/src/make-api.js +1 -0
- package/src/types.ts +4 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ordergroove/offers",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.36.0",
|
|
4
4
|
"description": "offer state component",
|
|
5
5
|
"author": "Eugenio Lattanzio <eugenio63@gmail.com>",
|
|
6
6
|
"homepage": "https://github.com/ordergroove/plush-toys#readme",
|
|
@@ -48,5 +48,5 @@
|
|
|
48
48
|
"@ordergroove/offers-templates": "^0.9.6",
|
|
49
49
|
"@types/lodash.memoize": "^4.1.9"
|
|
50
50
|
},
|
|
51
|
-
"gitHead": "
|
|
51
|
+
"gitHead": "3d4c898b8dffb8c106a36e1f3eaa9c7291e70702"
|
|
52
52
|
}
|
package/src/components/Offer.js
CHANGED
|
@@ -33,7 +33,7 @@ function logMulticurrencyWarning(storeCurrency, primaryCurrency) {
|
|
|
33
33
|
// only log once
|
|
34
34
|
if (!hasLogged) {
|
|
35
35
|
console.warn(
|
|
36
|
-
`Hiding Ordergroove offer since the store currency ${storeCurrency} does not match your configured currency ${primaryCurrency} and you are not
|
|
36
|
+
`Hiding Ordergroove offer since the store currency ${storeCurrency} does not match your configured currency ${primaryCurrency} and you are not set up for multicurrency. Contact your Ordergroove representative for next steps.`
|
|
37
37
|
);
|
|
38
38
|
hasLogged = true;
|
|
39
39
|
}
|
|
@@ -320,6 +320,7 @@ export class Offer extends TemplateElement {
|
|
|
320
320
|
}
|
|
321
321
|
|
|
322
322
|
get shouldRenderOffer() {
|
|
323
|
+
// currently, only the shopify reducer populates storeCurrency
|
|
323
324
|
if (this.config && this.config.storeCurrency && this.config.merchantSettings) {
|
|
324
325
|
const shouldRender =
|
|
325
326
|
this.config.merchantSettings.multicurrency_enabled ||
|
package/src/core/actions.js
CHANGED
|
@@ -313,6 +313,9 @@ export const setProductToSubscribe = (product, productToSubscribe) => ({
|
|
|
313
313
|
payload: { product, productToSubscribe }
|
|
314
314
|
});
|
|
315
315
|
|
|
316
|
+
/**
|
|
317
|
+
* @param {import('../types').MerchantSettings} settings
|
|
318
|
+
*/
|
|
316
319
|
export const receiveMerchantSettings = settings => ({
|
|
317
320
|
type: constants.RECEIVE_MERCHANT_SETTINGS,
|
|
318
321
|
payload: settings
|
package/src/make-api.js
CHANGED
|
@@ -166,6 +166,7 @@ export default function makeApi(store) {
|
|
|
166
166
|
* @param {*} merchantId
|
|
167
167
|
* @param {*} env
|
|
168
168
|
* @param {*} authUrl
|
|
169
|
+
* @param {import('./types').MerchantSettings} merchantSettings
|
|
169
170
|
*/
|
|
170
171
|
initialize(merchantId, env, authUrl, merchantSettings) {
|
|
171
172
|
// settings resolves once, before anything.
|
package/src/types.ts
ADDED