Skip to main content
Version: v4

Checkbox

Overview

This element allow the user to select one or more items from a set.

Properties

NameTypeDescription
namestringName of the element
labelTextstringCaption text of the element
checkedbooleanWhen set to true, element is checked by default
disabledbooleanWhen set to true, disables the element
checkboxStyleCheckboxStyleStyling properties and values of the element

CheckboxStyle

Styling properties and values of the element

NameDescription
widthSets the width of the element
heightSets the height of the element
borderSets the border of the element
borderRadiusSets the border radius of the element
backgroundSets all background style properties at once, such as color, image, origin and size, or repeat method. Reference link
labelTextFontSets all the different properties of font for the caption text. Reference link
labelTextColorSets the foreground color of caption text.
checkedBackgroundColorSets the background color when the element is in checked state
uncheckedBackgroundColorSets the background color when the element is in unchecked state

Events

Events triggered by the element

NameDescription
cc-checkbox-changedTriggered when user updates or modifies the element

Usage

<cometchat-checkbox 
[labelText]="'Checkbox 1'"
[checked]="true"
(cc-checkbox-changed)="changeHandler($event)"
></cometchat-checkbox>