Comment Object
The Comment Object component renders a comment item.
It is composed of a section containing the avatar and username of the author, the body of the comment and the date of creation of the same. There are also various actions that can be performed, such as reply and like, which are represented by icons and text. Moreover, through the top right menu it is possible to flag, hide or delete the comment item.
Usage
import React from 'react';
import {SCContextProvider} from '@selfcommunity/react-core';
import {CommentObject} from '@selfcommunity/react-ui';
function App() {
const conf = {
portal: '<community-path>',
session: {
type: 'OAuth',
token: '<community-token>',
refreshToken: '<community-refresh-token>',
refreshTokenEndpoint: '<community-refresh-endpoint>',
},
};
return (
<SCContextProvider conf={conf}><CommentObject /></SCContextProvider>
);
}