FIX: Add more descriptive text for expanding links
This commit is contained in:
parent
fd57865046
commit
43e7890dcf
|
@ -31,7 +31,8 @@ export default createWidget('link', {
|
|||
},
|
||||
|
||||
buildAttributes(attrs) {
|
||||
return { href: this.href(attrs), title: this.label(attrs) };
|
||||
return { href: this.href(attrs),
|
||||
title: attrs.title ? I18n.t(attrs.title) : this.label(attrs) };
|
||||
},
|
||||
|
||||
label(attrs) {
|
||||
|
|
|
@ -19,6 +19,7 @@ export default createWidget('post-links', {
|
|||
if (state.collapsed) {
|
||||
return this.attach('link', {
|
||||
labelCount: `post_links.title`,
|
||||
title: "post_links.about",
|
||||
count: links.length,
|
||||
action: 'expandLinks',
|
||||
className: 'expand-links'
|
||||
|
@ -48,14 +49,6 @@ export default createWidget('post-links', {
|
|||
});
|
||||
}
|
||||
|
||||
// if (attrs.canReplyAsNewTopic) {
|
||||
// result.push(h('li', this.attach('link', {
|
||||
// className: 'reply-new',
|
||||
// contents: () => [I18n.t('post.reply_as_new_topic'), iconNode('plus')],
|
||||
// action: 'newTopicAction'
|
||||
// })));
|
||||
// }
|
||||
|
||||
return h('ul.post-links', result);
|
||||
},
|
||||
|
||||
|
|
|
@ -1828,6 +1828,7 @@ en:
|
|||
one: "1 click"
|
||||
other: "%{count} clicks"
|
||||
post_links:
|
||||
about: "expand the links for this post"
|
||||
title:
|
||||
one: "1 post link"
|
||||
other: "%{count} post links"
|
||||
|
|
Loading…
Reference in New Issue