ui: Add chip to distinguish metric generated tracks
Screenshot: https://screenshot.googleplex.com/JmXDJoDKXMLJDu4
Bug: 176173660
Change-Id: I6da38f4e9dafcb9dd7ab59f857cb1cccaff4816b
diff --git a/ui/src/frontend/track_panel.ts b/ui/src/frontend/track_panel.ts
index a2a5b81..c89b061 100644
--- a/ui/src/frontend/track_panel.ts
+++ b/ui/src/frontend/track_panel.ts
@@ -82,11 +82,15 @@
ondragleave: this.ondragleave.bind(this),
ondrop: this.ondrop.bind(this),
},
- m('h1',
- {
- title: attrs.trackState.name,
- },
- attrs.trackState.name),
+ m(
+ 'h1',
+ {
+ title: attrs.trackState.name,
+ },
+ attrs.trackState.name,
+ ('namespace' in attrs.trackState.config) &&
+ m('span.chip', 'metric'),
+ ),
m('.track-buttons',
attrs.track.getTrackShellButtons(),
m(TrackButton, {