@lawkit/ui 0.1.41 → 0.1.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.css +1 -1
- package/dist/index.js +1933 -1739
- package/dist/ui-v3/src/components/DatePicker/index.d.ts +5 -1
- package/dist/ui-v3/src/components/InputDatePicker/InputDatePicker.css.d.ts +4 -0
- package/dist/ui-v3/src/components/InputDatePicker/index.d.ts +40 -0
- package/dist/ui-v3/src/components/InputDateRangePicker/InputDateRangePicker.css.d.ts +8 -0
- package/dist/ui-v3/src/components/InputDateRangePicker/index.d.ts +48 -0
- package/dist/ui-v3/src/index.d.ts +4 -0
- package/package.json +1 -1
|
@@ -21,6 +21,10 @@ export interface DateRangePickerProps extends Omit<HTMLAttributes<HTMLDivElement
|
|
|
21
21
|
start: Date | null;
|
|
22
22
|
end: Date | null;
|
|
23
23
|
}) => void;
|
|
24
|
+
/** 최소 선택 가능 날짜 */
|
|
25
|
+
minDate?: Date;
|
|
26
|
+
/** 최대 선택 가능 날짜 */
|
|
27
|
+
maxDate?: Date;
|
|
24
28
|
}
|
|
25
29
|
/**
|
|
26
30
|
* **DatePicker**
|
|
@@ -54,4 +58,4 @@ export declare function DatePicker({ value, onChange, showTime, minDate, maxDate
|
|
|
54
58
|
* />
|
|
55
59
|
* ```
|
|
56
60
|
*/
|
|
57
|
-
export declare function DateRangePicker({ startDate, endDate, onChange, className, ...rest }: DateRangePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
61
|
+
export declare function DateRangePicker({ startDate, endDate, onChange, minDate, maxDate, className, ...rest }: DateRangePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'react';
|
|
2
|
+
import { InputSize, InputState } from '../Input';
|
|
3
|
+
/** Date → "yyyy-MM-dd" (빈 값이면 "") */
|
|
4
|
+
export declare const formatYmd: (date: Date | null | undefined) => string;
|
|
5
|
+
export interface InputDatePickerProps extends Omit<HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
|
|
6
|
+
/** 선택된 날짜 */
|
|
7
|
+
value?: Date | null;
|
|
8
|
+
/** 날짜 변경 콜백 */
|
|
9
|
+
onChange?: (date: Date) => void;
|
|
10
|
+
/** placeholder (선택 전 표시) */
|
|
11
|
+
placeholder?: string;
|
|
12
|
+
/** 인풋 사이즈 */
|
|
13
|
+
inputSize?: InputSize;
|
|
14
|
+
/** 인풋 상태 (테두리 색 등) */
|
|
15
|
+
state?: InputState;
|
|
16
|
+
/** 비활성화 */
|
|
17
|
+
disabled?: boolean;
|
|
18
|
+
/** 최소 선택 가능 날짜 */
|
|
19
|
+
minDate?: Date;
|
|
20
|
+
/** 최대 선택 가능 날짜 */
|
|
21
|
+
maxDate?: Date;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* **InputDatePicker** (프로토타입)
|
|
25
|
+
*
|
|
26
|
+
* Input 박스에 포커스하거나 캘린더 아이콘을 클릭하면 `DatePicker` 캘린더가
|
|
27
|
+
* 팝오버로 펼쳐지는 날짜 선택 컴포넌트.
|
|
28
|
+
*
|
|
29
|
+
* - 포커스 / 클릭 → 캘린더 열림
|
|
30
|
+
* - 날짜 선택 → 인풋에 `yyyy-MM-dd` 표시 후 닫힘
|
|
31
|
+
* - ESC / 바깥 클릭 → 닫힘
|
|
32
|
+
*
|
|
33
|
+
* > ⚠️ 아직 정식 export 컴포넌트가 아닌 Storybook 검토용 시안입니다.
|
|
34
|
+
*
|
|
35
|
+
* ```tsx
|
|
36
|
+
* const [date, setDate] = useState<Date | null>(null);
|
|
37
|
+
* <InputDatePicker value={date} onChange={setDate} />
|
|
38
|
+
* ```
|
|
39
|
+
*/
|
|
40
|
+
export declare const InputDatePicker: ({ value, onChange, placeholder, inputSize, state, disabled, minDate, maxDate, className, ...rest }: InputDatePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export declare const wrapper: string;
|
|
2
|
+
export declare const rangeTrigger: string;
|
|
3
|
+
export declare const singleTrigger: string;
|
|
4
|
+
export declare const rangeInput: string;
|
|
5
|
+
export declare const singleInput: string;
|
|
6
|
+
export declare const rangeSeparator: string;
|
|
7
|
+
export declare const calendarIcon: string;
|
|
8
|
+
export declare const popover: string;
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { HTMLAttributes } from 'react';
|
|
2
|
+
import { InputSize, InputState } from '../Input';
|
|
3
|
+
export interface InputDateRangePickerProps extends Omit<HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
|
|
4
|
+
startDate?: Date | null;
|
|
5
|
+
endDate?: Date | null;
|
|
6
|
+
onChange?: (range: {
|
|
7
|
+
start: Date | null;
|
|
8
|
+
end: Date | null;
|
|
9
|
+
}) => void;
|
|
10
|
+
placeholder?: string;
|
|
11
|
+
inputSize?: InputSize;
|
|
12
|
+
state?: InputState;
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
minDate?: Date;
|
|
15
|
+
maxDate?: Date;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* **InputDateRangePicker** (프로토타입)
|
|
19
|
+
*
|
|
20
|
+
* 하나의 Input에 `yyyy-MM-dd ~ yyyy-MM-dd` 형태로 범위를 표시하는 기본안입니다.
|
|
21
|
+
*
|
|
22
|
+
* - 포커스 / 클릭 → 캘린더 열림
|
|
23
|
+
* - 시작일/종료일 선택 → 하나의 인풋에 범위 문자열 표시
|
|
24
|
+
* - 종료일 선택 완료 시 닫힘
|
|
25
|
+
* - ESC / 바깥 클릭 → 닫힘
|
|
26
|
+
*/
|
|
27
|
+
export declare const InputDateRangePicker: ({ startDate, endDate, onChange, placeholder, inputSize, state, disabled, minDate, maxDate, className, ...rest }: InputDateRangePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
export interface InputDateRangePickerSplitProps extends Omit<HTMLAttributes<HTMLDivElement>, "onChange" | "defaultValue"> {
|
|
29
|
+
startDate?: Date | null;
|
|
30
|
+
endDate?: Date | null;
|
|
31
|
+
onChange?: (range: {
|
|
32
|
+
start: Date | null;
|
|
33
|
+
end: Date | null;
|
|
34
|
+
}) => void;
|
|
35
|
+
startPlaceholder?: string;
|
|
36
|
+
endPlaceholder?: string;
|
|
37
|
+
inputSize?: InputSize;
|
|
38
|
+
state?: InputState;
|
|
39
|
+
disabled?: boolean;
|
|
40
|
+
minDate?: Date;
|
|
41
|
+
maxDate?: Date;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* **InputDateRangePickerSplit** (프로토타입)
|
|
45
|
+
*
|
|
46
|
+
* Input 2개(시작일/종료일)로 범위를 보여주는 보조 variant입니다.
|
|
47
|
+
*/
|
|
48
|
+
export declare const InputDateRangePickerSplit: ({ startDate, endDate, onChange, startPlaceholder, endPlaceholder, inputSize, state, disabled, minDate, maxDate, className, ...rest }: InputDateRangePickerSplitProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -60,6 +60,10 @@ export { Radio, RadioGroup } from './components/Radio';
|
|
|
60
60
|
export type { RadioProps, RadioSize, RadioVariant, RadioGroupProps, } from './components/Radio';
|
|
61
61
|
export { DatePicker, DateRangePicker } from './components/DatePicker';
|
|
62
62
|
export type { DatePickerProps, DateRangePickerProps, } from './components/DatePicker';
|
|
63
|
+
export { InputDatePicker, formatYmd as formatInputDateYmd, } from './components/InputDatePicker';
|
|
64
|
+
export type { InputDatePickerProps } from './components/InputDatePicker';
|
|
65
|
+
export { InputDateRangePicker, InputDateRangePickerSplit, } from './components/InputDateRangePicker';
|
|
66
|
+
export type { InputDateRangePickerProps, InputDateRangePickerSplitProps, } from './components/InputDateRangePicker';
|
|
63
67
|
export { FileUploadArea, FileThumbnail, FileItem, FileAttachBadge, } from './components/FileUpload';
|
|
64
68
|
export type { FileUploadAreaProps, FileThumbnailProps, FileItemProps, FileAttachBadgeProps, ThumbnailLayout, ThumbnailSize, } from './components/FileUpload';
|
|
65
69
|
export { NumberInput } from './components/NumberInput';
|