feat: enhance query view with fullscreen toggle and details management

- Added fullscreen toggle functionality to the QueryView component.
- Introduced new icons for maximizing and minimizing the view.
- Updated the QueryView component to handle details display with tab management.
- Refactored the store to manage details data and active tabs.
- Improved the handling of view data in the studio, including filtering unnecessary fields.
- Created new routes for ID and console views, integrating them into the routing structure.
- Added dynamic basename calculation based on the current URL path.
- Enhanced the query module to utilize context keys for better state management.
- Updated the UI components for better user experience and accessibility.
This commit is contained in:
2026-02-19 00:21:56 +08:00
parent 94047cd45f
commit eafe815d8f
21 changed files with 1026 additions and 290 deletions

View File

@@ -9,8 +9,26 @@
// Additionally, you should also exclude this file from your linter and/or formatter to prevent it from being checked or modified.
import { Route as rootRouteImport } from './routes/__root'
import { Route as ViewRouteImport } from './routes/view'
import { Route as ConsoleRouteImport } from './routes/console'
import { Route as IdRouteImport } from './routes/$id'
import { Route as IndexRouteImport } from './routes/index'
const ViewRoute = ViewRouteImport.update({
id: '/view',
path: '/view',
getParentRoute: () => rootRouteImport,
} as any)
const ConsoleRoute = ConsoleRouteImport.update({
id: '/console',
path: '/console',
getParentRoute: () => rootRouteImport,
} as any)
const IdRoute = IdRouteImport.update({
id: '/$id',
path: '/$id',
getParentRoute: () => rootRouteImport,
} as any)
const IndexRoute = IndexRouteImport.update({
id: '/',
path: '/',
@@ -19,28 +37,61 @@ const IndexRoute = IndexRouteImport.update({
export interface FileRoutesByFullPath {
'/': typeof IndexRoute
'/$id': typeof IdRoute
'/console': typeof ConsoleRoute
'/view': typeof ViewRoute
}
export interface FileRoutesByTo {
'/': typeof IndexRoute
'/$id': typeof IdRoute
'/console': typeof ConsoleRoute
'/view': typeof ViewRoute
}
export interface FileRoutesById {
__root__: typeof rootRouteImport
'/': typeof IndexRoute
'/$id': typeof IdRoute
'/console': typeof ConsoleRoute
'/view': typeof ViewRoute
}
export interface FileRouteTypes {
fileRoutesByFullPath: FileRoutesByFullPath
fullPaths: '/'
fullPaths: '/' | '/$id' | '/console' | '/view'
fileRoutesByTo: FileRoutesByTo
to: '/'
id: '__root__' | '/'
to: '/' | '/$id' | '/console' | '/view'
id: '__root__' | '/' | '/$id' | '/console' | '/view'
fileRoutesById: FileRoutesById
}
export interface RootRouteChildren {
IndexRoute: typeof IndexRoute
IdRoute: typeof IdRoute
ConsoleRoute: typeof ConsoleRoute
ViewRoute: typeof ViewRoute
}
declare module '@tanstack/react-router' {
interface FileRoutesByPath {
'/view': {
id: '/view'
path: '/view'
fullPath: '/view'
preLoaderRoute: typeof ViewRouteImport
parentRoute: typeof rootRouteImport
}
'/console': {
id: '/console'
path: '/console'
fullPath: '/console'
preLoaderRoute: typeof ConsoleRouteImport
parentRoute: typeof rootRouteImport
}
'/$id': {
id: '/$id'
path: '/$id'
fullPath: '/$id'
preLoaderRoute: typeof IdRouteImport
parentRoute: typeof rootRouteImport
}
'/': {
id: '/'
path: '/'
@@ -53,6 +104,9 @@ declare module '@tanstack/react-router' {
const rootRouteChildren: RootRouteChildren = {
IndexRoute: IndexRoute,
IdRoute: IdRoute,
ConsoleRoute: ConsoleRoute,
ViewRoute: ViewRoute,
}
export const routeTree = rootRouteImport
._addFileChildren(rootRouteChildren)