微信回复文字格式不一致,微信回复换行处理

This commit is contained in:
txz 2016-06-08 15:02:06 +08:00
parent 24a17d719e
commit 5f26e9e3ee
28 changed files with 3047 additions and 3054 deletions

View File

@ -8,7 +8,7 @@
<div class="post-title mb5"><span class="c-grey3 f15 fb">{{blog.title}}</span><img ng-if="blog.locked" src="/images/locked.png" style="display:inline-block;" /></div>
<div class="post-title"><a herf="javascript:void(0);" class="mr10">{{blog.user.realname}}</a>发表博客</div>
<div class="cl"></div>
<div class="f13 c-grey3 mt10" ng-bind-html="blog.content|safeHtml"></div>
<div class="f13 c-grey3 mt10 text-control" ng-bind-html="blog.content|safeHtml"></div>
<div class="cl"></div>
<span class="c-grey f13 mt10 fl">{{blog.created_at}}</span>
<div class="cl"></div>
@ -24,7 +24,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></div>
<div class="post-reply-date fl">{{journal.lasted_comment}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -15,7 +15,7 @@
<td class="text-nowrap v-top">&nbsp;&nbsp;&nbsp;源:</td>
<td>{{discussion.course_project_name}}&nbsp;&nbsp;|&nbsp;&nbsp;课程问答区</td>
</tr></table>
<div class="f13 c-grey3 mt10" ng-bind-html="discussion.content|safeHtml"></div>
<div class="f13 c-grey3 mt10 text-control" ng-bind-html="discussion.content|safeHtml"></div>
<div class="cl"></div>
<span class="c-grey f13 mt10 fl">{{discussion.created_on}}</span>
<div class="cl"></div>
@ -31,7 +31,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></div>
<div class="post-reply-date fl">{{journal.lasted_comment}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -14,7 +14,7 @@
<td class="text-nowrap v-top">&nbsp;&nbsp;&nbsp;源:</td>
<td>{{news.course_name}}&nbsp;&nbsp;|&nbsp;&nbsp;课程通知</td>
</tr></table>
<div class="f13 c-grey3 mt10" ng-bind-html="news.description|safeHtml"></div>
<div class="f13 c-grey3 mt10 text-control" ng-bind-html="news.description|safeHtml"></div>
<div class="cl"></div>
<span class="c-grey f13 mt10 fl">{{news.created_on}}</span>
<div class="cl"></div>
@ -30,7 +30,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{comments.author.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{comments.author.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="comments.comments|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="comments.comments|safeHtml"></div>
<div class="post-reply-date fl">{{comments.created_on}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -16,7 +16,7 @@
<td class="text-nowrap v-top">&nbsp;&nbsp;&nbsp;源:</td>
<td>{{homework.course_name}}&nbsp;&nbsp;|&nbsp;&nbsp;课程作业</td>
</tr></table>
<div class="f13 c-grey3 mt10 mb10" ng-bind-html="homework.description|safeHtml"></div>
<div class="f13 c-grey3 mt10 mb10 text-control" ng-bind-html="homework.description|safeHtml"></div>
<span class="c-grey f13">迟交扣分:{{homework.late_penalty}}分</span><br/>
<span ng-if="!homework.anonymous_comment" class="c-grey f13">缺评扣分:{{homework.absence_penalty}}分/作品<br /></span>
<span ng-if="!homework.anonymous_comment" class="c-grey f13">匿评开启时间:{{homework.evaluation_start}}<br /></span>
@ -36,7 +36,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></div>
<div class="post-reply-date fl">{{journal.lasted_comment}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -14,7 +14,7 @@
<td class="text-nowrap v-top">&nbsp;&nbsp;&nbsp;源:</td>
<td>{{issue.project_name}}&nbsp;&nbsp;|&nbsp;&nbsp;项目问题</td>
</tr></table>
<div class="f13 c-grey3 mt10 mb10" ng-bind-html="issue.description|safeHtml"></div>
<div class="f13 c-grey3 mt10 mb10 text-control" ng-bind-html="issue.description|safeHtml"></div>
<span class="c-grey f13">&nbsp;&nbsp;&nbsp;态:{{issue.issue_status}}<br>
优先级:{{issue.issue_priority}}<br />
指派给:{{issue.issue_assigned_to}}<br />
@ -34,7 +34,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></div>
<div class="post-reply-date fl">{{journal.created_on}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -7,7 +7,7 @@
<div class="post-title mb5"><a herf="javascript:void(0);" class="mr10">{{message.user.realname}}</a><span style="vertical-align:top;">给您留言了</span><br /></div>
<div class="post-title">{{message.created_on}}</div>
<div class="cl"></div>
<div class="f13 c-grey3 mt10" ng-bind-html="message.notes|safeHtml"></div>
<div class="f13 c-grey3 mt10 text-control" ng-bind-html="message.notes|safeHtml"></div>
<div class="cl"></div>
</div>
<div class="post-interactive border-bottom">
@ -22,7 +22,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.notes|safeHtml"></div>
<div class="post-reply-date fl">{{journal.lasted_comment}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -14,7 +14,7 @@
<td class="text-nowrap v-top">&nbsp;&nbsp;&nbsp;源:</td>
<td>{{discussion.course_project_name}}&nbsp;&nbsp;|&nbsp;&nbsp;项目讨论区</td>
</tr></table>
<div class="f13 c-grey3 mt10" ng-bind-html="discussion.content|safeHtml"></div>
<div class="f13 c-grey3 mt10 text-control" ng-bind-html="discussion.content|safeHtml"></div>
<div class="cl"></div>
<span class="c-grey f13 mt10 fl">{{discussion.created_on}}</span>
<div class="cl"></div>
@ -30,7 +30,7 @@
<div class="post-reply-avatar fl"><img ng-src="{{journal.user.img_url}}" width="45" height="45" class="border-radius" /></div>
<div class="ml55">
<div class="post-reply-user hidden">{{journal.user.realname}}</div>
<pre class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></pre>
<div class="post-reply-content c-grey2 mb10" ng-bind-html="journal.content|safeHtml"></div>
<div class="post-reply-date fl">{{journal.lasted_comment}}</div>
<div class="post-reply-trigger fr undis">回复</div>
</div>

View File

@ -140,12 +140,13 @@ app.factory('common', function($http, auth, $routeParams){
return;
}
var temp = data.comment.replace(/\n/g,'<br/>');
var userInfo = {
type: type,
content: data.comment,
content: temp,
openid: auth.openid()
};
//回复按钮禁用
data.disabled = true;

View File

@ -5,16 +5,8 @@
body,table,input,textarea,select,button { font-family: "微软雅黑","宋体";}
h1,h2,h3,h4,h5,p,pre {padding:0px; margin:0px;}
img {max-width:100%;}
blockquote {
border:1px solid #d4d4d4;
padding: 0.6em;
margin-left: 1.4em;
margin-right: 0.4em;
border-radius: 4px;
font-family: "Microsoft YaHei";
background-size: 100% 100%;
margin-top:5px;
}
blockquote {border:1px solid #d4d4d4; padding: 0.6em; margin-left: 1.4em; margin-right: 0.4em; border-radius: 4px; font-family: "Microsoft YaHei"; background-size: 100% 100%; margin-top:5px;}
.text-control {word-break:normal; word-wrap:break-word;}
.f12 {font-size:12px;}
.f13 {font-size:13px;}
.f15 {font-size:15px;}
@ -71,7 +63,7 @@ a.underline {text-decoration:underline;}
.more-wrap {width:100%;}
.more-events {width:98%; font-size:13px; text-align:center; margin:0 auto; padding: 5px 0; border:1px solid #e6e6e6; border-radius:3px; background-color:#f8f9fb; }
.border-bottom {border-bottom:1px solid #e6e6e6;}
.post-reply-wrap, .post-input-wrap {width:100%; line-height:18px; background-color:#f8f9fb;}
.post-reply-wrap, .post-input-wrap {width:100%; background-color:#f8f9fb;}
.post-reply-row {padding:10px; color:#9a9a9a;}
.post-reply-avatar {width:45px; height:30px; text-align:center; margin-right:10px;}
.post-reply-user {font-size:13px; text-align:left; margin-bottom:10px;}