This repository was archived by the owner on Nov 16, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +40
-1
lines changed
pages/Components/CodeDemo Expand file tree Collapse file tree 2 files changed +40
-1
lines changed Original file line number Diff line number Diff line change 1+ import React from "react";
2+ import DemoWithCode from "@material-docs/core /components/DemoWithCode";
3+
4+ function Component () {
5+ return (
6+ <div style={{padding: 30}}>
7+ I am a test component
8+ <br />
9+ <br />
10+ And I displayed in 2 DemoWithCode blocks.
11+ </div >
12+ );
13+ }
14+
15+ const code = `
16+ function Component () {
17+ return (
18+ <div style={{padding: 30}}>
19+ I am a test component
20+ <br />
21+ <br />
22+ And I displayed in 2 DemoWithCode blocks.
23+ </div >
24+ );
25+ }
26+ `.trim();
27+
28+ export default function DemoWithCodeExample() {
29+ return (
30+ <DemoWithCode
31+ name={"I am a DemoWithCode component"}
32+ theme={"darcula"}
33+ code={code}
34+ paperContainer
35+ >
36+ <Component />
37+ </DemoWithCode >
38+ );
39+ }
Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ import ExpansionCodeExample from "../../../examples/Code/ExpansionCodeExample";
2323
2424import { TaggingContext } from "@material-docs/core/hooks/useTags"
2525
26- import demoWithCodeCode from "../../../examples/Code/expansionCodeExample .md" ;
26+ import demoWithCodeCode from "../../../examples/Code/demoWithCodeExampleCode .md" ;
2727import DemoWithCodeExample from "../../../examples/Code/DemoWithCodeExpample" ;
2828import H2 from "@material-docs/core/components/H2" ;
2929
You can’t perform that action at this time.
0 commit comments