mirror of
https://github.com/DeNNiiInc/dbgate.git
synced 2026-04-20 17:06:01 +00:00
recently closed tabs
This commit is contained in:
@@ -76,7 +76,7 @@ export default function QueryTab({
|
||||
...other
|
||||
}) {
|
||||
const loadingText = 'Loading SQL template...';
|
||||
const localStorageKey = storageKey || `sql_${tabid}`;
|
||||
const localStorageKey = storageKey || `tabdata_sql_${tabid}`;
|
||||
const { sqlTemplate } = initialArgs || {};
|
||||
const [queryText, setQueryText] = React.useState(
|
||||
() => localStorage.getItem(localStorageKey) || initialScript || (sqlTemplate ? loadingText : '')
|
||||
|
||||
@@ -33,7 +33,7 @@ export default function ShellTab({
|
||||
storageKey,
|
||||
...other
|
||||
}) {
|
||||
const localStorageKey = storageKey || `shell_${tabid}`;
|
||||
const localStorageKey = storageKey || `tabdata_shell_${tabid}`;
|
||||
const [shellText, setShellText] = React.useState(() => localStorage.getItem(localStorageKey) || initialScript || '');
|
||||
const shellTextRef = React.useRef(shellText);
|
||||
const [busy, setBusy] = React.useState(false);
|
||||
|
||||
Reference in New Issue
Block a user