MCPcopy Create free account
hub / github.com/bytebase/bytebase / useIsDisconnected

Function useIsDisconnected

frontend/src/react/stores/sqlEditor/tab.ts:631–636  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

629 * `true` when the current tab has no valid database connection.
630 */
631export const useIsDisconnected = (): boolean =>
632 useSQLEditorTabsStore((s) => {
633 const tab = s.tabsById.get(s.currentTabId);
634 if (!tab) return true;
635 return !isConnectedSQLEditorTab(tab);
636 });
637
638/**
639 * Batch query mode flags. Derived from current tab + feature gates.

Callers 8

AdminModeButtonFunction · 0.90
OpenAIButtonFunction · 0.90
SQLEditorHomePageFunction · 0.90
EditorActionFunction · 0.90
AsidePanelFunction · 0.90
TerminalPanelFunction · 0.90
StandardPanelFunction · 0.90
EditorMainFunction · 0.90

Calls 2

isConnectedSQLEditorTabFunction · 0.90
getMethod · 0.45

Tested by

no test coverage detected