You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
504 B
19 lines
504 B
import React from 'react';
|
|
|
|
import { Protobuf } from '@meshtastic/meshtasticjs';
|
|
|
|
import { useAppSelector } from '../../../hooks/redux';
|
|
import { Channel } from './Channel';
|
|
|
|
export const ChannelList = (): JSX.Element => {
|
|
const channels = useAppSelector((state) => state.meshtastic.channels);
|
|
|
|
return (
|
|
<>
|
|
{channels.map((channel, index) => {
|
|
if (channel.role !== Protobuf.Channel_Role.DISABLED)
|
|
return <Channel key={index} channel={channel} />;
|
|
})}
|
|
</>
|
|
);
|
|
};
|
|
|