mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: Ensure badge description is updated when routing without loading state (#12196)
This commit is contained in:
parent
de32fa299d
commit
d22ab6fe22
@ -22,14 +22,13 @@ export default Component.extend({
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@discourseComputed("size")
|
@discourseComputed("size", "badge.long_description", "badge.description")
|
||||||
summary(size) {
|
summary(size, longDescription, description) {
|
||||||
if (size === "large") {
|
if (size === "large") {
|
||||||
const longDescription = this.get("badge.long_description");
|
|
||||||
if (!isEmpty(longDescription)) {
|
if (!isEmpty(longDescription)) {
|
||||||
return emojiUnescape(sanitize(longDescription));
|
return emojiUnescape(sanitize(longDescription));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return sanitize(this.get("badge.description"));
|
return sanitize(description);
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user