@alfalab/core-components-number-input 1.2.5 → 1.2.6

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.
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import React from "react";
3
3
  import { FC } from "react";
4
- import { BaseButtonProps } from "./typings-9211a437";
4
+ import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
5
5
  type SpinnerProps = {
6
6
  /**
7
7
  * Управление видимостью компонента
@@ -34,5 +34,5 @@ declare const Spinner: FC<SpinnerProps>;
34
34
  * чтобы при быстрых ответах от сервера кнопка не «моргала».
35
35
  */
36
36
  declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
37
- declare const BaseButton: React.ForwardRefExoticComponent<BaseButtonProps & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
37
+ declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
38
38
  export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import React from "react";
3
3
  import { FC } from "react";
4
- import { BaseButtonProps } from "./typings-9211a437";
4
+ import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
5
5
  type SpinnerProps = {
6
6
  /**
7
7
  * Управление видимостью компонента
@@ -34,5 +34,5 @@ declare const Spinner: FC<SpinnerProps>;
34
34
  * чтобы при быстрых ответах от сервера кнопка не «моргала».
35
35
  */
36
36
  declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
37
- declare const BaseButton: React.ForwardRefExoticComponent<BaseButtonProps & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
37
+ declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
38
38
  export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
@@ -10,10 +10,6 @@ declare function easeInOutQuad(x: number): number;
10
10
  declare const easingFns: {
11
11
  easeInOutQuad: typeof easeInOutQuad;
12
12
  };
13
- declare function disableUserInput<T>(disabled: boolean | undefined, event: React.KeyboardEvent<T>): void;
14
- declare const inputUtils: {
15
- disableUserInput: typeof disableUserInput;
16
- };
17
13
  /**
18
14
  * Возвращает true, если значение равно null или undefined
19
15
  */
@@ -51,4 +47,4 @@ declare const maskUtils: {
51
47
  prefixPostprocessor: typeof prefixPostprocessor;
52
48
  caretGuard: typeof caretGuard;
53
49
  };
54
- export { isClient, getDataTestId, createPaddingStyle, easingFns, inputUtils, fnUtils, maskUtils };
50
+ export { isClient, getDataTestId, createPaddingStyle, easingFns, fnUtils, maskUtils };
@@ -69,6 +69,8 @@ type ComponentProps = {
69
69
  * Дочерние элементы.
70
70
  */
71
71
  children?: ReactNode;
72
+ };
73
+ type PrivateButtonProps = {
72
74
  /**
73
75
  * Основные стили компонента.
74
76
  */
@@ -80,16 +82,12 @@ type ComponentProps = {
80
82
  */
81
83
  colorStylesMap: StyleColors;
82
84
  };
83
- type AnchorBaseButtonProps = ComponentProps & AnchorHTMLAttributes<HTMLAnchorElement>;
84
- type NativeBaseButtonProps = ComponentProps & ButtonHTMLAttributes<HTMLButtonElement>;
85
- type BaseButtonProps = Partial<AnchorBaseButtonProps | NativeBaseButtonProps>;
86
- type AnchorButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & AnchorHTMLAttributes<HTMLAnchorElement>;
87
- type NativeButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & ButtonHTMLAttributes<HTMLButtonElement>;
88
- type ButtonProps = Partial<AnchorButtonProps | NativeButtonProps> & {
85
+ type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
86
+ type ButtonProps = CommonButtonProps & {
89
87
  /**
90
88
  * Контрольная точка, с нее начинается desktop версия
91
89
  * @default 1024
92
90
  */
93
91
  breakpoint?: number;
94
92
  };
95
- export { StyleColors, ComponentProps, AnchorBaseButtonProps, NativeBaseButtonProps, BaseButtonProps, AnchorButtonProps, NativeButtonProps, ButtonProps };
93
+ export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import React from "react";
3
3
  import { FC } from "react";
4
- import { BaseButtonProps } from "./typings-9211a437";
4
+ import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
5
5
  type SpinnerProps = {
6
6
  /**
7
7
  * Управление видимостью компонента
@@ -34,5 +34,5 @@ declare const Spinner: FC<SpinnerProps>;
34
34
  * чтобы при быстрых ответах от сервера кнопка не «моргала».
35
35
  */
36
36
  declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
37
- declare const BaseButton: React.ForwardRefExoticComponent<BaseButtonProps & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
37
+ declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
38
38
  export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
@@ -10,10 +10,6 @@ declare function easeInOutQuad(x: number): number;
10
10
  declare const easingFns: {
11
11
  easeInOutQuad: typeof easeInOutQuad;
12
12
  };
13
- declare function disableUserInput<T>(disabled: boolean | undefined, event: React.KeyboardEvent<T>): void;
14
- declare const inputUtils: {
15
- disableUserInput: typeof disableUserInput;
16
- };
17
13
  /**
18
14
  * Возвращает true, если значение равно null или undefined
19
15
  */
@@ -51,4 +47,4 @@ declare const maskUtils: {
51
47
  prefixPostprocessor: typeof prefixPostprocessor;
52
48
  caretGuard: typeof caretGuard;
53
49
  };
54
- export { isClient, getDataTestId, createPaddingStyle, easingFns, inputUtils, fnUtils, maskUtils };
50
+ export { isClient, getDataTestId, createPaddingStyle, easingFns, fnUtils, maskUtils };
@@ -69,6 +69,8 @@ type ComponentProps = {
69
69
  * Дочерние элементы.
70
70
  */
71
71
  children?: ReactNode;
72
+ };
73
+ type PrivateButtonProps = {
72
74
  /**
73
75
  * Основные стили компонента.
74
76
  */
@@ -80,16 +82,12 @@ type ComponentProps = {
80
82
  */
81
83
  colorStylesMap: StyleColors;
82
84
  };
83
- type AnchorBaseButtonProps = ComponentProps & AnchorHTMLAttributes<HTMLAnchorElement>;
84
- type NativeBaseButtonProps = ComponentProps & ButtonHTMLAttributes<HTMLButtonElement>;
85
- type BaseButtonProps = Partial<AnchorBaseButtonProps | NativeBaseButtonProps>;
86
- type AnchorButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & AnchorHTMLAttributes<HTMLAnchorElement>;
87
- type NativeButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & ButtonHTMLAttributes<HTMLButtonElement>;
88
- type ButtonProps = Partial<AnchorButtonProps | NativeButtonProps> & {
85
+ type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
86
+ type ButtonProps = CommonButtonProps & {
89
87
  /**
90
88
  * Контрольная точка, с нее начинается desktop версия
91
89
  * @default 1024
92
90
  */
93
91
  breakpoint?: number;
94
92
  };
95
- export { StyleColors, ComponentProps, AnchorBaseButtonProps, NativeBaseButtonProps, BaseButtonProps, AnchorButtonProps, NativeButtonProps, ButtonProps };
93
+ export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
@@ -10,10 +10,6 @@ declare function easeInOutQuad(x: number): number;
10
10
  declare const easingFns: {
11
11
  easeInOutQuad: typeof easeInOutQuad;
12
12
  };
13
- declare function disableUserInput<T>(disabled: boolean | undefined, event: React.KeyboardEvent<T>): void;
14
- declare const inputUtils: {
15
- disableUserInput: typeof disableUserInput;
16
- };
17
13
  /**
18
14
  * Возвращает true, если значение равно null или undefined
19
15
  */
@@ -51,4 +47,4 @@ declare const maskUtils: {
51
47
  prefixPostprocessor: typeof prefixPostprocessor;
52
48
  caretGuard: typeof caretGuard;
53
49
  };
54
- export { isClient, getDataTestId, createPaddingStyle, easingFns, inputUtils, fnUtils, maskUtils };
50
+ export { isClient, getDataTestId, createPaddingStyle, easingFns, fnUtils, maskUtils };
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import React from "react";
3
3
  import { FC } from "react";
4
- import { BaseButtonProps } from "./typings-9211a437";
4
+ import { CommonButtonProps, PrivateButtonProps } from "./typings-89f0cb07";
5
5
  type SpinnerProps = {
6
6
  /**
7
7
  * Управление видимостью компонента
@@ -34,5 +34,5 @@ declare const Spinner: FC<SpinnerProps>;
34
34
  * чтобы при быстрых ответах от сервера кнопка не «моргала».
35
35
  */
36
36
  declare const LOADER_MIN_DISPLAY_INTERVAL = 500;
37
- declare const BaseButton: React.ForwardRefExoticComponent<BaseButtonProps & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
37
+ declare const BaseButton: React.ForwardRefExoticComponent<(CommonButtonProps & PrivateButtonProps) & React.RefAttributes<HTMLAnchorElement | HTMLButtonElement>>;
38
38
  export { SpinnerProps, Spinner, LOADER_MIN_DISPLAY_INTERVAL, BaseButton };
@@ -10,10 +10,6 @@ declare function easeInOutQuad(x: number): number;
10
10
  declare const easingFns: {
11
11
  easeInOutQuad: typeof easeInOutQuad;
12
12
  };
13
- declare function disableUserInput<T>(disabled: boolean | undefined, event: React.KeyboardEvent<T>): void;
14
- declare const inputUtils: {
15
- disableUserInput: typeof disableUserInput;
16
- };
17
13
  /**
18
14
  * Возвращает true, если значение равно null или undefined
19
15
  */
@@ -51,4 +47,4 @@ declare const maskUtils: {
51
47
  prefixPostprocessor: typeof prefixPostprocessor;
52
48
  caretGuard: typeof caretGuard;
53
49
  };
54
- export { isClient, getDataTestId, createPaddingStyle, easingFns, inputUtils, fnUtils, maskUtils };
50
+ export { isClient, getDataTestId, createPaddingStyle, easingFns, fnUtils, maskUtils };
@@ -69,6 +69,8 @@ type ComponentProps = {
69
69
  * Дочерние элементы.
70
70
  */
71
71
  children?: ReactNode;
72
+ };
73
+ type PrivateButtonProps = {
72
74
  /**
73
75
  * Основные стили компонента.
74
76
  */
@@ -80,16 +82,12 @@ type ComponentProps = {
80
82
  */
81
83
  colorStylesMap: StyleColors;
82
84
  };
83
- type AnchorBaseButtonProps = ComponentProps & AnchorHTMLAttributes<HTMLAnchorElement>;
84
- type NativeBaseButtonProps = ComponentProps & ButtonHTMLAttributes<HTMLButtonElement>;
85
- type BaseButtonProps = Partial<AnchorBaseButtonProps | NativeBaseButtonProps>;
86
- type AnchorButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & AnchorHTMLAttributes<HTMLAnchorElement>;
87
- type NativeButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & ButtonHTMLAttributes<HTMLButtonElement>;
88
- type ButtonProps = Partial<AnchorButtonProps | NativeButtonProps> & {
85
+ type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
86
+ type ButtonProps = CommonButtonProps & {
89
87
  /**
90
88
  * Контрольная точка, с нее начинается desktop версия
91
89
  * @default 1024
92
90
  */
93
91
  breakpoint?: number;
94
92
  };
95
- export { StyleColors, ComponentProps, AnchorBaseButtonProps, NativeBaseButtonProps, BaseButtonProps, AnchorButtonProps, NativeButtonProps, ButtonProps };
93
+ export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfalab/core-components-number-input",
3
- "version": "1.2.5",
3
+ "version": "1.2.6",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -14,7 +14,7 @@
14
14
  "react": "^16.9.0 || ^17.0.1 || ^18.0.0"
15
15
  },
16
16
  "dependencies": {
17
- "@alfalab/core-components-input": "^12.2.0",
17
+ "@alfalab/core-components-input": "^12.2.1",
18
18
  "react-merge-refs": "^1.1.0",
19
19
  "tslib": "^2.4.0"
20
20
  }
@@ -69,6 +69,8 @@ type ComponentProps = {
69
69
  * Дочерние элементы.
70
70
  */
71
71
  children?: ReactNode;
72
+ };
73
+ type PrivateButtonProps = {
72
74
  /**
73
75
  * Основные стили компонента.
74
76
  */
@@ -80,16 +82,12 @@ type ComponentProps = {
80
82
  */
81
83
  colorStylesMap: StyleColors;
82
84
  };
83
- type AnchorBaseButtonProps = ComponentProps & AnchorHTMLAttributes<HTMLAnchorElement>;
84
- type NativeBaseButtonProps = ComponentProps & ButtonHTMLAttributes<HTMLButtonElement>;
85
- type BaseButtonProps = Partial<AnchorBaseButtonProps | NativeBaseButtonProps>;
86
- type AnchorButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & AnchorHTMLAttributes<HTMLAnchorElement>;
87
- type NativeButtonProps = Omit<BaseButtonProps, 'styles' | 'colorStylesMap'> & ButtonHTMLAttributes<HTMLButtonElement>;
88
- type ButtonProps = Partial<AnchorButtonProps | NativeButtonProps> & {
85
+ type CommonButtonProps = ComponentProps & Partial<AnchorHTMLAttributes<HTMLAnchorElement> | ButtonHTMLAttributes<HTMLButtonElement>>;
86
+ type ButtonProps = CommonButtonProps & {
89
87
  /**
90
88
  * Контрольная точка, с нее начинается desktop версия
91
89
  * @default 1024
92
90
  */
93
91
  breakpoint?: number;
94
92
  };
95
- export { StyleColors, ComponentProps, AnchorBaseButtonProps, NativeBaseButtonProps, BaseButtonProps, AnchorButtonProps, NativeButtonProps, ButtonProps };
93
+ export { StyleColors, ComponentProps, PrivateButtonProps, CommonButtonProps, ButtonProps };