Skip to content

Commit

Permalink
feat: ValueComponent to customize value rendering
Browse files Browse the repository at this point in the history
Thanks @gnidan for the work done in #224
  • Loading branch information
jy95 authored Dec 19, 2023
1 parent 24e4260 commit d558668
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions testsite/docs/demo-viewer/custom/values.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import TabItem from "@theme/TabItem"

// if schema defines a default value, ensure it is bold wherever it
// appears (e.g. in an enum)
if (value === schema.default) {
if (schema.default && value === schema.default) {
return <strong>{component}</strong>
}

Expand All @@ -56,7 +56,7 @@ import TabItem from "@theme/TabItem"

// if schema defines a default value, ensure it is bold wherever it
// appears (e.g. in an enum)
if (value === schema.default) {
if (schema.default && value === schema.default) {
return <strong>{component}</strong>
}

Expand Down

0 comments on commit d558668

Please sign in to comment.