Skip to content

Commit e22a87e

Browse files
committed
Fix syntax for template name, use number_format instead of localizednumber
1 parent a92ca8a commit e22a87e

File tree

3 files changed

+20
-19
lines changed

3 files changed

+20
-19
lines changed

Bridge/ContainerIntrospectionBundle/Resources/config/services.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,6 @@ services:
1010
tags:
1111
-
1212
name: data_collector
13-
template: 'ContainerIntrospectionBundle:DataCollector:container.html.twig'
13+
template: '@ContainerIntrospection/DataCollector/container.html.twig'
1414
id: steevanb.container_collector
1515
public: false

Bridge/ContainerIntrospectionBundle/Resources/views/DataCollector/container.html.twig

+11-11
Original file line numberDiff line numberDiff line change
@@ -3,33 +3,33 @@
33
{% block toolbar %}
44
{% set icon %}
55
{{ include('@ContainerIntrospection/DataCollector/container.svg') }}
6-
<span class="sf-toolbar-value">{{ collector.countInstantiatedServices()|localizednumber }} / {{ collector.countRegisteredServices()|localizednumber }}</span>
6+
<span class="sf-toolbar-value">{{ collector.countInstantiatedServices()|number_format(0, '.', ',') }} / {{ collector.countRegisteredServices()|number_format(0, '.', ',') }}</span>
77
{% endset %}
88

99
{% set text %}
1010
<div class="sf-toolbar-info-piece">
1111
<b>Instantiated services</b>
12-
<span>{{ collector.countInstantiatedServices()|localizednumber }}</span>
12+
<span>{{ collector.countInstantiatedServices()|number_format(0, '.', ',') }}</span>
1313
</div>
1414

1515
<div class="sf-toolbar-info-piece">
1616
<b>Registered services</b>
17-
<span>{{ collector.countRegisteredServices()|localizednumber }}</span>
17+
<span>{{ collector.countRegisteredServices()|number_format(0, '.', ',') }}</span>
1818
</div>
1919

2020
<div class="sf-toolbar-info-piece">
2121
<b>Public services</b>
22-
<span>{{ collector.countPublicServices()|localizednumber }}</span>
22+
<span>{{ collector.countPublicServices()|number_format(0, '.', ',') }}</span>
2323
</div>
2424

2525
<div class="sf-toolbar-info-piece">
2626
<b>Private services</b>
27-
<span>{{ collector.countPrivateServices()|localizednumber }}</span>
27+
<span>{{ collector.countPrivateServices()|number_format(0, '.', ',') }}</span>
2828
</div>
2929

3030
<div class="sf-toolbar-info-piece">
3131
<b>Parameters</b>
32-
<span>{{ collector.countParameters()|localizednumber }}</span>
32+
<span>{{ collector.countParameters()|number_format(0, '.', ',') }}</span>
3333
</div>
3434
{% endset %}
3535

@@ -93,7 +93,7 @@
9393
<div class="tab">
9494
<h3 class="tab-title">
9595
Instantiated services
96-
<span class="badge">{{ collector.countInstantiatedServices()|localizednumber }}</span>
96+
<span class="badge">{{ collector.countInstantiatedServices()|number_format(0, '.', ',') }}</span>
9797
</h3>
9898

9999
<p class="text-muted">
@@ -183,7 +183,7 @@
183183
<div class="tab">
184184
<h3 class="tab-title">
185185
Registered services
186-
<span class="badge">{{ collector.countRegisteredServices()|localizednumber }}</span>
186+
<span class="badge">{{ collector.countRegisteredServices()|number_format(0, '.', ',') }}</span>
187187
</h3>
188188

189189
<div class="tab-content">
@@ -209,7 +209,7 @@
209209
<div class="tab">
210210
<h3 class="tab-title">
211211
Public services
212-
<span class="badge">{{ collector.countPublicServices()|localizednumber }}</span>
212+
<span class="badge">{{ collector.countPublicServices()|number_format(0, '.', ',') }}</span>
213213
</h3>
214214

215215
<div class="tab-content">
@@ -235,7 +235,7 @@
235235
<div class="tab">
236236
<h3 class="tab-title">
237237
Private services
238-
<span class="badge">{{ collector.countPrivateServices()|localizednumber }}</span>
238+
<span class="badge">{{ collector.countPrivateServices()|number_format(0, '.', ',') }}</span>
239239
</h3>
240240

241241
<div class="tab-content">
@@ -261,7 +261,7 @@
261261
<div class="tab">
262262
<h3 class="tab-title">
263263
Parameters
264-
<span class="badge">{{ collector.countParameters()|localizednumber }}</span>
264+
<span class="badge">{{ collector.countParameters()|number_format(0, '.', ',') }}</span>
265265
</h3>
266266

267267
<div class="tab-content">

README.md

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
[![version](https://img.shields.io/badge/version-1.0.2-green.svg)](https://github.com/steevanb/symfony-container-introspection/tree/1.0.2)
1+
[![version](https://img.shields.io/badge/version-1.0.3-green.svg)](https://github.com/steevanb/symfony-container-introspection/tree/1.0.3)
22
[![php](https://img.shields.io/badge/php-^7.1-blue.svg)](https://php.net)
3-
[![symfony](https://img.shields.io/badge/symfony/dependency--injection-^3.4||^4.0-blue.svg)](https://symfony.com)
4-
![Lines](https://img.shields.io/badge/code%20lines-738-green.svg)
3+
[![symfony](https://img.shields.io/badge/symfony/dependency--injection-^3.4-blue.svg)](https://symfony.com)
4+
![Lines](https://img.shields.io/badge/code%20lines-809-green.svg)
55
![Total Downloads](https://poser.pugx.org/steevanb/symfony-container-introspection/downloads)
66
[![Scrutinizer](https://scrutinizer-ci.com/g/steevanb/symfony-container-introspection/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/steevanb/symfony-container-introspection/)
77

@@ -20,18 +20,19 @@ With Symfony, a new profiler tab will appear:
2020

2121
[Changelog](changelog.md)
2222

23+
If you want to use it with `symfony/dependency-injection ^4.0`, see [^1.1](https://github.com/steevanb/symfony-container-introspection)
24+
2325
Installation
2426
============
2527

28+
Don't use `^1.0.*` as version, because `1.1.0` is not compatible with `symfony/dependency-injection 3.4` (only with `^4.0`) but is marked as compatible by error.
2629
```bash
27-
composer require --dev steevanb/symfony-container-introspection ^1.0.2
30+
composer require --dev steevanb/symfony-container-introspection 1.0.*
2831
```
2932

3033
If you use Symfony (and not just symfony/dependency-injection), you can add `ContainerIntrospectionBundle` to your Kernel:
3134
```php
32-
# app/AppKernel.php for Symfony 3.*
33-
# src/Kernel.php for Symfony 4.*
34-
35+
# app/AppKernel.php
3536
class Kernel
3637
{
3738
public function registerBundles()

0 commit comments

Comments
 (0)