@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/cjs/index.js
CHANGED
|
@@ -169,11 +169,11 @@ var SvgChevronUpDown$1 = function (props) { return (React__namespace.createEleme
|
|
|
169
169
|
|
|
170
170
|
var SvgClipboard$1 = function (props) { return (React__namespace.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
171
171
|
React__namespace.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" }),
|
|
172
|
-
React__namespace.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.
|
|
172
|
+
React__namespace.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" }))); };
|
|
173
173
|
|
|
174
174
|
var SvgClipboardCheck$1 = function (props) { return (React__namespace.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
175
|
-
React__namespace.createElement("path", { fill: "currentColor", d: "M14.5
|
|
176
|
-
React__namespace.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.
|
|
175
|
+
React__namespace.createElement("path", { fill: "currentColor", d: "M14 9.5 17.5 6 19 7.5l-5 5L10.5 9 12 7.5l2 2Z" }),
|
|
176
|
+
React__namespace.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" }),
|
|
177
177
|
React__namespace.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" }))); };
|
|
178
178
|
|
|
179
179
|
var SvgClock$1 = function (props) { return (React__namespace.createElement("svg", __assign({ xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", fill: "none", viewBox: "0 0 24 24" }, props),
|
|
@@ -528,7 +528,9 @@ function Tooltip(_a) {
|
|
|
528
528
|
var hiddenOnMobileClasses = "s-hidden sm:s-block";
|
|
529
529
|
var tooltipCenterClasses = "s-left-1/2 -s-translate-x-1/2";
|
|
530
530
|
var tooltipPositionClasses = position === "above" ? "s-bottom-full s-mb-2" : "s-top-full s-mt-2";
|
|
531
|
-
|
|
531
|
+
// if tooltip text is too long we need to wrap it
|
|
532
|
+
var labelLength = (label === null || label === void 0 ? void 0 : label.length) || 0;
|
|
533
|
+
var labelClasses = labelLength > 80 ? "w-[38em]" : "s-whitespace-nowrap";
|
|
532
534
|
return (React.createElement("div", { onMouseEnter: handleMouseOver, onMouseLeave: handleMouseLeave, className: "s-relative s-inline-block" },
|
|
533
535
|
children,
|
|
534
536
|
React.createElement("div", { className: classNames("".concat(isHovered ? visibleClasses : hiddenClasses), baseClasses, hiddenOnMobileClasses, tooltipPositionClasses, tooltipCenterClasses, contentChildren ? "" : labelClasses), onAnimationEnd: function () { return setIsHovered(false); } }, contentChildren || label)));
|