mirror of
https://github.com/discourse/discourse.git
synced 2025-01-19 17:12:46 +08:00
DEV: migrates reviewable-created-by to gjs (#27862)
This commit is contained in:
parent
38f80be810
commit
6547f78ff8
|
@ -0,0 +1,15 @@
|
|||
import UserLink from "discourse/components/user-link";
|
||||
import avatar from "discourse/helpers/avatar";
|
||||
import icon from "discourse-common/helpers/d-icon";
|
||||
|
||||
const ReviewableCreatedBy = <template>
|
||||
<div class="created-by">
|
||||
{{#if @user}}
|
||||
<UserLink @user={{@user}}>{{avatar @user imageSize="large"}}</UserLink>
|
||||
{{else}}
|
||||
{{icon "far-trash-alt" class="deleted-user-avatar"}}
|
||||
{{/if}}
|
||||
</div>
|
||||
</template>;
|
||||
|
||||
export default ReviewableCreatedBy;
|
|
@ -1,10 +0,0 @@
|
|||
<div class="created-by">
|
||||
{{#if this.user}}
|
||||
<UserLink @user={{this.user}}>{{avatar
|
||||
this.user
|
||||
imageSize="large"
|
||||
}}</UserLink>
|
||||
{{else}}
|
||||
{{d-icon "far-trash-alt" class="deleted-user-avatar"}}
|
||||
{{/if}}
|
||||
</div>
|
|
@ -1,3 +0,0 @@
|
|||
import Component from "@ember/component";
|
||||
|
||||
export default Component.extend({});
|
|
@ -4,7 +4,7 @@
|
|||
</div>
|
||||
|
||||
<div class="post-contents-wrapper">
|
||||
<ReviewableCreatedBy @user={{@reviewable.target_created_by}} @tagName="" />
|
||||
<ReviewableCreatedBy @user={{@reviewable.target_created_by}} />
|
||||
<div class="post-contents">
|
||||
<ReviewablePostHeader
|
||||
@reviewable={{@reviewable}}
|
||||
|
|
|
@ -4,10 +4,7 @@
|
|||
</div>
|
||||
|
||||
<div class="post-contents-wrapper">
|
||||
<ReviewableCreatedBy
|
||||
@user={{this.reviewable.target_created_by}}
|
||||
@tagName=""
|
||||
/>
|
||||
<ReviewableCreatedBy @user={{this.reviewable.target_created_by}} />
|
||||
<div class="post-contents">
|
||||
<ReviewablePostHeader
|
||||
@reviewable={{this.reviewable}}
|
||||
|
|
|
@ -13,7 +13,7 @@
|
|||
</ReviewableTopicLink>
|
||||
|
||||
<div class="post-contents-wrapper">
|
||||
<ReviewableCreatedBy @user={{@reviewable.target_created_by}} @tagName="" />
|
||||
<ReviewableCreatedBy @user={{@reviewable.target_created_by}} />
|
||||
|
||||
<div class="post-contents">
|
||||
<ReviewablePostHeader
|
||||
|
|
|
@ -399,10 +399,7 @@
|
|||
</span>
|
||||
</div>
|
||||
<div class="post-contents-wrapper">
|
||||
<ReviewableCreatedBy
|
||||
@user={{this.currentUser}}
|
||||
@tagName=""
|
||||
/>
|
||||
<ReviewableCreatedBy @user={{this.currentUser}} />
|
||||
<div class="post-contents">
|
||||
<ReviewableCreatedByName @user={{this.currentUser}} />
|
||||
<div class="post-body"><CookText
|
||||
|
|
|
@ -40,10 +40,7 @@ export default class ReviewableChatMessage extends Component {
|
|||
{{/if}}
|
||||
|
||||
<div class="post-contents-wrapper">
|
||||
<ReviewableCreatedBy
|
||||
@user={{@reviewable.target_created_by}}
|
||||
@tagName=""
|
||||
/>
|
||||
<ReviewableCreatedBy @user={{@reviewable.target_created_by}} />
|
||||
<div class="post-contents">
|
||||
<ReviewablePostHeader
|
||||
@reviewable={{@reviewable}}
|
||||
|
|
Loading…
Reference in New Issue
Block a user