@dust-tt/sparkle 0.1.93 → 0.1.94
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 +6 -4
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +6 -4
- package/dist/esm/index.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
package/dist/esm/index.js
CHANGED
|
@@ -149,11 +149,11 @@ var SvgChevronUpDown$1 = function (props) { return (React.createElement("svg", _
|
|
|
149
149
|
|
|
150
150
|
var SvgClipboard$1 = function (props) { return (React.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
151
151
|
React.createElement("path", { fill: "currentColor", d: "M17 21v-3H7a1 1 0 0 1-1-1V7H3a1 1 0 0 0-1 1v13a1 1 0 0 0 1 1h13a1 1 0 0 0 1-1Z" }),
|
|
152
|
-
React.createElement("path", { fill: "currentColor", fillRule: "evenodd", d: "M7 16a1 1 0 0 0 1 1h12.99c.558 0 1.007-.451 1.007-1.008L22 3.008C22 2.45 21.549 2 20.992 2H8.008C7.45 2 7 2.451 7 3.
|
|
152
|
+
React.createElement("path", { fill: "currentColor", fillRule: "evenodd", d: "M7 16a1 1 0 0 0 1 1h12.99c.558 0 1.007-.451 1.007-1.008L22 3.008C22 2.45 21.549 2 20.992 2H8.008C7.45 2 7 2.451 7 3.007V16ZM19.502 4.5l-.002 10h-10v-10h10.002Z", clipRule: "evenodd" }))); };
|
|
153
153
|
|
|
154
154
|
var SvgClipboardCheck$1 = function (props) { return (React.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
155
|
-
React.createElement("path", { fill: "currentColor", d: "M14.5
|
|
156
|
-
React.createElement("path", { fill: "currentColor", fillRule: "evenodd", d: "M8 17a1 1 0 0 1-1-1V3.008C7 2.45 7.449 2 8.007 2h12.986C21.549 2 22 2.449 22 3.007l-.003 12.985c0 .557-.449 1.008-1.008 1.008H8Zm11.
|
|
155
|
+
React.createElement("path", { fill: "currentColor", d: "M14 9.5 17.5 6 19 7.5l-5 5L10.5 9 12 7.5l2 2Z" }),
|
|
156
|
+
React.createElement("path", { fill: "currentColor", fillRule: "evenodd", d: "M8 17a1 1 0 0 1-1-1V3.008C7 2.45 7.449 2 8.007 2h12.986C21.549 2 22 2.449 22 3.007l-.003 12.985c0 .557-.449 1.008-1.008 1.008H8Zm11.5-2.5.002-10H9.5v10h10Z", clipRule: "evenodd" }),
|
|
157
157
|
React.createElement("path", { fill: "currentColor", d: "M17 18v3a1 1 0 0 1-1 1H3a1 1 0 0 1-1-1V8a1 1 0 0 1 1-1h3v10a1 1 0 0 0 1 1h10Z" }))); };
|
|
158
158
|
|
|
159
159
|
var SvgClock$1 = function (props) { return (React.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
@@ -508,7 +508,9 @@ function Tooltip(_a) {
|
|
|
508
508
|
var hiddenOnMobileClasses = "s-hidden sm:s-block";
|
|
509
509
|
var tooltipCenterClasses = "s-left-1/2 -s-translate-x-1/2";
|
|
510
510
|
var tooltipPositionClasses = position === "above" ? "s-bottom-full s-mb-2" : "s-top-full s-mt-2";
|
|
511
|
-
|
|
511
|
+
// if tooltip text is too long we need to wrap it
|
|
512
|
+
var labelLength = (label === null || label === void 0 ? void 0 : label.length) || 0;
|
|
513
|
+
var labelClasses = labelLength > 80 ? "w-[38em]" : "s-whitespace-nowrap";
|
|
512
514
|
return (React__default.createElement("div", { onMouseEnter: handleMouseOver, onMouseLeave: handleMouseLeave, className: "s-relative s-inline-block" },
|
|
513
515
|
children,
|
|
514
516
|
React__default.createElement("div", { className: classNames("".concat(isHovered ? visibleClasses : hiddenClasses), baseClasses, hiddenOnMobileClasses, tooltipPositionClasses, tooltipCenterClasses, contentChildren ? "" : labelClasses), onAnimationEnd: function () { return setIsHovered(false); } }, contentChildren || label)));
|