Commit graph

48 commits

Author SHA1 Message Date
Rohith Gilla
f2cfd165f9 chore: release v0.10.0 2025-12-18 20:31:32 +05:30
Rohith Gilla
7458e6649a Merge branch 'main' into claude/setup-blog-posts-sitemap-GqlX8 2025-12-18 13:28:50 +05:30
Rohith Gilla
8a865b512a feat: add widgets!!!! 2025-12-17 08:34:49 +05:30
Rohith Gilla
3ed1de344f feat(scheduler): replace setTimeout with node-cron for reliable scheduling
- Replace setTimeout-based scheduling with node-cron for precise timing
- Add "New Schedule" button to empty state in sidebar
- Add cron expression validation before scheduling
- Remove comment dividers per style preference
2025-12-16 19:58:56 +05:30
Rohith Gilla
505e1a139c chore: release v0.9.0 2025-12-16 18:26:32 +05:30
Claude
ac4557c301
feat: add query scheduling with cron-like support
- Add ScheduledQuery and ScheduledQueryRun types to shared package
- Create scheduler service in main process with cron-parser for scheduling
- Add IPC handlers for scheduled queries CRUD operations
- Update preload to expose scheduled queries API
- Create Zustand store for scheduled queries state management
- Add UI components:
  - ScheduledQueriesDialog for listing and managing schedules
  - ScheduledQueryFormDialog for creating/editing schedules
  - ScheduledQueryRunsDialog for viewing run history
  - ScheduledQueries sidebar component
- Support schedule presets (every minute, hourly, daily, etc.) and custom cron
- Include desktop notifications on completion/error
- Store run history with configurable retention
2025-12-16 10:09:32 +00:00
Rohith Gilla
a610709b80
feat: add query performance indicator (#69)
* feat: add query perf indication

* fix: address code review issues from PR #69

- Fix invalid PostgreSQL identifier truncation (use substring(0,63) instead of appending dots)
- Split long regex patterns to satisfy Prettier line length limits
- Add guard against empty/malformed EXPLAIN plan arrays
- Use @shared/index import for consistency with project conventions
- Add missing uuid dependency to package.json
2025-12-16 11:52:55 +05:30
Rohith Gilla
8d9b533ad4 chore: release v0.8.1 2025-12-15 15:17:11 +05:30
Rohith Gilla
c09d243b58
chore: codebase cleanup and DRY refactoring (#63)
* chore: codebase cleanup and DRY refactoring

- Create useCopyToClipboard hook to eliminate duplicate clipboard pattern
- Create getTypeColor utility to consolidate type color logic
- Create usePanelCollapse hook for panel state management
- Create useExecutionPlanResize hook for resize logic with persistence
- Extract connection string parser to dedicated module (206 lines)
- Remove 5 unused AI response types from shared package
- Remove unused dependencies (@ai-sdk/openai-compatible, @ai-sdk/react)
- Remove machine-generated section comments from shared/index.ts

* chore: fix small issue
2025-12-12 15:04:01 +05:30
Rohith Gilla
5311e58c13 fix: add missing @radix-ui/react-visually-hidden dependency
The command.tsx component imports this package but it was not listed
in dependencies, causing production builds to fail.
2025-12-12 13:00:03 +05:30
Rohith Gilla
448fa4895b chore: release v0.8.0 2025-12-12 12:51:38 +05:30
Rohith Gilla
ca5d3e0e5c
feat: migrate command palette to cmdk library (#59)
* feat: migrate command palette to cmdk library

- Replace custom command palette with cmdk for better UX
- Add nested page navigation (connections, saved queries, appearance)
- Implement smart fuzzy search with acronym and character matching
- Add pin/unpin functionality for saved queries
- Auto-switch to newly added connections
- Cmd+P now opens directly to connection list with add/edit options

* chore: Apply consistent code formatting and quoting conventions across various files.

* chore: delete unwanted
2025-12-12 11:26:57 +05:30
Rohith Gilla
256b06b3a1 chore: release v0.7.0 2025-12-11 12:31:44 +05:30
Rohith Gilla
8d023eee0d chore: release v0.6.2 2025-12-09 09:30:57 +05:30
Rohith Gilla
4a57d3c707 chore: release v0.6.1 2025-12-09 09:30:45 +05:30
Rohith Gilla
ec5de32862 fix: move shared package to devDependencies for electron-builder
Fixes Linux build by moving @data-peek/shared from dependencies to
devDependencies. The shared package is bundled by Vite via the @shared
alias, so it's not needed at runtime. Also excludes .turbo directories
from the build.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-09 09:27:34 +05:30
Rohith Gilla
a64d964c60 chore: release v0.6.0 2025-12-09 08:36:59 +05:30
phantomreactor
70d5f6a270
feat: db connections via ssh (#51)
* feat: connect via ssh

* Update apps/desktop/src/main/ssh-tunnel-service.ts

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* refactor ssh changes

* fix: address review comments

---------

Co-authored-by: Rohith Gilla <gillarohith1@gmail.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-12-09 08:07:57 +05:30
Rohith Gilla
da8cc574d3 chore: fix build and clean things 2025-12-08 19:58:17 +05:30
Rohith Gilla
66df1f77a8 Merge branch 'main' into claude/add-test-coverage-01L5b9CcytSmm7k9rzFdLdiH 2025-12-06 15:54:05 +05:30
Rohith Gilla
f102f61a55 chore: refactor logging 2025-12-06 15:34:08 +05:30
Claude
ff83bb33ae
feat: add comprehensive test coverage for core SQL builders
- Add Vitest testing framework with v8 coverage
- Add 177 unit tests covering critical paths:
  - sql-builder.ts: INSERT/UPDATE/DELETE generation (97% coverage)
  - ddl-builder.ts: CREATE/ALTER TABLE DDL (97% coverage)
  - sql-utils.ts: identifier quoting (100% coverage)
  - edit-store.ts: Zustand store state management (92% coverage)
- Test all 4 database dialects: PostgreSQL, MySQL, SQLite, MSSQL
- Add test scripts: pnpm test, pnpm test:watch, pnpm test:coverage

Resolves CRIT-001: Zero Test Coverage
2025-12-06 08:25:38 +00:00
Rohith Gilla
bf6281c08e chore: release v0.5.3 2025-12-05 21:27:30 +05:30
Rohith Gilla
0f971d0352 chore: release v0.5.2 2025-12-05 08:20:41 +05:30
Rohith Gilla
49890b255c chore: fix linter issues 2025-12-05 08:20:12 +05:30
carvalab
048861fd13
Feat/fix anthropic and OpenAI ai errors (#35)
* feat: fix the AI service to remove the discrimination union

* feat: chore 0.5.2

* feat: reimplement the multi provider
2025-12-05 08:18:55 +05:30
Rohith Gilla
fe092ceee7 chore: release v0.5.1 2025-12-04 21:48:49 +05:30
Rohith Gilla
3051178ce1 chore: release v0.5.0 2025-12-04 18:20:43 +05:30
Rohith Gilla
bfd94e46d3
feat: Sidebar UX improvements with resizable width and virtualization (#30)
* feat: hide quick editor panel and virtualization for longer list

* fix: Address PR review feedback

- Add dynamic size estimation for virtualized items based on expanded state
- Add effect to recalculate virtualizer when items expand/collapse
- Fix keyboard shortcut whitespace issues in tab-query-editor.tsx
2025-12-04 18:19:59 +05:30
Rohith Gilla
8781cb946c chore: release v0.4.0 2025-12-03 16:45:07 +05:30
Rohith Gilla
5cc4a55515
feat: web updates with pro license, customer portal, and safety improvements (#24)
* fix: prevent duplicate autocomplete suggestions in SQL editor

Use singleton pattern for Monaco completion provider to prevent
duplicates when multiple editor tabs are open. Also disable
word-based suggestions since the custom provider is comprehensive.


* feat(ai): prevent auto-execution of destructive SQL queries

Add safety guardrails to ensure UPDATE, DELETE, DROP, and TRUNCATE
queries are never auto-executed from the AI chat. Users must manually
review and execute these queries in a new tab.

- Add requiresConfirmation field to AI query response schema
- Update system prompt to require confirmation for destructive queries
- Hide "Run Query" button when requiresConfirmation is true
- Show "Review in Tab" button with warning styling instead


* feat: handle pro license

* feat: add customer portal

* feat: fix a few things

* chore: add simeple umami self hosted analytics

* fix: add globalEnv to turbo.json for Vercel builds

Declares environment variables required by the web app so Turborepo
passes them through during Vercel builds.

* refactor: use next/script for analytics with afterInteractive strategy

Replaces raw script tag with Next.js Script component for better
loading optimization, de-duplication, and automatic placement.
2025-12-03 16:44:38 +05:30
Rohith Gilla
24b66e9f64 chore: release v0.3.0 2025-12-02 07:52:12 +05:30
Pablo Maldonado
f2e636883f
Add MSSQL support (#14)
* feat: add MSSQL support to the application

- Introduced MSSQL database adapter and integrated it into the existing database management system.
- Updated connection handling to support MSSQL-specific options, including Active Directory authentication.
- Enhanced SQL query generation to accommodate MSSQL syntax, including TOP clause for limits and schema handling.
- Added UI components for MSSQL connection setup and management.
- Updated package dependencies to include mssql and related types.

* fix: attend nit-picks from CodeRabbit

- Moved identifier quoting logic from DDL and SQL builders to a new utility function in sql-utils.ts for better code reuse and maintainability.
- Updated the quoteIdentifier function in both ddl-builder.ts and sql-builder.ts to utilize the new utility function.
- Enhanced MSSQL adapter to improve data type resolution logic.
- Improved connection string parsing in add-connection-dialog.ts to support multiple key formats for parameters.
- Updated tab-store.ts to handle quoting for MSSQL and other database types consistently.

* fix: update MSSQL support to disable 'if not exists' functionality

- Changed the MSSQL adapter to set 'supportsIfNotExists' to false, aligning with the current database capabilities.
2025-11-30 22:18:38 +05:30
Rohith Gilla
dac87ec006 chore: release v0.2.0 2025-11-30 18:42:54 +05:30
Rohith Gilla
91cb5791d2
feat: Add AI Assistant with multi-provider support and chat persistence (#13)
* feat: add AI assistant with inline query execution and chat persistence

- Integrate AI SDK with structured JSON output (query, chart, metric, schema, message types)
- Support multiple AI providers: OpenAI, Anthropic, Google, Groq, Ollama
- Add inline query execution with results displayed directly in chat
- Persist chat history per connection using electron-store
- Add AI settings modal for API key configuration
- Create generative UI components: charts (bar, line, pie, area), metrics, schema cards
- Add SQL preview with syntax highlighting and copy/execute actions

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* feat: ai chat persistence

* chore: fix linting issues

* chore: add some notes

* feat: Introduce shared AI types and implement secure, migratable storage for

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-11-30 18:33:03 +05:30
Rohith Gilla
e4938b194f
feat: UX improvements - click to edit, enum dropdowns, settings, JSON viewer, ERD layout (#9)
* feat: UX improvements - click to edit, enum dropdowns, settings, JSON viewer, ERD layout

- Allow clicking on any cell to edit directly (was double-click)
- Add enum dropdown support for enum type columns
- Create global settings store with localStorage persistence
- Add setting to hide query editor by default for table previews
- Add setting to expand JSON objects by default in viewer
- Implement JSON cell editing via sheet editor with live preview
- Improve JSON cell preview with partial content and tooltip
- Fix ERD diagram auto-layout with better spacing to prevent overlapping
- Add Switch UI component from Radix

* chore: small react issue

* feat: on click to editable table data

* chore: fix lock file

* feat: Add support for PostgreSQL expression indexes and refine data table cell editing interactions.

* Update apps/desktop/src/main/adapters/postgres-adapter.ts

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

---------

Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
2025-11-30 14:08:43 +05:30
Rohith Gilla
79cecc2f1f
fix: pin electron version for electron-builder compatibility (#10)
* fix: pin electron version for electron-builder compatibility

Remove semver range (^) from electron dependency to fix
"Cannot compute electron version from installed node modules" error
during postinstall.

Fixes #6

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>

* chore: fix lock files

* chore: fix lock file

---------

Co-authored-by: Claude <noreply@anthropic.com>
2025-11-30 09:59:47 +05:30
Rohith Gilla
2425755879
feat: user feedback improvements and bug fixes (#5)
* db: drizzle migrations

* feat: implement user feedback!

Thanks @Mihaly_NC for the feedback!

* feat: expandable and collapsible query panel

* chore: formatting

* chore: bump version

* chore: fix a small oopsie
2025-11-29 17:21:56 +05:30
Rohith Gilla
d6b31d0559 chore: prepare for open source release 2025-11-29 10:57:24 +05:30
Claude
c77a67a0b3
feat: add MySQL database support
- Add mysql2 package for MySQL connectivity
- Create database adapter interface with PostgreSQL and MySQL implementations
- Update ConnectionConfig to include dbType field for database type selection
- Refactor IPC handlers to use adapters for database-agnostic operations
- Update connection dialog with database type selector (PostgreSQL/MySQL)
- Support MySQL-specific schema fetching, DDL reverse engineering, and EXPLAIN
- Add MySQL type code to human-readable name mapping
- Ensure backward compatibility for existing PostgreSQL connections
2025-11-28 15:36:39 +00:00
Rohith Gilla
be6a9a4db7 feat: add memory rouhter 2025-11-28 18:28:31 +05:30
Rohith Gilla
1c1cb1df97 feat: add table search, ERD visualization, and tab improvements
- Add table search in schema explorer with real-time filtering
- Add ERD visualization using @xyflow/react to view table relationships
- Fix tab switching shortcuts (Cmd+Option+Arrow instead of Cmd+Tab)
- Fix duplicate tab bug when clicking already-opened table
- Add "Close All Tabs" option to tab context menu
- Add future-plan.md documenting planned features

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-28 14:36:48 +05:30
Rohith Gilla
98ee74257e feat: add inline data editing with database-agnostic SQL generation
- Add edit mode toggle for table-preview tabs with visual indicators
- Implement cell editing with type-aware inputs (text, number, date, boolean)
- Support row deletion (mark for deletion) and new row insertion
- Build parameterized SQL queries for PostgreSQL, MySQL, and SQLite dialects
- Add SQL preview modal before committing changes
- Execute edits in transactions with rollback on error
- Extract JsonCellValue and FKCellValue to shared components
- Add edit-store for managing edit state per tab

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-28 13:39:04 +05:30
Rohith Gilla
887dd1e48c ui: use geist mono font 2025-11-28 11:07:26 +05:30
Rohith Gilla
0a48c3638a feat: add multi tab support 2025-11-28 10:53:55 +05:30
Rohith Gilla
8f568f9ef2 feat: query editor 2025-11-28 08:57:19 +05:30
Rohith Gilla
69248610b7 feat: working state 2025-11-28 08:27:08 +05:30
Rohith Gilla
703c850744 🚀 chore: init commit 2025-11-26 15:53:53 +05:30