@luscii-healthtech/web-ui 35.2.1 → 35.3.1

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.
@@ -1,7 +1,7 @@
1
1
  import React from "react";
2
2
  import { SIZES } from "../../system/Sizes";
3
3
  import { ELEVATION } from "../../system/Elevation";
4
- import { BackgroundColor } from "../../types/general.types";
4
+ import { BackgroundColor, CursorOption } from "../../types/general.types";
5
5
  type Size = keyof typeof SIZES;
6
6
  declare const spacingKeys: readonly ["p", "pt", "pr", "pb", "pl", "px", "py", "m", "mt", "mr", "mb", "ml", "mx", "my"];
7
7
  type SpacingProps = Partial<Record<(typeof spacingKeys)[number], Size>>;
@@ -22,6 +22,7 @@ export type Props<C extends React.ElementType> = React.ComponentPropsWithoutRef<
22
22
  * Check {@link SIZES} for reference.
23
23
  */
24
24
  borderRadius?: keyof typeof SIZES;
25
+ cursor?: CursorOption;
25
26
  };
26
27
  export declare const Box: <C extends React.ElementType = "div">(props: Props<C>) => React.JSX.Element;
27
28
  export {};
@@ -1468,6 +1468,7 @@ const Box = (props) => {
1468
1468
  const borderRadiusClassName = createRadiusClassName(borderRadius);
1469
1469
  const attributesWithoutSpacingKeys = omit__default.default(attributes, spacingKeys);
1470
1470
  return React__namespace.default.createElement(Element, Object.assign({ className: classNames__default.default(spacingClasses, {
1471
+ "ui-bg-surface": props.backgroundColor === "surface",
1471
1472
  "ui-bg-slate-100": props.backgroundColor === "base",
1472
1473
  "ui-bg-blue-50": props.backgroundColor === "blue",
1473
1474
  "ui-bg-red-50": props.backgroundColor === "red",
@@ -1475,6 +1476,19 @@ const Box = (props) => {
1475
1476
  " ui-bg-amber-50": props.backgroundColor === "amber",
1476
1477
  [`ui-w-${width}`]: width && width !== "full",
1477
1478
  "ui-w-full": width === "full"
1479
+ }, {
1480
+ "ui-cursor-auto": props.cursor === "auto",
1481
+ "ui-cursor-default": props.cursor === "default",
1482
+ "ui-cursor-pointer": props.cursor === "pointer",
1483
+ "ui-cursor-wait": props.cursor === "wait",
1484
+ "ui-cursor-move": props.cursor === "move",
1485
+ "ui-cursor-help": props.cursor === "help",
1486
+ "ui-cursor-not-allowed": props.cursor === "not-allowed",
1487
+ "ui-cursor-progress": props.cursor === "progress",
1488
+ "ui-cursor-copy": props.cursor === "copy",
1489
+ "ui-cursor-no-drop": props.cursor === "no-drop",
1490
+ "ui-cursor-grab": props.cursor === "grab",
1491
+ "ui-cursor-grabbing": props.cursor === "grabbing"
1478
1492
  }, className, shadowClassName, borderRadiusClassName) }, attributesWithoutSpacingKeys));
1479
1493
  };
1480
1494