jinjor / elm-contextmenu Goto Github PK
View Code? Open in Web Editor NEWFlexible context menu for Elm
Home Page: http://package.elm-lang.org/packages/jinjor/elm-contextmenu/latest
License: BSD 3-Clause "New" or "Revised" License
Flexible context menu for Elm
Home Page: http://package.elm-lang.org/packages/jinjor/elm-contextmenu/latest
License: BSD 3-Clause "New" or "Revised" License
During my work on #6 I have seen that some of your code is never used. Please fix this:
src/Styles.elm
line 95: The disabled
flag is never used in your code.
annotation : Color -> Float -> Float -> Bool -> Style msg
annotation color annotationHeight fontSize disabled =
[ style "margin-top" "-2px"
, style "line-height" (px annotationHeight)
, style "font-size" (px fontSize)
, style "color" color
]
src/Styles.elm
line 117: The borderWidth
setting is never used.
partition : Float -> Float -> Style msg
partition borderWidth margin =
[ style "border-bottom-style" "solid"
, style "border-bottom-width" (px 1)
, style "border-bottom-color" borderColor
, style "border-top" "none"
, style "margin" (px margin ++ " 0")
]
src/ContextMenu.elm
line 42 and 49: The imports Browser
and Process
are never used in your code. You can safely remove them.Great work, thank you !
I've had to modify you code in this line:
github.com/jinjor/elm-contextmenu/blob/master/src/ContextMenu.elm#L521
"contextmenu"-->"click"
Because I needed the menu to open on left click.
I needed to change the position: fixed
style to position: absolute
for it to work correctly.
Just so you know ๐ I think it has something to do with the scroll position?
PS. Thanks for this library!
Hey is there any way to make the context menu stay open until the cursor is moved off the menu?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.