diy-template-components 0.2.65 → 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 +17 -9
- package/build/index.es.js.map +1 -1
- package/build/index.js +17 -9
- 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,8 +1155,8 @@ const NextImageRenderer = ({
|
|
|
1153
1155
|
desktop: 1200
|
|
1154
1156
|
};
|
|
1155
1157
|
const dynamicWidth = isMobile ? breakpoints.mobile : breakpoints?.desktop;
|
|
1156
|
-
if (
|
|
1157
|
-
return `${
|
|
1158
|
+
if (ASSET_PREFIX_URL !== undefined) {
|
|
1159
|
+
return `${ASSET_PREFIX_URL}/_next/image?url=${src}&w=${width}&q=${quality || 75}`;
|
|
1158
1160
|
} else {
|
|
1159
1161
|
return `/_next/image?url=${src}&w=${width}&q=${quality || 75}`;
|
|
1160
1162
|
}
|
|
@@ -2068,9 +2070,11 @@ function PageRenderer$1({
|
|
|
2068
2070
|
isTutorWebsite = false,
|
|
2069
2071
|
extraProps,
|
|
2070
2072
|
hideLogin,
|
|
2071
|
-
isCustomWebsite
|
|
2073
|
+
isCustomWebsite,
|
|
2074
|
+
ASSET_PREFIX_URL = undefined
|
|
2072
2075
|
}) {
|
|
2073
2076
|
const theme = useMemo(() => getTheme(color, font), [color, font]);
|
|
2077
|
+
console.log("pageRenderer", ASSET_PREFIX_URL);
|
|
2074
2078
|
const navList = header?.navs;
|
|
2075
2079
|
const context = useMemo(() => ({
|
|
2076
2080
|
isMobile,
|
|
@@ -2089,8 +2093,9 @@ function PageRenderer$1({
|
|
|
2089
2093
|
extraProps,
|
|
2090
2094
|
hideLogin,
|
|
2091
2095
|
isCustomWebsite,
|
|
2092
|
-
_id
|
|
2093
|
-
|
|
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]);
|
|
2094
2099
|
const Wrapper = SectionWrapper || Fragment;
|
|
2095
2100
|
return /*#__PURE__*/React.createElement(ThemeProvider, {
|
|
2096
2101
|
theme: theme
|
|
@@ -8828,10 +8833,12 @@ function PageRenderer({
|
|
|
8828
8833
|
templateId,
|
|
8829
8834
|
isTutorWebsite = false,
|
|
8830
8835
|
extraProps,
|
|
8831
|
-
hideLogin
|
|
8836
|
+
hideLogin,
|
|
8837
|
+
ASSET_PREFIX_URL
|
|
8832
8838
|
}) {
|
|
8833
8839
|
const theme = useMemo(() => getTheme(color, font), [color, font]);
|
|
8834
8840
|
const navList = header?.navs;
|
|
8841
|
+
console.log("pageRenderer static", ASSET_PREFIX_URL);
|
|
8835
8842
|
const context = useMemo(() => ({
|
|
8836
8843
|
isMobile,
|
|
8837
8844
|
isLandingPages,
|
|
@@ -8849,8 +8856,9 @@ function PageRenderer({
|
|
|
8849
8856
|
extraProps,
|
|
8850
8857
|
hideLogin,
|
|
8851
8858
|
isCustomWebsite,
|
|
8852
|
-
_id
|
|
8853
|
-
|
|
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]);
|
|
8854
8862
|
const Wrapper = SectionWrapper || Fragment;
|
|
8855
8863
|
return /*#__PURE__*/React.createElement(ThemeProvider, {
|
|
8856
8864
|
theme: theme
|