@likelion-design/ui 0.1.0 → 0.1.1

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.
Files changed (2) hide show
  1. package/README.md +90 -22
  2. package/package.json +17 -1
package/README.md CHANGED
@@ -1,40 +1,108 @@
1
- This is a [Next.js](https://nextjs.org) project bootstrapped with [`create-next-app`](https://nextjs.org/docs/pages/api-reference/create-next-app).
1
+ # @likelion-design/ui
2
2
 
3
- ## Getting Started
3
+ React UI 컴포넌트 라이브러리
4
4
 
5
- First, run the development server:
5
+ ## 설치
6
6
 
7
7
  ```bash
8
- npm run dev
8
+ npm install @likelion-design/ui
9
9
  # or
10
- yarn dev
11
- # or
12
- pnpm dev
13
- # or
14
- bun dev
10
+ yarn add @likelion-design/ui
11
+ ```
12
+
13
+ ## 사용법
14
+
15
+ ### 1. CSS 스타일 import (필수)
16
+
17
+ 컴포넌트를 사용하기 전에 반드시 CSS 파일을 import해야 합니다:
18
+
19
+ ```tsx
20
+ // App.tsx 또는 최상위 파일
21
+ import "@likelion-design/ui/styles.css";
22
+ ```
23
+
24
+ ### 2. 컴포넌트 사용
25
+
26
+ ```tsx
27
+ import { ActionButton, IconButton } from "@likelion-design/ui";
28
+
29
+ function App() {
30
+ return (
31
+ <div>
32
+ <ActionButton
33
+ size="medium"
34
+ variant="primary"
35
+ onClick={() => console.log("clicked")}
36
+ >
37
+ Click me
38
+ </ActionButton>
39
+
40
+ <IconButton
41
+ size="large"
42
+ variant="primary"
43
+ icon={<YourIcon />}
44
+ aria-label="좋아요"
45
+ />
46
+ </div>
47
+ );
48
+ }
15
49
  ```
16
50
 
17
- Open [http://localhost:3000](http://localhost:3000) with your browser to see the result.
51
+ ## 컴포넌트
18
52
 
19
- You can start editing the page by modifying `pages/index.tsx`. The page auto-updates as you edit the file.
53
+ ### ActionButton
20
54
 
21
- [API routes](https://nextjs.org/docs/pages/building-your-application/routing/api-routes) can be accessed on [http://localhost:3000/api/hello](http://localhost:3000/api/hello). This endpoint can be edited in `pages/api/hello.ts`.
55
+ 액션 버튼 컴포넌트 - 사용자가 액션을 트리거하거나 이벤트를 실행할 사용
22
56
 
23
- The `pages/api` directory is mapped to `/api/*`. Files in this directory are treated as [API routes](https://nextjs.org/docs/pages/building-your-application/routing/api-routes) instead of React pages.
57
+ **Props:**
24
58
 
25
- This project uses [`next/font`](https://nextjs.org/docs/pages/building-your-application/optimizing/fonts) to automatically optimize and load [Geist](https://vercel.com/font), a new font family for Vercel.
59
+ - `size`: `"xlarge" | "large" | "medium" | "small"`
60
+ - `variant`: `"primary" | "neutral" | "secondary"`
61
+ - `shape`: `"solid" | "outline" | "ghost"`
62
+ - `state`: `"enabled" | "hovered" | "loading" | "disabled"`
63
+ - `prefixIcon`: 앞쪽 아이콘
64
+ - `suffixIcon`: 뒤쪽 아이콘
65
+ - `loading`: 로딩 상태
26
66
 
27
- ## Learn More
67
+ ### IconButton
28
68
 
29
- To learn more about Next.js, take a look at the following resources:
69
+ 아이콘 버튼 컴포넌트 - 텍스트 레이블 없이 아이콘만으로 액션을 전달
30
70
 
31
- - [Next.js Documentation](https://nextjs.org/docs) - learn about Next.js features and API.
32
- - [Learn Next.js](https://nextjs.org/learn-pages-router) - an interactive Next.js tutorial.
71
+ **Props:**
33
72
 
34
- You can check out [the Next.js GitHub repository](https://github.com/vercel/next.js) - your feedback and contributions are welcome!
73
+ - `size`: `"xlarge" | "large" | "medium" | "small"`
74
+ - `variant`: `"primary" | "neutral"`
75
+ - `iconType`: `"solid" | "outline" | "weak"`
76
+ - `state`: `"enabled" | "hovered" | "disabled"`
77
+ - `icon`: React 아이콘 컴포넌트
78
+ - `aria-label`: 접근성 라벨 (필수)
35
79
 
36
- ## Deploy on Vercel
80
+ ### Button
81
+
82
+ 레거시 버튼 컴포넌트 (하위 호환성)
83
+
84
+ ### Header
85
+
86
+ 헤더 컴포넌트
87
+
88
+ ### Page
89
+
90
+ 페이지 컴포넌트
91
+
92
+ ## TypeScript 지원
93
+
94
+ 모든 컴포넌트는 완전한 TypeScript 타입 정의를 제공합니다.
95
+
96
+ ## 개발
97
+
98
+ ```bash
99
+ # Storybook 실행
100
+ npm run storybook
101
+
102
+ # 패키지 빌드
103
+ npm run build
104
+ ```
37
105
 
38
- The easiest way to deploy your Next.js app is to use the [Vercel Platform](https://vercel.com/new?utm_medium=default-template&filter=next.js&utm_source=create-next-app&utm_campaign=create-next-app-readme) from the creators of Next.js.
106
+ ## 라이선스
39
107
 
40
- Check out our [Next.js deployment documentation](https://nextjs.org/docs/pages/building-your-application/deploying) for more details.
108
+ MIT
package/package.json CHANGED
@@ -1,10 +1,26 @@
1
1
  {
2
2
  "name": "@likelion-design/ui",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "private": false,
5
5
  "main": "dist/index.cjs",
6
6
  "module": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
8
+ "exports": {
9
+ ".": {
10
+ "import": {
11
+ "types": "./dist/index.d.mts",
12
+ "default": "./dist/index.mjs"
13
+ },
14
+ "require": {
15
+ "types": "./dist/index.d.ts",
16
+ "default": "./dist/index.js"
17
+ }
18
+ },
19
+ "./styles.css": "./dist/index.css"
20
+ },
21
+ "sideEffects": [
22
+ "**/*.css"
23
+ ],
8
24
  "files": [
9
25
  "dist",
10
26
  "README.md"