Commit graph

4 commits

Author SHA1 Message Date
43a70929ec fix(database-view): pick a database before listing tables
The insert-database modal called the public bridge /api/v1/tables route,
which requires a databaseId and a Baserow user JWT — the modal supplied
neither, so the request returned 400 then 501.

Add a step 0 to pick a workspace and database (auto-resolved when each
lists only one), then list tables via the admin endpoint
GET /api/v1/admin/tables?databaseId=X. The client extension is also
rewired to .extend() the shared DatabaseView node.
2026-05-11 12:28:38 +00:00
d0b75774d8 feat(acadenice): add timeline view (Gantt) for databases — R4.1
- New TimelineRenderer using @fullcalendar/timeline + @fullcalendar/resource-timeline
- Column mapping config (title/start/end/resource) persisted in bridge Redis TTL 30d
- useTimelineConfig hook (GET+POST /views/:viewId/timeline-config)
- Inline config panel shown on first use; re-accessible via Configure button
- Resource swimlane mode activated automatically when resourceCol is configured
- eventResize persists endCol via useUpdateRow (respects canWriteRows)
- End date fallback: start + 1 day when endCol is absent
- InsertDatabaseModal extended with step 3 for column mapping on timeline views
- database-view-component dispatches timeline viewType to TimelineRenderer
- 14 client Vitest tests + 12 bridge Vitest tests (26 total new, all green)
- 0 TypeScript errors (client + bridge)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-08 11:27:11 +02:00
f3fae2ac78 feat(client): add kanban + calendar renderers + inline edit for R3.1.d
- KanbanRenderer: @dnd-kit drag-drop, group by single_select field,
  optimistic update + rollback, empty column placeholder, read-only mode
- CalendarRenderer: @fullcalendar month/week/day toggle, eventDrop ->
  PATCH date field, event click -> RowDetailModal, stub deps noted
- InlineEditor: polymorphic (text/number/date/select/multi-select),
  save on blur/Enter, cancel on Escape, permission denied read-only
- RowDetailModal: simple field detail view opened from calendar events
- useUpdateRow: generic PATCH with React Query v5 optimistic+rollback
- usePermissions: reads acadenice_permissions from window global or cookie
- patchRow helper added to bridge-client.ts
- DatabaseViewComponent: dispatches kanban/calendar to real renderers
- TableRenderer: integrates InlineEditor on double-click cells
- i18n: +12 keys (kanban.*, calendar.*, edit.*, row_detail.*) in en-US + fr-FR
- 5 new test suites: kanban, calendar, inline-editor, use-update-row, use-permissions
- Updated database-view-component.test.tsx for R3.1.d dispatch

Deps to install: @dnd-kit/core@^6 @dnd-kit/sortable@^8 @dnd-kit/utilities@^3
  @fullcalendar/react@^6 @fullcalendar/daygrid@^6
  @fullcalendar/timegrid@^6 @fullcalendar/interaction@^6

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-08 00:24:12 +02:00
71c2abad8a feat(client): add database-view Tiptap extension for R3.1.c
- Tiptap Node extension (database-view) with attrs tableId/viewId/viewType/bridgeUrl
- NodeViewWrapper dispatches on viewType: grid/table -> TableRenderer, other -> PlaceholderRenderer
- TableRenderer (HTML table, TanStack Table v8 migration-ready - dep not yet installed)
- InsertDatabaseModal (Mantine, 2-step: table -> view selection)
- useDatabaseRealtimeUpdates SSE hook (EventSource + exponential backoff + React Query invalidation)
- bridge-client.ts (axios wrapper, per-origin singleton, cookie Bearer passthrough)
- Slash command /database registered in menu-items CommandGroups
- DatabaseViewExtension wired in mainExtensions array
- i18n: 22 keys added in en-US and fr-FR
- 41 Vitest tests across 5 suites (extension schema, component dispatch, renderer states, modal steps, SSE hook)

Upstream patches: extensions.ts (+2 lines), menu-items.ts (+4 lines), 2 translation files

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-08 00:07:33 +02:00