kwant-ui 3.51.0-dev.2 → 3.51.0-dev.21
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/components/Avatar/Avatar.types.d.ts +2 -0
- package/dist/components/Dropdown/DropdownTypes.d.ts +18 -1
- package/dist/components/Dropdown/hooks/useDropdownPositioning.d.ts +7 -0
- package/dist/components/Select/Select.types.d.ts +1 -0
- package/dist/components/Switch/Switch.d.ts +1 -1
- package/dist/components/Switch/types.d.ts +2 -0
- package/dist/components/TimePicker/timepicker.styled.d.ts +6 -0
- package/dist/components/TimePicker/types.d.ts +4 -1
- package/dist/index.es.js +490 -482
- package/dist/index.js +308 -300
- package/dist/package.json +3 -2
- package/dist/public/assets/icons/Compare.svg +1 -0
- package/dist/public/assets/icons/Notifications.svg +1 -0
- package/dist/public/assets/icons/Search.svg +1 -0
- package/dist/types/IconTypes.d.ts +1 -1
- package/package.json +3 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
import { RefObject } from 'react';
|
|
2
2
|
import { AvatarDeclarations } from '../Avatar/Avatar.types';
|
|
3
3
|
import { IBaseDropdown } from '../BaseDropdown/BaseDropdownTypes';
|
|
4
4
|
export declare namespace IDropdown {
|
|
@@ -31,5 +31,22 @@ export declare namespace IDropdown {
|
|
|
31
31
|
avatarProps?: AvatarDeclarations.Props;
|
|
32
32
|
selectedValue?: string | null;
|
|
33
33
|
withInput?: boolean;
|
|
34
|
+
dropdownWidth?: number;
|
|
34
35
|
};
|
|
35
36
|
}
|
|
37
|
+
export interface DropdownOffsets {
|
|
38
|
+
offsetTop?: string;
|
|
39
|
+
offsetBottom?: string;
|
|
40
|
+
maxHeight: number;
|
|
41
|
+
}
|
|
42
|
+
export interface UseDropdownPositioningProps {
|
|
43
|
+
isDynamicOptionPosition?: boolean;
|
|
44
|
+
targetRef?: RefObject<HTMLElement>;
|
|
45
|
+
opened: boolean;
|
|
46
|
+
maxHeight?: number;
|
|
47
|
+
offsetTop?: string;
|
|
48
|
+
offsetBottom?: string;
|
|
49
|
+
searchable?: boolean;
|
|
50
|
+
dataLength?: number;
|
|
51
|
+
itemHeight?: number;
|
|
52
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { DropdownOffsets, UseDropdownPositioningProps } from '../DropdownTypes';
|
|
2
|
+
export declare const useDropdownPositioning: ({ isDynamicOptionPosition, targetRef, opened, maxHeight, offsetTop, offsetBottom, searchable, dataLength, itemHeight, }: UseDropdownPositioningProps) => {
|
|
3
|
+
currentOffsets: DropdownOffsets;
|
|
4
|
+
isOpeningUpward: boolean;
|
|
5
|
+
calculateDropdownPosition: () => void;
|
|
6
|
+
renderDropDown: boolean;
|
|
7
|
+
};
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { SWType } from './types';
|
|
2
|
-
declare function Switch(
|
|
2
|
+
declare function Switch(props: SWType): import("react/jsx-runtime").JSX.Element;
|
|
3
3
|
export { Switch };
|
|
@@ -8,6 +8,7 @@ export type SWType = {
|
|
|
8
8
|
color?: string;
|
|
9
9
|
size?: 'small' | 'medium' | 'large';
|
|
10
10
|
mode?: 'default' | 'labelMode' | 'iconMode';
|
|
11
|
+
cursorPointer?: boolean;
|
|
11
12
|
};
|
|
12
13
|
export type SwitchContainerTypes = {
|
|
13
14
|
disabled?: boolean;
|
|
@@ -20,4 +21,5 @@ export type SwitchContainerTypes = {
|
|
|
20
21
|
size?: 'small' | 'medium' | 'large';
|
|
21
22
|
labelMode?: boolean;
|
|
22
23
|
iconMode?: boolean;
|
|
24
|
+
cursorPointer?: boolean;
|
|
23
25
|
};
|
|
@@ -1,7 +1,13 @@
|
|
|
1
1
|
export declare const TimeContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
2
2
|
export declare const TimeInput: import("styled-components").StyledComponent<"input", any, {
|
|
3
3
|
format?: string;
|
|
4
|
+
onlyHours?: boolean;
|
|
4
5
|
}, never>;
|
|
6
|
+
export declare const TimeInputWrapper: import("styled-components").StyledComponent<"div", any, {
|
|
7
|
+
onlyHours?: boolean;
|
|
8
|
+
}, never>;
|
|
9
|
+
export declare const ColonSeparator: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
10
|
+
export declare const DisabledMinutes: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
5
11
|
export declare const DropdownContainer: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
6
12
|
export declare const DropdownButton: import("styled-components").StyledComponent<"button", any, {}, never>;
|
|
7
13
|
export declare const PeriodText: import("styled-components").StyledComponent<"span", any, {}, never>;
|
|
@@ -3,7 +3,10 @@ import { TooltipComponent } from '../Tooltip/types';
|
|
|
3
3
|
type Period = 'AM' | 'PM';
|
|
4
4
|
type Format = '12' | '24';
|
|
5
5
|
export interface TimePickerProps {
|
|
6
|
-
onChange?: (
|
|
6
|
+
onChange?: (value: {
|
|
7
|
+
time: string;
|
|
8
|
+
period?: Period;
|
|
9
|
+
}) => void;
|
|
7
10
|
onBlur?: (e: React.FocusEvent<HTMLInputElement>) => void;
|
|
8
11
|
disabled?: boolean;
|
|
9
12
|
required?: boolean;
|