Merge pull request #11 from MuhammadKhalilzadeh/syncings_3

Syncings 3
This commit is contained in:
Mohammad Khalilzadeh authored and GitHub committed 2024-05-15 09:42:41 +03:30
commit 3a5c889a8b
29 files changed
+7 -22

No files matched your search

+1
View File
@@ -0,0 +1 @@
.vite
-3
View File
@@ -1,3 +0,0 @@
{
"type": "module"
}
-3
View File
@@ -1,3 +0,0 @@
{
"type": "module"
}
+1 -2
View File
@@ -1,11 +1,10 @@
import { Routes, Route } from "react-router-dom"; import { Routes, Route } from "react-router-dom";
// import "./App.css"; import "./App.css";
import NotFound from "./Pages/NotFound"; import NotFound from "./Pages/NotFound";
import Login from "./Pages/Login"; import Login from "./Pages/Login";
import Register from "./Pages/Register"; import Register from "./Pages/Register";
import HomeLayout from "./Layouts/HomeLayout"; import HomeLayout from "./Layouts/HomeLayout";
import Demo from "./Pages/Demo/Demo"; import Demo from "./Pages/Demo/Demo";
import PlayGround from "./Pages/PlayGround/PlayGround";
function App() { function App() {
return ( return (
@@ -1,12 +1,11 @@
import "./tooltipWithTail.css"; import "./tooltipWithTail.css";
import React from "react"; import React from "react";
import { styled } from "@mui/material/styles"; import { styled } from "@mui/material/styles";
import Tooltip, { TooltipProps, tooltipClasses } from "@mui/material/Tooltip"; import Tooltip, { tooltipClasses } from "@mui/material/Tooltip";
import HelpOutlineIcon from "@mui/icons-material/HelpOutline"; import HelpOutlineIcon from "@mui/icons-material/HelpOutline";
import { useTheme } from "@mui/material";
const CustomizedTooltip = styled( const CustomizedTooltip = styled(
({ className, placement, arrow, ...props }: TooltipProps) => ( ({ className, placement, arrow, ...props }) => (
<Tooltip <Tooltip
{...props} {...props}
placement={placement} placement={placement}
@@ -23,17 +22,9 @@ const CustomizedTooltip = styled(
}, },
})); }));
const TooltipWithTail = ({ placement, arrow = false, title, text }) => { function TooltipWithTail({ placement, arrow = false, title, text }) {
const theme = useTheme();
const fontLookup = {
default: theme.font.default.font,
};
const fontFamily = fontLookup["default"];
return ( return (
<div style={{ fontFamily: fontFamily }}> <div>
<CustomizedTooltip <CustomizedTooltip
arrow={arrow} arrow={arrow}
placement={placement} placement={placement}
@@ -49,6 +40,6 @@ const TooltipWithTail = ({ placement, arrow = false, title, text }) => {
</CustomizedTooltip> </CustomizedTooltip>
</div> </div>
); );
}; }
export default TooltipWithTail; export default TooltipWithTail;