diff --git a/app/component/modalSearchCity/ButtonFilter.js b/app/component/modalSearchCity/ButtonFilter.js index 57160c0..4cda88c 100644 --- a/app/component/modalSearchCity/ButtonFilter.js +++ b/app/component/modalSearchCity/ButtonFilter.js @@ -21,8 +21,6 @@ function ButtonFilter({ selected, setOpen }) { className='text-[#616161] text-[11px] md:text-[14px] leading-[17px] sm:leading-[19px] md:leading-[22px] lg:leading-[24px] font-medium ml-1 md:mx-1' > - {selected.province || 'استان'} - {' | '} {selected.city || 'شهر'}

diff --git a/app/globals.css b/app/globals.css index 864a2f4..1caaab4 100644 --- a/app/globals.css +++ b/app/globals.css @@ -235,7 +235,7 @@ html { } .MuiFormControl-root .MuiInputBase-root .MuiInputBase-input { - font-size: 10px !important; + font-size: 16px !important; } @keyframes openx { @@ -384,7 +384,7 @@ html { } .MuiFormControl-root .MuiInputBase-root .MuiInputBase-input { - font-size: 13px !important; + font-size: 16px !important; } .MuiModal-root .MuiBox-root { diff --git a/components/doctors/index.js b/components/doctors/index.js index 8e81805..5dd3f99 100644 --- a/components/doctors/index.js +++ b/components/doctors/index.js @@ -3,38 +3,18 @@ import { useEffect, useState } from "react"; import SearchBar from "./search"; import SortList from "./sortlist"; +import { Button } from "@mui/material"; import ListDoctors from "./listDoctors"; import LocationD from "../icons/LocationD"; -import { useSearchParams } from "next/navigation"; import ModalSearchCity from "@/app/component/modalSearchCity"; -import { useProvince } from "@/context/ProvinceProvider"; -import { Button } from "@mui/material"; - -// Data -import citiesData from "@/data/city.json"; -import statesData from "@/data/state.json"; function DoctorsPage({ params, matchedCity, matchedState }) { const [loading, setLoading] = useState(true); const [open, setOpen] = useState(false); - const { isProvinceInclude } = useProvince(); const [selected, setSelected] = useState({ - province: matchedState?.name, - city: matchedCity?.name, + province: matchedState?.name || params?.province, + city: matchedCity?.name || params?.city, }); - const searchParams = useSearchParams(); - const locationSelected = { - province: searchParams.get("province"), - city: searchParams.get("city"), - }; - const provinceId = statesData.find( - (state) => state.name === locationSelected?.province - ); - - const newCity = - locationSelected.city || - (provinceId && - citiesData.find((city) => city.province_id === provinceId.id)?.name); const [data, setData] = useState({ expertise: "", diff --git a/components/doctors/sortlist/SelectSort.js b/components/doctors/sortlist/SelectSort.js index 1dc9f5a..4a0fea6 100644 --- a/components/doctors/sortlist/SelectSort.js +++ b/components/doctors/sortlist/SelectSort.js @@ -2,17 +2,20 @@ import { MenuItem, Select, SvgIcon } from "@mui/material"; import { useState } from "react"; import ArrowBottomD from "../../icons/ArrowBottomD"; import SortD from "../../icons/SortD"; +import StarDI from "@/components/icons/StarDI"; const listSort = [ - { label: "براساس امتیاز 1", id: 10 }, - { label: "براساس امتیاز 2", id: 20 }, - { label: "براساس امتیاز 3", id: 30 }, + { label: 3, id: 30 }, + { label: 4, id: 40 }, + { label: 5, id: 50 }, ]; function SelectSort() { - const [sort, setSort] = useState(""); + const [sort, setSort] = useState(3); + + const handleChange = (event) => setSort(event.target.value); + console.log(sort); - const handleChange = (event) => setSort(event.target.name); return (