moduleTitles.tsx 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
  1. import {MODULE_TITLE as RESOURCES_MODULE_TITLE} from 'sentry/views/insights/browser/resources/settings';
  2. import {MODULE_TITLE as VITALS_MODULE_TITLE} from 'sentry/views/insights/browser/webVitals/settings';
  3. import {MODULE_TITLE as CACHE_MODULE_TITLE} from 'sentry/views/insights/cache/settings';
  4. import {MODULE_TITLE as DB_MODULE_TITLE} from 'sentry/views/insights/database/settings';
  5. import {
  6. FRONTEND_MODULE_TITLE as HTTP_FRONTEND_MODULE_TITLE,
  7. MODULE_TITLE as HTTP_MODULE_TITLE,
  8. } from 'sentry/views/insights/http/settings';
  9. import {MODULE_TITLE as AI_MODULE_TITLE} from 'sentry/views/insights/llmMonitoring/settings';
  10. import {MODULE_TITLE as APP_STARTS_MODULE_TITLE} from 'sentry/views/insights/mobile/appStarts/settings';
  11. import {MODULE_TITLE as SCREEN_LOADS_MODULE_TITLE} from 'sentry/views/insights/mobile/screenload/settings';
  12. import {MODULE_TITLE as SCREEN_RENDERING_MODULE_TITLE} from 'sentry/views/insights/mobile/screenRendering/settings';
  13. import {MODULE_TITLE as MOBILE_VITALS_MODULE_TITLE} from 'sentry/views/insights/mobile/screens/settings';
  14. import {MODULE_TITLE as MOBILE_UI_MODULE_TITLE} from 'sentry/views/insights/mobile/ui/settings';
  15. import type {DomainView} from 'sentry/views/insights/pages/useFilters';
  16. import {MODULE_TITLE as QUEUE_MODULE_TITLE} from 'sentry/views/insights/queues/settings';
  17. import {ModuleName} from 'sentry/views/insights/types';
  18. export const MODULE_TITLES: Record<ModuleName, string> = {
  19. [ModuleName.DB]: DB_MODULE_TITLE,
  20. [ModuleName.HTTP]: HTTP_MODULE_TITLE,
  21. [ModuleName.CACHE]: CACHE_MODULE_TITLE,
  22. [ModuleName.QUEUE]: QUEUE_MODULE_TITLE,
  23. [ModuleName.SCREEN_LOAD]: SCREEN_LOADS_MODULE_TITLE,
  24. [ModuleName.APP_START]: APP_STARTS_MODULE_TITLE,
  25. [ModuleName.VITAL]: VITALS_MODULE_TITLE,
  26. [ModuleName.RESOURCE]: RESOURCES_MODULE_TITLE,
  27. [ModuleName.AI]: AI_MODULE_TITLE,
  28. [ModuleName.MOBILE_UI]: MOBILE_UI_MODULE_TITLE,
  29. [ModuleName.MOBILE_SCREENS]: MOBILE_VITALS_MODULE_TITLE,
  30. [ModuleName.SCREEN_RENDERING]: SCREEN_RENDERING_MODULE_TITLE,
  31. [ModuleName.OTHER]: '',
  32. };
  33. /**
  34. * These are overrides for the module titles for each domain view,
  35. * If a module is not listed here, it will use the default module title from MODULE_TITLES
  36. */
  37. export const DOMAIN_VIEW_MODULE_TITLES: Record<
  38. DomainView,
  39. Partial<Record<ModuleName, string>>
  40. > = {
  41. ai: {},
  42. backend: {},
  43. mobile: {},
  44. frontend: {
  45. [ModuleName.HTTP]: HTTP_FRONTEND_MODULE_TITLE,
  46. },
  47. };