@ai-matrx/design-system 0.20.22 → 0.21.0

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.
@@ -107,13 +107,28 @@ var buttonVariants = (0, import_class_variance_authority.cva)(
107
107
  }
108
108
  }
109
109
  );
110
+ var TOUCH_FLOOR_SIZES = /* @__PURE__ */ new Set([
111
+ "xs",
112
+ "sm",
113
+ "default",
114
+ "md",
115
+ "lg",
116
+ "icon",
117
+ "icon-sm",
118
+ "roundIcon"
119
+ ]);
120
+ var SQUARE_SIZES = /* @__PURE__ */ new Set(["icon", "icon-sm", "roundIcon"]);
110
121
  var Button = React.forwardRef(
111
122
  ({ className, variant, size, asChild = false, ...props }, ref) => {
112
123
  const Component = asChild ? import_react_slot.Slot : "button";
124
+ const resolvedSize = size ?? "default";
113
125
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
114
126
  Component,
115
127
  {
116
128
  className: cn(buttonVariants({ variant, size, className })),
129
+ "data-matrx-button": "",
130
+ "data-tap-floor": TOUCH_FLOOR_SIZES.has(resolvedSize) ? "" : void 0,
131
+ "data-tap-floor-square": SQUARE_SIZES.has(resolvedSize) ? "" : void 0,
117
132
  ref,
118
133
  ...props
119
134
  }