-
-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Updated the Messenger profiler panel #26674
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{% extends '@WebProfiler/Profiler/layout.html.twig' %} | ||
|
||
{% import _self as helper %} | ||
|
||
{% block toolbar %} | ||
{% set color_code = 'normal' %} | ||
{% set message_count = 0 %} | ||
{% set icon %} | ||
{{ include('@WebProfiler/Icon/messenger.svg') }} | ||
<span class="sf-toolbar-value">{{ message_count }}</span> | ||
{% endset %} | ||
|
||
{{ include('@WebProfiler/Profiler/toolbar_item.html.twig', { link: 'messages', status: color_code }) }} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. you could even avoid passing the status explicitly, as you never change it to anything else than There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Removed too! |
||
{% endblock %} | ||
|
||
{% block menu %} | ||
<span class="label"> | ||
<span class="icon">{{ include('@WebProfiler/Icon/messenger.svg') }}</span> | ||
<strong>Messages</strong> | ||
|
||
{% if collector.messages|length > 0 %} | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. IIRC, we removed all counts from the profiler menu in the redesign done in 2.8. Why having it here ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. True ... but I've moved this to There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Well, you haven't removed the count itself in the profiler menu |
||
<span class="count"> | ||
<span>{{ collector.messages|length }}</span> | ||
</span> | ||
{% endif %} | ||
</span> | ||
{% endblock %} | ||
|
||
{% block panel %} | ||
<h2>Messages</h2> | ||
|
||
{% if collector.messages is empty %} | ||
<div class="empty"> | ||
<p>No messages have been collected.</p> | ||
</div> | ||
{% else %} | ||
<table> | ||
<thead> | ||
<tr> | ||
<th>Message</th> | ||
<th>Result</th> | ||
</tr> | ||
</thead> | ||
<tbody> | ||
{% for message in collector.messages %} | ||
<tr> | ||
<td>{{ message.message.type }}</td> | ||
<td> | ||
{% if message.result.type is defined %} | ||
{{ message.result.type }} | ||
{% endif %} | ||
|
||
{% if message.exception.type is defined %} | ||
{{ message.exception.type }} | ||
{% endif %} | ||
</td> | ||
</tr> | ||
{% endfor %} | ||
</tbody> | ||
</table> | ||
{% endif %} | ||
{% endblock %} |
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wrong count here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is going to be fixed in #26650
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed