{ "name": "smartCity-infoPanel", "version": "1.0.2", "description": "smartCity-infoPanel子组件", "main": "index.js", "scripts": { "build": "cube build ./ --output=../../datavComponent --remote=pandav --smart" }, "keywords": [ "map", "subcoms" ], "dependencies": { "eventemitter3": "3.0.0", "safely-merge": "1.0.1", "lodash": "4.17.11" }, "pandav": { "cn_name": "信息面板", "level": 1, "protocol": 2, "type": [ "smartCity-v1_subcoms_infoPanel" ], "parent": { "supportTypes": [ "smartCity-v1" ], "supportNames": [] }, "events": { "switch": { "name": "状态改变" }, "click": { "name": "鼠标点击" }, "hover": { "name": "鼠标移入" }, "cancel": { "name": "取消选中" } }, "publicHandler": {}, "api_data": { "source": [ { "name": "水厂一", "state": "正常", "lng": 121.138414, "lat": 30.058213, "height": 60, "zoom": 17 }, { "name": "水厂二", "state": "异常", "lng": 121.150142, "lat": 30.018194, "height": 60, "zoom": 17 }, { "name": "水厂三", "state": "正常", "lng": 121.16693, "lat": 30.032512, "height": 60, "zoom": 17 }, { "name": "水厂四", "state": "正常", "lng": 121.12106, "lat": 30.034512, "height": 60, "zoom": 17 } ] }, "apis": { "source": { "description": "数据接口", "handler": "render", "fields": { "name": { "description": "名称", "type": "string" }, "state": { "description": "状态", "type": "string" }, "lng": { "description": "经度", "type": "number" }, "lat": { "description": "纬度", "type": "number" }, "height": { "description": "高度", "type": "number" }, "zoom": { "description": "层级", "type": "number" } } } }, "config": { "options": { "type": "menu", "children": { "baseConfig": { "name": "基础配置", "type": "menuChild", "mode": "single", "children": { "system": { "name": "坐标系", "type": "radio", "default": "WGS84", "optionCol": 12, "options": [ { "label": "WGS84", "value": "WGS84" }, { "label": "GCJ02", "value": "GCJ02" } ] }, "showLevel": { "name": "可见级别", "type": "slider", "mode": "double", "default": [ 0, 20 ], "step": 0.1, "min": 0, "max": 20, "showCurrentRange": true }, "altitude": { "name": "抬升高度", "default": 0, "type": "number" }, "depthTest": { "name": "自动排序", "type": "switch", "default": true }, "renderOrder": { "name": "层级序号", "type": "number", "default": 0, "show": [ [ "depthTest", "$eq", false ] ] } } }, "styleConfig": { "name": "样式配置", "type": "menuChild", "mode": "single", "children": { "sizeType": { "name": "尺寸模式", "type": "radio", "default": "world", "description": "世界尺寸随镜头层级改变,屏幕尺寸不随镜头层级改变", "optionCol": 12, "options": [ { "label": "世界尺寸", "value": "world" }, { "label": "屏幕尺寸", "value": "screen" } ] }, "states": { "name": "状态背景", "type": "tabs", "fold": false, "default": [ { "type": "正常", "backStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_back.png", "size": { "width": 460, "height": 500 }, "scale": 0.01, "center": { "x": 50, "y": 100 } }, "pointStyle": { "direction": "row", "defaultStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_point1.png", "size": { "width": 100, "height": 100 }, "scale": 0.01 }, "currentStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_point2.png", "size": { "width": 100, "height": 100 }, "scale": 0.01 } } }, { "type": "异常", "backStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/error_back.png", "size": { "width": 460, "height": 500 }, "scale": 0.01, "center": { "x": 50, "y": 100 } }, "pointStyle": { "direction": "row", "defaultStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/error_point1.png", "size": { "width": 100, "height": 100 }, "scale": 0.01 }, "currentStyle": { "url": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/error_point2.png", "size": { "width": 100, "height": 100 }, "scale": 0.01 } } } ], "template": { "name": "状态<%=i+1%>", "type": "object", "children": { "type": { "name": "状态值", "default": "正常", "type": "text" }, "backStyle": { "name": "背景样式", "type": "group", "fold": false, "children": { "url": { "name": "图片上传", "type": "image", "default": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_back.png" }, "size": { "type": "suite", "name": "尺寸", "children": { "width": { "name": "宽度", "default": 460, "type": "number", "col": 12 }, "height": { "name": "高度", "default": 500, "type": "number", "col": 12 } } }, "scale": { "name": "缩放比例", "default": 0.01, "type": "number" }, "center": { "type": "suite", "name": "基准点", "children": { "x": { "name": "X", "default": 50, "type": "number", "min": 0, "max": 100, "suffix": "%", "col": 12 }, "y": { "name": "Y", "min": 0, "max": 100, "default": 100, "type": "number", "suffix": "%", "col": 12 } } } } }, "pointStyle": { "name": "定位点", "type": "group", "fold": false, "children": { "direction": { "name": "方向", "type": "radio", "default": "row", "optionCol": 12, "options": [ { "label": "水平", "value": "row" }, { "label": "竖立", "value": "column" } ] }, "defaultStyle": { "name": "默认样式", "type": "group", "fold": false, "children": { "url": { "name": "图片上传", "type": "image", "default": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_point1.png" }, "size": { "type": "suite", "name": "尺寸", "children": { "width": { "name": "宽度", "default": 100, "type": "number", "col": 12 }, "height": { "name": "高度", "default": 100, "type": "number", "col": 12 } } }, "scale": { "name": "缩放比例", "default": 0.01, "type": "number" } } }, "currentStyle": { "name": "当前样式", "type": "group", "fold": false, "children": { "url": { "name": "图片上传", "type": "image", "default": "/civ_pandaview_component/pandabi-component/assets/components/smartCity/normal_point2.png" }, "size": { "type": "suite", "name": "尺寸", "children": { "width": { "name": "宽度", "default": 100, "type": "number", "col": 12 }, "height": { "name": "高度", "default": 100, "type": "number", "col": 12 } } }, "scale": { "name": "缩放比例", "default": 0.01, "type": "number" } } } } } } } }, "lines": { "name": "行配置", "type": "tabs", "fold": false, "default": [ { "mapping": { "field": "name", "showName": "区域:" }, "position": { "x": 80, "y": 96 }, "labelConfig": { "simpleTextStyle": { "fontSize": 46, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 0, "y": 0 } }, "valueConfig": { "simpleTextStyle": { "fontSize": 46, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 10, "y": 0 } }, "suffixConfig": { "show": true, "content": "", "simpleTextStyle": { "fontSize": 24, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 45, "y": 0 } } }, { "mapping": { "field": "state", "showName": "状态:" }, "position": { "x": 80, "y": 180 }, "labelConfig": { "simpleTextStyle": { "fontSize": 46, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 0, "y": 0 } }, "valueConfig": { "simpleTextStyle": { "fontSize": 46, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 10, "y": 0 } }, "suffixConfig": { "show": true, "content": "", "simpleTextStyle": { "fontSize": 24, "color": "#fff", "fontFamily": "微软雅黑" }, "offset": { "x": 45, "y": 0 } } } ], "template": { "name": "行<%=i+1%>", "type": "object", "children": { "mapping": { "name": "映射", "type": "suite", "children": { "field": { "name": "字段名", "type": "text", "default": "", "col": 12 }, "showName": { "name": "显示名", "type": "text", "default": "", "col": 12 } } }, "position": { "name": "位置", "type": "suite", "children": { "x": { "name": "X", "type": "number", "default": 0, "col": 12 }, "y": { "name": "Y", "type": "number", "default": 0, "col": 12 } } }, "labelConfig": { "name": "标签样式", "type": "group", "fold": false, "children": { "simpleTextStyle": { "type": "font", "components": [ "fontFamily", "fontSize", "color" ], "name": "文本样式", "default": { "fontFamily": "微软雅黑", "fontSize": 24, "color": "#eee" } }, "offset": { "name": "偏移", "type": "suite", "children": { "x": { "name": "X", "type": "number", "default": 10, "col": 12 }, "y": { "name": "Y", "type": "number", "default": 0, "col": 12 } } } } }, "valueConfig": { "name": "值样式", "type": "group", "fold": false, "children": { "simpleTextStyle": { "type": "font", "components": [ "fontFamily", "fontSize", "color" ], "name": "文本样式", "default": { "fontFamily": "微软雅黑", "fontSize": 24, "color": "#eee" } }, "offset": { "name": "偏移", "type": "suite", "children": { "x": { "name": "X", "type": "number", "default": 0, "col": 12 }, "y": { "name": "Y", "type": "number", "default": 0, "col": 12 } } } } }, "suffixConfig": { "name": "后缀", "fold": false, "enableHide": true, "type": "group", "children": { "show": { "default": true }, "content": { "name": "内容", "type": "text", "default": "" }, "simpleTextStyle": { "type": "font", "components": [ "fontFamily", "fontSize", "color" ], "name": "文本样式", "default": { "fontFamily": "微软雅黑", "fontSize": 24, "color": "#eee" } }, "offset": { "name": "偏移", "type": "suite", "children": { "x": { "name": "X", "type": "number", "default": 0, "col": 12 }, "y": { "name": "Y", "type": "number", "default": 0, "col": 12 } } } } } } } } } }, "animateConfig": { "name": "交互动画", "type": "menuChild", "mode": "single", "children": { "triggerType": { "name": "切换方式", "type": "radio", "default": "click", "options": [ { "name": "无", "value": "none" }, { "name": "点击", "value": "click" }, { "name": "悬停", "value": "hover" } ] }, "canCancel": { "show": [ [ "triggerType", "$ne", "none" ] ], "name": "取消选中", "type": "switch", "default": true, "description": "鼠标再次点击/鼠标移出时,可取消选中。" }, "loop_show": { "name": "轮播动画", "type": "switch", "default": true }, "loop_interval": { "name": "轮播间隔", "type": "number", "default": 5, "suffix": "s", "show": [ [ "loop_show", "$eq", true ] ] }, "drill_show": { "name": "点击聚焦", "type": "switch", "default": true }, "drill_duration": { "name": "聚焦动画时长", "type": "number", "default": 1, "suffix": "s", "show": [ [ "drill_show", "$eq", true ] ] } } } } } } } }