Skip to content

Commit 3314d23

Browse files
authored
Merge branch 'main' into app-analytics-log-events-fix
2 parents 336ab62 + 1bfe411 commit 3314d23

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

public/components/trace_analytics/home.tsx

+7-1
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,13 @@ export const Home = (props: HomeProps) => {
120120

121121
const [dataSourceMDSId, setDataSourceMDSId] = useState([{ id: '', label: '' }]);
122122
const [currentSelectedService, setCurrentSelectedService] = useState('');
123-
const { defaultRoute = '/services' } = props;
123+
let defaultRoute = props.defaultRoute ?? '/services';
124+
const currentHash = window.location.hash.split('#')[1] || '';
125+
126+
if (currentHash === '/traces' || currentHash === '/services') {
127+
defaultRoute = currentHash;
128+
}
129+
124130
const { chrome } = props;
125131
const isNavGroupEnabled = chrome.navGroup.getNavGroupEnabled();
126132

public/components/trace_analytics/trace_side_nav.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ export function TraceSideBar(props: { children: React.ReactNode }) {
3030
{
3131
name: 'Trace analytics',
3232
id: 1,
33-
href: '#/',
33+
href: '#/services',
3434
items: [
3535
{
3636
name: 'Services',

0 commit comments

Comments
 (0)