import {Component} from 'react'; import type {RouteComponentProps} from 'react-router'; import Access from 'sentry/components/acl/access'; import Link from 'sentry/components/links/link'; import LoadingIndicator from 'sentry/components/loadingIndicator'; import Panel from 'sentry/components/panels/panel'; import PanelAlert from 'sentry/components/panels/panelAlert'; import PanelBody from 'sentry/components/panels/panelBody'; import PanelHeader from 'sentry/components/panels/panelHeader'; import PanelItem from 'sentry/components/panels/panelItem'; import {t, tct} from 'sentry/locale'; import type {Organization, Plugin, Project} from 'sentry/types'; import RouteError from 'sentry/views/routeError'; import ProjectPluginRow from './projectPluginRow'; type Props = { error: React.ComponentProps['error']; loading: boolean; onChange: React.ComponentProps['onChange']; organization: Organization; plugins: Plugin[]; project: Project; } & RouteComponentProps<{}, {}>; class ProjectPlugins extends Component { render() { const {plugins, loading, error, onChange, routes, organization, project} = this.props; const hasError = error; const isLoading = !hasError && loading; if (hasError) { return ; } if (isLoading) { return ; } const params = {orgId: organization.slug, projectId: project.slug}; return ( {({hasAccess}) => (
{t('Legacy Integration')}
{hasAccess ? tct( "Legacy Integrations must be configured per-project. It's recommended to prefer organization integrations over the legacy project integrations when available. Visit the [link:organization integrations] settings to manage them.", { link: , } ) : t( "Legacy Integrations must be configured per-project. It's recommended to prefer organization integrations over the legacy project integrations when available." )} {plugins .filter(p => { return !p.isHidden; }) .map(plugin => ( ))} )} ); } } export default ProjectPlugins;