@bsol-oss/react-datatable5 13.0.1-beta.0 → 13.0.1-beta.10
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.d.ts +71 -21
- package/dist/index.js +2119 -1250
- package/dist/index.mjs +2122 -1254
- package/dist/types/components/DatePicker/Calendar.d.ts +2 -0
- package/dist/types/components/DatePicker/DatePicker.d.ts +27 -0
- package/dist/types/components/DatePicker/DateTimePicker.d.ts +20 -4
- package/dist/types/components/DatePicker/UniversalPicker.d.ts +2 -3
- package/dist/types/components/DatePicker/index.d.ts +1 -2
- package/dist/types/components/Form/SchemaFormContext.d.ts +0 -1
- package/dist/types/components/Form/components/core/FormRoot.d.ts +1 -2
- package/dist/types/components/Form/components/fields/FilePicker.d.ts +1 -1
- package/dist/types/components/Form/components/fields/TagPicker.d.ts +1 -1
- package/dist/types/components/Form/components/fields/useIdPickerData.d.ts +8 -2
- package/dist/types/components/Form/components/types/CustomJSONSchema7.d.ts +43 -0
- package/dist/types/components/Form/components/viewers/EnumViewer.d.ts +1 -1
- package/dist/types/components/Form/components/viewers/TagViewer.d.ts +1 -1
- package/dist/types/components/Form/utils/getTableData.d.ts +1 -2
- package/dist/types/components/Form/utils/useFormI18n.d.ts +14 -30
- package/dist/types/components/TimePicker/TimePicker.d.ts +39 -10
- package/dist/types/index.d.ts +0 -1
- package/package.json +7 -4
- package/dist/types/components/DatePicker/DatePickerInput.d.ts +0 -18
- package/dist/types/components/DatePicker/IsoTimePicker.d.ts +0 -24
|
@@ -30,6 +30,9 @@ export interface DatePickerProps {
|
|
|
30
30
|
weekdayNamesShort: string[];
|
|
31
31
|
backButtonLabel?: string;
|
|
32
32
|
forwardButtonLabel?: string;
|
|
33
|
+
todayLabel?: string;
|
|
34
|
+
yesterdayLabel?: string;
|
|
35
|
+
tomorrowLabel?: string;
|
|
33
36
|
};
|
|
34
37
|
render?: (calendarData: CalendarRenderProps) => React.ReactNode;
|
|
35
38
|
}
|
|
@@ -38,6 +41,30 @@ export interface DatePickerLabels {
|
|
|
38
41
|
weekdayNamesShort: string[];
|
|
39
42
|
backButtonLabel?: string;
|
|
40
43
|
forwardButtonLabel?: string;
|
|
44
|
+
todayLabel?: string;
|
|
45
|
+
yesterdayLabel?: string;
|
|
46
|
+
tomorrowLabel?: string;
|
|
41
47
|
}
|
|
48
|
+
export declare const DatePickerContext: React.Context<{
|
|
49
|
+
labels: DatePickerLabels;
|
|
50
|
+
}>;
|
|
42
51
|
declare const DatePicker: React.FC<DatePickerProps>;
|
|
43
52
|
export default DatePicker;
|
|
53
|
+
export interface DatePickerInputProps {
|
|
54
|
+
value?: string | Date;
|
|
55
|
+
onChange?: (date?: string) => void;
|
|
56
|
+
placeholder?: string;
|
|
57
|
+
dateFormat?: string;
|
|
58
|
+
displayFormat?: string;
|
|
59
|
+
labels?: DatePickerLabels;
|
|
60
|
+
timezone?: string;
|
|
61
|
+
minDate?: Date;
|
|
62
|
+
maxDate?: Date;
|
|
63
|
+
firstDayOfWeek?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
64
|
+
showOutsideDays?: boolean;
|
|
65
|
+
monthsToDisplay?: number;
|
|
66
|
+
insideDialog?: boolean;
|
|
67
|
+
readOnly?: boolean;
|
|
68
|
+
showHelperButtons?: boolean;
|
|
69
|
+
}
|
|
70
|
+
export declare function DatePickerInput({ value, onChange, placeholder, dateFormat, displayFormat, labels, timezone, minDate, maxDate, firstDayOfWeek, showOutsideDays, monthsToDisplay, insideDialog, readOnly, showHelperButtons, }: DatePickerInputProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,17 +1,33 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { TimePickerLabels } from '../Form/components/types/CustomJSONSchema7';
|
|
1
|
+
import { DateTimePickerLabels, TimePickerLabels } from '../Form/components/types/CustomJSONSchema7';
|
|
3
2
|
interface DateTimePickerProps {
|
|
4
3
|
value?: string;
|
|
5
4
|
onChange?: (date?: string) => void;
|
|
6
5
|
format?: 'date-time' | 'iso-date-time';
|
|
7
6
|
showSeconds?: boolean;
|
|
8
|
-
labels?:
|
|
7
|
+
labels?: DateTimePickerLabels;
|
|
9
8
|
timePickerLabels?: TimePickerLabels;
|
|
10
9
|
timezone?: string;
|
|
11
10
|
startTime?: string;
|
|
12
11
|
minDate?: Date;
|
|
13
12
|
maxDate?: Date;
|
|
14
13
|
portalled?: boolean;
|
|
14
|
+
defaultDate?: string;
|
|
15
|
+
defaultTime?: {
|
|
16
|
+
hour: number | null;
|
|
17
|
+
minute: number | null;
|
|
18
|
+
second?: number | null;
|
|
19
|
+
meridiem?: 'am' | 'pm' | null;
|
|
20
|
+
};
|
|
21
|
+
showQuickActions?: boolean;
|
|
22
|
+
quickActionLabels?: {
|
|
23
|
+
yesterday?: string;
|
|
24
|
+
today?: string;
|
|
25
|
+
tomorrow?: string;
|
|
26
|
+
plus7Days?: string;
|
|
27
|
+
};
|
|
28
|
+
showTimezoneSelector?: boolean;
|
|
29
|
+
timezoneOffset?: string;
|
|
30
|
+
onTimezoneOffsetChange?: (offset: string) => void;
|
|
15
31
|
}
|
|
16
|
-
export declare function DateTimePicker({ value, onChange, format, showSeconds, labels, timePickerLabels, timezone, startTime, minDate, maxDate, portalled, }: DateTimePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
32
|
+
export declare function DateTimePicker({ value, onChange, format, showSeconds, labels, timePickerLabels, timezone: tz, startTime, minDate, maxDate, portalled, defaultDate, defaultTime, showQuickActions, quickActionLabels, showTimezoneSelector, timezoneOffset: controlledTimezoneOffset, onTimezoneOffsetChange, }: DateTimePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
17
33
|
export {};
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
type FormatType =
|
|
1
|
+
type FormatType = 'date' | 'time' | 'date-time' | 'iso-time' | 'iso-date-time' | 'duration';
|
|
2
2
|
interface UniversalPickerProps {
|
|
3
3
|
format: FormatType;
|
|
4
4
|
value?: string | null;
|
|
5
5
|
onChange?: (value: string | null) => void;
|
|
6
|
-
placeholder?: string;
|
|
7
6
|
}
|
|
8
|
-
export declare function UniversalPicker({ format, value, onChange,
|
|
7
|
+
export declare function UniversalPicker({ format, value, onChange, }: UniversalPickerProps): import("react/jsx-runtime").JSX.Element;
|
|
9
8
|
export {};
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
export { default as DatePicker } from './DatePicker';
|
|
2
2
|
export { TimePicker } from '../TimePicker/TimePicker';
|
|
3
|
-
export { IsoTimePicker } from './IsoTimePicker';
|
|
4
3
|
export { DateTimePicker } from './DateTimePicker';
|
|
5
4
|
export { DurationPicker } from './DurationPicker';
|
|
6
5
|
export { UniversalPicker } from './UniversalPicker';
|
|
7
|
-
export { DatePickerInput } from './
|
|
6
|
+
export { DatePickerInput } from './DatePicker';
|
|
8
7
|
export type { DatePickerProps, CalendarProps, GetDateColorProps, GetVariantProps, } from './DatePicker';
|
|
@@ -6,7 +6,6 @@ import { Translate } from './useForm';
|
|
|
6
6
|
import { DateTimePickerLabels, IdPickerLabels, EnumPickerLabels, FilePickerLabels, FormButtonLabels, TimePickerLabels } from './components/types/CustomJSONSchema7';
|
|
7
7
|
export interface SchemaFormContext<TData extends FieldValues> {
|
|
8
8
|
schema: JSONSchema7;
|
|
9
|
-
serverUrl: string;
|
|
10
9
|
requestUrl: string;
|
|
11
10
|
order: string[];
|
|
12
11
|
ignore: string[];
|
|
@@ -7,7 +7,6 @@ import { Translate } from '../../useForm';
|
|
|
7
7
|
import { CustomJSONSchema7, DateTimePickerLabels, IdPickerLabels, EnumPickerLabels, FilePickerLabels, FormButtonLabels, TimePickerLabels } from '../types/CustomJSONSchema7';
|
|
8
8
|
export interface FormRootProps<TData extends FieldValues> {
|
|
9
9
|
schema: CustomJSONSchema7;
|
|
10
|
-
serverUrl: string;
|
|
11
10
|
requestUrl?: string;
|
|
12
11
|
idMap: Record<string, object>;
|
|
13
12
|
setIdMap: Dispatch<SetStateAction<Record<string, object>>>;
|
|
@@ -51,4 +50,4 @@ export declare const idPickerSanityCheck: (column: string, foreign_key?: {
|
|
|
51
50
|
table?: string | undefined;
|
|
52
51
|
column?: string | undefined;
|
|
53
52
|
} | undefined) => void;
|
|
54
|
-
export declare const FormRoot: <TData extends FieldValues>({ schema, idMap, setIdMap, form,
|
|
53
|
+
export declare const FormRoot: <TData extends FieldValues>({ schema, idMap, setIdMap, form, translate, children, order, ignore, include, onSubmit, rowNumber, requestOptions, getUpdatedData, customErrorRenderer, customSuccessRenderer, displayConfig, requireConfirmation, dateTimePickerLabels, idPickerLabels, enumPickerLabels, filePickerLabels, formButtonLabels, timePickerLabels, insideDialog, }: FormRootProps<TData>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -12,6 +12,6 @@ interface MediaBrowserDialogProps {
|
|
|
12
12
|
labels?: FilePickerLabels;
|
|
13
13
|
colLabel: string;
|
|
14
14
|
}
|
|
15
|
-
export declare function MediaBrowserDialog({ open, onClose, onSelect, title, filterImageOnly, onFetchFiles, onUploadFile, enableUpload, labels,
|
|
15
|
+
export declare function MediaBrowserDialog({ open, onClose, onSelect, title, filterImageOnly, onFetchFiles, onUploadFile, enableUpload, labels, }: MediaBrowserDialogProps): import("react/jsx-runtime").JSX.Element | null;
|
|
16
16
|
export declare const FilePicker: ({ column, schema, prefix }: InputDefaultProps) => import("react/jsx-runtime").JSX.Element;
|
|
17
17
|
export {};
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
import { CustomJSONSchema7 } from '../types/CustomJSONSchema7';
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { CustomJSONSchema7, LoadInitialValuesParams, LoadInitialValuesResult } from '../types/CustomJSONSchema7';
|
|
3
3
|
export interface RecordType {
|
|
4
4
|
[key: string]: any;
|
|
5
5
|
}
|
|
6
|
+
export type { LoadInitialValuesParams, LoadInitialValuesResult, } from '../types/CustomJSONSchema7';
|
|
6
7
|
export interface UseIdPickerDataProps {
|
|
7
8
|
column: string;
|
|
8
9
|
schema: CustomJSONSchema7;
|
|
@@ -25,6 +26,7 @@ export interface UseIdPickerDataReturn {
|
|
|
25
26
|
missingIds: string[];
|
|
26
27
|
comboboxItems: Array<{
|
|
27
28
|
label: string;
|
|
29
|
+
displayLabel: string;
|
|
28
30
|
value: string;
|
|
29
31
|
raw: RecordType;
|
|
30
32
|
}>;
|
|
@@ -32,6 +34,7 @@ export interface UseIdPickerDataReturn {
|
|
|
32
34
|
filter: (text: string) => void;
|
|
33
35
|
set: (items: Array<{
|
|
34
36
|
label: string;
|
|
37
|
+
displayLabel: string;
|
|
35
38
|
value: string;
|
|
36
39
|
raw: RecordType;
|
|
37
40
|
}>) => void;
|
|
@@ -39,6 +42,9 @@ export interface UseIdPickerDataReturn {
|
|
|
39
42
|
idPickerLabels: any;
|
|
40
43
|
insideDialog: boolean;
|
|
41
44
|
renderDisplay: ((item: RecordType) => React.ReactNode) | undefined;
|
|
45
|
+
itemToValue: (item: RecordType) => string;
|
|
46
|
+
itemToString: (item: RecordType) => string;
|
|
47
|
+
loadInitialValues: (params: LoadInitialValuesParams) => Promise<LoadInitialValuesResult>;
|
|
42
48
|
column_ref: string;
|
|
43
49
|
errors: any;
|
|
44
50
|
setValue: (name: string, value: any) => void;
|
|
@@ -3,6 +3,7 @@ import { ReactNode } from 'react';
|
|
|
3
3
|
import { ForeignKeyProps } from '../fields/StringInputField';
|
|
4
4
|
import { UseFormReturn } from 'react-hook-form';
|
|
5
5
|
import { ValidationErrorType } from '../../utils/buildErrorMessages';
|
|
6
|
+
import React from 'react';
|
|
6
7
|
export interface DateTimePickerLabels {
|
|
7
8
|
monthNamesShort?: string[];
|
|
8
9
|
weekdayNamesShort?: string[];
|
|
@@ -60,12 +61,26 @@ export interface TimePickerLabels {
|
|
|
60
61
|
placeholder?: string;
|
|
61
62
|
emptyMessage?: string;
|
|
62
63
|
}
|
|
64
|
+
export interface LoadInitialValuesParams {
|
|
65
|
+
ids: string[];
|
|
66
|
+
foreign_key: ForeignKeyProps;
|
|
67
|
+
setIdMap: React.Dispatch<React.SetStateAction<Record<string, object>>>;
|
|
68
|
+
}
|
|
69
|
+
export interface LoadInitialValuesResult {
|
|
70
|
+
data: {
|
|
71
|
+
data: Record<string, any>[];
|
|
72
|
+
count: number;
|
|
73
|
+
};
|
|
74
|
+
idMap: Record<string, object>;
|
|
75
|
+
}
|
|
63
76
|
export interface CustomJSONSchema7 extends JSONSchema7 {
|
|
64
77
|
gridColumn?: string;
|
|
65
78
|
gridRow?: string;
|
|
66
79
|
foreign_key?: ForeignKeyProps;
|
|
67
80
|
variant?: string;
|
|
68
81
|
renderDisplay?: (item: unknown) => ReactNode;
|
|
82
|
+
itemToValue?: (item: unknown) => string;
|
|
83
|
+
loadInitialValues?: (params: LoadInitialValuesParams) => Promise<LoadInitialValuesResult>;
|
|
69
84
|
inputRender?: (props: {
|
|
70
85
|
column: string;
|
|
71
86
|
schema: CustomJSONSchema7;
|
|
@@ -87,6 +102,34 @@ export interface CustomJSONSchema7 extends JSONSchema7 {
|
|
|
87
102
|
numberStorageType?: 'string' | 'number';
|
|
88
103
|
errorMessages?: Partial<Record<ValidationErrorType | string, string>>;
|
|
89
104
|
filePicker?: FilePickerProps;
|
|
105
|
+
tagPicker?: {
|
|
106
|
+
queryFn?: (params: {
|
|
107
|
+
in_table: string;
|
|
108
|
+
where?: {
|
|
109
|
+
id: string;
|
|
110
|
+
value: string[];
|
|
111
|
+
}[];
|
|
112
|
+
limit?: number;
|
|
113
|
+
offset?: number;
|
|
114
|
+
searching?: string;
|
|
115
|
+
}) => Promise<{
|
|
116
|
+
data: {
|
|
117
|
+
data: any[];
|
|
118
|
+
count: number;
|
|
119
|
+
};
|
|
120
|
+
idMap?: Record<string, object>;
|
|
121
|
+
}>;
|
|
122
|
+
};
|
|
123
|
+
dateTimePicker?: {
|
|
124
|
+
showQuickActions?: boolean;
|
|
125
|
+
quickActionLabels?: {
|
|
126
|
+
yesterday?: string;
|
|
127
|
+
today?: string;
|
|
128
|
+
tomorrow?: string;
|
|
129
|
+
plus7Days?: string;
|
|
130
|
+
};
|
|
131
|
+
showTimezoneSelector?: boolean;
|
|
132
|
+
};
|
|
90
133
|
}
|
|
91
134
|
export declare const defaultRenderDisplay: (item: unknown) => ReactNode;
|
|
92
135
|
export interface TagPickerProps {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
export interface GetTableDataConfig {
|
|
2
|
-
serverUrl: string;
|
|
3
2
|
in_table: string;
|
|
4
3
|
limit?: number;
|
|
5
4
|
offset?: number;
|
|
@@ -13,4 +12,4 @@ export interface GetTableResponse {
|
|
|
13
12
|
data?: object[];
|
|
14
13
|
count: number;
|
|
15
14
|
}
|
|
16
|
-
export declare const getTableData: ({
|
|
15
|
+
export declare const getTableData: ({ in_table, searching, where, limit, offset, }: GetTableDataConfig) => Promise<never>;
|
|
@@ -1,57 +1,41 @@
|
|
|
1
|
+
import { CustomJSONSchema7 } from '../components/types/CustomJSONSchema7';
|
|
1
2
|
/**
|
|
2
|
-
* Custom hook for form field labels
|
|
3
|
-
* Automatically handles colLabel construction
|
|
4
|
-
* Uses schema.title
|
|
3
|
+
* Custom hook for form field labels.
|
|
4
|
+
* Automatically handles colLabel construction.
|
|
5
|
+
* Uses schema.title for labels and schema.errorMessages for error messages.
|
|
5
6
|
*
|
|
6
7
|
* @param column - The column name
|
|
7
8
|
* @param prefix - The prefix for the field (usually empty string or parent path)
|
|
8
|
-
* @param schema -
|
|
9
|
+
* @param schema - Required schema object with title and errorMessages properties
|
|
9
10
|
* @returns Object with label helper functions
|
|
10
11
|
*
|
|
11
12
|
* @example
|
|
12
13
|
* ```tsx
|
|
13
14
|
* const formI18n = useFormI18n(column, prefix, schema);
|
|
14
15
|
*
|
|
15
|
-
* // Get field label (
|
|
16
|
+
* // Get field label (from schema.title)
|
|
16
17
|
* <Field label={formI18n.label()} />
|
|
17
18
|
*
|
|
18
|
-
* // Get required error message
|
|
19
|
+
* // Get required error message (from schema.errorMessages?.required)
|
|
19
20
|
* <Text>{formI18n.required()}</Text>
|
|
20
21
|
*
|
|
21
|
-
* // Get custom text
|
|
22
|
-
* <Text>{formI18n.t('add_more')}</Text>
|
|
23
|
-
*
|
|
24
22
|
* // Access the raw colLabel
|
|
25
23
|
* const colLabel = formI18n.colLabel;
|
|
26
24
|
* ```
|
|
27
25
|
*/
|
|
28
|
-
export declare const useFormI18n: (column: string, prefix
|
|
29
|
-
title?: string;
|
|
30
|
-
}) => {
|
|
26
|
+
export declare const useFormI18n: (column: string, prefix: string | undefined, schema: CustomJSONSchema7) => {
|
|
31
27
|
/**
|
|
32
28
|
* The constructed column label (prefix + column)
|
|
33
29
|
*/
|
|
34
30
|
colLabel: string;
|
|
35
31
|
/**
|
|
36
|
-
* Get the field label from schema title
|
|
37
|
-
*
|
|
38
|
-
*/
|
|
39
|
-
label: (options?: any) => string;
|
|
40
|
-
/**
|
|
41
|
-
* Get the required error message
|
|
42
|
-
* Equivalent to: translate.t(removeIndex(`${colLabel}.field_required`))
|
|
43
|
-
*/
|
|
44
|
-
required: (options?: any) => string;
|
|
45
|
-
/**
|
|
46
|
-
* Get text for any custom key relative to the field
|
|
47
|
-
* Equivalent to: translate.t(removeIndex(`${colLabel}.${key}`))
|
|
48
|
-
*
|
|
49
|
-
* @param key - The key suffix (e.g., 'add_more', 'total', etc.)
|
|
50
|
-
* @param options - Optional options (e.g., defaultValue, interpolation variables)
|
|
32
|
+
* Get the field label from schema title property.
|
|
33
|
+
* Logs a debug message if title is missing.
|
|
51
34
|
*/
|
|
52
|
-
|
|
35
|
+
label: () => string;
|
|
53
36
|
/**
|
|
54
|
-
*
|
|
37
|
+
* Get the required error message from schema.errorMessages?.required.
|
|
38
|
+
* Returns a helpful fallback message if not provided.
|
|
55
39
|
*/
|
|
56
|
-
|
|
40
|
+
required: () => string;
|
|
57
41
|
};
|
|
@@ -1,13 +1,18 @@
|
|
|
1
1
|
import { Dispatch, SetStateAction } from 'react';
|
|
2
2
|
import { TimePickerLabels } from '../Form/components/types/CustomJSONSchema7';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
3
|
+
type TimePickerProps12h = {
|
|
4
|
+
format?: '12h';
|
|
5
|
+
value?: string;
|
|
6
|
+
onChange?: (value: string | undefined) => void;
|
|
7
|
+
hour?: number | null;
|
|
8
|
+
setHour?: Dispatch<SetStateAction<number | null>>;
|
|
9
|
+
minute?: number | null;
|
|
10
|
+
setMinute?: Dispatch<SetStateAction<number | null>>;
|
|
11
|
+
meridiem?: 'am' | 'pm' | null;
|
|
12
|
+
setMeridiem?: Dispatch<SetStateAction<'am' | 'pm' | null>>;
|
|
13
|
+
second?: never;
|
|
14
|
+
setSecond?: never;
|
|
15
|
+
onTimeChange?: (newValue: {
|
|
11
16
|
hour: number | null;
|
|
12
17
|
minute: number | null;
|
|
13
18
|
meridiem: 'am' | 'pm' | null;
|
|
@@ -17,6 +22,30 @@ interface TimePickerProps {
|
|
|
17
22
|
timezone?: string;
|
|
18
23
|
portalled?: boolean;
|
|
19
24
|
labels?: TimePickerLabels;
|
|
20
|
-
}
|
|
21
|
-
|
|
25
|
+
};
|
|
26
|
+
type TimePickerProps24h = {
|
|
27
|
+
format: '24h';
|
|
28
|
+
value?: string;
|
|
29
|
+
onChange?: (value: string | undefined) => void;
|
|
30
|
+
hour?: number | null;
|
|
31
|
+
setHour?: Dispatch<SetStateAction<number | null>>;
|
|
32
|
+
minute?: number | null;
|
|
33
|
+
setMinute?: Dispatch<SetStateAction<number | null>>;
|
|
34
|
+
second?: number | null;
|
|
35
|
+
setSecond?: Dispatch<SetStateAction<number | null>>;
|
|
36
|
+
meridiem?: never;
|
|
37
|
+
setMeridiem?: never;
|
|
38
|
+
onTimeChange?: (newValue: {
|
|
39
|
+
hour: number | null;
|
|
40
|
+
minute: number | null;
|
|
41
|
+
second: number | null;
|
|
42
|
+
}) => void;
|
|
43
|
+
startTime?: string;
|
|
44
|
+
selectedDate?: string;
|
|
45
|
+
timezone?: string;
|
|
46
|
+
portalled?: boolean;
|
|
47
|
+
labels?: TimePickerLabels;
|
|
48
|
+
};
|
|
49
|
+
export type TimePickerProps = TimePickerProps12h | TimePickerProps24h;
|
|
50
|
+
export declare const TimePicker: (props: TimePickerProps) => import("react/jsx-runtime").JSX.Element;
|
|
22
51
|
export {};
|
package/dist/types/index.d.ts
CHANGED
|
@@ -126,7 +126,6 @@ export * from './components/DatePicker/DatePicker';
|
|
|
126
126
|
export * from './components/DatePicker/getMultiDates';
|
|
127
127
|
export * from './components/DatePicker/getRangeDates';
|
|
128
128
|
export * from './components/DatePicker/RangeDatePicker';
|
|
129
|
-
export * from './components/DatePicker/DatePickerInput';
|
|
130
129
|
export * from './components/DataTable/display/RecordDisplay';
|
|
131
130
|
export * from './components/DataTable/display/TableDataDisplay';
|
|
132
131
|
export * from './components/DataTable/DefaultTable';
|
package/package.json
CHANGED
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bsol-oss/react-datatable5",
|
|
3
|
-
"version": "13.0.1-beta.
|
|
3
|
+
"version": "13.0.1-beta.10",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"module": "dist/index.mjs",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
8
|
-
"repository":
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "git+https://github.com/bsol-oss/react-datatable5.git"
|
|
11
|
+
},
|
|
9
12
|
"homepage": "https://github.com/bsol-oss/react-datatable5#react-datatable5",
|
|
10
13
|
"author": "screw123",
|
|
11
14
|
"license": "MIT",
|
|
@@ -46,7 +49,7 @@
|
|
|
46
49
|
"ajv": "^8.12.0",
|
|
47
50
|
"ajv-errors": "^3.0.0",
|
|
48
51
|
"ajv-formats": "^3.0.1",
|
|
49
|
-
"axios": "^1.
|
|
52
|
+
"axios": "^1.13.2",
|
|
50
53
|
"dayjs": "^1.11.13",
|
|
51
54
|
"next-themes": "^0.4.4",
|
|
52
55
|
"react": "^19.0.0",
|
|
@@ -80,7 +83,7 @@
|
|
|
80
83
|
"lint-staged": "^16.2.5",
|
|
81
84
|
"prettier": "3.2.5",
|
|
82
85
|
"rollup-plugin-dts": "^6.1.0",
|
|
83
|
-
"storybook": "^10.
|
|
86
|
+
"storybook": "^10.1.11",
|
|
84
87
|
"typescript": "^5.2.2",
|
|
85
88
|
"vite": "^5.2.0"
|
|
86
89
|
},
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { DatePickerLabels } from './DatePicker';
|
|
2
|
-
export interface DatePickerInputProps {
|
|
3
|
-
value?: string | Date;
|
|
4
|
-
onChange?: (date?: string) => void;
|
|
5
|
-
placeholder?: string;
|
|
6
|
-
dateFormat?: string;
|
|
7
|
-
displayFormat?: string;
|
|
8
|
-
labels?: DatePickerLabels;
|
|
9
|
-
timezone?: string;
|
|
10
|
-
minDate?: Date;
|
|
11
|
-
maxDate?: Date;
|
|
12
|
-
firstDayOfWeek?: 0 | 1 | 2 | 3 | 4 | 5 | 6;
|
|
13
|
-
showOutsideDays?: boolean;
|
|
14
|
-
monthsToDisplay?: number;
|
|
15
|
-
insideDialog?: boolean;
|
|
16
|
-
readOnly?: boolean;
|
|
17
|
-
}
|
|
18
|
-
export declare function DatePickerInput({ value, onChange, placeholder, dateFormat, displayFormat, labels, timezone, minDate, maxDate, firstDayOfWeek, showOutsideDays, monthsToDisplay, insideDialog, readOnly, }: DatePickerInputProps): import("react/jsx-runtime").JSX.Element;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { Dispatch, SetStateAction } from 'react';
|
|
2
|
-
interface IsoTimePickerProps {
|
|
3
|
-
hour: number | null;
|
|
4
|
-
setHour: Dispatch<SetStateAction<number | null>>;
|
|
5
|
-
minute: number | null;
|
|
6
|
-
setMinute: Dispatch<SetStateAction<number | null>>;
|
|
7
|
-
second: number | null;
|
|
8
|
-
setSecond: Dispatch<SetStateAction<number | null>>;
|
|
9
|
-
onChange?: (newValue: {
|
|
10
|
-
hour: number | null;
|
|
11
|
-
minute: number | null;
|
|
12
|
-
second: number | null;
|
|
13
|
-
}) => void;
|
|
14
|
-
startTime?: string;
|
|
15
|
-
selectedDate?: string;
|
|
16
|
-
timezone?: string;
|
|
17
|
-
portalled?: boolean;
|
|
18
|
-
labels?: {
|
|
19
|
-
placeholder?: string;
|
|
20
|
-
emptyMessage?: string;
|
|
21
|
-
};
|
|
22
|
-
}
|
|
23
|
-
export declare function IsoTimePicker({ hour, setHour, minute, setMinute, second, setSecond, onChange, startTime, selectedDate, timezone, portalled, labels, }: IsoTimePickerProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
-
export {};
|