Skip to content

Commit 8ffe408

Browse files
committed
Merge remote-tracking branch 'upstream/6.4' into docs/lazy
2 parents 1e06011 + 2ff728f commit 8ffe408

File tree

186 files changed

+8198
-2420
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

186 files changed

+8198
-2420
lines changed

.doctor-rst.yaml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ rules:
1616
ensure_exactly_one_space_between_link_definition_and_link: ~
1717
ensure_link_definition_contains_valid_url: ~
1818
ensure_order_of_code_blocks_in_configuration_block: ~
19+
ensure_php_reference_syntax: ~
1920
extend_abstract_controller: ~
2021
# extension_xlf_instead_of_xliff: ~
2122
forbidden_directives:
@@ -36,6 +37,7 @@ rules:
3637
no_directive_after_shorthand: ~
3738
no_duplicate_use_statements: ~
3839
no_explicit_use_of_code_block_php: ~
40+
no_footnotes: ~
3941
no_inheritdoc: ~
4042
no_merge_conflict: ~
4143
no_namespace_after_use_statements: ~
@@ -80,6 +82,10 @@ rules:
8082
exclude_rule_for_file:
8183
- path: configuration/multiple_kernels.rst
8284
rule_name: replacement
85+
- path: page_creation.rst
86+
rule_name: no_php_open_tag_in_code_block_php_directive
87+
- path: frontend/create_ux_bundle.rst
88+
rule_name: argument_variable_must_match_type
8389

8490
# do not report as violation
8591
whitelist:
@@ -94,7 +100,6 @@ whitelist:
94100
- '.. _`LDAP injection`: http://projects.webappsec.org/w/page/13246947/LDAP%20Injection'
95101
- '.. versionadded:: 2.7.2' # Doctrine
96102
- '.. versionadded:: 1.9.0' # Encore
97-
- '.. versionadded:: 1.11' # Messenger (Middleware / DoctrineBundle)
98103
- '.. versionadded:: 1.18' # Flex in setup/upgrade_minor.rst
99104
- '.. versionadded:: 1.0.0' # Encore
100105
- '.. versionadded:: 2.7.1' # Doctrine
@@ -104,6 +109,5 @@ whitelist:
104109
- '.. versionadded:: 0.2' # MercureBundle
105110
- '.. versionadded:: 3.6' # MonologBundle
106111
- '.. versionadded:: 3.8' # MonologBundle
107-
- '// bin/console'
108112
- '.. _`a feature to test applications using Mercure`: https://github.com/symfony/panther#creating-isolated-browsers-to-test-apps-using-mercure-or-websocket'
109113
- '.. End to End Tests (E2E)'

.github/workflows/ci.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ jobs:
7373
key: ${{ runner.os }}-doctor-rst-${{ steps.extract_base_branch.outputs.branch }}
7474

7575
- name: "Run DOCtor-RST"
76-
uses: docker://oskarstark/doctor-rst:1.48.0
76+
uses: docker://oskarstark/doctor-rst:1.51.0
7777
with:
7878
args: --short --error-format=github --cache-file=/github/workspace/.cache/doctor-rst.cache
7979

_build/build.php

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,14 @@
5252
foreach (new RegexIterator($iterator, '/^.+\.html$/i', RegexIterator::GET_MATCH) as $match) {
5353
$htmlFilePath = array_shift($match);
5454
$htmlContents = file_get_contents($htmlFilePath);
55-
file_put_contents($htmlFilePath, str_replace('<head>', '<head><base href="/">', $htmlContents));
55+
56+
$htmlRelativeFilePath = str_replace($outputDir.'/', '', $htmlFilePath);
57+
$subdirLevel = substr_count($htmlRelativeFilePath, '/');
58+
$baseHref = str_repeat('../', $subdirLevel);
59+
60+
$htmlContents = str_replace('<head>', '<head><base href="'.$baseHref.'">', $htmlContents);
61+
$htmlContents = str_replace('<img src="/_images/', '<img src="_images/', $htmlContents);
62+
file_put_contents($htmlFilePath, $htmlContents);
5663
}
5764

5865
foreach (new RegexIterator($iterator, '/^.+\.css/i', RegexIterator::GET_MATCH) as $match) {

_build/redirection_map

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -562,3 +562,6 @@
562562
/frontend/assetic/index /frontend
563563
/controller/argument_value_resolver /controller/value_resolver
564564
/frontend/ux https://symfony.com/bundles/StimulusBundle/current/index.html
565+
/messenger/handler_results /messenger#messenger-getting-handler-results
566+
/messenger/dispatch_after_current_bus /messenger#messenger-transactional-messages
567+
/messenger/multiple_buses /messenger#messenger-multiple-buses
-2.69 KB
Loading
-62.4 KB
Binary file not shown.

_images/doctrine/mapping_relations.svg

Lines changed: 602 additions & 0 deletions
Loading
-148 KB
Binary file not shown.

_images/doctrine/mapping_relations_proxy.svg

Lines changed: 926 additions & 0 deletions
Loading
-62.9 KB
Binary file not shown.

_images/doctrine/mapping_single_entity.svg

Lines changed: 469 additions & 0 deletions
Loading
-45.2 KB
Binary file not shown.

_images/form/data-transformer-types.svg

Lines changed: 178 additions & 0 deletions
Loading

_images/form/form_prepopulation_workflow.svg

Lines changed: 252 additions & 53 deletions
Loading

_images/form/form_submission_workflow.svg

Lines changed: 333 additions & 75 deletions
Loading

_images/form/form_workflow.svg

Lines changed: 262 additions & 65 deletions
Loading

_images/form/tailwindcss-form.png

37.7 KB
Loading

_images/http/xkcd-full.png

-10.7 KB
Binary file not shown.

_images/http/xkcd-full.svg

Lines changed: 324 additions & 0 deletions
Loading

_images/http/xkcd-request.png

-6.83 KB
Binary file not shown.

_images/http/xkcd-request.svg

Lines changed: 191 additions & 0 deletions
Loading

_images/mercure/discovery.png

-173 KB
Binary file not shown.

_images/mercure/discovery.svg

Lines changed: 294 additions & 0 deletions
Loading

_images/mercure/hub.svg

Lines changed: 196 additions & 0 deletions
Loading

_images/mercure/schema.png

-326 KB
Binary file not shown.

_images/sources/README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,9 @@ Use the following snippet to embed the diagram in the docs:
3939
```
4040
.. raw:: html
4141
42-
<object data="../_images/<folder-name>/<diagram-file-name>.svg" type="image/svg+xml"></object>
42+
<object data="_images/<folder-name>/<diagram-file-name>.svg" type="image/svg+xml"
43+
alt="<alt description>"
44+
></object>
4345
```
4446

4547
### Reasoning
3.04 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
1.96 KB
Binary file not shown.
Binary file not shown.
Binary file not shown.
1.83 KB
Binary file not shown.

_images/sources/http/xkcd-full.dia

1.57 KB
Binary file not shown.

_images/sources/http/xkcd-request.dia

1.35 KB
Binary file not shown.

_images/sources/mercure/discovery.dia

1.42 KB
Binary file not shown.

_images/sources/mercure/hub.dia

1.53 KB
Binary file not shown.

bundles.rst

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ to be adjusted if needed:
9494

9595
``src/``
9696
Contains all PHP classes related to the bundle logic (e.g. ``Controller/RandomController.php``).
97-
97+
9898
``config/``
9999
Houses configuration, including routing configuration (e.g. ``routing.yaml``).
100100

@@ -105,13 +105,14 @@ to be adjusted if needed:
105105
Holds translations organized by domain and locale (e.g. ``AcmeTestBundle.en.xlf``).
106106

107107
``public/``
108-
Contains web assets (images, stylesheets, etc) and is copied or symbolically
109-
linked into the project ``public/`` directory via the ``assets:install`` console
110-
command.
108+
Contains web assets (images, compiled CSS and JavaScript files, etc.) and is
109+
copied or symbolically linked into the project ``public/`` directory via the
110+
``assets:install`` console command.
111111

112112
``assets/``
113-
Contains JavaScript, CSS, images and other assets related to the bundle that
114-
are not in ``public/`` (e.g. stimulus controllers)
113+
Contains the web asset sources (JavaScript and TypeScript files, CSS and Sass
114+
files, etc.), images and other assets related to the bundle that are not in
115+
``public/`` (e.g. Stimulus controllers)
115116

116117
``tests/``
117118
Holds all tests for the bundle.

bundles/best_practices.rst

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ The following is the recommended directory structure of an AcmeBlogBundle:
6363
.. code-block:: text
6464
6565
<your-bundle>/
66+
├── assets/
6667
├── config/
6768
├── docs/
6869
│ └─ index.md
@@ -121,7 +122,8 @@ Doctrine ORM entities ``src/Entity/``
121122
Doctrine ODM documents ``src/Document/``
122123
Event Listeners ``src/EventListener/``
123124
Configuration (routes, services, etc.) ``config/``
124-
Web Assets (CSS, JS, images) ``public/``
125+
Web Assets (compiled CSS and JS, images) ``public/``
126+
Web Asset sources (``.scss``, ``.ts``, Stimulus) ``assets/``
125127
Translation files ``translations/``
126128
Validation (when not using attributes) ``config/validation/``
127129
Serialization (when not using attributes) ``config/serialization/``
@@ -529,16 +531,12 @@ Resources
529531
---------
530532

531533
If the bundle references any resources (config files, translation files, etc.),
532-
don't use physical paths (e.g. ``__DIR__/config/services.xml``) but logical
533-
paths (e.g. ``@AcmeBlogBundle/config/services.xml``).
534+
you can use physical paths (e.g. ``__DIR__/config/services.xml``).
534535

535-
The logical paths are required because of the bundle overriding mechanism that
536-
lets you override any resource/file of any bundle. See :ref:`http-kernel-resource-locator`
537-
for more details about transforming physical paths into logical paths.
538-
539-
Beware that templates use a simplified version of the logical path shown above.
540-
For example, an ``index.html.twig`` template located in the ``templates/Default/``
541-
directory of the AcmeBlogBundle, is referenced as ``@AcmeBlog/Default/index.html.twig``.
536+
In the past, we recommended to only use logical paths (e.g.
537+
``@AcmeBlogBundle/config/services.xml``) and resolve them with the
538+
:ref:`resource locator <http-kernel-resource-locator>` provided by the Symfony
539+
kernel, but this is no longer a recommended practice.
542540

543541
Learn more
544542
----------

bundles/override.rst

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,6 @@ When using a third-party bundle, you might want to customize or override some of
55
its features. This document describes ways of overriding the most common
66
features of a bundle.
77

8-
.. tip::
9-
10-
The bundle overriding mechanism means that you cannot use physical paths to
11-
refer to bundle's resources (e.g. ``__DIR__/config/services.xml``). Always
12-
use logical paths in your bundles (e.g. ``@FooBundle/config/services.xml``)
13-
and call the :ref:`locateResource() method <http-kernel-resource-locator>`
14-
to turn them into physical paths when needed.
15-
168
.. _override-templates:
179

1810
Templates

0 commit comments

Comments
 (0)