diff --git a/src/plugin/sentry.js b/src/plugin/sentry.js index d5a2a7c4..7576c2a2 100644 --- a/src/plugin/sentry.js +++ b/src/plugin/sentry.js @@ -37,6 +37,7 @@ export async function initSentry(app) { release: version, replaysSessionSampleRate: 0.1, replaysOnErrorSampleRate: 1.0, + tracesSampleRate: 0.1, beforeSend(event, hint) { if ( event.request?.status && @@ -49,7 +50,13 @@ export async function initSentry(app) { integrations: [ Sentry.replayIntegration({ maskAllText: true, - blockAllMedia: true + blockAllMedia: false + }), + Sentry.browserTracingIntegration(), + Sentry.vueIntegration({ + tracingOptions: { + trackComponents: true + } }) ] }); diff --git a/src/stores/settings/advanced.js b/src/stores/settings/advanced.js index 15c9f88d..9f3fdf11 100644 --- a/src/stores/settings/advanced.js +++ b/src/stores/settings/advanced.js @@ -447,9 +447,12 @@ export const useAdvancedSettingsStore = defineStore('AdvancedSettings', () => { '• Can be disabled at anytime in Advanced Settings.', 'Anonymous Error Reporting', { - type: 'info', + type: 'warning', center: true, - dangerouslyUseHTMLString: true + dangerouslyUseHTMLString: true, + closeOnClickModal: false, + closeOnPressEscape: false, + distinguishCancelAndClose: true } ) .then(() => { @@ -462,16 +465,22 @@ export const useAdvancedSettingsStore = defineStore('AdvancedSettings', () => { { confirmButtonText: 'Restart Now', cancelButtonText: 'Later', - type: 'info', - center: true + type: 'warning', + center: true, + closeOnClickModal: false, + closeOnPressEscape: false } ).then(() => { VRCXUpdaterStore.restartVRCX(false); }); }) - .catch(() => { - state.sentryErrorReporting = false; - configRepository.setString('VRCX_SentryEnabled', 'false'); + .catch((action) => { + const act = + typeof action === 'string' ? action : action?.action; + if (act === 'cancel') { + state.sentryErrorReporting = false; + configRepository.setString('VRCX_SentryEnabled', 'false'); + } }); }