|
@@ -51,9 +51,6 @@ const ArticleViewWidget = ({
|
|
|
remains,
|
|
remains,
|
|
|
onPathChange,
|
|
onPathChange,
|
|
|
}: IWidgetArticleData) => {
|
|
}: IWidgetArticleData) => {
|
|
|
- const [currPath, setCurrPath] = useState(path);
|
|
|
|
|
-
|
|
|
|
|
- useEffect(() => setCurrPath(path), [path]);
|
|
|
|
|
console.log("ArticleViewWidget render");
|
|
console.log("ArticleViewWidget render");
|
|
|
|
|
|
|
|
let currChannelList = <></>;
|
|
let currChannelList = <></>;
|
|
@@ -91,7 +88,7 @@ const ArticleViewWidget = ({
|
|
|
|
|
|
|
|
<Space direction="vertical">
|
|
<Space direction="vertical">
|
|
|
<TocPath
|
|
<TocPath
|
|
|
- data={currPath}
|
|
|
|
|
|
|
+ data={path}
|
|
|
channel={channels}
|
|
channel={channels}
|
|
|
onChange={(
|
|
onChange={(
|
|
|
node: ITocPathNode,
|
|
node: ITocPathNode,
|