@patternfly/react-table 4.110.12 → 4.110.14
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/CHANGELOG.md +16 -0
- package/dist/umd/react-table.css +2245 -2223
- package/dist/umd/react-table.js +12 -5
- package/dist/umd/react-table.min.css +11110 -11088
- package/dist/umd/react-table.min.js +2 -2
- package/package.json +6 -6
package/dist/umd/react-table.js
CHANGED
|
@@ -4180,6 +4180,7 @@
|
|
|
4180
4180
|
|
|
4181
4181
|
var styles$a = {
|
|
4182
4182
|
"modifiers": {
|
|
4183
|
+
"inline": "pf-m-inline",
|
|
4183
4184
|
"sm": "pf-m-sm",
|
|
4184
4185
|
"md": "pf-m-md",
|
|
4185
4186
|
"lg": "pf-m-lg",
|
|
@@ -5384,6 +5385,11 @@
|
|
|
5384
5385
|
TextInputTypes["time"] = "time";
|
|
5385
5386
|
TextInputTypes["url"] = "url";
|
|
5386
5387
|
})(TextInputTypes || (TextInputTypes = {}));
|
|
5388
|
+
var TextInputReadOnlyVariant;
|
|
5389
|
+
(function (TextInputReadOnlyVariant) {
|
|
5390
|
+
TextInputReadOnlyVariant["default"] = "default";
|
|
5391
|
+
TextInputReadOnlyVariant["plain"] = "plain";
|
|
5392
|
+
})(TextInputReadOnlyVariant || (TextInputReadOnlyVariant = {}));
|
|
5387
5393
|
class TextInputBase extends React__namespace.Component {
|
|
5388
5394
|
constructor(props) {
|
|
5389
5395
|
super(props);
|
|
@@ -5445,9 +5451,7 @@
|
|
|
5445
5451
|
render() {
|
|
5446
5452
|
const _a = this.props, { innerRef, className, type, value, validated,
|
|
5447
5453
|
/* eslint-disable @typescript-eslint/no-unused-vars */
|
|
5448
|
-
onChange, onFocus, onBlur, isLeftTruncated,
|
|
5449
|
-
/* eslint-enable @typescript-eslint/no-unused-vars */
|
|
5450
|
-
isReadOnly, isRequired, isDisabled, isIconSprite, iconVariant, customIconUrl, customIconDimensions, ouiaId, ouiaSafe } = _a, props = __rest$1(_a, ["innerRef", "className", "type", "value", "validated", "onChange", "onFocus", "onBlur", "isLeftTruncated", "isReadOnly", "isRequired", "isDisabled", "isIconSprite", "iconVariant", "customIconUrl", "customIconDimensions", "ouiaId", "ouiaSafe"]);
|
|
5454
|
+
onChange, onFocus, onBlur, isLeftTruncated, isReadOnly, readOnly, readOnlyVariant, isRequired, isDisabled, isIconSprite, iconVariant, customIconUrl, customIconDimensions, ouiaId, ouiaSafe } = _a, props = __rest$1(_a, ["innerRef", "className", "type", "value", "validated", "onChange", "onFocus", "onBlur", "isLeftTruncated", "isReadOnly", "readOnly", "readOnlyVariant", "isRequired", "isDisabled", "isIconSprite", "iconVariant", "customIconUrl", "customIconDimensions", "ouiaId", "ouiaSafe"]);
|
|
5451
5455
|
const customIconStyle = {};
|
|
5452
5456
|
if (customIconUrl) {
|
|
5453
5457
|
customIconStyle.backgroundImage = `url('${customIconUrl}')`;
|
|
@@ -5455,7 +5459,7 @@
|
|
|
5455
5459
|
if (customIconDimensions) {
|
|
5456
5460
|
customIconStyle.backgroundSize = customIconDimensions;
|
|
5457
5461
|
}
|
|
5458
|
-
return (React__namespace.createElement("input", Object.assign({}, props, { onFocus: this.onFocus, onBlur: this.onBlur, className: css(formStyles$1.formControl, isIconSprite && formStyles$1.modifiers.iconSprite, validated === ValidatedOptions.success && formStyles$1.modifiers.success, validated === ValidatedOptions.warning && formStyles$1.modifiers.warning, ((iconVariant && iconVariant !== 'search') || customIconUrl) && formStyles$1.modifiers.icon, iconVariant && formStyles$1.modifiers[iconVariant], className), onChange: this.handleChange, type: type, value: this.sanitizeInputValue(value), "aria-invalid": props['aria-invalid'] ? props['aria-invalid'] : validated === ValidatedOptions.error, required: isRequired, disabled: isDisabled, readOnly: isReadOnly, ref: innerRef || this.inputRef }, ((customIconUrl || customIconDimensions) && { style: customIconStyle }), getOUIAProps(TextInput.displayName, ouiaId !== undefined ? ouiaId : this.state.ouiaStateId, ouiaSafe))));
|
|
5462
|
+
return (React__namespace.createElement("input", Object.assign({}, props, { onFocus: this.onFocus, onBlur: this.onBlur, className: css(formStyles$1.formControl, isIconSprite && formStyles$1.modifiers.iconSprite, readOnlyVariant === 'plain' && formStyles$1.modifiers.plain, validated === ValidatedOptions.success && formStyles$1.modifiers.success, validated === ValidatedOptions.warning && formStyles$1.modifiers.warning, ((iconVariant && iconVariant !== 'search') || customIconUrl) && formStyles$1.modifiers.icon, iconVariant && formStyles$1.modifiers[iconVariant], className), onChange: this.handleChange, type: type, value: this.sanitizeInputValue(value), "aria-invalid": props['aria-invalid'] ? props['aria-invalid'] : validated === ValidatedOptions.error, required: isRequired, disabled: isDisabled, readOnly: !!readOnlyVariant || isReadOnly || readOnly, ref: innerRef || this.inputRef }, ((customIconUrl || customIconDimensions) && { style: customIconStyle }), getOUIAProps(TextInput.displayName, ouiaId !== undefined ? ouiaId : this.state.ouiaStateId, ouiaSafe))));
|
|
5459
5463
|
}
|
|
5460
5464
|
}
|
|
5461
5465
|
TextInputBase.displayName = 'TextInputBase';
|
|
@@ -6383,7 +6387,10 @@
|
|
|
6383
6387
|
}
|
|
6384
6388
|
// Move focus to top of the menu if state.focusFirstOption was updated to true and the menu does not have custom content
|
|
6385
6389
|
if (!prevState.focusFirstOption && this.state.focusFirstOption && !this.props.customContent) {
|
|
6386
|
-
const firstRef = this.refCollection.find(ref =>
|
|
6390
|
+
const firstRef = this.refCollection.find(ref =>
|
|
6391
|
+
// If a select option is disabled then ref[0] will be undefined, so we want to return
|
|
6392
|
+
// the first ref that both a) is not null and b) is not disabled.
|
|
6393
|
+
ref !== null && ref[0]);
|
|
6387
6394
|
if (firstRef && firstRef[0]) {
|
|
6388
6395
|
firstRef[0].focus();
|
|
6389
6396
|
}
|