Fix 3 bugs (#3391)

* Fix Favorites

* Fix opportunities
This commit is contained in:
Charles Bochet
2024-01-11 21:34:56 +01:00
committed by GitHub
parent 985c2f321e
commit 3ad032cdc1
6 changed files with 56 additions and 32 deletions

View File

@ -22,7 +22,6 @@ import { useDropdown } from '@/ui/layout/dropdown/hooks/useDropdown';
import { MenuItem } from '@/ui/navigation/menu-item/components/MenuItem';
import { MenuItemNavigate } from '@/ui/navigation/menu-item/components/MenuItemNavigate';
import { MenuItemToggle } from '@/ui/navigation/menu-item/components/MenuItemToggle';
import { ThemeColor } from '@/ui/theme/constants/colors';
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
import { ViewFieldsVisibilityDropdownSection } from '@/views/components/ViewFieldsVisibilityDropdownSection';
import { useViewScopedStates } from '@/views/hooks/internal/useViewScopedStates';
@ -39,13 +38,6 @@ export type RecordBoardOptionsDropdownContentProps = {
type BoardOptionsMenu = 'fields' | 'stage-creation' | 'stages';
type ColumnForCreate = {
id: string;
colorCode: ThemeColor;
position: number;
title: string;
};
export const RecordBoardOptionsDropdownContent = ({
onStageAdd,
recordBoardId,
@ -85,7 +77,7 @@ export const RecordBoardOptionsDropdownContent = ({
if (currentMenu !== 'stage-creation' || !stageInputRef?.current?.value)
return;
const columnToCreate: ColumnForCreate = {
const columnToCreate: BoardColumnDefinition = {
id: v4(),
colorCode: 'gray',
position: boardColumns.length,
@ -143,7 +135,6 @@ export const RecordBoardOptionsDropdownContent = ({
const name = viewEditInputRef.current?.value;
resetMenu();
setViewEditMode('none');
closeDropdown();
handleStageSubmit();
handleViewNameSubmit(name);
closeDropdown();

View File

@ -5,6 +5,5 @@ export type ObjectRecordIdentifier = {
name: string;
avatarUrl?: string | null;
avatarType?: AvatarType | null;
linkToEntity?: string;
linkToShowPage?: string;
};