Просмотр исходного кода

Merge pull request #2909 from weseek/imprv/article-area-gw4053

Imprv/article area gw4053
Yuki Takei 5 лет назад
Родитель
Сommit
bb9d8575c7

+ 8 - 0
src/client/js/components/NotFoundPage.jsx

@@ -2,8 +2,10 @@ import React from 'react';
 import PropTypes from 'prop-types';
 import { withTranslation } from 'react-i18next';
 import PageListIcon from './Icons/PageListIcon';
+import TimeLineIcon from './Icons/TimeLineIcon';
 import CustomNavigation from './CustomNavigation';
 import PageList from './PageList';
+import PageTimeline from './PageTimeline';
 
 
 const NotFoundPage = (props) => {
@@ -16,6 +18,12 @@ const NotFoundPage = (props) => {
       tabContent: <PageList />,
       index: 0,
     },
+    timeLine: {
+      icon: <TimeLineIcon />,
+      i18n: t('Timeline View'),
+      tabContent: <PageTimeline />,
+      index: 1,
+    },
   };
 
   return (

+ 1 - 1
src/client/js/components/PageTimeline.jsx

@@ -62,7 +62,7 @@ class PageTimeline extends React.Component {
 
   render() {
     const { pages } = this.state;
-    if (pages == null) {
+    if (pages == null || pages.length === 0) {
       return <React.Fragment></React.Fragment>;
     }