dce-reactkit 3.6.7 → 3.6.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.js +2 -3
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/components/Tooltip.d.ts +1 -0
- package/dist/esm/index.js +2 -3
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/components/Tooltip.d.ts +1 -0
- package/dist/index.d.ts +1 -0
- package/package.json +1 -1
- package/src/components/Tooltip.tsx +4 -2
package/dist/index.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -27,6 +27,8 @@ type Props = {
|
|
|
27
27
|
wide?: boolean,
|
|
28
28
|
// If true, tooltip is thinner
|
|
29
29
|
thin?: boolean,
|
|
30
|
+
// If true, the tooltip container should be display: block
|
|
31
|
+
containerIsDisplayBlock?: boolean,
|
|
30
32
|
};
|
|
31
33
|
|
|
32
34
|
/*------------------------------------------------------------------------*/
|
|
@@ -48,7 +50,6 @@ const TOOLTIP_BORDER_RADIUS_REM = 0.3;
|
|
|
48
50
|
const style = `
|
|
49
51
|
/* Container for contents and tooltip */
|
|
50
52
|
.Tooltip-outer-container {
|
|
51
|
-
display: inline-block;
|
|
52
53
|
position: relative;
|
|
53
54
|
}
|
|
54
55
|
|
|
@@ -339,6 +340,7 @@ const Tooltip: React.FC<Props> = (props) => {
|
|
|
339
340
|
children,
|
|
340
341
|
wide,
|
|
341
342
|
thin,
|
|
343
|
+
containerIsDisplayBlock,
|
|
342
344
|
} = props;
|
|
343
345
|
|
|
344
346
|
/* -------------- State ------------- */
|
|
@@ -463,7 +465,7 @@ const Tooltip: React.FC<Props> = (props) => {
|
|
|
463
465
|
// Render
|
|
464
466
|
return (
|
|
465
467
|
<div
|
|
466
|
-
className=
|
|
468
|
+
className={`Tooltip-outer-container ${containerIsDisplayBlock ? 'd-block' : 'd-inline-block'}}`}
|
|
467
469
|
aria-label={text}
|
|
468
470
|
onMouseEnter={() => {
|
|
469
471
|
dispatch({
|