@alfalab/core-components-picker-button 11.5.3 → 11.6.0
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/{Component-72dda473.d.ts → Component-064acd29.d.ts} +1 -1
- package/{cssm/Component-c29389e5.d.ts → Component-70284312.d.ts} +1 -1
- package/Component-a5b021bd.d.ts +4 -2
- package/Component-bdb4c6b9.d.ts +2 -2
- package/Component-c44170fe.d.ts +5 -3
- package/{esm/ResponsiveContext-8a2a8ad1.d.ts → ResponsiveContext-88b743b5.d.ts} +1 -1
- package/consts-6c9aad46.d.ts +12 -0
- package/consts-ef43bf1b.d.ts +12 -0
- package/cssm/{Component-72dda473.d.ts → Component-064acd29.d.ts} +1 -1
- package/{Component-c29389e5.d.ts → cssm/Component-70284312.d.ts} +1 -1
- package/cssm/Component-a5b021bd.d.ts +4 -2
- package/cssm/Component-bdb4c6b9.d.ts +2 -2
- package/cssm/Component-c44170fe.d.ts +5 -3
- package/{modern/ResponsiveContext-8a2a8ad1.d.ts → cssm/ResponsiveContext-88b743b5.d.ts} +1 -1
- package/cssm/consts-6c9aad46.d.ts +12 -0
- package/cssm/consts-ef43bf1b.d.ts +12 -0
- package/cssm/desktop/Component.desktop.d.ts +2 -0
- package/cssm/desktop/Component.desktop.js +2 -2
- package/cssm/field/Component.d.ts +1 -1
- package/cssm/field/Component.js +16 -2
- package/cssm/field/index.module.css +1 -1
- package/{esm/index-72dda473.d.ts → cssm/index-064acd29.d.ts} +2 -1
- package/cssm/index-a5b021bd.d.ts +1 -1
- package/cssm/index.module.css +1 -1
- package/cssm/mobile/Component.mobile.js +1 -1
- package/cssm/option/index.module.css +1 -1
- package/cssm/types.d.ts +1 -1
- package/cssm/{typings-c29389e5.d.ts → typings-70284312.d.ts} +16 -11
- package/{esm/typings-8a2a8ad1.d.ts → cssm/typings-88b743b5.d.ts} +3 -2
- package/cssm/utils/index.d.ts +2 -2
- package/cssm/utils/index.js +2 -2
- package/cssm/utils-89376c31.d.ts +1 -1
- package/desktop/Component.desktop.d.ts +2 -0
- package/desktop/Component.desktop.js +3 -3
- package/esm/{Component-72dda473.d.ts → Component-064acd29.d.ts} +1 -1
- package/esm/{Component-c29389e5.d.ts → Component-70284312.d.ts} +1 -1
- package/esm/Component-a5b021bd.d.ts +4 -2
- package/esm/Component-bdb4c6b9.d.ts +2 -2
- package/esm/Component-c44170fe.d.ts +5 -3
- package/{ResponsiveContext-8a2a8ad1.d.ts → esm/ResponsiveContext-88b743b5.d.ts} +1 -1
- package/esm/consts-6c9aad46.d.ts +12 -0
- package/esm/consts-ef43bf1b.d.ts +12 -0
- package/esm/desktop/Component.desktop.d.ts +2 -0
- package/esm/desktop/Component.desktop.js +3 -3
- package/esm/field/Component.d.ts +1 -1
- package/esm/field/Component.js +17 -3
- package/esm/field/index.css +7 -7
- package/{index-72dda473.d.ts → esm/index-064acd29.d.ts} +2 -1
- package/esm/index-a5b021bd.d.ts +1 -1
- package/esm/index.css +6 -6
- package/esm/mobile/Component.mobile.js +1 -1
- package/esm/option/Component.js +1 -1
- package/esm/option/index.css +5 -5
- package/esm/types.d.ts +1 -1
- package/esm/{typings-c29389e5.d.ts → typings-70284312.d.ts} +16 -11
- package/{modern/typings-8a2a8ad1.d.ts → esm/typings-88b743b5.d.ts} +3 -2
- package/esm/utils/index.d.ts +2 -2
- package/esm/utils/index.js +2 -2
- package/esm/utils-89376c31.d.ts +1 -1
- package/field/Component.d.ts +1 -1
- package/field/Component.js +17 -3
- package/field/index.css +7 -7
- package/{cssm/index-72dda473.d.ts → index-064acd29.d.ts} +2 -1
- package/index-a5b021bd.d.ts +1 -1
- package/index.css +6 -6
- package/mobile/Component.mobile.js +1 -1
- package/modern/{Component-72dda473.d.ts → Component-064acd29.d.ts} +1 -1
- package/modern/{Component-c29389e5.d.ts → Component-70284312.d.ts} +1 -1
- package/modern/Component-a5b021bd.d.ts +4 -2
- package/modern/Component-bdb4c6b9.d.ts +2 -2
- package/modern/Component-c44170fe.d.ts +5 -3
- package/{cssm/ResponsiveContext-8a2a8ad1.d.ts → modern/ResponsiveContext-88b743b5.d.ts} +1 -1
- package/modern/consts-6c9aad46.d.ts +12 -0
- package/modern/consts-ef43bf1b.d.ts +12 -0
- package/modern/desktop/Component.desktop.d.ts +2 -0
- package/modern/desktop/Component.desktop.js +3 -3
- package/modern/field/Component.d.ts +1 -1
- package/modern/field/Component.js +17 -3
- package/modern/field/index.css +7 -7
- package/modern/{index-72dda473.d.ts → index-064acd29.d.ts} +2 -1
- package/modern/index-a5b021bd.d.ts +1 -1
- package/modern/index.css +6 -6
- package/modern/mobile/Component.mobile.js +1 -1
- package/modern/option/Component.js +1 -1
- package/modern/option/index.css +5 -5
- package/modern/types.d.ts +1 -1
- package/modern/{typings-c29389e5.d.ts → typings-70284312.d.ts} +16 -11
- package/{typings-8a2a8ad1.d.ts → modern/typings-88b743b5.d.ts} +3 -2
- package/modern/utils/index.d.ts +2 -2
- package/modern/utils/index.js +2 -2
- package/modern/utils-89376c31.d.ts +1 -1
- package/option/Component.js +1 -1
- package/option/index.css +5 -5
- package/package.json +3 -3
- package/src/desktop/Component.desktop.tsx +3 -2
- package/src/field/Component.tsx +20 -2
- package/src/mobile/Component.mobile.tsx +1 -1
- package/src/types.ts +1 -1
- package/src/utils/index.ts +4 -4
- package/types.d.ts +1 -1
- package/{typings-c29389e5.d.ts → typings-70284312.d.ts} +16 -11
- package/{cssm/typings-8a2a8ad1.d.ts → typings-88b743b5.d.ts} +3 -2
- package/utils/index.d.ts +2 -2
- package/utils/index.js +2 -2
- package/utils-89376c31.d.ts +1 -1
- package/consts-f777ba1a.d.ts +0 -2
- package/cssm/consts-f777ba1a.d.ts +0 -2
- package/esm/consts-f777ba1a.d.ts +0 -2
- package/modern/consts-f777ba1a.d.ts +0 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { BackgroundColorType, GraphicColorType } from "./index-
|
|
3
|
+
import { BackgroundColorType, GraphicColorType } from "./index-064acd29";
|
|
4
4
|
type IconColorType = Extract<GraphicColorType, 'positive' | 'attention' | 'link' | 'negative' | 'tertiary' | 'secondary' | 'primary'>;
|
|
5
5
|
type BadgeProps = {
|
|
6
6
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { OptgroupProps } from "./typings-
|
|
3
|
+
import { OptgroupProps } from "./typings-70284312";
|
|
4
4
|
declare const Optgroup: ({ children, className, label, size }: OptgroupProps) => React.JSX.Element;
|
|
5
5
|
export { Optgroup };
|
package/Component-a5b021bd.d.ts
CHANGED
|
@@ -25,8 +25,9 @@ type CheckboxProps = Omit<NativeProps, 'size' | 'onChange' | 'enterKeyHint'> & {
|
|
|
25
25
|
hint?: ReactNode;
|
|
26
26
|
/**
|
|
27
27
|
* Размер компонента
|
|
28
|
+
* @description s и m deprecated, используйте вместо них 20 и 24 соответственно
|
|
28
29
|
*/
|
|
29
|
-
size?: 's' | 'm';
|
|
30
|
+
size?: 's' | 'm' | 20 | 24;
|
|
30
31
|
/**
|
|
31
32
|
* Доп. класс чекбокса
|
|
32
33
|
*/
|
|
@@ -101,8 +102,9 @@ declare const Checkbox: React.ForwardRefExoticComponent<Omit<NativeProps, "size"
|
|
|
101
102
|
hint?: ReactNode;
|
|
102
103
|
/**
|
|
103
104
|
* Размер компонента
|
|
105
|
+
* @description s и m deprecated, используйте вместо них 20 и 24 соответственно
|
|
104
106
|
*/
|
|
105
|
-
size?: "s" | "m" | undefined;
|
|
107
|
+
size?: "s" | "m" | 24 | 20 | undefined;
|
|
106
108
|
/**
|
|
107
109
|
* Доп. класс чекбокса
|
|
108
110
|
*/
|
package/Component-bdb4c6b9.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { View } from "./typings-
|
|
3
|
+
import { View } from "./typings-88b743b5";
|
|
4
4
|
declare const Modal: React.ForwardRefExoticComponent<import("./index-bdb4c6b9").BaseModalProps & {
|
|
5
|
-
size?: "s" | "m" | "l" | "xl" | "fullscreen" | undefined;
|
|
5
|
+
size?: "s" | "m" | "l" | "xl" | 500 | "fullscreen" | 600 | 800 | 1140 | undefined;
|
|
6
6
|
fullscreen?: boolean | undefined;
|
|
7
7
|
fixedPosition?: boolean | undefined;
|
|
8
8
|
hasCloser?: boolean | undefined;
|
package/Component-c44170fe.d.ts
CHANGED
|
@@ -27,8 +27,9 @@ type BaseInputProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type
|
|
|
27
27
|
clear?: boolean;
|
|
28
28
|
/**
|
|
29
29
|
* Размер компонента
|
|
30
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
30
31
|
*/
|
|
31
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
32
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
32
33
|
/**
|
|
33
34
|
* Набор цветов для компонента
|
|
34
35
|
*/
|
|
@@ -164,8 +165,9 @@ declare const BaseInput: React.ForwardRefExoticComponent<Omit<React.InputHTMLAtt
|
|
|
164
165
|
clear?: boolean | undefined;
|
|
165
166
|
/**
|
|
166
167
|
* Размер компонента
|
|
168
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
167
169
|
*/
|
|
168
|
-
size?: "s" | "m" | "l" | "xl" | undefined;
|
|
170
|
+
size?: "s" | "m" | "l" | "xl" | 48 | 56 | 64 | 72 | undefined;
|
|
169
171
|
/**
|
|
170
172
|
* Набор цветов для компонента
|
|
171
173
|
*/
|
|
@@ -285,5 +287,5 @@ declare const BaseInput: React.ForwardRefExoticComponent<Omit<React.InputHTMLAtt
|
|
|
285
287
|
*/
|
|
286
288
|
disableUserInput?: boolean | undefined;
|
|
287
289
|
} & React.RefAttributes<HTMLInputElement>>;
|
|
288
|
-
export * from "./Component-
|
|
290
|
+
export * from "./Component-064acd29";
|
|
289
291
|
export { ClearButton, BaseInputProps, BaseInput };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { TResponsiveModalContext } from "./typings-
|
|
3
|
+
import { TResponsiveModalContext } from "./typings-88b743b5";
|
|
4
4
|
declare const ResponsiveContext: React.Context<TResponsiveModalContext>;
|
|
5
5
|
export { ResponsiveContext };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
declare const DEFAULT_VISIBLE_OPTIONS = 5;
|
|
2
|
+
declare const SIZE_TO_CLASSNAME_MAP: {
|
|
3
|
+
s: string;
|
|
4
|
+
m: string;
|
|
5
|
+
l: string;
|
|
6
|
+
xl: string;
|
|
7
|
+
48: string;
|
|
8
|
+
56: string;
|
|
9
|
+
64: string;
|
|
10
|
+
72: string;
|
|
11
|
+
};
|
|
12
|
+
export { DEFAULT_VISIBLE_OPTIONS, SIZE_TO_CLASSNAME_MAP };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { BackgroundColorType, GraphicColorType } from "./index-
|
|
3
|
+
import { BackgroundColorType, GraphicColorType } from "./index-064acd29";
|
|
4
4
|
type IconColorType = Extract<GraphicColorType, 'positive' | 'attention' | 'link' | 'negative' | 'tertiary' | 'secondary' | 'primary'>;
|
|
5
5
|
type BadgeProps = {
|
|
6
6
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { OptgroupProps } from "./typings-
|
|
3
|
+
import { OptgroupProps } from "./typings-70284312";
|
|
4
4
|
declare const Optgroup: ({ children, className, label, size }: OptgroupProps) => React.JSX.Element;
|
|
5
5
|
export { Optgroup };
|
|
@@ -25,8 +25,9 @@ type CheckboxProps = Omit<NativeProps, 'size' | 'onChange' | 'enterKeyHint'> & {
|
|
|
25
25
|
hint?: ReactNode;
|
|
26
26
|
/**
|
|
27
27
|
* Размер компонента
|
|
28
|
+
* @description s и m deprecated, используйте вместо них 20 и 24 соответственно
|
|
28
29
|
*/
|
|
29
|
-
size?: 's' | 'm';
|
|
30
|
+
size?: 's' | 'm' | 20 | 24;
|
|
30
31
|
/**
|
|
31
32
|
* Доп. класс чекбокса
|
|
32
33
|
*/
|
|
@@ -101,8 +102,9 @@ declare const Checkbox: React.ForwardRefExoticComponent<Omit<NativeProps, "size"
|
|
|
101
102
|
hint?: ReactNode;
|
|
102
103
|
/**
|
|
103
104
|
* Размер компонента
|
|
105
|
+
* @description s и m deprecated, используйте вместо них 20 и 24 соответственно
|
|
104
106
|
*/
|
|
105
|
-
size?: "s" | "m" | undefined;
|
|
107
|
+
size?: "s" | "m" | 24 | 20 | undefined;
|
|
106
108
|
/**
|
|
107
109
|
* Доп. класс чекбокса
|
|
108
110
|
*/
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { View } from "./typings-
|
|
3
|
+
import { View } from "./typings-88b743b5";
|
|
4
4
|
declare const Modal: React.ForwardRefExoticComponent<import("./index-bdb4c6b9").BaseModalProps & {
|
|
5
|
-
size?: "s" | "m" | "l" | "xl" | "fullscreen" | undefined;
|
|
5
|
+
size?: "s" | "m" | "l" | "xl" | 500 | "fullscreen" | 600 | 800 | 1140 | undefined;
|
|
6
6
|
fullscreen?: boolean | undefined;
|
|
7
7
|
fixedPosition?: boolean | undefined;
|
|
8
8
|
hasCloser?: boolean | undefined;
|
|
@@ -27,8 +27,9 @@ type BaseInputProps = Omit<InputHTMLAttributes<HTMLInputElement>, 'size' | 'type
|
|
|
27
27
|
clear?: boolean;
|
|
28
28
|
/**
|
|
29
29
|
* Размер компонента
|
|
30
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
30
31
|
*/
|
|
31
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
32
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
32
33
|
/**
|
|
33
34
|
* Набор цветов для компонента
|
|
34
35
|
*/
|
|
@@ -164,8 +165,9 @@ declare const BaseInput: React.ForwardRefExoticComponent<Omit<React.InputHTMLAtt
|
|
|
164
165
|
clear?: boolean | undefined;
|
|
165
166
|
/**
|
|
166
167
|
* Размер компонента
|
|
168
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
167
169
|
*/
|
|
168
|
-
size?: "s" | "m" | "l" | "xl" | undefined;
|
|
170
|
+
size?: "s" | "m" | "l" | "xl" | 48 | 56 | 64 | 72 | undefined;
|
|
169
171
|
/**
|
|
170
172
|
* Набор цветов для компонента
|
|
171
173
|
*/
|
|
@@ -285,5 +287,5 @@ declare const BaseInput: React.ForwardRefExoticComponent<Omit<React.InputHTMLAtt
|
|
|
285
287
|
*/
|
|
286
288
|
disableUserInput?: boolean | undefined;
|
|
287
289
|
} & React.RefAttributes<HTMLInputElement>>;
|
|
288
|
-
export * from "./Component-
|
|
290
|
+
export * from "./Component-064acd29";
|
|
289
291
|
export { ClearButton, BaseInputProps, BaseInput };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { TResponsiveModalContext } from "./typings-
|
|
3
|
+
import { TResponsiveModalContext } from "./typings-88b743b5";
|
|
4
4
|
declare const ResponsiveContext: React.Context<TResponsiveModalContext>;
|
|
5
5
|
export { ResponsiveContext };
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
declare const DEFAULT_VISIBLE_OPTIONS = 5;
|
|
2
|
+
declare const SIZE_TO_CLASSNAME_MAP: {
|
|
3
|
+
s: string;
|
|
4
|
+
m: string;
|
|
5
|
+
l: string;
|
|
6
|
+
xl: string;
|
|
7
|
+
48: string;
|
|
8
|
+
56: string;
|
|
9
|
+
64: string;
|
|
10
|
+
72: string;
|
|
11
|
+
};
|
|
12
|
+
export { DEFAULT_VISIBLE_OPTIONS, SIZE_TO_CLASSNAME_MAP };
|
|
@@ -13,6 +13,7 @@ type PickerButtonDesktopProps = Omit<BaseSelectProps, 'placeholder' | 'Arrow' |
|
|
|
13
13
|
}>;
|
|
14
14
|
/**
|
|
15
15
|
* Размер кнопки
|
|
16
|
+
* @description xxs, xs, s, m, l, xl deprecated, используйте вместо них 32, 40, 48, 56, 64, 72 соответственно
|
|
16
17
|
*/
|
|
17
18
|
size?: PickerButtonSize;
|
|
18
19
|
/**
|
|
@@ -34,6 +35,7 @@ declare const PickerButtonDesktop: React.ForwardRefExoticComponent<Omit<BaseSele
|
|
|
34
35
|
}>;
|
|
35
36
|
/**
|
|
36
37
|
* Размер кнопки
|
|
38
|
+
* @description xxs, xs, s, m, l, xl deprecated, используйте вместо них 32, 40, 48, 56, 64, 72 соответственно
|
|
37
39
|
*/
|
|
38
40
|
size?: PickerButtonSize | undefined;
|
|
39
41
|
/**
|
|
@@ -20,7 +20,7 @@ var styles__default = /*#__PURE__*/_interopDefaultCompat(styles);
|
|
|
20
20
|
var SIDE_POSITIONS = ['right', 'right-start', 'right-end', 'left', 'left-start', 'left-end'];
|
|
21
21
|
var PickerButtonDesktop = React.forwardRef(function (_a, ref) {
|
|
22
22
|
var _b;
|
|
23
|
-
var _c = _a.OptionsList, OptionsList = _c === void 0 ? shared.OptionsList : _c, _d = _a.Optgroup, Optgroup = _d === void 0 ? shared.Optgroup : _d, _e = _a.Option, Option = _e === void 0 ? option_Component.Option : _e, view = _a.view, loading = _a.loading, _f = _a.size, size = _f === void 0 ?
|
|
23
|
+
var _c = _a.OptionsList, OptionsList = _c === void 0 ? shared.OptionsList : _c, _d = _a.Optgroup, Optgroup = _d === void 0 ? shared.Optgroup : _d, _e = _a.Option, Option = _e === void 0 ? option_Component.Option : _e, view = _a.view, loading = _a.loading, _f = _a.size, size = _f === void 0 ? 56 : _f, _g = _a.variant, variant = _g === void 0 ? 'default' : _g, className = _a.className, leftAddons = _a.leftAddons, rightAddons = _a.rightAddons, popperClassName = _a.popperClassName, optionClassName = _a.optionClassName, showArrow = _a.showArrow, _h = _a.Field, Field = _h === void 0 ? field_Component.Field : _h, _j = _a.fieldProps, fieldProps = _j === void 0 ? {} : _j, restProps = tslib.__rest(_a, ["OptionsList", "Optgroup", "Option", "view", "loading", "size", "variant", "className", "leftAddons", "rightAddons", "popperClassName", "optionClassName", "showArrow", "Field", "fieldProps"]);
|
|
24
24
|
var isSideGap = !!restProps.popoverPosition && SIDE_POSITIONS.includes(restProps.popoverPosition);
|
|
25
25
|
var fieldDefaultProps = {
|
|
26
26
|
view: view,
|
|
@@ -33,7 +33,7 @@ var PickerButtonDesktop = React.forwardRef(function (_a, ref) {
|
|
|
33
33
|
showArrow: showArrow,
|
|
34
34
|
breakpoint: 1,
|
|
35
35
|
};
|
|
36
|
-
return (React__default.default.createElement(shared.BaseSelect, tslib.__assign({}, restProps, { Popover: coreComponentsPopover.Popover, view: 'desktop', optionProps: { Checkmark: null }, ref: ref, Option: Option, Field: Field, size: size === 'm' ?
|
|
36
|
+
return (React__default.default.createElement(shared.BaseSelect, tslib.__assign({}, restProps, { Popover: coreComponentsPopover.Popover, view: 'desktop', optionProps: { Checkmark: null }, ref: ref, Option: Option, Field: Field, size: size === 'm' || size === 56 ? 56 : 48, fieldProps: tslib.__assign(tslib.__assign({}, fieldDefaultProps), fieldProps), Optgroup: Optgroup, OptionsList: OptionsList, className: cn__default.default(styles__default.default.container, className), popperClassName: cn__default.default('cc-picker-button', styles__default.default.optionsPopover, popperClassName, (_b = {},
|
|
37
37
|
_b[styles__default.default.sideGap] = isSideGap,
|
|
38
38
|
_b)), optionClassName: cn__default.default(styles__default.default.option, optionClassName), selected: [], closeOnSelect: true })));
|
|
39
39
|
});
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ButtonProps } from "@alfalab/core-components-button";
|
|
4
|
-
import { FieldProps as BaseFieldProps } from "../typings-
|
|
4
|
+
import { FieldProps as BaseFieldProps } from "../typings-70284312";
|
|
5
5
|
import { PickerButtonSize, PickerButtonVariant } from "../types";
|
|
6
6
|
type FieldProps = Omit<BaseFieldProps, 'size' | 'hint' | 'success' | 'error' | 'placeholder'> & ButtonProps & {
|
|
7
7
|
buttonSize?: PickerButtonSize;
|
package/cssm/field/Component.js
CHANGED
|
@@ -15,10 +15,24 @@ var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
|
15
15
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
16
16
|
var styles__default = /*#__PURE__*/_interopDefaultCompat(styles);
|
|
17
17
|
|
|
18
|
+
var SIZE_TO_CLASSNAME_MAP = {
|
|
19
|
+
xxs: 'size-32',
|
|
20
|
+
xs: 'size-40',
|
|
21
|
+
s: 'size-48',
|
|
22
|
+
m: 'size-56',
|
|
23
|
+
l: 'size-64',
|
|
24
|
+
xl: 'size-72',
|
|
25
|
+
32: 'size-32',
|
|
26
|
+
40: 'size-40',
|
|
27
|
+
48: 'size-48',
|
|
28
|
+
56: 'size-56',
|
|
29
|
+
64: 'size-64',
|
|
30
|
+
72: 'size-72',
|
|
31
|
+
};
|
|
18
32
|
var Field = function (_a) {
|
|
19
33
|
var _b, _c;
|
|
20
|
-
var _d = _a.buttonSize, buttonSize = _d === void 0 ?
|
|
21
|
-
var Icon = utils_index.getIcon(buttonVariant, buttonSize);
|
|
34
|
+
var _d = _a.buttonSize, buttonSize = _d === void 0 ? 56 : _d, _e = _a.buttonVariant, buttonVariant = _e === void 0 ? 'default' : _e, view = _a.view, label = _a.label, open = _a.open; _a.multiple; var rightAddons = _a.rightAddons; _a.Arrow; var innerProps = _a.innerProps, className = _a.className; _a.selected; _a.selectedMultiple; _a.setSelectedItems; _a.toggleMenu; _a.valueRenderer; var _f = _a.showArrow, showArrow = _f === void 0 ? true : _f; _a.labelView; var restProps = tslib.__rest(_a, ["buttonSize", "buttonVariant", "view", "label", "open", "multiple", "rightAddons", "Arrow", "innerProps", "className", "selected", "selectedMultiple", "setSelectedItems", "toggleMenu", "valueRenderer", "showArrow", "labelView"]);
|
|
35
|
+
var Icon = utils_index.getIcon(buttonVariant, SIZE_TO_CLASSNAME_MAP[buttonSize]);
|
|
22
36
|
var ref = innerProps.ref, restInnerProps = tslib.__rest(innerProps, ["ref"]);
|
|
23
37
|
var buttonProps = tslib.__assign(tslib.__assign({}, restProps), restInnerProps);
|
|
24
38
|
return (React__default.default.createElement("div", { ref: ref },
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
:root {
|
|
1
|
+
:root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
2
2
|
} /* deprecated */ :root {
|
|
3
3
|
--color-light-transparent-default-hover: rgba(38, 55, 88, 0.06); /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
@@ -9,4 +9,5 @@ type PaddingType = number | string | {
|
|
|
9
9
|
bottom?: number;
|
|
10
10
|
left?: number;
|
|
11
11
|
};
|
|
12
|
-
|
|
12
|
+
type TypographyType = 'accent-caps' | 'accent-component-primary' | 'accent-component-secondary' | 'accent-primary-large' | 'accent-primary-medium' | 'accent-primary-small' | 'accent-secondary-large' | 'accent-secondary-medium' | 'accent-secondary-small' | 'action-caps' | 'action-component-primary' | 'action-component-secondary' | 'action-primary-large' | 'action-primary-medium' | 'action-primary-small' | 'action-secondary-large' | 'action-secondary-medium' | 'action-secondary-small' | 'headline-mobile-large' | 'headline-mobile-medium' | 'headline-mobile-small' | 'headline-mobile-xlarge' | 'headline-mobile-xsmall' | 'headline-system-mobile-large' | 'headline-system-mobile-medium' | 'headline-system-mobile-small' | 'headline-system-mobile-xlarge' | 'headline-system-mobile-xsmall' | 'headline-system-large' | 'headline-system-medium' | 'headline-system-small' | 'headline-system-xlarge' | 'headline-system-xsmall' | 'headline-large' | 'headline-medium' | 'headline-small' | 'headline-xlarge' | 'headline-xsmall' | 'key-large' | 'key-medium' | 'key-small' | 'key-xlarge' | 'key-xsmall' | 'paragraph-caps' | 'paragraph-component-primary' | 'paragraph-component-secondary' | 'paragraph-primary-large' | 'paragraph-primary-medium' | 'paragraph-primary-small' | 'paragraph-secondary-large' | 'paragraph-secondary-medium' | 'paragraph-secondary-small' | 'promo-mobile-large' | 'promo-mobile-medium' | 'promo-mobile-small' | 'promo-mobile-xlarge' | 'promo-mobile-xsmall' | 'promo-system-mobile-large' | 'promo-system-mobile-medium' | 'promo-system-mobile-small' | 'promo-system-mobile-xlarge' | 'promo-system-mobile-xsmall' | 'promo-system-large' | 'promo-system-medium' | 'promo-system-small' | 'promo-system-xlarge' | 'promo-system-xsmall' | 'promo-large' | 'promo-medium' | 'promo-small' | 'promo-xlarge' | 'promo-xsmall' | 'accent-component' | 'action-component' | 'paragraph-component';
|
|
13
|
+
export { BackgroundColorType, BorderColorType, GraphicColorType, ShadowType, GapType, PaddingType, TypographyType };
|
package/cssm/index-a5b021bd.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from "react";
|
|
3
|
-
import { PaddingType } from "./index-
|
|
3
|
+
import { PaddingType } from "./index-064acd29";
|
|
4
4
|
/* eslint-disable no-plusplus, no-param-reassign */
|
|
5
5
|
import { MaskitoPlugin, MaskitoPostprocessor, MaskitoPreprocessor } from "@maskito/core";
|
|
6
6
|
import { useCustomWebkitScrollbar } from "./useCustomWebkitScrollbar-a216f694";
|
package/cssm/index.module.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
:root {
|
|
1
|
+
:root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
2
2
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
3
3
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root {
|
|
@@ -26,7 +26,7 @@ var PickerButtonMobile = React.forwardRef(function (_a, ref) {
|
|
|
26
26
|
showArrow: showArrow,
|
|
27
27
|
breakpoint: breakpoint,
|
|
28
28
|
};
|
|
29
|
-
return (React__default.default.createElement(mobile.SelectMobile, tslib.__assign({}, restProps, { label: label, Option: Option, bottomSheetProps: tslib.__assign({ title: label, stickyHeader: true }, bottomSheetProps), Field: Field, Optgroup: Optgroup, size: size === 'm' ?
|
|
29
|
+
return (React__default.default.createElement(mobile.SelectMobile, tslib.__assign({}, restProps, { label: label, Option: Option, bottomSheetProps: tslib.__assign({ title: label, stickyHeader: true }, bottomSheetProps), Field: Field, Optgroup: Optgroup, size: size === 'm' || size === 56 ? 56 : 48, closeOnSelect: true, fieldProps: tslib.__assign(tslib.__assign({}, fieldDefaultProps), fieldProps), ref: ref, options: options, selected: [] })));
|
|
30
30
|
});
|
|
31
31
|
|
|
32
32
|
exports.PickerButtonMobile = PickerButtonMobile;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
:root {
|
|
1
|
+
:root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
2
2
|
} /* deprecated */ :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
3
3
|
} :root { /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */ /* deprecated */
|
|
4
4
|
} :root {
|
package/cssm/types.d.ts
CHANGED
|
@@ -6,11 +6,11 @@ import { HandledEvents } from "react-swipeable/es/types";
|
|
|
6
6
|
import { TransitionProps } from "react-transition-group/Transition";
|
|
7
7
|
import { BaseModalProps } from "./index-bdb4c6b9";
|
|
8
8
|
import { NavigationBarProps } from "./types-667e33fd";
|
|
9
|
-
import { BackgroundColorType } from "./index-
|
|
9
|
+
import { BackgroundColorType } from "./index-064acd29";
|
|
10
10
|
import { BaseInputProps, BackdropProps } from "./index-ebda875c";
|
|
11
11
|
import { SwipeableHandlers } from "react-swipeable";
|
|
12
12
|
import { FormControlProps } from "./index-c44170fe";
|
|
13
|
-
import { ModalResponsiveProps as ModalProps } from "./typings-
|
|
13
|
+
import { ModalResponsiveProps as ModalProps } from "./typings-88b743b5";
|
|
14
14
|
import { PopoverProps } from "@alfalab/core-components-popover";
|
|
15
15
|
import { UseSelectWithApplyProps } from "./field/Component";
|
|
16
16
|
type BottomSheetTitleAlign = "center" | "left";
|
|
@@ -328,7 +328,7 @@ type FooterProps = {
|
|
|
328
328
|
gap?: 16 | 24 | 32;
|
|
329
329
|
};
|
|
330
330
|
declare const ModalResponsive: React.ForwardRefExoticComponent<import("./index-bdb4c6b9").BaseModalProps & {
|
|
331
|
-
size?: "s" | "m" | "l" | "xl" | "fullscreen" | undefined;
|
|
331
|
+
size?: "s" | "m" | "l" | "xl" | 500 | "fullscreen" | 600 | 800 | 1140 | undefined;
|
|
332
332
|
fullscreen?: boolean | undefined;
|
|
333
333
|
fixedPosition?: boolean | undefined;
|
|
334
334
|
hasCloser?: boolean | undefined;
|
|
@@ -337,7 +337,7 @@ declare const ModalResponsive: React.ForwardRefExoticComponent<import("./index-b
|
|
|
337
337
|
defaultMatchMediaValue?: boolean | (() => boolean) | undefined;
|
|
338
338
|
} & React.RefAttributes<HTMLDivElement>> & {
|
|
339
339
|
Header: React.FC<HeaderProps>;
|
|
340
|
-
Content: React.FC<import("./typings-
|
|
340
|
+
Content: React.FC<import("./typings-88b743b5").ContentProps>;
|
|
341
341
|
Footer: React.FC<FooterProps>;
|
|
342
342
|
Controls: React.FC<ControlsProps>;
|
|
343
343
|
};
|
|
@@ -491,12 +491,14 @@ type BaseSelectProps = {
|
|
|
491
491
|
multiple?: boolean;
|
|
492
492
|
/**
|
|
493
493
|
* Размер компонента
|
|
494
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
494
495
|
*/
|
|
495
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
496
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
496
497
|
/**
|
|
497
498
|
* Размер пунктов меню
|
|
499
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
498
500
|
*/
|
|
499
|
-
optionsSize?: 's' | 'm' | 'l' | 'xl';
|
|
501
|
+
optionsSize?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
500
502
|
/**
|
|
501
503
|
* Растягивает компонент на ширину контейнера
|
|
502
504
|
*/
|
|
@@ -761,8 +763,9 @@ type OptionsListProps = {
|
|
|
761
763
|
scrollbarClassName?: string;
|
|
762
764
|
/**
|
|
763
765
|
* Размер компонента
|
|
766
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
764
767
|
*/
|
|
765
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
768
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
766
769
|
/**
|
|
767
770
|
* Компонент пункта меню
|
|
768
771
|
*/
|
|
@@ -864,8 +867,9 @@ type OptgroupProps = {
|
|
|
864
867
|
className?: string;
|
|
865
868
|
/**
|
|
866
869
|
* Размер компонента
|
|
870
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
867
871
|
*/
|
|
868
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
872
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
869
873
|
/**
|
|
870
874
|
* Заголовок группы
|
|
871
875
|
*/
|
|
@@ -882,8 +886,9 @@ type OptionProps = {
|
|
|
882
886
|
className?: string;
|
|
883
887
|
/**
|
|
884
888
|
* Размер компонента
|
|
889
|
+
* @description s, m, l, xl deprecated, используйте вместо них 48, 56, 64, 72 соответственно
|
|
885
890
|
*/
|
|
886
|
-
size?: 's' | 'm' | 'l' | 'xl';
|
|
891
|
+
size?: 's' | 'm' | 'l' | 'xl' | 48 | 56 | 64 | 72;
|
|
887
892
|
/**
|
|
888
893
|
* Контент пункта меню
|
|
889
894
|
*/
|
|
@@ -1041,8 +1046,8 @@ type SelectProps = BaseSelectProps & AdditionalMobileProps & ConditionalMobilePr
|
|
|
1041
1046
|
};
|
|
1042
1047
|
export { BottomSheet, CLOSE_OFFSET, HEADER_OFFSET, InputProps, Input, ModalResponsive as Modal, getModalTestIds, FooterProps$0 as FooterProps, Footer$0 as Footer, HeaderProps$0 as HeaderProps, Header$0 as Header, SwipeableBackdropProps, SwipeableBackdrop, AnyObject, OptionShape, GroupShape, BaseSelectChangePayload, BaseSelectProps, FieldProps, ArrowProps, OptionsListProps, OptgroupProps, OptionProps, CheckmarkProps, SearchProps, SelectFieldProps, AdditionalMobileProps, BottomSheetSelectMobileProps, ModalSelectMobileProps, SelectModalMobileProps, SelectMobileProps, SelectDesktopProps, SelectProps };
|
|
1043
1048
|
export type { BottomSheetProps, BottomSheetTitleAlign, HeaderProps as ModalHeaderProps, FooterProps as ModalFooterProps };
|
|
1044
|
-
export { ModalResponsiveProps as ModalProps } from "./typings-
|
|
1049
|
+
export { ModalResponsiveProps as ModalProps } from "./typings-88b743b5";
|
|
1045
1050
|
export { ModalContext } from "./Context-c2e6f1b2";
|
|
1046
|
-
export type { ContentProps as ModalContentProps } from "./typings-
|
|
1051
|
+
export type { ContentProps as ModalContentProps } from "./typings-88b743b5";
|
|
1047
1052
|
export * from "./Component.desktop-63dec22f";
|
|
1048
1053
|
export * from "./Component.mobile-96988a65";
|
|
@@ -3,9 +3,10 @@ import { BaseModalProps } from "./index-bdb4c6b9";
|
|
|
3
3
|
type ModalDesktopProps = BaseModalProps & {
|
|
4
4
|
/**
|
|
5
5
|
* Ширина модального окна
|
|
6
|
-
* @default
|
|
6
|
+
* @default 600
|
|
7
|
+
* @description s, m, l, xl deprecated, используйте вместо них 500, 600, 800, 1140 соответственно
|
|
7
8
|
*/
|
|
8
|
-
size?: 's' | 'm' | 'l' | 'xl' | 'fullscreen';
|
|
9
|
+
size?: 's' | 'm' | 'l' | 'xl' | 'fullscreen' | 500 | 600 | 800 | 1140;
|
|
9
10
|
/**
|
|
10
11
|
* Растягивает модальное окно на весь экран
|
|
11
12
|
* @deprecated Используйте размер fullscreen
|
package/cssm/utils/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { FC, SVGProps } from 'react';
|
|
2
|
-
import {
|
|
3
|
-
declare const getIcon: (variant: PickerButtonVariant, size:
|
|
2
|
+
import { PickerButtonVariant } from "../types";
|
|
3
|
+
declare const getIcon: (variant: PickerButtonVariant, size: string) => FC<SVGProps<SVGSVGElement>>;
|
|
4
4
|
export { getIcon };
|
package/cssm/utils/index.js
CHANGED
|
@@ -9,9 +9,9 @@ var MoreSIcon = require('@alfalab/icons-glyph/MoreSIcon');
|
|
|
9
9
|
|
|
10
10
|
var getIcon = function (variant, size) {
|
|
11
11
|
if (variant === 'compact') {
|
|
12
|
-
return size === '
|
|
12
|
+
return size === 'size-32' ? MoreSIcon.MoreSIcon : MoreMIcon.MoreMIcon;
|
|
13
13
|
}
|
|
14
|
-
return size
|
|
14
|
+
return ['size-40', 'size-32'].includes(size) ? ChevronDownCompactSIcon.ChevronDownCompactSIcon : ChevronDownMIcon.ChevronDownMIcon;
|
|
15
15
|
};
|
|
16
16
|
|
|
17
17
|
exports.getIcon = getIcon;
|
package/cssm/utils-89376c31.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactNode, RefObject } from 'react';
|
|
2
|
-
import { BaseSelectProps, GroupShape, OptionShape } from "./typings-
|
|
2
|
+
import { BaseSelectProps, GroupShape, OptionShape } from "./typings-70284312";
|
|
3
3
|
declare const isGroup: (item: OptionShape | GroupShape) => item is GroupShape;
|
|
4
4
|
declare const isOptionShape: (item: OptionShape | string | null) => item is OptionShape;
|
|
5
5
|
declare const joinOptions: ({ selected, selectedMultiple, }: {
|
|
@@ -13,6 +13,7 @@ type PickerButtonDesktopProps = Omit<BaseSelectProps, 'placeholder' | 'Arrow' |
|
|
|
13
13
|
}>;
|
|
14
14
|
/**
|
|
15
15
|
* Размер кнопки
|
|
16
|
+
* @description xxs, xs, s, m, l, xl deprecated, используйте вместо них 32, 40, 48, 56, 64, 72 соответственно
|
|
16
17
|
*/
|
|
17
18
|
size?: PickerButtonSize;
|
|
18
19
|
/**
|
|
@@ -34,6 +35,7 @@ declare const PickerButtonDesktop: React.ForwardRefExoticComponent<Omit<BaseSele
|
|
|
34
35
|
}>;
|
|
35
36
|
/**
|
|
36
37
|
* Размер кнопки
|
|
38
|
+
* @description xxs, xs, s, m, l, xl deprecated, используйте вместо них 32, 40, 48, 56, 64, 72 соответственно
|
|
37
39
|
*/
|
|
38
40
|
size?: PickerButtonSize | undefined;
|
|
39
41
|
/**
|
|
@@ -15,13 +15,13 @@ function _interopDefaultCompat (e) { return e && typeof e === 'object' && 'defau
|
|
|
15
15
|
var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
16
16
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
17
17
|
|
|
18
|
-
var styles = {"container":"picker-
|
|
18
|
+
var styles = {"container":"picker-button__container_1v0ea","optionsPopover":"picker-button__optionsPopover_1v0ea","sideGap":"picker-button__sideGap_1v0ea","option":"picker-button__option_1v0ea"};
|
|
19
19
|
require('./../index.css')
|
|
20
20
|
|
|
21
21
|
var SIDE_POSITIONS = ['right', 'right-start', 'right-end', 'left', 'left-start', 'left-end'];
|
|
22
22
|
var PickerButtonDesktop = React.forwardRef(function (_a, ref) {
|
|
23
23
|
var _b;
|
|
24
|
-
var _c = _a.OptionsList, OptionsList = _c === void 0 ? shared.OptionsList : _c, _d = _a.Optgroup, Optgroup = _d === void 0 ? shared.Optgroup : _d, _e = _a.Option, Option = _e === void 0 ? option_Component.Option : _e, view = _a.view, loading = _a.loading, _f = _a.size, size = _f === void 0 ?
|
|
24
|
+
var _c = _a.OptionsList, OptionsList = _c === void 0 ? shared.OptionsList : _c, _d = _a.Optgroup, Optgroup = _d === void 0 ? shared.Optgroup : _d, _e = _a.Option, Option = _e === void 0 ? option_Component.Option : _e, view = _a.view, loading = _a.loading, _f = _a.size, size = _f === void 0 ? 56 : _f, _g = _a.variant, variant = _g === void 0 ? 'default' : _g, className = _a.className, leftAddons = _a.leftAddons, rightAddons = _a.rightAddons, popperClassName = _a.popperClassName, optionClassName = _a.optionClassName, showArrow = _a.showArrow, _h = _a.Field, Field = _h === void 0 ? field_Component.Field : _h, _j = _a.fieldProps, fieldProps = _j === void 0 ? {} : _j, restProps = tslib.__rest(_a, ["OptionsList", "Optgroup", "Option", "view", "loading", "size", "variant", "className", "leftAddons", "rightAddons", "popperClassName", "optionClassName", "showArrow", "Field", "fieldProps"]);
|
|
25
25
|
var isSideGap = !!restProps.popoverPosition && SIDE_POSITIONS.includes(restProps.popoverPosition);
|
|
26
26
|
var fieldDefaultProps = {
|
|
27
27
|
view: view,
|
|
@@ -34,7 +34,7 @@ var PickerButtonDesktop = React.forwardRef(function (_a, ref) {
|
|
|
34
34
|
showArrow: showArrow,
|
|
35
35
|
breakpoint: 1,
|
|
36
36
|
};
|
|
37
|
-
return (React__default.default.createElement(shared.BaseSelect, tslib.__assign({}, restProps, { Popover: coreComponentsPopover.Popover, view: 'desktop', optionProps: { Checkmark: null }, ref: ref, Option: Option, Field: Field, size: size === 'm' ?
|
|
37
|
+
return (React__default.default.createElement(shared.BaseSelect, tslib.__assign({}, restProps, { Popover: coreComponentsPopover.Popover, view: 'desktop', optionProps: { Checkmark: null }, ref: ref, Option: Option, Field: Field, size: size === 'm' || size === 56 ? 56 : 48, fieldProps: tslib.__assign(tslib.__assign({}, fieldDefaultProps), fieldProps), Optgroup: Optgroup, OptionsList: OptionsList, className: cn__default.default(styles.container, className), popperClassName: cn__default.default('cc-picker-button', styles.optionsPopover, popperClassName, (_b = {},
|
|
38
38
|
_b[styles.sideGap] = isSideGap,
|
|
39
39
|
_b)), optionClassName: cn__default.default(styles.option, optionClassName), selected: [], closeOnSelect: true })));
|
|
40
40
|
});
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { BackgroundColorType, GraphicColorType } from "./index-
|
|
3
|
+
import { BackgroundColorType, GraphicColorType } from "./index-064acd29";
|
|
4
4
|
type IconColorType = Extract<GraphicColorType, 'positive' | 'attention' | 'link' | 'negative' | 'tertiary' | 'secondary' | 'primary'>;
|
|
5
5
|
type BadgeProps = {
|
|
6
6
|
/**
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { OptgroupProps } from "./typings-
|
|
3
|
+
import { OptgroupProps } from "./typings-70284312";
|
|
4
4
|
declare const Optgroup: ({ children, className, label, size }: OptgroupProps) => React.JSX.Element;
|
|
5
5
|
export { Optgroup };
|