import { Ref } from 'vue'; import { Command, EditorState } from '../command/types'; import { Translator } from '../i18n'; import { EditorController } from './controller'; import { ModelId } from '../core/types'; /** 이 축이 팩토리 클로저에서 쓰는 것 전부. 늘어나면 여기 선언이 먼저 늘어난다(= 의존 인벤토리). */ export interface EntityContext { /** 편집 대상 reactive 상태(속성만 교체되므로 참조 안정). */ state: EditorState; /** 조회 모드 판정 — `addEntity`가 `null`을 돌려주려면 run()의 no-op 백스톱보다 앞에서 봐야 한다. */ editable: Ref; /** 모델 변경의 단일 실행점(조회 모드 no-op + 안내). */ run: (c: Command) => void; /** 잠금 게이트 — 차단 시 true + 안내 emit(사용자 intent 경로). */ gateEntityLocked: (id: ModelId) => boolean; /** 순수 잠금 조회 — 공개 질의의 위임 대상. **안내를 내지 않는다**(위 ⚠️ 참고). */ isEntityLockedFn: (id: ModelId) => boolean; isAssocLockedFn: (assocId: ModelId) => boolean; /** 번역 — 아래 구조 차단의 이유 안내에 쓴다(속성 축의 FK 삭제 안내와 같은 짝). */ t: Translator; /** 구조 차단 안내(dedup 경로) — 무음 차단은 "고장"으로 읽힌다(VE-2 규율). */ emitGateNotice: (text: string) => void; } export declare function createEntityApi(ctx: EntityContext): Pick;