@likelion-design/ui 0.1.6 → 0.1.8
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/README.md +26 -20
- package/dist/Button.d.mts +63 -0
- package/dist/Button.d.ts +63 -0
- package/dist/Button.js +2 -0
- package/dist/Button.js.map +1 -0
- package/dist/Button.mjs +2 -0
- package/dist/Button.mjs.map +1 -0
- package/dist/Header.d.mts +14 -0
- package/dist/Header.d.ts +14 -0
- package/dist/Header.js +2 -0
- package/dist/Header.js.map +1 -0
- package/dist/Header.mjs +2 -0
- package/dist/Header.mjs.map +1 -0
- package/dist/Page.d.mts +5 -0
- package/dist/Page.d.ts +5 -0
- package/dist/Page.js +2 -0
- package/dist/Page.js.map +1 -0
- package/dist/Page.mjs +2 -0
- package/dist/Page.mjs.map +1 -0
- package/dist/chunk-HI5DDIGM.mjs +2 -0
- package/dist/chunk-HI5DDIGM.mjs.map +1 -0
- package/dist/chunk-LRXJPSTV.mjs +2 -0
- package/dist/chunk-LRXJPSTV.mjs.map +1 -0
- package/dist/chunk-RYQQG4LH.mjs +2 -0
- package/dist/chunk-RYQQG4LH.mjs.map +1 -0
- package/dist/chunk-SV46H7N2.mjs +2 -0
- package/dist/chunk-SV46H7N2.mjs.map +1 -0
- package/dist/index.css +1 -698
- package/dist/index.css.map +1 -1
- package/dist/index.d.mts +5 -76
- package/dist/index.d.ts +5 -76
- package/dist/index.js +1 -393
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1 -355
- package/dist/index.mjs.map +1 -1
- package/dist/tailwind-preset.d.mts +5 -0
- package/dist/tailwind-preset.d.ts +5 -0
- package/dist/tailwind-preset.js +2 -0
- package/dist/tailwind-preset.js.map +1 -0
- package/dist/tailwind-preset.mjs +2 -0
- package/dist/tailwind-preset.mjs.map +1 -0
- package/package.json +22 -11
package/README.md
CHANGED
|
@@ -23,31 +23,37 @@ import "@likelion-design/ui/styles.css";
|
|
|
23
23
|
|
|
24
24
|
### 2. 컴포넌트 사용
|
|
25
25
|
|
|
26
|
+
#### 전체 가져오기
|
|
27
|
+
|
|
26
28
|
```tsx
|
|
27
29
|
import { ActionButton, IconButton } from "@likelion-design/ui";
|
|
30
|
+
import "@likelion-design/ui/styles.css";
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
#### 개별 컴포넌트 가져오기 (Tree-shaking 최적화)
|
|
34
|
+
|
|
35
|
+
특정 컴포넌트와 그에 필요한 스타일만 선택적으로 불러올 수 있습니다:
|
|
36
|
+
|
|
37
|
+
```tsx
|
|
38
|
+
import { ActionButton } from "@likelion-design/ui/Button";
|
|
39
|
+
import "@likelion-design/ui/dist/Button.css";
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
### 3. Tailwind CSS 통합 (선택 사항)
|
|
28
43
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
</ActionButton>
|
|
39
|
-
|
|
40
|
-
<IconButton
|
|
41
|
-
size="large"
|
|
42
|
-
variant="primary"
|
|
43
|
-
icon={<YourIcon />}
|
|
44
|
-
aria-label="좋아요"
|
|
45
|
-
/>
|
|
46
|
-
</div>
|
|
47
|
-
);
|
|
48
|
-
}
|
|
44
|
+
라이브러리의 디자인 토큰(색상 등)을 프로젝트의 Tailwind 설정에 통합하여 사용할 수 있습니다.
|
|
45
|
+
|
|
46
|
+
`tailwind.config.js`:
|
|
47
|
+
|
|
48
|
+
```javascript
|
|
49
|
+
module.exports = {
|
|
50
|
+
presets: [require("@likelion-design/ui/tailwind-preset")],
|
|
51
|
+
// ...
|
|
52
|
+
};
|
|
49
53
|
```
|
|
50
54
|
|
|
55
|
+
이제 `text-semantic-fg-primary` 또는 `bg-primary-500`과 같은 클래스를 프로젝트 어디에서나 사용할 수 있습니다.
|
|
56
|
+
|
|
51
57
|
## 컴포넌트
|
|
52
58
|
|
|
53
59
|
### ActionButton
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
|
|
4
|
+
type ButtonSize = "xlarge" | "large" | "medium" | "small";
|
|
5
|
+
type ButtonVariant = "primary" | "neutral" | "secondary";
|
|
6
|
+
type ButtonShape = "solid" | "outline" | "ghost";
|
|
7
|
+
type ButtonState = "enabled" | "hovered" | "loading" | "disabled";
|
|
8
|
+
type IconButtonSize = "xlarge" | "large" | "medium" | "small";
|
|
9
|
+
type IconButtonVariant = "primary" | "neutral";
|
|
10
|
+
type IconButtonType = "solid" | "outline" | "weak";
|
|
11
|
+
type IconButtonState = "enabled" | "hovered" | "disabled";
|
|
12
|
+
interface ActionButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "type"> {
|
|
13
|
+
/** 버튼 크기 */
|
|
14
|
+
size?: ButtonSize;
|
|
15
|
+
/** 버튼 타입 (primary, neutral, secondary) */
|
|
16
|
+
variant?: ButtonVariant;
|
|
17
|
+
/** 버튼 모양 (solid, outline, ghost) */
|
|
18
|
+
shape?: ButtonShape;
|
|
19
|
+
/** 버튼 상태 */
|
|
20
|
+
state?: ButtonState;
|
|
21
|
+
/** 버튼 텍스트 */
|
|
22
|
+
children: React.ReactNode;
|
|
23
|
+
/** Prefix 아이콘 */
|
|
24
|
+
prefixIcon?: React.ReactNode;
|
|
25
|
+
/** Suffix 아이콘 */
|
|
26
|
+
suffixIcon?: React.ReactNode;
|
|
27
|
+
/** 로딩 상태일 때 표시할 스피너 */
|
|
28
|
+
loading?: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */
|
|
31
|
+
declare const ActionButton: ({ size, variant, shape, state, children, prefixIcon, suffixIcon, loading, className, disabled, ...props }: ActionButtonProps) => react_jsx_runtime.JSX.Element;
|
|
32
|
+
interface ButtonProps {
|
|
33
|
+
/** Is this the principal call to action on the page? */
|
|
34
|
+
primary?: boolean;
|
|
35
|
+
/** What background color to use */
|
|
36
|
+
backgroundColor?: string;
|
|
37
|
+
/** How large should the button be? */
|
|
38
|
+
size?: "small" | "medium" | "large";
|
|
39
|
+
/** Button contents */
|
|
40
|
+
label: string;
|
|
41
|
+
/** Optional click handler */
|
|
42
|
+
onClick?: () => void;
|
|
43
|
+
}
|
|
44
|
+
/** Primary UI component for user interaction */
|
|
45
|
+
declare const Button: ({ primary, size, backgroundColor, label, ...props }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
46
|
+
interface IconButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
47
|
+
/** 버튼 크기 */
|
|
48
|
+
size?: IconButtonSize;
|
|
49
|
+
/** 버튼 타입 (primary 또는 neutral) */
|
|
50
|
+
variant?: IconButtonVariant;
|
|
51
|
+
/** 버튼 모양 (solid, outline, weak) */
|
|
52
|
+
iconType?: IconButtonType;
|
|
53
|
+
/** 버튼 상태 */
|
|
54
|
+
state?: IconButtonState;
|
|
55
|
+
/** 아이콘 (Heroicons 또는 React 컴포넌트) */
|
|
56
|
+
icon: React.ReactNode;
|
|
57
|
+
/** 아이콘에 대한 접근성 라벨 */
|
|
58
|
+
"aria-label": string;
|
|
59
|
+
}
|
|
60
|
+
/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */
|
|
61
|
+
declare const IconButton: ({ size, variant, iconType, state, icon, className, disabled, type, ...props }: IconButtonProps) => react_jsx_runtime.JSX.Element;
|
|
62
|
+
|
|
63
|
+
export { ActionButton, type ActionButtonProps, Button, type ButtonProps, type ButtonShape, type ButtonSize, type ButtonState, type ButtonVariant, IconButton, type IconButtonProps, type IconButtonSize, type IconButtonState, type IconButtonType, type IconButtonVariant };
|
package/dist/Button.d.ts
ADDED
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import React from 'react';
|
|
3
|
+
|
|
4
|
+
type ButtonSize = "xlarge" | "large" | "medium" | "small";
|
|
5
|
+
type ButtonVariant = "primary" | "neutral" | "secondary";
|
|
6
|
+
type ButtonShape = "solid" | "outline" | "ghost";
|
|
7
|
+
type ButtonState = "enabled" | "hovered" | "loading" | "disabled";
|
|
8
|
+
type IconButtonSize = "xlarge" | "large" | "medium" | "small";
|
|
9
|
+
type IconButtonVariant = "primary" | "neutral";
|
|
10
|
+
type IconButtonType = "solid" | "outline" | "weak";
|
|
11
|
+
type IconButtonState = "enabled" | "hovered" | "disabled";
|
|
12
|
+
interface ActionButtonProps extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, "type"> {
|
|
13
|
+
/** 버튼 크기 */
|
|
14
|
+
size?: ButtonSize;
|
|
15
|
+
/** 버튼 타입 (primary, neutral, secondary) */
|
|
16
|
+
variant?: ButtonVariant;
|
|
17
|
+
/** 버튼 모양 (solid, outline, ghost) */
|
|
18
|
+
shape?: ButtonShape;
|
|
19
|
+
/** 버튼 상태 */
|
|
20
|
+
state?: ButtonState;
|
|
21
|
+
/** 버튼 텍스트 */
|
|
22
|
+
children: React.ReactNode;
|
|
23
|
+
/** Prefix 아이콘 */
|
|
24
|
+
prefixIcon?: React.ReactNode;
|
|
25
|
+
/** Suffix 아이콘 */
|
|
26
|
+
suffixIcon?: React.ReactNode;
|
|
27
|
+
/** 로딩 상태일 때 표시할 스피너 */
|
|
28
|
+
loading?: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */
|
|
31
|
+
declare const ActionButton: ({ size, variant, shape, state, children, prefixIcon, suffixIcon, loading, className, disabled, ...props }: ActionButtonProps) => react_jsx_runtime.JSX.Element;
|
|
32
|
+
interface ButtonProps {
|
|
33
|
+
/** Is this the principal call to action on the page? */
|
|
34
|
+
primary?: boolean;
|
|
35
|
+
/** What background color to use */
|
|
36
|
+
backgroundColor?: string;
|
|
37
|
+
/** How large should the button be? */
|
|
38
|
+
size?: "small" | "medium" | "large";
|
|
39
|
+
/** Button contents */
|
|
40
|
+
label: string;
|
|
41
|
+
/** Optional click handler */
|
|
42
|
+
onClick?: () => void;
|
|
43
|
+
}
|
|
44
|
+
/** Primary UI component for user interaction */
|
|
45
|
+
declare const Button: ({ primary, size, backgroundColor, label, ...props }: ButtonProps) => react_jsx_runtime.JSX.Element;
|
|
46
|
+
interface IconButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> {
|
|
47
|
+
/** 버튼 크기 */
|
|
48
|
+
size?: IconButtonSize;
|
|
49
|
+
/** 버튼 타입 (primary 또는 neutral) */
|
|
50
|
+
variant?: IconButtonVariant;
|
|
51
|
+
/** 버튼 모양 (solid, outline, weak) */
|
|
52
|
+
iconType?: IconButtonType;
|
|
53
|
+
/** 버튼 상태 */
|
|
54
|
+
state?: IconButtonState;
|
|
55
|
+
/** 아이콘 (Heroicons 또는 React 컴포넌트) */
|
|
56
|
+
icon: React.ReactNode;
|
|
57
|
+
/** 아이콘에 대한 접근성 라벨 */
|
|
58
|
+
"aria-label": string;
|
|
59
|
+
}
|
|
60
|
+
/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */
|
|
61
|
+
declare const IconButton: ({ size, variant, iconType, state, icon, className, disabled, type, ...props }: IconButtonProps) => react_jsx_runtime.JSX.Element;
|
|
62
|
+
|
|
63
|
+
export { ActionButton, type ActionButtonProps, Button, type ButtonProps, type ButtonShape, type ButtonSize, type ButtonState, type ButtonVariant, IconButton, type IconButtonProps, type IconButtonSize, type IconButtonState, type IconButtonType, type IconButtonVariant };
|
package/dist/Button.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var b=Object.defineProperty,S=Object.defineProperties,I=Object.getOwnPropertyDescriptor,R=Object.getOwnPropertyDescriptors,$=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols;var g=Object.prototype.hasOwnProperty,k=Object.prototype.propertyIsEnumerable;var _=(t,o,e)=>o in t?b(t,o,{enumerable:!0,configurable:!0,writable:!0,value:e}):t[o]=e,d=(t,o)=>{for(var e in o||(o={}))g.call(o,e)&&_(t,e,o[e]);if(p)for(var e of p(o))k.call(o,e)&&_(t,e,o[e]);return t},m=(t,o)=>S(t,R(o));var B=(t,o)=>{var e={};for(var n in t)g.call(t,n)&&o.indexOf(n)<0&&(e[n]=t[n]);if(t!=null&&p)for(var n of p(t))o.indexOf(n)<0&&k.call(t,n)&&(e[n]=t[n]);return e};var w=(t,o)=>{for(var e in o)b(t,e,{get:o[e],enumerable:!0})},z=(t,o,e,n)=>{if(o&&typeof o=="object"||typeof o=="function")for(let s of $(o))!g.call(t,s)&&s!==e&&b(t,s,{get:()=>o[s],enumerable:!(n=I(o,s))||n.enumerable});return t};var C=t=>z(b({},"__esModule",{value:!0}),t);var L={};w(L,{ActionButton:()=>P,Button:()=>T,IconButton:()=>A});module.exports=C(L);var a=require("react/jsx-runtime"),P=x=>{var l=x,{size:t="medium",variant:o="primary",shape:e="solid",state:n="enabled",children:s,prefixIcon:c,suffixIcon:i,loading:r=!1,className:y="",disabled:N}=l,u=B(l,["size","variant","shape","state","children","prefixIcon","suffixIcon","loading","className","disabled"]);let f=N||n==="disabled"||r,h=r?"loading":n,v=["action-button",`action-button--${t}`,`action-button--${o}`,`action-button--${e}`,`action-button--${h}`,y].filter(Boolean).join(" ");return(0,a.jsxs)("button",m(d({type:"button",className:v,disabled:f},u),{children:[(0,a.jsxs)("span",{className:"action-button__content",children:[c&&(0,a.jsx)("span",{className:"action-button__prefix-icon",children:c}),(0,a.jsx)("span",{className:"action-button__label",children:s}),i&&(0,a.jsx)("span",{className:"action-button__suffix-icon",children:i})]}),r&&(0,a.jsx)("span",{className:"action-button__spinner","aria-hidden":"true",children:(0,a.jsx)("svg",{className:"action-button__spinner-svg",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsxs)("circle",{className:"action-button__spinner-circle",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4",strokeLinecap:"round",strokeDasharray:"32",strokeDashoffset:"32",children:[(0,a.jsx)("animate",{attributeName:"stroke-dasharray",dur:"2s",values:"0 40;40 40;0 40",repeatCount:"indefinite"}),(0,a.jsx)("animate",{attributeName:"stroke-dashoffset",dur:"2s",values:"0;-40;-80",repeatCount:"indefinite"})]})})})]}))},T=c=>{var i=c,{primary:t=!1,size:o="medium",backgroundColor:e,label:n}=i,s=B(i,["primary","size","backgroundColor","label"]);let r=t?"storybook-button--primary":"storybook-button--secondary";return(0,a.jsx)("button",m(d({type:"button",className:["storybook-button",`storybook-button--${o}`,r].join(" "),style:{backgroundColor:e}},s),{children:n}))},A=N=>{var u=N,{size:t="large",variant:o="primary",iconType:e="solid",state:n="enabled",icon:s,className:c="",disabled:i,type:r="button"}=u,y=B(u,["size","variant","iconType","state","icon","className","disabled","type"]);let x=i||n==="disabled",l=e==="weak"&&x?"enabled":n,f=["icon-button",`icon-button--${t}`,`icon-button--${o}`,`icon-button--${e}`,`icon-button--${l}`,c].filter(Boolean).join(" ");return(0,a.jsx)("button",m(d({type:r,className:f,disabled:x},y),{children:(0,a.jsx)("span",{className:"icon-button__icon",children:s})}))};0&&(module.exports={ActionButton,Button,IconButton});
|
|
2
|
+
//# sourceMappingURL=Button.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Button.tsx"],"sourcesContent":["import React from \"react\";\n\nexport type ButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type ButtonVariant = \"primary\" | \"neutral\" | \"secondary\";\nexport type ButtonShape = \"solid\" | \"outline\" | \"ghost\";\nexport type ButtonState = \"enabled\" | \"hovered\" | \"loading\" | \"disabled\";\n\nexport type IconButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type IconButtonVariant = \"primary\" | \"neutral\";\nexport type IconButtonType = \"solid\" | \"outline\" | \"weak\";\nexport type IconButtonState = \"enabled\" | \"hovered\" | \"disabled\";\n\nexport interface ActionButtonProps\n extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, \"type\"> {\n /** 버튼 크기 */\n size?: ButtonSize;\n /** 버튼 타입 (primary, neutral, secondary) */\n variant?: ButtonVariant;\n /** 버튼 모양 (solid, outline, ghost) */\n shape?: ButtonShape;\n /** 버튼 상태 */\n state?: ButtonState;\n /** 버튼 텍스트 */\n children: React.ReactNode;\n /** Prefix 아이콘 */\n prefixIcon?: React.ReactNode;\n /** Suffix 아이콘 */\n suffixIcon?: React.ReactNode;\n /** 로딩 상태일 때 표시할 스피너 */\n loading?: boolean;\n}\n\n/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */\nexport const ActionButton = ({\n size = \"medium\",\n variant = \"primary\",\n shape = \"solid\",\n state = \"enabled\",\n children,\n prefixIcon,\n suffixIcon,\n loading = false,\n className = \"\",\n disabled,\n ...props\n}: ActionButtonProps) => {\n const isDisabled = disabled || state === \"disabled\" || loading;\n const actualState = loading ? \"loading\" : state;\n\n const baseClasses = [\n \"action-button\",\n `action-button--${size}`,\n `action-button--${variant}`,\n `action-button--${shape}`,\n `action-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type=\"button\"\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"action-button__content\">\n {prefixIcon && (\n <span className=\"action-button__prefix-icon\">{prefixIcon}</span>\n )}\n <span className=\"action-button__label\">{children}</span>\n {suffixIcon && (\n <span className=\"action-button__suffix-icon\">{suffixIcon}</span>\n )}\n </span>\n {loading && (\n <span className=\"action-button__spinner\" aria-hidden=\"true\">\n <svg\n className=\"action-button__spinner-svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <circle\n className=\"action-button__spinner-circle\"\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n strokeLinecap=\"round\"\n strokeDasharray=\"32\"\n strokeDashoffset=\"32\"\n >\n <animate\n attributeName=\"stroke-dasharray\"\n dur=\"2s\"\n values=\"0 40;40 40;0 40\"\n repeatCount=\"indefinite\"\n />\n <animate\n attributeName=\"stroke-dashoffset\"\n dur=\"2s\"\n values=\"0;-40;-80\"\n repeatCount=\"indefinite\"\n />\n </circle>\n </svg>\n </span>\n )}\n </button>\n );\n};\n\n// 기존 Button 컴포넌트는 하위 호환성을 위해 유지\nexport interface ButtonProps {\n /** Is this the principal call to action on the page? */\n primary?: boolean;\n /** What background color to use */\n backgroundColor?: string;\n /** How large should the button be? */\n size?: \"small\" | \"medium\" | \"large\";\n /** Button contents */\n label: string;\n /** Optional click handler */\n onClick?: () => void;\n}\n\n/** Primary UI component for user interaction */\nexport const Button = ({\n primary = false,\n size = \"medium\",\n backgroundColor,\n label,\n ...props\n}: ButtonProps) => {\n const mode = primary\n ? \"storybook-button--primary\"\n : \"storybook-button--secondary\";\n return (\n <button\n type=\"button\"\n className={[\"storybook-button\", `storybook-button--${size}`, mode].join(\n \" \"\n )}\n style={{ backgroundColor }}\n {...props}\n >\n {label}\n </button>\n );\n};\n\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /** 버튼 크기 */\n size?: IconButtonSize;\n /** 버튼 타입 (primary 또는 neutral) */\n variant?: IconButtonVariant;\n /** 버튼 모양 (solid, outline, weak) */\n iconType?: IconButtonType;\n /** 버튼 상태 */\n state?: IconButtonState;\n /** 아이콘 (Heroicons 또는 React 컴포넌트) */\n icon: React.ReactNode;\n /** 아이콘에 대한 접근성 라벨 */\n \"aria-label\": string;\n}\n\n/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */\nexport const IconButton = ({\n size = \"large\",\n variant = \"primary\",\n iconType = \"solid\",\n state = \"enabled\",\n icon,\n className = \"\",\n disabled,\n type = \"button\",\n ...props\n}: IconButtonProps) => {\n const isDisabled = disabled || state === \"disabled\";\n // weak 타입은 disabled 상태를 가지지 않음\n const actualState = iconType === \"weak\" && isDisabled ? \"enabled\" : state;\n\n const baseClasses = [\n \"icon-button\",\n `icon-button--${size}`,\n `icon-button--${variant}`,\n `icon-button--${iconType}`,\n `icon-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type={type}\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"icon-button__icon\">{icon}</span>\n </button>\n );\n};\n"],"mappings":"s6BAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kBAAAE,EAAA,WAAAC,EAAA,eAAAC,IAAA,eAAAC,EAAAL,GAmEM,IAAAM,EAAA,6BAlCOC,EAAgBC,GAYJ,CAZI,IAAAC,EAAAD,EAC3B,MAAAE,EAAO,SACP,QAAAC,EAAU,UACV,MAAAC,EAAQ,QACR,MAAAC,EAAQ,UACR,SAAAC,EACA,WAAAC,EACA,WAAAC,EACA,QAAAC,EAAU,GACV,UAAAC,EAAY,GACZ,SAAAC,CA3CF,EAiC6BV,EAWxBW,EAAAC,EAXwBZ,EAWxB,CAVH,OACA,UACA,QACA,QACA,WACA,aACA,aACA,UACA,YACA,aAGA,IAAMa,EAAaH,GAAYN,IAAU,YAAcI,EACjDM,EAAcN,EAAU,UAAYJ,EAEpCW,EAAc,CAClB,gBACA,kBAAkBd,CAAI,GACtB,kBAAkBC,CAAO,GACzB,kBAAkBC,CAAK,GACvB,kBAAkBW,CAAW,GAC7BL,CACF,EACG,OAAO,OAAO,EACd,KAAK,GAAG,EAEX,SACE,QAAC,SAAAO,EAAAC,EAAA,CACC,KAAK,SACL,UAAWF,EACX,SAAUF,GACNF,GAJL,CAMC,qBAAC,QAAK,UAAU,yBACb,UAAAL,MACC,OAAC,QAAK,UAAU,6BAA8B,SAAAA,EAAW,KAE3D,OAAC,QAAK,UAAU,uBAAwB,SAAAD,EAAS,EAChDE,MACC,OAAC,QAAK,UAAU,6BAA8B,SAAAA,EAAW,GAE7D,EACCC,MACC,OAAC,QAAK,UAAU,yBAAyB,cAAY,OACnD,mBAAC,OACC,UAAU,6BACV,QAAQ,YACR,KAAK,OACL,MAAM,6BAEN,oBAAC,UACC,UAAU,gCACV,GAAG,KACH,GAAG,KACH,EAAE,KACF,OAAO,eACP,YAAY,IACZ,cAAc,QACd,gBAAgB,KAChB,iBAAiB,KAEjB,oBAAC,WACC,cAAc,mBACd,IAAI,KACJ,OAAO,kBACP,YAAY,aACd,KACA,OAAC,WACC,cAAc,oBACd,IAAI,KACJ,OAAO,YACP,YAAY,aACd,GACF,EACF,EACF,IAEJ,CAEJ,EAiBaU,EAAUnB,GAMJ,CANI,IAAAC,EAAAD,EACrB,SAAAoB,EAAU,GACV,KAAAlB,EAAO,SACP,gBAAAmB,EACA,MAAAC,CAtIF,EAkIuBrB,EAKlBW,EAAAC,EALkBZ,EAKlB,CAJH,UACA,OACA,kBACA,UAGA,IAAMsB,EAAOH,EACT,4BACA,8BACJ,SACE,OAAC,SAAAH,EAAAC,EAAA,CACC,KAAK,SACL,UAAW,CAAC,mBAAoB,qBAAqBhB,CAAI,GAAIqB,CAAI,EAAE,KACjE,GACF,EACA,MAAO,CAAE,gBAAAF,CAAgB,GACrBT,GANL,CAQE,SAAAU,GACH,CAEJ,EAmBaE,EAAcxB,GAUJ,CAVI,IAAAC,EAAAD,EACzB,MAAAE,EAAO,QACP,QAAAC,EAAU,UACV,SAAAsB,EAAW,QACX,MAAApB,EAAQ,UACR,KAAAqB,EACA,UAAAhB,EAAY,GACZ,SAAAC,EACA,KAAAgB,EAAO,QAnLT,EA2K2B1B,EAStBW,EAAAC,EATsBZ,EAStB,CARH,OACA,UACA,WACA,QACA,OACA,YACA,WACA,SAGA,IAAMa,EAAaH,GAAYN,IAAU,WAEnCU,EAAcU,IAAa,QAAUX,EAAa,UAAYT,EAE9DW,EAAc,CAClB,cACA,gBAAgBd,CAAI,GACpB,gBAAgBC,CAAO,GACvB,gBAAgBsB,CAAQ,GACxB,gBAAgBV,CAAW,GAC3BL,CACF,EACG,OAAO,OAAO,EACd,KAAK,GAAG,EAEX,SACE,OAAC,SAAAO,EAAAC,EAAA,CACC,KAAMS,EACN,UAAWX,EACX,SAAUF,GACNF,GAJL,CAMC,mBAAC,QAAK,UAAU,oBAAqB,SAAAc,EAAK,GAC5C,CAEJ","names":["Button_exports","__export","ActionButton","Button","IconButton","__toCommonJS","import_jsx_runtime","ActionButton","_a","_b","size","variant","shape","state","children","prefixIcon","suffixIcon","loading","className","disabled","props","__objRest","isDisabled","actualState","baseClasses","__spreadProps","__spreadValues","Button","primary","backgroundColor","label","mode","IconButton","iconType","icon","type"]}
|
package/dist/Button.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
|
|
3
|
+
type User = {
|
|
4
|
+
name: string;
|
|
5
|
+
};
|
|
6
|
+
interface HeaderProps {
|
|
7
|
+
user?: User;
|
|
8
|
+
onLogin?: () => void;
|
|
9
|
+
onLogout?: () => void;
|
|
10
|
+
onCreateAccount?: () => void;
|
|
11
|
+
}
|
|
12
|
+
declare const Header: ({ user, onLogin, onLogout, onCreateAccount, }: HeaderProps) => react_jsx_runtime.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { Header, type HeaderProps };
|
package/dist/Header.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
|
|
3
|
+
type User = {
|
|
4
|
+
name: string;
|
|
5
|
+
};
|
|
6
|
+
interface HeaderProps {
|
|
7
|
+
user?: User;
|
|
8
|
+
onLogin?: () => void;
|
|
9
|
+
onLogout?: () => void;
|
|
10
|
+
onCreateAccount?: () => void;
|
|
11
|
+
}
|
|
12
|
+
declare const Header: ({ user, onLogin, onLogout, onCreateAccount, }: HeaderProps) => react_jsx_runtime.JSX.Element;
|
|
13
|
+
|
|
14
|
+
export { Header, type HeaderProps };
|
package/dist/Header.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var r=Object.defineProperty,g=Object.defineProperties,h=Object.getOwnPropertyDescriptor,f=Object.getOwnPropertyDescriptors,x=Object.getOwnPropertyNames,i=Object.getOwnPropertySymbols;var c=Object.prototype.hasOwnProperty,b=Object.prototype.propertyIsEnumerable;var d=(t,e,o)=>e in t?r(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o,m=(t,e)=>{for(var o in e||(e={}))c.call(e,o)&&d(t,o,e[o]);if(i)for(var o of i(e))b.call(e,o)&&d(t,o,e[o]);return t},B=(t,e)=>g(t,f(e));var y=(t,e)=>{var o={};for(var a in t)c.call(t,a)&&e.indexOf(a)<0&&(o[a]=t[a]);if(t!=null&&i)for(var a of i(t))e.indexOf(a)<0&&b.call(t,a)&&(o[a]=t[a]);return o};var k=(t,e)=>{for(var o in e)r(t,o,{get:e[o],enumerable:!0})},N=(t,e,o,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let s of x(e))!c.call(t,s)&&s!==o&&r(t,s,{get:()=>e[s],enumerable:!(a=h(e,s))||a.enumerable});return t};var _=t=>N(r({},"__esModule",{value:!0}),t);var w={};k(w,{Header:()=>z});module.exports=_(w);var u=require("react/jsx-runtime");var l=S=>{var p=S,{primary:t=!1,size:e="medium",backgroundColor:o,label:a}=p,s=y(p,["primary","size","backgroundColor","label"]);let v=t?"storybook-button--primary":"storybook-button--secondary";return(0,u.jsx)("button",B(m({type:"button",className:["storybook-button",`storybook-button--${e}`,v].join(" "),style:{backgroundColor:o}},s),{children:a}))};var n=require("react/jsx-runtime"),z=({user:t,onLogin:e,onLogout:o,onCreateAccount:a})=>(0,n.jsx)("header",{children:(0,n.jsxs)("div",{className:"storybook-header",children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("svg",{width:"32",height:"32",viewBox:"0 0 32 32",xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,n.jsx)("path",{d:"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z",fill:"#FFF"}),(0,n.jsx)("path",{d:"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z",fill:"#555AB9"}),(0,n.jsx)("path",{d:"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z",fill:"#91BAF8"})]})}),(0,n.jsx)("h1",{children:"Acme"})]}),(0,n.jsx)("div",{children:t?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("span",{className:"welcome",children:["Welcome, ",(0,n.jsx)("b",{children:t.name}),"!"]}),(0,n.jsx)(l,{size:"small",onClick:o,label:"Log out"})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(l,{size:"small",onClick:e,label:"Log in"}),(0,n.jsx)(l,{primary:!0,size:"small",onClick:a,label:"Sign up"})]})})]})});0&&(module.exports={Header});
|
|
2
|
+
//# sourceMappingURL=Header.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Header.tsx","../src/stories/Button.tsx"],"sourcesContent":["import { Button } from \"./Button\";\n\ntype User = {\n name: string;\n};\n\nexport interface HeaderProps {\n user?: User;\n onLogin?: () => void;\n onLogout?: () => void;\n onCreateAccount?: () => void;\n}\n\nexport const Header = ({\n user,\n onLogin,\n onLogout,\n onCreateAccount,\n}: HeaderProps) => (\n <header>\n <div className=\"storybook-header\">\n <div>\n <svg\n width=\"32\"\n height=\"32\"\n viewBox=\"0 0 32 32\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <g fill=\"none\" fillRule=\"evenodd\">\n <path\n d=\"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z\"\n fill=\"#FFF\"\n />\n <path\n d=\"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z\"\n fill=\"#555AB9\"\n />\n <path\n d=\"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z\"\n fill=\"#91BAF8\"\n />\n </g>\n </svg>\n <h1>Acme</h1>\n </div>\n <div>\n {user ? (\n <>\n <span className=\"welcome\">\n Welcome, <b>{user.name}</b>!\n </span>\n <Button size=\"small\" onClick={onLogout} label=\"Log out\" />\n </>\n ) : (\n <>\n <Button size=\"small\" onClick={onLogin} label=\"Log in\" />\n <Button\n primary\n size=\"small\"\n onClick={onCreateAccount}\n label=\"Sign up\"\n />\n </>\n )}\n </div>\n </div>\n </header>\n);\n","import React from \"react\";\n\nexport type ButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type ButtonVariant = \"primary\" | \"neutral\" | \"secondary\";\nexport type ButtonShape = \"solid\" | \"outline\" | \"ghost\";\nexport type ButtonState = \"enabled\" | \"hovered\" | \"loading\" | \"disabled\";\n\nexport type IconButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type IconButtonVariant = \"primary\" | \"neutral\";\nexport type IconButtonType = \"solid\" | \"outline\" | \"weak\";\nexport type IconButtonState = \"enabled\" | \"hovered\" | \"disabled\";\n\nexport interface ActionButtonProps\n extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, \"type\"> {\n /** 버튼 크기 */\n size?: ButtonSize;\n /** 버튼 타입 (primary, neutral, secondary) */\n variant?: ButtonVariant;\n /** 버튼 모양 (solid, outline, ghost) */\n shape?: ButtonShape;\n /** 버튼 상태 */\n state?: ButtonState;\n /** 버튼 텍스트 */\n children: React.ReactNode;\n /** Prefix 아이콘 */\n prefixIcon?: React.ReactNode;\n /** Suffix 아이콘 */\n suffixIcon?: React.ReactNode;\n /** 로딩 상태일 때 표시할 스피너 */\n loading?: boolean;\n}\n\n/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */\nexport const ActionButton = ({\n size = \"medium\",\n variant = \"primary\",\n shape = \"solid\",\n state = \"enabled\",\n children,\n prefixIcon,\n suffixIcon,\n loading = false,\n className = \"\",\n disabled,\n ...props\n}: ActionButtonProps) => {\n const isDisabled = disabled || state === \"disabled\" || loading;\n const actualState = loading ? \"loading\" : state;\n\n const baseClasses = [\n \"action-button\",\n `action-button--${size}`,\n `action-button--${variant}`,\n `action-button--${shape}`,\n `action-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type=\"button\"\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"action-button__content\">\n {prefixIcon && (\n <span className=\"action-button__prefix-icon\">{prefixIcon}</span>\n )}\n <span className=\"action-button__label\">{children}</span>\n {suffixIcon && (\n <span className=\"action-button__suffix-icon\">{suffixIcon}</span>\n )}\n </span>\n {loading && (\n <span className=\"action-button__spinner\" aria-hidden=\"true\">\n <svg\n className=\"action-button__spinner-svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <circle\n className=\"action-button__spinner-circle\"\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n strokeLinecap=\"round\"\n strokeDasharray=\"32\"\n strokeDashoffset=\"32\"\n >\n <animate\n attributeName=\"stroke-dasharray\"\n dur=\"2s\"\n values=\"0 40;40 40;0 40\"\n repeatCount=\"indefinite\"\n />\n <animate\n attributeName=\"stroke-dashoffset\"\n dur=\"2s\"\n values=\"0;-40;-80\"\n repeatCount=\"indefinite\"\n />\n </circle>\n </svg>\n </span>\n )}\n </button>\n );\n};\n\n// 기존 Button 컴포넌트는 하위 호환성을 위해 유지\nexport interface ButtonProps {\n /** Is this the principal call to action on the page? */\n primary?: boolean;\n /** What background color to use */\n backgroundColor?: string;\n /** How large should the button be? */\n size?: \"small\" | \"medium\" | \"large\";\n /** Button contents */\n label: string;\n /** Optional click handler */\n onClick?: () => void;\n}\n\n/** Primary UI component for user interaction */\nexport const Button = ({\n primary = false,\n size = \"medium\",\n backgroundColor,\n label,\n ...props\n}: ButtonProps) => {\n const mode = primary\n ? \"storybook-button--primary\"\n : \"storybook-button--secondary\";\n return (\n <button\n type=\"button\"\n className={[\"storybook-button\", `storybook-button--${size}`, mode].join(\n \" \"\n )}\n style={{ backgroundColor }}\n {...props}\n >\n {label}\n </button>\n );\n};\n\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /** 버튼 크기 */\n size?: IconButtonSize;\n /** 버튼 타입 (primary 또는 neutral) */\n variant?: IconButtonVariant;\n /** 버튼 모양 (solid, outline, weak) */\n iconType?: IconButtonType;\n /** 버튼 상태 */\n state?: IconButtonState;\n /** 아이콘 (Heroicons 또는 React 컴포넌트) */\n icon: React.ReactNode;\n /** 아이콘에 대한 접근성 라벨 */\n \"aria-label\": string;\n}\n\n/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */\nexport const IconButton = ({\n size = \"large\",\n variant = \"primary\",\n iconType = \"solid\",\n state = \"enabled\",\n icon,\n className = \"\",\n disabled,\n type = \"button\",\n ...props\n}: IconButtonProps) => {\n const isDisabled = disabled || state === \"disabled\";\n // weak 타입은 disabled 상태를 가지지 않음\n const actualState = iconType === \"weak\" && isDisabled ? \"enabled\" : state;\n\n const baseClasses = [\n \"icon-button\",\n `icon-button--${size}`,\n `icon-button--${variant}`,\n `icon-button--${iconType}`,\n `icon-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type={type}\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"icon-button__icon\">{icon}</span>\n </button>\n );\n};\n"],"mappings":"s6BAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,YAAAE,IAAA,eAAAC,EAAAH,GCmEM,IAAAI,EAAA,6BA+DC,IAAMC,EAAUC,GAMJ,CANI,IAAAC,EAAAD,EACrB,SAAAE,EAAU,GACV,KAAAC,EAAO,SACP,gBAAAC,EACA,MAAAC,CAtIF,EAkIuBJ,EAKlBK,EAAAC,EALkBN,EAKlB,CAJH,UACA,OACA,kBACA,UAGA,IAAMO,EAAON,EACT,4BACA,8BACJ,SACE,OAAC,SAAAO,EAAAC,EAAA,CACC,KAAK,SACL,UAAW,CAAC,mBAAoB,qBAAqBP,CAAI,GAAIK,CAAI,EAAE,KACjE,GACF,EACA,MAAO,CAAE,gBAAAJ,CAAgB,GACrBE,GANL,CAQE,SAAAD,GACH,CAEJ,ED5HU,IAAAM,EAAA,6BAfGC,EAAS,CAAC,CACrB,KAAAC,EACA,QAAAC,EACA,SAAAC,EACA,gBAAAC,CACF,OACE,OAAC,UACC,oBAAC,OAAI,UAAU,mBACb,qBAAC,OACC,oBAAC,OACC,MAAM,KACN,OAAO,KACP,QAAQ,YACR,MAAM,6BAEN,oBAAC,KAAE,KAAK,OAAO,SAAS,UACtB,oBAAC,QACC,EAAE,oFACF,KAAK,OACP,KACA,OAAC,QACC,EAAE,mEACF,KAAK,UACP,KACA,OAAC,QACC,EAAE,iEACF,KAAK,UACP,GACF,EACF,KACA,OAAC,MAAG,gBAAI,GACV,KACA,OAAC,OACE,SAAAH,KACC,oBACE,qBAAC,QAAK,UAAU,UAAU,yBACf,OAAC,KAAG,SAAAA,EAAK,KAAK,EAAI,KAC7B,KACA,OAACI,EAAA,CAAO,KAAK,QAAQ,QAASF,EAAU,MAAM,UAAU,GAC1D,KAEA,oBACE,oBAACE,EAAA,CAAO,KAAK,QAAQ,QAASH,EAAS,MAAM,SAAS,KACtD,OAACG,EAAA,CACC,QAAO,GACP,KAAK,QACL,QAASD,EACT,MAAM,UACR,GACF,EAEJ,GACF,EACF","names":["Header_exports","__export","Header","__toCommonJS","import_jsx_runtime","Button","_a","_b","primary","size","backgroundColor","label","props","__objRest","mode","__spreadProps","__spreadValues","import_jsx_runtime","Header","user","onLogin","onLogout","onCreateAccount","Button"]}
|
package/dist/Header.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
package/dist/Page.d.mts
ADDED
package/dist/Page.d.ts
ADDED
package/dist/Page.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";var w=Object.create;var i=Object.defineProperty,x=Object.defineProperties,N=Object.getOwnPropertyDescriptor,z=Object.getOwnPropertyDescriptors,S=Object.getOwnPropertyNames,l=Object.getOwnPropertySymbols,_=Object.getPrototypeOf,p=Object.prototype.hasOwnProperty,b=Object.prototype.propertyIsEnumerable;var m=(t,e,o)=>e in t?i(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o,g=(t,e)=>{for(var o in e||(e={}))p.call(e,o)&&m(t,o,e[o]);if(l)for(var o of l(e))b.call(e,o)&&m(t,o,e[o]);return t},h=(t,e)=>x(t,z(e));var v=(t,e)=>{var o={};for(var s in t)p.call(t,s)&&e.indexOf(s)<0&&(o[s]=t[s]);if(t!=null&&l)for(var s of l(t))e.indexOf(s)<0&&b.call(t,s)&&(o[s]=t[s]);return o};var R=(t,e)=>{for(var o in e)i(t,o,{get:e[o],enumerable:!0})},y=(t,e,o,s)=>{if(e&&typeof e=="object"||typeof e=="function")for(let r of S(e))!p.call(t,r)&&r!==o&&i(t,r,{get:()=>e[r],enumerable:!(s=N(e,r))||s.enumerable});return t};var A=(t,e,o)=>(o=t!=null?w(_(t)):{},y(e||!t||!t.__esModule?i(o,"default",{value:t,enumerable:!0}):o,t)),H=t=>y(i({},"__esModule",{value:!0}),t);var V={};R(V,{Page:()=>C});module.exports=H(V);var B=A(require("react"));var u=require("react/jsx-runtime");var c=I=>{var d=I,{primary:t=!1,size:e="medium",backgroundColor:o,label:s}=d,r=v(d,["primary","size","backgroundColor","label"]);let k=t?"storybook-button--primary":"storybook-button--secondary";return(0,u.jsx)("button",h(g({type:"button",className:["storybook-button",`storybook-button--${e}`,k].join(" "),style:{backgroundColor:o}},r),{children:s}))};var n=require("react/jsx-runtime"),f=({user:t,onLogin:e,onLogout:o,onCreateAccount:s})=>(0,n.jsx)("header",{children:(0,n.jsxs)("div",{className:"storybook-header",children:[(0,n.jsxs)("div",{children:[(0,n.jsx)("svg",{width:"32",height:"32",viewBox:"0 0 32 32",xmlns:"http://www.w3.org/2000/svg",children:(0,n.jsxs)("g",{fill:"none",fillRule:"evenodd",children:[(0,n.jsx)("path",{d:"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z",fill:"#FFF"}),(0,n.jsx)("path",{d:"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z",fill:"#555AB9"}),(0,n.jsx)("path",{d:"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z",fill:"#91BAF8"})]})}),(0,n.jsx)("h1",{children:"Acme"})]}),(0,n.jsx)("div",{children:t?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("span",{className:"welcome",children:["Welcome, ",(0,n.jsx)("b",{children:t.name}),"!"]}),(0,n.jsx)(c,{size:"small",onClick:o,label:"Log out"})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(c,{size:"small",onClick:e,label:"Log in"}),(0,n.jsx)(c,{primary:!0,size:"small",onClick:s,label:"Sign up"})]})})]})});var a=require("react/jsx-runtime"),C=()=>{let[t,e]=B.default.useState();return(0,a.jsxs)("article",{children:[(0,a.jsx)(f,{user:t,onLogin:()=>e({name:"Jane Doe"}),onLogout:()=>e(void 0),onCreateAccount:()=>e({name:"Jane Doe"})}),(0,a.jsxs)("section",{className:"storybook-page",children:[(0,a.jsx)("h2",{children:"Pages in Storybook"}),(0,a.jsxs)("p",{children:["We recommend building UIs with a"," ",(0,a.jsx)("a",{href:"https://componentdriven.org",target:"_blank",rel:"noopener noreferrer",children:(0,a.jsx)("strong",{children:"component-driven"})})," ","process starting with atomic components and ending with pages."]}),(0,a.jsx)("p",{children:"Render pages with mock data. This makes it easy to build and review page states without needing to navigate to them in your app. Here are some handy patterns for managing page data in Storybook:"}),(0,a.jsxs)("ul",{children:[(0,a.jsx)("li",{children:'Use a higher-level connected component. Storybook helps you compose such data from the "args" of child component stories'}),(0,a.jsx)("li",{children:"Assemble data in the page component from your services. You can mock these services out using Storybook."})]}),(0,a.jsxs)("p",{children:["Get a guided tutorial on component-driven development at"," ",(0,a.jsx)("a",{href:"https://storybook.js.org/tutorials/",target:"_blank",rel:"noopener noreferrer",children:"Storybook tutorials"}),". Read more in the"," ",(0,a.jsx)("a",{href:"https://storybook.js.org/docs",target:"_blank",rel:"noopener noreferrer",children:"docs"}),"."]}),(0,a.jsxs)("div",{className:"tip-wrapper",children:[(0,a.jsx)("span",{className:"tip",children:"Tip"})," Adjust the width of the canvas with the"," ",(0,a.jsx)("svg",{width:"10",height:"10",viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsx)("g",{fill:"none",fillRule:"evenodd",children:(0,a.jsx)("path",{d:"M1.5 5.2h4.8c.3 0 .5.2.5.4v5.1c-.1.2-.3.3-.4.3H1.4a.5.5 0 01-.5-.4V5.7c0-.3.2-.5.5-.5zm0-2.1h6.9c.3 0 .5.2.5.4v7a.5.5 0 01-1 0V4H1.5a.5.5 0 010-1zm0-2.1h9c.3 0 .5.2.5.4v9.1a.5.5 0 01-1 0V2H1.5a.5.5 0 010-1zm4.3 5.2H2V10h3.8V6.2z",id:"a",fill:"#999"})})}),"Viewports addon in the toolbar"]})]})]})};0&&(module.exports={Page});
|
|
2
|
+
//# sourceMappingURL=Page.js.map
|
package/dist/Page.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Page.tsx","../src/stories/Button.tsx","../src/stories/Header.tsx"],"sourcesContent":["import React from \"react\";\n\nimport { Header } from \"./Header\";\n\ntype User = {\n name: string;\n};\n\nexport const Page: React.FC = () => {\n const [user, setUser] = React.useState<User>();\n\n return (\n <article>\n <Header\n user={user}\n onLogin={() => setUser({ name: \"Jane Doe\" })}\n onLogout={() => setUser(undefined)}\n onCreateAccount={() => setUser({ name: \"Jane Doe\" })}\n />\n\n <section className=\"storybook-page\">\n <h2>Pages in Storybook</h2>\n <p>\n We recommend building UIs with a{\" \"}\n <a\n href=\"https://componentdriven.org\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <strong>component-driven</strong>\n </a>{\" \"}\n process starting with atomic components and ending with pages.\n </p>\n <p>\n Render pages with mock data. This makes it easy to build and review\n page states without needing to navigate to them in your app. Here are\n some handy patterns for managing page data in Storybook:\n </p>\n <ul>\n <li>\n Use a higher-level connected component. Storybook helps you compose\n such data from the "args" of child component stories\n </li>\n <li>\n Assemble data in the page component from your services. You can mock\n these services out using Storybook.\n </li>\n </ul>\n <p>\n Get a guided tutorial on component-driven development at{\" \"}\n <a\n href=\"https://storybook.js.org/tutorials/\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n Storybook tutorials\n </a>\n . Read more in the{\" \"}\n <a\n href=\"https://storybook.js.org/docs\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n docs\n </a>\n .\n </p>\n <div className=\"tip-wrapper\">\n <span className=\"tip\">Tip</span> Adjust the width of the canvas with\n the{\" \"}\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 12 12\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <g fill=\"none\" fillRule=\"evenodd\">\n <path\n d=\"M1.5 5.2h4.8c.3 0 .5.2.5.4v5.1c-.1.2-.3.3-.4.3H1.4a.5.5 0 01-.5-.4V5.7c0-.3.2-.5.5-.5zm0-2.1h6.9c.3 0 .5.2.5.4v7a.5.5 0 01-1 0V4H1.5a.5.5 0 010-1zm0-2.1h9c.3 0 .5.2.5.4v9.1a.5.5 0 01-1 0V2H1.5a.5.5 0 010-1zm4.3 5.2H2V10h3.8V6.2z\"\n id=\"a\"\n fill=\"#999\"\n />\n </g>\n </svg>\n Viewports addon in the toolbar\n </div>\n </section>\n </article>\n );\n};\n","import React from \"react\";\n\nexport type ButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type ButtonVariant = \"primary\" | \"neutral\" | \"secondary\";\nexport type ButtonShape = \"solid\" | \"outline\" | \"ghost\";\nexport type ButtonState = \"enabled\" | \"hovered\" | \"loading\" | \"disabled\";\n\nexport type IconButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type IconButtonVariant = \"primary\" | \"neutral\";\nexport type IconButtonType = \"solid\" | \"outline\" | \"weak\";\nexport type IconButtonState = \"enabled\" | \"hovered\" | \"disabled\";\n\nexport interface ActionButtonProps\n extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, \"type\"> {\n /** 버튼 크기 */\n size?: ButtonSize;\n /** 버튼 타입 (primary, neutral, secondary) */\n variant?: ButtonVariant;\n /** 버튼 모양 (solid, outline, ghost) */\n shape?: ButtonShape;\n /** 버튼 상태 */\n state?: ButtonState;\n /** 버튼 텍스트 */\n children: React.ReactNode;\n /** Prefix 아이콘 */\n prefixIcon?: React.ReactNode;\n /** Suffix 아이콘 */\n suffixIcon?: React.ReactNode;\n /** 로딩 상태일 때 표시할 스피너 */\n loading?: boolean;\n}\n\n/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */\nexport const ActionButton = ({\n size = \"medium\",\n variant = \"primary\",\n shape = \"solid\",\n state = \"enabled\",\n children,\n prefixIcon,\n suffixIcon,\n loading = false,\n className = \"\",\n disabled,\n ...props\n}: ActionButtonProps) => {\n const isDisabled = disabled || state === \"disabled\" || loading;\n const actualState = loading ? \"loading\" : state;\n\n const baseClasses = [\n \"action-button\",\n `action-button--${size}`,\n `action-button--${variant}`,\n `action-button--${shape}`,\n `action-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type=\"button\"\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"action-button__content\">\n {prefixIcon && (\n <span className=\"action-button__prefix-icon\">{prefixIcon}</span>\n )}\n <span className=\"action-button__label\">{children}</span>\n {suffixIcon && (\n <span className=\"action-button__suffix-icon\">{suffixIcon}</span>\n )}\n </span>\n {loading && (\n <span className=\"action-button__spinner\" aria-hidden=\"true\">\n <svg\n className=\"action-button__spinner-svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <circle\n className=\"action-button__spinner-circle\"\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n strokeLinecap=\"round\"\n strokeDasharray=\"32\"\n strokeDashoffset=\"32\"\n >\n <animate\n attributeName=\"stroke-dasharray\"\n dur=\"2s\"\n values=\"0 40;40 40;0 40\"\n repeatCount=\"indefinite\"\n />\n <animate\n attributeName=\"stroke-dashoffset\"\n dur=\"2s\"\n values=\"0;-40;-80\"\n repeatCount=\"indefinite\"\n />\n </circle>\n </svg>\n </span>\n )}\n </button>\n );\n};\n\n// 기존 Button 컴포넌트는 하위 호환성을 위해 유지\nexport interface ButtonProps {\n /** Is this the principal call to action on the page? */\n primary?: boolean;\n /** What background color to use */\n backgroundColor?: string;\n /** How large should the button be? */\n size?: \"small\" | \"medium\" | \"large\";\n /** Button contents */\n label: string;\n /** Optional click handler */\n onClick?: () => void;\n}\n\n/** Primary UI component for user interaction */\nexport const Button = ({\n primary = false,\n size = \"medium\",\n backgroundColor,\n label,\n ...props\n}: ButtonProps) => {\n const mode = primary\n ? \"storybook-button--primary\"\n : \"storybook-button--secondary\";\n return (\n <button\n type=\"button\"\n className={[\"storybook-button\", `storybook-button--${size}`, mode].join(\n \" \"\n )}\n style={{ backgroundColor }}\n {...props}\n >\n {label}\n </button>\n );\n};\n\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /** 버튼 크기 */\n size?: IconButtonSize;\n /** 버튼 타입 (primary 또는 neutral) */\n variant?: IconButtonVariant;\n /** 버튼 모양 (solid, outline, weak) */\n iconType?: IconButtonType;\n /** 버튼 상태 */\n state?: IconButtonState;\n /** 아이콘 (Heroicons 또는 React 컴포넌트) */\n icon: React.ReactNode;\n /** 아이콘에 대한 접근성 라벨 */\n \"aria-label\": string;\n}\n\n/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */\nexport const IconButton = ({\n size = \"large\",\n variant = \"primary\",\n iconType = \"solid\",\n state = \"enabled\",\n icon,\n className = \"\",\n disabled,\n type = \"button\",\n ...props\n}: IconButtonProps) => {\n const isDisabled = disabled || state === \"disabled\";\n // weak 타입은 disabled 상태를 가지지 않음\n const actualState = iconType === \"weak\" && isDisabled ? \"enabled\" : state;\n\n const baseClasses = [\n \"icon-button\",\n `icon-button--${size}`,\n `icon-button--${variant}`,\n `icon-button--${iconType}`,\n `icon-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type={type}\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"icon-button__icon\">{icon}</span>\n </button>\n );\n};\n","import { Button } from \"./Button\";\n\ntype User = {\n name: string;\n};\n\nexport interface HeaderProps {\n user?: User;\n onLogin?: () => void;\n onLogout?: () => void;\n onCreateAccount?: () => void;\n}\n\nexport const Header = ({\n user,\n onLogin,\n onLogout,\n onCreateAccount,\n}: HeaderProps) => (\n <header>\n <div className=\"storybook-header\">\n <div>\n <svg\n width=\"32\"\n height=\"32\"\n viewBox=\"0 0 32 32\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <g fill=\"none\" fillRule=\"evenodd\">\n <path\n d=\"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z\"\n fill=\"#FFF\"\n />\n <path\n d=\"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z\"\n fill=\"#555AB9\"\n />\n <path\n d=\"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z\"\n fill=\"#91BAF8\"\n />\n </g>\n </svg>\n <h1>Acme</h1>\n </div>\n <div>\n {user ? (\n <>\n <span className=\"welcome\">\n Welcome, <b>{user.name}</b>!\n </span>\n <Button size=\"small\" onClick={onLogout} label=\"Log out\" />\n </>\n ) : (\n <>\n <Button size=\"small\" onClick={onLogin} label=\"Log in\" />\n <Button\n primary\n size=\"small\"\n onClick={onCreateAccount}\n label=\"Sign up\"\n />\n </>\n )}\n </div>\n </div>\n </header>\n);\n"],"mappings":"mjCAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,UAAAE,IAAA,eAAAC,EAAAH,GAAA,IAAAI,EAAkB,oBCmEZ,IAAAC,EAAA,6BA+DC,IAAMC,EAAUC,GAMJ,CANI,IAAAC,EAAAD,EACrB,SAAAE,EAAU,GACV,KAAAC,EAAO,SACP,gBAAAC,EACA,MAAAC,CAtIF,EAkIuBJ,EAKlBK,EAAAC,EALkBN,EAKlB,CAJH,UACA,OACA,kBACA,UAGA,IAAMO,EAAON,EACT,4BACA,8BACJ,SACE,OAAC,SAAAO,EAAAC,EAAA,CACC,KAAK,SACL,UAAW,CAAC,mBAAoB,qBAAqBP,CAAI,GAAIK,CAAI,EAAE,KACjE,GACF,EACA,MAAO,CAAE,gBAAAJ,CAAgB,GACrBE,GANL,CAQE,SAAAD,GACH,CAEJ,EC5HU,IAAAM,EAAA,6BAfGC,EAAS,CAAC,CACrB,KAAAC,EACA,QAAAC,EACA,SAAAC,EACA,gBAAAC,CACF,OACE,OAAC,UACC,oBAAC,OAAI,UAAU,mBACb,qBAAC,OACC,oBAAC,OACC,MAAM,KACN,OAAO,KACP,QAAQ,YACR,MAAM,6BAEN,oBAAC,KAAE,KAAK,OAAO,SAAS,UACtB,oBAAC,QACC,EAAE,oFACF,KAAK,OACP,KACA,OAAC,QACC,EAAE,mEACF,KAAK,UACP,KACA,OAAC,QACC,EAAE,iEACF,KAAK,UACP,GACF,EACF,KACA,OAAC,MAAG,gBAAI,GACV,KACA,OAAC,OACE,SAAAH,KACC,oBACE,qBAAC,QAAK,UAAU,UAAU,yBACf,OAAC,KAAG,SAAAA,EAAK,KAAK,EAAI,KAC7B,KACA,OAACI,EAAA,CAAO,KAAK,QAAQ,QAASF,EAAU,MAAM,UAAU,GAC1D,KAEA,oBACE,oBAACE,EAAA,CAAO,KAAK,QAAQ,QAASH,EAAS,MAAM,SAAS,KACtD,OAACG,EAAA,CACC,QAAO,GACP,KAAK,QACL,QAASD,EACT,MAAM,UACR,GACF,EAEJ,GACF,EACF,EFrDI,IAAAE,EAAA,6BALOC,EAAiB,IAAM,CAClC,GAAM,CAACC,EAAMC,CAAO,EAAI,EAAAC,QAAM,SAAe,EAE7C,SACE,QAAC,WACC,oBAACC,EAAA,CACC,KAAMH,EACN,QAAS,IAAMC,EAAQ,CAAE,KAAM,UAAW,CAAC,EAC3C,SAAU,IAAMA,EAAQ,MAAS,EACjC,gBAAiB,IAAMA,EAAQ,CAAE,KAAM,UAAW,CAAC,EACrD,KAEA,QAAC,WAAQ,UAAU,iBACjB,oBAAC,MAAG,8BAAkB,KACtB,QAAC,KAAE,6CACgC,OACjC,OAAC,KACC,KAAK,8BACL,OAAO,SACP,IAAI,sBAEJ,mBAAC,UAAO,4BAAgB,EAC1B,EAAK,IAAI,kEAEX,KACA,OAAC,KAAE,8MAIH,KACA,QAAC,MACC,oBAAC,MAAG,oIAGJ,KACA,OAAC,MAAG,oHAGJ,GACF,KACA,QAAC,KAAE,qEACwD,OACzD,OAAC,KACC,KAAK,sCACL,OAAO,SACP,IAAI,sBACL,+BAED,EAAI,qBACe,OACnB,OAAC,KACC,KAAK,gCACL,OAAO,SACP,IAAI,sBACL,gBAED,EAAI,KAEN,KACA,QAAC,OAAI,UAAU,cACb,oBAAC,QAAK,UAAU,MAAM,eAAG,EAAO,2CAC5B,OACJ,OAAC,OACC,MAAM,KACN,OAAO,KACP,QAAQ,YACR,MAAM,6BAEN,mBAAC,KAAE,KAAK,OAAO,SAAS,UACtB,mBAAC,QACC,EAAE,uOACF,GAAG,IACH,KAAK,OACP,EACF,EACF,EAAM,kCAER,GACF,GACF,CAEJ","names":["Page_exports","__export","Page","__toCommonJS","import_react","import_jsx_runtime","Button","_a","_b","primary","size","backgroundColor","label","props","__objRest","mode","__spreadProps","__spreadValues","import_jsx_runtime","Header","user","onLogin","onLogout","onCreateAccount","Button","import_jsx_runtime","Page","user","setUser","React","Header"]}
|
package/dist/Page.mjs
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as p,b,c as d}from"./chunk-SV46H7N2.mjs";import{jsx as t,jsxs as x}from"react/jsx-runtime";var _=B=>{var l=B,{size:s="medium",variant:i="primary",shape:a="solid",state:o="enabled",children:r,prefixIcon:c,suffixIcon:e,loading:n=!1,className:m="",disabled:f}=l,u=d(l,["size","variant","shape","state","children","prefixIcon","suffixIcon","loading","className","disabled"]);let y=f||o==="disabled"||n,g=n?"loading":o,N=["action-button",`action-button--${s}`,`action-button--${i}`,`action-button--${a}`,`action-button--${g}`,m].filter(Boolean).join(" ");return x("button",b(p({type:"button",className:N,disabled:y},u),{children:[x("span",{className:"action-button__content",children:[c&&t("span",{className:"action-button__prefix-icon",children:c}),t("span",{className:"action-button__label",children:r}),e&&t("span",{className:"action-button__suffix-icon",children:e})]}),n&&t("span",{className:"action-button__spinner","aria-hidden":"true",children:t("svg",{className:"action-button__spinner-svg",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:x("circle",{className:"action-button__spinner-circle",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4",strokeLinecap:"round",strokeDasharray:"32",strokeDashoffset:"32",children:[t("animate",{attributeName:"stroke-dasharray",dur:"2s",values:"0 40;40 40;0 40",repeatCount:"indefinite"}),t("animate",{attributeName:"stroke-dashoffset",dur:"2s",values:"0;-40;-80",repeatCount:"indefinite"})]})})})]}))},k=c=>{var e=c,{primary:s=!1,size:i="medium",backgroundColor:a,label:o}=e,r=d(e,["primary","size","backgroundColor","label"]);let n=s?"storybook-button--primary":"storybook-button--secondary";return t("button",b(p({type:"button",className:["storybook-button",`storybook-button--${i}`,n].join(" "),style:{backgroundColor:a}},r),{children:o}))},h=f=>{var u=f,{size:s="large",variant:i="primary",iconType:a="solid",state:o="enabled",icon:r,className:c="",disabled:e,type:n="button"}=u,m=d(u,["size","variant","iconType","state","icon","className","disabled","type"]);let B=e||o==="disabled",l=a==="weak"&&B?"enabled":o,y=["icon-button",`icon-button--${s}`,`icon-button--${i}`,`icon-button--${a}`,`icon-button--${l}`,c].filter(Boolean).join(" ");return t("button",b(p({type:n,className:y,disabled:B},m),{children:t("span",{className:"icon-button__icon",children:r})}))};export{_ as a,k as b,h as c};
|
|
2
|
+
//# sourceMappingURL=chunk-HI5DDIGM.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Button.tsx"],"sourcesContent":["import React from \"react\";\n\nexport type ButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type ButtonVariant = \"primary\" | \"neutral\" | \"secondary\";\nexport type ButtonShape = \"solid\" | \"outline\" | \"ghost\";\nexport type ButtonState = \"enabled\" | \"hovered\" | \"loading\" | \"disabled\";\n\nexport type IconButtonSize = \"xlarge\" | \"large\" | \"medium\" | \"small\";\nexport type IconButtonVariant = \"primary\" | \"neutral\";\nexport type IconButtonType = \"solid\" | \"outline\" | \"weak\";\nexport type IconButtonState = \"enabled\" | \"hovered\" | \"disabled\";\n\nexport interface ActionButtonProps\n extends Omit<React.ButtonHTMLAttributes<HTMLButtonElement>, \"type\"> {\n /** 버튼 크기 */\n size?: ButtonSize;\n /** 버튼 타입 (primary, neutral, secondary) */\n variant?: ButtonVariant;\n /** 버튼 모양 (solid, outline, ghost) */\n shape?: ButtonShape;\n /** 버튼 상태 */\n state?: ButtonState;\n /** 버튼 텍스트 */\n children: React.ReactNode;\n /** Prefix 아이콘 */\n prefixIcon?: React.ReactNode;\n /** Suffix 아이콘 */\n suffixIcon?: React.ReactNode;\n /** 로딩 상태일 때 표시할 스피너 */\n loading?: boolean;\n}\n\n/** ActionButton 컴포넌트는 사용자가 어떠한 액션을 트리거하거나 이벤트를 실행할 때 사용한다. */\nexport const ActionButton = ({\n size = \"medium\",\n variant = \"primary\",\n shape = \"solid\",\n state = \"enabled\",\n children,\n prefixIcon,\n suffixIcon,\n loading = false,\n className = \"\",\n disabled,\n ...props\n}: ActionButtonProps) => {\n const isDisabled = disabled || state === \"disabled\" || loading;\n const actualState = loading ? \"loading\" : state;\n\n const baseClasses = [\n \"action-button\",\n `action-button--${size}`,\n `action-button--${variant}`,\n `action-button--${shape}`,\n `action-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type=\"button\"\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"action-button__content\">\n {prefixIcon && (\n <span className=\"action-button__prefix-icon\">{prefixIcon}</span>\n )}\n <span className=\"action-button__label\">{children}</span>\n {suffixIcon && (\n <span className=\"action-button__suffix-icon\">{suffixIcon}</span>\n )}\n </span>\n {loading && (\n <span className=\"action-button__spinner\" aria-hidden=\"true\">\n <svg\n className=\"action-button__spinner-svg\"\n viewBox=\"0 0 24 24\"\n fill=\"none\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <circle\n className=\"action-button__spinner-circle\"\n cx=\"12\"\n cy=\"12\"\n r=\"10\"\n stroke=\"currentColor\"\n strokeWidth=\"4\"\n strokeLinecap=\"round\"\n strokeDasharray=\"32\"\n strokeDashoffset=\"32\"\n >\n <animate\n attributeName=\"stroke-dasharray\"\n dur=\"2s\"\n values=\"0 40;40 40;0 40\"\n repeatCount=\"indefinite\"\n />\n <animate\n attributeName=\"stroke-dashoffset\"\n dur=\"2s\"\n values=\"0;-40;-80\"\n repeatCount=\"indefinite\"\n />\n </circle>\n </svg>\n </span>\n )}\n </button>\n );\n};\n\n// 기존 Button 컴포넌트는 하위 호환성을 위해 유지\nexport interface ButtonProps {\n /** Is this the principal call to action on the page? */\n primary?: boolean;\n /** What background color to use */\n backgroundColor?: string;\n /** How large should the button be? */\n size?: \"small\" | \"medium\" | \"large\";\n /** Button contents */\n label: string;\n /** Optional click handler */\n onClick?: () => void;\n}\n\n/** Primary UI component for user interaction */\nexport const Button = ({\n primary = false,\n size = \"medium\",\n backgroundColor,\n label,\n ...props\n}: ButtonProps) => {\n const mode = primary\n ? \"storybook-button--primary\"\n : \"storybook-button--secondary\";\n return (\n <button\n type=\"button\"\n className={[\"storybook-button\", `storybook-button--${size}`, mode].join(\n \" \"\n )}\n style={{ backgroundColor }}\n {...props}\n >\n {label}\n </button>\n );\n};\n\nexport interface IconButtonProps\n extends React.ButtonHTMLAttributes<HTMLButtonElement> {\n /** 버튼 크기 */\n size?: IconButtonSize;\n /** 버튼 타입 (primary 또는 neutral) */\n variant?: IconButtonVariant;\n /** 버튼 모양 (solid, outline, weak) */\n iconType?: IconButtonType;\n /** 버튼 상태 */\n state?: IconButtonState;\n /** 아이콘 (Heroicons 또는 React 컴포넌트) */\n icon: React.ReactNode;\n /** 아이콘에 대한 접근성 라벨 */\n \"aria-label\": string;\n}\n\n/** IconButton 컴포넌트는 텍스트 레이블 없이 아이콘만으로 액션을 전달하는 버튼 컴포넌트이다. */\nexport const IconButton = ({\n size = \"large\",\n variant = \"primary\",\n iconType = \"solid\",\n state = \"enabled\",\n icon,\n className = \"\",\n disabled,\n type = \"button\",\n ...props\n}: IconButtonProps) => {\n const isDisabled = disabled || state === \"disabled\";\n // weak 타입은 disabled 상태를 가지지 않음\n const actualState = iconType === \"weak\" && isDisabled ? \"enabled\" : state;\n\n const baseClasses = [\n \"icon-button\",\n `icon-button--${size}`,\n `icon-button--${variant}`,\n `icon-button--${iconType}`,\n `icon-button--${actualState}`,\n className,\n ]\n .filter(Boolean)\n .join(\" \");\n\n return (\n <button\n type={type}\n className={baseClasses}\n disabled={isDisabled}\n {...props}\n >\n <span className=\"icon-button__icon\">{icon}</span>\n </button>\n );\n};\n"],"mappings":"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","names":["jsx","jsxs","ActionButton","_a","_b","size","variant","shape","state","children","prefixIcon","suffixIcon","loading","className","disabled","props","__objRest","isDisabled","actualState","baseClasses","__spreadProps","__spreadValues","Button","primary","backgroundColor","label","mode","IconButton","iconType","icon","type"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a}from"./chunk-RYQQG4LH.mjs";import r from"react";import{jsx as e,jsxs as o}from"react/jsx-runtime";var p=()=>{let[n,t]=r.useState();return o("article",{children:[e(a,{user:n,onLogin:()=>t({name:"Jane Doe"}),onLogout:()=>t(void 0),onCreateAccount:()=>t({name:"Jane Doe"})}),o("section",{className:"storybook-page",children:[e("h2",{children:"Pages in Storybook"}),o("p",{children:["We recommend building UIs with a"," ",e("a",{href:"https://componentdriven.org",target:"_blank",rel:"noopener noreferrer",children:e("strong",{children:"component-driven"})})," ","process starting with atomic components and ending with pages."]}),e("p",{children:"Render pages with mock data. This makes it easy to build and review page states without needing to navigate to them in your app. Here are some handy patterns for managing page data in Storybook:"}),o("ul",{children:[e("li",{children:'Use a higher-level connected component. Storybook helps you compose such data from the "args" of child component stories'}),e("li",{children:"Assemble data in the page component from your services. You can mock these services out using Storybook."})]}),o("p",{children:["Get a guided tutorial on component-driven development at"," ",e("a",{href:"https://storybook.js.org/tutorials/",target:"_blank",rel:"noopener noreferrer",children:"Storybook tutorials"}),". Read more in the"," ",e("a",{href:"https://storybook.js.org/docs",target:"_blank",rel:"noopener noreferrer",children:"docs"}),"."]}),o("div",{className:"tip-wrapper",children:[e("span",{className:"tip",children:"Tip"})," Adjust the width of the canvas with the"," ",e("svg",{width:"10",height:"10",viewBox:"0 0 12 12",xmlns:"http://www.w3.org/2000/svg",children:e("g",{fill:"none",fillRule:"evenodd",children:e("path",{d:"M1.5 5.2h4.8c.3 0 .5.2.5.4v5.1c-.1.2-.3.3-.4.3H1.4a.5.5 0 01-.5-.4V5.7c0-.3.2-.5.5-.5zm0-2.1h6.9c.3 0 .5.2.5.4v7a.5.5 0 01-1 0V4H1.5a.5.5 0 010-1zm0-2.1h9c.3 0 .5.2.5.4v9.1a.5.5 0 01-1 0V2H1.5a.5.5 0 010-1zm4.3 5.2H2V10h3.8V6.2z",id:"a",fill:"#999"})})}),"Viewports addon in the toolbar"]})]})]})};export{p as a};
|
|
2
|
+
//# sourceMappingURL=chunk-LRXJPSTV.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Page.tsx"],"sourcesContent":["import React from \"react\";\n\nimport { Header } from \"./Header\";\n\ntype User = {\n name: string;\n};\n\nexport const Page: React.FC = () => {\n const [user, setUser] = React.useState<User>();\n\n return (\n <article>\n <Header\n user={user}\n onLogin={() => setUser({ name: \"Jane Doe\" })}\n onLogout={() => setUser(undefined)}\n onCreateAccount={() => setUser({ name: \"Jane Doe\" })}\n />\n\n <section className=\"storybook-page\">\n <h2>Pages in Storybook</h2>\n <p>\n We recommend building UIs with a{\" \"}\n <a\n href=\"https://componentdriven.org\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n <strong>component-driven</strong>\n </a>{\" \"}\n process starting with atomic components and ending with pages.\n </p>\n <p>\n Render pages with mock data. This makes it easy to build and review\n page states without needing to navigate to them in your app. Here are\n some handy patterns for managing page data in Storybook:\n </p>\n <ul>\n <li>\n Use a higher-level connected component. Storybook helps you compose\n such data from the "args" of child component stories\n </li>\n <li>\n Assemble data in the page component from your services. You can mock\n these services out using Storybook.\n </li>\n </ul>\n <p>\n Get a guided tutorial on component-driven development at{\" \"}\n <a\n href=\"https://storybook.js.org/tutorials/\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n Storybook tutorials\n </a>\n . Read more in the{\" \"}\n <a\n href=\"https://storybook.js.org/docs\"\n target=\"_blank\"\n rel=\"noopener noreferrer\"\n >\n docs\n </a>\n .\n </p>\n <div className=\"tip-wrapper\">\n <span className=\"tip\">Tip</span> Adjust the width of the canvas with\n the{\" \"}\n <svg\n width=\"10\"\n height=\"10\"\n viewBox=\"0 0 12 12\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <g fill=\"none\" fillRule=\"evenodd\">\n <path\n d=\"M1.5 5.2h4.8c.3 0 .5.2.5.4v5.1c-.1.2-.3.3-.4.3H1.4a.5.5 0 01-.5-.4V5.7c0-.3.2-.5.5-.5zm0-2.1h6.9c.3 0 .5.2.5.4v7a.5.5 0 01-1 0V4H1.5a.5.5 0 010-1zm0-2.1h9c.3 0 .5.2.5.4v9.1a.5.5 0 01-1 0V2H1.5a.5.5 0 010-1zm4.3 5.2H2V10h3.8V6.2z\"\n id=\"a\"\n fill=\"#999\"\n />\n </g>\n </svg>\n Viewports addon in the toolbar\n </div>\n </section>\n </article>\n );\n};\n"],"mappings":"oCAAA,OAAOA,MAAW,QAaZ,cAAAC,EASE,QAAAC,MATF,oBALC,IAAMC,EAAiB,IAAM,CAClC,GAAM,CAACC,EAAMC,CAAO,EAAIC,EAAM,SAAe,EAE7C,OACEJ,EAAC,WACC,UAAAD,EAACM,EAAA,CACC,KAAMH,EACN,QAAS,IAAMC,EAAQ,CAAE,KAAM,UAAW,CAAC,EAC3C,SAAU,IAAMA,EAAQ,MAAS,EACjC,gBAAiB,IAAMA,EAAQ,CAAE,KAAM,UAAW,CAAC,EACrD,EAEAH,EAAC,WAAQ,UAAU,iBACjB,UAAAD,EAAC,MAAG,8BAAkB,EACtBC,EAAC,KAAE,6CACgC,IACjCD,EAAC,KACC,KAAK,8BACL,OAAO,SACP,IAAI,sBAEJ,SAAAA,EAAC,UAAO,4BAAgB,EAC1B,EAAK,IAAI,kEAEX,EACAA,EAAC,KAAE,8MAIH,EACAC,EAAC,MACC,UAAAD,EAAC,MAAG,oIAGJ,EACAA,EAAC,MAAG,oHAGJ,GACF,EACAC,EAAC,KAAE,qEACwD,IACzDD,EAAC,KACC,KAAK,sCACL,OAAO,SACP,IAAI,sBACL,+BAED,EAAI,qBACe,IACnBA,EAAC,KACC,KAAK,gCACL,OAAO,SACP,IAAI,sBACL,gBAED,EAAI,KAEN,EACAC,EAAC,OAAI,UAAU,cACb,UAAAD,EAAC,QAAK,UAAU,MAAM,eAAG,EAAO,2CAC5B,IACJA,EAAC,OACC,MAAM,KACN,OAAO,KACP,QAAQ,YACR,MAAM,6BAEN,SAAAA,EAAC,KAAE,KAAK,OAAO,SAAS,UACtB,SAAAA,EAAC,QACC,EAAE,uOACF,GAAG,IACH,KAAK,OACP,EACF,EACF,EAAM,kCAER,GACF,GACF,CAEJ","names":["React","jsx","jsxs","Page","user","setUser","React","Header"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{b as o}from"./chunk-HI5DDIGM.mjs";import{Fragment as a,jsx as e,jsxs as l}from"react/jsx-runtime";var t=({user:i,onLogin:s,onLogout:d,onCreateAccount:n})=>e("header",{children:l("div",{className:"storybook-header",children:[l("div",{children:[e("svg",{width:"32",height:"32",viewBox:"0 0 32 32",xmlns:"http://www.w3.org/2000/svg",children:l("g",{fill:"none",fillRule:"evenodd",children:[e("path",{d:"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z",fill:"#FFF"}),e("path",{d:"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z",fill:"#555AB9"}),e("path",{d:"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z",fill:"#91BAF8"})]})}),e("h1",{children:"Acme"})]}),e("div",{children:i?l(a,{children:[l("span",{className:"welcome",children:["Welcome, ",e("b",{children:i.name}),"!"]}),e(o,{size:"small",onClick:d,label:"Log out"})]}):l(a,{children:[e(o,{size:"small",onClick:s,label:"Log in"}),e(o,{primary:!0,size:"small",onClick:n,label:"Sign up"})]})})]})});export{t as a};
|
|
2
|
+
//# sourceMappingURL=chunk-RYQQG4LH.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/stories/Header.tsx"],"sourcesContent":["import { Button } from \"./Button\";\n\ntype User = {\n name: string;\n};\n\nexport interface HeaderProps {\n user?: User;\n onLogin?: () => void;\n onLogout?: () => void;\n onCreateAccount?: () => void;\n}\n\nexport const Header = ({\n user,\n onLogin,\n onLogout,\n onCreateAccount,\n}: HeaderProps) => (\n <header>\n <div className=\"storybook-header\">\n <div>\n <svg\n width=\"32\"\n height=\"32\"\n viewBox=\"0 0 32 32\"\n xmlns=\"http://www.w3.org/2000/svg\"\n >\n <g fill=\"none\" fillRule=\"evenodd\">\n <path\n d=\"M10 0h12a10 10 0 0110 10v12a10 10 0 01-10 10H10A10 10 0 010 22V10A10 10 0 0110 0z\"\n fill=\"#FFF\"\n />\n <path\n d=\"M5.3 10.6l10.4 6v11.1l-10.4-6v-11zm11.4-6.2l9.7 5.5-9.7 5.6V4.4z\"\n fill=\"#555AB9\"\n />\n <path\n d=\"M27.2 10.6v11.2l-10.5 6V16.5l10.5-6zM15.7 4.4v11L6 10l9.7-5.5z\"\n fill=\"#91BAF8\"\n />\n </g>\n </svg>\n <h1>Acme</h1>\n </div>\n <div>\n {user ? (\n <>\n <span className=\"welcome\">\n Welcome, <b>{user.name}</b>!\n </span>\n <Button size=\"small\" onClick={onLogout} label=\"Log out\" />\n </>\n ) : (\n <>\n <Button size=\"small\" onClick={onLogin} label=\"Log in\" />\n <Button\n primary\n size=\"small\"\n onClick={onCreateAccount}\n label=\"Sign up\"\n />\n </>\n )}\n </div>\n </div>\n </header>\n);\n"],"mappings":"yCA4BU,OAmBA,YAAAA,EAlBE,OAAAC,EADF,QAAAC,MAAA,oBAfH,IAAMC,EAAS,CAAC,CACrB,KAAAC,EACA,QAAAC,EACA,SAAAC,EACA,gBAAAC,CACF,IACEN,EAAC,UACC,SAAAC,EAAC,OAAI,UAAU,mBACb,UAAAA,EAAC,OACC,UAAAD,EAAC,OACC,MAAM,KACN,OAAO,KACP,QAAQ,YACR,MAAM,6BAEN,SAAAC,EAAC,KAAE,KAAK,OAAO,SAAS,UACtB,UAAAD,EAAC,QACC,EAAE,oFACF,KAAK,OACP,EACAA,EAAC,QACC,EAAE,mEACF,KAAK,UACP,EACAA,EAAC,QACC,EAAE,iEACF,KAAK,UACP,GACF,EACF,EACAA,EAAC,MAAG,gBAAI,GACV,EACAA,EAAC,OACE,SAAAG,EACCF,EAAAF,EAAA,CACE,UAAAE,EAAC,QAAK,UAAU,UAAU,sBACfD,EAAC,KAAG,SAAAG,EAAK,KAAK,EAAI,KAC7B,EACAH,EAACO,EAAA,CAAO,KAAK,QAAQ,QAASF,EAAU,MAAM,UAAU,GAC1D,EAEAJ,EAAAF,EAAA,CACE,UAAAC,EAACO,EAAA,CAAO,KAAK,QAAQ,QAASH,EAAS,MAAM,SAAS,EACtDJ,EAACO,EAAA,CACC,QAAO,GACP,KAAK,QACL,QAASD,EACT,MAAM,UACR,GACF,EAEJ,GACF,EACF","names":["Fragment","jsx","jsxs","Header","user","onLogin","onLogout","onCreateAccount","Button"]}
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
var i=Object.defineProperty,j=Object.defineProperties;var k=Object.getOwnPropertyDescriptors;var e=Object.getOwnPropertySymbols;var g=Object.prototype.hasOwnProperty,h=Object.prototype.propertyIsEnumerable;var f=(b,a,c)=>a in b?i(b,a,{enumerable:!0,configurable:!0,writable:!0,value:c}):b[a]=c,l=(b,a)=>{for(var c in a||(a={}))g.call(a,c)&&f(b,c,a[c]);if(e)for(var c of e(a))h.call(a,c)&&f(b,c,a[c]);return b},m=(b,a)=>j(b,k(a));var n=(b,a)=>{var c={};for(var d in b)g.call(b,d)&&a.indexOf(d)<0&&(c[d]=b[d]);if(b!=null&&e)for(var d of e(b))a.indexOf(d)<0&&h.call(b,d)&&(c[d]=b[d]);return c};var o=(b,a)=>()=>(a||b((a={exports:{}}).exports,a),a.exports);export{l as a,m as b,n as c,o as d};
|
|
2
|
+
//# sourceMappingURL=chunk-SV46H7N2.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":[],"sourcesContent":[],"mappings":"","names":[]}
|