Skip to content

delpikye-v/react-mui-tooltip-if-need

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 

Repository files navigation

react-mui-tooltip-ifz

react-mui-tooltip-ifz

LIVE EXAMPLE

Description

React MUI (v.5). Show tooltip if need. (truncate)


Usage

Install the package

npm install --save react-mui-tooltip-ifz

Import the module in the place you want to use:

import { MuiTooltipIfNeed } from "react-mui-tooltip-ifz";

Snippet

simple
<MuiTooltipIfNeed title="abdc">
  {/* <div>fdsfs</div> */}
  <Button
    variant="contained"
    className="abcd"
    style={{
      width: 200 // => you should update it from css class
    }}
    onClick={() => setSize(400)}
    onDoubleClick={() => setSize(200)}
  >
    Hellofds fdsfsfsfdsdf fdsf s
  </Button>
</MuiTooltipIfNeed>


props

TooltipProps: from react: @mui/material

props type description
always boolean default: false: show if text is overflow
bootstrapCss boolean default: true: arrow and color like bootstrapCss

Note

RUN

LIVE EXAMPLE


License

MIT

About

React-Mui. Truncate and show tooltip if need

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published