@pisodev/test-component-library 1.1.2 → 2.0.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.
- package/components/Anchor/Anchor.native.tsx +44 -0
- package/components/Anchor/Anchor.types.ts +11 -0
- package/components/Anchor/Anchor.web.module.scss +33 -0
- package/components/Anchor/Anchor.web.tsx +35 -0
- package/components/Anchor/README.md +58 -0
- package/components/Anchor/index.ts +2 -0
- package/components/README.md +195 -0
- package/components/StatusBar/README.md +56 -0
- package/components/StatusBar/StatusBar.tsx +17 -0
- package/components/StatusBar/StatusBar.types.ts +5 -0
- package/components/StatusBar/index.ts +3 -0
- package/components/StatusBar/index.web.ts +14 -0
- package/components/Tooltip/README.md +45 -0
- package/components/Tooltip/Tooltip.module.scss +44 -0
- package/components/Tooltip/Tooltip.tsx +26 -0
- package/components/Tooltip/Tooltip.types.ts +7 -0
- package/components/Tooltip/index.native.ts +15 -0
- package/components/Tooltip/index.ts +3 -0
- package/components/index.ts +8 -0
- package/dist/Anchor/Anchor.native.d.ts +3 -0
- package/dist/Anchor/Anchor.native.js +34 -0
- package/dist/Anchor/Anchor.types.d.ts +10 -0
- package/dist/Anchor/Anchor.types.js +2 -0
- package/dist/Anchor/Anchor.web.d.ts +3 -0
- package/dist/Anchor/index.d.ts +2 -0
- package/dist/StatusBar/StatusBar.d.ts +3 -0
- package/dist/StatusBar/StatusBar.types.d.ts +5 -0
- package/dist/StatusBar/StatusBar.types.js +2 -0
- package/dist/StatusBar/index.d.ts +2 -0
- package/dist/StatusBar/index.web.d.ts +3 -0
- package/dist/Tooltip/Tooltip.d.ts +3 -0
- package/dist/Tooltip/Tooltip.types.d.ts +6 -0
- package/dist/Tooltip/Tooltip.types.js +2 -0
- package/dist/Tooltip/index.d.ts +2 -0
- package/dist/Tooltip/index.native.d.ts +4 -0
- package/dist/Tooltip/index.native.js +12 -0
- package/dist/index.d.ts +3 -2
- package/dist/index.esm.js +23 -143
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +23 -146
- package/dist/index.js.map +1 -1
- package/package.json +22 -9
- package/README.md +0 -67
- package/dist/components/Anchor/Anchor.d.ts +0 -11
- package/dist/components/Anchor/index.d.ts +0 -2
- package/dist/components/Button/Button.d.ts +0 -11
- package/dist/components/Button/index.d.ts +0 -2
- package/dist/components/Card/Card.d.ts +0 -11
- package/dist/components/Card/index.d.ts +0 -2
- package/dist/components/index.d.ts +0 -6
- package/dist/theme/ThemeProvider.d.ts +0 -12
- package/dist/theme/defaultTheme.d.ts +0 -2
- package/dist/theme/index.d.ts +0 -3
- package/dist/theme/types.d.ts +0 -23
package/package.json
CHANGED
|
@@ -1,31 +1,42 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pisodev/test-component-library",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "
|
|
5
|
-
"type": "module",
|
|
3
|
+
"version": "2.0.1",
|
|
4
|
+
"description": "웹과 React Native를 위한 컴포넌트 라이브러리",
|
|
6
5
|
"main": "dist/index.js",
|
|
7
6
|
"module": "dist/index.esm.js",
|
|
8
7
|
"types": "dist/index.d.ts",
|
|
8
|
+
"react-native": "components/index.ts",
|
|
9
9
|
"files": [
|
|
10
|
-
"dist"
|
|
10
|
+
"dist",
|
|
11
|
+
"components"
|
|
11
12
|
],
|
|
12
13
|
"scripts": {
|
|
13
|
-
"build": "
|
|
14
|
+
"build": "npm run build:web",
|
|
15
|
+
"build:web": "rollup -c rollup.config.web.js",
|
|
16
|
+
"build:native": "tsc -p tsconfig.native.json",
|
|
14
17
|
"prepublishOnly": "npm run build"
|
|
15
18
|
},
|
|
16
19
|
"keywords": [
|
|
17
20
|
"react",
|
|
21
|
+
"react-native",
|
|
18
22
|
"components",
|
|
19
|
-
"sass",
|
|
20
23
|
"ui",
|
|
21
24
|
"component-library",
|
|
22
|
-
"typescript"
|
|
25
|
+
"typescript",
|
|
26
|
+
"cross-platform"
|
|
23
27
|
],
|
|
24
28
|
"author": "",
|
|
25
29
|
"license": "MIT",
|
|
26
30
|
"peerDependencies": {
|
|
27
|
-
"react": "^17.0.0 || ^18.0.0 || ^19.0.0"
|
|
28
|
-
|
|
31
|
+
"react": "^17.0.0 || ^18.0.0 || ^19.0.0"
|
|
32
|
+
},
|
|
33
|
+
"peerDependenciesMeta": {
|
|
34
|
+
"react-dom": {
|
|
35
|
+
"optional": true
|
|
36
|
+
},
|
|
37
|
+
"react-native": {
|
|
38
|
+
"optional": true
|
|
39
|
+
}
|
|
29
40
|
},
|
|
30
41
|
"devDependencies": {
|
|
31
42
|
"@rollup/plugin-commonjs": "^29.0.0",
|
|
@@ -33,8 +44,10 @@
|
|
|
33
44
|
"@rollup/plugin-typescript": "^12.3.0",
|
|
34
45
|
"@types/react": "^19.2.7",
|
|
35
46
|
"@types/react-dom": "^19.2.3",
|
|
47
|
+
"@types/react-native": "^0.73.0",
|
|
36
48
|
"react": "^19.2.3",
|
|
37
49
|
"react-dom": "^19.2.3",
|
|
50
|
+
"react-native": "^0.76.6",
|
|
38
51
|
"rollup": "^4.54.0",
|
|
39
52
|
"rollup-plugin-peer-deps-external": "^2.2.4",
|
|
40
53
|
"rollup-plugin-postcss": "^4.0.2",
|
package/README.md
DELETED
|
@@ -1,67 +0,0 @@
|
|
|
1
|
-
# @pisodev/test-component-library
|
|
2
|
-
|
|
3
|
-
SASS 기반 React 컴포넌트 라이브러리입니다.
|
|
4
|
-
|
|
5
|
-
## 설치
|
|
6
|
-
|
|
7
|
-
```bash
|
|
8
|
-
npm install @pisodev/test-component-library
|
|
9
|
-
```
|
|
10
|
-
|
|
11
|
-
## 사용법
|
|
12
|
-
|
|
13
|
-
### 기본 사용
|
|
14
|
-
|
|
15
|
-
```tsx
|
|
16
|
-
import { Anchor, ThemeProvider } from '@pisodev/test-component-library';
|
|
17
|
-
|
|
18
|
-
function App() {
|
|
19
|
-
return (
|
|
20
|
-
<ThemeProvider>
|
|
21
|
-
<Anchor
|
|
22
|
-
href="https://example.com"
|
|
23
|
-
rel="noopener noreferrer"
|
|
24
|
-
title="예시 사이트로 이동"
|
|
25
|
-
target="_blank"
|
|
26
|
-
>
|
|
27
|
-
외부 링크
|
|
28
|
-
</Anchor>
|
|
29
|
-
</ThemeProvider>
|
|
30
|
-
);
|
|
31
|
-
}
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
## 컴포넌트
|
|
35
|
-
|
|
36
|
-
### Anchor
|
|
37
|
-
|
|
38
|
-
`rel`과 `title` 속성이 **필수**인 링크 컴포넌트입니다.
|
|
39
|
-
|
|
40
|
-
```tsx
|
|
41
|
-
<Anchor
|
|
42
|
-
href="https://example.com"
|
|
43
|
-
rel="noopener noreferrer"
|
|
44
|
-
title="예시 사이트로 이동"
|
|
45
|
-
target="_blank"
|
|
46
|
-
>
|
|
47
|
-
외부 링크
|
|
48
|
-
</Anchor>
|
|
49
|
-
|
|
50
|
-
<Anchor
|
|
51
|
-
href="/about"
|
|
52
|
-
rel="internal"
|
|
53
|
-
title="회사 소개 페이지"
|
|
54
|
-
>
|
|
55
|
-
회사 소개
|
|
56
|
-
</Anchor>
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
**Props (필수 항목)**
|
|
60
|
-
- `href`: `string` (필수)
|
|
61
|
-
- `rel`: `string` (필수) - 링크 관계 (예: `"noopener noreferrer"`, `"internal"`)
|
|
62
|
-
- `title`: `string` (필수) - 링크 설명
|
|
63
|
-
- `target`: `'_blank'` | `'_self'` | `'_parent'` | `'_top'` (기본값: `'_self'`)
|
|
64
|
-
|
|
65
|
-
## 배포
|
|
66
|
-
|
|
67
|
-
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface AnchorProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
href: string;
|
|
5
|
-
rel: string;
|
|
6
|
-
title: string;
|
|
7
|
-
target?: '_blank' | '_self' | '_parent' | '_top';
|
|
8
|
-
className?: string;
|
|
9
|
-
onClick?: (e: React.MouseEvent<HTMLAnchorElement>) => void;
|
|
10
|
-
}
|
|
11
|
-
export declare const Anchor: React.FC<AnchorProps>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface ButtonProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
variant?: 'primary' | 'secondary' | 'outline';
|
|
5
|
-
size?: 'small' | 'medium' | 'large';
|
|
6
|
-
onClick?: () => void;
|
|
7
|
-
disabled?: boolean;
|
|
8
|
-
type?: 'button' | 'submit' | 'reset';
|
|
9
|
-
className?: string;
|
|
10
|
-
}
|
|
11
|
-
export declare const Button: React.FC<ButtonProps>;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
export interface CardProps {
|
|
3
|
-
children: React.ReactNode;
|
|
4
|
-
title?: string;
|
|
5
|
-
subtitle?: string;
|
|
6
|
-
footer?: React.ReactNode;
|
|
7
|
-
variant?: 'default' | 'elevated' | 'outlined';
|
|
8
|
-
className?: string;
|
|
9
|
-
onClick?: () => void;
|
|
10
|
-
}
|
|
11
|
-
export declare const Card: React.FC<CardProps>;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Theme, ThemeColors } from './types';
|
|
3
|
-
interface ThemeContextValue {
|
|
4
|
-
theme: Theme;
|
|
5
|
-
}
|
|
6
|
-
interface ThemeProviderProps {
|
|
7
|
-
children: React.ReactNode;
|
|
8
|
-
colors?: ThemeColors;
|
|
9
|
-
}
|
|
10
|
-
export declare const ThemeProvider: React.FC<ThemeProviderProps>;
|
|
11
|
-
export declare const useTheme: () => ThemeContextValue;
|
|
12
|
-
export {};
|
package/dist/theme/index.d.ts
DELETED
package/dist/theme/types.d.ts
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
export interface ColorScale {
|
|
2
|
-
50: string;
|
|
3
|
-
100: string;
|
|
4
|
-
200: string;
|
|
5
|
-
300: string;
|
|
6
|
-
400: string;
|
|
7
|
-
500: string;
|
|
8
|
-
600: string;
|
|
9
|
-
700: string;
|
|
10
|
-
800: string;
|
|
11
|
-
900: string;
|
|
12
|
-
}
|
|
13
|
-
export interface ThemeColors {
|
|
14
|
-
primary?: Partial<ColorScale>;
|
|
15
|
-
secondary?: Partial<ColorScale>;
|
|
16
|
-
success?: Partial<ColorScale>;
|
|
17
|
-
warning?: Partial<ColorScale>;
|
|
18
|
-
danger?: Partial<ColorScale>;
|
|
19
|
-
[key: string]: Partial<ColorScale> | undefined;
|
|
20
|
-
}
|
|
21
|
-
export interface Theme {
|
|
22
|
-
colors: ThemeColors;
|
|
23
|
-
}
|