|
|
@ -116,10 +116,9 @@ export const usePromptStore = create<PromptStore>()(
|
|
|
|
})
|
|
|
|
})
|
|
|
|
.concat([...(state?.prompts?.values() ?? [])]);
|
|
|
|
.concat([...(state?.prompts?.values() ?? [])]);
|
|
|
|
|
|
|
|
|
|
|
|
const allPromptsForSearch = builtinPrompts.reduce(
|
|
|
|
const allPromptsForSearch = builtinPrompts
|
|
|
|
(pre, cur) => pre.concat(cur),
|
|
|
|
.reduce((pre, cur) => pre.concat(cur), [])
|
|
|
|
[],
|
|
|
|
.filter((v) => !!v.title && !!v.content);
|
|
|
|
);
|
|
|
|
|
|
|
|
SearchService.count.builtin = res.en.length + res.cn.length;
|
|
|
|
SearchService.count.builtin = res.en.length + res.cn.length;
|
|
|
|
SearchService.init(allPromptsForSearch);
|
|
|
|
SearchService.init(allPromptsForSearch);
|
|
|
|
});
|
|
|
|
});
|
|
|
|