Skip to content

Commit 559554e

Browse files
committed
bug symfony#16023 Minor fixes for the profiler and toolbar (javiereguiluz)
This PR was squashed before being merged into the 2.8 branch (closes symfony#16023). Discussion ---------- Minor fixes for the profiler and toolbar | Q | A | ------------- | --- | Bug fix? | yes | New feature? | no | BC breaks? | no | Deprecations? | no | Tests pass? | yes | Fixed tickets | partially symfony#15439 | License | MIT | Doc PR | - Changes: * Fixed a misaligned icon * Changed the priorities of the collectors to better control their position and to leave a "gap" between priorities so custom panels can be displayed between the default panels. This idea came from @stof. By the way, @stof do you know how can I set the priority of the SwiftMailer collector? Its definition is the only one that doesn't use the `<tag name="data_collector" />`: ```xml <service id="swiftmailer.data_collector" class="%swiftmailer.data_collector.class%"> <argument type="service" id="service_container" /> </service> ``` https://github.com/symfony/swiftmailer-bundle/blob/master/Resources/config/swiftmailer.xml#L90-L92 Commits ------- bff4098 Minor fixes for the profiler and toolbar
2 parents b107f23 + bff4098 commit 559554e

File tree

7 files changed

+14
-13
lines changed

7 files changed

+14
-13
lines changed

src/Symfony/Bundle/DebugBundle/Resources/config/services.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
</service>
1212

1313
<service id="data_collector.dump" class="Symfony\Component\HttpKernel\DataCollector\DumpDataCollector">
14-
<tag name="data_collector" id="dump" template="@Debug/Profiler/dump.html.twig" />
14+
<tag name="data_collector" id="dump" template="@Debug/Profiler/dump.html.twig" priority="240" />
1515
<argument type="service" id="debug.stopwatch" on-invalid="ignore" />
1616
<argument>null</argument><!-- %templating.helper.code.file_link_format% -->
1717
<argument>%kernel.charset%</argument>

src/Symfony/Bundle/DebugBundle/Tests/DependencyInjection/DebugExtensionTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ public function testLoadWithoutConfiguration()
2828
array(
2929
'id' => 'dump',
3030
'template' => '@Debug/Profiler/dump.html.twig',
31+
'priority' => 240,
3132
),
3233
);
3334

src/Symfony/Bundle/FrameworkBundle/Resources/config/collectors.xml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,41 +23,41 @@
2323

2424
<service id="data_collector.request" class="%data_collector.request.class%">
2525
<tag name="kernel.event_subscriber" />
26-
<tag name="data_collector" template="@WebProfiler/Collector/request.html.twig" id="request" priority="260" />
26+
<tag name="data_collector" template="@WebProfiler/Collector/request.html.twig" id="request" priority="335" />
2727
</service>
2828

2929
<service id="data_collector.ajax" class="Symfony\Bundle\FrameworkBundle\DataCollector\AjaxDataCollector" public="false">
30-
<tag name="data_collector" template="@WebProfiler/Collector/ajax.html.twig" id="ajax" priority="256" />
30+
<tag name="data_collector" template="@WebProfiler/Collector/ajax.html.twig" id="ajax" priority="315" />
3131
</service>
3232

3333
<service id="data_collector.exception" class="%data_collector.exception.class%" public="false">
34-
<tag name="data_collector" template="@WebProfiler/Collector/exception.html.twig" id="exception" priority="255" />
34+
<tag name="data_collector" template="@WebProfiler/Collector/exception.html.twig" id="exception" priority="305" />
3535
</service>
3636

3737
<service id="data_collector.events" class="%data_collector.events.class%" public="false">
38-
<tag name="data_collector" template="@WebProfiler/Collector/events.html.twig" id="events" priority="255" />
38+
<tag name="data_collector" template="@WebProfiler/Collector/events.html.twig" id="events" priority="290" />
3939
<argument type="service" id="event_dispatcher" on-invalid="ignore" />
4040
</service>
4141

4242
<service id="data_collector.logger" class="%data_collector.logger.class%" public="false">
43-
<tag name="data_collector" template="@WebProfiler/Collector/logger.html.twig" id="logger" priority="255" />
43+
<tag name="data_collector" template="@WebProfiler/Collector/logger.html.twig" id="logger" priority="300" />
4444
<tag name="monolog.logger" channel="profiler" />
4545
<argument type="service" id="logger" on-invalid="ignore" />
4646
</service>
4747

4848
<service id="data_collector.time" class="%data_collector.time.class%" public="false">
49-
<tag name="data_collector" template="@WebProfiler/Collector/time.html.twig" id="time" priority="259" />
49+
<tag name="data_collector" template="@WebProfiler/Collector/time.html.twig" id="time" priority="330" />
5050
<argument type="service" id="kernel" on-invalid="ignore" />
5151
<argument type="service" id="debug.stopwatch" on-invalid="ignore" />
5252
</service>
5353

5454
<service id="data_collector.memory" class="%data_collector.memory.class%" public="false">
55-
<tag name="data_collector" template="@WebProfiler/Collector/memory.html.twig" id="memory" priority="258" />
55+
<tag name="data_collector" template="@WebProfiler/Collector/memory.html.twig" id="memory" priority="325" />
5656
</service>
5757

5858
<service id="data_collector.router" class="%data_collector.router.class%" >
5959
<tag name="kernel.event_listener" event="kernel.controller" method="onKernelController"/>
60-
<tag name="data_collector" template="@WebProfiler/Collector/router.html.twig" id="router" priority="255" />
60+
<tag name="data_collector" template="@WebProfiler/Collector/router.html.twig" id="router" priority="285" />
6161
</service>
6262
</services>
6363
</container>

src/Symfony/Bundle/FrameworkBundle/Resources/config/form_debug.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
<service id="data_collector.form.extractor" class="%data_collector.form.extractor.class%" />
3030

3131
<service id="data_collector.form" class="%data_collector.form.class%">
32-
<tag name="data_collector" template="@WebProfiler/Collector/form.html.twig" id="form" priority="255" />
32+
<tag name="data_collector" template="@WebProfiler/Collector/form.html.twig" id="form" priority="310" />
3333
<argument type="service" id="data_collector.form.extractor" />
3434
</service>
3535
</services>

src/Symfony/Bundle/FrameworkBundle/Resources/config/translation_debug.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212

1313
<!-- DataCollector -->
1414
<service id="data_collector.translation" class="Symfony\Component\Translation\DataCollector\TranslationDataCollector">
15-
<tag name="data_collector" template="@WebProfiler/Collector/translation.html.twig" id="translation" priority="255" />
15+
<tag name="data_collector" template="@WebProfiler/Collector/translation.html.twig" id="translation" priority="275" />
1616
<argument type="service" id="translator.data_collector" />
1717
</service>
1818
</services>

src/Symfony/Bundle/SecurityBundle/Resources/config/collectors.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<services>
1212
<service id="data_collector.security" class="%data_collector.security.class%" public="false">
13-
<tag name="data_collector" template="@Security/Collector/security.html.twig" id="security" />
13+
<tag name="data_collector" template="@Security/Collector/security.html.twig" id="security" priority="270" />
1414
<argument type="service" id="security.token_storage" on-invalid="ignore" />
1515
<argument type="service" id="security.role_hierarchy" />
1616
<argument type="service" id="security.logout_url_generator" />

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Profiler/toolbar.css.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
}
5454
.sf-toolbarreset .hide-button svg {
5555
max-height: 18px;
56-
padding-top: 10px;
56+
margin-top: 10px;
5757
}
5858

5959
.sf-toolbar-block {

0 commit comments

Comments
 (0)