From 2437528c536fa7d3de3b53662a56cee5df6b3ce0 Mon Sep 17 00:00:00 2001 From: Ben Gotow Date: Thu, 5 Mar 2015 18:49:43 -0800 Subject: [PATCH] fix(*) minor patches and fixes for specs / ui --- .../composer/lib/composer-view.cjsx | 3 +- .../message-list/lib/message-list.cjsx | 2 +- .../onboarding/lib/container-view.cjsx | 2 +- .../search-bar/lib/search-bar.cjsx | 1 + .../thread-list/lib/thread-list-tabular.cjsx | 2 +- spec-inbox/models/contact-spec.coffee | 6 +- static/buttons.less | 64 +++++++++---------- static/inputs.less | 9 ++- 8 files changed, 48 insertions(+), 41 deletions(-) diff --git a/internal_packages/composer/lib/composer-view.cjsx b/internal_packages/composer/lib/composer-view.cjsx index c3ed60819..72bf7aaf7 100644 --- a/internal_packages/composer/lib/composer-view.cjsx +++ b/internal_packages/composer/lib/composer-view.cjsx @@ -41,7 +41,6 @@ ComposerView = React.createClass @_prepareForDraft() componentDidMount: -> - @undoManager = new UndoManager @keymap_unsubscriber = atom.commands.add '.composer-outer-wrap', { 'composer:show-and-focus-bcc': @_showAndFocusBcc 'composer:show-and-focus-cc': @_showAndFocusCc @@ -78,6 +77,8 @@ ComposerView = React.createClass @_prepareForDraft() _prepareForDraft: -> + # UndoManager must be ready before we call _onDraftChanged for the first time + @undoManager = new UndoManager @_proxy = DraftStore.sessionForLocalId(@props.localId) if @_proxy.draft() @_onDraftChanged() diff --git a/internal_packages/message-list/lib/message-list.cjsx b/internal_packages/message-list/lib/message-list.cjsx index 720b32779..e163e3335 100755 --- a/internal_packages/message-list/lib/message-list.cjsx +++ b/internal_packages/message-list/lib/message-list.cjsx @@ -40,7 +40,7 @@ MessageList = React.createClass render: -> return
if not @state.current_thread? -
+
{@_oldMessageListHeaders()} diff --git a/internal_packages/onboarding/lib/container-view.cjsx b/internal_packages/onboarding/lib/container-view.cjsx index ab599a675..0d4c16c9e 100644 --- a/internal_packages/onboarding/lib/container-view.cjsx +++ b/internal_packages/onboarding/lib/container-view.cjsx @@ -66,7 +66,7 @@ ContainerView = React.createClass
Enter your email address:
- + {@_environmentComponent()}
diff --git a/internal_packages/search-bar/lib/search-bar.cjsx b/internal_packages/search-bar/lib/search-bar.cjsx index 03b7c7758..861b24880 100644 --- a/internal_packages/search-bar/lib/search-bar.cjsx +++ b/internal_packages/search-bar/lib/search-bar.cjsx @@ -25,6 +25,7 @@ SearchBar = React.createClass render: -> inputValue = @_queryToString(@state.query) inputClass = React.addons.classSet + 'input-bordered': true 'empty': inputValue.length is 0 headerComponents = [ diff --git a/internal_packages/thread-list/lib/thread-list-tabular.cjsx b/internal_packages/thread-list/lib/thread-list-tabular.cjsx index ffdb5d792..59d8987e8 100644 --- a/internal_packages/thread-list/lib/thread-list-tabular.cjsx +++ b/internal_packages/thread-list/lib/thread-list-tabular.cjsx @@ -30,7 +30,7 @@ ThreadListTabular = React.createClass unlisten() for unlisten in @unlisteners render: -> -
+
diff --git a/spec-inbox/models/contact-spec.coffee b/spec-inbox/models/contact-spec.coffee index 26919071c..14a8c3161 100644 --- a/spec-inbox/models/contact-spec.coffee +++ b/spec-inbox/models/contact-spec.coffee @@ -76,8 +76,8 @@ describe "Contact", -> expect(c3.displayFirstName()).toBe "" expect(c3.displayLastName()).toBe "" - it "should properly return `Me` as the display name for the current user", -> + it "should properly return `You` as the display name for the current user", -> c1 = new Contact {name: " Test Monkey", email: NamespaceStore.current().emailAddress} - expect(c1.displayName()).toBe "Me" - expect(c1.displayFirstName()).toBe "Me" + expect(c1.displayName()).toBe "You" + expect(c1.displayFirstName()).toBe "You" expect(c1.displayLastName()).toBe "" diff --git a/static/buttons.less b/static/buttons.less index d1e8a77dd..e5113e327 100644 --- a/static/buttons.less +++ b/static/buttons.less @@ -109,35 +109,35 @@ background: -webkit-gradient(linear, left top, left bottom, from(darken(@btn-default-bg-color, 9%)), to(darken(@btn-default-bg-color, 13.5%))); } -// .btn-icon { -// background: transparent; -// border: 0; -// color: @text-color-subtle; -// margin-right: 10px; -// outline: none !important; -// font-size: 20px; -// -// &:last-child { -// margin-right: 0; -// } -// -// &.inverse { -// color: @text-color-inverse; -// -// &:hover { -// color: white; -// } -// -// &:active { -// color: @text-color-inverse; -// } -// } -// -// &:hover { -// cursor: pointer; -// color: @text-color-link; -// } -// &:active { -// color: darken(@text-color-link, 5%); -// } -// } +.btn-icon { + background: transparent; + border: 0; + color: @text-color-subtle; + margin-right: 10px; + outline: none !important; + font-size: 20px; + + &:last-child { + margin-right: 0; + } + + &.inverse { + color: @text-color-inverse; + + &:hover { + color: white; + } + + &:active { + color: @text-color-inverse; + } + } + + &:hover { + cursor: pointer; + color: @text-color-link; + } + &:active { + color: @text-color-link-active; + } +} diff --git a/static/inputs.less b/static/inputs.less index e90f472a3..2b6847271 100644 --- a/static/inputs.less +++ b/static/inputs.less @@ -8,11 +8,16 @@ input[type="email"] { padding-right: @padding-xs-horizontal; font-size: @font-size-base; line-height: @line-height-computed; - border-radius: @border-radius-base; - border: 1px solid @input-border; font-weight:400; + + &.input-bordered { + border-radius: @border-radius-base; + border: 1px solid @input-border; + } } input[type="text"]:focus, input[type="email"]:focus, { + &.input-bordered { box-shadow: 0 0 3px @accent-primary; + } } \ No newline at end of file