@bigbinary/neeto-site-blocks 1.4.0 → 1.4.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/dist/index.cjs.js +48 -48
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.js +48 -48
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -15486,7 +15486,9 @@ var LinkElement = function LinkElement(_ref) {
|
|
|
15486
15486
|
_ref$isHighlighted = _ref.isHighlighted,
|
|
15487
15487
|
isHighlighted = _ref$isHighlighted === void 0 ? false : _ref$isHighlighted,
|
|
15488
15488
|
_ref$disableButtonAnd = _ref.disableButtonAndLinks,
|
|
15489
|
-
disableButtonAndLinks = _ref$disableButtonAnd === void 0 ? false : _ref$disableButtonAnd
|
|
15489
|
+
disableButtonAndLinks = _ref$disableButtonAnd === void 0 ? false : _ref$disableButtonAnd,
|
|
15490
|
+
_ref$children = _ref.children,
|
|
15491
|
+
children = _ref$children === void 0 ? null : _ref$children;
|
|
15490
15492
|
var baseClass = classnames("inline-flex items-center transition-all duration-300 ease-in-out", {
|
|
15491
15493
|
"pointer-events-none": action === "" || disableButtonAndLinks
|
|
15492
15494
|
});
|
|
@@ -15501,18 +15503,18 @@ var LinkElement = function LinkElement(_ref) {
|
|
|
15501
15503
|
if (action === "external") {
|
|
15502
15504
|
return /*#__PURE__*/React__default["default"].createElement(StyledAnchor, _extends__default["default"]({}, commonProps, {
|
|
15503
15505
|
target: "_blank"
|
|
15504
|
-
}), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null));
|
|
15506
|
+
}), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null), children);
|
|
15505
15507
|
}
|
|
15506
15508
|
if (action === "page") {
|
|
15507
15509
|
return /*#__PURE__*/React__default["default"].createElement(StyledAnchor, _extends__default["default"]({
|
|
15508
15510
|
as: Link !== null && Link !== void 0 ? Link : "a"
|
|
15509
15511
|
}, commonProps, {
|
|
15510
15512
|
to: draftMode ? "".concat(baseUrl).concat(to) : to
|
|
15511
|
-
}), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null));
|
|
15513
|
+
}), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null), children);
|
|
15512
15514
|
}
|
|
15513
15515
|
return /*#__PURE__*/React__default["default"].createElement(StyledAnchor, _extends__default["default"]({
|
|
15514
15516
|
as: !draftMode && Link
|
|
15515
|
-
}, commonProps), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null));
|
|
15517
|
+
}, commonProps), label, Icon && /*#__PURE__*/React__default["default"].createElement(Icon, null), children);
|
|
15516
15518
|
};
|
|
15517
15519
|
var Link = withConditionalRender(LinkElement, function () {
|
|
15518
15520
|
return !!(prop("label") || prop("icon"));
|
|
@@ -40984,20 +40986,17 @@ var HeaderWithButtons = function HeaderWithButtons(_ref) {
|
|
|
40984
40986
|
className: classnames("col-start-2 ml-3 flex max-h-8 justify-start sm:ml-0 sm:max-h-10 lg:col-span-3 lg:col-start-1 lg:max-h-14", {
|
|
40985
40987
|
"col-span-10": isEmpty(buttons),
|
|
40986
40988
|
"col-span-3 sm:col-span-4 sm:col-start-2": neetoCist.isNotEmpty(buttons)
|
|
40987
|
-
})
|
|
40988
|
-
|
|
40989
|
-
|
|
40990
|
-
|
|
40991
|
-
|
|
40992
|
-
});
|
|
40993
|
-
}
|
|
40994
|
-
}, otherProps)), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
40989
|
+
})
|
|
40990
|
+
}, otherProps), /*#__PURE__*/React__default["default"].createElement(StyledImage$1, {
|
|
40991
|
+
design: design.logo,
|
|
40992
|
+
src: properties.logo.src
|
|
40993
|
+
})), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
40995
40994
|
className: classnames("col-span-5 col-start-4 hidden items-center justify-center gap-x-6 lg:flex", {
|
|
40996
40995
|
"col-span-9 sm:justify-end": isEmpty(buttons)
|
|
40997
40996
|
})
|
|
40998
40997
|
}, properties.links.map(function (link, index) {
|
|
40999
40998
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41000
|
-
isHighlighted: currentPath === link.to,
|
|
40999
|
+
isHighlighted: link.to && currentPath === link.to,
|
|
41001
41000
|
key: getUniqueKey(link.label, index),
|
|
41002
41001
|
style: design.links
|
|
41003
41002
|
}, link, otherProps));
|
|
@@ -41021,7 +41020,7 @@ var HeaderWithButtons = function HeaderWithButtons(_ref) {
|
|
|
41021
41020
|
className: "fadeIn col-span-2 col-start-1 ml-2 mt-3 block space-y-2 lg:hidden"
|
|
41022
41021
|
}, properties.links.map(function (button, index) {
|
|
41023
41022
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41024
|
-
isHighlighted: currentPath === button.to,
|
|
41023
|
+
isHighlighted: button.to && currentPath === button.to,
|
|
41025
41024
|
key: getUniqueKey(button.to, button.label, index),
|
|
41026
41025
|
style: design.links
|
|
41027
41026
|
}, button, otherProps));
|
|
@@ -41067,21 +41066,18 @@ var HeaderWithIcons = function HeaderWithIcons(_ref) {
|
|
|
41067
41066
|
className: "col-span-4 col-start-1 hidden items-center gap-6 lg:flex"
|
|
41068
41067
|
}, properties.links.map(function (link, index) {
|
|
41069
41068
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41070
|
-
isHighlighted: currentPath === link.to,
|
|
41069
|
+
isHighlighted: link.to && currentPath === link.to,
|
|
41071
41070
|
key: getUniqueKey(link.label, index),
|
|
41072
41071
|
style: design.links
|
|
41073
41072
|
}, link, otherProps));
|
|
41074
41073
|
})), /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41075
41074
|
action: properties.logo.action,
|
|
41076
41075
|
className: "col-span-6 col-start-4 m-auto flex max-h-8 justify-center sm:col-span-4 sm:col-start-5 sm:max-h-10 lg:col-span-3 lg:col-start-6 lg:max-h-14",
|
|
41077
|
-
to: properties.logo.to
|
|
41078
|
-
|
|
41079
|
-
|
|
41080
|
-
|
|
41081
|
-
|
|
41082
|
-
});
|
|
41083
|
-
}
|
|
41084
|
-
}, otherProps)), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
41076
|
+
to: properties.logo.to
|
|
41077
|
+
}, otherProps), /*#__PURE__*/React__default["default"].createElement(StyledImage$1, {
|
|
41078
|
+
design: design.logo,
|
|
41079
|
+
src: properties.logo.src
|
|
41080
|
+
})), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
41085
41081
|
className: "col-span-5 col-start-8 hidden justify-end sm:col-span-3 sm:col-start-10 sm:flex"
|
|
41086
41082
|
}, properties.icons.map(function (_icon, index) {
|
|
41087
41083
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
@@ -41117,7 +41113,7 @@ var HeaderWithIcons = function HeaderWithIcons(_ref) {
|
|
|
41117
41113
|
}, properties.links.map(function (icon, index) {
|
|
41118
41114
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41119
41115
|
className: "w-full",
|
|
41120
|
-
isHighlighted: currentPath === icon.to,
|
|
41116
|
+
isHighlighted: icon.to && currentPath === icon.to,
|
|
41121
41117
|
key: getUniqueKey(icon.url, icon.label, index),
|
|
41122
41118
|
style: design.links
|
|
41123
41119
|
}, icon));
|
|
@@ -41176,26 +41172,23 @@ var HeaderWithLogoTitle = function HeaderWithLogoTitle(_ref) {
|
|
|
41176
41172
|
}, /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41177
41173
|
action: properties.logo.action,
|
|
41178
41174
|
className: "flex w-full gap-x-2",
|
|
41179
|
-
to: properties.logo.to
|
|
41180
|
-
|
|
41181
|
-
|
|
41182
|
-
|
|
41183
|
-
|
|
41184
|
-
|
|
41185
|
-
|
|
41186
|
-
|
|
41187
|
-
|
|
41188
|
-
|
|
41189
|
-
|
|
41190
|
-
|
|
41191
|
-
}, properties.logo.title));
|
|
41192
|
-
}
|
|
41193
|
-
}, otherProps))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
41175
|
+
to: properties.logo.to
|
|
41176
|
+
}, otherProps), /*#__PURE__*/React__default["default"].createElement(StyledImage$1, {
|
|
41177
|
+
className: "max-h-8 sm:max-h-10 lg:max-h-14",
|
|
41178
|
+
design: design.logo,
|
|
41179
|
+
src: properties.logo.src
|
|
41180
|
+
}), /*#__PURE__*/React__default["default"].createElement(Typography$1, {
|
|
41181
|
+
component: "p",
|
|
41182
|
+
style: design.logoTitle,
|
|
41183
|
+
className: classnames({
|
|
41184
|
+
"hidden sm:flex": properties.logo.src
|
|
41185
|
+
})
|
|
41186
|
+
}, properties.logo.title))), /*#__PURE__*/React__default["default"].createElement("div", {
|
|
41194
41187
|
className: "col-span-6 col-start-7 flex items-center justify-end gap-x-6 sm:col-span-5 sm:col-start-8 lg:col-span-7 lg:col-start-6"
|
|
41195
41188
|
}, properties.links.map(function (link, index) {
|
|
41196
41189
|
return /*#__PURE__*/React__default["default"].createElement(Link, _extends__default["default"]({
|
|
41197
41190
|
className: "hidden lg:inline",
|
|
41198
|
-
isHighlighted: currentPath === link.to,
|
|
41191
|
+
isHighlighted: link.to && currentPath === link.to,
|
|
41199
41192
|
key: getUniqueKey(link.label, link.to, index),
|
|
41200
41193
|
style: design.links
|
|
41201
41194
|
}, link, otherProps));
|
|
@@ -41223,7 +41216,7 @@ var HeaderWithLogoTitle = function HeaderWithLogoTitle(_ref) {
|
|
|
41223
41216
|
action: action,
|
|
41224
41217
|
label: label,
|
|
41225
41218
|
to: to,
|
|
41226
|
-
isHighlighted: currentPath === to,
|
|
41219
|
+
isHighlighted: to && currentPath === to,
|
|
41227
41220
|
key: getUniqueKey(to, label, index),
|
|
41228
41221
|
style: design.links
|
|
41229
41222
|
}, otherProps));
|
|
@@ -41306,7 +41299,7 @@ var HeroWithCallToAction = function HeroWithCallToAction(_ref) {
|
|
|
41306
41299
|
})));
|
|
41307
41300
|
};
|
|
41308
41301
|
|
|
41309
|
-
var _excluded$3 = ["configurations", "className", "id"];
|
|
41302
|
+
var _excluded$3 = ["configurations", "className", "id", "disableButtonAndLinks"];
|
|
41310
41303
|
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
|
|
41311
41304
|
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty__default["default"](target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
|
|
41312
41305
|
var HeroWithMultipleLayouts = function HeroWithMultipleLayouts(_ref) {
|
|
@@ -41314,6 +41307,7 @@ var HeroWithMultipleLayouts = function HeroWithMultipleLayouts(_ref) {
|
|
|
41314
41307
|
_ref$className = _ref.className,
|
|
41315
41308
|
className = _ref$className === void 0 ? "" : _ref$className,
|
|
41316
41309
|
id = _ref.id,
|
|
41310
|
+
disableButtonAndLinks = _ref.disableButtonAndLinks,
|
|
41317
41311
|
otherProps = _objectWithoutProperties__default["default"](_ref, _excluded$3);
|
|
41318
41312
|
var _useState = React.useState(0),
|
|
41319
41313
|
_useState2 = _slicedToArray__default["default"](_useState, 2),
|
|
@@ -41330,11 +41324,11 @@ var HeroWithMultipleLayouts = function HeroWithMultipleLayouts(_ref) {
|
|
|
41330
41324
|
var src = _ref2.src,
|
|
41331
41325
|
position = _ref2.position,
|
|
41332
41326
|
isEmptyContent = _ref2.isEmptyContent;
|
|
41333
|
-
return classnames("
|
|
41334
|
-
"sm:col-start-1": src && position === POSITIONS.RIGHT.label,
|
|
41327
|
+
return classnames("col-span-12", {
|
|
41328
|
+
"sm:col-start-1 sm:col-span-6 ": src && position === POSITIONS.RIGHT.label,
|
|
41335
41329
|
"sm:col-span-8 sm:col-start-3": src && position === POSITIONS.BOTTOM.label,
|
|
41336
|
-
"sm:col-span-
|
|
41337
|
-
"sm:col-start-7": src && position === POSITIONS.LEFT.label,
|
|
41330
|
+
"sm:col-span-8 sm:col-start-3 flex flex-col justify-center order-2": src && position === POSITIONS.TOP.label,
|
|
41331
|
+
"sm:col-start-7 sm:col-span-6 ": src && position === POSITIONS.LEFT.label,
|
|
41338
41332
|
"flex flex-col justify-center sm:col-span-12": !src,
|
|
41339
41333
|
hidden: isEmptyContent
|
|
41340
41334
|
});
|
|
@@ -41435,11 +41429,17 @@ var HeroWithMultipleLayouts = function HeroWithMultipleLayouts(_ref) {
|
|
|
41435
41429
|
return (_swiperRef$current = swiperRef.current) === null || _swiperRef$current === void 0 ? void 0 : _swiperRef$current.slidePrev();
|
|
41436
41430
|
}
|
|
41437
41431
|
}), /*#__PURE__*/React__default["default"].createElement(Swiper, {
|
|
41438
|
-
|
|
41439
|
-
|
|
41432
|
+
keyboard: {
|
|
41433
|
+
enabled: true,
|
|
41434
|
+
onlyInViewport: true
|
|
41435
|
+
},
|
|
41436
|
+
modules: [Pagination, Keyboard],
|
|
41440
41437
|
pagination: {
|
|
41441
41438
|
clickable: true
|
|
41442
41439
|
},
|
|
41440
|
+
className: classnames("ns-hero-with-slider", {
|
|
41441
|
+
"pointer-events-none": disableButtonAndLinks
|
|
41442
|
+
}),
|
|
41443
41443
|
onSlideChange: function onSlideChange(swiper) {
|
|
41444
41444
|
return setActiveIndex(swiper.activeIndex);
|
|
41445
41445
|
},
|