dustyui 1.0.0 → 1.0.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/Badge/Badge.cjs +67 -0
- package/dist/Badge/Badge.d.ts +17 -0
- package/dist/Badge/Badge.js +33 -0
- package/dist/Badge/Badge.module.css +26 -0
- package/dist/Button/Button.cjs +74 -0
- package/dist/Button/Button.d.ts +14 -0
- package/dist/Button/Button.js +42 -0
- package/dist/Button/Button.module.css +37 -0
- package/dist/index.cjs +32 -0
- package/dist/index.d.ts +3 -8
- package/dist/index.js +6 -49
- package/dist/styles/tokens.css +15 -0
- package/package.json +39 -8
- package/dist/index.css +0 -9
- package/dist/index.d.mts +0 -8
- package/dist/index.mjs +0 -13
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var Badge_exports = {};
|
|
30
|
+
__export(Badge_exports, {
|
|
31
|
+
Badge: () => Badge
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(Badge_exports);
|
|
34
|
+
var import_react = __toESM(require("react"));
|
|
35
|
+
var import_react2 = require("react");
|
|
36
|
+
var import_clsx = __toESM(require("clsx"));
|
|
37
|
+
var import_Badge_module = __toESM(require("./Badge.module.css"));
|
|
38
|
+
const Badge = (0, import_react2.forwardRef)(
|
|
39
|
+
({
|
|
40
|
+
label,
|
|
41
|
+
icon,
|
|
42
|
+
iconPosition = "left",
|
|
43
|
+
announce = false,
|
|
44
|
+
dataTestId,
|
|
45
|
+
className
|
|
46
|
+
}, ref) => {
|
|
47
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
48
|
+
"span",
|
|
49
|
+
{
|
|
50
|
+
ref,
|
|
51
|
+
className: (0, import_clsx.default)(import_Badge_module.default.badge, className),
|
|
52
|
+
"data-testid": dataTestId,
|
|
53
|
+
"data-icon-position": iconPosition,
|
|
54
|
+
role: announce ? "status" : void 0,
|
|
55
|
+
"aria-live": announce ? "polite" : void 0
|
|
56
|
+
},
|
|
57
|
+
icon && iconPosition === "left" && /* @__PURE__ */ import_react.default.createElement("span", { className: import_Badge_module.default.icon, "aria-hidden": "true" }, icon),
|
|
58
|
+
/* @__PURE__ */ import_react.default.createElement("span", { className: import_Badge_module.default.label }, label),
|
|
59
|
+
icon && iconPosition === "right" && /* @__PURE__ */ import_react.default.createElement("span", { className: import_Badge_module.default.icon, "aria-hidden": "true" }, icon)
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
);
|
|
63
|
+
Badge.displayName = "Badge";
|
|
64
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
65
|
+
0 && (module.exports = {
|
|
66
|
+
Badge
|
|
67
|
+
});
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import React, { type ReactNode } from "react";
|
|
2
|
+
interface BadgeProps {
|
|
3
|
+
/** Visible text inside the badge. */
|
|
4
|
+
label: string;
|
|
5
|
+
/** Optional icon */
|
|
6
|
+
icon?: ReactNode;
|
|
7
|
+
/** Where to place the icon relative to the label. */
|
|
8
|
+
iconPosition?: "left" | "right";
|
|
9
|
+
/** If true, announces updates to assistive tech (use when value changes dynamically). */
|
|
10
|
+
announce?: boolean;
|
|
11
|
+
/** Test hook. */
|
|
12
|
+
dataTestId?: string;
|
|
13
|
+
/** Extra class on the root element. */
|
|
14
|
+
className?: string;
|
|
15
|
+
}
|
|
16
|
+
export declare const Badge: React.ForwardRefExoticComponent<BadgeProps & React.RefAttributes<HTMLSpanElement>>;
|
|
17
|
+
export {};
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import { forwardRef } from "react";
|
|
3
|
+
import clsx from "clsx";
|
|
4
|
+
import styles from "./Badge.module.css";
|
|
5
|
+
const Badge = forwardRef(
|
|
6
|
+
({
|
|
7
|
+
label,
|
|
8
|
+
icon,
|
|
9
|
+
iconPosition = "left",
|
|
10
|
+
announce = false,
|
|
11
|
+
dataTestId,
|
|
12
|
+
className
|
|
13
|
+
}, ref) => {
|
|
14
|
+
return /* @__PURE__ */ React.createElement(
|
|
15
|
+
"span",
|
|
16
|
+
{
|
|
17
|
+
ref,
|
|
18
|
+
className: clsx(styles.badge, className),
|
|
19
|
+
"data-testid": dataTestId,
|
|
20
|
+
"data-icon-position": iconPosition,
|
|
21
|
+
role: announce ? "status" : void 0,
|
|
22
|
+
"aria-live": announce ? "polite" : void 0
|
|
23
|
+
},
|
|
24
|
+
icon && iconPosition === "left" && /* @__PURE__ */ React.createElement("span", { className: styles.icon, "aria-hidden": "true" }, icon),
|
|
25
|
+
/* @__PURE__ */ React.createElement("span", { className: styles.label }, label),
|
|
26
|
+
icon && iconPosition === "right" && /* @__PURE__ */ React.createElement("span", { className: styles.icon, "aria-hidden": "true" }, icon)
|
|
27
|
+
);
|
|
28
|
+
}
|
|
29
|
+
);
|
|
30
|
+
Badge.displayName = "Badge";
|
|
31
|
+
export {
|
|
32
|
+
Badge
|
|
33
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
.badge {
|
|
2
|
+
display: inline-flex;
|
|
3
|
+
align-items: center;
|
|
4
|
+
font-size: 0.75rem;
|
|
5
|
+
line-height: 1rem;
|
|
6
|
+
padding: 0.125rem 0.625rem;
|
|
7
|
+
font-weight: 600;
|
|
8
|
+
border: 1px solid var(--color-gray-300);
|
|
9
|
+
width: max-content;
|
|
10
|
+
border-radius: 12px;
|
|
11
|
+
align-items: center;
|
|
12
|
+
gap: 4px;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.icon {
|
|
16
|
+
width: 0.875rem;
|
|
17
|
+
height: 0.875rem;
|
|
18
|
+
display: inline-flex;
|
|
19
|
+
align-items: center;
|
|
20
|
+
justify-content: center;
|
|
21
|
+
line-height: 0;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.label {
|
|
25
|
+
white-space: nowrap;
|
|
26
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
+
};
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
+
mod
|
|
27
|
+
));
|
|
28
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
+
var Button_exports = {};
|
|
30
|
+
__export(Button_exports, {
|
|
31
|
+
Button: () => Button
|
|
32
|
+
});
|
|
33
|
+
module.exports = __toCommonJS(Button_exports);
|
|
34
|
+
var import_react = __toESM(require("react"));
|
|
35
|
+
var import_clsx = __toESM(require("clsx"));
|
|
36
|
+
var import_Button_module = __toESM(require("./Button.module.css"));
|
|
37
|
+
const Button = (0, import_react.forwardRef)(
|
|
38
|
+
({
|
|
39
|
+
children,
|
|
40
|
+
variant = "primary",
|
|
41
|
+
loading = false,
|
|
42
|
+
dataTestId,
|
|
43
|
+
className,
|
|
44
|
+
disabled,
|
|
45
|
+
type = "button",
|
|
46
|
+
...props
|
|
47
|
+
}, ref) => {
|
|
48
|
+
const isDisabled = disabled || loading;
|
|
49
|
+
return /* @__PURE__ */ import_react.default.createElement(
|
|
50
|
+
"button",
|
|
51
|
+
{
|
|
52
|
+
ref,
|
|
53
|
+
type,
|
|
54
|
+
className: (0, import_clsx.default)(
|
|
55
|
+
import_Button_module.default.button,
|
|
56
|
+
import_Button_module.default[variant],
|
|
57
|
+
isDisabled && import_Button_module.default.disabled,
|
|
58
|
+
className
|
|
59
|
+
),
|
|
60
|
+
"data-testid": dataTestId,
|
|
61
|
+
"data-variant": variant,
|
|
62
|
+
"aria-busy": loading || void 0,
|
|
63
|
+
disabled: isDisabled,
|
|
64
|
+
...props
|
|
65
|
+
},
|
|
66
|
+
children
|
|
67
|
+
);
|
|
68
|
+
}
|
|
69
|
+
);
|
|
70
|
+
Button.displayName = "Button";
|
|
71
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
72
|
+
0 && (module.exports = {
|
|
73
|
+
Button
|
|
74
|
+
});
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React, { type ButtonHTMLAttributes, type ReactNode } from "react";
|
|
2
|
+
export interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
|
3
|
+
/** Content inside the button */
|
|
4
|
+
children: ReactNode;
|
|
5
|
+
/** Visual style variant */
|
|
6
|
+
variant?: "primary" | "secondary";
|
|
7
|
+
/** Show as busy (disables interaction + aria-busy) */
|
|
8
|
+
loading?: boolean;
|
|
9
|
+
/** Test hook. */
|
|
10
|
+
dataTestId?: string;
|
|
11
|
+
/** Additional CSS class names */
|
|
12
|
+
className?: string;
|
|
13
|
+
}
|
|
14
|
+
export declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import React, {
|
|
2
|
+
forwardRef
|
|
3
|
+
} from "react";
|
|
4
|
+
import clsx from "clsx";
|
|
5
|
+
import styles from "./Button.module.css";
|
|
6
|
+
const Button = forwardRef(
|
|
7
|
+
({
|
|
8
|
+
children,
|
|
9
|
+
variant = "primary",
|
|
10
|
+
loading = false,
|
|
11
|
+
dataTestId,
|
|
12
|
+
className,
|
|
13
|
+
disabled,
|
|
14
|
+
type = "button",
|
|
15
|
+
...props
|
|
16
|
+
}, ref) => {
|
|
17
|
+
const isDisabled = disabled || loading;
|
|
18
|
+
return /* @__PURE__ */ React.createElement(
|
|
19
|
+
"button",
|
|
20
|
+
{
|
|
21
|
+
ref,
|
|
22
|
+
type,
|
|
23
|
+
className: clsx(
|
|
24
|
+
styles.button,
|
|
25
|
+
styles[variant],
|
|
26
|
+
isDisabled && styles.disabled,
|
|
27
|
+
className
|
|
28
|
+
),
|
|
29
|
+
"data-testid": dataTestId,
|
|
30
|
+
"data-variant": variant,
|
|
31
|
+
"aria-busy": loading || void 0,
|
|
32
|
+
disabled: isDisabled,
|
|
33
|
+
...props
|
|
34
|
+
},
|
|
35
|
+
children
|
|
36
|
+
);
|
|
37
|
+
}
|
|
38
|
+
);
|
|
39
|
+
Button.displayName = "Button";
|
|
40
|
+
export {
|
|
41
|
+
Button
|
|
42
|
+
};
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
.button {
|
|
2
|
+
display: inline-block;
|
|
3
|
+
padding: 0.75rem 1.5rem;
|
|
4
|
+
border-radius: 8px;
|
|
5
|
+
font-weight: var(--weight-semibold);
|
|
6
|
+
text-decoration: none;
|
|
7
|
+
line-height: 1;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/* Primary: filled black */
|
|
11
|
+
.primary {
|
|
12
|
+
background-color: var(--color-black);
|
|
13
|
+
color: var(--color-white);
|
|
14
|
+
border: 1px solid var(--color-black);
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.primary:hover {
|
|
18
|
+
background-color: var(--color-black-700);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/* Secondary: outline black */
|
|
22
|
+
.secondary {
|
|
23
|
+
background-color: transparent;
|
|
24
|
+
color: var(--color-black);
|
|
25
|
+
border: 1px solid var(--color-black);
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.secondary:hover {
|
|
29
|
+
background-color: var(--color-gray-200);
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/* Disabled state */
|
|
33
|
+
.disabled {
|
|
34
|
+
opacity: 0.5;
|
|
35
|
+
cursor: not-allowed;
|
|
36
|
+
pointer-events: none;
|
|
37
|
+
}
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var src_exports = {};
|
|
20
|
+
__export(src_exports, {
|
|
21
|
+
Badge: () => import_Badge.Badge,
|
|
22
|
+
Button: () => import_Button.Button
|
|
23
|
+
});
|
|
24
|
+
module.exports = __toCommonJS(src_exports);
|
|
25
|
+
var import_tokens = require("./styles/tokens.css");
|
|
26
|
+
var import_Badge = require("./Badge/Badge");
|
|
27
|
+
var import_Button = require("./Button/Button");
|
|
28
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
29
|
+
0 && (module.exports = {
|
|
30
|
+
Badge,
|
|
31
|
+
Button
|
|
32
|
+
});
|
package/dist/index.d.ts
CHANGED
|
@@ -1,8 +1,3 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
children: React.ReactNode;
|
|
5
|
-
};
|
|
6
|
-
declare const Button: ({ children }: Props) => React.JSX.Element;
|
|
7
|
-
|
|
8
|
-
export { Button };
|
|
1
|
+
import "./styles/tokens.css";
|
|
2
|
+
export { Badge } from "./Badge/Badge";
|
|
3
|
+
export { Button } from "./Button/Button";
|
package/dist/index.js
CHANGED
|
@@ -1,50 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
-
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
-
var __export = (target, all) => {
|
|
9
|
-
for (var name in all)
|
|
10
|
-
__defProp(target, name, { get: all[name], enumerable: true });
|
|
11
|
-
};
|
|
12
|
-
var __copyProps = (to, from, except, desc) => {
|
|
13
|
-
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
-
for (let key of __getOwnPropNames(from))
|
|
15
|
-
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
-
}
|
|
18
|
-
return to;
|
|
19
|
-
};
|
|
20
|
-
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
22
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
23
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
24
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
25
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
26
|
-
mod
|
|
27
|
-
));
|
|
28
|
-
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
29
|
-
|
|
30
|
-
// src/index.ts
|
|
31
|
-
var src_exports = {};
|
|
32
|
-
__export(src_exports, {
|
|
33
|
-
Button: () => Button
|
|
34
|
-
});
|
|
35
|
-
module.exports = __toCommonJS(src_exports);
|
|
36
|
-
|
|
37
|
-
// src/Button/Button.tsx
|
|
38
|
-
var import_react = __toESM(require("react"));
|
|
39
|
-
|
|
40
|
-
// src/Button/Button.module.css
|
|
41
|
-
var Button_module_default = {};
|
|
42
|
-
|
|
43
|
-
// src/Button/Button.tsx
|
|
44
|
-
var Button = ({ children }) => {
|
|
45
|
-
return /* @__PURE__ */ import_react.default.createElement("button", { className: Button_module_default.button }, children);
|
|
46
|
-
};
|
|
47
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
48
|
-
0 && (module.exports = {
|
|
1
|
+
import "./styles/tokens.css";
|
|
2
|
+
import { Badge } from "./Badge/Badge";
|
|
3
|
+
import { Button } from "./Button/Button";
|
|
4
|
+
export {
|
|
5
|
+
Badge,
|
|
49
6
|
Button
|
|
50
|
-
}
|
|
7
|
+
};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
:root {
|
|
2
|
+
/* Color Variables */
|
|
3
|
+
--color-black: #222222;
|
|
4
|
+
--color-black-800: #2a2a2a;
|
|
5
|
+
--color-black-700: #2f2f2f;
|
|
6
|
+
--color-gray-700: #444444;
|
|
7
|
+
--color-gray-600: #666666;
|
|
8
|
+
--color-gray-500: #999999;
|
|
9
|
+
--color-gray-400: #bbbbbb;
|
|
10
|
+
--color-gray-300: #dddddd;
|
|
11
|
+
--color-gray-200: #eeeeee;
|
|
12
|
+
--color-gray-100: #f5f5f5;
|
|
13
|
+
--color-gray-50: #fcfcfc;
|
|
14
|
+
--color-white: #fafafa;
|
|
15
|
+
}
|
package/package.json
CHANGED
|
@@ -1,8 +1,15 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dustyui",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "A minimalist, neutral-toned React UI component library styled with CSS Modules.",
|
|
5
|
-
"keywords": [
|
|
5
|
+
"keywords": [
|
|
6
|
+
"react",
|
|
7
|
+
"ui",
|
|
8
|
+
"design-system",
|
|
9
|
+
"component-library",
|
|
10
|
+
"css-modules",
|
|
11
|
+
"dustyui"
|
|
12
|
+
],
|
|
6
13
|
"author": "Wioletta Gluza <wiolagluza@gmail.com> (https://wiola.dev)",
|
|
7
14
|
"license": "MIT",
|
|
8
15
|
"repository": {
|
|
@@ -11,12 +18,22 @@
|
|
|
11
18
|
},
|
|
12
19
|
"homepage": "https://dustyui.com",
|
|
13
20
|
"main": "dist/index.cjs",
|
|
14
|
-
"module": "dist/index.
|
|
21
|
+
"module": "dist/index.js",
|
|
15
22
|
"types": "dist/index.d.ts",
|
|
16
|
-
"files": [
|
|
23
|
+
"files": [
|
|
24
|
+
"dist"
|
|
25
|
+
],
|
|
17
26
|
"scripts": {
|
|
18
|
-
"build": "tsup"
|
|
27
|
+
"build": "rm -rf dist && tsup && tsc -p tsconfig.build.json && cpy \"src/**/*.css\" dist --parents",
|
|
28
|
+
"typecheck": "tsc --noEmit",
|
|
29
|
+
"format": "prettier --check .",
|
|
30
|
+
"format:fix": "prettier --write .",
|
|
31
|
+
"lint": "eslint .",
|
|
32
|
+
"lint:css": "stylelint 'src/**/*.css'"
|
|
19
33
|
},
|
|
34
|
+
"sideEffects": [
|
|
35
|
+
"**/*.css"
|
|
36
|
+
],
|
|
20
37
|
"peerDependencies": {
|
|
21
38
|
"react": ">=17.0.0",
|
|
22
39
|
"react-dom": ">=17.0.0"
|
|
@@ -24,14 +41,28 @@
|
|
|
24
41
|
"devDependencies": {
|
|
25
42
|
"@types/react": "^18.0.0",
|
|
26
43
|
"@types/react-dom": "^18.0.0",
|
|
27
|
-
"typescript": "^
|
|
28
|
-
"
|
|
44
|
+
"@typescript-eslint/eslint-plugin": "^8.35.1",
|
|
45
|
+
"@typescript-eslint/parser": "^8.35.1",
|
|
46
|
+
"cpy-cli": "^6.0.0",
|
|
47
|
+
"eslint": "^9.30.1",
|
|
48
|
+
"eslint-config-prettier": "^10.1.5",
|
|
49
|
+
"eslint-config-turbo": "^2.5.4",
|
|
50
|
+
"eslint-plugin-react": "^7.37.5",
|
|
51
|
+
"prettier": "^3.6.2",
|
|
52
|
+
"stylelint": "^16.21.1",
|
|
53
|
+
"stylelint-config-css-modules": "^4.5.1",
|
|
54
|
+
"stylelint-config-standard": "^38.0.0",
|
|
55
|
+
"tsup": "^7.0.0",
|
|
56
|
+
"typescript": "^5.0.0"
|
|
29
57
|
},
|
|
30
58
|
"exports": {
|
|
31
59
|
".": {
|
|
32
|
-
"import": "./dist/index.
|
|
60
|
+
"import": "./dist/index.js",
|
|
33
61
|
"require": "./dist/index.cjs",
|
|
34
62
|
"types": "./dist/index.d.ts"
|
|
35
63
|
}
|
|
64
|
+
},
|
|
65
|
+
"dependencies": {
|
|
66
|
+
"clsx": "^2.1.1"
|
|
36
67
|
}
|
|
37
68
|
}
|
package/dist/index.css
DELETED
package/dist/index.d.mts
DELETED
package/dist/index.mjs
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
// src/Button/Button.tsx
|
|
2
|
-
import React from "react";
|
|
3
|
-
|
|
4
|
-
// src/Button/Button.module.css
|
|
5
|
-
var Button_module_default = {};
|
|
6
|
-
|
|
7
|
-
// src/Button/Button.tsx
|
|
8
|
-
var Button = ({ children }) => {
|
|
9
|
-
return /* @__PURE__ */ React.createElement("button", { className: Button_module_default.button }, children);
|
|
10
|
-
};
|
|
11
|
-
export {
|
|
12
|
-
Button
|
|
13
|
-
};
|