Comments (8)
The context menu tries to orient itself so that it doesn't flow off the side of screen (if possible). The first orientation it tries is to put the top left corner of the context menu at the mouse location. Can you give me more details about your app?
- What does the event object look like?
- Are you doing any styling using the
position
css property?
from ngx-contextmenu.
Thanks for answering so quickly.
- Would you like to see an example of generated MouseEvent object?
- I haven't applied any custom styling to this component or any other yet.
from ngx-contextmenu.
- Yes.
from ngx-contextmenu.
from ngx-contextmenu.
In your console, enter document.body.clientWidth
and document.body.clientHeight
and let me know what they say.
from ngx-contextmenu.
Width returned 1060, Height returned 10
PS My app has a component that contains a D3.js graph in which I included context menus in the nodes like in the issue I opened a while ago. That context menu also opens from the bottom left corner.
from ngx-contextmenu.
The height is the problem. The context menu thinks it only has 10px of height to work with and is trying to show as much of the context menu as possible in those 10px. Giving your body a min-height in css will fix the problem, but I'm guessing there is some underlying issue that is stopping your body from knowing its real height. Are you using float based layout? Adding a clearfix at the end of the body would help that situation.
from ngx-contextmenu.
clearfix solved it! Thanks!
from ngx-contextmenu.
Related Issues (20)
- Can't install with Angular 12.0.1 HOT 1
- Support Angular 11 and 12 HOT 1
- Long touch does not trigger in ios mobile devices
- Context menu is not working in Angular 9 HOT 1
- contextMenuService not showing the menus in angular 11 HOT 4
- Unable to render nested submenu
- Contextmenu is broken in Angular 13 HOT 16
- Can't bind to 'subMenu' since it isn't a known property of 'ng-template'.
- Disable the context-menu if the contextMenuSubject is empty or undefined
- Blank context menu issue when there is no context menu to show
- Angular 12
- In bootstrap model popup , context menu is not getting on right click on grid/cell in angular
- Archiving the repo HOT 2
- delay on close
- ngx context menu with filtering ability
- ngx-contextmenu does not support with angular 14. HOT 2
- contextMenu not bind With Html in angular 12.
- Accessibility issue with Context Menu-Confirmation needed HOT 3
- Support for Angular 16 HOT 3
- Default css doesn't work on Angular 7 HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ngx-contextmenu.