Skip to content

AI Agents & MCPs & AI Workflow Automation • (~400 MCP servers for AI agents) • AI Automation / AI Agent with MCPs • AI Workflows & AI Agents • MCPs for AI Agents

595 B
Raw Blame
import { t } from 'i18next';

import { ValueRow } from './shared-value-rendering';

type OutputGenericFieldListProps = {
  json: Record<string, unknown>;
};

function OutputGenericFieldList({ json }: OutputGenericFieldListProps) {
  const entries = Object.entries(json);

  if (entries.length === 0) {
    return <div className="p-4 text-sm text-gray-11 italic">{t('empty')}</div>;
  }

  return (
    <div className="py-1">
      {entries.map(([key, value]) => (
        <ValueRow key={key} label={key} value={value} depth={0} />
      ))}
    </div>
  );
}

export { OutputGenericFieldList };