@alfalab/core-components-input-autocomplete 8.2.6 → 9.0.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-7ca84eff.d.ts +32 -19
- package/Component.d.ts +11 -11
- package/Component.js +3 -3
- package/Component.mobile.d.ts +7 -7
- package/Component.mobile.js +12 -14
- package/autocomplete-field/Component.js +8 -11
- package/autocomplete-field/index.css +2 -2
- package/autocomplete-field/index.js +2 -2
- package/autocomplete-mobile-field/Component.d.ts +1 -1
- package/autocomplete-mobile-field/Component.js +5 -5
- package/autocomplete-mobile-field/index.css +8 -8
- package/autocomplete-mobile-field/index.js +3 -3
- package/cssm/Component-7ca84eff.d.ts +32 -19
- package/cssm/Component.d.ts +11 -11
- package/cssm/Component.js +3 -3
- package/cssm/Component.mobile.d.ts +7 -7
- package/cssm/Component.mobile.js +11 -13
- package/cssm/autocomplete-field/Component.js +7 -10
- package/cssm/autocomplete-field/index.js +2 -2
- package/cssm/autocomplete-mobile-field/Component.d.ts +1 -1
- package/cssm/autocomplete-mobile-field/Component.js +4 -4
- package/cssm/autocomplete-mobile-field/index.js +3 -3
- package/cssm/index-7ca84eff.d.ts +1 -1
- package/cssm/index-bdb4c6b9.d.ts +6 -1
- package/cssm/index-ebda875c.d.ts +1 -1
- package/cssm/index.js +3 -3
- package/cssm/mobile.js +4 -4
- package/cssm/{tslib.es6-ce870b46.d.ts → tslib.es6-9682e485.d.ts} +8 -4
- package/{tslib.es6-5e3ffdb9.js → cssm/tslib.es6-9682e485.js} +1 -1
- package/esm/Component-7ca84eff.d.ts +32 -19
- package/esm/Component.d.ts +11 -11
- package/esm/Component.js +3 -3
- package/esm/Component.mobile.d.ts +7 -7
- package/esm/Component.mobile.js +11 -13
- package/esm/autocomplete-field/Component.js +7 -10
- package/esm/autocomplete-field/index.css +2 -2
- package/esm/autocomplete-field/index.js +2 -2
- package/esm/autocomplete-mobile-field/Component.d.ts +1 -1
- package/esm/autocomplete-mobile-field/Component.js +4 -4
- package/esm/autocomplete-mobile-field/index.css +8 -8
- package/esm/autocomplete-mobile-field/index.js +3 -3
- package/esm/index-7ca84eff.d.ts +1 -1
- package/esm/index-bdb4c6b9.d.ts +6 -1
- package/esm/index-ebda875c.d.ts +1 -1
- package/esm/index.js +3 -3
- package/esm/mobile.css +4 -4
- package/esm/mobile.js +4 -4
- package/{tslib.es6-5e3ffdb9.d.ts → esm/tslib.es6-e57054c9.d.ts} +8 -4
- package/esm/{tslib.es6-ebe4326a.js → tslib.es6-e57054c9.js} +1 -1
- package/index-7ca84eff.d.ts +1 -1
- package/index-bdb4c6b9.d.ts +6 -1
- package/index-ebda875c.d.ts +1 -1
- package/index.js +3 -3
- package/mobile.css +4 -4
- package/mobile.js +4 -4
- package/modern/Component-7ca84eff.d.ts +32 -19
- package/modern/Component.d.ts +11 -11
- package/modern/Component.js +4 -4
- package/modern/Component.mobile.d.ts +7 -7
- package/modern/Component.mobile.js +15 -17
- package/modern/autocomplete-field/Component.js +7 -10
- package/modern/autocomplete-field/index.css +2 -2
- package/modern/autocomplete-field/index.js +1 -1
- package/modern/autocomplete-mobile-field/Component.d.ts +1 -1
- package/modern/autocomplete-mobile-field/Component.js +5 -5
- package/modern/autocomplete-mobile-field/index.css +8 -8
- package/modern/autocomplete-mobile-field/index.js +2 -2
- package/modern/index-7ca84eff.d.ts +1 -1
- package/modern/index-bdb4c6b9.d.ts +6 -1
- package/modern/index-ebda875c.d.ts +1 -1
- package/modern/index.js +2 -2
- package/modern/mobile.css +4 -4
- package/modern/mobile.js +3 -3
- package/package.json +5 -5
- package/{esm/tslib.es6-ebe4326a.d.ts → tslib.es6-7eb75557.d.ts} +8 -4
- package/{cssm/tslib.es6-ce870b46.js → tslib.es6-7eb75557.js} +1 -1
package/cssm/Component.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import {
|
|
3
|
+
import { ChangeEvent, FC, RefAttributes } from "react";
|
|
4
4
|
import { InputProps } from "@alfalab/core-components-input";
|
|
5
5
|
import { BaseSelectProps } from "@alfalab/core-components-select";
|
|
6
6
|
type InputAutocompleteProps = Omit<BaseSelectProps, 'Field' | 'nativeSelect'> & {
|
|
@@ -33,11 +33,11 @@ type InputAutocompleteProps = Omit<BaseSelectProps, 'Field' | 'nativeSelect'> &
|
|
|
33
33
|
*/
|
|
34
34
|
updatePopover?: BaseSelectProps['updatePopover'];
|
|
35
35
|
};
|
|
36
|
-
declare const InputAutocomplete: React.ForwardRefExoticComponent<
|
|
36
|
+
declare const InputAutocomplete: React.ForwardRefExoticComponent<Omit<BaseSelectProps, "nativeSelect" | "Field"> & {
|
|
37
37
|
/**
|
|
38
38
|
* Компонент ввода значения
|
|
39
39
|
*/
|
|
40
|
-
Input?: React.FC<
|
|
40
|
+
Input?: React.FC<Omit<React.InputHTMLAttributes<HTMLInputElement>, "type" | "onClick" | "value" | "onMouseDown" | "defaultValue" | "onChange" | "size" | "enterKeyHint"> & {
|
|
41
41
|
value?: string | undefined;
|
|
42
42
|
defaultValue?: string | undefined;
|
|
43
43
|
block?: boolean | undefined;
|
|
@@ -49,8 +49,8 @@ declare const InputAutocomplete: React.ForwardRefExoticComponent<Pick<BaseSelect
|
|
|
49
49
|
hint?: React.ReactNode;
|
|
50
50
|
label?: React.ReactNode;
|
|
51
51
|
labelView?: "inner" | "outer" | undefined;
|
|
52
|
-
type?: "number" | "text" | "tel" | "email" | "
|
|
53
|
-
wrapperRef?:
|
|
52
|
+
type?: "number" | "text" | "tel" | "email" | "password" | "card" | "money" | undefined;
|
|
53
|
+
wrapperRef?: React.Ref<HTMLDivElement> | undefined;
|
|
54
54
|
leftAddons?: React.ReactNode;
|
|
55
55
|
rightAddons?: React.ReactNode;
|
|
56
56
|
bottomAddons?: React.ReactNode;
|
|
@@ -73,7 +73,7 @@ declare const InputAutocomplete: React.ForwardRefExoticComponent<Pick<BaseSelect
|
|
|
73
73
|
/**
|
|
74
74
|
* Пропсы, которые будут прокинуты в инпут
|
|
75
75
|
*/
|
|
76
|
-
inputProps?: (
|
|
76
|
+
inputProps?: (Omit<React.InputHTMLAttributes<HTMLInputElement>, "type" | "onClick" | "value" | "onMouseDown" | "defaultValue" | "onChange" | "size" | "enterKeyHint"> & {
|
|
77
77
|
value?: string | undefined;
|
|
78
78
|
defaultValue?: string | undefined;
|
|
79
79
|
block?: boolean | undefined;
|
|
@@ -85,8 +85,8 @@ declare const InputAutocomplete: React.ForwardRefExoticComponent<Pick<BaseSelect
|
|
|
85
85
|
hint?: React.ReactNode;
|
|
86
86
|
label?: React.ReactNode;
|
|
87
87
|
labelView?: "inner" | "outer" | undefined;
|
|
88
|
-
type?: "number" | "text" | "tel" | "email" | "
|
|
89
|
-
wrapperRef?:
|
|
88
|
+
type?: "number" | "text" | "tel" | "email" | "password" | "card" | "money" | undefined;
|
|
89
|
+
wrapperRef?: React.Ref<HTMLDivElement> | undefined;
|
|
90
90
|
leftAddons?: React.ReactNode;
|
|
91
91
|
rightAddons?: React.ReactNode;
|
|
92
92
|
bottomAddons?: React.ReactNode;
|
|
@@ -113,7 +113,7 @@ declare const InputAutocomplete: React.ForwardRefExoticComponent<Pick<BaseSelect
|
|
|
113
113
|
/**
|
|
114
114
|
* Поле доступно только для чтения
|
|
115
115
|
*/
|
|
116
|
-
readOnly?:
|
|
116
|
+
readOnly?: InputProps['readOnly'];
|
|
117
117
|
/**
|
|
118
118
|
* Отображение иконки успеха
|
|
119
119
|
*/
|
|
@@ -121,10 +121,10 @@ declare const InputAutocomplete: React.ForwardRefExoticComponent<Pick<BaseSelect
|
|
|
121
121
|
/**
|
|
122
122
|
* Обработчик ввода
|
|
123
123
|
*/
|
|
124
|
-
onInput?: ((event:
|
|
124
|
+
onInput?: ((event: ChangeEvent<HTMLInputElement>) => void) | undefined;
|
|
125
125
|
/**
|
|
126
126
|
* Хранит функцию, с помощью которой можно обновить положение поповера
|
|
127
127
|
*/
|
|
128
|
-
updatePopover?:
|
|
128
|
+
updatePopover?: BaseSelectProps['updatePopover'];
|
|
129
129
|
} & React.RefAttributes<HTMLInputElement>>;
|
|
130
130
|
export { InputAutocompleteProps, InputAutocomplete };
|
package/cssm/Component.js
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var tslib_es6 = require('./tslib.es6-
|
|
6
|
-
require('classnames');
|
|
5
|
+
var tslib_es6 = require('./tslib.es6-9682e485.js');
|
|
7
6
|
var React = require('react');
|
|
8
7
|
require('react-merge-refs');
|
|
9
|
-
|
|
8
|
+
require('classnames');
|
|
10
9
|
require('@alfalab/core-components-input/cssm');
|
|
10
|
+
var coreComponentsSelect = require('@alfalab/core-components-select/cssm');
|
|
11
11
|
require('./autocomplete-field/index.module.css');
|
|
12
12
|
var autocompleteField_Component = require('./autocomplete-field/Component.js');
|
|
13
13
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { ChangeEvent, ElementType } from "react";
|
|
4
|
-
import { BaseSelectProps, BaseSelectChangePayload } from "@alfalab/core-components-select";
|
|
5
|
-
import { ButtonProps } from "@alfalab/core-components-button";
|
|
6
4
|
import { BottomSheetProps } from "./index-7ca84eff";
|
|
5
|
+
import { ButtonProps } from "@alfalab/core-components-button";
|
|
6
|
+
import { BaseSelectChangePayload, BaseSelectProps } from "@alfalab/core-components-select";
|
|
7
7
|
type InputAutocompleteMobileProps = Omit<BaseSelectProps, 'OptionsList' | 'Checkmark' | 'onScroll' | 'selected' | 'nativeSelect' | 'multiple' | 'autocomplete' | 'valueRenderer' | 'allowUnselect'> & {
|
|
8
8
|
/**
|
|
9
9
|
* Обработчик выбора
|
|
@@ -50,7 +50,7 @@ type InputAutocompleteMobileProps = Omit<BaseSelectProps, 'OptionsList' | 'Check
|
|
|
50
50
|
*/
|
|
51
51
|
Input?: ElementType;
|
|
52
52
|
};
|
|
53
|
-
declare const InputAutocompleteMobile: React.ForwardRefExoticComponent<
|
|
53
|
+
declare const InputAutocompleteMobile: React.ForwardRefExoticComponent<Omit<BaseSelectProps, "onScroll" | "selected" | "multiple" | "valueRenderer" | "autocomplete" | "allowUnselect" | "nativeSelect" | "OptionsList" | "Checkmark"> & {
|
|
54
54
|
/**
|
|
55
55
|
* Обработчик выбора
|
|
56
56
|
*/
|
|
@@ -58,7 +58,7 @@ declare const InputAutocompleteMobile: React.ForwardRefExoticComponent<Pick<Base
|
|
|
58
58
|
/**
|
|
59
59
|
* Обработчик ввода фильтра.
|
|
60
60
|
*/
|
|
61
|
-
onFilter: (event:
|
|
61
|
+
onFilter: (event: ChangeEvent<HTMLInputElement>) => void;
|
|
62
62
|
/**
|
|
63
63
|
* Значение поля ввода
|
|
64
64
|
*/
|
|
@@ -86,14 +86,14 @@ declare const InputAutocompleteMobile: React.ForwardRefExoticComponent<Pick<Base
|
|
|
86
86
|
/**
|
|
87
87
|
* Дополнительные пропсы на кнопку "продолжить"
|
|
88
88
|
*/
|
|
89
|
-
continueButtonProps?:
|
|
89
|
+
continueButtonProps?: ButtonProps | undefined;
|
|
90
90
|
/**
|
|
91
91
|
* Дополнительные пропсы на кнопку "отмена"
|
|
92
92
|
*/
|
|
93
|
-
cancelButtonProps?:
|
|
93
|
+
cancelButtonProps?: ButtonProps | undefined;
|
|
94
94
|
/**
|
|
95
95
|
* Кастомный инпут
|
|
96
96
|
*/
|
|
97
|
-
Input?:
|
|
97
|
+
Input?: React.ElementType<any> | undefined;
|
|
98
98
|
} & React.RefAttributes<unknown>>;
|
|
99
99
|
export { InputAutocompleteMobileProps, InputAutocompleteMobile };
|
package/cssm/Component.mobile.js
CHANGED
|
@@ -2,25 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var tslib_es6 = require('./tslib.es6-
|
|
6
|
-
var cn = require('classnames');
|
|
5
|
+
var tslib_es6 = require('./tslib.es6-9682e485.js');
|
|
7
6
|
var React = require('react');
|
|
8
7
|
var mergeRefs = require('react-merge-refs');
|
|
8
|
+
var cn = require('classnames');
|
|
9
9
|
var throttle = require('lodash.throttle');
|
|
10
|
-
var coreComponentsSelect = require('@alfalab/core-components-select/cssm');
|
|
11
10
|
var coreComponentsButton = require('@alfalab/core-components-button/cssm');
|
|
12
11
|
var coreComponentsInput = require('@alfalab/core-components-input/cssm');
|
|
13
|
-
require('@alfalab/
|
|
12
|
+
var coreComponentsSelect = require('@alfalab/core-components-select/cssm');
|
|
14
13
|
require('@alfalab/core-components-form-control/cssm');
|
|
14
|
+
require('@alfalab/hooks');
|
|
15
15
|
require('./autocomplete-mobile-field/index.module.css');
|
|
16
16
|
var autocompleteMobileField_Component = require('./autocomplete-mobile-field/Component.js');
|
|
17
17
|
var styles = require('./mobile.module.css');
|
|
18
18
|
|
|
19
19
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
20
20
|
|
|
21
|
-
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
22
21
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
23
22
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultLegacy(mergeRefs);
|
|
23
|
+
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
24
24
|
var throttle__default = /*#__PURE__*/_interopDefaultLegacy(throttle);
|
|
25
25
|
var styles__default = /*#__PURE__*/_interopDefaultLegacy(styles);
|
|
26
26
|
|
|
@@ -41,14 +41,12 @@ var InputAutocompleteMobile = React__default['default'].forwardRef(function (_a,
|
|
|
41
41
|
var handleOpen = function (payload) {
|
|
42
42
|
setBottomSheetVisibility(Boolean(payload.open));
|
|
43
43
|
};
|
|
44
|
-
var handleOptionsListTouchMove = React.useMemo(function () {
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}, 300);
|
|
51
|
-
}, []);
|
|
44
|
+
var handleOptionsListTouchMove = React.useMemo(function () { return throttle__default['default'](function () {
|
|
45
|
+
var input = bottomSheetInputRef.current;
|
|
46
|
+
if (input && document.activeElement === input) {
|
|
47
|
+
input.blur();
|
|
48
|
+
}
|
|
49
|
+
}, 300); }, []);
|
|
52
50
|
var handleChange = function () {
|
|
53
51
|
setBottomSheetVisibility(false);
|
|
54
52
|
onChange(filter);
|
|
@@ -2,18 +2,18 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var tslib_es6 = require('../tslib.es6-
|
|
6
|
-
var cn = require('classnames');
|
|
5
|
+
var tslib_es6 = require('../tslib.es6-9682e485.js');
|
|
7
6
|
var React = require('react');
|
|
8
7
|
var mergeRefs = require('react-merge-refs');
|
|
8
|
+
var cn = require('classnames');
|
|
9
9
|
var coreComponentsInput = require('@alfalab/core-components-input/cssm');
|
|
10
10
|
var styles = require('./index.module.css');
|
|
11
11
|
|
|
12
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
13
13
|
|
|
14
|
-
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
15
14
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
16
15
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultLegacy(mergeRefs);
|
|
16
|
+
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
17
17
|
var styles__default = /*#__PURE__*/_interopDefaultLegacy(styles);
|
|
18
18
|
|
|
19
19
|
var AutocompleteField = function (_a) {
|
|
@@ -29,13 +29,10 @@ var AutocompleteField = function (_a) {
|
|
|
29
29
|
inputRef.current.focus();
|
|
30
30
|
}
|
|
31
31
|
}, [onClick]);
|
|
32
|
-
return (React__default['default'].createElement(Input, tslib_es6.__assign({}, inputProps, innerProps, {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-ignore
|
|
37
|
-
// @ts-ignore
|
|
38
|
-
ref: mergeRefs__default['default']([inputRef, inputProps.ref]), disabled: disabled, readOnly: readOnly, block: true, label: label, labelView: labelView, placeholder: placeholder, size: size, error: error, success: success, hint: hint, onChange: onInput, onClick: inputDisabled ? undefined : handleClick, onFocus: inputDisabled ? undefined : onFocus, autoComplete: 'off', value: value, rightAddons: (Arrow || inputProps.rightAddons) && (React__default['default'].createElement(React__default['default'].Fragment, null,
|
|
32
|
+
return (React__default['default'].createElement(Input, tslib_es6.__assign({}, inputProps, innerProps, { wrapperRef: mergeRefs__default['default']([
|
|
33
|
+
innerProps.ref,
|
|
34
|
+
inputProps.wrapperRef,
|
|
35
|
+
]), ref: mergeRefs__default['default']([inputRef, inputProps.ref]), disabled: disabled, readOnly: readOnly, block: true, label: label, labelView: labelView, placeholder: placeholder, size: size, error: error, success: success, hint: hint, onChange: onInput, onClick: inputDisabled ? undefined : handleClick, onFocus: inputDisabled ? undefined : onFocus, autoComplete: 'off', value: value, rightAddons: (Arrow || inputProps.rightAddons) && (React__default['default'].createElement(React__default['default'].Fragment, null,
|
|
39
36
|
inputProps.rightAddons,
|
|
40
37
|
Arrow && (React__default['default'].createElement("span", { className: cn__default['default'](styles__default['default'].arrow, (_b = {},
|
|
41
38
|
_b[styles__default['default'].error] = error,
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
require('../tslib.es6-
|
|
6
|
-
require('classnames');
|
|
5
|
+
require('../tslib.es6-9682e485.js');
|
|
7
6
|
require('react');
|
|
8
7
|
require('react-merge-refs');
|
|
8
|
+
require('classnames');
|
|
9
9
|
require('@alfalab/core-components-input/cssm');
|
|
10
10
|
require('./index.module.css');
|
|
11
11
|
var autocompleteField_Component = require('./Component.js');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
2
|
import { FormControlProps } from "@alfalab/core-components-form-control";
|
|
3
|
-
import { FieldProps as BaseFieldProps } from "@alfalab/core-components-select";
|
|
4
3
|
import { InputAutocompleteProps } from "../index";
|
|
4
|
+
import { FieldProps as BaseFieldProps } from "@alfalab/core-components-select";
|
|
5
5
|
type AutocompleteMobileFieldProps = FormControlProps & Omit<BaseFieldProps, 'selected' | 'multiple' | 'success'> & Pick<InputAutocompleteProps, 'value'>;
|
|
6
6
|
declare const AutocompleteMobileField: ({ size, open, error, hint, disabled, label, labelView, placeholder, value, innerProps, dataTestId, fieldClassName, Arrow, valueRenderer, toggleMenu, setSelectedItems, selectedMultiple, ...restProps }: AutocompleteMobileFieldProps) => JSX.Element;
|
|
7
7
|
export { AutocompleteMobileFieldProps, AutocompleteMobileField };
|
|
@@ -2,17 +2,17 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
var tslib_es6 = require('../tslib.es6-
|
|
6
|
-
var cn = require('classnames');
|
|
5
|
+
var tslib_es6 = require('../tslib.es6-9682e485.js');
|
|
7
6
|
var React = require('react');
|
|
8
|
-
var
|
|
7
|
+
var cn = require('classnames');
|
|
9
8
|
var coreComponentsFormControl = require('@alfalab/core-components-form-control/cssm');
|
|
9
|
+
var hooks = require('@alfalab/hooks');
|
|
10
10
|
var styles = require('./index.module.css');
|
|
11
11
|
|
|
12
12
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
13
13
|
|
|
14
|
-
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
15
14
|
var React__default = /*#__PURE__*/_interopDefaultLegacy(React);
|
|
15
|
+
var cn__default = /*#__PURE__*/_interopDefaultLegacy(cn);
|
|
16
16
|
var styles__default = /*#__PURE__*/_interopDefaultLegacy(styles);
|
|
17
17
|
|
|
18
18
|
var AutocompleteMobileField = function (_a) {
|
|
@@ -2,11 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
require('../tslib.es6-
|
|
6
|
-
require('classnames');
|
|
5
|
+
require('../tslib.es6-9682e485.js');
|
|
7
6
|
require('react');
|
|
8
|
-
require('
|
|
7
|
+
require('classnames');
|
|
9
8
|
require('@alfalab/core-components-form-control/cssm');
|
|
9
|
+
require('@alfalab/hooks');
|
|
10
10
|
require('./index.module.css');
|
|
11
11
|
var autocompleteMobileField_Component = require('./Component.js');
|
|
12
12
|
|
package/cssm/index-7ca84eff.d.ts
CHANGED
|
@@ -4,8 +4,8 @@ import React from "react";
|
|
|
4
4
|
import { HTMLAttributes, ReactNode, FC } from "react";
|
|
5
5
|
import { TransitionProps } from "react-transition-group/Transition";
|
|
6
6
|
import { BaseModalProps } from "./index-bdb4c6b9";
|
|
7
|
-
import { BackdropProps } from "./index-ebda875c";
|
|
8
7
|
import { SwipeableHandlers } from "react-swipeable/types";
|
|
8
|
+
import { BackdropProps } from "./index-ebda875c";
|
|
9
9
|
type BottomSheetTitleAlign = "center" | "left";
|
|
10
10
|
type BottomSheetProps = {
|
|
11
11
|
/**
|
package/cssm/index-bdb4c6b9.d.ts
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/// <reference types="react" />
|
|
3
3
|
/* eslint-disable jsx-a11y/no-noninteractive-element-interactions */
|
|
4
4
|
import React from "react";
|
|
5
|
-
import {
|
|
5
|
+
import { FC, KeyboardEvent, MouseEvent, MutableRefObject, ReactNode, Ref, RefObject } from "react";
|
|
6
6
|
import { TransitionProps } from "react-transition-group/Transition";
|
|
7
7
|
import { BackdropProps } from "./index-ebda875c";
|
|
8
8
|
type PortalProps = {
|
|
@@ -12,6 +12,10 @@ type PortalProps = {
|
|
|
12
12
|
* Функция, возвращающая контейнер, в который будут рендериться дочерние элементы
|
|
13
13
|
*/
|
|
14
14
|
getPortalContainer?: () => Element;
|
|
15
|
+
/**
|
|
16
|
+
* Немедленно отрендерить дочерние элементы (false - контент будет отрендерен на след. рендер).
|
|
17
|
+
*/
|
|
18
|
+
immediateMount?: boolean;
|
|
15
19
|
};
|
|
16
20
|
type BaseModalProps = {
|
|
17
21
|
/**
|
|
@@ -139,6 +143,7 @@ type BaseModalContext = {
|
|
|
139
143
|
setHasFooter: (exists: boolean) => void;
|
|
140
144
|
onClose: Required<BaseModalProps>["onClose"];
|
|
141
145
|
};
|
|
146
|
+
// eslint-disable-next-line @typescript-eslint/no-redeclare
|
|
142
147
|
declare const BaseModalContext: React.Context<BaseModalContext>;
|
|
143
148
|
declare const BaseModal: React.ForwardRefExoticComponent<BaseModalProps & React.RefAttributes<HTMLDivElement>>;
|
|
144
149
|
declare function isScrolledToTop(target: HTMLElement): boolean;
|
package/cssm/index-ebda875c.d.ts
CHANGED
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
/// <reference types="react" />
|
|
3
3
|
import React from "react";
|
|
4
4
|
import { MouseEvent, ReactNode } from "react";
|
|
5
|
-
import { TransitionProps } from "react-transition-group/Transition";
|
|
6
5
|
import { CSSTransitionClassNames } from "react-transition-group/CSSTransition";
|
|
6
|
+
import { TransitionProps } from "react-transition-group/Transition";
|
|
7
7
|
type BackdropProps = Partial<TransitionProps> & {
|
|
8
8
|
/**
|
|
9
9
|
* Прозрачный бэкдроп
|
package/cssm/index.js
CHANGED
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
require('./tslib.es6-
|
|
6
|
-
require('classnames');
|
|
5
|
+
require('./tslib.es6-9682e485.js');
|
|
7
6
|
require('react');
|
|
8
7
|
require('react-merge-refs');
|
|
9
|
-
require('
|
|
8
|
+
require('classnames');
|
|
10
9
|
require('@alfalab/core-components-input/cssm');
|
|
10
|
+
require('@alfalab/core-components-select/cssm');
|
|
11
11
|
require('./autocomplete-field/index.module.css');
|
|
12
12
|
require('./autocomplete-field/Component.js');
|
|
13
13
|
var Component = require('./Component.js');
|
package/cssm/mobile.js
CHANGED
|
@@ -2,16 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
|
-
require('./tslib.es6-
|
|
6
|
-
require('classnames');
|
|
5
|
+
require('./tslib.es6-9682e485.js');
|
|
7
6
|
require('react');
|
|
8
7
|
require('react-merge-refs');
|
|
8
|
+
require('classnames');
|
|
9
9
|
require('lodash.throttle');
|
|
10
|
-
require('@alfalab/core-components-select/cssm');
|
|
11
10
|
require('@alfalab/core-components-button/cssm');
|
|
12
11
|
require('@alfalab/core-components-input/cssm');
|
|
13
|
-
require('@alfalab/
|
|
12
|
+
require('@alfalab/core-components-select/cssm');
|
|
14
13
|
require('@alfalab/core-components-form-control/cssm');
|
|
14
|
+
require('@alfalab/hooks');
|
|
15
15
|
require('./autocomplete-mobile-field/index.module.css');
|
|
16
16
|
require('./autocomplete-mobile-field/Component.js');
|
|
17
17
|
require('./mobile.module.css');
|
|
@@ -12,9 +12,12 @@ declare function __generator(thisArg: any, body: any): {
|
|
|
12
12
|
declare function __exportStar(m: any, o: any): void;
|
|
13
13
|
declare function __values(o: any): any;
|
|
14
14
|
declare function __read(o: any, n: any): any;
|
|
15
|
+
/** @deprecated */
|
|
15
16
|
declare function __spread(...args: any[]): any[];
|
|
17
|
+
/** @deprecated */
|
|
16
18
|
declare function __spreadArrays(...args: any[]): any[];
|
|
17
|
-
declare function
|
|
19
|
+
declare function __spreadArray(to: any, from: any, pack: any, ...args: any[]): any;
|
|
20
|
+
declare function __await(v: any): __await;
|
|
18
21
|
declare class __await {
|
|
19
22
|
constructor(v: any);
|
|
20
23
|
v: any;
|
|
@@ -25,8 +28,9 @@ declare function __asyncValues(o: any): any;
|
|
|
25
28
|
declare function __makeTemplateObject(cooked: any, raw: any): any;
|
|
26
29
|
declare function __importStar(mod: any): any;
|
|
27
30
|
declare function __importDefault(mod: any): any;
|
|
28
|
-
declare function __classPrivateFieldGet(receiver: any,
|
|
29
|
-
declare function __classPrivateFieldSet(receiver: any,
|
|
31
|
+
declare function __classPrivateFieldGet(receiver: any, state: any, kind: any, f: any): any;
|
|
32
|
+
declare function __classPrivateFieldSet(receiver: any, state: any, value: any, kind: any, f: any): any;
|
|
33
|
+
declare function __classPrivateFieldIn(state: any, receiver: any): any;
|
|
30
34
|
declare function __assign(...args: any[]): any;
|
|
31
35
|
declare function __createBinding(o: any, m: any, k: any, k2: any): void;
|
|
32
|
-
export { __extends, __rest, __decorate, __param, __metadata, __awaiter, __generator, __exportStar, __values, __read, __spread, __spreadArrays, __await, __asyncGenerator, __asyncDelegator, __asyncValues, __makeTemplateObject, __importStar, __importDefault, __classPrivateFieldGet, __classPrivateFieldSet, __assign, __createBinding };
|
|
36
|
+
export { __extends, __rest, __decorate, __param, __metadata, __awaiter, __generator, __exportStar, __values, __read, __spread, __spreadArrays, __spreadArray, __await, __asyncGenerator, __asyncDelegator, __asyncValues, __makeTemplateObject, __importStar, __importDefault, __classPrivateFieldGet, __classPrivateFieldSet, __classPrivateFieldIn, __assign, __createBinding };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
/******************************************************************************
|
|
4
4
|
Copyright (c) Microsoft Corporation.
|
|
5
5
|
|
|
6
6
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
@@ -49,18 +49,27 @@ type CloserProps = ButtonHTMLAttributes<HTMLButtonElement> & {
|
|
|
49
49
|
icon?: ElementType;
|
|
50
50
|
};
|
|
51
51
|
declare const Closer: React.FC<CloserProps>;
|
|
52
|
-
declare const colors: readonly [
|
|
52
|
+
declare const colors: readonly [
|
|
53
|
+
"tertiary",
|
|
54
|
+
"disabled",
|
|
55
|
+
"accent",
|
|
56
|
+
"primary",
|
|
57
|
+
"attention",
|
|
58
|
+
"positive",
|
|
59
|
+
"secondary",
|
|
60
|
+
"tertiary-inverted",
|
|
61
|
+
"primary-inverted",
|
|
62
|
+
"secondary-inverted",
|
|
63
|
+
"link",
|
|
64
|
+
"negative"
|
|
65
|
+
];
|
|
53
66
|
type Color = typeof colors[number];
|
|
54
|
-
type NativeProps = HTMLAttributes<
|
|
55
|
-
type
|
|
56
|
-
/**
|
|
57
|
-
* HTML тег
|
|
58
|
-
*/
|
|
59
|
-
tag: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "div";
|
|
67
|
+
type NativeProps = HTMLAttributes<HTMLSpanElement>;
|
|
68
|
+
type TextProps = Omit<NativeProps, "color"> & {
|
|
60
69
|
/**
|
|
61
70
|
* [Вариант начертания](https://alfa-laboratory.github.io/core-components/master/?path=/docs/гайдлайны-типографика--page)
|
|
62
71
|
*/
|
|
63
|
-
view?: "
|
|
72
|
+
view?: "primary-large" | "primary-medium" | "primary-small" | "secondary-large" | "secondary-medium" | "secondary-small" | "component" | "caps";
|
|
64
73
|
/**
|
|
65
74
|
* Цвет текста
|
|
66
75
|
*/
|
|
@@ -70,13 +79,13 @@ type TitleProps = Omit<NativeProps, "color"> & {
|
|
|
70
79
|
*/
|
|
71
80
|
weight?: "regular" | "medium" | "bold";
|
|
72
81
|
/**
|
|
73
|
-
*
|
|
82
|
+
* Делает цифры моноширинными
|
|
74
83
|
*/
|
|
75
|
-
|
|
84
|
+
monospaceNumbers?: boolean;
|
|
76
85
|
/**
|
|
77
|
-
*
|
|
86
|
+
* HTML тег
|
|
78
87
|
*/
|
|
79
|
-
|
|
88
|
+
tag?: "p" | "span" | "div";
|
|
80
89
|
/**
|
|
81
90
|
* Css-класс для стилизации (native prop)
|
|
82
91
|
*/
|
|
@@ -90,12 +99,16 @@ type TitleProps = Omit<NativeProps, "color"> & {
|
|
|
90
99
|
*/
|
|
91
100
|
children?: React.ReactNode;
|
|
92
101
|
};
|
|
93
|
-
type NativeProps$0 = HTMLAttributes<
|
|
94
|
-
type
|
|
102
|
+
type NativeProps$0 = HTMLAttributes<HTMLHeadingElement>;
|
|
103
|
+
type TitleProps = Omit<NativeProps$0, "color"> & {
|
|
104
|
+
/**
|
|
105
|
+
* HTML тег
|
|
106
|
+
*/
|
|
107
|
+
tag: "h1" | "h2" | "h3" | "h4" | "h5" | "h6" | "div";
|
|
95
108
|
/**
|
|
96
109
|
* [Вариант начертания](https://alfa-laboratory.github.io/core-components/master/?path=/docs/гайдлайны-типографика--page)
|
|
97
110
|
*/
|
|
98
|
-
view?: "
|
|
111
|
+
view?: "xlarge" | "large" | "medium" | "small" | "xsmall";
|
|
99
112
|
/**
|
|
100
113
|
* Цвет текста
|
|
101
114
|
*/
|
|
@@ -105,13 +118,13 @@ type TextProps = Omit<NativeProps$0, "color"> & {
|
|
|
105
118
|
*/
|
|
106
119
|
weight?: "regular" | "medium" | "bold";
|
|
107
120
|
/**
|
|
108
|
-
*
|
|
121
|
+
* Шрифт текста
|
|
109
122
|
*/
|
|
110
|
-
|
|
123
|
+
font?: "styrene" | "system";
|
|
111
124
|
/**
|
|
112
|
-
*
|
|
125
|
+
* Добавляет отступы
|
|
113
126
|
*/
|
|
114
|
-
|
|
127
|
+
defaultMargins?: boolean;
|
|
115
128
|
/**
|
|
116
129
|
* Css-класс для стилизации (native prop)
|
|
117
130
|
*/
|