-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
[5.4] Update repeatable-table.php #46287
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 5.4-dev
Are you sure you want to change the base?
[5.4] Update repeatable-table.php #46287
Conversation
The <th> width was hardcoded to 45%, regardless of the number of columns. This change makes it dynamic, distributing the width according to the number of fields, while reserving 8% for the action column.
Co-authored-by: Richard Fath <[email protected]>
Width calculation done before the foreach
Fix table header width calculation in repeatable table
|
@chmst Could you do an issue tracker test? |
|
I have tested this item ✅ successfully on 3d4662a This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/46287. |
|
@nordmograph I have tested this PR and see:
However, there is no difference in the presentation for me on quick view in any of the three browsers (Firefox, Chrome, and Safari). All fields are present, and I can scroll horizontally before or after the PR. Could you please explain/show what bug this PR fixes?
|
|
@muhme Maybe you can see the effect only on small screens, e.g. mobile phone? |
|
It is the calculation - before: every column has with: 45% which is not correct if there are more than 2 cloumns. Now, all columns have a correctly calculated width. |



Pull Request for Issue # .
Summary of Changes
The width was hardcoded to 45%, regardless of the number of columns. This change makes it dynamic, distributing the width according to the number of fields, while reserving 8% for the action column.
Testing Instructions
Create a subform 'test' field with a repeatable.table layout and at least 3 (text for eg.) fields in it.
(layout="joomla.form.field.subform.repeatable-table") + subform_test.xml
Actual result BEFORE applying this Pull Request
2 first fields have 45% as width and the 3rd and following ones are compressed
Expected result AFTER applying this Pull Request
the width of ech field is a divisiion of the total width per the amount of fields
Link to documentations
Please select:
Documentation link for docs.joomla.org:
No documentation changes for docs.joomla.org needed
Pull Request link for manual.joomla.org:
No documentation changes for manual.joomla.org needed