Image Field Config (#2983)

* Added image field configuration.
This commit is contained in:
Beka Westberg
2019-09-16 11:05:32 -07:00
committed by Sam El-Husseini
parent 8b9816abcb
commit b149aabd16
3 changed files with 180 additions and 62 deletions

View File

@@ -493,8 +493,10 @@ FactoryUtils.getFieldsJs_ = function(block) {
var width = Number(block.getFieldValue('WIDTH'));
var height = Number(block.getFieldValue('HEIGHT'));
var alt = JSON.stringify(block.getFieldValue('ALT'));
var flipRtl = Json.stringify(block.getFieldValue('FLIP_RTL'));
fields.push('new Blockly.FieldImage(' +
src + ', ' + width + ', ' + height + ', ' + alt + ')');
src + ', ' + width + ', ' + height +
', { alt: ' + alt + ', flipRtl: ' + flipRtl + ' })');
break;
}
}