@hazelcast/ui 1.3.2-next.55 → 1.3.2-next.56
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/lib/AutocompleteField.d.ts +1 -1
- package/lib/FieldHeader.d.ts +1 -1
- package/lib/Icon.d.ts +1 -1
- package/lib/NumberField.d.ts +1 -1
- package/lib/SegmentedControl.d.ts +1 -1
- package/lib/TextField.d.ts +1 -0
- package/lib/TextField.js +2 -3
- package/lib/TextField.js.map +1 -1
- package/lib/Toggle.d.ts +1 -1
- package/package.json +2 -2
|
@@ -16,7 +16,7 @@ export type AutocompleteFieldProps = {
|
|
|
16
16
|
error?: string;
|
|
17
17
|
errorClassName?: string;
|
|
18
18
|
isClearable?: boolean;
|
|
19
|
-
label
|
|
19
|
+
label?: string;
|
|
20
20
|
labelClassName?: string;
|
|
21
21
|
menuPortalTarget?: 'body' | 'self' | HTMLElement | null;
|
|
22
22
|
onChange?: (newValue: string) => void;
|
package/lib/FieldHeader.d.ts
CHANGED
|
@@ -3,7 +3,7 @@ import { HelpProps } from './Help';
|
|
|
3
3
|
import { DataTestProp } from '@hazelcast/helpers';
|
|
4
4
|
export type FieldHeaderSize = 'small' | 'medium';
|
|
5
5
|
export type FieldHeaderLabelProps = {
|
|
6
|
-
label
|
|
6
|
+
label?: string;
|
|
7
7
|
labelClassName?: string;
|
|
8
8
|
helperText?: HelpProps['helperText'];
|
|
9
9
|
helperTextTooltipWordBreak?: CSSProperties['wordBreak'];
|
package/lib/Icon.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { FC, SVGAttributes } from 'react';
|
|
2
2
|
export type IconSize = 'small' | 'smallMedium' | 'medium' | 'large' | 'xlarge';
|
|
3
3
|
export type IconAriaProps = {
|
|
4
|
-
ariaLabel: string;
|
|
4
|
+
ariaLabel: string | undefined;
|
|
5
5
|
ariaLabelledBy?: never;
|
|
6
6
|
ariaHidden?: never;
|
|
7
7
|
} | {
|
package/lib/NumberField.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ export type NumberFieldExtraProps = Omit<TextFieldProps<'number'>, 'onChange' |
|
|
|
18
18
|
numberType?: 'int' | 'float';
|
|
19
19
|
iconPosition?: 'separate' | 'together';
|
|
20
20
|
showIconButtons?: boolean;
|
|
21
|
-
label
|
|
21
|
+
label?: string;
|
|
22
22
|
showAriaLabel?: boolean;
|
|
23
23
|
size?: TextFieldSize;
|
|
24
24
|
className?: string;
|
|
@@ -8,7 +8,7 @@ export type SegmentedControlSize = 'medium' | 'small';
|
|
|
8
8
|
export type SegmentedControlProps<V> = {
|
|
9
9
|
value: V;
|
|
10
10
|
onChange: (value: V) => void;
|
|
11
|
-
label
|
|
11
|
+
label?: string;
|
|
12
12
|
options: SegmentedControlOption<V>[];
|
|
13
13
|
size?: SegmentedControlSize;
|
|
14
14
|
className?: string;
|
package/lib/TextField.d.ts
CHANGED
package/lib/TextField.js
CHANGED
|
@@ -20,14 +20,13 @@ import styles from './TextField.module.scss';
|
|
|
20
20
|
* - Text Field is available in 2 variations: `small` (height of 30 px) and `medium` (height of 40 px). The use depends mainly on the space in UI.
|
|
21
21
|
* - All of the variations can be either with the label, or without label.
|
|
22
22
|
* - Standard label alignment is left-aligned with the field underneath.
|
|
23
|
-
* - Mostly all of the fields are required. If some of them are not, use text "Optional" behind the label.
|
|
24
23
|
* - If needed, you can use icon on the left side or on the right side inside the Text Input (e.g. Eye icon to show / hide password).
|
|
25
24
|
*
|
|
26
25
|
* ### Usage
|
|
27
26
|
* Use a text input when the expected user input is a single line of text.
|
|
28
27
|
*/
|
|
29
28
|
const TextFieldInternal = (props, ref) => {
|
|
30
|
-
const { 'data-test': dataTest, className, disabled, error, errorClassName, helperText, helperTextTooltipWordBreak, id: explicitId, inputClassName, inputContainerChild, inputContainerClassName, inputIcon, inputTrailingIcon, inputTrailingIconLabel, label, labelClassName, showAriaLabel = false, name, size = 'medium', onBlur, onChange, onKeyPress, placeholder, required, type = 'text', value, readOnly, onClick, clearable, iconSize = size, errorTooltipPlacement = 'top', ...htmlAttrs } = props;
|
|
29
|
+
const { 'data-test': dataTest, ariaLabel, className, disabled, error, errorClassName, helperText, helperTextTooltipWordBreak, id: explicitId, inputClassName, inputContainerChild, inputContainerClassName, inputIcon, inputTrailingIcon, inputTrailingIconLabel, label, labelClassName, showAriaLabel = false, name, size = 'medium', onBlur, onChange, onKeyPress, placeholder, required, type = 'text', value, readOnly, onClick, clearable, iconSize = size, errorTooltipPlacement = 'top', ...htmlAttrs } = props;
|
|
31
30
|
const autoId = useUID();
|
|
32
31
|
const id = explicitId !== null && explicitId !== void 0 ? explicitId : autoId;
|
|
33
32
|
const inputRef = useRef(null);
|
|
@@ -49,7 +48,7 @@ const TextFieldInternal = (props, ref) => {
|
|
|
49
48
|
React.createElement(FieldHeader, { id: id, size: size, label: label, helperText: helperText, showAriaLabel: showAriaLabel, labelClassName: labelClassName, helperTextTooltipWordBreak: helperTextTooltipWordBreak }),
|
|
50
49
|
React.createElement("div", { className: styles.inputBlock },
|
|
51
50
|
React.createElement("div", { className: cn(styles.inputContainer, inputContainerClassName) },
|
|
52
|
-
React.createElement("input", { type: type, id: id, ref: mergedRef, value: value !== null && value !== void 0 ? value : '', name: name, onChange: onChange, onBlur: onBlur, readOnly: readOnly, onKeyPress: onKeyPress, onClick: onClick, "aria-label": showAriaLabel ?
|
|
51
|
+
React.createElement("input", { type: type, id: id, ref: mergedRef, value: value !== null && value !== void 0 ? value : '', name: name, onChange: onChange, onBlur: onBlur, readOnly: readOnly, onKeyPress: onKeyPress, onClick: onClick, "aria-label": showAriaLabel ? ariaLabel : undefined, "aria-invalid": !!error, "aria-required": required, "aria-describedby": helperText && helpTooltipId(id), "aria-errormessage": error && errorId(id), disabled: disabled, placeholder: placeholder, className: cn(inputClassName, {
|
|
53
52
|
[styles.trailingIcon]: inputTrailingIcon,
|
|
54
53
|
}), ...htmlAttrs }),
|
|
55
54
|
React.createElement("div", { className: styles.borderOverlay }),
|
package/lib/TextField.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../src/TextField.tsx"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,OAAO,KAAK,EAAE,EAQZ,UAAU,EACV,MAAM,GACP,MAAM,OAAO,CAAA;AACd,OAAO,EAAE,MAAM,YAAY,CAAA;AAC3B,OAAO,EAAgB,wBAAwB,EAAE,MAAM,oBAAoB,CAAA;AAC3E,OAAO,EAAoB,CAAC,EAAE,MAAM,eAAe,CAAA;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,SAAS,MAAM,kBAAkB,CAAA;AAExC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAA;AAC7B,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AACxC,OAAO,EAAE,WAAW,EAAoB,MAAM,eAAe,CAAA;AAC7D,OAAO,EAAE,aAAa,EAAE,MAAM,QAAQ,CAAA;AACtC,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAIzC,OAAO,MAAM,MAAM,yBAAyB,CAAA;
|
|
1
|
+
{"version":3,"file":"TextField.js","sourceRoot":"","sources":["../src/TextField.tsx"],"names":[],"mappings":"AAAA,uDAAuD;AACvD,OAAO,KAAK,EAAE,EAQZ,UAAU,EACV,MAAM,GACP,MAAM,OAAO,CAAA;AACd,OAAO,EAAE,MAAM,YAAY,CAAA;AAC3B,OAAO,EAAgB,wBAAwB,EAAE,MAAM,oBAAoB,CAAA;AAC3E,OAAO,EAAoB,CAAC,EAAE,MAAM,eAAe,CAAA;AACnD,OAAO,EAAE,MAAM,EAAE,MAAM,WAAW,CAAA;AAClC,OAAO,SAAS,MAAM,kBAAkB,CAAA;AAExC,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAA;AAC7B,OAAO,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,SAAS,CAAA;AACxC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C,KAAK,IACJ,SAAS,QACT,OAAO,EAAE,EAAE,EACX,KAAK,EAAE,KAAK,EACZ,gBAAgB,EAAE,qBAAqB,EACvC,SAAS,EAAE,EAAE,CAAC,MAAM,CAAC,cAAc,EAAE,cAAc,CAAC,GACpD,CACE,CACP,CAAA;AACH,CAAC,CAAA;AAED,MAAM,gBAAgB,GAAG,UAAU,CAAC,iBAAiB,CAAC,CAAA;AAEtD,MAAM,CAAC,MAAM,SAAS,GAAG,CAA2B,EAAE,IAAI,EAAE,GAAG,KAAK,EAAwD,EAAE,EAAE,CAAC,CAC/H,oBAAC,gBAAgB,IAAC,GAAG,EAAE,IAAI,KAAM,KAAK,GAAI,CAC3C,CAAA"}
|
package/lib/Toggle.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hazelcast/ui",
|
|
3
|
-
"version": "1.3.2-next.
|
|
3
|
+
"version": "1.3.2-next.56+f0f4f42",
|
|
4
4
|
"description": "Hazelcast design system components",
|
|
5
5
|
"author": "",
|
|
6
6
|
"homepage": "https://github.com/hazelcast/frontend-shared#readme",
|
|
@@ -117,5 +117,5 @@
|
|
|
117
117
|
"react": "^17 || ^18",
|
|
118
118
|
"react-dom": "^17 || ^18"
|
|
119
119
|
},
|
|
120
|
-
"gitHead": "
|
|
120
|
+
"gitHead": "f0f4f420b5bb6ed062ed325d3babb1ca58e577ec"
|
|
121
121
|
}
|