tabexseriescomponents 0.0.359 → 0.0.360

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
@@ -119,6 +119,7 @@ var FiPhone = require('@react-icons/all-files/fi/FiPhone');
119
119
  var HiMenuAlt4 = require('@react-icons/all-files/hi/HiMenuAlt4');
120
120
  var FiSearch = require('@react-icons/all-files/fi/FiSearch');
121
121
  var BsSearch = require('@react-icons/all-files/bs/BsSearch');
122
+ var AiOutlinePhone = require('@react-icons/all-files/ai/AiOutlinePhone');
122
123
  var GoSearch = require('@react-icons/all-files/go/GoSearch');
123
124
  var AiOutlineInstagram = require('@react-icons/all-files/ai/AiOutlineInstagram');
124
125
  var BsChevronDown = require('@react-icons/all-files/bs/BsChevronDown');
@@ -131,7 +132,6 @@ var AiFillPhone = require('@react-icons/all-files/ai/AiFillPhone');
131
132
  var FaTelegramPlane = require('@react-icons/all-files/fa/FaTelegramPlane');
132
133
  var FaPhoneAlt = require('@react-icons/all-files/fa/FaPhoneAlt');
133
134
  var FaPhone = require('@react-icons/all-files/fa/FaPhone');
134
- var AiOutlinePhone = require('@react-icons/all-files/ai/AiOutlinePhone');
135
135
  var BiUserCircle = require('@react-icons/all-files/bi/BiUserCircle');
136
136
  var GoLocation = require('@react-icons/all-files/go/GoLocation');
137
137
  var RiRoadMapLine = require('@react-icons/all-files/ri/RiRoadMapLine');
@@ -12858,7 +12858,7 @@ var Select$1 = /*#__PURE__*/React__default["default"].lazy(function () {
12858
12858
  return Promise.resolve().then(function () { return /*#__PURE__*/_interopNamespace(require('react-select')); });
12859
12859
  });
12860
12860
  var Filter$1 = function Filter(props) {
12861
- var _authdetailsContext$i;
12861
+ var _authdetailsContext$i, _css;
12862
12862
  var lang = props.actions.lang;
12863
12863
  var langdetect = props.actions.langdetect;
12864
12864
  props.actions.productfiltercontext;
@@ -12873,9 +12873,13 @@ var Filter$1 = function Filter(props) {
12873
12873
  min: 0,
12874
12874
  max: 10000
12875
12875
  }),
12876
- _useState2 = _slicedToArray__default["default"](_useState, 2),
12877
- pricevalue = _useState2[0],
12878
- setpricevalue = _useState2[1];
12876
+ _useState2 = _slicedToArray__default["default"](_useState, 2);
12877
+ _useState2[0];
12878
+ _useState2[1];
12879
+ var _useState3 = React.useState([]),
12880
+ _useState4 = _slicedToArray__default["default"](_useState3, 2),
12881
+ productfeatuesarr = _useState4[0],
12882
+ setproductfeatuesarr = _useState4[1];
12879
12883
  var fetchTabexCountriesQueryContext = props.actions.fetchTabexCountriesQueryContext;
12880
12884
  var FetchQueriesEngineContext = props.actions.FetchQueriesEngineContext;
12881
12885
  var setFetchQueriesEngineContext = props.actions.setFetchQueriesEngineContext;
@@ -12883,40 +12887,41 @@ var Filter$1 = function Filter(props) {
12883
12887
  var fetchTabexStatesQueryContext = props.actions.fetchTabexStatesQueryContext;
12884
12888
  var FetchTabexStatesPayloadobjContext = props.actions.FetchTabexStatesPayloadobjContext;
12885
12889
  var setFetchTabexStatesPayloadobjContext = props.actions.setFetchTabexStatesPayloadobjContext;
12886
- var _useState3 = React.useState(''),
12887
- _useState4 = _slicedToArray__default["default"](_useState3, 2),
12888
- sectionproperties = _useState4[0],
12889
- setsectionproperties = _useState4[1];
12890
- var _useState5 = React.useState(_toConsumableArray__default["default"](authdetailsContext.instinfo.instfilters)),
12890
+ var fetchProductFeaturesQueryContext = props.actions.fetchProductFeaturesQueryContext;
12891
+ var _useState5 = React.useState(''),
12891
12892
  _useState6 = _slicedToArray__default["default"](_useState5, 2),
12892
- instfilters = _useState6[0],
12893
- setinstfilters = _useState6[1];
12894
- var _useState7 = React.useState([]),
12893
+ sectionproperties = _useState6[0],
12894
+ setsectionproperties = _useState6[1];
12895
+ var _useState7 = React.useState(_toConsumableArray__default["default"](authdetailsContext.instinfo.instfilters)),
12895
12896
  _useState8 = _slicedToArray__default["default"](_useState7, 2),
12896
- collectionstobevisible = _useState8[0],
12897
- setcollectionstobevisible = _useState8[1];
12898
- var _useState9 = React.useState(_toConsumableArray__default["default"](authdetailsContext.instinfo.instcollections)),
12897
+ instfilters = _useState8[0],
12898
+ setinstfilters = _useState8[1];
12899
+ var _useState9 = React.useState([]),
12899
12900
  _useState10 = _slicedToArray__default["default"](_useState9, 2),
12900
- instcollections = _useState10[0],
12901
- setinstcollections = _useState10[1];
12902
- var _useState11 = React.useState(_toConsumableArray__default["default"](authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i = authdetailsContext.instinfo) === null || _authdetailsContext$i === void 0 ? void 0 : _authdetailsContext$i.instcategories)),
12901
+ collectionstobevisible = _useState10[0],
12902
+ setcollectionstobevisible = _useState10[1];
12903
+ var _useState11 = React.useState(_toConsumableArray__default["default"](authdetailsContext.instinfo.instcollections)),
12903
12904
  _useState12 = _slicedToArray__default["default"](_useState11, 2),
12904
- instcategories = _useState12[0],
12905
- setinstcategories = _useState12[1];
12905
+ instcollections = _useState12[0],
12906
+ setinstcollections = _useState12[1];
12907
+ var _useState13 = React.useState(_toConsumableArray__default["default"](authdetailsContext === null || authdetailsContext === void 0 || (_authdetailsContext$i = authdetailsContext.instinfo) === null || _authdetailsContext$i === void 0 ? void 0 : _authdetailsContext$i.instcategories)),
12908
+ _useState14 = _slicedToArray__default["default"](_useState13, 2),
12909
+ instcategories = _useState14[0],
12910
+ setinstcategories = _useState14[1];
12906
12911
  // const [sortby, setSortby] = useState('Sort by');
12907
- var _useState13 = React.useState({
12912
+ var _useState15 = React.useState({
12908
12913
  min: 0,
12909
12914
  max: 5
12910
12915
  }),
12911
- _useState14 = _slicedToArray__default["default"](_useState13, 2),
12912
- raterangevalue = _useState14[0],
12913
- setraterangevalue = _useState14[1];
12916
+ _useState16 = _slicedToArray__default["default"](_useState15, 2),
12917
+ raterangevalue = _useState16[0],
12918
+ setraterangevalue = _useState16[1];
12914
12919
  var timeoutRef = React__default["default"].useRef(null);
12915
- var _useState15 = React.useState(''),
12916
- _useState16 = _slicedToArray__default["default"](_useState15, 2);
12917
- _useState16[0];
12918
- var setsortbycontext = _useState16[1];
12919
- var _useState17 = React.useState([{
12920
+ var _useState17 = React.useState(''),
12921
+ _useState18 = _slicedToArray__default["default"](_useState17, 2);
12922
+ _useState18[0];
12923
+ var setsortbycontext = _useState18[1];
12924
+ var _useState19 = React.useState([{
12920
12925
  payloadvalue: 'sortprice',
12921
12926
  name: lang.price,
12922
12927
  filterarray: [{
@@ -12941,9 +12946,9 @@ var Filter$1 = function Filter(props) {
12941
12946
  isfilterselected: false
12942
12947
  }]
12943
12948
  }]),
12944
- _useState18 = _slicedToArray__default["default"](_useState17, 2),
12945
- otherfilters = _useState18[0];
12946
- _useState18[1];
12949
+ _useState20 = _slicedToArray__default["default"](_useState19, 2),
12950
+ otherfilters = _useState20[0];
12951
+ _useState20[1];
12947
12952
  React.useEffect(function () {
12948
12953
  filterupdater();
12949
12954
  }, []);
@@ -13053,6 +13058,14 @@ var Filter$1 = function Filter(props) {
13053
13058
  setcollectionstobevisible(instcollections);
13054
13059
  }
13055
13060
  }, [ProductFilterObjContext]);
13061
+ React.useEffect(function () {
13062
+ if (productfeatuesarr.length != 0) {
13063
+ var tempfetchproductsfilerobjcontext = _objectSpread$26({}, ProductFilterObjContext);
13064
+ tempfetchproductsfilerobjcontext.prod_featruesar = productfeatuesarr;
13065
+ setProductFilterObjContext(_objectSpread$26({}, tempfetchproductsfilerobjcontext));
13066
+ filterrouting(tempfetchproductsfilerobjcontext);
13067
+ }
13068
+ }, [productfeatuesarr]);
13056
13069
  React.useEffect(function () {
13057
13070
  if (fetchTabexStatesQueryContext.isSuccess) {
13058
13071
  if (ProductFilterObjContext.stateid != undefined && ProductFilterObjContext.stateid != null && ProductFilterObjContext.stateid != '' && ProductFilterObjContext.stateid != 'all') {
@@ -13392,308 +13405,159 @@ var Filter$1 = function Filter(props) {
13392
13405
  })));
13393
13406
  };
13394
13407
  var DynamicFilter = function DynamicFilter() {
13395
- var _ref, _ref3, _ref4, _ref5, _ref6, _ref7;
13408
+ var _fetchProductFeatures;
13396
13409
  return /*#__PURE__*/React__default["default"].createElement("div", {
13397
13410
  "class": "row m-0 w-100"
13398
13411
  }, /*#__PURE__*/React__default["default"].createElement("div", {
13399
13412
  "class": "col-lg-12 p-0 mb-3"
13400
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13401
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13402
- style: (_ref = {
13403
- color: sectionproperties.filtertitle_color
13404
- }, _defineProperty__default["default"](_ref, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref, "color", sectionproperties.filtertitle_color), _ref)
13405
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13406
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13407
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13408
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13409
- }, langdetect == 'en' ? 'Car Brand' : 'الماركة'))), /*#__PURE__*/React__default["default"].createElement("div", {
13413
+ }, (fetchProductFeaturesQueryContext === null || fetchProductFeaturesQueryContext === void 0 ? void 0 : fetchProductFeaturesQueryContext.isSuccess) && /*#__PURE__*/React__default["default"].createElement("div", {
13410
13414
  className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13411
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13412
- className: 'col-lg-12 p-0'
13413
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13414
- options: [{
13415
- name: 'Tesla',
13416
- value: 'Tesla'
13417
- }, {
13418
- name: 'VW',
13419
- value: 'VW'
13420
- }, {
13421
- name: 'Mercedes',
13422
- value: 'Mercedes'
13423
- }],
13424
- getOptionLabel: function getOptionLabel(option) {
13425
- var crname = '';
13426
- if (langdetect == 'en') {
13427
- crname = option.name;
13428
- } else if (langdetect == 'ar') {
13429
- if (option.name_ar != null) {
13430
- crname = option.name_ar;
13415
+ }, fetchProductFeaturesQueryContext === null || fetchProductFeaturesQueryContext === void 0 || (_fetchProductFeatures = fetchProductFeaturesQueryContext.data) === null || _fetchProductFeatures === void 0 || (_fetchProductFeatures = _fetchProductFeatures.data) === null || _fetchProductFeatures === void 0 || (_fetchProductFeatures = _fetchProductFeatures.productfeatues) === null || _fetchProductFeatures === void 0 ? void 0 : _fetchProductFeatures.map(function (item, index) {
13416
+ if (item.type == 'Selectbox') {
13417
+ var _item$featuresselectb, _ref;
13418
+ var selectboxarr = [];
13419
+ item === null || item === void 0 || (_item$featuresselectb = item.featuresselectbovalue) === null || _item$featuresselectb === void 0 || _item$featuresselectb.forEach(function (slecitem) {
13420
+ var itemlabel = '';
13421
+ if (langdetect == 'en') {
13422
+ itemlabel = slecitem.value_en;
13431
13423
  } else {
13432
- crname = option.name;
13424
+ itemlabel = slecitem.value_ar;
13433
13425
  }
13434
- }
13435
- return crname;
13436
- },
13437
- getOptionValue: function getOptionValue(option) {
13438
- return option.id;
13439
- },
13440
- value: '',
13441
- onChange: function onChange(option) {},
13442
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13443
- isSearchable: true,
13444
- placeholder: ''
13445
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13446
- "class": "col-lg-12 p-0 mb-3"
13447
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13448
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13449
- style: _defineProperty__default["default"]({
13450
- color: sectionproperties.filtertitle_color,
13451
- fontSize: sectionproperties.filtertitle_fontsize + 'px',
13452
- fontWeight: sectionproperties.filtertitle_fontweight
13453
- }, "color", sectionproperties.filtertitle_color)
13454
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13455
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13456
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13457
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13458
- }, langdetect == 'en' ? 'Car Model' : 'النوع'))), /*#__PURE__*/React__default["default"].createElement("div", {
13459
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13460
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13461
- className: 'col-lg-12 p-0'
13462
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13463
- options: [{
13464
- name: 'ID.4',
13465
- value: 'ID.4'
13466
- }, {
13467
- name: 'ID.6',
13468
- value: 'ID.6'
13469
- }],
13470
- getOptionLabel: function getOptionLabel(option) {
13471
- var crname = '';
13472
- if (langdetect == 'en') {
13473
- crname = option.name;
13474
- } else if (langdetect == 'ar') {
13475
- if (option.name_ar != null) {
13476
- crname = option.name_ar;
13477
- } else {
13478
- crname = option.name;
13426
+ selectboxarr.push({
13427
+ label: itemlabel,
13428
+ value: slecitem.value_en
13429
+ });
13430
+ });
13431
+ return /*#__PURE__*/React__default["default"].createElement("div", {
13432
+ "class": "col-lg-12 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3 p-0"
13433
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
13434
+ className: ' mb-3 w-100 ',
13435
+ style: (_ref = {
13436
+ textAlign: langdetect == 'en' ? 'left' : 'right',
13437
+ color: sectionproperties.filtertitle_color
13438
+ }, _defineProperty__default["default"](_ref, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref, "textTransform", 'capitalize'), _ref)
13439
+ }, langdetect == 'en' ? item.name_en : item.name_ar), /*#__PURE__*/React__default["default"].createElement("div", {
13440
+ "class": 'col-lg-12 p-0'
13441
+ }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13442
+ options: selectboxarr,
13443
+ styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13444
+ placeholder: '',
13445
+ onChange: function onChange(e) {
13446
+ var isattrexists = false;
13447
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
13448
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
13449
+ if (attritem.id == item.id) {
13450
+ tempproductfeatuesarr[attrindex].value = e.value;
13451
+ isattrexists = true;
13452
+ }
13453
+ });
13454
+ if (isattrexists == false) {
13455
+ tempproductfeatuesarr.push({
13456
+ id: item.id,
13457
+ value: e.value
13458
+ });
13459
+ }
13460
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
13479
13461
  }
13480
- }
13481
- return crname;
13482
- },
13483
- getOptionValue: function getOptionValue(option) {
13484
- return option.id;
13485
- },
13486
- value: '',
13487
- onChange: function onChange(option) {},
13488
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13489
- isSearchable: true,
13490
- placeholder: ''
13491
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13492
- "class": "col-lg-12 p-0 mb-3"
13493
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13494
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13495
- style: (_ref3 = {
13496
- color: sectionproperties.filtertitle_color
13497
- }, _defineProperty__default["default"](_ref3, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref3, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref3, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref3, "color", sectionproperties.filtertitle_color), _ref3)
13498
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13499
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13500
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13501
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13502
- }, " ", langdetect == 'en' ? 'Kilometers (From)' : 'كيلومترات (من)'))), /*#__PURE__*/React__default["default"].createElement("div", {
13503
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13504
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13505
- className: 'col-lg-12 p-0'
13506
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13507
- options: [{
13508
- name: '10000',
13509
- value: '10000'
13510
- }, {
13511
- name: '20000',
13512
- value: '20000'
13513
- }],
13514
- getOptionLabel: function getOptionLabel(option) {
13515
- var crname = '';
13516
- if (langdetect == 'en') {
13517
- crname = option.name;
13518
- } else if (langdetect == 'ar') {
13519
- if (option.name_ar != null) {
13520
- crname = option.name_ar;
13521
- } else {
13522
- crname = option.name;
13462
+ })));
13463
+ }
13464
+ if (item.type == 'Number') {
13465
+ var _ref2;
13466
+ return /*#__PURE__*/React__default["default"].createElement("div", {
13467
+ "class": "col-lg-12 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3 p-0"
13468
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
13469
+ className: "".concat(filter_cssstyles.input_label_name) + ' mb-3 w-100 ',
13470
+ style: (_ref2 = {
13471
+ textAlign: langdetect == 'en' ? 'left' : 'right',
13472
+ color: sectionproperties.filtertitle_color
13473
+ }, _defineProperty__default["default"](_ref2, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref2, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref2, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref2, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref2, "textTransform", 'capitalize'), _ref2)
13474
+ }, langdetect == 'en' ? item.name_en : item.name_ar), /*#__PURE__*/React__default["default"].createElement("div", {
13475
+ "class": 'col-lg-12 p-0'
13476
+ }, /*#__PURE__*/React__default["default"].createElement("input", {
13477
+ type: "number",
13478
+ className: "".concat(formstyles.form_control, " ").concat(filter_cssstyles.form_control),
13479
+ placeholder: '',
13480
+ onChange: function onChange(e) {
13481
+ var isattrexists = false;
13482
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
13483
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
13484
+ if (attritem.id == item.id) {
13485
+ tempproductfeatuesarr[attrindex].value = e.target.value;
13486
+ isattrexists = true;
13487
+ }
13488
+ });
13489
+ if (isattrexists == false) {
13490
+ tempproductfeatuesarr.push({
13491
+ id: item.id,
13492
+ value: e.target.value
13493
+ });
13494
+ }
13495
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
13523
13496
  }
13524
- }
13525
- return crname;
13526
- },
13527
- getOptionValue: function getOptionValue(option) {
13528
- return option.id;
13529
- },
13530
- value: '',
13531
- onChange: function onChange(option) {},
13532
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13533
- isSearchable: true,
13534
- placeholder: ''
13535
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13536
- "class": "col-lg-12 p-0 mb-3"
13537
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13538
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13539
- style: (_ref4 = {
13540
- color: sectionproperties.filtertitle_color
13541
- }, _defineProperty__default["default"](_ref4, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref4, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref4, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref4, "color", sectionproperties.filtertitle_color), _ref4)
13542
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13543
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13544
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13545
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13546
- }, langdetect == 'en' ? 'Kilometers (To)' : 'كيلومترات (الى)'))), /*#__PURE__*/React__default["default"].createElement("div", {
13547
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13548
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13549
- className: 'col-lg-12 p-0'
13550
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13551
- options: [{
13552
- name: '10000',
13553
- value: '10000'
13554
- }, {
13555
- name: '20000',
13556
- value: '20000'
13557
- }],
13558
- getOptionLabel: function getOptionLabel(option) {
13559
- var crname = '';
13560
- if (langdetect == 'en') {
13561
- crname = option.name;
13562
- } else if (langdetect == 'ar') {
13563
- if (option.name_ar != null) {
13564
- crname = option.name_ar;
13565
- } else {
13566
- crname = option.name;
13497
+ })));
13498
+ }
13499
+ if (item.type == 'NumberRange') {
13500
+ var _ref3;
13501
+ var temppricevalue = {
13502
+ min: 0,
13503
+ max: 10000
13504
+ };
13505
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
13506
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
13507
+ if (attritem.id == item.id) {
13508
+ var _attritem$value, _attritem$valuemax;
13509
+ if (attritem.value != undefined && attritem.value != null && (attritem === null || attritem === void 0 || (_attritem$value = attritem.value) === null || _attritem$value === void 0 ? void 0 : _attritem$value.length) != 0) {
13510
+ temppricevalue.min = attritem.value;
13511
+ }
13512
+ if (attritem.valuemax != undefined && attritem.valuemax != null && (attritem === null || attritem === void 0 || (_attritem$valuemax = attritem.valuemax) === null || _attritem$valuemax === void 0 ? void 0 : _attritem$valuemax.length) != 0) {
13513
+ temppricevalue.max = attritem.valuemax;
13514
+ }
13567
13515
  }
13568
- }
13569
- return crname;
13570
- },
13571
- getOptionValue: function getOptionValue(option) {
13572
- return option.id;
13573
- },
13574
- value: '',
13575
- onChange: function onChange(option) {},
13576
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13577
- isSearchable: true,
13578
- placeholder: ''
13579
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13580
- "class": "col-lg-12 p-0 mb-3"
13581
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13582
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13583
- style: (_ref5 = {
13584
- color: sectionproperties.filtertitle_color
13585
- }, _defineProperty__default["default"](_ref5, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref5, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref5, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref5, "color", sectionproperties.filtertitle_color), _ref5)
13586
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13587
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13588
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13589
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13590
- }, langdetect == 'en' ? 'Year of built (From)' : 'سنة الصنع (من)'))), /*#__PURE__*/React__default["default"].createElement("div", {
13591
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13592
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13593
- className: 'col-lg-12 p-0'
13594
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13595
- options: [{
13596
- name: '2020',
13597
- value: '2020'
13598
- }, {
13599
- name: '2021',
13600
- value: '2021'
13601
- }],
13602
- getOptionLabel: function getOptionLabel(option) {
13603
- var crname = '';
13604
- if (langdetect == 'en') {
13605
- crname = option.name;
13606
- } else if (langdetect == 'ar') {
13607
- if (option.name_ar != null) {
13608
- crname = option.name_ar;
13609
- } else {
13610
- crname = option.name;
13516
+ });
13517
+ return /*#__PURE__*/React__default["default"].createElement("div", {
13518
+ className: "".concat(langdetect == 'en' ? 'text-left' : 'text-right') + ' col-lg-12 col-md-12 col-sm-12 mb-3 '
13519
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
13520
+ className: "".concat(filter_cssstyles.input_label_name) + ' mb-3 w-100',
13521
+ style: (_ref3 = {
13522
+ textAlign: langdetect == 'en' ? 'left' : 'right',
13523
+ color: sectionproperties.filtertitle_color
13524
+ }, _defineProperty__default["default"](_ref3, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref3, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref3, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref3, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref3, "textTransform", 'capitalize'), _ref3)
13525
+ }, langdetect == 'en' ? item.name_en : item.name_ar, item.type), /*#__PURE__*/React__default["default"].createElement("div", {
13526
+ "class": 'col-lg-12 pl-4 pr-4 mt-2 mb-2',
13527
+ style: {
13528
+ direction: 'ltr'
13611
13529
  }
13612
- }
13613
- return crname;
13614
- },
13615
- getOptionValue: function getOptionValue(option) {
13616
- return option.id;
13617
- },
13618
- value: '',
13619
- onChange: function onChange(option) {},
13620
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13621
- isSearchable: true,
13622
- placeholder: ''
13623
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13624
- "class": "col-lg-12 p-0 mb-3"
13625
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13626
- className: ' row m-0 p-0 mb-2 pl-md-3 pr-md-3 ',
13627
- style: (_ref6 = {
13628
- color: sectionproperties.filtertitle_color
13629
- }, _defineProperty__default["default"](_ref6, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref6, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref6, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref6, "color", sectionproperties.filtertitle_color), _ref6)
13630
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13631
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13632
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13633
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13634
- }, langdetect == 'en' ? 'Year of built (To)' : 'سنة الصنع (الى)'))), /*#__PURE__*/React__default["default"].createElement("div", {
13635
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13636
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13637
- className: 'col-lg-12 p-0'
13638
- }, /*#__PURE__*/React__default["default"].createElement(Select$1, {
13639
- options: [{
13640
- name: '2020',
13641
- value: '2020'
13642
- }, {
13643
- name: '2021',
13644
- value: '2021'
13645
- }],
13646
- getOptionLabel: function getOptionLabel(option) {
13647
- var crname = '';
13648
- if (langdetect == 'en') {
13649
- crname = option.name;
13650
- } else if (langdetect == 'ar') {
13651
- if (option.name_ar != null) {
13652
- crname = option.name_ar;
13653
- } else {
13654
- crname = option.name;
13530
+ }, /*#__PURE__*/React__default["default"].createElement(InputRange__default["default"], {
13531
+ draggableTrack: true,
13532
+ formatLabel: function formatLabel(value) {
13533
+ return "".concat(value);
13534
+ },
13535
+ maxValue: parseInt(sectionproperties.filterpricemaxvalue),
13536
+ minValue: parseInt(sectionproperties.filterpriceminvalue),
13537
+ value: temppricevalue,
13538
+ onChange: function onChange(e) {
13539
+ // setpricevalue({ ...value });
13540
+ var isattrexists = false;
13541
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
13542
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
13543
+ if (attritem.id == item.id) {
13544
+ tempproductfeatuesarr[attrindex].value = e.min;
13545
+ tempproductfeatuesarr[attrindex].valuemax = e.max;
13546
+ isattrexists = true;
13547
+ }
13548
+ });
13549
+ if (isattrexists == false) {
13550
+ tempproductfeatuesarr.push({
13551
+ id: item.id,
13552
+ value: e.min,
13553
+ valuemax: e.max
13554
+ });
13555
+ }
13556
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
13655
13557
  }
13656
- }
13657
- return crname;
13658
- },
13659
- getOptionValue: function getOptionValue(option) {
13660
- return option.id;
13661
- },
13662
- value: '',
13663
- onChange: function onChange(option) {},
13664
- styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
13665
- isSearchable: true,
13666
- placeholder: ''
13667
- })))), /*#__PURE__*/React__default["default"].createElement("div", {
13668
- "class": "col-lg-12 p-0 mb-3"
13669
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13670
- className: ' row m-0 p-0 mb-4 pl-md-3 pr-md-3 ',
13671
- style: (_ref7 = {
13672
- color: sectionproperties.filtertitle_color
13673
- }, _defineProperty__default["default"](_ref7, "color", sectionproperties.filtertitle_color), _defineProperty__default["default"](_ref7, "fontSize", sectionproperties.filtertitle_fontsize + 'px'), _defineProperty__default["default"](_ref7, "fontWeight", sectionproperties.filtertitle_fontweight), _defineProperty__default["default"](_ref7, "color", sectionproperties.filtertitle_color), _ref7)
13674
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13675
- className: "col-lg-10 col-md-10 col-sm-10 p-0"
13676
- }, /*#__PURE__*/React__default["default"].createElement("p", {
13677
- className: langdetect == 'en' ? ' m-0 p-0 ' : ' m-0 p-0 text-right'
13678
- }, langdetect == 'en' ? 'Price' : 'السعر'))), /*#__PURE__*/React__default["default"].createElement("div", {
13679
- className: "row mt-0 mb-2 ml-0 mr-0 d-lg-flex pl-md-3 pr-md-3"
13680
- }, /*#__PURE__*/React__default["default"].createElement("div", {
13681
- className: 'col-lg-12 p-0 px-md-4',
13682
- style: {
13683
- direction: 'ltr'
13684
- }
13685
- }, /*#__PURE__*/React__default["default"].createElement(InputRange__default["default"], {
13686
- draggableTrack: true,
13687
- formatLabel: function formatLabel(value) {
13688
- return "".concat(value);
13689
- },
13690
- maxValue: parseInt(sectionproperties.filterpricemaxvalue),
13691
- minValue: parseInt(sectionproperties.filterpriceminvalue),
13692
- value: pricevalue,
13693
- onChange: function onChange(value) {
13694
- setpricevalue(_objectSpread$26({}, value));
13558
+ })));
13695
13559
  }
13696
- })))));
13560
+ }))));
13697
13561
  };
13698
13562
  var InstFilters = function InstFilters() {
13699
13563
  return /*#__PURE__*/React__default["default"].createElement(reactAccessibleAccordion.Accordion, {
@@ -13752,6 +13616,15 @@ var Filter$1 = function Filter(props) {
13752
13616
  }));
13753
13617
  };
13754
13618
  var filter_cssstyles = {
13619
+ form_control: glamor.css((_css = {
13620
+ position: 'relative',
13621
+ display: 'flex',
13622
+ alignItems: 'center'
13623
+ }, _defineProperty__default["default"](_css, "display", 'block'), _defineProperty__default["default"](_css, "width", '100%'), _defineProperty__default["default"](_css, "padding", '0 30px'), _defineProperty__default["default"](_css, "transition", '.3s'), _defineProperty__default["default"](_css, "fontWeight", 500), _defineProperty__default["default"](_css, "border", '1px solid #ccc'), _defineProperty__default["default"](_css, "borderRadius", '5px'), _defineProperty__default["default"](_css, "height", '40px'), _defineProperty__default["default"](_css, "background", 'transparent'), _defineProperty__default["default"](_css, "color", '#000'), _defineProperty__default["default"](_css, "fontSize", '14px'), _defineProperty__default["default"](_css, ':focus', {
13624
+ // borderColor: sectionproperties.inputfeildbordercoloronfocus,
13625
+ borderColor: '#eac435',
13626
+ boxShadow: 'none'
13627
+ }), _css)),
13755
13628
  collapsetitle: glamor.css({
13756
13629
  fontSize: sectionproperties.filtertitle_fontsize + 'px',
13757
13630
  fontWeight: sectionproperties.filtertitle_fontweight,
@@ -14014,10 +13887,10 @@ var Filter$1 = function Filter(props) {
14014
13887
  isSearchable: true
14015
13888
  })))));
14016
13889
  };
14017
- var _useState19 = React.useState(false),
14018
- _useState20 = _slicedToArray__default["default"](_useState19, 2),
14019
- checked = _useState20[0],
14020
- setChecked = _useState20[1];
13890
+ var _useState21 = React.useState(false),
13891
+ _useState22 = _slicedToArray__default["default"](_useState21, 2),
13892
+ checked = _useState22[0],
13893
+ setChecked = _useState22[1];
14021
13894
  // const queryParameters = new URLSearchParams(window.location.search);
14022
13895
  // useEffect(() => {
14023
13896
  // // setsortbycontext('Sort By');
@@ -15909,7 +15782,8 @@ var CardsSection = function CardsSection(props) {
15909
15782
  borderTopLeftRadius: langdetect == 'en' ? sectionproperties.borderTopLeftRadius + 'px' : sectionproperties.borderTopRightRadius + 'px',
15910
15783
  borderTopRightRadius: langdetect == 'en' ? sectionproperties.borderTopRightRadius + 'px' : sectionproperties.borderTopLeftRadius + 'px',
15911
15784
  marginTop: sectionproperties.marginTop + 'px',
15912
- marginBottom: sectionproperties.marginBottom + 'px'
15785
+ marginBottom: sectionproperties.marginBottom + 'px',
15786
+ minHeight: sectionproperties.height == null || sectionproperties.height == 0 ? 'auto' : sectionproperties.height + 'vh'
15913
15787
  }
15914
15788
  }, sectionproperties.length != 0 && /*#__PURE__*/React__default["default"].createElement("div", {
15915
15789
  "class": section_cssstyles.innercardssection + ' row ml-0 mr-0 d-flex justify-content-center w-md-100 h-md-100 w-100 '
@@ -21766,6 +21640,32 @@ var ClassicHeader = function ClassicHeader(props) {
21766
21640
  }, /*#__PURE__*/React__default["default"].createElement(FaWhatsapp.FaWhatsapp, {
21767
21641
  size: 25,
21768
21642
  color: '#fff'
21643
+ })))), sectionproperties.showwhatsapp == 'Show' && /*#__PURE__*/React__default["default"].createElement("a", {
21644
+ href: 'tel:' + (authdetailsContext === null || authdetailsContext === void 0 ? void 0 : authdetailsContext.CuContactphonenumber),
21645
+ target: '_blank',
21646
+ style: {
21647
+ position: 'fixed',
21648
+ bottom: 60,
21649
+ right: 10,
21650
+ zIndex: 999999,
21651
+ transition: 'all 0.3s ease-out'
21652
+ }
21653
+ }, /*#__PURE__*/React__default["default"].createElement("div", {
21654
+ style: {
21655
+ width: 40,
21656
+ height: 40,
21657
+ borderRadius: 100,
21658
+ background: '#000',
21659
+ cursor: 'pointer'
21660
+ }
21661
+ }, /*#__PURE__*/React__default["default"].createElement("i", {
21662
+ "class": "h-100 allcentered"
21663
+ }, /*#__PURE__*/React__default["default"].createElement(AiOutlinePhone.AiOutlinePhone, {
21664
+ size: 25,
21665
+ color: '#fff',
21666
+ style: {
21667
+ transform: langdetect == 'en' ? 'scaleX(-1)' : 'scaleX(1)'
21668
+ }
21769
21669
  })))), /*#__PURE__*/React__default["default"].createElement("div", {
21770
21670
  "class": "row m-0",
21771
21671
  style: {
@@ -47732,6 +47632,7 @@ var CustomerAddressForm = function CustomerAddressForm(props) {
47732
47632
  function ownKeys$17(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; }
47733
47633
  function _objectSpread$17(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys$17(Object(t), !0).forEach(function (r) { _defineProperty__default["default"](e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys$17(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
47734
47634
  var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props) {
47635
+ var _css, _fetchProductFeatures;
47735
47636
  var _useState = React.useState(''),
47736
47637
  _useState2 = _slicedToArray__default["default"](_useState, 2),
47737
47638
  sectionproperties = _useState2[0],
@@ -47758,6 +47659,7 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
47758
47659
  var fetchTabexStatesQueryContext = props.actions.fetchTabexStatesQueryContext;
47759
47660
  var fetchTabexCitiesQueryContext = props.actions.fetchTabexCitiesQueryContext;
47760
47661
  var fetchproductsfilerobjcontext = props.actions.fetchproductsfilerobjcontext;
47662
+ var fetchProductFeaturesQueryContext = props.actions.fetchProductFeaturesQueryContext;
47761
47663
  var routingcountext = props.actions.routingcountext;
47762
47664
  var StaticPagesLinksContext = props.actions.StaticPagesLinksContext;
47763
47665
  // const fetchcollectionsQueryContext = props.actions.fetchcollectionsQueryContext;
@@ -47777,6 +47679,10 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
47777
47679
  _useState12 = _slicedToArray__default["default"](_useState11, 2);
47778
47680
  _useState12[0];
47779
47681
  _useState12[1];
47682
+ var _useState13 = React.useState([]),
47683
+ _useState14 = _slicedToArray__default["default"](_useState13, 2),
47684
+ productfeatuesarr = _useState14[0],
47685
+ setproductfeatuesarr = _useState14[1];
47780
47686
  var FetchQueriesEngineContext = props.actions.FetchQueriesEngineContext;
47781
47687
  var setFetchQueriesEngineContext = props.actions.setFetchQueriesEngineContext;
47782
47688
  var authdetailsContext = props.actions.authdetailsContext;
@@ -47820,6 +47726,15 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
47820
47726
  }
47821
47727
  }, [sectionproperties]);
47822
47728
  var sectionstyles = {
47729
+ form_control: glamor.css((_css = {
47730
+ position: 'relative',
47731
+ display: 'flex',
47732
+ alignItems: 'center'
47733
+ }, _defineProperty__default["default"](_css, "display", 'block'), _defineProperty__default["default"](_css, "width", '100%'), _defineProperty__default["default"](_css, "padding", '0 30px'), _defineProperty__default["default"](_css, "transition", '.3s'), _defineProperty__default["default"](_css, "fontWeight", 500), _defineProperty__default["default"](_css, "border", '1px solid #e6e6e6'), _defineProperty__default["default"](_css, "borderRadius", '5px'), _defineProperty__default["default"](_css, "height", '38px'), _defineProperty__default["default"](_css, "background", 'transparent'), _defineProperty__default["default"](_css, "color", '#000'), _defineProperty__default["default"](_css, "fontSize", '14px'), _defineProperty__default["default"](_css, ':focus', {
47734
+ // borderColor: sectionproperties.inputfeildbordercoloronfocus,
47735
+ borderColor: '#eac435',
47736
+ boxShadow: 'none'
47737
+ }), _css)),
47823
47738
  btnstyles: glamor.css({
47824
47739
  width: sectionproperties.generalbtn_width + '%',
47825
47740
  height: sectionproperties.generalbtn_height + 'px',
@@ -47835,9 +47750,6 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
47835
47750
  color: sectionproperties.generalbtn_textColoronhover
47836
47751
  }
47837
47752
  }),
47838
- form_control: glamor.css({
47839
- backgroundImage: 'linear-gradient(to top, #eac435 2px, rgba(156, 39, 176, 0) 2px), linear-gradient(to top, #d2d2d2 1px, rgba(210, 210, 210, 0) 1px)'
47840
- }),
47841
47753
  input_label_name: glamor.css({
47842
47754
  color: sectionproperties.form_labelcolor,
47843
47755
  textTransform: sectionproperties.form_labeltexttransform,
@@ -48182,159 +48094,147 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
48182
48094
  "class": "col-lg-12 p-0"
48183
48095
  }, /*#__PURE__*/React__default["default"].createElement("div", {
48184
48096
  "class": "row m-0 w-100 d-flex align-items-center justify-content-start"
48185
- }, /*#__PURE__*/React__default["default"].createElement("div", {
48186
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48187
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48188
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48189
- style: {
48190
- textAlign: langdetect == 'en' ? 'left' : 'right'
48191
- }
48192
- }, langdetect == 'en' ? 'Car Brand' : 'الماركة'), /*#__PURE__*/React__default["default"].createElement("div", {
48193
- "class": 'col-lg-12 p-0'
48194
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48195
- options: [{
48196
- label: 'Tesla',
48197
- value: 1
48198
- }, {
48199
- label: 'VW',
48200
- value: 0
48201
- }, {
48202
- label: 'BYD',
48203
- value: 0
48204
- }],
48205
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48206
- placeholder: ''
48207
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48208
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48209
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48210
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48211
- style: {
48212
- textAlign: langdetect == 'en' ? 'left' : 'right'
48213
- }
48214
- }, langdetect == 'en' ? 'Car Model' : 'النوع'), /*#__PURE__*/React__default["default"].createElement("div", {
48215
- "class": 'col-lg-12 p-0'
48216
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48217
- options: [{
48218
- label: 'ID.4',
48219
- value: 1
48220
- }, {
48221
- label: 'ID.6',
48222
- value: 0
48223
- }],
48224
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48225
- placeholder: ''
48226
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48227
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48228
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48229
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48230
- style: {
48231
- textAlign: langdetect == 'en' ? 'left' : 'right'
48232
- }
48233
- }, langdetect == 'en' ? 'Kilometers (From)' : 'كيلومترات (من)'), /*#__PURE__*/React__default["default"].createElement("div", {
48234
- "class": 'col-lg-12 p-0'
48235
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48236
- options: [{
48237
- label: '100000',
48238
- value: 1
48239
- }, {
48240
- label: '50000',
48241
- value: 0
48242
- }, {
48243
- label: '30000',
48244
- value: 0
48245
- }],
48246
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48247
- placeholder: ''
48248
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48249
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48250
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48251
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48252
- style: {
48253
- textAlign: langdetect == 'en' ? 'left' : 'right'
48254
- }
48255
- }, langdetect == 'en' ? 'Kilometers (To)' : 'كيلومترات (الى)'), /*#__PURE__*/React__default["default"].createElement("div", {
48256
- "class": 'col-lg-12 p-0'
48257
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48258
- options: [{
48259
- label: '100000',
48260
- value: 1
48261
- }, {
48262
- label: '50000',
48263
- value: 0
48264
- }, {
48265
- label: '30000',
48266
- value: 0
48267
- }],
48268
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48269
- placeholder: ''
48270
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48271
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48272
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48273
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48274
- style: {
48275
- textAlign: langdetect == 'en' ? 'left' : 'right'
48276
- }
48277
- }, langdetect == 'en' ? 'Year of built (From)' : 'سنة الصنع (من)'), /*#__PURE__*/React__default["default"].createElement("div", {
48278
- "class": 'col-lg-12 p-0'
48279
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48280
- options: [{
48281
- label: '2023',
48282
- value: 1
48283
- }, {
48284
- label: '2022',
48285
- value: 0
48286
- }, {
48287
- label: '2021',
48288
- value: 0
48289
- }],
48290
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48291
- placeholder: ''
48292
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48293
- "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48294
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48295
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48296
- style: {
48297
- textAlign: langdetect == 'en' ? 'left' : 'right'
48298
- }
48299
- }, langdetect == 'en' ? 'Year of built (To)' : 'سنة الصنع (الى)'), /*#__PURE__*/React__default["default"].createElement("div", {
48300
- "class": 'col-lg-12 p-0'
48301
- }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48302
- options: [{
48303
- label: '2023',
48304
- value: 1
48305
- }, {
48306
- label: '2022',
48307
- value: 0
48308
- }, {
48309
- label: '2021',
48310
- value: 0
48311
- }],
48312
- styles: langdetect == 'en' ? defaultstyles : defaultstylestranslated,
48313
- placeholder: ''
48314
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48315
- className: "".concat(langdetect == 'en' ? 'text-left' : 'text-right') + ' col-lg-3 col-md-12 col-sm-12 mb-3 '
48316
- }, /*#__PURE__*/React__default["default"].createElement("label", {
48317
- className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100',
48318
- style: {
48319
- textAlign: langdetect == 'en' ? 'left' : 'right'
48097
+ }, (fetchProductFeaturesQueryContext === null || fetchProductFeaturesQueryContext === void 0 ? void 0 : fetchProductFeaturesQueryContext.isSuccess) && (fetchProductFeaturesQueryContext === null || fetchProductFeaturesQueryContext === void 0 || (_fetchProductFeatures = fetchProductFeaturesQueryContext.data) === null || _fetchProductFeatures === void 0 || (_fetchProductFeatures = _fetchProductFeatures.data) === null || _fetchProductFeatures === void 0 || (_fetchProductFeatures = _fetchProductFeatures.productfeatues) === null || _fetchProductFeatures === void 0 ? void 0 : _fetchProductFeatures.map(function (item, index) {
48098
+ if (item.type == 'Selectbox') {
48099
+ var _item$featuresselectb;
48100
+ var selectboxarr = [];
48101
+ item === null || item === void 0 || (_item$featuresselectb = item.featuresselectbovalue) === null || _item$featuresselectb === void 0 || _item$featuresselectb.forEach(function (slecitem) {
48102
+ var itemlabel = '';
48103
+ if (langdetect == 'en') {
48104
+ itemlabel = slecitem.value_en;
48105
+ } else {
48106
+ itemlabel = slecitem.value_ar;
48107
+ }
48108
+ selectboxarr.push({
48109
+ label: itemlabel,
48110
+ value: slecitem.value_en
48111
+ });
48112
+ });
48113
+ return /*#__PURE__*/React__default["default"].createElement("div", {
48114
+ "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48115
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
48116
+ className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48117
+ style: {
48118
+ textAlign: langdetect == 'en' ? 'left' : 'right'
48119
+ }
48120
+ }, langdetect == 'en' ? item.name_en : item.name_ar), /*#__PURE__*/React__default["default"].createElement("div", {
48121
+ "class": 'col-lg-12 p-0'
48122
+ }, /*#__PURE__*/React__default["default"].createElement(Select__default["default"], {
48123
+ options: selectboxarr,
48124
+ styles: langdetect == 'en' ? selectcustomStyles : selectcustomStylesTranslated,
48125
+ placeholder: '',
48126
+ onChange: function onChange(e) {
48127
+ var isattrexists = false;
48128
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
48129
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
48130
+ if (attritem.id == item.id) {
48131
+ tempproductfeatuesarr[attrindex].value = e.value;
48132
+ isattrexists = true;
48133
+ }
48134
+ });
48135
+ if (isattrexists == false) {
48136
+ tempproductfeatuesarr.push({
48137
+ id: item.id,
48138
+ value: e.value
48139
+ });
48140
+ }
48141
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
48142
+ }
48143
+ })));
48320
48144
  }
48321
- }, langdetect == 'en' ? 'Price' : 'السعر'), /*#__PURE__*/React__default["default"].createElement("div", {
48322
- "class": 'col-lg-12 pl-4 pr-4 mt-2 mb-2',
48323
- style: {
48324
- direction: 'ltr'
48145
+ if (item.type == 'Number') {
48146
+ return /*#__PURE__*/React__default["default"].createElement("div", {
48147
+ "class": "col-lg-3 col-md-12 d-flex flex-column align-items-center justify-content-start mb-3"
48148
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
48149
+ className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100 ',
48150
+ style: {
48151
+ textAlign: langdetect == 'en' ? 'left' : 'right'
48152
+ }
48153
+ }, langdetect == 'en' ? item.name_en : item.name_ar), /*#__PURE__*/React__default["default"].createElement("div", {
48154
+ "class": 'col-lg-12 p-0 mt-1'
48155
+ }, /*#__PURE__*/React__default["default"].createElement("input", {
48156
+ type: "number",
48157
+ className: "".concat(formstyles.form_control, " ").concat(sectionstyles.form_control),
48158
+ placeholder: '',
48159
+ onChange: function onChange(e) {
48160
+ var isattrexists = false;
48161
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
48162
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
48163
+ if (attritem.id == item.id) {
48164
+ tempproductfeatuesarr[attrindex].value = e.target.value;
48165
+ isattrexists = true;
48166
+ }
48167
+ });
48168
+ if (isattrexists == false) {
48169
+ tempproductfeatuesarr.push({
48170
+ id: item.id,
48171
+ value: e.target.value
48172
+ });
48173
+ }
48174
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
48175
+ }
48176
+ })));
48325
48177
  }
48326
- }, /*#__PURE__*/React__default["default"].createElement(InputRange__default["default"], {
48327
- draggableTrack: true,
48328
- formatLabel: function formatLabel(value) {
48329
- return "".concat(value);
48330
- },
48331
- maxValue: parseInt(sectionproperties.filterpricemaxvalue),
48332
- minValue: parseInt(sectionproperties.filterpriceminvalue),
48333
- value: pricevalue,
48334
- onChange: function onChange(value) {
48335
- setpricevalue(_objectSpread$17({}, value));
48178
+ if (item.type == 'NumberRange') {
48179
+ var temppricevalue = {
48180
+ min: 0,
48181
+ max: 10000
48182
+ };
48183
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
48184
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
48185
+ if (attritem.id == item.id) {
48186
+ var _attritem$value, _attritem$valuemax;
48187
+ if (attritem.value != undefined && attritem.value != null && (attritem === null || attritem === void 0 || (_attritem$value = attritem.value) === null || _attritem$value === void 0 ? void 0 : _attritem$value.length) != 0) {
48188
+ temppricevalue.min = attritem.value;
48189
+ }
48190
+ if (attritem.valuemax != undefined && attritem.valuemax != null && (attritem === null || attritem === void 0 || (_attritem$valuemax = attritem.valuemax) === null || _attritem$valuemax === void 0 ? void 0 : _attritem$valuemax.length) != 0) {
48191
+ temppricevalue.max = attritem.valuemax;
48192
+ }
48193
+ }
48194
+ });
48195
+ return /*#__PURE__*/React__default["default"].createElement("div", {
48196
+ className: "".concat(langdetect == 'en' ? 'text-left' : 'text-right') + ' col-lg-3 col-md-12 col-sm-12 mb-3 '
48197
+ }, /*#__PURE__*/React__default["default"].createElement("label", {
48198
+ className: "".concat(sectionstyles.input_label_name) + ' mb-3 w-100',
48199
+ style: {
48200
+ textAlign: langdetect == 'en' ? 'left' : 'right'
48201
+ }
48202
+ }, langdetect == 'en' ? item.name_en : item.name_ar), /*#__PURE__*/React__default["default"].createElement("div", {
48203
+ "class": 'col-lg-12 pl-4 pr-4 mt-2 mb-2',
48204
+ style: {
48205
+ direction: 'ltr'
48206
+ }
48207
+ }, /*#__PURE__*/React__default["default"].createElement(InputRange__default["default"], {
48208
+ draggableTrack: true,
48209
+ formatLabel: function formatLabel(value) {
48210
+ return "".concat(value);
48211
+ },
48212
+ maxValue: parseInt(sectionproperties.filterpricemaxvalue),
48213
+ minValue: parseInt(sectionproperties.filterpriceminvalue),
48214
+ value: temppricevalue,
48215
+ onChange: function onChange(e) {
48216
+ // setpricevalue({ ...value });
48217
+ var isattrexists = false;
48218
+ var tempproductfeatuesarr = _toConsumableArray__default["default"](productfeatuesarr);
48219
+ tempproductfeatuesarr === null || tempproductfeatuesarr === void 0 || tempproductfeatuesarr.forEach(function (attritem, attrindex) {
48220
+ if (attritem.id == item.id) {
48221
+ tempproductfeatuesarr[attrindex].value = e.min;
48222
+ tempproductfeatuesarr[attrindex].valuemax = e.max;
48223
+ isattrexists = true;
48224
+ }
48225
+ });
48226
+ if (isattrexists == false) {
48227
+ tempproductfeatuesarr.push({
48228
+ id: item.id,
48229
+ value: e.min,
48230
+ valuemax: e.max
48231
+ });
48232
+ }
48233
+ setproductfeatuesarr(_toConsumableArray__default["default"](tempproductfeatuesarr));
48234
+ }
48235
+ })));
48336
48236
  }
48337
- }))), /*#__PURE__*/React__default["default"].createElement("div", {
48237
+ })), /*#__PURE__*/React__default["default"].createElement("div", {
48338
48238
  "class": "col-lg-2 col-md-12 text-end",
48339
48239
  style: {
48340
48240
  marginLeft: langdetect == 'en' ? 'auto' : '',
@@ -48379,6 +48279,9 @@ var BackgroundImageWithTopContent = function BackgroundImageWithTopContent(props
48379
48279
  tempfetchproductsfilerobjcontext.price_max = pricevalue.max;
48380
48280
  }
48381
48281
  }
48282
+ if (productfeatuesarr != undefined && productfeatuesarr != null && Array.isArray(productfeatuesarr) && (productfeatuesarr === null || productfeatuesarr === void 0 ? void 0 : productfeatuesarr.length) != 0) {
48283
+ tempfetchproductsfilerobjcontext.prod_featruesar = productfeatuesarr;
48284
+ }
48382
48285
  if ((sectionproperties === null || sectionproperties === void 0 ? void 0 : sectionproperties.generalbtnonclick) == 'Products') {
48383
48286
  routingcountext(StaticPagesLinksContext.GeneralProductsComponent, true, encodeURIComponent(JSON.stringify(tempfetchproductsfilerobjcontext)));
48384
48287
  }