@yomologic/react-ui 0.5.0 → 0.5.2
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/base.css +41 -10
- package/dist/index.d.mts +1006 -0
- package/dist/index.d.ts +17 -5
- package/dist/index.js +269 -216
- package/dist/index.js.map +1 -0
- package/dist/index.mjs +354 -301
- package/dist/index.mjs.map +1 -0
- package/dist/styles.css +162 -52
- package/dist/styles.css.map +1 -0
- package/dist/styles.d.mts +2 -0
- package/package.json +4 -5
package/dist/index.d.ts
CHANGED
|
@@ -2,14 +2,23 @@ import React, { ReactNode } from 'react';
|
|
|
2
2
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
3
3
|
import { ClassValue } from 'clsx';
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
type ButtonBaseProps = {
|
|
6
6
|
variant?: "primary" | "secondary" | "outline" | "ghost" | "info" | "success" | "warning" | "error";
|
|
7
7
|
size?: "xs" | "sm" | "md" | "lg" | "xl";
|
|
8
8
|
isLoading?: boolean;
|
|
9
9
|
leftIcon?: React.ReactNode;
|
|
10
10
|
rightIcon?: React.ReactNode;
|
|
11
|
-
|
|
12
|
-
|
|
11
|
+
children?: React.ReactNode;
|
|
12
|
+
className?: string;
|
|
13
|
+
};
|
|
14
|
+
type ButtonAsButton = ButtonBaseProps & Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, keyof ButtonBaseProps> & {
|
|
15
|
+
href?: never;
|
|
16
|
+
};
|
|
17
|
+
type ButtonAsLink = ButtonBaseProps & Omit<React.AnchorHTMLAttributes<HTMLAnchorElement>, keyof ButtonBaseProps> & {
|
|
18
|
+
href: string;
|
|
19
|
+
};
|
|
20
|
+
type ButtonProps = ButtonAsButton | ButtonAsLink;
|
|
21
|
+
declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement | HTMLAnchorElement>>;
|
|
13
22
|
|
|
14
23
|
interface FormState {
|
|
15
24
|
values: Record<string, any>;
|
|
@@ -67,10 +76,11 @@ interface InputProps extends Omit<React.InputHTMLAttributes<HTMLInputElement>, "
|
|
|
67
76
|
}
|
|
68
77
|
declare const Input: React.ForwardRefExoticComponent<InputProps & React.RefAttributes<HTMLInputElement>>;
|
|
69
78
|
|
|
70
|
-
interface CardProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
71
|
-
variant?: "default" | "bordered" | "elevated";
|
|
79
|
+
interface CardProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "variant" | "accentColor"> {
|
|
80
|
+
variant?: "default" | "bordered" | "elevated" | "accent";
|
|
72
81
|
padding?: "none" | "sm" | "md" | "lg";
|
|
73
82
|
hoverable?: boolean;
|
|
83
|
+
accentColor?: string;
|
|
74
84
|
}
|
|
75
85
|
declare const Card: React.ForwardRefExoticComponent<CardProps & React.RefAttributes<HTMLDivElement>>;
|
|
76
86
|
declare const CardHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & React.RefAttributes<HTMLDivElement>>;
|
|
@@ -84,10 +94,12 @@ interface CardMediaProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
|
84
94
|
component?: "img" | "video" | "div";
|
|
85
95
|
aspectRatio?: "16/9" | "4/3" | "1/1" | "21/9" | string;
|
|
86
96
|
alt?: string;
|
|
97
|
+
objectFit?: "cover" | "contain" | "fill" | "none" | "scale-down";
|
|
87
98
|
}
|
|
88
99
|
declare const CardMedia: React.ForwardRefExoticComponent<CardMediaProps & React.RefAttributes<HTMLDivElement>>;
|
|
89
100
|
interface CardActionsProps extends React.HTMLAttributes<HTMLDivElement> {
|
|
90
101
|
disableSpacing?: boolean;
|
|
102
|
+
position?: "left" | "center" | "right";
|
|
91
103
|
}
|
|
92
104
|
declare const CardActions: React.ForwardRefExoticComponent<CardActionsProps & React.RefAttributes<HTMLDivElement>>;
|
|
93
105
|
interface CardActionAreaProps extends React.HTMLAttributes<HTMLDivElement> {
|