pge-front-common 14.1.2 → 14.1.3

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/index.esm.js CHANGED
@@ -105,14 +105,14 @@ styleInject(css_248z$B);
105
105
 
106
106
  var InputBase = function (_a) {
107
107
  var _b;
108
- var customClass = _a.customClass, restrictionMessage = _a.restrictionMessage, label = _a.label, leftIcon = _a.leftIcon, rightIcon = _a.rightIcon, onRightIconClick = _a.onRightIconClick, style = _a.style, required = _a.required; _a.error; _a.helperText; var disabled = _a.disabled; _a.readOnly; _a.className; var showCounter = _a.showCounter, value = _a.value, props = __rest(_a, ["customClass", "restrictionMessage", "label", "leftIcon", "rightIcon", "onRightIconClick", "style", "required", "error", "helperText", "disabled", "readOnly", "className", "showCounter", "value"]);
108
+ var customClass = _a.customClass, restrictionMessage = _a.restrictionMessage, label = _a.label, leftIcon = _a.leftIcon, rightIcon = _a.rightIcon, onRightIconClick = _a.onRightIconClick, style = _a.style, required = _a.required, error = _a.error; _a.helperText; var disabled = _a.disabled; _a.readOnly; _a.className; var showCounter = _a.showCounter, value = _a.value, props = __rest(_a, ["customClass", "restrictionMessage", "label", "leftIcon", "rightIcon", "onRightIconClick", "style", "required", "error", "helperText", "disabled", "readOnly", "className", "showCounter", "value"]);
109
109
  var characterCount = (value === null || value === void 0 ? void 0 : value.toString().length) || 0;
110
110
  return (React__default.createElement("div", { className: styles$y.inputContainer },
111
111
  label && (React__default.createElement("label", { tabIndex: disabled ? -1 : 0, htmlFor: props.name, className: "".concat(styles$y.labelInput, " ").concat(required ? styles$y.labelRequired : "") }, label)),
112
112
  React__default.createElement("div", { className: styles$y.inputContent },
113
113
  leftIcon && React__default.createElement("div", { className: styles$y.iconWrapperLeft }, leftIcon),
114
114
  React__default.createElement("input", __assign({ className: clsx(styles$y.textInput, customClass, (_b = {},
115
- _b[styles$y.textInputDanger] = restrictionMessage,
115
+ _b[styles$y.textInputDanger] = restrictionMessage || error,
116
116
  _b)), style: __assign({ paddingLeft: leftIcon ? "36px" : "8px", paddingRight: rightIcon ? "36px" : "8px" }, style), id: props.name, value: value }, props, { disabled: disabled })),
117
117
  rightIcon && (React__default.createElement("button", { tabIndex: -1, type: "button", className: styles$y.iconWrapperRight, onClick: function () { return onRightIconClick === null || onRightIconClick === void 0 ? void 0 : onRightIconClick(); }, "aria-label": "A\u00E7\u00E3o ao clicar no \u00EDcone ao lado direito" }, rightIcon))),
118
118
  (restrictionMessage || showCounter) && (React__default.createElement("div", { className: styles$y.messageContainer },