-
-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
[4.0] Repeatable Modal fields and subforms #32663
Comments
That was the reason I kept saying that all fields need to be implemented as custom elements (or web components). Custom elements have lifecycle events, so if you create (as it happens with subform) a new field by copying the html then the field initialises automatically (the lifecycle event for this is Can it be done without custom elements? Yes but you need to set up event listeners and it would get messy. Not to mention that having multiple ways for the same task is extremely confusing for devs (when should I use this method over the other, etc) Unfortunately the last 1-2 years nothing happen to bring the remaining fields to parity with the existing ones and on top of that people added interactivity (or new fields) that are totally incompatible with subforms (the color slider, the text count characters, etc). I had a list #19427 which apparently was never implemented although the code was written... |
Here multiple issues:
Custom elements can help only with initialization. @brianteeman unfortunately it cannot be fixed, without a loot of rewriting.
This somehow related to what I tries to explain in #32473 discussion. |
Sorry I dont understand your work around. For my own component I am just forking the users webcomponent |
I will try differently: |
I realised what you meant as soon as I hit comment ;) |
@Fedik this is the worse part and unfortunately cannot be done in any B/C way. But B/C might be ignored here (the modal fields or whatever the name) is an internal thing. There was a PR that was solving aspects of this but not the callbacks |
No need for a user to see technical terms when something goes wrong if the message is good enough without PR for joomla#32263 To test. Follow replication instructions in joomla#32663
Just tried to do exactly what is mentioned by @brianteeman in my custom component, and I confirm that it still doesn't work, in Joomla 4.3.4. Same for
Would that make sense? |
This will be fixed in Joomla 5, in For now only for |
Most of the fields is fixed:
Some still need to be tested. |
This is not about the user or media fields as they are different and there already is a PR to fix those.
This is about the other modal fields such as the article tester
Steps to reproduce the issue
Edit
administrator\components\com_users\forms\user.xml
by inserting the following code at the beginning of the file after the openingform
ie on line4If you try to add a new user you will see a new tab as shown in the image

Click on the Select and add an article
Click on the green plus to repeat the field
Click on the Select and you cannot add an article as the modal is empty
Basically if the field is on the page when it loads then the modal works. If not then it is empty
The text was updated successfully, but these errors were encountered: