schema property
Implementation
static final schema = {
r'$schema': 'http://json-schema.org/draft-06/schema#',
r'$id': id,
r'$children': 0,
r'$comment':
'https://api.flutter.dev/flutter/cupertino/CupertinoSwitch-class.html',
'type': 'object',
'title': 'CupertinoSwitch',
'additionalProperties': false,
'properties': {
'activeColor': SchemaHelper.objectSchema(ColorSchema.id),
'autovalidate': SchemaHelper.boolSchema,
'autovalidateMode': SchemaHelper.objectSchema(AutovalidateModeSchema.id),
'dragStartBehavior':
SchemaHelper.objectSchema(DragStartBehaviorSchema.id),
'enabled': SchemaHelper.boolSchema,
'label': SchemaHelper.stringSchema,
'onChanged': SchemaHelper.stringSchema,
'onSaved': SchemaHelper.stringSchema,
'restorationId': SchemaHelper.stringSchema,
'thumbColor': SchemaHelper.objectSchema(ColorSchema.id),
'trackColor': SchemaHelper.objectSchema(ColorSchema.id),
'validators': {
'type': 'array',
'items': {
'type': 'object',
'additionalProperties': true,
}
},
'value': SchemaHelper.boolSchema,
'visualDensity': SchemaHelper.objectSchema(VisualDensitySchema.id),
},
};