import { h, Component } from 'preact';
import PropTypes from 'prop-types';
import Article from './article';
import ChannelRequest from './channelRequest';
import RequestManager from './requestManager';
import ChatChannelSettings from './ChatChannelSettings/ChatChannelSettings';
export default class Content extends Component {
static propTypes = {
resource : PropTypes.object,
activeChannelId : PropTypes.number,
pusherKey : PropTypes.string,
fullscreen : PropTypes.bool
};
render() {
const { onTriggerContent, fullscreen } = this.props;
if (!this.props.resource) {
return '';
}
const smartSvgIcon = (content, d) => (
);
return (
{display(this.props)}
);
}
}
function display(props) {
const { resource } = props;
switch(resource.type_of) {
case 'loading-user':
return
case 'article':
return ;
case 'channel-request':
return ;
case 'channel-request-manager':
return (
)
case 'chat-channel-setting':
return (
);
default:
return null;
}
}