<commit_before>---
order: 0
title:
  zh-CN: 对象编辑
  en-US: From drawer
---

## zh-CN

用于承载编辑相关操作，需要点击关闭按钮关闭。

## en-US

sed to carry edit related operations, need to close by clicking the close button.

```jsx
import { Drawer, Form, Button, Col, Row, Input, Select, DatePicker } from 'antd';

const { Option } = Select;

class App extends React.Component {
  state = { visible: false };
  showDrawer = () => {
    this.setState({
      visible: !this.state.visible,
    });
  };
  onClose = () => {
    this.setState({
      visible: false,
    });
  };
  render() {
    const { getFieldDecorator } = this.props.form;
    return (
      <div>
        <Button type="primary" onClick={this.showDrawer}><commit_msg>Modify drawer description<commit_after>---
order: 0
title:
  zh-CN: 对象编辑
  en-US: Edit item in drawer
---

## zh-CN

用于承载编辑相关操作，需要点击关闭按钮关闭。

## en-US

A drawer containing an editable form which needs to be collapsed by clicking the close button.

```jsx
import { Drawer, Form, Button, Col, Row, Input, Select, DatePicker } from 'antd';

const { Option } = Select;

class App extends React.Component {
  state = { visible: false };
  showDrawer = () => {
    this.setState({
      visible: !this.state.visible,
    });
  };
  onClose = () => {
    this.setState({
      visible: false,
    });
  };
  render() {
    const { getFieldDecorator } = this.props.form;
    return (
      <div>
        <Button type="primary" onClick={this.showDrawer}>
{'fraction_non_alphanumeric': 0.1463917525773196, 'fraction_numerical': 0.0013745704467353953, 'mean_word_length': 2.8620689655172415, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 11, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1350551', 'n_tokens_mistral': 524, 'n_tokens_neox': 545, 'n_words': 135}