Skip to content

Commit

Permalink
Fixed tabs for representation contentType (#1127)
Browse files Browse the repository at this point in the history
closes #1119
  • Loading branch information
ygrik authored Jan 22, 2021
1 parent ea30931 commit 3c27cca
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -102,10 +102,10 @@ <h4>Request body</h4>
<!-- ko if: request.meaningfulRepresentations().length > 0 -->
<div class="tabs" data-bind="foreach: { data: request.meaningfulRepresentations(), as: 'representation' }">
<input class="tab-radio" type="radio" name="requestContentType"
data-bind="attr : { id: 'request' + representation.contentType, checked: $index() === 0 }">
data-bind="attr : { id: 'request' + representation.contentType + '_' + $index(), checked: $index() === 0 }">

<label class="tab-label"
data-bind="attr : { for: 'request' + representation.contentType }, text: representation.contentType"></label>
data-bind="attr : { for: 'request' + representation.contentType + '_' + $index() }, text: representation.contentType"></label>

<div class="tab-content">
<!-- ko if: representation.typeName -->
Expand Down Expand Up @@ -164,10 +164,10 @@ <h4>Response headers</h4>
<!-- ko if: response.meaningfulRepresentations().length > 0 -->
<div class="tabs" data-bind="foreach: { data: meaningfulRepresentations(), as: 'representation' }">
<input class="tab-radio" type="radio"
data-bind="attr: { id: response.identifier + representation.contentType, name: response.identifier, checked: $index() === 0 }">
data-bind="attr: { id: response.identifier + '_' + $index(), name: response.identifier, checked: $index() === 0 }">

<label class="tab-label"
data-bind="attr: { for: response.identifier + representation.contentType }, text: representation.contentType"></label>
data-bind="attr: { for: response.identifier + '_' + $index() }, text: representation.contentType"></label>

<div class="tab-content">
<!-- ko if: representation.typeName -->
Expand Down

0 comments on commit 3c27cca

Please sign in to comment.