tabexseriescomponents 0.2.1050 → 0.2.1051

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 CHANGED
@@ -1578,7 +1578,7 @@ var Select$3 = /*#__PURE__*/React__default["default"].lazy(function () {
1578
1578
  return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require('react-select')); });
1579
1579
  });
1580
1580
  var Variantoptions = function Variantoptions(props) {
1581
- var _css, _fetchProductInfoQuer, _ProductInfoObj$data5, _fetchProductInfoQuer2, _fetchProductInfoQuer3, _fetchProductInfoQuer4, _fetchProductInfoQuer5, _fetchProductInfoQuer6, _fetchProductInfoQuer7, _ProductInfoObj$data6, _ProductInfoObj$data7, _sizeguideimage$;
1581
+ var _css, _fetchProductInfoQuer, _ProductInfoObj$data4, _fetchProductInfoQuer2, _fetchProductInfoQuer3, _fetchProductInfoQuer4, _fetchProductInfoQuer5, _fetchProductInfoQuer6, _fetchProductInfoQuer7, _ProductInfoObj$data5, _ProductInfoObj$data6, _sizeguideimage$;
1582
1582
  var productinfo_cssstyles = props.actions.productinfo_cssstyles;
1583
1583
  var lang = props.actions.lang;
1584
1584
  var langdetect = props.actions.langdetect;
@@ -1589,6 +1589,7 @@ var Variantoptions = function Variantoptions(props) {
1589
1589
  var sectionproperties = props.actions.sectionproperties;
1590
1590
  var ikimagecredcontext = props.actions.ikimagecredcontext;
1591
1591
  var ProductInfoObj = props.actions.ProductInfoObj;
1592
+ var isOptionInStock = props.actions.isOptionInStock;
1592
1593
  var _useState = React.useState(''),
1593
1594
  _useState2 = _slicedToArray__default["default"](_useState, 2);
1594
1595
  _useState2[0];
@@ -1751,98 +1752,7 @@ var Variantoptions = function Variantoptions(props) {
1751
1752
 
1752
1753
  // return isInStock;
1753
1754
  // };
1754
- var isOptionInStock = function isOptionInStock(Currvalueid) {
1755
- var _authdetailsContext$i;
1756
- if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i = authdetailsContext.instinfo) === null || _authdetailsContext$i === void 0 ? void 0 : _authdetailsContext$i.contactinfo.instid) == '68d28fc494276') {
1757
- var _ProductInfoObj$data4;
1758
- var productinfo = ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data4 = ProductInfoObj.data) === null || _ProductInfoObj$data4 === void 0 ? void 0 : _ProductInfoObj$data4.productinfo;
1759
- var options = (productinfo === null || productinfo === void 0 ? void 0 : productinfo.productoptions) || [];
1760
- var variants = (productinfo === null || productinfo === void 0 ? void 0 : productinfo.variants) || [];
1761
1755
 
1762
- // Collect selected option value IDs and find which option they belong to
1763
- var selectedValues = [];
1764
- options.forEach(function (option) {
1765
- option.optionvalues.forEach(function (value) {
1766
- if (value.isselected === 1) {
1767
- selectedValues.push({
1768
- optionid: option.optionid,
1769
- valueid: value.valueid
1770
- });
1771
- }
1772
- });
1773
- });
1774
- options.length;
1775
- var selectedCount = selectedValues.length;
1776
- var inStockVariants = variants.filter(function (v) {
1777
- return v.current_quantity > 0;
1778
- });
1779
-
1780
- // 🧠 Case 1: No selection yet → show if this value exists in any in-stock variant
1781
- if (selectedCount === 0) {
1782
- return inStockVariants.some(function (variant) {
1783
- return variant.variantoptions.some(function (opt) {
1784
- return opt.valueid === Currvalueid;
1785
- });
1786
- }) ? 1 : 0;
1787
- }
1788
-
1789
- // 🧠 Case 2: Only one option selected
1790
- if (selectedCount === 1) {
1791
- var selected = selectedValues[0];
1792
- var selectedOptionId = selected.optionid;
1793
-
1794
- // Find which option this Currvalueid belongs to
1795
- var currentOptionId = null;
1796
- options.forEach(function (option) {
1797
- option.optionvalues.forEach(function (v) {
1798
- if (v.valueid === Currvalueid) currentOptionId = option.optionid;
1799
- });
1800
- });
1801
-
1802
- // Same option (e.g., selecting only size)
1803
- if (selectedOptionId === currentOptionId) {
1804
- // Show all sizes that appear in any in-stock variant (any color)
1805
- return inStockVariants.some(function (variant) {
1806
- return variant.variantoptions.some(function (opt) {
1807
- return opt.valueid === Currvalueid;
1808
- });
1809
- }) ? 1 : 0;
1810
- }
1811
-
1812
- // Different option (e.g., color)
1813
- // Only in-stock if a variant has both selected value + this value
1814
- return inStockVariants.some(function (variant) {
1815
- var variantValueIds = variant.variantoptions.map(function (v) {
1816
- return v.valueid;
1817
- });
1818
- return variantValueIds.includes(selected.valueid) && variantValueIds.includes(Currvalueid);
1819
- }) ? 1 : 0;
1820
- }
1821
-
1822
- // 🧠 Case 3: Multiple options selected (e.g., color + size)
1823
- // Check if this value can exist with all selected options except its own type in any in-stock variant
1824
- var inStock = inStockVariants.some(function (variant) {
1825
- var variantValueIds = variant.variantoptions.map(function (v) {
1826
- return v.valueid;
1827
- });
1828
- // Must match all selected except the one that belongs to same option
1829
- return selectedValues.every(function (sel) {
1830
- if (options.some(function (opt) {
1831
- return opt.optionvalues.some(function (v) {
1832
- return v.valueid === Currvalueid && v.optionid === sel.optionid;
1833
- });
1834
- })) {
1835
- // Skip same option
1836
- return true;
1837
- }
1838
- return variantValueIds.includes(sel.valueid);
1839
- }) && variantValueIds.includes(Currvalueid);
1840
- });
1841
- return inStock ? 1 : 0;
1842
- } else {
1843
- return 1;
1844
- }
1845
- };
1846
1756
  return /*#__PURE__*/React__default["default"].createElement(React__default["default"].Fragment, null, (fetchProductInfoQueryContext === null || fetchProductInfoQueryContext === void 0 || (_fetchProductInfoQuer = fetchProductInfoQueryContext.data) === null || _fetchProductInfoQuer === void 0 || (_fetchProductInfoQuer = _fetchProductInfoQuer.data) === null || _fetchProductInfoQuer === void 0 || (_fetchProductInfoQuer = _fetchProductInfoQuer.productinfo) === null || _fetchProductInfoQuer === void 0 ? void 0 : _fetchProductInfoQuer.hasvariants) == 1 && /*#__PURE__*/React__default["default"].createElement("div", {
1847
1757
  className: props.srcprops == 'reservation' ? 'row mx-0 mt-3 w-100 d-flex align-items-start' : 'row m-0 w-100 d-flex align-items-start'
1848
1758
  }, /*#__PURE__*/React__default["default"].createElement("div", {
@@ -1851,7 +1761,7 @@ var Variantoptions = function Variantoptions(props) {
1851
1761
  "class": sectionproperties.showsizeguidebtn == 'Show' ? 'col-9 p-0' : 'col-lg-12 p-0'
1852
1762
  }, /*#__PURE__*/React__default["default"].createElement("div", {
1853
1763
  "class": "row m-0 w-100"
1854
- }, sectionproperties.variantstyle == 'Slider' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data5 = ProductInfoObj.data) === null || _ProductInfoObj$data5 === void 0 || (_ProductInfoObj$data5 = _ProductInfoObj$data5.productinfo) === null || _ProductInfoObj$data5 === void 0 || (_ProductInfoObj$data5 = _ProductInfoObj$data5.productoptions) === null || _ProductInfoObj$data5 === void 0 ? void 0 : _ProductInfoObj$data5.map(function (item, index) {
1764
+ }, sectionproperties.variantstyle == 'Slider' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data4 = ProductInfoObj.data) === null || _ProductInfoObj$data4 === void 0 || (_ProductInfoObj$data4 = _ProductInfoObj$data4.productinfo) === null || _ProductInfoObj$data4 === void 0 || (_ProductInfoObj$data4 = _ProductInfoObj$data4.productoptions) === null || _ProductInfoObj$data4 === void 0 ? void 0 : _ProductInfoObj$data4.map(function (item, index) {
1855
1765
  return /*#__PURE__*/React__default["default"].createElement("div", {
1856
1766
  className: 'col-lg-12 p-0 mb-3 d-flex justify-content-start'
1857
1767
  }, /*#__PURE__*/React__default["default"].createElement("div", {
@@ -1891,9 +1801,9 @@ var Variantoptions = function Variantoptions(props) {
1891
1801
  var isValueinStock = isOptionInStock(optionvaluesitem.valueid);
1892
1802
  var is_value_permdisabled = 0;
1893
1803
  if ((optionvaluesitem === null || optionvaluesitem === void 0 ? void 0 : optionvaluesitem.perm_disabled) == 1) {
1894
- var _authdetailsContext$i2;
1804
+ var _authdetailsContext$i;
1895
1805
  // if()
1896
- if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i2 = authdetailsContext.instinfo) === null || _authdetailsContext$i2 === void 0 ? void 0 : _authdetailsContext$i2.contactinfo.instid) == '68d28fc494276') {
1806
+ if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i = authdetailsContext.instinfo) === null || _authdetailsContext$i === void 0 ? void 0 : _authdetailsContext$i.contactinfo.instid) == '68d28fc494276') {
1897
1807
  is_value_permdisabled = 1;
1898
1808
  }
1899
1809
  }
@@ -1922,7 +1832,7 @@ var Variantoptions = function Variantoptions(props) {
1922
1832
  } else if (item.optionname == 'size' || item.optionname == 'Size') {
1923
1833
  // if (ProductInfoObj?.data?.productinfo?.productoptions?.length == 1 || isoptionvaluedenabled == 1) {
1924
1834
  if (is_value_permdisabled == 0) {
1925
- var _authdetailsContext$i4;
1835
+ var _authdetailsContext$i3;
1926
1836
  return /*#__PURE__*/React__default["default"].createElement("div", {
1927
1837
  // className={
1928
1838
  // issingleoptionoutofstock(optionvaluesitem)['isoutofstock'] == true &&
@@ -1937,8 +1847,8 @@ var Variantoptions = function Variantoptions(props) {
1937
1847
  className: " ".concat(productinfostyles.variant_container, " ").concat(productinfostyles.size_variant_container) + ' mr-2 variabttcontainer allcentered ' + " ".concat(isoptionvalueselected == 1 ? productinfostyles.variant_container_active : ''),
1938
1848
  onClick: function onClick() {
1939
1849
  if (isoptionvalueselected == 0) {
1940
- var _authdetailsContext$i3;
1941
- if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i3 = authdetailsContext.instinfo) === null || _authdetailsContext$i3 === void 0 ? void 0 : _authdetailsContext$i3.contactinfo.instid) == '68d28fc494276') {
1850
+ var _authdetailsContext$i2;
1851
+ if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i2 = authdetailsContext.instinfo) === null || _authdetailsContext$i2 === void 0 ? void 0 : _authdetailsContext$i2.contactinfo.instid) == '68d28fc494276') {
1942
1852
  if (isValueinStock == 0) {
1943
1853
  return;
1944
1854
  }
@@ -1982,7 +1892,7 @@ var Variantoptions = function Variantoptions(props) {
1982
1892
  }, /*#__PURE__*/React__default["default"].createElement("i", {
1983
1893
  "class": "h-100 allcentered"
1984
1894
  }, /*#__PURE__*/React__default["default"].createElement(IoMdClose.IoMdClose, null))), /*#__PURE__*/React__default["default"].createElement("p", {
1985
- className: isValueinStock == 0 && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i4 = authdetailsContext.instinfo) === null || _authdetailsContext$i4 === void 0 ? void 0 : _authdetailsContext$i4.contactinfo.instid) == '68d28fc494276' ? 'wordbreak m-0 p-0 d-flex align-items-center justify-content-center linethrough' : 'wordbreak m-0 p-0 d-flex align-items-center justify-content-center',
1895
+ className: isValueinStock == 0 && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i3 = authdetailsContext.instinfo) === null || _authdetailsContext$i3 === void 0 ? void 0 : _authdetailsContext$i3.contactinfo.instid) == '68d28fc494276' ? 'wordbreak m-0 p-0 d-flex align-items-center justify-content-center linethrough' : 'wordbreak m-0 p-0 d-flex align-items-center justify-content-center',
1986
1896
  style: {
1987
1897
  color: sectionproperties.variantcontainerbordercolor != undefined && sectionproperties.variantcontainerbordercolor != null && isoptionvalueselected == 1 ? sectionproperties.activeproductcolor : sectionproperties.variantcontainer_color,
1988
1898
  fontSize: sectionproperties.variantcontainer_fontSize + 'px',
@@ -2066,7 +1976,7 @@ var Variantoptions = function Variantoptions(props) {
2066
1976
  dangerouslySetInnerHTML: {
2067
1977
  __html: langdetect == 'en' ? fetchProductInfoQueryContext === null || fetchProductInfoQueryContext === void 0 || (_fetchProductInfoQuer6 = fetchProductInfoQueryContext.data) === null || _fetchProductInfoQuer6 === void 0 || (_fetchProductInfoQuer6 = _fetchProductInfoQuer6.data) === null || _fetchProductInfoQuer6 === void 0 || (_fetchProductInfoQuer6 = _fetchProductInfoQuer6.productinfo) === null || _fetchProductInfoQuer6 === void 0 || (_fetchProductInfoQuer6 = _fetchProductInfoQuer6.variants[variantindexcompleted]) === null || _fetchProductInfoQuer6 === void 0 ? void 0 : _fetchProductInfoQuer6.variantdescription_en : fetchProductInfoQueryContext === null || fetchProductInfoQueryContext === void 0 || (_fetchProductInfoQuer7 = fetchProductInfoQueryContext.data) === null || _fetchProductInfoQuer7 === void 0 || (_fetchProductInfoQuer7 = _fetchProductInfoQuer7.data) === null || _fetchProductInfoQuer7 === void 0 || (_fetchProductInfoQuer7 = _fetchProductInfoQuer7.productinfo) === null || _fetchProductInfoQuer7 === void 0 || (_fetchProductInfoQuer7 = _fetchProductInfoQuer7.variants[variantindexcompleted]) === null || _fetchProductInfoQuer7 === void 0 ? void 0 : _fetchProductInfoQuer7.variantdescription_ar
2068
1978
  }
2069
- })), sectionproperties.variantstyle == 'Vertical' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data6 = ProductInfoObj.data) === null || _ProductInfoObj$data6 === void 0 || (_ProductInfoObj$data6 = _ProductInfoObj$data6.productinfo) === null || _ProductInfoObj$data6 === void 0 || (_ProductInfoObj$data6 = _ProductInfoObj$data6.productoptions) === null || _ProductInfoObj$data6 === void 0 ? void 0 : _ProductInfoObj$data6.map(function (item, index) {
1979
+ })), sectionproperties.variantstyle == 'Vertical' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data5 = ProductInfoObj.data) === null || _ProductInfoObj$data5 === void 0 || (_ProductInfoObj$data5 = _ProductInfoObj$data5.productinfo) === null || _ProductInfoObj$data5 === void 0 || (_ProductInfoObj$data5 = _ProductInfoObj$data5.productoptions) === null || _ProductInfoObj$data5 === void 0 ? void 0 : _ProductInfoObj$data5.map(function (item, index) {
2070
1980
  return /*#__PURE__*/React__default["default"].createElement("ul", {
2071
1981
  "class": "thwvsf-wrapper-ul"
2072
1982
  }, /*#__PURE__*/React__default["default"].createElement("div", {
@@ -2207,7 +2117,7 @@ var Variantoptions = function Variantoptions(props) {
2207
2117
  // );
2208
2118
  // }
2209
2119
  }));
2210
- })), sectionproperties.variantstyle == 'Select Box' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data7 = ProductInfoObj.data) === null || _ProductInfoObj$data7 === void 0 || (_ProductInfoObj$data7 = _ProductInfoObj$data7.productinfo) === null || _ProductInfoObj$data7 === void 0 || (_ProductInfoObj$data7 = _ProductInfoObj$data7.productoptions) === null || _ProductInfoObj$data7 === void 0 ? void 0 : _ProductInfoObj$data7.map(function (item, index) {
2120
+ })), sectionproperties.variantstyle == 'Select Box' && (ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data6 = ProductInfoObj.data) === null || _ProductInfoObj$data6 === void 0 || (_ProductInfoObj$data6 = _ProductInfoObj$data6.productinfo) === null || _ProductInfoObj$data6 === void 0 || (_ProductInfoObj$data6 = _ProductInfoObj$data6.productoptions) === null || _ProductInfoObj$data6 === void 0 ? void 0 : _ProductInfoObj$data6.map(function (item, index) {
2211
2121
  var orgselectoptions = [];
2212
2122
  var selecteditemid = null;
2213
2123
  var placeholdervalue = '';
@@ -6134,7 +6044,7 @@ var Article_itemtype = function Article_itemtype(props) {
6134
6044
  function ownKeys$2A(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
6135
6045
  function _objectSpread$2A(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$2A(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$2A(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6136
6046
  var Productinfo = function Productinfo(props) {
6137
- var _css, _fetchProductInfoQuer71, _ref, _fetchProductInfoQuer72, _ref2, _fetchProductInfoQuer73, _ref3, _authdetailsContext$i10, _authdetailsContext$i11, _authdetailsContext$i12, _fetchProductInfoQuer74, _fetchProductInfoQuer75, _fetchProductInfoQuer76, _returnpolicyobj5, _returnpolicyobj6, _returnpolicyobj7, _returnpolicyobj8, _fetchProductInfoQuer77, _fetchProductInfoQuer78, _returnpolicyobj9, _returnpolicyobj0, _returnpolicyobj1, _returnpolicyobj10, _fetchProductInfoQuer79, _fetchProductInfoQuer80, _returnpolicyobj11, _returnpolicyobj12, _returnpolicyobj13, _returnpolicyobj14;
6047
+ var _css, _fetchProductInfoQuer71, _ref, _fetchProductInfoQuer72, _ref2, _fetchProductInfoQuer73, _ref3, _authdetailsContext$i12, _authdetailsContext$i13, _authdetailsContext$i14, _fetchProductInfoQuer74, _fetchProductInfoQuer75, _fetchProductInfoQuer76, _returnpolicyobj5, _returnpolicyobj6, _returnpolicyobj7, _returnpolicyobj8, _fetchProductInfoQuer77, _fetchProductInfoQuer78, _returnpolicyobj9, _returnpolicyobj0, _returnpolicyobj1, _returnpolicyobj10, _fetchProductInfoQuer79, _fetchProductInfoQuer80, _returnpolicyobj11, _returnpolicyobj12, _returnpolicyobj13, _returnpolicyobj14;
6138
6048
  var _useState = React.useState({}),
6139
6049
  _useState2 = _slicedToArray__default["default"](_useState, 2),
6140
6050
  ProductInfoObj = _useState2[0],
@@ -6582,17 +6492,175 @@ var Productinfo = function Productinfo(props) {
6582
6492
  }
6583
6493
  }
6584
6494
  }, [fetchProductInfoQueryContext.isSuccess, fetchProductInfoQueryContext.data, ikimagecredcontext]);
6495
+ // const clearchoosenvaluesbutkeepcurrentvalue = (optionindex, optionvaluesitem, optionvaluesindex) => {
6496
+ // var productarr = ProductInfoObj;
6497
+ // productarr?.data?.productinfo?.productoptions?.forEach(function (item, index) {
6498
+ // item.isselected = 0;
6499
+ // item?.optionvalues?.forEach(function (valueitem, valueindex) {
6500
+ // valueitem.isselected = 0;
6501
+ // });
6502
+ // });
6503
+
6504
+ // selectproductoptionvalue(optionindex, optionvaluesitem, optionvaluesindex, productarr);
6505
+ // };
6506
+ var isOptionInStock = function isOptionInStock(Currvalueid) {
6507
+ var _authdetailsContext$i2;
6508
+ if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i2 = authdetailsContext.instinfo) === null || _authdetailsContext$i2 === void 0 ? void 0 : _authdetailsContext$i2.contactinfo.instid) == '68d28fc494276') {
6509
+ var _ProductInfoObj$data;
6510
+ var productinfo = ProductInfoObj === null || ProductInfoObj === void 0 || (_ProductInfoObj$data = ProductInfoObj.data) === null || _ProductInfoObj$data === void 0 ? void 0 : _ProductInfoObj$data.productinfo;
6511
+ var options = (productinfo === null || productinfo === void 0 ? void 0 : productinfo.productoptions) || [];
6512
+ var variants = (productinfo === null || productinfo === void 0 ? void 0 : productinfo.variants) || [];
6513
+
6514
+ // Collect selected option value IDs and find which option they belong to
6515
+ var selectedValues = [];
6516
+ options.forEach(function (option) {
6517
+ option.optionvalues.forEach(function (value) {
6518
+ if (value.isselected === 1) {
6519
+ selectedValues.push({
6520
+ optionid: option.optionid,
6521
+ valueid: value.valueid
6522
+ });
6523
+ }
6524
+ });
6525
+ });
6526
+ options.length;
6527
+ var selectedCount = selectedValues.length;
6528
+ var inStockVariants = variants.filter(function (v) {
6529
+ return v.current_quantity > 0;
6530
+ });
6531
+
6532
+ // 🧠 Case 1: No selection yet → show if this value exists in any in-stock variant
6533
+ if (selectedCount === 0) {
6534
+ return inStockVariants.some(function (variant) {
6535
+ return variant.variantoptions.some(function (opt) {
6536
+ return opt.valueid === Currvalueid;
6537
+ });
6538
+ }) ? 1 : 0;
6539
+ }
6540
+
6541
+ // 🧠 Case 2: Only one option selected
6542
+ if (selectedCount === 1) {
6543
+ var selected = selectedValues[0];
6544
+ var selectedOptionId = selected.optionid;
6545
+
6546
+ // Find which option this Currvalueid belongs to
6547
+ var currentOptionId = null;
6548
+ options.forEach(function (option) {
6549
+ option.optionvalues.forEach(function (v) {
6550
+ if (v.valueid === Currvalueid) currentOptionId = option.optionid;
6551
+ });
6552
+ });
6553
+
6554
+ // Same option (e.g., selecting only size)
6555
+ if (selectedOptionId === currentOptionId) {
6556
+ // Show all sizes that appear in any in-stock variant (any color)
6557
+ return inStockVariants.some(function (variant) {
6558
+ return variant.variantoptions.some(function (opt) {
6559
+ return opt.valueid === Currvalueid;
6560
+ });
6561
+ }) ? 1 : 0;
6562
+ }
6563
+
6564
+ // Different option (e.g., color)
6565
+ // Only in-stock if a variant has both selected value + this value
6566
+ return inStockVariants.some(function (variant) {
6567
+ var variantValueIds = variant.variantoptions.map(function (v) {
6568
+ return v.valueid;
6569
+ });
6570
+ return variantValueIds.includes(selected.valueid) && variantValueIds.includes(Currvalueid);
6571
+ }) ? 1 : 0;
6572
+ }
6573
+
6574
+ // 🧠 Case 3: Multiple options selected (e.g., color + size)
6575
+ // Check if this value can exist with all selected options except its own type in any in-stock variant
6576
+ var inStock = inStockVariants.some(function (variant) {
6577
+ var variantValueIds = variant.variantoptions.map(function (v) {
6578
+ return v.valueid;
6579
+ });
6580
+ // Must match all selected except the one that belongs to same option
6581
+ return selectedValues.every(function (sel) {
6582
+ if (options.some(function (opt) {
6583
+ return opt.optionvalues.some(function (v) {
6584
+ return v.valueid === Currvalueid && v.optionid === sel.optionid;
6585
+ });
6586
+ })) {
6587
+ // Skip same option
6588
+ return true;
6589
+ }
6590
+ return variantValueIds.includes(sel.valueid);
6591
+ }) && variantValueIds.includes(Currvalueid);
6592
+ });
6593
+ return inStock ? 1 : 0;
6594
+ } else {
6595
+ return 1;
6596
+ }
6597
+ };
6585
6598
  var clearchoosenvaluesbutkeepcurrentvalue = function clearchoosenvaluesbutkeepcurrentvalue(optionindex, optionvaluesitem, optionvaluesindex) {
6586
- var _productarr$data;
6587
- var productarr = ProductInfoObj;
6588
- productarr === null || productarr === void 0 || (_productarr$data = productarr.data) === null || _productarr$data === void 0 || (_productarr$data = _productarr$data.productinfo) === null || _productarr$data === void 0 || (_productarr$data = _productarr$data.productoptions) === null || _productarr$data === void 0 || _productarr$data.forEach(function (item, index) {
6589
- var _item$optionvalues;
6590
- item.isselected = 0;
6591
- item === null || item === void 0 || (_item$optionvalues = item.optionvalues) === null || _item$optionvalues === void 0 || _item$optionvalues.forEach(function (valueitem, valueindex) {
6592
- valueitem.isselected = 0;
6599
+ var _authdetailsContext$i3;
6600
+ if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i3 = authdetailsContext.instinfo) === null || _authdetailsContext$i3 === void 0 ? void 0 : _authdetailsContext$i3.contactinfo.instid) == '68d28fc494276') {
6601
+ var _productarr$data, _productarr$data$prod;
6602
+ var _productarr = ProductInfoObj;
6603
+ if (!(_productarr !== null && _productarr !== void 0 && (_productarr$data = _productarr.data) !== null && _productarr$data !== void 0 && _productarr$data.productinfo)) return;
6604
+
6605
+ // 1. Find variants that include the newly selected value
6606
+ var validVariants = (_productarr.data.productinfo.variants || []).filter(function (variant) {
6607
+ return (variant.variantoptions || []).some(function (opt) {
6608
+ return opt.valueid === optionvaluesitem.valueid;
6609
+ });
6593
6610
  });
6594
- });
6595
- selectproductoptionvalue(optionindex, optionvaluesitem, optionvaluesindex, productarr);
6611
+
6612
+ // 2. Build a set of valid value ids
6613
+ var validValueIds = new Set(validVariants.flatMap(function (v) {
6614
+ return (v.variantoptions || []).map(function (opt) {
6615
+ return opt.valueid;
6616
+ });
6617
+ }));
6618
+
6619
+ // 3. Loop all options and their values
6620
+ (_productarr$data$prod = _productarr.data.productinfo.productoptions) === null || _productarr$data$prod === void 0 || _productarr$data$prod.forEach(function (option) {
6621
+ var _option$optionvalues;
6622
+ var anySelected = false;
6623
+ (_option$optionvalues = option.optionvalues) === null || _option$optionvalues === void 0 || _option$optionvalues.forEach(function (value) {
6624
+ // Normalize stock check result to boolean
6625
+ var stockResult = isOptionInStock(value.valueid);
6626
+ var inStock = !(stockResult === 0 || stockResult === '0' || stockResult === false || stockResult === 'false' || stockResult == null);
6627
+
6628
+ // Unselect if NOT valid with the chosen new value OR out of stock
6629
+ if (!validValueIds.has(value.valueid) || !inStock) {
6630
+ value.isselected = 0;
6631
+ } else {
6632
+ // keep whatever selection is already there (do not auto-select)
6633
+ if (value.isselected) anySelected = true;
6634
+ }
6635
+ });
6636
+
6637
+ // keep option-level selected state in sync
6638
+ option.isselected = anySelected ? 1 : 0;
6639
+ });
6640
+
6641
+ // 4. Only select the new value if it's in stock
6642
+ var newInStock = function () {
6643
+ var r = isOptionInStock(optionvaluesitem.valueid);
6644
+ return !(r === 0 || r === '0' || r === false || r === 'false' || r == null);
6645
+ }();
6646
+ if (newInStock) {
6647
+ selectproductoptionvalue(optionindex, optionvaluesitem, optionvaluesindex, _productarr);
6648
+ } else {
6649
+ // optional: show user message or disable click
6650
+ console.warn('Attempted to select an out-of-stock value:', optionvaluesitem);
6651
+ }
6652
+ } else {
6653
+ var _productarr$data2;
6654
+ var productarr = ProductInfoObj;
6655
+ productarr === null || productarr === void 0 || (_productarr$data2 = productarr.data) === null || _productarr$data2 === void 0 || (_productarr$data2 = _productarr$data2.productinfo) === null || _productarr$data2 === void 0 || (_productarr$data2 = _productarr$data2.productoptions) === null || _productarr$data2 === void 0 || _productarr$data2.forEach(function (item, index) {
6656
+ var _item$optionvalues;
6657
+ item.isselected = 0;
6658
+ item === null || item === void 0 || (_item$optionvalues = item.optionvalues) === null || _item$optionvalues === void 0 || _item$optionvalues.forEach(function (valueitem, valueindex) {
6659
+ valueitem.isselected = 0;
6660
+ });
6661
+ });
6662
+ selectproductoptionvalue(optionindex, optionvaluesitem, optionvaluesindex, productarr);
6663
+ }
6596
6664
  };
6597
6665
  var selectproductoptionvalue = function selectproductoptionvalue(optionindex, optionvaluesitem, optionvaluesindex, productarrtobepassed) {
6598
6666
  if (productarrtobepassed == undefined || productarrtobepassed == null) {
@@ -6607,8 +6675,8 @@ var Productinfo = function Productinfo(props) {
6607
6675
  productarr.data.productinfo.productoptions[optionindex].optionvalues[optionvaluesindex].isselected = 1;
6608
6676
  }
6609
6677
  if (productarr.data.productinfo.productoptions[optionindex].optionname == 'color' || productarr.data.productinfo.productoptions[optionindex].optionname == 'Color' || productarr.data.productinfo.productoptions[optionindex].optionname == 'Colour') {
6610
- var _productarr$data$prod;
6611
- setvariantvalueidentifier((_productarr$data$prod = productarr.data.productinfo.productoptions[optionindex].optionvalues[optionvaluesindex]) === null || _productarr$data$prod === void 0 ? void 0 : _productarr$data$prod.value_identifier);
6678
+ var _productarr$data$prod2;
6679
+ setvariantvalueidentifier((_productarr$data$prod2 = productarr.data.productinfo.productoptions[optionindex].optionvalues[optionvaluesindex]) === null || _productarr$data$prod2 === void 0 ? void 0 : _productarr$data$prod2.value_identifier);
6612
6680
  // setvariantnotchosendisclaimer('This field is required');
6613
6681
  var variantimageindex = 0;
6614
6682
  var variantImageMatching = null;
@@ -6865,8 +6933,8 @@ var Productinfo = function Productinfo(props) {
6865
6933
  var variantchecker = function variantchecker() {
6866
6934
  var productarr = ProductInfoObj;
6867
6935
  if (Object.keys(productarr).length != 0) {
6868
- var _productarr$data2;
6869
- if ((productarr === null || productarr === void 0 || (_productarr$data2 = productarr.data) === null || _productarr$data2 === void 0 || (_productarr$data2 = _productarr$data2.productinfo) === null || _productarr$data2 === void 0 ? void 0 : _productarr$data2.hasvariants) == 1) {
6936
+ var _productarr$data3;
6937
+ if ((productarr === null || productarr === void 0 || (_productarr$data3 = productarr.data) === null || _productarr$data3 === void 0 || (_productarr$data3 = _productarr$data3.productinfo) === null || _productarr$data3 === void 0 ? void 0 : _productarr$data3.hasvariants) == 1) {
6870
6938
  var selectedoptionsvalues = [];
6871
6939
  var variantsaccessible = [];
6872
6940
  productarr.data.productinfo.productoptions.forEach(function (productoptionsitem, productoptionsindex) {
@@ -7053,10 +7121,10 @@ var Productinfo = function Productinfo(props) {
7053
7121
  if (addtocardpayloadobj.variantid.length != 0) {
7054
7122
  runfunc = true;
7055
7123
  } else {
7056
- var _authdetailsContext$i2;
7124
+ var _authdetailsContext$i4;
7057
7125
  // here
7058
7126
  setvariantnotchosendisclaimer('This field is required');
7059
- NotificationManager.warning('', (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i2 = authdetailsContext.instinfo) === null || _authdetailsContext$i2 === void 0 ? void 0 : _authdetailsContext$i2.contactinfo.instid) == '674f0617c7811' ? 'Please Choose Size & Color' : 'Please Choose Product Options');
7127
+ NotificationManager.warning('', (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i4 = authdetailsContext.instinfo) === null || _authdetailsContext$i4 === void 0 ? void 0 : _authdetailsContext$i4.contactinfo.instid) == '674f0617c7811' ? 'Please Choose Size & Color' : 'Please Choose Product Options');
7060
7128
  }
7061
7129
  } else {
7062
7130
  runfunc = true;
@@ -7140,9 +7208,9 @@ var Productinfo = function Productinfo(props) {
7140
7208
  };
7141
7209
  };
7142
7210
  var returnpolicyobj = function returnpolicyobj(policytype) {
7143
- var _authdetailsContext$i3;
7211
+ var _authdetailsContext$i5;
7144
7212
  var policyobj = {};
7145
- authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i3 = authdetailsContext.instinfo) === null || _authdetailsContext$i3 === void 0 || (_authdetailsContext$i3 = _authdetailsContext$i3.instpolicies) === null || _authdetailsContext$i3 === void 0 || _authdetailsContext$i3.forEach(function (item, index) {
7213
+ authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i5 = authdetailsContext.instinfo) === null || _authdetailsContext$i5 === void 0 || (_authdetailsContext$i5 = _authdetailsContext$i5.instpolicies) === null || _authdetailsContext$i5 === void 0 || _authdetailsContext$i5.forEach(function (item, index) {
7146
7214
  if (item.policytype == policytype) {
7147
7215
  policyobj = item;
7148
7216
  }
@@ -7151,7 +7219,7 @@ var Productinfo = function Productinfo(props) {
7151
7219
  };
7152
7220
  var relatedproducts = function relatedproducts() {
7153
7221
  if (Relatedproducts.length != 0) {
7154
- var _authdetailsContext$i4;
7222
+ var _authdetailsContext$i6;
7155
7223
  return /*#__PURE__*/React__default["default"].createElement("div", {
7156
7224
  className: "w-100 row ml-0 mr-0 d-flex justify-content-start pl-md-3 pr-md-3 pl-sm-2 pr-sm-2",
7157
7225
  style: {
@@ -7193,7 +7261,7 @@ var Productinfo = function Productinfo(props) {
7193
7261
  }, /*#__PURE__*/React__default["default"].createElement(reactHorizontalScrollingMenu.ScrollMenu, {
7194
7262
  transitionBehavior: 'auto',
7195
7263
  wrapperClassName: '',
7196
- itemClassName: (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i4 = authdetailsContext.instinfo) === null || _authdetailsContext$i4 === void 0 ? void 0 : _authdetailsContext$i4.contactinfo.instid) == '67dc756de56bd' ? 'scrollmenuclassnameitemrelatedproductkingtut' : 'scrollmenuclassnameitemrelatedproduct',
7264
+ itemClassName: (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i6 = authdetailsContext.instinfo) === null || _authdetailsContext$i6 === void 0 ? void 0 : _authdetailsContext$i6.contactinfo.instid) == '67dc756de56bd' ? 'scrollmenuclassnameitemrelatedproductkingtut' : 'scrollmenuclassnameitemrelatedproduct',
7197
7265
  scrollContainerClassName: 'scrollmenuclasssubscrollbarrelatedproducts'
7198
7266
  }, Relatedproducts.map(function (item, index) {
7199
7267
  if (item.productinfo != null) {
@@ -7969,7 +8037,7 @@ var Productinfo = function Productinfo(props) {
7969
8037
  })));
7970
8038
  };
7971
8039
  var StoreInfo = function StoreInfo(position) {
7972
- var _fetchProductInfoQuer65, _authdetailsContext$i6, _returnpolicyobj, _returnpolicyobj2, _returnpolicyobj3, _returnpolicyobj4, _authdetailsContext$i7, _authdetailsContext$i9;
8040
+ var _fetchProductInfoQuer65, _authdetailsContext$i8, _returnpolicyobj, _returnpolicyobj2, _returnpolicyobj3, _returnpolicyobj4, _authdetailsContext$i9, _authdetailsContext$i1;
7973
8041
  return /*#__PURE__*/React__default["default"].createElement("div", {
7974
8042
  "class": sectionproperties.storeinformationcontainerborderwidth != 0 ? 'row m-0 w-100 p-3' : 'row m-0 w-100',
7975
8043
  style: {
@@ -8048,8 +8116,8 @@ var Productinfo = function Productinfo(props) {
8048
8116
  }, authdetailsContext === null || authdetailsContext === void 0 ? void 0 : authdetailsContext.CuContactphonenumber))), sectionproperties.showfooteremail == 'Show' && /*#__PURE__*/React__default["default"].createElement("div", {
8049
8117
  className: "".concat(productinfo_cssstyles.storeinfobtn, " ").concat(productinfo_cssstyles.storeinfocontainer) + ' mb-t col-lg-12 p-0 d-flex align-items-center cursor-pointer ',
8050
8118
  onClick: function onClick() {
8051
- var _authdetailsContext$i5;
8052
- window.open('mailto:' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i5 = authdetailsContext.instinfo) === null || _authdetailsContext$i5 === void 0 || (_authdetailsContext$i5 = _authdetailsContext$i5.contactinfo) === null || _authdetailsContext$i5 === void 0 ? void 0 : _authdetailsContext$i5.email), '_self');
8119
+ var _authdetailsContext$i7;
8120
+ window.open('mailto:' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i7 = authdetailsContext.instinfo) === null || _authdetailsContext$i7 === void 0 || (_authdetailsContext$i7 = _authdetailsContext$i7.contactinfo) === null || _authdetailsContext$i7 === void 0 ? void 0 : _authdetailsContext$i7.email), '_self');
8053
8121
  }
8054
8122
  }, /*#__PURE__*/React__default["default"].createElement("div", {
8055
8123
  "class": productinfo_cssstyles.iconContainer + ' iconContainer '
@@ -8069,7 +8137,7 @@ var Productinfo = function Productinfo(props) {
8069
8137
  style: {
8070
8138
  textAlign: langdetect == 'en' ? 'left' : 'right'
8071
8139
  }
8072
- }, authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i6 = authdetailsContext.instinfo) === null || _authdetailsContext$i6 === void 0 || (_authdetailsContext$i6 = _authdetailsContext$i6.contactinfo) === null || _authdetailsContext$i6 === void 0 ? void 0 : _authdetailsContext$i6.email))), /*#__PURE__*/React__default["default"].createElement("div", {
8140
+ }, authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i8 = authdetailsContext.instinfo) === null || _authdetailsContext$i8 === void 0 || (_authdetailsContext$i8 = _authdetailsContext$i8.contactinfo) === null || _authdetailsContext$i8 === void 0 ? void 0 : _authdetailsContext$i8.email))), /*#__PURE__*/React__default["default"].createElement("div", {
8073
8141
  "class": "col-lg-12 my-2",
8074
8142
  style: {
8075
8143
  display: sectionproperties.showfirstpolicy_storeinfo == 'Hide' && sectionproperties.showsecondpolicy_storeinfo == 'Hide' ? 'none' : 'block'
@@ -8121,25 +8189,25 @@ var Productinfo = function Productinfo(props) {
8121
8189
  }
8122
8190
  }, /*#__PURE__*/React__default["default"].createElement("p", {
8123
8191
  "class": "m-0 p-0"
8124
- }, langdetect == 'en' ? sectionproperties.phonetitle_en : sectionproperties.phonetitle_ar))), sectionproperties.showfooteremail == 'Show' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i7 = authdetailsContext.instinfo) === null || _authdetailsContext$i7 === void 0 || (_authdetailsContext$i7 = _authdetailsContext$i7.contactinfo) === null || _authdetailsContext$i7 === void 0 ? void 0 : _authdetailsContext$i7.email) != null && /*#__PURE__*/React__default["default"].createElement("div", {
8192
+ }, langdetect == 'en' ? sectionproperties.phonetitle_en : sectionproperties.phonetitle_ar))), sectionproperties.showfooteremail == 'Show' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i9 = authdetailsContext.instinfo) === null || _authdetailsContext$i9 === void 0 || (_authdetailsContext$i9 = _authdetailsContext$i9.contactinfo) === null || _authdetailsContext$i9 === void 0 ? void 0 : _authdetailsContext$i9.email) != null && /*#__PURE__*/React__default["default"].createElement("div", {
8125
8193
  "class": position == 'belowinfo' ? 'col-lg-12 allcentered mb-2 p-0' : 'col-lg-12 allcentered mb-2 p-sm-0'
8126
8194
  }, /*#__PURE__*/React__default["default"].createElement("button", {
8127
8195
  "class": productinfo_cssstyles.storeinfobtn + ' allcentered ',
8128
8196
  onClick: function onClick() {
8129
- var _authdetailsContext$i8;
8130
- window.open('mailto:' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i8 = authdetailsContext.instinfo) === null || _authdetailsContext$i8 === void 0 || (_authdetailsContext$i8 = _authdetailsContext$i8.contactinfo) === null || _authdetailsContext$i8 === void 0 ? void 0 : _authdetailsContext$i8.email), '_self');
8197
+ var _authdetailsContext$i0;
8198
+ window.open('mailto:' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i0 = authdetailsContext.instinfo) === null || _authdetailsContext$i0 === void 0 || (_authdetailsContext$i0 = _authdetailsContext$i0.contactinfo) === null || _authdetailsContext$i0 === void 0 ? void 0 : _authdetailsContext$i0.email), '_self');
8131
8199
  }
8132
8200
  }, /*#__PURE__*/React__default["default"].createElement("p", {
8133
8201
  "class": "m-0 p-0"
8134
- }, langdetect == 'en' ? sectionproperties.emailtitle_en : sectionproperties.emailtitle_ar))), sectionproperties.showwhatsapp == 'Show' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i9 = authdetailsContext.instinfo) === null || _authdetailsContext$i9 === void 0 ? void 0 : _authdetailsContext$i9.whatsappnumber) != null && /*#__PURE__*/React__default["default"].createElement("div", {
8202
+ }, langdetect == 'en' ? sectionproperties.emailtitle_en : sectionproperties.emailtitle_ar))), sectionproperties.showwhatsapp == 'Show' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i1 = authdetailsContext.instinfo) === null || _authdetailsContext$i1 === void 0 ? void 0 : _authdetailsContext$i1.whatsappnumber) != null && /*#__PURE__*/React__default["default"].createElement("div", {
8135
8203
  "class": position == 'belowinfo' ? 'col-lg-12 allcentered mb-2 p-0' : 'col-lg-12 allcentered mb-2 p-sm-0'
8136
8204
  }, /*#__PURE__*/React__default["default"].createElement("button", {
8137
8205
  "class": productinfo_cssstyles.storeinfobtn + ' allcentered ',
8138
8206
  onClick: function onClick() {
8139
- var _authdetailsContext$i0;
8140
- if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i0 = authdetailsContext.instinfo) === null || _authdetailsContext$i0 === void 0 ? void 0 : _authdetailsContext$i0.whatsappnumber) != null) {
8141
- var _authdetailsContext$i1;
8142
- window.open('https://api.whatsapp.com/send?phone=' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i1 = authdetailsContext.instinfo) === null || _authdetailsContext$i1 === void 0 ? void 0 : _authdetailsContext$i1.whatsappnumber), '_blank');
8207
+ var _authdetailsContext$i10;
8208
+ if ((authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i10 = authdetailsContext.instinfo) === null || _authdetailsContext$i10 === void 0 ? void 0 : _authdetailsContext$i10.whatsappnumber) != null) {
8209
+ var _authdetailsContext$i11;
8210
+ window.open('https://api.whatsapp.com/send?phone=' + (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i11 = authdetailsContext.instinfo) === null || _authdetailsContext$i11 === void 0 ? void 0 : _authdetailsContext$i11.whatsappnumber), '_blank');
8143
8211
  }
8144
8212
  }
8145
8213
  }, /*#__PURE__*/React__default["default"].createElement("p", {
@@ -8215,6 +8283,7 @@ var Productinfo = function Productinfo(props) {
8215
8283
  }
8216
8284
  }, (fetchProductInfoQueryContext === null || fetchProductInfoQueryContext === void 0 || (_fetchProductInfoQuer71 = fetchProductInfoQueryContext.data) === null || _fetchProductInfoQuer71 === void 0 || (_fetchProductInfoQuer71 = _fetchProductInfoQuer71.data) === null || _fetchProductInfoQuer71 === void 0 || (_fetchProductInfoQuer71 = _fetchProductInfoQuer71.productinfo) === null || _fetchProductInfoQuer71 === void 0 ? void 0 : _fetchProductInfoQuer71.item_type) == 'product' && /*#__PURE__*/React__default["default"].createElement(Product_itemtype, {
8217
8285
  actions: (_ref = {
8286
+ isOptionInStock: isOptionInStock,
8218
8287
  variantnotchosendisclaimer: variantnotchosendisclaimer,
8219
8288
  fetchAuthorizationQueryContext: fetchAuthorizationQueryContext,
8220
8289
  setisoutofstock: setisoutofstock,
@@ -8246,7 +8315,7 @@ var Productinfo = function Productinfo(props) {
8246
8315
  lang: lang,
8247
8316
  srcfromprops: props.srcfromprops
8248
8317
  }, _defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_ref3, "returnpolicyobj", returnpolicyobj), "productinfo_cssstyles", productinfo_cssstyles), "addtocartfunc", addtocartfunc), "selectproductoptionvalue", selectproductoptionvalue), "clearchoosenvaluesbutkeepcurrentvalue", clearchoosenvaluesbutkeepcurrentvalue), "productimagesarray", productimagesarray), "fetchProductInfoQueryContext", fetchProductInfoQueryContext), "sectionproperties", sectionproperties), "addtocardpayloadobj", addtocardpayloadobj), "ProductInfoObj", ProductInfoObj), _defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_ref3, "currentshowingimageindex", currentshowingimageindex), "setcurrentshowingimageindex", setcurrentshowingimageindex), "setaddtocardpayloadobj", setaddtocardpayloadobj), "routingcountext", routingcountext), "AddtoCartMutationContext", AddtoCartMutationContext), "authdetailsContext", authdetailsContext), "addtofavoritescontext", addtofavoritescontext), "StaticPagesLinksContext", StaticPagesLinksContext), "variantindexcompleted", variantindexcompleted), "GeneralAPIMutationContext", GeneralAPIMutationContext), _defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_defineProperty__default["default"](_ref3, "NotificationManager", NotificationManager), "getprice_discountpriceprops", getprice_discountpriceprops), "quantityconditionfoundobjprops", quantityconditionfoundobj), "relatedproducts", relatedproducts), "getQuantityCondition", getQuantityCondition), "StoreInfoprops", StoreInfo), "templatepropcontext", templatepropcontext), "ikimagecredcontext", ikimagecredcontext), "sizeguideimage", sizeguideimage), "setopensizeguidemodal", setopensizeguidemodal))
8249
- }), props.srcfromprops != 'templatedraftrouter' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i10 = authdetailsContext.instinfo) === null || _authdetailsContext$i10 === void 0 ? void 0 : _authdetailsContext$i10.contactinfo.instid) != '6852e5ed44e14' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i11 = authdetailsContext.instinfo) === null || _authdetailsContext$i11 === void 0 ? void 0 : _authdetailsContext$i11.contactinfo.instid) != '68a9e83c05b75' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i12 = authdetailsContext.instinfo) === null || _authdetailsContext$i12 === void 0 ? void 0 : _authdetailsContext$i12.contactinfo.instid) != '68c27b4570751' && /*#__PURE__*/React__default["default"].createElement("div", {
8318
+ }), props.srcfromprops != 'templatedraftrouter' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i12 = authdetailsContext.instinfo) === null || _authdetailsContext$i12 === void 0 ? void 0 : _authdetailsContext$i12.contactinfo.instid) != '6852e5ed44e14' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i13 = authdetailsContext.instinfo) === null || _authdetailsContext$i13 === void 0 ? void 0 : _authdetailsContext$i13.contactinfo.instid) != '68a9e83c05b75' && (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i14 = authdetailsContext.instinfo) === null || _authdetailsContext$i14 === void 0 ? void 0 : _authdetailsContext$i14.contactinfo.instid) != '68c27b4570751' && /*#__PURE__*/React__default["default"].createElement("div", {
8250
8319
  className: sectionproperties.card_marginLeft != 0 ? ' col-lg-12 p-0 pl-lg-3 pr-lg-3 pl-md-4 pr-md-4 pl-sm-1 pr-sm-1 ' : ' col-lg-12 p-sm-0 ',
8251
8320
  style: {
8252
8321
  paddingLeft: props.srcfromprops == 'Productinfomodel' ? langdetect == 'en' ? sectionproperties.card_marginLeft + 'px' : sectionproperties.card_marginRight + 'px' : 0,