mirror of https://github.com/openspug/spug
U 优化样式问题
parent
da19a6981e
commit
411bbc2c57
|
@ -15,6 +15,7 @@ export default function (props) {
|
||||||
theme="tomorrow"
|
theme="tomorrow"
|
||||||
fontSize={13}
|
fontSize={13}
|
||||||
tabSize={2}
|
tabSize={2}
|
||||||
|
style={{fontFamily: 'source-code-pro, Menlo, Monaco, Consolas, PingFang SC, Microsoft YaHei'}}
|
||||||
{...props}
|
{...props}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
|
|
|
@ -2,16 +2,23 @@
|
||||||
|
|
||||||
body {
|
body {
|
||||||
margin: 0;
|
margin: 0;
|
||||||
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Roboto", "Oxygen",
|
font-family: -apple-system, BlinkMacSystemFont, Helvetica Neue, PingFang SC, Microsoft YaHei, Source Han Sans SC, Noto Sans CJK SC, WenQuanYi Micro Hei, sans-serif;
|
||||||
"Ubuntu", "Cantarell", "Fira Sans", "Droid Sans", "Helvetica Neue",
|
|
||||||
sans-serif;
|
|
||||||
-webkit-font-smoothing: antialiased;
|
-webkit-font-smoothing: antialiased;
|
||||||
-moz-osx-font-smoothing: grayscale;
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
|
||||||
|
div::-webkit-scrollbar, textarea::-webkit-scrollbar {
|
||||||
|
width: 6px;
|
||||||
|
}
|
||||||
|
|
||||||
|
div::-webkit-scrollbar-thumb, textarea::-webkit-scrollbar-thumb {
|
||||||
|
border-radius: 6px;
|
||||||
|
background: rgba(0, 0, 0, .2);
|
||||||
}
|
}
|
||||||
|
|
||||||
code {
|
code {
|
||||||
font-family: source-code-pro, Menlo, Monaco, Consolas, "Courier New",
|
font-family: source-code-pro, Menlo, Monaco, Consolas, Courier New, monospace, PingFang SC, Microsoft YaHei;
|
||||||
monospace;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Common CSS style */
|
/* Common CSS style */
|
||||||
|
|
|
@ -74,6 +74,10 @@
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.content::-webkit-scrollbar {
|
||||||
|
width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
.sider {
|
.sider {
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 208px;
|
width: 208px;
|
||||||
|
@ -83,7 +87,10 @@
|
||||||
|
|
||||||
.menus {
|
.menus {
|
||||||
overflow: auto;
|
overflow: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
.menus::-webkit-scrollbar {
|
||||||
|
width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
|
|
|
@ -91,7 +91,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}
|
}}
|
||||||
|
|
|
@ -50,7 +50,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -72,7 +72,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -59,7 +59,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -54,7 +54,6 @@ function ComTable() {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -55,7 +55,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -35,7 +35,7 @@ export default function () {
|
||||||
{ip !== null && <Tag closable color="#1890ff" onClose={() => setIp(null)}>{ip}</Tag>}
|
{ip !== null && <Tag closable color="#1890ff" onClose={() => setIp(null)}>{ip}</Tag>}
|
||||||
</div>
|
</div>
|
||||||
)}>
|
)}>
|
||||||
<List style={{height: 329, overflow: 'scroll'}} dataSource={dataSource} renderItem={item => (
|
<List className={styles.loginActive} dataSource={dataSource} renderItem={item => (
|
||||||
<List.Item>
|
<List.Item>
|
||||||
<span>{item.created_at}</span>
|
<span>{item.created_at}</span>
|
||||||
<span className={styles.spanText} onClick={() => setName(item.nickname)}>{item.nickname}</span>
|
<span className={styles.spanText} onClick={() => setName(item.nickname)}>{item.nickname}</span>
|
||||||
|
|
|
@ -23,3 +23,8 @@
|
||||||
color: #1890ff;
|
color: #1890ff;
|
||||||
padding: 0 4px;
|
padding: 0 4px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.loginActive {
|
||||||
|
height: 329px;
|
||||||
|
overflow: auto;
|
||||||
|
}
|
|
@ -135,7 +135,6 @@ function ComTable() {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -71,6 +71,7 @@ export default observer(function Console() {
|
||||||
function initialTerm() {
|
function initialTerm() {
|
||||||
const fitPlugin = new FitAddon()
|
const fitPlugin = new FitAddon()
|
||||||
term.loadAddon(fitPlugin)
|
term.loadAddon(fitPlugin)
|
||||||
|
term.setOption('fontFamily', 'source-code-pro, Menlo, Monaco, Consolas, PingFang SC, Microsoft YaHei')
|
||||||
term.setOption('theme', {background: '#fafafa', foreground: '#000', selection: '#999'})
|
term.setOption('theme', {background: '#fafafa', foreground: '#000', selection: '#999'})
|
||||||
term.open(el.current)
|
term.open(el.current)
|
||||||
term.fit = () => fitPlugin.fit()
|
term.fit = () => fitPlugin.fit()
|
||||||
|
|
|
@ -81,7 +81,6 @@ function ComTable() {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -14,6 +14,7 @@ function OutView(props) {
|
||||||
setTimeout(() => {
|
setTimeout(() => {
|
||||||
const fitPlugin = new FitAddon()
|
const fitPlugin = new FitAddon()
|
||||||
const term = new Terminal({disableStdin: true})
|
const term = new Terminal({disableStdin: true})
|
||||||
|
term.setOption('fontFamily', 'source-code-pro, Menlo, Monaco, Consolas, PingFang SC, Microsoft YaHei')
|
||||||
term.loadAddon(fitPlugin)
|
term.loadAddon(fitPlugin)
|
||||||
term.setOption('theme', {background: '#fff', foreground: '#000', selection: '#999'})
|
term.setOption('theme', {background: '#fff', foreground: '#000', selection: '#999'})
|
||||||
term.open(el.current)
|
term.open(el.current)
|
||||||
|
|
|
@ -179,7 +179,6 @@ function ComTable() {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}/>
|
}}/>
|
||||||
|
|
|
@ -31,6 +31,7 @@ function OutView(props) {
|
||||||
gCurrent = current
|
gCurrent = current
|
||||||
const fitPlugin = new FitAddon()
|
const fitPlugin = new FitAddon()
|
||||||
term.setOption('disableStdin', false)
|
term.setOption('disableStdin', false)
|
||||||
|
term.setOption('fontFamily', 'source-code-pro, Menlo, Monaco, Consolas, PingFang SC, Microsoft YaHei')
|
||||||
term.setOption('theme', {background: '#f0f0f0', foreground: '#000', selection: '#999', cursor: '#f0f0f0'})
|
term.setOption('theme', {background: '#f0f0f0', foreground: '#000', selection: '#999', cursor: '#f0f0f0'})
|
||||||
term.loadAddon(fitPlugin)
|
term.loadAddon(fitPlugin)
|
||||||
term.open(el.current)
|
term.open(el.current)
|
||||||
|
|
|
@ -57,7 +57,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -166,7 +166,7 @@ export default observer(function () {
|
||||||
onChange={setDraggable}
|
onChange={setDraggable}
|
||||||
checkedChildren="排版"
|
checkedChildren="排版"
|
||||||
unCheckedChildren="浏览"/>
|
unCheckedChildren="浏览"/>
|
||||||
<Tooltip title="右键点击分组进行编辑,开启排版模式后可通过拖拽分组进行快速排序。">
|
<Tooltip title="排版模式下,可通过拖拽分组实现快速排序。">
|
||||||
<QuestionCircleOutlined style={{marginLeft: 8, color: '#999'}}/>
|
<QuestionCircleOutlined style={{marginLeft: 8, color: '#999'}}/>
|
||||||
</Tooltip>
|
</Tooltip>
|
||||||
</AuthFragment>)}>
|
</AuthFragment>)}>
|
||||||
|
|
|
@ -69,7 +69,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}>
|
}}>
|
||||||
|
|
|
@ -145,7 +145,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}
|
}}
|
||||||
|
|
|
@ -18,6 +18,7 @@ function WebSSH(props) {
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const fitPlugin = new FitAddon();
|
const fitPlugin = new FitAddon();
|
||||||
term.loadAddon(fitPlugin);
|
term.loadAddon(fitPlugin);
|
||||||
|
term.setOption('fontFamily', 'source-code-pro, Menlo, Monaco, Consolas, PingFang SC, Microsoft YaHei')
|
||||||
term.open(container.current);
|
term.open(container.current);
|
||||||
term.write('WebSocket connecting ... ');
|
term.write('WebSocket connecting ... ');
|
||||||
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
|
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
|
||||||
|
|
|
@ -112,7 +112,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}
|
}}
|
||||||
|
|
|
@ -56,14 +56,7 @@ export default observer(function () {
|
||||||
confirmLoading={loading}
|
confirmLoading={loading}
|
||||||
onOk={handleSubmit}>
|
onOk={handleSubmit}>
|
||||||
<Form layout="vertical">
|
<Form layout="vertical">
|
||||||
<Form.Item label={
|
<Form.Item label="授权访问主机组" tooltip="主机权限将全局影响属于该角色的用户能够看到的主机。">
|
||||||
<span>
|
|
||||||
授权访问主机组
|
|
||||||
<Tooltip title="主机权限将全局影响属于该角色的用户能够看到的主机。">
|
|
||||||
<QuestionCircleOutlined/>
|
|
||||||
</Tooltip>
|
|
||||||
</span>
|
|
||||||
}>
|
|
||||||
{groups.map((id, index) => (
|
{groups.map((id, index) => (
|
||||||
<div className={styles.groupItem} key={index}>
|
<div className={styles.groupItem} key={index}>
|
||||||
<TreeSelect
|
<TreeSelect
|
||||||
|
|
|
@ -69,7 +69,6 @@ class ComTable extends React.Component {
|
||||||
pagination={{
|
pagination={{
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
showLessItems: true,
|
showLessItems: true,
|
||||||
hideOnSinglePage: true,
|
|
||||||
showTotal: total => `共 ${total} 条`,
|
showTotal: total => `共 ${total} 条`,
|
||||||
pageSizeOptions: ['10', '20', '50', '100']
|
pageSizeOptions: ['10', '20', '50', '100']
|
||||||
}}
|
}}
|
||||||
|
|
Loading…
Reference in New Issue