schema-components 1.12.5 → 1.12.6

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.
@@ -147,10 +147,9 @@ function renderField(tree, value, onChange, userResolver, renderChild, instanceW
147
147
  } catch (err) {
148
148
  throw new SchemaRenderError(err instanceof Error ? err.message : `Render function threw for type "${tree.type}"`, tree, tree.type, err);
149
149
  }
150
- if (result !== void 0 && result !== null) {
151
- if (isValidElement(result)) return result;
152
- if (typeof result === "string" || typeof result === "number") return result;
153
- }
150
+ if (result === null || result === void 0) return null;
151
+ if (isValidElement(result)) return result;
152
+ if (typeof result === "string" || typeof result === "number") return result;
154
153
  }
155
154
  if (value === void 0 || value === null) return /* @__PURE__ */ jsx("span", { children: "—" });
156
155
  return /* @__PURE__ */ jsx("span", { children: typeof value === "string" ? value : JSON.stringify(value) });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "schema-components",
3
- "version": "1.12.5",
3
+ "version": "1.12.6",
4
4
  "description": "React components that render UI from Zod schemas, JSON Schema, and OpenAPI documents",
5
5
  "type": "module",
6
6
  "main": "./dist/index.mjs",