index.jsx 716 Bytes
Newer Older
wuhao's avatar
wuhao committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
import InitForm from "../InitForm";
import { Drawer } from "antd";
import React, { useState, memo } from "react";

// title="Basic Drawer"
// placement="right"
// closable={false}
// onClose={this.onClose}
// visible={this.state.visible}
// getContainer={false}
// style={{ position: 'absolute' }}

function DrawInitForm(props) {
  let newProps = { ...props };
  delete newProps.children;
  return (
    <Drawer
      maskClosable={false}
      placement="right"
      closable={true}
      getContainer={false}
wuhao's avatar
wuhao committed
22
      style={{ position: "absolute",transform:"translateX(0)" }}
wuhao's avatar
wuhao committed
23 24 25 26 27 28 29 30 31
      {...props}
    >
      {props.children}
      <InitForm {...newProps}></InitForm>
    </Drawer>
  );
}

export default DrawInitForm;