DEV: Convert `{{cook-text}}` to angle-brackets (#17287)
This commit is contained in:
parent
16ea7ab248
commit
7343cb9f73
|
@ -18,14 +18,14 @@
|
|||
<div class="post-contents">
|
||||
<ReviewablePostHeader @reviewable={{reviewable}} @createdBy={{reviewable.created_by}} @tagName="" />
|
||||
|
||||
{{cook-text
|
||||
reviewable.payload.raw
|
||||
class="post-body"
|
||||
categoryId=reviewable.category_id
|
||||
topicId=reviewable.topic_id
|
||||
paintOneboxes=true
|
||||
opts=(hash removeMissing=true)
|
||||
}}
|
||||
<CookText
|
||||
@rawText={{reviewable.payload.raw}}
|
||||
@class="post-body"
|
||||
@categoryId={{reviewable.category_id}}
|
||||
@topicId={{reviewable.topic_id}}
|
||||
@paintOneboxes={{true}}
|
||||
@opts={{hash removeMissing=true}}
|
||||
/>
|
||||
|
||||
{{yield}}
|
||||
</div>
|
||||
|
|
|
@ -149,7 +149,7 @@
|
|||
<ReviewableCreatedBy @user={{currentUser}} @tagName="" />
|
||||
<div class="post-contents">
|
||||
<ReviewableCreatedByName @user={{currentUser}} @tagName="" />
|
||||
<div class="post-body">{{cook-text pending.raw}}</div>
|
||||
<div class="post-body"><CookText @rawText={{pending.raw}} /></div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="reviewable-actions">
|
||||
|
|
|
@ -10,7 +10,7 @@ discourseModule("Integration | Component | cook-text", function (hooks) {
|
|||
setupRenderingTest(hooks);
|
||||
|
||||
componentTest("renders markdown", {
|
||||
template: hbs`{{cook-text "_foo_" class="post-body"}}`,
|
||||
template: hbs`<CookText @rawText="_foo_" @class="post-body" />`,
|
||||
|
||||
test(assert) {
|
||||
const html = query(".post-body").innerHTML.trim();
|
||||
|
@ -19,7 +19,7 @@ discourseModule("Integration | Component | cook-text", function (hooks) {
|
|||
});
|
||||
|
||||
componentTest("resolves short URLs", {
|
||||
template: hbs`{{cook-text "![an image](upload://a.png)" class="post-body"}}`,
|
||||
template: hbs`<CookText @rawText="![an image](upload://a.png)" @class="post-body" />`,
|
||||
|
||||
beforeEach() {
|
||||
pretender.post("/uploads/lookup-urls", () => {
|
||||
|
|
Loading…
Reference in New Issue