Skip to content
This repository was archived by the owner on Sep 6, 2021. It is now read-only.

Commit 188c125

Browse files
shubhsnovswmitra
authored andcommitted
Fix for CodeHint Description CSS Issue (#14728)
* Fix for overlapping dropdown div * Cleanup #1
1 parent 1b13b49 commit 188c125

File tree

2 files changed

+2
-7
lines changed

2 files changed

+2
-7
lines changed

src/editor/CodeHintList.js

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -266,16 +266,12 @@ define(function (require, exports, module) {
266266
// attach to DOM
267267
$parent.append($ul);
268268

269-
$parent.find(".hint-list-offset").remove();
270-
$("<div class='hint-list-offset'></div>").appendTo($parent);
271-
272269
// If a a description field requested attach one
273270
if (this.enableDescription) {
274271
// Remove the desc element first to ensure DOM order
275272
$parent.find("#codehint-desc").remove();
276273
$parent.append("<div id='codehint-desc' class='dropdown-menu quiet-scrollbars'></div>");
277274
$ul.addClass("withDesc");
278-
$parent.find(".hint-list-offset").addClass("withDesc");
279275
}
280276
this._setSelectedIndex(selectInitial ? 0 : -1);
281277
}
@@ -323,7 +319,7 @@ define(function (require, exports, module) {
323319
if (descOffset === 0) {
324320
descOffset = menuHeight - descOverhang;
325321
}
326-
this.$hintMenu.find(".hint-list-offset").css("height", descOffset - 1);
322+
this.$hintMenu.find("#codehint-desc").css("margin-top", descOffset - 1);
327323

328324
return {left: posLeft, top: posTop, width: availableWidth};
329325
};

src/styles/brackets_patterns_override.less

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -586,11 +586,10 @@ a:focus {
586586

587587
#codehint-desc {
588588
background: @bc-codehint-desc;
589-
position: relative;
589+
position: absolute;
590590
width: 100%;
591591
box-sizing: border-box;
592592
float: left;
593-
top: 34px;
594593
border-radius: 1px !important;
595594
border-top-left-radius: 0px !important;
596595
border-top-right-radius: 0px !important;

0 commit comments

Comments
 (0)