fix(web): 调整样式
This commit is contained in:
@@ -51,6 +51,7 @@ const FlowableDiv = styled.div`
|
||||
position: absolute;
|
||||
right: 20px;
|
||||
top: 20px;
|
||||
z-index: 10;
|
||||
}
|
||||
|
||||
.node-card {
|
||||
@@ -101,7 +102,7 @@ function FlowEditor() {
|
||||
} = useFlowStore()
|
||||
|
||||
const [currentNodeForm, setCurrentNodeForm] = useState<JSX.Element>()
|
||||
const editNode = (id: string, name: string, description: string, columnSchema?: Schema[]) => {
|
||||
const editNode = (id: string, columnSchema?: Schema[]) => {
|
||||
if (!isNil(columnSchema)) {
|
||||
setCurrentNodeForm(
|
||||
amisRender(
|
||||
@@ -321,13 +322,6 @@ function FlowEditor() {
|
||||
<FlowableDiv>
|
||||
{contextHolder}
|
||||
<Space className="toolbar">
|
||||
<Button type="primary" onClick={() => {
|
||||
let saveData = {nodes, edges, data}
|
||||
console.log(JSON.stringify(saveData, null, 2))
|
||||
}}>
|
||||
<SaveFilled/>
|
||||
保存
|
||||
</Button>
|
||||
<Dropdown
|
||||
menu={{
|
||||
items: nodeDef.map(def => ({key: def.key, label: def.name})),
|
||||
@@ -352,11 +346,18 @@ function FlowEditor() {
|
||||
},
|
||||
}}
|
||||
>
|
||||
<Button type="dashed">
|
||||
<Button type="default">
|
||||
<PlusCircleFilled/>
|
||||
新增节点
|
||||
</Button>
|
||||
</Dropdown>
|
||||
<Button type="primary" onClick={() => {
|
||||
let saveData = {nodes, edges, data}
|
||||
console.log(JSON.stringify(saveData, null, 2))
|
||||
}}>
|
||||
<SaveFilled/>
|
||||
保存
|
||||
</Button>
|
||||
</Space>
|
||||
<Drawer
|
||||
title="节点编辑"
|
||||
|
||||
@@ -92,8 +92,6 @@ const AmisNode = (
|
||||
// @ts-ignore
|
||||
editNode(
|
||||
id,
|
||||
defaultNodeName,
|
||||
defaultNodeDescription,
|
||||
[
|
||||
{
|
||||
type: 'input-text',
|
||||
|
||||
Reference in New Issue
Block a user