Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions supernav.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,19 +26,23 @@

var HOST = location.hostname;
var PATH = location.pathname;
// Quickstart, demos, and telemetry live under the apex host, so the active
// item cannot be resolved from the hostname alone the way every other entry can.
// Quickstart, demos, telemetry, registry, and (today) WCM live under the
// apex host, so the active item cannot be resolved from the hostname alone
// the way every other entry can.

var CURRENT_ID = (HOST === 'agentrust-io.com' && PATH.indexOf('/quickstart') === 0) ? 'quickstart'
: (HOST === 'agentrust-io.com' && PATH.indexOf('/demos') === 0) ? 'demos'
: (HOST === 'agentrust-io.com' && PATH.indexOf('/telemetry') === 0) ? 'telemetry'
: (HOST === 'agentrust-io.com' && PATH.indexOf('/registry') === 0) ? 'registry'
: (HOST === 'agentrust-io.com' && PATH.indexOf('/wcm') === 0) ? 'wcm'
: (HOST === 'agentrust-io.com' && PATH.indexOf('/extensions/ca2a') === 0) ? 'ca2a'
: HOST === 'agentrust-io.com' ? 'home'
: HOST.indexOf('trace.') === 0 ? 'trace'
: HOST.indexOf('manifest.') === 0 ? 'manifest'
: HOST.indexOf('cmcp.') === 0 ? 'cmcp'
: HOST.indexOf('ca2a.') === 0 ? 'ca2a'
: HOST.indexOf('governance.') === 0 ? 'governance'
: HOST.indexOf('wcm.') === 0 ? 'wcm'
: HOST.indexOf('tests.') === 0 ? 'trace'
: 'home';

Expand Down
Loading