Skip to content

Commit

Permalink
Only include endpoint path in <summary> (#1446)
Browse files Browse the repository at this point in the history
  • Loading branch information
David Robertson committed Mar 2, 2023
1 parent a45138c commit f9ea0f9
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 6 deletions.
14 changes: 9 additions & 5 deletions assets/scss/custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -288,16 +288,20 @@ footer {
/* Styles for sections that are rendered from data, such as HTTP APIs and event schemas */
.rendered-data {
background-color: $secondary-lightest-background;
padding: 1rem;
margin: 1rem 0;
padding: 0.85rem;
margin: 0.85rem 0;

details {
summary {
padding: .5rem 0;
p {
max-width: 80%;
h1 {
margin: 0;
/* Ensure the disclosure control is vertically centred with the header text. */
vertical-align: middle;
}
}
p {
max-width: 80%;
}
}

.deprecated-inline {
Expand Down
1 change: 1 addition & 0 deletions changelogs/internal/newsfragments/1446.clarification
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Endpoint disclosures now hide everything but the URL.
2 changes: 1 addition & 1 deletion layouts/partials/openapi/render-operation.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ <h1 id="{{ lower $method }}{{ $anchor }}">
<span class="http-api-method {{ $method }}">{{ $method }}</span>
<span class="endpoint{{ if $operation_data.deprecated }} deprecated-inline{{ end }}">{{ $endpoint }}</span>
</h1>
</summary>

<hr/>

Expand All @@ -49,7 +50,6 @@ <h1 id="{{ lower $method }}{{ $anchor }}">

<p>{{ $operation_data.description | markdownify }}</p>

</summary>

<table class="basic-info">
<tr>
Expand Down

0 comments on commit f9ea0f9

Please sign in to comment.