Skip to content

Commit

Permalink
Feat : Display a chat icon next to data entities that have threads (#…
Browse files Browse the repository at this point in the history
…3026)

* Fix #2778 UI : Add Queries tab for table details page.
  • Loading branch information
Sachin-chaurasiya committed Mar 1, 2022
1 parent 568845b commit 642f875
Show file tree
Hide file tree
Showing 31 changed files with 884 additions and 110 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,8 @@
*/

import { AxiosResponse } from 'axios';
import { Feed, Post } from 'Models';
import { Post } from 'Models';
import { CreateThread } from '../generated/api/feed/createThread';
import APIClient from './index';

export const getAllFeeds: Function = (
Expand All @@ -35,7 +36,9 @@ export const getFeedCount: Function = (
});
};

export const postFeed: Function = (data: Feed): Promise<AxiosResponse> => {
export const postThread: Function = (
data: CreateThread
): Promise<AxiosResponse> => {
return APIClient.post('/feed', data);
};

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ import FeedEditor from '../../FeedEditor/FeedEditor';
interface ActivityFeedEditorProp extends HTMLAttributes<HTMLDivElement> {
onSave?: (value: string) => void;
buttonClass?: string;
placeHolder?: string;
}
type EditorContentRef = {
getEditorValue: () => string;
Expand All @@ -32,6 +33,7 @@ const ActivityFeedEditor: FC<ActivityFeedEditorProp> = ({
className,
buttonClass = '',
onSave,
placeHolder,
}) => {
const editorRef = useRef<EditorContentRef>();
const [editorValue, setEditorValue] = useState<string>('');
Expand All @@ -53,6 +55,7 @@ const ActivityFeedEditor: FC<ActivityFeedEditorProp> = ({
<div className={classNames('tw-relative', className)}>
<FeedEditor
defaultValue={editorValue}
placeHolder={placeHolder}
ref={editorRef}
onChangeHandler={onChangeHandler}
onSave={onSaveHandler}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ interface FeedListBodyProp
onViewMore: () => void;
}

const FeedListSeparator: FC<FeedListSeparatorProp> = ({
export const FeedListSeparator: FC<FeedListSeparatorProp> = ({
className,
relativeDay,
}) => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ interface FeedPanelBodyProp extends HTMLAttributes<HTMLDivElement> {
isLoading: boolean;
}

const FeedPanelHeader: FC<FeedPanelHeaderProp> = ({
export const FeedPanelHeader: FC<FeedPanelHeaderProp> = ({
onCancel,
entityField,
className,
Expand Down Expand Up @@ -79,7 +79,7 @@ const FeedPanelHeader: FC<FeedPanelHeaderProp> = ({
);
};

const FeedPanelOverlay: FC<FeedPanelOverlayProp> = ({
export const FeedPanelOverlay: FC<FeedPanelOverlayProp> = ({
className,
onCancel,
}) => {
Expand Down

0 comments on commit 642f875

Please sign in to comment.