maru_design2 2.28.0 → 2.28.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.
Files changed (108) hide show
  1. package/.release-please-manifest.json +3 -0
  2. package/CHANGELOG.md +273 -909
  3. package/dist/components/atoms/button/Button.d.ts +33 -33
  4. package/dist/components/atoms/button/index.d.ts +1 -1
  5. package/dist/components/atoms/checkbox/Checkbox.d.ts +21 -21
  6. package/dist/components/atoms/checkbox/index.d.ts +1 -1
  7. package/dist/components/atoms/chip/Chip.d.ts +29 -29
  8. package/dist/components/atoms/chip/index.d.ts +1 -1
  9. package/dist/components/atoms/code/Code.d.ts +7 -7
  10. package/dist/components/atoms/code/index.d.ts +1 -1
  11. package/dist/components/atoms/icon/Icon.d.ts +16 -16
  12. package/dist/components/atoms/icon/iconmap.d.ts +422 -418
  13. package/dist/components/atoms/icon/index.d.ts +2 -2
  14. package/dist/components/atoms/input/Input.d.ts +43 -43
  15. package/dist/components/atoms/input/index.d.ts +1 -1
  16. package/dist/components/atoms/popover/Popover.d.ts +19 -19
  17. package/dist/components/atoms/popover/index.d.ts +1 -1
  18. package/dist/components/atoms/radio/Radio.d.ts +14 -14
  19. package/dist/components/atoms/radio/index.d.ts +1 -1
  20. package/dist/components/atoms/skeleton/Contents.d.ts +1 -1
  21. package/dist/components/atoms/skeleton/Skeleton.d.ts +6 -6
  22. package/dist/components/atoms/skeleton/index.d.ts +1 -1
  23. package/dist/components/atoms/slider/Slider.d.ts +31 -31
  24. package/dist/components/atoms/slider/index.d.ts +1 -1
  25. package/dist/components/atoms/textarea/Textarea.d.ts +38 -38
  26. package/dist/components/atoms/textarea/index.d.ts +1 -1
  27. package/dist/components/atoms/toggle/Toggle.d.ts +20 -20
  28. package/dist/components/atoms/toggle/index.d.ts +1 -1
  29. package/dist/components/atoms/tooltip/Tooltip.d.ts +29 -29
  30. package/dist/components/atoms/tooltip/index.d.ts +1 -1
  31. package/dist/components/molecules/calendar/Calendar.d.ts +27 -27
  32. package/dist/components/molecules/calendar/DatePickerHeader.d.ts +3 -3
  33. package/dist/components/molecules/calendar/DatePickerWrapper.d.ts +9 -9
  34. package/dist/components/molecules/calendar/index.d.ts +1 -1
  35. package/dist/components/molecules/dropdown/Dropdown.d.ts +90 -90
  36. package/dist/components/molecules/dropdown/index.d.ts +1 -1
  37. package/dist/components/molecules/dropdown/menu/MenuItem.d.ts +16 -16
  38. package/dist/components/molecules/dropdown/menu/index.d.ts +31 -31
  39. package/dist/components/molecules/dropdown/toggleButton/Arrow.d.ts +9 -9
  40. package/dist/components/molecules/dropdown/toggleButton/Clear.d.ts +6 -6
  41. package/dist/components/molecules/dropdown/toggleButton/index.d.ts +19 -19
  42. package/dist/components/molecules/modal/Modal.d.ts +48 -48
  43. package/dist/components/molecules/modal/index.d.ts +1 -1
  44. package/dist/components/molecules/multiSelectDropdown/MultiSelectDropdown.d.ts +76 -76
  45. package/dist/components/molecules/multiSelectDropdown/index.d.ts +1 -1
  46. package/dist/components/molecules/multiSelectDropdown/menu/MenuItem.d.ts +12 -12
  47. package/dist/components/molecules/multiSelectDropdown/menu/index.d.ts +21 -21
  48. package/dist/components/molecules/multiSelectDropdown/toggleButton/Arrow.d.ts +9 -9
  49. package/dist/components/molecules/multiSelectDropdown/toggleButton/Clear.d.ts +6 -6
  50. package/dist/components/molecules/multiSelectDropdown/toggleButton/index.d.ts +17 -17
  51. package/dist/components/molecules/pagination/Pagination.d.ts +22 -22
  52. package/dist/components/molecules/pagination/index.d.ts +1 -1
  53. package/dist/components/molecules/searchInput/SearchInput.d.ts +34 -34
  54. package/dist/components/molecules/searchInput/filter/FilterPopover.d.ts +16 -16
  55. package/dist/components/molecules/searchInput/filter/index.d.ts +17 -17
  56. package/dist/components/molecules/searchInput/index.d.ts +1 -1
  57. package/dist/components/molecules/table/Colgroup.d.ts +9 -9
  58. package/dist/components/molecules/table/Table.d.ts +3 -3
  59. package/dist/components/molecules/table/body/BinButtonTd.d.ts +7 -7
  60. package/dist/components/molecules/table/body/ChartButtonTd.d.ts +8 -8
  61. package/dist/components/molecules/table/body/CheckboxTd.d.ts +6 -6
  62. package/dist/components/molecules/table/body/EmptyTr.d.ts +8 -8
  63. package/dist/components/molecules/table/body/KebabMenuTd.d.ts +7 -7
  64. package/dist/components/molecules/table/body/RadioTd.d.ts +6 -6
  65. package/dist/components/molecules/table/body/Tr.d.ts +7 -7
  66. package/dist/components/molecules/table/body/index.d.ts +7 -7
  67. package/dist/components/molecules/table/header/FilterButtonsTh.d.ts +7 -7
  68. package/dist/components/molecules/table/header/FilterTh.d.ts +8 -8
  69. package/dist/components/molecules/table/header/SortableColumn.d.ts +15 -15
  70. package/dist/components/molecules/table/header/index.d.ts +17 -17
  71. package/dist/components/molecules/table/index.d.ts +1 -1
  72. package/dist/components/molecules/table/types.d.ts +125 -125
  73. package/dist/components/molecules/toast/Details.d.ts +6 -6
  74. package/dist/components/molecules/toast/Toast.d.ts +31 -31
  75. package/dist/components/molecules/toast/ToastContext.d.ts +15 -15
  76. package/dist/components/molecules/toast/ToastStyle.d.ts +18 -18
  77. package/dist/components/molecules/toast/index.d.ts +1 -1
  78. package/dist/components/molecules/toast/types.d.ts +4 -4
  79. package/dist/components/styleProvider/StyleProvider.d.ts +10 -10
  80. package/dist/components/styleProvider/index.d.ts +1 -1
  81. package/dist/enums/color.d.ts +14 -14
  82. package/dist/enums/direction.d.ts +2 -2
  83. package/dist/enums/gap.d.ts +4 -4
  84. package/dist/enums/size.d.ts +8 -8
  85. package/dist/enums/type.d.ts +4 -4
  86. package/dist/enums/variant.d.ts +8 -8
  87. package/dist/hooks/useButtonState.d.ts +16 -16
  88. package/dist/hooks/useColor.d.ts +4 -4
  89. package/dist/hooks/useCombineRef.d.ts +11 -11
  90. package/dist/hooks/useCreatePortal.d.ts +7 -7
  91. package/dist/hooks/useId.d.ts +7 -7
  92. package/dist/index.d.ts +22 -22
  93. package/dist/index.js +320 -250
  94. package/dist/utils/copy.d.ts +6 -6
  95. package/dist/utils/format.d.ts +2 -2
  96. package/dist/utils/highlight.d.ts +1 -1
  97. package/package.json +74 -74
  98. package/release-please-config.json +8 -0
  99. package/.idea/MaruDesign2.iml +0 -13
  100. package/.idea/codeStyles/Project.xml +0 -77
  101. package/.idea/codeStyles/codeStyleConfig.xml +0 -5
  102. package/.idea/inspectionProfiles/Project_Default.xml +0 -94
  103. package/.idea/jsLinters/eslint.xml +0 -6
  104. package/.idea/material_theme_project_new.xml +0 -12
  105. package/.idea/modules.xml +0 -8
  106. package/.idea/prettier.xml +0 -8
  107. package/.idea/vcs.xml +0 -6
  108. package/.idea/watcherTasks.xml +0 -4
@@ -1,125 +1,125 @@
1
- /// <reference types="react" />
2
- export interface ISort {
3
- columnName: string;
4
- desc: boolean;
5
- }
6
- export interface IColumnFormats {
7
- columnIdKey: string;
8
- columnName?: string;
9
- filter?: React.ReactNode;
10
- customColumn?: (content: any, rowId: string) => React.ReactNode;
11
- width?: string;
12
- sortable?: boolean;
13
- isHide?: boolean;
14
- /**
15
- * 헤더 컬럼명 옆에 아이콘+툴팁 노출. 툴팁에 들어갈 문자열 설정.
16
- */
17
- iconTooltip?: string;
18
- key?: string;
19
- }
20
- export interface IFilter {
21
- on: boolean;
22
- onReset: () => void;
23
- }
24
- export type TShow = 'none' | 'hover' | 'always';
25
- export interface TableProps {
26
- /**
27
- * 행 아이디로 쓸 키
28
- */
29
- rowIdKey: string;
30
- data: Record<string, any>[];
31
- /**
32
- * 열 구성
33
- * @param columnIdKey
34
- */
35
- formats: IColumnFormats[];
36
- /**
37
- * 테이블의 최대 높이 px (@v2_old tableBodyMaxHeight)
38
- * 최소 160은 되어야 행 하나가 보입니다.
39
- */
40
- maxHeight: number;
41
- /**
42
- * 소팅할 열과 방향(오름차순, 내림차순)을 설정할뿐 실제로 정렬을 하지는 않습니다. (@v1 currentSort)
43
- */
44
- sort?: ISort;
45
- /**
46
- * (@v1 setCurrentSort)
47
- */
48
- onSort?: (sort: ISort) => void;
49
- /**
50
- * 체크박스에 체크된 아이디들. radioCheckedId와 같이 쓸 수 없음.(@v1 hasCheckbox, checkedArray)
51
- */
52
- checkedIds?: string[];
53
- /**
54
- * (@v1 setCheckedArray)
55
- */
56
- onCheck?: (ids: string[]) => void;
57
- /**
58
- * 라디오에 체크된 아이디. checkedIds와 같이 쓸 수 없음.
59
- */
60
- radioCheckedId?: string;
61
- onRadioCheck?: (id: string) => void;
62
- /**
63
- * 최우측 컬럼 헤더의 필터 영역. format.filter와 조합해서 사용 가능
64
- */
65
- filter?: IFilter;
66
- /**
67
- * 최우측 컬럼 바디의 더보기 메뉴. binButton, arrowButton과 같이 쓸 수 없음.
68
- * TShow='none' | 'hover' | 'always'. (@v1 hamberger)
69
- */
70
- kebabMenu?: {
71
- show: (rowId?: string) => TShow;
72
- content: (rowId: string, onClose: () => void) => React.ReactNode;
73
- };
74
- /**
75
- * 최우측 컬럼 바디의 휴지통 버튼. kebabMenu, arrowButton과 같이 쓸 수 없음.
76
- * TShow='none' | 'hover' | 'always'.
77
- */
78
- binButton?: {
79
- show: (rowId?: string) => TShow;
80
- onClick: (rowId: string) => void;
81
- };
82
- /**
83
- * 최우측 컬럼 바디의 화살표 버튼. kebabMenu, binButton과 같이 쓸 수 없음.
84
- * TShow='none' | 'hover' | 'always'.
85
- */
86
- chartButton?: {
87
- show: (rowId?: string) => TShow;
88
- onClick: (rowId: string) => void;
89
- };
90
- /**
91
- * 테이블 행 click 이벤트. rowId를 콜백함수에게 전달.
92
- */
93
- onRowClick?: (rowId: string) => void;
94
- /**
95
- * 선택된 행 스타일 지정, onRowClick과 조합해서 사용 가능 (@v1 focusedRowInfo)
96
- */
97
- selectedRow?: {
98
- rowId: string;
99
- className?: string;
100
- scrollIntoView?: boolean | ScrollIntoViewOptions;
101
- };
102
- /**
103
- * 하이라이팅할 행과 스타일 지정
104
- */
105
- highlightRows?: {
106
- rowIds: string[];
107
- className?: string;
108
- };
109
- className?: string;
110
- id?: string;
111
- /**
112
- * 데이터가 없을때의 조건과 문구
113
- */
114
- noData?: {
115
- isNoData: boolean;
116
- message: string;
117
- };
118
- /**
119
- * 로딩일때의 조건과 노드
120
- */
121
- loading?: {
122
- isLoading: boolean;
123
- content?: React.ReactNode;
124
- };
125
- }
1
+ /// <reference types="react" />
2
+ export interface ISort {
3
+ columnName: string;
4
+ desc: boolean;
5
+ }
6
+ export interface IColumnFormats {
7
+ columnIdKey: string;
8
+ columnName?: string;
9
+ filter?: React.ReactNode;
10
+ customColumn?: (content: any, rowId: string) => React.ReactNode;
11
+ width?: string;
12
+ sortable?: boolean;
13
+ isHide?: boolean;
14
+ /**
15
+ * 헤더 컬럼명 옆에 아이콘+툴팁 노출. 툴팁에 들어갈 문자열 설정.
16
+ */
17
+ iconTooltip?: string;
18
+ key?: string;
19
+ }
20
+ export interface IFilter {
21
+ on: boolean;
22
+ onReset: () => void;
23
+ }
24
+ export type TShow = 'none' | 'hover' | 'always';
25
+ export interface TableProps {
26
+ /**
27
+ * 행 아이디로 쓸 키
28
+ */
29
+ rowIdKey: string;
30
+ data: Record<string, any>[];
31
+ /**
32
+ * 열 구성
33
+ * @param columnIdKey
34
+ */
35
+ formats: IColumnFormats[];
36
+ /**
37
+ * 테이블의 최대 높이 px (@v2_old tableBodyMaxHeight)
38
+ * 최소 160은 되어야 행 하나가 보입니다.
39
+ */
40
+ maxHeight: number;
41
+ /**
42
+ * 소팅할 열과 방향(오름차순, 내림차순)을 설정할뿐 실제로 정렬을 하지는 않습니다. (@v1 currentSort)
43
+ */
44
+ sort?: ISort;
45
+ /**
46
+ * (@v1 setCurrentSort)
47
+ */
48
+ onSort?: (sort: ISort) => void;
49
+ /**
50
+ * 체크박스에 체크된 아이디들. radioCheckedId와 같이 쓸 수 없음.(@v1 hasCheckbox, checkedArray)
51
+ */
52
+ checkedIds?: string[];
53
+ /**
54
+ * (@v1 setCheckedArray)
55
+ */
56
+ onCheck?: (ids: string[]) => void;
57
+ /**
58
+ * 라디오에 체크된 아이디. checkedIds와 같이 쓸 수 없음.
59
+ */
60
+ radioCheckedId?: string;
61
+ onRadioCheck?: (id: string) => void;
62
+ /**
63
+ * 최우측 컬럼 헤더의 필터 영역. format.filter와 조합해서 사용 가능
64
+ */
65
+ filter?: IFilter;
66
+ /**
67
+ * 최우측 컬럼 바디의 더보기 메뉴. binButton, arrowButton과 같이 쓸 수 없음.
68
+ * TShow='none' | 'hover' | 'always'. (@v1 hamberger)
69
+ */
70
+ kebabMenu?: {
71
+ show: (rowId?: string) => TShow;
72
+ content: (rowId: string, onClose: () => void) => React.ReactNode;
73
+ };
74
+ /**
75
+ * 최우측 컬럼 바디의 휴지통 버튼. kebabMenu, arrowButton과 같이 쓸 수 없음.
76
+ * TShow='none' | 'hover' | 'always'.
77
+ */
78
+ binButton?: {
79
+ show: (rowId?: string) => TShow;
80
+ onClick: (rowId: string) => void;
81
+ };
82
+ /**
83
+ * 최우측 컬럼 바디의 화살표 버튼. kebabMenu, binButton과 같이 쓸 수 없음.
84
+ * TShow='none' | 'hover' | 'always'.
85
+ */
86
+ chartButton?: {
87
+ show: (rowId?: string) => TShow;
88
+ onClick: (rowId: string) => void;
89
+ };
90
+ /**
91
+ * 테이블 행 click 이벤트. rowId를 콜백함수에게 전달.
92
+ */
93
+ onRowClick?: (rowId: string) => void;
94
+ /**
95
+ * 선택된 행 스타일 지정, onRowClick과 조합해서 사용 가능 (@v1 focusedRowInfo)
96
+ */
97
+ selectedRow?: {
98
+ rowId: string;
99
+ className?: string;
100
+ scrollIntoView?: boolean | ScrollIntoViewOptions;
101
+ };
102
+ /**
103
+ * 하이라이팅할 행과 스타일 지정
104
+ */
105
+ highlightRows?: {
106
+ rowIds: string[];
107
+ className?: string;
108
+ };
109
+ className?: string;
110
+ id?: string;
111
+ /**
112
+ * 데이터가 없을때의 조건과 문구
113
+ */
114
+ noData?: {
115
+ isNoData: boolean;
116
+ message: string;
117
+ };
118
+ /**
119
+ * 로딩일때의 조건과 노드
120
+ */
121
+ loading?: {
122
+ isLoading: boolean;
123
+ content?: React.ReactNode;
124
+ };
125
+ }
@@ -1,6 +1,6 @@
1
- import { IToastDetailItem } from './types';
2
- interface DetailsProps {
3
- details: IToastDetailItem[] | undefined;
4
- }
5
- export default function Details({ details }: DetailsProps): import("react/jsx-runtime").JSX.Element | null;
6
- export {};
1
+ import { IToastDetailItem } from './types';
2
+ interface DetailsProps {
3
+ details: IToastDetailItem[] | undefined;
4
+ }
5
+ export default function Details({ details }: DetailsProps): import("react/jsx-runtime").JSX.Element | null;
6
+ export {};
@@ -1,31 +1,31 @@
1
- import { IToastDetailItem } from './types';
2
- import { TToastVariant } from '../../../enums/variant';
3
- export interface IToast {
4
- variant: TToastVariant;
5
- content: string;
6
- title?: {
7
- main: string;
8
- sub?: string;
9
- };
10
- closeButton?: {
11
- content: string;
12
- onClick: () => void;
13
- };
14
- details?: IToastDetailItem[];
15
- disableAutoOff?: boolean;
16
- }
17
- export interface ToastProps {
18
- id: string;
19
- /**
20
- * @param variant 'success', 'warning', 'danger'
21
- * @param content 컴포넌트에 들어갈 한 줄짜리 내용(string)
22
- * @param title {main: string, sub?: string}
23
- * @param closeButton 닫기 버튼 커스텀 (default는 x 아이콘 버튼) {content: string, onClick: () => void}
24
- * @param details details, summary 태그를 활용하여 노출할 내용 (legacy)
25
- * @param disableAutoOff 자동 꺼짐 불가 여부(boolean)
26
- */
27
- toast: IToast;
28
- drop: (id: string) => void;
29
- className?: string;
30
- }
31
- export declare function Toast({ id, toast, drop, className }: ToastProps): import("react/jsx-runtime").JSX.Element | null;
1
+ import { IToastDetailItem } from './types';
2
+ import { TToastVariant } from '../../../enums/variant';
3
+ export interface IToast {
4
+ variant: TToastVariant;
5
+ content: string;
6
+ title?: {
7
+ main: string;
8
+ sub?: string;
9
+ };
10
+ closeButton?: {
11
+ content: string;
12
+ onClick: () => void;
13
+ };
14
+ details?: IToastDetailItem[];
15
+ disableAutoOff?: boolean;
16
+ }
17
+ export interface ToastProps {
18
+ id: string;
19
+ /**
20
+ * @param variant 'success', 'warning', 'danger'
21
+ * @param content 컴포넌트에 들어갈 한 줄짜리 내용(string)
22
+ * @param title {main: string, sub?: string}
23
+ * @param closeButton 닫기 버튼 커스텀 (default는 x 아이콘 버튼) {content: string, onClick: () => void}
24
+ * @param details details, summary 태그를 활용하여 노출할 내용 (legacy)
25
+ * @param disableAutoOff 자동 꺼짐 불가 여부(boolean)
26
+ */
27
+ toast: IToast;
28
+ drop: (id: string) => void;
29
+ className?: string;
30
+ }
31
+ export declare function Toast({ id, toast, drop, className }: ToastProps): import("react/jsx-runtime").JSX.Element | null;
@@ -1,15 +1,15 @@
1
- import React, { ReactNode } from 'react';
2
- import { IToast } from './Toast';
3
- interface ToastContextProps {
4
- toasts: {
5
- [id: string]: IToast;
6
- };
7
- pop: (toast: IToast) => void;
8
- drop: (id: string) => void;
9
- }
10
- declare const ToastContext: React.Context<ToastContextProps | undefined>;
11
- declare function ToastProvider({ children }: {
12
- children: ReactNode;
13
- }): import("react/jsx-runtime").JSX.Element;
14
- export declare const useToast: () => ToastContextProps;
15
- export { ToastContext, ToastProvider };
1
+ import React, { ReactNode } from 'react';
2
+ import { IToast } from './Toast';
3
+ interface ToastContextProps {
4
+ toasts: {
5
+ [id: string]: IToast;
6
+ };
7
+ pop: (toast: IToast) => void;
8
+ drop: (id: string) => void;
9
+ }
10
+ declare const ToastContext: React.Context<ToastContextProps | undefined>;
11
+ declare function ToastProvider({ children }: {
12
+ children: ReactNode;
13
+ }): import("react/jsx-runtime").JSX.Element;
14
+ export declare const useToast: () => ToastContextProps;
15
+ export { ToastContext, ToastProvider };
@@ -1,18 +1,18 @@
1
- import { IToastDetailItem } from './types';
2
- import { TToastVariant } from '../../../enums/variant';
3
- import './toast.scss';
4
- export interface ToastStyleProps {
5
- variant: TToastVariant;
6
- content: string;
7
- title?: {
8
- main: string;
9
- sub?: string;
10
- };
11
- closeButton?: {
12
- content: string;
13
- onClick: () => void;
14
- };
15
- details?: IToastDetailItem[];
16
- onClose: () => void;
17
- }
18
- export declare function ToastStyle({ variant, content, title, closeButton, details, onClose, }: ToastStyleProps): import("react/jsx-runtime").JSX.Element;
1
+ import { IToastDetailItem } from './types';
2
+ import { TToastVariant } from '../../../enums/variant';
3
+ import './toast.scss';
4
+ export interface ToastStyleProps {
5
+ variant: TToastVariant;
6
+ content: string;
7
+ title?: {
8
+ main: string;
9
+ sub?: string;
10
+ };
11
+ closeButton?: {
12
+ content: string;
13
+ onClick: () => void;
14
+ };
15
+ details?: IToastDetailItem[];
16
+ onClose: () => void;
17
+ }
18
+ export declare function ToastStyle({ variant, content, title, closeButton, details, onClose, }: ToastStyleProps): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- export * from './Toast';
1
+ export * from './Toast';
@@ -1,4 +1,4 @@
1
- export interface IToastDetailItem {
2
- summary: string;
3
- subDetails: string[];
4
- }
1
+ export interface IToastDetailItem {
2
+ summary: string;
3
+ subDetails: string[];
4
+ }
@@ -1,10 +1,10 @@
1
- import React from 'react';
2
- import { TTheme } from '../../enums/color';
3
- import './reset.scss';
4
- import './style-provider.scss';
5
- interface Props {
6
- children: React.ReactNode;
7
- theme: TTheme;
8
- }
9
- export declare function StyleProvider({ children, theme }: Props): import("react/jsx-runtime").JSX.Element;
10
- export {};
1
+ import React from 'react';
2
+ import { TTheme } from '../../enums/color';
3
+ import './reset.scss';
4
+ import './style-provider.scss';
5
+ interface Props {
6
+ children: React.ReactNode;
7
+ theme: TTheme;
8
+ }
9
+ export declare function StyleProvider({ children, theme }: Props): import("react/jsx-runtime").JSX.Element;
10
+ export {};
@@ -1 +1 @@
1
- export * from './StyleProvider';
1
+ export * from './StyleProvider';
@@ -1,14 +1,14 @@
1
- export type TTheme = 'blue' | 'green' | 'navy';
2
- declare const DColor: {
3
- readonly primary: "var(--p)";
4
- readonly secondary: "#8c8c8c";
5
- readonly positive: "#32a483";
6
- readonly warning: "#ffb020";
7
- readonly danger: "#e53e3e";
8
- readonly success: "#308acc";
9
- };
10
- export declare const COLORS: string[];
11
- export type TColor = (typeof COLORS)[number];
12
- export { DColor };
13
- export declare const RADIO_COLORS: readonly ["default", "primary"];
14
- export type TRadioColor = (typeof RADIO_COLORS)[number];
1
+ export type TTheme = 'blue' | 'green' | 'navy';
2
+ declare const DColor: {
3
+ readonly primary: "var(--p)";
4
+ readonly secondary: "#8c8c8c";
5
+ readonly positive: "#32a483";
6
+ readonly warning: "#ffb020";
7
+ readonly danger: "#e53e3e";
8
+ readonly success: "#308acc";
9
+ };
10
+ export declare const COLORS: string[];
11
+ export type TColor = (typeof COLORS)[number];
12
+ export { DColor };
13
+ export declare const RADIO_COLORS: readonly ["default", "primary"];
14
+ export type TRadioColor = (typeof RADIO_COLORS)[number];
@@ -1,2 +1,2 @@
1
- export declare const DIRECTIONS: readonly ["top-start", "top", "top-end", "left-start", "left", "left-end", "bottom-start", "bottom", "bottom-end", "right-start", "right", "right-end"];
2
- export type TDirection = (typeof DIRECTIONS)[number];
1
+ export declare const DIRECTIONS: readonly ["top-start", "top", "top-end", "left-start", "left", "left-end", "bottom-start", "bottom", "bottom-end", "right-start", "right", "right-end"];
2
+ export type TDirection = (typeof DIRECTIONS)[number];
@@ -1,4 +1,4 @@
1
- export declare const GAPS: readonly ["8px", "4px", "2px"];
2
- export type TGap = (typeof GAPS)[number];
3
- export declare const TOOLTIP_GAPS: readonly [6, 4, 0];
4
- export type TTooltipGap = (typeof TOOLTIP_GAPS)[number];
1
+ export declare const GAPS: readonly ["8px", "4px", "2px"];
2
+ export type TGap = (typeof GAPS)[number];
3
+ export declare const TOOLTIP_GAPS: readonly [6, 4, 0];
4
+ export type TTooltipGap = (typeof TOOLTIP_GAPS)[number];
@@ -1,8 +1,8 @@
1
- export declare const BUTTON_SIZES: readonly ["small", "normal", "large"];
2
- export type TButtonSize = (typeof BUTTON_SIZES)[number];
3
- export declare const CHECKBOX_SIZES: readonly [16, 18, 24];
4
- export type TCheckboxSize = (typeof CHECKBOX_SIZES)[number];
5
- export declare const CHIP_SIZES: readonly ["small", "normal"];
6
- export type TChipSize = (typeof CHIP_SIZES)[number];
7
- export declare const MODAL_SIZES: readonly ["xs", "s", "m", "l", "xl"];
8
- export type TModalSize = (typeof MODAL_SIZES)[number];
1
+ export declare const BUTTON_SIZES: readonly ["small", "normal", "large"];
2
+ export type TButtonSize = (typeof BUTTON_SIZES)[number];
3
+ export declare const CHECKBOX_SIZES: readonly [16, 18, 24];
4
+ export type TCheckboxSize = (typeof CHECKBOX_SIZES)[number];
5
+ export declare const CHIP_SIZES: readonly ["small", "normal"];
6
+ export type TChipSize = (typeof CHIP_SIZES)[number];
7
+ export declare const MODAL_SIZES: readonly ["xs", "s", "m", "l", "xl"];
8
+ export type TModalSize = (typeof MODAL_SIZES)[number];
@@ -1,4 +1,4 @@
1
- export declare const INPUT_TYPES: readonly ["text", "password", "number", "date", "time", "datetime"];
2
- export type TInputType = (typeof INPUT_TYPES)[number];
3
- export declare const DROPDOWN_TYPES: readonly ["button", "search"];
4
- export type TDropdownType = (typeof DROPDOWN_TYPES)[number];
1
+ export declare const INPUT_TYPES: readonly ["text", "password", "number", "date", "time", "datetime"];
2
+ export type TInputType = (typeof INPUT_TYPES)[number];
3
+ export declare const DROPDOWN_TYPES: readonly ["button", "search"];
4
+ export type TDropdownType = (typeof DROPDOWN_TYPES)[number];
@@ -1,8 +1,8 @@
1
- export declare const BUTTON_VARIANTS: readonly ["default", "default-light", "outline", "text", "color-on-focus"];
2
- export type TButtonVariant = (typeof BUTTON_VARIANTS)[number];
3
- export declare const CHIP_VARIANTS: readonly ["default", "outline", "dot"];
4
- export type TChipVariant = (typeof CHIP_VARIANTS)[number];
5
- export declare const TOAST_VARIANTS: readonly ["success", "warning", "danger"];
6
- export type TToastVariant = (typeof TOAST_VARIANTS)[number];
7
- export declare const SKELETON_VARIANTS: readonly ["frame"];
8
- export type TSkeletonVariant = (typeof SKELETON_VARIANTS)[number];
1
+ export declare const BUTTON_VARIANTS: readonly ["default", "default-light", "outline", "text", "color-on-focus"];
2
+ export type TButtonVariant = (typeof BUTTON_VARIANTS)[number];
3
+ export declare const CHIP_VARIANTS: readonly ["default", "outline", "dot"];
4
+ export type TChipVariant = (typeof CHIP_VARIANTS)[number];
5
+ export declare const TOAST_VARIANTS: readonly ["success", "warning", "danger"];
6
+ export type TToastVariant = (typeof TOAST_VARIANTS)[number];
7
+ export declare const SKELETON_VARIANTS: readonly ["frame"];
8
+ export type TSkeletonVariant = (typeof SKELETON_VARIANTS)[number];
@@ -1,16 +1,16 @@
1
- /// <reference types="react" />
2
- /**
3
- * 버튼 hover/active 상태를 추적할 때 사용.
4
- */
5
- interface IButtonState {
6
- isHover: boolean;
7
- isActive: boolean;
8
- }
9
- declare function useButtonState(): [
10
- IButtonState,
11
- {
12
- setIsHover: React.Dispatch<React.SetStateAction<boolean>>;
13
- setIsActive: React.Dispatch<React.SetStateAction<boolean>>;
14
- }
15
- ];
16
- export default useButtonState;
1
+ /// <reference types="react" />
2
+ /**
3
+ * 버튼 hover/active 상태를 추적할 때 사용.
4
+ */
5
+ interface IButtonState {
6
+ isHover: boolean;
7
+ isActive: boolean;
8
+ }
9
+ declare function useButtonState(): [
10
+ IButtonState,
11
+ {
12
+ setIsHover: React.Dispatch<React.SetStateAction<boolean>>;
13
+ setIsActive: React.Dispatch<React.SetStateAction<boolean>>;
14
+ }
15
+ ];
16
+ export default useButtonState;
@@ -1,4 +1,4 @@
1
- declare const useColor: (color?: string) => {
2
- keyColor: "var(--p)" | "#8c8c8c" | "#32a483" | "#ffb020" | "#e53e3e" | "#308acc";
3
- };
4
- export default useColor;
1
+ declare const useColor: (color?: string) => {
2
+ keyColor: "var(--p)" | "#8c8c8c" | "#32a483" | "#ffb020" | "#e53e3e" | "#308acc";
3
+ };
4
+ export default useColor;
@@ -1,11 +1,11 @@
1
- import { Ref } from 'react';
2
- /**
3
- * 파라미터로 들어온 ref들을 generic type을 가진 ref로 바꾸는 hook
4
- * ex. refs(주로 부모 refs)가 HTMLInputElement인 RefObject일 때,
5
- * combineRef를 선언한 컴포넌트의 ref<T>로 바꿀때 사용.
6
- * 참고 : RefObejct는 default로 null을 가지고, MutableRefObject는 그 외 다른 값을 가짐
7
- * @param refs RefObject or function
8
- * @returns RefObject
9
- */
10
- declare const useCombineRef: <T>(...refs: (Ref<T> | undefined)[]) => import("react").RefObject<T>;
11
- export default useCombineRef;
1
+ import { Ref } from 'react';
2
+ /**
3
+ * 파라미터로 들어온 ref들을 generic type을 가진 ref로 바꾸는 hook
4
+ * ex. refs(주로 부모 refs)가 HTMLInputElement인 RefObject일 때,
5
+ * combineRef를 선언한 컴포넌트의 ref<T>로 바꿀때 사용.
6
+ * 참고 : RefObejct는 default로 null을 가지고, MutableRefObject는 그 외 다른 값을 가짐
7
+ * @param refs RefObject or function
8
+ * @returns RefObject
9
+ */
10
+ declare const useCombineRef: <T>(...refs: (Ref<T> | undefined)[]) => import("react").RefObject<T>;
11
+ export default useCombineRef;
@@ -1,7 +1,7 @@
1
- import React from 'react';
2
- interface CreatePortalProps {
3
- parent?: HTMLElement;
4
- children: React.ReactNode;
5
- }
6
- declare function CreatePortal({ parent, children }: CreatePortalProps): React.ReactPortal | null;
7
- export { CreatePortal };
1
+ import React from 'react';
2
+ interface CreatePortalProps {
3
+ parent?: HTMLElement;
4
+ children: React.ReactNode;
5
+ }
6
+ declare function CreatePortal({ parent, children }: CreatePortalProps): React.ReactPortal | null;
7
+ export { CreatePortal };
@@ -1,7 +1,7 @@
1
- /**
2
- * 최대 32자리의 uuid를 생성합니다.
3
- * @param length 1 <= lenght <= 32 or undefined
4
- * @returns uuid
5
- */
6
- declare function uuidv4(length?: number): string;
7
- export default uuidv4;
1
+ /**
2
+ * 최대 32자리의 uuid를 생성합니다.
3
+ * @param length 1 <= lenght <= 32 or undefined
4
+ * @returns uuid
5
+ */
6
+ declare function uuidv4(length?: number): string;
7
+ export default uuidv4;