fix: type hiint dispatch stateupdater

This commit is contained in:
2024-10-14 17:22:57 +08:00
parent 6df6ad031a
commit f5d43ec4b9
4 changed files with 8 additions and 8 deletions

View File

@@ -1,5 +1,5 @@
import { createRef } from "preact";
import { StateUpdater, useContext, useEffect, useState } from "preact/hooks";
import { StateUpdater, useContext, useEffect, useState, Dispatch } from "preact/hooks";
import {
ChatStore,
TemplateAPI,
@@ -414,7 +414,7 @@ const Choice = (props: {
export default (props: {
chatStore: ChatStore;
setChatStore: (cs: ChatStore) => void;
setShow: StateUpdater<boolean>;
setShow: Dispatch<StateUpdater<boolean>>;
selectedChatStoreIndex: number;
templates: TemplateChatStore[];
setTemplates: (templates: TemplateChatStore[]) => void;