@oneplatformdev/ui 0.1.99-beta.234 → 0.1.99-beta.236
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/CHANGELOG.md +16 -0
- package/Tooltip/Tooltip.d.ts.map +1 -1
- package/Tooltip/Tooltip.js +35 -29
- package/Tooltip/Tooltip.js.map +1 -1
- package/Tooltip/Tooltip.types.d.ts +9 -0
- package/Tooltip/Tooltip.types.d.ts.map +1 -1
- package/Tooltip/tooltipVariants.d.ts.map +1 -1
- package/Tooltip/tooltipVariants.js +2 -3
- package/Tooltip/tooltipVariants.js.map +1 -1
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,19 @@
|
|
|
1
|
+
## 0.1.99-beta.236 (2026-03-02)
|
|
2
|
+
|
|
3
|
+
### 🧱 Updated Dependencies
|
|
4
|
+
|
|
5
|
+
- Updated @oneplatformdev/utils to 0.1.99-beta.236
|
|
6
|
+
- Updated @oneplatformdev/hooks to 0.1.99-beta.236
|
|
7
|
+
- Updated @oneplatformdev/tokens to 0.1.99-beta.236
|
|
8
|
+
|
|
9
|
+
## 0.1.99-beta.235 (2026-03-02)
|
|
10
|
+
|
|
11
|
+
### 🧱 Updated Dependencies
|
|
12
|
+
|
|
13
|
+
- Updated @oneplatformdev/utils to 0.1.99-beta.235
|
|
14
|
+
- Updated @oneplatformdev/hooks to 0.1.99-beta.235
|
|
15
|
+
- Updated @oneplatformdev/tokens to 0.1.99-beta.235
|
|
16
|
+
|
|
1
17
|
## 0.1.99-beta.234 (2026-03-02)
|
|
2
18
|
|
|
3
19
|
### 🧱 Updated Dependencies
|
package/Tooltip/Tooltip.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.d.ts","sourceRoot":"","sources":["../../src/Tooltip/Tooltip.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAG1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAIpD,eAAO,MAAM,YAAY,GAAI,OAAO,iBAAiB,CAAC,YAAY,CAAC,
|
|
1
|
+
{"version":3,"file":"Tooltip.d.ts","sourceRoot":"","sources":["../../src/Tooltip/Tooltip.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,OAAO,CAAC;AAG1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAIpD,eAAO,MAAM,YAAY,GAAI,OAAO,iBAAiB,CAAC,YAAY,CAAC,4CAwDlE,CAAC;AAEF,eAAO,MAAM,OAAO,GAAI,OAAO,iBAAiB,CAAC,YAAY,CAAC,4CAQ7D,CAAC"}
|
package/Tooltip/Tooltip.js
CHANGED
|
@@ -1,48 +1,53 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import { CircleQuestionMarkIcon as
|
|
1
|
+
import { jsx as o, jsxs as a } from "react/jsx-runtime";
|
|
2
|
+
import { CircleQuestionMarkIcon as d } from "lucide-react";
|
|
3
3
|
import { cn as n } from "@oneplatformdev/utils";
|
|
4
|
-
import { TooltipProvider as
|
|
5
|
-
import { tooltipQuestionIconVariants as
|
|
6
|
-
const
|
|
7
|
-
const { triggerProps:
|
|
8
|
-
return /* @__PURE__ */
|
|
9
|
-
|
|
4
|
+
import { TooltipProvider as x, TooltipRoot as g, TooltipTrigger as h, TooltipContent as w } from "./TooltipRoot.js";
|
|
5
|
+
import { tooltipQuestionIconVariants as N } from "./tooltipVariants.js";
|
|
6
|
+
const l = (t) => {
|
|
7
|
+
const { triggerProps: r, contentProps: i, message: c, children: m, showQuestionMark: p = !1, size: s = "md", questionIconSize: u = s, slotProps: e, ...f } = t;
|
|
8
|
+
return /* @__PURE__ */ a(
|
|
9
|
+
g,
|
|
10
10
|
{
|
|
11
11
|
defaultOpen: !1,
|
|
12
12
|
delayDuration: 300,
|
|
13
|
-
...
|
|
13
|
+
...f,
|
|
14
14
|
children: [
|
|
15
|
-
/* @__PURE__ */
|
|
16
|
-
|
|
15
|
+
/* @__PURE__ */ a(
|
|
16
|
+
h,
|
|
17
17
|
{
|
|
18
|
-
...
|
|
18
|
+
...r || {},
|
|
19
|
+
...e?.trigger || {},
|
|
19
20
|
className: n(
|
|
20
21
|
"flex flex-row gap-1 w-fit",
|
|
21
22
|
"items-center",
|
|
22
23
|
"cursor-pointer",
|
|
23
24
|
"outline-none",
|
|
24
|
-
|
|
25
|
+
r?.className,
|
|
26
|
+
e?.trigger?.className
|
|
25
27
|
),
|
|
26
28
|
type: "button",
|
|
27
29
|
children: [
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
m,
|
|
31
|
+
p && /* @__PURE__ */ o(
|
|
32
|
+
d,
|
|
31
33
|
{
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
34
|
+
...e?.questionIcon || {},
|
|
35
|
+
className: n(
|
|
36
|
+
N({ size: s || u }),
|
|
37
|
+
e?.questionIcon?.className
|
|
38
|
+
)
|
|
35
39
|
}
|
|
36
40
|
)
|
|
37
41
|
]
|
|
38
42
|
}
|
|
39
43
|
),
|
|
40
|
-
/* @__PURE__ */
|
|
41
|
-
|
|
44
|
+
/* @__PURE__ */ o(
|
|
45
|
+
w,
|
|
42
46
|
{
|
|
43
47
|
align: "center",
|
|
44
48
|
sideOffset: 8,
|
|
45
|
-
...
|
|
49
|
+
...i || {},
|
|
50
|
+
...e?.content || {},
|
|
46
51
|
className: n(
|
|
47
52
|
"flex items-center justify-center",
|
|
48
53
|
"w-auto max-w-80",
|
|
@@ -53,20 +58,21 @@ const s = (e) => {
|
|
|
53
58
|
"text-md font-normal leading-normal",
|
|
54
59
|
"shadow-[1px_1px_10px_0px_rgba(6,8,13,0.1)]",
|
|
55
60
|
"whitespace-pre-wrap",
|
|
56
|
-
|
|
61
|
+
i?.className,
|
|
62
|
+
e?.content?.className
|
|
57
63
|
),
|
|
58
|
-
children:
|
|
64
|
+
children: c || ""
|
|
59
65
|
}
|
|
60
66
|
)
|
|
61
67
|
]
|
|
62
68
|
}
|
|
63
69
|
);
|
|
64
|
-
},
|
|
65
|
-
const { skipProvider:
|
|
66
|
-
return
|
|
70
|
+
}, b = (t) => {
|
|
71
|
+
const { skipProvider: r = !0 } = t;
|
|
72
|
+
return r ? /* @__PURE__ */ o(l, { ...t }) : /* @__PURE__ */ o(x, { children: /* @__PURE__ */ o(l, { ...t }) });
|
|
67
73
|
};
|
|
68
74
|
export {
|
|
69
|
-
|
|
70
|
-
|
|
75
|
+
b as Tooltip,
|
|
76
|
+
l as TooltipInner
|
|
71
77
|
};
|
|
72
78
|
//# sourceMappingURL=Tooltip.js.map
|
package/Tooltip/Tooltip.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.js","sources":["../../src/Tooltip/Tooltip.tsx"],"sourcesContent":["import { CircleQuestionMarkIcon } from 'lucide-react';\nimport { PropsWithChildren } from \"react\";\n\nimport { cn } from \"@oneplatformdev/utils\";\nimport type { TooltipProps } from \"./Tooltip.types\";\nimport { TooltipRoot, TooltipTrigger, TooltipContent, TooltipProvider } from \"./TooltipRoot\";\nimport { tooltipQuestionIconVariants } from './tooltipVariants';\n\nexport const TooltipInner = (props: PropsWithChildren<TooltipProps>) => {\n const { triggerProps, contentProps, message, children, showQuestionMark = false, questionIconSize, ...rest } = props;\n return (\n <TooltipRoot\n defaultOpen={false}\n delayDuration={300}\n {...rest}\n >\n <TooltipTrigger\n {...(triggerProps || {})}\n className={cn(\n 'flex flex-row gap-1 w-fit',\n 'items-center',\n 'cursor-pointer',\n 'outline-none',\n triggerProps?.className\n )}\n type='button'\n >\n {children}\n {showQuestionMark && (\n <CircleQuestionMarkIcon\n className={
|
|
1
|
+
{"version":3,"file":"Tooltip.js","sources":["../../src/Tooltip/Tooltip.tsx"],"sourcesContent":["import { CircleQuestionMarkIcon } from 'lucide-react';\nimport { PropsWithChildren } from \"react\";\n\nimport { cn } from \"@oneplatformdev/utils\";\nimport type { TooltipProps } from \"./Tooltip.types\";\nimport { TooltipRoot, TooltipTrigger, TooltipContent, TooltipProvider } from \"./TooltipRoot\";\nimport { tooltipQuestionIconVariants } from './tooltipVariants';\n\nexport const TooltipInner = (props: PropsWithChildren<TooltipProps>) => {\n const { triggerProps, contentProps, message, children, showQuestionMark = false, size = 'md', questionIconSize = size, slotProps, ...rest } = props;\n return (\n <TooltipRoot\n defaultOpen={false}\n delayDuration={300}\n {...rest}\n >\n <TooltipTrigger\n {...(triggerProps || {})}\n {...(slotProps?.trigger || {})}\n className={cn(\n 'flex flex-row gap-1 w-fit',\n 'items-center',\n 'cursor-pointer',\n 'outline-none',\n triggerProps?.className,\n slotProps?.trigger?.className\n )}\n type='button'\n >\n {children}\n {showQuestionMark && (\n <CircleQuestionMarkIcon\n {...(slotProps?.questionIcon || {})}\n className={cn(\n tooltipQuestionIconVariants({ size: size || questionIconSize }),\n slotProps?.questionIcon?.className\n )}\n />\n )}\n </TooltipTrigger>\n\n <TooltipContent\n align=\"center\"\n sideOffset={8}\n {...(contentProps || {})}\n {...(slotProps?.content || {})}\n className={cn(\n 'flex items-center justify-center',\n 'w-auto max-w-80',\n 'rounded-xl',\n 'px-4 py-3',\n 'bg-white',\n 'text-primary',\n 'text-md font-normal leading-normal',\n 'shadow-[1px_1px_10px_0px_rgba(6,8,13,0.1)]',\n 'whitespace-pre-wrap',\n contentProps?.className,\n slotProps?.content?.className\n )}\n >\n {message || ''}\n </TooltipContent>\n </TooltipRoot>\n );\n};\n\nexport const Tooltip = (props: PropsWithChildren<TooltipProps>) => {\n const { skipProvider = true } = props;\n if (skipProvider) return <TooltipInner {...props}/>;\n return (\n <TooltipProvider>\n <TooltipInner {...props}/>\n </TooltipProvider>\n );\n};\n"],"names":["TooltipInner","props","triggerProps","contentProps","message","children","showQuestionMark","size","questionIconSize","slotProps","rest","jsxs","TooltipRoot","TooltipTrigger","cn","jsx","CircleQuestionMarkIcon","toolt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AA;AAAA,YAGrB,UAAAL,KAAW;AAAA,UAAA;AAAA,QAAA;AAAA,MACd;AAAA,IAAA;AAAA,EAAA;AAGN,GAEae,IAAU,CAAClB,MAA2C;AACjE,QAAM,EAAE,cAAAmB,IAAe,GAAA,IAASnB;AAChC,SAAImB,IAAqB,gBAAAL,EAACf,GAAA,EAAc,GAAGC,EAAA,CAAM,sBAE9CoB,GAAA,EACC,UAAA,gBAAAN,EAACf,GAAA,EAAc,GAAGC,GAAM,GAC1B;AAEJ;"}
|
|
@@ -4,8 +4,17 @@ export interface TooltipProps extends ComponentPropsWithoutRef<typeof TooltipRoo
|
|
|
4
4
|
message?: ReactNode;
|
|
5
5
|
skipProvider?: boolean;
|
|
6
6
|
showQuestionMark?: boolean;
|
|
7
|
+
/** @deprecated use `slotProps.content` */
|
|
7
8
|
contentProps?: ComponentPropsWithoutRef<typeof TooltipContent>;
|
|
9
|
+
/** @deprecated use `slotProps.trigger` */
|
|
8
10
|
triggerProps?: ComponentPropsWithoutRef<typeof TooltipTrigger>;
|
|
11
|
+
size?: "xs" | "sm" | "md";
|
|
12
|
+
/** @deprecated use `size` */
|
|
9
13
|
questionIconSize?: "xs" | "sm" | "md";
|
|
14
|
+
slotProps?: {
|
|
15
|
+
content?: ComponentPropsWithoutRef<typeof TooltipContent>;
|
|
16
|
+
trigger?: ComponentPropsWithoutRef<typeof TooltipTrigger>;
|
|
17
|
+
questionIcon?: ComponentPropsWithoutRef<"svg">;
|
|
18
|
+
};
|
|
10
19
|
}
|
|
11
20
|
//# sourceMappingURL=Tooltip.types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tooltip.types.d.ts","sourceRoot":"","sources":["../../src/Tooltip/Tooltip.types.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,wBAAwB,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAC5D,OAAO,EAAE,WAAW,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,eAAe,CAAC;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YAAY,CAAC,EAAE,wBAAwB,CAAC,KAAK,CAAC,CAAC;KAChD,CAAC;CACH"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltipVariants.d.ts","sourceRoot":"","sources":["../../src/Tooltip/tooltipVariants.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,2BAA2B;;
|
|
1
|
+
{"version":3,"file":"tooltipVariants.d.ts","sourceRoot":"","sources":["../../src/Tooltip/tooltipVariants.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,2BAA2B;;8EAgBvC,CAAC"}
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { cva as s } from "class-variance-authority";
|
|
2
2
|
const t = s(
|
|
3
3
|
[
|
|
4
|
-
"shrink-0"
|
|
5
|
-
"text-[#666A78]"
|
|
4
|
+
"shrink-0 text-[#8C8F9A]"
|
|
6
5
|
],
|
|
7
6
|
{
|
|
8
7
|
variants: {
|
|
@@ -13,7 +12,7 @@ const t = s(
|
|
|
13
12
|
}
|
|
14
13
|
},
|
|
15
14
|
defaultVariants: {
|
|
16
|
-
size: "
|
|
15
|
+
size: "md"
|
|
17
16
|
}
|
|
18
17
|
}
|
|
19
18
|
);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltipVariants.js","sources":["../../src/Tooltip/tooltipVariants.ts"],"sourcesContent":["import { cva } from \"class-variance-authority\";\n\nexport const tooltipQuestionIconVariants = cva(\n [\n \"shrink-0
|
|
1
|
+
{"version":3,"file":"tooltipVariants.js","sources":["../../src/Tooltip/tooltipVariants.ts"],"sourcesContent":["import { cva } from \"class-variance-authority\";\n\nexport const tooltipQuestionIconVariants = cva(\n [\n \"shrink-0 text-[#8C8F9A]\",\n ],\n {\n variants: {\n size: {\n xs: \"size-2\",\n sm: \"size-3\",\n md: \"size-4\",\n },\n },\n defaultVariants: {\n size: \"md\",\n },\n }\n);\n"],"names":["tooltipQuestionIconVariants","cva"],"mappings":";AAEO,MAAMA,IAA8BC;AAAA,EACzC;AAAA,IACE;AAAA,EAAA;AAAA,EAEF;AAAA,IACE,UAAU;AAAA,MACR,MAAM;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,QACJ,IAAI;AAAA,MAAA;AAAA,IACN;AAAA,IAEF,iBAAiB;AAAA,MACf,MAAM;AAAA,IAAA;AAAA,EACR;AAEJ;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oneplatformdev/ui",
|
|
3
|
-
"version": "0.1.99-beta.
|
|
3
|
+
"version": "0.1.99-beta.236",
|
|
4
4
|
"description": "UI component library for OnePlatform",
|
|
5
5
|
"author": "One Platform Development Team",
|
|
6
6
|
"keywords": [
|
|
@@ -106,9 +106,9 @@
|
|
|
106
106
|
"recharts": "^3.2.0",
|
|
107
107
|
"sonner": "^2.0.7",
|
|
108
108
|
"vaul": "^1.1.2",
|
|
109
|
-
"@oneplatformdev/
|
|
110
|
-
"@oneplatformdev/
|
|
111
|
-
"@oneplatformdev/
|
|
109
|
+
"@oneplatformdev/tokens": "^0.1.99-beta.236",
|
|
110
|
+
"@oneplatformdev/hooks": "^0.1.99-beta.236",
|
|
111
|
+
"@oneplatformdev/utils": "^0.1.99-beta.236"
|
|
112
112
|
},
|
|
113
113
|
"scripts": {
|
|
114
114
|
"chromatic": "chromatic"
|