Start annotating which version of the spec added a thing (#3425)
* Introduce a new "added-in" template and use it on endpoints * Use "added-in" on schema properties too * Annotate sections of the spec with their added versions * Demo of "added-in" on a room version (to be fleshed out) * Use clearer versioning semantics * Update and fix validator for Swagger custom properties * Fix docs
This commit is contained in:
parent
649fc2bdd2
commit
5be0df02c5
32 changed files with 380 additions and 22 deletions
8
layouts/shortcodes/added-in.html
Normal file
8
layouts/shortcodes/added-in.html
Normal file
|
@ -0,0 +1,8 @@
|
|||
{{ $ver := .Params.v }}
|
||||
{{ $this := .Params.this }}
|
||||
|
||||
{{ if $this }}
|
||||
<span>**[New in this version]**</span>
|
||||
{{ else }}
|
||||
<span>**[Added in `v{{ $ver }}`]**</span>
|
||||
{{ end }} {{/* Do not leave an empty line at the end of this file otherwise the inline behaviour breaks. */}}
|
|
@ -37,6 +37,10 @@
|
|||
|
||||
<hr/>
|
||||
|
||||
{{ if (index $definition "x-addedInMatrixVersion") }}
|
||||
{{ partial "added-in" (dict "v" (index $definition "x-addedInMatrixVersion")) }}
|
||||
{{ end }}
|
||||
|
||||
{{ $definition.description | markdownify }}
|
||||
|
||||
</summary>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue