Ver Fonte

onSearchChange -》onSearch

visuddhinanda há 3 anos atrás
pai
commit
1acb299326
1 ficheiros alterados com 4 adições e 4 exclusões
  1. 4 4
      dashboard/src/components/corpus/ChapterFilter.tsx

+ 4 - 4
dashboard/src/components/corpus/ChapterFilter.tsx

@@ -10,21 +10,21 @@ interface IWidget {
   onTypeChange?: Function;
   onLangChange?: Function;
   onProgressChange?: Function;
-  onSearchChange?: Function;
+  onSearch?: Function;
 }
 const Widget = ({
   onTypeChange,
   onLangChange,
   onProgressChange,
-  onSearchChange,
+  onSearch,
 }: IWidget) => {
   return (
     <Space style={{ margin: 8 }}>
       <Search
         placeholder="标题搜索"
         onSearch={(value: string) => {
-          if (typeof onSearchChange !== "undefined") {
-            onSearchChange(value);
+          if (typeof onSearch !== "undefined") {
+            onSearch(value);
           }
         }}
         style={{ width: 200 }}