mirror of
https://github.com/google/blockly.git
synced 2026-01-07 17:10:11 +01:00
Use generics to derive SVG element type (#4036)
* Encapsulate type in a generic to automatically derive type of SVG element when using createSvgElement
This commit is contained in:
@@ -58,8 +58,8 @@ Blockly.BlockSvg = function(workspace, prototypeName, opt_id) {
|
||||
* @type {!SVGGElement}
|
||||
* @private
|
||||
*/
|
||||
this.svgGroup_ = /** @type {!SVGGElement} */ (
|
||||
Blockly.utils.dom.createSvgElement('g', {}, null));
|
||||
this.svgGroup_ = Blockly.utils.dom.createSvgElement(
|
||||
Blockly.utils.dom.SvgElementType.G, {}, null);
|
||||
this.svgGroup_.translate_ = '';
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user