ChannelList
Default ChannelList component, that relies on the ChannelListViewModel to load the data and show it on the UI.
Parameters
Modifier for styling.
Padding values to be applied to the channel list surrounding the content inside.
The ViewModel that loads all the data and connects it to the UI. We provide a factory that builds the default ViewModel in case the user doesn't want to provide their own.
State of the lazy list that represents the list of channels. Useful for controlling the scroll state.
Handler for pagination, when the user reaches the last item in the list.
Handler for a single item tap.
Handler for a long item tap.
Handler for a single search result tap.
Handler for the "Start a chat" button in the empty state. If null, the button is hidden.
Root Channel list component, that represents different UI, based on the current channel state.
This is decoupled from ViewModels, so the user can provide manual and custom data handling, as well as define a completely custom UI component for the channel item.
If there is no state, no query active or the data is being loaded, we show the LoadingIndicator.
If there are no results or we're offline, usually due to an error in the API or network, we show an EmptyContent.
If there is data available and it is not empty, we show Channels.
Parameters
Current state of the Channel list, represented by ChannelsState.
The data of the current user, used various states.
Modifier for styling.
Padding values to be applied to the list surrounding the content inside.
State of the lazy list that represents the list of channels. Useful for controlling the scroll state.
Handler for pagination, when the user reaches the end of the list.
Handler for a single item tap.
Handler for a long item tap.
Handler for a single search result tap.
Handler for the "Start a chat" button in the empty state. If null, the button is hidden.