feat(website): show source code for examples

This commit is contained in:
moklick
2020-10-12 14:27:36 +02:00
parent eeafad3694
commit ae17b99a0c
25 changed files with 364 additions and 398 deletions
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/CustomConnectionLine';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Custom Connectionline',
slug: 'custom-connectionline',
order: 10,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/CustomNode';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Custom Node',
slug: 'custom-node',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/EdgeTypes';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Edge Types',
slug: 'edge-types',
order: 11,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>{' '}
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Edges';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Edges',
slug: 'edges',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Hidden';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Hidden',
slug: 'hidden',
order: 12,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Horizontal';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Horizontal',
slug: 'horizontal',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Overview';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Overview',
slug: '',
order: 0,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Interaction';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Interaction',
slug: 'interaction',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-18
View File
@@ -1,18 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Provider';
export const frontmatter = {
title: 'Provider',
slug: 'provider',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<Flow />
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Stress';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Stress',
slug: 'stress',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};
-21
View File
@@ -1,21 +0,0 @@
import React from 'react';
import ExamplePage from 'components/Page/Example';
import Flow from 'example-flows/Validation';
import { ReactFlowProvider } from 'react-flow-renderer';
export const frontmatter = {
title: 'Validation',
slug: 'validation',
order: 4,
};
export default () => {
return (
<ExamplePage title={frontmatter.title} slug={frontmatter.slug}>
<ReactFlowProvider>
<Flow />
</ReactFlowProvider>
</ExamplePage>
);
};