@elliemae/ds-date-range-picker 2.3.0-alpha.8 → 2.3.0-alpha.9
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/types/DSDateRangePicker.d.ts +243 -0
- package/dist/types/components/DSDateRangePickerImpl.d.ts +24 -0
- package/dist/types/components/DatePickerLabel/DatePickerLabel.d.ts +6 -0
- package/dist/types/components/DatePickerRangeHeader/DatePickerRangeHeader.d.ts +10 -0
- package/dist/types/components/DayPickerRangeController.d.ts +36 -0
- package/dist/types/index.d.ts +2 -0
- package/dist/types/isMaxDiffSafe.d.ts +2 -0
- package/package.json +6 -6
|
@@ -0,0 +1,243 @@
|
|
|
1
|
+
/// <reference path="../../../../shared/typings/react-desc.d.ts" />
|
|
2
|
+
/// <reference types="react" />
|
|
3
|
+
import moment from 'moment';
|
|
4
|
+
import 'react-dates/initialize';
|
|
5
|
+
import DayPickerRangeController from './components/DayPickerRangeController';
|
|
6
|
+
import { START_DATE, END_DATE } from './components/DSDateRangePickerImpl';
|
|
7
|
+
declare const DSDateRangePicker: {
|
|
8
|
+
({ containerProps, className, disabled, required, startDateRequired, endDateRequired, id, hasError, validationMessage, readOnly, screenReaderInputMessage, initialVisibleMonth, firstDayOfWeek, keepOpenOnDateSelect, reopenPickerOnClearDates, hideKeyboardShortcutsPanel, onPrevMonthClick, onNextMonthClick, onClose, onOutsideClick, transitionDuration, verticalSpacing, minimumNights, isDayBlocked, isOutsideRange, isDayHighlighted, displayFormat, displayFormatDay, phrases, startDate, endDate, startDateId, endDateId, labelFrom, labelTo, enableOutsideDays, onChangeStartInput, onChangeEndInput, onDatesChange, }: {
|
|
9
|
+
containerProps?: {} | undefined;
|
|
10
|
+
className?: string | undefined;
|
|
11
|
+
disabled?: boolean | undefined;
|
|
12
|
+
required?: boolean | undefined;
|
|
13
|
+
startDateRequired?: boolean | undefined;
|
|
14
|
+
endDateRequired?: boolean | undefined;
|
|
15
|
+
id: any;
|
|
16
|
+
hasError?: boolean | undefined;
|
|
17
|
+
validationMessage?: string | undefined;
|
|
18
|
+
readOnly?: boolean | undefined;
|
|
19
|
+
screenReaderInputMessage?: string | undefined;
|
|
20
|
+
initialVisibleMonth?: moment.Moment | undefined;
|
|
21
|
+
firstDayOfWeek?: number | undefined;
|
|
22
|
+
keepOpenOnDateSelect?: boolean | undefined;
|
|
23
|
+
reopenPickerOnClearDates?: boolean | undefined;
|
|
24
|
+
hideKeyboardShortcutsPanel?: boolean | undefined;
|
|
25
|
+
onPrevMonthClick?: (() => null) | undefined;
|
|
26
|
+
onNextMonthClick?: (() => null) | undefined;
|
|
27
|
+
onClose?: (() => null) | undefined;
|
|
28
|
+
onOutsideClick?: (() => null) | undefined;
|
|
29
|
+
transitionDuration?: number | undefined;
|
|
30
|
+
verticalSpacing?: number | undefined;
|
|
31
|
+
minimumNights?: number | undefined;
|
|
32
|
+
isDayBlocked?: (() => boolean) | undefined;
|
|
33
|
+
isOutsideRange?: (() => boolean) | undefined;
|
|
34
|
+
isDayHighlighted?: (() => boolean) | undefined;
|
|
35
|
+
displayFormat?: string | undefined;
|
|
36
|
+
displayFormatDay?: string | undefined;
|
|
37
|
+
phrases?: any;
|
|
38
|
+
startDate: any;
|
|
39
|
+
endDate: any;
|
|
40
|
+
startDateId?: string | undefined;
|
|
41
|
+
endDateId?: string | undefined;
|
|
42
|
+
labelFrom?: string | undefined;
|
|
43
|
+
labelTo?: string | undefined;
|
|
44
|
+
enableOutsideDays?: boolean | undefined;
|
|
45
|
+
onChangeStartInput?: (() => null) | undefined;
|
|
46
|
+
onChangeEndInput?: (() => null) | undefined;
|
|
47
|
+
onDatesChange?: (() => null) | undefined;
|
|
48
|
+
}): JSX.Element;
|
|
49
|
+
propTypes: {
|
|
50
|
+
containerProps: {
|
|
51
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
52
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
53
|
+
};
|
|
54
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
55
|
+
};
|
|
56
|
+
className: {
|
|
57
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
58
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
59
|
+
};
|
|
60
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
61
|
+
};
|
|
62
|
+
disabled: {
|
|
63
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
64
|
+
};
|
|
65
|
+
required: {
|
|
66
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
67
|
+
};
|
|
68
|
+
startDateRequired: {
|
|
69
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
70
|
+
};
|
|
71
|
+
endDateRequired: {
|
|
72
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
73
|
+
};
|
|
74
|
+
id: {
|
|
75
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
76
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
77
|
+
};
|
|
78
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
79
|
+
};
|
|
80
|
+
hasError: {
|
|
81
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
82
|
+
};
|
|
83
|
+
validationMessage: {
|
|
84
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
85
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
86
|
+
};
|
|
87
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
88
|
+
};
|
|
89
|
+
readOnly: any;
|
|
90
|
+
screenReaderInputMessage: {
|
|
91
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
92
|
+
};
|
|
93
|
+
initialVisibleMonth: {
|
|
94
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
95
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
96
|
+
};
|
|
97
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
98
|
+
};
|
|
99
|
+
firstDayOfWeek: {
|
|
100
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
101
|
+
};
|
|
102
|
+
keepOpenOnDateSelect: {
|
|
103
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
104
|
+
};
|
|
105
|
+
reopenPickerOnClearDates: {
|
|
106
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
107
|
+
};
|
|
108
|
+
hideKeyboardShortcutsPanel: {
|
|
109
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
110
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
111
|
+
};
|
|
112
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
113
|
+
};
|
|
114
|
+
onPrevMonthClick: {
|
|
115
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
116
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
117
|
+
};
|
|
118
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
119
|
+
};
|
|
120
|
+
onNextMonthClick: {
|
|
121
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
122
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
123
|
+
};
|
|
124
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
125
|
+
};
|
|
126
|
+
onClose: {
|
|
127
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
128
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
129
|
+
};
|
|
130
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
131
|
+
};
|
|
132
|
+
transitionDuration: {
|
|
133
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
134
|
+
};
|
|
135
|
+
verticalSpacing: {
|
|
136
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
137
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
138
|
+
};
|
|
139
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
140
|
+
};
|
|
141
|
+
isDayBlocked: {
|
|
142
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
143
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
144
|
+
};
|
|
145
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
146
|
+
};
|
|
147
|
+
isOutsideRange: {
|
|
148
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
149
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
150
|
+
};
|
|
151
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
152
|
+
};
|
|
153
|
+
isDayHighlighted: {
|
|
154
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
155
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
156
|
+
};
|
|
157
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
158
|
+
};
|
|
159
|
+
minimumNights: number;
|
|
160
|
+
displayFormat: {
|
|
161
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
162
|
+
};
|
|
163
|
+
displayFormatDay: {
|
|
164
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
165
|
+
};
|
|
166
|
+
phrases: {
|
|
167
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
168
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
169
|
+
};
|
|
170
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
171
|
+
};
|
|
172
|
+
startDate: {
|
|
173
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
174
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
175
|
+
};
|
|
176
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
177
|
+
};
|
|
178
|
+
endDate: {
|
|
179
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
180
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
181
|
+
};
|
|
182
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
183
|
+
};
|
|
184
|
+
startDateId: {
|
|
185
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
186
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
187
|
+
};
|
|
188
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
189
|
+
};
|
|
190
|
+
endDateId: {
|
|
191
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
192
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
193
|
+
};
|
|
194
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
195
|
+
};
|
|
196
|
+
labelFrom: {
|
|
197
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
198
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
199
|
+
};
|
|
200
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
201
|
+
};
|
|
202
|
+
labelTo: {
|
|
203
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
204
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
205
|
+
};
|
|
206
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
207
|
+
};
|
|
208
|
+
enableOutsideDays: {
|
|
209
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
210
|
+
};
|
|
211
|
+
onDatesChange: {
|
|
212
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
213
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
214
|
+
};
|
|
215
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
216
|
+
};
|
|
217
|
+
onChangeStartInput: {
|
|
218
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
219
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
220
|
+
};
|
|
221
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
222
|
+
};
|
|
223
|
+
onChangeEndInput: {
|
|
224
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
225
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
226
|
+
};
|
|
227
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
228
|
+
};
|
|
229
|
+
onOutsideClick: {
|
|
230
|
+
defaultValue(arg: import("react-desc").ReactDescPossibleDefaultValues): {
|
|
231
|
+
deprecated: import("react-desc").PropTypesDescValidator;
|
|
232
|
+
};
|
|
233
|
+
isRequired: import("react-desc").PropTypesDescValue;
|
|
234
|
+
};
|
|
235
|
+
};
|
|
236
|
+
};
|
|
237
|
+
declare const DateRangePickerWithSchema: {
|
|
238
|
+
(props?: unknown): JSX.Element;
|
|
239
|
+
propTypes: unknown;
|
|
240
|
+
toTypescript: () => import("react-desc").TypescriptSchema;
|
|
241
|
+
};
|
|
242
|
+
export { DayPickerRangeController, START_DATE, END_DATE, DateRangePickerWithSchema, };
|
|
243
|
+
export default DSDateRangePicker;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
export declare const START_DATE = "startDate";
|
|
3
|
+
export declare const END_DATE = "endDate";
|
|
4
|
+
export default class DSDateRangePickerImpl extends React.Component {
|
|
5
|
+
constructor(props: any);
|
|
6
|
+
componentDidMount(): void;
|
|
7
|
+
componentWillUnmount(): void;
|
|
8
|
+
onDatesChange: ({ startDate, endDate }: {
|
|
9
|
+
startDate: any;
|
|
10
|
+
endDate: any;
|
|
11
|
+
}) => void;
|
|
12
|
+
onFocusChange: () => void;
|
|
13
|
+
handleKeyDown: (event: any) => void;
|
|
14
|
+
getSafeStartInputValue: () => any;
|
|
15
|
+
getSafeEndInputValue: () => any;
|
|
16
|
+
changeFocus: () => void;
|
|
17
|
+
handleChangeStart: (e: any) => void;
|
|
18
|
+
handleChangeEnd: (e: any) => void;
|
|
19
|
+
handleChangeDate: ({ startDate: _start, endDate }: {
|
|
20
|
+
startDate: any;
|
|
21
|
+
endDate: any;
|
|
22
|
+
}) => void;
|
|
23
|
+
render(): JSX.Element;
|
|
24
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
declare const DatePickerRangeHeader: ({ placeholderStart, placeholderEnd, onStartInputChange, onEndInputChange, selectedStartDate, selectedEndDate, }: {
|
|
3
|
+
placeholderStart?: string | undefined;
|
|
4
|
+
placeholderEnd?: string | undefined;
|
|
5
|
+
onStartInputChange?: (() => null) | undefined;
|
|
6
|
+
onEndInputChange?: (() => null) | undefined;
|
|
7
|
+
selectedStartDate: any;
|
|
8
|
+
selectedEndDate: any;
|
|
9
|
+
}) => JSX.Element;
|
|
10
|
+
export default DatePickerRangeHeader;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import PropTypes from 'prop-types';
|
|
3
|
+
declare const DayPickerRangeController: {
|
|
4
|
+
({ endDate, startDate, displayFormatDay, focusedInput, enableOutsideDays, onDatesChange, onFocusChange, onOutsideClick, isDayBlocked, isDayHighlighted, isOutsideRange, onNextMonthClick, onPrevMonthClick, ...otherProps }: {
|
|
5
|
+
[x: string]: any;
|
|
6
|
+
endDate?: undefined;
|
|
7
|
+
startDate?: undefined;
|
|
8
|
+
displayFormatDay?: string | undefined;
|
|
9
|
+
focusedInput?: undefined;
|
|
10
|
+
enableOutsideDays?: boolean | undefined;
|
|
11
|
+
onDatesChange?: (() => null) | undefined;
|
|
12
|
+
onFocusChange?: (() => null) | undefined;
|
|
13
|
+
onOutsideClick?: (() => null) | undefined;
|
|
14
|
+
isDayBlocked?: (() => null) | undefined;
|
|
15
|
+
isDayHighlighted?: (() => null) | undefined;
|
|
16
|
+
isOutsideRange?: (() => null) | undefined;
|
|
17
|
+
onNextMonthClick?: (() => null) | undefined;
|
|
18
|
+
onPrevMonthClick?: (() => null) | undefined;
|
|
19
|
+
}): JSX.Element;
|
|
20
|
+
propTypes: {
|
|
21
|
+
endDate: PropTypes.Requireable<Date>;
|
|
22
|
+
startDate: PropTypes.Requireable<Date>;
|
|
23
|
+
displayFormatDay: PropTypes.Requireable<string>;
|
|
24
|
+
focusedInput: PropTypes.Requireable<boolean>;
|
|
25
|
+
onDatesChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
26
|
+
onFocusChange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
27
|
+
onOutsideClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
28
|
+
onNextMonthClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
29
|
+
onPrevMonthClick: PropTypes.Requireable<(...args: any[]) => any>;
|
|
30
|
+
enableOutsideDays: PropTypes.Requireable<boolean>;
|
|
31
|
+
isDayBlocked: PropTypes.Requireable<(...args: any[]) => any>;
|
|
32
|
+
isDayHighlighted: PropTypes.Requireable<(...args: any[]) => any>;
|
|
33
|
+
isOutsideRange: PropTypes.Requireable<(...args: any[]) => any>;
|
|
34
|
+
};
|
|
35
|
+
};
|
|
36
|
+
export default DayPickerRangeController;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-date-range-picker",
|
|
3
|
-
"version": "2.3.0-alpha.
|
|
3
|
+
"version": "2.3.0-alpha.9",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Date Range Picker",
|
|
6
6
|
"files": [
|
|
@@ -53,11 +53,11 @@
|
|
|
53
53
|
},
|
|
54
54
|
"author": "ICE MT",
|
|
55
55
|
"dependencies": {
|
|
56
|
-
"@elliemae/ds-classnames": "2.3.0-alpha.
|
|
57
|
-
"@elliemae/ds-date-picker": "2.3.0-alpha.
|
|
58
|
-
"@elliemae/ds-form": "2.3.0-alpha.
|
|
59
|
-
"@elliemae/ds-icons": "2.3.0-alpha.
|
|
60
|
-
"@elliemae/ds-popper": "2.3.0-alpha.
|
|
56
|
+
"@elliemae/ds-classnames": "2.3.0-alpha.9",
|
|
57
|
+
"@elliemae/ds-date-picker": "2.3.0-alpha.9",
|
|
58
|
+
"@elliemae/ds-form": "2.3.0-alpha.9",
|
|
59
|
+
"@elliemae/ds-icons": "2.3.0-alpha.9",
|
|
60
|
+
"@elliemae/ds-popper": "2.3.0-alpha.9",
|
|
61
61
|
"moment": "~2.29.1",
|
|
62
62
|
"prop-types": "~15.7.2",
|
|
63
63
|
"react-dates": "~21.8.0",
|