Platform: Checkbox Component Technical Design - SAP/fundamental-ngx GitHub Wiki

Checkbox

Summary

The checkbox is an input element which is used to represent a binary or ternary value field.

Example

<fdp-checkbox
  [(ngModel)]="vote"
  [tristate]="false"></fdp-checkbox>

Design

There is already a Fundamental NGX: Core implementation of Checkbox. As such the Platform Checkbox component will be a wrapper around the Core component, and will have the same property and/or event bindings.

As this is an input control it needs to implement the FormFieldControl as described in the FormGroup Layout or extend existing BaseInputComponent.


i18n

Link to general support for i18n: Supporting internationalization in ngx/platform

Special Usecase: No

  • fdp-checkbox's label and can be supported with string binding:
<fdp-checkbox
            [name]="'checkbox-7'"
            i18n-label="@@cbLabel"
            label="Checkbox7"
            i18n-value="@@cbValue"
            value="Checkbox7"
            [(ngModel)]="example6">
</fdp-checkbox>

Redesign Required: No


Notes:

@Manju: Need description for the signature, like we have for other components.