Commit dc7dca56 authored by 邓晓峰's avatar 邓晓峰

Merge branch 'feat/map'

parents 79d91fc0 aca6e9ed
Pipeline #37454 passed with stages
in 29 minutes 7 seconds
...@@ -106,7 +106,7 @@ ...@@ -106,7 +106,7 @@
"@wisdom-utils/runtime": "0.0.15", "@wisdom-utils/runtime": "0.0.15",
"@wisdom-utils/utils": "0.0.52", "@wisdom-utils/utils": "0.0.52",
"animate.css": "^4.1.1", "animate.css": "^4.1.1",
"antd": "^4.11.2", "antd": "^4.16.13",
"compression": "1.7.4", "compression": "1.7.4",
"connected-react-router": "6.4.0", "connected-react-router": "6.4.0",
"fontfaceobserver": "2.1.0", "fontfaceobserver": "2.1.0",
......
...@@ -45,7 +45,9 @@ window.createStoreage = new Storeage(namespace); ...@@ -45,7 +45,9 @@ window.createStoreage = new Storeage(namespace);
const initialState = Immutable.Map(); const initialState = Immutable.Map();
const store = configureStore(initialState, history); const store = configureStore(initialState, history);
const MOUNT_NODE = document.getElementById('root'); const MOUNT_NODE = document.getElementById('root');
ConfigProvider.config({
prefixCls: 'panda-console-base'
});
const render = () => { const render = () => {
// eslint-disable-next-line react-hooks/rules-of-hooks // eslint-disable-next-line react-hooks/rules-of-hooks
ReactDOM.render( ReactDOM.render(
......
...@@ -84,7 +84,7 @@ ...@@ -84,7 +84,7 @@
transition: font-size .15s cubic-bezier(.215,.61,.355,1),margin .3s cubic-bezier(.645,.045,.355,1),color .3s; transition: font-size .15s cubic-bezier(.215,.61,.355,1),margin .3s cubic-bezier(.645,.045,.355,1),color .3s;
font-size: 14px; font-size: 14px;
svg { svg {
path, rect, circle { path, rect, circle, .cls-1 {
fill:hsla(0,0%,100%,.65)!important; fill:hsla(0,0%,100%,.65)!important;
stroke:hsla(0,0%,100%,.65)!important; stroke:hsla(0,0%,100%,.65)!important;
stroke-width:0!important; stroke-width:0!important;
...@@ -322,11 +322,22 @@ ...@@ -322,11 +322,22 @@
.menu-item-name { .menu-item-name {
color: @primary-color; color: @primary-color;
} }
.ant-tabs-tab-btn { .@{ant-prefix}-tabs-tab-btn {
color: @primary-color; color: @primary-color;
} }
} }
.@{ant-prefix}-tabs-tab-btn {
.@{ant-prefix}-dropdown-trigger {
div {
div {
width: 100%;
height: 100%;
}
}
}
}
} }
} }
.menu-item { .menu-item {
...@@ -472,9 +483,9 @@ ...@@ -472,9 +483,9 @@
} }
&:hover { &:hover {
span:first-child { // span:first-child {
background: @primary-color; // background: @primary-color;
} // }
span:last-child { span:last-child {
color: @primary-color; color: @primary-color;
} }
...@@ -490,6 +501,21 @@ ...@@ -490,6 +501,21 @@
} }
& :global { & :global {
.@{ant-prefix}-dropdown-custom-menu { .@{ant-prefix}-dropdown-custom-menu {
top: 92px!important; top: 82px!important;
//div span:first-child
.@{ant-prefix}-dropdown-menu-item {
.@{ant-prefix}-dropdown-menu-title-content {
&:hover {
span:first-child {
background: @primary-color!important;
}
span:last-child {
color: @primary-color;
}
}
}
}
} }
} }
...@@ -3,6 +3,7 @@ import React, { ...@@ -3,6 +3,7 @@ import React, {
useEffect, useEffect,
useRef, useRef,
useState, useState,
useContext
} from 'react'; } from 'react';
import { import {
...@@ -16,7 +17,8 @@ import { ...@@ -16,7 +17,8 @@ import {
Divider, Divider,
Dropdown, Dropdown,
Menu, Menu,
Tooltip Tooltip,
ConfigProvider
} from 'antd'; } from 'antd';
// import { RouteWithSubRoutes, renderRoutes } from '../utils/routes'; // import { RouteWithSubRoutes, renderRoutes } from '../utils/routes';
// import { renderRoutes } from 'react-router-config'; // import { renderRoutes } from 'react-router-config';
...@@ -248,7 +250,9 @@ const renderSite = ({data, config, loading, setLoading, action}) => { ...@@ -248,7 +250,9 @@ const renderSite = ({data, config, loading, setLoading, action}) => {
const BasicLayout = props => { const BasicLayout = props => {
/* eslint-disable no-unused-vars */ /* eslint-disable no-unused-vars */
const { getPrefixCls } = useContext(ConfigProvider.ConfigContext);
const prefixCls = props.prefixCls || getPrefixCls('');
console.log("prefixCls", prefixCls);
// const [currentRoutes, setCurrentRoutes] = useState([]); // const [currentRoutes, setCurrentRoutes] = useState([]);
const [collapse, setCollapse] = useState(false); const [collapse, setCollapse] = useState(false);
const [toggleSystem, setToggleSystem] = useState(false); const [toggleSystem, setToggleSystem] = useState(false);
...@@ -461,15 +465,18 @@ const BasicLayout = props => { ...@@ -461,15 +465,18 @@ const BasicLayout = props => {
</Menu> </Menu>
) )
return ( return (
<Dropdown overlay={menu} overlayClassName="ant-dropdown-custom-menu"> <>
<div> <Dropdown overlay={menu} overlayClassName={`${prefixCls}-dropdown-custom-menu`}>
{ <div >
/.svg/.test(route.extData.icon) ?<ReactSVG src={route.extData.icon} style={{width: '18px', height: '18px', position: 'relative', top: '-3px'}}/>: <img src={route.extData.icon} style={{width: '18px', height: '18px'}}/> {
} /.svg/.test(route.extData.icon) ?<ReactSVG src={route.extData.icon} style={{width: '18px', height: '18px', position: 'relative', top: '-3px'}}/>: <img src={route.extData.icon} style={{width: '18px', height: '18px'}}/>
<span style={{marginLeft: '8px'}}>{route.name} </span> }
<DownOutlined style={{position: 'relative', right: '-10px'}}/> <span style={{marginLeft: '8px'}}>{route.name} </span>
</div> <DownOutlined style={{position: 'relative', right: '-10px'}}/>
</Dropdown> </div>
</Dropdown>
<Divider type="vertical" />
</>
) )
} }
......
...@@ -80,8 +80,6 @@ class Map extends React.PureComponent { ...@@ -80,8 +80,6 @@ class Map extends React.PureComponent {
} }
getArcGISMap(map) { getArcGISMap(map) {
debugger
console.log(map)
this.props.updageMapView(map); this.props.updageMapView(map);
} }
......
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