integrationContext.tsx 671 B

123456789101112131415161718192021222324
  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. };
  13. installStatus: string;
  14. provider: IntegrationProvider;
  15. type: IntegrationType;
  16. modalParams?: {[key: string]: string};
  17. onAddIntegration?: () => void;
  18. };
  19. export const IntegrationContext = createContext<IntegrationContextProps | undefined>(
  20. undefined
  21. );