Skip to main content
Every component in the Android UI Kit follows a three-layer architecture. Understanding these layers is the key to unlocking deep customization without rebuilding components from scratch.

Architecture

Each component is composed of three collaborating classes:

Accessing Internal Layers

The View layer provides accessor methods to reach the other layers:

Customization Categories

The UI Kit provides eight categories of customization entry points. Each category has a dedicated guide:

View Slots

Replace specific regions of a component’s UI (leading view, title, subtitle, trailing view) using the ViewHolderListener pattern.

Styles

Customize visual appearance using XML theme attributes or programmatic setter methods on the View layer.

ViewModel & Data

Configure data fetching with RequestBuilders, observe LiveData, and call mutation methods on the ViewModel.

Adapters

Access or replace the RecyclerView Adapter to control how list items are rendered and manage list data.

Events & Callbacks

Handle click events, selection mode, and global UI Kit events with component-level and static event listeners.

State Views

Replace or restyle the default empty, error, and loading state views with custom layouts.

Text Formatters

Create custom text processors for hashtags, mentions, links, or any pattern using the CometChatTextFormatter API.

Menu & Options

Add, replace, or extend context menu actions and composer attachment options on components.
For global-level customization that spans across all message types and components, see the DataSource & ChatConfigurator guide.

What’s Next

If you’re new to customization, start with View Slots for quick UI changes, or Styles to match your brand. For advanced use cases like custom message types or global behavior changes, head to DataSource & ChatConfigurator.