瀏覽代碼

remove attribution

tags/2.1.3
Caven Chen 4 年之前
父節點
當前提交
fae0a9e37e
共有 3 個檔案被更改,包括 0 行新增63 行删除
  1. 0
    14
      modules/themes/index.scss
  2. 0
    2
      modules/widget/index.js
  3. 0
    47
      modules/widget/type/Attribution.js

+ 0
- 14
modules/themes/index.scss 查看文件

@@ -10,20 +10,6 @@
display: block;
}

.dc-attribution {
img{
width: 20px;
height: 20px;
margin-right: 3px;
}
a {
text-decoration: none;
&:hover {
text-decoration: underline;
}
}
}

.div-icon {
user-select: none;
background-color: #fff;

+ 0
- 2
modules/widget/index.js 查看文件

@@ -3,7 +3,6 @@
* @Date:2020-03-05 21:53:35
*/

import Attribution from './type/Attribution'
import ContextMenu from './type/ContextMenu'
import LocationBar from './type/LocationBar'
import MapSplit from './type/MapSplit'
@@ -18,7 +17,6 @@ import LoadingMask from './type/LoadingMask'

export default function createWidgets() {
return {
attribution: new Attribution(),
popup: new Popup(),
contextMenu: new ContextMenu(),
tooltip: new Tooltip(),

+ 0
- 47
modules/widget/type/Attribution.js 查看文件

@@ -1,47 +0,0 @@
/**
* @Author: Caven
* @Date: 2020-02-11 21:08:01
*/

import State from '@dc-modules/state/State'
import Icons from '@dc-modules/icons'
import { DomUtil } from '@dc-modules/utils'
import Widget from '../Widget'

class Attribution extends Widget {
constructor() {
super()
this._wrapper = DomUtil.create('div', 'dc-attribution')
this._wrapper.style.cssText = `
position: absolute;
left: 2px;
bottom: 2px;
font-size: 14px;
color: #a7a7a7;
padding: 2px 5px;
border-radius: 2px;
user-select: none;
display:flex;
`
this._config = undefined
this.type = Widget.getWidgetType('attribution')
this._state = State.INSTALLED
}

_installHook() {
let logo = DomUtil.create('img', '', this._wrapper)
logo.src = Icons.logo
let a = DomUtil.create('a', '', this._wrapper)
a.innerHTML = '数字视觉'
a.href = 'javascript:void(0)'
a.onclick = () => {
window.open('https://www.dvgis.cn')
}
a.style.cssText = `color:#a7a7a7;font-size:14px`
this.enable = true
}
}

Widget.registerType('attribution')

export default Attribution

Loading…
取消
儲存