From 12a23429d692709dc36a8eefe8966a8d0a0c9fd6 Mon Sep 17 00:00:00 2001 From: yafeilee <lyfi2003@gmail.com> Date: Thu, 3 Apr 2014 20:28:49 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E8=AF=84=E8=AE=BA=E7=9A=84bu?= =?UTF-8?q?tton=E6=A0=B7=E5=BC=8F=E5=9C=A8=E7=A6=81=E7=94=A8=E6=97=B6?= =?UTF-8?q?=E6=9B=B4=E6=9C=89=E6=95=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/assets/stylesheets/comments.css.scss | 11 +++++++++++ app/views/blogs/_comment.html.slim | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/app/assets/stylesheets/comments.css.scss b/app/assets/stylesheets/comments.css.scss index 96cf18d..8a16d43 100644 --- a/app/assets/stylesheets/comments.css.scss +++ b/app/assets/stylesheets/comments.css.scss @@ -55,6 +55,17 @@ } } +.comment-submit[disabled] { + opacity: 0.4; + cursor: not-allowed; +} + +.comment-submit { + background-color: #008cba; + opacity: 0.8; +} + + .comment-success { color: #66FAB5; } diff --git a/app/views/blogs/_comment.html.slim b/app/views/blogs/_comment.html.slim index 42c33fd..9b828cf 100644 --- a/app/views/blogs/_comment.html.slim +++ b/app/views/blogs/_comment.html.slim @@ -8,7 +8,7 @@ .small-12.large-6.columns = text_field_tag(:name, nil, placeholder: '你的名字', 'ng-model'=> 'name', 'ng-required'=> 'true') = text_field_tag(:email, nil, placeholder: '你的邮箱', 'ng-model'=> 'email', 'ng-pattern'=>"/^.+@.+$/", 'ng-required'=>"true") - button ng-click="submit()" ng-disabled="form.$invalid" 发表 + button.comment-submit ng-click="submit()" ng-disabled="form.$invalid" 发表 p.comment-success ng-show="publish_success" 发布成功 p.comment-fail ng-show="publish_success == false" 发布失败: {{ publish_fail_msg }} .comment-diag ng-cloak=""