import deviceType from '../config/deviceType'; import Link from './Link'; /** 图库*/ const mapShape = {}; mapShape[deviceType.Link] = Link; function shapefactory(type, device, style) { const shape = mapShape[type]; if (shape instanceof Function) { return new shape(device, style[type], style.Global); } } export default shapefactory;