Skip to content

@advjs/monorepo / @advjs/client / useAdvStore

Variable: useAdvStore

const useAdvStore: StoreDefinition<"adv", Pick<{ ast: ShallowRef<Root, Root>; cur: Ref<{ background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: "text"; value: string; } | { type: "link"; value: string; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }, CurStateType | { background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: ...; value: ...; } | { type: ...; value: ...; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }>; curChapter: Ref<undefined | AdvChapter, undefined | AdvChapter>; curFlowNode: Ref<{ id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }, AdvFlowNode | { id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }>; curNode: ComputedRef<undefined | Item | AdvFlowNode>; status: { isEnd: ComputedRef<boolean>; }; }, "status" | "ast" | "curFlowNode" | "curChapter" | "cur">, Pick<{ ast: ShallowRef<Root, Root>; cur: Ref<{ background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: "text"; value: string; } | { type: "link"; value: string; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }, CurStateType | { background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: ...; value: ...; } | { type: ...; value: ...; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }>; curChapter: Ref<undefined | AdvChapter, undefined | AdvChapter>; curFlowNode: Ref<{ id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }, AdvFlowNode | { id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }>; curNode: ComputedRef<undefined | Item | AdvFlowNode>; status: { isEnd: ComputedRef<boolean>; }; }, "curNode">, Pick<{ ast: ShallowRef<Root, Root>; cur: Ref<{ background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: "text"; value: string; } | { type: "link"; value: string; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }, CurStateType | { background: string; dialog: { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { character: { name: string; status?: string; type: "character"; }; children: ({ type: ...; value: ...; } | { type: ...; value: ...; })[]; type: "dialog"; }; order: number; tachies: Map<string, { status: string; }> & Omit<Map<string, { status: string; }>, keyof Map<any, any>>; }>; curChapter: Ref<undefined | AdvChapter, undefined | AdvChapter>; curFlowNode: Ref<{ id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }, AdvFlowNode | { id: string; name: string; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "background"; } | { action: "enter" | "exit"; enter?: string | string[]; exit?: string | string[]; id: string; name: string; status: string; target?: string | { chapterId: string; nodeId: string; }; type: "tachie"; } | { bgmThemeId?: string; dialogues: object[]; id: string; sceneId?: string; target?: string | { chapterId: string; nodeId: string; }; type: "dialogues"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "end"; } | { ast?: { children: ({ type: ...; } | { type: ...; value: ...; } | { data?: ...; lang?: ...; meta?: ...; position?: ...; type: ...; value: ...; } | { choices: ...; default?: ...; type: ...; } | { name: ...; status?: ...; type: ...; } | { text: ...; type: ...; } | { character: ...; children: ...; type: ...; } | { children: ...; type: ...; } | { inOrOut: ...; place: ...; time: ...; type: ...; } | { children: ...; type: ...; })[]; functions: Record<string, string>; scene: Record<string, number>; type: "adv-root"; }; id: string; order?: number; src: string; target?: string | { chapterId: string; nodeId: string; }; type: "fountain"; } | { id: string; target?: string | { chapterId: string; nodeId: string; }; type: "start"; }>; curNode: ComputedRef<undefined | Item | AdvFlowNode>; status: { isEnd: ComputedRef<boolean>; }; }, never>>

Defined in: packages/client/stores/useAdvStore.ts:38