U 优化文件管理器样式

pull/467/head
vapao 2022-04-02 00:06:49 +08:00
parent 56b7a3e46d
commit 96521a5ef1
3 changed files with 95 additions and 83 deletions

View File

@ -28,6 +28,8 @@ class SSH:
'password': password, 'password': password,
'pkey': RSAKey.from_private_key(StringIO(pkey)) if isinstance(pkey, str) else pkey, 'pkey': RSAKey.from_private_key(StringIO(pkey)) if isinstance(pkey, str) else pkey,
'timeout': connect_timeout, 'timeout': connect_timeout,
'allow_agent': False,
'look_for_keys': False,
'banner_timeout': 30 'banner_timeout': 30
} }

View File

@ -70,8 +70,9 @@ class FileManager extends React.Component {
key: 'action', key: 'action',
render: info => info.kind === '-' ? ( render: info => info.kind === '-' ? (
<Action> <Action>
<Action.Button icon={<DownloadOutlined/>} onClick={() => this.handleDownload(info.name)}/> <Action.Button className={styles.drawerBtn} icon={<DownloadOutlined/>}
<Action.Button auth="host.console.del" danger icon={<DeleteOutlined/>} onClick={() => this.handleDownload(info.name)}/>
<Action.Button danger auth="host.console.del" className={styles.drawerBtn} icon={<DeleteOutlined/>}
onClick={() => this.handleDelete(info.name)}/> onClick={() => this.handleDelete(info.name)}/>
</Action> </Action>
) : null ) : null

View File

@ -23,16 +23,19 @@
justify-content: center; justify-content: center;
align-items: center; align-items: center;
background-color: #f0f0f0; background-color: #f0f0f0;
img { img {
height: 30px; height: 30px;
} }
} }
.hosts { .hosts {
:global(.ant-tree-node-content-wrapper) { :global(.ant-tree-node-content-wrapper) {
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
white-space: nowrap; white-space: nowrap;
} }
:global(.ant-tree) { :global(.ant-tree) {
background-color: #fafafa; background-color: #fafafa;
height: calc(100vh - 98px); height: calc(100vh - 98px);
@ -45,6 +48,7 @@
} }
} }
} }
.content { .content {
flex: 1; flex: 1;
display: flex; display: flex;
@ -58,6 +62,12 @@
color: #666; color: #666;
} }
.tabRender {
user-select: none;
padding: 8px 8px 8px 16px;
margin: 0 -8px 0 -16px;
}
:global(.ant-tabs-nav) { :global(.ant-tabs-nav) {
height: 42px; height: 42px;
margin: 0; margin: 0;
@ -98,8 +108,7 @@
margin-bottom: 15px; margin-bottom: 15px;
} }
.tabRender { .drawerBtn {
user-select: none; height: 22px;
padding: 8px 8px 8px 16px; width: 22px;
margin: 0 -8px 0 -16px;
} }