[resultui] fix getPropKeyLabel when prop key contain '.'

Previously, if a property key is v.test.suite, only test will be
displayed.

R=gavinmak@google.com, nodir

Change-Id: If80da726fedad6045b7fba3119d31e9d1e63d416
Reviewed-on: https://chromium-review.googlesource.com/c/infra/luci/luci-go/+/2892297
Auto-Submit: Weiwei Lin <weiweilin@google.com>
Commit-Queue: Weiwei Lin <weiweilin@google.com>
Reviewed-by: Nodir Turakulov <nodir@chromium.org>
diff --git a/milo/frontend/resultui/src/components/test_variants_table/index.ts b/milo/frontend/resultui/src/components/test_variants_table/index.ts
index 9fa0da0..571cdc4 100644
--- a/milo/frontend/resultui/src/components/test_variants_table/index.ts
+++ b/milo/frontend/resultui/src/components/test_variants_table/index.ts
@@ -38,7 +38,8 @@
 
 function getPropKeyLabel(key: string) {
   // If the key has the format of '{type}.{value}', hide the '{type}.' prefix.
-  return key.split('.', 2)[1] ?? key;
+  // Don't use String.split here because value may contain '.'.
+  return key.match(/^([^.]*\.)?(.*)$/)![2];
 }
 
 /**