Pholio mock: do not allow to unset the image title
Summary:
Do not allow to unset the image title from Pholio mock images,
in order to avoid at least 3 related UX bugs shown in T16478.
Also remove the broken method 'shouldHide()',
because it always returns false, which is the default from
the parent call, PhabricatorModularTransactionType#shouldHide().
The 'shouldHide()' was also broken in PHP 8.5.
Also improve one error message to talk about "image titles"
(and not "image names"), so to be consistent with the "Title"
field in the UX.
Thanks to @aklapper for the original troubleshooting.
Closes T16478
Ref T16460
Test Plan:
Create a Pholio mock with at least one image and save.
Try to unset one image title (not the mock title, but the image title)
and enjoy the new validation message: "Mock images must have a name."
Reviewers: aklapper, O1 Blessed Committers
Reviewed By: aklapper, O1 Blessed Committers
Subscribers: tobiaswiese, Matthew, aklapper, Cigaryno
Maniphest Tasks: T16478, T16460
Differential Revision: https://we.phorge.it/D26717