@gusarov-studio/rubik-ui 9.0.0 → 9.1.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.
package/dist/Box/Box.d.ts CHANGED
@@ -1,10 +1,6 @@
1
1
  import React from "react";
2
+ import type { DimensionValue, StyleMultiValue, StyleSingleValue } from "./types";
2
3
  import "./Box.scss";
3
- import type { CSSUnit } from "../types/CSSUnit";
4
- type SingleValue = CSSUnit | "0" | `calc(${string})`;
5
- type MultiValue<T extends string> = T | `${T} ${T}` | `${T} ${T} ${T}` | `${T} ${T} ${T} ${T}`;
6
- type StyleSingleValue = SingleValue | number;
7
- type StyleMultiValue = MultiValue<SingleValue> | number;
8
4
  interface StyleProps {
9
5
  margin?: StyleMultiValue;
10
6
  marginTop?: StyleSingleValue;
@@ -29,6 +25,11 @@ interface StyleProps {
29
25
  }
30
26
  interface BoxProps extends React.HTMLAttributes<HTMLDivElement>, StyleProps {
31
27
  variant?: "transparent" | "primary" | "secondary";
28
+ width?: DimensionValue;
29
+ height?: DimensionValue;
30
+ direction?: "row" | "row-reverse" | "column" | "column-reverse";
31
+ alignItems?: "start" | "center" | "end" | "stretch" | "baseline";
32
+ justifyContent?: "start" | "center" | "end" | "space-between" | "space-around" | "space-evenly";
32
33
  className?: string;
33
34
  }
34
35
  declare const Box: React.MemoExoticComponent<React.ForwardRefExoticComponent<BoxProps & React.RefAttributes<HTMLDivElement>>>;
@@ -0,0 +1,7 @@
1
+ import type { CSSUnit } from "../types/CSSUnit";
2
+ type DimensionValue = CSSUnit | "0" | `calc(${string})` | number | "auto";
3
+ type SingleValue = CSSUnit | "0" | `calc(${string})`;
4
+ type MultiValue<T extends string> = T | `${T} ${T}` | `${T} ${T} ${T}` | `${T} ${T} ${T} ${T}`;
5
+ type StyleSingleValue = SingleValue | number;
6
+ type StyleMultiValue = MultiValue<SingleValue> | number;
7
+ export type { DimensionValue, SingleValue, MultiValue, StyleSingleValue, StyleMultiValue };
@@ -2,7 +2,7 @@ import React from "react";
2
2
  import "./Button.scss";
3
3
  interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
4
4
  appearance?: "fill" | "outline" | "ghost" | "text";
5
- variant: "accent" | "primary" | "secondary" | "success" | "danger" | "warning";
5
+ variant?: "accent" | "primary" | "secondary" | "success" | "danger" | "warning";
6
6
  size?: "16" | "20" | "24" | "28" | "32" | "36" | "40" | "44" | "48" | "56";
7
7
  shape?: "rectangle" | "rounded" | "pill";
8
8
  fullWidth?: boolean;