@speakapbv/dough-component-library 10.6.1 → 10.7.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.
@@ -1,5 +1,5 @@
1
1
  import React, { MouseEventHandler, ReactNode, Ref, UIEvent } from "react";
2
- import { Colors, Sizes, DoughDataAttributes } from "../../../utils/constants";
2
+ import { Colors, Sizes, DoughDataAttributes, CardColors } from "../../../utils/constants";
3
3
  import "./box.scss";
4
4
  export declare enum BoxDirection {
5
5
  ROW = "row",
@@ -65,6 +65,7 @@ export interface Positions {
65
65
  top?: string;
66
66
  bottom?: string;
67
67
  }
68
+ export declare const ColorToHoverColor: Partial<Record<Exclude<BoxProps["color"], undefined>, string>>;
68
69
  export interface BoxProps {
69
70
  /** Base properties */
70
71
  className?: string;
@@ -81,7 +82,8 @@ export interface BoxProps {
81
82
  absolute?: boolean | Positions;
82
83
  zIndex?: number;
83
84
  /** Style properties */
84
- color?: Colors;
85
+ color?: Colors | CardColors;
86
+ hover?: boolean;
85
87
  border?: boolean;
86
88
  borderRadius?: boolean;
87
89
  rounded?: boolean;
@@ -117,4 +119,4 @@ export interface BoxProps {
117
119
  onMouseLeave?: MouseEventHandler<HTMLDivElement>;
118
120
  onClick?: MouseEventHandler<HTMLDivElement>;
119
121
  }
120
- export declare const Box: React.ForwardRefExoticComponent<Pick<BoxProps, "className" | "children" | "dataAttributes" | "width" | "height" | "minWidth" | "minHeight" | "maxWidth" | "maxHeight" | "absolute" | "zIndex" | "color" | "border" | "borderRadius" | "rounded" | "shadow" | "padding" | "transform" | "overflow" | "display" | "direction" | "flex" | "basis" | "grow" | "shrink" | "order" | "wrap" | "justifyContent" | "alignItems" | "alignContent" | "alignSelf" | "onScrollReachedBottom" | "onMouseEnter" | "onMouseMove" | "onMouseLeave" | "onClick"> & React.RefAttributes<HTMLDivElement>>;
122
+ export declare const Box: React.ForwardRefExoticComponent<Pick<BoxProps, "color" | "className" | "children" | "dataAttributes" | "width" | "height" | "minWidth" | "minHeight" | "maxWidth" | "maxHeight" | "absolute" | "zIndex" | "hover" | "border" | "borderRadius" | "rounded" | "shadow" | "padding" | "transform" | "overflow" | "display" | "direction" | "flex" | "basis" | "grow" | "shrink" | "order" | "wrap" | "justifyContent" | "alignItems" | "alignContent" | "alignSelf" | "onScrollReachedBottom" | "onMouseEnter" | "onMouseMove" | "onMouseLeave" | "onClick"> & React.RefAttributes<HTMLDivElement>>;
@@ -1,5 +1,5 @@
1
1
  import { ReactNode, ReactNodeArray, UIEvent } from "react";
2
- import { Colors, Sizes, DoughDataAttributes, BorderStyles } from "../../../utils/constants";
2
+ import { Colors, Sizes, DoughDataAttributes, BorderStyles, CardColors } from "../../../utils/constants";
3
3
  import "./card.scss";
4
4
  import { BoxOverflow } from "../box/box";
5
5
  export interface CardProps {
@@ -9,7 +9,8 @@ export interface CardProps {
9
9
  headerButtons?: ReactNodeArray;
10
10
  className?: string;
11
11
  dataAttributes?: DoughDataAttributes;
12
- color?: Colors;
12
+ color?: Colors | CardColors;
13
+ hover?: boolean;
13
14
  fullHeight?: boolean;
14
15
  maxHeight?: string;
15
16
  shadow?: boolean;
@@ -21,5 +21,6 @@ export interface LinkProps {
21
21
  download?: string;
22
22
  width?: string;
23
23
  flex?: string;
24
+ hover?: boolean;
24
25
  }
25
- export declare const Link: React.ForwardRefExoticComponent<Pick<LinkProps, "className" | "dataAttributes" | "color" | "children" | "onClick" | "onMouseDown" | "onPointerDown" | "allEvents" | "underline" | "fullWidth" | "disabled" | "colorOnlyOnHover" | "href" | "target" | "rel" | "download" | "width" | "flex"> & React.RefAttributes<HTMLAnchorElement>>;
26
+ export declare const Link: React.ForwardRefExoticComponent<Pick<LinkProps, "className" | "dataAttributes" | "color" | "children" | "onClick" | "onMouseDown" | "onPointerDown" | "allEvents" | "underline" | "fullWidth" | "disabled" | "colorOnlyOnHover" | "href" | "target" | "rel" | "download" | "width" | "flex" | "hover"> & React.RefAttributes<HTMLAnchorElement>>;
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import "./assets/scss/library.scss";
2
- export { Colors, ColorsText, ColorsIcon, FixedColors, Sizes, BorderStyles, Direction, DateRangeValue, DoughBooleanInputRef, DoughNumericInputRef, DoughTextInputRef, DoughValidationResult, Spacings, HorizontalAlignment, VerticalAlignment, DoughDataAttributes, BreakpointViewportSizes, AlertStatus, } from "./utils/constants";
2
+ export { CardColors, Colors, ColorsText, ColorsIcon, FixedColors, Sizes, BorderStyles, Direction, DateRangeValue, DoughBooleanInputRef, DoughNumericInputRef, DoughTextInputRef, DoughValidationResult, Spacings, HorizontalAlignment, VerticalAlignment, DoughDataAttributes, BreakpointViewportSizes, AlertStatus, } from "./utils/constants";
3
3
  export { Button, ButtonProps, ButtonInputType, } from "./components/button/button";
4
4
  export { Link, LinkProps } from "./components/link/link";
5
5
  export { Toggle } from "./components/form-elements/toggle/toggle";