@dust-tt/sparkle 0.2.82 → 0.2.83

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.
@@ -2,6 +2,8 @@ import { SparkleContext } from "./context";
2
2
  export { SparkleContext };
3
3
  import { Div3D, Hover3D } from "./components/Hover3D";
4
4
  export { Div3D, Hover3D };
5
+ import { Hoverable } from "./components/Hoverable";
6
+ export { Hoverable };
5
7
  import { Button } from "./components/Button";
6
8
  export { Button };
7
9
  import { SliderToggle } from "./components/SliderToggle";
package/dist/cjs/index.js CHANGED
@@ -197,6 +197,22 @@ var Div3D = function (_a) {
197
197
  return (React.createElement("div", { style: style, className: className }, children));
198
198
  };
199
199
 
200
+ function classNames() {
201
+ var classes = [];
202
+ for (var _i = 0; _i < arguments.length; _i++) {
203
+ classes[_i] = arguments[_i];
204
+ }
205
+ return classes.filter(Boolean).join(" ");
206
+ }
207
+
208
+ Hoverable.defaultProps = {
209
+ className: "",
210
+ };
211
+ function Hoverable(_a) {
212
+ var children = _a.children, className = _a.className, onClick = _a.onClick;
213
+ return (React.createElement("span", { className: classNames("s-cursor-pointer s-duration-300 hover:s-text-action-500 active:s-text-action-600", className), onClick: onClick }, children));
214
+ }
215
+
200
216
  var SvgArrowDown$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),
201
217
  React__namespace.createElement("path", { fill: "currentColor", d: "m13.5 15.5 5-5 2 2L12 21l-8.5-8.5 2-2 5 5V3h3v12.5Z" }))); };
202
218
 
@@ -538,14 +554,6 @@ var SvgXCircle$1 = function (props) { return (React__namespace.createElement("sv
538
554
  var SvgXMark$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),
539
555
  React__namespace.createElement("path", { fill: "currentColor", d: "m12 10 5-5 2 2-5 5 5 5-2 2-5-5-5 5-2-2 5-5-5-5 2-2 5 5Z" }))); };
540
556
 
541
- function classNames() {
542
- var classes = [];
543
- for (var _i = 0; _i < arguments.length; _i++) {
544
- classes[_i] = arguments[_i];
545
- }
546
- return classes.filter(Boolean).join(" ");
547
- }
548
-
549
557
  var colors = [
550
558
  "s-bg-red-300",
551
559
  "s-bg-orange-300",
@@ -33916,6 +33924,7 @@ exports.HandThumbUpStrokeIcon = SvgHandThumbUp;
33916
33924
  exports.HexagonIcon = SvgHexagon$1;
33917
33925
  exports.HexagonStrokeIcon = SvgHexagon;
33918
33926
  exports.Hover3D = Hover3D;
33927
+ exports.Hoverable = Hoverable;
33919
33928
  exports.HuggingFaceLogo = SvgHuggingFace;
33920
33929
  exports.Icon = Icon;
33921
33930
  exports.IconButton = IconButton;