github TableProApp/TablePro v0.5.0

latest releases: v0.32.1, v0.32.0, v0.31.5...
one month ago

Changed

  • AI chat panel — native macOS inspector styling: removed iOS-style chat bubbles, flattened message layout with role headers and compact spacing, reduced heading sizes for narrow sidebar, inline typing indicator without pill background
  • AppKit → SwiftUI migration: migrated 5 NSPopover controllers (Enum, Set, TypePicker, JSONEditor, ForeignKey) to SwiftUI content views with a shared PopoverPresenter utility — eliminates manual NSEvent monitors, NSPopoverDelegate, and singleton patterns
  • AppKit → SwiftUI migration: replaced KeyEventHandler NSViewRepresentable with native .onKeyPress() modifiers (macOS 14+) in DatabaseSwitcherSheet and WelcomeWindowView
  • AppKit → SwiftUI migration: replaced AppKit history panel (5 files: HistoryPanelController, HistoryListViewController, QueryPreviewViewController, HistoryTableView, HistoryRowView) with single pure SwiftUI HistoryPanelView using HSplitView, List with selection, context menus, and swipe-to-delete
  • AppKit → SwiftUI migration: replaced ExportTableOutlineView (NSOutlineView, 757 lines across 2 files) with SwiftUI ExportTableTreeView using List, DisclosureGroup, and tristate checkboxes (~146 lines)
  • Design tokens: replaced hardcoded Color.secondary.opacity(0.6) with system Color(nsColor: .tertiaryLabelColor) in DesignConstants and ToolbarDesignTokens for proper semantic color

Added

  • AI chat panel shows "Set Up AI Provider" empty state when no AI provider is configured, with a button to open Settings
  • AI chat panel — right-side panel for AI-assisted SQL queries with multi-provider support (Claude, OpenAI, OpenRouter, Ollama, custom endpoints)
  • AI provider settings — configure multiple AI providers in Settings > AI with API key management (Keychain), endpoint configuration, model selection, and connection testing
  • AI feature routing — map AI features (Chat, Explain Query, Fix Error, Inline Suggestions) to specific providers and models
  • AI schema context — automatically includes database schema, current query, and query results in AI conversations for context-aware assistance
  • AI chat code blocks — SQL code blocks in AI responses include Copy and Insert to Editor buttons
  • AI chat markdown rendering — replaced custom per-line AttributedString parsing with MarkdownUI library for full CommonMark + GitHub Flavored Markdown support (proper lists, tables, blockquotes, headers, strikethrough)
  • Per-connection AI policy — control AI access per connection (Always Allow, Ask Each Time, Never) in the connection form
  • Toggle AI Chat keyboard shortcut (⌘⇧L) and toolbar button
  • Tab reuse setting — opt-in option in Settings > Tabs to reuse clean table tabs when clicking a new table in the sidebar (off by default)
  • Structure view: full undo/redo support (⌘Z / ⇧⌘Z) for all column, index, and foreign key operations
  • Structure view: database-specific type picker popover for the Type column — searchable, grouped by category (Numeric, String, Date & Time, Binary, Other), supports freeform input for parametric types like VARCHAR(255)
  • Structure view: YES/NO dropdown menu for Nullable, Auto Inc, and Unique columns (replaces freeform text input)
  • Structure view: "Don't show again" toggle in SQL preview sheet now correctly skips the review step on future saves
  • SQL autocomplete: new clause types — RETURNING, UNION/INTERSECT/EXCEPT, OVER/PARTITION BY, USING, DROP/CREATE INDEX/VIEW
  • SQL autocomplete: smart clause transition suggestions (e.g., WHERE after FROM, HAVING after GROUP BY, LIMIT after ORDER BY)
  • SQL autocomplete: qualified column suggestions (table.column) in JOIN ON clauses and table.* in SELECT
  • SQL autocomplete: compound keyword suggestions — IS NULL, IS NOT NULL, NULLS FIRST, NULLS LAST, ON CONFLICT, ON DUPLICATE KEY UPDATE
  • SQL autocomplete: richer column metadata in suggestions (primary key, nullability, default value, comment)
  • SQL autocomplete: keyword documentation in completion popover
  • SQL autocomplete: expanded keyword and function coverage — window functions, PostgreSQL/MySQL-specific, transaction, DCL, aggregate, datetime, string, numeric, JSON
  • SQL autocomplete: context-aware suggestions for ALTER TABLE, INSERT INTO, CREATE TABLE, and COUNT(*)
  • SQL autocomplete: improved fuzzy match scoring — prefix and contains matches rank above fuzzy-only matches
  • Keyboard shortcut customization in Settings > Keyboard — rebind any menu shortcut via press-to-record UI, with conflict detection and "Reset to Defaults" support
  • Keyboard shortcut for Switch Connection (⌘⌥C) — quickly open the connection switcher popover from the menu or keyboard

Changed

  • Layout architecture: replaced SplitViewMinWidthEnforcer NSViewRepresentable hack with proper AppDelegate-based inspector split view configuration — eliminates KVO observation, 300ms sleep, and recursive view tree traversal
  • Inspector data flow: replaced manual snapshot syncing (syncRightPanelSnapshotData() + 5 onChange handlers) with InspectorContext value type passed directly through the view hierarchy via @Binding
  • Right panel state: RightPanelState no longer holds snapshot copies of coordinator data or a weak coordinator reference — it now only manages panel visibility, tab state, and owned objects
  • AI chat panel: receives currentQuery: String? parameter instead of a MainContentCoordinator reference — better separation of concerns
  • Sidebar save: replaced .saveSidebarChanges notification with direct closure (RightPanelState.onSave) set by the notification handler
  • Structure tab grid columns now auto-size to fit content on data load
  • Structure view column headers and status messages are now localized
  • SQL autocomplete: 50ms debounce for completion triggers to reduce unnecessary work
  • SQL autocomplete: fuzzy matching rewritten for O(1) character access performance

Fixed

  • Structure view: undo/redo (⌘Z / ⇧⌘Z) now works for all schema editing operations — previously non-functional
  • Structure view: undo-delete no longer duplicates existing rows in the grid
  • Structure view: deleting a new (unsaved) item then undoing correctly re-adds it
  • Structure view: save button now disabled when validation errors exist (empty column names/types)
  • Structure view: validation now rejects indexes and foreign keys referencing columns pending deletion
  • Structure view: multi-column foreign keys are correctly preserved instead of being truncated to single-column
  • Structure view: renaming a MySQL/MariaDB column now uses CHANGE COLUMN instead of MODIFY COLUMN (which cannot rename)
  • Structure view: eliminated redundant discardChanges() and loadSchemaForEditing() calls on save and initial load
  • PostgreSQL: DDL tab now includes PRIMARY KEY, UNIQUE, CHECK, and FOREIGN KEY constraints plus standalone indexes
  • PostgreSQL: primary key columns are now correctly detected and displayed in the structure grid
  • Security: escape table and database names in all driver schema queries to prevent SQL injection from names containing special characters
  • SQL editor: undo/redo (⌘Z / ⇧⌘Z) now works correctly (was blocked by responder chain selector mismatch)
  • SQL autocomplete: clause detection now works correctly inside subqueries
  • SQL autocomplete: block comment detection no longer treats -- inside /* */ as a line comment
  • SQL autocomplete: database-specific type keywords (e.g., PostgreSQL JSONB, MySQL ENUM) now appear in suggestions
  • SQL autocomplete: schema suggestions no longer disappear after CREATE TABLE
  • SQL autocomplete: function completion now inserts COUNT() with cursor between parentheses instead of COUNT(
  • SQL autocomplete: RETURNING suggestions now work after INSERT INTO and after closed VALUES (...) parentheses
  • SQL autocomplete: CREATE INDEX ON suggests columns from the referenced table instead of table names
  • SQL autocomplete: transition keywords (WHERE, JOIN, ORDER BY) no longer buried under columns at clause boundaries
  • SQL autocomplete: schema-qualified names (e.g., schema.table.column) handled correctly
  • Data grid: column order no longer flashes/swaps when sorting (stable identifiers for layout persistence)
  • Data grid: "Copy Column Name" and "Filter with column" context menu actions no longer copy sort indicators (e.g., "name 1▲")
  • SQL generation: ALTER TABLE, DDL, and SQL Preview statements now consistently end with a semicolon
  • AI chat: "Ask Each Time" connection policy now shows a confirmation dialog before sending data to AI — previously silently fell through to "Always Allow"

Removed

  • Deleted unused StructureTableCoordinator.swift (~275 lines of dead code)
  • Deleted 5 dead NSToolbar files (ToolbarController, ToolbarWindowConfigurator, ToolbarItemFactory, ToolbarItemIdentifier, ToolbarHostingViews) — never referenced by active code
  • Removed SplitViewMinWidthEnforcer struct from ContentView.swift
  • Removed .saveSidebarChanges notification definition and subscription

Don't miss a new TablePro release

NewReleases is sending notifications on new releases.