diy-template-components 2.0.16 → 2.0.17
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/build/index.es.js +54 -9
- package/build/index.es.js.map +1 -1
- package/build/index.js +54 -9
- package/build/index.js.map +1 -1
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -362,9 +362,10 @@ const buttonStyles = createUseStyles(theme => ({
|
|
|
362
362
|
color: ({
|
|
363
363
|
disabled
|
|
364
364
|
} = {}) => disabled ? colorMixer(theme?.palette?.background?.default, 0.5).color : theme?.colors?.CtaTextColor,
|
|
365
|
-
background:
|
|
365
|
+
background: theme?.colors?.ctaColor,
|
|
366
|
+
opacity: ({
|
|
366
367
|
disabled
|
|
367
|
-
} = {}) => disabled ?
|
|
368
|
+
} = {}) => disabled ? 0.5 : 1,
|
|
368
369
|
border: 'none',
|
|
369
370
|
textDecoration: 'none',
|
|
370
371
|
cursor: ({
|
|
@@ -388,9 +389,10 @@ const buttonStyles = createUseStyles(theme => ({
|
|
|
388
389
|
color: ({
|
|
389
390
|
disabled
|
|
390
391
|
} = {}) => disabled ? colorMixer(theme.palette.primary.main, 0.5).color : theme?.colors?.CtaTextColor,
|
|
391
|
-
background:
|
|
392
|
+
background: theme?.colors?.ctaColor,
|
|
393
|
+
opacity: ({
|
|
392
394
|
disabled
|
|
393
|
-
} = {}) => disabled ?
|
|
395
|
+
} = {}) => disabled ? 0.5 : 1,
|
|
394
396
|
border: ({
|
|
395
397
|
disabled
|
|
396
398
|
} = {}) => disabled ? `1px solid ${colorMixer(theme.palette.primary.main, 0.5).color}` : `1px solid ${theme?.colors?.ctaColor}`,
|
|
@@ -1081,6 +1083,7 @@ function OptionList({
|
|
|
1081
1083
|
const downloadAppText = countryCode === 'KR' ? '앱다운로드' : 'Download App';
|
|
1082
1084
|
const renderDownloadAppButton = () => {
|
|
1083
1085
|
return /*#__PURE__*/React.createElement(React.Fragment, null, apkURL && /*#__PURE__*/React.createElement("a", {
|
|
1086
|
+
download: true,
|
|
1084
1087
|
href: headerData?.apkURL,
|
|
1085
1088
|
target: "_blank",
|
|
1086
1089
|
className: classes.socialBtnItems,
|
|
@@ -1414,7 +1417,7 @@ function MobileHeader({
|
|
|
1414
1417
|
onClick: () => {
|
|
1415
1418
|
let url = getAppDownloadLink(apkURL, iosDownloadLink);
|
|
1416
1419
|
window.open(url, '_blank');
|
|
1417
|
-
if (
|
|
1420
|
+
if (!header?.iosUrl && typeof onDownloadAppTriggered == 'function') {
|
|
1418
1421
|
onDownloadAppTriggered(header?.isAndroidDelisted, header?.apkURL);
|
|
1419
1422
|
}
|
|
1420
1423
|
}
|
|
@@ -1449,7 +1452,7 @@ function MobileHeader({
|
|
|
1449
1452
|
onClick: () => {
|
|
1450
1453
|
let url = getAppDownloadLink(apkURL, iosDownloadLink);
|
|
1451
1454
|
window.open(url, '_blank');
|
|
1452
|
-
if (
|
|
1455
|
+
if (!header?.iosUrl && typeof onDownloadAppTriggered == 'function') {
|
|
1453
1456
|
onDownloadAppTriggered(header?.isAndroidDelisted, header?.apkURL);
|
|
1454
1457
|
}
|
|
1455
1458
|
}
|
|
@@ -1590,6 +1593,7 @@ const useSectionStyles$9 = createUseStyles(theme => ({
|
|
|
1590
1593
|
|
|
1591
1594
|
// '& img': { maxHeight: '55px' }
|
|
1592
1595
|
},
|
|
1596
|
+
|
|
1593
1597
|
upperContainerItem1Img: {
|
|
1594
1598
|
maxHeight: '55px',
|
|
1595
1599
|
paddingBottom: '84px',
|
|
@@ -2016,6 +2020,7 @@ const mobilePadding = {
|
|
|
2016
2020
|
// 24px
|
|
2017
2021
|
medium: baseFactor * 6 // 48px
|
|
2018
2022
|
};
|
|
2023
|
+
|
|
2019
2024
|
const padding = {
|
|
2020
2025
|
minute: baseFactor * 2,
|
|
2021
2026
|
// 16px
|
|
@@ -2481,6 +2486,7 @@ const useSectionStyles$8 = createUseStyles(theme => ({
|
|
|
2481
2486
|
// }
|
|
2482
2487
|
// }
|
|
2483
2488
|
},
|
|
2489
|
+
|
|
2484
2490
|
sectionContainer: {
|
|
2485
2491
|
margin: '0 auto',
|
|
2486
2492
|
maxWidth: ({
|
|
@@ -3050,6 +3056,7 @@ const useSectionStyles$7 = createUseStyles(theme => ({
|
|
|
3050
3056
|
// padding: '0'
|
|
3051
3057
|
}
|
|
3052
3058
|
},
|
|
3059
|
+
|
|
3053
3060
|
'&:nth-child(2n+1)': {
|
|
3054
3061
|
marginRight: '0',
|
|
3055
3062
|
'& $contentText': {
|
|
@@ -3059,6 +3066,7 @@ const useSectionStyles$7 = createUseStyles(theme => ({
|
|
|
3059
3066
|
}
|
|
3060
3067
|
}
|
|
3061
3068
|
},
|
|
3069
|
+
|
|
3062
3070
|
contentNumber: {
|
|
3063
3071
|
width: '100%',
|
|
3064
3072
|
padding: '24px',
|
|
@@ -3451,6 +3459,7 @@ const useSectionStyles$5 = createUseStyles(theme => {
|
|
|
3451
3459
|
// }
|
|
3452
3460
|
// }
|
|
3453
3461
|
},
|
|
3462
|
+
|
|
3454
3463
|
sectionContainer: {
|
|
3455
3464
|
margin: '0 auto',
|
|
3456
3465
|
maxWidth: ({
|
|
@@ -3464,6 +3473,7 @@ const useSectionStyles$5 = createUseStyles(theme => {
|
|
|
3464
3473
|
|
|
3465
3474
|
// padding: `${theme?.spacing?.padding?.regular}px ${theme?.spacing?.padding?.medium}px 0px ${theme?.spacing?.padding?.medium}px`
|
|
3466
3475
|
},
|
|
3476
|
+
|
|
3467
3477
|
imageContainerDiv: {
|
|
3468
3478
|
width: '50%',
|
|
3469
3479
|
position: 'relative'
|
|
@@ -3535,6 +3545,7 @@ const useSectionStyles$5 = createUseStyles(theme => {
|
|
|
3535
3545
|
width: '100%'
|
|
3536
3546
|
// padding: `${theme?.spacing?.padding?.medium}px ${theme?.spacing?.padding?.regular}px`
|
|
3537
3547
|
},
|
|
3548
|
+
|
|
3538
3549
|
imageContainer: {
|
|
3539
3550
|
height: 'unset !important',
|
|
3540
3551
|
'& img': {
|
|
@@ -4541,6 +4552,7 @@ const useVideoTestimonialStyles = createUseStyles(theme => {
|
|
|
4541
4552
|
fontFamily: theme?.typography?.fontFamily
|
|
4542
4553
|
// boxSizing: 'border-box'
|
|
4543
4554
|
},
|
|
4555
|
+
|
|
4544
4556
|
'& h2,& h3,& p': {
|
|
4545
4557
|
marginTop: '0'
|
|
4546
4558
|
}
|
|
@@ -4565,6 +4577,7 @@ const useVideoTestimonialStyles = createUseStyles(theme => {
|
|
|
4565
4577
|
wordBreak: 'break-word'
|
|
4566
4578
|
// marginBottom: '8px'
|
|
4567
4579
|
},
|
|
4580
|
+
|
|
4568
4581
|
videoTestimonialTitle: {
|
|
4569
4582
|
fontSize: theme.typography.fontSize.h2,
|
|
4570
4583
|
// lineHeight: '71px',
|
|
@@ -5005,6 +5018,7 @@ const useSectionStyles$3 = createUseStyles(theme => ({
|
|
|
5005
5018
|
// }
|
|
5006
5019
|
// }
|
|
5007
5020
|
},
|
|
5021
|
+
|
|
5008
5022
|
sectionContainer: {
|
|
5009
5023
|
margin: '0 auto',
|
|
5010
5024
|
maxWidth: ({
|
|
@@ -5362,6 +5376,7 @@ const usePhotoGalleryStyles = createUseStyles(theme => {
|
|
|
5362
5376
|
// }
|
|
5363
5377
|
// }
|
|
5364
5378
|
},
|
|
5379
|
+
|
|
5365
5380
|
sectionContainer: {
|
|
5366
5381
|
margin: '0 auto',
|
|
5367
5382
|
maxWidth: ({
|
|
@@ -5392,6 +5407,7 @@ const usePhotoGalleryStyles = createUseStyles(theme => {
|
|
|
5392
5407
|
position: 'relative',
|
|
5393
5408
|
paddingBottom: '59.83%' // keeping aspect ratio 585x350
|
|
5394
5409
|
},
|
|
5410
|
+
|
|
5395
5411
|
contentRow: {
|
|
5396
5412
|
display: 'grid',
|
|
5397
5413
|
gridTemplateColumns: ({
|
|
@@ -5938,6 +5954,7 @@ const useCourseStyles = createUseStyles(theme => {
|
|
|
5938
5954
|
// }
|
|
5939
5955
|
// }
|
|
5940
5956
|
},
|
|
5957
|
+
|
|
5941
5958
|
sectionContainer: {
|
|
5942
5959
|
margin: '0 auto',
|
|
5943
5960
|
maxWidth: ({
|
|
@@ -5970,6 +5987,7 @@ const useCourseStyles = createUseStyles(theme => {
|
|
|
5970
5987
|
// textAlign: 'center',
|
|
5971
5988
|
// wordBreak: 'break-word'
|
|
5972
5989
|
},
|
|
5990
|
+
|
|
5973
5991
|
slickContainer: {
|
|
5974
5992
|
marginRight: '-20px'
|
|
5975
5993
|
},
|
|
@@ -6017,6 +6035,7 @@ const useCourseStyles = createUseStyles(theme => {
|
|
|
6017
6035
|
justifyContent: 'space-between'
|
|
6018
6036
|
//alignItems: 'center',
|
|
6019
6037
|
},
|
|
6038
|
+
|
|
6020
6039
|
courseCardTags: {
|
|
6021
6040
|
display: 'flex',
|
|
6022
6041
|
justifyContent: 'flex-start',
|
|
@@ -6047,6 +6066,7 @@ const useCourseStyles = createUseStyles(theme => {
|
|
|
6047
6066
|
// whiteSpace: 'nowrap',
|
|
6048
6067
|
// textOverflow: 'ellipsis'
|
|
6049
6068
|
},
|
|
6069
|
+
|
|
6050
6070
|
courseCardDiscount: {
|
|
6051
6071
|
display: 'flex',
|
|
6052
6072
|
justifyContent: 'flex-start',
|
|
@@ -6153,6 +6173,7 @@ const useCourseStyles = createUseStyles(theme => {
|
|
|
6153
6173
|
// whiteSpace: 'nowrap',
|
|
6154
6174
|
// textOverflow: 'ellipsis'
|
|
6155
6175
|
},
|
|
6176
|
+
|
|
6156
6177
|
singleCard: {
|
|
6157
6178
|
margin: '6px 2px'
|
|
6158
6179
|
// width: 'calc(100% - 12px)'
|
|
@@ -6528,6 +6549,7 @@ const useTeamStyles = createUseStyles(theme => {
|
|
|
6528
6549
|
margin: '20px 0 0'
|
|
6529
6550
|
// overflowWrap: 'break-word'
|
|
6530
6551
|
},
|
|
6552
|
+
|
|
6531
6553
|
teamDetailsHeading: {
|
|
6532
6554
|
fontSize: theme.typography.fontSize.h6,
|
|
6533
6555
|
fontWeight: theme.typography.fontWeight.bold,
|
|
@@ -6571,6 +6593,7 @@ const useTeamStyles = createUseStyles(theme => {
|
|
|
6571
6593
|
// margin: '15px 0 0',
|
|
6572
6594
|
// paddingBottom: '0'
|
|
6573
6595
|
},
|
|
6596
|
+
|
|
6574
6597
|
teamDetailsHeading: {
|
|
6575
6598
|
fontSize: '16px',
|
|
6576
6599
|
lineHeight: '24px',
|
|
@@ -6703,6 +6726,7 @@ const useSectionStyles$1 = createUseStyles(theme => ({
|
|
|
6703
6726
|
// }
|
|
6704
6727
|
// }
|
|
6705
6728
|
},
|
|
6729
|
+
|
|
6706
6730
|
formContainer: {
|
|
6707
6731
|
margin: '0 auto',
|
|
6708
6732
|
maxWidth: ({
|
|
@@ -6739,12 +6763,14 @@ const useSectionStyles$1 = createUseStyles(theme => ({
|
|
|
6739
6763
|
display: 'flex'
|
|
6740
6764
|
// alignItems: 'flex-start',
|
|
6741
6765
|
},
|
|
6766
|
+
|
|
6742
6767
|
leftContainerForm: {
|
|
6743
6768
|
width: '65%',
|
|
6744
6769
|
display: 'flex',
|
|
6745
6770
|
flexDirection: 'column'
|
|
6746
6771
|
// justifyContent: 'space-between'
|
|
6747
6772
|
},
|
|
6773
|
+
|
|
6748
6774
|
subtitle: {
|
|
6749
6775
|
// margin: '0 0 40px 0',
|
|
6750
6776
|
fontSize: theme.typography.fontSize.h5,
|
|
@@ -6812,6 +6838,7 @@ const useSectionStyles$1 = createUseStyles(theme => ({
|
|
|
6812
6838
|
width: '100%'
|
|
6813
6839
|
// padding: '0 16ox'
|
|
6814
6840
|
},
|
|
6841
|
+
|
|
6815
6842
|
rightContainer: {
|
|
6816
6843
|
width: '100%',
|
|
6817
6844
|
padding: '0'
|
|
@@ -7119,6 +7146,7 @@ const useSectionStyles = createUseStyles(theme => ({
|
|
|
7119
7146
|
// }
|
|
7120
7147
|
// }
|
|
7121
7148
|
},
|
|
7149
|
+
|
|
7122
7150
|
contactContainer: {
|
|
7123
7151
|
width: '100%',
|
|
7124
7152
|
margin: '0 auto',
|
|
@@ -7157,6 +7185,7 @@ const useSectionStyles = createUseStyles(theme => ({
|
|
|
7157
7185
|
// justifyContent: 'space-between',
|
|
7158
7186
|
// flex: 1
|
|
7159
7187
|
},
|
|
7188
|
+
|
|
7160
7189
|
subtitle: {
|
|
7161
7190
|
// margin: '0 0 auto 0',
|
|
7162
7191
|
fontSize: theme.typography.fontSize.h6,
|
|
@@ -7313,6 +7342,7 @@ function Contact({
|
|
|
7313
7342
|
extraProps
|
|
7314
7343
|
} = useContext(PageContext);
|
|
7315
7344
|
let [btnDisabled, setBtnDisabled] = useState(false);
|
|
7345
|
+
const [isSubmitted, setIsSubmitted] = useState(false);
|
|
7316
7346
|
const [nodeData] = sectionData.components;
|
|
7317
7347
|
const classes = useSectionStyles({
|
|
7318
7348
|
containerWidth,
|
|
@@ -7345,14 +7375,18 @@ function Contact({
|
|
|
7345
7375
|
if (!(isPreview || isEdit)) postApiCall(baseURLs, data);
|
|
7346
7376
|
setBtnDisabled(true);
|
|
7347
7377
|
setInputVal(formInitialValue);
|
|
7378
|
+
setIsSubmitted(true);
|
|
7379
|
+
setTimeout(() => {
|
|
7380
|
+
setIsSubmitted(false);
|
|
7381
|
+
}, 1000);
|
|
7348
7382
|
};
|
|
7349
7383
|
useEffect(() => {
|
|
7350
|
-
if (validData?.nameValid && validData?.emailValid && validData?.phoneValid && validData?.messageValid) {
|
|
7384
|
+
if (validData?.nameValid && validData?.emailValid && validData?.phoneValid && validData?.messageValid && inputVal?.email && inputVal?.name && inputVal?.phone && inputVal?.message) {
|
|
7351
7385
|
setBtnDisabled(false);
|
|
7352
7386
|
} else {
|
|
7353
7387
|
setBtnDisabled(true);
|
|
7354
7388
|
}
|
|
7355
|
-
}, [validData]);
|
|
7389
|
+
}, [validData, inputVal]);
|
|
7356
7390
|
const checkValidity = (regexField, fieldname, fieldValidity) => {
|
|
7357
7391
|
if (validations?.[regexField]?.length) {
|
|
7358
7392
|
let regex = new RegExp(validations[regexField]);
|
|
@@ -7495,7 +7529,7 @@ function Contact({
|
|
|
7495
7529
|
className: classes.btnContainer
|
|
7496
7530
|
}, /*#__PURE__*/React.createElement(Button, {
|
|
7497
7531
|
ref: nodeData?.cta?.refSetter,
|
|
7498
|
-
data:
|
|
7532
|
+
data: isSubmitted ? {
|
|
7499
7533
|
value: 'Submitted'
|
|
7500
7534
|
} : {
|
|
7501
7535
|
value: nodeData.cta.metadata.value
|
|
@@ -7596,6 +7630,7 @@ const useWebinarPromotionPage = createUseStyles(theme => {
|
|
|
7596
7630
|
marginTop: '5%'
|
|
7597
7631
|
// padding: '0px 5% 0px 5%'
|
|
7598
7632
|
},
|
|
7633
|
+
|
|
7599
7634
|
iframe: {
|
|
7600
7635
|
position: 'absolute',
|
|
7601
7636
|
width: '100%',
|
|
@@ -7943,6 +7978,7 @@ const SingleVideoSlide$1 = props => {
|
|
|
7943
7978
|
value: data.isPaid ? buyNowText : registerNowText
|
|
7944
7979
|
// isExternal: 1
|
|
7945
7980
|
},
|
|
7981
|
+
|
|
7946
7982
|
onClick: webinarCtaClick,
|
|
7947
7983
|
type: 'primary',
|
|
7948
7984
|
size: 'medium',
|
|
@@ -8011,6 +8047,7 @@ const useCoursePromotionPage = createUseStyles(theme => {
|
|
|
8011
8047
|
// }
|
|
8012
8048
|
// }
|
|
8013
8049
|
},
|
|
8050
|
+
|
|
8014
8051
|
sectionContainer: {
|
|
8015
8052
|
margin: '0 auto',
|
|
8016
8053
|
maxWidth: ({
|
|
@@ -8128,6 +8165,7 @@ const useCoursePromotionPage = createUseStyles(theme => {
|
|
|
8128
8165
|
// paddingBottom: '10px',
|
|
8129
8166
|
// paddingTop: '10px'
|
|
8130
8167
|
},
|
|
8168
|
+
|
|
8131
8169
|
bannerContainer: {
|
|
8132
8170
|
width: '100%',
|
|
8133
8171
|
background: theme?.colors?.bannerColor,
|
|
@@ -8142,6 +8180,7 @@ const useCoursePromotionPage = createUseStyles(theme => {
|
|
|
8142
8180
|
clipPath: 'polygon(0 0, 100% 0, 100% calc(100% - 10px), 0 calc(100% - 10px), 15px calc(50% - 10px/2))'
|
|
8143
8181
|
// marginBottom: '16px'
|
|
8144
8182
|
},
|
|
8183
|
+
|
|
8145
8184
|
bannerContainerText: {
|
|
8146
8185
|
transform: 'rotate(180deg)'
|
|
8147
8186
|
},
|
|
@@ -8254,6 +8293,7 @@ const useCoursePromotionPage = createUseStyles(theme => {
|
|
|
8254
8293
|
height: 'max-content'
|
|
8255
8294
|
// paddingRight: '10px'
|
|
8256
8295
|
},
|
|
8296
|
+
|
|
8257
8297
|
videoDetails: {
|
|
8258
8298
|
width: '100%'
|
|
8259
8299
|
},
|
|
@@ -8512,6 +8552,7 @@ const SingleVideoSlide = props => {
|
|
|
8512
8552
|
value: buyNowText
|
|
8513
8553
|
// isExternal: 1
|
|
8514
8554
|
},
|
|
8555
|
+
|
|
8515
8556
|
onClick: courseBuyNow,
|
|
8516
8557
|
type: 'primary',
|
|
8517
8558
|
size: 'medium',
|
|
@@ -8616,6 +8657,7 @@ const useFormPageStyles = createUseStyles(theme => ({
|
|
|
8616
8657
|
// border: '1px solid #D8E0F0',
|
|
8617
8658
|
// borderRadius: '16px'
|
|
8618
8659
|
},
|
|
8660
|
+
|
|
8619
8661
|
inputFieldLabel: {
|
|
8620
8662
|
color: theme?.colors?.lightblack,
|
|
8621
8663
|
fontSize: theme.typography.fontSize.body,
|
|
@@ -8928,6 +8970,7 @@ const FormPage = ({
|
|
|
8928
8970
|
value: countryCode === 'KR' ? '제출하기' : 'SUBMIT'
|
|
8929
8971
|
// isExternal: 1
|
|
8930
8972
|
},
|
|
8973
|
+
|
|
8931
8974
|
type: 'primary',
|
|
8932
8975
|
size: 'medium',
|
|
8933
8976
|
target: null,
|
|
@@ -9110,6 +9153,7 @@ const useEmailStyles = createUseStyles(theme => ({
|
|
|
9110
9153
|
height: '48px'
|
|
9111
9154
|
/* margin: 18px 0px; */
|
|
9112
9155
|
},
|
|
9156
|
+
|
|
9113
9157
|
'p-young-guru-title': {
|
|
9114
9158
|
fontFamily: theme?.typography?.fontFamily,
|
|
9115
9159
|
fontStyle: 'normal',
|
|
@@ -9137,6 +9181,7 @@ const useEmailStyles = createUseStyles(theme => ({
|
|
|
9137
9181
|
textAlign: 'center'
|
|
9138
9182
|
/* padding:35px 0 40px */
|
|
9139
9183
|
},
|
|
9184
|
+
|
|
9140
9185
|
'two-columns .column': {
|
|
9141
9186
|
width: '100%',
|
|
9142
9187
|
maxWidth: '275px',
|