58 lines
1.5 KiB
JavaScript
58 lines
1.5 KiB
JavaScript
import { useTranslation } from "react-i18next";
|
|
|
|
export const useFilterOptions = () => {
|
|
const { t } = useTranslation();
|
|
|
|
const cities = [
|
|
{ id: "all", label: t("allCities") },
|
|
{ id: "دمشق", label: t("damascus") },
|
|
{ id: "حلب", label: t("aleppo") },
|
|
{ id: "حمص", label: t("homs") },
|
|
{ id: "اللاذقية", label: t("latakia") },
|
|
{ id: "درعا", label: t("daraa") },
|
|
];
|
|
|
|
const propertyTypes = [
|
|
{ id: "all", label: t("all") },
|
|
{ id: "apartment", label: t("residentialApartments") },
|
|
{ id: "studio", label: t("studio") },
|
|
{ id: "commercial", label: t("commercialProperty") },
|
|
{ id: "villa", label: t("villaFarm") },
|
|
];
|
|
|
|
const priceRanges = [
|
|
{ id: "all", label: t("allPrices") },
|
|
{ id: "0-500", label: t("priceRange1") },
|
|
{ id: "500-1000", label: t("priceRange2") },
|
|
{ id: "1000-2000", label: t("priceRange3") },
|
|
{ id: "2000-3000", label: t("priceRange4") },
|
|
{ id: "3000+", label: t("priceRange5") },
|
|
];
|
|
|
|
const identityTypes = [
|
|
{ id: "syrian", label: t("syrianId") },
|
|
{ id: "passport", label: t("passport") },
|
|
];
|
|
|
|
const ownerSources = [
|
|
{ id: "all", label: t("all") },
|
|
{ id: "owner", label: t("fromOwner") },
|
|
{ id: "agency", label: t("fromAgency") },
|
|
];
|
|
|
|
const rentPeriods = [
|
|
{ id: "all", label: t("all") },
|
|
{ id: "daily", label: t("dailyRent") },
|
|
{ id: "monthly", label: t("monthlyRent") },
|
|
];
|
|
|
|
return {
|
|
cities,
|
|
propertyTypes,
|
|
priceRanges,
|
|
identityTypes,
|
|
ownerSources,
|
|
rentPeriods,
|
|
};
|
|
};
|