From 1c0101ce4c171a7c2e61c31c01c4ca800438612c Mon Sep 17 00:00:00 2001 From: Patrick Cloke Date: Fri, 16 Sep 2022 08:50:19 -0400 Subject: [PATCH] Put commas between enum values. --- changelogs/client_server/newsfragments/1240.clarification | 1 + layouts/partials/openapi/render-object-table.html | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 changelogs/client_server/newsfragments/1240.clarification diff --git a/changelogs/client_server/newsfragments/1240.clarification b/changelogs/client_server/newsfragments/1240.clarification new file mode 100644 index 000000000..d88de5eb4 --- /dev/null +++ b/changelogs/client_server/newsfragments/1240.clarification @@ -0,0 +1 @@ +Clarify enum values by separating possible values with commas. diff --git a/layouts/partials/openapi/render-object-table.html b/layouts/partials/openapi/render-object-table.html index b49cb3e82..512714818 100644 --- a/layouts/partials/openapi/render-object-table.html +++ b/layouts/partials/openapi/render-object-table.html @@ -89,7 +89,7 @@ {{ if $required }}Required: {{end -}} {{ $property.description | markdownify -}} - {{ if eq $type "enum"}}

One of: {{ $property.enum }}.

{{ end -}} + {{ if eq $type "enum"}}

One of: [{{ delimit $property.enum ", " }}].

{{ end -}} {{ if (index $property "x-addedInMatrixVersion") }}{{ partial "added-in" (dict "v" (index $property "x-addedInMatrixVersion")) }}{{ end -}} {{ if (index $property "x-changedInMatrixVersion") }}{{ partial "changed-in" (dict "changes_dict" (index $property "x-changedInMatrixVersion")) }}{{ end -}}