tabexseriescomponents 0.0.64 → 0.0.66

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.
Files changed (178) hide show
  1. package/dist/index.cjs.js +25023 -16634
  2. package/dist/index.esm.js +25033 -16645
  3. package/dist/index.umd.js +24824 -16437
  4. package/package.json +1 -1
  5. package/src1-10/Contexts/LanguageContext.jsx +347 -0
  6. package/src1-10/Contexts/ProductsCardsSectionContext.jsx +28 -0
  7. package/src1-10/StylesJS/Customstyles.js +235 -0
  8. package/src1-10/TabexComponents/Cards/CategoryCardwithhoveraction/CategoryCardwithhoveraction.jsx +205 -0
  9. package/src1-10/TabexComponents/Cards/Categorycard_fullimage/Categorycard_fullimage.jsx +239 -0
  10. package/src1-10/TabexComponents/Cards/Categorycard_slidebgscaled/Categorycard_slidebgscaled.jsx +198 -0
  11. package/src1-10/TabexComponents/Cards/Categorycard_with_trianglebg/Categorycard_with_trianglebg.jsx +169 -0
  12. package/src1-10/TabexComponents/Cards/Categorycard_with_twolinestransition/Categorycard_with_twolinestransition.jsx +180 -0
  13. package/src1-10/TabexComponents/Cards/Categorycard_withshapes/Categorycard_withshapes.jsx +162 -0
  14. package/src1-10/TabexComponents/Cards/Categorycard_withtext/Categorycard_withtext.jsx +184 -0
  15. package/src1-10/TabexComponents/Cards/Classiccategorycard/Classiccategorycard.jsx +149 -0
  16. package/src1-10/TabexComponents/Cards/Horizontalcard/Horizontalcard.jsx +271 -0
  17. package/src1-10/TabexComponents/Cards/MenuCard/MenuCard.jsx +546 -0
  18. package/src1-10/TabexComponents/Cards/ModernProductCard/ModernProductCard.jsx +474 -0
  19. package/src1-10/TabexComponents/Cards/Productcard6/Productcard6.jsx +290 -0
  20. package/src1-10/TabexComponents/Cards/Productcard7/Productcard7.jsx +278 -0
  21. package/src1-10/TabexComponents/Cards/Productcard_animatedbuttons/Productcard_animatedbuttons.jsx +293 -0
  22. package/src1-10/TabexComponents/Cards/Productcard_with_circularbg/Productcard_with_circularbg.jsx +278 -0
  23. package/src1-10/TabexComponents/Cards/Productcard_with_circularhover/Productcard_with_circularhover.jsx +312 -0
  24. package/src1-10/TabexComponents/Cards/Productcard_with_slideanimation/Productcard_with_slideanimation.jsx +279 -0
  25. package/src1-10/TabexComponents/Cards/Productcard_with_variants/Productcard_with_variants.jsx +293 -0
  26. package/src1-10/TabexComponents/Cards/Productcard_with_zoominonhover/Productcard_with_zoominonhover.jsx +456 -0
  27. package/src1-10/TabexComponents/Cards/Productcarddefault/Productcarddefault.jsx +272 -0
  28. package/src1-10/TabexComponents/Cards/Productccard_with_imageontopleft/Productccard_with_imageontopleft.jsx +286 -0
  29. package/src1-10/TabexComponents/Cards/Prouductcard_with_zoomhover/Prouductcard_with_zoomhover.jsx +127 -0
  30. package/src1-10/TabexComponents/Cards/Simplecategorycardwithtextbelow/Simplecategorycardwithtextbelow.jsx +126 -0
  31. package/src1-10/TabexComponents/Cards/Simpleproductcard/Simpleproductcard.jsx +292 -0
  32. package/src1-10/TabexComponents/Cards/StylishProductCard/StylishProductCard.jsx +281 -0
  33. package/src1-10/TabexComponents/Footer/Footer1/Footer1.jsx +418 -0
  34. package/src1-10/TabexComponents/Footer/Footer2/Footer2.jsx +381 -0
  35. package/src1-10/TabexComponents/Footer/Footer3/Footer3.jsx +316 -0
  36. package/src1-10/TabexComponents/Footer/Footer4/Footer4.jsx +437 -0
  37. package/src1-10/TabexComponents/Footer/Footer5/Footer5.jsx +488 -0
  38. package/src1-10/TabexComponents/Footer/Footer6/Footer6.jsx +286 -0
  39. package/src1-10/TabexComponents/Footer/Footer7/Footer7.jsx +370 -0
  40. package/src1-10/TabexComponents/Footer/Simplefooter/Simplefooter.jsx +231 -0
  41. package/src1-10/TabexComponents/Generalfiles/images/egyptflag.png +0 -0
  42. package/src1-10/TabexComponents/Generalfiles/images/noimage.png +0 -0
  43. package/src1-10/TabexComponents/Generalfiles/images/payment/cod.png +0 -0
  44. package/src1-10/TabexComponents/Generalfiles/images/payment/fawry.png +0 -0
  45. package/src1-10/TabexComponents/Generalfiles/images/payment/payment.png +0 -0
  46. package/src1-10/TabexComponents/Generalfiles/images/payment/paymob.png +0 -0
  47. package/src1-10/TabexComponents/Generalfiles/images/payment/paypal.png +0 -0
  48. package/src1-10/TabexComponents/Generalfiles/images/payment/visa.png +0 -0
  49. package/src1-10/TabexComponents/Generalfiles/images/shoppingcart.png +0 -0
  50. package/src1-10/TabexComponents/Generalfiles/images/tabexlogo.png +0 -0
  51. package/src1-10/TabexComponents/Generalfiles/images/unknownmaleuser.png +0 -0
  52. package/src1-10/TabexComponents/Generalfiles/images/usflag.png +0 -0
  53. package/src1-10/TabexComponents/Generalfiles/images/whatsapp.png +0 -0
  54. package/src1-10/TabexComponents/Headers/AllinoneHeader/AllinoneHeader.jsx +722 -0
  55. package/src1-10/TabexComponents/Headers/ClassicHeader/ClassicHeader.jsx +681 -0
  56. package/src1-10/TabexComponents/Headers/Header4/Header4.jsx +614 -0
  57. package/src1-10/TabexComponents/Headers/Header6/Header6.jsx +666 -0
  58. package/src1-10/TabexComponents/Headers/Header8/Header8.jsx +888 -0
  59. package/src1-10/TabexComponents/Headers/HeaderRestaurant/HeaderRestaurant.jsx +710 -0
  60. package/src1-10/TabexComponents/Headers/Header_threesectionslogocentered/Header_threesectionslogocentered.jsx +769 -0
  61. package/src1-10/TabexComponents/Headers/Headerresponsive/Headerresponsive.jsx +666 -0
  62. package/src1-10/TabexComponents/Headers/HeaderwithContactinfo/HeaderwithContactinfo.jsx +940 -0
  63. package/src1-10/TabexComponents/Headers/Modernheader/Modernheader.jsx +714 -0
  64. package/src1-10/TabexComponents/Headers/StylishHeader/StylishHeader.jsx +833 -0
  65. package/src1-10/TabexComponents/Headers/Subheader/Subheader.jsx +239 -0
  66. package/src1-10/TabexComponents/Sections/BackgroundImages/Backgroundimage1/Backgroundimage1.jsx +312 -0
  67. package/src1-10/TabexComponents/Sections/BackgroundImages/Backgroundimage_with_toppill/Backgroundimage_with_toppill.jsx +278 -0
  68. package/src1-10/TabexComponents/Sections/BackgroundImages/BackgroundimageandTextsection/BackgroundimageandTextsection.jsx +129 -0
  69. package/src1-10/TabexComponents/Sections/BackgroundImages/Section_with_rightbgcont/Section_with_rightbgcont.jsx +153 -0
  70. package/src1-10/TabexComponents/Sections/BackgroundImages/Threebgimages/Threebgimages.jsx +295 -0
  71. package/src1-10/TabexComponents/Sections/BackgroundImages/Twobgimages/Twobgimages.jsx +409 -0
  72. package/src1-10/TabexComponents/Sections/Cards/CardsSection/CardsSection.jsx +793 -0
  73. package/src1-10/TabexComponents/Sections/Cards/CardsSection2/CardsSection2.jsx +486 -0
  74. package/src1-10/TabexComponents/Sections/Cards/CardsSection7/CardsSection7.js +888 -0
  75. package/src1-10/TabexComponents/Sections/Cards/CardsSection8/CardsSection8.js +419 -0
  76. package/src1-10/TabexComponents/Sections/Cards/Sixverticalcardssection/Sixverticalcardssection.jsx +512 -0
  77. package/src1-10/TabexComponents/Sections/Slideshow/AboutSection/AboutSection.jsx +281 -0
  78. package/src1-10/TabexComponents/Sections/Slideshow/Backgroundimage_with_topcircle/Backgroundimage_with_topcircle.jsx +166 -0
  79. package/src1-10/TabexComponents/Sections/Slideshow/Freetextsection/Freetextsection.jsx +152 -0
  80. package/src1-10/TabexComponents/Sections/Slideshow/Image_with_leftwords/Image_with_leftwords.jsx +139 -0
  81. package/src1-10/TabexComponents/Sections/Slideshow/Image_with_rightwords/Image_with_rightwords.jsx +146 -0
  82. package/src1-10/TabexComponents/Sections/Slideshow/Servicesection/Servicesection.jsx +209 -0
  83. package/src1-10/TabexComponents/Sections/Slideshow/ServicesectionCenteredcards/ServicesectionCenteredcards.jsx +145 -0
  84. package/src1-10/TabexComponents/Sections/Slideshow/Slideshow_with_rotatedsquare/Slideshow_with_rotatedsquare.jsx +252 -0
  85. package/src1-10/TabexComponents/Sections/Slideshow/Slideshow_with_squarebg/Slideshow_with_squarebg.jsx +175 -0
  86. package/src1-10/TabexComponents/Sections/Slideshow/Slideshowdifferentanimations/Slideshowdifferentanimations.jsx +154 -0
  87. package/src1-10/TabexComponents/Sections/Slideshow/Slideshowfade/Slideshowfade.jsx +193 -0
  88. package/src1-10/TabexComponents/Sections/Slideshow/Slideshowslide/Slideshowslide.jsx +197 -0
  89. package/src1-10/TabexComponents/Sections/Slideshow/Slideshowzoom/Arrow.js +91 -0
  90. package/src1-10/TabexComponents/Sections/Slideshow/Slideshowzoom/Slideshowzoom.jsx +309 -0
  91. package/src1-10/TabexComponents/StaticPages/AccountInformation/AccountInformation.jsx +260 -0
  92. package/src1-10/TabexComponents/StaticPages/CartSlider/CartSlider.jsx +459 -0
  93. package/src1-10/TabexComponents/StaticPages/Categoriesdropdown/Categoriesdropdown.jsx +216 -0
  94. package/src1-10/TabexComponents/StaticPages/Checkout/Checkout.jsx +1220 -0
  95. package/src1-10/TabexComponents/StaticPages/Filter/Filter.jsx +542 -0
  96. package/src1-10/TabexComponents/StaticPages/Login/FacebookLoginButton.jsx +51 -0
  97. package/src1-10/TabexComponents/StaticPages/Login/GoogleLoginButton.jsx +35 -0
  98. package/src1-10/TabexComponents/StaticPages/Login/Login.jsx +299 -0
  99. package/src1-10/TabexComponents/StaticPages/OrderSuccess/OrderSuccess.js +192 -0
  100. package/src1-10/TabexComponents/StaticPages/Ordershistory/Ordershistory.jsx +1271 -0
  101. package/src1-10/TabexComponents/StaticPages/Policies/Policies.jsx +353 -0
  102. package/src1-10/TabexComponents/StaticPages/Productinfo/Productinfo.jsx +1456 -0
  103. package/src1-10/TabexComponents/StaticPages/Searchlist/Searchlist.jsx +209 -0
  104. package/src1-10/TabexComponents/StaticPages/Signup/CustomerInformationForm.jsx +776 -0
  105. package/src1-10/TabexComponents/StaticPages/Signup/Signup.jsx +157 -0
  106. package/src1-10/TabexComponents/StaticPages/Staticpagesrouter/Staticpagesrouter.jsx +285 -0
  107. package/src1-10/TabexComponents/StaticPages/Viewcart/Viewcart.js +1090 -0
  108. package/src1-10/TabexComponents/StaticPages/Wishlist/Wishlist.jsx +606 -0
  109. package/src1-10/assets/images/cod.png +0 -0
  110. package/src1-10/assets/images/egyptflag.png +0 -0
  111. package/src1-10/assets/images/fawry.png +0 -0
  112. package/src1-10/assets/images/payment.png +0 -0
  113. package/src1-10/assets/images/paymob.png +0 -0
  114. package/src1-10/assets/images/paypal.png +0 -0
  115. package/src1-10/assets/images/shoppingcart.png +0 -0
  116. package/src1-10/assets/images/usflag.png +0 -0
  117. package/src1-10/assets/images/visa.png +0 -0
  118. package/src1-10/assets/images/whatsapp.png +0 -0
  119. package/src1-10/button.jsx +40 -0
  120. package/src1-10/index.jsx +179 -0
  121. package/src1-10/styles/Home.module.css +129 -0
  122. package/src1-10/styles/cards/Categorcycard_fullimage.module.css +10 -0
  123. package/src1-10/styles/cards/Categorycard_slidebgscaled.module.css +73 -0
  124. package/src1-10/styles/cards/Categorycard_withshapes.module.css +189 -0
  125. package/src1-10/styles/cards/Productcard6.module.css +9 -0
  126. package/src1-10/styles/cards/Productcard_with_circularbg.module.css +137 -0
  127. package/src1-10/styles/cards/Productccard_with_zoominonhover.module.css +51 -0
  128. package/src1-10/styles/cards/Prouductcard_with_zoomhover.module.css +61 -0
  129. package/src1-10/styles/cards/categorycard.module.css +102 -0
  130. package/src1-10/styles/cards/categorycard3.module.css +51 -0
  131. package/src1-10/styles/cards/categorycardwithtext.module.css +40 -0
  132. package/src1-10/styles/cards/productcard_animatedbuttons.module.css +104 -0
  133. package/src1-10/styles/cards/productcard_with_textonhover.module.css +12 -0
  134. package/src1-10/styles/cards/productccard_with_imageontopleft.module.css +85 -0
  135. package/src1-10/styles/general/bootstrap.css +4415 -0
  136. package/src1-10/styles/general/dropdown.css +199 -0
  137. package/src1-10/styles/general/editorbardropdown.module.css +94 -0
  138. package/src1-10/styles/general/filter.module.css +108 -0
  139. package/src1-10/styles/general/form.module.css +273 -0
  140. package/src1-10/styles/general/general.module.css +861 -0
  141. package/src1-10/styles/general/image-gallery.css +481 -0
  142. package/src1-10/styles/general/react-accessible-accordion.module.css +52 -0
  143. package/src1-10/styles/general/react-phone-input-2.module.css +927 -0
  144. package/src1-10/styles/general/scrollbtn.module.css +22 -0
  145. package/src1-10/styles/general/slick.module.css +166 -0
  146. package/src1-10/styles/general/tabs.module.css +110 -0
  147. package/src1-10/styles/general/workplaceeditor.module.css +328 -0
  148. package/src1-10/styles/globals.css +26 -0
  149. package/src1-10/styles/headers/Allinoneheader.module.css +91 -0
  150. package/src1-10/styles/headers/Header7.module.css +50 -0
  151. package/src1-10/styles/headers/Header_threesectionslogocentered.module.css +97 -0
  152. package/src1-10/styles/headers/Sideheader.module.css +108 -0
  153. package/src1-10/styles/headers/classicheaderstyles.module.css +16 -0
  154. package/src1-10/styles/headers/dropdown.css +0 -0
  155. package/src1-10/styles/headers/header4.module.css +175 -0
  156. package/src1-10/styles/headers/header5.module.css +30 -0
  157. package/src1-10/styles/headers/header6.module.css +117 -0
  158. package/src1-10/styles/headers/header_contactinfo.module.css +78 -0
  159. package/src1-10/styles/headers/headerresturant.module.css +89 -0
  160. package/src1-10/styles/headers/headerstyles.module.css +24 -0
  161. package/src1-10/styles/headers/modernheader.module.css +78 -0
  162. package/src1-10/styles/headers/subheader.module.css +114 -0
  163. package/src1-10/styles/sections/Backgroundimage1.module.css +17 -0
  164. package/src1-10/styles/sections/Backgroundimage_with_topcircle.module.css +28 -0
  165. package/src1-10/styles/sections/Section_with_rightbgcont.module.css +49 -0
  166. package/src1-10/styles/sections/Slideshow_with_rotatedsquare.module.css +35 -0
  167. package/src1-10/styles/sections/Slideshow_with_squarebg.module.css +39 -0
  168. package/src1-10/styles/staticpages/accordion.module.css +9 -0
  169. package/src1-10/styles/staticpages/cart.module.css +108 -0
  170. package/src1-10/styles/staticpages/dropdown.css +196 -0
  171. package/src1-10/styles/staticpages/filter.module.css +139 -0
  172. package/src1-10/styles/staticpages/login.module.css +146 -0
  173. package/src1-10/styles/staticpages/productinfo.module.css +54 -0
  174. package/src1-10/styles/staticpages/shop.module.css +191 -0
  175. package/src1-10/styles/staticpages/signup.module.css +206 -0
  176. package/src1-10/styles/staticpages/staticroutersidenav.module.css +129 -0
  177. package/src1-10/styles/staticpages/viewcart.module.css +129 -0
  178. package/src1-10/styles/staticpages/wishlist.module.css +29 -0
@@ -0,0 +1,459 @@
1
+ import React, { useEffect, useState, useContext } from 'react';
2
+ import cartstyles from '../../../styles/staticpages/cart.module.css';
3
+ import { IoMdClose } from 'react-icons/io';
4
+ import { HiOutlineTrash } from 'react-icons/hi';
5
+ import { CircularProgress } from 'react-cssfx-loading';
6
+ import { Offcanvas } from 'react-bootstrap';
7
+
8
+ import { css } from 'glamor';
9
+ import { IKImage } from 'imagekitio-react';
10
+ import shoppingcart from '../../../assets/images/shoppingcart.png';
11
+ import { FiShoppingCart } from 'react-icons/fi';
12
+ import { MdOutlineShoppingCart } from 'react-icons/md';
13
+ import { FiShoppingBag } from 'react-icons/fi';
14
+ import { CgShoppingBag } from 'react-icons/cg';
15
+ import { BsBag } from 'react-icons/bs';
16
+ import { IoBagHandleOutline } from 'react-icons/io5';
17
+ import { IKpublicKey, IKurlEndpoint } from '../../../../Env';
18
+ const CartSlider = (props) => {
19
+ const lang = props.actions.lang;
20
+ const langdetect = props.actions.langdetect;
21
+ const templatepropcontext = props.actions.templatepropcontext;
22
+ const routingcountext = props.actions.routingcountext;
23
+ const StaticPagesLinksContext = props.actions.StaticPagesLinksContext;
24
+ const fetchcustomercartQueryContext = props.actions.fetchcustomercartQueryContext;
25
+ const AddtoCartMutationContext = props.actions.AddtoCartMutationContext;
26
+ const deletecartitemContext = props.actions.deletecartitemContext;
27
+ const sidecartnavshowcontext = props.actions.sidecartnavshowcontext;
28
+ const setsidecartnavshowcontext = props.actions.setsidecartnavshowcontext;
29
+ const StatePagePropertiesContext = props.actions.StatePagePropertiesContext;
30
+ const CurrentSrcTypeContext = props.actions.CurrentSrcTypeContext;
31
+ const setsidecartnavshowWorkplaceDesigncontext = props.actions.setsidecartnavshowWorkplaceDesigncontext;
32
+ const sidecartnavshowWorkplaceDesigncontext = props.actions.sidecartnavshowWorkplaceDesigncontext;
33
+ const [OpenCloseCartSlider, setOpenCloseCartSlider] = useState(false);
34
+ const [sectionproperties, setsectionproperties] = useState('');
35
+ const [CurrentPageId, setCurrentPageId] = useState('');
36
+ const [fetchingtype, setfetchingtype] = useState('');
37
+ const [ProductsFetchingTypeSectionObj, setProductsFetchingTypeSectionObj] = useState({ productfetchingtype: 'Random', collectionid: '' });
38
+
39
+ useEffect(() => {
40
+ if (CurrentSrcTypeContext == 'workplace') {
41
+ setOpenCloseCartSlider(sidecartnavshowWorkplaceDesigncontext);
42
+ setOpenCloseCartSlider(sidecartnavshowcontext);
43
+ } else {
44
+ setOpenCloseCartSlider(sidecartnavshowcontext);
45
+ }
46
+ // alert(CurrentSrcTypeContext);
47
+ }, [sidecartnavshowcontext, sidecartnavshowWorkplaceDesigncontext]);
48
+ useEffect(() => {
49
+ var cartindex = templatepropcontext.pagesnprop.findIndex((x) => x.staticpageid == '6218bccb801d0');
50
+ if (cartindex >= 0) {
51
+ setCurrentPageId(cartindex);
52
+ }
53
+ }, [templatepropcontext]);
54
+ useEffect(() => {
55
+ var secpropobj = {};
56
+
57
+ templatepropcontext?.pagesnprop[CurrentPageId]?.pageproperties?.forEach(function (arrayItem, arrayindex) {
58
+ secpropobj[arrayItem.property_css_name] = arrayItem.property_value;
59
+ });
60
+ setsectionproperties({ ...secpropobj });
61
+ }, [CurrentPageId]);
62
+ useEffect(() => {
63
+ if (CurrentSrcTypeContext == 'workplace') {
64
+ if (StatePagePropertiesContext != null && StatePagePropertiesContext != undefined && StatePagePropertiesContext.length != 0) {
65
+ var secpropobj = {};
66
+ StatePagePropertiesContext?.pageobj?.pageproperties?.forEach(function (arrayItem, arrayindex) {
67
+ secpropobj[arrayItem.property_css_name] = arrayItem.property_value;
68
+ });
69
+ setsectionproperties({ ...secpropobj });
70
+ }
71
+ }
72
+ }, [StatePagePropertiesContext]);
73
+ const cart_cssstyles = {
74
+ productNameStyles: css({
75
+ color: sectionproperties.prodNameColor,
76
+ fontSize: sectionproperties.prodNameFontSize + 'px',
77
+ fontWeight: sectionproperties.texthover_productcard_fontWeight,
78
+ textTransform: sectionproperties.prodNameTextTranform,
79
+ fontWeight: sectionproperties.prodNameFontWeight,
80
+ }),
81
+ productPricestyles: css({
82
+ fontSize: sectionproperties.prodpriceFontSize + 'px',
83
+ fontWeight: sectionproperties.prodPriceFontWeight,
84
+ color: sectionproperties.prodPriceColor,
85
+ }),
86
+ close_menu_icon_cont: css({
87
+ background: sectionproperties.closeSliderBgColor,
88
+ width: sectionproperties.closeSliderWidth + 'px',
89
+ height: sectionproperties.closeSliderHeight + 'px',
90
+ borderRadius: sectionproperties.closeSlider_borderBottomLeftRadius + 'px',
91
+ left: sectionproperties.closeSliderLeft + '%',
92
+ color: sectionproperties.closeSlider_color,
93
+ fontSize: sectionproperties.closeSlider_fontSize + 'px',
94
+ ':hover': {
95
+ background: sectionproperties.closeSliderBgColorHover,
96
+ },
97
+ }),
98
+ cart_btn: css({
99
+ width: sectionproperties.cartBtnWidth + 'px',
100
+ height: sectionproperties.cartBtnHeight + 'px',
101
+ background: sectionproperties.cartbtn_bgtransparent == 'Transparent' ? 'transparent' : sectionproperties.cartBtnbgColor,
102
+ borderRadius: sectionproperties.cart_btn_borderBottomLeftRadius + 'px',
103
+ color: sectionproperties.cartBtnTextcolor,
104
+ fontSize: sectionproperties.cartBtnTextfontsize + 'px',
105
+ // fontSize: sectionproperties.cartBtn_iconFontSize + 'px',
106
+ textTransform: sectionproperties.cartBtnTexttransform,
107
+ fontWeight: sectionproperties.cartBtnTextfontweight,
108
+ border: sectionproperties.cartbtnborderwidth + 'px solid ' + sectionproperties.cartbtnbordercolor,
109
+ transition: '.3s',
110
+ ':hover': {
111
+ background: sectionproperties.cartbtn_transparentbgcoloronhover == 'Transparent' ? 'transparent' : sectionproperties.cartBtnbgColoronhover,
112
+ color: sectionproperties.cartBtnTextcoloronhover,
113
+ },
114
+ }),
115
+ checkoutbtn: css({
116
+ background: sectionproperties.checkoutBtnbgColortranparent == 'Transparent' ? 'transparent' : sectionproperties.checkoutBtnbgColor,
117
+ width: sectionproperties.checkoutBtnWidth,
118
+ height: sectionproperties.checkoutBtnHeight,
119
+ borderRadius: sectionproperties.checkout_borderBottomLeftRadius + 'px',
120
+ color: sectionproperties.checkoutBtnTextcolor,
121
+ textTransform: sectionproperties.checkoutBtnTexttransform,
122
+ fontWeight: sectionproperties.checkoutBtnTextfontweight,
123
+ fontSize: sectionproperties.checkoutBtnTextfontsize + 'px',
124
+ boxShadow: sectionproperties.checkoutBtn_showshadow == 'Show' ? '0 0 10px ' + sectionproperties.checkoutBtn_shadowcolor : '',
125
+ border: sectionproperties.checkoutBtn_borderwidth + 'px solid ' + sectionproperties.checkoutBtn_bordercolor,
126
+ opacity: sectionproperties.checkoutBtn_opacity,
127
+ transition: '.3s',
128
+ ':hover': {
129
+ background: sectionproperties.checkoutBtnbgColoronhover_tranparent == 'Transparent' ? 'transparent' : sectionproperties.checkoutBtnbgColoronhover,
130
+ color: sectionproperties.checkoutBtnTextcoloronhover,
131
+ opacity: sectionproperties.checkoutbtn_opacityonhover,
132
+ },
133
+ }),
134
+ trash_btn: css({
135
+ width: sectionproperties.trashbtn_Width + 'px',
136
+ height: sectionproperties.trashbtn_Height + 'px',
137
+ background: sectionproperties.trashbtn_bgColortransparent == 'Transparent' ? 'transparent' : sectionproperties.trashbtn_bgColor,
138
+ color: sectionproperties.trashbtn_Textcolor,
139
+ borderRadius: sectionproperties.trashbtn_borderBottomLeftRadius + 'px',
140
+ transition: '.3s',
141
+ border: sectionproperties.trashbtn_borderwidth + 'px solid ' + sectionproperties.trashbtn_bordercolor,
142
+ // trashbtn_fontSize
143
+ ':hover': {
144
+ background: sectionproperties.trashbtn_bgColoronhover,
145
+ color: sectionproperties.trashbtn_Textcoloronhover,
146
+ },
147
+ }),
148
+ imagecont: css({
149
+ // width: '7vh',
150
+ // height: '7vh',
151
+ // border: '2px solid #e6e6e6',
152
+ width: sectionproperties.prodimage_width + 'px',
153
+ height: sectionproperties.prodimage_height + 'px',
154
+ border: sectionproperties.prodimage_borderwidth + 'px solid ' + sectionproperties.prodimage_color,
155
+ backgroundColor: sectionproperties.prodimage_bgcolor,
156
+ borderBottomLeftRadius: sectionproperties.prodimage__borderBottomLeftRadius + 'px',
157
+ borderBottomRightRadius: sectionproperties.prodimage__borderBottomRightRadius + 'px',
158
+ borderTopLeftRadius: sectionproperties.prodimage__borderTopLeftRadius + 'px',
159
+ borderTopRightRadius: sectionproperties.prodimage__borderTopRightRadius + 'px',
160
+ display: 'flex',
161
+ alignItems: 'center',
162
+ justifyContent: 'center',
163
+ backgroundRepeat: 'no-repeat',
164
+ backgroundSize: 'cover',
165
+ backgroundPosition: 'center',
166
+ position: 'relative',
167
+ }),
168
+ };
169
+ return (
170
+ <div className="col-lg-12" style={{ zIndex: 2000 }}>
171
+ {sectionproperties.length != 0 && (
172
+ <Offcanvas
173
+ show={OpenCloseCartSlider}
174
+ onHide={() => {
175
+ setOpenCloseCartSlider(false);
176
+ setsidecartnavshowWorkplaceDesigncontext(false);
177
+ setsidecartnavshowcontext(false);
178
+ }}
179
+ placement="end"
180
+ scroll={true}
181
+ style={{
182
+ minWidth: sectionproperties.width + 'px',
183
+ backgroundColor: sectionproperties.backgroundColor,
184
+ height: sectionproperties.height + 'vh',
185
+ borderBottomLeftRadius: sectionproperties.borderBottomLeftRadius + 'px',
186
+ borderBottomRightRadius: sectionproperties.borderBottomRightRadius + 'px',
187
+ borderTopLeftRadius: sectionproperties.borderTopLeftRadius + 'px',
188
+ borderTopRightRadius: sectionproperties.borderTopRightRadius + 'px',
189
+ }}
190
+ backdrop={CurrentSrcTypeContext == 'workplace' ? false : true}
191
+ >
192
+ <Offcanvas.Header>
193
+ <Offcanvas.Title>
194
+ <div className="row m-0 w-100 mt-2">
195
+ <div
196
+ className={' col-lg-12 d-flex align-items-center justify-content-center '}
197
+ style={{
198
+ fontSize: sectionproperties.sectionTitleFontSize + 'px',
199
+ color: sectionproperties.sectionTitleColor,
200
+ marginTop: sectionproperties.sectionTitleMarginTop + 'px',
201
+ marginBottom: sectionproperties.sectionTitleMarginBottom + 'px',
202
+ marginLeft: sectionproperties.sectionTitleMarginLeft + 'px',
203
+ marginRight: sectionproperties.sectionTitleMarginRight + 'px',
204
+ textTransform: sectionproperties.sectionTitleTextTransform,
205
+ fontWeight: sectionproperties.sectionTitleFontWeight,
206
+ // justifyContent: sectionproperties.sectiontitleposition == 'Centered' ? 'center' : '',
207
+ }}
208
+ >
209
+ {langdetect == 'en' ? 'My Cart' : 'حقيبة التسوق'}
210
+ </div>
211
+ <div className="col-lg-12">
212
+ <hr className="mt-2 mb-2" />
213
+ </div>
214
+ </div>
215
+ </Offcanvas.Title>
216
+ </Offcanvas.Header>
217
+ <Offcanvas.Body>
218
+ {fetchcustomercartQueryContext?.data?.data?.status && (
219
+ <div className={`${cartstyles.cartslider_container} `}>
220
+ <div
221
+ className={`${cartstyles.close_menu_icon_cont} ${cart_cssstyles.close_menu_icon_cont}`}
222
+ onClick={() => {
223
+ setOpenCloseCartSlider(false);
224
+ setsidecartnavshowWorkplaceDesigncontext(false);
225
+ setsidecartnavshowcontext(false);
226
+ }}
227
+ >
228
+ <i
229
+ className="h-100 d-flex align-items-center justify-content-center"
230
+ style={{ cursor: 'pointer' }}
231
+ onClick={() => {
232
+ setOpenCloseCartSlider(false);
233
+ setsidecartnavshowWorkplaceDesigncontext(false);
234
+ setsidecartnavshowcontext(false);
235
+ }}
236
+ >
237
+ <IoMdClose />
238
+ </i>
239
+ </div>
240
+ <div className="row m-0 w-100 ">
241
+ {AddtoCartMutationContext.isLoading && (
242
+ <div className="col-lg-12 d-flex justify-content-center ">
243
+ <div style={{ backgroundColor: 'white', height: '100vh', zIndex: 99999, width: '100%', position: 'absolute', right: 0, top: 0, opacity: 0.5 }}>
244
+ <div className="m-auto mx-auto">
245
+ <CircularProgress color="black" width="40px" height="40px" duration="1s" />
246
+ </div>
247
+ </div>
248
+ </div>
249
+ )}
250
+ <div className="col-lg-12 pt-4">
251
+ {fetchcustomercartQueryContext?.data?.data?.customercart != null && (
252
+ <div className="row m-0 w-100">
253
+ {fetchcustomercartQueryContext?.data?.data?.customercart != null && (
254
+ <div className="row m-0 w-100">
255
+ {fetchcustomercartQueryContext?.data?.data?.customercart?.cartitems == 0 && (
256
+ <div className="row m-0 w-100 d-flex align-items-center justify-content-center" style={{ height: '40vh' }}>
257
+ <div className="col-lg-12 d-flex align-items-center justify-content-center text-light flex-column">
258
+ <img src={shoppingcart} style={{ maxWidth: '200px', maxHeight: '200px' }} />
259
+ <p className="font-weight-500" style={{ fontSize: '15px' }}>
260
+ {lang.emptyshoppingcart}
261
+ </p>
262
+ </div>
263
+ <div className="col-lg-12 d-flex align-items-center justify-content-center text-light flex-column">
264
+ <button
265
+ className={` ${cart_cssstyles.cart_btn}` + ' mr-1 ml-1 d-flex align-items-center justify-content-center '}
266
+ onClick={() => {
267
+ if (fetchingtype == 'products') {
268
+ if (ProductsFetchingTypeSectionObj.productfetchingtype == 'Collection') {
269
+ routingcountext(
270
+ StaticPagesLinksContext.GeneralProductsComponent,
271
+ true,
272
+ ProductsFetchingTypeSectionObj.collectionid,
273
+ );
274
+ } else {
275
+ routingcountext(StaticPagesLinksContext.GeneralProductsComponent, false);
276
+ }
277
+ } else {
278
+ routingcountext(StaticPagesLinksContext.GeneralProductsComponent, false);
279
+ }
280
+ }}
281
+ >
282
+ <i className={langdetect == 'en' ? 'h-100 d-flex align-items-center mr-2' : 'h-100 d-flex align-items-center ml-2'}>
283
+ <FiShoppingCart size={sectionproperties.cartBtn_iconFontSize} />
284
+ </i>
285
+ {lang.shopnow}
286
+ </button>
287
+ </div>
288
+ </div>
289
+ )}
290
+ {fetchcustomercartQueryContext?.data?.data?.customercart?.cartitems?.map((item, index) => {
291
+ return (
292
+ <div className="col-lg-12 mb-3 p-0">
293
+ <div className="row w-100 m-0">
294
+ <div className={'col-lg-2 col-md-2 col-sm-2 p-0 '}>
295
+ <div className={cart_cssstyles.imagecont}>
296
+ <IKImage
297
+ urlEndpoint={IKurlEndpoint}
298
+ publicKey={IKpublicKey}
299
+ path={
300
+ item.productinfo.hasvariants == 0
301
+ ? item.productinfo.productmainimage
302
+ : item.productinfo.variantinfo.variantimageurl
303
+ }
304
+ loading="lazy"
305
+ style={{
306
+ height: '100%',
307
+ width: '100%',
308
+ objectFit: 'cover',
309
+ }}
310
+ />
311
+ </div>
312
+ </div>
313
+ <div className="col-lg-8 col-md-8 col-sm-8 pl-2 pl-sm-3">
314
+ <div className="row m-0 w-100">
315
+ <div className="col-lg-12 col-md-12 col-sm-12 p-0 d-flex">
316
+ <p className={`${cart_cssstyles.productNameStyles}` + ' m-0 p-0 wordbreak d-flex align-items-start '}>
317
+ {langdetect == 'en' ? item.productinfo.name_en : item.productinfo.name_ar}
318
+ </p>
319
+ </div>
320
+ <div className={`${cart_cssstyles.productPricestyles}` + ' col-lg-12 col-md-12 col-sm-12 p-0 d-flex '}>
321
+ {item.quantity} x
322
+ <span className={'ml-1 mr-1 wordbreak'}>
323
+ {/* {item.productinfo.hasvariants == 1 ? item.productinfo.variantinfo.variantsaleprice : item.productinfo.defaultsaleprice}{' '} */}
324
+
325
+ {item.productinfo.hasvariants == 0 && (
326
+ <>
327
+ {item.productinfo.hassale == 1 && (
328
+ <span className="wordbreak">
329
+ {langdetect == 'en' ? 'EGP' : ''} {item.productinfo.defaultsaleprice}{' '}
330
+ {langdetect == 'en' ? '' : 'ج.م'}
331
+ </span>
332
+ )}
333
+ {item.productinfo.hassale == 0 && (
334
+ <span className="wordbreak">
335
+ {langdetect == 'en' ? 'EGP' : ''} {item.productinfo.defaultprice}{' '}
336
+ {langdetect == 'en' ? '' : 'ج.م'}
337
+ </span>
338
+ )}
339
+ </>
340
+ )}
341
+ {item.productinfo.hasvariants == 1 && (
342
+ <>
343
+ {item.productinfo.variantinfo.hassale == 1 && (
344
+ <span className="wordbreak">
345
+ {langdetect == 'en' ? 'EGP' : ''} {item.productinfo.variantinfo.variantsaleprice}{' '}
346
+ {langdetect == 'en' ? '' : 'ج.م'}
347
+ </span>
348
+ )}
349
+ {item.productinfo.variantinfo.hassale == 0 && (
350
+ <span className="wordbreak">
351
+ {langdetect == 'en' ? 'EGP' : ''} {item.productinfo.variantinfo.variantprice}{' '}
352
+ {langdetect == 'en' ? '' : 'ج.م'}
353
+ </span>
354
+ )}
355
+ </>
356
+ )}
357
+ </span>
358
+ </div>
359
+ </div>
360
+ </div>
361
+ <div className="col-lg-2 col-md-2 col-sm-2 p-0 d-flex justify-content-end">
362
+ <button
363
+ className={`${cart_cssstyles.trash_btn}` + ' d-flex align-items-center justify-content-center '}
364
+ style={{}}
365
+ onClick={() => {
366
+ deletecartitemContext(item);
367
+ }}
368
+ >
369
+ <HiOutlineTrash size={sectionproperties.trashbtn_fontSize} />
370
+ </button>
371
+ </div>
372
+ </div>
373
+ <div className="col-lg-12 mt-3 p-0">
374
+ <hr className="m-0" />
375
+ </div>
376
+ </div>
377
+ );
378
+ })}
379
+ {fetchcustomercartQueryContext?.data?.data?.customercart?.cartitems?.length != 0 && (
380
+ <div className="col-lg-12 mb-3 p-0">
381
+ <div className="row m-0 w-100">
382
+ <div className="col-lg-6 col-md-6 col-sm-6 p-0 d-flex justify-content-start">
383
+ <p
384
+ className={'p-0 m-0 '}
385
+ style={{
386
+ fontSize: sectionproperties.total_fontsize + 'px',
387
+ fontWeight: sectionproperties.total_fontweight,
388
+ textTransform: sectionproperties.total_texttransform,
389
+ color: sectionproperties.total_color,
390
+ }}
391
+ >
392
+ {lang.total}
393
+ </p>
394
+ </div>
395
+ <div className="col-lg-6 col-md-6 col-sm-6 d-flex justify-content-end p-0">
396
+ <p
397
+ className={langdetect == 'en' ? ' p-0 m-0 wordbreak text-right ' : ' p-0 m-0 wordbreak text-left'}
398
+ style={{
399
+ fontSize: sectionproperties.total_fontsize + 'px',
400
+ fontWeight: sectionproperties.total_fontweight,
401
+ textTransform: sectionproperties.total_texttransform,
402
+ color: sectionproperties.total_color,
403
+ }}
404
+ >
405
+ {langdetect == 'en' ? 'EGP' : ''} {fetchcustomercartQueryContext?.data?.data?.customercart?.totalprice}{' '}
406
+ {langdetect == 'en' ? '' : 'ج.م'}
407
+ </p>
408
+ </div>
409
+ </div>
410
+ </div>
411
+ )}
412
+ </div>
413
+ )}
414
+ </div>
415
+ )}
416
+ </div>
417
+ {fetchcustomercartQueryContext?.data?.data?.customercart?.cartitems?.length != 0 && (
418
+ <div className="col-lg-12 d-flex align-items-center justify-content-center">
419
+ <button
420
+ className={` ${cart_cssstyles.cart_btn}` + ' mr-1 ml-1 d-flex align-items-center justify-content-center '}
421
+ onClick={() => {
422
+ routingcountext(StaticPagesLinksContext.viewcart);
423
+ }}
424
+ >
425
+ <i className={langdetect == 'en' ? 'h-100 d-flex align-items-center mr-2' : 'h-100 d-flex align-items-center ml-2'}>
426
+ {sectionproperties.carticonstyle == 'Shopping bag 1' && <FiShoppingBag className="" size={sectionproperties.cartBtn_iconFontSize} />}
427
+ {sectionproperties.carticonstyle == 'Shopping bag 2' && <CgShoppingBag className="" size={sectionproperties.cartBtn_iconFontSize} />}
428
+ {sectionproperties.carticonstyle == 'Shopping bag 3' && <BsBag className="" size={sectionproperties.cartBtn_iconFontSize} />}
429
+ {sectionproperties.carticonstyle == 'Shopping bag 4' && <IoBagHandleOutline className="" size={sectionproperties.cartBtn_iconFontSize} />}
430
+ {sectionproperties.carticonstyle == 'Shopping cart 1' && <FiShoppingCart className="" size={sectionproperties.cartBtn_iconFontSize} />}
431
+ {sectionproperties.carticonstyle == 'Shopping cart 2' && <MdOutlineShoppingCart size={sectionproperties.cartBtn_iconFontSize} />}
432
+ </i>
433
+ {lang.viewcart}
434
+ </button>
435
+ <button
436
+ className={` ${cart_cssstyles.checkoutbtn}` + ' ml-1 mr-1 '}
437
+ onClick={() => {
438
+ // if (fetchAuthorizationQueryContext.data.data.loggedin == true) {
439
+ routingcountext(StaticPagesLinksContext.Checkout);
440
+ // } else {
441
+ // NotificationManager.warning('', 'Please Login To Checkout');
442
+ // routingcountext(StaticPagesLinksContext.Login);
443
+ // }
444
+ }}
445
+ >
446
+ {lang.checkout}
447
+ </button>
448
+ </div>
449
+ )}
450
+ </div>
451
+ </div>
452
+ )}
453
+ </Offcanvas.Body>
454
+ </Offcanvas>
455
+ )}
456
+ </div>
457
+ );
458
+ };
459
+ export default CartSlider;