update 97 files

master
Reza_ashrafi 2 years ago
parent 3979d86209
commit 28500ff68c
  1. 2
      src/components/BottomNavigation/index.js
  2. 14
      src/components/Comments/index.js
  3. 8
      src/components/CourseChapter/index.js
  4. 4
      src/components/Dialog/index.js
  5. 6
      src/components/Drawer/index.js
  6. 4
      src/components/Footer/index.js
  7. 2
      src/components/Header/index.js
  8. 266
      src/components/Navbar/index.js
  9. 2
      src/components/OR/index.js
  10. 2
      src/components/ProductImage/index.js
  11. 24
      src/components/ProductStatusCard/index.js
  12. 6
      src/components/ProductSuggestion/index.js
  13. 2
      src/components/ProductTab/index.js
  14. 22
      src/components/QandA/index.js
  15. 4
      src/components/VerticalExpandableProductFilter/index.js
  16. 4
      src/redux/actions/blog.js
  17. 6
      src/redux/actions/config.js
  18. 3
      src/redux/actions/index.js
  19. 16
      src/redux/reducers/blog.js
  20. 16
      src/redux/reducers/config.js
  21. 3
      src/redux/reducers/index.js
  22. 55
      src/router.js
  23. 7
      src/views/About/index.js
  24. 4
      src/views/About/index.scss
  25. 2
      src/views/Activation/components/Alert.js
  26. 14
      src/views/Address/index.js
  27. 4
      src/views/Auth/Profile/index.js
  28. 4
      src/views/Auth/SignUp/index.js
  29. 2
      src/views/Blog/index.js
  30. 185
      src/views/Blogs/index.js
  31. 45
      src/views/Blogs/layouts/Blog.js
  32. 23
      src/views/Blogs/layouts/Hashtags.js
  33. 2
      src/views/Blogs/layouts/Join.js
  34. 2
      src/views/Blogs/layouts/Single.js
  35. 6
      src/views/Blogs/layouts/Target.js
  36. 2
      src/views/Contact/index.js
  37. 2
      src/views/Contact/layouts/Info.js
  38. 2
      src/views/Dashboard/index.js
  39. 6
      src/views/Dashboard/layouts/Main/Addresses/index.js
  40. 2
      src/views/Dashboard/layouts/Mobile/List.js
  41. 4
      src/views/Dashboard/layouts/Mobile/ProfileAddress/index.js
  42. 4
      src/views/Dashboard/layouts/Mobile/Trophy.js
  43. 4
      src/views/Dashboard/layouts/Mobile/User.js
  44. 8
      src/views/Dashboard/layouts/SidebarMenu/index.js
  45. 12
      src/views/DeliveryForm/Address/index.js
  46. 2
      src/views/DeliveryForm/PaymentMethod/index.js
  47. 4
      src/views/DeliveryForm/TransportDate/index.js
  48. 2
      src/views/DeliveryForm/TransportMethod/index.js
  49. 14
      src/views/DeliveryForm/index.js
  50. 2
      src/views/Faq/components/NotFound.js
  51. 2
      src/views/Faq/components/Question.js
  52. 2
      src/views/Faq/index.js
  53. 2
      src/views/Favorites/index.js
  54. 2
      src/views/Home/Desktop/Part2/index.js
  55. 2
      src/views/Home/Desktop/Part4/index.js
  56. 2
      src/views/Home/Desktop/SalesContainer/index.js
  57. 2
      src/views/Home/Landscape/Page1/Lights/index.js
  58. 6
      src/views/Home/Landscape/Page1/index.js
  59. 2
      src/views/Home/Landscape/Page2/Mobile/QrResult/Link/index.js
  60. 2
      src/views/Home/Landscape/Page2/Mobile/QrResult/PDF/index.js
  61. 4
      src/views/Home/Landscape/Page2/Mobile/QrResult/index.js
  62. 2
      src/views/Home/Landscape/Page3/index.js
  63. 2
      src/views/Home/Landscape/Page4/index.js
  64. 2
      src/views/Home/Landscape/Test/Question.js
  65. 6
      src/views/Home/Landscape/Test/index.js
  66. 4
      src/views/Home/Landscape/VideoTube/LessonPlayList/index.js
  67. 4
      src/views/Home/Landscape/VideoTube/index.js
  68. 12
      src/views/Home/Portrait/Private/Blogs/index.js
  69. 2
      src/views/Home/Portrait/Private/MyBooks/index.js
  70. 4
      src/views/Home/Portrait/Private/Videos/index.js
  71. 2
      src/views/Home/Portrait/Public/Features/index.js
  72. 4
      src/views/Home/Portrait/Public/Header/index.js
  73. 2
      src/views/Home/Portrait/Public/Platforms/index.js
  74. 4
      src/views/Home/Portrait/Public/Responsive/index.js
  75. 6
      src/views/Order/components/Book.js
  76. 34
      src/views/Order/index.js
  77. 12
      src/views/Orders/components/Order.js
  78. 4
      src/views/Product/Comment/index.js
  79. 6
      src/views/Product/Desktop/ProductOverAll/index.js
  80. 2
      src/views/Product/Rate/index.js
  81. 10
      src/views/Product/index.js
  82. 4
      src/views/Products/index.js
  83. 2
      src/views/Products/layouts/Desktop/Main.js
  84. 6
      src/views/Products/layouts/Desktop/Sidebar.js
  85. 2
      src/views/Products/layouts/Mobile/Header.js
  86. 6
      src/views/Products/layouts/Mobile/Main.js
  87. 2
      src/views/QR/Content/components/Links.js
  88. 2
      src/views/QR/Content/components/PDF.js
  89. 2
      src/views/QR/Content/components/Tab.js
  90. 2
      src/views/ShoppingCart/Code/index.js
  91. 14
      src/views/ShoppingCart/Product/index.js
  92. 20
      src/views/ShoppingCart/index.js
  93. 2
      src/views/Video/components/Desktop/Videos.js
  94. 4
      src/views/Video/components/Season.js
  95. 12
      src/views/Video/index.js
  96. 8
      src/views/VideoDisplay/components/Season.js
  97. 2
      src/views/VideoDisplay/index.js
  98. 6
      src/views/Videos/components/MostViewedVideo.js
  99. 2
      src/views/Videos/components/NewestVideo.js
  100. 2
      src/views/Videos/components/VerticalGradeFilter.js

@ -38,7 +38,7 @@ export const BottomNavigation = ({ pages, isDark }) => {
return (
<>
<footer
className="w-full flex flex-row justify-around items-center fixed bottom-0 left-0 py-2 z-20 lg:hidden"
className="w-full flex justify-around items-center fixed bottom-0 left-0 py-2 z-20 lg:hidden"
style={{ background: isDark ? "hsla(209, 39%, 28%)" : "#E8FCFF" }}
>
{pages.map((page, index) => (

@ -39,8 +39,8 @@ export const Comments = ({ comments, indent }) => {
const Comment = ({ comment }) => {
return (
<div className="flex flex-col w-full">
<header className="w-full flex flex-row justify-between py-1">
<div className="flex flex-row items-end">
<header className="w-full flex justify-between py-1">
<div className="flex items-end">
<Avatar source={comment?.userImage} size={60} rounded={true} />
<div className="flex flex-col">
<div className="flex items-center">
@ -48,18 +48,18 @@ export const Comments = ({ comments, indent }) => {
<span className="text-tiny text-greenBA mr-3">
{comment?.userRoll || window.t("خریدار محصول")}
</span>
<div className="flex flex-row items-center mr-10 font-semibold">
<div className="flex items-center mr-10 font-semibold">
<StarRating />
</div>
</div>
<div
className="flex flex-row divide-x divide-gray-300 mt-4 divided items-center"
className="flex divide-x divide-gray-300 mt-4 divided items-center"
style={{ direction: "ltr" }}
></div>
</div>
</div>
<div
className="flex flex-row divide-x divide-gray-300 divided items-center"
className="flex divide-x divide-gray-300 divided items-center"
style={{ direction: "ltr" }}
>
<span className="px-2 text-sm text-blue-400">
@ -73,9 +73,9 @@ export const Comments = ({ comments, indent }) => {
<div className="flex flex-row">
<div style={{ width: 60 }} className="min-h-full"></div>
<div className="flex flex-1 flex-col px-3">
<header className="w-full flex flex-row justify-between items-center">
<header className="w-full flex justify-between items-center">
<div>&nbsp;</div>
<div className="flex flex-row items-center">
<div className="flex items-center">
{comment?.status === true && (
<>
<img src={positiveIcon} alt="" className="w-6 ml-2" />

@ -33,7 +33,7 @@ const CourseChapter = ({
height: isMobile ? "auto" : "calc(100vh - 300px)",
}}
>
<div className="hidden lg:flex flex-row w-full items-center justify-between">
<div className="hidden lg:flex w-full items-center justify-between">
<div>
<h2 className="text-green7B bg-opacity-5 text-base font-semibold">
{window.t("سرفصل دوره")}
@ -48,7 +48,7 @@ const CourseChapter = ({
</div>
<span className="hidden lg:flex w-full h-px bg-blue-200 my-4"></span>
<div className="lg:overflow-y-scroll w-full hasScrollbar flex-1 flex flex-col">
<div className="bg-green-600 rounded-sm p-4 flex flex-row items-center justify-between mb-2">
<div className="bg-green-600 rounded-sm p-4 flex items-center justify-between mb-2">
<p className="text-tiny font-bold text-white">
{seasons?.length > 0 &&
playList?.length > 0 &&
@ -65,7 +65,7 @@ const CourseChapter = ({
key={index}
>
<div
className="flex flex-row items-center justify-around"
className="flex items-center justify-around"
key={index}
>
{/* right div dot dot */}
@ -108,7 +108,7 @@ const CourseChapter = ({
disabled={true}
>
{/* top */}
<div className="flex flex-row items-center justify-between p-3 border-0 border-b border-solid border-green-200">
<div className="flex items-center justify-between p-3 border-0 border-b border-solid border-green-200">
<p
className={`text-base lg:text-tiny font-bold
${selectedVideo?.id === video?.id ? "text-white" : ""}`}

@ -47,7 +47,7 @@ export const Dialog = ({ dialog, setDialog }) => {
{text}
</p>
{type === "confirm" && (
<div className="flex flex-row gap-4 w-full">
<div className="flex gap-4 w-full">
<button
className="py-2.5 w-1/2 shadow-md rounded-sm bg-blueC0 text-white"
onClick={() => acceptFunc()}
@ -63,7 +63,7 @@ export const Dialog = ({ dialog, setDialog }) => {
</div>
)}
{type === "alert" && (
<div className="flex flex-row gap-4 w-full">
<div className="flex gap-4 w-full">
<button
className="py-2.5 w-full shadow-md rounded-sm bg-blue-400 text-white"
onClick={() => setDialog({ ...dialog, open: !dialog.open })}

@ -238,7 +238,7 @@ const MyDrawer = ({
className="flex flex-col justify-between h-1/6 pt-3 px-3 bg-green-500 dark:bg-blue90"
style={{ minHeight: "calc(100vh / 6)" }}
>
<div className="flex flex-row justify-between">
<div className="flex justify-between">
<Avatar size={70} rounded={true} />
<img
src={isDark ? sunIcon : moonIcon}
@ -247,7 +247,7 @@ const MyDrawer = ({
onClick={() => changeDarkMode(!isDark)}
/>
</div>
<div className="flex flex-row justify-between px-2 pb-3 mt-1">
<div className="flex justify-between px-2 pb-3 mt-1">
<div className="flex flex-col">
<strong className="text-lg text-white">
{user && user?.firstName + " " + user?.lastName}
@ -274,7 +274,7 @@ const MyDrawer = ({
<ul className="h-full flex flex-col py-6 px-4 gap-6">
{(!user ? publicLink : privateLink).map((item, key) => (
<Link to={item.link} key={key} onClick={() => item.onClick()}>
<div className="flex flex-row items-center">
<div className="flex items-center">
{item.icon}
<div className="text-gray70 text-tiny mr-5 dark:text-white">
{item.name}

@ -53,10 +53,10 @@ const FooterDesign1 = ({ color, bg, items, hasHeader }) => {
</div>
) : null}
<footer
className={`flex flex-col bg-gray-200 py-16 md:flex-row justify-around items-start md:items-start relative shadow-md z-20 ${bg}`}
className={`flex flex-col bg-gray-200 py-16 md:justify-around items-start md:items-start relative shadow-md z-20 ${bg}`}
>
<div className="w-11/12 flex justify-between">
<div className="flex flex-row gap-10">
<div className="flex gap-10">
{items.map((item, index) => (
<div className="flex flex-col" key={index}>
<strong className="text-xl text-gray70">{item.name}</strong>

@ -6,7 +6,7 @@ import arrowWhiteIcon from "../../assets/icons/arrow-left-white.svg";
function Header({ title, link, isDark }) {
return (
<header className="w-full flex flex-row justify-between items-center pl-0">
<header className="w-full flex justify-between items-center pl-0">
<strong className="text-green7B dark:text-white font-semibold text-base lg:text-sm">
{title}
</strong>

@ -70,24 +70,52 @@ function Navbar({
}
}, [isLogin]);
return isMobile ? (
return (
<div
className={_.join(
[
"z-50 flex flex-1 flex-row fixed left-0 top-0 justify-between w-full lg:bg-opacity-20 lg:bg-transparent lg:shadow-sm lg:backdrop-filter lg:backdrop-blur-md lg:px-5 xl:px-10 transition-all duration-300",
],
" "
)}
className="z-50 flex fixed left-0 top-0 w-full"
style={{
backgroundColor: !top ? (isDark ? "#061B30" : "white") : "",
}}
>
{/* landscape start */}
{/* landscape end */}
{/* portrait start */}
<div className="w-full lg:w-11/12 lg:mx-auto relative flex items-center justify-between py-3 px-4 bg-white">
{/* desktop */}
<div className=" items-center hidden lg:flex">
<Link
to="/"
className="flex items-center text-2xl font-black text-green7B"
>
<img src={logoIcon} className="w-8 relative bottom-1 ml-1" alt="" />
{window.t("دانوین")}
</Link>
<div className="w-full h-full relative flex flex-row items-center justify-between lg:hidden py-3 px-4">
<div className="relative">
<ul className="flex list-none items-center relative top-0.5 mr-4">
{pages.map((page, index) => (
<li key={index}>
<NavLink
to={page.link}
className="text-tiny py-2 px-4 mx-4"
style={({ isActive }) => ({
color: isActive ? "rgb(19, 123, 79)" : "#202020",
fontWeight: isActive ? "700" : "200",
})}
>
{page.name}
</NavLink>
</li>
))}
</ul>
</div>
{logo && (
<Link
to="/"
className="lg:hidden absolute left-1/2 transform -translate-y-1/2 top-1/2 -translate-x-1/2"
>
<img src={logoIcon} className="w-6 h-8" />
</Link>
)}
{/* desktop */}
{/* <div className="flex items-center"></div> */}
<div className="flex lg:hidden relative">
{hamburgerMenu && (
<>
<span className="w-2.5 h-2.5 rounded-full bg-redFF1 absolute -left-1 -top-1 animate-bounce"></span>
@ -113,29 +141,31 @@ function Navbar({
</strong>
)}
</div>
{logo && (
<Link
to="/"
className="absolute left-1/2 transform -translate-y-1/2 top-1/2 -translate-x-1/2"
>
<img src={logoIcon} className="w-6 h-8" />
</Link>
)}
<div className="flex flex-row items-center">
<div className="flex items-center">
{overLayer && (
<div
className="z-30 w-screen h-full fixed top-0 right-0 backdrop-filter blur-sm bg-opacity-60 bg-gray-600"
onClick={() => setOverLayer(false)}
>
<div className="relative w-full h-full">
<div
className="flex flex-col w-full absolute left-1/2 top-16 transform -translate-x-1/2 z-50 rounded-md"
style={{ maxWidth: "calc(100vw / 3)" }}
onClick={(e) => e.stopPropagation()}
>
<Search onChange={(val) => setSearch(val)} />
{search && <SearchResult text={search} setText={setSearch} />}
</div>
</div>
</div>
)}
{qr && (
<>
<Link
to="/scan"
className={_.join(
[
"rounded-sm p-1.5",
isDark
? "bg-blueC0 bg-opacity-10 ml-2"
: " ml-3 shadow-sm",
],
" "
)}
className={`flex lg:hidden rounded-sm p-1.5 ${
isDark ? "bg-blueC0 bg-opacity-10 ml-2" : " ml-3 shadow-sm"
}`}
style={{
border: `1px solid ${isDark ? "#D7E3FC20" : "#D7E3FC"}`,
}}
@ -148,13 +178,9 @@ function Navbar({
</Link>
<Link
to="/ar"
className={_.join(
[
"rounded-sm p-1.5",
isDark ? "bg-blueC0 bg-opacity-10" : " shadow-sm",
],
" "
)}
className={`flex lg:hidden rounded-sm p-1.5 ${
isDark ? "bg-blueC0 bg-opacity-10" : "shadow-sm"
}`}
style={{
border: `1px solid ${isDark ? "#D7E3FC20" : "#D7E3FC"}`,
}}
@ -173,7 +199,7 @@ function Navbar({
isDark ? bookmarkDeactiveDarkIcon : bookmarkDeactiveLightIcon
}
alt="bookmark"
className="w-7"
className="w-7 flex lg:hidden"
onClick={() => addToFavorite({ [bookmark]: location.getId() })}
/>
)}
@ -181,134 +207,76 @@ function Navbar({
<img
src={isDark ? dotsMenuDarkIcon : dotsMenuLightIcon}
alt="menu"
className="w-7 mr-2"
className="w-7 mr-2 flex lg:hidden"
/>
)}
{title && back ? (
<img
src={isDark ? arrowWhiteIcon : arrowBlueIcon}
alt="back"
className={`w-6 transform ${isDark ? "" : "-rotate-180"}`}
className={`w-6 flex lg:hidden transform ${
isDark ? "" : "-rotate-180"
}`}
onClick={() => navigation(-1)}
/>
) : null}
</div>
</div>
{/* desktop */}
<select
style={{ width: "100px" }}
className="hidden lg:flex items-center text-blueC0 border border-blueC0 px-1 rounded base py-1.5 ml-4 cursor-pointer"
>
{language.map((item, index) => (
<option
className="border border-blueC0 shadow-0 text-blueC0 text-base "
key={index}
>
{item.name}
</option>
))}
</select>
<Drawer drawerOpen={drawerOpen} setDrawerOpen={setDrawerOpen} />
{/* portrait end */}
</div>
) : (
<header
className={`w-full border-b border-gray-200 border-solid fixed top-0 right-0 bg-white z-20`}
style={{ boxShadow: "0px 0px 10px rgba(0,0,0,0.1)" }}
>
<div className={`w-11/12 mx-auto flex flex-col`}>
<div className="w-full flex flex-row items-center py-3 relative justify-between h-ful">
<div className="flex flex-row items-center">
<Link
to="/"
className="flex flex-row items-center text-2xl font-black text-green7B"
>
<img
src={logoIcon}
className="w-8 relative bottom-1 ml-1"
alt=""
/>
{window.t("دانوین")}
</Link>
<img
src={searchIcon}
alt=""
className="w-7 ml-3 cursor-pointer lg:flex hidden"
onClick={() => setOverLayer(true)}
/>
<ul className="flex flex-row list-none items-center relative top-0.5 mr-6">
{pages.map((page, index) => (
<li key={index}>
<NavLink
to={page.link}
className="text-tiny py-2 px-4 mx-4"
style={({ isActive }) => ({
color: isActive ? "rgb(19, 123, 79)" : "#202020",
fontWeight: isActive ? "700" : "200",
})}
>
{page.name}
</NavLink>
</li>
))}
</ul>
</div>
{isLogin && (
<div className="hidden lg:flex justify-end items-center gap-4">
<Link to="/cart" className="relative">
<img src={cartIcon} alt="" className="w-8" />
<span className="absolute -right-2 -top-0.5 w-4 p-2.5 h-4 flex justify-center items-center bg-green-700 bg-opacity-100 rounded-full text-white text-xs">
{cartProductsLength}
</span>
</Link>
{/* <img src={whiteCartIcon} alt="" className="w-5 h-5 ml-2" /> */}
{overLayer && (
<div
className="z-30 w-screen h-full fixed top-0 right-0 backdrop-filter blur-sm bg-opacity-60 bg-gray-600"
onClick={() => setOverLayer(false)}
>
<div className="relative w-full h-full">
<div
className="flex flex-col w-full absolute left-1/2 top-16 transform -translate-x-1/2 z-50 rounded-md"
style={{ maxWidth: "calc(100vw / 3)" }}
onClick={(e) => e.stopPropagation()}
>
<Search onChange={(val) => setSearch(val)} />
{search && <SearchResult text={search} setText={setSearch} />}
</div>
</div>
{/* <img src={profileIcon} alt="" className="w-5 h-5" /> */}
</div>
)}
<div className="flex flex-row items-center">
<select
style={{ width: "100px" }}
className="flex items-center text-blueC0 border border-blueC0 px-1 rounded base py-1.5 ml-4 cursor-pointer"
{!isLogin ? (
<Link
to="/signup"
className="bg-blueC0 font-semibold text-white rounded-md px-4 py-3 text-sm mr-7 hover:bg-opacity-90 shadow-sm"
>
{language.map((item, index) => (
<option
className="border border-blueC0 shadow-0 text-blueC0 text-base "
key={index}
>
{item.name}
</option>
))}
</select>
<img
src={searchIcon}
alt=""
className="w-7 ml-3 cursor-pointer"
onClick={() => setOverLayer(true)}
/>
{isLogin && (
<div className="flex justify-end items-center gap-4">
<Link to="/cart" className="relative">
<img src={cartIcon} alt="" className="w-8" />
<span className="absolute -right-2 -top-0.5 w-4 p-2.5 h-4 flex justify-center items-center bg-green-700 bg-opacity-100 rounded-full text-white text-xs">
{cartProductsLength}
</span>
</Link>
{/* <img src={whiteCartIcon} alt="" className="w-5 h-5 ml-2" /> */}
{/* <img src={profileIcon} alt="" className="w-5 h-5" /> */}
</div>
)}
{!isLogin ? (
<Link
to="/signup"
className="bg-blueC0 font-semibold text-white rounded-md px-4 py-3 text-sm mr-7 hover:bg-opacity-90 shadow-sm"
>
{window.t("ورود یا ثبت نام")}
</Link>
) : (
<Link
to="/dashboard"
className="bg-blueC0 font-semibold text-white rounded-md px-4 py-3 text-sm mr-7 hover:bg-opacity-90 shadow-sm"
>
{window.t("حساب کاربری")}
</Link>
)}
</div>
{window.t("ورود یا ثبت نام")}
</Link>
) : (
<Link
to="/dashboard"
className="hidden lg:flex bg-blueC0 font-semibold text-white rounded-md px-4 py-3 text-sm mr-7 hover:bg-opacity-90 shadow-sm"
>
{window.t("حساب کاربری")}
</Link>
)}
{/* desktop */}
</div>
</div>
</header>
<Drawer drawerOpen={drawerOpen} setDrawerOpen={setDrawerOpen} />
</div>
);
}

@ -2,7 +2,7 @@ import React from "react";
function OR({}) {
return (
<div className="w-full flex flex-row justify-between items-center my-3 lg:my-5">
<div className="w-full flex justify-between items-center my-3 lg:my-5">
<div
style={{ width: "43%", height: 1, backgroundColor: "#EFEFEF" }}
></div>

@ -13,7 +13,7 @@ const ProductImage = ({ images }) => {
}
}, [images]);
return (
<div className="flex flex-row w-1/3 gap-2">
<div className="flex w-1/3 gap-2">
<div
className="flex flex-col items-center justify-between w-1/5"
style={{ height: "calc(100vw / 5)" }}

@ -37,8 +37,8 @@ const ProductStatusCard = ({
return (
<section className="w-full" style={{ minWidth: 350 }}>
<div className="bg-grayF9 rounded-md px-4 py-2 divide-y divide-solid divide-gray-200">
<div className="flex flex-row items-center justify-between py-3">
<div className="flex flex-row items-center">
<div className="flex items-center justify-between py-3">
<div className="flex items-center">
<img src={tick} alt="" className="w-8" />
<div className="flex flex-col mr-3">
<div className="text-sm">{`${window.t(
@ -49,8 +49,8 @@ const ProductStatusCard = ({
</div>
{seller && (
<div className="flex flex-row items-center justify-between py-3">
<div className="flex flex-row items-center">
<div className="flex items-center justify-between py-3">
<div className="flex items-center">
<img src={shop} alt="" className="w-8" />
<div className="flex flex-1 flex-col mr-3 text-sm gap-2">
<div className="text-tiny">{"فروشنده" + " " + seller.name}</div>
@ -63,11 +63,11 @@ const ProductStatusCard = ({
</div>
)}
<div className="flex flex-row items-center justify-between py-3">
<div className="flex flex-row items-center">
<div className="flex items-center justify-between py-3">
<div className="flex items-center">
<img src={delivery} alt="" className="w-8" />
<div className="flex flex-col mr-3">
<div className="flex flex-row gap-1 text-sm">
<div className="flex gap-1 text-sm">
&nbsp;{shippingTime}
</div>
</div>
@ -75,18 +75,18 @@ const ProductStatusCard = ({
</div>
{garanty && (
<div className="flex flex-row items-center justify-between py-3">
<div className="flex flex-row items-center">
<div className="flex items-center justify-between py-3">
<div className="flex items-center">
<img src={shield} alt="" className="w-8" />
<div className="flex flex-col mr-3">
<div className="flex flex-row gap-1 text-sm">{garanty}</div>
<div className="flex gap-1 text-sm">{garanty}</div>
</div>
</div>
</div>
)}
{bookmark && (
<div className="flex flex-row items-center py-3">
<div className="flex items-center py-3">
<img
src={
isDark ? bookmarkDeactiveDarkIcon : bookmarkDeactiveLightIcon
@ -141,7 +141,7 @@ const ProductStatusCard = ({
}
/>
</div>
<div className="bg-grayF9 rounded px-4 py-2 mt-4 flex flex-row items-center">
<div className="bg-grayF9 rounded px-4 py-2 mt-4 flex items-center">
<div>
<img src={arrow} alt="" className="w-20 h-20" />
</div>

@ -46,10 +46,10 @@ const ProductSuggestion = ({
{window.t("این کالاها برای خرید به شما پیشنهام می دهیم")}
</h2>
{/* product design */}
<div className="flex flex-row flex-wrap items-center justify-center mt-5 w-full gap-10">
<div className="flex flex-wrap items-center justify-center mt-5 w-full gap-10">
{similarList.map((book, index) => (
<div
className="flex flex-row mb-7 justify-center relative"
className="flex mb-7 justify-center relative"
style={{ maxWidth: "calc(100% / 5)" }}
key={index}
>
@ -98,7 +98,7 @@ const ProductSuggestion = ({
</div>
{/* bottom */}
<div className="flex flex-col justify-center items-center mt-4">
<div className="flex flex-row mb-5">
<div className="flex mb-5">
<p className="text-base text-productPrice font-bold">
&nbsp;
{window.t("جمع لوازم اختیاری خریداری شده")}

@ -7,7 +7,7 @@ const ProductTab = ({ tabs }) => {
return (
<section className="mt-10 flex flex-col w-full">
<div className="rounded-md bg-grayF9">
<ul className="flex flex-row justify-center gap-16">
<ul className="flex justify-center gap-16">
{tabs.map((tab, index) =>
tab.shown ? (
<li

@ -14,8 +14,8 @@ const QandA = ({ comments }) => {
return (
<>
<div className="flex flex-col leading-7 w-full py-6 border-t-2 border-solid border-gray-200">
<header className="w-full flex flex-row justify-between py-1">
<div className="flex flex-row items-end">
<header className="w-full flex justify-between py-1">
<div className="flex items-end">
<div className="flex items-center">
<strong className="text-lg mx-2">{comment.username}</strong>
{comment.isCostumer ? (
@ -26,7 +26,7 @@ const QandA = ({ comments }) => {
</div>
</div>
<div
className="flex flex-row divide-x divide-gray-300 divided items-center"
className="flex divide-x divide-gray-300 divided items-center"
style={{ direction: "ltr" }}
>
<span className="px-2 text-sm text-blue-400">
@ -38,11 +38,11 @@ const QandA = ({ comments }) => {
</span>
</div>
</header>
<div className="flex flex-row py-4">
<div className="flex py-4">
<div style={{ width: 60 }} className="min-h-full"></div>
<div className="flex flex-1 flex-col px-3">
<header className="w-full flex flex-row justify-between items-center">
<div className="flex flex-row items-center">
<header className="w-full flex justify-between items-center">
<div className="flex items-center">
<div className="py-4 px-6 bg-blue-100 text-gray-400 rounded">
<h1>{window.t("پرسش")}</h1>
</div>
@ -58,11 +58,11 @@ const QandA = ({ comments }) => {
{comment.answers.length > 0 ? (
comment.answers.slice(0, numberOfAnswers).map((item, index) => (
<div className="flex flex-row py-1" key={index}>
<div className="flex py-1" key={index}>
<div style={{ width: 60 }} className="min-h-full"></div>
<div className="flex flex-1 flex-col px-3">
<header className="w-full flex flex-row justify-between items-center">
<div className="flex flex-row items-center">
<header className="w-full flex justify-between items-center">
<div className="flex items-center">
<div className="py-4 px-6 bg-green-100 text-gray-400 rounded">
<h1>{window.t("پاسخال پاسخ")}</h1>
</div>
@ -79,8 +79,8 @@ const QandA = ({ comments }) => {
</div>
))
) : (
<header className="w-full flex flex-row justify-between items-center">
<div className="flex w-4/5 flex-row items-center">
<header className="w-full flex justify-between items-center">
<div className="flex w-4/5 items-center">
<div className="py-4 px-6 bg-green-100 text-gray-400 mx-16 rounded">
<h1>{window.t("ارسال پاسخ")}</h1>
</div>

@ -55,9 +55,9 @@ export default function VerticalExpandableProductFilter(props) {
(item1, i) => (
<li
key={i}
className="hover:bg-gray-100 px-3 flex flex-row items-center justify-between py-2"
className="hover:bg-gray-100 px-3 flex items-center justify-between py-2"
>
<div className="flex flex-row items-center">
<div className="flex items-center">
<Checkbox
name={`ch${name}_${i}`}
checked={true}

@ -7,7 +7,9 @@ const blog = {
info: (data) => async (dispatch) =>
await proxy.get("public/blogInfo", data, { dispatch }),
active: (data) => async (dispatch) =>
await dispatch({ type: "public/active", data }),
await dispatch({ type: "blog/active", data }),
setActiveHashtag: (data) => async (dispatch) =>
await dispatch({ type: "blog/activeHashtag", data }),
letterAdd: (data) => async (dispatch) =>
await proxy.post("news/LetterAdd", data, { dispatch }),
};

@ -0,0 +1,6 @@
const config = {
setDevice: (data) => async (dispatch) =>
await dispatch({ type: "config/setDevice", data }),
};
export default config;

@ -18,4 +18,5 @@ export {default as qr} from "./qr";
export {default as comment} from "./comment";
export {default as form} from "./form";
export {default as dialog} from "./dialog";
export {default as menu} from "./menu";
export {default as menu} from "./menu";
export {default as config} from "./config";

@ -5,31 +5,37 @@ const initialState = {
error: null,
list: [],
info: null,
hashtags : [],
hashtags: [],
active: null,
activeHashtag: "همه",
};
export default function blog(state = initialState, action) {
let { type, data } = action;
switch (type) {
case "blog/activeHashtag":
return {
...state,
activeHashtag: data,
};
case "public/blogList":
return {
...state,
loading: false,
list: data,
hashtags: [...new Set(data.map((object) => object.tag))],
hashtags: ["همه", ...new Set(data.map((object) => object.tag))],
error: null,
};
case "public/active":
case "blog/active":
return {
...state,
active : data,
active: data,
loading: false,
error: null,
};
case "public/blogInfo":
return { ...state, loading: false, error: null, blog: data };
case "news/LetterAdd":
toast.success('.به خبرنامه دانوین خوش آمدید');
toast.success(".به خبرنامه دانوین خوش آمدید");
return { ...state, loading: false, error: null };
case "blog/loading":
return { ...state, loading: true };

@ -0,0 +1,16 @@
const initialState = {
device: "mobile",
};
export default function config(state = initialState, action) {
let { type, data } = action;
switch (type) {
case "config/setDevice":
return {
...state,
device: data,
};
default:
return state;
}
}

@ -18,4 +18,5 @@ export {default as qr} from "./qr";
export {default as comment} from "./comment";
export {default as form} from "./form";
export {default as dialog} from "./dialog";
export {default as menu} from "./menu";
export {default as menu} from "./menu";
export {default as config} from "./config";

@ -2,7 +2,7 @@ import React, { useEffect } from "react";
import { BrowserRouter, Routes, Route } from "react-router-dom";
import { Navigate } from "react-router-dom";
import { connect } from "react-redux";
import { publicApi, menu } from "./redux/actions";
import { publicApi, menu, config } from "./redux/actions";
import Navbar from "./components/Navbar";
import BG from "./components/BG";
import BottomNavigation from "./components/BottomNavigation";
@ -35,11 +35,56 @@ import Address from "./views/Address";
import Favorites from "./views/Favorites";
import Addresses from "./views/Dashboard/layouts/Mobile/ProfileAddress";
function Router({ isDark, isMobile, headerOptions, dialog, menu, setMenu }) {
function Router({
isDark,
isMobile,
headerOptions,
dialog,
menu,
setMenu,
setDevice,
device,
}) {
useEffect(() => {
window.addEventListener("scroll", () => {});
const width = window.innerWidth;
if (width <= 640) {
setDevice("mobile");
}
if (width > 640 && width < 1024) {
setDevice("tablet");
}
if (width > 1024) {
setDevice("desktop");
}
}, []);
React.useEffect(() => {
window.addEventListener("resize", () => {
const width = window.innerWidth;
if (width <= 640) {
if (device === "mobile") {
return;
} else {
setDevice("mobile");
}
}
if (width > 640 && width < 1024) {
if (device === "tablet") {
return;
} else {
setDevice("tablet");
}
}
if (width > 1024) {
if (device === "desktop") {
return;
} else {
setDevice("desktop");
}
}
});
}, [device]);
const prevDefault = (e) => {
setMenu();
e.stopPropagation();
@ -535,16 +580,18 @@ function Router({ isDark, isMobile, headerOptions, dialog, menu, setMenu }) {
const mapStateToProps = (state) => ({
isDark: state.publicApi.isDark,
isMobile: state.publicApi.isMobile,
isMobile: state.config.device === "mobile",
isLogin: state.user.status,
headerOptions: state.publicApi.headerOptions,
dialog: state.dialog.dialog,
menu: state.menu.open,
device: state.config.device,
});
const mapDispatchToProps = {
setDesktopContentTransform: publicApi.setDesktopContentTransform,
setMenu: menu.set,
setDevice: config.setDevice,
};
export default connect(mapStateToProps, mapDispatchToProps)(Router);

@ -17,8 +17,9 @@ function About({
first,
setHeaderOptions,
}) {
useEffect(() => {
setHeaderOptions({ shown: true });
setHeaderOptions({ shown: true, hamburgerMenu : true, logo: true, qr : true });
}, []);
useEffect(() => {
@ -26,8 +27,8 @@ function About({
}, []);
return (
<div className={_.join(["about w-11/12 mx-auto flex flex-col"], " ")}>
<main className="flex flex-col items-center pt-16 ">
<div className="about w-11/12 mx-auto flex flex-col py-8 lg:py-16">
<main className="flex flex-col items-center">
<header>
<h1>{first.title}</h1>
<p

@ -1,4 +1,4 @@
$gray : #aaa;
$gray : #818181;
$green3 : #00cc69;
@ -6,7 +6,7 @@ $green3 : #00cc69;
main {
li::before {
color: $gray;
content: "\2022";
// content: "\2022";
font-weight: bold;
display: inline-block;
width: 1em;

@ -4,7 +4,7 @@ import React from 'react'
import alertIcon from '../../../assets/icons/alert.svg';
function Alert({text}) {
return (
<div className="flex flex-row items-center bg-blueFD rounded-md border border-solid border-blueC0 py-3 px-2 w-full my-3 dark:bg-opacity-5">
<div className="flex items-center bg-blueFD rounded-md border border-solid border-blueC0 py-3 px-2 w-full my-3 dark:bg-opacity-5">
<img src={alertIcon} alt="" />
<p className="text-blueC0 text-xs mr-3 dark:text-white leading-5 lg:text-sm">
{text}

@ -286,7 +286,7 @@ export const Address = ({
const Header = ({ title, text }) => {
return (
<div className="flex flex-col lg:flex-row lg:items-center gap-2 lg:mb-4 mt-2 lg:mt-0">
<div className="flex flex-col lg:lg:items-center gap-2 lg:mb-4 mt-2 lg:mt-0">
<strong className="text-green4F text-base dark:text-white">
{title}
</strong>
@ -335,7 +335,7 @@ export const Address = ({
onClick={() => submit()}
/>
<button
className="bg-transparent mt-4 text-base lg:text-tiny border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 lg:py-4 flex flex-row justify-center items-center"
className="bg-transparent mt-4 text-base lg:text-tiny border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 lg:py-4 flex justify-center items-center"
onClick={() => {
setPhase("deliveryForm");
navigation(-1);
@ -363,7 +363,7 @@ export const Address = ({
<div className="flex item-center gap-x-4">
{/* my self */}
<div
className={`flex flex-row items-center mb-7 cursor-pointer
className={`flex items-center mb-7 cursor-pointer
`}
onClick={() => {
setActiveCheckbox(true);
@ -380,7 +380,7 @@ export const Address = ({
</div>
{/* someone else */}
<div
className={`flex flex-row items-center mb-7 cursor-pointer
className={`flex items-center mb-7 cursor-pointer
`}
onClick={() => {
setActiveCheckbox(false);
@ -410,7 +410,7 @@ export const Address = ({
)}
/>
<div className="flex flex-col lg:flex-row items-center lg:gap-5 w-full mb-4">
<div className="flex flex-col lg:items-center lg:gap-5 w-full mb-4">
<Input
width={isMobile ? "100%" : "50%"}
label={window.t("نام")}
@ -457,7 +457,7 @@ export const Address = ({
)}
/>
<div className="flex flex-col lg:flex-row items-center lg:gap-5 w-full mb-4">
<div className="flex flex-col lg:items-center lg:gap-5 w-full mb-4">
<Input
width={isMobile ? "100%" : "50%"}
label={window.t("شماره موبایل")}
@ -526,7 +526,7 @@ export const Address = ({
)}
/>
<div className="flex flex-col lg:flex-row items-center gap-3 lg:gap-5 w-full">
<div className="flex flex-col lg:items-center gap-3 lg:gap-5 w-full">
<Select
selectProvince={"استان"}
options={provinces.map((e) => ({ value: e.id, name: e.name }))}

@ -422,7 +422,7 @@ function Profile({
</div>
) : (
<ul className="flex flex-col flex-1">
<li className="flex flex-row gap-5">
<li className="flex gap-5">
<div className="flex flex-col w-4/12">
<strong>{window.t(" اطلاعات هویتی")}</strong>
<p>
@ -431,7 +431,7 @@ function Profile({
)}
</p>
</div>
<div className="flex flex-row w-8/12"></div>
<div className="flex w-8/12"></div>
</li>
</ul>
);

@ -143,7 +143,7 @@ function SignUp({
return (
<div
className="w-screen overflow-x-hidden flex flex-row transform relative"
className="w-screen overflow-x-hidden flex transform relative"
style={{ height: "calc(100vh - 160px)" }}
>
<button
@ -308,7 +308,7 @@ function SignUp({
level === "phonenumber" ? checkPhoneNumber(e) : checkOtp(e)
}
/>
<div className="mt-10 flex flex-row text-center w-full justify-center">
<div className="mt-10 flex text-center w-full justify-center">
<div className="text-sm text-gray1 dark:text-gray-200 lg:text-sm">
{window.t(" شماره خود را اشتباه وارد کردید؟")}
<button

@ -131,7 +131,7 @@ export const Blog = ({
}}
></div>
)}
<div className="flex lg:flex-row my-5 gap-5">
<div className="flex lg:my-5 gap-5">
<strong className="flex-1 lg:text-5xl lg:font-black dark:text-gray-200">
{blog?.title}
</strong>

@ -4,6 +4,7 @@ import { blog, publicApi } from "../../redux/actions";
import { Carousel } from "@trendyol-js/react-carousel";
import Hashtags from "./layouts/Hashtags";
import Blog from "./layouts/Blog";
import Single from "./layouts/Single";
import Join from "./layouts/Join";
import New from "./layouts/New";
@ -14,7 +15,13 @@ import Target from "./layouts/Target";
//assets
import arrow from "../../assets/icons/dropdown-blue.svg";
export const Blogs = ({ isMobile, getList, blogs, setHeaderOptions }) => {
export const Blogs = ({
isMobile,
getList,
blogs,
setHeaderOptions,
activeHashtag,
}) => {
useEffect(() => {
if (isMobile) {
setHeaderOptions({
@ -33,91 +40,104 @@ export const Blogs = ({ isMobile, getList, blogs, setHeaderOptions }) => {
}, []);
return (
<div className="flex w-full px-4 lg:px-0 flex-col lg:w-11/12 mx-auto lg:py-24 pb-24 lg:pb-0 ">
<div className="flex w-full px-4 lg:px-0 flex-col lg:w-11/12 mx-auto lg:py-24 pb-24 lg:pb-16">
<Hashtags />
<Single />
<Header title={window.t(" تازهترینها از وبلاگ")} />
{isMobile ? (
<div className="w-full flex overflow-x-scroll no-scrollbar gap-4">
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</div>
) : (
<div className="w-full relative" style={{ direction: "ltr" }}>
{blogs.length > 0 && (
<Carousel
show={3}
slide={2}
swiping={true}
useArrowKeys={true}
transition={0.5}
rightArrow={
<img
className="absolute top-1/2 transform -rotate-90 -translate-y-1/2 cursor-pointer p-0"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
leftArrow={
<img
className="absolute top-1/2 transform -translate-y-1/2 -translate-x-5 cursor-pointer rotate-90 p-2 -left-3"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
>
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</Carousel>
)}
</div>
)}
<Header title={window.t("پیشنهاد سردبیر")} />
{isMobile ? (
<div className="w-full flex overflow-x-scroll no-scrollbar gap-4">
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</div>
{activeHashtag === "همه" ? (
<>
<Single />
<Header title={window.t(" تازهترینها از وبلاگ")} />
<div className=" w-full flex lg:hidden overflow-x-scroll no-scrollbar gap-4">
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</div>
<div
className="hidden lg:flex w-full relative"
style={{ direction: "ltr" }}
>
{blogs.length > 0 && (
<Carousel
show={3}
slide={2}
swiping={true}
useArrowKeys={true}
transition={0.5}
rightArrow={
<img
className="absolute top-1/2 transform -rotate-90 -translate-y-1/2 cursor-pointer p-0"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
leftArrow={
<img
className="absolute top-1/2 transform -translate-y-1/2 -translate-x-5 cursor-pointer rotate-90 p-2 -left-3"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
>
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</Carousel>
)}
</div>
<Header title={window.t("پیشنهاد سردبیر")} />
<div className="w-full flex lg:hidden overflow-x-scroll no-scrollbar gap-4">
{blogs.map((blog, index) => (
<New blog={blog} key={index} />
))}
</div>
<div
className="hidden lg:flex w-full relative"
style={{ direction: "ltr" }}
>
{blogs.length > 0 && (
<Carousel
show={4}
slide={2}
swiping={true}
useArrowKeys={true}
transition={0.5}
rightArrow={
<img
className="absolute top-1/2 transform -rotate-90 -translate-y-1/2 cursor-pointer p-0"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
leftArrow={
<img
className="absolute top-1/2 transform -translate-y-1/2 -translate-x-5 cursor-pointer rotate-90 p-2 -left-3"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
>
{blogs.map((blog, index) => (
<Suggest blog={blog} key={index} />
))}
</Carousel>
)}
</div>
<Header title={window.t("از دنیای آموزش")} />
<Target blogs={blogs?.slice(0, 4)} />
</>
) : (
<div className="w-full relative" style={{ direction: "ltr" }}>
{blogs.length > 0 && (
<Carousel
show={4}
slide={2}
swiping={true}
useArrowKeys={true}
transition={0.5}
rightArrow={
<img
className="absolute top-1/2 transform -rotate-90 -translate-y-1/2 cursor-pointer p-0"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
leftArrow={
<img
className="absolute top-1/2 transform -translate-y-1/2 -translate-x-5 cursor-pointer rotate-90 p-2 -left-3"
src={arrow}
alt=""
// onClick={(e) => e.stopPropagation()}
/>
}
>
{blogs.map((blog, index) => (
<Suggest blog={blog} key={index} />
))}
</Carousel>
)}
<div className="flex flex-wrap items-center">
{blogs
?.filter((blog) => blog?.tag === activeHashtag)
?.map((blog, index) => (
<Blog blog={blog} key={index} />
))}
</div>
)}
<Header title={window.t("از دنیای آموزش")} />
<Target blogs={blogs?.slice(0, 4)} />
<Join />
</div>
);
@ -126,6 +146,7 @@ export const Blogs = ({ isMobile, getList, blogs, setHeaderOptions }) => {
const mapStateToProps = (state) => ({
isMobile: state.publicApi.isMobile,
blogs: state.blog.list,
activeHashtag: state.blog.activeHashtag,
});
const mapDispatchToProps = {

@ -0,0 +1,45 @@
import React from "react";
import { connect } from "react-redux";
import { useNavigate } from "react-router-dom";
const height = {
mobile: "calc((100vw - 32px) / 16 * 9)",
tablet: "calc((100vw - 32px) / 16 * 9)",
desktop: "calc((100vw / 12 * 11) / 4 / 16 * 9)",
};
export const Blog = ({ blog, device }) => {
const navigation = useNavigate();
return (
<article className="flex w-full lg:w-1/4 p-2">
<div
className="cursor-pointer flex flex-col gap-4 w-full"
onClick={() =>
navigation(`/blogs/${blog?.id}`, { state: { id: blog?.id } })
}
>
<div
className="w-full rounded-md"
style={{
backgroundImage: `url(https://dnvn.ir/api/v1/file/${blog?.fileIds})`,
backgroundRepeat: "no-repeat",
backgroundPosition: "center",
backgroundSize: "cover",
minHeight: height[device],
}}
></div>
<strong className="text-sm lg:text-tiny xl:text-base text-backgroundText h-20">
{blog?.title}
</strong>
</div>
</article>
);
};
const mapStateToProps = (state) => ({
device: state.config.device,
});
const mapDispatchToProps = {};
export default connect(mapStateToProps, mapDispatchToProps)(Blog);

@ -1,17 +1,25 @@
import React from "react";
import { connect } from "react-redux";
import { blog } from "../../../redux/actions";
//assets
import arrowIcon from "../arrow.svg";
export const Hashtags = ({ hashtags }) => {
export const Hashtags = ({ hashtags, setActive, activeHashtag }) => {
return (
<div className="flex py-3 px-2 rounded-full border-2 border-green-50 dark:border-opacity-20 shadow-sm border-solid items-center w-full mb-7 overflow-x-scroll no-scrollbar">
<div className="flex py-1 lg:py-3 px-2 rounded-full border-2 border-green-50 dark:border-opacity-20 shadow-sm border-solid items-center w-full mb-7 overflow-x-scroll no-scrollbar">
<img src={arrowIcon} alt="" className="w-7" />
<ul className="list-none flex justify-around items-center lg:flex-1 lg:ml-0 ml-4">
<ul className="list-none flex items-center lg:flex-1 lg:ml-0 ml-4">
{hashtags.map((hashtag, index) => (
<li className="text-tiny font-semibold cursor-pointer mx-4 lg:px-0 flex-1">
{hashtag}
<li
className={`text-tiny w-16 lg:w-28 font-medium cursor-pointer rounded-md text-center py-2 transition-all mx-4 flex-1 ${
activeHashtag === hashtag
? "bg-green-400 text-white"
: "text-green79"
}`}
onClick={() => setActive(hashtag)}
>
{"#" + hashtag}
</li>
))}
</ul>
@ -21,8 +29,11 @@ export const Hashtags = ({ hashtags }) => {
const mapStateToProps = (state) => ({
hashtags: state.blog.hashtags,
activeHashtag: state.blog.activeHashtag,
});
const mapDispatchToProps = {};
const mapDispatchToProps = {
setActive: blog.setActiveHashtag,
};
export default connect(mapStateToProps, mapDispatchToProps)(Hashtags);

@ -13,7 +13,7 @@ export const Join = ({ isMobile, join, userId }) => {
userId ? join({ userId, email }) : join({ email });
};
return (
<div className="w-full lg:h-72 border-2 px-3 lg:p-0 py-4 border-solid border-gray-200 dark:border-opacity-30 rounded-md flex lg:flex-row flex-col-reverse mt-7 lg:mt-32">
<div className="w-full lg:h-72 border-2 px-3 lg:p-0 py-4 border-solid border-gray-200 dark:border-opacity-30 rounded-md flex lg:flex-col-reverse mt-7 lg:mt-32">
<img
src={picImage}
alt=""

@ -7,7 +7,7 @@ export const Single = ({ blog, isMobile }) => {
return (
<Link
to={"/blogs/" + blog?.id}
className="flex flex-col lg:flex-row lg:gap-5 overflow-y-hidden"
className="flex flex-col lg:lg:gap-5 overflow-y-hidden"
>
<div
className="w-full lg:w-1/2 rounded-md overflow-hidden relative"

@ -78,12 +78,12 @@ export const Target = ({ blogs, isMobile }) => {
const Small = ({ blogs }) => {
return (
<div className="w-full lg:w-1/2 flex flex-row flex-wrap lg:flex-col justify-between">
<div className="w-full lg:w-1/2 flex flex-wrap lg:flex-col justify-between">
{blogs.map((blog, index) => (
<Link
to={"/blogs/" + blog.id}
key={index}
className="lg:mb-0 mb-3 lg:flex-row lg:flex lg:gap-2"
className="lg:mb-0 mb-3 lg:lg:flex lg:gap-2"
style={{ width: isMobile ? "48%" : "100%" }}
>
<img
@ -115,7 +115,7 @@ export const Target = ({ blogs, isMobile }) => {
);
};
return (
<div className="flex flex-col lg:flex-row gap-10">
<div className="flex flex-col lg:gap-10">
<Large blog={blogs[0]} />
<Small blogs={blogs?.slice(0, 3)} />
</div>

@ -48,7 +48,7 @@ function Contact({ headerOptions, setHeaderOptions, info, isMobile, isDark }) {
/>
</div>
) : (
<div className="flex flex-row gap-10 transform -translate-y-12 w-11/12 mx-auto">
<div className="flex gap-10 transform -translate-y-12 w-11/12 mx-auto">
<div className="w-1/3">
<Ticket />
</div>

@ -5,7 +5,7 @@ import { connect } from "react-redux";
function Info({ info, isDark }) {
return (
<div
className="flex flex-row py-4 px-3 rounded-md mt-4"
className="flex py-4 px-3 rounded-md mt-4"
style={{
backgroundColor: info.bg,
border: `1px solid ${info.borderColor}`,

@ -30,7 +30,7 @@ export const Dashboard = ({ isMobile, headerOptions, setHeaderOptions }) => {
</div>
) : (
<div className="w-full">
<div className="gap-5 w-full h-screen pt-20 mx-auto flex flex-row bg-transparent justify-end">
<div className="gap-5 w-full h-screen pt-20 mx-auto flex bg-transparent justify-end">
<Sidebar page={page} setPage={setPage} />
<Main page={page} />
</div>

@ -51,7 +51,7 @@ const ProfileAddress = ({
isMobile ? "p-0" : "px-10"
} mx-auto`}
>
<div className="w-full flex flex-row justify-between items-center mt-4">
<div className="w-full flex justify-between items-center mt-4">
<button
className={`flex justify-center text-tiny lg:text-sm rounded-md py-3 bg-grayF9 dark:bg-blueC0 dark:bg-opacity-30 cursor:pointer ${
isDark ? "text-white" : "text-gray70"
@ -189,7 +189,7 @@ const Location = ({
<Link
style={{ border: "solid 1px #12CF7F" }}
to={"/editAddress/" + address.id}
className="w-full flex flex-row text-sm items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
className="w-full flex text-sm items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
onClick={() => setMenu()}
>
{window.t("ویرایش")}
@ -197,7 +197,7 @@ const Location = ({
</Link>
<div
style={{ border: "solid 1px #fca5a5" }}
class="w-full flex flex-row items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
class="w-full flex items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
onClick={() => delAddress(address.id)}
>
<button class="text-sm ">{window.t("حذف")}</button>

@ -51,7 +51,7 @@ const List = ({ mobile }) => {
<Link
key={index}
to={page.link}
className={`w-full flex items-center justify-between mb-6 pb-4 flex-row shadow-sm`}
className={`w-full flex items-center justify-between mb-6 pb-4 shadow-sm`}
>
<div className={`flex items-center flex-row`}>
{page.icon}

@ -151,8 +151,8 @@ const Location = ({
</div>
<div className={"flex flex-col flex-1 mr-2"}>
{active && (
<div className={"w-full flex flex-row justify-between mb-3"}>
<div className={"flex flex-row items-center"}>
<div className={"w-full flex justify-between mb-3"}>
<div className={"flex items-center"}>
<strong className={"text-base font-bold text-gray1"}>
{window.t("آدرس انتخابی شما")}
</strong>

@ -6,9 +6,9 @@ const Trophy = ({}) => {
const [dropdown, setDropdown] = React.useState(true);
return (
<div
className={`w-full flex py-5 px-3 justify-between items-center flex-row bg-yellow4 bg-opacity-40`}
className={`w-full flex py-5 px-3 justify-between items-center bg-yellow4 bg-opacity-40`}
>
<div className={`flex flex-row items-center`}>
<div className={`flex items-center`}>
<svg xmlns="http://www.w3.org/2000/svg" width={23.862} height={23.862}>
<g fill="none" stroke="#d6d020" data-name="vuesax/linear/cup">
<path

@ -7,7 +7,7 @@ const User = ({ user, mobile }) => {
return (
<div className={`w-full`}>
<button
className={`w-full mt-2 mb-2 flex flex-row justify-between items-center border-none`}
className={`w-full mt-2 mb-2 flex justify-between items-center border-none`}
onClick={() => setDropdown(!dropdown)}
>
<div className={`flex items-center flex-row`}>
@ -49,7 +49,7 @@ const User = ({ user, mobile }) => {
}`}
>
<div
className={`flex items-center w-full pb-3 mb-3 flex-row border-b border-solid border-gray-100`}
className={`flex items-center w-full pb-3 mb-3 border-b border-solid border-gray-100`}
>
<strong className="text-sm text-gray1">
{window.t("افزودن حساب کاربری جدید")}

@ -40,7 +40,7 @@ const SidebarMenu = ({
return (
<div className="flex flex-col">
<div
className="flex flex-row justify-between items-center py-2 my-2 cursor-pointer group hover:bg-blueC0 hover:bg-opacity-10 rounded-md px-1"
className="flex justify-between items-center py-2 my-2 cursor-pointer group hover:bg-blueC0 hover:bg-opacity-10 rounded-md px-1"
onClick={() =>
setToggleList({ ...toggleList, [name]: !toggleList[name] })
}
@ -69,7 +69,7 @@ const SidebarMenu = ({
{list.map((item, index) => (
<li
key={index}
className={`flex flex-row items-center cursor-pointer rounded-md hover:bg-gray-100`}
className={`flex items-center cursor-pointer rounded-md hover:bg-gray-100`}
onClick={() => (page !== item.value ? setPage(item.value) : {})}
>
<span
@ -150,7 +150,7 @@ const SidebarMenu = ({
}}
>
{/* profile */}
<div className="flex flex-row items-center mb-10">
<div className="flex items-center mb-10">
<Avatar size={60} rounded={true} />
<p className="text-green7B font-bold text-base flex-1 mx-2">
{user.firstName === null ? "" : user.firstName + " " + user.lastName}
@ -177,7 +177,7 @@ const SidebarMenu = ({
key={i}
>
<div
className={`flex flex-row items-center cursor-pointer rounded-md py-0 my-3 px-1`}
className={`flex items-center cursor-pointer rounded-md py-0 my-3 px-1`}
>
<img src={button.icon} alt="" />
<strong

@ -62,14 +62,14 @@ function Address({
<div className="flex items-center gap-x-4 mt-2">
<div
style={{ border: "solid 1px #fca5a5" }}
class="w-full flex flex-row items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
class="w-full flex items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
>
<button class="text-sm">{window.t("حذف")}</button>
<img src={trash} alt="delete-address" className="w-5 mr-3" />
</div>
<div
style={{ border: "solid 1px #12CF7F" }}
class="w-full flex flex-row items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
class="w-full flex items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
>
<button class="text-sm">{window.t("ویرایش")}</button>
<img src={editButton} alt="edit-address" className="w-5 mr-3 " />
@ -128,14 +128,14 @@ function Address({
<div className="flex flex-col items-center gap-y-2">
<div
style={{ border: "solid 1px #fca5a5" }}
class="w-full flex flex-row items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
class="w-full flex items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
>
<button class="text-sm">{window.t("حذف")}</button>
<img src={trash} alt="delete-address" className="w-5 mr-3" />
</div>
<div
style={{ border: "solid 1px #12CF7F" }}
class="w-full flex flex-row items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
class="w-full flex items-center justify-between px-2 py-1 rounded-sm cursor-pointer"
>
<button class="text-sm">{window.t("ویرایش")}</button>
<img src={editButton} alt="edit-address" className="w-5 mr-3 " />
@ -163,7 +163,7 @@ function Address({
/>
))}
</ul>
<div className="w-full flex flex-row justify-between items-center mt-4">
<div className="w-full flex justify-between items-center mt-4">
<button
className={`flex justify-center text-tiny py-3 rounded-md bg-grayF9 dark:bg-blueC0 dark:bg-opacity-10 w-full ${
isDark ? "text-white" : "text-gray70"
@ -193,7 +193,7 @@ function Address({
/>
))}
</ul>
<div className="w-full flex flex-row justify-between items-center mt-4">
<div className="w-full flex justify-between items-center mt-4">
<button
className={`flex justify-center text-tiny lg:text-sm rounded-md py-3 bg-grayF9 dark:bg-blueC0 dark:bg-opacity-30 ${
isDark ? "text-white" : "text-gray70"

@ -22,7 +22,7 @@ function PaymentMethods({ paymentMethods }) {
<strong className="font-medium dark:text-white text-base">
{window.t("انتخاب شیوه پرداخت")}
</strong>
<ul className="list-none p-0 m-0 flex flex-row justify-between flex-wrap">
<ul className="list-none p-0 m-0 flex justify-between flex-wrap">
{paymentMethods.map((method, index) => (
<Method method={method} key={index} />
))}

@ -62,7 +62,7 @@ function TransportDate({ transportDate, isMobile }) {
{/* <strong className="font-bold text-green7B dark:text-white lg:text-tiny">
زمان ارسال را انتخاب کنید
</strong>
<ul className="list-none p-0 m-0 flex flex-row justify-between flex-wrap w-full gap-4 mt-4">
<ul className="list-none p-0 m-0 flex justify-between flex-wrap w-full gap-4 mt-4">
{transportDate.times.map((time, index) => (
<Time time={time} key={index} />
))}
@ -73,7 +73,7 @@ function TransportDate({ transportDate, isMobile }) {
{/* <strong className="font-medium dark:text-white">
زمان ارسال را انتخاب کنید
</strong>
<ul className="list-none p-0 m-0 flex flex-row flex-wrap w-full gap-2">
<ul className="list-none p-0 m-0 flex flex-wrap w-full gap-2">
{transportDate.times.map((time, index) => (
<Time time={time} key={index} />
))}

@ -102,7 +102,7 @@ function TransportMethod({
<strong className="font-medium dark:text-white">
لطفا یک روش ارسال انتخاب کنید
</strong>
<ul className="list-none p-0 m-0 flex flex-row gap-5 flex-wrap">
<ul className="list-none p-0 m-0 flex gap-5 flex-wrap">
{list.map((method, index) => (
<Method
method={method}

@ -34,7 +34,7 @@ export const DeliveryForm = ({
const PriceStatus = ({ name, value, type }) => {
return (
<div className="w-full flex flex-row justify-between py-2">
<div className="w-full flex justify-between py-2">
<strong className="font-light text-sm dark:text-white">{name}</strong>
<span
className="font-bold text-sm dark:text-white"
@ -50,13 +50,13 @@ export const DeliveryForm = ({
return isMobile ? (
<div className="w-full flex flex-col pt-4 pb-4">
<div className="w-full flex flex-row gap-5">
<div className="w-full flex gap-5">
<Address addresses={list} setPhase={setPhase} />
</div>
<div className="w-full flex flex-row gap-5 mt-8">
<div className="w-full flex gap-5 mt-8">
<TransportMethod />
</div>
<div className="w-full flex flex-row gap-5 mt-8">
<div className="w-full flex gap-5 mt-8">
<TransportDate transportDate={form.transportDate} />
</div>
{isMobile && (
@ -80,19 +80,19 @@ export const DeliveryForm = ({
</div>
) : (
<div className="w-full flex flex-col px-4 pb-10">
<div className="w-full flex flex-row gap-5">
<div className="w-full flex gap-5">
<span className="w-6 h-6 rounded-full bg-grayF4 flex justify-center items-center text-sm">
1
</span>
<Address addresses={list} setPhase={setPhase} />
</div>
<div className="w-full flex flex-row gap-5 mt-8">
<div className="w-full flex gap-5 mt-8">
<span className="w-6 h-6 rounded-full bg-grayF4 flex justify-center items-center text-sm">
2
</span>
<TransportMethod />
</div>
{/* <div className="w-full flex flex-row gap-5 mt-8">
{/* <div className="w-full flex gap-5 mt-8">
<span className="w-6 h-6 rounded-full bg-grayF4 flex justify-center items-center text-sm">
3
</span>

@ -8,7 +8,7 @@ function NotFound({ title, subTitle, link }) {
return (
<Link
to={link}
className="flex flex-row items-center justify-between py-3.5 px-2 rounded-sm bg-blueC0 bg-opacity-10 mt-4 self-end lg:self-auto lg:ml-1/2 w-full lg:w-auto"
className="flex items-center justify-between py-3.5 px-2 rounded-sm bg-blueC0 bg-opacity-10 mt-4 self-end lg:self-auto lg:ml-1/2 w-full lg:w-auto"
>
<div className="flex flex-col w-full lg:w-full">
{title && <strong className="text-xs text-green4F text-opacity-70 lg:text-tiny">{title}</strong>}

@ -15,7 +15,7 @@ function Question({ item, selectFaq }) {
}
}
>
<div className="flex flex-row justify-between items-center">
<div className="flex justify-between items-center">
<strong className="flex-1 text-green4F text-xs lg:text-tiny font-medium dark:text-white lg:text-green4F">
{item.title}
</strong>

@ -41,7 +41,7 @@ function Faq({ headerOptions, setHeaderOptions, isMobile, list, getList, selectF
<Question key={index} item={item} selectFaq={selectFaq} />
))}
</div>
<div className="w-full flex flex-row lg:w-4/5 justify-end">
<div className="w-full flex lg:w-4/5 justify-end">
<NotFound
title={"پرسش خود را در لیست بالا پیدا نکردید؟"}
subTitle={"برای ما پیام ارسال کنید"}

@ -26,7 +26,7 @@ const Favorites = ({
}, []);
return (
<div className="flex flex-row flex-wrap">
<div className="flex flex-wrap">
{bookmarkList.map((bookmark, index) => (
<Bookmark key={index} bookmark={bookmark} />
))}

@ -23,7 +23,7 @@ const Part2 = ({ books }) => {
<div>
<Link
to="/products"
className="py-3 px-4 rounded bg-grayF4 text-blue3D text-tiny flex flex-row items-center"
className="py-3 px-4 rounded bg-grayF4 text-blue3D text-tiny flex items-center"
>
مشاهده بیشتر
<div className="transform rotate-90 translate-y-px mr-1">

@ -15,7 +15,7 @@ const Part4 = ({ books, grades }) => {
<div>
<Link
to="/products"
className="py-3 px-4 rounded bg-grayF4 text-blue3D text-tiny flex flex-row items-center"
className="py-3 px-4 rounded bg-grayF4 text-blue3D text-tiny flex items-center"
>
مشاهده بیشتر
<div className="transform rotate-90 translate-y-px mr-1">

@ -14,7 +14,7 @@ const SalesContainer = ({ books }) => {
return (
<div className="w-full my-10">
<div className="w-full py-10 pl-2 bg-white flex justify-between items-center gap-3">
<div className="flex flex-row items-center pl-4">
<div className="flex items-center pl-4">
{/* <div className="w-6 h-6 bg-blue-300 ml-4 rounded-full"></div> */}
<div className="text-3xl leading-normal">
<h3 className=" bg-blueC0 text-white text-center bold text-7xl">

@ -6,7 +6,7 @@ import _ from "lodash";
export default function Lights({ degrees}) {
return (
<div className="w-full">
<header className="container hidden flex-row px-12 lg:px-0 justify-between z-20 transform -translate-y-16 lg:-translate-y-24">
<header className="container hidden px-12 lg:px-0 justify-between z-20 transform -translate-y-16 lg:-translate-y-24">
{degrees.map((light, index) => (
<Light degree={light} key={index} />
))}

@ -101,10 +101,10 @@ function Page1({ list, top }) {
/>
</div>
<div
className="container flex flex-row justify-between relative transform translate-y-12"
className="container flex justify-between relative transform translate-y-12"
style={{ alignItems: "start" }}
>
<div className="list-none flex flex-row bg-blueB0 bg-opacity-40 p-2.5 rounded-md backdrop-filter backdrop-blur-md">
<div className="list-none flex bg-blueB0 bg-opacity-40 p-2.5 rounded-md backdrop-filter backdrop-blur-md">
<strong className="text-white text-sm font-light ml-1 border-l-2 pl-2 border-gray-300">
لیست محصولات
</strong>
@ -129,7 +129,7 @@ function Page1({ list, top }) {
</p>
<Link
to="/products"
className="flex flex-row items-center text-white text-xs bg-blueC0 px-4 py-3 rounded-md backdrop-filter backdrop-blur-md mt-5 self-end animate-bounce"
className="flex items-center text-white text-xs bg-blueC0 px-4 py-3 rounded-md backdrop-filter backdrop-blur-md mt-5 self-end animate-bounce"
>
ورود به فروشگاه <img src={arrowLeftWhite} alt="" className="mr-2" />
</Link>

@ -5,7 +5,7 @@ export default function PDF({ link }) {
return (
<a
href={link.value}
className="w-full flex flex-row justify-between py-3 px-4 rounded-md bg-yellow2 my-2"
className="w-full flex justify-between py-3 px-4 rounded-md bg-yellow2 my-2"
>
<p className="text-xs font-medium text-yellow1">{link.name}</p>
<img src={linkIcon} className="w-5 h-5" />

@ -6,7 +6,7 @@ export default function PDF({ pdf }) {
<a
download
href={pdf.value}
className="w-full flex flex-row justify-between py-3 px-4 rounded-md bg-redFF my-2"
className="w-full flex justify-between py-3 px-4 rounded-md bg-redFF my-2"
>
<p className="text-xs font-medium text-red5F">{pdf.name}</p>
<img src={pdfIcon} className="w-5 h-5" />

@ -44,7 +44,7 @@ function QrResult({ book, grades, checked, dataTypes, list }) {
)}
onClick={(e) => e.stopPropagation()}
>
<div className="w-full flex flex-row items-center">
<div className="w-full flex items-center">
<img src={book.imageUrl} alt={book.name} className="rounded-md w-1/3" />
<div className="flex flex-col">
<h1 className="font-semibold text-primary">{book.name}</h1>
@ -60,7 +60,7 @@ function QrResult({ book, grades, checked, dataTypes, list }) {
className="flex flex-col justify-start rounded-md border border-blueFE overflow-hidden"
style={{ borderWidth: 1, borderColor: "#C1E0FE", borderStyle: "solid" }}
>
<ul className="w-full flex flex-row list-none items-center">
<ul className="w-full flex list-none items-center">
{dataTypes.map((item, index) => (
<li
key={index}

@ -10,7 +10,7 @@ function Page3({ top, translateY }) {
<div
className={_.join(
[
"fixed left-0 h-screen w-full bg-white transition-opacity duration-1000 flex flex-row justify-center items-end z-30",
"fixed left-0 h-screen w-full bg-white transition-opacity duration-1000 flex justify-center items-end z-30",
top > 50 ? "opacity-0" : "opacity-100",
],
" "

@ -35,7 +35,7 @@ function Page4({ top }) {
رنگی پر نشد، به یاد هم باشیم شاید فردا ما هم در کنار هم نباشیم
</p>
<div
className="flex flex-row justify-center w-full mt-5"
className="flex justify-center w-full mt-5"
style={{ width: "30%" }}
>
<img src={bazarImage} alt="" className="w-36 mx-5 cursor-pointer" />

@ -18,7 +18,7 @@ export default function Question({ question }) {
onClick={() => setSelect(option)}
className={_.join(
[
"rounded-md w-full overflow-hidden flex flex-row items-center my-2 cursor-pointer transition-all duration-500",
"rounded-md w-full overflow-hidden flex items-center my-2 cursor-pointer transition-all duration-500",
],
" "
)}

@ -15,17 +15,17 @@ function Test({ title, duration, questions, translateY }) {
}}
>
<header
className="w-3/4 flex flex-row justify-between py-3 px-3 rounded-md"
className="w-3/4 flex justify-between py-3 px-3 rounded-md"
style={{ border: "1px solid #777" }}
>
<div className="flex flex-row items-center">
<div className="flex items-center">
<span
className="w-2 h-2 rounded-full ml-2"
style={{ backgroundColor: "#CEFDFF" }}
></span>
<h1 className="text-blueE8 text-md font-medium">{title}</h1>
</div>
<div className="flex flex-row items-center">
<div className="flex items-center">
<img src={timerIcon} className="w-4 h-4 ml-1" />
<div className="text-sm text-green71">
{_.join(["زمان باقیمانده", duration], " ")}

@ -36,7 +36,7 @@ function LessonPlayList({
{
<div className={_.join(["w-full mb-2.5 flex flex-col border"], " ")}>
{/* {bookId && (
<header className="mb-1 flex flex-row items-center">
<header className="mb-1 flex items-center">
<h3 className="py-1 px-2.5 m-0 bg-white inline">
{
realCategories.filter(
@ -57,7 +57,7 @@ function LessonPlayList({
<div
className={_.join(
[
"flex flex-row items-center py-2",
"flex items-center py-2",
video?.id === selectedVideo?.id ? "bg-white" : "",
],
" "

@ -31,7 +31,7 @@ function VodTube({
onClick={(e) => e.stopPropagation()}
className={_.join(
[
"fixed flex flex-row rtl pt-20 lg:px-5 xl:px-10 w-full bg-white dark:bg-black bg-opacity-80 transition-opacity duration-500 min-h-screen backdrop-filter backdrop-blur-md",
"fixed flex rtl pt-20 lg:px-5 xl:px-10 w-full bg-white dark:bg-black bg-opacity-80 transition-opacity duration-500 min-h-screen backdrop-filter backdrop-blur-md",
top > 10 ? "opacity-0 z-0" : "opacity-100 z-10",
],
" "
@ -59,7 +59,7 @@ function VodTube({
{/* <p className="desktop">{selectedVideo.text}</p> */}
</section>
<section className="md:hidden sm:hidden xs:hidden pb-7 flex flex-col">
<header className="flex flex-row justify-between items-center px-5 py-0">
<header className="flex justify-between items-center px-5 py-0">
<h2 className="m-0">نظرات</h2>
<button className="border-0">بستن نظرات</button>
</header>

@ -12,7 +12,7 @@ function Blogs({ list, isDark, setActive }) {
return (
<div className="w-full pr-4">
<div className="w-full flex flex-col rounded-md py-4 overflow-hidden">
<header className="w-full flex flex-row justify-between items-center">
<header className="w-full flex justify-between items-center">
<strong className="text-green7B dark:text-white font-bold text-base lg:text-sm">
خواندنیها
</strong>
@ -32,7 +32,7 @@ function Blogs({ list, isDark, setActive }) {
)}
</Link>
</header>
<ul className="list-none w-full overflow-x-scroll pt-3 flex flex-row pb-16 no-scrollbar">
<ul className="list-none w-full overflow-x-scroll pt-3 flex pb-16 no-scrollbar">
{list.map((blog, index) => (
<Blog blog={blog} key={index} setActive={setActive} />
))}
@ -47,7 +47,7 @@ const Blog = ({ blog, setActive }) => {
<li className="flex flex-col ml-3">
<Link
to={"/blogs/" + blog?.id}
className="flex flex-row justify-center items-end rounded-md"
className="flex justify-center items-end rounded-md"
style={{
background: `url(https://dnvn.ir/api/v1/file/${blog?.fileIds})`,
backgroundPosition: "contain",
@ -65,8 +65,8 @@ const Blog = ({ blog, setActive }) => {
<h2 className="text-xs font-semibold text-blue5F dark:text-white leading-5">
{blog.title}
</h2>
<div className="w-full flex flex-row justify-between items-center mt-3">
<div className="flex flex-row items-center">
<div className="w-full flex justify-between items-center mt-3">
<div className="flex items-center">
<img
src={`https://dnvn.ir/api/v1/file/${blog?.fileIds}`}
alt=""
@ -76,7 +76,7 @@ const Blog = ({ blog, setActive }) => {
{"حامد دژبانی نسب"}
</span>
</div>
<div className="flex flex-row items-center">
<div className="flex items-center">
<span className="text-xs font-light text-gray70 dark:text-greenBA">
{_.join(["زمان مناسب", "30"], " ")}
</span>

@ -41,7 +41,7 @@ function MyBooks({ books, grades, isMobile }) {
کتابهای من
</strong>
{isMobile ? (
<ul className="list-none w-full overflow-x-scroll pt-2 flex flex-row lg:pt-5 lg:flex-wrap lg:overflow-y-scroll gap-3 lg:gap-10 no-scrollbar">
<ul className="list-none w-full overflow-x-scroll pt-2 flex lg:pt-5 lg:flex-wrap lg:overflow-y-scroll gap-3 lg:gap-10 no-scrollbar">
{books?.slice(0, 5)?.map((book, index) => (
<Book book={book} key={index} />
))}

@ -47,7 +47,7 @@ function Videos({ videos, grades, isDark, isMobile }) {
return (
<div className="w-full px-4 lg:py-4">
<div className="w-full flex flex-col py-4 lg:px-3 overflow-hidden lg:border lg:border-solid lg:border-gray-200 rounded-md lg:bg-blueC0 lg:bg-opacity-5">
<header className="w-full flex flex-row justify-between items-center">
<header className="w-full flex justify-between items-center">
<strong className="text-green7B dark:text-white font-bold text-base lg:text-base mt-2">
دورههای ویدئویی شما
</strong>
@ -66,7 +66,7 @@ function Videos({ videos, grades, isDark, isMobile }) {
)}
</header>
{isMobile ? (
<ul className="list-none w-full overflow-x-scroll pt-3 gap-3 lg:gap-5 flex flex-row lg:pt-5 lg:flex-wrap lg:overflow-y-scroll no-scrollbar">
<ul className="list-none w-full overflow-x-scroll pt-3 gap-3 lg:gap-5 flex lg:pt-5 lg:flex-wrap lg:overflow-y-scroll no-scrollbar">
{videos?.slice(0, 5)?.map((video, index) => (
<Video video={video} key={index} />
))}

@ -6,7 +6,7 @@ import interactiveIcon from "../../../../../assets/icons/interactive.svg";
function Features({ features }) {
return (
<div className="w-full flex flex-row flex-wrap justify-between px-2">
<div className="w-full flex flex-wrap justify-between px-2">
{features.map((feature, index) => (
<Feature feature={feature} key={index} />
))}

@ -66,7 +66,7 @@ function Header({ list }) {
<div className="w-full flex justify-center mt-5">
<Link
to="/products"
className="flex flex-row items-center text-white text-tiny bg-blueC0 px-4 py-3 rounded-md backdrop-filter backdrop-blur-md mt-5 self-end"
className="flex items-center text-white text-tiny bg-blueC0 px-4 py-3 rounded-md backdrop-filter backdrop-blur-md mt-5 self-end"
>
ورود به فروشگاه
</Link>
@ -79,7 +79,7 @@ function Header({ list }) {
</div>
<h1 className="inline">با طعم لذت</h1>
</div>
<div className="flex flex-row my-1.5">
<div className="flex my-1.5">
<h1 className="inline">از اول تا یازدهم &nbsp;</h1>
<div className="relative">
<h1 className="inline z-20 pb-1">کنارتونیم</h1>

@ -15,7 +15,7 @@ function Platforms({ platforms }) {
const Platform = ({ platform }) => {
return (
<div
className="w-full flex flex-row rounded-sm p-4 items-start mb-5"
className="w-full flex rounded-sm p-4 items-start mb-5"
style={{
backgroundColor: platform.backgroundColor,
border: `1px solid ${platform.borderColor}`,

@ -13,12 +13,12 @@ function Responsive() {
}}
>
<div className="flex flex-col items-center text-center font-extrabold text-blue5F dark:text-gray-300 text-lg mt-3 transform translate-y-4">
<div className="flex flex-row ">
<div className="flex ">
<h1 className="inline z-50">
از طریق موبایل یا کامپیوتر میتونی
</h1>
</div>
<div className="flex flex-row my-1.5">
<div className="flex my-1.5">
<div className="relative">
<h1 className="inline z-50 pb-1">به محتوای دیجیتال &nbsp;</h1>
<span className="h-1 w-full absolute bottom-0 left-0 bg-green1"></span>

@ -3,8 +3,8 @@ import _ from "lodash";
export default function Book({ book }) {
return (
<div className="w-full flex flex-row justify-between py-3 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex flex-row items-center flex-1">
<div className="w-full flex justify-between py-3 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex items-center flex-1">
<img
src={book}
className="rounded-md"
@ -16,7 +16,7 @@ export default function Book({ book }) {
<span className="mt-2 text-xs lg:text-sm text-gray70 dark:text-white">نسخه دیجیتال</span>
</div>
</div>
<div className="flex flex-row items-center">
<div className="flex items-center">
<span className="py-1 px-2 rounded-sm text-green4F2 text-sm lg:text-base bg-grayF9 dark:bg-gray-500 dark:text-white">
1
</span>

@ -25,11 +25,11 @@ function OrderDetails({ order, setHeaderOptions, headerOptions }) {
},[]);
return (
<div className="px-4 flex flex-col py-5 lg:pt-24 lg:w-3/5 lg:mx-auto">
<div className="flex flex-row w-full justify-between items-center p-3 bg-blueC0 bg-opacity-10 rounded-t-md dark:bg-blueC0 dark:bg-opacity-10">
<div className="flex w-full justify-between items-center p-3 bg-blueC0 bg-opacity-10 rounded-t-md dark:bg-blueC0 dark:bg-opacity-10">
<strong className="font-medium text-sm lg:text-tiny text-blue52 dark:text-white">
{_.join(["شماره سفارش:", order.number], " ")}
</strong>
<div className="flex flex-row items-center">
<div className="flex items-center">
<span className="text-xs lg:text-tiny font-light text-blue52 dark:text-white">
{status[order.status]}
</span>
@ -39,20 +39,20 @@ function OrderDetails({ order, setHeaderOptions, headerOptions }) {
></div>
</div>
</div>
<div className="w-full flex flex-row items-center py-4 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="w-full flex items-center py-4 border-b border-solid border-blueFF1 dark:border-gray45">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">آدرس تحویل:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.address}
</span>
</div>
<div className="w-full flex flex-row justify-between py-0 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex flex-row py-4">
<div className="w-full flex justify-between py-0 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">مشخصات تحویل گیرنده:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.name}
</span>
</div>
<div className="flex flex-row py-4">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">شماره موبایل:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.cellphone}
@ -72,50 +72,50 @@ function OrderDetails({ order, setHeaderOptions, headerOptions }) {
<Book book={item} key={index} />
))}
</div>
<div className="w-full flex flex-row justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex flex-row py-4">
<div className="w-full flex justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">مبلغ سبد خرید:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{_.join([order.shoppingCardPrice, "تومان"], " ")}
</span>
</div>
<div className="flex flex-row py-4">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">تخفیف:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{_.join([order.discountPrice, "تومان"], " ")}
</span>
</div>
</div>
<div className="w-full flex flex-row justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex flex-row py-4">
<div className="w-full flex justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white"> هزینه ارسال کالا:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{_.join([order.sendPrice, "تومان"], " ")}
</span>
</div>
<div className="flex flex-row py-4 border">
<div className="flex py-4 border">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">جمع هزینه پرداختی:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{_.join([order.totalPrice, "تومان"], " ")}
</span>
</div>
</div>
<div className="w-full flex flex-row justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex flex-row py-4">
<div className="w-full flex justify-between py-2 border-b border-solid border-blueFF1 dark:border-gray45">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">نحوه پرداخت:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.payMethod}
</span>
</div>
<div className="flex flex-row py-4">
<div className="flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white"> شماره تراکنش:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.transactionNumber}
</span>
</div>
</div>
<div className="w-full flex flex-row justify-between py-2">
<div className="w-full flex flex-row py-4">
<div className="w-full flex justify-between py-2">
<div className="w-full flex py-4">
<strong className="text-xs lg:text-tiny text-green4F dark:text-white">تاریخ تحویل:</strong>
<span className="flex-1 font-light text-right mr-2 text-xs lg:text-tiny text-green4F dark:text-white">
{order.date}

@ -21,11 +21,11 @@ const status = {
function Order({ order, isMobile }) {
return (
<div className="w-full flex flex-col rounded-md overflow-hidden my-3 border border-solid border-blueC0 border-opacity-50 dark:border-blueC0 dark:border-opacity-10 lg:w-4/5 mx-auto">
<div className="flex flex-row w-full justify-between items-center p-3 bg-blueC0 bg-opacity-10 dark:bg-blueC0 dark:bg-opacity-10">
<div className="flex w-full justify-between items-center p-3 bg-blueC0 bg-opacity-10 dark:bg-blueC0 dark:bg-opacity-10">
<strong className="font-medium text-sm lg:text-tiny text-green4F dark:text-white">
{_.join(["شماره سفارش:", order.number], " ")}
</strong>
<div className="flex flex-row items-center">
<div className="flex items-center">
<span className="text-xs lg:text-tiny font-light text-green4F dark:text-white">
{status[order.status]}
</span>
@ -35,9 +35,9 @@ function Order({ order, isMobile }) {
></div>
</div>
</div>
<div className="w-full flex flex-row justify-between p-3">
<div className="w-full flex justify-between p-3">
<div className="flex flex-col">
<div className="flex flex-row mb-2">
<div className="flex mb-2">
{order.items.length < 2
? order?.items?.map((item, index) => (
<img
@ -63,7 +63,7 @@ function Order({ order, isMobile }) {
))}
{isMobile && order.items.length >= 2 && (
<div
className="flex flex-row items-center justify-center relative rounded-md overflow-hidden bg-grayEE dark:bg-gray-400"
className="flex items-center justify-center relative rounded-md overflow-hidden bg-grayEE dark:bg-gray-400"
style={{
width: 60,
height: 90,
@ -104,7 +104,7 @@ function Order({ order, isMobile }) {
</strong>
<Link
to="/orders/order"
className="rounded-md flex flex-row justify-center px-5 py-2.5 border border-solid border-blueC0 text-green4F bg-blueC0 bg-opacity-10"
className="rounded-md flex justify-center px-5 py-2.5 border border-solid border-blueC0 text-green4F bg-blueC0 bg-opacity-10"
>
جزئیات سفارش
<img

@ -7,8 +7,8 @@ function Comment({ comment }) {
className="flex flex-col py-3 px-2 rounded-md shadow-all border border-gray-200 border-solid dark:border-opacity-10 ml-4 w-auto"
style={{ minWidth: "250px" }}
>
<header className="flex flex-row justify-between">
<div className="flex flex-row items-center">
<header className="flex justify-between">
<div className="flex items-center">
<img src={userImage} alt="" className="h-10 w-10 rounded-full" />
<strong className="text-blue5F text-md mr-1 dark:text-white">
{comment?.name}

@ -16,7 +16,7 @@ export const ProductOverAll = ({ book, grades, isDark, loading }) => {
const [type, setType] = useState("1");
return (
<div className="w-full flex flex-col">
<header className={`w-full flex flex-row justify-between gap-5`}>
<header className={`w-full flex justify-between gap-5`}>
<ProductImages images={book?.fileIds} />
<div className="flex flex-col w-1/2 divide-y divide-solid divide-gray-200">
<div className="w-full flex flex-col pr-2 py-2 border-0">
@ -43,7 +43,7 @@ export const ProductOverAll = ({ book, grades, isDark, loading }) => {
به من کمک کن انتخاب کنم
</p>
</div>
<div className="w-full flex flex-row justify-between items-center mt-4 gap-5">
<div className="w-full flex justify-between items-center mt-4 gap-5">
<Button
title="نسخه فیزیکی"
backgroundColor={isDark ? "bg-transparent" : "bg-white"}
@ -102,7 +102,7 @@ export const ProductOverAll = ({ book, grades, isDark, loading }) => {
<div className="flex py-4">
<Link
to={"/videos/" + book?.id}
className="bg-blueC0 text-green7B bg-opacity-5 font-semibold text-tiny rounded-md border border-solid border-blueC0 w-2/3 py-4 text-center flex flex-row items-center justify-center"
className="bg-blueC0 text-green7B bg-opacity-5 font-semibold text-tiny rounded-md border border-solid border-blueC0 w-2/3 py-4 text-center flex items-center justify-center"
>
مشاهده دوره ویدیویی این محصول
<img

@ -9,7 +9,7 @@ import Progress from "../../../components/Progress";
function Rate({ avarage, all, fields, desktop }) {
return (
<div className="w-full flex flex-row justify-between items-center mt-5">
<div className="w-full flex justify-between items-center mt-5">
<div className="flex flex-col items-center justify-center h-full ml-4">
{
desktop ?

@ -79,7 +79,7 @@ export const Product = ({
</div>
</header>
<ul
className="list-none flex flex-row divide-x items-center mt-5"
className="list-none flex divide-x items-center mt-5"
style={{ direction: "ltr" }}
>
<li className="border-solid border-blueFE flex-1 flex-shrink-0 text-center text-tiny leading-5 font-medium text-green7B dark:text-white">
@ -95,7 +95,7 @@ export const Product = ({
<h2 className="text-green7B text-base font-semibold mt-10 dark:text-greenBA">
نسخه محصول را انتخاب کنید
</h2>
<div className="w-full flex flex-row justify-between items-center mt-5">
<div className="w-full flex justify-between items-center mt-5">
<ButtonBetween
width="100%"
item={"خرید نسخه فیزیکی کتاب"}
@ -111,7 +111,7 @@ export const Product = ({
}
/>
</div>
<div className="w-full flex flex-row justify-between items-center mt-4 gap-2">
<div className="w-full flex justify-between items-center mt-4 gap-2">
<ButtonBetween
width="72%"
item={"خرید نسخه دیجیتال کتاب"}
@ -134,7 +134,7 @@ export const Product = ({
مشاهده نمونه
</a>
</div>
<div className="w-full flex flex-row justify-between items-center mt-4">
<div className="w-full flex justify-between items-center mt-4">
<ButtonBetween
width="72%"
item={"خرید نسخه ویدئویی کتاب"}
@ -173,7 +173,7 @@ export const Product = ({
<Rate value={book?.rate || 0} />
</div>
<div
className="flex flex-row w-full pb-4 mt-10 no-scrollbar"
className="flex w-full pb-4 mt-10 no-scrollbar"
style={{ overflowX: "scroll" }}
>
{[0, 1, 2, 2].map((comment, index) => (

@ -40,9 +40,9 @@ export const Products = ({
</div>
) : (
<div
className={`w-full flex flex-row gap-10 px-5 overflow-y-hidden mt-3 justify-center lg:pt-24 lg:mt-0`}
className={`w-full flex gap-10 px-5 overflow-y-hidden mt-3 justify-center lg:pt-24 lg:mt-0`}
>
<div className="w-11/12 flex flex-row gap-5 justify-end">
<div className="w-11/12 flex gap-5 justify-end">
<Sidebar />
<Main books={books} grades={grades} />
</div>

@ -248,7 +248,7 @@ export const Main = ({
</div>
)}
<div className="w-full flex flex-row flex-wrap mt-0 border-t-2 border-solid border-gray-100 overflow-y-hidden gap-4 justify-evenly pt-3">
<div className="w-full flex flex-wrap mt-0 border-t-2 border-solid border-gray-100 overflow-y-hidden gap-4 justify-evenly pt-3">
{elements
?.slice((page - 1) * num, page * num)
.map((product, index) => (

@ -45,7 +45,7 @@ export const Sidebar = ({
return (
<div className="flex flex-col">
<div
className="flex flex-row justify-between items-center py-5 cursor-pointer"
className="flex justify-between items-center py-5 cursor-pointer"
onClick={() => dropdownActionMap[name]()}
>
<strong className="font-semibold text-tiny text-green4F">
@ -69,7 +69,7 @@ export const Sidebar = ({
{list.map((item, index) => (
<li
key={index}
className="flex flex-row items-center mb-3"
className="flex items-center mb-3"
onClick={() =>
active !== item
? setFilterOptions({ ...filterOptions, [name]: item })
@ -88,7 +88,7 @@ export const Sidebar = ({
const CkeckItem = ({ title, name }) => {
return (
<div
className="flex flex-row justify-between items-center py-4"
className="flex justify-between items-center py-4"
onClick={() =>
setFilterOptions({
...filterOptions,

@ -30,7 +30,7 @@ export const Header = ({
700
)}
/>
<div className="w-full flex flex-row justify-between mt-3">
<div className="w-full flex justify-between mt-3">
<Select
margin="ml-1"
fill="fill-green-700 dark:fill-white"

@ -83,7 +83,7 @@ export const Main = ({ books, filterOptions, grades }) => {
<span className="text-tiny lg:text-sm text-green7B dark:text-greenBA font-light mb-4">
{"پایه" + " " + grades[product?.gradeId]}
</span>
<div className="w-full flex flex-row justify-center font-bold lg:font-medium text-lg lg:text-tiny text-blue5F dark:text-white">
<div className="w-full flex justify-center font-bold lg:font-medium text-lg lg:text-tiny text-blue5F dark:text-white">
{product?.product[2]?.price + " " + "تومان"}
</div>
</Link>
@ -106,7 +106,7 @@ export const Main = ({ books, filterOptions, grades }) => {
<span className="text-tiny lg:text-xs text-green7B dark:text-greenBA font-light mb-4">
{"پایه" + " " + grades[product?.gradeId]}
</span>
<div className="w-full flex flex-row justify-center font-bold lg:font-medium text-lg lg:text-sm text-blue5F dark:text-white">
<div className="w-full flex justify-center font-bold lg:font-medium text-lg lg:text-sm text-blue5F dark:text-white">
{product?.product[0]?.price + " " + "تومان"}
</div>
</Link>
@ -127,7 +127,7 @@ export const Main = ({ books, filterOptions, grades }) => {
<span className="text-tiny lg:text-xs text-green7B dark:text-greenBA font-light mb-4">
{"پایه" + " " + grades[product?.gradeId]}
</span>
<div className="w-full flex flex-row justify-center font-bold lg:font-medium text-lg lg:text-sm text-blue5F dark:text-white">
<div className="w-full flex justify-center font-bold lg:font-medium text-lg lg:text-sm text-blue5F dark:text-white">
{product?.product[1]?.price + " " + "تومان"}
</div>
</Link>

@ -4,7 +4,7 @@ import linkIcon from "./links.svg";
export default function Links({ data }) {
return (
<div className="w-full flex-row justify-between items-center rounded-md bg-yellow-100 bg-opacity-20 py-3 px-2 mt-5 relative dark:bg-opacity-10">
<div className="w-full justify-between items-center rounded-md bg-yellow-100 bg-opacity-20 py-3 px-2 mt-5 relative dark:bg-opacity-10">
<div className="flex flex-col">
<strong className="text-sm font-normal dark:text-white">لینک ها</strong>
{data.map((link, i) => (

@ -3,7 +3,7 @@ import pdfIcon from "./pdf.svg";
export default function PDF({ data }) {
return (
<div className="w-full flex-row justify-between items-center rounded-md bg-red-100 bg-opacity-50 py-6 px-2 mt-5 relative dark:bg-opacity-10">
<div className="w-full justify-between items-center rounded-md bg-red-100 bg-opacity-50 py-6 px-2 mt-5 relative dark:bg-opacity-10">
<strong className="text-right text-red-900 text-xs font-normal dark:text-white">{data.name}</strong>
<img src={pdfIcon} className="w-8 absolute left-2 top-1/2 transform -translate-y-1/2" />
</div>

@ -12,7 +12,7 @@ export default function Tab({ data }) {
const [dataType, setDataType] = useState("all");
return (
<div className="w-full flex flex-col rounded-md overflow-hidden mt-5 border border-solid border-blueFF1 dark:border-opacity-10">
<div className="w-full flex flex-row justify-between">
<div className="w-full flex justify-between">
<button
onClick={() => setDataType("all")}
className={`py-2 w-1/6 border-b border-solid text-blueC0 text-sm dark:bg-opacity-10 dark:text-white border-blueFF1 dark:border-opacity-10 ${

@ -10,7 +10,7 @@ function Code({ codeId, setCodeId, userId, factorId }) {
}
return (
<div className="flex w-full flex-row border border-blueC0 border-solid rounded-md mt-3 mb-4 overflow-hidden lg:w-2/5 lg:mt-5">
<div className="flex w-full border border-blueC0 border-solid rounded-md mt-3 mb-4 overflow-hidden lg:w-2/5 lg:mt-5">
<input
type="text"
className="border-0 flex-1 text-right pr-3 font-medium text-tiny dark:bg-gray2077 placeholder:text-blue5F dark:text-white outline-none lg:text-base lg:font-bold"

@ -11,8 +11,8 @@ import deleteIcon from "../../../assets/icons/delete.svg";
function Product({ product, grades, pushToCart, isMobile, loading }) {
return isMobile ? (
<div className="flex flex-row justify-between py-5 border-b border-solid border-grayDB dark:border-gray45">
<div className="flex flex-row ">
<div className="flex justify-between py-5 border-b border-solid border-grayDB dark:border-gray45">
<div className="flex ">
<img
src={"https://dnvn.ir/api/v1/file/" + product.product.book.fileIds}
className="rounded-md w-20"
@ -48,7 +48,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
/>
<div className="flex flex-col items-center">
{product.productType === 2 && (
<div className="flex flex-row items-center mb-3">
<div className="flex items-center mb-3">
<button
className="rounded-md pt-2 pb-1.5 px-3 border border-solid border-blueC0 text-blueC0"
onClick={() =>
@ -114,7 +114,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
</div>
) : (
<div
className="flex flex-row w-full gap-10 py-4 border-b border-solid border-gray-200"
className="flex w-full gap-10 py-4 border-b border-solid border-gray-200"
onClick={() => localStorage.setItem("cartItem", product?.id)}
>
<div className="w-3/4 flex flex-row">
@ -126,7 +126,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
<strong className="text-lg text-blue5F mb-1 dark:text-white font-semibold">
{product?.product?.book?.name}
</strong>
<div className="flex flex-row items-center mt-4">
<div className="flex items-center mt-4">
<span className="w-2 h-2 bg-greenBA rounded-md ml-1"></span>
<div className="text-gray70 text-sm dark:text-greenBA">
{"پایه" + " " + grades[product?.product?.book?.gradeId]}
@ -136,7 +136,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
{product?.productType === 2 ? "نسخه فیزیکی" : "نسخه دیجیتال"}
</div>
</div>
<div className="flex flex-row items-center pl-4 mt-6">
<div className="flex items-center pl-4 mt-6">
<strong className="font-semibold text-xl text-blue5F dark:text-white">
&nbsp;{separate(product?.product?.price * product.count)}
&nbsp;&nbsp;تومان
@ -144,7 +144,7 @@ function Product({ product, grades, pushToCart, isMobile, loading }) {
</div>
</div>
</div>
<div className="w-1/4 flex flex-row items-center">
<div className="w-1/4 flex items-center">
<button
className="rounded-md pt-1 px-1.5 border border-solid border-blueC0 text-blueC0 text-lg font-bold"
onClick={() =>

@ -85,7 +85,7 @@ function ShoppingCart({
const Table = () => {
return (
<div className="w-full flex flex-col">
<header className="w-full flex flex-row gap-10">
<header className="w-full flex gap-10">
<strong className="w-3/4 pb-2 border-b border-solid border-gray-200 text-gray70 text-sm font-normal">
کالاهای انتخابی
</strong>
@ -112,7 +112,7 @@ function ShoppingCart({
const PriceStatus = ({ name, value, type }) => {
return isMobile ? (
<div className="w-full flex flex-row justify-between py-3">
<div className="w-full flex justify-between py-3">
<strong className="font-semibold text-tiny dark:text-white text-blue5F">
{name}
</strong>
@ -138,7 +138,7 @@ function ShoppingCart({
</span>
</div>
) : (
<div className="w-full flex flex-row justify-between py-4">
<div className="w-full flex justify-between py-4">
<strong className="font-semibold text-tiny dark:text-white text-blue5F">
{name}
</strong>
@ -217,7 +217,7 @@ function ShoppingCart({
type="error"
/> */}
</div>
<div className="flex flex-row justify-between items-center w-full py-3">
<div className="flex justify-between items-center w-full py-3">
<strong className="font-bold text-tiny text-blue5F dark:text-white">
جمع کل سبد خرید
</strong>
@ -228,7 +228,7 @@ function ShoppingCart({
</p>
</div>
<div
className="w-full rounded-md flex flex-row justify-center items-center py-2.5 px-3 mt-5 mb-4"
className="w-full rounded-md flex justify-center items-center py-2.5 px-3 mt-5 mb-4"
style={{ backgroundColor: isDark ? "#DEFFF111" : "#DEFFF188" }}
>
<img src={alertIcon} className="w-5 ml-2" />
@ -246,7 +246,7 @@ function ShoppingCart({
/>
{phase !== "products" && (
<button
className="bg-transparent mt-4 text-base border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 flex flex-row justify-center items-center"
className="bg-transparent mt-4 text-base border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 flex justify-center items-center"
onClick={() => setPhase("products")}
>
{window.t("بازگشت")}
@ -271,7 +271,7 @@ function ShoppingCart({
</div>
) : (
<div
className={`w-11/12 mx-auto flex flex-row relative gap-10 px-5 mt-10 pb-20 pt-16 ${
className={`w-11/12 mx-auto flex relative gap-10 px-5 mt-10 pb-20 pt-16 ${
desktopContentTransform ? "top-24" : ""
}`}
>
@ -309,7 +309,7 @@ function ShoppingCart({
type="error"
/> */}
</div>
<div className="flex flex-row justify-between items-center w-full py-4 border-t border-b border-grayDB border-solid">
<div className="flex justify-between items-center w-full py-4 border-t border-b border-grayDB border-solid">
<strong className="font-semibold text-tiny text-blue5F dark:text-white">
جمع کل سبد خرید
</strong>
@ -322,7 +322,7 @@ function ShoppingCart({
</div>
{phase === "products" && (
<div
className="w-full rounded-md flex flex-row justify-center items-center py-2.5 px-3 mt-5 mb-4"
className="w-full rounded-md flex justify-center items-center py-2.5 px-3 mt-5 mb-4"
style={{ backgroundColor: "#DEFFF188" }}
>
<img src={alertIcon} className="w-5 ml-2" />
@ -377,7 +377,7 @@ function ShoppingCart({
/>
{phase === "deliveryForm" && (
<button
className="bg-transparent mt-4 text-base lg:text-tiny border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 lg:py-4 flex flex-row justify-center items-center"
className="bg-transparent mt-4 text-base lg:text-tiny border border-blueC0 text-blueC0 font-bold rounded-md py-3.5 lg:py-4 flex justify-center items-center"
onClick={() => setPhase("products")}
>
{window.t("بازگشت")}

@ -18,7 +18,7 @@ const Videos = ({ videos }) => {
return (
<div
className="flex flex-row w-full bg-gray-300"
className="flex w-full bg-gray-300"
style={{ height: "calc(100vh / 1.5)" }}
></div>
);

@ -110,7 +110,7 @@ const Season = ({
onClick={() => toggle(season[0].categoryId)}
>
<button
className="flex flex-row justify-between items-center rounded-md py-3 px-3 mb-3 bg-blueC0 bg-opacity-5 border border-solid border-green-300"
className="flex justify-between items-center rounded-md py-3 px-3 mb-3 bg-blueC0 bg-opacity-5 border border-solid border-green-300"
// onClick={() =>
// setActiveSeason(season.name === activeSeason ? null : season.name)
// }
@ -148,7 +148,7 @@ const Season = ({
) : (
<li className="w-full flex flex-col bg-blueC0 bg-opacity-10 rounded-md overflow-hidden shadow-md mb-1">
<header
className="w-full flex flex-row justify-between items-center py-3 px-6"
className="w-full flex justify-between items-center py-3 px-6"
onClick={() => toggle(season[0].categoryId)}
>
<strong className="text-tiny text-green7B font-medium">

@ -56,7 +56,7 @@ function Video({
)}
<div className="w-full flex flex-col">
<div
className="w-full flex flex-row flex-1 = relative overflow-hidden"
className="w-full flex flex-1 = relative overflow-hidden"
style={{}}
>
<img
@ -111,7 +111,7 @@ function Video({
</div>
) : (
<div className="flex flex-col w-11/12 min-h-screen mx-auto pb-20 pt-24">
<header className="w-full flex flex-row gap-12">
<header className="w-full flex gap-12">
<div className="w-9/12">
<Videos videos={book?.fileIds} />
{seasons?.length > 0 && (
@ -185,11 +185,11 @@ function Video({
</div>
</div>
<div className="bg-grayF9 w-full flex flex-col rounded-md divide-y divide-solid divide-gray-200 mb-4 px-4">
<div className="flex flex-row items-center w-full gap-5 my-5">
<div className="flex items-center w-full gap-5 my-5">
<img src={tickIcon} alt="" className="w-9" />
<p className="text-blue52 text-sm font-light">{`توصیه خرید توسط ${book?.product[2]?.suggestedCounter} نفر`}</p>
</div>
<div className="flex flex-row items-center py-3">
<div className="flex items-center py-3">
<img
src={
isDark ? bookmarkDeactiveDarkIcon : bookmarkDeactiveLightIcon
@ -203,7 +203,7 @@ function Video({
</span>
</div>
<div className="flex flex-col w-full py-4 px-4">
<div className="flex flex-row items-center justify-center gap-2">
<div className="flex items-center justify-center gap-2">
<strong className="text-blueC0 text-5xl">
{separate(book?.product[2]?.price)}
</strong>
@ -240,7 +240,7 @@ function Video({
</div>
<Link
to={"/products/" + location.getId()}
className="bg-blueC0 text-green7B bg-opacity-5 font-semibold text-tiny rounded-md border border-solid border-blueC0 w-full py-4 text-center flex flex-row items-center justify-center"
className="bg-blueC0 text-green7B bg-opacity-5 font-semibold text-tiny rounded-md border border-solid border-blueC0 w-full py-4 text-center flex items-center justify-center"
>
مشاهده کتاب این محصول
<img src={arrow} alt="" className="mr-2 transform rotate-90 w-5" />

@ -5,7 +5,7 @@ const Season = ({ season }) => {
const Unit = ({ unit }) => {
return (
<div className="w-full flex flex-col rounded-md overflow-hidden mb-3 border border-solid border-blueFE dark:border-opacity-60 bg-blueFF dark:bg-opacity-10">
<div className="w-full flex flex-row justify-between items-center py-3 px-2 border-b border-solid border-blueFE dark:border-opacity-60">
<div className="w-full flex justify-between items-center py-3 px-2 border-b border-solid border-blueFE dark:border-opacity-60">
<strong className="text-blueC0 text-sm dark:text-white font-normal">
{unit.name}
</strong>
@ -17,7 +17,7 @@ const Season = ({ season }) => {
{unit.play && (
<Link
to={"/videos/0/display"}
className="flex flex-1 flex-row items-center py-2.5 px-2 border-l border-solid border-blueFE dark:border-opacity-60 justify-center text-sm text-blueC0 dark:text-white"
className="flex flex-1 items-center py-2.5 px-2 border-l border-solid border-blueFE dark:border-opacity-60 justify-center text-sm text-blueC0 dark:text-white"
>
نمایش
</Link>
@ -25,7 +25,7 @@ const Season = ({ season }) => {
{unit.download && (
<Link
to="/videos/0/download"
className="flex flex-1 flex-row items-center py-2.5 px-2 justify-center text-sm text-blueC0 dark:text-white"
className="flex flex-1 items-center py-2.5 px-2 justify-center text-sm text-blueC0 dark:text-white"
>
دانلود
</Link>
@ -36,7 +36,7 @@ const Season = ({ season }) => {
};
return (
<div className="w-full flex flex-col">
<button className="flex flex-row justify-between items-center rounded-md py-3 px-3 mb-3 bg-blueC0">
<button className="flex justify-between items-center rounded-md py-3 px-3 mb-3 bg-blueC0">
<strong className="text-sm text-white font-medium">
{season.name}
</strong>

@ -39,7 +39,7 @@ function VideoDisplay({
</div>
) : (
<div className="w-11/12 flex flex-col mb-6 justify-center items-center mx-auto pt-24 pb-20">
<div className="w-full flex flex-row justify-between overflow-hidden relative gap-2 mt-4">
<div className="w-full flex justify-between overflow-hidden relative gap-2 mt-4">
<div className="flex flex-col w-8/12">
<JolPlayer
fileIds={selectedVideo?.fileIds}

@ -8,7 +8,7 @@ function MostViewedVideo({ videos, grades }) {
return (
<div className="w-full flex flex-col">
<Header title="پربازدیدترین" link="/videos/video" />
<div className="w-full flex flex-row overflow-x-scroll pb-4 no-scrollbar">
<div className="w-full flex overflow-x-scroll pb-4 no-scrollbar">
{videos.map((video, index) => (
<Video key={index} video={video} grades={grades} />
))}
@ -24,7 +24,7 @@ const Video = ({ video, grades }) => {
className="flex flex-col rounded-md ml-4 shadow-md p-2 border border-solid border-gray-200 dark:border-opacity-30 mt-3"
>
<div
className="w-full flex flex-row flex-1 justify-between items-center relative overflow-hidden"
className="w-full flex flex-1 justify-between items-center relative overflow-hidden"
style={{
backgroundImage: `url(${posterImage})`,
backgroundSize: "100% 100%",
@ -44,7 +44,7 @@ const Video = ({ video, grades }) => {
<strong className="text-base mt-0 text-blue5F dark:text-white font-bold">
{"دوره ویدئویی" + " " + video.name}
</strong>
<div className="w-full flex flex-row justify-between items-center mt-3">
<div className="w-full flex justify-between items-center mt-3">
<span className="text-green7B text-sm dark:text-white">
{"پایه" + " " + grades[video.gradeId]}
</span>

@ -9,7 +9,7 @@ const NewestVideo = ({ videos, grades }) => {
return (
<div className="w-full flex flex-col">
<Header title="جدیدترین دورهها" link="/videos/video" />
<div className="w-full flex flex-row flex-wrap justify-between overflow-x-scroll mt-3">
<div className="w-full flex flex-wrap justify-between overflow-x-scroll mt-3">
{videos.slice(0, 4).map((video, index) => (
<Video key={index} video={video} grades={grades} />
))}

@ -15,7 +15,7 @@ const VerticalGradeFilter = ({ grades }) => {
return (
<div className="w-full flex flex-col mt-3">
<Header title={"پایه تحصیلی"} link="videos/video" />
<div className="flex flex-row w-full overflow-x-scroll pb-3">
<div className="flex w-full overflow-x-scroll pb-3">
{Object.keys(grades).map((grade, index) => (
<Grade grade={grade} key={index} />
))}

Loading…
Cancel
Save