29 files changed
+7
-22
No files matched your search
@@ -0,0 +1 @@
|
||||
.vite
|
||||
@@ -1,3 +0,0 @@
|
||||
{
|
||||
"type": "module"
|
||||
}
|
||||
@@ -1,3 +0,0 @@
|
||||
{
|
||||
"type": "module"
|
||||
}
|
||||
+1
-2
@@ -1,11 +1,10 @@
|
||||
import { Routes, Route } from "react-router-dom";
|
||||
// import "./App.css";
|
||||
import "./App.css";
|
||||
import NotFound from "./Pages/NotFound";
|
||||
import Login from "./Pages/Login";
|
||||
import Register from "./Pages/Register";
|
||||
import HomeLayout from "./Layouts/HomeLayout";
|
||||
import Demo from "./Pages/Demo/Demo";
|
||||
import PlayGround from "./Pages/PlayGround/PlayGround";
|
||||
|
||||
function App() {
|
||||
return (
|
||||
|
||||
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
+5
-14
@@ -1,12 +1,11 @@
|
||||
import "./tooltipWithTail.css";
|
||||
import React from "react";
|
||||
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 { useTheme } from "@mui/material";
|
||||
|
||||
const CustomizedTooltip = styled(
|
||||
({ className, placement, arrow, ...props }: TooltipProps) => (
|
||||
({ className, placement, arrow, ...props }) => (
|
||||
<Tooltip
|
||||
{...props}
|
||||
placement={placement}
|
||||
@@ -23,17 +22,9 @@ const CustomizedTooltip = styled(
|
||||
},
|
||||
}));
|
||||
|
||||
const TooltipWithTail = ({ placement, arrow = false, title, text }) => {
|
||||
const theme = useTheme();
|
||||
|
||||
const fontLookup = {
|
||||
default: theme.font.default.font,
|
||||
};
|
||||
|
||||
const fontFamily = fontLookup["default"];
|
||||
|
||||
function TooltipWithTail({ placement, arrow = false, title, text }) {
|
||||
return (
|
||||
<div style={{ fontFamily: fontFamily }}>
|
||||
<div>
|
||||
<CustomizedTooltip
|
||||
arrow={arrow}
|
||||
placement={placement}
|
||||
@@ -49,6 +40,6 @@ const TooltipWithTail = ({ placement, arrow = false, title, text }) => {
|
||||
</CustomizedTooltip>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
}
|
||||
|
||||
export default TooltipWithTail;
|
||||
Reference in new issue
Block a user