Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@

- The profiler collector has been rewritten to use objects instead of arrays.
- Bumped minimum Symfony version to 2.8.
- Updated profiler badges to match Symfony 2.8+ profiler design.

### Fixed

Expand Down
13 changes: 9 additions & 4 deletions Resources/views/webprofiler.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,15 @@
{% set text %}
<div class="sf-toolbar-info-piece">
<b>Successful requests</b>
<span>{{ collector.successfulStacks|length }}</span>
<span class="sf-toolbar-status">{{ collector.successfulStacks|length }}</span>
</div>
<div class="sf-toolbar-info-piece">
<b>Failed requests</b>
<span>{{ collector.failedStacks|length }}</span>
<span class="sf-toolbar-status {{ collector.failedStacks|length ? 'sf-toolbar-status-red' }}">{{ collector.failedStacks|length }}</span>
</div>
{% endset %}

{% include 'WebProfilerBundle:Profiler:toolbar_item.html.twig' with { 'link': profiler_url } %}
{% include 'WebProfilerBundle:Profiler:toolbar_item.html.twig' with { 'link': profiler_url, 'status': collector.failedStacks|length ? 'red' : '' } %}
{% endif %}
{% endblock %}

Expand All @@ -33,11 +33,16 @@

{% block menu %}
{# This left-hand menu appears when using the full-screen profiler. #}
<span class="label {{ collector.stacks|length == 0 ? 'disabled' }}">
<span class="label {{ collector.stacks|length == 0 ? 'disabled' }} {{ collector.failedStacks|length ? 'label-status-error' }}">
<span class="icon">
{{ include('@Httplug/Icon/httplug.svg') }}
</span>
<strong>Httplug</strong>
{% if collector.failedStacks|length %}
<span class="count">
<span>{{ collector.failedStacks|length }}</span>
</span>
{% endif %}
</span>
{% endblock %}

Expand Down