CmsBoolEntry class

CmsEntry for handling boolean values

Inheritance

Constructors

CmsBoolEntry({required String key, String? label, CmsEntryModifier modifier = const CmsEntryModifier(), int flex = 2})

Properties

editable bool
no setterinherited
expanded bool
no setterinherited
fixedLabel String
Real display of the field. If null, last segment of key is displayed
no setterinherited
fixedLabelRequired String
Adds * at the end of the label
no setterinherited
flex int
  • Defines size of the CmsTableItem in the CmsTable
  • final
    hashCode int
    The hash code for this object.
    no setterinherited
    initializable bool
    no setterinherited
    key String
  • key is a path to the value in JsonMap. It may be staggered e.g. user.data.image. To see how it works check JsonMapExtensions
  • final
    label String?
  • label displays the name of the entry. To find out more check fixedLabel
  • final
    modifier CmsEntryModifier
    Modifies the behavior of the CmsEntry
    final
    pinned bool
    no setterinherited
    required bool
    no setterinherited
    runtimeType Type
    A representation of the runtime type of the object.
    no setterinherited
    sortable bool
    no setterinherited
    sortInvertNulls bool
    no setterinherited

    Methods

    buildEditField({required BuildContext context, required bool? value, required void onChanged(bool value)}) Widget
    Builder for edit/create flow. It provides context, current value and onChanged method. It is recommended to wrap it in the CmsFieldWrapper.
    override
    buildPreview(BuildContext context, bool? value) Widget
    Preview of the value shown in the CmsTable
    override
    fromJson(Object? json) bool?
    simple fromJson method, e.g. int.parse(json.toString) for an int value.
    inherited
    noSuchMethod(Invocation invocation) → dynamic
    Invoked when a nonexistent method or property is accessed.
    inherited
    onSaved() Future<void>
    inherited
    toJson(bool value) Object?
    simple toJson method, e.g. 12.toString for an int value.
    inherited
    toString() String
    A string representation of this object.
    inherited

    Operators

    operator ==(Object other) bool
    The equality operator.
    inherited