fix(*) minor patches and fixes for specs / ui

This commit is contained in:
Ben Gotow 2015-03-05 18:49:43 -08:00
parent a347893594
commit 2437528c53
8 changed files with 48 additions and 41 deletions

View file

@ -41,7 +41,6 @@ ComposerView = React.createClass
@_prepareForDraft() @_prepareForDraft()
componentDidMount: -> componentDidMount: ->
@undoManager = new UndoManager
@keymap_unsubscriber = atom.commands.add '.composer-outer-wrap', { @keymap_unsubscriber = atom.commands.add '.composer-outer-wrap', {
'composer:show-and-focus-bcc': @_showAndFocusBcc 'composer:show-and-focus-bcc': @_showAndFocusBcc
'composer:show-and-focus-cc': @_showAndFocusCc 'composer:show-and-focus-cc': @_showAndFocusCc
@ -78,6 +77,8 @@ ComposerView = React.createClass
@_prepareForDraft() @_prepareForDraft()
_prepareForDraft: -> _prepareForDraft: ->
# UndoManager must be ready before we call _onDraftChanged for the first time
@undoManager = new UndoManager
@_proxy = DraftStore.sessionForLocalId(@props.localId) @_proxy = DraftStore.sessionForLocalId(@props.localId)
if @_proxy.draft() if @_proxy.draft()
@_onDraftChanged() @_onDraftChanged()

View file

@ -40,7 +40,7 @@ MessageList = React.createClass
render: -> render: ->
return <div></div> if not @state.current_thread? return <div></div> if not @state.current_thread?
<div class="message-list" id="message-list"> <div className="message-list" id="message-list">
<div tabIndex=1 className="messages-wrap"> <div tabIndex=1 className="messages-wrap">
{@_oldMessageListHeaders()} {@_oldMessageListHeaders()}

View file

@ -66,7 +66,7 @@ ContainerView = React.createClass
<form role="form" className="thin-container"> <form role="form" className="thin-container">
<div className="prompt">Enter your email address:</div> <div className="prompt">Enter your email address:</div>
<input type="email" placeholder="you@gmail.com" tabIndex="1" value={@state.email} onChange={@_onValueChange} id="email" /> <input className="input-bordered" type="email" placeholder="you@gmail.com" tabIndex="1" value={@state.email} onChange={@_onValueChange} id="email" />
<button className="btn btn-larger btn-gradient" style={width:215} onClick={@_fireStart}>Start using Nilas</button> <button className="btn btn-larger btn-gradient" style={width:215} onClick={@_fireStart}>Start using Nilas</button>
{@_environmentComponent()} {@_environmentComponent()}
</form> </form>

View file

@ -25,6 +25,7 @@ SearchBar = React.createClass
render: -> render: ->
inputValue = @_queryToString(@state.query) inputValue = @_queryToString(@state.query)
inputClass = React.addons.classSet inputClass = React.addons.classSet
'input-bordered': true
'empty': inputValue.length is 0 'empty': inputValue.length is 0
headerComponents = [ headerComponents = [

View file

@ -30,7 +30,7 @@ ThreadListTabular = React.createClass
unlisten() for unlisten in @unlisteners unlisten() for unlisten in @unlisteners
render: -> render: ->
<div class="thread-list" id="thread-list"> <div className="thread-list" id="thread-list">
<div tabIndex=1 <div tabIndex=1
className="thread-list-container thread-list-tabular"> className="thread-list-container thread-list-tabular">

View file

@ -76,8 +76,8 @@ describe "Contact", ->
expect(c3.displayFirstName()).toBe "" expect(c3.displayFirstName()).toBe ""
expect(c3.displayLastName()).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} c1 = new Contact {name: " Test Monkey", email: NamespaceStore.current().emailAddress}
expect(c1.displayName()).toBe "Me" expect(c1.displayName()).toBe "You"
expect(c1.displayFirstName()).toBe "Me" expect(c1.displayFirstName()).toBe "You"
expect(c1.displayLastName()).toBe "" expect(c1.displayLastName()).toBe ""

View file

@ -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%))); 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 { .btn-icon {
// background: transparent; background: transparent;
// border: 0; border: 0;
// color: @text-color-subtle; color: @text-color-subtle;
// margin-right: 10px; margin-right: 10px;
// outline: none !important; outline: none !important;
// font-size: 20px; font-size: 20px;
//
// &:last-child { &:last-child {
// margin-right: 0; margin-right: 0;
// } }
//
// &.inverse { &.inverse {
// color: @text-color-inverse; color: @text-color-inverse;
//
// &:hover { &:hover {
// color: white; color: white;
// } }
//
// &:active { &:active {
// color: @text-color-inverse; color: @text-color-inverse;
// } }
// } }
//
// &:hover { &:hover {
// cursor: pointer; cursor: pointer;
// color: @text-color-link; color: @text-color-link;
// } }
// &:active { &:active {
// color: darken(@text-color-link, 5%); color: @text-color-link-active;
// } }
// } }

View file

@ -8,11 +8,16 @@ input[type="email"] {
padding-right: @padding-xs-horizontal; padding-right: @padding-xs-horizontal;
font-size: @font-size-base; font-size: @font-size-base;
line-height: @line-height-computed; line-height: @line-height-computed;
font-weight:400;
&.input-bordered {
border-radius: @border-radius-base; border-radius: @border-radius-base;
border: 1px solid @input-border; border: 1px solid @input-border;
font-weight:400; }
} }
input[type="text"]:focus, input[type="text"]:focus,
input[type="email"]:focus, { input[type="email"]:focus, {
&.input-bordered {
box-shadow: 0 0 3px @accent-primary; box-shadow: 0 0 3px @accent-primary;
}
} }