Skip to content

Commit 3504306

Browse files
authored
fix wcm supernav highlight (#47)
Signed-off-by: rajnisht7 <rajnishtiwari9787@gmail.com>
1 parent d5aa566 commit 3504306

1 file changed

Lines changed: 6 additions & 2 deletions

File tree

supernav.js

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,23 @@
2626

2727
var HOST = location.hostname;
2828
var PATH = location.pathname;
29-
// Quickstart, demos, and telemetry live under the apex host, so the active
30-
// item cannot be resolved from the hostname alone the way every other entry can.
29+
// Quickstart, demos, telemetry, registry, and (today) WCM live under the
30+
// apex host, so the active item cannot be resolved from the hostname alone
31+
// the way every other entry can.
32+
3133
var CURRENT_ID = (HOST === 'agentrust-io.com' && PATH.indexOf('/quickstart') === 0) ? 'quickstart'
3234
: (HOST === 'agentrust-io.com' && PATH.indexOf('/demos') === 0) ? 'demos'
3335
: (HOST === 'agentrust-io.com' && PATH.indexOf('/telemetry') === 0) ? 'telemetry'
3436
: (HOST === 'agentrust-io.com' && PATH.indexOf('/registry') === 0) ? 'registry'
37+
: (HOST === 'agentrust-io.com' && PATH.indexOf('/wcm') === 0) ? 'wcm'
3538
: (HOST === 'agentrust-io.com' && PATH.indexOf('/extensions/ca2a') === 0) ? 'ca2a'
3639
: HOST === 'agentrust-io.com' ? 'home'
3740
: HOST.indexOf('trace.') === 0 ? 'trace'
3841
: HOST.indexOf('manifest.') === 0 ? 'manifest'
3942
: HOST.indexOf('cmcp.') === 0 ? 'cmcp'
4043
: HOST.indexOf('ca2a.') === 0 ? 'ca2a'
4144
: HOST.indexOf('governance.') === 0 ? 'governance'
45+
: HOST.indexOf('wcm.') === 0 ? 'wcm'
4246
: HOST.indexOf('tests.') === 0 ? 'trace'
4347
: 'home';
4448

0 commit comments

Comments
 (0)