@pelcro/react-pelcro-js 3.1.0-beta.1 → 3.1.0-beta.2
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/index.cjs.js +829 -494
- package/dist/index.esm.js +824 -495
- package/dist/pelcro.css +22 -0
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -3461,9 +3461,9 @@ var paymentMethod_fr = {
|
|
|
3461
3461
|
select: select
|
|
3462
3462
|
};
|
|
3463
3463
|
|
|
3464
|
-
var title$
|
|
3464
|
+
var title$h = "Enter your email to subscribe to our newsletter";
|
|
3465
3465
|
var updateTitle$1 = "Update newsletter selections";
|
|
3466
|
-
var subtitle$
|
|
3466
|
+
var subtitle$9 = "We may use your email for other marketing communication";
|
|
3467
3467
|
var labels$p = {
|
|
3468
3468
|
submit: "Submit",
|
|
3469
3469
|
firstName: "First name",
|
|
@@ -3480,16 +3480,16 @@ var messages$r = {
|
|
|
3480
3480
|
here: "here"
|
|
3481
3481
|
};
|
|
3482
3482
|
var newsletter_en = {
|
|
3483
|
-
title: title$
|
|
3483
|
+
title: title$h,
|
|
3484
3484
|
updateTitle: updateTitle$1,
|
|
3485
|
-
subtitle: subtitle$
|
|
3485
|
+
subtitle: subtitle$9,
|
|
3486
3486
|
labels: labels$p,
|
|
3487
3487
|
messages: messages$r
|
|
3488
3488
|
};
|
|
3489
3489
|
|
|
3490
|
-
var title$
|
|
3490
|
+
var title$g = "Entrez votre adresse courriel pour vous abonner à notre infolettre";
|
|
3491
3491
|
var updateTitle = "Mettre à jour son choix d'infolettres";
|
|
3492
|
-
var subtitle$
|
|
3492
|
+
var subtitle$8 = "Nous pouvons utiliser votre adresse courriel pour d’autres communications marketing";
|
|
3493
3493
|
var labels$o = {
|
|
3494
3494
|
submit: "Lire l’article !",
|
|
3495
3495
|
firstName: "Prénom",
|
|
@@ -3506,9 +3506,9 @@ var messages$q = {
|
|
|
3506
3506
|
here: "ici"
|
|
3507
3507
|
};
|
|
3508
3508
|
var newsletter_fr = {
|
|
3509
|
-
title: title$
|
|
3509
|
+
title: title$g,
|
|
3510
3510
|
updateTitle: updateTitle,
|
|
3511
|
-
subtitle: subtitle$
|
|
3511
|
+
subtitle: subtitle$8,
|
|
3512
3512
|
labels: labels$o,
|
|
3513
3513
|
messages: messages$q
|
|
3514
3514
|
};
|
|
@@ -3765,8 +3765,8 @@ var login_fr = {
|
|
|
3765
3765
|
errors: errors$4
|
|
3766
3766
|
};
|
|
3767
3767
|
|
|
3768
|
-
var title$
|
|
3769
|
-
var subtitle$
|
|
3768
|
+
var title$f = "Create an account";
|
|
3769
|
+
var subtitle$7 = "Enter your email and password below";
|
|
3770
3770
|
var labels$h = {
|
|
3771
3771
|
signUpFacebook: "Sign up with Facebook",
|
|
3772
3772
|
signUpGoogle: "Sign up with Google",
|
|
@@ -3851,8 +3851,8 @@ var redeem$1 = {
|
|
|
3851
3851
|
}
|
|
3852
3852
|
};
|
|
3853
3853
|
var register_en = {
|
|
3854
|
-
title: title$
|
|
3855
|
-
subtitle: subtitle$
|
|
3854
|
+
title: title$f,
|
|
3855
|
+
subtitle: subtitle$7,
|
|
3856
3856
|
labels: labels$h,
|
|
3857
3857
|
messages: messages$h,
|
|
3858
3858
|
errors: errors$3,
|
|
@@ -3860,8 +3860,8 @@ var register_en = {
|
|
|
3860
3860
|
redeem: redeem$1
|
|
3861
3861
|
};
|
|
3862
3862
|
|
|
3863
|
-
var title$
|
|
3864
|
-
var subtitle$
|
|
3863
|
+
var title$e = "Créer un compte";
|
|
3864
|
+
var subtitle$6 = "Entrez votre courriel et votre mot de passe ci-dessous";
|
|
3865
3865
|
var labels$g = {
|
|
3866
3866
|
signUpFacebook: "Inscrivez-vous avec Facebook",
|
|
3867
3867
|
signUpGoogle: "Inscrivez-vous avec Google",
|
|
@@ -3947,8 +3947,8 @@ var redeem = {
|
|
|
3947
3947
|
}
|
|
3948
3948
|
};
|
|
3949
3949
|
var register_fr = {
|
|
3950
|
-
title: title$
|
|
3951
|
-
subtitle: subtitle$
|
|
3950
|
+
title: title$e,
|
|
3951
|
+
subtitle: subtitle$6,
|
|
3952
3952
|
labels: labels$g,
|
|
3953
3953
|
messages: messages$g,
|
|
3954
3954
|
errors: errors$2,
|
|
@@ -4008,7 +4008,7 @@ var userEdit_fr = {
|
|
|
4008
4008
|
messages: messages$e
|
|
4009
4009
|
};
|
|
4010
4010
|
|
|
4011
|
-
var title$
|
|
4011
|
+
var title$d = "Enter your shipping address";
|
|
4012
4012
|
var selectAddressTitle$1 = "Please select an address";
|
|
4013
4013
|
var selectAddressSubtitle$1 = "Select one of your saved addresses, or add a new one";
|
|
4014
4014
|
var labels$d = {
|
|
@@ -4031,7 +4031,7 @@ var messages$d = {
|
|
|
4031
4031
|
subRedeemed: "Your subscription has been redeemed."
|
|
4032
4032
|
};
|
|
4033
4033
|
var address_en = {
|
|
4034
|
-
title: title$
|
|
4034
|
+
title: title$d,
|
|
4035
4035
|
selectAddressTitle: selectAddressTitle$1,
|
|
4036
4036
|
selectAddressSubtitle: selectAddressSubtitle$1,
|
|
4037
4037
|
labels: labels$d,
|
|
@@ -4039,7 +4039,7 @@ var address_en = {
|
|
|
4039
4039
|
messages: messages$d
|
|
4040
4040
|
};
|
|
4041
4041
|
|
|
4042
|
-
var title$
|
|
4042
|
+
var title$c = "Entrez votre adresse de livraison";
|
|
4043
4043
|
var selectAddressTitle = "Veuillez sélectionner une adresse";
|
|
4044
4044
|
var selectAddressSubtitle = "Choisissez l'une de vos adresses ou créez-en une nouvelle";
|
|
4045
4045
|
var labels$c = {
|
|
@@ -4062,7 +4062,7 @@ var messages$c = {
|
|
|
4062
4062
|
subRedeemed: "Votre abonnement a bien été activé."
|
|
4063
4063
|
};
|
|
4064
4064
|
var address_fr = {
|
|
4065
|
-
title: title$
|
|
4065
|
+
title: title$c,
|
|
4066
4066
|
selectAddressTitle: selectAddressTitle,
|
|
4067
4067
|
selectAddressSubtitle: selectAddressSubtitle,
|
|
4068
4068
|
labels: labels$c,
|
|
@@ -4070,8 +4070,8 @@ var address_fr = {
|
|
|
4070
4070
|
messages: messages$c
|
|
4071
4071
|
};
|
|
4072
4072
|
|
|
4073
|
-
var title$
|
|
4074
|
-
var subtitle$
|
|
4073
|
+
var title$b = "Reset your password";
|
|
4074
|
+
var subtitle$5 = "Enter a new password below";
|
|
4075
4075
|
var email$3 = "Email";
|
|
4076
4076
|
var password$3 = "Password";
|
|
4077
4077
|
var confirmPassword$1 = "Confirm password";
|
|
@@ -4079,8 +4079,8 @@ var submit$5 = "Submit";
|
|
|
4079
4079
|
var required$5 = "Required";
|
|
4080
4080
|
var passwordUpdated$1 = "Password has been updated, please login with the new password";
|
|
4081
4081
|
var passwordReset_en = {
|
|
4082
|
-
title: title$
|
|
4083
|
-
subtitle: subtitle$
|
|
4082
|
+
title: title$b,
|
|
4083
|
+
subtitle: subtitle$5,
|
|
4084
4084
|
email: email$3,
|
|
4085
4085
|
password: password$3,
|
|
4086
4086
|
confirmPassword: confirmPassword$1,
|
|
@@ -4089,8 +4089,8 @@ var passwordReset_en = {
|
|
|
4089
4089
|
passwordUpdated: passwordUpdated$1
|
|
4090
4090
|
};
|
|
4091
4091
|
|
|
4092
|
-
var title$
|
|
4093
|
-
var subtitle$
|
|
4092
|
+
var title$a = "Réinitialiser votre mot de passe";
|
|
4093
|
+
var subtitle$4 = "Entrez un nouveau mot de passe ci-dessous";
|
|
4094
4094
|
var email$2 = "Adresse courriel";
|
|
4095
4095
|
var password$2 = "Mot de passe";
|
|
4096
4096
|
var confirmPassword = "Confirmer le mot de passe";
|
|
@@ -4098,8 +4098,8 @@ var submit$4 = "Soumettre";
|
|
|
4098
4098
|
var required$4 = "Champs obligatoires";
|
|
4099
4099
|
var passwordUpdated = "Votre mot de passe a été mis à jour, veuillez vous connecter avec celui-ci";
|
|
4100
4100
|
var passwordReset_fr = {
|
|
4101
|
-
title: title$
|
|
4102
|
-
subtitle: subtitle$
|
|
4101
|
+
title: title$a,
|
|
4102
|
+
subtitle: subtitle$4,
|
|
4103
4103
|
email: email$2,
|
|
4104
4104
|
password: password$2,
|
|
4105
4105
|
confirmPassword: confirmPassword,
|
|
@@ -4108,7 +4108,7 @@ var passwordReset_fr = {
|
|
|
4108
4108
|
passwordUpdated: passwordUpdated
|
|
4109
4109
|
};
|
|
4110
4110
|
|
|
4111
|
-
var title$
|
|
4111
|
+
var title$9 = "Forgot your password?";
|
|
4112
4112
|
var email$1 = "Email";
|
|
4113
4113
|
var password$1 = "Password";
|
|
4114
4114
|
var submit$3 = "Submit";
|
|
@@ -4119,7 +4119,7 @@ var messages$b = {
|
|
|
4119
4119
|
loginHere: "login here."
|
|
4120
4120
|
};
|
|
4121
4121
|
var passwordForgot_en = {
|
|
4122
|
-
title: title$
|
|
4122
|
+
title: title$9,
|
|
4123
4123
|
email: email$1,
|
|
4124
4124
|
password: password$1,
|
|
4125
4125
|
submit: submit$3,
|
|
@@ -4128,7 +4128,7 @@ var passwordForgot_en = {
|
|
|
4128
4128
|
messages: messages$b
|
|
4129
4129
|
};
|
|
4130
4130
|
|
|
4131
|
-
var title$
|
|
4131
|
+
var title$8 = "Mot de passe oublié ?";
|
|
4132
4132
|
var email = "Courriel";
|
|
4133
4133
|
var password = "Mot de passe";
|
|
4134
4134
|
var submit$2 = "Soumettre";
|
|
@@ -4139,7 +4139,7 @@ var messages$a = {
|
|
|
4139
4139
|
loginHere: "Connectez-vous ici"
|
|
4140
4140
|
};
|
|
4141
4141
|
var passwordForgot_fr = {
|
|
4142
|
-
title: title$
|
|
4142
|
+
title: title$8,
|
|
4143
4143
|
email: email,
|
|
4144
4144
|
password: password,
|
|
4145
4145
|
submit: submit$2,
|
|
@@ -4148,7 +4148,7 @@ var passwordForgot_fr = {
|
|
|
4148
4148
|
messages: messages$a
|
|
4149
4149
|
};
|
|
4150
4150
|
|
|
4151
|
-
var title$
|
|
4151
|
+
var title$7 = "Change your password";
|
|
4152
4152
|
var currentPassword$1 = "Current password";
|
|
4153
4153
|
var newPassword$1 = "New password";
|
|
4154
4154
|
var confirmNewPassword$1 = "Confirm new password";
|
|
@@ -4158,7 +4158,7 @@ var passwordChanged$1 = "Password has been changed, please login with the new pa
|
|
|
4158
4158
|
var passwordsNotMatching$1 = "Passwords don't match";
|
|
4159
4159
|
var weakPassword$1 = "Your password must contain at least 6 characters";
|
|
4160
4160
|
var passwordChange_en = {
|
|
4161
|
-
title: title$
|
|
4161
|
+
title: title$7,
|
|
4162
4162
|
currentPassword: currentPassword$1,
|
|
4163
4163
|
newPassword: newPassword$1,
|
|
4164
4164
|
confirmNewPassword: confirmNewPassword$1,
|
|
@@ -4169,7 +4169,7 @@ var passwordChange_en = {
|
|
|
4169
4169
|
weakPassword: weakPassword$1
|
|
4170
4170
|
};
|
|
4171
4171
|
|
|
4172
|
-
var title$
|
|
4172
|
+
var title$6 = "Changez votre mot de passe";
|
|
4173
4173
|
var currentPassword = "Mot de passe actuel";
|
|
4174
4174
|
var newPassword = "Nouveau mot de passe";
|
|
4175
4175
|
var confirmNewPassword = "Confirmer le nouveau mot de passe";
|
|
@@ -4179,7 +4179,7 @@ var passwordChanged = "Le mot de passe a été modifié, veuillez vous connecter
|
|
|
4179
4179
|
var passwordsNotMatching = "Les mots de passe ne correspondent pas";
|
|
4180
4180
|
var weakPassword = "Votre mot de passe doit contenir au moins 6";
|
|
4181
4181
|
var passwordChange_fr = {
|
|
4182
|
-
title: title$
|
|
4182
|
+
title: title$6,
|
|
4183
4183
|
currentPassword: currentPassword,
|
|
4184
4184
|
newPassword: newPassword,
|
|
4185
4185
|
confirmNewPassword: confirmNewPassword,
|
|
@@ -4190,8 +4190,8 @@ var passwordChange_fr = {
|
|
|
4190
4190
|
weakPassword: weakPassword
|
|
4191
4191
|
};
|
|
4192
4192
|
|
|
4193
|
-
var title$
|
|
4194
|
-
var subtitle$
|
|
4193
|
+
var title$5 = "Votre panier";
|
|
4194
|
+
var subtitle$3 = "Terminez votre achat ci-dessous";
|
|
4195
4195
|
var name$1 = "Produit";
|
|
4196
4196
|
var quantity$1 = "Quantité";
|
|
4197
4197
|
var price$1 = "Prix";
|
|
@@ -4202,8 +4202,8 @@ var confirm$3 = "Passer à la caisse";
|
|
|
4202
4202
|
var empty$1 = "Votre panier est vide.";
|
|
4203
4203
|
var removeAll$1 = "Vider";
|
|
4204
4204
|
var cart_fr = {
|
|
4205
|
-
title: title$
|
|
4206
|
-
subtitle: subtitle$
|
|
4205
|
+
title: title$5,
|
|
4206
|
+
subtitle: subtitle$3,
|
|
4207
4207
|
name: name$1,
|
|
4208
4208
|
quantity: quantity$1,
|
|
4209
4209
|
price: price$1,
|
|
@@ -4215,8 +4215,8 @@ var cart_fr = {
|
|
|
4215
4215
|
removeAll: removeAll$1
|
|
4216
4216
|
};
|
|
4217
4217
|
|
|
4218
|
-
var title$
|
|
4219
|
-
var subtitle = "Comple your purchase below";
|
|
4218
|
+
var title$4 = "Your shopping cart";
|
|
4219
|
+
var subtitle$2 = "Comple your purchase below";
|
|
4220
4220
|
var name = "Name";
|
|
4221
4221
|
var quantity = "Quantity";
|
|
4222
4222
|
var price = "Price";
|
|
@@ -4227,8 +4227,8 @@ var confirm$2 = "Checkout";
|
|
|
4227
4227
|
var empty = "Your cart is empty.";
|
|
4228
4228
|
var removeAll = "Remove all";
|
|
4229
4229
|
var cart_en = {
|
|
4230
|
-
title: title$
|
|
4231
|
-
subtitle: subtitle,
|
|
4230
|
+
title: title$4,
|
|
4231
|
+
subtitle: subtitle$2,
|
|
4232
4232
|
name: name,
|
|
4233
4233
|
quantity: quantity,
|
|
4234
4234
|
price: price,
|
|
@@ -4666,7 +4666,7 @@ var verifyEmail_fr = {
|
|
|
4666
4666
|
messages: messages
|
|
4667
4667
|
};
|
|
4668
4668
|
|
|
4669
|
-
var title$
|
|
4669
|
+
var title$3 = "Invoice details";
|
|
4670
4670
|
var labels$1 = {
|
|
4671
4671
|
summary: "Summary",
|
|
4672
4672
|
total: "Total",
|
|
@@ -4679,12 +4679,12 @@ var buttons$1 = {
|
|
|
4679
4679
|
pay: "Pay now"
|
|
4680
4680
|
};
|
|
4681
4681
|
var invoiceDetails_en = {
|
|
4682
|
-
title: title$
|
|
4682
|
+
title: title$3,
|
|
4683
4683
|
labels: labels$1,
|
|
4684
4684
|
buttons: buttons$1
|
|
4685
4685
|
};
|
|
4686
4686
|
|
|
4687
|
-
var title = "Invoice details";
|
|
4687
|
+
var title$2 = "Invoice details";
|
|
4688
4688
|
var labels = {
|
|
4689
4689
|
summary: "Summary",
|
|
4690
4690
|
total: "Total",
|
|
@@ -4697,11 +4697,37 @@ var buttons = {
|
|
|
4697
4697
|
pay: "Pay now"
|
|
4698
4698
|
};
|
|
4699
4699
|
var invoiceDetails_fr = {
|
|
4700
|
-
title: title,
|
|
4700
|
+
title: title$2,
|
|
4701
4701
|
labels: labels,
|
|
4702
4702
|
buttons: buttons
|
|
4703
4703
|
};
|
|
4704
4704
|
|
|
4705
|
+
var title$1 = "Renewal options";
|
|
4706
|
+
var subtitle$1 = "Select one of the options below to continue";
|
|
4707
|
+
var next$1 = "Next";
|
|
4708
|
+
var addNew$1 = "Add Another Subscription";
|
|
4709
|
+
var renew$1 = "Renew Existing Subscription";
|
|
4710
|
+
var subscriptionOptions_en = {
|
|
4711
|
+
title: title$1,
|
|
4712
|
+
subtitle: subtitle$1,
|
|
4713
|
+
next: next$1,
|
|
4714
|
+
addNew: addNew$1,
|
|
4715
|
+
renew: renew$1
|
|
4716
|
+
};
|
|
4717
|
+
|
|
4718
|
+
var title = "Renewal options";
|
|
4719
|
+
var subtitle = "Select one of the options below to continue";
|
|
4720
|
+
var next = "Next";
|
|
4721
|
+
var addNew = "Add Another Subscription";
|
|
4722
|
+
var renew = "Renew Existing Subscription";
|
|
4723
|
+
var subscriptionOptions_fr = {
|
|
4724
|
+
title: title,
|
|
4725
|
+
subtitle: subtitle,
|
|
4726
|
+
next: next,
|
|
4727
|
+
addNew: addNew,
|
|
4728
|
+
renew: renew
|
|
4729
|
+
};
|
|
4730
|
+
|
|
4705
4731
|
function create$1(createState) {
|
|
4706
4732
|
let state;
|
|
4707
4733
|
const listeners = new Set();
|
|
@@ -6051,7 +6077,7 @@ class PelcroActions {
|
|
|
6051
6077
|
view,
|
|
6052
6078
|
cartItems,
|
|
6053
6079
|
...otherStateFields
|
|
6054
|
-
} = initialState$
|
|
6080
|
+
} = initialState$j;
|
|
6055
6081
|
this.set(otherStateFields);
|
|
6056
6082
|
});
|
|
6057
6083
|
|
|
@@ -6075,6 +6101,16 @@ class PelcroActions {
|
|
|
6075
6101
|
});
|
|
6076
6102
|
}
|
|
6077
6103
|
|
|
6104
|
+
if (view === "subscription-options") {
|
|
6105
|
+
const noRenewableProducts = getRenewableProducts().length === 0;
|
|
6106
|
+
|
|
6107
|
+
if (noRenewableProducts) {
|
|
6108
|
+
return this.set({
|
|
6109
|
+
view: "plan-select"
|
|
6110
|
+
});
|
|
6111
|
+
}
|
|
6112
|
+
}
|
|
6113
|
+
|
|
6078
6114
|
this.set({
|
|
6079
6115
|
view
|
|
6080
6116
|
});
|
|
@@ -6149,6 +6185,26 @@ class PelcroActions {
|
|
|
6149
6185
|
}
|
|
6150
6186
|
});
|
|
6151
6187
|
|
|
6188
|
+
_defineProperty$3(this, "setProductsList", products => {
|
|
6189
|
+
if (!Array.isArray(products)) {
|
|
6190
|
+
return console.error(`setProductsList expects an array of products as an argument, got an argument of type ${typeof products} instead`);
|
|
6191
|
+
}
|
|
6192
|
+
|
|
6193
|
+
const allowedProducts = window.Pelcro.product.list();
|
|
6194
|
+
const validProducts = products.filter(product => {
|
|
6195
|
+
const isValidProduct = allowedProducts.some(allowedProduct => allowedProduct.id === (product === null || product === void 0 ? void 0 : product.id) && allowedProduct.name === (product === null || product === void 0 ? void 0 : product.name));
|
|
6196
|
+
|
|
6197
|
+
if (!isValidProduct) {
|
|
6198
|
+
console.warn(`setProductsList expects an array of products that exist in the list of valid products (window.Pelcro.product.list()), but it recieved a product which doesn't exist in that list:`, product);
|
|
6199
|
+
}
|
|
6200
|
+
|
|
6201
|
+
return isValidProduct;
|
|
6202
|
+
});
|
|
6203
|
+
this.set({
|
|
6204
|
+
productsList: validProducts
|
|
6205
|
+
});
|
|
6206
|
+
});
|
|
6207
|
+
|
|
6152
6208
|
_defineProperty$3(this, "setProduct", id => {
|
|
6153
6209
|
const product = window.Pelcro.product.getById(id);
|
|
6154
6210
|
if (!product) return console.error("invalid product id");
|
|
@@ -6370,10 +6426,12 @@ class PelcroCallbacks {
|
|
|
6370
6426
|
|
|
6371
6427
|
}
|
|
6372
6428
|
|
|
6373
|
-
|
|
6429
|
+
var _window$Pelcro$produc, _window$Pelcro;
|
|
6430
|
+
const initialState$j = {
|
|
6374
6431
|
// View
|
|
6375
6432
|
view: null,
|
|
6376
6433
|
// Plans
|
|
6434
|
+
productsList: (_window$Pelcro$produc = (_window$Pelcro = window.Pelcro) === null || _window$Pelcro === void 0 ? void 0 : _window$Pelcro.product.list()) !== null && _window$Pelcro$produc !== void 0 ? _window$Pelcro$produc : [],
|
|
6377
6435
|
product: null,
|
|
6378
6436
|
plan: null,
|
|
6379
6437
|
isGift: false,
|
|
@@ -6400,7 +6458,7 @@ const createPelcroStore = () => createStore(middleware_3((set, get) => {
|
|
|
6400
6458
|
return {
|
|
6401
6459
|
// Store setter
|
|
6402
6460
|
set,
|
|
6403
|
-
...initialState$
|
|
6461
|
+
...initialState$j,
|
|
6404
6462
|
// State actions
|
|
6405
6463
|
...actions,
|
|
6406
6464
|
// Callbacks
|
|
@@ -6755,6 +6813,28 @@ function userMustVerifyEmail() {
|
|
|
6755
6813
|
const isUserEmailVerified = (_window$Pelcro$user$r9 = (_window$Pelcro$user$r10 = window.Pelcro.user.read()) === null || _window$Pelcro$user$r10 === void 0 ? void 0 : _window$Pelcro$user$r10.email_confirm) !== null && _window$Pelcro$user$r9 !== void 0 ? _window$Pelcro$user$r9 : false;
|
|
6756
6814
|
return window.Pelcro.user.isAuthenticated() && isEmailVerificationEnabled && !isUserEmailVerified;
|
|
6757
6815
|
}
|
|
6816
|
+
function getRenewableProducts() {
|
|
6817
|
+
const renewableSubs = window.Pelcro.subscription.list().filter(sub => sub.status === "active" && sub.cancel_at_period_end === 1);
|
|
6818
|
+
const renewableProductsIds = [...new Set(renewableSubs.map(sub => sub.plan.product.id))];
|
|
6819
|
+
const renewablePlansIds = [...new Set(renewableSubs.map(sub => sub.plan.id))];
|
|
6820
|
+
const {
|
|
6821
|
+
productsList
|
|
6822
|
+
} = usePelcro.getStore();
|
|
6823
|
+
return productsList.map(product => {
|
|
6824
|
+
if (renewableProductsIds.includes(product.id)) {
|
|
6825
|
+
const renewablePlans = getRenewablePlansOnly(product);
|
|
6826
|
+
return { ...product,
|
|
6827
|
+
plans: renewablePlans
|
|
6828
|
+
};
|
|
6829
|
+
}
|
|
6830
|
+
}).filter(product => product);
|
|
6831
|
+
|
|
6832
|
+
function getRenewablePlansOnly(product) {
|
|
6833
|
+
var _product$plans$filter, _product$plans;
|
|
6834
|
+
|
|
6835
|
+
return (_product$plans$filter = product === null || product === void 0 ? void 0 : (_product$plans = product.plans) === null || _product$plans === void 0 ? void 0 : _product$plans.filter(plan => renewablePlansIds.includes(plan.id))) !== null && _product$plans$filter !== void 0 ? _product$plans$filter : [];
|
|
6836
|
+
}
|
|
6837
|
+
}
|
|
6758
6838
|
|
|
6759
6839
|
const resources = {
|
|
6760
6840
|
en: {
|
|
@@ -6779,7 +6859,8 @@ const resources = {
|
|
|
6779
6859
|
dashboard: dashboard_en,
|
|
6780
6860
|
select: select_en,
|
|
6781
6861
|
notification: notification_en,
|
|
6782
|
-
invoiceDetails: invoiceDetails_en
|
|
6862
|
+
invoiceDetails: invoiceDetails_en,
|
|
6863
|
+
subscriptionOptions: subscriptionOptions_en
|
|
6783
6864
|
},
|
|
6784
6865
|
fr: {
|
|
6785
6866
|
common: common_fr,
|
|
@@ -6803,7 +6884,8 @@ const resources = {
|
|
|
6803
6884
|
dashboard: dashboard_fr,
|
|
6804
6885
|
select: select_fr,
|
|
6805
6886
|
notification: notification_fr,
|
|
6806
|
-
invoiceDetails: invoiceDetails_fr
|
|
6887
|
+
invoiceDetails: invoiceDetails_fr,
|
|
6888
|
+
subscriptionOptions: subscriptionOptions_fr
|
|
6807
6889
|
}
|
|
6808
6890
|
}; // set UI language to the page language or default to the language in site settings
|
|
6809
6891
|
|
|
@@ -7094,8 +7176,8 @@ const saveToMetadataButton = new SaveToMetadataButtonClass();
|
|
|
7094
7176
|
|
|
7095
7177
|
let e={data:""},t=t=>"undefined"!=typeof window?((t?t.querySelector("#_goober"):window._goober)||Object.assign((t||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:t||e,l=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(})/g,a=/\/\*[^]*?\*\/|\s\s+|\n/g,n=(e,t)=>{let r,l="",a="",o="";for(let c in e){let s=e[c];"object"==typeof s?(r=t?t.replace(/([^,])+/g,e=>c.replace(/([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):c,a+="@"==c[0]?"f"==c[1]?n(s,c):c+"{"+n(s,"k"==c[1]?"":t)+"}":n(s,r)):"@"==c[0]&&"i"==c[1]?l=c+" "+s+";":(c=c.replace(/[A-Z]/g,"-$&").toLowerCase(),o+=n.p?n.p(c,s):c+":"+s+";");}return o[0]?(r=t?t+"{"+o+"}":o,l+r+a):l+a},o={},c=e=>{let t="";for(let r in e)t+=r+("object"==typeof e[r]?c(e[r]):e[r]);return t},s=(e,t,r,s,i)=>{let p="object"==typeof e?c(e):e,u=o[p]||(o[p]=(e=>{let t=0,r=11;for(;t<e.length;)r=101*r+e.charCodeAt(t++)>>>0;return "go"+r})(p));if(!o[u]){let t="object"==typeof e?e:(e=>{let t,r=[{}];for(;t=l.exec(e.replace(a,""));)t[4]&&r.shift(),t[3]?r.unshift(r[0][t[3]]=r[0][t[3]]||{}):t[4]||(r[0][t[1]]=t[2]);return r[0]})(e);o[u]=n(i?{["@keyframes "+u]:t}:t,r?"":"."+u);}return ((e,t,r)=>{-1==t.data.indexOf(e)&&(t.data=r?e+t.data:t.data+e);})(o[u],t,s),u},i=(e,t,r)=>e.reduce((e,l,a)=>{let o=t[a];if(o&&o.call){let e=o(r),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;o=t?"."+t:e&&"object"==typeof e?e.props?"":n(e,""):e;}return e+l+(null==o?"":o)},"");function p(e){let r=this||{},l=e.call?e(r.p):e;return s(l.unshift?l.raw?i(l,[].slice.call(arguments,1),r.p):l.reduce((e,t)=>t?Object.assign(e,t.call?t(r.p):t):e,{}):l,t(r.target),r.g,r.o,r.k)}let u,f,d;p.bind({g:1});let b=p.bind({k:1});function h(e,t,r,l){n.p=t,u=e,f=r,d=l;}function y(e,t){let r=this||{};return function(){let l=arguments;function a(n,o){let c=Object.assign({},n),s=c.className||a.className;r.p=Object.assign({theme:f&&f()},c),r.o=/ *go\d+/.test(s),c.className=p.apply(r,l)+(s?" "+s:""),t&&(c.ref=o);let i=c.as||e;return d&&i[0]&&d(c),u(i,c)}return t?t(a):a}}
|
|
7096
7178
|
|
|
7097
|
-
function _extends$
|
|
7098
|
-
_extends$
|
|
7179
|
+
function _extends$A() {
|
|
7180
|
+
_extends$A = Object.assign || function (target) {
|
|
7099
7181
|
for (var i = 1; i < arguments.length; i++) {
|
|
7100
7182
|
var source = arguments[i];
|
|
7101
7183
|
|
|
@@ -7109,7 +7191,7 @@ function _extends$z() {
|
|
|
7109
7191
|
return target;
|
|
7110
7192
|
};
|
|
7111
7193
|
|
|
7112
|
-
return _extends$
|
|
7194
|
+
return _extends$A.apply(this, arguments);
|
|
7113
7195
|
}
|
|
7114
7196
|
|
|
7115
7197
|
function _taggedTemplateLiteralLoose(strings, raw) {
|
|
@@ -7199,7 +7281,7 @@ var clearFromRemoveQueue = function clearFromRemoveQueue(toastId) {
|
|
|
7199
7281
|
var reducer = function reducer(state, action) {
|
|
7200
7282
|
switch (action.type) {
|
|
7201
7283
|
case ActionType.ADD_TOAST:
|
|
7202
|
-
return _extends$
|
|
7284
|
+
return _extends$A({}, state, {
|
|
7203
7285
|
toasts: [action.toast].concat(state.toasts).slice(0, TOAST_LIMIT)
|
|
7204
7286
|
});
|
|
7205
7287
|
|
|
@@ -7209,9 +7291,9 @@ var reducer = function reducer(state, action) {
|
|
|
7209
7291
|
clearFromRemoveQueue(action.toast.id);
|
|
7210
7292
|
}
|
|
7211
7293
|
|
|
7212
|
-
return _extends$
|
|
7294
|
+
return _extends$A({}, state, {
|
|
7213
7295
|
toasts: state.toasts.map(function (t) {
|
|
7214
|
-
return t.id === action.toast.id ? _extends$
|
|
7296
|
+
return t.id === action.toast.id ? _extends$A({}, t, action.toast) : t;
|
|
7215
7297
|
})
|
|
7216
7298
|
});
|
|
7217
7299
|
|
|
@@ -7238,9 +7320,9 @@ var reducer = function reducer(state, action) {
|
|
|
7238
7320
|
});
|
|
7239
7321
|
}
|
|
7240
7322
|
|
|
7241
|
-
return _extends$
|
|
7323
|
+
return _extends$A({}, state, {
|
|
7242
7324
|
toasts: state.toasts.map(function (t) {
|
|
7243
|
-
return t.id === toastId || toastId === undefined ? _extends$
|
|
7325
|
+
return t.id === toastId || toastId === undefined ? _extends$A({}, t, {
|
|
7244
7326
|
visible: false
|
|
7245
7327
|
}) : t;
|
|
7246
7328
|
})
|
|
@@ -7248,28 +7330,28 @@ var reducer = function reducer(state, action) {
|
|
|
7248
7330
|
|
|
7249
7331
|
case ActionType.REMOVE_TOAST:
|
|
7250
7332
|
if (action.toastId === undefined) {
|
|
7251
|
-
return _extends$
|
|
7333
|
+
return _extends$A({}, state, {
|
|
7252
7334
|
toasts: []
|
|
7253
7335
|
});
|
|
7254
7336
|
}
|
|
7255
7337
|
|
|
7256
|
-
return _extends$
|
|
7338
|
+
return _extends$A({}, state, {
|
|
7257
7339
|
toasts: state.toasts.filter(function (t) {
|
|
7258
7340
|
return t.id !== action.toastId;
|
|
7259
7341
|
})
|
|
7260
7342
|
});
|
|
7261
7343
|
|
|
7262
7344
|
case ActionType.START_PAUSE:
|
|
7263
|
-
return _extends$
|
|
7345
|
+
return _extends$A({}, state, {
|
|
7264
7346
|
pausedAt: action.time
|
|
7265
7347
|
});
|
|
7266
7348
|
|
|
7267
7349
|
case ActionType.END_PAUSE:
|
|
7268
7350
|
var diff = action.time - (state.pausedAt || 0);
|
|
7269
|
-
return _extends$
|
|
7351
|
+
return _extends$A({}, state, {
|
|
7270
7352
|
pausedAt: undefined,
|
|
7271
7353
|
toasts: state.toasts.map(function (t) {
|
|
7272
|
-
return _extends$
|
|
7354
|
+
return _extends$A({}, t, {
|
|
7273
7355
|
pauseDuration: t.pauseDuration + diff
|
|
7274
7356
|
});
|
|
7275
7357
|
})
|
|
@@ -7316,12 +7398,12 @@ var useStore = function useStore(toastOptions) {
|
|
|
7316
7398
|
var mergedToasts = state.toasts.map(function (t) {
|
|
7317
7399
|
var _toastOptions$t$type, _toastOptions, _toastOptions$t$type2;
|
|
7318
7400
|
|
|
7319
|
-
return _extends$
|
|
7401
|
+
return _extends$A({}, toastOptions, toastOptions[t.type], t, {
|
|
7320
7402
|
duration: t.duration || ((_toastOptions$t$type = toastOptions[t.type]) == null ? void 0 : _toastOptions$t$type.duration) || ((_toastOptions = toastOptions) == null ? void 0 : _toastOptions.duration) || defaultTimeouts[t.type],
|
|
7321
|
-
style: _extends$
|
|
7403
|
+
style: _extends$A({}, toastOptions.style, (_toastOptions$t$type2 = toastOptions[t.type]) == null ? void 0 : _toastOptions$t$type2.style, t.style)
|
|
7322
7404
|
});
|
|
7323
7405
|
});
|
|
7324
|
-
return _extends$
|
|
7406
|
+
return _extends$A({}, state, {
|
|
7325
7407
|
toasts: mergedToasts
|
|
7326
7408
|
});
|
|
7327
7409
|
};
|
|
@@ -7331,7 +7413,7 @@ var createToast = function createToast(message, type, opts) {
|
|
|
7331
7413
|
type = 'blank';
|
|
7332
7414
|
}
|
|
7333
7415
|
|
|
7334
|
-
return _extends$
|
|
7416
|
+
return _extends$A({
|
|
7335
7417
|
createdAt: Date.now(),
|
|
7336
7418
|
visible: true,
|
|
7337
7419
|
type: type,
|
|
@@ -7381,14 +7463,14 @@ toast.remove = function (toastId) {
|
|
|
7381
7463
|
};
|
|
7382
7464
|
|
|
7383
7465
|
toast.promise = function (promise, msgs, opts) {
|
|
7384
|
-
var id = toast.loading(msgs.loading, _extends$
|
|
7466
|
+
var id = toast.loading(msgs.loading, _extends$A({}, opts, opts == null ? void 0 : opts.loading));
|
|
7385
7467
|
promise.then(function (p) {
|
|
7386
|
-
toast.success(resolveValue(msgs.success, p), _extends$
|
|
7468
|
+
toast.success(resolveValue(msgs.success, p), _extends$A({
|
|
7387
7469
|
id: id
|
|
7388
7470
|
}, opts, opts == null ? void 0 : opts.success));
|
|
7389
7471
|
return p;
|
|
7390
7472
|
})["catch"](function (e) {
|
|
7391
|
-
toast.error(resolveValue(msgs.error, e), _extends$
|
|
7473
|
+
toast.error(resolveValue(msgs.error, e), _extends$A({
|
|
7392
7474
|
id: id
|
|
7393
7475
|
}, opts, opts == null ? void 0 : opts.error));
|
|
7394
7476
|
});
|
|
@@ -7727,7 +7809,7 @@ var ToastBar = /*#__PURE__*/React.memo(function (_ref2) {
|
|
|
7727
7809
|
var message = React.createElement(Message, Object.assign({}, toast.ariaProps), resolveValue(toast.message, toast));
|
|
7728
7810
|
return React.createElement(ToastBarBase, {
|
|
7729
7811
|
className: toast.className,
|
|
7730
|
-
style: _extends$
|
|
7812
|
+
style: _extends$A({}, animationStyle, style, toast.style)
|
|
7731
7813
|
}, typeof children === 'function' ? children({
|
|
7732
7814
|
icon: icon,
|
|
7733
7815
|
message: message
|
|
@@ -7757,7 +7839,7 @@ var getPositionStyle = function getPositionStyle(position, offset) {
|
|
|
7757
7839
|
} : position.includes('right') ? {
|
|
7758
7840
|
justifyContent: 'flex-end'
|
|
7759
7841
|
} : {};
|
|
7760
|
-
return _extends$
|
|
7842
|
+
return _extends$A({
|
|
7761
7843
|
left: 0,
|
|
7762
7844
|
right: 0,
|
|
7763
7845
|
display: 'flex',
|
|
@@ -7784,7 +7866,7 @@ var Toaster = function Toaster(_ref) {
|
|
|
7784
7866
|
handlers = _useToaster.handlers;
|
|
7785
7867
|
|
|
7786
7868
|
return React.createElement("div", {
|
|
7787
|
-
style: _extends$
|
|
7869
|
+
style: _extends$A({
|
|
7788
7870
|
position: 'fixed',
|
|
7789
7871
|
zIndex: 9999,
|
|
7790
7872
|
top: DEFAULT_OFFSET,
|
|
@@ -7819,82 +7901,82 @@ var Toaster = function Toaster(_ref) {
|
|
|
7819
7901
|
}));
|
|
7820
7902
|
};
|
|
7821
7903
|
|
|
7822
|
-
var _path$
|
|
7904
|
+
var _path$x;
|
|
7823
7905
|
|
|
7824
|
-
function _extends$
|
|
7906
|
+
function _extends$z() { _extends$z = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$z.apply(this, arguments); }
|
|
7825
7907
|
|
|
7826
7908
|
function SvgCheckSolid(props) {
|
|
7827
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
7909
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$z({
|
|
7828
7910
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7829
7911
|
className: "h-5 w-5",
|
|
7830
7912
|
viewBox: "0 0 20 20",
|
|
7831
7913
|
fill: "currentColor"
|
|
7832
|
-
}, props), _path$
|
|
7914
|
+
}, props), _path$x || (_path$x = /*#__PURE__*/React__namespace.createElement("path", {
|
|
7833
7915
|
fillRule: "evenodd",
|
|
7834
7916
|
d: "M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z",
|
|
7835
7917
|
clipRule: "evenodd"
|
|
7836
7918
|
})));
|
|
7837
7919
|
}
|
|
7838
7920
|
|
|
7839
|
-
var _path$
|
|
7921
|
+
var _path$w;
|
|
7840
7922
|
|
|
7841
|
-
function _extends$
|
|
7923
|
+
function _extends$y() { _extends$y = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$y.apply(this, arguments); }
|
|
7842
7924
|
|
|
7843
7925
|
function SvgXIcon(props) {
|
|
7844
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
7926
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$y({
|
|
7845
7927
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7846
7928
|
viewBox: "0 0 20 20",
|
|
7847
7929
|
fill: "currentColor"
|
|
7848
|
-
}, props), _path$
|
|
7930
|
+
}, props), _path$w || (_path$w = /*#__PURE__*/React__namespace.createElement("path", {
|
|
7849
7931
|
fill: "evenodd",
|
|
7850
7932
|
d: "M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",
|
|
7851
7933
|
clipRule: "evenodd"
|
|
7852
7934
|
})));
|
|
7853
7935
|
}
|
|
7854
7936
|
|
|
7855
|
-
var _path$
|
|
7937
|
+
var _path$v;
|
|
7856
7938
|
|
|
7857
|
-
function _extends$
|
|
7939
|
+
function _extends$x() { _extends$x = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$x.apply(this, arguments); }
|
|
7858
7940
|
|
|
7859
7941
|
function SvgXIconSolid(props) {
|
|
7860
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
7942
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$x({
|
|
7861
7943
|
className: "plc-w-4 plc-h-4",
|
|
7862
7944
|
fill: "currentColor",
|
|
7863
7945
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7864
7946
|
viewBox: "0 0 100 100"
|
|
7865
|
-
}, props), _path$
|
|
7947
|
+
}, props), _path$v || (_path$v = /*#__PURE__*/React__namespace.createElement("path", {
|
|
7866
7948
|
d: "M94.842 48.408c0 24.852-20.148 44.999-45.002 44.999-24.851 0-44.997-20.146-44.997-44.999 0-24.854 20.146-45 44.997-45 24.853 0 45.002 20.146 45.002 45zM71.073 64.841L54.73 48.497l16.344-16.344-4.979-4.979-16.343 16.345-16.343-16.344-4.799 4.799 16.344 16.344L28.61 64.661l4.979 4.978 16.344-16.344 16.343 16.344 4.797-4.798z"
|
|
7867
7949
|
})));
|
|
7868
7950
|
}
|
|
7869
7951
|
|
|
7870
|
-
var _path$
|
|
7952
|
+
var _path$u;
|
|
7871
7953
|
|
|
7872
|
-
function _extends$
|
|
7954
|
+
function _extends$w() { _extends$w = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$w.apply(this, arguments); }
|
|
7873
7955
|
|
|
7874
7956
|
function SvgExclamation(props) {
|
|
7875
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
7957
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$w({
|
|
7876
7958
|
className: "plc-w-4 plc-h-4 plc-mr-1",
|
|
7877
7959
|
xmlns: "http://www.w3.org/2000/svg",
|
|
7878
7960
|
viewBox: "0 0 20 20",
|
|
7879
7961
|
fill: "currentColor"
|
|
7880
|
-
}, props), _path$
|
|
7962
|
+
}, props), _path$u || (_path$u = /*#__PURE__*/React__namespace.createElement("path", {
|
|
7881
7963
|
fillRule: "evenodd",
|
|
7882
7964
|
d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z",
|
|
7883
7965
|
clipRule: "evenodd"
|
|
7884
7966
|
})));
|
|
7885
7967
|
}
|
|
7886
7968
|
|
|
7887
|
-
var _path$
|
|
7969
|
+
var _path$t, _path2$4;
|
|
7888
7970
|
|
|
7889
|
-
function _extends$
|
|
7971
|
+
function _extends$v() { _extends$v = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$v.apply(this, arguments); }
|
|
7890
7972
|
|
|
7891
7973
|
function SvgSpinner(props) {
|
|
7892
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
7974
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$v({
|
|
7893
7975
|
className: "plc-animate-spin",
|
|
7894
7976
|
viewBox: "0 0 24 24",
|
|
7895
7977
|
fill: "currentColor",
|
|
7896
7978
|
xmlns: "http://www.w3.org/2000/svg"
|
|
7897
|
-
}, props), _path$
|
|
7979
|
+
}, props), _path$t || (_path$t = /*#__PURE__*/React__namespace.createElement("path", {
|
|
7898
7980
|
opacity: 0.2,
|
|
7899
7981
|
fill: "evenodd",
|
|
7900
7982
|
clipRule: "evenodd",
|
|
@@ -8184,7 +8266,9 @@ const init$1 = () => {
|
|
|
8184
8266
|
return switchToAddressView();
|
|
8185
8267
|
});
|
|
8186
8268
|
} else {
|
|
8187
|
-
pelcroSubscribeButtonsByClass[j].addEventListener("click", () =>
|
|
8269
|
+
pelcroSubscribeButtonsByClass[j].addEventListener("click", () => {
|
|
8270
|
+
return switchView("subscription-options");
|
|
8271
|
+
});
|
|
8188
8272
|
}
|
|
8189
8273
|
}
|
|
8190
8274
|
}
|
|
@@ -8346,7 +8430,8 @@ function Link({
|
|
|
8346
8430
|
const init = () => {
|
|
8347
8431
|
const {
|
|
8348
8432
|
switchView,
|
|
8349
|
-
set
|
|
8433
|
+
set,
|
|
8434
|
+
setProductsList
|
|
8350
8435
|
} = usePelcro.getStore();
|
|
8351
8436
|
const entitlementsProtectedElements = document.querySelectorAll("[data-pelcro-entitlements]");
|
|
8352
8437
|
|
|
@@ -8397,7 +8482,8 @@ const init = () => {
|
|
|
8397
8482
|
}
|
|
8398
8483
|
|
|
8399
8484
|
notify.dismiss(NOTIFICATION_ID);
|
|
8400
|
-
|
|
8485
|
+
setProductsList(window.Pelcro.product.getByEntitlements(entitlements));
|
|
8486
|
+
switchView("plan-select");
|
|
8401
8487
|
}
|
|
8402
8488
|
}, "Subscribe"), "now to get full page access.")), {
|
|
8403
8489
|
className: "pelcro-notification-entitlement",
|
|
@@ -9202,7 +9288,7 @@ const PelcroModalController = ({
|
|
|
9202
9288
|
type
|
|
9203
9289
|
}) => (type === null || type === void 0 ? void 0 : type.viewId) === "dashboard-open"), React__default['default'].Children.map(children, child => child).find(({
|
|
9204
9290
|
type
|
|
9205
|
-
}) => (type === null || type === void 0 ? void 0 : type.viewId) === "notification"), view === "_plan-select-
|
|
9291
|
+
}) => (type === null || type === void 0 ? void 0 : type.viewId) === "notification"), view === "_plan-select-renew" && React__default['default'].Children.map(children, child => child).find(({
|
|
9206
9292
|
type
|
|
9207
9293
|
}) => (type === null || type === void 0 ? void 0 : type.viewId) === "plan-select"), React__default['default'].Children.map(children, child => child).find(({
|
|
9208
9294
|
type
|
|
@@ -9483,8 +9569,10 @@ const LOAD_PAYMENT_METHODS = "LOAD_PAYMENT_METHODS";
|
|
|
9483
9569
|
const GET_NEWSLETTERS_FETCH = "GET_NEWSLETTERS_FETCH";
|
|
9484
9570
|
const GET_NEWSLETTERS_SUCCESS = "GET_NEWSLETTERS_SUCCESS";
|
|
9485
9571
|
const SWITCH_TO_UPDATE = "SWITCH_TO_UPDATE";
|
|
9572
|
+
const SWITCH_TO_RENEW = "SWITCH_TO_RENEW";
|
|
9573
|
+
const SWITCH_TO_NEW = "SWITCH_TO_NEW";
|
|
9486
9574
|
|
|
9487
|
-
const initialState$
|
|
9575
|
+
const initialState$i = {
|
|
9488
9576
|
email: "",
|
|
9489
9577
|
password: "",
|
|
9490
9578
|
emailError: null,
|
|
@@ -9495,10 +9583,10 @@ const initialState$h = {
|
|
|
9495
9583
|
content: ""
|
|
9496
9584
|
}
|
|
9497
9585
|
};
|
|
9498
|
-
const store$
|
|
9586
|
+
const store$i = /*#__PURE__*/React.createContext(initialState$i);
|
|
9499
9587
|
const {
|
|
9500
|
-
Provider: Provider$
|
|
9501
|
-
} = store$
|
|
9588
|
+
Provider: Provider$i
|
|
9589
|
+
} = store$i;
|
|
9502
9590
|
|
|
9503
9591
|
const LoginContainer = ({
|
|
9504
9592
|
style,
|
|
@@ -9605,7 +9693,7 @@ const LoginContainer = ({
|
|
|
9605
9693
|
});
|
|
9606
9694
|
|
|
9607
9695
|
case RESET_LOGIN_FORM:
|
|
9608
|
-
return initialState$
|
|
9696
|
+
return initialState$i;
|
|
9609
9697
|
|
|
9610
9698
|
case DISABLE_LOGIN_BUTTON:
|
|
9611
9699
|
return lib_7({ ...state,
|
|
@@ -9623,12 +9711,12 @@ const LoginContainer = ({
|
|
|
9623
9711
|
default:
|
|
9624
9712
|
return state;
|
|
9625
9713
|
}
|
|
9626
|
-
}, initialState$
|
|
9714
|
+
}, initialState$i);
|
|
9627
9715
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
9628
9716
|
style: { ...style
|
|
9629
9717
|
},
|
|
9630
9718
|
className: `pelcro-container pelcro-login-container ${className}`
|
|
9631
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
9719
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$i, {
|
|
9632
9720
|
value: {
|
|
9633
9721
|
state,
|
|
9634
9722
|
dispatch
|
|
@@ -9636,12 +9724,12 @@ const LoginContainer = ({
|
|
|
9636
9724
|
}, children.length ? children.map((child, i) => {
|
|
9637
9725
|
if (child) {
|
|
9638
9726
|
return /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
9639
|
-
store: store$
|
|
9727
|
+
store: store$i,
|
|
9640
9728
|
key: i
|
|
9641
9729
|
});
|
|
9642
9730
|
}
|
|
9643
9731
|
}) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
9644
|
-
store: store$
|
|
9732
|
+
store: store$i
|
|
9645
9733
|
})));
|
|
9646
9734
|
};
|
|
9647
9735
|
|
|
@@ -9886,7 +9974,7 @@ const LoginButton = ({
|
|
|
9886
9974
|
buttonDisabled
|
|
9887
9975
|
},
|
|
9888
9976
|
dispatch
|
|
9889
|
-
} = React.useContext(store$
|
|
9977
|
+
} = React.useContext(store$i);
|
|
9890
9978
|
const {
|
|
9891
9979
|
t
|
|
9892
9980
|
} = useTranslation("login");
|
|
@@ -9907,23 +9995,23 @@ const LoginButton = ({
|
|
|
9907
9995
|
};
|
|
9908
9996
|
|
|
9909
9997
|
const LoginEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
9910
|
-
store: store$
|
|
9998
|
+
store: store$i
|
|
9911
9999
|
}, props));
|
|
9912
10000
|
|
|
9913
10001
|
const LoginPassword = props => /*#__PURE__*/React__default['default'].createElement(Password, Object.assign({
|
|
9914
|
-
store: store$
|
|
10002
|
+
store: store$i
|
|
9915
10003
|
}, props));
|
|
9916
10004
|
|
|
9917
|
-
var _path$
|
|
10005
|
+
var _path$s;
|
|
9918
10006
|
|
|
9919
|
-
function _extends$
|
|
10007
|
+
function _extends$u() { _extends$u = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$u.apply(this, arguments); }
|
|
9920
10008
|
|
|
9921
10009
|
function SvgCheck(props) {
|
|
9922
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
10010
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$u({
|
|
9923
10011
|
xmlns: "http://www.w3.org/2000/svg",
|
|
9924
10012
|
fill: "currentColor",
|
|
9925
10013
|
viewBox: "0 0 20 20"
|
|
9926
|
-
}, props), _path$
|
|
10014
|
+
}, props), _path$s || (_path$s = /*#__PURE__*/React__namespace.createElement("path", {
|
|
9927
10015
|
fillRule: "evenodd",
|
|
9928
10016
|
d: "M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",
|
|
9929
10017
|
clipRule: "evenodd"
|
|
@@ -9988,7 +10076,7 @@ var facebookLoginRenderProps = createCommonjsModule(function (module, exports) {
|
|
|
9988
10076
|
var FacebookLogin = unwrapExports(facebookLoginRenderProps);
|
|
9989
10077
|
facebookLoginRenderProps.FacebookLogin;
|
|
9990
10078
|
|
|
9991
|
-
const initialState$
|
|
10079
|
+
const initialState$h = {
|
|
9992
10080
|
email: "",
|
|
9993
10081
|
password: "",
|
|
9994
10082
|
emailError: null,
|
|
@@ -10005,10 +10093,10 @@ const initialState$g = {
|
|
|
10005
10093
|
content: ""
|
|
10006
10094
|
}
|
|
10007
10095
|
};
|
|
10008
|
-
const store$
|
|
10096
|
+
const store$h = /*#__PURE__*/React.createContext(initialState$h);
|
|
10009
10097
|
const {
|
|
10010
|
-
Provider: Provider$
|
|
10011
|
-
} = store$
|
|
10098
|
+
Provider: Provider$h
|
|
10099
|
+
} = store$h;
|
|
10012
10100
|
|
|
10013
10101
|
const RegisterContainer = ({
|
|
10014
10102
|
style,
|
|
@@ -10191,7 +10279,7 @@ const RegisterContainer = ({
|
|
|
10191
10279
|
});
|
|
10192
10280
|
|
|
10193
10281
|
case RESET_LOGIN_FORM:
|
|
10194
|
-
return initialState$
|
|
10282
|
+
return initialState$h;
|
|
10195
10283
|
|
|
10196
10284
|
case DISABLE_REGISTRATION_BUTTON:
|
|
10197
10285
|
return lib_7({ ...state,
|
|
@@ -10209,12 +10297,12 @@ const RegisterContainer = ({
|
|
|
10209
10297
|
default:
|
|
10210
10298
|
return state;
|
|
10211
10299
|
}
|
|
10212
|
-
}, initialState$
|
|
10300
|
+
}, initialState$h);
|
|
10213
10301
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
10214
10302
|
style: { ...style
|
|
10215
10303
|
},
|
|
10216
10304
|
className: `pelcro-container pelcro-register-container ${className}`
|
|
10217
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
10305
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$h, {
|
|
10218
10306
|
value: {
|
|
10219
10307
|
state,
|
|
10220
10308
|
dispatch
|
|
@@ -10222,12 +10310,12 @@ const RegisterContainer = ({
|
|
|
10222
10310
|
}, children.length ? children.map((child, i) => {
|
|
10223
10311
|
if (child) {
|
|
10224
10312
|
return /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
10225
|
-
store: store$
|
|
10313
|
+
store: store$h,
|
|
10226
10314
|
key: i
|
|
10227
10315
|
});
|
|
10228
10316
|
}
|
|
10229
10317
|
}) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
10230
|
-
store: store$
|
|
10318
|
+
store: store$h
|
|
10231
10319
|
})));
|
|
10232
10320
|
};
|
|
10233
10321
|
/**
|
|
@@ -10242,15 +10330,15 @@ function hasSecurityTokenEnabled$1() {
|
|
|
10242
10330
|
return hasSecuritySdkLoaded;
|
|
10243
10331
|
}
|
|
10244
10332
|
|
|
10245
|
-
var _path$
|
|
10333
|
+
var _path$r;
|
|
10246
10334
|
|
|
10247
|
-
function _extends$
|
|
10335
|
+
function _extends$t() { _extends$t = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$t.apply(this, arguments); }
|
|
10248
10336
|
|
|
10249
10337
|
function SvgFacebookLogo(props) {
|
|
10250
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
10338
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$t({
|
|
10251
10339
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10252
10340
|
viewBox: "88.428 12.828 107.543 207.085"
|
|
10253
|
-
}, props), _path$
|
|
10341
|
+
}, props), _path$r || (_path$r = /*#__PURE__*/React__namespace.createElement("path", {
|
|
10254
10342
|
d: "M158.232 219.912v-94.461h31.707l4.747-36.813h-36.454V65.134c0-10.658 2.96-17.922 18.245-17.922l19.494-.009V14.278c-3.373-.447-14.944-1.449-28.406-1.449-28.106 0-47.348 17.155-47.348 48.661v27.149H88.428v36.813h31.788v94.461l38.016-.001z",
|
|
10255
10343
|
fill: "#3c5a9a"
|
|
10256
10344
|
})));
|
|
@@ -10267,10 +10355,10 @@ const FacebookLoginButton = ({
|
|
|
10267
10355
|
const facebookLoginEnabled = (_window$Pelcro$site$r = window.Pelcro.site.read()) === null || _window$Pelcro$site$r === void 0 ? void 0 : _window$Pelcro$site$r.facebook_app_id;
|
|
10268
10356
|
const {
|
|
10269
10357
|
dispatch: loginDispatch
|
|
10270
|
-
} = React.useContext(store$
|
|
10358
|
+
} = React.useContext(store$i);
|
|
10271
10359
|
const {
|
|
10272
10360
|
dispatch: registerDispatch
|
|
10273
|
-
} = React.useContext(store$
|
|
10361
|
+
} = React.useContext(store$h);
|
|
10274
10362
|
|
|
10275
10363
|
const onSuccess = facebookUser => {
|
|
10276
10364
|
loginDispatch === null || loginDispatch === void 0 ? void 0 : loginDispatch({
|
|
@@ -10323,15 +10411,15 @@ var googleLogin = createCommonjsModule(function (module, exports) {
|
|
|
10323
10411
|
unwrapExports(googleLogin);
|
|
10324
10412
|
var googleLogin_1 = googleLogin.GoogleLogin;
|
|
10325
10413
|
|
|
10326
|
-
var _path$
|
|
10414
|
+
var _path$q, _path2$3, _path3$1, _path4;
|
|
10327
10415
|
|
|
10328
|
-
function _extends$
|
|
10416
|
+
function _extends$s() { _extends$s = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$s.apply(this, arguments); }
|
|
10329
10417
|
|
|
10330
10418
|
function SvgGoogleLogo(props) {
|
|
10331
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
10419
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$s({
|
|
10332
10420
|
viewBox: "0 0 24 24",
|
|
10333
10421
|
xmlns: "http://www.w3.org/2000/svg"
|
|
10334
|
-
}, props), _path$
|
|
10422
|
+
}, props), _path$q || (_path$q = /*#__PURE__*/React__namespace.createElement("path", {
|
|
10335
10423
|
fill: "#4285F4",
|
|
10336
10424
|
d: "M23.745 12.27c0-.79-.07-1.54-.19-2.27h-11.3v4.51h6.47c-.29 1.48-1.14 2.73-2.4 3.58v3h3.86c2.26-2.09 3.56-5.17 3.56-8.82z"
|
|
10337
10425
|
})), _path2$3 || (_path2$3 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
@@ -10357,10 +10445,10 @@ const GoogleLoginButton = ({
|
|
|
10357
10445
|
const googleLoginEnabled = (_window$Pelcro$site$r = window.Pelcro.site.read()) === null || _window$Pelcro$site$r === void 0 ? void 0 : _window$Pelcro$site$r.google_app_id;
|
|
10358
10446
|
const {
|
|
10359
10447
|
dispatch: loginDispatch
|
|
10360
|
-
} = React.useContext(store$
|
|
10448
|
+
} = React.useContext(store$i);
|
|
10361
10449
|
const {
|
|
10362
10450
|
dispatch: registerDispatch
|
|
10363
|
-
} = React.useContext(store$
|
|
10451
|
+
} = React.useContext(store$h);
|
|
10364
10452
|
|
|
10365
10453
|
const onSuccess = response => {
|
|
10366
10454
|
var _response$getAuthResp, _profile$getEmail, _profile$getGivenName, _profile$getFamilyNam, _profile$getEmail2, _profile$getGivenName2, _profile$getFamilyNam2;
|
|
@@ -10408,15 +10496,15 @@ const GoogleLoginButton = ({
|
|
|
10408
10496
|
}) : null;
|
|
10409
10497
|
};
|
|
10410
10498
|
|
|
10411
|
-
var _path$
|
|
10499
|
+
var _path$p;
|
|
10412
10500
|
|
|
10413
|
-
function _extends$
|
|
10501
|
+
function _extends$r() { _extends$r = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$r.apply(this, arguments); }
|
|
10414
10502
|
|
|
10415
10503
|
function SvgAuth0Logo(props) {
|
|
10416
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
10504
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$r({
|
|
10417
10505
|
viewBox: "0 0 256 285",
|
|
10418
10506
|
xmlns: "http://www.w3.org/2000/svg"
|
|
10419
|
-
}, props), _path$
|
|
10507
|
+
}, props), _path$p || (_path$p = /*#__PURE__*/React__namespace.createElement("path", {
|
|
10420
10508
|
d: "M220.412 0h-92.415l28.562 89.006h92.416l-74.77 53.077 28.57 89.511c48.128-35.06 63.854-88.12 46.208-142.588L220.413 0zM7.018 89.006h92.416L127.997 0H35.589L7.019 89.006c-17.655 54.468-1.92 107.529 46.207 142.588l28.563-89.51-74.77-53.078zm46.208 142.588l74.77 52.97 74.77-52.97-74.77-53.847-74.77 53.847z"
|
|
10421
10509
|
})));
|
|
10422
10510
|
}
|
|
@@ -10456,10 +10544,10 @@ const Auth0LoginButton = ({
|
|
|
10456
10544
|
}, [auth0Enabled, auth0Loaded]);
|
|
10457
10545
|
const {
|
|
10458
10546
|
dispatch: loginDispatch
|
|
10459
|
-
} = React.useContext(store$
|
|
10547
|
+
} = React.useContext(store$i);
|
|
10460
10548
|
const {
|
|
10461
10549
|
dispatch: registerDispatch
|
|
10462
|
-
} = React.useContext(store$
|
|
10550
|
+
} = React.useContext(store$h);
|
|
10463
10551
|
|
|
10464
10552
|
function handleClick() {
|
|
10465
10553
|
var _auth0InstanceRef$cur, _auth0InstanceRef$cur2, _auth0InstanceRef$cur3;
|
|
@@ -10592,15 +10680,15 @@ function LoginView(props) {
|
|
|
10592
10680
|
}, /*#__PURE__*/React__default['default'].createElement(GoogleLoginButton, null), /*#__PURE__*/React__default['default'].createElement(FacebookLoginButton, null), /*#__PURE__*/React__default['default'].createElement(Auth0LoginButton, null))))));
|
|
10593
10681
|
}
|
|
10594
10682
|
|
|
10595
|
-
var _path$
|
|
10683
|
+
var _path$o, _path2$2, _path3;
|
|
10596
10684
|
|
|
10597
|
-
function _extends$
|
|
10685
|
+
function _extends$q() { _extends$q = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$q.apply(this, arguments); }
|
|
10598
10686
|
|
|
10599
10687
|
function SvgPelcroAuthorship(props) {
|
|
10600
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
10688
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$q({
|
|
10601
10689
|
xmlns: "http://www.w3.org/2000/svg",
|
|
10602
10690
|
viewBox: "0 -80.652 497.072 179.991"
|
|
10603
|
-
}, props), _path$
|
|
10691
|
+
}, props), _path$o || (_path$o = /*#__PURE__*/React__namespace.createElement("path", {
|
|
10604
10692
|
fill: "none",
|
|
10605
10693
|
stroke: "#4a4a4a",
|
|
10606
10694
|
d: "M487.89 42.299c0 13.158-10.671 23.829-23.829 23.829H37.074c-13.162 0-23.832-10.671-23.832-23.829v-63.552c0-13.158 10.67-23.831 23.832-23.831H464.06c13.158 0 23.829 10.672 23.829 23.831l.001 63.552z"
|
|
@@ -10747,11 +10835,11 @@ function LoginModal({
|
|
|
10747
10835
|
LoginModal.viewId = "login";
|
|
10748
10836
|
|
|
10749
10837
|
const RegisterEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
10750
|
-
store: store$
|
|
10838
|
+
store: store$h
|
|
10751
10839
|
}, props));
|
|
10752
10840
|
|
|
10753
10841
|
const RegisterPassword = props => /*#__PURE__*/React__default['default'].createElement(Password, Object.assign({
|
|
10754
|
-
store: store$
|
|
10842
|
+
store: store$h
|
|
10755
10843
|
}, props));
|
|
10756
10844
|
|
|
10757
10845
|
const RegisterButton = ({
|
|
@@ -10771,7 +10859,7 @@ const RegisterButton = ({
|
|
|
10771
10859
|
buttonDisabled
|
|
10772
10860
|
},
|
|
10773
10861
|
dispatch
|
|
10774
|
-
} = React.useContext(store$
|
|
10862
|
+
} = React.useContext(store$h);
|
|
10775
10863
|
const {
|
|
10776
10864
|
t
|
|
10777
10865
|
} = useTranslation("register");
|
|
@@ -10909,7 +10997,7 @@ function FirstName({
|
|
|
10909
10997
|
}
|
|
10910
10998
|
|
|
10911
10999
|
const RegisterFirstName = props => /*#__PURE__*/React__default['default'].createElement(FirstName, Object.assign({
|
|
10912
|
-
store: store$
|
|
11000
|
+
store: store$h
|
|
10913
11001
|
}, props));
|
|
10914
11002
|
|
|
10915
11003
|
function LastName({
|
|
@@ -10940,7 +11028,7 @@ function LastName({
|
|
|
10940
11028
|
}
|
|
10941
11029
|
|
|
10942
11030
|
const RegisterLastName = props => /*#__PURE__*/React__default['default'].createElement(LastName, Object.assign({
|
|
10943
|
-
store: store$
|
|
11031
|
+
store: store$h
|
|
10944
11032
|
}, props));
|
|
10945
11033
|
|
|
10946
11034
|
/**
|
|
@@ -11064,7 +11152,7 @@ function TextInput({
|
|
|
11064
11152
|
|
|
11065
11153
|
const RegisterTextInput = props => {
|
|
11066
11154
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({}, props, {
|
|
11067
|
-
store: store$
|
|
11155
|
+
store: store$h
|
|
11068
11156
|
}));
|
|
11069
11157
|
};
|
|
11070
11158
|
|
|
@@ -11211,6 +11299,7 @@ function SelectModalWithHook(props) {
|
|
|
11211
11299
|
(_props$onDisplay = props.onDisplay) === null || _props$onDisplay === void 0 ? void 0 : _props$onDisplay.call(props);
|
|
11212
11300
|
}, []);
|
|
11213
11301
|
const {
|
|
11302
|
+
productsList,
|
|
11214
11303
|
isGift,
|
|
11215
11304
|
plan,
|
|
11216
11305
|
product,
|
|
@@ -11220,11 +11309,12 @@ function SelectModalWithHook(props) {
|
|
|
11220
11309
|
view,
|
|
11221
11310
|
set
|
|
11222
11311
|
} = usePelcro();
|
|
11223
|
-
const
|
|
11224
|
-
const entitlements = entitlementsProtectedElements.length > 0 ? getEntitlementsFromElem(entitlementsProtectedElements[0]) : null;
|
|
11312
|
+
const isRenewingSub = view === "_plan-select-renew";
|
|
11225
11313
|
return /*#__PURE__*/React__default['default'].createElement(SelectModalWithTrans, {
|
|
11314
|
+
productsList: productsList,
|
|
11226
11315
|
isGift: isGift,
|
|
11227
|
-
disableGifting: isRenewingGift,
|
|
11316
|
+
disableGifting: isRenewingGift || isRenewingSub,
|
|
11317
|
+
isRenewingSub: isRenewingSub,
|
|
11228
11318
|
plan: plan,
|
|
11229
11319
|
product: product,
|
|
11230
11320
|
onClose: () => {
|
|
@@ -11238,8 +11328,10 @@ function SelectModalWithHook(props) {
|
|
|
11238
11328
|
plan,
|
|
11239
11329
|
isGift
|
|
11240
11330
|
}),
|
|
11241
|
-
|
|
11242
|
-
|
|
11331
|
+
setSubscriptionIdToRenew: subscriptionIdToRenew => set({
|
|
11332
|
+
subscriptionIdToRenew
|
|
11333
|
+
}),
|
|
11334
|
+
setView: switchView
|
|
11243
11335
|
});
|
|
11244
11336
|
}
|
|
11245
11337
|
SelectModalWithHook.viewId = "plan-select";
|
|
@@ -11271,10 +11363,10 @@ class SelectModal extends React.Component {
|
|
|
11271
11363
|
});
|
|
11272
11364
|
}
|
|
11273
11365
|
|
|
11274
|
-
if (this.
|
|
11366
|
+
if (this.props.productsList.length === 1) {
|
|
11275
11367
|
this.setState({
|
|
11276
|
-
product: this.
|
|
11277
|
-
planList: this.
|
|
11368
|
+
product: this.props.productsList[0],
|
|
11369
|
+
planList: this.props.productsList[0].plans,
|
|
11278
11370
|
mode: "plan"
|
|
11279
11371
|
});
|
|
11280
11372
|
}
|
|
@@ -11291,7 +11383,7 @@ class SelectModal extends React.Component {
|
|
|
11291
11383
|
});
|
|
11292
11384
|
|
|
11293
11385
|
_defineProperty$3(this, "onProductChange", e => {
|
|
11294
|
-
const product =
|
|
11386
|
+
const product = productsList[e.target.selectedIndex];
|
|
11295
11387
|
this.setState({
|
|
11296
11388
|
product: product,
|
|
11297
11389
|
plan: product.plans[0]
|
|
@@ -11357,7 +11449,7 @@ class SelectModal extends React.Component {
|
|
|
11357
11449
|
|
|
11358
11450
|
_defineProperty$3(this, "renderProducts", () => {
|
|
11359
11451
|
const userDidSelectProduct = Boolean(this.state.mode === "plan");
|
|
11360
|
-
const productsToShow = userDidSelectProduct ? [this.state.product] : this.
|
|
11452
|
+
const productsToShow = userDidSelectProduct ? [this.state.product] : this.props.productsList;
|
|
11361
11453
|
return productsToShow.map((product, index) => {
|
|
11362
11454
|
return this.renderOneProduct(product, index);
|
|
11363
11455
|
});
|
|
@@ -11370,7 +11462,7 @@ class SelectModal extends React.Component {
|
|
|
11370
11462
|
return this.renderOneProduct(this.state.product);
|
|
11371
11463
|
}
|
|
11372
11464
|
|
|
11373
|
-
const [productsThatMatchArticleTag, allProductsMinusMatched] = productsWithMatchedTaggedFirst(); // Render normal products if there are no available matching products
|
|
11465
|
+
const [productsThatMatchArticleTag, allProductsMinusMatched] = productsWithMatchedTaggedFirst(this.props.productsList); // Render normal products if there are no available matching products
|
|
11374
11466
|
|
|
11375
11467
|
if (!(productsThatMatchArticleTag !== null && productsThatMatchArticleTag !== void 0 && productsThatMatchArticleTag.length)) {
|
|
11376
11468
|
return this.renderProducts();
|
|
@@ -11386,10 +11478,7 @@ class SelectModal extends React.Component {
|
|
|
11386
11478
|
className: "plc-text-sm plc-font-semibold"
|
|
11387
11479
|
}, this.locale("labels.restrictiveArticles.or")), allProductsMinusMatched.map((product, index) => this.renderOneProduct(product, index))));
|
|
11388
11480
|
|
|
11389
|
-
function productsWithMatchedTaggedFirst() {
|
|
11390
|
-
var _window$Pelcro$produc;
|
|
11391
|
-
|
|
11392
|
-
const allProducts = (_window$Pelcro$produc = window.Pelcro.product.list()) !== null && _window$Pelcro$produc !== void 0 ? _window$Pelcro$produc : [];
|
|
11481
|
+
function productsWithMatchedTaggedFirst(allProducts) {
|
|
11393
11482
|
const productsThatMatchArticleTag = window.Pelcro.product.getByMatchingPageTags();
|
|
11394
11483
|
const allProductsMinusMatched = allProducts.filter(product => !productsThatMatchArticleTag.some(matchedProduct => matchedProduct.id === product.id));
|
|
11395
11484
|
return [productsThatMatchArticleTag, allProductsMinusMatched];
|
|
@@ -11423,7 +11512,7 @@ class SelectModal extends React.Component {
|
|
|
11423
11512
|
_defineProperty$3(this, "selectProduct", e => {
|
|
11424
11513
|
const id = e.target.dataset.key;
|
|
11425
11514
|
|
|
11426
|
-
for (const product of this.
|
|
11515
|
+
for (const product of this.props.productsList) {
|
|
11427
11516
|
if (+product.id === +id) {
|
|
11428
11517
|
var _this$state$plan;
|
|
11429
11518
|
|
|
@@ -11476,6 +11565,14 @@ class SelectModal extends React.Component {
|
|
|
11476
11565
|
|
|
11477
11566
|
_defineProperty$3(this, "submitOption", () => {
|
|
11478
11567
|
this.props.setProductAndPlan(this.state.product, this.state.plan, this.state.isGift);
|
|
11568
|
+
|
|
11569
|
+
if (this.props.isRenewingSub) {
|
|
11570
|
+
var _matchingSub$id;
|
|
11571
|
+
|
|
11572
|
+
const matchingSub = window.Pelcro.subscription.list().find(sub => sub.plan.id === this.state.plan.id && sub.status === "active" && sub.cancel_at_period_end === 1);
|
|
11573
|
+
this.props.setSubscriptionIdToRenew((_matchingSub$id = matchingSub === null || matchingSub === void 0 ? void 0 : matchingSub.id) !== null && _matchingSub$id !== void 0 ? _matchingSub$id : null);
|
|
11574
|
+
}
|
|
11575
|
+
|
|
11479
11576
|
const {
|
|
11480
11577
|
product,
|
|
11481
11578
|
isGift
|
|
@@ -11513,8 +11610,7 @@ class SelectModal extends React.Component {
|
|
|
11513
11610
|
plan: {},
|
|
11514
11611
|
isGift: props.isGift,
|
|
11515
11612
|
disabled: true,
|
|
11516
|
-
mode: "product"
|
|
11517
|
-
productList: props.matchingEntitlements ? window.Pelcro.product.getByEntitlements(props.matchingEntitlements) : window.Pelcro.product.list()
|
|
11613
|
+
mode: "product"
|
|
11518
11614
|
};
|
|
11519
11615
|
this.product = this.props.product || window.Pelcro.paywall.getProduct();
|
|
11520
11616
|
this.locale = this.props.t;
|
|
@@ -11522,7 +11618,7 @@ class SelectModal extends React.Component {
|
|
|
11522
11618
|
}
|
|
11523
11619
|
|
|
11524
11620
|
render() {
|
|
11525
|
-
var
|
|
11621
|
+
var _this$props$productsL, _this$props$productsL2, _window$Pelcro$site$r;
|
|
11526
11622
|
|
|
11527
11623
|
const {
|
|
11528
11624
|
disableGifting
|
|
@@ -11556,7 +11652,7 @@ class SelectModal extends React.Component {
|
|
|
11556
11652
|
className: "plc-mb-6 plc-text-center plc-text-gray-900 pelcro-title-wrapper"
|
|
11557
11653
|
}, /*#__PURE__*/React__default['default'].createElement("h4", {
|
|
11558
11654
|
className: "plc-text-2xl plc-font-semibold"
|
|
11559
|
-
}, this.product && this.product.paywall.select_title || ((
|
|
11655
|
+
}, this.product && this.product.paywall.select_title || ((_this$props$productsL = this.props.productsList[0]) === null || _this$props$productsL === void 0 ? void 0 : _this$props$productsL.paywall.select_title)), /*#__PURE__*/React__default['default'].createElement("p", null, this.product && this.product.paywall.select_subtitle || ((_this$props$productsL2 = this.props.productsList[0]) === null || _this$props$productsL2 === void 0 ? void 0 : _this$props$productsL2.paywall.select_subtitle))), /*#__PURE__*/React__default['default'].createElement("div", {
|
|
11560
11656
|
className: "pelcro-select-products-wrapper"
|
|
11561
11657
|
}, (_window$Pelcro$site$r = window.Pelcro.site.read()) !== null && _window$Pelcro$site$r !== void 0 && _window$Pelcro$site$r.restrictive_paywall_metatags_enabled ? this.renderMatchingProductsFirst() : this.renderProducts()), this.state.mode === "plan" && /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement("div", {
|
|
11562
11658
|
className: "plc-overflow-y-scroll plc-max-h-72 pelcro-select-plans-wrapper"
|
|
@@ -13131,7 +13227,7 @@ class PaypalGateWay {
|
|
|
13131
13227
|
|
|
13132
13228
|
/** @type {PaymentStateType} */
|
|
13133
13229
|
|
|
13134
|
-
const initialState$
|
|
13230
|
+
const initialState$g = {
|
|
13135
13231
|
disableSubmit: false,
|
|
13136
13232
|
isLoading: false,
|
|
13137
13233
|
disableCouponButton: false,
|
|
@@ -13150,10 +13246,10 @@ const initialState$f = {
|
|
|
13150
13246
|
content: ""
|
|
13151
13247
|
}
|
|
13152
13248
|
};
|
|
13153
|
-
const store$
|
|
13249
|
+
const store$g = /*#__PURE__*/React.createContext(initialState$g);
|
|
13154
13250
|
const {
|
|
13155
|
-
Provider: Provider$
|
|
13156
|
-
} = store$
|
|
13251
|
+
Provider: Provider$g
|
|
13252
|
+
} = store$g;
|
|
13157
13253
|
|
|
13158
13254
|
const PaymentMethodContainerWithoutStripe = ({
|
|
13159
13255
|
style,
|
|
@@ -14193,21 +14289,21 @@ const PaymentMethodContainerWithoutStripe = ({
|
|
|
14193
14289
|
default:
|
|
14194
14290
|
return state;
|
|
14195
14291
|
}
|
|
14196
|
-
}, initialState$
|
|
14292
|
+
}, initialState$g);
|
|
14197
14293
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
14198
14294
|
style: { ...style
|
|
14199
14295
|
},
|
|
14200
14296
|
className: `pelcro-container pelcro-payment-container ${className}`
|
|
14201
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
14297
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$g, {
|
|
14202
14298
|
value: {
|
|
14203
14299
|
state,
|
|
14204
14300
|
dispatch
|
|
14205
14301
|
}
|
|
14206
14302
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
14207
|
-
store: store$
|
|
14303
|
+
store: store$g,
|
|
14208
14304
|
key: i
|
|
14209
14305
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
14210
|
-
store: store$
|
|
14306
|
+
store: store$g
|
|
14211
14307
|
})));
|
|
14212
14308
|
};
|
|
14213
14309
|
|
|
@@ -14229,7 +14325,7 @@ const PaymentMethodContainer = props => {
|
|
|
14229
14325
|
stripeAccount: window.Pelcro.site.read().account_id,
|
|
14230
14326
|
locale: getPageOrDefaultLanguage()
|
|
14231
14327
|
}, /*#__PURE__*/React__default['default'].createElement(es_11, null, /*#__PURE__*/React__default['default'].createElement(UnwrappedForm, Object.assign({
|
|
14232
|
-
store: store$
|
|
14328
|
+
store: store$g
|
|
14233
14329
|
}, props))));
|
|
14234
14330
|
}
|
|
14235
14331
|
|
|
@@ -14282,7 +14378,7 @@ const PelcroPaymentRequestButton = props => {
|
|
|
14282
14378
|
currentPlan,
|
|
14283
14379
|
updatedPrice
|
|
14284
14380
|
}
|
|
14285
|
-
} = React.useContext(store$
|
|
14381
|
+
} = React.useContext(store$g);
|
|
14286
14382
|
|
|
14287
14383
|
const updatePaymentRequest = () => {
|
|
14288
14384
|
// Make sure payment request is up to date, eg. user added a coupon code.
|
|
@@ -14342,7 +14438,7 @@ const DiscountedPrice = props => {
|
|
|
14342
14438
|
taxAmount,
|
|
14343
14439
|
percentOff
|
|
14344
14440
|
}
|
|
14345
|
-
} = React.useContext(store$
|
|
14441
|
+
} = React.useContext(store$g);
|
|
14346
14442
|
const {
|
|
14347
14443
|
order,
|
|
14348
14444
|
plan
|
|
@@ -14392,7 +14488,7 @@ const SubmitPaymentMethod = ({
|
|
|
14392
14488
|
isLoading,
|
|
14393
14489
|
updatedPrice
|
|
14394
14490
|
}
|
|
14395
|
-
} = React.useContext(store$
|
|
14491
|
+
} = React.useContext(store$g);
|
|
14396
14492
|
const planQuantity = (_plan$quantity = plan === null || plan === void 0 ? void 0 : plan.quantity) !== null && _plan$quantity !== void 0 ? _plan$quantity : 1;
|
|
14397
14493
|
const price = updatedPrice !== null && updatedPrice !== void 0 ? updatedPrice : plan === null || plan === void 0 ? void 0 : plan.amount;
|
|
14398
14494
|
const priceFormatted = getFormattedPriceByLocal(price * planQuantity, plan === null || plan === void 0 ? void 0 : plan.currency, getPageOrDefaultLanguage());
|
|
@@ -14413,17 +14509,17 @@ const SubmitPaymentMethod = ({
|
|
|
14413
14509
|
}, t("labels.pay"), " ", priceFormatted && priceFormatted) : t("labels.submit"));
|
|
14414
14510
|
};
|
|
14415
14511
|
|
|
14416
|
-
var _path$
|
|
14512
|
+
var _path$n;
|
|
14417
14513
|
|
|
14418
|
-
function _extends$
|
|
14514
|
+
function _extends$p() { _extends$p = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$p.apply(this, arguments); }
|
|
14419
14515
|
|
|
14420
14516
|
function SvgArrowLeft(props) {
|
|
14421
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
14517
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$p({
|
|
14422
14518
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14423
14519
|
fill: "none",
|
|
14424
14520
|
viewBox: "0 0 24 24",
|
|
14425
14521
|
stroke: "currentColor"
|
|
14426
|
-
}, props), _path$
|
|
14522
|
+
}, props), _path$n || (_path$n = /*#__PURE__*/React__namespace.createElement("path", {
|
|
14427
14523
|
strokeLinecap: "round",
|
|
14428
14524
|
strokeLinejoin: "round",
|
|
14429
14525
|
strokeWidth: 2,
|
|
@@ -14442,7 +14538,7 @@ const ApplyCouponButton = ({
|
|
|
14442
14538
|
disableCouponButton
|
|
14443
14539
|
},
|
|
14444
14540
|
dispatch
|
|
14445
|
-
} = React.useContext(store$
|
|
14541
|
+
} = React.useContext(store$g);
|
|
14446
14542
|
const {
|
|
14447
14543
|
t
|
|
14448
14544
|
} = useTranslation("checkoutForm");
|
|
@@ -14476,7 +14572,7 @@ const CouponCodeField = props => {
|
|
|
14476
14572
|
couponCode,
|
|
14477
14573
|
couponError
|
|
14478
14574
|
}
|
|
14479
|
-
} = React.useContext(store$
|
|
14575
|
+
} = React.useContext(store$g);
|
|
14480
14576
|
|
|
14481
14577
|
const onCouponCodeChange = e => {
|
|
14482
14578
|
dispatch({
|
|
@@ -14505,17 +14601,17 @@ const CouponCodeField = props => {
|
|
|
14505
14601
|
}, props));
|
|
14506
14602
|
};
|
|
14507
14603
|
|
|
14508
|
-
var _path$
|
|
14604
|
+
var _path$m;
|
|
14509
14605
|
|
|
14510
|
-
function _extends$
|
|
14606
|
+
function _extends$o() { _extends$o = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$o.apply(this, arguments); }
|
|
14511
14607
|
|
|
14512
14608
|
function SvgTicket(props) {
|
|
14513
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
14609
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$o({
|
|
14514
14610
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14515
14611
|
fill: "none",
|
|
14516
14612
|
viewBox: "0 0 24 24",
|
|
14517
14613
|
stroke: "currentColor"
|
|
14518
|
-
}, props), _path$
|
|
14614
|
+
}, props), _path$m || (_path$m = /*#__PURE__*/React__namespace.createElement("path", {
|
|
14519
14615
|
strokeLinecap: "round",
|
|
14520
14616
|
strokeLinejoin: "round",
|
|
14521
14617
|
strokeWidth: 2,
|
|
@@ -14532,7 +14628,7 @@ const CouponCode = ({
|
|
|
14532
14628
|
state: {
|
|
14533
14629
|
enableCouponField
|
|
14534
14630
|
}
|
|
14535
|
-
} = React.useContext(store$
|
|
14631
|
+
} = React.useContext(store$g);
|
|
14536
14632
|
const {
|
|
14537
14633
|
t
|
|
14538
14634
|
} = useTranslation("checkoutForm");
|
|
@@ -14789,7 +14885,7 @@ const PaypalSubscribeButton = props => {
|
|
|
14789
14885
|
const {
|
|
14790
14886
|
dispatch,
|
|
14791
14887
|
state
|
|
14792
|
-
} = React.useContext(store$
|
|
14888
|
+
} = React.useContext(store$g);
|
|
14793
14889
|
const {
|
|
14794
14890
|
product,
|
|
14795
14891
|
plan,
|
|
@@ -14875,16 +14971,16 @@ const BankRedirection = () => {
|
|
|
14875
14971
|
}));
|
|
14876
14972
|
};
|
|
14877
14973
|
|
|
14878
|
-
var _path$
|
|
14974
|
+
var _path$l;
|
|
14879
14975
|
|
|
14880
|
-
function _extends$
|
|
14976
|
+
function _extends$n() { _extends$n = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$n.apply(this, arguments); }
|
|
14881
14977
|
|
|
14882
14978
|
function SvgLock(props) {
|
|
14883
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
14979
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$n({
|
|
14884
14980
|
xmlns: "http://www.w3.org/2000/svg",
|
|
14885
14981
|
viewBox: "0 0 20 20",
|
|
14886
14982
|
fill: "currentColor"
|
|
14887
|
-
}, props), _path$
|
|
14983
|
+
}, props), _path$l || (_path$l = /*#__PURE__*/React__namespace.createElement("path", {
|
|
14888
14984
|
fillRule: "evenodd",
|
|
14889
14985
|
d: "M5 9V7a5 5 0 0110 0v2a2 2 0 012 2v5a2 2 0 01-2 2H5a2 2 0 01-2-2v-5a2 2 0 012-2zm8-2v2H7V7a3 3 0 016 0z",
|
|
14890
14986
|
clipRule: "evenodd"
|
|
@@ -14901,7 +14997,7 @@ const SelectedPaymentMethod = () => {
|
|
|
14901
14997
|
state: {
|
|
14902
14998
|
isLoading
|
|
14903
14999
|
}
|
|
14904
|
-
} = React.useContext(store$
|
|
15000
|
+
} = React.useContext(store$g);
|
|
14905
15001
|
const {
|
|
14906
15002
|
switchView,
|
|
14907
15003
|
selectedPaymentMethodId
|
|
@@ -14943,7 +15039,7 @@ const TaxAmount = () => {
|
|
|
14943
15039
|
state: {
|
|
14944
15040
|
taxAmount
|
|
14945
15041
|
}
|
|
14946
|
-
} = React.useContext(store$
|
|
15042
|
+
} = React.useContext(store$g);
|
|
14947
15043
|
const {
|
|
14948
15044
|
plan
|
|
14949
15045
|
} = usePelcro();
|
|
@@ -15106,12 +15202,12 @@ function SubscriptionRenewModal({
|
|
|
15106
15202
|
}
|
|
15107
15203
|
SubscriptionRenewModal.viewId = "subscription-renew";
|
|
15108
15204
|
|
|
15109
|
-
var _path$
|
|
15205
|
+
var _path$k;
|
|
15110
15206
|
|
|
15111
|
-
function _extends$
|
|
15207
|
+
function _extends$m() { _extends$m = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$m.apply(this, arguments); }
|
|
15112
15208
|
|
|
15113
15209
|
function SvgGift(props) {
|
|
15114
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
15210
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$m({
|
|
15115
15211
|
className: "plc-w-6 plc-h-6 plc-mr-2",
|
|
15116
15212
|
fill: "none",
|
|
15117
15213
|
stroke: "currentColor",
|
|
@@ -15120,7 +15216,7 @@ function SvgGift(props) {
|
|
|
15120
15216
|
strokeWidth: 2,
|
|
15121
15217
|
viewBox: "0 0 24 24",
|
|
15122
15218
|
xmlns: "http://www.w3.org/2000/svg"
|
|
15123
|
-
}, props), _path$
|
|
15219
|
+
}, props), _path$k || (_path$k = /*#__PURE__*/React__namespace.createElement("path", {
|
|
15124
15220
|
d: "M20 12v10H4V12M2 7h20v5H2zM12 22V7M12 7H7.5a2.5 2.5 0 010-5C11 2 12 7 12 7zM12 7h4.5a2.5 2.5 0 000-5C13 2 12 7 12 7z"
|
|
15125
15221
|
})));
|
|
15126
15222
|
}
|
|
@@ -15461,7 +15557,7 @@ class DefaultNewsLetter extends React.Component {
|
|
|
15461
15557
|
|
|
15462
15558
|
const NewsLetter = withTranslation("newsletter")(DefaultNewsLetter);
|
|
15463
15559
|
|
|
15464
|
-
const initialState$
|
|
15560
|
+
const initialState$f = {
|
|
15465
15561
|
didSubToNewslettersBefore: false,
|
|
15466
15562
|
newsletters: [],
|
|
15467
15563
|
isListLoading: true,
|
|
@@ -15471,10 +15567,10 @@ const initialState$e = {
|
|
|
15471
15567
|
content: ""
|
|
15472
15568
|
}
|
|
15473
15569
|
};
|
|
15474
|
-
const store$
|
|
15570
|
+
const store$f = /*#__PURE__*/React.createContext(initialState$f);
|
|
15475
15571
|
const {
|
|
15476
|
-
Provider: Provider$
|
|
15477
|
-
} = store$
|
|
15572
|
+
Provider: Provider$f
|
|
15573
|
+
} = store$f;
|
|
15478
15574
|
|
|
15479
15575
|
const NewsletterUpdateContainer = ({
|
|
15480
15576
|
style,
|
|
@@ -15587,7 +15683,7 @@ const NewsletterUpdateContainer = ({
|
|
|
15587
15683
|
default:
|
|
15588
15684
|
return state;
|
|
15589
15685
|
}
|
|
15590
|
-
}, initialState$
|
|
15686
|
+
}, initialState$f);
|
|
15591
15687
|
React.useEffect(() => {
|
|
15592
15688
|
const getUserNewsletters = () => {
|
|
15593
15689
|
var _window$Pelcro$user$r3, _window$Pelcro$user$r4;
|
|
@@ -15631,7 +15727,7 @@ const NewsletterUpdateContainer = ({
|
|
|
15631
15727
|
style: { ...style
|
|
15632
15728
|
},
|
|
15633
15729
|
className: `pelcro-container pelcro-newsletter-update-container ${className}`
|
|
15634
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
15730
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$f, {
|
|
15635
15731
|
value: {
|
|
15636
15732
|
state,
|
|
15637
15733
|
dispatch
|
|
@@ -15639,12 +15735,12 @@ const NewsletterUpdateContainer = ({
|
|
|
15639
15735
|
}, children.length ? children.map((child, i) => {
|
|
15640
15736
|
if (child) {
|
|
15641
15737
|
return /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
15642
|
-
store: store$
|
|
15738
|
+
store: store$f,
|
|
15643
15739
|
key: i
|
|
15644
15740
|
});
|
|
15645
15741
|
}
|
|
15646
15742
|
}) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
15647
|
-
store: store$
|
|
15743
|
+
store: store$f
|
|
15648
15744
|
})));
|
|
15649
15745
|
};
|
|
15650
15746
|
|
|
@@ -15659,7 +15755,7 @@ const NewsletterUpdateButton = ({
|
|
|
15659
15755
|
isSubmitting,
|
|
15660
15756
|
isListLoading
|
|
15661
15757
|
}
|
|
15662
|
-
} = React.useContext(store$
|
|
15758
|
+
} = React.useContext(store$f);
|
|
15663
15759
|
const {
|
|
15664
15760
|
t
|
|
15665
15761
|
} = useTranslation("newsletter");
|
|
@@ -15689,7 +15785,7 @@ const NewsletterUpdateList = () => {
|
|
|
15689
15785
|
newsletters,
|
|
15690
15786
|
isListLoading
|
|
15691
15787
|
}
|
|
15692
|
-
} = React.useContext(store$
|
|
15788
|
+
} = React.useContext(store$f);
|
|
15693
15789
|
|
|
15694
15790
|
if (isListLoading) {
|
|
15695
15791
|
return /*#__PURE__*/React__default['default'].createElement(Loader, {
|
|
@@ -15893,7 +15989,7 @@ function SubscriptionCreateModal({
|
|
|
15893
15989
|
SubscriptionCreateModal.viewId = "subscription-create";
|
|
15894
15990
|
|
|
15895
15991
|
var _window$Pelcro$user$r, _window$Pelcro$user$r2, _window$Pelcro$user$r3, _window$Pelcro$user$r4, _window$Pelcro$user$r5;
|
|
15896
|
-
const initialState$
|
|
15992
|
+
const initialState$e = {
|
|
15897
15993
|
email: (_window$Pelcro$user$r = window.Pelcro.user.read()) === null || _window$Pelcro$user$r === void 0 ? void 0 : _window$Pelcro$user$r.email,
|
|
15898
15994
|
firstName: (_window$Pelcro$user$r2 = window.Pelcro.user.read()) === null || _window$Pelcro$user$r2 === void 0 ? void 0 : _window$Pelcro$user$r2.first_name,
|
|
15899
15995
|
lastName: (_window$Pelcro$user$r3 = window.Pelcro.user.read()) === null || _window$Pelcro$user$r3 === void 0 ? void 0 : _window$Pelcro$user$r3.last_name,
|
|
@@ -15906,10 +16002,10 @@ const initialState$d = {
|
|
|
15906
16002
|
content: ""
|
|
15907
16003
|
}
|
|
15908
16004
|
};
|
|
15909
|
-
const store$
|
|
16005
|
+
const store$e = /*#__PURE__*/React.createContext(initialState$e);
|
|
15910
16006
|
const {
|
|
15911
|
-
Provider: Provider$
|
|
15912
|
-
} = store$
|
|
16007
|
+
Provider: Provider$e
|
|
16008
|
+
} = store$e;
|
|
15913
16009
|
|
|
15914
16010
|
const UserUpdateContainer = ({
|
|
15915
16011
|
style,
|
|
@@ -16041,27 +16137,27 @@ const UserUpdateContainer = ({
|
|
|
16041
16137
|
default:
|
|
16042
16138
|
return state;
|
|
16043
16139
|
}
|
|
16044
|
-
}, initialState$
|
|
16140
|
+
}, initialState$e);
|
|
16045
16141
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
16046
16142
|
style: { ...style
|
|
16047
16143
|
},
|
|
16048
16144
|
className: `pelcro-container pelcro-user-update-container ${className}`
|
|
16049
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
16145
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$e, {
|
|
16050
16146
|
value: {
|
|
16051
16147
|
state,
|
|
16052
16148
|
dispatch
|
|
16053
16149
|
}
|
|
16054
16150
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
16055
|
-
store: store$
|
|
16151
|
+
store: store$e,
|
|
16056
16152
|
key: i
|
|
16057
16153
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
16058
|
-
store: store$
|
|
16154
|
+
store: store$e
|
|
16059
16155
|
})));
|
|
16060
16156
|
};
|
|
16061
16157
|
|
|
16062
16158
|
const UserUpdateEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
16063
16159
|
disabled: true,
|
|
16064
|
-
store: store$
|
|
16160
|
+
store: store$e
|
|
16065
16161
|
}, props));
|
|
16066
16162
|
|
|
16067
16163
|
const UserUpdateButton = ({
|
|
@@ -16074,7 +16170,7 @@ const UserUpdateButton = ({
|
|
|
16074
16170
|
buttonDisabled
|
|
16075
16171
|
},
|
|
16076
16172
|
dispatch
|
|
16077
|
-
} = React.useContext(store$
|
|
16173
|
+
} = React.useContext(store$e);
|
|
16078
16174
|
const {
|
|
16079
16175
|
t
|
|
16080
16176
|
} = useTranslation("userEdit");
|
|
@@ -16091,11 +16187,11 @@ const UserUpdateButton = ({
|
|
|
16091
16187
|
};
|
|
16092
16188
|
|
|
16093
16189
|
const UserUpdateFirstName = props => /*#__PURE__*/React__default['default'].createElement(FirstName, Object.assign({
|
|
16094
|
-
store: store$
|
|
16190
|
+
store: store$e
|
|
16095
16191
|
}, props));
|
|
16096
16192
|
|
|
16097
16193
|
const UserUpdateLastName = props => /*#__PURE__*/React__default['default'].createElement(LastName, Object.assign({
|
|
16098
|
-
store: store$
|
|
16194
|
+
store: store$e
|
|
16099
16195
|
}, props));
|
|
16100
16196
|
|
|
16101
16197
|
function Phone({
|
|
@@ -16124,22 +16220,22 @@ function Phone({
|
|
|
16124
16220
|
}
|
|
16125
16221
|
|
|
16126
16222
|
const UserUpdatePhone = props => /*#__PURE__*/React__default['default'].createElement(Phone, Object.assign({
|
|
16127
|
-
store: store$
|
|
16223
|
+
store: store$e
|
|
16128
16224
|
}, props));
|
|
16129
16225
|
|
|
16130
16226
|
var userSolidIcon = "data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20class%3D%22plc-h-5%20plc-w-5%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22white%22%3E%20%20%3Cpath%20transform%3D%22translate%280%2C2%29%22%20fill-rule%3D%22evenodd%22%20d%3D%22M10%209a3%203%200%20100-6%203%203%200%20000%206zm-7%209a7%207%200%201114%200H3z%22%20clip-rule%3D%22evenodd%22%20%2F%3E%3C%2Fsvg%3E";
|
|
16131
16227
|
|
|
16132
|
-
var _path$
|
|
16228
|
+
var _path$j;
|
|
16133
16229
|
|
|
16134
|
-
function _extends$
|
|
16230
|
+
function _extends$l() { _extends$l = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$l.apply(this, arguments); }
|
|
16135
16231
|
|
|
16136
16232
|
function SvgEdit(props) {
|
|
16137
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
16233
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$l({
|
|
16138
16234
|
className: "plc-w-6 plc-h-6",
|
|
16139
16235
|
xmlns: "http://www.w3.org/2000/svg",
|
|
16140
16236
|
viewBox: "0 0 20 20",
|
|
16141
16237
|
fill: "currentColor"
|
|
16142
|
-
}, props), _path$
|
|
16238
|
+
}, props), _path$j || (_path$j = /*#__PURE__*/React__namespace.createElement("path", {
|
|
16143
16239
|
d: "M13.586 3.586a2 2 0 112.828 2.828l-.793.793-2.828-2.828.793-.793zm-2.207 2.207L3 14.172V17h2.828l8.38-8.379-2.83-2.828z"
|
|
16144
16240
|
})));
|
|
16145
16241
|
}
|
|
@@ -16271,16 +16367,16 @@ function DisplayName({
|
|
|
16271
16367
|
}
|
|
16272
16368
|
|
|
16273
16369
|
const UserUpdateDisplayName = props => /*#__PURE__*/React__default['default'].createElement(DisplayName, Object.assign({
|
|
16274
|
-
store: store$
|
|
16370
|
+
store: store$e
|
|
16275
16371
|
}, props));
|
|
16276
16372
|
|
|
16277
16373
|
const UserUpdateTextInput = props => {
|
|
16278
16374
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({}, props, {
|
|
16279
|
-
store: store$
|
|
16375
|
+
store: store$e
|
|
16280
16376
|
}));
|
|
16281
16377
|
};
|
|
16282
16378
|
|
|
16283
|
-
const initialState$
|
|
16379
|
+
const initialState$d = {
|
|
16284
16380
|
isSubmitting: false,
|
|
16285
16381
|
firstName: "",
|
|
16286
16382
|
firstNameError: "",
|
|
@@ -16305,10 +16401,10 @@ const initialState$c = {
|
|
|
16305
16401
|
content: ""
|
|
16306
16402
|
}
|
|
16307
16403
|
};
|
|
16308
|
-
const store$
|
|
16404
|
+
const store$d = /*#__PURE__*/React.createContext(initialState$d);
|
|
16309
16405
|
const {
|
|
16310
|
-
Provider: Provider$
|
|
16311
|
-
} = store$
|
|
16406
|
+
Provider: Provider$d
|
|
16407
|
+
} = store$d;
|
|
16312
16408
|
|
|
16313
16409
|
const getNewlyCreatedAddress = addresses => addresses[addresses.length - 1];
|
|
16314
16410
|
|
|
@@ -16515,7 +16611,7 @@ const AddressCreateContainer = ({
|
|
|
16515
16611
|
default:
|
|
16516
16612
|
return state;
|
|
16517
16613
|
}
|
|
16518
|
-
}, initialState$
|
|
16614
|
+
}, initialState$d);
|
|
16519
16615
|
React.useEffect(() => {
|
|
16520
16616
|
const getStates = () => {
|
|
16521
16617
|
dispatch({
|
|
@@ -16547,16 +16643,16 @@ const AddressCreateContainer = ({
|
|
|
16547
16643
|
style: { ...style
|
|
16548
16644
|
},
|
|
16549
16645
|
className: `pelcro-container pelcro-address-create-container ${className}`
|
|
16550
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
16646
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$d, {
|
|
16551
16647
|
value: {
|
|
16552
16648
|
state,
|
|
16553
16649
|
dispatch
|
|
16554
16650
|
}
|
|
16555
16651
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
16556
|
-
store: store$
|
|
16652
|
+
store: store$d,
|
|
16557
16653
|
key: i
|
|
16558
16654
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
16559
|
-
store: store$
|
|
16655
|
+
store: store$d
|
|
16560
16656
|
})));
|
|
16561
16657
|
};
|
|
16562
16658
|
|
|
@@ -16567,7 +16663,7 @@ function AddressCreateFirstName(props) {
|
|
|
16567
16663
|
firstName,
|
|
16568
16664
|
firstNameError
|
|
16569
16665
|
}
|
|
16570
|
-
} = React.useContext(store$
|
|
16666
|
+
} = React.useContext(store$d);
|
|
16571
16667
|
|
|
16572
16668
|
const handleBlur = () => {
|
|
16573
16669
|
return dispatch({
|
|
@@ -16610,7 +16706,7 @@ function AddressCreateLastName(props) {
|
|
|
16610
16706
|
lastName,
|
|
16611
16707
|
lastNameError
|
|
16612
16708
|
}
|
|
16613
|
-
} = React.useContext(store$
|
|
16709
|
+
} = React.useContext(store$d);
|
|
16614
16710
|
|
|
16615
16711
|
const handleBlur = () => {
|
|
16616
16712
|
return dispatch({
|
|
@@ -16653,7 +16749,7 @@ function AddressCreateLine1(props) {
|
|
|
16653
16749
|
line1,
|
|
16654
16750
|
line1Error
|
|
16655
16751
|
}
|
|
16656
|
-
} = React.useContext(store$
|
|
16752
|
+
} = React.useContext(store$d);
|
|
16657
16753
|
|
|
16658
16754
|
const handleBlur = () => {
|
|
16659
16755
|
return dispatch({
|
|
@@ -16696,7 +16792,7 @@ function AddressCreateCity(props) {
|
|
|
16696
16792
|
city,
|
|
16697
16793
|
cityError
|
|
16698
16794
|
}
|
|
16699
|
-
} = React.useContext(store$
|
|
16795
|
+
} = React.useContext(store$d);
|
|
16700
16796
|
|
|
16701
16797
|
const handleBlur = () => {
|
|
16702
16798
|
return dispatch({
|
|
@@ -16739,7 +16835,7 @@ function AddressCreatePostalCode(props) {
|
|
|
16739
16835
|
postalCode,
|
|
16740
16836
|
postalCodeError
|
|
16741
16837
|
}
|
|
16742
|
-
} = React.useContext(store$
|
|
16838
|
+
} = React.useContext(store$d);
|
|
16743
16839
|
|
|
16744
16840
|
const handleBlur = () => {
|
|
16745
16841
|
return dispatch({
|
|
@@ -16785,7 +16881,7 @@ const AddressCreateSubmit = ({
|
|
|
16785
16881
|
state: {
|
|
16786
16882
|
isSubmitting
|
|
16787
16883
|
}
|
|
16788
|
-
} = React.useContext(store$
|
|
16884
|
+
} = React.useContext(store$d);
|
|
16789
16885
|
const {
|
|
16790
16886
|
t
|
|
16791
16887
|
} = useTranslation("address");
|
|
@@ -16896,7 +16992,7 @@ function CountrySelect({
|
|
|
16896
16992
|
}
|
|
16897
16993
|
|
|
16898
16994
|
const AddressCreateCountrySelect = props => /*#__PURE__*/React__default['default'].createElement(CountrySelect, Object.assign({
|
|
16899
|
-
store: store$
|
|
16995
|
+
store: store$d
|
|
16900
16996
|
}, props));
|
|
16901
16997
|
|
|
16902
16998
|
function StateSelect({
|
|
@@ -16984,7 +17080,7 @@ function StateSelect({
|
|
|
16984
17080
|
}
|
|
16985
17081
|
|
|
16986
17082
|
const AddressCreateStateSelect = props => /*#__PURE__*/React__default['default'].createElement(StateSelect, Object.assign({
|
|
16987
|
-
store: store$
|
|
17083
|
+
store: store$d
|
|
16988
17084
|
}, props));
|
|
16989
17085
|
|
|
16990
17086
|
const AddressCreateView = props => {
|
|
@@ -17089,18 +17185,18 @@ AddressCreateModal.viewId = "address-create";
|
|
|
17089
17185
|
|
|
17090
17186
|
const AddressCreateTextInput = props => {
|
|
17091
17187
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({}, props, {
|
|
17092
|
-
store: store$
|
|
17188
|
+
store: store$d
|
|
17093
17189
|
}));
|
|
17094
17190
|
};
|
|
17095
17191
|
|
|
17096
17192
|
const AddressCreateLine2 = props => {
|
|
17097
17193
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({
|
|
17098
17194
|
fieldName: "line2",
|
|
17099
|
-
store: store$
|
|
17195
|
+
store: store$d
|
|
17100
17196
|
}, props));
|
|
17101
17197
|
};
|
|
17102
17198
|
|
|
17103
|
-
const initialState$
|
|
17199
|
+
const initialState$c = {
|
|
17104
17200
|
isSubmitting: false,
|
|
17105
17201
|
firstName: "",
|
|
17106
17202
|
firstNameError: "",
|
|
@@ -17125,10 +17221,10 @@ const initialState$b = {
|
|
|
17125
17221
|
content: ""
|
|
17126
17222
|
}
|
|
17127
17223
|
};
|
|
17128
|
-
const store$
|
|
17224
|
+
const store$c = /*#__PURE__*/React.createContext(initialState$c);
|
|
17129
17225
|
const {
|
|
17130
|
-
Provider: Provider$
|
|
17131
|
-
} = store$
|
|
17226
|
+
Provider: Provider$c
|
|
17227
|
+
} = store$c;
|
|
17132
17228
|
|
|
17133
17229
|
const AddressUpdateContainer = ({
|
|
17134
17230
|
style,
|
|
@@ -17180,7 +17276,7 @@ const AddressUpdateContainer = ({
|
|
|
17180
17276
|
const thisAddress = addresses[address];
|
|
17181
17277
|
|
|
17182
17278
|
if (+thisAddress.id === +addressId) {
|
|
17183
|
-
const newState = { ...initialState$
|
|
17279
|
+
const newState = { ...initialState$c,
|
|
17184
17280
|
firstName: thisAddress.first_name,
|
|
17185
17281
|
lastName: thisAddress.last_name,
|
|
17186
17282
|
line1: thisAddress.line1,
|
|
@@ -17313,7 +17409,7 @@ const AddressUpdateContainer = ({
|
|
|
17313
17409
|
default:
|
|
17314
17410
|
return state;
|
|
17315
17411
|
}
|
|
17316
|
-
}, initialState$
|
|
17412
|
+
}, initialState$c);
|
|
17317
17413
|
React.useEffect(() => {
|
|
17318
17414
|
const getStates = () => {
|
|
17319
17415
|
dispatch({
|
|
@@ -17345,21 +17441,21 @@ const AddressUpdateContainer = ({
|
|
|
17345
17441
|
style: { ...style
|
|
17346
17442
|
},
|
|
17347
17443
|
className: `pelcro-container pelcro-address-update-container ${className}`
|
|
17348
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
17444
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$c, {
|
|
17349
17445
|
value: {
|
|
17350
17446
|
state,
|
|
17351
17447
|
dispatch
|
|
17352
17448
|
}
|
|
17353
17449
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
17354
|
-
store: store$
|
|
17450
|
+
store: store$c,
|
|
17355
17451
|
key: i
|
|
17356
17452
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
17357
|
-
store: store$
|
|
17453
|
+
store: store$c
|
|
17358
17454
|
})));
|
|
17359
17455
|
};
|
|
17360
17456
|
|
|
17361
17457
|
const AddressUpdateCountrySelect = props => /*#__PURE__*/React__default['default'].createElement(CountrySelect, Object.assign({
|
|
17362
|
-
store: store$
|
|
17458
|
+
store: store$c
|
|
17363
17459
|
}, props));
|
|
17364
17460
|
|
|
17365
17461
|
function AddressUpdateFirstName(props) {
|
|
@@ -17369,7 +17465,7 @@ function AddressUpdateFirstName(props) {
|
|
|
17369
17465
|
firstName,
|
|
17370
17466
|
firstNameError
|
|
17371
17467
|
}
|
|
17372
|
-
} = React.useContext(store$
|
|
17468
|
+
} = React.useContext(store$c);
|
|
17373
17469
|
|
|
17374
17470
|
const handleBlur = () => {
|
|
17375
17471
|
return dispatch({
|
|
@@ -17412,7 +17508,7 @@ function AddressUpdateLastName(props) {
|
|
|
17412
17508
|
lastName,
|
|
17413
17509
|
lastNameError
|
|
17414
17510
|
}
|
|
17415
|
-
} = React.useContext(store$
|
|
17511
|
+
} = React.useContext(store$c);
|
|
17416
17512
|
|
|
17417
17513
|
const handleBlur = () => {
|
|
17418
17514
|
return dispatch({
|
|
@@ -17455,7 +17551,7 @@ function AddressUpdateLine1(props) {
|
|
|
17455
17551
|
line1,
|
|
17456
17552
|
line1Error
|
|
17457
17553
|
}
|
|
17458
|
-
} = React.useContext(store$
|
|
17554
|
+
} = React.useContext(store$c);
|
|
17459
17555
|
|
|
17460
17556
|
const handleBlur = () => {
|
|
17461
17557
|
return dispatch({
|
|
@@ -17495,7 +17591,7 @@ const AddressUpdateLine2 = props => {
|
|
|
17495
17591
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({
|
|
17496
17592
|
fieldName: "line2"
|
|
17497
17593
|
}, props, {
|
|
17498
|
-
store: store$
|
|
17594
|
+
store: store$c
|
|
17499
17595
|
}));
|
|
17500
17596
|
};
|
|
17501
17597
|
|
|
@@ -17506,7 +17602,7 @@ function AddressUpdateCity(props) {
|
|
|
17506
17602
|
city,
|
|
17507
17603
|
cityError
|
|
17508
17604
|
}
|
|
17509
|
-
} = React.useContext(store$
|
|
17605
|
+
} = React.useContext(store$c);
|
|
17510
17606
|
|
|
17511
17607
|
const handleBlur = () => {
|
|
17512
17608
|
return dispatch({
|
|
@@ -17549,7 +17645,7 @@ function AddressUpdatePostalCode(props) {
|
|
|
17549
17645
|
postalCode,
|
|
17550
17646
|
postalCodeError
|
|
17551
17647
|
}
|
|
17552
|
-
} = React.useContext(store$
|
|
17648
|
+
} = React.useContext(store$c);
|
|
17553
17649
|
|
|
17554
17650
|
const handleBlur = () => {
|
|
17555
17651
|
return dispatch({
|
|
@@ -17595,7 +17691,7 @@ const AddressUpdateSubmit = ({
|
|
|
17595
17691
|
state: {
|
|
17596
17692
|
isSubmitting
|
|
17597
17693
|
}
|
|
17598
|
-
} = React.useContext(store$
|
|
17694
|
+
} = React.useContext(store$c);
|
|
17599
17695
|
const {
|
|
17600
17696
|
t
|
|
17601
17697
|
} = useTranslation("address");
|
|
@@ -17611,7 +17707,7 @@ const AddressUpdateSubmit = ({
|
|
|
17611
17707
|
};
|
|
17612
17708
|
|
|
17613
17709
|
const AddressUpdateStateSelect = props => /*#__PURE__*/React__default['default'].createElement(StateSelect, Object.assign({
|
|
17614
|
-
store: store$
|
|
17710
|
+
store: store$c
|
|
17615
17711
|
}, props));
|
|
17616
17712
|
|
|
17617
17713
|
const AddressUpdateView = props => {
|
|
@@ -17694,7 +17790,7 @@ AddressUpdateModal.viewId = "address-edit";
|
|
|
17694
17790
|
|
|
17695
17791
|
const AddressUpdateTextInput = props => {
|
|
17696
17792
|
return /*#__PURE__*/React__default['default'].createElement(TextInput, Object.assign({}, props, {
|
|
17697
|
-
store: store$
|
|
17793
|
+
store: store$c
|
|
17698
17794
|
}));
|
|
17699
17795
|
};
|
|
17700
17796
|
|
|
@@ -17777,7 +17873,7 @@ const PaymentMethodUpdateModal = props => {
|
|
|
17777
17873
|
};
|
|
17778
17874
|
PaymentMethodUpdateModal.viewId = "payment-method-update";
|
|
17779
17875
|
|
|
17780
|
-
const initialState$
|
|
17876
|
+
const initialState$b = {
|
|
17781
17877
|
email: "",
|
|
17782
17878
|
password: "",
|
|
17783
17879
|
passwordError: null,
|
|
@@ -17790,10 +17886,10 @@ const initialState$a = {
|
|
|
17790
17886
|
content: ""
|
|
17791
17887
|
}
|
|
17792
17888
|
};
|
|
17793
|
-
const store$
|
|
17889
|
+
const store$b = /*#__PURE__*/React.createContext(initialState$b);
|
|
17794
17890
|
const {
|
|
17795
|
-
Provider: Provider$
|
|
17796
|
-
} = store$
|
|
17891
|
+
Provider: Provider$b
|
|
17892
|
+
} = store$b;
|
|
17797
17893
|
|
|
17798
17894
|
const PasswordResetContainer = ({
|
|
17799
17895
|
style,
|
|
@@ -17850,7 +17946,7 @@ const PasswordResetContainer = ({
|
|
|
17850
17946
|
type: SET_EMAIL,
|
|
17851
17947
|
payload: window.Pelcro.helpers.getURLParameter("email")
|
|
17852
17948
|
});
|
|
17853
|
-
initialState$
|
|
17949
|
+
initialState$b.email = window.Pelcro.helpers.getURLParameter("email");
|
|
17854
17950
|
dispatch({
|
|
17855
17951
|
type: SET_TOKEN,
|
|
17856
17952
|
payload: window.Pelcro.helpers.getURLParameter("token")
|
|
@@ -17910,26 +18006,26 @@ const PasswordResetContainer = ({
|
|
|
17910
18006
|
default:
|
|
17911
18007
|
return state;
|
|
17912
18008
|
}
|
|
17913
|
-
}, initialState$
|
|
18009
|
+
}, initialState$b);
|
|
17914
18010
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
17915
18011
|
style: { ...style
|
|
17916
18012
|
},
|
|
17917
18013
|
className: `pelcro-container pelcro-password-reset-container ${className}`
|
|
17918
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
18014
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$b, {
|
|
17919
18015
|
value: {
|
|
17920
18016
|
state,
|
|
17921
18017
|
dispatch
|
|
17922
18018
|
}
|
|
17923
18019
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
17924
|
-
store: store$
|
|
18020
|
+
store: store$b,
|
|
17925
18021
|
key: i
|
|
17926
18022
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
17927
|
-
store: store$
|
|
18023
|
+
store: store$b
|
|
17928
18024
|
})));
|
|
17929
18025
|
};
|
|
17930
18026
|
|
|
17931
18027
|
const PasswordResetPassword = props => /*#__PURE__*/React__default['default'].createElement(Password, Object.assign({
|
|
17932
|
-
store: store$
|
|
18028
|
+
store: store$b
|
|
17933
18029
|
}, props));
|
|
17934
18030
|
|
|
17935
18031
|
const PasswordResetButton = ({
|
|
@@ -17942,7 +18038,7 @@ const PasswordResetButton = ({
|
|
|
17942
18038
|
buttonDisabled
|
|
17943
18039
|
},
|
|
17944
18040
|
dispatch
|
|
17945
|
-
} = React.useContext(store$
|
|
18041
|
+
} = React.useContext(store$b);
|
|
17946
18042
|
const {
|
|
17947
18043
|
t
|
|
17948
18044
|
} = useTranslation("passwordReset");
|
|
@@ -17959,14 +18055,14 @@ const PasswordResetButton = ({
|
|
|
17959
18055
|
};
|
|
17960
18056
|
|
|
17961
18057
|
const PasswordResetEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
17962
|
-
store: store$
|
|
18058
|
+
store: store$b
|
|
17963
18059
|
}, props, {
|
|
17964
18060
|
value: window.Pelcro.helpers.getURLParameter("email"),
|
|
17965
18061
|
disabled: true
|
|
17966
18062
|
}));
|
|
17967
18063
|
|
|
17968
18064
|
const PasswordResetConfirmPassword = props => /*#__PURE__*/React__default['default'].createElement(ConfirmPassword, Object.assign({
|
|
17969
|
-
store: store$
|
|
18065
|
+
store: store$b
|
|
17970
18066
|
}, props));
|
|
17971
18067
|
|
|
17972
18068
|
const PasswordResetView = props => {
|
|
@@ -18018,7 +18114,7 @@ const PasswordResetModal = ({
|
|
|
18018
18114
|
};
|
|
18019
18115
|
PasswordResetModal.viewId = "password-reset";
|
|
18020
18116
|
|
|
18021
|
-
const initialState$
|
|
18117
|
+
const initialState$a = {
|
|
18022
18118
|
email: "",
|
|
18023
18119
|
emailError: null,
|
|
18024
18120
|
buttonDisabled: false,
|
|
@@ -18027,10 +18123,10 @@ const initialState$9 = {
|
|
|
18027
18123
|
content: ""
|
|
18028
18124
|
}
|
|
18029
18125
|
};
|
|
18030
|
-
const store$
|
|
18126
|
+
const store$a = /*#__PURE__*/React.createContext(initialState$a);
|
|
18031
18127
|
const {
|
|
18032
|
-
Provider: Provider$
|
|
18033
|
-
} = store$
|
|
18128
|
+
Provider: Provider$a
|
|
18129
|
+
} = store$a;
|
|
18034
18130
|
|
|
18035
18131
|
const PasswordForgotContainer = ({
|
|
18036
18132
|
style,
|
|
@@ -18108,21 +18204,21 @@ const PasswordForgotContainer = ({
|
|
|
18108
18204
|
default:
|
|
18109
18205
|
return state;
|
|
18110
18206
|
}
|
|
18111
|
-
}, initialState$
|
|
18207
|
+
}, initialState$a);
|
|
18112
18208
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
18113
18209
|
style: { ...style
|
|
18114
18210
|
},
|
|
18115
18211
|
className: `pelcro-container pelcro-password-forgot-container ${className}`
|
|
18116
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
18212
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$a, {
|
|
18117
18213
|
value: {
|
|
18118
18214
|
state,
|
|
18119
18215
|
dispatch
|
|
18120
18216
|
}
|
|
18121
18217
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
18122
|
-
store: store$
|
|
18218
|
+
store: store$a,
|
|
18123
18219
|
key: i
|
|
18124
18220
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
18125
|
-
store: store$
|
|
18221
|
+
store: store$a
|
|
18126
18222
|
})));
|
|
18127
18223
|
};
|
|
18128
18224
|
|
|
@@ -18138,7 +18234,7 @@ const PasswordForgotButton = ({
|
|
|
18138
18234
|
emailError
|
|
18139
18235
|
},
|
|
18140
18236
|
dispatch
|
|
18141
|
-
} = React.useContext(store$
|
|
18237
|
+
} = React.useContext(store$a);
|
|
18142
18238
|
const {
|
|
18143
18239
|
t
|
|
18144
18240
|
} = useTranslation("passwordForgot");
|
|
@@ -18159,7 +18255,7 @@ const PasswordForgotButton = ({
|
|
|
18159
18255
|
};
|
|
18160
18256
|
|
|
18161
18257
|
const PasswordForgotEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
18162
|
-
store: store$
|
|
18258
|
+
store: store$a
|
|
18163
18259
|
}, props));
|
|
18164
18260
|
|
|
18165
18261
|
const PasswordForgotView = props => {
|
|
@@ -18209,7 +18305,7 @@ const PasswordForgotModal = ({
|
|
|
18209
18305
|
};
|
|
18210
18306
|
PasswordForgotModal.viewId = "password-forgot";
|
|
18211
18307
|
|
|
18212
|
-
const initialState$
|
|
18308
|
+
const initialState$9 = {
|
|
18213
18309
|
currentPassword: "",
|
|
18214
18310
|
newPassword: "",
|
|
18215
18311
|
confirmNewPassword: "",
|
|
@@ -18223,10 +18319,10 @@ const initialState$8 = {
|
|
|
18223
18319
|
content: ""
|
|
18224
18320
|
}
|
|
18225
18321
|
};
|
|
18226
|
-
const store$
|
|
18322
|
+
const store$9 = /*#__PURE__*/React.createContext(initialState$9);
|
|
18227
18323
|
const {
|
|
18228
|
-
Provider: Provider$
|
|
18229
|
-
} = store$
|
|
18324
|
+
Provider: Provider$9
|
|
18325
|
+
} = store$9;
|
|
18230
18326
|
const PasswordChangeContainer = ({
|
|
18231
18327
|
style,
|
|
18232
18328
|
className = "",
|
|
@@ -18378,21 +18474,21 @@ const PasswordChangeContainer = ({
|
|
|
18378
18474
|
default:
|
|
18379
18475
|
return state;
|
|
18380
18476
|
}
|
|
18381
|
-
}, initialState$
|
|
18477
|
+
}, initialState$9);
|
|
18382
18478
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
18383
18479
|
style: { ...style
|
|
18384
18480
|
},
|
|
18385
18481
|
className: `pelcro-container pelcro-password-change-container ${className}`
|
|
18386
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
18482
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$9, {
|
|
18387
18483
|
value: {
|
|
18388
18484
|
state,
|
|
18389
18485
|
dispatch
|
|
18390
18486
|
}
|
|
18391
18487
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
18392
|
-
store: store$
|
|
18488
|
+
store: store$9,
|
|
18393
18489
|
key: i
|
|
18394
18490
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
18395
|
-
store: store$
|
|
18491
|
+
store: store$9
|
|
18396
18492
|
})));
|
|
18397
18493
|
};
|
|
18398
18494
|
|
|
@@ -18403,7 +18499,7 @@ function PasswordChangeCurrentPassword(props) {
|
|
|
18403
18499
|
currentPassword,
|
|
18404
18500
|
currentPasswordError
|
|
18405
18501
|
}
|
|
18406
|
-
} = React.useContext(store$
|
|
18502
|
+
} = React.useContext(store$9);
|
|
18407
18503
|
const handleBlur = React.useCallback(() => {
|
|
18408
18504
|
return dispatch({
|
|
18409
18505
|
type: VALIDATE_PASSWORD
|
|
@@ -18437,7 +18533,7 @@ function PasswordChangeNewPassword(props) {
|
|
|
18437
18533
|
newPassword,
|
|
18438
18534
|
newPasswordError
|
|
18439
18535
|
}
|
|
18440
|
-
} = React.useContext(store$
|
|
18536
|
+
} = React.useContext(store$9);
|
|
18441
18537
|
const handleBlur = React.useCallback(() => {
|
|
18442
18538
|
return dispatch({
|
|
18443
18539
|
type: VALIDATE_NEW_PASSWORD
|
|
@@ -18471,7 +18567,7 @@ function PasswordChangeConfirmNewPassword(props) {
|
|
|
18471
18567
|
confirmNewPassword,
|
|
18472
18568
|
confirmNewPasswordError
|
|
18473
18569
|
}
|
|
18474
|
-
} = React.useContext(store$
|
|
18570
|
+
} = React.useContext(store$9);
|
|
18475
18571
|
const handleBlur = React.useCallback(() => {
|
|
18476
18572
|
return dispatch({
|
|
18477
18573
|
type: VALIDATE_CONFIRM_NEW_PASSWORD
|
|
@@ -18512,7 +18608,7 @@ const PasswordChangeButton = ({
|
|
|
18512
18608
|
confirmNewPasswordError
|
|
18513
18609
|
},
|
|
18514
18610
|
dispatch
|
|
18515
|
-
} = React.useContext(store$
|
|
18611
|
+
} = React.useContext(store$9);
|
|
18516
18612
|
const {
|
|
18517
18613
|
t
|
|
18518
18614
|
} = useTranslation("passwordChange");
|
|
@@ -18578,17 +18674,17 @@ const PasswordChangeModal = ({
|
|
|
18578
18674
|
};
|
|
18579
18675
|
PasswordChangeModal.viewId = "password-change";
|
|
18580
18676
|
|
|
18581
|
-
const initialState$
|
|
18677
|
+
const initialState$8 = {
|
|
18582
18678
|
buttonDisabled: false,
|
|
18583
18679
|
alert: {
|
|
18584
18680
|
type: "error",
|
|
18585
18681
|
content: ""
|
|
18586
18682
|
}
|
|
18587
18683
|
};
|
|
18588
|
-
const store$
|
|
18684
|
+
const store$8 = /*#__PURE__*/React.createContext(initialState$8);
|
|
18589
18685
|
const {
|
|
18590
|
-
Provider: Provider$
|
|
18591
|
-
} = store$
|
|
18686
|
+
Provider: Provider$8
|
|
18687
|
+
} = store$8;
|
|
18592
18688
|
|
|
18593
18689
|
const CartContainer = ({
|
|
18594
18690
|
style,
|
|
@@ -18679,21 +18775,21 @@ const CartContainer = ({
|
|
|
18679
18775
|
default:
|
|
18680
18776
|
return state;
|
|
18681
18777
|
}
|
|
18682
|
-
}, initialState$
|
|
18778
|
+
}, initialState$8);
|
|
18683
18779
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
18684
18780
|
style: { ...style
|
|
18685
18781
|
},
|
|
18686
18782
|
className: `pelcro-container pelcro-cart-container ${className}`
|
|
18687
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
18783
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$8, {
|
|
18688
18784
|
value: {
|
|
18689
18785
|
state,
|
|
18690
18786
|
dispatch
|
|
18691
18787
|
}
|
|
18692
18788
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
18693
|
-
store: store$
|
|
18789
|
+
store: store$8,
|
|
18694
18790
|
key: i
|
|
18695
18791
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
18696
|
-
store: store$
|
|
18792
|
+
store: store$8
|
|
18697
18793
|
})));
|
|
18698
18794
|
};
|
|
18699
18795
|
|
|
@@ -18730,7 +18826,7 @@ const CartSubmit = ({
|
|
|
18730
18826
|
buttonDisabled
|
|
18731
18827
|
},
|
|
18732
18828
|
dispatch
|
|
18733
|
-
} = React.useContext(store$
|
|
18829
|
+
} = React.useContext(store$8);
|
|
18734
18830
|
const {
|
|
18735
18831
|
t
|
|
18736
18832
|
} = useTranslation("cart");
|
|
@@ -18761,7 +18857,7 @@ const CartTotalPrice = () => {
|
|
|
18761
18857
|
state: {
|
|
18762
18858
|
alert
|
|
18763
18859
|
}
|
|
18764
|
-
} = React.useContext(store$
|
|
18860
|
+
} = React.useContext(store$8);
|
|
18765
18861
|
const {
|
|
18766
18862
|
cartItems
|
|
18767
18863
|
} = usePelcro();
|
|
@@ -19074,7 +19170,7 @@ const OrderConfirmModal = props => {
|
|
|
19074
19170
|
};
|
|
19075
19171
|
OrderConfirmModal.viewId = "order-confirm";
|
|
19076
19172
|
|
|
19077
|
-
const initialState$
|
|
19173
|
+
const initialState$7 = {
|
|
19078
19174
|
email: "",
|
|
19079
19175
|
firstName: "",
|
|
19080
19176
|
lastName: "",
|
|
@@ -19086,10 +19182,10 @@ const initialState$6 = {
|
|
|
19086
19182
|
content: ""
|
|
19087
19183
|
}
|
|
19088
19184
|
};
|
|
19089
|
-
const store$
|
|
19185
|
+
const store$7 = /*#__PURE__*/React.createContext(initialState$7);
|
|
19090
19186
|
const {
|
|
19091
|
-
Provider: Provider$
|
|
19092
|
-
} = store$
|
|
19187
|
+
Provider: Provider$7
|
|
19188
|
+
} = store$7;
|
|
19093
19189
|
|
|
19094
19190
|
const GiftCreateContainer = ({
|
|
19095
19191
|
style,
|
|
@@ -19193,21 +19289,21 @@ const GiftCreateContainer = ({
|
|
|
19193
19289
|
default:
|
|
19194
19290
|
return state;
|
|
19195
19291
|
}
|
|
19196
|
-
}, initialState$
|
|
19292
|
+
}, initialState$7);
|
|
19197
19293
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
19198
19294
|
style: { ...style
|
|
19199
19295
|
},
|
|
19200
19296
|
className: `pelcro-container pelcro-gift-create-container ${className}`
|
|
19201
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
19297
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$7, {
|
|
19202
19298
|
value: {
|
|
19203
19299
|
state,
|
|
19204
19300
|
dispatch
|
|
19205
19301
|
}
|
|
19206
19302
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
19207
|
-
store: store$
|
|
19303
|
+
store: store$7,
|
|
19208
19304
|
key: i
|
|
19209
19305
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
19210
|
-
store: store$
|
|
19306
|
+
store: store$7
|
|
19211
19307
|
})));
|
|
19212
19308
|
};
|
|
19213
19309
|
|
|
@@ -19221,7 +19317,7 @@ const GiftCreateSubmitButton = ({
|
|
|
19221
19317
|
state: {
|
|
19222
19318
|
disableSubmit
|
|
19223
19319
|
}
|
|
19224
|
-
} = React.useContext(store$
|
|
19320
|
+
} = React.useContext(store$7);
|
|
19225
19321
|
const {
|
|
19226
19322
|
t
|
|
19227
19323
|
} = useTranslation("register");
|
|
@@ -19238,29 +19334,29 @@ const GiftCreateSubmitButton = ({
|
|
|
19238
19334
|
|
|
19239
19335
|
const GiftCreateEmail = props => /*#__PURE__*/React__default['default'].createElement(Email, Object.assign({
|
|
19240
19336
|
initWithUserEmail: false,
|
|
19241
|
-
store: store$
|
|
19337
|
+
store: store$7
|
|
19242
19338
|
}, props));
|
|
19243
19339
|
|
|
19244
19340
|
const GiftCreateFirstName = props => /*#__PURE__*/React__default['default'].createElement(FirstName, Object.assign({
|
|
19245
|
-
store: store$
|
|
19341
|
+
store: store$7
|
|
19246
19342
|
}, props));
|
|
19247
19343
|
|
|
19248
19344
|
const GiftCreateLastName = props => /*#__PURE__*/React__default['default'].createElement(LastName, Object.assign({
|
|
19249
|
-
store: store$
|
|
19345
|
+
store: store$7
|
|
19250
19346
|
}, props));
|
|
19251
19347
|
|
|
19252
|
-
var _path$
|
|
19348
|
+
var _path$i;
|
|
19253
19349
|
|
|
19254
|
-
function _extends$
|
|
19350
|
+
function _extends$k() { _extends$k = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$k.apply(this, arguments); }
|
|
19255
19351
|
|
|
19256
19352
|
function SvgInfoCircle(props) {
|
|
19257
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
19353
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$k({
|
|
19258
19354
|
xmlns: "http://www.w3.org/2000/svg",
|
|
19259
19355
|
className: "plc-w-5 plc-h-5",
|
|
19260
19356
|
fill: "none",
|
|
19261
19357
|
viewBox: "0 0 24 24",
|
|
19262
19358
|
stroke: "currentColor"
|
|
19263
|
-
}, props), _path$
|
|
19359
|
+
}, props), _path$i || (_path$i = /*#__PURE__*/React__namespace.createElement("path", {
|
|
19264
19360
|
strokeLinecap: "round",
|
|
19265
19361
|
strokeLinejoin: "round",
|
|
19266
19362
|
strokeWidth: 2,
|
|
@@ -19331,7 +19427,7 @@ const GiftCreateStartDate = props => {
|
|
|
19331
19427
|
const {
|
|
19332
19428
|
dispatch,
|
|
19333
19429
|
state
|
|
19334
|
-
} = React.useContext(store$
|
|
19430
|
+
} = React.useContext(store$7);
|
|
19335
19431
|
|
|
19336
19432
|
const handleInputChange = value => {
|
|
19337
19433
|
dispatch({
|
|
@@ -19404,7 +19500,7 @@ function GiftCreateMessage(props) {
|
|
|
19404
19500
|
const {
|
|
19405
19501
|
dispatch,
|
|
19406
19502
|
state
|
|
19407
|
-
} = React.useContext(store$
|
|
19503
|
+
} = React.useContext(store$7);
|
|
19408
19504
|
const MAX_CHARS_COUNT = 200;
|
|
19409
19505
|
const remainingCharsCount = (_ref = MAX_CHARS_COUNT - ((_state$giftMessage = state.giftMessage) === null || _state$giftMessage === void 0 ? void 0 : _state$giftMessage.length)) !== null && _ref !== void 0 ? _ref : 0;
|
|
19410
19506
|
|
|
@@ -19528,7 +19624,7 @@ const GiftCreateModal = ({
|
|
|
19528
19624
|
};
|
|
19529
19625
|
GiftCreateModal.viewId = "gift-create";
|
|
19530
19626
|
|
|
19531
|
-
const initialState$
|
|
19627
|
+
const initialState$6 = {
|
|
19532
19628
|
giftCode: "",
|
|
19533
19629
|
buttonDisabled: true,
|
|
19534
19630
|
alert: {
|
|
@@ -19536,10 +19632,10 @@ const initialState$5 = {
|
|
|
19536
19632
|
content: ""
|
|
19537
19633
|
}
|
|
19538
19634
|
};
|
|
19539
|
-
const store$
|
|
19635
|
+
const store$6 = /*#__PURE__*/React.createContext(initialState$6);
|
|
19540
19636
|
const {
|
|
19541
|
-
Provider: Provider$
|
|
19542
|
-
} = store$
|
|
19637
|
+
Provider: Provider$6
|
|
19638
|
+
} = store$6;
|
|
19543
19639
|
|
|
19544
19640
|
const GiftRedeemContainer = ({
|
|
19545
19641
|
style,
|
|
@@ -19604,21 +19700,21 @@ const GiftRedeemContainer = ({
|
|
|
19604
19700
|
default:
|
|
19605
19701
|
return state;
|
|
19606
19702
|
}
|
|
19607
|
-
}, initialState$
|
|
19703
|
+
}, initialState$6);
|
|
19608
19704
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
19609
19705
|
style: { ...style
|
|
19610
19706
|
},
|
|
19611
19707
|
className: `pelcro-container pelcro-gift-redeem-container ${className}`
|
|
19612
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
19708
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$6, {
|
|
19613
19709
|
value: {
|
|
19614
19710
|
state,
|
|
19615
19711
|
dispatch
|
|
19616
19712
|
}
|
|
19617
19713
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
19618
|
-
store: store$
|
|
19714
|
+
store: store$6,
|
|
19619
19715
|
key: i
|
|
19620
19716
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
19621
|
-
store: store$
|
|
19717
|
+
store: store$6
|
|
19622
19718
|
})));
|
|
19623
19719
|
};
|
|
19624
19720
|
|
|
@@ -19655,7 +19751,7 @@ function GiftCode({
|
|
|
19655
19751
|
}
|
|
19656
19752
|
|
|
19657
19753
|
const GiftRedeemCode = props => /*#__PURE__*/React__default['default'].createElement(GiftCode, Object.assign({
|
|
19658
|
-
store: store$
|
|
19754
|
+
store: store$6
|
|
19659
19755
|
}, props));
|
|
19660
19756
|
|
|
19661
19757
|
const GiftRedeemSubmitButton = ({
|
|
@@ -19668,7 +19764,7 @@ const GiftRedeemSubmitButton = ({
|
|
|
19668
19764
|
state: {
|
|
19669
19765
|
disableSubmit
|
|
19670
19766
|
}
|
|
19671
|
-
} = React.useContext(store$
|
|
19767
|
+
} = React.useContext(store$6);
|
|
19672
19768
|
const {
|
|
19673
19769
|
t
|
|
19674
19770
|
} = useTranslation("register");
|
|
@@ -19761,7 +19857,7 @@ const moveDefaultAddressToStart = addresses => {
|
|
|
19761
19857
|
return [defaultAddress, ...addressesWithoutDefault];
|
|
19762
19858
|
};
|
|
19763
19859
|
|
|
19764
|
-
const initialState$
|
|
19860
|
+
const initialState$5 = {
|
|
19765
19861
|
addresses: [],
|
|
19766
19862
|
selectedAddressId: null,
|
|
19767
19863
|
isSubmitting: false,
|
|
@@ -19770,10 +19866,10 @@ const initialState$4 = {
|
|
|
19770
19866
|
content: ""
|
|
19771
19867
|
}
|
|
19772
19868
|
};
|
|
19773
|
-
const store$
|
|
19869
|
+
const store$5 = /*#__PURE__*/React.createContext(initialState$5);
|
|
19774
19870
|
const {
|
|
19775
|
-
Provider: Provider$
|
|
19776
|
-
} = store$
|
|
19871
|
+
Provider: Provider$5
|
|
19872
|
+
} = store$5;
|
|
19777
19873
|
|
|
19778
19874
|
const AddressSelectContainer = ({
|
|
19779
19875
|
style,
|
|
@@ -19868,7 +19964,7 @@ const AddressSelectContainer = ({
|
|
|
19868
19964
|
default:
|
|
19869
19965
|
return state;
|
|
19870
19966
|
}
|
|
19871
|
-
}, initialState$
|
|
19967
|
+
}, initialState$5);
|
|
19872
19968
|
React.useEffect(() => {
|
|
19873
19969
|
var _window$Pelcro$user$r;
|
|
19874
19970
|
|
|
@@ -19881,16 +19977,16 @@ const AddressSelectContainer = ({
|
|
|
19881
19977
|
style: { ...style
|
|
19882
19978
|
},
|
|
19883
19979
|
className: `pelcro-container pelcro-address-select-container ${className}`
|
|
19884
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
19980
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$5, {
|
|
19885
19981
|
value: {
|
|
19886
19982
|
state,
|
|
19887
19983
|
dispatch
|
|
19888
19984
|
}
|
|
19889
19985
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
19890
|
-
store: store$
|
|
19986
|
+
store: store$5,
|
|
19891
19987
|
key: i
|
|
19892
19988
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
19893
|
-
store: store$
|
|
19989
|
+
store: store$5
|
|
19894
19990
|
})));
|
|
19895
19991
|
};
|
|
19896
19992
|
|
|
@@ -19901,7 +19997,7 @@ const AddressSelectList = () => {
|
|
|
19901
19997
|
addresses,
|
|
19902
19998
|
selectedAddressId
|
|
19903
19999
|
}
|
|
19904
|
-
} = React.useContext(store$
|
|
20000
|
+
} = React.useContext(store$5);
|
|
19905
20001
|
|
|
19906
20002
|
const handleAddressSelect = event => {
|
|
19907
20003
|
dispatch({
|
|
@@ -19945,7 +20041,7 @@ const AddressSelectSubmit = ({
|
|
|
19945
20041
|
selectedAddressId,
|
|
19946
20042
|
isSubmitting
|
|
19947
20043
|
}
|
|
19948
|
-
} = React.useContext(store$
|
|
20044
|
+
} = React.useContext(store$5);
|
|
19949
20045
|
const {
|
|
19950
20046
|
t
|
|
19951
20047
|
} = useTranslation("address");
|
|
@@ -20041,7 +20137,7 @@ const moveDefaultPaymentMethodToStart = paymentMethods => {
|
|
|
20041
20137
|
return [defaultPaymentMethod, ...paymentMethodsWithoutDefault];
|
|
20042
20138
|
};
|
|
20043
20139
|
|
|
20044
|
-
const initialState$
|
|
20140
|
+
const initialState$4 = {
|
|
20045
20141
|
paymentMethods: [],
|
|
20046
20142
|
selectedPaymentMethodId: null,
|
|
20047
20143
|
isSubmitting: false,
|
|
@@ -20050,10 +20146,10 @@ const initialState$3 = {
|
|
|
20050
20146
|
content: ""
|
|
20051
20147
|
}
|
|
20052
20148
|
};
|
|
20053
|
-
const store$
|
|
20149
|
+
const store$4 = /*#__PURE__*/React.createContext(initialState$4);
|
|
20054
20150
|
const {
|
|
20055
|
-
Provider: Provider$
|
|
20056
|
-
} = store$
|
|
20151
|
+
Provider: Provider$4
|
|
20152
|
+
} = store$4;
|
|
20057
20153
|
|
|
20058
20154
|
const PaymentMethodSelectContainer = ({
|
|
20059
20155
|
style,
|
|
@@ -20098,7 +20194,7 @@ const PaymentMethodSelectContainer = ({
|
|
|
20098
20194
|
default:
|
|
20099
20195
|
return state;
|
|
20100
20196
|
}
|
|
20101
|
-
}, initialState$
|
|
20197
|
+
}, initialState$4);
|
|
20102
20198
|
React.useEffect(() => {
|
|
20103
20199
|
var _window$Pelcro$user$r4;
|
|
20104
20200
|
|
|
@@ -20111,16 +20207,16 @@ const PaymentMethodSelectContainer = ({
|
|
|
20111
20207
|
style: { ...style
|
|
20112
20208
|
},
|
|
20113
20209
|
className: `pelcro-container pelcro-payment-select-container ${className}`
|
|
20114
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
20210
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$4, {
|
|
20115
20211
|
value: {
|
|
20116
20212
|
state,
|
|
20117
20213
|
dispatch
|
|
20118
20214
|
}
|
|
20119
20215
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
20120
|
-
store: store$
|
|
20216
|
+
store: store$4,
|
|
20121
20217
|
key: i
|
|
20122
20218
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
20123
|
-
store: store$
|
|
20219
|
+
store: store$4
|
|
20124
20220
|
})));
|
|
20125
20221
|
};
|
|
20126
20222
|
|
|
@@ -20134,7 +20230,7 @@ const PaymentMethodSelectList = () => {
|
|
|
20134
20230
|
paymentMethods,
|
|
20135
20231
|
selectedPaymentMethodId
|
|
20136
20232
|
}
|
|
20137
|
-
} = React.useContext(store$
|
|
20233
|
+
} = React.useContext(store$4);
|
|
20138
20234
|
|
|
20139
20235
|
const handlePaymentMethodSelect = event => {
|
|
20140
20236
|
dispatch({
|
|
@@ -20184,7 +20280,7 @@ const PaymentMethodSelectSubmit = ({
|
|
|
20184
20280
|
selectedPaymentMethodId,
|
|
20185
20281
|
isSubmitting
|
|
20186
20282
|
}
|
|
20187
|
-
} = React.useContext(store$
|
|
20283
|
+
} = React.useContext(store$4);
|
|
20188
20284
|
return /*#__PURE__*/React__default['default'].createElement(Button, Object.assign({
|
|
20189
20285
|
onClick: () => {
|
|
20190
20286
|
dispatch({
|
|
@@ -20258,8 +20354,8 @@ const PaymentMethodSelectModal = ({
|
|
|
20258
20354
|
};
|
|
20259
20355
|
PaymentMethodSelectModal.viewId = "payment-method-select";
|
|
20260
20356
|
|
|
20261
|
-
function _extends$
|
|
20262
|
-
_extends$
|
|
20357
|
+
function _extends$j() {
|
|
20358
|
+
_extends$j = Object.assign || function (target) {
|
|
20263
20359
|
for (var i = 1; i < arguments.length; i++) {
|
|
20264
20360
|
var source = arguments[i];
|
|
20265
20361
|
|
|
@@ -20273,7 +20369,7 @@ function _extends$i() {
|
|
|
20273
20369
|
return target;
|
|
20274
20370
|
};
|
|
20275
20371
|
|
|
20276
|
-
return _extends$
|
|
20372
|
+
return _extends$j.apply(this, arguments);
|
|
20277
20373
|
}
|
|
20278
20374
|
|
|
20279
20375
|
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
@@ -20457,7 +20553,7 @@ function render(props, propsBag, defaultTag, features, visible) {
|
|
|
20457
20553
|
return match(strategy, (_match = {}, _match[RenderStrategy.Unmount] = function () {
|
|
20458
20554
|
return null;
|
|
20459
20555
|
}, _match[RenderStrategy.Hidden] = function () {
|
|
20460
|
-
return _render(_extends$
|
|
20556
|
+
return _render(_extends$j({}, _rest, {
|
|
20461
20557
|
hidden: true,
|
|
20462
20558
|
style: {
|
|
20463
20559
|
display: 'none'
|
|
@@ -20985,7 +21081,7 @@ function TransitionChild(props) {
|
|
|
20985
21081
|
var passthroughProps = rest;
|
|
20986
21082
|
return React__default['default'].createElement(NestingContext.Provider, {
|
|
20987
21083
|
value: nesting
|
|
20988
|
-
}, render(_extends$
|
|
21084
|
+
}, render(_extends$j({}, passthroughProps, propsWeControl), propsBag, DEFAULT_TRANSITION_CHILD_TAG, TransitionChildRenderFeatures, state === TreeStates.Visible));
|
|
20989
21085
|
}
|
|
20990
21086
|
|
|
20991
21087
|
function Transition(props) {
|
|
@@ -21029,7 +21125,7 @@ function Transition(props) {
|
|
|
21029
21125
|
value: nestingBag
|
|
21030
21126
|
}, React__default['default'].createElement(TransitionContext.Provider, {
|
|
21031
21127
|
value: transitionBag
|
|
21032
|
-
}, render(_extends$
|
|
21128
|
+
}, render(_extends$j({}, sharedProps, {
|
|
21033
21129
|
as: React.Fragment,
|
|
21034
21130
|
children: React__default['default'].createElement(TransitionChild, Object.assign({}, sharedProps, passthroughProps))
|
|
21035
21131
|
}), propsBag, React.Fragment, TransitionChildRenderFeatures, state === TreeStates.Visible)));
|
|
@@ -21156,12 +21252,12 @@ var ActionTypes;
|
|
|
21156
21252
|
})(ActionTypes || (ActionTypes = {}));
|
|
21157
21253
|
|
|
21158
21254
|
(_reducers = {}, _reducers[ActionTypes.CloseMenu] = function (state) {
|
|
21159
|
-
return _extends$
|
|
21255
|
+
return _extends$j({}, state, {
|
|
21160
21256
|
activeItemIndex: null,
|
|
21161
21257
|
menuState: MenuStates.Closed
|
|
21162
21258
|
});
|
|
21163
21259
|
}, _reducers[ActionTypes.OpenMenu] = function (state) {
|
|
21164
|
-
return _extends$
|
|
21260
|
+
return _extends$j({}, state, {
|
|
21165
21261
|
menuState: MenuStates.Open
|
|
21166
21262
|
});
|
|
21167
21263
|
}, _reducers[ActionTypes.GoToItem] = function (state, action) {
|
|
@@ -21180,7 +21276,7 @@ var ActionTypes;
|
|
|
21180
21276
|
}
|
|
21181
21277
|
});
|
|
21182
21278
|
if (state.searchQuery === '' && state.activeItemIndex === activeItemIndex) return state;
|
|
21183
|
-
return _extends$
|
|
21279
|
+
return _extends$j({}, state, {
|
|
21184
21280
|
searchQuery: '',
|
|
21185
21281
|
activeItemIndex: activeItemIndex
|
|
21186
21282
|
});
|
|
@@ -21191,19 +21287,19 @@ var ActionTypes;
|
|
|
21191
21287
|
|
|
21192
21288
|
return ((_item$dataRef$current = item.dataRef.current.textValue) == null ? void 0 : _item$dataRef$current.startsWith(searchQuery)) && !item.dataRef.current.disabled;
|
|
21193
21289
|
});
|
|
21194
|
-
if (match === -1 || match === state.activeItemIndex) return _extends$
|
|
21290
|
+
if (match === -1 || match === state.activeItemIndex) return _extends$j({}, state, {
|
|
21195
21291
|
searchQuery: searchQuery
|
|
21196
21292
|
});
|
|
21197
|
-
return _extends$
|
|
21293
|
+
return _extends$j({}, state, {
|
|
21198
21294
|
searchQuery: searchQuery,
|
|
21199
21295
|
activeItemIndex: match
|
|
21200
21296
|
});
|
|
21201
21297
|
}, _reducers[ActionTypes.ClearSearch] = function (state) {
|
|
21202
|
-
return _extends$
|
|
21298
|
+
return _extends$j({}, state, {
|
|
21203
21299
|
searchQuery: ''
|
|
21204
21300
|
});
|
|
21205
21301
|
}, _reducers[ActionTypes.RegisterItem] = function (state, action) {
|
|
21206
|
-
return _extends$
|
|
21302
|
+
return _extends$j({}, state, {
|
|
21207
21303
|
items: [].concat(state.items, [{
|
|
21208
21304
|
id: action.id,
|
|
21209
21305
|
dataRef: action.dataRef
|
|
@@ -21216,7 +21312,7 @@ var ActionTypes;
|
|
|
21216
21312
|
return a.id === action.id;
|
|
21217
21313
|
});
|
|
21218
21314
|
if (idx !== -1) nextItems.splice(idx, 1);
|
|
21219
|
-
return _extends$
|
|
21315
|
+
return _extends$j({}, state, {
|
|
21220
21316
|
items: nextItems,
|
|
21221
21317
|
activeItemIndex: function () {
|
|
21222
21318
|
if (idx === state.activeItemIndex) return null;
|
|
@@ -21255,19 +21351,19 @@ var ActionTypes$1;
|
|
|
21255
21351
|
(_reducers$1 = {}, _reducers$1[ActionTypes$1.CloseListbox] = function (state) {
|
|
21256
21352
|
if (state.disabled) return state;
|
|
21257
21353
|
if (state.listboxState === ListboxStates.Closed) return state;
|
|
21258
|
-
return _extends$
|
|
21354
|
+
return _extends$j({}, state, {
|
|
21259
21355
|
activeOptionIndex: null,
|
|
21260
21356
|
listboxState: ListboxStates.Closed
|
|
21261
21357
|
});
|
|
21262
21358
|
}, _reducers$1[ActionTypes$1.OpenListbox] = function (state) {
|
|
21263
21359
|
if (state.disabled) return state;
|
|
21264
21360
|
if (state.listboxState === ListboxStates.Open) return state;
|
|
21265
|
-
return _extends$
|
|
21361
|
+
return _extends$j({}, state, {
|
|
21266
21362
|
listboxState: ListboxStates.Open
|
|
21267
21363
|
});
|
|
21268
21364
|
}, _reducers$1[ActionTypes$1.SetDisabled] = function (state, action) {
|
|
21269
21365
|
if (state.disabled === action.disabled) return state;
|
|
21270
|
-
return _extends$
|
|
21366
|
+
return _extends$j({}, state, {
|
|
21271
21367
|
disabled: action.disabled
|
|
21272
21368
|
});
|
|
21273
21369
|
}, _reducers$1[ActionTypes$1.GoToOption] = function (state, action) {
|
|
@@ -21288,7 +21384,7 @@ var ActionTypes$1;
|
|
|
21288
21384
|
}
|
|
21289
21385
|
});
|
|
21290
21386
|
if (state.searchQuery === '' && state.activeOptionIndex === activeOptionIndex) return state;
|
|
21291
|
-
return _extends$
|
|
21387
|
+
return _extends$j({}, state, {
|
|
21292
21388
|
searchQuery: '',
|
|
21293
21389
|
activeOptionIndex: activeOptionIndex
|
|
21294
21390
|
});
|
|
@@ -21301,10 +21397,10 @@ var ActionTypes$1;
|
|
|
21301
21397
|
|
|
21302
21398
|
return !option.dataRef.current.disabled && ((_option$dataRef$curre = option.dataRef.current.textValue) == null ? void 0 : _option$dataRef$curre.startsWith(searchQuery));
|
|
21303
21399
|
});
|
|
21304
|
-
if (match === -1 || match === state.activeOptionIndex) return _extends$
|
|
21400
|
+
if (match === -1 || match === state.activeOptionIndex) return _extends$j({}, state, {
|
|
21305
21401
|
searchQuery: searchQuery
|
|
21306
21402
|
});
|
|
21307
|
-
return _extends$
|
|
21403
|
+
return _extends$j({}, state, {
|
|
21308
21404
|
searchQuery: searchQuery,
|
|
21309
21405
|
activeOptionIndex: match
|
|
21310
21406
|
});
|
|
@@ -21312,11 +21408,11 @@ var ActionTypes$1;
|
|
|
21312
21408
|
if (state.disabled) return state;
|
|
21313
21409
|
if (state.listboxState === ListboxStates.Closed) return state;
|
|
21314
21410
|
if (state.searchQuery === '') return state;
|
|
21315
|
-
return _extends$
|
|
21411
|
+
return _extends$j({}, state, {
|
|
21316
21412
|
searchQuery: ''
|
|
21317
21413
|
});
|
|
21318
21414
|
}, _reducers$1[ActionTypes$1.RegisterOption] = function (state, action) {
|
|
21319
|
-
return _extends$
|
|
21415
|
+
return _extends$j({}, state, {
|
|
21320
21416
|
options: [].concat(state.options, [{
|
|
21321
21417
|
id: action.id,
|
|
21322
21418
|
dataRef: action.dataRef
|
|
@@ -21329,7 +21425,7 @@ var ActionTypes$1;
|
|
|
21329
21425
|
return a.id === action.id;
|
|
21330
21426
|
});
|
|
21331
21427
|
if (idx !== -1) nextOptions.splice(idx, 1);
|
|
21332
|
-
return _extends$
|
|
21428
|
+
return _extends$j({}, state, {
|
|
21333
21429
|
options: nextOptions,
|
|
21334
21430
|
activeOptionIndex: function () {
|
|
21335
21431
|
if (idx === state.activeOptionIndex) return null;
|
|
@@ -21390,18 +21486,18 @@ const getPaymentCardIcon = name => {
|
|
|
21390
21486
|
}));
|
|
21391
21487
|
};
|
|
21392
21488
|
|
|
21393
|
-
var _path$
|
|
21489
|
+
var _path$h;
|
|
21394
21490
|
|
|
21395
|
-
function _extends$
|
|
21491
|
+
function _extends$i() { _extends$i = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$i.apply(this, arguments); }
|
|
21396
21492
|
|
|
21397
21493
|
function SvgChevronRight(props) {
|
|
21398
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
21494
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$i({
|
|
21399
21495
|
className: "plc-w-6 plc-h-6",
|
|
21400
21496
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21401
21497
|
fill: "none",
|
|
21402
21498
|
viewBox: "0 0 24 24",
|
|
21403
21499
|
stroke: "currentColor"
|
|
21404
|
-
}, props), _path$
|
|
21500
|
+
}, props), _path$h || (_path$h = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21405
21501
|
strokeLinecap: "round",
|
|
21406
21502
|
strokeLinejoin: "round",
|
|
21407
21503
|
strokeWidth: 2,
|
|
@@ -21617,18 +21713,18 @@ const SavedItems = ({
|
|
|
21617
21713
|
});
|
|
21618
21714
|
};
|
|
21619
21715
|
|
|
21620
|
-
var _path$
|
|
21716
|
+
var _path$g;
|
|
21621
21717
|
|
|
21622
|
-
function _extends$
|
|
21718
|
+
function _extends$h() { _extends$h = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$h.apply(this, arguments); }
|
|
21623
21719
|
|
|
21624
21720
|
function SvgRefresh(props) {
|
|
21625
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
21721
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$h({
|
|
21626
21722
|
className: "plc-w-4 plc-h-4 plc-mr-1",
|
|
21627
21723
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21628
21724
|
fill: "none",
|
|
21629
21725
|
viewBox: "0 0 24 24",
|
|
21630
21726
|
stroke: "currentColor"
|
|
21631
|
-
}, props), _path$
|
|
21727
|
+
}, props), _path$g || (_path$g = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21632
21728
|
strokeLinecap: "round",
|
|
21633
21729
|
strokeLinejoin: "round",
|
|
21634
21730
|
strokeWidth: 2,
|
|
@@ -21636,35 +21732,35 @@ function SvgRefresh(props) {
|
|
|
21636
21732
|
})));
|
|
21637
21733
|
}
|
|
21638
21734
|
|
|
21639
|
-
var _path$
|
|
21735
|
+
var _path$f;
|
|
21640
21736
|
|
|
21641
|
-
function _extends$
|
|
21737
|
+
function _extends$g() { _extends$g = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$g.apply(this, arguments); }
|
|
21642
21738
|
|
|
21643
21739
|
function SvgCalendar(props) {
|
|
21644
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
21740
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$g({
|
|
21645
21741
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21646
21742
|
className: "plc-h-4 plc-w-4 plc-mr-1",
|
|
21647
21743
|
viewBox: "0 0 20 20",
|
|
21648
21744
|
fill: "currentColor"
|
|
21649
|
-
}, props), _path$
|
|
21745
|
+
}, props), _path$f || (_path$f = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21650
21746
|
fillRule: "evenodd",
|
|
21651
21747
|
d: "M6 2a1 1 0 00-1 1v1H4a2 2 0 00-2 2v10a2 2 0 002 2h12a2 2 0 002-2V6a2 2 0 00-2-2h-1V3a1 1 0 10-2 0v1H7V3a1 1 0 00-1-1zm0 5a1 1 0 000 2h8a1 1 0 100-2H6z",
|
|
21652
21748
|
clipRule: "evenodd"
|
|
21653
21749
|
})));
|
|
21654
21750
|
}
|
|
21655
21751
|
|
|
21656
|
-
var _path$
|
|
21752
|
+
var _path$e;
|
|
21657
21753
|
|
|
21658
|
-
function _extends$
|
|
21754
|
+
function _extends$f() { _extends$f = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$f.apply(this, arguments); }
|
|
21659
21755
|
|
|
21660
21756
|
function SvgPlus(props) {
|
|
21661
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
21757
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$f({
|
|
21662
21758
|
className: "plc-w-5 plc-h-5",
|
|
21663
21759
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21664
21760
|
fill: "none",
|
|
21665
21761
|
viewBox: "0 0 24 24",
|
|
21666
21762
|
stroke: "currentColor"
|
|
21667
|
-
}, props), _path$
|
|
21763
|
+
}, props), _path$e || (_path$e = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21668
21764
|
strokeLinecap: "round",
|
|
21669
21765
|
strokeLinejoin: "round",
|
|
21670
21766
|
strokeWidth: 2,
|
|
@@ -21672,17 +21768,17 @@ function SvgPlus(props) {
|
|
|
21672
21768
|
})));
|
|
21673
21769
|
}
|
|
21674
21770
|
|
|
21675
|
-
var _path$
|
|
21771
|
+
var _path$d;
|
|
21676
21772
|
|
|
21677
|
-
function _extends$
|
|
21773
|
+
function _extends$e() { _extends$e = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$e.apply(this, arguments); }
|
|
21678
21774
|
|
|
21679
21775
|
function SvgCheckMark(props) {
|
|
21680
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
21776
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$e({
|
|
21681
21777
|
className: "plc-w-4 plc-h-4 plc-mr-1",
|
|
21682
21778
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21683
21779
|
viewBox: "0 0 20 20",
|
|
21684
21780
|
fill: "currentColor"
|
|
21685
|
-
}, props), _path$
|
|
21781
|
+
}, props), _path$d || (_path$d = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21686
21782
|
fillRule: "evenodd",
|
|
21687
21783
|
d: "M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z",
|
|
21688
21784
|
clipRule: "evenodd"
|
|
@@ -21746,7 +21842,8 @@ const SubscriptionsItems = ({
|
|
|
21746
21842
|
} = useTranslation("dashboard");
|
|
21747
21843
|
const {
|
|
21748
21844
|
switchView,
|
|
21749
|
-
|
|
21845
|
+
switchToAddressView,
|
|
21846
|
+
switchToPaymentView
|
|
21750
21847
|
} = usePelcro();
|
|
21751
21848
|
const subs = getNonDonationSubs();
|
|
21752
21849
|
if (subs.length === 0) return null;
|
|
@@ -21788,7 +21885,12 @@ const SubscriptionsItems = ({
|
|
|
21788
21885
|
const plan = window.Pelcro.plan.getById(plan_id);
|
|
21789
21886
|
setProductAndPlan(product, plan);
|
|
21790
21887
|
setSubscriptionIdToRenew(sub.id);
|
|
21791
|
-
|
|
21888
|
+
|
|
21889
|
+
if (product.address_required) {
|
|
21890
|
+
return switchToAddressView();
|
|
21891
|
+
}
|
|
21892
|
+
|
|
21893
|
+
return switchToPaymentView();
|
|
21792
21894
|
};
|
|
21793
21895
|
|
|
21794
21896
|
const getPhases = () => {
|
|
@@ -21977,18 +22079,18 @@ Accordion.item = function AccordionItem({
|
|
|
21977
22079
|
}, content)) : null;
|
|
21978
22080
|
};
|
|
21979
22081
|
|
|
21980
|
-
var _path$
|
|
22082
|
+
var _path$c;
|
|
21981
22083
|
|
|
21982
|
-
function _extends$
|
|
22084
|
+
function _extends$d() { _extends$d = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$d.apply(this, arguments); }
|
|
21983
22085
|
|
|
21984
22086
|
function SvgExit(props) {
|
|
21985
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22087
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$d({
|
|
21986
22088
|
className: "plc-w-6 plc-h-6",
|
|
21987
22089
|
xmlns: "http://www.w3.org/2000/svg",
|
|
21988
22090
|
fill: "none",
|
|
21989
22091
|
viewBox: "0 0 24 24",
|
|
21990
22092
|
stroke: "currentColor"
|
|
21991
|
-
}, props), _path$
|
|
22093
|
+
}, props), _path$c || (_path$c = /*#__PURE__*/React__namespace.createElement("path", {
|
|
21992
22094
|
strokeLinecap: "round",
|
|
21993
22095
|
strokeLinejoin: "round",
|
|
21994
22096
|
strokeWidth: 2,
|
|
@@ -21996,17 +22098,17 @@ function SvgExit(props) {
|
|
|
21996
22098
|
})));
|
|
21997
22099
|
}
|
|
21998
22100
|
|
|
21999
|
-
var _path$
|
|
22101
|
+
var _path$b;
|
|
22000
22102
|
|
|
22001
|
-
function _extends$
|
|
22103
|
+
function _extends$c() { _extends$c = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$c.apply(this, arguments); }
|
|
22002
22104
|
|
|
22003
22105
|
function SvgUser(props) {
|
|
22004
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22106
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$c({
|
|
22005
22107
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22006
22108
|
fill: "none",
|
|
22007
22109
|
viewBox: "0 0 24 24",
|
|
22008
22110
|
stroke: "currentColor"
|
|
22009
|
-
}, props), _path$
|
|
22111
|
+
}, props), _path$b || (_path$b = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22010
22112
|
strokeLinecap: "round",
|
|
22011
22113
|
strokeLinejoin: "round",
|
|
22012
22114
|
strokeWidth: 2,
|
|
@@ -22014,18 +22116,18 @@ function SvgUser(props) {
|
|
|
22014
22116
|
})));
|
|
22015
22117
|
}
|
|
22016
22118
|
|
|
22017
|
-
var _path$
|
|
22119
|
+
var _path$a;
|
|
22018
22120
|
|
|
22019
|
-
function _extends$
|
|
22121
|
+
function _extends$b() { _extends$b = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$b.apply(this, arguments); }
|
|
22020
22122
|
|
|
22021
22123
|
function SvgNewsletter(props) {
|
|
22022
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22124
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$b({
|
|
22023
22125
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22024
22126
|
className: "plc-h-5 plc-w-5",
|
|
22025
22127
|
fill: "none",
|
|
22026
22128
|
viewBox: "0 0 24 24",
|
|
22027
22129
|
stroke: "currentColor"
|
|
22028
|
-
}, props), _path$
|
|
22130
|
+
}, props), _path$a || (_path$a = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22029
22131
|
strokeLinecap: "round",
|
|
22030
22132
|
strokeLinejoin: "round",
|
|
22031
22133
|
strokeWidth: 2,
|
|
@@ -22033,18 +22135,18 @@ function SvgNewsletter(props) {
|
|
|
22033
22135
|
})));
|
|
22034
22136
|
}
|
|
22035
22137
|
|
|
22036
|
-
var _path$
|
|
22138
|
+
var _path$9;
|
|
22037
22139
|
|
|
22038
|
-
function _extends$
|
|
22140
|
+
function _extends$a() { _extends$a = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$a.apply(this, arguments); }
|
|
22039
22141
|
|
|
22040
22142
|
function SvgDocument(props) {
|
|
22041
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22143
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$a({
|
|
22042
22144
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22043
22145
|
className: "plc-h-6 plc-w-6 plc-mr-2",
|
|
22044
22146
|
fill: "none",
|
|
22045
22147
|
viewBox: "0 0 24 24",
|
|
22046
22148
|
stroke: "currentColor"
|
|
22047
|
-
}, props), _path$
|
|
22149
|
+
}, props), _path$9 || (_path$9 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22048
22150
|
strokeLinecap: "round",
|
|
22049
22151
|
strokeLinejoin: "round",
|
|
22050
22152
|
strokeWidth: 2,
|
|
@@ -22052,18 +22154,18 @@ function SvgDocument(props) {
|
|
|
22052
22154
|
})));
|
|
22053
22155
|
}
|
|
22054
22156
|
|
|
22055
|
-
var _path$
|
|
22157
|
+
var _path$8;
|
|
22056
22158
|
|
|
22057
|
-
function _extends$
|
|
22159
|
+
function _extends$9() { _extends$9 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$9.apply(this, arguments); }
|
|
22058
22160
|
|
|
22059
22161
|
function SvgPaymentCard(props) {
|
|
22060
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22162
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$9({
|
|
22061
22163
|
className: "plc-w-6 plc-h-6 plc-mr-2",
|
|
22062
22164
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22063
22165
|
fill: "none",
|
|
22064
22166
|
viewBox: "0 0 24 24",
|
|
22065
22167
|
stroke: "currentColor"
|
|
22066
|
-
}, props), _path$
|
|
22168
|
+
}, props), _path$8 || (_path$8 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22067
22169
|
strokeLinecap: "round",
|
|
22068
22170
|
strokeLinejoin: "round",
|
|
22069
22171
|
strokeWidth: 2,
|
|
@@ -22071,18 +22173,18 @@ function SvgPaymentCard(props) {
|
|
|
22071
22173
|
})));
|
|
22072
22174
|
}
|
|
22073
22175
|
|
|
22074
|
-
var _path$
|
|
22176
|
+
var _path$7, _path2$1;
|
|
22075
22177
|
|
|
22076
|
-
function _extends$
|
|
22178
|
+
function _extends$8() { _extends$8 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$8.apply(this, arguments); }
|
|
22077
22179
|
|
|
22078
22180
|
function SvgLocationPin(props) {
|
|
22079
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22181
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$8({
|
|
22080
22182
|
className: "plc-w-6 plc-h-6 plc-mr-2",
|
|
22081
22183
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22082
22184
|
fill: "none",
|
|
22083
22185
|
viewBox: "0 0 24 24",
|
|
22084
22186
|
stroke: "currentColor"
|
|
22085
|
-
}, props), _path$
|
|
22187
|
+
}, props), _path$7 || (_path$7 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22086
22188
|
strokeLinecap: "round",
|
|
22087
22189
|
strokeLinejoin: "round",
|
|
22088
22190
|
strokeWidth: 2,
|
|
@@ -22097,10 +22199,10 @@ function SvgLocationPin(props) {
|
|
|
22097
22199
|
|
|
22098
22200
|
var _switch;
|
|
22099
22201
|
|
|
22100
|
-
function _extends$
|
|
22202
|
+
function _extends$7() { _extends$7 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$7.apply(this, arguments); }
|
|
22101
22203
|
|
|
22102
22204
|
function SvgSubscription(props) {
|
|
22103
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22205
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$7({
|
|
22104
22206
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22105
22207
|
viewBox: "0 0 100 125",
|
|
22106
22208
|
fill: "currentColor"
|
|
@@ -22115,18 +22217,18 @@ function SvgSubscription(props) {
|
|
|
22115
22217
|
}))))));
|
|
22116
22218
|
}
|
|
22117
22219
|
|
|
22118
|
-
var _path$
|
|
22220
|
+
var _path$6;
|
|
22119
22221
|
|
|
22120
|
-
function _extends$
|
|
22222
|
+
function _extends$6() { _extends$6 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$6.apply(this, arguments); }
|
|
22121
22223
|
|
|
22122
22224
|
function SvgShopping(props) {
|
|
22123
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22225
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$6({
|
|
22124
22226
|
className: "plc-w-6 plc-h-6 plc-mr-2",
|
|
22125
22227
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22126
22228
|
fill: "none",
|
|
22127
22229
|
viewBox: "0 0 24 24",
|
|
22128
22230
|
stroke: "currentColor"
|
|
22129
|
-
}, props), _path$
|
|
22231
|
+
}, props), _path$6 || (_path$6 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22130
22232
|
strokeLinecap: "round",
|
|
22131
22233
|
strokeLinejoin: "round",
|
|
22132
22234
|
strokeWidth: 2,
|
|
@@ -22134,18 +22236,18 @@ function SvgShopping(props) {
|
|
|
22134
22236
|
})));
|
|
22135
22237
|
}
|
|
22136
22238
|
|
|
22137
|
-
var _path$
|
|
22239
|
+
var _path$5;
|
|
22138
22240
|
|
|
22139
|
-
function _extends$
|
|
22241
|
+
function _extends$5() { _extends$5 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$5.apply(this, arguments); }
|
|
22140
22242
|
|
|
22141
22243
|
function SvgBookmark(props) {
|
|
22142
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22244
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$5({
|
|
22143
22245
|
className: "plc-w-6 plc-h-6 plc-mr-2",
|
|
22144
22246
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22145
22247
|
fill: "none",
|
|
22146
22248
|
viewBox: "0 0 24 24",
|
|
22147
22249
|
stroke: "currentColor"
|
|
22148
|
-
}, props), _path$
|
|
22250
|
+
}, props), _path$5 || (_path$5 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22149
22251
|
strokeLinecap: "round",
|
|
22150
22252
|
strokeLinejoin: "round",
|
|
22151
22253
|
strokeWidth: 2,
|
|
@@ -22153,33 +22255,33 @@ function SvgBookmark(props) {
|
|
|
22153
22255
|
})));
|
|
22154
22256
|
}
|
|
22155
22257
|
|
|
22156
|
-
var _path$
|
|
22258
|
+
var _path$4;
|
|
22157
22259
|
|
|
22158
|
-
function _extends$
|
|
22260
|
+
function _extends$4() { _extends$4 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$4.apply(this, arguments); }
|
|
22159
22261
|
|
|
22160
22262
|
function SvgKey(props) {
|
|
22161
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22263
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$4({
|
|
22162
22264
|
xmlns: "http://www.w3.org/2000/svg",
|
|
22163
22265
|
viewBox: "0 0 20 20",
|
|
22164
22266
|
fill: "currentColor"
|
|
22165
|
-
}, props), _path$
|
|
22267
|
+
}, props), _path$4 || (_path$4 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22166
22268
|
fillRule: "evenodd",
|
|
22167
22269
|
d: "M18 8a6 6 0 01-7.743 5.743L10 14l-1 1-1 1H6v2H2v-4l4.257-4.257A6 6 0 1118 8zm-6-4a1 1 0 100 2 2 2 0 012 2 1 1 0 102 0 4 4 0 00-4-4z",
|
|
22168
22270
|
clipRule: "evenodd"
|
|
22169
22271
|
})));
|
|
22170
22272
|
}
|
|
22171
22273
|
|
|
22172
|
-
var _path$
|
|
22274
|
+
var _path$3;
|
|
22173
22275
|
|
|
22174
|
-
function _extends$
|
|
22276
|
+
function _extends$3() { _extends$3 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$3.apply(this, arguments); }
|
|
22175
22277
|
|
|
22176
22278
|
function SvgDonate(props) {
|
|
22177
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
22279
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$3({
|
|
22178
22280
|
width: 24,
|
|
22179
22281
|
height: 24,
|
|
22180
22282
|
fill: "currentColor",
|
|
22181
22283
|
xmlns: "http://www.w3.org/2000/svg"
|
|
22182
|
-
}, props), _path$
|
|
22284
|
+
}, props), _path$3 || (_path$3 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
22183
22285
|
d: "M4 21h9.62a3.995 3.995 0 003.037-1.397l5.102-5.952a1 1 0 00-.442-1.6l-1.968-.656a3.043 3.043 0 00-2.823.503l-3.185 2.547-.617-1.235A3.98 3.98 0 009.146 11H4c-1.103 0-2 .897-2 2v6c0 1.103.897 2 2 2zm0-8h5.146c.763 0 1.448.423 1.789 1.105l.447.895H7v2h6.014a.996.996 0 00.442-.11l.003-.001.004-.002h.003l.002-.001h.004l.001-.001c.009.003.003-.001.003-.001.01 0 .002-.001.002-.001h.001l.002-.001.003-.001.002-.001.002-.001.003-.001.002-.001c.003 0 .001-.001.002-.001l.003-.002.002-.001.002-.001.003-.001.002-.001h.001l.002-.001h.001l.002-.001.002-.001c.009-.001.003-.001.003-.001l.002-.001a.915.915 0 00.11-.078l4.146-3.317c.262-.208.623-.273.94-.167l.557.186-4.133 4.823a2.029 2.029 0 01-1.52.688H4v-6zM16 2h-.017c-.163.002-1.006.039-1.983.705-.951-.648-1.774-.7-1.968-.704L12.002 2h-.004c-.801 0-1.555.313-2.119.878C9.313 3.445 9 4.198 9 5s.313 1.555.861 2.104l3.414 3.586a1.006 1.006 0 001.45-.001l3.396-3.568C18.688 6.555 19 5.802 19 5s-.313-1.555-.878-2.121A2.978 2.978 0 0016.002 2H16zm1 3c0 .267-.104.518-.311.725L14 8.55l-2.707-2.843C11.104 5.518 11 5.267 11 5s.104-.518.294-.708A.977.977 0 0111.979 4c.025.001.502.032 1.067.485.081.065.163.139.247.222l.707.707.707-.707c.084-.083.166-.157.247-.222.529-.425.976-.478 1.052-.484a.987.987 0 01.701.292c.189.189.293.44.293.707z"
|
|
22184
22286
|
})));
|
|
22185
22287
|
}
|
|
@@ -22506,9 +22608,10 @@ class Dashboard extends React.Component {
|
|
|
22506
22608
|
}) => {
|
|
22507
22609
|
if (isGift) {
|
|
22508
22610
|
this.props.setProductAndPlan(null, null, true);
|
|
22611
|
+
return this.props.setView("plan-select");
|
|
22509
22612
|
}
|
|
22510
22613
|
|
|
22511
|
-
return this.props.setView("
|
|
22614
|
+
return this.props.setView("subscription-options");
|
|
22512
22615
|
});
|
|
22513
22616
|
|
|
22514
22617
|
_defineProperty$3(this, "displayAddressCreate", () => {
|
|
@@ -22974,7 +23077,7 @@ const DashboardOpenButton = () => {
|
|
|
22974
23077
|
};
|
|
22975
23078
|
DashboardOpenButton.viewId = "dashboard-open";
|
|
22976
23079
|
|
|
22977
|
-
const initialState$
|
|
23080
|
+
const initialState$3 = {
|
|
22978
23081
|
imageSrc: null,
|
|
22979
23082
|
crop: {
|
|
22980
23083
|
x: 0,
|
|
@@ -22988,10 +23091,10 @@ const initialState$2 = {
|
|
|
22988
23091
|
content: ""
|
|
22989
23092
|
}
|
|
22990
23093
|
};
|
|
22991
|
-
const store$
|
|
23094
|
+
const store$3 = /*#__PURE__*/React.createContext(initialState$3);
|
|
22992
23095
|
const {
|
|
22993
|
-
Provider: Provider$
|
|
22994
|
-
} = store$
|
|
23096
|
+
Provider: Provider$3
|
|
23097
|
+
} = store$3;
|
|
22995
23098
|
|
|
22996
23099
|
const ProfilePicChangeContainer = ({
|
|
22997
23100
|
style,
|
|
@@ -23125,21 +23228,21 @@ const ProfilePicChangeContainer = ({
|
|
|
23125
23228
|
default:
|
|
23126
23229
|
return state;
|
|
23127
23230
|
}
|
|
23128
|
-
}, initialState$
|
|
23231
|
+
}, initialState$3);
|
|
23129
23232
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
23130
23233
|
style: { ...style
|
|
23131
23234
|
},
|
|
23132
23235
|
className: `pelcro-container pelcro-profile-picture-container ${className}`
|
|
23133
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
23236
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$3, {
|
|
23134
23237
|
value: {
|
|
23135
23238
|
state,
|
|
23136
23239
|
dispatch
|
|
23137
23240
|
}
|
|
23138
23241
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
23139
|
-
store: store$
|
|
23242
|
+
store: store$3,
|
|
23140
23243
|
key: i
|
|
23141
23244
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
23142
|
-
store: store$
|
|
23245
|
+
store: store$3
|
|
23143
23246
|
})));
|
|
23144
23247
|
};
|
|
23145
23248
|
/**
|
|
@@ -23201,7 +23304,7 @@ const ProfilePicChangeButton = ({
|
|
|
23201
23304
|
isSubmitting
|
|
23202
23305
|
},
|
|
23203
23306
|
dispatch
|
|
23204
|
-
} = React.useContext(store$
|
|
23307
|
+
} = React.useContext(store$3);
|
|
23205
23308
|
const {
|
|
23206
23309
|
t
|
|
23207
23310
|
} = useTranslation("userEdit");
|
|
@@ -24569,7 +24672,7 @@ const ProfilePicChangeCropper = ({
|
|
|
24569
24672
|
zoom
|
|
24570
24673
|
},
|
|
24571
24674
|
dispatch
|
|
24572
|
-
} = React.useContext(store$
|
|
24675
|
+
} = React.useContext(store$3);
|
|
24573
24676
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
24574
24677
|
className: `plc-relative plc-w-full plc-h-52 sm:plc-h-96 ${className}`
|
|
24575
24678
|
}, /*#__PURE__*/React__default['default'].createElement(Cropper, Object.assign({
|
|
@@ -24611,7 +24714,7 @@ const ProfilePicChangeZoom = ({
|
|
|
24611
24714
|
zoom
|
|
24612
24715
|
},
|
|
24613
24716
|
dispatch
|
|
24614
|
-
} = React.useContext(store$
|
|
24717
|
+
} = React.useContext(store$3);
|
|
24615
24718
|
const {
|
|
24616
24719
|
t
|
|
24617
24720
|
} = useTranslation("userEdit");
|
|
@@ -24634,18 +24737,18 @@ const ProfilePicChangeZoom = ({
|
|
|
24634
24737
|
}, otherProps)));
|
|
24635
24738
|
};
|
|
24636
24739
|
|
|
24637
|
-
var _path$
|
|
24740
|
+
var _path$2;
|
|
24638
24741
|
|
|
24639
|
-
function _extends$
|
|
24742
|
+
function _extends$2() { _extends$2 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$2.apply(this, arguments); }
|
|
24640
24743
|
|
|
24641
24744
|
function SvgPhotograph(props) {
|
|
24642
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
24745
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$2({
|
|
24643
24746
|
xmlns: "http://www.w3.org/2000/svg",
|
|
24644
24747
|
className: "plc-h-6 plc-w-6",
|
|
24645
24748
|
fill: "none",
|
|
24646
24749
|
viewBox: "0 0 24 24",
|
|
24647
24750
|
stroke: "currentColor"
|
|
24648
|
-
}, props), _path$
|
|
24751
|
+
}, props), _path$2 || (_path$2 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
24649
24752
|
strokeLinecap: "round",
|
|
24650
24753
|
strokeLinejoin: "round",
|
|
24651
24754
|
strokeWidth: 2,
|
|
@@ -24663,7 +24766,7 @@ const ProfilePicChangeSelectButton = ({
|
|
|
24663
24766
|
state: {
|
|
24664
24767
|
isSubmitting
|
|
24665
24768
|
}
|
|
24666
|
-
} = React.useContext(store$
|
|
24769
|
+
} = React.useContext(store$3);
|
|
24667
24770
|
const {
|
|
24668
24771
|
t
|
|
24669
24772
|
} = useTranslation("userEdit");
|
|
@@ -24705,7 +24808,7 @@ const ProfilePicChangeRemoveButton = ({
|
|
|
24705
24808
|
state: {
|
|
24706
24809
|
isSubmitting
|
|
24707
24810
|
}
|
|
24708
|
-
} = React.useContext(store$
|
|
24811
|
+
} = React.useContext(store$3);
|
|
24709
24812
|
const {
|
|
24710
24813
|
t
|
|
24711
24814
|
} = useTranslation("userEdit");
|
|
@@ -24728,7 +24831,7 @@ const ProfilePicChangeWrapper = () => {
|
|
|
24728
24831
|
state: {
|
|
24729
24832
|
imageSrc
|
|
24730
24833
|
}
|
|
24731
|
-
} = React.useContext(store$
|
|
24834
|
+
} = React.useContext(store$3);
|
|
24732
24835
|
const {
|
|
24733
24836
|
t
|
|
24734
24837
|
} = useTranslation("userEdit");
|
|
@@ -24790,17 +24893,17 @@ function ProfilePicChangeModal({
|
|
|
24790
24893
|
}
|
|
24791
24894
|
ProfilePicChangeModal.viewId = "profile-picture";
|
|
24792
24895
|
|
|
24793
|
-
const initialState$
|
|
24896
|
+
const initialState$2 = {
|
|
24794
24897
|
isSubmitting: false,
|
|
24795
24898
|
alert: {
|
|
24796
24899
|
type: "error",
|
|
24797
24900
|
content: ""
|
|
24798
24901
|
}
|
|
24799
24902
|
};
|
|
24800
|
-
const store$
|
|
24903
|
+
const store$2 = /*#__PURE__*/React.createContext(initialState$2);
|
|
24801
24904
|
const {
|
|
24802
|
-
Provider: Provider$
|
|
24803
|
-
} = store$
|
|
24905
|
+
Provider: Provider$2
|
|
24906
|
+
} = store$2;
|
|
24804
24907
|
|
|
24805
24908
|
const EmailVerifyContainer = ({
|
|
24806
24909
|
style,
|
|
@@ -24863,21 +24966,21 @@ const EmailVerifyContainer = ({
|
|
|
24863
24966
|
default:
|
|
24864
24967
|
return state;
|
|
24865
24968
|
}
|
|
24866
|
-
}, initialState$
|
|
24969
|
+
}, initialState$2);
|
|
24867
24970
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
24868
24971
|
style: { ...style
|
|
24869
24972
|
},
|
|
24870
24973
|
className: `pelcro-container pelcro-email-verify-container ${className}`
|
|
24871
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider$
|
|
24974
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$2, {
|
|
24872
24975
|
value: {
|
|
24873
24976
|
state,
|
|
24874
24977
|
dispatch
|
|
24875
24978
|
}
|
|
24876
24979
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
24877
|
-
store: store$
|
|
24980
|
+
store: store$2,
|
|
24878
24981
|
key: i
|
|
24879
24982
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
24880
|
-
store: store$
|
|
24983
|
+
store: store$2
|
|
24881
24984
|
})));
|
|
24882
24985
|
};
|
|
24883
24986
|
|
|
@@ -24891,7 +24994,7 @@ const EmailVerifyResendButton = ({
|
|
|
24891
24994
|
state: {
|
|
24892
24995
|
isSubmitting
|
|
24893
24996
|
}
|
|
24894
|
-
} = React.useContext(store$
|
|
24997
|
+
} = React.useContext(store$2);
|
|
24895
24998
|
const {
|
|
24896
24999
|
t
|
|
24897
25000
|
} = useTranslation("verifyEmail");
|
|
@@ -24906,16 +25009,16 @@ const EmailVerifyResendButton = ({
|
|
|
24906
25009
|
}, otherProps), name !== null && name !== void 0 ? name : t("labels.resend"));
|
|
24907
25010
|
};
|
|
24908
25011
|
|
|
24909
|
-
var _path, _path2;
|
|
25012
|
+
var _path$1, _path2;
|
|
24910
25013
|
|
|
24911
|
-
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25014
|
+
function _extends$1() { _extends$1 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$1.apply(this, arguments); }
|
|
24912
25015
|
|
|
24913
25016
|
function SvgEmailVerify(props) {
|
|
24914
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
25017
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$1({
|
|
24915
25018
|
className: "plc-w-6 plc-h-6",
|
|
24916
25019
|
viewBox: "0 0 700 700",
|
|
24917
25020
|
xmlns: "http://www.w3.org/2000/svg"
|
|
24918
|
-
}, props), _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
|
|
25021
|
+
}, props), _path$1 || (_path$1 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
24919
25022
|
d: "M583.01 231.93a15.008 15.008 0 00-.887-3.875c-.562-1.254-1.129-2.508-1.695-3.762a14.686 14.686 0 00-1.898-1.789c-.438-.437-.653-1.027-1.153-1.414l-56.266-44.164v-52.484a15.555 15.555 0 00-15.554-15.555H434.56l-74.945-58.895a15.547 15.547 0 00-19.227 0l-74.945 58.895h-70.996a15.555 15.555 0 00-15.555 15.555v52.484l-56.266 44.16c-.496.39-.715.996-1.152 1.43v.004a13.37 13.37 0 00-1.898 1.773c-.22.426-.414.86-.59 1.305a14.158 14.158 0 00-1.106 2.457 15.009 15.009 0 00-.886 3.875c0 .48-.329.918-.329 1.398l.004 264.45a15.555 15.555 0 0015.555 15.555h435.55a15.555 15.555 0 0015.555-15.555v-264.45c0-.48-.278-.918-.325-1.398zm-41.176.809l-20.723 14.809v-31.11zm-191.83-150.73l34.223 26.883h-68.445zm-140 57.992h280v124.45c.07 1.593.383 3.168.934 4.664l-140.93 100.66-140.46-100.33c.214-.77.37-1.555.464-2.348zm-31.109 107.55l-20.719-14.81 20.719-16.27zm-31.113 234.67V263.56l193.18 137.99a15.562 15.562 0 0018.078 0l193.18-137.99v218.66z"
|
|
24920
25023
|
})), _path2 || (_path2 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
24921
25024
|
d: "M324.33 291.81a15.56 15.56 0 0020.582-.297l85.555-77.777a15.56 15.56 0 00-20.938-23.023l-75.398 68.539-44.023-37.723a15.54 15.54 0 00-11.46-4.106 15.553 15.553 0 00-8.758 27.718z"
|
|
@@ -25019,11 +25122,11 @@ const invoicePaymentSubmitButton = props => {
|
|
|
25019
25122
|
return /*#__PURE__*/React__default['default'].createElement(SubmitPaymentMethod, props);
|
|
25020
25123
|
};
|
|
25021
25124
|
|
|
25022
|
-
const initialState = {};
|
|
25023
|
-
const store = /*#__PURE__*/React.createContext(initialState);
|
|
25125
|
+
const initialState$1 = {};
|
|
25126
|
+
const store$1 = /*#__PURE__*/React.createContext(initialState$1);
|
|
25024
25127
|
const {
|
|
25025
|
-
Provider
|
|
25026
|
-
} = store;
|
|
25128
|
+
Provider: Provider$1
|
|
25129
|
+
} = store$1;
|
|
25027
25130
|
|
|
25028
25131
|
const InvoiceDetailsContainer = ({
|
|
25029
25132
|
style,
|
|
@@ -25044,21 +25147,21 @@ const InvoiceDetailsContainer = ({
|
|
|
25044
25147
|
default:
|
|
25045
25148
|
return state;
|
|
25046
25149
|
}
|
|
25047
|
-
}, initialState);
|
|
25150
|
+
}, initialState$1);
|
|
25048
25151
|
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
25049
25152
|
style: { ...style
|
|
25050
25153
|
},
|
|
25051
25154
|
className: `pelcro-container pelcro-invoice-details-container ${className}`
|
|
25052
|
-
}, /*#__PURE__*/React__default['default'].createElement(Provider, {
|
|
25155
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider$1, {
|
|
25053
25156
|
value: {
|
|
25054
25157
|
state,
|
|
25055
25158
|
dispatch
|
|
25056
25159
|
}
|
|
25057
25160
|
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
25058
|
-
store,
|
|
25161
|
+
store: store$1,
|
|
25059
25162
|
key: i
|
|
25060
25163
|
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
25061
|
-
store
|
|
25164
|
+
store: store$1
|
|
25062
25165
|
})));
|
|
25063
25166
|
};
|
|
25064
25167
|
|
|
@@ -25090,7 +25193,7 @@ const InvoiceDetailsPayButton = ({
|
|
|
25090
25193
|
}) => {
|
|
25091
25194
|
const {
|
|
25092
25195
|
dispatch
|
|
25093
|
-
} = React.useContext(store);
|
|
25196
|
+
} = React.useContext(store$1);
|
|
25094
25197
|
const {
|
|
25095
25198
|
t
|
|
25096
25199
|
} = useTranslation("invoiceDetails");
|
|
@@ -25195,6 +25298,232 @@ const InvoiceDetailsModal = ({
|
|
|
25195
25298
|
};
|
|
25196
25299
|
InvoiceDetailsModal.viewId = "invoice-details";
|
|
25197
25300
|
|
|
25301
|
+
const initialState = {
|
|
25302
|
+
selectedOption: ""
|
|
25303
|
+
};
|
|
25304
|
+
const store = /*#__PURE__*/React.createContext(initialState);
|
|
25305
|
+
const {
|
|
25306
|
+
Provider
|
|
25307
|
+
} = store;
|
|
25308
|
+
|
|
25309
|
+
const SubscriptionOptionsContainer = ({
|
|
25310
|
+
style,
|
|
25311
|
+
className = "",
|
|
25312
|
+
onRenewSubSuccess = () => {},
|
|
25313
|
+
onNewSubSuccess = () => {},
|
|
25314
|
+
children,
|
|
25315
|
+
...props
|
|
25316
|
+
}) => {
|
|
25317
|
+
const submit = ({
|
|
25318
|
+
selectedOption
|
|
25319
|
+
}, dispatch) => {
|
|
25320
|
+
if (selectedOption === "renew") return onRenewSubSuccess();
|
|
25321
|
+
if (selectedOption === "new") return onNewSubSuccess();
|
|
25322
|
+
};
|
|
25323
|
+
|
|
25324
|
+
const [state, dispatch] = useReducerWithSideEffects((state, action) => {
|
|
25325
|
+
switch (action.type) {
|
|
25326
|
+
case SWITCH_TO_NEW:
|
|
25327
|
+
return lib_7({ ...state,
|
|
25328
|
+
selectedOption: "new"
|
|
25329
|
+
});
|
|
25330
|
+
|
|
25331
|
+
case SWITCH_TO_RENEW:
|
|
25332
|
+
return lib_7({ ...state,
|
|
25333
|
+
selectedOption: "renew"
|
|
25334
|
+
});
|
|
25335
|
+
|
|
25336
|
+
case HANDLE_SUBMIT:
|
|
25337
|
+
return lib_4((state, dispatch) => submit(state));
|
|
25338
|
+
|
|
25339
|
+
default:
|
|
25340
|
+
return state;
|
|
25341
|
+
}
|
|
25342
|
+
}, initialState);
|
|
25343
|
+
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
25344
|
+
style: { ...style
|
|
25345
|
+
},
|
|
25346
|
+
className: `pelcro-container pelcro-subscription-options-container ${className}`
|
|
25347
|
+
}, /*#__PURE__*/React__default['default'].createElement(Provider, {
|
|
25348
|
+
value: {
|
|
25349
|
+
state,
|
|
25350
|
+
dispatch
|
|
25351
|
+
}
|
|
25352
|
+
}, children.length ? children.map((child, i) => /*#__PURE__*/React__default['default'].cloneElement(child, {
|
|
25353
|
+
store,
|
|
25354
|
+
key: i
|
|
25355
|
+
})) : /*#__PURE__*/React__default['default'].cloneElement(children, {
|
|
25356
|
+
store
|
|
25357
|
+
})));
|
|
25358
|
+
};
|
|
25359
|
+
|
|
25360
|
+
var _path;
|
|
25361
|
+
|
|
25362
|
+
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
25363
|
+
|
|
25364
|
+
function SvgPlusCircle(props) {
|
|
25365
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends({
|
|
25366
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
25367
|
+
className: "plc-h-6 plc-w-6",
|
|
25368
|
+
fill: "none",
|
|
25369
|
+
viewBox: "0 0 24 24",
|
|
25370
|
+
stroke: "currentColor",
|
|
25371
|
+
strokeWidth: 2
|
|
25372
|
+
}, props), _path || (_path = /*#__PURE__*/React__namespace.createElement("path", {
|
|
25373
|
+
strokeLinecap: "round",
|
|
25374
|
+
strokeLinejoin: "round",
|
|
25375
|
+
d: "M12 9v3m0 0v3m0-3h3m-3 0H9m12 0a9 9 0 11-18 0 9 9 0 0118 0z"
|
|
25376
|
+
})));
|
|
25377
|
+
}
|
|
25378
|
+
|
|
25379
|
+
const SubscriptionOptionsNewButton = ({
|
|
25380
|
+
name,
|
|
25381
|
+
onClick,
|
|
25382
|
+
...otherProps
|
|
25383
|
+
}) => {
|
|
25384
|
+
const {
|
|
25385
|
+
dispatch,
|
|
25386
|
+
state: {
|
|
25387
|
+
selectedOption
|
|
25388
|
+
}
|
|
25389
|
+
} = React.useContext(store);
|
|
25390
|
+
const {
|
|
25391
|
+
t
|
|
25392
|
+
} = useTranslation("subscriptionOptions");
|
|
25393
|
+
const isChecked = selectedOption === "new";
|
|
25394
|
+
return /*#__PURE__*/React__default['default'].createElement(Radio, Object.assign({
|
|
25395
|
+
className: "plc-hidden pelcro-new-sub-option",
|
|
25396
|
+
labelClassName: `plc-flex plc-flex-col plc-items-center plc-justify-center plc-text-lg plc-font-semibold plc-ml-0 plc-w-52 plc-h-52 plc-text-black plc-p-2 hover:plc-bg-gray-200 pelcro-new-sub-option-label plc-border-2 plc-text-center ${isChecked ? "plc-border-black" : "plc-border-gray-300"}`,
|
|
25397
|
+
id: "pelcro-new-sub-option",
|
|
25398
|
+
name: "option",
|
|
25399
|
+
onChange: () => {
|
|
25400
|
+
dispatch({
|
|
25401
|
+
type: SWITCH_TO_NEW
|
|
25402
|
+
});
|
|
25403
|
+
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
25404
|
+
},
|
|
25405
|
+
checked: isChecked
|
|
25406
|
+
}, otherProps), name !== null && name !== void 0 ? name : t("addNew"), /*#__PURE__*/React__default['default'].createElement(SvgPlusCircle, {
|
|
25407
|
+
className: "plc-w-full plc-h-full plc-mr-0"
|
|
25408
|
+
}));
|
|
25409
|
+
};
|
|
25410
|
+
|
|
25411
|
+
const SubscriptionOptionsRenewButton = ({
|
|
25412
|
+
name,
|
|
25413
|
+
onClick,
|
|
25414
|
+
...otherProps
|
|
25415
|
+
}) => {
|
|
25416
|
+
const {
|
|
25417
|
+
dispatch,
|
|
25418
|
+
state: {
|
|
25419
|
+
selectedOption
|
|
25420
|
+
}
|
|
25421
|
+
} = React.useContext(store);
|
|
25422
|
+
const {
|
|
25423
|
+
t
|
|
25424
|
+
} = useTranslation("subscriptionOptions");
|
|
25425
|
+
const isChecked = selectedOption === "renew";
|
|
25426
|
+
return /*#__PURE__*/React__default['default'].createElement(Radio, Object.assign({
|
|
25427
|
+
className: "plc-hidden pelcro-renew-sub-option",
|
|
25428
|
+
labelClassName: `plc-flex plc-flex-col plc-items-center plc-justify-center plc-text-lg plc-font-semibold plc-ml-0 plc-w-52 plc-h-52 plc-text-black plc-p-2 hover:plc-bg-gray-200 pelcro-renew-sub-option-label plc-border-2 plc-text-center ${isChecked ? "plc-border-black" : "plc-border-gray-300"}`,
|
|
25429
|
+
id: "pelcro-renew-sub-option",
|
|
25430
|
+
name: "option",
|
|
25431
|
+
onChange: () => {
|
|
25432
|
+
dispatch({
|
|
25433
|
+
type: SWITCH_TO_RENEW
|
|
25434
|
+
});
|
|
25435
|
+
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
25436
|
+
},
|
|
25437
|
+
checked: isChecked
|
|
25438
|
+
}, otherProps), name !== null && name !== void 0 ? name : t("renew"), /*#__PURE__*/React__default['default'].createElement(SvgRefresh, {
|
|
25439
|
+
className: "plc-w-full plc-h-full plc-mr-0"
|
|
25440
|
+
}));
|
|
25441
|
+
};
|
|
25442
|
+
|
|
25443
|
+
const SubscriptionOptionsSubmit = ({
|
|
25444
|
+
name,
|
|
25445
|
+
onClick,
|
|
25446
|
+
...otherProps
|
|
25447
|
+
}) => {
|
|
25448
|
+
const {
|
|
25449
|
+
dispatch,
|
|
25450
|
+
state: {
|
|
25451
|
+
selectedOption
|
|
25452
|
+
}
|
|
25453
|
+
} = React.useContext(store);
|
|
25454
|
+
const {
|
|
25455
|
+
t
|
|
25456
|
+
} = useTranslation("subscriptionOptions");
|
|
25457
|
+
return /*#__PURE__*/React__default['default'].createElement(Button, Object.assign({
|
|
25458
|
+
onClick: () => {
|
|
25459
|
+
dispatch({
|
|
25460
|
+
type: HANDLE_SUBMIT
|
|
25461
|
+
});
|
|
25462
|
+
onClick === null || onClick === void 0 ? void 0 : onClick();
|
|
25463
|
+
},
|
|
25464
|
+
disabled: !selectedOption
|
|
25465
|
+
}, otherProps), name !== null && name !== void 0 ? name : t("next"));
|
|
25466
|
+
};
|
|
25467
|
+
|
|
25468
|
+
const SubscriptionOptionsView = props => {
|
|
25469
|
+
const {
|
|
25470
|
+
t
|
|
25471
|
+
} = useTranslation("subscriptionOptions");
|
|
25472
|
+
return /*#__PURE__*/React__default['default'].createElement("div", {
|
|
25473
|
+
id: "pelcro-subscription-options-view"
|
|
25474
|
+
}, /*#__PURE__*/React__default['default'].createElement("div", {
|
|
25475
|
+
className: "plc-mb-6 plc-text-center plc-text-gray-900 pelcro-title-wrapper"
|
|
25476
|
+
}, /*#__PURE__*/React__default['default'].createElement("h4", {
|
|
25477
|
+
className: "plc-text-2xl plc-font-semibold"
|
|
25478
|
+
}, t("title")), /*#__PURE__*/React__default['default'].createElement("p", null, t("subtitle"))), /*#__PURE__*/React__default['default'].createElement("form", {
|
|
25479
|
+
action: "javascript:void(0);",
|
|
25480
|
+
className: "plc-mt-2 pelcro-form"
|
|
25481
|
+
}, /*#__PURE__*/React__default['default'].createElement(SubscriptionOptionsContainer, props, /*#__PURE__*/React__default['default'].createElement("div", {
|
|
25482
|
+
className: "plc-flex plc-justify-between plc-items-center"
|
|
25483
|
+
}, /*#__PURE__*/React__default['default'].createElement(SubscriptionOptionsRenewButton, null), /*#__PURE__*/React__default['default'].createElement(SubscriptionOptionsNewButton, null)), /*#__PURE__*/React__default['default'].createElement(SubscriptionOptionsSubmit, {
|
|
25484
|
+
role: "submit",
|
|
25485
|
+
className: "plc-mt-4 plc-w-full",
|
|
25486
|
+
name: t("next"),
|
|
25487
|
+
id: "pelcro-submit"
|
|
25488
|
+
}))));
|
|
25489
|
+
};
|
|
25490
|
+
|
|
25491
|
+
const SubscriptionOptionsModal = ({
|
|
25492
|
+
onDisplay,
|
|
25493
|
+
onClose,
|
|
25494
|
+
...otherProps
|
|
25495
|
+
}) => {
|
|
25496
|
+
const {
|
|
25497
|
+
switchView,
|
|
25498
|
+
setProductsList
|
|
25499
|
+
} = usePelcro();
|
|
25500
|
+
|
|
25501
|
+
const onRenewSubSuccess = () => {
|
|
25502
|
+
var _otherProps$onRenewSu;
|
|
25503
|
+
|
|
25504
|
+
(_otherProps$onRenewSu = otherProps.onRenewSubSuccess) === null || _otherProps$onRenewSu === void 0 ? void 0 : _otherProps$onRenewSu.call(otherProps);
|
|
25505
|
+
setProductsList(getRenewableProducts());
|
|
25506
|
+
switchView("_plan-select-renew");
|
|
25507
|
+
};
|
|
25508
|
+
|
|
25509
|
+
const onNewSubSuccess = () => {
|
|
25510
|
+
var _otherProps$onNewSubS;
|
|
25511
|
+
|
|
25512
|
+
(_otherProps$onNewSubS = otherProps.onNewSubSuccess) === null || _otherProps$onNewSubS === void 0 ? void 0 : _otherProps$onNewSubS.call(otherProps);
|
|
25513
|
+
switchView("plan-select");
|
|
25514
|
+
};
|
|
25515
|
+
|
|
25516
|
+
return /*#__PURE__*/React__default['default'].createElement(Modal, {
|
|
25517
|
+
onDisplay: onDisplay,
|
|
25518
|
+
onClose: onClose,
|
|
25519
|
+
id: "pelcro-subscription-options-modal"
|
|
25520
|
+
}, /*#__PURE__*/React__default['default'].createElement(ModalBody, null, /*#__PURE__*/React__default['default'].createElement(SubscriptionOptionsView, Object.assign({}, otherProps, {
|
|
25521
|
+
onNewSubSuccess: onNewSubSuccess,
|
|
25522
|
+
onRenewSubSuccess: onRenewSubSuccess
|
|
25523
|
+
}))), /*#__PURE__*/React__default['default'].createElement(ModalFooter, null, /*#__PURE__*/React__default['default'].createElement(Authorship, null)));
|
|
25524
|
+
};
|
|
25525
|
+
SubscriptionOptionsModal.viewId = "subscription-options";
|
|
25526
|
+
|
|
25198
25527
|
exports.AddressCreateCity = AddressCreateCity;
|
|
25199
25528
|
exports.AddressCreateContainer = AddressCreateContainer;
|
|
25200
25529
|
exports.AddressCreateCountrySelect = AddressCreateCountrySelect;
|
|
@@ -25372,6 +25701,12 @@ exports.SubmitPaymentMethod = SubmitPaymentMethod;
|
|
|
25372
25701
|
exports.SubscriptionCreateContainer = SubscriptionCreateContainer;
|
|
25373
25702
|
exports.SubscriptionCreateModal = SubscriptionCreateModal;
|
|
25374
25703
|
exports.SubscriptionCreateView = SubscriptionCreateView;
|
|
25704
|
+
exports.SubscriptionOptionsContainer = SubscriptionOptionsContainer;
|
|
25705
|
+
exports.SubscriptionOptionsModal = SubscriptionOptionsModal;
|
|
25706
|
+
exports.SubscriptionOptionsNewButton = SubscriptionOptionsNewButton;
|
|
25707
|
+
exports.SubscriptionOptionsRenewButton = SubscriptionOptionsRenewButton;
|
|
25708
|
+
exports.SubscriptionOptionsSubmit = SubscriptionOptionsSubmit;
|
|
25709
|
+
exports.SubscriptionOptionsView = SubscriptionOptionsView;
|
|
25375
25710
|
exports.SubscriptionRenewContainer = SubscriptionRenewContainer;
|
|
25376
25711
|
exports.SubscriptionRenewModal = SubscriptionRenewModal;
|
|
25377
25712
|
exports.SubscriptionRenewView = SubscriptionRenewView;
|