| import useIsMobile from "../../../../hooks/useIsMobile"; | import useIsMobile from "../../../../hooks/useIsMobile"; | ||||
| import { ArrowButton } from "../../../Buttons/ArrowButton/ArrowButton"; | import { ArrowButton } from "../../../Buttons/ArrowButton/ArrowButton"; | ||||
| import { useTranslation } from "react-i18next"; | import { useTranslation } from "react-i18next"; | ||||
| import history from "../../../../store/utils/history"; | |||||
| import { useHistory } from "react-router-dom"; | |||||
| const TooltipHeader = (props) => { | const TooltipHeader = (props) => { | ||||
| const headerString = useSelector(selectHeaderString); | const headerString = useSelector(selectHeaderString); | ||||
| const { isMobile } = useIsMobile(); | const { isMobile } = useIsMobile(); | ||||
| const { t } = useTranslation(); | const { t } = useTranslation(); | ||||
| const history = useHistory(); | |||||
| console.log(history); | |||||
| const handleClickCategory = () => { | const handleClickCategory = () => { | ||||
| props?.offers?.filters?.locations.clear(); | props?.offers?.filters?.locations.clear(); | ||||
| const goBack = () => { | const goBack = () => { | ||||
| history.goBack(); | history.goBack(); | ||||
| }; | }; | ||||
| console.log(props) | |||||
| console.log(props); | |||||
| return ( | return ( | ||||
| <Tooltip title={headerString.text}> | |||||
| <Tooltip | |||||
| title={ | |||||
| history.location.pathname.includes("admin") || | |||||
| history.location.pathname.includes("myoffers") | |||||
| ? "" | |||||
| : headerString.text | |||||
| } | |||||
| > | |||||
| <TooltipInnerContainer> | <TooltipInnerContainer> | ||||
| {!props?.myOffers ? ( | {!props?.myOffers ? ( | ||||
| <> | <> |