diff --git a/eslint.config.js b/eslint.config.js index fd4802f10d4..c31f2f77930 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -410,4 +410,22 @@ module.exports = [ ], }, }, + { + name: 'grafana/no-extensions-imports', + files: ['**/*.{ts,tsx,js}'], + ignores: ['public/app/extensions/**/*'], + rules: { + 'no-restricted-imports': [ + 'error', + { + patterns: [ + { + group: ['app/extensions', 'app/extensions/*'], + message: 'Importing from app/extensions is not allowed', + }, + ], + }, + ], + }, + }, ]; diff --git a/public/app/features/alerting/unified/enterprise-components/AI/addAIFeedbackButton.tsx b/public/app/features/alerting/unified/enterprise-components/AI/addAIFeedbackButton.tsx index fae71645554..d0d68bcd0e8 100644 --- a/public/app/features/alerting/unified/enterprise-components/AI/addAIFeedbackButton.tsx +++ b/public/app/features/alerting/unified/enterprise-components/AI/addAIFeedbackButton.tsx @@ -2,10 +2,11 @@ import { ComponentType, createElement } from 'react'; import { t } from '@grafana/i18n'; import { withErrorBoundary } from '@grafana/ui'; -import { AIFeedbackOrigin } from 'app/extensions/alerting/AI/feedback/AIFeedbackComponent'; import { logError } from '../../Analytics'; +export type AIFeedbackOrigin = 'alert-rule' | 'template' | 'triage'; + export interface GenAIFeedbackButtonProps { origin: AIFeedbackOrigin; shouldShowFeedbackButton?: boolean;