Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

843 B
Raw Blame
/* Copyright 2026 Marimo. All rights reserved. */
import { PrimitiveType } from "compassql/build/src/schema";
import {
  CalendarIcon,
  HashIcon,
  ListOrderedIcon,
  ToggleLeftIcon,
  TypeIcon,
} from "lucide-react";

/**
 * Icon mapping from PrimitiveType to Lucid icon
 */
export const PRIMITIVE_TYPE_ICON: Record<PrimitiveType, React.ReactNode> = {
  [PrimitiveType.BOOLEAN]: (
    <ToggleLeftIcon className="h-5 w-5 inline-flex opacity-60" />
  ),
  [PrimitiveType.DATETIME]: (
    <CalendarIcon className="h-5 w-5 inline-flex opacity-60" />
  ),
  [PrimitiveType.NUMBER]: (
    <HashIcon className="h-5 w-5 inline-flex opacity-60" />
  ),
  [PrimitiveType.STRING]: (
    <TypeIcon className="h-5 w-5 inline-flex opacity-60" />
  ),
  [PrimitiveType.INTEGER]: (
    <ListOrderedIcon className="h-5 w-5 inline-flex opacity-60" />
  ),
};