feat(client): menu styling
This commit is contained in:
parent
4faf19d8eb
commit
97ad82fcdc
@ -34,7 +34,18 @@ const InternalAdminLayout = (props: any) => {
|
|||||||
const result = useSystemSettings();
|
const result = useSystemSettings();
|
||||||
return (
|
return (
|
||||||
<Layout>
|
<Layout>
|
||||||
<Layout.Header style={{ height: 46, lineHeight: '46px', position: 'relative', paddingLeft: 0 }}>
|
<Layout.Header
|
||||||
|
className={css`
|
||||||
|
.ant-menu.ant-menu-dark .ant-menu-item-selected,
|
||||||
|
.ant-menu-submenu-popup.ant-menu-dark .ant-menu-item-selected {
|
||||||
|
background-color: rgba(255, 255, 255, 0.1);
|
||||||
|
}
|
||||||
|
.ant-menu-dark.ant-menu-horizontal > .ant-menu-item:hover {
|
||||||
|
background-color: rgba(255, 255, 255, 0.1);
|
||||||
|
}
|
||||||
|
`}
|
||||||
|
style={{ height: 46, lineHeight: '46px', position: 'relative', paddingLeft: 0 }}
|
||||||
|
>
|
||||||
<div style={{ display: 'flex', height: '100%' }}>
|
<div style={{ display: 'flex', height: '100%' }}>
|
||||||
<div style={{ width: 200, display: 'inline-flex', color: '#fff', padding: '0', alignItems: 'center' }}>
|
<div style={{ width: 200, display: 'inline-flex', color: '#fff', padding: '0', alignItems: 'center' }}>
|
||||||
<img
|
<img
|
||||||
|
@ -1,17 +1,20 @@
|
|||||||
import React from 'react';
|
|
||||||
import { Button, Menu } from 'antd';
|
|
||||||
import { HighlightOutlined } from '@ant-design/icons';
|
import { HighlightOutlined } from '@ant-design/icons';
|
||||||
import cls from 'classnames';
|
import React from 'react';
|
||||||
import { useDesignable } from '..';
|
import { useDesignable } from '..';
|
||||||
import { PluginManager } from '../../plugin-manager';
|
import { PluginManager } from '../../plugin-manager';
|
||||||
|
|
||||||
export const DesignableSwitch = () => {
|
export const DesignableSwitch = () => {
|
||||||
const { designable, setDesignable } = useDesignable();
|
const { designable, setDesignable } = useDesignable();
|
||||||
|
const style = {};
|
||||||
|
if (designable) {
|
||||||
|
style['backgroundColor'] = '#f18b62';
|
||||||
|
}
|
||||||
return (
|
return (
|
||||||
<PluginManager.Toolbar.Item
|
<PluginManager.Toolbar.Item
|
||||||
selected={designable}
|
selected={designable}
|
||||||
icon={<HighlightOutlined />}
|
icon={<HighlightOutlined />}
|
||||||
title={'界面配置'}
|
title={'界面配置'}
|
||||||
|
style={style}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
setDesignable(!designable);
|
setDesignable(!designable);
|
||||||
}}
|
}}
|
||||||
|
Loading…
Reference in New Issue
Block a user