diff options
author | Ned Batchelder <ned@nedbatchelder.com> | 2019-10-12 19:37:58 -0400 |
---|---|---|
committer | Ned Batchelder <ned@nedbatchelder.com> | 2019-10-13 12:30:25 -0400 |
commit | eba18707241a052419d54cdc304aea346aa0605c (patch) | |
tree | 2e8a9c1391aa7d293bebacf5ea86169319eafda9 /coverage/htmlfiles/pyfile.html | |
parent | bcbdf41c6bb9d4ee30842bd14d45c7d48c2c6d01 (diff) | |
download | python-coveragepy-git-eba18707241a052419d54cdc304aea346aa0605c.tar.gz |
Better presentation of contexts. #855
Diffstat (limited to 'coverage/htmlfiles/pyfile.html')
-rw-r--r-- | coverage/htmlfiles/pyfile.html | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/coverage/htmlfiles/pyfile.html b/coverage/htmlfiles/pyfile.html index 2154c06c..85f79f18 100644 --- a/coverage/htmlfiles/pyfile.html +++ b/coverage/htmlfiles/pyfile.html @@ -79,11 +79,18 @@ <span class="annotate long">{{line.annotate_long}}</span>{#-#} {% endif -%} {% if line.contexts -%} - <span class="context-button">{{ line.contexts|len }} ctx</span>{#-#} - <span class="context-list"> - {% for context in line.contexts -%} - <span class="context-line">{{context}}</span>{#-#} - {% endfor -%} + <span class="ctx"> + {% if line.context_list -%} + <input type="checkbox" id="ctxs{{line.number}}" /> + {% endif -%} + <label for="ctxs{{line.number}}">{{ line.contexts_label }}</label>{#-#} + {% if line.context_list -%} + <span class="ctxs"> + {% for context in line.context_list -%} + <span>{{context}}</span>{#-#} + {% endfor -%} + </span>{#-#} + {% endif -%} </span>{#-#} {% endif -%} </p> |