Skip to content

Commit 4e8c15d

Browse files
authored
fix: Use ReportDialogOptions (#1588)
1 parent aada598 commit 4e8c15d

File tree

1 file changed

+2
-25
lines changed

1 file changed

+2
-25
lines changed

packages/browser/src/sdk.ts

Lines changed: 2 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import { getCurrentHub, initAndBind, Integrations as CoreIntegrations } from '@sentry/core';
2-
import { DsnLike } from '@sentry/types';
32
import { BrowserOptions } from './backend';
4-
import { BrowserClient } from './client';
3+
import { BrowserClient, ReportDialogOptions } from './client';
54
import { Breadcrumbs, GlobalHandlers, LinkedErrors, ReportingObserver, TryCatch, UserAgent } from './integrations';
65

76
export const defaultIntegrations = [
@@ -72,29 +71,7 @@ export function init(options: BrowserOptions): void {
7271
*
7372
* @param options Everything is optional, we try to fetch all info need from the global scope.
7473
*/
75-
export function showReportDialog(
76-
options: {
77-
[key: string]: any;
78-
eventId?: string;
79-
dsn?: DsnLike;
80-
user?: {
81-
email?: string;
82-
name?: string;
83-
};
84-
lang?: string;
85-
title?: string;
86-
subtitle?: string;
87-
subtitle2?: string;
88-
labelName?: string;
89-
labelEmail?: string;
90-
labelComments?: string;
91-
labelClose?: string;
92-
labelSubmit?: string;
93-
errorGeneric?: string;
94-
errorFormEntry?: string;
95-
successMessage?: string;
96-
} = {},
97-
): void {
74+
export function showReportDialog(options: ReportDialogOptions = {}): void {
9875
if (!options.eventId) {
9976
options.eventId = getCurrentHub().lastEventId();
10077
}

0 commit comments

Comments
 (0)