diy-template-components 0.0.72 → 0.1.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/build/index.es.js CHANGED
@@ -12,6 +12,8 @@ function ___$insertStyle(css) {
12
12
  import React, { createContext, useContext, forwardRef, useRef, useEffect, useState, useMemo, useLayoutEffect, Suspense, memo, lazy, Fragment } from 'react';
13
13
  import Slider from 'react-slick';
14
14
  import axios from 'axios';
15
+ import moment from 'moment';
16
+ import Countdown from 'react-countdown';
15
17
  import { createTheming, createUseStyles as createUseStyles$1, useTheme as useTheme$1 } from 'react-jss';
16
18
 
17
19
  function _extends() {
@@ -617,6 +619,16 @@ var success = "data:image/svg+xml,%3Csvg%20width%3D%2248%22%20height%3D%2248%22%
617
619
 
618
620
  var quote = "data:image/svg+xml,%3Csvg%20width%3D%2228%22%20height%3D%2221%22%20viewBox%3D%220%200%2028%2021%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20fill-rule%3D%22evenodd%22%20clip-rule%3D%22evenodd%22%20d%3D%22M8.352%2020.88H3.384L0%2010.584V0H11.736V10.584L8.352%2020.88ZM24.0476%2020.88H19.1516L15.7676%2010.584V0H27.5036V10.584L24.0476%2020.88Z%22%20fill%3D%22%236269C9%22%2F%3E%3C%2Fsvg%3E";
619
621
 
622
+ var clock = "data:image/svg+xml,%3Csvg%20width%3D%2218%22%20height%3D%2218%22%20viewBox%3D%220%200%2018%2018%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M9%2016.5C13.1421%2016.5%2016.5%2013.1421%2016.5%209C16.5%204.85786%2013.1421%201.5%209%201.5C4.85786%201.5%201.5%204.85786%201.5%209C1.5%2013.1421%204.85786%2016.5%209%2016.5Z%22%20fill%3D%22%234E93FF%22%2F%3E%3Cpath%20d%3D%22M11.7825%2011.9478C11.685%2011.9478%2011.5875%2011.9253%2011.4975%2011.8653L9.17248%2010.4778C8.59498%2010.1328%208.16748%209.37531%208.16748%208.70781V5.63281C8.16748%205.32531%208.42248%205.07031%208.72998%205.07031C9.03748%205.07031%209.29248%205.32531%209.29248%205.63281V8.70781C9.29248%208.97781%209.51748%209.37531%209.74998%209.51031L12.075%2010.8978C12.345%2011.0553%2012.4275%2011.4003%2012.27%2011.6703C12.1575%2011.8503%2011.97%2011.9478%2011.7825%2011.9478Z%22%20fill%3D%22white%22%2F%3E%3C%2Fsvg%3E";
623
+
624
+ var bookSaved = "data:image/svg+xml,%3Csvg%20width%3D%2218%22%20height%3D%2218%22%20viewBox%3D%220%200%2018%2018%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M8.4375%204.50055V14.933C8.4375%2015.4655%207.8975%2015.833%207.41%2015.6305C6.015%2015.0455%204.2825%2014.5355%203.0525%2014.3705L2.82%2014.3405C2.0925%2014.2505%201.5%2013.583%201.5%2012.8555V3.93805C1.5%203.03805%202.2275%202.31055%203.1275%202.31055H3.18C4.59%202.43055%206.6675%203.09055%208.04%203.83305C8.2875%203.96805%208.4375%204.21555%208.4375%204.50055Z%22%20fill%3D%22%234E93FF%22%2F%3E%3Cpath%20d%3D%22M14.8725%202.31055H14.8275C14.6475%202.32555%2014.4525%202.34805%2014.25%202.38555C13.3275%202.53555%2012.2325%202.85055%2011.25%203.24055C10.785%203.42805%2010.35%203.63055%209.9675%203.83305C9.72%203.96805%209.5625%204.22305%209.5625%204.50055V14.933C9.5625%2015.4655%2010.1025%2015.833%2010.59%2015.6305C11.985%2015.0455%2013.7175%2014.5355%2014.9475%2014.3705L15.18%2014.3405C15.9075%2014.2505%2016.5%2013.583%2016.5%2012.8555V3.93805C16.5%203.03805%2015.7725%202.31055%2014.8725%202.31055ZM14.4525%2010.298C14.4525%2010.5905%2014.2425%2010.718%2013.9875%2010.5755L13.1925%2010.133C13.11%2010.088%2012.975%2010.088%2012.885%2010.133L12.09%2010.5755C11.835%2010.718%2011.625%2010.5905%2011.625%2010.298V7.99555C11.625%207.65055%2011.91%207.36555%2012.255%207.36555H13.83C14.175%207.36555%2014.46%207.65055%2014.46%207.99555V10.298H14.4525Z%22%20fill%3D%22%234E93FF%22%2F%3E%3C%2Fsvg%3E";
625
+
626
+ var certificate = "data:image/svg+xml,%3Csvg%20width%3D%2212%22%20height%3D%2214%22%20viewBox%3D%220%200%2012%2014%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20opacity%3D%220.7%22%20d%3D%22M10.5%200H1.5C0.675%200%200%200.63%200%201.4V12.6C0%2013.37%200.675%2014%201.5%2014H10.5C11.325%2014%2012%2013.37%2012%2012.6V1.4C12%200.63%2011.325%200%2010.5%200ZM1.5%201.4H5.25V7L3.375%205.95L1.5%207V1.4Z%22%20fill%3D%22%231676F3%22%2F%3E%3C%2Fsvg%3E";
627
+
628
+ var calendar = "data:image/svg+xml,%3Csvg%20width%3D%2218%22%20height%3D%2218%22%20viewBox%3D%220%200%2018%2018%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M12.5627%202.67V1.5C12.5627%201.1925%2012.3077%200.9375%2012.0002%200.9375C11.6927%200.9375%2011.4377%201.1925%2011.4377%201.5V2.625H6.56267V1.5C6.56267%201.1925%206.30767%200.9375%206.00017%200.9375C5.69267%200.9375%205.43767%201.1925%205.43767%201.5V2.67C3.41267%202.8575%202.43017%204.065%202.28017%205.8575C2.26517%206.075%202.44517%206.255%202.65517%206.255H15.3452C15.5627%206.255%2015.7427%206.0675%2015.7202%205.8575C15.5702%204.065%2014.5877%202.8575%2012.5627%202.67Z%22%20fill%3D%22%234E93FF%22%2F%3E%3Cpath%20d%3D%22M15%207.38086H3C2.5875%207.38086%202.25%207.71836%202.25%208.13086V12.7509C2.25%2015.0009%203.375%2016.5009%206%2016.5009H12C14.625%2016.5009%2015.75%2015.0009%2015.75%2012.7509V8.13086C15.75%207.71836%2015.4125%207.38086%2015%207.38086ZM6.9075%2013.6584C6.87%2013.6884%206.8325%2013.7259%206.795%2013.7484C6.75%2013.7784%206.705%2013.8009%206.66%2013.8159C6.615%2013.8384%206.57%2013.8534%206.525%2013.8609C6.4725%2013.8684%206.4275%2013.8759%206.375%2013.8759C6.2775%2013.8759%206.18%2013.8534%206.09%2013.8159C5.9925%2013.7784%205.9175%2013.7259%205.8425%2013.6584C5.7075%2013.5159%205.625%2013.3209%205.625%2013.1259C5.625%2012.9309%205.7075%2012.7359%205.8425%2012.5934C5.9175%2012.5259%205.9925%2012.4734%206.09%2012.4359C6.225%2012.3759%206.375%2012.3609%206.525%2012.3909C6.57%2012.3984%206.615%2012.4134%206.66%2012.4359C6.705%2012.4509%206.75%2012.4734%206.795%2012.5034C6.8325%2012.5334%206.87%2012.5634%206.9075%2012.5934C7.0425%2012.7359%207.125%2012.9309%207.125%2013.1259C7.125%2013.3209%207.0425%2013.5159%206.9075%2013.6584ZM6.9075%2011.0334C6.765%2011.1684%206.57%2011.2509%206.375%2011.2509C6.18%2011.2509%205.985%2011.1684%205.8425%2011.0334C5.7075%2010.8909%205.625%2010.6959%205.625%2010.5009C5.625%2010.3059%205.7075%2010.1109%205.8425%209.96836C6.0525%209.75836%206.3825%209.69086%206.66%209.81086C6.7575%209.84836%206.84%209.90086%206.9075%209.96836C7.0425%2010.1109%207.125%2010.3059%207.125%2010.5009C7.125%2010.6959%207.0425%2010.8909%206.9075%2011.0334ZM9.5325%2013.6584C9.39%2013.7934%209.195%2013.8759%209%2013.8759C8.805%2013.8759%208.61%2013.7934%208.4675%2013.6584C8.3325%2013.5159%208.25%2013.3209%208.25%2013.1259C8.25%2012.9309%208.3325%2012.7359%208.4675%2012.5934C8.745%2012.3159%209.255%2012.3159%209.5325%2012.5934C9.6675%2012.7359%209.75%2012.9309%209.75%2013.1259C9.75%2013.3209%209.6675%2013.5159%209.5325%2013.6584ZM9.5325%2011.0334C9.495%2011.0634%209.4575%2011.0934%209.42%2011.1234C9.375%2011.1534%209.33%2011.1759%209.285%2011.1909C9.24%2011.2134%209.195%2011.2284%209.15%2011.2359C9.0975%2011.2434%209.0525%2011.2509%209%2011.2509C8.805%2011.2509%208.61%2011.1684%208.4675%2011.0334C8.3325%2010.8909%208.25%2010.6959%208.25%2010.5009C8.25%2010.3059%208.3325%2010.1109%208.4675%209.96836C8.535%209.90086%208.6175%209.84836%208.715%209.81086C8.9925%209.69086%209.3225%209.75836%209.5325%209.96836C9.6675%2010.1109%209.75%2010.3059%209.75%2010.5009C9.75%2010.6959%209.6675%2010.8909%209.5325%2011.0334ZM12.1575%2013.6584C12.015%2013.7934%2011.82%2013.8759%2011.625%2013.8759C11.43%2013.8759%2011.235%2013.7934%2011.0925%2013.6584C10.9575%2013.5159%2010.875%2013.3209%2010.875%2013.1259C10.875%2012.9309%2010.9575%2012.7359%2011.0925%2012.5934C11.37%2012.3159%2011.88%2012.3159%2012.1575%2012.5934C12.2925%2012.7359%2012.375%2012.9309%2012.375%2013.1259C12.375%2013.3209%2012.2925%2013.5159%2012.1575%2013.6584ZM12.1575%2011.0334C12.12%2011.0634%2012.0825%2011.0934%2012.045%2011.1234C12%2011.1534%2011.955%2011.1759%2011.91%2011.1909C11.865%2011.2134%2011.82%2011.2284%2011.775%2011.2359C11.7225%2011.2434%2011.67%2011.2509%2011.625%2011.2509C11.43%2011.2509%2011.235%2011.1684%2011.0925%2011.0334C10.9575%2010.8909%2010.875%2010.6959%2010.875%2010.5009C10.875%2010.3059%2010.9575%2010.1109%2011.0925%209.96836C11.1675%209.90086%2011.2425%209.84836%2011.34%209.81086C11.475%209.75086%2011.625%209.73586%2011.775%209.76586C11.82%209.77336%2011.865%209.78836%2011.91%209.81086C11.955%209.82586%2012%209.84836%2012.045%209.87836C12.0825%209.90836%2012.12%209.93836%2012.1575%209.96836C12.2925%2010.1109%2012.375%2010.3059%2012.375%2010.5009C12.375%2010.6959%2012.2925%2010.8909%2012.1575%2011.0334Z%22%20fill%3D%22%234E93FF%22%2F%3E%3C%2Fsvg%3E";
629
+
630
+ var video = "data:image/svg+xml,%3Csvg%20width%3D%2218%22%20height%3D%2219%22%20viewBox%3D%220%200%2018%2019%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M15.8625%205.1275C15.555%204.9625%2014.91%204.79%2014.0325%205.405L12.93%206.185C12.8475%203.8525%2011.835%202.9375%209.375%202.9375H4.875C2.31%202.9375%201.3125%203.935%201.3125%206.5V12.5C1.3125%2014.225%202.25%2016.0625%204.875%2016.0625H9.375C11.835%2016.0625%2012.8475%2015.1475%2012.93%2012.815L14.0325%2013.595C14.4975%2013.925%2014.9025%2014.03%2015.225%2014.03C15.5025%2014.03%2015.72%2013.9475%2015.8625%2013.8725C16.17%2013.715%2016.6875%2013.2875%2016.6875%2012.215V6.785C16.6875%205.7125%2016.17%205.285%2015.8625%205.1275ZM8.25%209.035C7.4775%209.035%206.84%208.405%206.84%207.625C6.84%206.845%207.4775%206.215%208.25%206.215C9.0225%206.215%209.66%206.845%209.66%207.625C9.66%208.405%209.0225%209.035%208.25%209.035Z%22%20fill%3D%22%23589DF5%22%2F%3E%3C%2Fsvg%3E";
631
+
620
632
  /** @returns {import('./types').IconData} */
621
633
 
622
634
  const getConfiguredIcon1 = url => ({
@@ -704,7 +716,13 @@ const icons = {
704
716
  // Others
705
717
  Teachers: getConfiguredIcon2(teachers, false, true),
706
718
  Learning: getConfiguredIcon2(learning, false, true),
707
- Success: getConfiguredIcon2(success, false, true)
719
+ Success: getConfiguredIcon2(success, false, true),
720
+ // landing pages
721
+ Clock: getConfiguredIcon2(clock, false, true),
722
+ 'Book Saved': getConfiguredIcon2(bookSaved, false, true),
723
+ Certificate: getConfiguredIcon2(certificate, false, true),
724
+ Calendar: getConfiguredIcon2(calendar, false, true),
725
+ Video: getConfiguredIcon2(video, false, true)
708
726
  };
709
727
 
710
728
  const someMethod1 = (
@@ -989,7 +1007,8 @@ function OptionList({
989
1007
  isMobile,
990
1008
  moreContent,
991
1009
  navDataCount,
992
- isTutorWebsite
1010
+ isTutorWebsite,
1011
+ isLandingPages
993
1012
  }) {
994
1013
  useContext(PageContext);
995
1014
 
@@ -1000,7 +1019,7 @@ function OptionList({
1000
1019
  link: dt.slug,
1001
1020
  active: dt.active,
1002
1021
  isLink: true,
1003
- isExisting: false
1022
+ isExistingLink: false
1004
1023
  };
1005
1024
  });
1006
1025
  };
@@ -1051,7 +1070,7 @@ function OptionList({
1051
1070
  link: headerData?.appLink,
1052
1071
  isLink: 1,
1053
1072
  value: 'Download App',
1054
- isExisting: false
1073
+ isExistingLink: false
1055
1074
  },
1056
1075
  type: 'primary',
1057
1076
  size: 'small',
@@ -1065,7 +1084,7 @@ function OptionList({
1065
1084
  link: headerData?.loginCtaLink,
1066
1085
  isLink: 1,
1067
1086
  value: 'Login',
1068
- isExisting: false
1087
+ isExistingLink: false
1069
1088
  },
1070
1089
  type: 'primary',
1071
1090
  size: isMobile ? 'small' : 'medium',
@@ -1080,7 +1099,8 @@ function OptionList({
1080
1099
  function DesktopHeader({
1081
1100
  header,
1082
1101
  navData,
1083
- isTutorWebsite
1102
+ isTutorWebsite,
1103
+ isLandingPages
1084
1104
  }) {
1085
1105
  const {
1086
1106
  isFixed = true
@@ -1139,6 +1159,7 @@ function DesktopHeader({
1139
1159
  navDataCount: navData?.length,
1140
1160
  headerData: header,
1141
1161
  isMobile: false,
1162
+ isLandingPages: isLandingPages,
1142
1163
  moreContent: moreContentFn(),
1143
1164
  isTutorWebsite: isTutorWebsite
1144
1165
  }))));
@@ -1151,7 +1172,8 @@ var phoneAndroid = "data:image/svg+xml,%3Csvg%20width%3D%2244%22%20height%3D%224
1151
1172
  function MobileHeader({
1152
1173
  header,
1153
1174
  navData,
1154
- isTutorWebsite
1175
+ isTutorWebsite,
1176
+ isLandingPages
1155
1177
  }) {
1156
1178
  const {
1157
1179
  isFixed = true
@@ -1189,7 +1211,7 @@ function MobileHeader({
1189
1211
  src: phoneIos,
1190
1212
  alt: "iosUrl"
1191
1213
  }),
1192
- isExisting: false
1214
+ isExistingLink: false
1193
1215
  },
1194
1216
  type: '',
1195
1217
  size: 'small',
@@ -1211,7 +1233,7 @@ function MobileHeader({
1211
1233
  src: phoneAndroid,
1212
1234
  alt: "iosUrl"
1213
1235
  }),
1214
- isExisting: false
1236
+ isExistingLink: false
1215
1237
  },
1216
1238
  type: '',
1217
1239
  size: 'small',
@@ -1231,7 +1253,7 @@ function MobileHeader({
1231
1253
  link: header?.iosUrl,
1232
1254
  isLink: 1,
1233
1255
  value: 'Download App',
1234
- isExisting: false
1256
+ isExistingLink: false
1235
1257
  },
1236
1258
  type: 'primary',
1237
1259
  size: 'small',
@@ -1244,7 +1266,7 @@ function MobileHeader({
1244
1266
  link: header?.androidURL,
1245
1267
  isLink: 1,
1246
1268
  value: 'Download App',
1247
- isExisting: false
1269
+ isExistingLink: false
1248
1270
  },
1249
1271
  type: 'primary',
1250
1272
  size: 'small',
@@ -1261,7 +1283,7 @@ function MobileHeader({
1261
1283
  link: header?.appLink,
1262
1284
  isLink: 1,
1263
1285
  value: 'Download App',
1264
- isExisting: false
1286
+ isExistingLink: false
1265
1287
  },
1266
1288
  type: 'primary',
1267
1289
  size: 'small',
@@ -1322,7 +1344,8 @@ function Header({
1322
1344
  }) {
1323
1345
  const {
1324
1346
  isMobile,
1325
- isTutorWebsite
1347
+ isTutorWebsite,
1348
+ isLandingPages
1326
1349
  } = useContext(PageContext);
1327
1350
 
1328
1351
  const filterHiddenNavs = () => {
@@ -1332,11 +1355,13 @@ function Header({
1332
1355
  return isMobile ? /*#__PURE__*/React.createElement(MobileHeader, {
1333
1356
  navData: filterHiddenNavs(),
1334
1357
  header: data,
1335
- isTutorWebsite: isTutorWebsite
1358
+ isTutorWebsite: isTutorWebsite,
1359
+ isLandingPages: isLandingPages
1336
1360
  }) : /*#__PURE__*/React.createElement(DesktopHeader, {
1337
1361
  navData: filterHiddenNavs(),
1338
1362
  header: data,
1339
- isTutorWebsite: isTutorWebsite
1363
+ isTutorWebsite: isTutorWebsite,
1364
+ isLandingPages: isLandingPages
1340
1365
  });
1341
1366
  }
1342
1367
 
@@ -1796,44 +1821,51 @@ function ArimaMadurai() {
1796
1821
  }
1797
1822
 
1798
1823
  const TYPE_TO_COMPONENT_MAP$1 = {
1799
- BANNER_CAROUSEL_RIGHT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$g; })),
1800
- GRID_CARD: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$f; })),
1801
- BANNER_CAROUSEL_CENTER: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$e; })),
1802
- BANNER_CAROUSEL_LEFT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$d; })),
1803
- FORM_SUBSCRIBE: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$c; })),
1804
- TEXT_TESTIMONIAL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$b; })),
1805
- VIDEO_TESTIMONIAL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$a; })),
1806
- VIDEO: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$9; })),
1807
- INFO: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$8; })),
1808
- TEXT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$7; })),
1809
- IMAGE_GALLERY: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$6; })),
1810
- FAQ_LISTING: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$5; })),
1811
- COURSE_CAROUSEL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$3; })),
1812
- TEAM_CARD: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$2; })),
1813
- TEXT_GRID: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$4; })),
1814
- CONTACT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$1; })),
1815
- FORM_ENQUIRY: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index; }))
1824
+ BANNER_CAROUSEL_RIGHT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$j; })),
1825
+ GRID_CARD: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$i; })),
1826
+ BANNER_CAROUSEL_CENTER: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$h; })),
1827
+ BANNER_CAROUSEL_LEFT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$g; })),
1828
+ FORM_SUBSCRIBE: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$f; })),
1829
+ TEXT_TESTIMONIAL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$e; })),
1830
+ VIDEO_TESTIMONIAL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$d; })),
1831
+ VIDEO: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$c; })),
1832
+ INFO: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$b; })),
1833
+ TEXT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$a; })),
1834
+ IMAGE_GALLERY: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$9; })),
1835
+ FAQ_LISTING: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$8; })),
1836
+ COURSE_CAROUSEL: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$6; })),
1837
+ TEAM_CARD: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$5; })),
1838
+ TEXT_GRID: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$7; })),
1839
+ CONTACT: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$4; })),
1840
+ FORM_ENQUIRY: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$3; })),
1841
+ WEBINAR_LANDING_PAGE: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$2; })),
1842
+ COURSE_LANDING_PAGE: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index$1; })),
1843
+ FORM_LANDING_PAGE: /*#__PURE__*/lazy(() => Promise.resolve().then(function () { return index; }))
1816
1844
  };
1817
1845
 
1818
1846
  const getCompToRender$1 = type => TYPE_TO_COMPONENT_MAP$1[type] || (() => null);
1819
1847
 
1820
1848
  const MemoisedSection$1 = /*#__PURE__*/memo(({
1821
- sectionData
1849
+ sectionData,
1850
+ extraProps
1822
1851
  }) => {
1823
1852
  const SectionComp = getCompToRender$1(sectionData.type);
1824
1853
  return /*#__PURE__*/React.createElement(SectionComp, {
1825
- sectionData: sectionData
1854
+ sectionData: sectionData,
1855
+ extraProps: extraProps
1826
1856
  });
1827
1857
  });
1828
1858
  function SectionRenderer$1({
1829
- sectionData
1859
+ sectionData,
1860
+ extraProps
1830
1861
  }) {
1831
1862
  return /*#__PURE__*/React.createElement(Suspense, {
1832
1863
  fallback: null
1833
1864
  /*GIF maybe*/
1834
1865
 
1835
1866
  }, /*#__PURE__*/React.createElement(MemoisedSection$1, {
1836
- sectionData: sectionData
1867
+ sectionData: sectionData,
1868
+ extraProps: extraProps
1837
1869
  }));
1838
1870
  }
1839
1871
 
@@ -1861,9 +1893,11 @@ function PageRenderer$1({
1861
1893
  sections,
1862
1894
  header,
1863
1895
  footer,
1864
- validations = {}
1896
+ validations = {},
1897
+ _id
1865
1898
  },
1866
1899
  isMobile = false,
1900
+ isLandingPages = false,
1867
1901
  baseURLs = {},
1868
1902
  hashToken,
1869
1903
  SectionWrapper,
@@ -1873,12 +1907,15 @@ function PageRenderer$1({
1873
1907
  isEdit,
1874
1908
  sectionPlaceholder,
1875
1909
  templateId,
1876
- isTutorWebsite = false
1910
+ isTutorWebsite = false,
1911
+ extraProps,
1912
+ hideLogin
1877
1913
  }) {
1878
1914
  const theme = useMemo(() => getTheme(color, font), [color, font]);
1879
1915
  const navList = header?.navs;
1880
1916
  const context = useMemo(() => ({
1881
1917
  isMobile,
1918
+ isLandingPages,
1882
1919
  layout,
1883
1920
  baseURLs,
1884
1921
  hashToken,
@@ -1889,8 +1926,11 @@ function PageRenderer$1({
1889
1926
  templateId,
1890
1927
  navList,
1891
1928
  validations,
1892
- isTutorWebsite
1893
- }), [isMobile, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite]);
1929
+ isTutorWebsite,
1930
+ extraProps,
1931
+ hideLogin,
1932
+ _id
1933
+ }), [isMobile, isLandingPages, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite, extraProps, hideLogin, _id]);
1894
1934
  const Wrapper = SectionWrapper || Fragment;
1895
1935
  return /*#__PURE__*/React.createElement(ThemeProvider, {
1896
1936
  theme: theme
@@ -1900,7 +1940,8 @@ function PageRenderer$1({
1900
1940
  fontFamily: font
1901
1941
  }), !!header && /*#__PURE__*/React.createElement(Wrapper, !!SectionWrapper && {
1902
1942
  sectionData: header,
1903
- isHeader: true
1943
+ isHeader: true,
1944
+ hideLogin
1904
1945
  }, /*#__PURE__*/React.createElement(Header, {
1905
1946
  data: header
1906
1947
  })), sections?.length ? sections?.map((sectionData, sectionIndex) => /*#__PURE__*/React.createElement(Wrapper, _extends({}, !!SectionWrapper && {
@@ -1909,7 +1950,8 @@ function PageRenderer$1({
1909
1950
  }, {
1910
1951
  key: sectionData.type + (sectionData._id || sectionIndex)
1911
1952
  }), /*#__PURE__*/React.createElement(SectionRenderer$1, {
1912
- sectionData: sectionData
1953
+ sectionData: sectionData,
1954
+ extraProps: extraProps
1913
1955
  }))) : sectionPlaceholder, !!footer && /*#__PURE__*/React.createElement(Wrapper, !!SectionWrapper && {
1914
1956
  sectionData: footer,
1915
1957
  isFooter: true
@@ -2334,7 +2376,7 @@ function BannerCarouselRight({
2334
2376
  })))));
2335
2377
  }
2336
2378
 
2337
- var index$g = /*#__PURE__*/Object.freeze({
2379
+ var index$j = /*#__PURE__*/Object.freeze({
2338
2380
  __proto__: null,
2339
2381
  'default': BannerCarouselRight
2340
2382
  });
@@ -2586,7 +2628,7 @@ function List({
2586
2628
  }))));
2587
2629
  }
2588
2630
 
2589
- var index$f = /*#__PURE__*/Object.freeze({
2631
+ var index$i = /*#__PURE__*/Object.freeze({
2590
2632
  __proto__: null,
2591
2633
  'default': List
2592
2634
  });
@@ -2755,7 +2797,7 @@ function BannerCarouselCenter({
2755
2797
  }))));
2756
2798
  }
2757
2799
 
2758
- var index$e = /*#__PURE__*/Object.freeze({
2800
+ var index$h = /*#__PURE__*/Object.freeze({
2759
2801
  __proto__: null,
2760
2802
  'default': BannerCarouselCenter
2761
2803
  });
@@ -2946,7 +2988,7 @@ function BannerCarouselLeft({
2946
2988
  })))));
2947
2989
  }
2948
2990
 
2949
- var index$d = /*#__PURE__*/Object.freeze({
2991
+ var index$g = /*#__PURE__*/Object.freeze({
2950
2992
  __proto__: null,
2951
2993
  'default': BannerCarouselLeft
2952
2994
  });
@@ -3315,7 +3357,7 @@ function SubscribeToNewsletter({
3315
3357
  })))))));
3316
3358
  }
3317
3359
 
3318
- var index$c = /*#__PURE__*/Object.freeze({
3360
+ var index$f = /*#__PURE__*/Object.freeze({
3319
3361
  __proto__: null,
3320
3362
  'default': SubscribeToNewsletter
3321
3363
  });
@@ -3577,7 +3619,7 @@ function Testimonials({
3577
3619
  }));
3578
3620
  }
3579
3621
 
3580
- var index$b = /*#__PURE__*/Object.freeze({
3622
+ var index$e = /*#__PURE__*/Object.freeze({
3581
3623
  __proto__: null,
3582
3624
  'default': Testimonials
3583
3625
  });
@@ -3730,13 +3772,13 @@ function VideoPlayer(props) {
3730
3772
 
3731
3773
  return /*#__PURE__*/React.createElement(React.Fragment, null, !isLoaded && /*#__PURE__*/React.createElement("div", {
3732
3774
  className: classes.imgContainer
3733
- }, isEnabled ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(Icon, {
3775
+ }, isEnabled ? /*#__PURE__*/React.createElement(Loader, null) : /*#__PURE__*/React.createElement(React.Fragment, null, props.onlyThumbnail ? null : /*#__PURE__*/React.createElement(Icon, {
3734
3776
  name: "Video Play",
3735
3777
  color: theme.palette.font.invertedDefault,
3736
3778
  onClick: () => {
3737
3779
  setIsEnableed(true);
3738
3780
  }
3739
- })), isEnabled && /*#__PURE__*/React.createElement("iframe", {
3781
+ }))), isEnabled && /*#__PURE__*/React.createElement("iframe", {
3740
3782
  className: classes.iframe + ' ' + classes.hideImg,
3741
3783
  src: imageUrl ? getId(videoUrl) + '?autoplay=1' : getId(videoUrl),
3742
3784
  frameBorder: "0",
@@ -3877,7 +3919,7 @@ const useVideoTestimonialStyles = createUseStyles(theme => {
3877
3919
  };
3878
3920
  });
3879
3921
 
3880
- const SingleVideoSlide = props => {
3922
+ const SingleVideoSlide$2 = props => {
3881
3923
  const {
3882
3924
  data
3883
3925
  } = props;
@@ -3950,13 +3992,13 @@ function VideoTestimonial({
3950
3992
  dangerouslySetInnerHTML: {
3951
3993
  __html: videoData.title.metadata.value
3952
3994
  }
3953
- })), /*#__PURE__*/React.createElement(Wrapper, null, videoData.videoCarousel.components.map((data, index) => /*#__PURE__*/React.createElement(SingleVideoSlide, {
3995
+ })), /*#__PURE__*/React.createElement(Wrapper, null, videoData.videoCarousel.components.map((data, index) => /*#__PURE__*/React.createElement(SingleVideoSlide$2, {
3954
3996
  data: data,
3955
3997
  key: index
3956
3998
  }))))));
3957
3999
  }
3958
4000
 
3959
- var index$a = /*#__PURE__*/Object.freeze({
4001
+ var index$d = /*#__PURE__*/Object.freeze({
3960
4002
  __proto__: null,
3961
4003
  'default': VideoTestimonial
3962
4004
  });
@@ -4184,7 +4226,7 @@ function Video({
4184
4226
  }, carouselContent))));
4185
4227
  }
4186
4228
 
4187
- var index$9 = /*#__PURE__*/Object.freeze({
4229
+ var index$c = /*#__PURE__*/Object.freeze({
4188
4230
  __proto__: null,
4189
4231
  'default': Video
4190
4232
  });
@@ -4410,7 +4452,7 @@ function Info({
4410
4452
  }, carouselContent))));
4411
4453
  }
4412
4454
 
4413
- var index$8 = /*#__PURE__*/Object.freeze({
4455
+ var index$b = /*#__PURE__*/Object.freeze({
4414
4456
  __proto__: null,
4415
4457
  'default': Info
4416
4458
  });
@@ -4529,7 +4571,7 @@ const TextSection = ({
4529
4571
  })))));
4530
4572
  };
4531
4573
 
4532
- var index$7 = /*#__PURE__*/Object.freeze({
4574
+ var index$a = /*#__PURE__*/Object.freeze({
4533
4575
  __proto__: null,
4534
4576
  'default': TextSection
4535
4577
  });
@@ -4686,7 +4728,7 @@ function PhotoGallery({
4686
4728
  }, carouselContent))));
4687
4729
  }
4688
4730
 
4689
- var index$6 = /*#__PURE__*/Object.freeze({
4731
+ var index$9 = /*#__PURE__*/Object.freeze({
4690
4732
  __proto__: null,
4691
4733
  'default': PhotoGallery
4692
4734
  });
@@ -4864,7 +4906,7 @@ const Accordion = ({
4864
4906
  })));
4865
4907
  };
4866
4908
 
4867
- var index$5 = /*#__PURE__*/Object.freeze({
4909
+ var index$8 = /*#__PURE__*/Object.freeze({
4868
4910
  __proto__: null,
4869
4911
  'default': FAQListing
4870
4912
  });
@@ -5029,7 +5071,7 @@ const TextGrid = ({
5029
5071
  }, carouselContent))));
5030
5072
  };
5031
5073
 
5032
- var index$4 = /*#__PURE__*/Object.freeze({
5074
+ var index$7 = /*#__PURE__*/Object.freeze({
5033
5075
  __proto__: null,
5034
5076
  'default': TextGrid
5035
5077
  });
@@ -5483,7 +5525,7 @@ function SimpleCardsContainer({
5483
5525
  }, children);
5484
5526
  }
5485
5527
 
5486
- var index$3 = /*#__PURE__*/Object.freeze({
5528
+ var index$6 = /*#__PURE__*/Object.freeze({
5487
5529
  __proto__: null,
5488
5530
  'default': courses
5489
5531
  });
@@ -5706,7 +5748,7 @@ function TeamCard({
5706
5748
  }, " ", carouselContent)));
5707
5749
  }
5708
5750
 
5709
- var index$2 = /*#__PURE__*/Object.freeze({
5751
+ var index$5 = /*#__PURE__*/Object.freeze({
5710
5752
  __proto__: null,
5711
5753
  'default': TeamCard
5712
5754
  });
@@ -6080,7 +6122,7 @@ function FormEnquiry({
6080
6122
  }))))));
6081
6123
  }
6082
6124
 
6083
- var index$1 = /*#__PURE__*/Object.freeze({
6125
+ var index$4 = /*#__PURE__*/Object.freeze({
6084
6126
  __proto__: null,
6085
6127
  'default': FormEnquiry
6086
6128
  });
@@ -6454,46 +6496,1068 @@ function Contact({
6454
6496
  }))))));
6455
6497
  }
6456
6498
 
6457
- var index = /*#__PURE__*/Object.freeze({
6499
+ var index$3 = /*#__PURE__*/Object.freeze({
6458
6500
  __proto__: null,
6459
6501
  'default': Contact
6460
6502
  });
6461
6503
 
6462
- const TYPE_TO_COMPONENT_MAP = {
6463
- BANNER_CAROUSEL_RIGHT: BannerCarouselRight,
6464
- GRID_CARD: List,
6465
- BANNER_CAROUSEL_CENTER: BannerCarouselCenter,
6466
- BANNER_CAROUSEL_LEFT: BannerCarouselLeft,
6467
- FORM_SUBSCRIBE: SubscribeToNewsletter,
6468
- TEXT_TESTIMONIAL: Testimonials,
6469
- VIDEO_TESTIMONIAL: VideoTestimonial,
6470
- VIDEO: Video,
6471
- INFO: Info,
6472
- TEXT: TextSection,
6473
- IMAGE_GALLERY: PhotoGallery,
6474
- FAQ_LISTING: FAQListing,
6475
- TEXT_GRID: TextGrid,
6476
- COURSE_CAROUSEL: courses,
6477
- TEAM_CARD: TeamCard,
6478
- CONTACT: FormEnquiry,
6479
- FORM_ENQUIRY: Contact
6480
- };
6504
+ const useWebinarPromotionPage = createUseStyles(theme => {
6505
+ return {
6506
+ webinarSuperContainer: {
6507
+ display: 'flex',
6508
+ justifyContent: 'center',
6509
+ padding: '70px',
6510
+ '&, & *, & *:before, & *:after': {
6511
+ fontFamily: theme?.typography?.fontFamily,
6512
+ boxSizing: 'border-box'
6513
+ },
6514
+ '& h2,& h3': {
6515
+ fontWeight: '500',
6516
+ '& b,& strong': {
6517
+ fontWeight: '700'
6518
+ }
6519
+ }
6520
+ },
6521
+ sectionContainer: {
6522
+ margin: '0 auto',
6523
+ maxWidth: ({
6524
+ containerWidth
6525
+ } = {}) => containerWidth
6526
+ },
6527
+ videoTestimonialContainer: {
6528
+ width: '100%',
6529
+ maxWidth: '1440px',
6530
+ fontFamily: theme?.typography?.fontFamily
6531
+ },
6532
+ videoTestimonialHeading: {
6533
+ fontSize: '16px',
6534
+ lineHeight: '20px',
6535
+ letterSpacing: '3px',
6536
+ textTransform: 'uppercase',
6537
+ color: theme.palette.font.tertiary,
6538
+ wordBreak: 'break-word',
6539
+ fontWeight: '700'
6540
+ },
6541
+ videoTestimonialTitle: {
6542
+ fontSize: '56px',
6543
+ lineHeight: '71px',
6544
+ letterSpacing: '-3px',
6545
+ margin: '0',
6546
+ color: theme.palette.font.default,
6547
+ wordBreak: 'break-word'
6548
+ },
6549
+ videoCarouselContainer: {
6550
+ marginTop: '16px'
6551
+ },
6552
+ webinarCarousel: {
6553
+ display: 'flex',
6554
+ justifyContent: 'flex-start',
6555
+ gap: '60px'
6556
+ },
6557
+ iframeSuperContainer: {
6558
+ height: '100%',
6559
+ width: '100%',
6560
+ display: 'flex',
6561
+ alignItems: 'center'
6562
+ },
6563
+ iframeContainer: {
6564
+ width: '90%',
6565
+ position: 'relative',
6566
+ paddingBottom: '56.25%',
6567
+ // top: "6%",
6568
+ left: '5%'
6569
+ },
6570
+ offerText: {
6571
+ textAlign: 'center',
6572
+ color: theme.palette.font.primary
6573
+ },
6574
+ offerPrice: {
6575
+ fontSize: '32px',
6576
+ fontWeight: '700'
6577
+ },
6578
+ priceContainer: {
6579
+ display: 'flex',
6580
+ flexDirection: 'column',
6581
+ width: 'fit-content'
6582
+ },
6583
+ originalPrice: {
6584
+ textDecoration: 'line-through',
6585
+ color: 'rgba(51, 51, 51, 0.6)'
6586
+ },
6587
+ offerDiscount: {
6588
+ color: '#08BD80',
6589
+ fontWeight: '600'
6590
+ },
6591
+ bottomContainer: {
6592
+ display: 'flex',
6593
+ justifyContent: 'space-around',
6594
+ marginTop: '5%'
6595
+ },
6596
+ iframe: {
6597
+ position: 'absolute',
6598
+ width: '100%',
6599
+ height: '100%',
6600
+ borderRadius: theme.shape.borderRadius.small
6601
+ },
6602
+ videoDetails: {
6603
+ width: '100%',
6604
+ display: 'flex',
6605
+ flexDirection: 'column',
6606
+ alignItems: 'flex-start'
6607
+ },
6608
+ videoDetailsHeading: {
6609
+ fontSize: '40px',
6610
+ lineHeight: '48px',
6611
+ margin: '0',
6612
+ letterSpacing: '-1px',
6613
+ wordBreak: 'break-word',
6614
+ color: theme.palette.font.default
6615
+ },
6616
+ courseViewContainer: {
6617
+ width: '645px',
6618
+ backgroundColor: '#f4f9ff',
6619
+ display: 'flex',
6620
+ flexDirection: 'column'
6621
+ },
6622
+ bannerContainer: {
6623
+ background: '#EB5757',
6624
+ color: '#fff',
6625
+ textAlign: 'center',
6626
+ padding: '6.5px 18px',
6627
+ position: 'relative',
6628
+ '&:after': {
6629
+ width: '0',
6630
+ height: '0',
6631
+ border: '11.5px solid transparent',
6632
+ position: 'absolute',
6633
+ content: '""',
6634
+ borderTopColor: '#EB5757',
6635
+ right: '-23px',
6636
+ top: '0px',
6637
+ borderLeftColor: ' #EB5757'
6638
+ },
6639
+ '&:before': {
6640
+ width: 0,
6641
+ height: 0,
6642
+ border: '22.5px solid transparent',
6643
+ position: 'absolute',
6644
+ content: '""',
6645
+ borderBottomColor: '#EB5757',
6646
+ right: '-23px',
6647
+ top: '-10.5px'
6648
+ }
6649
+ },
6650
+ courseDetailsTags: {
6651
+ marginTop: '16px',
6652
+ display: 'flex'
6653
+ },
6654
+ courseDetailTag: {
6655
+ display: 'flex',
6656
+ alignItems: 'center',
6657
+ marginRight: '20px',
6658
+ '& div': {
6659
+ fontSize: '14px',
6660
+ marginLeft: '10px'
6661
+ }
6662
+ },
6663
+ courseDetailContent: {
6664
+ marginTop: '16px',
6665
+ fontSize: '16px',
6666
+ lineHeight: '24px',
6667
+ wordBreak: 'break-word',
6668
+ color: theme.palette.font.primary,
6669
+ margin: '10px 0 20px'
6670
+ },
6671
+ courseDetailViewFullDetails: {
6672
+ cursor: 'pointer',
6673
+ fontSize: '16px',
6674
+ lineHeight: '24px',
6675
+ margin: '0',
6676
+ color: '#1676F3',
6677
+ wordBreak: 'break-word'
6678
+ },
6679
+ courseDetailTime: {
6680
+ color: '#EB5757',
6681
+ fontWeight: '600'
6682
+ },
6683
+ webinarButtonContainer: {
6684
+ marginBottom: '20px'
6685
+ },
6686
+ '@media (max-width: 767px)': {
6687
+ courseViewContainer: {
6688
+ width: '100%'
6689
+ },
6690
+ webinarSuperContainer: {
6691
+ padding: '20px 10px 60px 20px'
6692
+ },
6693
+ videoCarousel: {
6694
+ flexDirection: 'column-reverse',
6695
+ gap: '20px'
6696
+ },
6697
+ videoCarouselContainer: {
6698
+ height: 'max-content',
6699
+ paddingRight: '10px'
6700
+ },
6701
+ videoDetails: {
6702
+ width: '100%'
6703
+ },
6704
+ videoDetailsHeading: {
6705
+ fontSize: '16px',
6706
+ lineHeight: '20px'
6707
+ },
6708
+ videoTestimonialTitle: {
6709
+ fontSize: '24px',
6710
+ lineHeight: '36px',
6711
+ letterSpacing: '-1px'
6712
+ },
6713
+ videoDetailsContent: {
6714
+ marginTop: '4px'
6715
+ }
6716
+ }
6717
+ };
6718
+ });
6481
6719
 
6482
- const getCompToRender = type => TYPE_TO_COMPONENT_MAP[type] || (() => null);
6720
+ const SingleVideoSlide$1 = props => {
6721
+ useEffect(() => {// remaining days epoch
6722
+ // current date epoch
6723
+ // subtract remaining days from current day epoch
6724
+ // moment the result - and see if there are days
6725
+ // days is present show days
6726
+ // else start reverse timer
6727
+ }, []);
6728
+ const {
6729
+ data,
6730
+ webinarCtaClick
6731
+ } = props;
6483
6732
 
6484
- const MemoisedSection = /*#__PURE__*/memo(({
6485
- sectionData
6486
- }) => {
6487
- const SectionComp = getCompToRender(sectionData.type);
6488
- return /*#__PURE__*/React.createElement(SectionComp, {
6489
- sectionData: sectionData
6490
- });
6491
- });
6492
- function SectionRenderer({
6493
- sectionData
6733
+ const renderer = ({
6734
+ hours,
6735
+ minutes,
6736
+ seconds,
6737
+ completed
6738
+ }) => {
6739
+ if (hours < 24) {
6740
+ return /*#__PURE__*/React.createElement("span", null, hours, ":", minutes, ":", seconds);
6741
+ } else {
6742
+ let given = moment(props.data.endTime);
6743
+ let current = moment().startOf('day');
6744
+ return /*#__PURE__*/React.createElement("span", null, moment().duration(given.diff(current)).asDays());
6745
+ }
6746
+ };
6747
+
6748
+ const classes = useWebinarPromotionPage();
6749
+ return /*#__PURE__*/React.createElement("div", {
6750
+ className: classes.videoCarouselContainer
6751
+ }, /*#__PURE__*/React.createElement("div", {
6752
+ className: classes.webinarCarousel
6753
+ }, /*#__PURE__*/React.createElement("div", {
6754
+ className: classes.iframeSuperContainer
6755
+ }, /*#__PURE__*/React.createElement("div", {
6756
+ className: classes.videoDetails
6757
+ }, /*#__PURE__*/React.createElement("h3", {
6758
+ className: classes.bannerContainer
6759
+ }, data.offerPriceValidFor <= 0 ? /*#__PURE__*/React.createElement(React.Fragment, null, "Hurry up! Offer for limited period only") : /*#__PURE__*/React.createElement(React.Fragment, null, "Hurry up! Offer is left for ", data.offerPriceValidFor, " users now")), /*#__PURE__*/React.createElement("h3", {
6760
+ ref: data?.videoTextHeading?.refSetter,
6761
+ className: classes.videoDetailsHeading,
6762
+ dangerouslySetInnerHTML: {
6763
+ __html: data.title
6764
+ }
6765
+ }), /*#__PURE__*/React.createElement("div", {
6766
+ className: classes.courseDetailsTags
6767
+ }, /*#__PURE__*/React.createElement("div", {
6768
+ className: classes.courseDetailTag
6769
+ }, /*#__PURE__*/React.createElement(Icon, {
6770
+ name: 'Calendar'
6771
+ }), /*#__PURE__*/React.createElement("div", null, moment(data.startDate).format('dddd, MMMM Do, h:mm:ss'))), /*#__PURE__*/React.createElement("div", {
6772
+ className: classes.courseDetailTag
6773
+ }, /*#__PURE__*/React.createElement(Icon, {
6774
+ name: 'Video'
6775
+ }), /*#__PURE__*/React.createElement("div", null, data.webinarLocation))), /*#__PURE__*/React.createElement("p", {
6776
+ ref: data?.videoTextContent?.refSetter,
6777
+ className: classes.courseDetailContent,
6778
+ dangerouslySetInnerHTML: {
6779
+ __html: data.description.substring(0, 250)
6780
+ }
6781
+ }), /*#__PURE__*/React.createElement("p", {
6782
+ ref: data?.videoTextSubContent?.refSetter,
6783
+ className: classes.courseDetailViewFullDetails,
6784
+ dangerouslySetInnerHTML: {
6785
+ __html: data.description.length > 250 ? 'Read More' : null
6786
+ }
6787
+ }))), /*#__PURE__*/React.createElement("div", {
6788
+ className: classes.courseViewContainer
6789
+ }, /*#__PURE__*/React.createElement("p", {
6790
+ className: classes.offerText
6791
+ }, "Offer Ends in", ' ', /*#__PURE__*/React.createElement("span", {
6792
+ className: classes.courseDetailTime
6793
+ }, /*#__PURE__*/React.createElement(Countdown, {
6794
+ renderer: renderer,
6795
+ date: data.endDate
6796
+ }))), /*#__PURE__*/React.createElement("div", {
6797
+ ref: data?.videoFrame?.refSetter,
6798
+ className: classes.iframeContainer
6799
+ }, /*#__PURE__*/React.createElement(VideoPlayer, {
6800
+ onlyThumbnail: true,
6801
+ imageUrl: data.thumbnail,
6802
+ videoUrl: data.thumbnail
6803
+ })), /*#__PURE__*/React.createElement("div", {
6804
+ className: classes.bottomContainer
6805
+ }, data.isPaid && /*#__PURE__*/React.createElement("div", {
6806
+ className: classes.priceContainer
6807
+ }, /*#__PURE__*/React.createElement("div", {
6808
+ className: classes.offerPrice
6809
+ }, data.offerPrice), /*#__PURE__*/React.createElement("p", {
6810
+ style: {
6811
+ fontSize: '20px'
6812
+ }
6813
+ }, /*#__PURE__*/React.createElement("span", {
6814
+ className: classes.originalPrice
6815
+ }, data.regularPrice), ' ', /*#__PURE__*/React.createElement("span", {
6816
+ className: classes.offerDiscount
6817
+ }, "50% OFF"))), /*#__PURE__*/React.createElement("div", {
6818
+ className: classes.webinarButtonContainer
6819
+ }, /*#__PURE__*/React.createElement(Button, {
6820
+ style: {
6821
+ backgroundColor: '#009AE0',
6822
+ width: data.isPaid ? '150px' : '250px'
6823
+ },
6824
+ data: {
6825
+ // link: 'headerData?.loginCtaLink',
6826
+ // isLink: 1,
6827
+ value: data.isPaid ? 'BUY NOW' : 'REGISTER NOW' // isExternal: 1
6828
+
6829
+ },
6830
+ onClick: webinarCtaClick,
6831
+ type: 'primary',
6832
+ size: 'medium',
6833
+ target: null,
6834
+ rel: null
6835
+ }))))));
6836
+ };
6837
+
6838
+ function CoursePromotionPage$1({
6839
+ sectionData,
6840
+ extraProps = {}
6841
+ }) {
6842
+ const {
6843
+ layout: {
6844
+ containerWidth
6845
+ }
6846
+ } = useContext(PageContext);
6847
+ const classes = useWebinarPromotionPage({
6848
+ containerWidth
6849
+ });
6850
+ console.log(sectionData);
6851
+ return /*#__PURE__*/React.createElement("div", {
6852
+ className: classes.webinarSuperContainer
6853
+ }, /*#__PURE__*/React.createElement("div", {
6854
+ className: classes.videoTestimonialContainer
6855
+ }, /*#__PURE__*/React.createElement("div", {
6856
+ className: classes.sectionContainer
6857
+ }, /*#__PURE__*/React.createElement(SingleVideoSlide$1, {
6858
+ data: sectionData.components[0].metadata,
6859
+ webinarCtaClick: extraProps.webinarCtaClick
6860
+ }))));
6861
+ }
6862
+
6863
+ var index$2 = /*#__PURE__*/Object.freeze({
6864
+ __proto__: null,
6865
+ 'default': CoursePromotionPage$1
6866
+ });
6867
+
6868
+ const useCoursePromotionPage = createUseStyles(theme => {
6869
+ return {
6870
+ courseSuperContainer: {
6871
+ display: 'flex',
6872
+ justifyContent: 'center',
6873
+ padding: '70px ',
6874
+ '&, & *, & *:before, & *:after': {
6875
+ fontFamily: theme?.typography?.fontFamily,
6876
+ boxSizing: 'border-box'
6877
+ },
6878
+ '& h2,& h3': {
6879
+ fontWeight: '500',
6880
+ '& b,& strong': {
6881
+ fontWeight: '700'
6882
+ }
6883
+ }
6884
+ },
6885
+ sectionContainer: {
6886
+ margin: '0 auto',
6887
+ maxWidth: ({
6888
+ containerWidth
6889
+ } = {}) => containerWidth
6890
+ },
6891
+ videoTestimonialContainer: {
6892
+ width: '100%',
6893
+ maxWidth: '1440px',
6894
+ fontFamily: theme?.typography?.fontFamily
6895
+ },
6896
+ videoTestimonialHeading: {
6897
+ fontSize: '16px',
6898
+ lineHeight: '20px',
6899
+ letterSpacing: '3px',
6900
+ textTransform: 'uppercase',
6901
+ color: theme.palette.font.tertiary,
6902
+ wordBreak: 'break-word',
6903
+ fontWeight: '700'
6904
+ },
6905
+ videoTestimonialTitle: {
6906
+ fontSize: '56px',
6907
+ lineHeight: '71px',
6908
+ letterSpacing: '-3px',
6909
+ margin: '0',
6910
+ color: theme.palette.font.default,
6911
+ wordBreak: 'break-word'
6912
+ },
6913
+ videoCarouselContainer: {
6914
+ marginTop: '16px'
6915
+ },
6916
+ coursePageCarousel: {
6917
+ display: 'flex',
6918
+ justifyContent: 'flex-start',
6919
+ gap: '60px'
6920
+ },
6921
+ iframeSuperContainer: {
6922
+ height: '100%',
6923
+ width: '100%',
6924
+ display: 'flex',
6925
+ alignItems: 'center'
6926
+ },
6927
+ iframeContainer: {
6928
+ width: '90%',
6929
+ position: 'relative',
6930
+ paddingBottom: '56.25%',
6931
+ // top: "6%",
6932
+ left: '5%'
6933
+ },
6934
+ offerText: {
6935
+ textAlign: 'center',
6936
+ color: theme.palette.font.primary
6937
+ },
6938
+ offerPrice: {
6939
+ fontSize: '32px',
6940
+ fontWeight: '700'
6941
+ },
6942
+ priceContainer: {
6943
+ display: 'flex',
6944
+ flexDirection: 'column',
6945
+ width: 'fit-content'
6946
+ },
6947
+ originalPrice: {
6948
+ textDecoration: 'line-through',
6949
+ color: 'rgba(51, 51, 51, 0.6)'
6950
+ },
6951
+ offerDiscount: {
6952
+ color: '#08BD80',
6953
+ fontWeight: '600'
6954
+ },
6955
+ bottomContainer: {
6956
+ display: 'flex',
6957
+ justifyContent: 'space-around',
6958
+ marginTop: '5%'
6959
+ },
6960
+ iframe: {
6961
+ position: 'absolute',
6962
+ width: '100%',
6963
+ height: '100%',
6964
+ borderRadius: theme.shape.borderRadius.small
6965
+ },
6966
+ videoDetails: {
6967
+ width: '100%',
6968
+ display: 'flex',
6969
+ flexDirection: 'column',
6970
+ alignItems: 'flex-start'
6971
+ },
6972
+ videoDetailsHeading: {
6973
+ fontSize: '40px',
6974
+ lineHeight: '48px',
6975
+ margin: '0',
6976
+ letterSpacing: '-1px',
6977
+ wordBreak: 'break-word',
6978
+ color: theme.palette.font.default
6979
+ },
6980
+ courseViewContainer: {
6981
+ width: '645px',
6982
+ backgroundColor: '#f4f9ff',
6983
+ display: 'flex',
6984
+ flexDirection: 'column'
6985
+ },
6986
+ bannerContainer: {
6987
+ background: '#EB5757',
6988
+ color: '#fff',
6989
+ textAlign: 'center',
6990
+ padding: '6.5px 18px',
6991
+ position: 'relative',
6992
+ '&:after': {
6993
+ width: '0',
6994
+ height: '0',
6995
+ border: '11.5px solid transparent',
6996
+ position: 'absolute',
6997
+ content: '""',
6998
+ borderTopColor: '#EB5757',
6999
+ right: '-23px',
7000
+ top: '0px',
7001
+ borderLeftColor: ' #EB5757'
7002
+ },
7003
+ '&:before': {
7004
+ width: 0,
7005
+ height: 0,
7006
+ border: '22.5px solid transparent',
7007
+ position: 'absolute',
7008
+ content: '""',
7009
+ borderBottomColor: '#EB5757',
7010
+ right: '-23px',
7011
+ top: '-10.5px'
7012
+ }
7013
+ },
7014
+ courseDetailsTags: {
7015
+ marginTop: '16px',
7016
+ display: 'flex'
7017
+ },
7018
+ courseDetailTag: {
7019
+ display: 'flex',
7020
+ alignItems: 'center',
7021
+ marginRight: '20px',
7022
+ '& div': {
7023
+ fontSize: '14px',
7024
+ marginLeft: '10px'
7025
+ }
7026
+ },
7027
+ courseDetailContent: {
7028
+ marginTop: '16px',
7029
+ fontSize: '16px',
7030
+ lineHeight: '24px',
7031
+ wordBreak: 'break-word',
7032
+ color: theme.palette.font.primary,
7033
+ margin: '10px 0 20px'
7034
+ },
7035
+ courseDetailViewFullDetails: {
7036
+ cursor: 'pointer',
7037
+ fontSize: '16px',
7038
+ lineHeight: '24px',
7039
+ margin: '0',
7040
+ color: '#1676F3',
7041
+ wordBreak: 'break-word'
7042
+ },
7043
+ courseDetailTime: {
7044
+ color: '#EB5757',
7045
+ fontWeight: '600'
7046
+ },
7047
+ '@media (max-width: 767px)': {
7048
+ courseViewContainer: {
7049
+ width: '100%'
7050
+ },
7051
+ courseSuperContainer: {
7052
+ padding: '20px 10px 60px 20px'
7053
+ },
7054
+ videoCarousel: {
7055
+ flexDirection: 'column-reverse',
7056
+ gap: '20px'
7057
+ },
7058
+ videoCarouselContainer: {
7059
+ height: 'max-content',
7060
+ paddingRight: '10px'
7061
+ },
7062
+ videoDetails: {
7063
+ width: '100%'
7064
+ },
7065
+ videoDetailsHeading: {
7066
+ fontSize: '20px',
7067
+ fontWeight: '600',
7068
+ lineHeight: '20px'
7069
+ },
7070
+ videoTestimonialTitle: {
7071
+ fontSize: '24px',
7072
+ lineHeight: '36px',
7073
+ letterSpacing: '-1px'
7074
+ },
7075
+ videoDetailsContent: {
7076
+ marginTop: '4px'
7077
+ }
7078
+ }
7079
+ };
7080
+ });
7081
+
7082
+ const SingleVideoSlide = props => {
7083
+ useEffect(() => {// remaining days epoch
7084
+ // current date epoch
7085
+ // subtract remaining days from current day epoch
7086
+ // moment the result - and see if there are days
7087
+ // days is present show days
7088
+ // else start reverse timer
7089
+ }, []);
7090
+
7091
+ const renderer = ({
7092
+ hours,
7093
+ minutes,
7094
+ seconds,
7095
+ completed
7096
+ }) => {
7097
+ if (hours < 24) {
7098
+ return /*#__PURE__*/React.createElement("span", null, hours, ":", minutes, ":", seconds);
7099
+ } else {
7100
+ let given = moment(props.data.endTime);
7101
+ let current = moment().startOf('day');
7102
+ return /*#__PURE__*/React.createElement("span", null, moment.duration(given.diff(current)).asDays());
7103
+ }
7104
+ };
7105
+
7106
+ const {
7107
+ data,
7108
+ courseBuyNow
7109
+ } = props;
7110
+ const classes = useCoursePromotionPage();
7111
+ console.log(courseBuyNow, 'courseBuyNow');
7112
+ return /*#__PURE__*/React.createElement("div", {
7113
+ className: classes.videoCarouselContainer
7114
+ }, /*#__PURE__*/React.createElement("div", {
7115
+ className: classes.coursePageCarousel
7116
+ }, /*#__PURE__*/React.createElement("div", {
7117
+ className: classes.iframeSuperContainer
7118
+ }, /*#__PURE__*/React.createElement("div", {
7119
+ className: classes.videoDetails
7120
+ }, /*#__PURE__*/React.createElement("h3", {
7121
+ className: classes.bannerContainer
7122
+ }, data.offerPriceValidFor <= 0 ? /*#__PURE__*/React.createElement(React.Fragment, null, "Hurry up! Offer for limited period only") : /*#__PURE__*/React.createElement(React.Fragment, null, "Hurry up! Offer is left for ", data.offerPriceValidFor, " users now")), /*#__PURE__*/React.createElement("h3", {
7123
+ ref: data?.videoTextHeading?.refSetter,
7124
+ className: classes.videoDetailsHeading,
7125
+ dangerouslySetInnerHTML: {
7126
+ __html: data.courseName
7127
+ }
7128
+ }), /*#__PURE__*/React.createElement("div", {
7129
+ className: classes.courseDetailsTags
7130
+ }, /*#__PURE__*/React.createElement("div", {
7131
+ className: classes.courseDetailTag
7132
+ }, /*#__PURE__*/React.createElement(Icon, {
7133
+ name: 'Clock'
7134
+ }), /*#__PURE__*/React.createElement("div", null, data.courseInfo?.validity ? data.courseInfo?.validity : '1 year Validity')), /*#__PURE__*/React.createElement("div", {
7135
+ className: classes.courseDetailTag
7136
+ }, /*#__PURE__*/React.createElement(Icon, {
7137
+ name: 'Book Saved'
7138
+ }), /*#__PURE__*/React.createElement("div", null, data.courseInfo?.books ? data.courseInfo?.books : 'Physical Books')), /*#__PURE__*/React.createElement("div", {
7139
+ className: classes.courseDetailTag
7140
+ }, /*#__PURE__*/React.createElement(Icon, {
7141
+ name: 'Certificate'
7142
+ }), /*#__PURE__*/React.createElement("div", null, data.courseInfo?.certificate ? data.courseInfo?.certificate : 'Course Cerficate'))), /*#__PURE__*/React.createElement("p", {
7143
+ ref: data?.videoTextContent?.refSetter,
7144
+ className: classes.courseDetailContent,
7145
+ dangerouslySetInnerHTML: {
7146
+ __html: data.description.substring(0, 250)
7147
+ }
7148
+ }), /*#__PURE__*/React.createElement("p", {
7149
+ ref: data?.videoTextSubContent?.refSetter,
7150
+ className: classes.courseDetailViewFullDetails,
7151
+ dangerouslySetInnerHTML: {
7152
+ __html: data.description.length > 250 ? 'Read More' : null
7153
+ }
7154
+ }))), /*#__PURE__*/React.createElement("div", {
7155
+ className: classes.courseViewContainer
7156
+ }, /*#__PURE__*/React.createElement("p", {
7157
+ className: classes.offerText
7158
+ }, "Offer Ends in", ' ', /*#__PURE__*/React.createElement("span", {
7159
+ className: classes.courseDetailTime
7160
+ }, /*#__PURE__*/React.createElement(Countdown, {
7161
+ renderer: renderer,
7162
+ date: data.endDate
7163
+ }))), /*#__PURE__*/React.createElement("div", {
7164
+ ref: data?.videoFrame?.refSetter,
7165
+ className: classes.iframeContainer
7166
+ }, /*#__PURE__*/React.createElement(VideoPlayer, {
7167
+ onlyThumbnail: true,
7168
+ imageUrl: data.thumbnail,
7169
+ videoUrl: data.thumbnail
7170
+ })), /*#__PURE__*/React.createElement("div", {
7171
+ className: classes.bottomContainer
7172
+ }, /*#__PURE__*/React.createElement("div", {
7173
+ className: classes.priceContainer
7174
+ }, /*#__PURE__*/React.createElement("div", {
7175
+ className: classes.offerPrice
7176
+ }, "\u20B9 ", data.effectivePrice), /*#__PURE__*/React.createElement("p", {
7177
+ style: {
7178
+ fontSize: '20px'
7179
+ }
7180
+ }, /*#__PURE__*/React.createElement("span", {
7181
+ className: classes.originalPrice
7182
+ }, "\u20B9 ", data.price), ' ', /*#__PURE__*/React.createElement("span", {
7183
+ className: classes.offerDiscount
7184
+ }, "50% OFF"))), /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement(Button, {
7185
+ style: {
7186
+ width: '150px'
7187
+ },
7188
+ data: {
7189
+ // link: 'headerData?.loginCtaLink',
7190
+ // isLink: 1,
7191
+ value: 'BUY NOW' // isExternal: 1
7192
+
7193
+ },
7194
+ onClick: courseBuyNow,
7195
+ type: 'primary',
7196
+ size: 'medium',
7197
+ target: null,
7198
+ rel: null // styling={isMobile ? { margin: '0 40px' } : {}}
7199
+
7200
+ }))))));
7201
+ };
7202
+
7203
+ function CoursePromotionPage({
7204
+ sectionData,
7205
+ extraProps = {}
7206
+ }) {
7207
+ const {
7208
+ layout: {
7209
+ containerWidth
7210
+ }
7211
+ } = useContext(PageContext);
7212
+ const classes = useCoursePromotionPage({
7213
+ containerWidth
7214
+ });
7215
+ console.log(sectionData, 'sectionData');
7216
+ return /*#__PURE__*/React.createElement("div", {
7217
+ className: classes.courseSuperContainer
7218
+ }, /*#__PURE__*/React.createElement("div", {
7219
+ className: classes.videoTestimonialContainer
7220
+ }, /*#__PURE__*/React.createElement("div", {
7221
+ className: classes.sectionContainer
7222
+ }, /*#__PURE__*/React.createElement(SingleVideoSlide, {
7223
+ data: sectionData.components[0].metadata,
7224
+ courseBuyNow: extraProps.courseBuyNow
7225
+ }))));
7226
+ }
7227
+
7228
+ var index$1 = /*#__PURE__*/Object.freeze({
7229
+ __proto__: null,
7230
+ 'default': CoursePromotionPage
7231
+ });
7232
+
7233
+ const useFormPageStyles = createUseStyles(theme => ({
7234
+ formPageSection: {
7235
+ padding: '35px 70px',
7236
+ background: '#F4F9FF',
7237
+ '&, & *, & *:before, & *:after': {
7238
+ fontFamily: theme?.typography?.fontFamily,
7239
+ boxSizing: 'border-box'
7240
+ }
7241
+ },
7242
+ formPageHeader: {
7243
+ textAlign: 'center'
7244
+ },
7245
+ formPageTitle: {
7246
+ fontSize: '50px',
7247
+ fontWeight: '700'
7248
+ },
7249
+ formPageSubtitle: {
7250
+ marginTop: '16px',
7251
+ fontSize: '16px',
7252
+ lineHeight: '23px',
7253
+ color: 'rgba(51, 51, 51, 0.5)',
7254
+ marginBottom: '32px'
7255
+ },
7256
+ formPageFormContainer: {
7257
+ marginTop: '32px',
7258
+ '& form': {
7259
+ padding: '35px 140px',
7260
+ background: '#FFFFFF',
7261
+ borderRadius: '8px',
7262
+ boxShadow: '0px 4px 10px rgba(0, 0, 0, 0.16)'
7263
+ }
7264
+ },
7265
+ inputField: {
7266
+ marginTop: '20px',
7267
+ padding: '20px',
7268
+ border: '1px solid #D8E0F0',
7269
+ borderRadius: '16px'
7270
+ },
7271
+ inputFieldLabel: {
7272
+ color: '#333',
7273
+ fontSize: '20px',
7274
+ display: 'block',
7275
+ marginBottom: '10px'
7276
+ },
7277
+ inputFieldControl: {
7278
+ width: '100%',
7279
+ height: '50px',
7280
+ borderRadius: '8px',
7281
+ border: '1px solid #D8E0F0',
7282
+ padding: '5px 10px',
7283
+ color: '#7D8592',
7284
+ fontSize: '16px'
7285
+ },
7286
+ checkboxField: {
7287
+ marginTop: '20px',
7288
+ padding: '20px',
7289
+ border: '1px solid #D8E0F0',
7290
+ borderRadius: '8px'
7291
+ },
7292
+ checkBoxFieldLabel: {
7293
+ color: '#333',
7294
+ fontSize: '20px',
7295
+ margin: '10px 0'
7296
+ },
7297
+ checkboxFieldControl: {
7298
+ padding: '6px 0',
7299
+ '& label': {
7300
+ fontFamily: '16px',
7301
+ marginLeft: '10px',
7302
+ color: '#7D8592'
7303
+ }
7304
+ },
7305
+ submitBtnContainer: {
7306
+ marginTop: '20px',
7307
+ width: '100%',
7308
+ margin: '0 auto',
7309
+ '& button': {
7310
+ background: '#6269C9',
7311
+ height: '44px',
7312
+ padding: '10px 40px',
7313
+ border: '1px solid #4A90E2',
7314
+ color: '#FFFFFF',
7315
+ fontSize: '16px',
7316
+ cursor: 'pointer',
7317
+ borderRadius: '8px'
7318
+ }
7319
+ },
7320
+ // SMALL SCREEN
7321
+ '@media screen and (max-width: 767px)': {
7322
+ formPageSection: {
7323
+ padding: '24px'
7324
+ },
7325
+ formPageTitle: {
7326
+ fontSize: '24px'
7327
+ },
7328
+ formPageFormContainer: {
7329
+ '& form': {
7330
+ padding: '24px'
7331
+ }
7332
+ }
7333
+ }
7334
+ }));
7335
+
7336
+ const formPageMock = {
7337
+ title: 'Sed ut perspiciatis unde omnis iste',
7338
+ subTitle: 'Sed ut perspiciatis unde omnis iste natus error',
7339
+ questions: [{
7340
+ _id: '22',
7341
+ text: 'fdsafds',
7342
+ type: 'SA',
7343
+ options: [{
7344
+ value: ''
7345
+ }],
7346
+ isRequired: false,
7347
+ order: 1
7348
+ }, {
7349
+ _id: '23',
7350
+ text: 'fasdfdsaffdsafds',
7351
+ type: 'MC',
7352
+ options: [{
7353
+ value: 'fadsfdsf'
7354
+ }, {
7355
+ value: 'fdsafdsaf'
7356
+ }, {
7357
+ value: 'fsadfd'
7358
+ }, {
7359
+ value: 'fadsf'
7360
+ }],
7361
+ isRequired: false,
7362
+ order: 1
7363
+ }, {
7364
+ _id: '24',
7365
+ text: 'ewaofdsfkds',
7366
+ type: 'SC',
7367
+ options: [{
7368
+ value: 'fasdfdsf'
7369
+ }, {
7370
+ value: 'fasdfdasf'
7371
+ }, {
7372
+ value: 'fdsafsdf'
7373
+ }, {
7374
+ value: 'fdsafds'
7375
+ }],
7376
+ isRequired: false,
7377
+ order: 1
7378
+ }]
7379
+ };
7380
+
7381
+ const FormPage = ({
7382
+ sectionData,
7383
+ extraProps = {}
7384
+ }) => {
7385
+ const [formData, setFormData] = useState({});
7386
+ const classes = useFormPageStyles();
7387
+ const metadata = sectionData?.components?.[0]?.metadata || formPageMock;
7388
+ const {
7389
+ _id
7390
+ } = useContext(PageContext);
7391
+
7392
+ const handleSubmit = async e => {
7393
+ e.preventDefault();
7394
+ let formResponse = [];
7395
+
7396
+ for (const [key, value] of Object.entries(formData)) {
7397
+ formResponse.push({
7398
+ questionId: key,
7399
+ questionName: value.questionName,
7400
+ questionType: value.questionType,
7401
+ solutionArray: value.solutionArray
7402
+ });
7403
+ } // page id - section id
7404
+
7405
+
7406
+ axios.post(`https://diy.clp.staging.classplus.co/v1/diy/landingPages/form`, {
7407
+ paylaod: formResponse,
7408
+ sectionId: sectionData?.components?.[0]?._id || null,
7409
+ landingPageId: _id || null
7410
+ }).then(() => {
7411
+ if (extraProps && extraProps.formSubmitSuccess) {
7412
+ extraProps.formSubmitSuccess();
7413
+ }
7414
+ });
7415
+ };
7416
+
7417
+ return /*#__PURE__*/React.createElement("section", {
7418
+ className: classes.formPageSection
7419
+ }, /*#__PURE__*/React.createElement("div", {
7420
+ className: classes.formPageFormContainer
7421
+ }, /*#__PURE__*/React.createElement("form", {
7422
+ onSubmit: handleSubmit
7423
+ }, /*#__PURE__*/React.createElement("div", {
7424
+ className: classes.formPageHeader
7425
+ }, /*#__PURE__*/React.createElement("div", {
7426
+ className: classes.formPageTitle
7427
+ }, metadata?.title), /*#__PURE__*/React.createElement("div", {
7428
+ className: classes.formPageSubtitle
7429
+ }, metadata?.subTitle)), metadata?.questions?.map((item, index) => /*#__PURE__*/React.createElement(React.Fragment, null, item.type === 'SA' && /*#__PURE__*/React.createElement("div", {
7430
+ className: classes.inputField
7431
+ }, /*#__PURE__*/React.createElement("label", {
7432
+ className: classes.inputFieldLabel
7433
+ }, item.text), /*#__PURE__*/React.createElement("input", {
7434
+ className: classes.inputFieldControl,
7435
+ type: "text",
7436
+ placeholder: "Short answer",
7437
+ name: item._id,
7438
+ onChange: e => {
7439
+ setFormData({ ...formData,
7440
+ [item._id]: {
7441
+ questionName: item.text,
7442
+ solutionArray: [e.target.value],
7443
+ questionType: 'SA'
7444
+ }
7445
+ });
7446
+ }
7447
+ })), item.type === 'MC' && /*#__PURE__*/React.createElement("div", {
7448
+ className: classes.checkboxField
7449
+ }, /*#__PURE__*/React.createElement("div", {
7450
+ className: classes.checkBoxFieldLabel
7451
+ }, item.text), item.options.map((option, index) => /*#__PURE__*/React.createElement("div", {
7452
+ className: classes.checkboxFieldControl
7453
+ }, /*#__PURE__*/React.createElement("input", {
7454
+ value: option.value,
7455
+ type: "checkbox",
7456
+ name: option.value,
7457
+ id: option.value,
7458
+ onChange: e => {
7459
+ setFormData({ ...formData,
7460
+ [item._id]: {
7461
+ questionName: item.text,
7462
+ solutionArray: [],
7463
+ questionType: 'SA'
7464
+ }
7465
+ });
7466
+ },
7467
+ onBlur: e => {
7468
+ let newSolArray = [];
7469
+
7470
+ if (formData[item._id]) {
7471
+ if (!formData[item._id].solutionArray?.find(el => el === option.value)) {
7472
+ newSolArray.push(e.target.value);
7473
+ }
7474
+ }
7475
+
7476
+ setFormData({ ...formData,
7477
+ [item._id]: {
7478
+ questionName: item.text,
7479
+ solutionArray: [...newSolArray],
7480
+ questionType: 'SA'
7481
+ }
7482
+ });
7483
+ }
7484
+ }), /*#__PURE__*/React.createElement("label", {
7485
+ htmlFor: option.value
7486
+ }, option.value)))), item.type === 'SC' && /*#__PURE__*/React.createElement("div", {
7487
+ className: classes.checkboxField
7488
+ }, /*#__PURE__*/React.createElement("div", {
7489
+ className: classes.checkBoxFieldLabel
7490
+ }, item.text), item.options.map((option, index) => /*#__PURE__*/React.createElement("div", {
7491
+ className: classes.checkboxFieldControl
7492
+ }, /*#__PURE__*/React.createElement("input", {
7493
+ // value={option.value}
7494
+ type: "radio",
7495
+ name: "text" // name={option.value}
7496
+ // id={option.value}
7497
+ ,
7498
+ onChange: e => {
7499
+ setFormData({ ...formData,
7500
+ [item._id]: {
7501
+ questionName: item.text,
7502
+ solutionArray: [item.text],
7503
+ questionType: 'SC'
7504
+ }
7505
+ });
7506
+ }
7507
+ }), /*#__PURE__*/React.createElement("label", {
7508
+ htmlFor: option.value
7509
+ }, option.value)))))), /*#__PURE__*/React.createElement("div", {
7510
+ className: classes.submitBtnContainer
7511
+ }, /*#__PURE__*/React.createElement("button", null, "Submit")))));
7512
+ };
7513
+
7514
+ var index = /*#__PURE__*/Object.freeze({
7515
+ __proto__: null,
7516
+ 'default': FormPage
7517
+ });
7518
+
7519
+ const TYPE_TO_COMPONENT_MAP = {
7520
+ BANNER_CAROUSEL_RIGHT: BannerCarouselRight,
7521
+ GRID_CARD: List,
7522
+ BANNER_CAROUSEL_CENTER: BannerCarouselCenter,
7523
+ BANNER_CAROUSEL_LEFT: BannerCarouselLeft,
7524
+ FORM_SUBSCRIBE: SubscribeToNewsletter,
7525
+ TEXT_TESTIMONIAL: Testimonials,
7526
+ VIDEO_TESTIMONIAL: VideoTestimonial,
7527
+ VIDEO: Video,
7528
+ INFO: Info,
7529
+ TEXT: TextSection,
7530
+ IMAGE_GALLERY: PhotoGallery,
7531
+ FAQ_LISTING: FAQListing,
7532
+ TEXT_GRID: TextGrid,
7533
+ COURSE_CAROUSEL: courses,
7534
+ TEAM_CARD: TeamCard,
7535
+ CONTACT: FormEnquiry,
7536
+ FORM_ENQUIRY: Contact,
7537
+ WEBINAR_LANDING_PAGE: CoursePromotionPage$1,
7538
+ COURSE_LANDING_PAGE: CoursePromotionPage,
7539
+ FORM_LANDING_PAGE: FormPage
7540
+ };
7541
+
7542
+ const getCompToRender = type => TYPE_TO_COMPONENT_MAP[type] || (() => null);
7543
+
7544
+ const MemoisedSection = /*#__PURE__*/memo(({
7545
+ sectionData,
7546
+ extraProps
7547
+ }) => {
7548
+ const SectionComp = getCompToRender(sectionData.type);
7549
+ return /*#__PURE__*/React.createElement(SectionComp, {
7550
+ sectionData: sectionData,
7551
+ extraProps: extraProps
7552
+ });
7553
+ });
7554
+ function SectionRenderer({
7555
+ sectionData,
7556
+ extraProps
6494
7557
  }) {
6495
7558
  return /*#__PURE__*/React.createElement(MemoisedSection, {
6496
- sectionData: sectionData
7559
+ sectionData: sectionData,
7560
+ extraProps: extraProps
6497
7561
  });
6498
7562
  }
6499
7563
 
@@ -6512,6 +7576,7 @@ function PageRenderer({
6512
7576
  validations = {}
6513
7577
  },
6514
7578
  isMobile = false,
7579
+ isLandingPages = false,
6515
7580
  baseURLs = {},
6516
7581
  hashToken,
6517
7582
  SectionWrapper,
@@ -6521,12 +7586,15 @@ function PageRenderer({
6521
7586
  isEdit,
6522
7587
  sectionPlaceholder,
6523
7588
  templateId,
6524
- isTutorWebsite = false
7589
+ isTutorWebsite = false,
7590
+ extraProps,
7591
+ hideLogin
6525
7592
  }) {
6526
7593
  const theme = useMemo(() => getTheme(color, font), [color, font]);
6527
7594
  const navList = header?.navs;
6528
7595
  const context = useMemo(() => ({
6529
7596
  isMobile,
7597
+ isLandingPages,
6530
7598
  layout,
6531
7599
  baseURLs,
6532
7600
  hashToken,
@@ -6537,8 +7605,10 @@ function PageRenderer({
6537
7605
  templateId,
6538
7606
  navList,
6539
7607
  validations,
6540
- isTutorWebsite
6541
- }), [isMobile, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite]);
7608
+ isTutorWebsite,
7609
+ extraProps,
7610
+ hideLogin
7611
+ }), [isMobile, isLandingPages, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite, extraProps, hideLogin]);
6542
7612
  const Wrapper = SectionWrapper || Fragment;
6543
7613
  return /*#__PURE__*/React.createElement(ThemeProvider, {
6544
7614
  theme: theme
@@ -6557,7 +7627,8 @@ function PageRenderer({
6557
7627
  }, {
6558
7628
  key: sectionData.type + (sectionData._id || sectionIndex)
6559
7629
  }), /*#__PURE__*/React.createElement(SectionRenderer, {
6560
- sectionData: sectionData
7630
+ sectionData: sectionData,
7631
+ extraProps: extraProps
6561
7632
  }))) : sectionPlaceholder, !!footer && /*#__PURE__*/React.createElement(Wrapper, !!SectionWrapper && {
6562
7633
  sectionData: footer,
6563
7634
  isFooter: true