mirror of
https://github.com/CommunityOx/ox_lib.git
synced 2026-08-17 06:56:03 +01:00
feat(interface/context): context menu onBack function (#122)
* feat(interface/context): back button pressed * fix(context): types
This commit is contained in:
@@ -7,7 +7,7 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
|
||||
import { fetchNui } from '../../../utils/fetchNui';
|
||||
|
||||
const openMenu = (id: string | undefined) => {
|
||||
fetchNui<ContextMenuProps>('openContext', id);
|
||||
fetchNui<ContextMenuProps>('openContext', {id: id, back: true});
|
||||
};
|
||||
|
||||
const ContextMenu: React.FC = () => {
|
||||
|
||||
@@ -16,7 +16,7 @@ import { Option, ContextMenuProps } from '../../../interfaces/context';
|
||||
import { fetchNui } from '../../../utils/fetchNui';
|
||||
|
||||
const openMenu = (id: string | undefined) => {
|
||||
fetchNui<ContextMenuProps>('openContext', id);
|
||||
fetchNui<ContextMenuProps>('openContext', {id: id, back: false});
|
||||
};
|
||||
|
||||
const clickContext = (id: string) => {
|
||||
|
||||
Reference in New Issue
Block a user