Fix circular dependency in Group Members
This commit is contained in:
parent
18792f3a29
commit
2a69482201
|
@ -14,8 +14,7 @@ import PlaceholderAccount from 'soapbox/features/placeholder/components/placehol
|
||||||
import { useAppDispatch, useFeatures } from 'soapbox/hooks';
|
import { useAppDispatch, useFeatures } from 'soapbox/hooks';
|
||||||
import { GroupRoles } from 'soapbox/schemas/group-member';
|
import { GroupRoles } from 'soapbox/schemas/group-member';
|
||||||
import toast from 'soapbox/toast';
|
import toast from 'soapbox/toast';
|
||||||
|
import { MAX_ADMIN_COUNT } from 'soapbox/utils/groups';
|
||||||
import { MAX_ADMIN_COUNT } from '../group-members';
|
|
||||||
|
|
||||||
import type { Menu as IMenu } from 'soapbox/components/dropdown-menu';
|
import type { Menu as IMenu } from 'soapbox/components/dropdown-menu';
|
||||||
import type { Group, GroupMember } from 'soapbox/types/entities';
|
import type { Group, GroupMember } from 'soapbox/types/entities';
|
||||||
|
|
|
@ -6,6 +6,7 @@ import { PendingItemsRow } from 'soapbox/components/pending-items-row';
|
||||||
import ScrollableList from 'soapbox/components/scrollable-list';
|
import ScrollableList from 'soapbox/components/scrollable-list';
|
||||||
import { useFeatures } from 'soapbox/hooks';
|
import { useFeatures } from 'soapbox/hooks';
|
||||||
import { GroupRoles } from 'soapbox/schemas/group-member';
|
import { GroupRoles } from 'soapbox/schemas/group-member';
|
||||||
|
import { MAX_ADMIN_COUNT } from 'soapbox/utils/groups';
|
||||||
|
|
||||||
import PlaceholderAccount from '../placeholder/components/placeholder-account';
|
import PlaceholderAccount from '../placeholder/components/placeholder-account';
|
||||||
|
|
||||||
|
@ -18,8 +19,6 @@ interface IGroupMembers {
|
||||||
params: { groupId: string };
|
params: { groupId: string };
|
||||||
}
|
}
|
||||||
|
|
||||||
export const MAX_ADMIN_COUNT = 5;
|
|
||||||
|
|
||||||
const GroupMembers: React.FC<IGroupMembers> = (props) => {
|
const GroupMembers: React.FC<IGroupMembers> = (props) => {
|
||||||
const { groupId } = props.params;
|
const { groupId } = props.params;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,7 @@
|
||||||
import { groupSearchHistory } from 'soapbox/settings';
|
import { groupSearchHistory } from 'soapbox/settings';
|
||||||
|
|
||||||
|
export const MAX_ADMIN_COUNT = 5;
|
||||||
|
|
||||||
const RECENT_SEARCHES_KEY = 'soapbox:recent-group-searches';
|
const RECENT_SEARCHES_KEY = 'soapbox:recent-group-searches';
|
||||||
|
|
||||||
const clearRecentGroupSearches = (currentUserId: string) => groupSearchHistory.remove(currentUserId);
|
const clearRecentGroupSearches = (currentUserId: string) => groupSearchHistory.remove(currentUserId);
|
||||||
|
|
Loading…
Reference in New Issue