marginotes icon indicating copy to clipboard operation
marginotes copied to clipboard

Note element width wants to be dynamic

Open aaron-em opened this issue 8 years ago • 1 comments

responsive oops window.innerWidth is 1110px.

From poking at it, it looks like the margin note declines to display itself if it would have a width of less than 60px, but there's some slack between that minimum and wide enough to display content without having it cut off by the edge of the viewport. Perhaps it'd be desirable to check before rendering whether there's enough horizontal space to fit the element, and if not, to overlay it on the content in the style of a tooltip or otherwise provide some sort of fallback.

Just a thought, anyway; I noticed and figured I'd mention. It's a nifty little library in general; nice work!

aaron-em avatar Mar 09 '16 14:03 aaron-em

Yes, this is totally a todo. For the sake of not complicating myself too much at the beginning, I just limited rendering whenever there's some real estate for the note to show correctly. A tooltip over the element makes a lot of sense.

fdansv avatar Mar 09 '16 18:03 fdansv