It seems like $value->language ? $this...->_language->get('all') can also be of type array; however, Redaxscript\Html\Element::text() does only seem to accept string|integer|null, maybe add an additional type check?

If a method or function can return multiple different values and unless you are
sure that you only can receive a single value in this context, we recommend
to add an additional type check: