Skip to content

Commit d6522da

Browse files
author
Narciso Jaramillo
committed
Merge pull request adobe#3634 from adobe/larz/quick-open-tweaks
Visual tweaks for the quick open drop-down.
2 parents 4fda143 + cc37dbb commit d6522da

File tree

4 files changed

+80
-36
lines changed

4 files changed

+80
-36
lines changed

src/editor/EditorManager.js

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,6 @@ define(function (require, exports, module) {
5757
PerfUtils = require("utils/PerfUtils"),
5858
Editor = require("editor/Editor").Editor,
5959
InlineTextEditor = require("editor/InlineTextEditor").InlineTextEditor,
60-
ViewUtils = require("utils/ViewUtils"),
6160
Strings = require("strings");
6261

6362
/** @type {jQueryObject} DOM node that contains all editors (visible and hidden alike) */
@@ -529,17 +528,11 @@ define(function (require, exports, module) {
529528
container = _editorHolder.get(0);
530529

531530
var perfTimerName = PerfUtils.markStart("EditorManager._onCurrentDocumentChange():\t" + (!doc || doc.file.fullPath));
532-
533-
// Remove scroller-shadow from the current editor
534-
if (_currentEditor) {
535-
ViewUtils.removeScrollerShadow(container, _currentEditor);
536-
}
537531

538532
// Update the UI to show the right editor (or nothing), and also dispose old editor if no
539533
// longer needed.
540534
if (doc) {
541535
_showEditor(doc);
542-
ViewUtils.addScrollerShadow(container, _currentEditor);
543536
} else {
544537
_showNoEditor();
545538
}

src/styles/brackets.less

Lines changed: 36 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,8 @@ a, img {
104104
}
105105

106106
#titlebar, .modal-bar {
107-
.box-shadow(0 1px 1px 0 fadeout(@bc-black, 90%));
107+
border-bottom: 1px solid @tc-gray-panel-border;
108+
box-shadow: @tc-small-shadow-bottom;
108109

109110
// Make sure the bottom box-shadow goes above the editor (position: relative needed to start a new stacking group)
110111
position: relative;
@@ -456,10 +457,6 @@ a, img {
456457
}
457458
}
458459

459-
#editor-holder .scroller-shadow {
460-
width: 100%;
461-
}
462-
463460
.scroller-shadow {
464461
background-size: 100%;
465462
background-repeat: no-repeat;
@@ -713,8 +710,8 @@ a, img {
713710

714711
font-family: @fontstack-sans-serif;
715712
font-size: 13px;
716-
color: @content-color;
717-
background: #eee;
713+
color: @tc-text;
714+
background: @tc-gray-panel;
718715
padding: 5px 4px 4px 14px;
719716
overflow: hidden;
720717

@@ -726,14 +723,12 @@ a, img {
726723

727724
.modal-bar input {
728725
font-family: @fontstack-sans-serif;
729-
border: 1px solid @content-color-weaker;
730726
outline: none;
731-
background: @background-color-3;
732727
width: 20em;
733728
margin: .3em .3em;
734-
color: inherit;
735729
&.no-results {
736-
background-color: mix(@background-color-3, #FF0000, 70%);
730+
border: 1px solid #bc0023;
731+
box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.12), 0 0 0 2px rgba(255, 0, 120, 0.5);
737732
}
738733
}
739734

@@ -774,39 +769,51 @@ a, img {
774769

775770
.smart_autocomplete_container {
776771

777-
border: 1px solid #999;
778-
background-color: #FFFFFF;
772+
// the borders show up even if the container is empty, must set height to zero using JS.
773+
border: 1px solid @tc-gray-panel-border;
774+
775+
background-color: @tc-gray-panel;
776+
border-radius: 0 0 4px 4px;
777+
box-shadow: @tc-normal-shadow-bottom;
778+
779+
// so that border won't show when height is 0.
780+
box-sizing: border-box;
781+
782+
// using this to fix the spacing that breaks item seperators and had to use !important to override inline css
783+
width: 400px !important;
779784

780785
/* smart auto complete doesn't correctly position the container
781786
* so these specific padding and margin values are necessary*/
782-
padding: 0px 8px 0px 0px;
783-
margin: 9px 0px 0px 0px;
787+
padding: 0px;
788+
margin: 9px 0 0;
784789

785790
.quick-open-path {
791+
color: #666;
786792
font-size: 11px;
787-
color: gray;
793+
letter-spacing: 0.04em;
794+
line-height: 11px;
788795
}
789796

790797
li {
791-
color: black;
792-
border-bottom: 1px solid;
798+
color: #222;
799+
line-height: 15px;
793800
list-style: none;
794801
cursor: default;
795-
padding: 0px 2px 0px 4px;
802+
padding: 6px 10px;
803+
}
804+
805+
li:nth-child(odd) {
806+
background-color: #e6e9e9;
807+
}
808+
809+
li.smart_autocomplete_highlight {
810+
background-color: @tc-highlight;
796811
}
797812
}
798813

799-
li.smart_autocomplete_highlight {
800-
background-color: #e0f0fa;
801-
}
802-
803-
.quicksearch-pathmatch {
804-
font-weight: bold;
805-
color: #555;
806-
}
807-
814+
.quicksearch-pathmatch,
808815
.quicksearch-namematch {
809-
font-weight: bold;
816+
font-weight: @font-weight-semibold;
810817
}
811818

812819

src/styles/brackets_colors.less

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,3 +64,22 @@
6464
@bc-light-blue: #d8e0e8;
6565
@bc-cyan: #2aa198;
6666
@bc-green: #859900;
67+
68+
// TopCoat colors and styles, putting them here for now; let me know if there's a better place for these.
69+
@tc-gray-panel: #dfe2e2;
70+
@tc-gray-panel-border: rgba(0, 0, 0, 0.12);
71+
@tc-gray-panel-bevel: inset 0 1px 0 rgba(255, 255, 255, 0.6);
72+
@tc-gray-panel-top-bar: #d4d7d7;
73+
@tc-gray-panel-top-bar-shadow: 1px solid rgba(0, 0, 0, 0.03);
74+
@tc-gray-component-border: #9c9e9e;
75+
@tc-gray-component-focused-border: #0940fd;
76+
77+
@tc-small-shadow-top: 0 -1px 3px rgba(0, 0, 0, 0.12);
78+
@tc-small-shadow-bottom: 0 1px 3px rgba(0, 0, 0, 0.12);
79+
@tc-normal-shadow-bottom: 0 5px 10px rgba(0, 0, 0, 0.1);
80+
@tc-highlight: #e0f0fa;
81+
@tc-hover-highlight: rgba(255, 255, 255, 0.6);
82+
@tc-text: #454545;
83+
@tc-call-to-action: #288edf;
84+
@tc-call-to-action-text: #ffffff;
85+

src/styles/brackets_patterns_override.less

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -563,6 +563,29 @@
563563
}
564564
}
565565

566+
/* Input */
567+
input {
568+
background-color: #fff;
569+
border: 1px solid #9c9e9e;
570+
.border-radius(3px);
571+
@shadow: inset 0 1px 0 rgba(0, 0, 0, 0.12);
572+
573+
// Placeholder text gets special styles; can't be bundled together though for some reason
574+
&::-webkit-input-placeholder {
575+
color: #888;
576+
}
577+
// Focus states (we use .focused since IE8 and down doesn't support :focus)
578+
&:focus,
579+
&.focused {
580+
outline: 0;
581+
background-color: #fff;
582+
color: #000;
583+
text-shadow: none;
584+
border: 1px solid @tc-gray-component-focused-border;
585+
box-shadow: inset 0 1px 0 rgba(0, 0, 0, 0.12), 0 0 0 2px #6fb5f1;
586+
}
587+
}
588+
566589
/* Twipsy tooltips */
567590
.twipsy-inner {
568591
max-width: none;
@@ -592,6 +615,7 @@
592615

593616
// Focus state for keyboard and accessibility
594617
&:focus {
618+
border: 1px solid @tc-gray-component-focused-border;
595619
box-shadow: inset 0 1px 0 #fff, 0 0 0 2px #6fb5f1;
596620
outline: none;
597621
}
@@ -612,6 +636,7 @@
612636
}
613637

614638
&:focus {
639+
border: 1px solid @tc-gray-component-focused-border;
615640
box-shadow: inset 0 1px 0 rgba(255,255,255,0.36), 0 0 0 2px #6fb5f1;
616641
outline: none;
617642
}

0 commit comments

Comments
 (0)