Lucas/t 365 on comment drawer i see a add comment section with severa (#256)
* Added comments and authors on drawer with proper resolving * Fixed generated front graphql from rebase * Fixed comment chip * wip * wip 2 * - Added string typing for DateTime scalar - Refactored user in a recoil state and workspace using it - Added comment creation * Put theme and user state in generic providers * Fix from rebase * Fixed app theme provider removed from storybook * Wip * Fix graphql front * Fixed backend bug * - Added comment fetching in creation mode - Fixed drawer overflows and heights * - Fixed autosize validation button CSS bug * Fixed CSS bug with drawer changing height if overflow * Fixed text input too many event catched and useless error message * Removed console.log * Fixed comment cell chip * Create comment thread on each comment action bar click * Fixed lint * Fixed TopBar height
This commit is contained in:
@ -20,12 +20,12 @@ import {
|
||||
} from '@/filters-and-sorts/helpers';
|
||||
import { SelectedFilterType } from '@/filters-and-sorts/interfaces/filters/interface';
|
||||
import { EntityTableActionBar } from '@/ui/components/table/action-bar/EntityTableActionBar';
|
||||
import { TableActionBarButtonToggleComments } from '@/ui/components/table/action-bar/TableActionBarButtonOpenComments';
|
||||
import { EntityTable } from '@/ui/components/table/EntityTable';
|
||||
import { WithTopBarContainer } from '@/ui/layout/containers/WithTopBarContainer';
|
||||
import { BoolExpType } from '@/utils/interfaces/generic.interface';
|
||||
import { CompanyOrderByWithRelationInput as Companies_Order_By } from '~/generated/graphql';
|
||||
|
||||
import { TableActionBarButtonCreateCommentThreadCompany } from './table/TableActionBarButtonCreateCommentThreadCompany';
|
||||
import { TableActionBarButtonDeleteCompanies } from './table/TableActionBarButtonDeleteCompanies';
|
||||
import { useCompaniesColumns } from './companies-columns';
|
||||
import { availableFilters } from './companies-filters';
|
||||
@ -93,7 +93,7 @@ export function Companies() {
|
||||
/>
|
||||
</StyledCompaniesContainer>
|
||||
<EntityTableActionBar>
|
||||
<TableActionBarButtonToggleComments />
|
||||
<TableActionBarButtonCreateCommentThreadCompany />
|
||||
<TableActionBarButtonDeleteCompanies />
|
||||
</EntityTableActionBar>
|
||||
</>
|
||||
|
||||
@ -0,0 +1,14 @@
|
||||
import { useOpenCreateCommentThreadDrawerForSelectedRowIds } from '@/comments/hooks/useOpenCreateCommentDrawerForSelectedRowIds';
|
||||
import { TableActionBarButtonToggleComments } from '@/ui/components/table/action-bar/TableActionBarButtonOpenComments';
|
||||
import { CommentableType } from '~/generated/graphql';
|
||||
|
||||
export function TableActionBarButtonCreateCommentThreadCompany() {
|
||||
const openCreateCommentThreadRightDrawer =
|
||||
useOpenCreateCommentThreadDrawerForSelectedRowIds();
|
||||
|
||||
async function handleButtonClick() {
|
||||
openCreateCommentThreadRightDrawer(CommentableType.Company);
|
||||
}
|
||||
|
||||
return <TableActionBarButtonToggleComments onClick={handleButtonClick} />;
|
||||
}
|
||||
@ -17,11 +17,11 @@ import {
|
||||
usePeopleQuery,
|
||||
} from '@/people/services';
|
||||
import { EntityTableActionBar } from '@/ui/components/table/action-bar/EntityTableActionBar';
|
||||
import { TableActionBarButtonToggleComments } from '@/ui/components/table/action-bar/TableActionBarButtonOpenComments';
|
||||
import { EntityTable } from '@/ui/components/table/EntityTable';
|
||||
import { WithTopBarContainer } from '@/ui/layout/containers/WithTopBarContainer';
|
||||
import { BoolExpType } from '@/utils/interfaces/generic.interface';
|
||||
|
||||
import { TableActionBarButtonCreateCommentThreadPeople } from './table/TableActionBarButtonCreateCommentThreadPeople';
|
||||
import { TableActionBarButtonDeletePeople } from './table/TableActionBarButtonDeletePeople';
|
||||
import { usePeopleColumns } from './people-columns';
|
||||
import { availableFilters } from './people-filters';
|
||||
@ -91,7 +91,7 @@ export function People() {
|
||||
/>
|
||||
</StyledPeopleContainer>
|
||||
<EntityTableActionBar>
|
||||
<TableActionBarButtonToggleComments />
|
||||
<TableActionBarButtonCreateCommentThreadPeople />
|
||||
<TableActionBarButtonDeletePeople />
|
||||
</EntityTableActionBar>
|
||||
</>
|
||||
|
||||
@ -0,0 +1,14 @@
|
||||
import { useOpenCreateCommentThreadDrawerForSelectedRowIds } from '@/comments/hooks/useOpenCreateCommentDrawerForSelectedRowIds';
|
||||
import { TableActionBarButtonToggleComments } from '@/ui/components/table/action-bar/TableActionBarButtonOpenComments';
|
||||
import { CommentableType } from '~/generated/graphql';
|
||||
|
||||
export function TableActionBarButtonCreateCommentThreadPeople() {
|
||||
const openCreateCommentThreadRightDrawer =
|
||||
useOpenCreateCommentThreadDrawerForSelectedRowIds();
|
||||
|
||||
async function handleButtonClick() {
|
||||
openCreateCommentThreadRightDrawer(CommentableType.Person);
|
||||
}
|
||||
|
||||
return <TableActionBarButtonToggleComments onClick={handleButtonClick} />;
|
||||
}
|
||||
Reference in New Issue
Block a user