Open platform to collect and prioritize feedback
neutral theme (#97)
Guilherme Oenning18bcd23ac833
diff --git a/public/components/CommentInput.tsx b/public/components/CommentInput.tsxindex 4757242b1..f46fc325a 100644--- a/public/components/CommentInput.tsx+++ b/public/components/CommentInput.tsx@@ -54,9 +54,9 @@ export class CommentInput extends React.Component<CommentInputProps, CommentInpu</Button>: <div className="ui message signin-message"><div className="header">- Hey! We need to know who you are+ Hey, we need to know who you are!</div>- <p>This only takes a second and you'll be good to go!</p>+ <p>It's only one second and you'll be good to go!</p><SocialSignInList orientation="horizontal" size="small" /></div>;@@ -64,7 +64,8 @@ export class CommentInput extends React.Component<CommentInputProps, CommentInpu<DisplayError error={this.state.error} /><div className="field"><textarea onKeyUp={(e) => { this.setState({ content: e.currentTarget.value }); }}- placeholder="Leave your comment here..."></textarea>+ rows={3}+ placeholder="Write a comment..."></textarea></div>{ (this.state.content || user) && button }</div>;diff --git a/public/components/SupportCounter.tsx b/public/components/SupportCounter.tsxindex 0fabacaff..94d61b792 100644--- a/public/components/SupportCounter.tsx+++ b/public/components/SupportCounter.tsx@@ -64,41 +64,28 @@ export class SupportCounter extends React.Component<SupportCounterProps, Support} else {// TODO: handle this. we should have a global alert box}-}public render() {const noTouch = !('ontouchstart' in window);-const status = IdeaStatus.Get(this.props.idea.status);- const support = <div className={ `ui mini inverted main-color button ${noTouch ? 'animated' : 'not-animated'}` }- onClick={async () => await this.supportOrUndo()}>- <div className="visible content">Want</div>- { noTouch && <div className="hidden content">- <i className="heart icon"></i>- </div> }- </div>;-- const undo = <div className={ `ui mini main-color button ${noTouch ? 'animated' : 'not-animated'}` }+ const vote = <button ref={(e) => { this.elem = e!; } }+ className={`ui button ${noTouch ? 'no-touch' : ''} ${this.state.supported ? 'supported' : ''} `}onClick={async () => await this.supportOrUndo()}>- <div className="visible content"><i className="heart icon"></i></div>- { noTouch && <div className="hidden content">Undo</div> }- </div>;+ { this.state.total }+ <i className="medium thumbs up icon"></i>+ </button>;- const disabled = <div className="ui disabled mini button">- <div className="visible content">Votes</div>- </div>;+ const disabled = <div className="ui button disabled">+ { this.state.total }+ <i className="medium thumbs up icon"></i>+ </div>;return <div>- <div className="support-counter ui small statistics">- <div ref={(e) => { this.elem = e!; } } className="statistic">- <div className="value">- { this.state.total }- </div>- { status.closed ? disabled : this.state.supported ? undo : support }- </div>+ <div className="support-counter ui">+ { status.closed ? disabled : vote }</div><div ref={(e) => { this.list = e!; } } className="ui popup transition hidden signin-message"><p className="header">Hey! We need to know who you are</p>diff --git a/public/components/common/Header.tsx b/public/components/common/Header.tsxindex eb7ed5966..d9d5f4bfa 100644--- a/public/components/common/Header.tsx+++ b/public/components/common/Header.tsx@@ -58,7 +58,7 @@ export class Header extends React.Component<{}, {}> {</a><a ref={(e) => { this.dropdown = e!; } } className="item right signin"><Gravatar name={this.user.name} hash={this.user.gravatar} />- { this.user.name || 'Sign in' }+ { this.user.name || 'Log in' }<i className="dropdown icon"></i></a></div>diff --git a/public/components/common/SocialSignInButton.tsx b/public/components/common/SocialSignInButton.tsxindex f97895ba4..271c91a2b 100644--- a/public/components/common/SocialSignInButton.tsx+++ b/public/components/common/SocialSignInButton.tsx@@ -40,7 +40,7 @@ export class SocialSignInButton extends React.Component<SocialSignInButtonProps,return <Button href={href} className={classes}><i className={'icon ' + providers[this.props.provider].icon}></i>- { this.props.size === 'normal' && `Sign in with ${providers[this.props.provider].name}` }+ { this.props.size === 'normal' && `Log in with ${providers[this.props.provider].name}` }</Button>;}}diff --git a/public/pages/ShowIdeaPage.tsx b/public/pages/ShowIdeaPage.tsxindex 31bcaf04a..c93030c4b 100644--- a/public/pages/ShowIdeaPage.tsx+++ b/public/pages/ShowIdeaPage.tsx@@ -60,9 +60,10 @@ export class ShowIdeaPage extends React.Component<{}, {}> {<h1 className="ui header">{ this.idea.title }</h1><p>- #{ this.idea.number } shared by - <Gravatar name={this.idea.user.name} hash={this.idea.user.gravatar}/> <u>{this.idea.user.name}</u> - <Moment date={this.idea.createdOn} />+ <Gravatar name={this.idea.user.name} hash={this.idea.user.gravatar}/> <b>{this.idea.user.name}</b> + <span className="info">+ <Moment date={this.idea.createdOn} />+ </span></p></div></div>diff --git a/public/pages/home/IdeaFilter.tsx b/public/pages/home/IdeaFilter.tsxindex 71ca56447..fd672c4e0 100644--- a/public/pages/home/IdeaFilter.tsx+++ b/public/pages/home/IdeaFilter.tsx@@ -46,7 +46,6 @@ export class IdeaFilter extends React.Component<IdeaFilterProps, {}> {public render() {return <h4 className="ui header">- <i className="filter icon"></i><div className="content">Showing {' '}<div className="ui inline dropdown" ref={(e) => this.element = e!}>diff --git a/public/pages/home/IdeaInput.tsx b/public/pages/home/IdeaInput.tsxindex d0fb7c14c..66964ef00 100644--- a/public/pages/home/IdeaInput.tsx+++ b/public/pages/home/IdeaInput.tsx@@ -71,15 +71,15 @@ export class IdeaInput extends React.Component<IdeaInputProps, IdeaInputState> {placeholder="Describe your idea (optional)"></textarea></div><Button className={buttonCss} onClick={() => this.form.submit() }>- Submit Idea+ Submit</Button></div> :<div><div className="ui message signin-message"><div className="header">- Hey! We need to know who you are+ Hey, we need to know who you are!</div>- <p>This only takes a second and you'll be good to go!</p>+ <p>It's only one second and you'll be good to go!</p><SocialSignInList orientation="horizontal" size="small" /></div></div>;diff --git a/public/pages/home/SiteHomePage.scss b/public/pages/home/SiteHomePage.scssindex 9ede2b4a0..4d906982d 100644--- a/public/pages/home/SiteHomePage.scss+++ b/public/pages/home/SiteHomePage.scss@@ -12,10 +12,8 @@}> .item > .content {- margin-left: 20px;-.description {- min-height: 10px;+ min-height: 40px;}}}@@ -32,24 +30,6 @@margin: 10px 0px;}- #new-idea-input::-webkit-input-placeholder { /* WebKit, Blink, Edge */- color: lighten($main-color, 25);- }- #new-idea-input:-moz-placeholder { /* Mozilla Firefox 4 to 18 */- color: lighten($main-color, 25);- opacity: 1;- }- #new-idea-input::-moz-placeholder { /* Mozilla Firefox 19+ */- color: lighten($main-color, 25);- opacity: 1;- }- #new-idea-input:-ms-input-placeholder { /* Internet Explorer 10-11 */- color: lighten($main-color, 25);- }- #new-idea-input::-ms-input-placeholder { /* Microsoft Edge */- color: lighten($main-color, 25);- }-.idea-title {color: rgb(162, 145, 251);cursor: pointer;diff --git a/public/pages/home/SiteHomePage.tsx b/public/pages/home/SiteHomePage.tsxindex 8f1cf0e66..e8e33d836 100644--- a/public/pages/home/SiteHomePage.tsx+++ b/public/pages/home/SiteHomePage.tsx@@ -40,15 +40,17 @@ export class SiteHomePage extends React.Component<{}, SiteHomePageState> {<div className="item" key={x.id}><SupportCounter user={this.user} idea={x} /><div className="content">+ { x.totalComments > 0 && <div className="info right">+ { x.totalComments } <i className="comments outline icon"/>+ </div> }<a href={`/ideas/${x.number}/${x.slug}`} className="header">{ x.title }</a><MultiLineText className="description" text={ x.description } markdown={true} />- <div className="extra">- shared <Moment date={x.createdOn} />- <div style={{float: 'right'}}>{ x.totalComments } <i className="comments icon"/></div>- </div><ShowIdeaResponse status={ x.status } response={ x.response } />+ <div className="info">+ <Moment date={x.createdOn} />+ </div></div></div>);diff --git a/public/styles/main.scss b/public/styles/main.scssindex 6c85cd96f..b5fe83d1c 100644--- a/public/styles/main.scss+++ b/public/styles/main.scss@@ -1,10 +1,6 @@@import 'variables.scss';@import 'form.scss';-.idea-header {- margin-left: 20px;-}-.center {text-align: center;}@@ -15,18 +11,28 @@ body {#menu {margin-top: 0px;- background-color: $main-color;+ background-color: $menu-color;margin-bottom: 30px;height: 40px;+div, a {border: none;- color: textColorFor($main-color);+ color: textColorFor($menu-color);}a::before {content: none;}}+.info {+ color: rgba(0,0,0,.4);+ font-size: 90%;+}++.info.right {+ float: right;+}+code {padding: 2px 4px;font-size: 90%;@@ -41,6 +47,10 @@ code {}}+.avatar {+ border-radius: 500rem !important;+}+.no-border {border-radius: 0px !important;}@@ -50,19 +60,27 @@ code {}.support-counter {- width: 130px;+ width: 60px;+ margin-right: 10px;- .statistic {+ .button,+ .button.disabled {margin: 0 auto !important;+ padding: 0.5rem 1rem !important;+ background-color: #fff !important;+ box-shadow: 0 0 0 1px rgba(34,36,38,.15) inset !important;}- .button {- width: 60px;- margin: 0 auto !important;+ .button.supported,+ .button.no-touch:hover {+ background-color: lighten($main-color, 49%) !important;+ color: $main-color;+ box-shadow: 0 0 0 1px $main-color inset !important;}i.icon {- margin: 0px;+ margin: 3px !important;+ display: block;}}diff --git a/public/styles/variables.scss b/public/styles/variables.scssindex 71f238c4a..2f2607db8 100644--- a/public/styles/variables.scss+++ b/public/styles/variables.scss@@ -1,5 +1,6 @@-$main-color: #744fb7;+$main-color: #0069ff; //#0c9$bg-color: #f9f9f9;+$menu-color: #fff;@function textColorFor($color) {@if (lightness($color) > 60) {diff --git a/tests/submit-ideas.ts b/tests/submit-ideas.tsindex cbbcf94a2..290244d3d 100644--- a/tests/submit-ideas.ts+++ b/tests/submit-ideas.ts@@ -10,7 +10,7 @@ describe('Submit ideas', () => {// Assertawait Promise.all([- ensure(pages.home.UserMenu).textIs('Sign in'),+ ensure(pages.home.UserMenu).textIs('Log in'),ensure(pages.home.SubmitIdea).isNotVisible(),ensure(pages.home.IdeaDescription).isNotVisible(),]);