protected static function mapTranslatedTag(\DOMElement
$child, array
$values): array
{ if (!\
array_key_exists(self::
kebabCaseToCamelCase($child->tagName
),
$values)) { $values[self::
kebabCaseToCamelCase($child->tagName
)] =
[];
} // psalm would fail if it can't infer type from nested array
/** @var array<string, string> $tagValues */
$tagValues =
$values[self::
kebabCaseToCamelCase($child->tagName
)];
$tagValues[self::
getLocaleCodeFromElement($child)] =
trim($child->nodeValue ?? ''
);
$values[self::
kebabCaseToCamelCase($child->tagName
)] =
$tagValues;
return $values;
} /**
* @param callable(\DOMElement): (XmlElement|string) $transformer
*
* @return array<mixed>
*/
protected static function parseChildNodes(\DOMElement
$child, callable
$transformer): array
{