igloo-d2c-components 1.0.14 → 1.0.15
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/cjs/index.js +46 -6
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +46 -6
- package/dist/esm/index.js.map +1 -1
- package/dist/types/components/ContactDetailsForm/ContactDetailsForm.d.ts +12 -1
- package/dist/types/components/ContactDetailsForm/styled.d.ts +3 -0
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
|
@@ -2102,7 +2102,7 @@ function BillingToggle({ value, onChange, formatMessage = (descriptor) => descri
|
|
|
2102
2102
|
const toggleBgColor = getThemeColor(theme, 'ui.sliderBackground', '#f9f9f9');
|
|
2103
2103
|
return (jsxRuntime.jsxs(ToggleContainer, Object.assign({ sx: {
|
|
2104
2104
|
backgroundColor: toggleBgColor,
|
|
2105
|
-
} }, { children: [jsxRuntime.jsx(ToggleButton, Object.assign({ active: value === '
|
|
2105
|
+
} }, { children: [jsxRuntime.jsx(ToggleButton, Object.assign({ active: value === 'annually', onClick: () => onChange('monthly'), sx: {
|
|
2106
2106
|
backgroundColor: value === 'monthly' ? toggleActiveColor : 'transparent',
|
|
2107
2107
|
color: value === 'monthly'
|
|
2108
2108
|
? toggleActiveTextColor
|
|
@@ -2638,7 +2638,7 @@ const HeaderContainer = styles.styled(material.Box)(({ sticky }) => (Object.assi
|
|
|
2638
2638
|
const SectionHeader = styles.styled(material.Box)({
|
|
2639
2639
|
padding: '0 16px 24px',
|
|
2640
2640
|
});
|
|
2641
|
-
const SectionTitle$
|
|
2641
|
+
const SectionTitle$2 = styles.styled(material.Typography)({
|
|
2642
2642
|
fontFamily: 'Montserrat',
|
|
2643
2643
|
fontSize: '20px',
|
|
2644
2644
|
fontWeight: 700,
|
|
@@ -2655,7 +2655,7 @@ const SectionDescription = styles.styled(material.Typography)({
|
|
|
2655
2655
|
});
|
|
2656
2656
|
|
|
2657
2657
|
const CheckoutHeader = ({ progress, product, sectionTitle, sectionDescription, sticky = true, progressBarTheme, sx, }) => {
|
|
2658
|
-
return (jsxRuntime.jsxs(HeaderContainer, Object.assign({ sticky: sticky, sx: sx }, { children: [jsxRuntime.jsx(CheckoutProgress, Object.assign({}, progress, { progressBarTheme: progressBarTheme })), product && (jsxRuntime.jsx(material.Box, Object.assign({ sx: { padding: '0 16px 24px' } }, { children: jsxRuntime.jsx(ProductCard, Object.assign({}, product)) }))), jsxRuntime.jsxs(SectionHeader, { children: [jsxRuntime.jsx(SectionTitle$
|
|
2658
|
+
return (jsxRuntime.jsxs(HeaderContainer, Object.assign({ sticky: sticky, sx: sx }, { children: [jsxRuntime.jsx(CheckoutProgress, Object.assign({}, progress, { progressBarTheme: progressBarTheme })), product && (jsxRuntime.jsx(material.Box, Object.assign({ sx: { padding: '0 16px 24px' } }, { children: jsxRuntime.jsx(ProductCard, Object.assign({}, product)) }))), jsxRuntime.jsxs(SectionHeader, { children: [jsxRuntime.jsx(SectionTitle$2, { children: sectionTitle }), jsxRuntime.jsx(SectionDescription, { children: sectionDescription })] })] })));
|
|
2659
2659
|
};
|
|
2660
2660
|
|
|
2661
2661
|
const ButtonContainer = styles.styled(material.Box)(({ isFixed }) => ({
|
|
@@ -2807,9 +2807,16 @@ const CheckboxLabel = styles.styled(material.Typography)({
|
|
|
2807
2807
|
color: '#5F5E62',
|
|
2808
2808
|
lineHeight: '18px',
|
|
2809
2809
|
});
|
|
2810
|
+
const SectionTitle$1 = styles.styled(material.Typography)({
|
|
2811
|
+
fontFamily: 'Montserrat',
|
|
2812
|
+
fontSize: '16px',
|
|
2813
|
+
fontWeight: 600,
|
|
2814
|
+
color: '#13131B',
|
|
2815
|
+
lineHeight: '24px',
|
|
2816
|
+
});
|
|
2810
2817
|
|
|
2811
|
-
const ContactDetailsForm = ({ renderField, fields, mailingAddressSame, onSubmit, formRef, sx, }) => {
|
|
2812
|
-
const defaultMailingLabel = 'My mailing address is the same as residential';
|
|
2818
|
+
const ContactDetailsForm = ({ renderField, fields, mailingFields, mailingAddressSame, onSubmit, formRef, sx, }) => {
|
|
2819
|
+
const defaultMailingLabel = 'My mailing address is not the same as residential';
|
|
2813
2820
|
return (jsxRuntime.jsx(FormContainer$2, Object.assign({ ref: formRef, component: "form", onSubmit: onSubmit, sx: sx }, { children: jsxRuntime.jsxs(material.Box, Object.assign({ sx: { display: 'flex', flexDirection: 'column', gap: '24px' } }, { children: [jsxRuntime.jsxs(material.Box, { children: [renderField(fields.phone_number), fields.phone_number.helperText && (jsxRuntime.jsx(material.Box, Object.assign({ component: "span", sx: {
|
|
2814
2821
|
display: 'block',
|
|
2815
2822
|
mt: 0.5,
|
|
@@ -2817,7 +2824,40 @@ const ContactDetailsForm = ({ renderField, fields, mailingAddressSame, onSubmit,
|
|
|
2817
2824
|
color: '#5F5E62',
|
|
2818
2825
|
fontSize: '12px',
|
|
2819
2826
|
fontFamily: 'Montserrat',
|
|
2820
|
-
} }, { children: fields.phone_number.helperText })))] }), renderField(fields.email_address),
|
|
2827
|
+
} }, { children: fields.phone_number.helperText })))] }), renderField(fields.email_address), jsxRuntime.jsx(material.Divider, { sx: { borderColor: 'rgba(0,0,0,0.1)' } }), jsxRuntime.jsx(SectionTitle$1, { children: "Residential address" }), jsxRuntime.jsxs(material.Box, { children: [renderField(fields.residential_address_line1), fields.residential_address_line1.helperText && (jsxRuntime.jsx(material.Box, Object.assign({ component: "span", sx: {
|
|
2828
|
+
display: 'block',
|
|
2829
|
+
mt: 0.5,
|
|
2830
|
+
ml: 2,
|
|
2831
|
+
color: '#5F5E62',
|
|
2832
|
+
fontSize: '12px',
|
|
2833
|
+
fontFamily: 'Montserrat',
|
|
2834
|
+
} }, { children: fields.residential_address_line1.helperText })))] }), jsxRuntime.jsxs(material.Box, { children: [renderField(fields.residential_address_line2), fields.residential_address_line2.helperText && (jsxRuntime.jsx(material.Box, Object.assign({ component: "span", sx: {
|
|
2835
|
+
display: 'block',
|
|
2836
|
+
mt: 0.5,
|
|
2837
|
+
ml: 2,
|
|
2838
|
+
color: '#5F5E62',
|
|
2839
|
+
fontSize: '12px',
|
|
2840
|
+
fontFamily: 'Montserrat',
|
|
2841
|
+
} }, { children: fields.residential_address_line2.helperText })))] }), renderField(fields.postal_code), renderField(fields.city), renderField(fields.state), jsxRuntime.jsx(material.Divider, { sx: { borderColor: 'rgba(0,0,0,0.1)' } }), (mailingAddressSame === null || mailingAddressSame === void 0 ? void 0 : mailingAddressSame.checked) && mailingFields && (jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [jsxRuntime.jsx(SectionTitle$1, { children: "Mailing address" }), jsxRuntime.jsxs(material.Box, { children: [renderField(mailingFields.mailing_address_line1), mailingFields.mailing_address_line1.helperText && (jsxRuntime.jsx(material.Box, Object.assign({ component: "span", sx: {
|
|
2842
|
+
display: 'block',
|
|
2843
|
+
mt: 0.5,
|
|
2844
|
+
ml: 2,
|
|
2845
|
+
color: '#5F5E62',
|
|
2846
|
+
fontSize: '12px',
|
|
2847
|
+
fontFamily: 'Montserrat',
|
|
2848
|
+
} }, { children: mailingFields.mailing_address_line1.helperText })))] }), jsxRuntime.jsxs(material.Box, { children: [renderField(mailingFields.mailing_address_line2), mailingFields.mailing_address_line2.helperText && (jsxRuntime.jsx(material.Box, Object.assign({ component: "span", sx: {
|
|
2849
|
+
display: 'block',
|
|
2850
|
+
mt: 0.5,
|
|
2851
|
+
ml: 2,
|
|
2852
|
+
color: '#5F5E62',
|
|
2853
|
+
fontSize: '12px',
|
|
2854
|
+
fontFamily: 'Montserrat',
|
|
2855
|
+
} }, { children: mailingFields.mailing_address_line2.helperText })))] }), renderField(mailingFields.mailing_postal_code), renderField(mailingFields.mailing_city), renderField(mailingFields.mailing_state)] })), mailingAddressSame && (jsxRuntime.jsx(CheckboxContainer, { children: jsxRuntime.jsx(material.FormControlLabel, { control: jsxRuntime.jsx(material.Checkbox, { checked: mailingAddressSame.checked, onChange: (e) => mailingAddressSame.onChange(e.target.checked), name: "mailing_not_same_as_residential", sx: {
|
|
2856
|
+
color: '#929094',
|
|
2857
|
+
'&.Mui-checked': {
|
|
2858
|
+
color: '#317abc',
|
|
2859
|
+
},
|
|
2860
|
+
} }), label: jsxRuntime.jsx(CheckboxLabel, { children: mailingAddressSame.label || defaultMailingLabel }) }) }))] })) })));
|
|
2821
2861
|
};
|
|
2822
2862
|
|
|
2823
2863
|
const FormContainer$1 = styles.styled(material.Box)({
|