Implemtation in progress, UIX working , replacing in ContainerOperations.ts working but not properly need fix
This commit is contained in:
parent
62abd3ff03
commit
e789300090
9 changed files with 139 additions and 98 deletions
|
@ -2,11 +2,13 @@ import useSize from '@react-hook/size';
|
|||
import * as React from 'react';
|
||||
import { IPoint } from '../../Interfaces/IPoint';
|
||||
import { MenuItem } from './MenuItem';
|
||||
import { IConfiguration } from '../../Interfaces/IConfiguration';
|
||||
|
||||
interface IMenuProps {
|
||||
getListener: () => HTMLElement | null
|
||||
actions: Map<string, IMenuAction[]>
|
||||
className?: string
|
||||
configuration: IConfiguration
|
||||
}
|
||||
|
||||
export interface IMenuAction {
|
||||
|
@ -21,6 +23,7 @@ export interface IMenuAction {
|
|||
|
||||
/** function to be called on button click */
|
||||
action: (target: HTMLElement) => void
|
||||
|
||||
}
|
||||
|
||||
function UseMouseEvents(
|
||||
|
@ -139,7 +142,7 @@ function AddClassSpecificActions(
|
|||
onClick={() => action.action(target)} />);
|
||||
});
|
||||
children.push(<hr key={`contextmenu-hr-${count}`} className='border-slate-400' />);
|
||||
};
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue