diy-template-components 0.2.64 → 0.2.66
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 +20 -8
- package/build/index.es.js.map +1 -1
- package/build/index.js +20 -8
- package/build/index.js.map +1 -1
- package/package.json +2 -2
package/build/index.es.js
CHANGED
|
@@ -1134,8 +1134,10 @@ const NextImageRenderer = ({
|
|
|
1134
1134
|
const {
|
|
1135
1135
|
isCustomWebsite,
|
|
1136
1136
|
pageData,
|
|
1137
|
-
isMobile
|
|
1137
|
+
isMobile,
|
|
1138
|
+
ASSET_PREFIX_URL
|
|
1138
1139
|
} = useContext(PageContext);
|
|
1140
|
+
console.log("pageRenderer wrapper", ASSET_PREFIX_URL);
|
|
1139
1141
|
try {
|
|
1140
1142
|
let {
|
|
1141
1143
|
refSetter,
|
|
@@ -1153,7 +1155,11 @@ const NextImageRenderer = ({
|
|
|
1153
1155
|
desktop: 1200
|
|
1154
1156
|
};
|
|
1155
1157
|
const dynamicWidth = isMobile ? breakpoints.mobile : breakpoints?.desktop;
|
|
1156
|
-
|
|
1158
|
+
if (ASSET_PREFIX_URL !== undefined) {
|
|
1159
|
+
return `${ASSET_PREFIX_URL}/_next/image?url=${src}&w=${width}&q=${quality || 75}`;
|
|
1160
|
+
} else {
|
|
1161
|
+
return `/_next/image?url=${src}&w=${width}&q=${quality || 75}`;
|
|
1162
|
+
}
|
|
1157
1163
|
};
|
|
1158
1164
|
const NextImage = require('next/image').default;
|
|
1159
1165
|
return /*#__PURE__*/React.createElement(NextImage, _extends({
|
|
@@ -2064,9 +2070,11 @@ function PageRenderer$1({
|
|
|
2064
2070
|
isTutorWebsite = false,
|
|
2065
2071
|
extraProps,
|
|
2066
2072
|
hideLogin,
|
|
2067
|
-
isCustomWebsite
|
|
2073
|
+
isCustomWebsite,
|
|
2074
|
+
ASSET_PREFIX_URL = undefined
|
|
2068
2075
|
}) {
|
|
2069
2076
|
const theme = useMemo(() => getTheme(color, font), [color, font]);
|
|
2077
|
+
console.log("pageRenderer", ASSET_PREFIX_URL);
|
|
2070
2078
|
const navList = header?.navs;
|
|
2071
2079
|
const context = useMemo(() => ({
|
|
2072
2080
|
isMobile,
|
|
@@ -2085,8 +2093,9 @@ function PageRenderer$1({
|
|
|
2085
2093
|
extraProps,
|
|
2086
2094
|
hideLogin,
|
|
2087
2095
|
isCustomWebsite,
|
|
2088
|
-
_id
|
|
2089
|
-
|
|
2096
|
+
_id,
|
|
2097
|
+
ASSET_PREFIX_URL
|
|
2098
|
+
}), [isMobile, isLandingPages, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite, extraProps, hideLogin, _id, ASSET_PREFIX_URL]);
|
|
2090
2099
|
const Wrapper = SectionWrapper || Fragment;
|
|
2091
2100
|
return /*#__PURE__*/React.createElement(ThemeProvider, {
|
|
2092
2101
|
theme: theme
|
|
@@ -8824,10 +8833,12 @@ function PageRenderer({
|
|
|
8824
8833
|
templateId,
|
|
8825
8834
|
isTutorWebsite = false,
|
|
8826
8835
|
extraProps,
|
|
8827
|
-
hideLogin
|
|
8836
|
+
hideLogin,
|
|
8837
|
+
ASSET_PREFIX_URL
|
|
8828
8838
|
}) {
|
|
8829
8839
|
const theme = useMemo(() => getTheme(color, font), [color, font]);
|
|
8830
8840
|
const navList = header?.navs;
|
|
8841
|
+
console.log("pageRenderer static", ASSET_PREFIX_URL);
|
|
8831
8842
|
const context = useMemo(() => ({
|
|
8832
8843
|
isMobile,
|
|
8833
8844
|
isLandingPages,
|
|
@@ -8845,8 +8856,9 @@ function PageRenderer({
|
|
|
8845
8856
|
extraProps,
|
|
8846
8857
|
hideLogin,
|
|
8847
8858
|
isCustomWebsite,
|
|
8848
|
-
_id
|
|
8849
|
-
|
|
8859
|
+
_id,
|
|
8860
|
+
ASSET_PREFIX_URL
|
|
8861
|
+
}), [isMobile, isLandingPages, layout, baseURLs, hashToken, isPreview, isEdit, templateId, navList, isMasterTemplate, basePath, validations, isTutorWebsite, extraProps, hideLogin, _id, ASSET_PREFIX_URL]);
|
|
8850
8862
|
const Wrapper = SectionWrapper || Fragment;
|
|
8851
8863
|
return /*#__PURE__*/React.createElement(ThemeProvider, {
|
|
8852
8864
|
theme: theme
|