mirror of
https://github.com/discourse/discourse.git
synced 2024-11-24 18:29:54 +08:00
DEV: Inline cancel-link code (#26778)
No need for this small component (and its unused and empty admin component twin)
This commit is contained in:
parent
505d8b52b8
commit
f75c253b95
|
@ -1,5 +0,0 @@
|
|||
import Component from "@ember/component";
|
||||
import { tagName } from "@ember-decorators/component";
|
||||
|
||||
@tagName("")
|
||||
export default class CancelLink extends Component {}
|
|
@ -1,3 +0,0 @@
|
|||
<LinkTo @route={{this.route}} @model={{this.args}} class="cancel">
|
||||
{{i18n "cancel"}}
|
||||
</LinkTo>
|
|
@ -1,3 +0,0 @@
|
|||
import Component from "@ember/component";
|
||||
|
||||
export default Component.extend({});
|
|
@ -43,10 +43,13 @@
|
|||
type="submit"
|
||||
class="btn-primary"
|
||||
/>
|
||||
<CancelLink
|
||||
<LinkTo
|
||||
@route="preferences.account"
|
||||
@args={{this.model.username}}
|
||||
/>
|
||||
@model={{this.model.username}}
|
||||
class="cancel"
|
||||
>
|
||||
{{i18n "cancel"}}
|
||||
</LinkTo>
|
||||
</div>
|
||||
{{/if}}
|
||||
</form>
|
||||
|
|
|
@ -146,10 +146,13 @@
|
|||
@label="user.second_factor.disable_all"
|
||||
class="btn-danger"
|
||||
/>
|
||||
<CancelLink
|
||||
<LinkTo
|
||||
@route="preferences.security"
|
||||
@args={{this.model.username}}
|
||||
/>
|
||||
@model={{this.model.username}}
|
||||
class="cancel"
|
||||
>
|
||||
{{i18n "cancel"}}
|
||||
</LinkTo>
|
||||
</div>
|
||||
</div>
|
||||
{{/unless}}
|
||||
|
|
Loading…
Reference in New Issue
Block a user