Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit c110fb8

Browse files
committed
Merge branch '6.0' into 6.1
* 6.0: prevent the installation of unstable phpdocumentor/type-resolver releases chore: fix typo 'do' verb [Twig Bridge] Add PHPdoc information to some email methods Amend MoneyType twig to include a space. [WebProfilerBundle] Remove redundant code from logger template
2 parents 972926c + ba91838 commit c110fb8

12 files changed

+23
-14
lines changed

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@
153153
"egulias/email-validator": "~3.0.0",
154154
"masterminds/html5": "<2.6",
155155
"phpdocumentor/reflection-docblock": "<5.2",
156-
"phpdocumentor/type-resolver": "<1.5.1",
156+
"phpdocumentor/type-resolver": "<1.5.1|>=1.7.0",
157157
"ocramius/proxy-manager": "<2.1",
158158
"phpunit/phpunit": "<5.4.3"
159159
},

src/Symfony/Bridge/Twig/Mime/WrappedTemplatedEmail.php

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,12 @@ public function toName(): string
3535
return $this->message->getTo()[0]->getName();
3636
}
3737

38+
/**
39+
* @param string $image A Twig path to the image file. It's recommended to define
40+
* some Twig namespace for email images (e.g. '@email/images/logo.png').
41+
* @param string|null $contentType The media type (i.e. MIME type) of the image file (e.g. 'image/png').
42+
* Some email clients require this to display embedded images.
43+
*/
3844
public function image(string $image, string $contentType = null): string
3945
{
4046
$file = $this->twig->getLoader()->getSourceContext($image);
@@ -47,6 +53,13 @@ public function image(string $image, string $contentType = null): string
4753
return 'cid:'.$image;
4854
}
4955

56+
/**
57+
* @param string $file A Twig path to the file. It's recommended to define
58+
* some Twig namespace for email files (e.g. '@email/files/contract.pdf').
59+
* @param string|null $name A custom file name that overrides the original name of the attached file.
60+
* @param string|null $contentType The media type (i.e. MIME type) of the file (e.g. 'application/pdf').
61+
* Some email clients require this to display attached files.
62+
*/
5063
public function attach(string $file, string $name = null, string $contentType = null): void
5164
{
5265
$file = $this->twig->getLoader()->getSourceContext($file);

src/Symfony/Bridge/Twig/Resources/views/Form/bootstrap_4_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
{%- set prepend = not (money_pattern starts with '{{') -%}
77
{%- set append = not (money_pattern ends with '}}') -%}
88
{%- if prepend or append -%}
9-
<div class="input-group{{ group_class|default('') }}">
9+
<div class="input-group {{ group_class|default('') }}">
1010
{%- if prepend -%}
1111
<div class="input-group-prepend">
1212
<span class="input-group-text">{{ money_pattern|form_encode_currency }}</span>

src/Symfony/Bridge/Twig/Resources/views/Form/bootstrap_5_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
{%- set prepend = not (money_pattern starts with '{{') -%}
77
{%- set append = not (money_pattern ends with '}}') -%}
88
{%- if prepend or append -%}
9-
<div class="input-group{{ group_class|default('') }}">
9+
<div class="input-group {{ group_class|default('') }}">
1010
{%- if prepend -%}
1111
<span class="input-group-text">{{ money_pattern|form_encode_currency }}</span>
1212
{%- endif -%}

src/Symfony/Bridge/Twig/Resources/views/Form/bootstrap_base_layout.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
{% set prepend = not (money_pattern starts with '{{') %}
1212
{% set append = not (money_pattern ends with '}}') %}
1313
{% if prepend or append %}
14-
<div class="input-group{{ group_class|default('') }}">
14+
<div class="input-group {{ group_class|default('') }}">
1515
{% if prepend %}
1616
<span class="input-group-addon">{{ money_pattern|form_encode_currency }}</span>
1717
{% endif %}

src/Symfony/Bridge/Twig/Tests/Extension/AbstractBootstrap4LayoutTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1165,7 +1165,7 @@ public function testMoney()
11651165

11661166
$this->assertWidgetMatchesXpath($form->createView(), ['id' => 'my&id', 'attr' => ['class' => 'my&class']],
11671167
'/div
1168-
[@class="input-group"]
1168+
[@class="input-group "]
11691169
[
11701170
./div
11711171
[@class="input-group-prepend"]

src/Symfony/Bridge/Twig/Tests/Extension/AbstractBootstrap5LayoutTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1450,7 +1450,7 @@ public function testMoney()
14501450

14511451
$this->assertWidgetMatchesXpath($form->createView(), ['id' => 'my&id', 'attr' => ['class' => 'my&class']],
14521452
'/div
1453-
[@class="input-group"]
1453+
[@class="input-group "]
14541454
[
14551455
./span
14561456
[@class="input-group-text"]

src/Symfony/Bridge/Twig/Tests/Extension/FormExtensionBootstrap4LayoutTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@ public function testMoneyWidgetInIso()
102102
;
103103

104104
$this->assertSame(<<<'HTML'
105-
<div class="input-group"><div class="input-group-prepend">
105+
<div class="input-group "><div class="input-group-prepend">
106106
<span class="input-group-text">&euro; </span>
107107
</div><input type="text" id="name" name="name" required="required" class="form-control" /></div>
108108
HTML

src/Symfony/Bridge/Twig/Tests/Extension/FormExtensionBootstrap5LayoutTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ public function testMoneyWidgetInIso()
104104
->createView();
105105

106106
self::assertSame(<<<'HTML'
107-
<div class="input-group"><span class="input-group-text">&euro; </span><input type="text" id="name" name="name" required="required" class="form-control" /></div>
107+
<div class="input-group "><span class="input-group-text">&euro; </span><input type="text" id="name" name="name" required="required" class="form-control" /></div>
108108
HTML
109109
, trim($this->renderWidget($view)));
110110
}

src/Symfony/Bundle/WebProfilerBundle/Resources/views/Collector/logger.html.twig

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -253,10 +253,6 @@
253253
{% if has_trace %}
254254
{% set trace_id = 'trace-' ~ category ~ '-' ~ log_index %}
255255
<span><button type="button" class="btn btn-link text-small sf-toggle" data-toggle-selector="#{{ trace_id }}" data-toggle-alt-content="Hide trace">Show trace</button></span>
256-
257-
<div id="{{ trace_id }}" class="context sf-toggle-content sf-toggle-hidden">
258-
{{ profiler_dump(log.context.exception.trace, maxDepth=1) }}
259-
</div>
260256
{% endif %}
261257

262258
{% if has_context %}

src/Symfony/Component/HttpFoundation/Exception/SessionNotFoundException.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
namespace Symfony\Component\HttpFoundation\Exception;
1313

1414
/**
15-
* Raised when a session does not exists. This happens in the following cases:
15+
* Raised when a session does not exist. This happens in the following cases:
1616
* - the session is not enabled
1717
* - attempt to read a session outside a request context (ie. cli script).
1818
*

src/Symfony/Component/Serializer/composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242
"conflict": {
4343
"doctrine/annotations": "<1.12",
4444
"phpdocumentor/reflection-docblock": "<3.2.2",
45-
"phpdocumentor/type-resolver": "<1.4.0",
45+
"phpdocumentor/type-resolver": "<1.4.0|>=1.7.0",
4646
"symfony/dependency-injection": "<5.4",
4747
"symfony/property-access": "<5.4",
4848
"symfony/property-info": "<5.4",

0 commit comments

Comments
 (0)