ish-ui 1.3.3 → 1.3.4
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.
|
@@ -86,8 +86,7 @@ const getSpaceWidth = (probe, typographySignature) => {
|
|
|
86
86
|
return spaceWidth;
|
|
87
87
|
};
|
|
88
88
|
export const AutosizeInput = (_a) => {
|
|
89
|
-
var { placeholder, reserveWidth, inputRef, ref } = _a, props = __rest(_a, ["placeholder", "reserveWidth", "inputRef", "ref"]);
|
|
90
|
-
const [value, setValue] = useState(props.value || "");
|
|
89
|
+
var { placeholder, reserveWidth, inputRef, ref, value } = _a, props = __rest(_a, ["placeholder", "reserveWidth", "inputRef", "ref", "value"]);
|
|
91
90
|
const [width, setWidth] = useState(0);
|
|
92
91
|
const spanRef = useRef(null);
|
|
93
92
|
const probeRef = useRef(null);
|
|
@@ -143,7 +142,6 @@ export const AutosizeInput = (_a) => {
|
|
|
143
142
|
return () => fonts.removeEventListener("loadingdone", onLoadingDone);
|
|
144
143
|
}, [measure]);
|
|
145
144
|
const handleChange = (e) => {
|
|
146
|
-
setValue(e.target.value);
|
|
147
145
|
if (props.onChange)
|
|
148
146
|
props.onChange(e);
|
|
149
147
|
};
|
|
@@ -219,6 +219,9 @@ function EditInPlaceSearchSelect({ label, disabled, className, labelAdornment, i
|
|
|
219
219
|
if (typeof itemRenderer === 'function') {
|
|
220
220
|
return [itemRenderer(getHighlightedPartLabel(getOptionLabel(data), searchValue), data, searchValue, optionProps), optionProps];
|
|
221
221
|
}
|
|
222
|
+
if (inline || categoryKey) {
|
|
223
|
+
return getHighlightedPartLabel(getOptionLabel(data), searchValue, optionProps);
|
|
224
|
+
}
|
|
222
225
|
return [getHighlightedPartLabel(getOptionLabel(data), searchValue), optionProps];
|
|
223
226
|
};
|
|
224
227
|
const selectedOption = useMemo(() => sortedItems.find(i => multiple
|
|
@@ -268,7 +271,7 @@ function EditInPlaceSearchSelect({ label, disabled, className, labelAdornment, i
|
|
|
268
271
|
: (React.createElement("div", null,
|
|
269
272
|
allowEmpty && input.value && (React.createElement(IconButton, { size: "small", onClick: onClear, color: "inherit" },
|
|
270
273
|
React.createElement(CloseIcon, { fontSize: "inherit" }))),
|
|
271
|
-
editIcon === undefined ? React.createElement(IconButton, { size: "small", color: "inherit", className: cx(classes.expandIcon, 'pl-0 pr-0'), disableRipple: true },
|
|
274
|
+
editIcon === undefined ? React.createElement(IconButton, { size: "small", color: "inherit", className: cx(classes.expandIcon, 'pl-0 pr-0', inline && 'p-0'), disableRipple: true },
|
|
272
275
|
React.createElement(ExpandMore, { className: inline && 'fsInherit' })) : editIcon))), [disabled, loading, inline, allowEmpty, input.value]);
|
|
273
276
|
const inputValue = useMemo(() => {
|
|
274
277
|
if (multiple) {
|