fix: resolve Calendar identifier conflict in DynamicPropertiesPanel

- Rename Calendar import from lucide-react to CalendarIcon2 to avoid
  conflict with Calendar from @/components/ui/calendar
- Add tsc --noEmit and pnpm build steps to CI to catch type/bundler
  errors before tests run (prevents this class of bug from reaching main)
This commit is contained in:
lucaronin
2026-02-27 10:47:24 +01:00
parent 58692882f2
commit d6d1b87d0c
2 changed files with 9 additions and 2 deletions

View File

@@ -38,6 +38,13 @@ jobs:
- name: Install dependencies
run: pnpm install --frozen-lockfile
# ── 0. Build check (catches type errors and bundler failures) ─────────
- name: TypeScript type check
run: pnpm exec tsc --noEmit
- name: Vite build check
run: pnpm build
# ── 1. Tests ──────────────────────────────────────────────────────────
- name: Run frontend tests
run: pnpm test

View File

@@ -11,7 +11,7 @@ import { Select, SelectContent, SelectItem, SelectSeparator, SelectTrigger, Sele
import { CalendarIcon, XIcon } from 'lucide-react'
import { getTypeColor, getTypeLightColor } from '../utils/typeColors'
import { countWords } from '../utils/wikilinks'
import { Check, X, Type, Calendar, ToggleLeft, Circle, Link } from 'lucide-react'
import { Check, X, Type, Calendar as CalendarIcon2, ToggleLeft, Circle, Link } from 'lucide-react'
import {
type PropertyDisplayMode,
getEffectiveDisplayMode,
@@ -237,7 +237,7 @@ function DisplayModeSelector({ propKey, currentMode, autoMode, onSelect }: {
}
const DISPLAY_MODE_ICONS: Record<PropertyDisplayMode, typeof Type> = {
text: Type, date: Calendar, boolean: ToggleLeft, status: Circle, url: Link,
text: Type, date: CalendarIcon2, boolean: ToggleLeft, status: Circle, url: Link,
}
function AddPropertyForm({ onAdd, onCancel }: {