parentNameFromKey

fun parentNameFromKey(globalKey: GlobalKey?, idToTypeMap: Map<Int, Any>): String?

Extracts the parent component's simple name directly from a GlobalKey.

For DefaultGlobalKey: O(1) pointer dereference + map get (zero allocations).

For StringGlobalKey: two String.lastIndexOf calls + one substring + one map get — no full key split, no list allocation, no iteration over all segments.