{ getTitle( { title, theme } ) }
{ getContent( { content, theme } ) }
{
diff --git a/src/components/tooltip/tooltip.tsx b/src/components/tooltip/tooltip.tsx
index e9eda68e..4c3b9d3b 100644
--- a/src/components/tooltip/tooltip.tsx
+++ b/src/components/tooltip/tooltip.tsx
@@ -5,6 +5,7 @@ import {
isValidElement,
cloneElement,
useMemo,
+ Fragment,
} from 'react';
import {
useFloating,
@@ -174,21 +175,23 @@ export const Tooltip = ( {
const widthClasses = 'max-w-80 w-fit';
return (
- <>
- { isValidElement( children ) &&
- cloneElement( children as React.ReactElement, {
- ...children.props,
- ref: mergeRefs(
- (
- children as React.ReactElement & {
- ref?: React.Ref
;
- }
- ).ref,
- refs.setReference
- ),
- className: cn( children.props.className ),
- ...getReferenceProps(),
- } ) }
+
+ { isValidElement( children ) && (
+
+ { cloneElement( children as React.ReactElement, {
+ ref: mergeRefs(
+ (
+ children as React.ReactElement & {
+ ref?: React.Ref;
+ }
+ ).ref,
+ refs.setReference
+ ),
+ className: cn( children.props.className ),
+ ...getReferenceProps(),
+ } ) }
+
+ ) }
{ isMounted && (
{ !! title && (
-
{ title }
+
+ { title }
+
) }
{ !! content && (
-
{ content }
+
+ { content }
+
) }
{ arrow && (
@@ -223,8 +236,10 @@ export const Tooltip = ( {
) }
- >
+
);
};
+Tooltip.displayName = 'Tooltip';
+
export default Tooltip;
diff --git a/version.json b/version.json
index 7a009da5..fcf52ace 100644
--- a/version.json
+++ b/version.json
@@ -1,3 +1,3 @@
{
- "force-ui": "1.3.2"
+ "force-ui": "1.3.3"
}