31 lines
915 B
TypeScript
31 lines
915 B
TypeScript
|
|
"use client";
|
||
|
|
|
||
|
|
/**
|
||
|
|
* QuerySettingsTab.tsx
|
||
|
|
*
|
||
|
|
* 데이터 연결 탭 — 기존 QueryManager를 모달 탭 안에서 렌더링한다.
|
||
|
|
*
|
||
|
|
* [사용처]
|
||
|
|
* - ComponentSettingsModal의 "데이터 연결" 탭
|
||
|
|
* - QueryManager는 Context에서 직접 queries/setQueries를 구독하므로
|
||
|
|
* 별도 props 없이 그대로 mount하면 동작한다.
|
||
|
|
*
|
||
|
|
* [설계 결정]
|
||
|
|
* - 외부 DB 연결 목록은 QueryManager 내부 useEffect로 로드되므로
|
||
|
|
* 탭을 열 때마다 재조회된다. 빈번한 재마운트를 최소화하려면
|
||
|
|
* Context로 올리는 방향을 검토할 수 있으나, 현재는 단순성 우선.
|
||
|
|
*/
|
||
|
|
|
||
|
|
import { ScrollArea } from "@/components/ui/scroll-area";
|
||
|
|
import { QueryManager } from "../QueryManager";
|
||
|
|
|
||
|
|
export function QuerySettingsTab() {
|
||
|
|
return (
|
||
|
|
<ScrollArea className="h-full">
|
||
|
|
<div className="p-2">
|
||
|
|
<QueryManager />
|
||
|
|
</div>
|
||
|
|
</ScrollArea>
|
||
|
|
);
|
||
|
|
}
|