Merge pull request #4593 from techAPJ/composer
FEATURE: show the reply title and the reply icon in the minimized editor
This commit is contained in:
commit
4381afac1b
|
@ -6,6 +6,8 @@ import { default as computed, observes } from 'ember-addons/ember-computed-decor
|
||||||
import { relativeAge } from 'discourse/lib/formatter';
|
import { relativeAge } from 'discourse/lib/formatter';
|
||||||
import InputValidation from 'discourse/models/input-validation';
|
import InputValidation from 'discourse/models/input-validation';
|
||||||
import { getOwner } from 'discourse-common/lib/get-owner';
|
import { getOwner } from 'discourse-common/lib/get-owner';
|
||||||
|
import { escapeExpression } from 'discourse/lib/utilities';
|
||||||
|
import { emojiUnescape } from 'discourse/lib/text';
|
||||||
|
|
||||||
function loadDraft(store, opts) {
|
function loadDraft(store, opts) {
|
||||||
opts = opts || {};
|
opts = opts || {};
|
||||||
|
@ -195,6 +197,11 @@ export default Ember.Controller.extend({
|
||||||
return this.get('model.creatingPrivateMessage');
|
return this.get('model.creatingPrivateMessage');
|
||||||
}.property('model.creatingPrivateMessage', 'model.targetUsernames'),
|
}.property('model.creatingPrivateMessage', 'model.targetUsernames'),
|
||||||
|
|
||||||
|
@computed('model.topic')
|
||||||
|
draftTitle(topic) {
|
||||||
|
return emojiUnescape(escapeExpression(topic.get('title')));
|
||||||
|
},
|
||||||
|
|
||||||
actions: {
|
actions: {
|
||||||
|
|
||||||
typed() {
|
typed() {
|
||||||
|
|
|
@ -135,7 +135,11 @@
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
<div class='draft-text'>
|
<div class='draft-text'>
|
||||||
{{i18n 'composer.saved_draft'}}
|
{{#if model.topic}}
|
||||||
|
{{fa-icon "reply"}} {{{draftTitle}}}
|
||||||
|
{{else}}
|
||||||
|
{{i18n "composer.saved_draft"}}
|
||||||
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -99,6 +99,10 @@ input {
|
||||||
display: block;
|
display: block;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
margin-right: 40px;
|
margin-right: 40px;
|
||||||
|
max-width: 80%;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
.toggler {
|
.toggler {
|
||||||
&:before {
|
&:before {
|
||||||
|
|
Loading…
Reference in New Issue