Sfoglia il codice sorgente

单词表取前八个

visuddhinanda 2 anni fa
parent
commit
d2d559b5d6
1 ha cambiato i file con 1 aggiunte e 0 eliminazioni
  1. 1 0
      dashboard/src/components/dict/SearchVocabulary.tsx

+ 1 - 0
dashboard/src/components/dict/SearchVocabulary.tsx

@@ -115,6 +115,7 @@ const SearchVocabularyWidget = ({
             };
           })
           .sort((a, b) => b.weight - a.weight)
+          .slice(0, 7)
           .map((item) => {
             return renderItem(item.word, item.count, item.meaning);
           });