# Conflicts: # .github/PULL_REQUEST_TEMPLATE.md
# Conflicts: # CHANGELOG.md # CONTRIBUTORS.md # calendar-bundle/contao/languages/ja/tl_module.xlf # calendar-bundle/contao/languages/pl/tl_module.xlf # calendar-bundle/contao/languages/ru/tl_module.xlf # core-bundle/contao/languages/cs/tl_maintenance.xlf # core-bundle/contao/languages/de/tl_maintenance.xlf # core-bundle/contao/languages/it/tl_maintenance.xlf # core-bundle/contao/languages/ja/default.xlf # core-bundle/contao/languages/ja/tl_content.xlf # core-bundle/contao/languages/ja/tl_maintenance.xlf # core-bundle/contao/languages/ja/tl_page.xlf # core-bundle/contao/languages/ja/tl_user.xlf # core-bundle/contao/languages/nl/tl_maintenance.xlf # core-bundle/contao/languages/pl/default.xlf # core-bundle/contao/languages/pl/exception.xlf # core-bundle/contao/languages/pl/explain.xlf # core-bundle/contao/languages/pl/modules.xlf # core-bundle/contao/languages/pl/tl_article.xlf # core-bundle/contao/languages/pl/tl_content.xlf # core-bundle/contao/languages/pl/tl_favorites.xlf # core-bundle/contao/languages/pl/tl_form.xlf # core-bundle/contao/languages/pl/tl_form_field.xlf # core-bundle/contao/languages/pl/tl_image_size.xlf # core-bundle/contao/languages/pl/tl_image_size_item.xlf # core-bundle/contao/languages/pl/tl_log.xlf # core-bundle/contao/languages/pl/tl_maintenance.xlf # core-bundle/contao/languages/pl/tl_member.xlf # core-bundle/contao/languages/pl/tl_member_group.xlf # core-bundle/contao/languages/pl/tl_module.xlf # core-bundle/contao/languages/pl/tl_opt_in.xlf # core-bundle/contao/languages/pl/tl_page.xlf # core-bundle/contao/languages/pl/tl_preview_link.xlf # core-bundle/contao/languages/pl/tl_user.xlf # core-bundle/contao/languages/pl/tl_user_group.xlf # core-bundle/contao/languages/ru/default.xlf # core-bundle/contao/languages/ru/tl_content.xlf # core-bundle/contao/languages/ru/tl_maintenance.xlf # core-bundle/contao/languages/ru/tl_page.xlf # core-bundle/contao/languages/ru/tl_user.xlf # core-bundle/contao/languages/sl/tl_maintenance.xlf # core-bundle/contao/languages/sv/tl_maintenance.xlf # core-bundle/contao/languages/tr/default.xlf # core-bundle/contao/languages/tr/explain.xlf # core-bundle/contao/languages/tr/tl_content.xlf # core-bundle/contao/languages/tr/tl_maintenance.xlf # core-bundle/contao/languages/tr/tl_module.xlf # core-bundle/contao/languages/tr/tl_page.xlf # core-bundle/contao/languages/tr/tl_user.xlf # news-bundle/contao/languages/ja/tl_module.xlf # news-bundle/contao/languages/pl/default.xlf # news-bundle/contao/languages/pl/tl_module.xlf # news-bundle/contao/languages/pl/tl_news.xlf # news-bundle/contao/languages/pl/tl_news_archive.xlf # news-bundle/contao/languages/ru/tl_module.xlf # newsletter-bundle/contao/languages/pl/tl_newsletter.xlf
# Conflicts: # CHANGELOG.md # CONTRIBUTORS.md # core-bundle/contao/languages/ja/tl_maintenance.xlf # core-bundle/contao/languages/sl/tl_theme.xlf # core-bundle/contao/languages/tr/tl_maintenance.xlf
Allow to configure the components-dir (see #6846)
Description
-----------
For every Contao project, you must configure the contao-component-dir in the composer.json.
For a long time I thought that this config allows you to determine where the assets are located _and_ loaded from.
```json
{
"extra": {
"contao-component-dir": "my-contao-assets"
}
}
```
However, the Contao Core bundle is not using this config and hardcodes the assets directory to `/assets`.
Because I have the use case of modifying where to load the contao assets from, I propose the `contao.component_dir` config.
Currently, `/assets` collides with the default file structure of Symfony projects.
Commits
-------
fd4c56d Add contao.component_dir config
d25086b Tests
df99d5a Read config from composer.jsonAdd a button to the "invalid request token" template (see #6938)
Description ----------- Fixes #6924 <img width="953" alt="" src="https://github.com/contao/contao/assets/1192057/571031ac-a141-4211-8ccd-b521bd1c5f09"> I don‘t know if we really need a button though. Commits ------- 0eed9f3 Add a button to the "invalid request token" template 42840fd Rename "authentication token" to "request token"
# Conflicts: # CHANGELOG.md # CONTRIBUTORS.md # calendar-bundle/contao/languages/lv/tl_calendar_events.xlf # calendar-bundle/contao/languages/lv/tl_module.xlf # news-bundle/contao/languages/lv/tl_module.xlf # news-bundle/contao/languages/lv/tl_news.xlf # newsletter-bundle/contao/languages/lv/tl_newsletter.xlf
Fallback to the current request in the scope matcher (see #6998)
Description ----------- Commits ------- 5a8c56e Fallback to the current request in the scope matcher
Add the PageFinder::getCurrentPage() method (see #6997)
Description ----------- This is the first step towards deprecating `global $objPage`. Commits ------- eda7f87 Add the `PageFinder::getCurrentPage()` method 09fd8b3 Use the new service in the AbstractFragmentController 71a2c21 Replace $GLOBALS['objPage'] in the figure builder 9b86871 Make the request stack a required argument
Replace $GLOBALS['objPage'] in the fragment handler (see #7001)
Replace $GLOBALS['objPage'] in the filesystem loader (see #7004)
Replace $GLOBALS['objPage'] in the model argument resolver (see #7000)
Description ----------- Follow-up on #6997 Commits ------- 4b8d029 Replace `$GLOBALS['objPage']` in the model argument resolver 188c42a Only check the pageModel if is_a($type, PageModel::class) 571bd9c Remove the special handling 9747b4c Remove a left-over comment 5c986dc Revert the changes in the ModelArgumentResolver
# Conflicts: # CHANGELOG.md # calendar-bundle/contao/languages/sr/default.xlf # calendar-bundle/contao/languages/sr/tl_calendar.xlf # calendar-bundle/contao/languages/sr/tl_calendar_events.xlf # calendar-bundle/contao/languages/sr/tl_module.xlf # core-bundle/contao/languages/es/default.xlf # core-bundle/contao/languages/sl/tl_article.xlf # core-bundle/contao/languages/tr/tl_member.xlf # core-bundle/contao/languages/tr/tl_module.xlf # newsletter-bundle/contao/languages/sr/default.xlf # newsletter-bundle/contao/languages/sr/tl_module.xlf # newsletter-bundle/contao/languages/sr/tl_newsletter.xlf # newsletter-bundle/contao/languages/sr/tl_newsletter_channel.xlf # newsletter-bundle/contao/languages/sr/tl_newsletter_recipients.xlf
# Conflicts: # CHANGELOG.md # core-bundle/contao/languages/ru/default.xlf # core-bundle/contao/languages/ru/tl_article.xlf
Document the PHP versions in the GitHub workflow files (see #7065)
Description ----------- Commits ------- 977b8a9 Document the PHP versions in the GitHub workflow files
Rename tools to vendor-bin (see #7066)
Description ----------- Because Phive uses `tools/` and we don‘t want to cause issues for developers who want to use Phive with Contao. Commits ------- 5f2eccc Rename `cs-fixer` to `ecs` 28557d6 Rename `monorepo` to `monorepo-tools` 15ac574 Rename `tools` to `vendor-bin` 3e3786c Correctly set up the dependencies check
Revert "Allow to configure the components-dir (see #6846)"
This reverts commit 796f20f.
# Conflicts: # .github/workflows/ci.yml # .gitignore # CHANGELOG.md # composer.json # core-bundle/src/Routing/PageFinder.php # phpstan.neon # tools/phpstan/config/contao.neon # tools/require-checker/composer.lock # vendor-bin/ecs/config/default.php # vendor-bin/monorepo-tools/composer.json # vendor-bin/monorepo-tools/composer.lock # vendor-bin/phpstan/config/contao.neon # vendor-bin/rector/composer.json # vendor-bin/rector/config/rector.php # vendor-bin/require-checker/composer.json # vendor-bin/require-checker/composer.lock # vendor-bin/require-checker/config/config.json
# Conflicts: # CHANGELOG.md # calendar-bundle/contao/languages/tr/tl_module.xlf # comments-bundle/contao/languages/tr/default.xlf # comments-bundle/contao/languages/tr/tl_calendar.xlf # comments-bundle/contao/languages/tr/tl_faq.xlf # comments-bundle/contao/languages/tr/tl_faq_category.xlf # comments-bundle/contao/languages/tr/tl_news_archive.xlf # news-bundle/contao/languages/tr/tl_module.xlf # newsletter-bundle/contao/languages/tr/tl_newsletter.xlf
Description ----------- Commits ------- 09b360c Fix the CI chain
# Conflicts: # CHANGELOG.md # calendar-bundle/contao/languages/it/tl_module.xlf # core-bundle/config/listener.yaml # core-bundle/contao/languages/it/default.xlf # core-bundle/contao/languages/it/tl_article.xlf # core-bundle/contao/languages/it/tl_content.xlf # core-bundle/contao/languages/it/tl_maintenance.xlf # core-bundle/contao/languages/it/tl_member.xlf # core-bundle/contao/languages/it/tl_module.xlf # core-bundle/contao/languages/it/tl_page.xlf # core-bundle/contao/languages/it/tl_theme.xlf # core-bundle/contao/languages/it/tl_user.xlf # core-bundle/contao/languages/sl/default.xlf # core-bundle/contao/languages/sl/exception.xlf # core-bundle/contao/languages/sl/explain.xlf # core-bundle/contao/languages/sl/modules.xlf # core-bundle/contao/languages/sl/tl_article.xlf # core-bundle/contao/languages/sl/tl_content.xlf # core-bundle/contao/languages/sl/tl_files.xlf # core-bundle/contao/languages/sl/tl_image_size.xlf # core-bundle/contao/languages/sl/tl_log.xlf # core-bundle/contao/languages/sl/tl_maintenance.xlf # core-bundle/contao/languages/sl/tl_member.xlf # core-bundle/contao/languages/sl/tl_module.xlf # core-bundle/contao/languages/sl/tl_page.xlf # core-bundle/contao/languages/sl/tl_settings.xlf # core-bundle/contao/languages/sl/tl_theme.xlf # core-bundle/contao/languages/sl/tl_user.xlf # news-bundle/contao/languages/it/tl_module.xlf
Update the GitHub workflows (see #7208)
Description ----------- Commits ------- 53f2c68 Update the GitHub workflows
Add a rich text Twig component (see #7034)
Description ----------- This introduces a `_rich_text` component as outlined in #6783. This way you do not have to repeat yourself with things like this but can change it at one place: ```twig <div class="rte"> {{ text|csp_inline_styles|insert_tag|encode_email|raw }} </div> ``` It should also make updates smoother when we add yet another filter. 😛 Commits ------- eda2789 add a rich text component 1dc0c3a Update core-bundle/contao/templates/twig/component/_rich_text.html.twig 4b3dc38 add a note, that the text content needs to be trusted
Make the entity cache tags test compatible with PHPUnit 10 (see #7150)
Render widget groups in the back end with CSS grid (see #7087)
Description ----------- Reviving #2053 with this for Contao ^5.3 and the new introduced classes (w25, w33, w50, w66, w75). Could be merged with additional changes and would be BC-compatible due to the `widget-group` wrapper. Keep in mind this is the reworked CSS-Grid based on @m-vo's solution for the backend widgets as discussed in the contao call for #1024. ___ #### Rewrite Also grouped most media-queries so it's mobile first (not the split-button tho, doesn't make sense for that one) ___ #### Additional classes Introcuded `.w16` on that occasion ___ #### Custom properties Following custom properties were added: | Custom property | Description | | :- | :- | | `--widget-col-amount` | Column amount of the backend-grid<br>_(Defaults to 12)_ | | `--widget-cols` | Amount of space that this takes per row<br>_(Can be used to create more specific widget classes)_ | | `--widget-gap-rows` | Row gap for widget-group container | | `--widget-gap-cols` | Column gap for widget-group container | Commits ------- df706f1 Rewrite #2053 for Contao 5.3 (5.x) 13ff350 Mobile and tablet styles for grid widgets 67d15bd Revert editorConfig 8524095 Add a size range for grid template columns 84ca874 Update grid-layout b8fab3f Use `grid-column-end` for widget cols abd0710 Rebuild the assets 608b93e Use custom properties for backend widgets and introduce `w16` 87c308d Mobile first + CS ef4799a Update widget layout 1ec3509 Revert the unrelated changes 5c0d886 Consider more classes for backwards compatibility 937c34b Run the tools 8ab3b5a Use `align-items: center` instead of `.m12` 00c3545 Use `align-items: center` instead of `.m12` 0e6e8ff Consider `m12` for backwards compatibility 0ad58fb Remove unnecessary margins for `.tl_checkbox` c0f6333 Rebuild the assets Co-authored-by: leofeyer <1192057+leofeyer@users.noreply.github.com>
Fix the .nogrid backwards compatibility layer (see #7229)
Description ----------- Follow-up on #7087 ### Before <img width="847" alt="" src="https://github.com/contao/contao/assets/1192057/0acc60fa-e73b-4bc1-9a4f-57f49bc0e69c"> ### After <img width="782" alt="" src="https://github.com/contao/contao/assets/1192057/52deebc2-9863-45ca-af14-ad46c1ac7234"> Commits ------- c008fe2 Fix the `.nogrid` backwards compatibility layer b1eb3bc Use the :is() selector c23109b Convert `*:not` to `:not`
# Conflicts: # CHANGELOG.md # calendar-bundle/contao/languages/sv/tl_module.xlf # core-bundle/contao/languages/sv/default.xlf # core-bundle/contao/languages/sv/explain.xlf # core-bundle/contao/languages/sv/tl_article.xlf # core-bundle/contao/languages/sv/tl_content.xlf # core-bundle/contao/languages/sv/tl_maintenance.xlf # core-bundle/contao/languages/sv/tl_member.xlf # core-bundle/contao/languages/sv/tl_module.xlf # core-bundle/contao/languages/sv/tl_page.xlf # core-bundle/contao/languages/sv/tl_theme.xlf # core-bundle/contao/languages/sv/tl_user.xlf # news-bundle/contao/languages/sv/tl_module.xlf
Use the attr() method in templates (see #7218)
Description ----------- See https://github.com/contao/contao/pull/7209/files#r1598224759 <img width="775" alt="" src="https://github.com/contao/contao/assets/1192057/00e4aad4-2ea5-423f-8d80-c917b2b67641"> The content element templates belong to deprecated legacy elements, so I‘m not sure if we want to update these, too? Commits ------- b8eaf2d Use the `attr()` method in templates 01e85a5 Allow overwriting the wrapper attributes in child templates 3f428e9 Reduce duplicate code 9dcc427 Unify HtmlAttributes usage in legacy templates (see #13) 3f4899c Clean up 3e27bb5 Move the $this->extend() call to the top a62e072 Adjust the ce_teaser.html5 template bf5e8ee Adjust the info_default.html5 template Co-authored-by: fritzmg <fmg@inspiredminds.at>
Use CSS grid to align checkboxes and their labels and drag handles (see
#7231) Description ----------- ### Before <img width="372" alt="" src="https://github.com/contao/contao/assets/1192057/7d446ae3-fd75-4a6b-adea-7cf849c5e530"> ### After <img width="368" alt="" src="https://github.com/contao/contao/assets/1192057/fc2d02df-6552-4444-8a54-1cc008197315"> Commits ------- d5da62e Use CSS grid to align checkboxes and their labels and drag handles 8f839db Rebuild the assets 75ef26c Adjust the radio table as well
Use HtmlAttributes for fe_page (see #7238)
Description ----------- Since we don't have a replacement for our `fe_page.html5` in the pipeline yet - and inspired by #7218 I think it would be great if we could introduce the `HtmlAttributes` to the default `fe_page` as well. Adding additional attributes to `<html>` or `<body>` without overwriting the `fe_page` template completely is currently pretty akward. These are the hacks that I use currently: ```php $this->extend('fe_page'); // By adding a `"` in the beginning and omitting it at the end we can "inject" // additional attributes on the <html> node using the $this->language variable $this->language .= '" data-turbo="false'; // Same concept for the <body> via the $this->class variable $this->class .= '" data-controller="foobar'; ``` With this PR it would be much nicer: ```php $this->extend('fe_page'); $this->rootAttributes = $this->attr() ->set('data-turbo', false) ->mergeWith($this->rootAttributes) ; $this->bodyAttributes = $this->attr() ->set('data-controller', 'foobar') ->mergeWith($this->bodyAttributes) ; ``` Commits ------- feaa9d8 use HtmlAttributes for fe_page