Explorar el Código

点目录type=chapter

visuddhinanda hace 2 años
padre
commit
c52b1a818e
Se han modificado 1 ficheros con 3 adiciones y 10 borrados
  1. 3 10
      dashboard/src/components/article/TypePali.tsx

+ 3 - 10
dashboard/src/components/article/TypePali.tsx

@@ -248,16 +248,9 @@ const TypePaliWidget = ({
             ) => {
               let newType = type;
               if (node.level === 0) {
-                switch (type) {
-                  case "article":
-                    newType = "anthology";
-                    break;
-                  case "chapter":
-                    newType = "series";
-                    break;
-                  default:
-                    break;
-                }
+                newType = "series";
+              } else {
+                newType = "chapter";
               }
 
               if (typeof onArticleChange !== "undefined") {