Type Alias: FieldColourValidator
type FieldColourValidator = Blockly.FieldValidator<string>;
Defined in: plugins/field-colour/src/field_colour.ts:524
A function that is called to validate changes to the field's value before they are set.
See
https://docs.blockly.com/guides/create-custom-blocks/fields/validators/#return-values
Param
newValue
The value to be validated.
Returns
One of three instructions for setting the new value: T, null,
or undefined.
-
Tto set this function's returned value instead ofnewValue. -
nullto invokedoValueInvalid_and not set a value. -
undefinedto setnewValueas is.