@acronis-platform/ui-react 5.5.6 → 5.5.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.
|
@@ -23,7 +23,7 @@ var o = i.Root, s = i.Trigger, c = n.forwardRef(({ className: n, sideOffset: a =
|
|
|
23
23
|
className: "z-50",
|
|
24
24
|
children: /* @__PURE__ */ r(i.Popup, {
|
|
25
25
|
ref: f,
|
|
26
|
-
className: e("max-w-[var(--ui-tooltip-container-width-max)] min-w-[var(--ui-tooltip-container-width-min)] rounded-[var(--ui-tooltip-container-border-radius)] bg-[var(--ui-tooltip-container-color)] px-[var(--ui-tooltip-container-padding-x)] py-[var(--ui-tooltip-container-padding-y)] text-xs font-medium leading-4 text-[var(--ui-tooltip-label-color)]", n),
|
|
26
|
+
className: e("max-w-[var(--ui-tooltip-container-width-max)] min-w-[var(--ui-tooltip-container-width-min)] rounded-[var(--ui-tooltip-container-border-radius)] bg-[var(--ui-tooltip-container-color)] px-[var(--ui-tooltip-container-padding-x)] py-[var(--ui-tooltip-container-padding-y)] text-xs font-medium leading-4 break-words text-[var(--ui-tooltip-label-color)]", n),
|
|
27
27
|
...d
|
|
28
28
|
})
|
|
29
29
|
})
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltip.js","names":[],"sources":["../../../../src/components/ui/tooltip/tooltip.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Tooltip as TooltipPrimitive } from '@base-ui/react/tooltip';\n\nimport { cn } from '@/lib/utils';\nimport { usePortalContainer } from '@/lib/portal-container';\n\n// A contextual hint shown on hover/focus of its trigger. Wraps the Base UI\n// Tooltip primitive; the popup is themed with the `--ui-tooltip-*` token tier\n// (a dark, ~90%-opaque bubble with a light label, 12/8px padding, 4px radius,\n// 48–256px width). No arrow — matching the Figma design. Wrap the whole app (or\n// a region) in `TooltipProvider` to share open/close delays across tooltips.\n\nfunction TooltipProvider(props: React.ComponentProps<typeof TooltipPrimitive.Provider>) {\n return <TooltipPrimitive.Provider delay={300} {...props} />;\n}\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef<typeof TooltipPrimitive.Popup>,\n React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Popup> & {\n sideOffset?: number;\n side?: TooltipPrimitive.Positioner.Props['side'];\n align?: TooltipPrimitive.Positioner.Props['align'];\n /**\n * Override what the popup is positioned against — defaults to the\n * `TooltipTrigger` element. Useful when the hover/focus trigger is\n * narrower than the element the tooltip should visually align to (e.g. a\n * truncating label inside a full-width row, where the tooltip should\n * anchor to the row's edge, not the label's).\n */\n anchor?: TooltipPrimitive.Positioner.Props['anchor'];\n portalContainer?: TooltipPrimitive.Portal.Props['container'];\n keepMounted?: TooltipPrimitive.Portal.Props['keepMounted'];\n }\n>(\n (\n {\n className,\n sideOffset = 6,\n side = 'top',\n align = 'center',\n anchor,\n portalContainer,\n keepMounted,\n ...props\n },\n ref\n ) => {\n const ctxContainer = usePortalContainer();\n const resolvedContainer = portalContainer ?? ctxContainer;\n\n return (\n <TooltipPrimitive.Portal\n container={resolvedContainer}\n keepMounted={keepMounted}\n >\n <TooltipPrimitive.Positioner\n sideOffset={sideOffset}\n side={side}\n align={align}\n anchor={anchor}\n className=\"z-50\"\n >\n <TooltipPrimitive.Popup\n ref={ref}\n className={cn(\n 'max-w-[var(--ui-tooltip-container-width-max)] min-w-[var(--ui-tooltip-container-width-min)] rounded-[var(--ui-tooltip-container-border-radius)] bg-[var(--ui-tooltip-container-color)] px-[var(--ui-tooltip-container-padding-x)] py-[var(--ui-tooltip-container-padding-y)] text-xs font-medium leading-4 text-[var(--ui-tooltip-label-color)]',\n className\n )}\n {...props}\n />\n </TooltipPrimitive.Positioner>\n </TooltipPrimitive.Portal>\n );\n }\n);\nTooltipContent.displayName = 'TooltipContent';\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n"],"mappings":";;;;;;AAYA,SAAS,EAAgB,GAA+D;CACtF,OAAO,kBAAC,EAAiB,UAAlB;EAA2B,OAAO;EAAK,GAAI;CAAQ,CAAA;AAC5D;AAEA,IAAM,IAAU,EAAiB,MAE3B,IAAiB,EAAiB,SAElC,IAAiB,EAAM,YAmBzB,EACE,cACA,gBAAa,GACb,UAAO,OACP,WAAQ,UACR,WACA,oBACA,gBACA,GAAG,KAEL,MACG;CACH,IAAM,IAAe,EAAmB,GAClC,IAAoB,KAAmB;CAE7C,OACA,kBAAC,EAAiB,QAAlB;EACE,WAAW;EACE;EAEb,UAAA,kBAAC,EAAiB,YAAlB;GACc;GACN;GACC;GACC;GACR,WAAU;GAEV,UAAA,kBAAC,EAAiB,OAAlB;IACO;IACL,WAAW,EACT,
|
|
1
|
+
{"version":3,"file":"tooltip.js","names":[],"sources":["../../../../src/components/ui/tooltip/tooltip.tsx"],"sourcesContent":["import * as React from 'react';\nimport { Tooltip as TooltipPrimitive } from '@base-ui/react/tooltip';\n\nimport { cn } from '@/lib/utils';\nimport { usePortalContainer } from '@/lib/portal-container';\n\n// A contextual hint shown on hover/focus of its trigger. Wraps the Base UI\n// Tooltip primitive; the popup is themed with the `--ui-tooltip-*` token tier\n// (a dark, ~90%-opaque bubble with a light label, 12/8px padding, 4px radius,\n// 48–256px width). No arrow — matching the Figma design. Wrap the whole app (or\n// a region) in `TooltipProvider` to share open/close delays across tooltips.\n\nfunction TooltipProvider(props: React.ComponentProps<typeof TooltipPrimitive.Provider>) {\n return <TooltipPrimitive.Provider delay={300} {...props} />;\n}\n\nconst Tooltip = TooltipPrimitive.Root;\n\nconst TooltipTrigger = TooltipPrimitive.Trigger;\n\nconst TooltipContent = React.forwardRef<\n React.ElementRef<typeof TooltipPrimitive.Popup>,\n React.ComponentPropsWithoutRef<typeof TooltipPrimitive.Popup> & {\n sideOffset?: number;\n side?: TooltipPrimitive.Positioner.Props['side'];\n align?: TooltipPrimitive.Positioner.Props['align'];\n /**\n * Override what the popup is positioned against — defaults to the\n * `TooltipTrigger` element. Useful when the hover/focus trigger is\n * narrower than the element the tooltip should visually align to (e.g. a\n * truncating label inside a full-width row, where the tooltip should\n * anchor to the row's edge, not the label's).\n */\n anchor?: TooltipPrimitive.Positioner.Props['anchor'];\n portalContainer?: TooltipPrimitive.Portal.Props['container'];\n keepMounted?: TooltipPrimitive.Portal.Props['keepMounted'];\n }\n>(\n (\n {\n className,\n sideOffset = 6,\n side = 'top',\n align = 'center',\n anchor,\n portalContainer,\n keepMounted,\n ...props\n },\n ref\n ) => {\n const ctxContainer = usePortalContainer();\n const resolvedContainer = portalContainer ?? ctxContainer;\n\n return (\n <TooltipPrimitive.Portal\n container={resolvedContainer}\n keepMounted={keepMounted}\n >\n <TooltipPrimitive.Positioner\n sideOffset={sideOffset}\n side={side}\n align={align}\n anchor={anchor}\n className=\"z-50\"\n >\n <TooltipPrimitive.Popup\n ref={ref}\n className={cn(\n 'max-w-[var(--ui-tooltip-container-width-max)] min-w-[var(--ui-tooltip-container-width-min)] rounded-[var(--ui-tooltip-container-border-radius)] bg-[var(--ui-tooltip-container-color)] px-[var(--ui-tooltip-container-padding-x)] py-[var(--ui-tooltip-container-padding-y)] text-xs font-medium leading-4 break-words text-[var(--ui-tooltip-label-color)]',\n className\n )}\n {...props}\n />\n </TooltipPrimitive.Positioner>\n </TooltipPrimitive.Portal>\n );\n }\n);\nTooltipContent.displayName = 'TooltipContent';\n\nexport { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };\n"],"mappings":";;;;;;AAYA,SAAS,EAAgB,GAA+D;CACtF,OAAO,kBAAC,EAAiB,UAAlB;EAA2B,OAAO;EAAK,GAAI;CAAQ,CAAA;AAC5D;AAEA,IAAM,IAAU,EAAiB,MAE3B,IAAiB,EAAiB,SAElC,IAAiB,EAAM,YAmBzB,EACE,cACA,gBAAa,GACb,UAAO,OACP,WAAQ,UACR,WACA,oBACA,gBACA,GAAG,KAEL,MACG;CACH,IAAM,IAAe,EAAmB,GAClC,IAAoB,KAAmB;CAE7C,OACA,kBAAC,EAAiB,QAAlB;EACE,WAAW;EACE;EAEb,UAAA,kBAAC,EAAiB,YAAlB;GACc;GACN;GACC;GACC;GACR,WAAU;GAEV,UAAA,kBAAC,EAAiB,OAAlB;IACO;IACL,WAAW,EACT,+VACA,CACF;IACA,GAAI;GACL,CAAA;EAC0B,CAAA;CACN,CAAA;AAE3B,CACF;AACA,EAAe,cAAc"}
|
package/dist/llms/tooltip.md
CHANGED
|
@@ -124,6 +124,17 @@ arrow is rendered, matching the design.
|
|
|
124
124
|
- **Given** only `default-open`
|
|
125
125
|
**Then** the tooltip manages its own open state.
|
|
126
126
|
|
|
127
|
+
### Long content
|
|
128
|
+
|
|
129
|
+
- **Given** content wider than the popup's maximum width
|
|
130
|
+
**When** the popup opens
|
|
131
|
+
**Then** multi-word text wraps at spaces and the popup stays within its maximum
|
|
132
|
+
width.
|
|
133
|
+
- **Given** content with no space to wrap at (a single email, URL or UUID)
|
|
134
|
+
**When** the popup opens
|
|
135
|
+
**Then** the token breaks across lines inside the popup — it never runs past the
|
|
136
|
+
popup's edge.
|
|
137
|
+
|
|
127
138
|
### Placement
|
|
128
139
|
|
|
129
140
|
- **Given** a `side` on the content
|
package/dist/llms.txt
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Acronis UI Kit for React — LLM Reference
|
|
2
2
|
|
|
3
|
-
> `@acronis-platform/ui-react` v5.5.
|
|
3
|
+
> `@acronis-platform/ui-react` v5.5.8
|
|
4
4
|
|
|
5
5
|
Machine-readable component reference compiled from framework-agnostic specs.
|
|
6
6
|
Each entry links to a self-contained markdown file with props, behavior,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@acronis-platform/ui-react",
|
|
3
|
-
"version": "5.5.
|
|
3
|
+
"version": "5.5.8",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/acronis/uikit.git",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"react-resizable-panels": "4.11.2",
|
|
57
57
|
"recharts": "3.8.1",
|
|
58
58
|
"tailwind-merge": "3.6.0",
|
|
59
|
-
"@acronis-platform/
|
|
60
|
-
"@acronis-platform/
|
|
61
|
-
"@acronis-platform/
|
|
59
|
+
"@acronis-platform/icons-react": "2.1.0",
|
|
60
|
+
"@acronis-platform/tokens-pd": "4.0.1",
|
|
61
|
+
"@acronis-platform/design-assets": "2.0.0"
|
|
62
62
|
},
|
|
63
63
|
"devDependencies": {
|
|
64
64
|
"@figma/code-connect": "1.4.8",
|