// Mock data for Parcle Console

// Vendor definitions — geometric category icons (not branded marks), each tile gets
// an abstract glyph on a tinted colored background. Names are generic category names
// to avoid recreating branded product UI.
const VENDORS = {
  chatroom:  { name: 'Slack',      cat: 'Collaboration', color: '#4A154B', glyph: 'chat',    kind: 'chat' },
  telegram:  { name: 'Telegram',   cat: 'Collaboration', color: '#229ED9', glyph: 'chat',    kind: 'chat' },
  meetchat:  { name: 'Microsoft Teams', cat: 'Collaboration', color: '#464EB8', glyph: 'chat', kind: 'chat' },
  discal:    { name: 'Discord',    cat: 'Collaboration', color: '#5865F2', glyph: 'chat',    kind: 'chat' },
  callsync:  { name: 'Zoom',       cat: 'Collaboration', color: '#2D8CFF', glyph: 'call',    kind: 'calls' },
  voxgrid:   { name: 'Gong',       cat: 'Collaboration', color: '#6A2CEA', glyph: 'call',    kind: 'calls' },
  gmail:     { name: 'Gmail',      cat: 'Collaboration', color: '#1A73E8', glyph: 'envelope',kind: 'email' },
  gcal:      { name: 'Google Calendar', cat: 'Collaboration', color: '#1967D2', glyph: 'calendar', kind: 'calendar' },
  outmail:   { name: 'Outlook',    cat: 'Collaboration', color: '#0078D4', glyph: 'envelope',kind: 'email' },

  pagevault: { name: 'Notion',     cat: 'Docs & Wikis',  color: '#111827', glyph: 'doc',     kind: 'wiki' },
  wikiloom:  { name: 'Confluence', cat: 'Docs & Wikis',  color: '#0052CC', glyph: 'doc',     kind: 'wiki' },
  gdocs:     { name: 'Google Docs',cat: 'Docs & Wikis',  color: '#1A73E8', glyph: 'doc',     kind: 'docs' },
  codabook:  { name: 'Coda',       cat: 'Docs & Wikis',  color: '#F46A54', glyph: 'doc',     kind: 'docs' },

  cloudbin:  { name: 'Google Drive', cat: 'Files',       color: '#0B8043', glyph: 'file',    kind: 'files' },
  boxdrop:   { name: 'Dropbox',    cat: 'Files',         color: '#0061FF', glyph: 'file',    kind: 'files' },
  cratesvc:  { name: 'Box',        cat: 'Files',         color: '#0061D5', glyph: 'file',    kind: 'files' },
  bucket3:   { name: 'AWS S3',     cat: 'Files',         color: '#E85D04', glyph: 'bucket',  kind: 'files' },
  onevault:  { name: 'OneDrive',   cat: 'Files',         color: '#0364B8', glyph: 'file',    kind: 'files' },

  repohub:   { name: 'GitHub',     cat: 'Code',          color: '#24292F', glyph: 'branch',  kind: 'code' },
  gitlane:   { name: 'GitLab',     cat: 'Code',          color: '#FC6D26', glyph: 'branch',  kind: 'code' },
  bitforge:  { name: 'Bitbucket',  cat: 'Code',          color: '#0052CC', glyph: 'branch',  kind: 'code' },

  databricks:{ name: 'Databricks', cat: 'Data Warehouse',color: '#FF3621', glyph: 'db',      kind: 'dwh' },
  snowlake:  { name: 'Snowflake',  cat: 'Data Warehouse',color: '#29B5E8', glyph: 'db',      kind: 'dwh' },
  bigpool:   { name: 'BigQuery',   cat: 'Data Warehouse',color: '#4285F4', glyph: 'db',      kind: 'dwh' },
  redshift2: { name: 'Redshift',   cat: 'Data Warehouse',color: '#205081', glyph: 'db',      kind: 'dwh' },
  postgrex:  { name: 'Postgres',   cat: 'Data Warehouse',color: '#336791', glyph: 'db',      kind: 'db' },
  myvolt:    { name: 'MySQL',      cat: 'Data Warehouse',color: '#00618A', glyph: 'db',      kind: 'db' },

  salescrm:  { name: 'Salesforce', cat: 'CRM',           color: '#00A1E0', glyph: 'crm',     kind: 'crm' },
  hubforge:  { name: 'HubSpot',    cat: 'CRM',           color: '#FF7A59', glyph: 'crm',     kind: 'crm' },
  atomcrm:   { name: 'Attio',      cat: 'CRM',           color: '#4338CA', glyph: 'crm',     kind: 'crm' },

  deskzen:   { name: 'Zendesk',    cat: 'Support',       color: '#03363D', glyph: 'support', kind: 'support' },
  talkbox:   { name: 'Intercom',   cat: 'Support',       color: '#1F8DED', glyph: 'support', kind: 'support' },
  linebase:  { name: 'Linear',     cat: 'Support',       color: '#5E6AD2', glyph: 'issue',   kind: 'issues' },
  jiratide:  { name: 'Jira',       cat: 'Support',       color: '#0052CC', glyph: 'issue',   kind: 'issues' },

  segway:    { name: 'Segment',    cat: 'Product Analytics', color: '#52BD94', glyph: 'chart', kind: 'analytics' },
  amplify:   { name: 'Amplitude',  cat: 'Product Analytics', color: '#1E61F0', glyph: 'chart', kind: 'analytics' },
  mixtape:   { name: 'Mixpanel',   cat: 'Product Analytics', color: '#7856FF', glyph: 'chart', kind: 'analytics' },

  webhookc:  { name: 'Webhook',    cat: 'Custom',        color: '#6B7280', glyph: 'hook',    kind: 'custom' },
  restcustom:{ name: 'REST API',   cat: 'Custom',        color: '#6B7280', glyph: 'api',     kind: 'custom' },
  sqlcustom: { name: 'SQL Source', cat: 'Custom',        color: '#6B7280', glyph: 'db',      kind: 'custom' },
  upload:    { name: 'File Upload',cat: 'Custom',        color: '#6B7280', glyph: 'upload',  kind: 'custom' },
};

const CATEGORY_ORDER = [
  'Collaboration', 'Docs & Wikis', 'Files', 'Code',
  'Data Warehouse', 'CRM', 'Support', 'Product Analytics', 'Custom'
];

const CATEGORY_LABEL = {
  'Collaboration': 'Collaboration',
  'Docs & Wikis': 'Docs & Wikis',
  'Files': 'Files',
  'Code': 'Code',
  'Data Warehouse': 'Data Warehouses',
  'CRM': 'CRM',
  'Support': 'Support',
  'Product Analytics': 'Product Analytics',
  'Custom': 'Custom',
};

const CAT_LABEL_SHORT = {
  chat: 'chat', call: 'calls', doc: 'wiki', bucket: 'storage',
  file: 'files', branch: 'code', db: 'database', crm: 'crm',
  support: 'support', issue: 'issues', chart: 'analytics',
  hook: 'webhook', api: 'api', upload: 'upload'
};

// Connected sources (populated state)
const CONNECTED_SOURCES = [
  { id: 'chatroom',  volume: '412k msgs',    size: '3.2 GB',   rels: '184k',  synced: '2m',   used: '48s ago', status: 'live' },
  { id: 'pagevault', volume: '8.9k pages',   size: '1.1 GB',   rels: '62k',   synced: '34s',  used: '3m ago',  status: 'live' },
  { id: 'cloudbin',  volume: '224k files',   size: '418 GB',   rels: '91k',   synced: 'now',  used: '8m ago',  status: 'syncing', progress: 42 },
  { id: 'repohub',   volume: '312 repos',    size: '64 GB',    rels: '28k',   synced: '1m',   used: '2m ago',  status: 'live' },
  { id: 'postgrex',  volume: '48 schemas',   size: '1.8 TB',   rels: '412k',  synced: '3m',   used: '1m ago',  status: 'live' },
  { id: 'salescrm',  volume: '84k records',  size: '6.4 GB',   rels: '238k',  synced: '5m',   used: '14d ago', status: 'live' },
  { id: 'snowlake',  volume: '12 databases', size: '8.7 TB',   rels: '1.2M',  synced: '12m',  used: 'Never',   status: 'live' },
];

Object.assign(window, {
  VENDORS, CATEGORY_ORDER, CATEGORY_LABEL, CAT_LABEL_SHORT,
  CONNECTED_SOURCES
});
