Merge pull request #4461 from negue/markdownText

change markdown ngModel to text attribute
This commit is contained in:
negue 2015-01-05 22:12:06 +01:00
commit ad8add58d7
8 changed files with 12 additions and 12 deletions

View file

@ -33,5 +33,5 @@
li.filters-tags(ng-class='{active: user.filters[tag.id], challenge: tag.challenge}', ng-repeat='tag in user.tags', bindonce='user.tags')
a(ng-click='toggleFilter(tag)')
span.glyphicon.glyphicon-bullhorn(ng-if="::tag.challenge")
markdown(ng-model='tag.name')
markdown(text='tag.name')
// <li class="{#unless activeFilters(users[_userId].filters)}hidden{/}">

View file

@ -224,7 +224,7 @@ script(id='partials/options.profile.profile.html', type='text/ng-template')
| &nbsp;-
h4=env.t('displayBlurb')
markdown(ng-show='profile.profile.blurb', ng-model='profile.profile.blurb')
markdown(ng-show='profile.profile.blurb', text='profile.profile.blurb')
span.muted(ng-hide='profile.profile.blurb') -&nbsp;
=env.t('none')
| &nbsp;-

View file

@ -40,7 +40,7 @@ script(type='text/ng-template', id='partials/options.social.challenges.detail.ht
hr
.well(bindonce='challenge', ng-if='challenge.description')
markdown(ng-model='challenge.description')
markdown(text='challenge.description')
.modal-body=env.t('challengeDiscription')
habitrpg-tasks(obj='challenge', main=false)

View file

@ -12,7 +12,7 @@ mixin chatMessages(inbox)
span {{::message.user}}&nbsp;
span(ng-class='userAdminGlyphiconStyleFromLevel(message.contributor.level)')
// this invisible username label is here to push the message text far enough right that the visible label can be floated to this point without covering up any of the text
markdown(ng-model='::message.text')
markdown(text='::message.text')
| -
span.muted.time(from-now='::message.timestamp' tooltip="{{::message.timestamp | date:user.preferences.dateFormat.concat(' HH:mm:ss')}}")
unless inbox

View file

@ -44,7 +44,7 @@ a.pull-right.gem-wallet(ng-if='group.type!="party"', popover-trigger='mouseenter
div(ng-show='!group._editing')
img.pull-right(ng-show='group.logo', ng-src='{{group.logo}}')
markdown(ng-model='group.description')
markdown(text='group.description')
hr
small.muted Group ID: {{group._id}}
@ -113,7 +113,7 @@ a.pull-right.gem-wallet(ng-if='group.type!="party"', popover-trigger='mouseenter
.arrow
h3.popover-title {{Members.members[group.leader].profile.name}}
.popover-content
markdown(ng-model='group.leaderMessage')
markdown(text='group.leaderMessage')
div(ng-controller='ChatCtrl')
h3=env.t('chat')
include ./chat-box

View file

@ -93,7 +93,7 @@ script(type='text/ng-template', id='partials/options.social.hall.heroes.html')
td {{hero.contributor.level}}
td {{hero.contributor.text}}
td
markdown(ng-model='hero.contributor.contributions', target='_blank')
markdown(text='hero.contributor.contributions', target='_blank')
script(type='text/ng-template', id='partials/options.social.hall.patrons.html')
table.table.table-striped(infinite-scroll="loadMore()")

View file

@ -8,7 +8,7 @@ script(type='text/ng-template', id='modals/member.html')
.row
.col-md-6
img(ng-show='::profile.profile.imageUrl', ng-src='{{::profile.profile.imageUrl}}')
markdown(ng-show='::profile.profile.blurb', ng-model='::profile.profile.blurb')
markdown(ng-show='::profile.profile.blurb', text='::profile.profile.blurb')
ul.muted.list-unstyled(ng-if='::profile.auth.timestamps')
li {{profile._id}}
li(ng-show='::profile.auth.timestamps.created')
@ -94,7 +94,7 @@ script(type='text/ng-template', id='modals/abuse-flag.html')
h4!=env.t('abuseFlagModalHeading', {name: "<span class='text-danger'>{{profile.profile.name}}</span>"})
.modal-body
blockquote
markdown(ng-model="abuseObject.text")
markdown(text="abuseObject.text")
p!=env.t('abuseFlagModalBody', {firstLinkStart: "<a href='/static/community-guidelines' target='_blank'>", secondLinkStart: "<a href='/static/terms' target='_blank'>", linkEnd: "</a>"})
.modal-footer
button.pull-left.btn.btn-danger(ng-click='clearFlagCount(abuseObject, groupId)', ng-if='user.contributor.admin && abuseObject.flagCount >= 2')

View file

@ -79,14 +79,14 @@ li(bindonce='list', id='task-{{::task.id}}', ng-repeat='task in obj[list.type+"s
// main content
div.task-text(ng-dblclick='task._editing ? saveTask(task) : editTask(task)')
markdown(ng-model='task.text',target='_blank')
markdown(text='task.text',target='_blank')
//-| {{task.text}}
div(ng-if='task.checklist && !$state.includes("options.social.challenges") && !task.collapseChecklist && !task._editing')
fieldset.option-group.task-checklist
label.checkbox(ng-repeat='item in task.checklist')
input(type='checkbox',ng-model='item.completed',ng-change='saveTask(task,true)')
markdown(ng-model='item.text',target='_blank')
markdown(text='item.text',target='_blank')
// edit/options dialog
div(ng-if='task._editing')
@ -198,7 +198,7 @@ li(bindonce='list', id='task-{{::task.id}}', ng-repeat='task in obj[list.type+"s
p.option-title.mega(ng-click='task._tags = !task._tags', tooltip=env.t('expandCollapse'))=env.t('tags')
label.checkbox(ng-repeat='tag in user.tags', ng-class="{visuallyhidden: task._tags}")
input(type='checkbox', ng-model='task.tags[tag.id]')
markdown(ng-model='tag.name')
markdown(text='tag.name')
// Advanced Options
span(ng-if='::task.type!="reward"')