Skip to content

Commit 35af521

Browse files
ref(traces): "Add Instrumentation" is a external link (#87415)
<img alt="clipboard.png" width="235" src="https://i.imgur.com/zqSjrU8.png" /> Before it was <img alt="clipboard.png" width="224" src="https://i.imgur.com/hvEG98m.png" />
1 parent 0bbe952 commit 35af521

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

static/app/views/performance/newTraceDetails/traceActionsMenu.tsx

+12-11
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import {openModal} from 'sentry/actionCreators/modal';
22
import {Button} from 'sentry/components/core/button';
33
import {DropdownMenu} from 'sentry/components/dropdownMenu';
4-
import {IconEllipsis} from 'sentry/icons';
4+
import {IconEllipsis, IconOpen} from 'sentry/icons';
55
import {t} from 'sentry/locale';
66
import type {EventTransaction} from 'sentry/types/event';
77
import {trackAnalytics} from 'sentry/utils/analytics';
@@ -103,16 +103,6 @@ function TraceActionsMenu({
103103
navigate(target);
104104
},
105105
},
106-
{
107-
key: 'custom_instrumentation_button',
108-
label: t('Add Instrumentation'),
109-
onAction: () => {
110-
const docsLink = getCustomInstrumentationLink(traceProject);
111-
if (docsLink) {
112-
window.location.href = docsLink;
113-
}
114-
},
115-
},
116106
{
117107
key: 'shortcuts_button',
118108
label: t('See Shortcuts'),
@@ -121,6 +111,17 @@ function TraceActionsMenu({
121111
openModal(props => <TraceShortcutsModal {...props} />);
122112
},
123113
},
114+
{
115+
key: 'external-actions',
116+
children: [
117+
{
118+
key: 'custom_instrumentation_button',
119+
label: t('Add Instrumentation'),
120+
externalHref: getCustomInstrumentationLink(traceProject),
121+
leadingItems: <IconOpen />,
122+
},
123+
],
124+
},
124125
]}
125126
trigger={triggerProps => (
126127
<Button

0 commit comments

Comments
 (0)