- First commit to issue fork.
- Merge request !10519Add a notice to explain why File widget settings might be unavailable β (Open) created by Unnamed author
I have made a merge request addressing this issue this as part of Drupalcon Singapore 2024 Contribution Day.
@larowan came by and suggested to add a message explaining the empty field rather than altering the behaviour of the edit settings gear icon, as this would requireEntityDisplayFormBase::buildFieldRow()
to traverse all the nested fields inside of widget settings form to check if they are visible.
Removing the form element from the settings form was also not advisable as this would change the form schema.- First commit to issue fork.
- π¦πΊAustralia mstrelan
I read the issue summary and merge request and the proposed resolution doesn't match what's in the MR. I think either approach could be viable but we should pick one and update the issue or MR to match. I also wasn't clear what this issue was for from the issue title, I think we should mention field widgets in the title.
- πΊπΈUnited States smustgrave
Possible to get a simple test assertion added for this?
- π³πΏNew Zealand atowl
@smustgraves, little harder to do this as an automated test as we need to mock the extension checker so we can return false in check.
However, we could refactor it locally and then mock the call to the local function?Also, i'm wondering if the proposed solution doesn't quite match the screen shots that were provided now? The proposed solution is to just grey out the options if the extension isn't loaded, but the screenshots simply remove the options. Is that more what we are after? with maybe a message about why?
Also, i'm wondering if the proposed solution doesn't quite match the screen shots that were provided now? The proposed solution is to just grey out the options if the extension isn't loaded, but the screenshots simply remove the options
I can only see one screenshot in this thread, so I am assuming that you are referring to the screenshot in the IS.
That screenshot is not demonstrating the proposed solution. That screenshot under the "Problem" heading, so it is demonstrating the undesired behaviour.- π³πΏNew Zealand atowl
Think the current screen shots are for an older version of drupal, and prehaps outdated.
I've uploaded some new ones, showing what its currently like in D11, and have left the original screen shot showing what i think the OP wanted it to look like if the extension is loaded.The summary of the image should still be shown if the extension isn't loaded.
- π¦πΊAustralia larowlan π¦πΊπ.au GMT+10
I agree testing is not feasible here - short of mocking the extension_loaded function in the same namespace as the widget which would be a bit black magic.
Thanks for updating the screenshots @atowl
Updating issue credits - πΊπΈUnited States smustgrave
If no test coverage needed then this is probably good then.
-
longwave β
committed 66a2caac on 10.5.x
Issue #3037204 by starlight-sparkle, atowl, dww, kim.pepper: If upload...
-
longwave β
committed 66a2caac on 10.5.x
-
longwave β
committed 88aafb36 on 11.x
Issue #3037204 by starlight-sparkle, atowl, dww, kim.pepper: If upload...
-
longwave β
committed 88aafb36 on 11.x
- π¬π§United Kingdom longwave UK
Backported to 10.5.x as a minor UI improvement, but not eligible for 11.1.x or 10.4.x due to the UI change.
Committed and pushed 88aafb36335 to 11.x and 66a2caacc47 to 10.5.x. Thanks!