diy-template-components 0.2.39 → 0.2.41
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 +71 -50
- package/build/index.es.js.map +1 -1
- package/build/index.js +71 -50
- package/build/index.js.map +1 -1
- package/package.json +1 -1
package/build/index.es.js
CHANGED
|
@@ -94,9 +94,11 @@ const useSectionStyles$a = createUseStyles(theme => ({
|
|
|
94
94
|
}
|
|
95
95
|
},
|
|
96
96
|
imageAnchor: {
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
97
|
+
pointerEvents: 'auto',
|
|
98
|
+
cursor: 'default',
|
|
99
|
+
position: 'relative',
|
|
100
|
+
height: '55px',
|
|
101
|
+
width: 'inherit'
|
|
100
102
|
},
|
|
101
103
|
optionsContainer: {
|
|
102
104
|
display: 'flex',
|
|
@@ -137,7 +139,20 @@ const useSectionStyles$a = createUseStyles(theme => ({
|
|
|
137
139
|
},
|
|
138
140
|
imageDiv: {
|
|
139
141
|
display: 'flex',
|
|
140
|
-
|
|
142
|
+
position: 'relative',
|
|
143
|
+
maxHeight: '55px',
|
|
144
|
+
alignItems: 'center',
|
|
145
|
+
width: '25%'
|
|
146
|
+
},
|
|
147
|
+
imageDivImageMobile: {},
|
|
148
|
+
imageAnchorMobile: {
|
|
149
|
+
pointerEvents: 'auto',
|
|
150
|
+
cursor: 'default',
|
|
151
|
+
width: '100%',
|
|
152
|
+
maxWidth: '80px',
|
|
153
|
+
cursor: 'default',
|
|
154
|
+
height: '46px',
|
|
155
|
+
position: 'relative'
|
|
141
156
|
},
|
|
142
157
|
appNameClass: {
|
|
143
158
|
fontStyle: 'normal',
|
|
@@ -150,6 +165,7 @@ const useSectionStyles$a = createUseStyles(theme => ({
|
|
|
150
165
|
mobileContent: {
|
|
151
166
|
display: 'flex',
|
|
152
167
|
alignItems: 'center',
|
|
168
|
+
width: "100%",
|
|
153
169
|
'& img': {
|
|
154
170
|
marginRight: '8px',
|
|
155
171
|
maxWidth: '80px',
|
|
@@ -192,7 +208,8 @@ const useSectionStyles$a = createUseStyles(theme => ({
|
|
|
192
208
|
padding: '8px',
|
|
193
209
|
display: 'flex',
|
|
194
210
|
alignItems: 'center',
|
|
195
|
-
justifyContent: 'center'
|
|
211
|
+
justifyContent: 'center',
|
|
212
|
+
width: "10%"
|
|
196
213
|
},
|
|
197
214
|
'@media screen and (max-width: 767px)': {
|
|
198
215
|
optionsContainer: {
|
|
@@ -1083,6 +1100,42 @@ function OptionList({
|
|
|
1083
1100
|
}) : null));
|
|
1084
1101
|
}
|
|
1085
1102
|
|
|
1103
|
+
const NextImageRenderer = ({
|
|
1104
|
+
src,
|
|
1105
|
+
...props
|
|
1106
|
+
}) => {
|
|
1107
|
+
const {
|
|
1108
|
+
isCustomWebsite
|
|
1109
|
+
} = useContext(PageContext);
|
|
1110
|
+
const imageLoader = ({
|
|
1111
|
+
src,
|
|
1112
|
+
quality,
|
|
1113
|
+
width
|
|
1114
|
+
}) => {
|
|
1115
|
+
return `${process.env.NEXT_PUBLIC_ENV_ASSET_PREFIX}/_next/image?url=${src}&q=${quality || 75}&w=${width}`;
|
|
1116
|
+
};
|
|
1117
|
+
let {
|
|
1118
|
+
refSetter,
|
|
1119
|
+
className
|
|
1120
|
+
} = props;
|
|
1121
|
+
if (isCustomWebsite) {
|
|
1122
|
+
const NextImage = require('next/image').default;
|
|
1123
|
+
return /*#__PURE__*/React.createElement(NextImage, _extends({
|
|
1124
|
+
loader: imageLoader,
|
|
1125
|
+
src: src,
|
|
1126
|
+
layout: 'fill',
|
|
1127
|
+
ref: refSetter,
|
|
1128
|
+
className: className
|
|
1129
|
+
}, props));
|
|
1130
|
+
} else {
|
|
1131
|
+
return /*#__PURE__*/React.createElement("img", {
|
|
1132
|
+
ref: refSetter,
|
|
1133
|
+
className: className,
|
|
1134
|
+
src: src
|
|
1135
|
+
});
|
|
1136
|
+
}
|
|
1137
|
+
};
|
|
1138
|
+
|
|
1086
1139
|
function DesktopHeader({
|
|
1087
1140
|
header,
|
|
1088
1141
|
navData,
|
|
@@ -1132,9 +1185,12 @@ function DesktopHeader({
|
|
|
1132
1185
|
pointerEvents: isLandingPage ? 'none' : 'auto',
|
|
1133
1186
|
cursor: isLandingPage ? 'not-allowed' : 'default'
|
|
1134
1187
|
}
|
|
1135
|
-
}, /*#__PURE__*/React.createElement("
|
|
1136
|
-
|
|
1137
|
-
}
|
|
1188
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1189
|
+
className: classes?.imageDivImage
|
|
1190
|
+
}, /*#__PURE__*/React.createElement(NextImageRenderer, {
|
|
1191
|
+
src: header?.websiteLogo,
|
|
1192
|
+
className: classes.imageDivImageNext
|
|
1193
|
+
}))) : null, isTutorWebsite && header?.appName ? /*#__PURE__*/React.createElement("a", {
|
|
1138
1194
|
href: logoUrl
|
|
1139
1195
|
}, /*#__PURE__*/React.createElement("p", {
|
|
1140
1196
|
className: classes.appNameClass
|
|
@@ -1294,14 +1350,17 @@ function MobileHeader({
|
|
|
1294
1350
|
width: '24px'
|
|
1295
1351
|
})), header?.websiteLogo ? /*#__PURE__*/React.createElement("a", {
|
|
1296
1352
|
href: logoUrl,
|
|
1297
|
-
className: classes.
|
|
1353
|
+
className: classes.imageAnchorMobile,
|
|
1298
1354
|
style: {
|
|
1299
1355
|
pointerEvents: isLandingPage ? 'none' : 'auto',
|
|
1300
1356
|
cursor: isLandingPage ? 'not-allowed' : 'default'
|
|
1301
1357
|
}
|
|
1302
|
-
}, /*#__PURE__*/React.createElement("
|
|
1303
|
-
|
|
1304
|
-
}
|
|
1358
|
+
}, /*#__PURE__*/React.createElement("div", {
|
|
1359
|
+
className: classes?.imageDivImageMobile
|
|
1360
|
+
}, /*#__PURE__*/React.createElement(NextImageRenderer, {
|
|
1361
|
+
src: header?.websiteLogo,
|
|
1362
|
+
className: classes.imageDivImageNext
|
|
1363
|
+
}))) : null, isTutorWebsite && header?.appName ? /*#__PURE__*/React.createElement("p", {
|
|
1305
1364
|
className: classes.mobileAppNameClass
|
|
1306
1365
|
}, " ", header?.appName) : null), downloadLink), sideMenu ? /*#__PURE__*/React.createElement("div", {
|
|
1307
1366
|
className: classes.mobileMenu
|
|
@@ -1514,44 +1573,6 @@ const useSectionStyles$9 = createUseStyles(theme => ({
|
|
|
1514
1573
|
}
|
|
1515
1574
|
}));
|
|
1516
1575
|
|
|
1517
|
-
const NextImageRenderer = ({
|
|
1518
|
-
src,
|
|
1519
|
-
...props
|
|
1520
|
-
}) => {
|
|
1521
|
-
const {
|
|
1522
|
-
isCustomWebsite
|
|
1523
|
-
} = useContext(PageContext);
|
|
1524
|
-
const imageLoader = ({
|
|
1525
|
-
src,
|
|
1526
|
-
quality
|
|
1527
|
-
}) => {
|
|
1528
|
-
return `${process.env.NEXT_PUBLIC_ENV_ASSET_PREFIX}/_next/image?url=${src}&q=${quality || 75}`;
|
|
1529
|
-
};
|
|
1530
|
-
|
|
1531
|
-
// const imageUrl = `${process.env.NEXT_PUBLIC_ENV_ASSET_PREFIX}/_next/image?url=${src}&q=${quality || 75}`;
|
|
1532
|
-
|
|
1533
|
-
let {
|
|
1534
|
-
refSetter,
|
|
1535
|
-
className
|
|
1536
|
-
} = props;
|
|
1537
|
-
if (isCustomWebsite) {
|
|
1538
|
-
const NextImage = require('next/image').default;
|
|
1539
|
-
return /*#__PURE__*/React.createElement(NextImage, _extends({
|
|
1540
|
-
loader: imageLoader,
|
|
1541
|
-
src: src,
|
|
1542
|
-
layout: 'fill',
|
|
1543
|
-
ref: refSetter,
|
|
1544
|
-
className: className
|
|
1545
|
-
}, props));
|
|
1546
|
-
} else {
|
|
1547
|
-
return /*#__PURE__*/React.createElement("img", {
|
|
1548
|
-
ref: refSetter,
|
|
1549
|
-
className: className,
|
|
1550
|
-
src: src
|
|
1551
|
-
});
|
|
1552
|
-
}
|
|
1553
|
-
};
|
|
1554
|
-
|
|
1555
1576
|
function Footer({
|
|
1556
1577
|
data
|
|
1557
1578
|
}) {
|