JunoLab / atom-ink

IDE toolkit for Atom
MIT License
228 stars 40 forks source link

Console panel overlaps autosuggest overlay #116

Closed dansisan closed 5 years ago

dansisan commented 7 years ago

image

Looks like it results from this commit https://github.com/JunoLab/atom-ink/commit/365f54f2ea86f440127121efa763d37febe32f74 . I confirmed that undoing that commit fixes the autosuggest problem, but as the comment in the code notes, that makes the inline results overlap other panels.

It seems that problem should be fixed another way. You can get pretty close by tweaking the z-index values of a few elements:

.ink-overlay {z-index: auto} # undo z-index: 4 from Atom
.gutter-container, atom-panel-container > atom-panel.left { # put gutter, left panel at higher z-index
  z-index: 1;
 }

but you can still see the inline results through the transparent narrow borders in between panels, and the blank parts of the workspace panel. While not ideal, I'd say it's better than the current situation (and maybe good enough?).

To throw out another halfway measure: if you leave the clip rule on atom-text-editor you can make the overlapped autosuggest overlay readable by giving autocomplete-suggestion-list.select-list.popover-list ol.list-group a background color. The only problem there is that the drop shadow gets cut off by the clip.

It seems what you'd want the overlay to be positioned with absolute rather than fixed, but Atom's decoration API doesn't seem to allow that (it updates the position assuming its fixed). Another thought is to use the block decoration but float it (making it inline wasn't working, and I wasn't seeing a way to get the previous element to float it).

pfitzseb commented 7 years ago

Hm, I can't reproduce this: autocomplete

dansisan commented 7 years ago

Hm, I'm on OSX 10.12.2. (I upgraded from 10.10 recently, and I don't remember seeing this before.) I'm also on Atom 1.13.0, and Uber-Juno 0.1.1.

Your screenshot is actually what I would expect to see, given the CSS -- not sure why some of the overlay leaks through the clip -- and it's what I do see if I give a z-index to autocomplete-suggestion-list.select-list.popover-list.

Regardless, I would say your screenshot is still the bug described by this issue (just a less ugly version of it). The overlay should overlap the console. If you press the down arrow from where you are in the screenshot (a typical next step), for instance, the cursor and selected items are hidden behind the console (you have to scroll to see what's going on). If you're on the last line of the file, you have only a narrow window that shows barley one autosuggest item at a time.

pfitzseb commented 5 years ago

Fixed on latest version.