opus-toolkit-components 1.3.6 → 1.3.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.
@@ -4213,10 +4213,12 @@ function Checkbox(_ref) {
4213
4213
  isValid = true,
4214
4214
  errorMessage = '',
4215
4215
  disabled = false,
4216
+ title,
4216
4217
  dataCy
4217
4218
  } = _ref;
4218
4219
  const id = "checkbox-".concat(name);
4219
4220
  const errorId = "".concat(id, "-error");
4221
+ const showError = !isValid && errorMessage;
4220
4222
  return /*#__PURE__*/external_react_default().createElement("div", {
4221
4223
  className: "flex flex-col mb-4"
4222
4224
  }, /*#__PURE__*/external_react_default().createElement("div", {
@@ -4228,12 +4230,13 @@ function Checkbox(_ref) {
4228
4230
  checked: value,
4229
4231
  onChange: onChange,
4230
4232
  disabled: disabled,
4233
+ title: title,
4231
4234
  "data-cy": getDataCy({
4232
4235
  name,
4233
4236
  dataCy
4234
4237
  }),
4235
4238
  "aria-invalid": !isValid,
4236
- "aria-describedby": !isValid && errorMessage ? errorId : undefined,
4239
+ "aria-describedby": showError ? errorId : undefined,
4237
4240
  "aria-disabled": disabled,
4238
4241
  style: {
4239
4242
  accentColor: 'var(--color-primary-btn)'