mirror of
https://github.com/twentyhq/twenty.git
synced 2024-12-24 20:42:05 +03:00
Fix Select (#3327)
This commit is contained in:
parent
4ebb487fa1
commit
47ac97dd25
@ -1,9 +1,10 @@
|
|||||||
import { ContactLink } from "@/ui/navigation/link/components/ContactLink";
|
import { BrowserRouter as Router } from 'react-router-dom';
|
||||||
import { BrowserRouter as Router } from "react-router-dom";
|
|
||||||
|
import { ContactLink } from '@/ui/navigation/link/components/ContactLink';
|
||||||
|
|
||||||
export const MyComponent = () => {
|
export const MyComponent = () => {
|
||||||
const handleLinkClick = (event) => {
|
const handleLinkClick = (event) => {
|
||||||
console.log("Contact link clicked!", event);
|
console.log('Contact link clicked!', event);
|
||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
@ -26,11 +26,21 @@ export const useCommandMenu = () => {
|
|||||||
setHotkeyScopeAndMemorizePreviousScope(AppHotkeyScope.CommandMenuOpen);
|
setHotkeyScopeAndMemorizePreviousScope(AppHotkeyScope.CommandMenuOpen);
|
||||||
};
|
};
|
||||||
|
|
||||||
const closeCommandMenu = () => {
|
const closeCommandMenu = useRecoilCallback(
|
||||||
setIsCommandMenuOpened(false);
|
({ snapshot }) =>
|
||||||
resetSelectedItem();
|
() => {
|
||||||
goBackToPreviousHotkeyScope();
|
const isCommandMenuOpened = snapshot
|
||||||
};
|
.getLoadable(isCommandMenuOpenedState)
|
||||||
|
.getValue();
|
||||||
|
|
||||||
|
if (isCommandMenuOpened) {
|
||||||
|
setIsCommandMenuOpened(false);
|
||||||
|
resetSelectedItem();
|
||||||
|
goBackToPreviousHotkeyScope();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
[goBackToPreviousHotkeyScope, resetSelectedItem, setIsCommandMenuOpened],
|
||||||
|
);
|
||||||
|
|
||||||
const toggleCommandMenu = useRecoilCallback(({ snapshot }) => async () => {
|
const toggleCommandMenu = useRecoilCallback(({ snapshot }) => async () => {
|
||||||
const isCommandMenuOpened = snapshot
|
const isCommandMenuOpened = snapshot
|
||||||
|
@ -144,6 +144,7 @@ export const SettingsObjectFieldPreview = ({
|
|||||||
fieldName,
|
fieldName,
|
||||||
relationObjectMetadataNameSingular:
|
relationObjectMetadataNameSingular:
|
||||||
relationObjectMetadataItem?.nameSingular,
|
relationObjectMetadataItem?.nameSingular,
|
||||||
|
options: selectOptions,
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
hotkeyScope: 'field-preview',
|
hotkeyScope: 'field-preview',
|
||||||
|
Loading…
Reference in New Issue
Block a user