@salutejs/sdds-serv 0.227.0-canary.1706.12871124885.0 → 0.227.0-canary.1706.12871746061.0
Sign up to get free protection for your applications and to get access to all the features.
- package/api/sdds-serv.api.md +18 -17
- package/components/DatePicker/DatePicker.d.ts +5 -4
- package/components/Range/Range.d.ts +12 -12
- package/emotion/cjs/components/DatePicker/DatePicker.stories.tsx +1 -7
- package/emotion/es/components/DatePicker/DatePicker.stories.tsx +1 -7
- package/package.json +3 -3
package/api/sdds-serv.api.md
CHANGED
@@ -50,7 +50,6 @@ import { CellTextbox } from '@salutejs/plasma-new-hope/styled-components';
|
|
50
50
|
import { CellTextboxLabel } from '@salutejs/plasma-new-hope/styled-components';
|
51
51
|
import { CellTextboxSubtitle } from '@salutejs/plasma-new-hope/styled-components';
|
52
52
|
import { CellTextboxTitle } from '@salutejs/plasma-new-hope/styled-components';
|
53
|
-
import { ChangeEvent } from 'react';
|
54
53
|
import { ChangeInstanceCallback } from '@salutejs/plasma-new-hope/types/components/DatePicker/RangeDate/RangeDate.types';
|
55
54
|
import { CheckboxProps as CheckboxProps_2 } from '@salutejs/plasma-new-hope/types/components/Checkbox/Checkbox.types';
|
56
55
|
import { ChipGroupProps } from '@salutejs/plasma-new-hope/types/components/ChipGroup/ChipGroup.types';
|
@@ -112,6 +111,7 @@ import { FC } from 'react';
|
|
112
111
|
import { FileProcessHandler } from '@salutejs/plasma-new-hope/types/components/Dropzone/Dropzone.types';
|
113
112
|
import { Filter } from '@salutejs/plasma-new-hope/types/engines/types';
|
114
113
|
import { FlowProps } from '@salutejs/plasma-new-hope/styled-components';
|
114
|
+
import { FocusEvent as FocusEvent_2 } from 'react';
|
115
115
|
import { FormTypeNumber } from '@salutejs/plasma-new-hope/types/types/FormType';
|
116
116
|
import { FormTypeString } from '@salutejs/plasma-new-hope/types/types/FormType';
|
117
117
|
import { ForwardRefExoticComponent } from 'react';
|
@@ -1528,10 +1528,10 @@ secondTextfieldContentLeft?: ReactElement<any, string | JSXElementConstructor<an
|
|
1528
1528
|
secondTextfieldContentRight?: ReactElement<any, string | JSXElementConstructor<any>> | undefined;
|
1529
1529
|
firstTextfieldTextAfter?: string | undefined;
|
1530
1530
|
secondTextfieldTextAfter?: string | undefined;
|
1531
|
-
onFocusFirstTextfield?: ((event:
|
1532
|
-
onFocusSecondTextfield?: ((event:
|
1533
|
-
onBlurFirstTextfield?: ((event:
|
1534
|
-
onBlurSecondTextfield?: ((event:
|
1531
|
+
onFocusFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
1532
|
+
onFocusSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
1533
|
+
onBlurFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
1534
|
+
onBlurSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
1535
1535
|
firstTextfieldTextBefore?: string | undefined;
|
1536
1536
|
secondTextfieldTextBefore?: string | undefined;
|
1537
1537
|
dividerVariant?: "none" | "dash" | "icon" | undefined;
|
@@ -1539,6 +1539,7 @@ dividerIcon?: ReactNode;
|
|
1539
1539
|
} & DatePickerCalendarProps & Omit<DatePickerPopoverProps, "placement"> & {
|
1540
1540
|
placement?: DatePickerRangePlacement | DatePickerRangePlacementBasic[] | undefined;
|
1541
1541
|
isDoubleCalendar?: boolean | undefined;
|
1542
|
+
closeAfterDateSelect?: boolean | undefined;
|
1542
1543
|
} & HTMLAttributes<HTMLDivElement> & RefAttributes<RangeInputRefs>>;
|
1543
1544
|
|
1544
1545
|
export { DatePickerRangePlacement }
|
@@ -2949,10 +2950,10 @@ onChangeFirstValue?: BaseCallbackChangeInstance | undefined;
|
|
2949
2950
|
onChangeSecondValue?: BaseCallbackChangeInstance | undefined;
|
2950
2951
|
onSearchFirstValue?: BaseCallbackKeyboardInstance | undefined;
|
2951
2952
|
onSearchSecondValue?: BaseCallbackKeyboardInstance | undefined;
|
2952
|
-
onFocusFirstTextfield?: ((event:
|
2953
|
-
onFocusSecondTextfield?: ((event:
|
2954
|
-
onBlurFirstTextfield?: ((event:
|
2955
|
-
onBlurSecondTextfield?: ((event:
|
2953
|
+
onFocusFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2954
|
+
onFocusSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2955
|
+
onBlurFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2956
|
+
onBlurSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2956
2957
|
} & {
|
2957
2958
|
firstTextfieldTextBefore: string;
|
2958
2959
|
secondTextfieldTextBefore: string;
|
@@ -2988,10 +2989,10 @@ onChangeFirstValue?: BaseCallbackChangeInstance | undefined;
|
|
2988
2989
|
onChangeSecondValue?: BaseCallbackChangeInstance | undefined;
|
2989
2990
|
onSearchFirstValue?: BaseCallbackKeyboardInstance | undefined;
|
2990
2991
|
onSearchSecondValue?: BaseCallbackKeyboardInstance | undefined;
|
2991
|
-
onFocusFirstTextfield?: ((event:
|
2992
|
-
onFocusSecondTextfield?: ((event:
|
2993
|
-
onBlurFirstTextfield?: ((event:
|
2994
|
-
onBlurSecondTextfield?: ((event:
|
2992
|
+
onFocusFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2993
|
+
onFocusSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2994
|
+
onBlurFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2995
|
+
onBlurSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
2995
2996
|
} & {
|
2996
2997
|
dividerVariant?: "dash" | undefined;
|
2997
2998
|
dividerIcon?: undefined;
|
@@ -3027,10 +3028,10 @@ onChangeFirstValue?: BaseCallbackChangeInstance | undefined;
|
|
3027
3028
|
onChangeSecondValue?: BaseCallbackChangeInstance | undefined;
|
3028
3029
|
onSearchFirstValue?: BaseCallbackKeyboardInstance | undefined;
|
3029
3030
|
onSearchSecondValue?: BaseCallbackKeyboardInstance | undefined;
|
3030
|
-
onFocusFirstTextfield?: ((event:
|
3031
|
-
onFocusSecondTextfield?: ((event:
|
3032
|
-
onBlurFirstTextfield?: ((event:
|
3033
|
-
onBlurSecondTextfield?: ((event:
|
3031
|
+
onFocusFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
3032
|
+
onFocusSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
3033
|
+
onBlurFirstTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
3034
|
+
onBlurSecondTextfield?: ((event: FocusEvent_2<HTMLInputElement, Element>) => void) | undefined;
|
3034
3035
|
} & {
|
3035
3036
|
dividerIcon?: ReactNode;
|
3036
3037
|
dividerVariant?: "icon" | undefined;
|
@@ -93,10 +93,10 @@ export declare const DatePickerRange: import("react").FunctionComponent<import("
|
|
93
93
|
secondTextfieldContentRight?: import("react").ReactElement<any, string | import("react").JSXElementConstructor<any>> | undefined;
|
94
94
|
firstTextfieldTextAfter?: string | undefined;
|
95
95
|
secondTextfieldTextAfter?: string | undefined;
|
96
|
-
onFocusFirstTextfield?: ((event: import("react").
|
97
|
-
onFocusSecondTextfield?: ((event: import("react").
|
98
|
-
onBlurFirstTextfield?: ((event: import("react").
|
99
|
-
onBlurSecondTextfield?: ((event: import("react").
|
96
|
+
onFocusFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
97
|
+
onFocusSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
98
|
+
onBlurFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
99
|
+
onBlurSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
100
100
|
firstTextfieldTextBefore?: string | undefined;
|
101
101
|
secondTextfieldTextBefore?: string | undefined;
|
102
102
|
dividerVariant?: "none" | "dash" | "icon" | undefined;
|
@@ -104,4 +104,5 @@ export declare const DatePickerRange: import("react").FunctionComponent<import("
|
|
104
104
|
} & import("@salutejs/plasma-new-hope/types/components/DatePicker/DatePickerBase.types").DatePickerCalendarProps & Omit<import("@salutejs/plasma-new-hope/types/components/DatePicker/SingleDate/SingleDate.types").DatePickerPopoverProps, "placement"> & {
|
105
105
|
placement?: import("@salutejs/plasma-new-hope/styled-components").DatePickerRangePlacement | import("@salutejs/plasma-new-hope/types/components/DatePicker/RangeDate/RangeDate.types").DatePickerRangePlacementBasic[] | undefined;
|
106
106
|
isDoubleCalendar?: boolean | undefined;
|
107
|
+
closeAfterDateSelect?: boolean | undefined;
|
107
108
|
} & import("react").HTMLAttributes<HTMLDivElement> & import("react").RefAttributes<import("@salutejs/plasma-new-hope/styled-components").RangeInputRefs>>;
|
@@ -48,10 +48,10 @@ export declare const Range: import("react").FunctionComponent<import("@salutejs/
|
|
48
48
|
onChangeSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackChangeInstance | undefined;
|
49
49
|
onSearchFirstValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
50
50
|
onSearchSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
51
|
-
onFocusFirstTextfield?: ((event: import("react").
|
52
|
-
onFocusSecondTextfield?: ((event: import("react").
|
53
|
-
onBlurFirstTextfield?: ((event: import("react").
|
54
|
-
onBlurSecondTextfield?: ((event: import("react").
|
51
|
+
onFocusFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
52
|
+
onFocusSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
53
|
+
onBlurFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
54
|
+
onBlurSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
55
55
|
} & {
|
56
56
|
firstTextfieldTextBefore: string;
|
57
57
|
secondTextfieldTextBefore: string;
|
@@ -87,10 +87,10 @@ export declare const Range: import("react").FunctionComponent<import("@salutejs/
|
|
87
87
|
onChangeSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackChangeInstance | undefined;
|
88
88
|
onSearchFirstValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
89
89
|
onSearchSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
90
|
-
onFocusFirstTextfield?: ((event: import("react").
|
91
|
-
onFocusSecondTextfield?: ((event: import("react").
|
92
|
-
onBlurFirstTextfield?: ((event: import("react").
|
93
|
-
onBlurSecondTextfield?: ((event: import("react").
|
90
|
+
onFocusFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
91
|
+
onFocusSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
92
|
+
onBlurFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
93
|
+
onBlurSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
94
94
|
} & {
|
95
95
|
dividerVariant?: "dash" | undefined;
|
96
96
|
dividerIcon?: undefined;
|
@@ -126,10 +126,10 @@ export declare const Range: import("react").FunctionComponent<import("@salutejs/
|
|
126
126
|
onChangeSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackChangeInstance | undefined;
|
127
127
|
onSearchFirstValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
128
128
|
onSearchSecondValue?: import("@salutejs/plasma-new-hope/types/components/Range/Range.types").BaseCallbackKeyboardInstance | undefined;
|
129
|
-
onFocusFirstTextfield?: ((event: import("react").
|
130
|
-
onFocusSecondTextfield?: ((event: import("react").
|
131
|
-
onBlurFirstTextfield?: ((event: import("react").
|
132
|
-
onBlurSecondTextfield?: ((event: import("react").
|
129
|
+
onFocusFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
130
|
+
onFocusSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
131
|
+
onBlurFirstTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
132
|
+
onBlurSecondTextfield?: ((event: import("react").FocusEvent<HTMLInputElement, Element>) => void) | undefined;
|
133
133
|
} & {
|
134
134
|
dividerIcon?: import("react").ReactNode;
|
135
135
|
dividerVariant?: "icon" | undefined;
|
@@ -185,7 +185,6 @@ const StoryRange = ({
|
|
185
185
|
const rangeRef = useRef(null);
|
186
186
|
|
187
187
|
const [isOpen, setIsOpen] = useState(false);
|
188
|
-
const [firstDate, setFirstDate] = useState<string | Date>('');
|
189
188
|
|
190
189
|
const iconSize = size === 'xs' ? 'xs' : 's';
|
191
190
|
const showDividerIcon = dividerVariant === 'icon';
|
@@ -232,12 +231,6 @@ const StoryRange = ({
|
|
232
231
|
onChangeSecondValue={(e, currentValue) => {
|
233
232
|
onChangeSecondValue(e, currentValue);
|
234
233
|
}}
|
235
|
-
onCommitFirstDate={(currentValue) => {
|
236
|
-
setFirstDate(currentValue);
|
237
|
-
}}
|
238
|
-
onCommitSecondDate={(currentValue) => {
|
239
|
-
firstDate && currentValue && setIsOpen(false);
|
240
|
-
}}
|
241
234
|
{...dividerIconProps}
|
242
235
|
{...rest}
|
243
236
|
/>
|
@@ -265,6 +258,7 @@ export const Range: StoryObj<StoryPropsRange> = {
|
|
265
258
|
size: 'l',
|
266
259
|
view: 'default',
|
267
260
|
isDoubleCalendar: false,
|
261
|
+
closeAfterDateSelect: true,
|
268
262
|
dividerVariant: 'dash',
|
269
263
|
min: new Date(2024, 1, 1),
|
270
264
|
max: new Date(2024, 12, 29),
|
@@ -185,7 +185,6 @@ const StoryRange = ({
|
|
185
185
|
const rangeRef = useRef(null);
|
186
186
|
|
187
187
|
const [isOpen, setIsOpen] = useState(false);
|
188
|
-
const [firstDate, setFirstDate] = useState<string | Date>('');
|
189
188
|
|
190
189
|
const iconSize = size === 'xs' ? 'xs' : 's';
|
191
190
|
const showDividerIcon = dividerVariant === 'icon';
|
@@ -232,12 +231,6 @@ const StoryRange = ({
|
|
232
231
|
onChangeSecondValue={(e, currentValue) => {
|
233
232
|
onChangeSecondValue(e, currentValue);
|
234
233
|
}}
|
235
|
-
onCommitFirstDate={(currentValue) => {
|
236
|
-
setFirstDate(currentValue);
|
237
|
-
}}
|
238
|
-
onCommitSecondDate={(currentValue) => {
|
239
|
-
firstDate && currentValue && setIsOpen(false);
|
240
|
-
}}
|
241
234
|
{...dividerIconProps}
|
242
235
|
{...rest}
|
243
236
|
/>
|
@@ -265,6 +258,7 @@ export const Range: StoryObj<StoryPropsRange> = {
|
|
265
258
|
size: 'l',
|
266
259
|
view: 'default',
|
267
260
|
isDoubleCalendar: false,
|
261
|
+
closeAfterDateSelect: true,
|
268
262
|
dividerVariant: 'dash',
|
269
263
|
min: new Date(2024, 1, 1),
|
270
264
|
max: new Date(2024, 12, 29),
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@salutejs/sdds-serv",
|
3
|
-
"version": "0.227.0-canary.1706.
|
3
|
+
"version": "0.227.0-canary.1706.12871746061.0",
|
4
4
|
"description": "Salute Design System / React UI kit for SDDS SERV web applications",
|
5
5
|
"author": "Salute Frontend Team <salute.developers@gmail.com>",
|
6
6
|
"license": "MIT",
|
@@ -32,7 +32,7 @@
|
|
32
32
|
"directory": "packages/sdds-serv"
|
33
33
|
},
|
34
34
|
"dependencies": {
|
35
|
-
"@salutejs/plasma-new-hope": "0.242.0-canary.1706.
|
35
|
+
"@salutejs/plasma-new-hope": "0.242.0-canary.1706.12871746061.0",
|
36
36
|
"@salutejs/sdds-themes": "0.31.0"
|
37
37
|
},
|
38
38
|
"peerDependencies": {
|
@@ -137,5 +137,5 @@
|
|
137
137
|
"sideEffects": [
|
138
138
|
"*.css"
|
139
139
|
],
|
140
|
-
"gitHead": "
|
140
|
+
"gitHead": "530f421d25e29df4dd11a8589f4db0fb8860073e"
|
141
141
|
}
|