field_colour document javascript definition missed a parameter
mlzboy opened this issue · 1 comments
mlzboy commented
Location
No response
Type
- Text
- Image or Gif
- Other
Suggested content
field_colour document at creation setion https://developers.google.com/blockly/guides/create-custom-blocks/fields/built-in-fields/colour#javascript
the javascript definition missed a parameter,bellow the right code
Blockly.Blocks['example_colour'] = {
init: function () {
this.appendDummyInput()
.appendField('colour:')
.appendField(new Blockly.FieldColour('#ff4040',null,
{
"colourOptions":
['#ff4040', '#ff8080', '#ffc0c0',
'#4040ff', '#8080ff', '#c0c0ff'],
"colourTitles":
['dark pink', 'pink', 'light pink',
'dark blue', 'blue', 'light blue'],
"columns": 3
}), 'FIELDNAME');
}
};
codepen test link https://codepen.io/mlzboy/pen/ZEPZwQK at js panel line 154
Additional context
No response
maribethb commented
Hello, thanks for filing this bug! We're in the process of moving this field, and also its documentation, over to blockly-samples, so we'll double check the new documentation is accurate and the old documentation is being removed.