@alfalab/core-components-with-suffix 4.1.6 → 4.1.8
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.d.ts +1 -1
- package/Component.js +2 -2
- package/cssm/Component.d.ts +1 -1
- package/cssm/Component.js +1 -1
- package/esm/Component.d.ts +1 -1
- package/esm/Component.js +2 -2
- package/esm/index.css +9 -9
- package/index.css +9 -9
- package/modern/Component.d.ts +1 -1
- package/modern/Component.js +2 -2
- package/modern/index.css +9 -9
- package/package.json +2 -2
- package/src/Component.tsx +4 -1
package/Component.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ type withSuffixProps = InputProps & {
|
|
|
13
13
|
*/
|
|
14
14
|
suffixContainerClassName?: string;
|
|
15
15
|
};
|
|
16
|
-
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("
|
|
16
|
+
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-input/components/base-input").BaseInputProps, "colorStyles" | "FormControlComponent"> & {
|
|
17
17
|
breakpoint?: number | undefined;
|
|
18
18
|
defaultMatchMediaValue?: boolean | (() => boolean) | undefined;
|
|
19
19
|
} & {
|
package/Component.js
CHANGED
|
@@ -14,7 +14,7 @@ var React__default = /*#__PURE__*/_interopDefaultCompat(React);
|
|
|
14
14
|
var mergeRefs__default = /*#__PURE__*/_interopDefaultCompat(mergeRefs);
|
|
15
15
|
var cn__default = /*#__PURE__*/_interopDefaultCompat(cn);
|
|
16
16
|
|
|
17
|
-
var styles = {"suffixContainer":"with-
|
|
17
|
+
var styles = {"suffixContainer":"with-suffix__suffixContainer_nc1pc","suffixVisible":"with-suffix__suffixVisible_nc1pc","hasSuffix":"with-suffix__hasSuffix_nc1pc","spacer":"with-suffix__spacer_nc1pc","suffix":"with-suffix__suffix_nc1pc","disabled":"with-suffix__disabled_nc1pc","readOnly":"with-suffix__readOnly_nc1pc"};
|
|
18
18
|
require('./index.css')
|
|
19
19
|
|
|
20
20
|
var withSuffix = function (Input) {
|
|
@@ -50,7 +50,7 @@ var withSuffix = function (Input) {
|
|
|
50
50
|
_b[styles.hasSuffix] = suffix,
|
|
51
51
|
_b)) }, restProps)),
|
|
52
52
|
React__default.default.createElement(coreComponentsPortal.Portal, { getPortalContainer: getPortalContainer },
|
|
53
|
-
React__default.default.createElement("div", { className: cn__default.default(styles.suffixContainer, suffixContainerClassName) },
|
|
53
|
+
React__default.default.createElement("div", { translate: 'no', className: cn__default.default(styles.suffixContainer, suffixContainerClassName) },
|
|
54
54
|
React__default.default.createElement("span", { className: styles.spacer }, visibleValue),
|
|
55
55
|
suffix && (React__default.default.createElement("div", { className: cn__default.default(styles.suffix, (_c = {},
|
|
56
56
|
_c[styles.disabled] = disabled,
|
package/cssm/Component.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ type withSuffixProps = InputProps & {
|
|
|
13
13
|
*/
|
|
14
14
|
suffixContainerClassName?: string;
|
|
15
15
|
};
|
|
16
|
-
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("
|
|
16
|
+
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-input/components/base-input").BaseInputProps, "colorStyles" | "FormControlComponent"> & {
|
|
17
17
|
breakpoint?: number | undefined;
|
|
18
18
|
defaultMatchMediaValue?: boolean | (() => boolean) | undefined;
|
|
19
19
|
} & {
|
package/cssm/Component.js
CHANGED
|
@@ -49,7 +49,7 @@ var withSuffix = function (Input) {
|
|
|
49
49
|
_b[styles__default.default.hasSuffix] = suffix,
|
|
50
50
|
_b)) }, restProps)),
|
|
51
51
|
React__default.default.createElement(coreComponentsPortal.Portal, { getPortalContainer: getPortalContainer },
|
|
52
|
-
React__default.default.createElement("div", { className: cn__default.default(styles__default.default.suffixContainer, suffixContainerClassName) },
|
|
52
|
+
React__default.default.createElement("div", { translate: 'no', className: cn__default.default(styles__default.default.suffixContainer, suffixContainerClassName) },
|
|
53
53
|
React__default.default.createElement("span", { className: styles__default.default.spacer }, visibleValue),
|
|
54
54
|
suffix && (React__default.default.createElement("div", { className: cn__default.default(styles__default.default.suffix, (_c = {},
|
|
55
55
|
_c[styles__default.default.disabled] = disabled,
|
package/esm/Component.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ type withSuffixProps = InputProps & {
|
|
|
13
13
|
*/
|
|
14
14
|
suffixContainerClassName?: string;
|
|
15
15
|
};
|
|
16
|
-
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("
|
|
16
|
+
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-input/components/base-input").BaseInputProps, "colorStyles" | "FormControlComponent"> & {
|
|
17
17
|
breakpoint?: number | undefined;
|
|
18
18
|
defaultMatchMediaValue?: boolean | (() => boolean) | undefined;
|
|
19
19
|
} & {
|
package/esm/Component.js
CHANGED
|
@@ -4,7 +4,7 @@ import mergeRefs from 'react-merge-refs';
|
|
|
4
4
|
import cn from 'classnames';
|
|
5
5
|
import { Portal } from '@alfalab/core-components-portal/esm';
|
|
6
6
|
|
|
7
|
-
var styles = {"suffixContainer":"with-
|
|
7
|
+
var styles = {"suffixContainer":"with-suffix__suffixContainer_nc1pc","suffixVisible":"with-suffix__suffixVisible_nc1pc","hasSuffix":"with-suffix__hasSuffix_nc1pc","spacer":"with-suffix__spacer_nc1pc","suffix":"with-suffix__suffix_nc1pc","disabled":"with-suffix__disabled_nc1pc","readOnly":"with-suffix__readOnly_nc1pc"};
|
|
8
8
|
require('./index.css')
|
|
9
9
|
|
|
10
10
|
var withSuffix = function (Input) {
|
|
@@ -40,7 +40,7 @@ var withSuffix = function (Input) {
|
|
|
40
40
|
_b[styles.hasSuffix] = suffix,
|
|
41
41
|
_b)) }, restProps)),
|
|
42
42
|
React.createElement(Portal, { getPortalContainer: getPortalContainer },
|
|
43
|
-
React.createElement("div", { className: cn(styles.suffixContainer, suffixContainerClassName) },
|
|
43
|
+
React.createElement("div", { translate: 'no', className: cn(styles.suffixContainer, suffixContainerClassName) },
|
|
44
44
|
React.createElement("span", { className: styles.spacer }, visibleValue),
|
|
45
45
|
suffix && (React.createElement("div", { className: cn(styles.suffix, (_c = {},
|
|
46
46
|
_c[styles.disabled] = disabled,
|
package/esm/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1a5rj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-text-secondary: rgba(60, 60, 67, 0.66); /* 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 */
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
/* управляет видимостью иконки ошибки, если она стоит рядом с другой иконкой */
|
|
31
31
|
|
|
32
32
|
/* mobile */
|
|
33
|
-
} .with-
|
|
33
|
+
} .with-suffix__suffixContainer_nc1pc {
|
|
34
34
|
font-size: 16px;
|
|
35
35
|
line-height: 20px;
|
|
36
36
|
font-weight: 400;
|
|
@@ -42,20 +42,20 @@
|
|
|
42
42
|
align-items: center;
|
|
43
43
|
display: none;
|
|
44
44
|
pointer-events: none;
|
|
45
|
-
} input:focus:not(:read-only) + .with-
|
|
46
|
-
.with-
|
|
45
|
+
} input:focus:not(:read-only) + .with-suffix__suffixContainer_nc1pc,
|
|
46
|
+
.with-suffix__suffixVisible_nc1pc .with-suffix__suffixContainer_nc1pc {
|
|
47
47
|
display: inline-flex;
|
|
48
|
-
} .with-
|
|
48
|
+
} .with-suffix__hasSuffix_nc1pc input:focus::placeholder {
|
|
49
49
|
color: transparent;
|
|
50
50
|
transition: none;
|
|
51
|
-
} .with-
|
|
51
|
+
} .with-suffix__spacer_nc1pc {
|
|
52
52
|
visibility: hidden;
|
|
53
53
|
flex-shrink: 0;
|
|
54
54
|
white-space: pre;
|
|
55
|
-
} .with-
|
|
55
|
+
} .with-suffix__suffix_nc1pc {
|
|
56
56
|
white-space: pre;
|
|
57
|
-
} .with-
|
|
57
|
+
} .with-suffix__disabled_nc1pc {
|
|
58
58
|
color: var(--input-disabled-color);
|
|
59
|
-
} .with-
|
|
59
|
+
} .with-suffix__readOnly_nc1pc {
|
|
60
60
|
color: var(--input-read-only-color);
|
|
61
61
|
}
|
package/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1a5rj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-text-secondary: rgba(60, 60, 67, 0.66); /* 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 */
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
/* управляет видимостью иконки ошибки, если она стоит рядом с другой иконкой */
|
|
31
31
|
|
|
32
32
|
/* mobile */
|
|
33
|
-
} .with-
|
|
33
|
+
} .with-suffix__suffixContainer_nc1pc {
|
|
34
34
|
font-size: 16px;
|
|
35
35
|
line-height: 20px;
|
|
36
36
|
font-weight: 400;
|
|
@@ -42,20 +42,20 @@
|
|
|
42
42
|
align-items: center;
|
|
43
43
|
display: none;
|
|
44
44
|
pointer-events: none;
|
|
45
|
-
} input:focus:not(:read-only) + .with-
|
|
46
|
-
.with-
|
|
45
|
+
} input:focus:not(:read-only) + .with-suffix__suffixContainer_nc1pc,
|
|
46
|
+
.with-suffix__suffixVisible_nc1pc .with-suffix__suffixContainer_nc1pc {
|
|
47
47
|
display: inline-flex;
|
|
48
|
-
} .with-
|
|
48
|
+
} .with-suffix__hasSuffix_nc1pc input:focus::placeholder {
|
|
49
49
|
color: transparent;
|
|
50
50
|
transition: none;
|
|
51
|
-
} .with-
|
|
51
|
+
} .with-suffix__spacer_nc1pc {
|
|
52
52
|
visibility: hidden;
|
|
53
53
|
flex-shrink: 0;
|
|
54
54
|
white-space: pre;
|
|
55
|
-
} .with-
|
|
55
|
+
} .with-suffix__suffix_nc1pc {
|
|
56
56
|
white-space: pre;
|
|
57
|
-
} .with-
|
|
57
|
+
} .with-suffix__disabled_nc1pc {
|
|
58
58
|
color: var(--input-disabled-color);
|
|
59
|
-
} .with-
|
|
59
|
+
} .with-suffix__readOnly_nc1pc {
|
|
60
60
|
color: var(--input-read-only-color);
|
|
61
61
|
}
|
package/modern/Component.d.ts
CHANGED
|
@@ -13,7 +13,7 @@ type withSuffixProps = InputProps & {
|
|
|
13
13
|
*/
|
|
14
14
|
suffixContainerClassName?: string;
|
|
15
15
|
};
|
|
16
|
-
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("
|
|
16
|
+
declare const withSuffix: (Input: FC<InputProps & RefAttributes<HTMLInputElement>>) => React.ForwardRefExoticComponent<Omit<import("@alfalab/core-components-input/components/base-input").BaseInputProps, "colorStyles" | "FormControlComponent"> & {
|
|
17
17
|
breakpoint?: number | undefined;
|
|
18
18
|
defaultMatchMediaValue?: boolean | (() => boolean) | undefined;
|
|
19
19
|
} & {
|
package/modern/Component.js
CHANGED
|
@@ -3,7 +3,7 @@ import mergeRefs from 'react-merge-refs';
|
|
|
3
3
|
import cn from 'classnames';
|
|
4
4
|
import { Portal } from '@alfalab/core-components-portal/modern';
|
|
5
5
|
|
|
6
|
-
const styles = {"suffixContainer":"with-
|
|
6
|
+
const styles = {"suffixContainer":"with-suffix__suffixContainer_nc1pc","suffixVisible":"with-suffix__suffixVisible_nc1pc","hasSuffix":"with-suffix__hasSuffix_nc1pc","spacer":"with-suffix__spacer_nc1pc","suffix":"with-suffix__suffix_nc1pc","disabled":"with-suffix__disabled_nc1pc","readOnly":"with-suffix__readOnly_nc1pc"};
|
|
7
7
|
require('./index.css')
|
|
8
8
|
|
|
9
9
|
const withSuffix = (Input) => forwardRef(({ value, defaultValue, onChange, onClear, suffix = '', placeholder, className, disabled, readOnly, suffixContainerClassName, ...restProps }, ref) => {
|
|
@@ -36,7 +36,7 @@ const withSuffix = (Input) => forwardRef(({ value, defaultValue, onChange, onCle
|
|
|
36
36
|
[styles.hasSuffix]: suffix,
|
|
37
37
|
}), ...restProps }),
|
|
38
38
|
React.createElement(Portal, { getPortalContainer: getPortalContainer },
|
|
39
|
-
React.createElement("div", { className: cn(styles.suffixContainer, suffixContainerClassName) },
|
|
39
|
+
React.createElement("div", { translate: 'no', className: cn(styles.suffixContainer, suffixContainerClassName) },
|
|
40
40
|
React.createElement("span", { className: styles.spacer }, visibleValue),
|
|
41
41
|
suffix && (React.createElement("div", { className: cn(styles.suffix, {
|
|
42
42
|
[styles.disabled]: disabled,
|
package/modern/index.css
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* hash:
|
|
1
|
+
/* hash: 1a5rj */
|
|
2
2
|
:root {
|
|
3
3
|
} /* deprecated */ :root {
|
|
4
4
|
--color-light-text-secondary: rgba(60, 60, 67, 0.66); /* 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 */
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
/* управляет видимостью иконки ошибки, если она стоит рядом с другой иконкой */
|
|
31
31
|
|
|
32
32
|
/* mobile */
|
|
33
|
-
} .with-
|
|
33
|
+
} .with-suffix__suffixContainer_nc1pc {
|
|
34
34
|
font-size: 16px;
|
|
35
35
|
line-height: 20px;
|
|
36
36
|
font-weight: 400;
|
|
@@ -42,20 +42,20 @@
|
|
|
42
42
|
align-items: center;
|
|
43
43
|
display: none;
|
|
44
44
|
pointer-events: none;
|
|
45
|
-
} input:focus:not(:read-only) + .with-
|
|
46
|
-
.with-
|
|
45
|
+
} input:focus:not(:read-only) + .with-suffix__suffixContainer_nc1pc,
|
|
46
|
+
.with-suffix__suffixVisible_nc1pc .with-suffix__suffixContainer_nc1pc {
|
|
47
47
|
display: inline-flex;
|
|
48
|
-
} .with-
|
|
48
|
+
} .with-suffix__hasSuffix_nc1pc input:focus::placeholder {
|
|
49
49
|
color: transparent;
|
|
50
50
|
transition: none;
|
|
51
|
-
} .with-
|
|
51
|
+
} .with-suffix__spacer_nc1pc {
|
|
52
52
|
visibility: hidden;
|
|
53
53
|
flex-shrink: 0;
|
|
54
54
|
white-space: pre;
|
|
55
|
-
} .with-
|
|
55
|
+
} .with-suffix__suffix_nc1pc {
|
|
56
56
|
white-space: pre;
|
|
57
|
-
} .with-
|
|
57
|
+
} .with-suffix__disabled_nc1pc {
|
|
58
58
|
color: var(--input-disabled-color);
|
|
59
|
-
} .with-
|
|
59
|
+
} .with-suffix__readOnly_nc1pc {
|
|
60
60
|
color: var(--input-read-only-color);
|
|
61
61
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfalab/core-components-with-suffix",
|
|
3
|
-
"version": "4.1.
|
|
3
|
+
"version": "4.1.8",
|
|
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.
|
|
17
|
+
"@alfalab/core-components-input": "^12.2.0",
|
|
18
18
|
"@alfalab/core-components-portal": "^3.2.0",
|
|
19
19
|
"classnames": "^2.3.1",
|
|
20
20
|
"react-merge-refs": "^1.1.0",
|
package/src/Component.tsx
CHANGED
|
@@ -104,7 +104,10 @@ export const withSuffix = (Input: FC<InputProps & RefAttributes<HTMLInputElement
|
|
|
104
104
|
{...restProps}
|
|
105
105
|
/>
|
|
106
106
|
<Portal getPortalContainer={getPortalContainer}>
|
|
107
|
-
<div
|
|
107
|
+
<div
|
|
108
|
+
translate='no'
|
|
109
|
+
className={cn(styles.suffixContainer, suffixContainerClassName)}
|
|
110
|
+
>
|
|
108
111
|
<span className={styles.spacer}>{visibleValue}</span>
|
|
109
112
|
{suffix && (
|
|
110
113
|
<div
|