integrationContext.tsx 694 B

12345678910111213141516171819202122232425
  1. import {createContext} from 'react';
  2. import type {IntegrationProvider, IntegrationType} from 'sentry/types/integrations';
  3. export type IntegrationContextProps = {
  4. analyticsParams: {
  5. already_installed: boolean;
  6. view:
  7. | 'integrations_directory_integration_detail'
  8. | 'integrations_directory'
  9. | 'messaging_integration_onboarding'
  10. | 'onboarding'
  11. | 'project_creation';
  12. referrer?: string;
  13. };
  14. installStatus: string;
  15. provider: IntegrationProvider;
  16. type: IntegrationType;
  17. modalParams?: {[key: string]: string};
  18. onAddIntegration?: () => void;
  19. };
  20. export const IntegrationContext = createContext<IntegrationContextProps | undefined>(
  21. undefined
  22. );