diy-template-components 0.2.35 → 0.2.37
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 +58 -43
- package/build/index.es.js.map +1 -1
- package/build/index.js +58 -43
- package/build/index.js.map +1 -1
- package/package.json +2 -2
package/build/index.js
CHANGED
|
@@ -2,15 +2,15 @@
|
|
|
2
2
|
|
|
3
3
|
|
|
4
4
|
|
|
5
|
-
function ___$insertStyle(css) {
|
|
6
|
-
if (!css ||
|
|
7
|
-
return;
|
|
8
|
-
}
|
|
9
|
-
const style = document.createElement('style');
|
|
10
|
-
style.setAttribute('type', 'text/css');
|
|
11
|
-
style.innerHTML = css;
|
|
12
|
-
document.head.appendChild(style);
|
|
13
|
-
return css;
|
|
5
|
+
function ___$insertStyle(css) {
|
|
6
|
+
if (!css || typeof window === 'undefined') {
|
|
7
|
+
return;
|
|
8
|
+
}
|
|
9
|
+
const style = document.createElement('style');
|
|
10
|
+
style.setAttribute('type', 'text/css');
|
|
11
|
+
style.innerHTML = css;
|
|
12
|
+
document.head.appendChild(style);
|
|
13
|
+
return css;
|
|
14
14
|
}
|
|
15
15
|
|
|
16
16
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
@@ -1386,10 +1386,16 @@ const useSectionStyles$9 = createUseStyles(theme => ({
|
|
|
1386
1386
|
upperContainerItem1: {
|
|
1387
1387
|
width: '33%',
|
|
1388
1388
|
display: 'flex',
|
|
1389
|
-
justifyContent: 'flex-start'
|
|
1390
|
-
|
|
1391
|
-
|
|
1392
|
-
|
|
1389
|
+
justifyContent: 'flex-start'
|
|
1390
|
+
|
|
1391
|
+
// '& img': { maxHeight: '55px' }
|
|
1392
|
+
},
|
|
1393
|
+
|
|
1394
|
+
upperContainerItem1Img: {
|
|
1395
|
+
maxHeight: '55px',
|
|
1396
|
+
paddingBottom: '84px',
|
|
1397
|
+
position: 'relative',
|
|
1398
|
+
width: '33%'
|
|
1393
1399
|
},
|
|
1394
1400
|
upperContainerItem2: {
|
|
1395
1401
|
width: '33%'
|
|
@@ -1523,6 +1529,41 @@ const useSectionStyles$9 = createUseStyles(theme => ({
|
|
|
1523
1529
|
}
|
|
1524
1530
|
}));
|
|
1525
1531
|
|
|
1532
|
+
const NextImageRenderer = ({
|
|
1533
|
+
src,
|
|
1534
|
+
...props
|
|
1535
|
+
}) => {
|
|
1536
|
+
const {
|
|
1537
|
+
isCustomWebsite
|
|
1538
|
+
} = React.useContext(PageContext);
|
|
1539
|
+
const imageLoader = ({
|
|
1540
|
+
src,
|
|
1541
|
+
quality
|
|
1542
|
+
}) => {
|
|
1543
|
+
return `${process.env.NEXT_PUBLIC_ENV_ASSET_PREFIX}/_next/image?url=${src}&q=${quality || 75}`;
|
|
1544
|
+
};
|
|
1545
|
+
let {
|
|
1546
|
+
refSetter,
|
|
1547
|
+
className
|
|
1548
|
+
} = props;
|
|
1549
|
+
if (isCustomWebsite) {
|
|
1550
|
+
const NextImage = require('next/image').default;
|
|
1551
|
+
return /*#__PURE__*/React__default["default"].createElement(NextImage, _extends({
|
|
1552
|
+
loader: imageLoader,
|
|
1553
|
+
src: src,
|
|
1554
|
+
layout: 'fill',
|
|
1555
|
+
ref: refSetter,
|
|
1556
|
+
className: className
|
|
1557
|
+
}, props));
|
|
1558
|
+
} else {
|
|
1559
|
+
return /*#__PURE__*/React__default["default"].createElement("img", {
|
|
1560
|
+
ref: refSetter,
|
|
1561
|
+
className: className,
|
|
1562
|
+
src: src
|
|
1563
|
+
});
|
|
1564
|
+
}
|
|
1565
|
+
};
|
|
1566
|
+
|
|
1526
1567
|
function Footer({
|
|
1527
1568
|
data
|
|
1528
1569
|
}) {
|
|
@@ -1535,10 +1576,12 @@ function Footer({
|
|
|
1535
1576
|
className: classes.upperContainer
|
|
1536
1577
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1537
1578
|
className: classes.upperContainerItem1
|
|
1538
|
-
}, /*#__PURE__*/React__default["default"].createElement("
|
|
1579
|
+
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1580
|
+
className: classes.upperContainerItem1Img
|
|
1581
|
+
}, /*#__PURE__*/React__default["default"].createElement(NextImageRenderer, {
|
|
1539
1582
|
src: data?.logo?.metadata?.url,
|
|
1540
1583
|
ref: data?.logo?.refSetter
|
|
1541
|
-
})), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1584
|
+
}))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
1542
1585
|
className: classes.upperContainerItem2
|
|
1543
1586
|
}, data?.address?.metadata.value && data?.address?.metadata.value !== '<br>' ? /*#__PURE__*/React__default["default"].createElement("p", {
|
|
1544
1587
|
className: classes.addressContainer
|
|
@@ -2282,34 +2325,6 @@ function Carousel({
|
|
|
2282
2325
|
})));
|
|
2283
2326
|
}
|
|
2284
2327
|
|
|
2285
|
-
const NextImageRenderer = ({
|
|
2286
|
-
src,
|
|
2287
|
-
...props
|
|
2288
|
-
}) => {
|
|
2289
|
-
const {
|
|
2290
|
-
isCustomWebsite
|
|
2291
|
-
} = React.useContext(PageContext);
|
|
2292
|
-
let {
|
|
2293
|
-
refSetter,
|
|
2294
|
-
className
|
|
2295
|
-
} = props;
|
|
2296
|
-
if (isCustomWebsite) {
|
|
2297
|
-
const NextImage = require('next/image').default;
|
|
2298
|
-
return /*#__PURE__*/React__default["default"].createElement(NextImage, _extends({
|
|
2299
|
-
src: src,
|
|
2300
|
-
layout: 'fill',
|
|
2301
|
-
ref: refSetter,
|
|
2302
|
-
className: className
|
|
2303
|
-
}, props));
|
|
2304
|
-
} else {
|
|
2305
|
-
return /*#__PURE__*/React__default["default"].createElement("img", {
|
|
2306
|
-
ref: refSetter,
|
|
2307
|
-
className: className,
|
|
2308
|
-
src: src
|
|
2309
|
-
});
|
|
2310
|
-
}
|
|
2311
|
-
};
|
|
2312
|
-
|
|
2313
2328
|
function Section$4({
|
|
2314
2329
|
nodeData
|
|
2315
2330
|
}) {
|