- Issue created by @pdureau
- @pdureau opened merge request.
- 🇫🇷France pdureau Paris
Hi Grimreaper,
this issue is related to 🐛 Library: other group placed first Active which has introduced
label
&category
properties.I changed the logic to fix the TypeError but it may not be enough.
Are we comfortable with the addition of
label
&category
properties to all definitions? We are adding them to a kind of public interface.For
category
, we may have no choice.But for
label
, why not use the$label_key = 'name'
property instead?public function getSortedDefinitions(?array $definitions = NULL, $label_key = 'label'); public function getSortedDefinitions(?array $definitions = NULL, $label_key = 'label');
- 🇫🇷France Grimreaper France 🇫🇷
why not use the $label_key = 'name' property instead?
It was to minimize changes of 🐛 Library: other group placed first Active because default value for $label_key of CategorizingPluginManagerTrait is "label". So to avoid to edit all calls to getSortedDefinitions or getGroupedDefinitions, especially in case of usage in other contrib ui_patterns modules, or custom code.
So to avoid a breaking change.
- 🇫🇷France Grimreaper France 🇫🇷
I changed the moment default name is set.
Ok on my side, please retest on your side.