Skip to content

Commit

Permalink
ensure description comes before qualifier and default value
Browse files Browse the repository at this point in the history
  • Loading branch information
sserrata committed Sep 10, 2024
1 parent a2f8c28 commit 8323e7d
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -416,16 +416,16 @@ function createDetailsNode(
create("div", {
style: { marginLeft: "1rem" },
children: [
guard(getQualifierMessage(schema), (message) =>
guard(schema.description, (description) =>
create("div", {
style: { marginTop: ".5rem", marginBottom: ".5rem" },
children: createDescription(message),
children: createDescription(description),
})
),
guard(schema.description, (description) =>
guard(getQualifierMessage(schema), (message) =>
create("div", {
style: { marginTop: ".5rem", marginBottom: ".5rem" },
children: createDescription(description),
children: createDescription(message),
})
),
createNodes(schema, SCHEMA_TYPE),
Expand Down Expand Up @@ -559,20 +559,20 @@ function createPropertyDiscriminator(
]),
],
}),
guard(getQualifierMessage(discriminator), (message) =>
guard(schema.description, (description) =>
create("div", {
style: {
paddingLeft: "1rem",
},
children: createDescription(message),
children: createDescription(description),
})
),
guard(schema.description, (description) =>
guard(getQualifierMessage(discriminator), (message) =>
create("div", {
style: {
paddingLeft: "1rem",
},
children: createDescription(description),
children: createDescription(message),
})
),
create("DiscriminatorTabs", {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,9 +175,9 @@ export default function SchemaItem(props: Props) {
{renderRequired}
{renderDeprecated}
</span>
{renderQualifierMessage}
{renderSchemaDescription}
{renderEnumDescriptions}
{renderQualifierMessage}
{renderDefaultValue()}
{collapsibleSchemaContent ?? collapsibleSchemaContent}
</div>
Expand Down

0 comments on commit 8323e7d

Please sign in to comment.