* @private * @function mapboxgl.supermap.WebMap.prototype._matchStyleObject * @description 恢复 style 为标准格式。 * @param {Object} style - mapbox 样式。
(style)
| 5147 | * @param {Object} style - mapbox 样式。 |
| 5148 | */ |
| 5149 | _matchStyleObject(style) { |
| 5150 | let { sprite, glyphs } = style; |
| 5151 | if (sprite && typeof sprite === 'object') { |
| 5152 | style.sprite = Object.values(sprite)[0]; |
| 5153 | } |
| 5154 | if (glyphs && typeof glyphs === 'object') { |
| 5155 | style.glyphs = Object.values(glyphs)[0]; |
| 5156 | } |
| 5157 | } |
| 5158 | |
| 5159 | /** |
| 5160 | * @private |