* @
fix(grid): preserve current page on data refresh instead of resetting to page 1
When refreshing table data (toolbar button, Ctrl+R, or auto-refresh), the
offset was hardcoded to 0, causing pagination to always jump back to the
first page. This was frustrating for users viewing later pages.
Use the current page offset (currentPage - 1) * pageSize so the user
stays on the same page after refresh. In infinite-scroll mode, the
offset still evaluates to 0 because resetInfiniteScrollState() sets
currentPage = 1, so behavior is unchanged.
@
* @
fix(grid): auto-redirect to last page when refreshed page no longer exists
Extends the refresh pagination fix with a safety net: when data is deleted
while viewing a later page (e.g. page 5 with only 2 pages remaining), the
grid auto-navigates to the last available page instead of showing an empty
page.
Uses a transient isRefreshingData flag to distinguish refresh/rollback
from normal pagination navigation, avoiding false triggers.
@
* Revert "@"
This reverts commit ff0bf0bb31ccfbbb6d4787d1d036794fd37acd5a.
* @
fix(grid): auto-redirect to last page when refreshed page no longer exists
When data is deleted while viewing a later page, the grid now auto-navigates
to the last available page instead of showing an empty page.
Uses a transient isRefreshingData flag to distinguish refresh/rollback
from normal pagination, and a loading-transition watcher (true->false)
placed after displayedTotalRowCount declaration to avoid TDZ errors.
@
* @
test(grid): add pagination offset-preservation and auto-redirect tests
Cover the two new behaviors added to DataGrid.vue:
1. dataGridPagination.test.ts — auto-redirect page calculation:
- page beyond last page after data deletion → triggers redirect
- page still valid → no redirect
- fewer rows than one page → redirects to page 1
- total=0 / total=undefined → guard prevents redirect
2. useDataGridActions.test.ts — offset preserved on reload:
- onReloadData(offset=400) passes offset=400 to build-table-select-sql
- resultPageOffset stored as 400 (not reset to 0)
@
Previously, pure numeric values (e.g. 90001543) in the IN clause were not quoted while values with leading zeros (e.g. 00040787) were, causing inconsistent quoting. Now all non-NULL values are uniformly quoted.
* fix: preserve large integer precision when formatting JSON in value editor (fixes#2765)
* fix: add missing showDiagramDialog to useNavigationTargets in AiAssistant
* feat(spark): add Apache Spark database driver
Spark Thrift Server speaks the HiveServer2 protocol, so the Spark driver
reuses the hive-jdbc agent runtime. Registers spark (agentKey=spark,
defaultPort=10015) across the manifest, DatabaseType enum, agent catalog,
SQL dialects, connection dialog, and a SparkAgent built on AbstractJdbcAgent.
* feat(spark): add catalog support and official logo
SparkAgent now supports Spark 3.4+ multi-catalog (Paimon, Lance, Iceberg)
via catalog=<name> in url_params, mirroring the StarRocks catalog flow:
- afterConnect switches to the configured catalog via USE <catalog>
- listDatabases returns the catalog name when SHOW DATABASES is empty
(catalogs like Lance expose tables at the catalog root with no databases)
- listTables uses SHOW TABLES IN <catalog>[.<schema>] uniformly, working
for both catalog-root tables (Lance) and catalog.schema tables (Paimon)
- setSchemaSQL qualifies USE with the catalog to prevent resetting to
spark_catalog on schema switches
- buildJdbcUrl omits database from the URL path
Also replaces the placeholder lightning icon with the official Apache Spark
logo (spark-logo.png from spark.apache.org).
* fix(spark): use catalog-qualified DESCRIBE for column retrieval
getColumnsFromDescribe used USE <schema> + DESCRIBE <table>, which
generated USE `catalog`.`catalog` when the sidebar passed the catalog
name as the schema (Lance case where the catalog is the only node).
This failed and fell back to JDBC metadata which also returned nothing,
resulting in an empty DDL (CREATE TABLE ... ()).
Now uses DESCRIBE `catalog`.`table` directly when a catalog is
configured, bypassing USE entirely. Also fixes setSchemaSQL to treat
schema == catalog as catalog-only (no .schema suffix).
* fix(ci): add spark to metadata coverage matrix and BRIDGE_REQUIRED_TYPES
- agents/metadata-constraint-coverage.tsv: register spark as
intentional-fallback (SHOW TABLES/SHOW DATABASES, like Hive/TDengine)
- packages/node-core/src/diagnostics.ts: add spark to
BRIDGE_REQUIRED_TYPES (mcpMode=bridge, matches manifest)
* fix(ci): add spark to DBX_CONNECTION_TYPE_DESCRIPTION in mcp-server
The driver-manifest test asserts every manifest dbType appears in the
MCP server's connection type description string.
fix(ai): make reasoning expand/collapse consistent across messages
Replace per-message expandedReasoning Set with a global reasoningExpanded
boolean ref so all messages share the same toggle state. Default to collapsed.
This avoids the flip-flop where reasoning auto-expands during streaming and
collapses afterward, requiring repeated manual toggles.
- Replace expandedReasoning (Set<number>) with reasoningExpanded (boolean)
- Remove per-index toggleReasoning; use global flip instead
- Template uses reasoningExpanded instead of expandedReasoning.has(i) || msg.isThinking
@