tabexseriescomponents 0.50.126 → 0.50.128
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 +62 -8
- package/dist/index.esm.js +62 -8
- package/dist/index.umd.js +62 -8
- package/package.json +1 -1
package/dist/index.cjs.js
CHANGED
|
@@ -10987,10 +10987,14 @@ var Compare = function Compare(props) {
|
|
|
10987
10987
|
_useState4 = _slicedToArray__default["default"](_useState3, 2),
|
|
10988
10988
|
sectionproperties = _useState4[0],
|
|
10989
10989
|
setsectionproperties = _useState4[1];
|
|
10990
|
-
var _useState5 = React.useState(
|
|
10991
|
-
_useState6 = _slicedToArray__default["default"](_useState5, 2)
|
|
10992
|
-
|
|
10993
|
-
|
|
10990
|
+
var _useState5 = React.useState(false),
|
|
10991
|
+
_useState6 = _slicedToArray__default["default"](_useState5, 2);
|
|
10992
|
+
_useState6[0];
|
|
10993
|
+
var setIsCompared = _useState6[1];
|
|
10994
|
+
var _useState7 = React.useState([]),
|
|
10995
|
+
_useState8 = _slicedToArray__default["default"](_useState7, 2),
|
|
10996
|
+
productDataList = _useState8[0],
|
|
10997
|
+
setProductDataList = _useState8[1];
|
|
10994
10998
|
var fetchAuthorizationQueryContext = props.actions.fetchAuthorizationQueryContext;
|
|
10995
10999
|
var fetchComparedProducts = /*#__PURE__*/function () {
|
|
10996
11000
|
var _ref = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee() {
|
|
@@ -11032,6 +11036,30 @@ var Compare = function Compare(props) {
|
|
|
11032
11036
|
return _ref.apply(this, arguments);
|
|
11033
11037
|
};
|
|
11034
11038
|
}();
|
|
11039
|
+
var removecompareproduct = function removecompareproduct(productId) {
|
|
11040
|
+
// Replace this with a real ID (e.g., passed via props)
|
|
11041
|
+
var key = 'comparedProducts';
|
|
11042
|
+
|
|
11043
|
+
// Get current list from localStorage
|
|
11044
|
+
var existing = JSON.parse(localStorage.getItem(key)) || [];
|
|
11045
|
+
|
|
11046
|
+
// Check if the product is already in the list
|
|
11047
|
+
var index = existing.indexOf(productId);
|
|
11048
|
+
if (index > -1) {
|
|
11049
|
+
// If exists, remove it (toggle off)
|
|
11050
|
+
existing.splice(index, 1);
|
|
11051
|
+
setIsCompared(false);
|
|
11052
|
+
} else {
|
|
11053
|
+
// If not, add it (toggle on)
|
|
11054
|
+
|
|
11055
|
+
existing.push(productId);
|
|
11056
|
+
setIsCompared(true);
|
|
11057
|
+
}
|
|
11058
|
+
|
|
11059
|
+
// Update localStorage
|
|
11060
|
+
localStorage.setItem(key, JSON.stringify(existing));
|
|
11061
|
+
window.location.reload();
|
|
11062
|
+
};
|
|
11035
11063
|
React.useEffect(function () {
|
|
11036
11064
|
var runcomparefunc = /*#__PURE__*/function () {
|
|
11037
11065
|
var _ref2 = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee2() {
|
|
@@ -11109,7 +11137,17 @@ var Compare = function Compare(props) {
|
|
|
11109
11137
|
style: {
|
|
11110
11138
|
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11111
11139
|
}
|
|
11112
|
-
}, lang.price)
|
|
11140
|
+
}, lang.price), /*#__PURE__*/React__default["default"].createElement("th", {
|
|
11141
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
11142
|
+
style: {
|
|
11143
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11144
|
+
}
|
|
11145
|
+
}), /*#__PURE__*/React__default["default"].createElement("th", {
|
|
11146
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
11147
|
+
style: {
|
|
11148
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11149
|
+
}
|
|
11150
|
+
})), /*#__PURE__*/React__default["default"].createElement("tbody", null, productDataList.map(function (item, index) {
|
|
11113
11151
|
return /*#__PURE__*/React__default["default"].createElement("tr", null, /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
11114
11152
|
style: {
|
|
11115
11153
|
width: '70%',
|
|
@@ -11150,7 +11188,23 @@ var Compare = function Compare(props) {
|
|
|
11150
11188
|
color: '#000',
|
|
11151
11189
|
fontSize: '14px'
|
|
11152
11190
|
}
|
|
11153
|
-
}, item.defaultprice)
|
|
11191
|
+
}, item.defaultprice), /*#__PURE__*/React__default["default"].createElement("td", {
|
|
11192
|
+
"class": "cursor-pointer",
|
|
11193
|
+
style: {
|
|
11194
|
+
color: '#000',
|
|
11195
|
+
fontSize: '14px'
|
|
11196
|
+
},
|
|
11197
|
+
onClick: function onClick() {}
|
|
11198
|
+
}, lang.addtocart), /*#__PURE__*/React__default["default"].createElement("td", {
|
|
11199
|
+
"class": "cursor-pointer",
|
|
11200
|
+
style: {
|
|
11201
|
+
color: '#000',
|
|
11202
|
+
fontSize: '14px'
|
|
11203
|
+
},
|
|
11204
|
+
onClick: function onClick() {
|
|
11205
|
+
removecompareproduct(item.productid);
|
|
11206
|
+
}
|
|
11207
|
+
}, lang.remove));
|
|
11154
11208
|
})))));
|
|
11155
11209
|
};
|
|
11156
11210
|
|
|
@@ -29975,7 +30029,7 @@ var HeaderresponsiveStyle2 = function HeaderresponsiveStyle2(props) {
|
|
|
29975
30029
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i21 = authdetailsContext.instinfo) === null || _authdetailsContext$i21 === void 0 ? void 0 : _authdetailsContext$i21.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29976
30030
|
className: "row m-0 w-100 anim"
|
|
29977
30031
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29978
|
-
className: "col-lg-12
|
|
30032
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
29979
30033
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29980
30034
|
onClick: function onClick() {
|
|
29981
30035
|
setopenmenuCanvas(false);
|
|
@@ -30492,7 +30546,7 @@ var HeaderresponsiveStyle2 = function HeaderresponsiveStyle2(props) {
|
|
|
30492
30546
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i28 = authdetailsContext.instinfo) === null || _authdetailsContext$i28 === void 0 ? void 0 : _authdetailsContext$i28.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30493
30547
|
className: "row m-0 w-100 anim"
|
|
30494
30548
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30495
|
-
className: "col-lg-12
|
|
30549
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
30496
30550
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30497
30551
|
onClick: function onClick() {
|
|
30498
30552
|
setopenmenuCanvas(false);
|
package/dist/index.esm.js
CHANGED
|
@@ -10935,10 +10935,14 @@ var Compare = function Compare(props) {
|
|
|
10935
10935
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
10936
10936
|
sectionproperties = _useState4[0],
|
|
10937
10937
|
setsectionproperties = _useState4[1];
|
|
10938
|
-
var _useState5 = useState(
|
|
10939
|
-
_useState6 = _slicedToArray(_useState5, 2)
|
|
10940
|
-
|
|
10941
|
-
|
|
10938
|
+
var _useState5 = useState(false),
|
|
10939
|
+
_useState6 = _slicedToArray(_useState5, 2);
|
|
10940
|
+
_useState6[0];
|
|
10941
|
+
var setIsCompared = _useState6[1];
|
|
10942
|
+
var _useState7 = useState([]),
|
|
10943
|
+
_useState8 = _slicedToArray(_useState7, 2),
|
|
10944
|
+
productDataList = _useState8[0],
|
|
10945
|
+
setProductDataList = _useState8[1];
|
|
10942
10946
|
var fetchAuthorizationQueryContext = props.actions.fetchAuthorizationQueryContext;
|
|
10943
10947
|
var fetchComparedProducts = /*#__PURE__*/function () {
|
|
10944
10948
|
var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
|
|
@@ -10980,6 +10984,30 @@ var Compare = function Compare(props) {
|
|
|
10980
10984
|
return _ref.apply(this, arguments);
|
|
10981
10985
|
};
|
|
10982
10986
|
}();
|
|
10987
|
+
var removecompareproduct = function removecompareproduct(productId) {
|
|
10988
|
+
// Replace this with a real ID (e.g., passed via props)
|
|
10989
|
+
var key = 'comparedProducts';
|
|
10990
|
+
|
|
10991
|
+
// Get current list from localStorage
|
|
10992
|
+
var existing = JSON.parse(localStorage.getItem(key)) || [];
|
|
10993
|
+
|
|
10994
|
+
// Check if the product is already in the list
|
|
10995
|
+
var index = existing.indexOf(productId);
|
|
10996
|
+
if (index > -1) {
|
|
10997
|
+
// If exists, remove it (toggle off)
|
|
10998
|
+
existing.splice(index, 1);
|
|
10999
|
+
setIsCompared(false);
|
|
11000
|
+
} else {
|
|
11001
|
+
// If not, add it (toggle on)
|
|
11002
|
+
|
|
11003
|
+
existing.push(productId);
|
|
11004
|
+
setIsCompared(true);
|
|
11005
|
+
}
|
|
11006
|
+
|
|
11007
|
+
// Update localStorage
|
|
11008
|
+
localStorage.setItem(key, JSON.stringify(existing));
|
|
11009
|
+
window.location.reload();
|
|
11010
|
+
};
|
|
10983
11011
|
useEffect(function () {
|
|
10984
11012
|
var runcomparefunc = /*#__PURE__*/function () {
|
|
10985
11013
|
var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime.mark(function _callee2() {
|
|
@@ -11057,7 +11085,17 @@ var Compare = function Compare(props) {
|
|
|
11057
11085
|
style: {
|
|
11058
11086
|
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11059
11087
|
}
|
|
11060
|
-
}, lang.price)
|
|
11088
|
+
}, lang.price), /*#__PURE__*/React.createElement("th", {
|
|
11089
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
11090
|
+
style: {
|
|
11091
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11092
|
+
}
|
|
11093
|
+
}), /*#__PURE__*/React.createElement("th", {
|
|
11094
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
11095
|
+
style: {
|
|
11096
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
11097
|
+
}
|
|
11098
|
+
})), /*#__PURE__*/React.createElement("tbody", null, productDataList.map(function (item, index) {
|
|
11061
11099
|
return /*#__PURE__*/React.createElement("tr", null, /*#__PURE__*/React.createElement("td", null, /*#__PURE__*/React.createElement("div", {
|
|
11062
11100
|
style: {
|
|
11063
11101
|
width: '70%',
|
|
@@ -11098,7 +11136,23 @@ var Compare = function Compare(props) {
|
|
|
11098
11136
|
color: '#000',
|
|
11099
11137
|
fontSize: '14px'
|
|
11100
11138
|
}
|
|
11101
|
-
}, item.defaultprice)
|
|
11139
|
+
}, item.defaultprice), /*#__PURE__*/React.createElement("td", {
|
|
11140
|
+
"class": "cursor-pointer",
|
|
11141
|
+
style: {
|
|
11142
|
+
color: '#000',
|
|
11143
|
+
fontSize: '14px'
|
|
11144
|
+
},
|
|
11145
|
+
onClick: function onClick() {}
|
|
11146
|
+
}, lang.addtocart), /*#__PURE__*/React.createElement("td", {
|
|
11147
|
+
"class": "cursor-pointer",
|
|
11148
|
+
style: {
|
|
11149
|
+
color: '#000',
|
|
11150
|
+
fontSize: '14px'
|
|
11151
|
+
},
|
|
11152
|
+
onClick: function onClick() {
|
|
11153
|
+
removecompareproduct(item.productid);
|
|
11154
|
+
}
|
|
11155
|
+
}, lang.remove));
|
|
11102
11156
|
})))));
|
|
11103
11157
|
};
|
|
11104
11158
|
|
|
@@ -29923,7 +29977,7 @@ var HeaderresponsiveStyle2 = function HeaderresponsiveStyle2(props) {
|
|
|
29923
29977
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i21 = authdetailsContext.instinfo) === null || _authdetailsContext$i21 === void 0 ? void 0 : _authdetailsContext$i21.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React.createElement("div", {
|
|
29924
29978
|
className: "row m-0 w-100 anim"
|
|
29925
29979
|
}, /*#__PURE__*/React.createElement("div", {
|
|
29926
|
-
className: "col-lg-12
|
|
29980
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
29927
29981
|
}, /*#__PURE__*/React.createElement("div", {
|
|
29928
29982
|
onClick: function onClick() {
|
|
29929
29983
|
setopenmenuCanvas(false);
|
|
@@ -30440,7 +30494,7 @@ var HeaderresponsiveStyle2 = function HeaderresponsiveStyle2(props) {
|
|
|
30440
30494
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i28 = authdetailsContext.instinfo) === null || _authdetailsContext$i28 === void 0 ? void 0 : _authdetailsContext$i28.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React.createElement("div", {
|
|
30441
30495
|
className: "row m-0 w-100 anim"
|
|
30442
30496
|
}, /*#__PURE__*/React.createElement("div", {
|
|
30443
|
-
className: "col-lg-12
|
|
30497
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
30444
30498
|
}, /*#__PURE__*/React.createElement("div", {
|
|
30445
30499
|
onClick: function onClick() {
|
|
30446
30500
|
setopenmenuCanvas(false);
|
package/dist/index.umd.js
CHANGED
|
@@ -10794,10 +10794,14 @@
|
|
|
10794
10794
|
_useState4 = _slicedToArray__default["default"](_useState3, 2),
|
|
10795
10795
|
sectionproperties = _useState4[0],
|
|
10796
10796
|
setsectionproperties = _useState4[1];
|
|
10797
|
-
var _useState5 = React.useState(
|
|
10798
|
-
_useState6 = _slicedToArray__default["default"](_useState5, 2)
|
|
10799
|
-
|
|
10800
|
-
|
|
10797
|
+
var _useState5 = React.useState(false),
|
|
10798
|
+
_useState6 = _slicedToArray__default["default"](_useState5, 2);
|
|
10799
|
+
_useState6[0];
|
|
10800
|
+
var setIsCompared = _useState6[1];
|
|
10801
|
+
var _useState7 = React.useState([]),
|
|
10802
|
+
_useState8 = _slicedToArray__default["default"](_useState7, 2),
|
|
10803
|
+
productDataList = _useState8[0],
|
|
10804
|
+
setProductDataList = _useState8[1];
|
|
10801
10805
|
var fetchAuthorizationQueryContext = props.actions.fetchAuthorizationQueryContext;
|
|
10802
10806
|
var fetchComparedProducts = /*#__PURE__*/function () {
|
|
10803
10807
|
var _ref = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee() {
|
|
@@ -10839,6 +10843,30 @@
|
|
|
10839
10843
|
return _ref.apply(this, arguments);
|
|
10840
10844
|
};
|
|
10841
10845
|
}();
|
|
10846
|
+
var removecompareproduct = function removecompareproduct(productId) {
|
|
10847
|
+
// Replace this with a real ID (e.g., passed via props)
|
|
10848
|
+
var key = 'comparedProducts';
|
|
10849
|
+
|
|
10850
|
+
// Get current list from localStorage
|
|
10851
|
+
var existing = JSON.parse(localStorage.getItem(key)) || [];
|
|
10852
|
+
|
|
10853
|
+
// Check if the product is already in the list
|
|
10854
|
+
var index = existing.indexOf(productId);
|
|
10855
|
+
if (index > -1) {
|
|
10856
|
+
// If exists, remove it (toggle off)
|
|
10857
|
+
existing.splice(index, 1);
|
|
10858
|
+
setIsCompared(false);
|
|
10859
|
+
} else {
|
|
10860
|
+
// If not, add it (toggle on)
|
|
10861
|
+
|
|
10862
|
+
existing.push(productId);
|
|
10863
|
+
setIsCompared(true);
|
|
10864
|
+
}
|
|
10865
|
+
|
|
10866
|
+
// Update localStorage
|
|
10867
|
+
localStorage.setItem(key, JSON.stringify(existing));
|
|
10868
|
+
window.location.reload();
|
|
10869
|
+
};
|
|
10842
10870
|
React.useEffect(function () {
|
|
10843
10871
|
var runcomparefunc = /*#__PURE__*/function () {
|
|
10844
10872
|
var _ref2 = _asyncToGenerator__default["default"](/*#__PURE__*/_regeneratorRuntime__default["default"].mark(function _callee2() {
|
|
@@ -10916,7 +10944,17 @@
|
|
|
10916
10944
|
style: {
|
|
10917
10945
|
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
10918
10946
|
}
|
|
10919
|
-
}, lang.price)
|
|
10947
|
+
}, lang.price), /*#__PURE__*/React__default["default"].createElement("th", {
|
|
10948
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
10949
|
+
style: {
|
|
10950
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
10951
|
+
}
|
|
10952
|
+
}), /*#__PURE__*/React__default["default"].createElement("th", {
|
|
10953
|
+
className: 'font-weight-500 font-14 text-uppercase text-light mw-150 mw-md-300',
|
|
10954
|
+
style: {
|
|
10955
|
+
textAlign: langdetect != 'ar' ? 'left' : 'right'
|
|
10956
|
+
}
|
|
10957
|
+
})), /*#__PURE__*/React__default["default"].createElement("tbody", null, productDataList.map(function (item, index) {
|
|
10920
10958
|
return /*#__PURE__*/React__default["default"].createElement("tr", null, /*#__PURE__*/React__default["default"].createElement("td", null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
10921
10959
|
style: {
|
|
10922
10960
|
width: '70%',
|
|
@@ -10957,7 +10995,23 @@
|
|
|
10957
10995
|
color: '#000',
|
|
10958
10996
|
fontSize: '14px'
|
|
10959
10997
|
}
|
|
10960
|
-
}, item.defaultprice)
|
|
10998
|
+
}, item.defaultprice), /*#__PURE__*/React__default["default"].createElement("td", {
|
|
10999
|
+
"class": "cursor-pointer",
|
|
11000
|
+
style: {
|
|
11001
|
+
color: '#000',
|
|
11002
|
+
fontSize: '14px'
|
|
11003
|
+
},
|
|
11004
|
+
onClick: function onClick() {}
|
|
11005
|
+
}, lang.addtocart), /*#__PURE__*/React__default["default"].createElement("td", {
|
|
11006
|
+
"class": "cursor-pointer",
|
|
11007
|
+
style: {
|
|
11008
|
+
color: '#000',
|
|
11009
|
+
fontSize: '14px'
|
|
11010
|
+
},
|
|
11011
|
+
onClick: function onClick() {
|
|
11012
|
+
removecompareproduct(item.productid);
|
|
11013
|
+
}
|
|
11014
|
+
}, lang.remove));
|
|
10961
11015
|
})))));
|
|
10962
11016
|
};
|
|
10963
11017
|
|
|
@@ -29782,7 +29836,7 @@
|
|
|
29782
29836
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i21 = authdetailsContext.instinfo) === null || _authdetailsContext$i21 === void 0 ? void 0 : _authdetailsContext$i21.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29783
29837
|
className: "row m-0 w-100 anim"
|
|
29784
29838
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29785
|
-
className: "col-lg-12
|
|
29839
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
29786
29840
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
29787
29841
|
onClick: function onClick() {
|
|
29788
29842
|
setopenmenuCanvas(false);
|
|
@@ -30299,7 +30353,7 @@
|
|
|
30299
30353
|
}))), (authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i28 = authdetailsContext.instinfo) === null || _authdetailsContext$i28 === void 0 ? void 0 : _authdetailsContext$i28.contactinfo.instid) == '67d6bda67adf6' && /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30300
30354
|
className: "row m-0 w-100 anim"
|
|
30301
30355
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30302
|
-
className: "col-lg-12
|
|
30356
|
+
className: "col-lg-12 d-flex justify-content-start pl-3 pr-3"
|
|
30303
30357
|
}, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
30304
30358
|
onClick: function onClick() {
|
|
30305
30359
|
setopenmenuCanvas(false);
|