Skip to content

Commit 50d44f7

Browse files
example
1 parent 3fd02b8 commit 50d44f7

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

ui/react-example/src/components/MainContentDiffExampleCode.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@ const getCode = ({ theme, type }: { theme: "light" | "dark"; type: "react" | "vu
1111
import { generateDiffFile } from "@git-diff-view/file";
1212
import "@git-diff-view/react/styles/diff-view.css";
1313
14-
// git mode
14+
// git mode, use \`git diff\` output to render
1515
const getDiffFile = () => {
1616
// see https://git-scm.com/docs/git-diff
1717
const instance = new DiffFile(oldFileName, oldContent, newFileName, newContent, [ git diff output string ]);
1818
instance.initRaw();
1919
return instance;
2020
}
2121
22-
// file mode
22+
// file mode, use \`string content\` to render
2323
const getDiffFile = () => {
2424
const instance = generateDiffFile(oldFileName, oldContent, newFileName, newContent, '', '');
2525
instance.initRaw();
@@ -36,15 +36,15 @@ const App = () => {
3636
import { generateDiffFile } from "@git-diff-view/file";
3737
import "@git-diff-view/vue/styles/diff-view.css";
3838
39-
// git mode
39+
// git mode, use \`git diff\` output to render
4040
const getDiffFile = () => {
4141
// see https://git-scm.com/docs/git-diff
4242
const instance = new DiffFile(oldFileName, oldContent, newFileName, newContent, [ git diff output string ]);
4343
instance.initRaw();
4444
return instance;
4545
}
4646
47-
// file mode
47+
// file mode, use \`string content\` to render
4848
const getDiffFile = () => {
4949
const instance = generateDiffFile(oldFileName, oldContent, newFileName, newContent, '', '');
5050
instance.initRaw();

ui/vue-example/src/App.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ const resetV = () => (v.value = "");
110110
</button>
111111
</div>
112112
</div>
113-
<div class="m-auto mb-[5em] w-[90%] overflow-hidden rounded-[5px] border border-solid border-[#c1c1c1]">
113+
<div class="m-auto mb-[5em] w-[90%] overflow-hidden rounded-[5px] border border-solid border-[#e1e1e1]">
114114
<DiffView
115115
:diff-file="diffFile"
116116
:diff-view-font-size="14"

0 commit comments

Comments
 (0)