Commit 22303139 authored by chen shuai's avatar chen shuai

bugfix: fix SettingDrawer style error

parent 81ff030b
import React, { PureComponent } from 'react';
import React, { Component } from 'react';
import { Select, message, Drawer, List, Switch, Divider, Icon, Button, Alert, Tooltip } from 'antd';
import { formatMessage } from 'umi/locale';
import { CopyToClipboard } from 'react-copy-to-clipboard';
......@@ -23,7 +23,7 @@ const Body = ({ children, title, style }) => (
);
@connect(({ setting }) => ({ setting }))
class SettingDrawer extends PureComponent {
class SettingDrawer extends Component {
state = {
collapse: false,
};
......@@ -207,17 +207,22 @@ class SettingDrawer extends PureComponent {
<Divider />
<Body title={formatMessage({ id: 'app.setting.othersettings' })}>
<List.Item
actions={[
<List
split={false}
renderItem={this.renderLayoutSettingItem}
dataSource={[
{
title: formatMessage({ id: 'app.setting.weakmode' }),
action: (
<Switch
size="small"
checked={!!colorWeak}
onChange={checked => this.changeSetting('colorWeak', checked)}
/>,
/>
),
},
]}
>
{formatMessage({ id: 'app.setting.weakmode' })}
</List.Item>
/>
</Body>
<Divider />
<CopyToClipboard
......
......@@ -4,6 +4,13 @@
position: relative;
min-height: 100%;
background: #fff;
:global {
.ant-list-item {
span {
flex: 1;
}
}
}
}
.blockChecbox {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment