pge-front-common 14.2.5-beta.6 → 14.2.5-beta.7

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.js CHANGED
@@ -882,9 +882,8 @@ var styles$w = {"containerInput":"radioButton-module__containerInput___cdZaq","r
882
882
  styleInject(css_248z$A);
883
883
 
884
884
  var RadioButton = function (_a) {
885
- var name = _a.name, label = _a.label, value = _a.value, _b = _a.checked, checked = _b === void 0 ? false : _b, message = _a.message, textError = _a.textError, _c = _a.hasError, hasError = _c === void 0 ? false : _c, _d = _a.required, required = _d === void 0 ? false : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e, onChange = _a.onChange, customClass = _a.customClass, id = _a.id, ariaLabel = _a["aria-label"], ariaDescribedBy = _a["aria-describedby"], props = __rest(_a, ["name", "label", "value", "checked", "message", "textError", "hasError", "required", "disabled", "onChange", "customClass", "id", "aria-label", "aria-describedby"]);
885
+ var name = _a.name, label = _a.label, value = _a.value, _b = _a.checked, checked = _b === void 0 ? false : _b, message = _a.message, textError = _a.textError, _c = _a.hasError, hasError = _c === void 0 ? false : _c, _d = _a.required, required = _d === void 0 ? false : _d, _e = _a.disabled, disabled = _e === void 0 ? false : _e, onChange = _a.onChange, customClass = _a.customClass; _a.id; var ariaLabel = _a["aria-label"], ariaDescribedBy = _a["aria-describedby"], props = __rest(_a, ["name", "label", "value", "checked", "message", "textError", "hasError", "required", "disabled", "onChange", "customClass", "id", "aria-label", "aria-describedby"]);
886
886
  var generatedId = React.useId();
887
- var radioId = id || "radio-".concat(generatedId);
888
887
  var errorId = "radio-error-".concat(generatedId);
889
888
  var messageId = "radio-message-".concat(generatedId);
890
889
  var classes = customClass
@@ -900,8 +899,8 @@ var RadioButton = function (_a) {
900
899
  return (React.createElement("div", { className: classes },
901
900
  React.createElement("div", { className: "".concat(styles$w.envoltorioInput, " ").concat(hasError ? styles$w.envoltorioInputErro : "") },
902
901
  React.createElement("div", { className: styles$w.conteudoInput },
903
- React.createElement("label", { htmlFor: radioId, className: "".concat(styles$w.rotuloRadio, " ").concat(hasError ? styles$w.rotuloErro : "") },
904
- React.createElement("input", __assign({ type: "radio", id: radioId, name: name, value: value, checked: checked, onChange: function (event) {
902
+ React.createElement("label", { htmlFor: name, className: "".concat(styles$w.rotuloRadio, " ").concat(hasError ? styles$w.rotuloErro : "") },
903
+ React.createElement("input", __assign({ type: "radio", id: name, name: name, value: value, checked: checked, onChange: function (event) {
905
904
  onChange(event);
906
905
  }, disabled: disabled, required: required, "aria-label": ariaLabel || (typeof label === "string" ? label : undefined), "aria-describedby": ariaDescribedByValue, "aria-invalid": hasError, "aria-errormessage": hasError && textError ? errorId : undefined }, props)),
907
906
  label && (React.createElement("span", { className: "".concat(styles$w.rotulo, " ").concat(required ? styles$w.rotuloObrigatorio : "") }, label))))),