s-platform-landing-section 0.1.24 → 0.1.26

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.
@@ -1094,17 +1094,17 @@ var Hero2 = function Hero2(props) {
1094
1094
  }, /*#__PURE__*/React__default.createElement("img", {
1095
1095
  src: data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : (_data$data$ = _data$data[0]) === null || _data$data$ === void 0 ? void 0 : (_data$data$$srcImages = _data$data$.srcImages) === null || _data$data$$srcImages === void 0 ? void 0 : _data$data$$srcImages[0],
1096
1096
  alt: data === null || data === void 0 ? void 0 : (_data$data2 = data.data) === null || _data$data2 === void 0 ? void 0 : (_data$data2$ = _data$data2[0]) === null || _data$data2$ === void 0 ? void 0 : _data$data2$.title,
1097
- className: "w-full object-cover min-h-[30vh] md:min-h-[50vh] max-h-[100vh]"
1097
+ className: "w-full object-cover min-h-[22vh] md:min-h-[30vh] md:min-h-[50vh] max-h-[100vh]"
1098
1098
  }), /*#__PURE__*/React__default.createElement("div", {
1099
- className: "absolute flex flex-col gap-1 md:gap-4 absolute w-1/2 lg:w-[40%] top-2 sm:top-[20%] xl:top-1/4 right-[2%] lg:right-[15%]"
1099
+ className: "absolute flex flex-col gap-1 md:gap-4 absolute w-1/2 lg:w-[40%] top-6 sm:top-[20%] xl:top-1/4 right-[2%] lg:right-[15%]"
1100
1100
  }, /*#__PURE__*/React__default.createElement("img", {
1101
1101
  src: shopConfig === null || shopConfig === void 0 ? void 0 : shopConfig.logoUrl,
1102
1102
  alt: shopConfig === null || shopConfig === void 0 ? void 0 : shopConfig.shopName,
1103
- className: "h-6 w-6 md:h-16 md:w-16 lg:h-20 lg:w-20"
1103
+ className: "h-5 w-5 sm:h-8 sm:w-8 md:h-16 md:w-16 lg:h-20 lg:w-20"
1104
1104
  }), /*#__PURE__*/React__default.createElement("div", {
1105
- className: "text-lg md:text-3xl lg:text-4xl font-medium"
1105
+ className: "text-base md:text-3xl lg:text-4xl font-medium"
1106
1106
  }, data === null || data === void 0 ? void 0 : (_data$data3 = data.data) === null || _data$data3 === void 0 ? void 0 : (_data$data3$ = _data$data3[0]) === null || _data$data3$ === void 0 ? void 0 : _data$data3$.title), /*#__PURE__*/React__default.createElement("div", {
1107
- className: "text-sm md:text-xl lg:text-2xl "
1107
+ className: "text-xs md:text-xl lg:text-2xl "
1108
1108
  }, data === null || data === void 0 ? void 0 : (_data$data4 = data.data) === null || _data$data4 === void 0 ? void 0 : (_data$data4$ = _data$data4[0]) === null || _data$data4$ === void 0 ? void 0 : _data$data4$.description)));
1109
1109
  };
1110
1110
 
@@ -1138,13 +1138,13 @@ var Hero6 = function Hero6(props) {
1138
1138
  }, /*#__PURE__*/React__default.createElement("img", {
1139
1139
  src: data === null || data === void 0 ? void 0 : (_data$data = data.data) === null || _data$data === void 0 ? void 0 : (_data$data$ = _data$data[0]) === null || _data$data$ === void 0 ? void 0 : (_data$data$$srcImages = _data$data$.srcImages) === null || _data$data$$srcImages === void 0 ? void 0 : _data$data$$srcImages[0],
1140
1140
  alt: data === null || data === void 0 ? void 0 : (_data$data2 = data.data) === null || _data$data2 === void 0 ? void 0 : (_data$data2$ = _data$data2[0]) === null || _data$data2$ === void 0 ? void 0 : _data$data2$.title,
1141
- className: "object-cover w-full h-auto min-h-[30vh] md:min-h-[50vh] max-h-[100vh]"
1141
+ className: "object-cover w-full h-auto min-h-[25vh] md:min-h-[30vh] md:min-h-[50vh] max-h-[100vh]"
1142
1142
  }), /*#__PURE__*/React__default.createElement("div", {
1143
- className: "absolute top-0 md:top-14 lg:top-20 w-full p-3 md:p-6 lg:p-12 z-10 flex flex-col gap-2 md:gap-4 lg:gap-6 items-center justify-center"
1143
+ className: "absolute top-0 sm:top-8 md:top-14 lg:top-20 w-full p-3 md:p-6 lg:p-12 z-10 flex flex-col gap-2 md:gap-4 lg:gap-6 items-center justify-center"
1144
1144
  }, /*#__PURE__*/React__default.createElement("div", {
1145
- className: "text-primary text-xl md:text-3xl lg:text-5xl leading-[1.6] md:leading-[1.6] text-center font-headingFont"
1145
+ className: "text-primary line-clamp-1 text-xl md:text-3xl lg:text-5xl leading-[1.6] md:leading-[1.6] text-center font-headingFont"
1146
1146
  }, data === null || data === void 0 ? void 0 : (_data$data3 = data.data) === null || _data$data3 === void 0 ? void 0 : (_data$data3$ = _data$data3[0]) === null || _data$data3$ === void 0 ? void 0 : _data$data3$.title), /*#__PURE__*/React__default.createElement("div", {
1147
- className: "md:text-xl"
1147
+ className: "md:text-xl text-center line-clamp-2"
1148
1148
  }, data === null || data === void 0 ? void 0 : (_data$data4 = data.data) === null || _data$data4 === void 0 ? void 0 : (_data$data4$ = _data$data4[0]) === null || _data$data4$ === void 0 ? void 0 : _data$data4$.description), sectionData === null || sectionData === void 0 ? void 0 : (_sectionData$ = sectionData[0]) === null || _sectionData$ === void 0 ? void 0 : (_sectionData$$buttons = _sectionData$.buttons) === null || _sectionData$$buttons === void 0 ? void 0 : _sectionData$$buttons.map(function (button) {
1149
1149
  return /*#__PURE__*/React__default.createElement(LinkToPage, {
1150
1150
  Link: Link,
@@ -8505,7 +8505,7 @@ var Select = forwardRef(function (props, ref) {
8505
8505
  style: {
8506
8506
  background: "#FFFFFF"
8507
8507
  },
8508
- className: "overflow-y-auto max-h-72 absolute p-1 my-2 rounded-2xl w-full z-50 border " + (dropdownPosition === 'top' ? 'bottom-full mb-2' : 'top-full mt-2') + " " + optionClassName
8508
+ className: "overflow-y-auto max-h-72 absolute p-1 my-2 rounded-2xl w-full z-40 border " + (dropdownPosition === 'top' ? 'bottom-full mb-2' : 'top-full mt-2') + " " + optionClassName
8509
8509
  }, /*#__PURE__*/React__default.createElement("div", null, isSearch ? /*#__PURE__*/React__default.createElement("div", {
8510
8510
  className: "px-3 flex items-center border-b-[1px]"
8511
8511
  }, /*#__PURE__*/React__default.createElement(LuSearch, {
@@ -8699,10 +8699,11 @@ var InputPhoneNumber = forwardRef(function (props, ref) {
8699
8699
  return _setValue(text);
8700
8700
  },
8701
8701
  getValue: function getValue() {
8702
+ var cleanedValue = value === null || value === void 0 ? void 0 : value.replace(/\s+/g, '');
8702
8703
  if (!(value !== null && value !== void 0 && value.startsWith(countryCode === null || countryCode === void 0 ? void 0 : countryCode.value))) {
8703
- return (countryCode === null || countryCode === void 0 ? void 0 : countryCode.value) + (value === null || value === void 0 ? void 0 : value.replace(/^0/, ''));
8704
+ return (countryCode === null || countryCode === void 0 ? void 0 : countryCode.value) + (cleanedValue === null || cleanedValue === void 0 ? void 0 : cleanedValue.replace(/^0/, ''));
8704
8705
  }
8705
- return value;
8706
+ return cleanedValue;
8706
8707
  },
8707
8708
  setError: function setError(err) {
8708
8709
  return _setError(err);
@@ -8718,7 +8719,7 @@ var InputPhoneNumber = forwardRef(function (props, ref) {
8718
8719
  _setError(e === null || e === void 0 ? void 0 : e.message);
8719
8720
  count++;
8720
8721
  break;
8721
- } else if (value && (e === null || e === void 0 ? void 0 : e.type) === 'pattern' && !(e !== null && e !== void 0 && (_e$pattern = e.pattern) !== null && _e$pattern !== void 0 && _e$pattern.test(value))) {
8722
+ } else if (value && (e === null || e === void 0 ? void 0 : e.type) === 'pattern' && !(e !== null && e !== void 0 && (_e$pattern = e.pattern) !== null && _e$pattern !== void 0 && _e$pattern.test(value === null || value === void 0 ? void 0 : value.replace(/\s+/g, '')))) {
8722
8723
  _setError(e === null || e === void 0 ? void 0 : e.message);
8723
8724
  count++;
8724
8725
  break;
@@ -8754,7 +8755,7 @@ var InputPhoneNumber = forwardRef(function (props, ref) {
8754
8755
  optionClassName: "w-max",
8755
8756
  placeholder: "+84",
8756
8757
  onClick: setCountryCode,
8757
- selectClassName: "h-full !rounded-none py-[7px] ps-2 pr-1",
8758
+ selectClassName: "h-full !rounded-none py-[6px] ps-2 pr-1",
8758
8759
  renderItem: function renderItem(item) {
8759
8760
  return /*#__PURE__*/React__default.createElement("div", {
8760
8761
  className: "flex gap-3 items-center w-full"
@@ -14189,6 +14190,32 @@ var News1 = function News1(props) {
14189
14190
  return /*#__PURE__*/React__default.createElement("div", {
14190
14191
  className: SECTION_CLASS + " grid grid-cols-1 md:grid-cols-3 gap-6"
14191
14192
  }, /*#__PURE__*/React__default.createElement("div", {
14193
+ className: "block md:hidden"
14194
+ }, /*#__PURE__*/React__default.createElement("div", {
14195
+ className: "px-6 py-3 bg-primary rounded-t-lg text-lg text-textButton text-center ",
14196
+ onClick: function onClick() {
14197
+ setParams({
14198
+ page: 0,
14199
+ sort: "timeUpdate,DESC",
14200
+ size: 10
14201
+ });
14202
+ }
14203
+ }, "Chuy\xEAn m\u1EE5c"), /*#__PURE__*/React__default.createElement("div", {
14204
+ className: "rounded-b-lg bg-bgSecondary"
14205
+ }, newsCategories === null || newsCategories === void 0 ? void 0 : newsCategories.map(function (item, index) {
14206
+ return /*#__PURE__*/React__default.createElement("div", {
14207
+ className: "px-6 py-3 hover:bg-gray-100 hover:text-primary cursor-pointer",
14208
+ key: "sdjfdh-" + index,
14209
+ onClick: function onClick() {
14210
+ setCategorySelected(item);
14211
+ setParams(function (prev) {
14212
+ return _extends({}, prev, {
14213
+ catId: item === null || item === void 0 ? void 0 : item.catId
14214
+ });
14215
+ });
14216
+ }
14217
+ }, item === null || item === void 0 ? void 0 : item.catName);
14218
+ }))), /*#__PURE__*/React__default.createElement("div", {
14192
14219
  className: "md:col-span-2 flex flex-col gap-8"
14193
14220
  }, /*#__PURE__*/React__default.createElement("div", null, /*#__PURE__*/React__default.createElement("div", {
14194
14221
  className: "px-6 py-3 text-textButton text-lg rounded-t-lg bg-primary w-max"
@@ -14228,7 +14255,7 @@ var News1 = function News1(props) {
14228
14255
  onClick: handleSeeMoreNews,
14229
14256
  className: "w-max mx-auto"
14230
14257
  }) : null)), /*#__PURE__*/React__default.createElement("div", {
14231
- className: "sticky top-20 self-start"
14258
+ className: "sticky top-20 self-start md:block hidden"
14232
14259
  }, /*#__PURE__*/React__default.createElement("div", {
14233
14260
  className: "px-6 py-3 bg-primary rounded-t-lg text-lg text-textButton text-center ",
14234
14261
  onClick: function onClick() {
@@ -14340,6 +14367,20 @@ var NewsDetail1 = function NewsDetail1(props) {
14340
14367
  __html: article === null || article === void 0 ? void 0 : article.content
14341
14368
  }
14342
14369
  }), /*#__PURE__*/React__default.createElement("div", {
14370
+ className: "top-6 block md:hidden"
14371
+ }, /*#__PURE__*/React__default.createElement("div", {
14372
+ className: "px-6 py-3 bg-primary rounded-t-lg text-lg text-textButton text-center"
14373
+ }, "Chuy\xEAn m\u1EE5c"), /*#__PURE__*/React__default.createElement("div", {
14374
+ className: "rounded-b-lg bg-bgSecondary"
14375
+ }, newsCategories === null || newsCategories === void 0 ? void 0 : newsCategories.map(function (item, index) {
14376
+ return /*#__PURE__*/React__default.createElement(LinkToPage, {
14377
+ href: getLinkNewsByCategory(item),
14378
+ Link: Link
14379
+ }, /*#__PURE__*/React__default.createElement("div", {
14380
+ className: "px-6 py-3 hover:bg-gray-100 hover:text-primary cursor-pointer",
14381
+ key: "sdjfdh-" + index
14382
+ }, item === null || item === void 0 ? void 0 : item.catName));
14383
+ }))), /*#__PURE__*/React__default.createElement("div", {
14343
14384
  className: "mt-6"
14344
14385
  }, /*#__PURE__*/React__default.createElement("div", {
14345
14386
  className: "font-medium text-2xl mb-4"
@@ -14362,7 +14403,7 @@ var NewsDetail1 = function NewsDetail1(props) {
14362
14403
  onClick: handleSeeMore,
14363
14404
  shopConfigStyle: shopConfigStyle
14364
14405
  })) : null)), /*#__PURE__*/React__default.createElement("div", {
14365
- className: "sticky top-20 self-start"
14406
+ className: "sticky top-20 self-start hidden md:block"
14366
14407
  }, /*#__PURE__*/React__default.createElement("div", {
14367
14408
  className: "px-6 py-3 bg-primary rounded-t-lg text-lg text-textButton text-center"
14368
14409
  }, "Chuy\xEAn m\u1EE5c"), /*#__PURE__*/React__default.createElement("div", {