Skip to content

Commit 681a45d

Browse files
committed
feature #1337 Tweak source code modal for large screens (voronkovich)
This PR was merged into the main branch. Discussion ---------- Tweak source code modal for large screens I suggest to make source code modal wider on large screens to avoid word wrapping. ![Screenshot 2022-05-05 at 23-40-14 Symfony Demo application](https://user-images.githubusercontent.com/2299535/167022448-66db8d63-8ebc-4024-b70e-6344e5ee07a3.png) Bootstrap 5 has [.modal-xl](https://getbootstrap.com/docs/5.1/components/modal/#optional-sizes) CSS class for this. But we use Bootstrap 3, so I just created a "polyfill" for that feature. Commits ------- f1bea9f Tweak source code modal for large screens
2 parents 8f84337 + f1bea9f commit 681a45d

File tree

5 files changed

+13
-5
lines changed

5 files changed

+13
-5
lines changed

assets/styles/app.scss

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,14 @@ i {
5656
------------------------------------------------------------------------- */
5757
.m-b-0 { margin-bottom: 0 }
5858

59+
@media (min-width: $screen-md-min) {
60+
.modal-xl { width: $modal-lg; }
61+
}
62+
63+
@media (min-width: $screen-lg-min) {
64+
.modal-xl { width: $screen-lg-min - 60px; }
65+
}
66+
5967
/* Page elements
6068
------------------------------------------------------------------------- */
6169
body {

public/build/app.ac992678.css renamed to public/build/app.f66338b0.css

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

public/build/entrypoints.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
],
1111
"css": [
1212
"/build/979.dc75718b.css",
13-
"/build/app.ac992678.css"
13+
"/build/app.f66338b0.css"
1414
]
1515
},
1616
"login": {
@@ -49,7 +49,7 @@
4949
"/build/979.4967399b.js": "sha384-IPkjWWHEhfdos/b3w08uBZ2KjTFno/Ocwt1o6ardQjWJEbigWocfHbAeZfj+t7AX",
5050
"/build/app.a5511055.js": "sha384-t5u9zzpbS+SwUVCOSeCZdoFdZ5n1rIZ5nWHPzaEYkZ6U2oaG2AOokBmGXzL7uORK",
5151
"/build/979.dc75718b.css": "sha384-3Xq9zpkhbAPpNpmbJIfOIsDjVugU/PSQ4vcam/DSyD65+CvSOnCrlxkY+RpzfNKN",
52-
"/build/app.ac992678.css": "sha384-ICPCCj5CXbWgl5Qqe/h85MC7oJI7tfgk7ZWIPsFm93L6gG/fHXfzBERdusSM7Fy4",
52+
"/build/app.f66338b0.css": "sha384-KA475JLog/ODk4eDLal8AC7va3Rpmyw4GCOfZJrhCxpm2B2itR0J3w1NAKF38hJ9",
5353
"/build/login.395771d5.js": "sha384-bKBy5bAsLAFHFo/zxqJkheRiwvRSVHXwogJPw7DWc6qfnP03VaNFMyEc/0cRBf0k",
5454
"/build/919.63ff4a5d.js": "sha384-0o9glCmkeYT/iE8RHdbPnoqMslSFjP/uN4ggsyjBVE5eq+V2RUFdEzYZBs5JNiyb",
5555
"/build/admin.587634ca.js": "sha384-dcJSJPDI6xDEF7Z7o/d9W4sRi45GMJWp4hfnojnRhwtnjrGpoOUmmaPpE9AKOgXj",

public/build/manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"build/app.css": "/build/app.ac992678.css",
2+
"build/app.css": "/build/app.f66338b0.css",
33
"build/app.js": "/build/app.a5511055.js",
44
"build/login.js": "/build/login.395771d5.js",
55
"build/admin.css": "/build/admin.691f9b8c.css",

templates/debug/source_code.html.twig

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
</button>
99

1010
<div class="modal fade" id="sourceCodeModal" tabindex="-1">
11-
<div class="modal-dialog modal-lg">
11+
<div class="modal-dialog modal-xl">
1212
<div class="modal-content">
1313
<div class="modal-header">
1414
<button type="button" class="close" data-dismiss="modal" aria-label="{{ 'action.close'|trans }}">

0 commit comments

Comments
 (0)