// engine/detectors/advanced-framework-detector/enterprise-ds-detector.ts
// Detects enterprise design systems: Carbon, Polaris, Fluent UI, Arco, Radix, etc.
import { join } from 'node:path';
import { fileExists } from './helpers.js';
export async function detectEnterpriseDesignSystem(projectPath, deps) {
    if (deps.has('@carbon/react') || deps.has('carbon-components')) {
        return 'carbon';
    }
    if (deps.has('@shopify/polaris')) {
        const isShopifyApp = deps.has('@shopify/app') || (await fileExists(join(projectPath, 'shopify.app.toml')));
        if (isShopifyApp) {
            return 'polaris';
        }
    }
    if (deps.has('@fluentui/react') || deps.has('@fluentui/react-components')) {
        return 'fluent-ui';
    }
    if (deps.has('@arco-design/web-react') || deps.has('@arco-design/web-vue')) {
        return 'arco-design';
    }
    for (const dep of deps) {
        if (dep.startsWith('@radix-ui/react-')) {
            return 'radix-ui';
        }
    }
    if (deps.has('@ark-ui/react') || deps.has('@ark-ui/vue') || deps.has('@ark-ui/solid')) {
        return 'ark-ui';
    }
    if (deps.has('naive-ui')) {
        return 'naive-ui';
    }
    if (deps.has('vuetify')) {
        return 'vuetify';
    }
    if (deps.has('quasar')) {
        return 'quasar';
    }
    return null;
}
//# sourceMappingURL=enterprise-ds-detector.js.map