belong-ui-lib 1.0.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/Button.d.ts +7 -0
- package/dist/Button.js +6 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1 -0
- package/package.json +23 -0
- package/src/Button.tsx +19 -0
- package/src/index.tsx +1 -0
- package/tsconfig.json +15 -0
package/dist/Button.d.ts
ADDED
package/dist/Button.js
ADDED
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Button } from "./Button";
|
package/dist/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Button } from "./Button";
|
package/package.json
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "belong-ui-lib",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "belong-ui-lib",
|
|
5
|
+
"main": "index.js",
|
|
6
|
+
"author": "belong",
|
|
7
|
+
"scripts": {
|
|
8
|
+
"build": "tsc"
|
|
9
|
+
},
|
|
10
|
+
"dependencies": {
|
|
11
|
+
"react": "^19.2.3",
|
|
12
|
+
"react-dom": "^19.2.3"
|
|
13
|
+
},
|
|
14
|
+
"devDependencies": {
|
|
15
|
+
"@types/react": "^19.2.7",
|
|
16
|
+
"@types/react-dom": "^19.2.3",
|
|
17
|
+
"typescript": "^5.9.3"
|
|
18
|
+
},
|
|
19
|
+
"peerDependencies": {
|
|
20
|
+
"react": ">=16",
|
|
21
|
+
"react-dom": ">=16"
|
|
22
|
+
}
|
|
23
|
+
}
|
package/src/Button.tsx
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
|
|
3
|
+
export interface ButtonProps {
|
|
4
|
+
text: string;
|
|
5
|
+
onClick?: () => void;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
const Button: React.FC<ButtonProps> = ({ text, onClick }) => {
|
|
9
|
+
return (
|
|
10
|
+
<button
|
|
11
|
+
style={{ padding: "8px 16px", cursor: "pointer" }}
|
|
12
|
+
onClick={onClick}
|
|
13
|
+
>
|
|
14
|
+
{text}
|
|
15
|
+
</button>
|
|
16
|
+
);
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
export default Button;
|
package/src/index.tsx
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as Button } from "./Button";
|
package/tsconfig.json
ADDED