FIX: Pass in DecoratorHelper to PostCooked
This commit is contained in:
parent
797d450b73
commit
ad787656fe
|
@ -9,6 +9,7 @@ import PostCooked from "discourse/widgets/post-cooked";
|
||||||
import { formatUsername } from "discourse/lib/utilities";
|
import { formatUsername } from "discourse/lib/utilities";
|
||||||
import { iconHTML } from "discourse-common/lib/icon-library";
|
import { iconHTML } from "discourse-common/lib/icon-library";
|
||||||
import { iconNode } from "discourse-common/lib/icon-library";
|
import { iconNode } from "discourse-common/lib/icon-library";
|
||||||
|
import DecoratorHelper from "discourse/widgets/decorator-helper";
|
||||||
|
|
||||||
function clearAccepted(topic) {
|
function clearAccepted(topic) {
|
||||||
const posts = topic.get("postStream.posts");
|
const posts = topic.get("postStream.posts");
|
||||||
|
@ -161,10 +162,10 @@ function initializeWithApi(api) {
|
||||||
</div>
|
</div>
|
||||||
</aside>`;
|
</aside>`;
|
||||||
|
|
||||||
const cooked = new PostCooked({
|
const cooked = new PostCooked(
|
||||||
cooked: hasExcerpt ? withExcerpt : withoutExcerpt
|
{ cooked: hasExcerpt ? withExcerpt : withoutExcerpt },
|
||||||
});
|
dec
|
||||||
|
);
|
||||||
return dec.rawHtml(cooked.init());
|
return dec.rawHtml(cooked.init());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue