@scaleflex/ui-tw 0.0.13 → 0.0.15

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scaleflex/ui-tw",
3
- "version": "0.0.13",
3
+ "version": "0.0.15",
4
4
  "author": "scaleflex",
5
5
  "repository": "github:scaleflex/ui",
6
6
  "homepage": "https://github.com/scaleflex/ui/blob/master/README.md",
@@ -17,7 +17,7 @@
17
17
  "@radix-ui/react-slot": "^1.1.2",
18
18
  "@radix-ui/react-switch": "^1.0.1",
19
19
  "@radix-ui/react-tooltip": "^1.2.6",
20
- "@scaleflex/icons-tw": "^0.0.13",
20
+ "@scaleflex/icons-tw": "^0.0.15",
21
21
  "@types/lodash.merge": "^4.6.9",
22
22
  "class-variance-authority": "^0.7.1",
23
23
  "lodash.merge": "^4.6.2",
@@ -1,3 +1,3 @@
1
1
  export { toast } from 'sonner';
2
2
  export { Toaster } from './toaster.component';
3
- export { ToasterProps } from './toaster.types';
3
+ export type { ToasterProps } from './toaster.types';
package/toaster/index.js CHANGED
@@ -1,3 +1,2 @@
1
1
  export { toast } from 'sonner';
2
- export { Toaster } from './toaster.component';
3
- export { ToasterProps } from './toaster.types';
2
+ export { Toaster } from './toaster.component';
@@ -1,4 +1,4 @@
1
- import { ToasterProps } from '@scaleflex/ui-tw/toaster/toaster.types';
1
+ import { ToasterProps } from '@scaleflex/ui-tw/toaster';
2
2
  import React from 'react';
3
3
  declare const Toaster: ({ ...props }: ToasterProps) => React.JSX.Element;
4
4
  export { Toaster };
@@ -61,6 +61,7 @@ function WithTooltip(_ref5) {
61
61
  var variant = _ref5.variant,
62
62
  content = _ref5.content,
63
63
  children = _ref5.children;
64
+ if (!content) return children;
64
65
  return /*#__PURE__*/React.createElement(Tooltip, null, /*#__PURE__*/React.createElement(TooltipTrigger, {
65
66
  asChild: true
66
67
  }, children), /*#__PURE__*/React.createElement(TooltipContent, {
@@ -3,7 +3,7 @@ import { TooltipVariant } from '@scaleflex/ui-tw/tooltip/tooltip.constants';
3
3
  import { ComponentProps, ReactElement } from 'react';
4
4
  export type TooltipVariantType = (typeof TooltipVariant)[keyof typeof TooltipVariant];
5
5
  export interface WithTooltipProps {
6
- content: ReactElement;
6
+ content?: ReactElement | undefined | string;
7
7
  children: ReactElement;
8
8
  variant?: TooltipVariantType;
9
9
  }