Skip to content

Commit

Permalink
refactor: 项目代码重构,包括 examples、extension 及 core 包
Browse files Browse the repository at this point in the history
 - remove react-umi-app demo
 - rename lf-engine-browser -> engine-browser-examples
 - rename lf-engine-node -> engine-node-examples
 - extension 包中修改文件夹名大小写未生效,恢复成 Control 和 Node 文件夹,后续再处理
  • Loading branch information
boyongjiong committed May 10, 2024
1 parent 2fe5eb8 commit 6be5a2c
Show file tree
Hide file tree
Showing 234 changed files with 1,114 additions and 5,466 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import LogicFlow from '@logicflow/core';
import '@logicflow/core/es/index.css';
import LogicFlow from '@logicflow/core'
import '@logicflow/core/es/index.css'

import { Card } from 'antd';
import { useEffect, useRef } from 'react';
import styles from './index.less';
import { Card } from 'antd'
import { useEffect, useRef } from 'react'
import styles from './index.less'

const config: Partial<LogicFlow.Options> = {
isSilentMode: false,
Expand Down Expand Up @@ -36,7 +36,7 @@ const config: Partial<LogicFlow.Options> = {
fontSize: 12,
},
},
};
}

const data = {
nodes: [
Expand Down Expand Up @@ -90,11 +90,11 @@ const data = {
text: 'html节点',
},
],
};
}

export default function BasicNode() {
const lfRef = useRef<LogicFlow>();
const containerRef = useRef<HTMLDivElement>(null);
const lfRef = useRef<LogicFlow>()
const containerRef = useRef<HTMLDivElement>(null)
useEffect(() => {
if (!lfRef.current) {
const lf = new LogicFlow({
Expand All @@ -104,16 +104,16 @@ export default function BasicNode() {
grid: {
size: 10,
},
});
})

lf.render(data);
lfRef.current = lf;
lf.render(data)
lfRef.current = lf
}
}, []);
}, [])

return (
<Card title="内置基础节点">
<div ref={containerRef} id="graph" className={styles.viewport}></div>
</Card>
);
)
}
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const MainRoutes = {
path: 'nodes',
children: [
{
path: 'native-node',
path: 'NativeNodes',
element: <NativeNode />
}
]
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 0 additions & 3 deletions examples/react-umi-app/.eslintrc.js

This file was deleted.

13 changes: 0 additions & 13 deletions examples/react-umi-app/.gitignore

This file was deleted.

17 changes: 0 additions & 17 deletions examples/react-umi-app/.lintstagedrc

This file was deleted.

3 changes: 0 additions & 3 deletions examples/react-umi-app/.prettierignore

This file was deleted.

8 changes: 0 additions & 8 deletions examples/react-umi-app/.prettierrc

This file was deleted.

3 changes: 0 additions & 3 deletions examples/react-umi-app/.stylelintrc.js

This file was deleted.

96 changes: 0 additions & 96 deletions examples/react-umi-app/.umirc.ts

This file was deleted.

3 changes: 0 additions & 3 deletions examples/react-umi-app/README.md

This file was deleted.

20 changes: 0 additions & 20 deletions examples/react-umi-app/mock/userAPI.ts

This file was deleted.

30 changes: 0 additions & 30 deletions examples/react-umi-app/package.json

This file was deleted.

9 changes: 0 additions & 9 deletions examples/react-umi-app/src/.umi/core/EmptyRoute.tsx

This file was deleted.

20 changes: 0 additions & 20 deletions examples/react-umi-app/src/.umi/core/defineApp.ts

This file was deleted.

10 changes: 0 additions & 10 deletions examples/react-umi-app/src/.umi/core/helmet.ts

This file was deleted.

4 changes: 0 additions & 4 deletions examples/react-umi-app/src/.umi/core/helmetContext.ts

This file was deleted.

66 changes: 0 additions & 66 deletions examples/react-umi-app/src/.umi/core/history.ts

This file was deleted.

Loading

0 comments on commit 6be5a2c

Please sign in to comment.