Skip to content

Commit 4985f7b

Browse files
authored
Merge branch 'develop' into feature/5566_maintenance_contract-by-martin
2 parents 263f31f + dcdd479 commit 4985f7b

11 files changed

Lines changed: 175 additions & 44 deletions

File tree

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,5 +30,11 @@ yarn-error.log
3030
phpstan.neon
3131
###< phpstan/phpstan ###
3232
.phpunit.cache
33+
34+
###> symfony/asset-mapper ###
35+
/public/assets/
36+
/assets/vendor/
37+
###< symfony/asset-mapper ###
38+
3339
.twig-cs-fixer.cache
3440
.playwright-mcp

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1111
- Add security contract entity with crud controller
1212
- Add Abstract full crud controller and extend on it in some cases
1313
- Add economics service and sync action/command for service agreement synchronization
14+
- [#81](https://github.com/itk-dev/devops_itksites/pull/81) 5564: Asset Mapper migration
15+
- Add Symfony Asset Mapper bundle and importmap
1416

1517
## [1.11.0] - 2026-05-19
1618

assets/app.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/*
2+
* Welcome to your app's main JavaScript file!
3+
*
4+
* This file will be included onto the page via the importmap() Twig function,
5+
* which should already be in your base.html.twig.
6+
*/
7+
import "./styles/app.css";
8+
9+
console.log("This log comes from assets/app.js - welcome to AssetMapper! 🎉");

assets/styles/app.css

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
:root {
2+
--body-max-width: 100%;
3+
--sidebar-bg: #fff;
4+
/* make the base font size smaller */
5+
--button-primary-bg: rgb(0, 123, 166);
6+
--pagination-active-bg: rgb(0, 123, 166);
7+
--link-color: rgb(0, 123, 166);
8+
--sidebar-menu-active-item-color: rgb(0, 123, 166);
9+
--badge-boolean-true-bg: rgb(0, 123, 166);
10+
--badge-boolean-false-bg: rgb(228, 73, 48);
11+
--badge-boolean-false-color: var(--white);
12+
--sidebar-menu-color: rgb(66, 66, 66);
13+
--text-color-dark: rgb(66, 66, 66);
14+
--bs-danger-rgb: 228, 73, 48;
15+
}
16+
17+
/* Grouped dropdown group styling for index pages */
18+
.dropdown-menu {
19+
.btn-danger i,
20+
.text-danger i {
21+
color: var(--button-invisible-danger-color);
22+
}
23+
24+
a.btn-danger:hover,
25+
a.text-danger:hover {
26+
background: var(--button-invisible-danger-hover-hover-bg);
27+
}
28+
}

composer.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
"phpstan/phpdoc-parser": "^2.0",
2222
"symfony/amqp-messenger": "^8.0",
2323
"symfony/asset": "^8.0",
24+
"symfony/asset-mapper": "~8.0.0",
2425
"symfony/browser-kit": "^8.0",
2526
"symfony/console": "^8.0",
2627
"symfony/doctrine-messenger": "^8.0",
@@ -111,7 +112,8 @@
111112
],
112113
"auto-scripts": {
113114
"cache:clear": "symfony-cmd",
114-
"assets:install %PUBLIC_DIR%": "symfony-cmd"
115+
"assets:install %PUBLIC_DIR%": "symfony-cmd",
116+
"importmap:install": "symfony-cmd"
115117
},
116118
"coding-standards-apply": [
117119
"vendor/bin/php-cs-fixer fix"

composer.lock

Lines changed: 82 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

config/packages/asset_mapper.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
framework:
2+
asset_mapper:
3+
# The paths to make available to the asset mapper.
4+
paths:
5+
- assets/
6+
missing_import_mode: strict
7+
8+
when@prod:
9+
framework:
10+
asset_mapper:
11+
missing_import_mode: warn

importmap.php

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?php
2+
3+
/**
4+
* Returns the importmap for this application.
5+
*
6+
* - "path" is a path inside the asset mapper system. Use the
7+
* "debug:asset-map" command to see the full list of paths.
8+
*
9+
* - "entrypoint" (JavaScript only) set to true for any module that will
10+
* be used as an "entrypoint" (and passed to the importmap() Twig function).
11+
*
12+
* The "importmap:require" command can be used to add new entries to this file.
13+
*/
14+
return [
15+
'app' => [
16+
'path' => './assets/app.js',
17+
'entrypoint' => true,
18+
],
19+
];

psalm.xml

Lines changed: 0 additions & 27 deletions
This file was deleted.

public/css/admin.css

Lines changed: 0 additions & 15 deletions
This file was deleted.

0 commit comments

Comments
 (0)