Skip to content

Commit 02c7a61

Browse files
authored
Merge pull request #220 from liuliu-dev/add-diff-view
reset load graph
2 parents cfafade + 412d836 commit 02c7a61

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/stories/GitHubCommitStory.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React, { useState } from "react";
1+
import React, { useEffect, useState } from "react";
22
import css from "./index.module.css";
33
import Graph from "./Graph";
44
import { Diff, GraphStyle } from "../helpers/types";
@@ -40,6 +40,7 @@ function CustomizedGitHubCommitStory(props: CustomizedGitHubCommitStoryProps) {
4040
placeholder="OwnerName"
4141
onChange={e => {
4242
setError("");
43+
setLoadGraph(false);
4344
setOwnerName(e.target.value);
4445
}}
4546
/>
@@ -48,6 +49,7 @@ function CustomizedGitHubCommitStory(props: CustomizedGitHubCommitStoryProps) {
4849
placeholder="RepoName"
4950
onChange={e => {
5051
setError("");
52+
setLoadGraph(false);
5153
setRepoName(e.target.value);
5254
}}
5355
/>

0 commit comments

Comments
 (0)