mirror of
https://github.com/nocobase/nocobase
synced 2024-11-15 11:56:29 +00:00
feat(client): menu styling
This commit is contained in:
parent
4faf19d8eb
commit
97ad82fcdc
@ -34,7 +34,18 @@ const InternalAdminLayout = (props: any) => {
|
||||
const result = useSystemSettings();
|
||||
return (
|
||||
<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={{ width: 200, display: 'inline-flex', color: '#fff', padding: '0', alignItems: 'center' }}>
|
||||
<img
|
||||
|
@ -1,17 +1,20 @@
|
||||
import React from 'react';
|
||||
import { Button, Menu } from 'antd';
|
||||
import { HighlightOutlined } from '@ant-design/icons';
|
||||
import cls from 'classnames';
|
||||
import React from 'react';
|
||||
import { useDesignable } from '..';
|
||||
import { PluginManager } from '../../plugin-manager';
|
||||
|
||||
export const DesignableSwitch = () => {
|
||||
const { designable, setDesignable } = useDesignable();
|
||||
const style = {};
|
||||
if (designable) {
|
||||
style['backgroundColor'] = '#f18b62';
|
||||
}
|
||||
return (
|
||||
<PluginManager.Toolbar.Item
|
||||
selected={designable}
|
||||
icon={<HighlightOutlined />}
|
||||
title={'界面配置'}
|
||||
style={style}
|
||||
onClick={() => {
|
||||
setDesignable(!designable);
|
||||
}}
|
||||
|
Loading…
Reference in New Issue
Block a user