DEV: Tagless components
This commit is contained in:
parent
ba418ede2f
commit
7d7b067b98
|
|
@ -1,5 +1,7 @@
|
||||||
<div
|
<div class="progress progress-striped {{if this.active 'active'}}">
|
||||||
|
<div
|
||||||
class="progress-bar progress-bar-striped
|
class="progress-bar progress-bar-striped
|
||||||
{{if active 'progress-bar-animated'}}"
|
{{if this.active 'progress-bar-animated'}}"
|
||||||
style={{barStyle}}
|
style={{barStyle}}
|
||||||
></div>
|
></div>
|
||||||
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ import { computed } from "@ember/object";
|
||||||
import { htmlSafe } from "@ember/template";
|
import { htmlSafe } from "@ember/template";
|
||||||
|
|
||||||
export default Component.extend({
|
export default Component.extend({
|
||||||
classNameBindings: [":progress", ":progress-striped", "active"],
|
tagName: "",
|
||||||
|
|
||||||
active: computed("percent", function () {
|
active: computed("percent", function () {
|
||||||
return parseInt(this.get("percent"), 10) !== 100;
|
return parseInt(this.get("percent"), 10) !== 100;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
<td>
|
<tr>
|
||||||
|
<td>
|
||||||
{{#if this.officialRepoBadge}}
|
{{#if this.officialRepoBadge}}
|
||||||
{{d-icon
|
{{d-icon
|
||||||
this.officialRepoBadge
|
this.officialRepoBadge
|
||||||
|
|
@ -7,16 +8,16 @@
|
||||||
title=this.officialRepoBadgeTitle
|
title=this.officialRepoBadgeTitle
|
||||||
}}
|
}}
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<td>
|
<td>
|
||||||
<a href="{{repo.url}}">{{repo.name}}</a>
|
<a href="{{repo.url}}">{{repo.name}}</a>
|
||||||
<span class="current commit-hash" title={{repo.version}}>
|
<span class="current commit-hash" title={{repo.version}}>
|
||||||
{{repo.prettyVersion}}
|
{{repo.prettyVersion}}
|
||||||
</span>
|
</span>
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<td>
|
<td>
|
||||||
{{#if repo.checkingStatus}}
|
{{#if repo.checkingStatus}}
|
||||||
Checking for new version...
|
Checking for new version...
|
||||||
{{else if repo.upToDate}}
|
{{else if repo.upToDate}}
|
||||||
|
|
@ -66,4 +67,5 @@
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</td>
|
</td>
|
||||||
|
</tr>
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import { inject as service } from "@ember/service";
|
||||||
|
|
||||||
export default Component.extend({
|
export default Component.extend({
|
||||||
router: service(),
|
router: service(),
|
||||||
tagName: "tr",
|
tagName: "",
|
||||||
|
|
||||||
upgradeDisabled: computed(
|
upgradeDisabled: computed(
|
||||||
"upgradingRepo",
|
"upgradingRepo",
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
{{#if currentUser.admin}}
|
{{#if currentUser.admin}}
|
||||||
|
<tr>
|
||||||
<th colspan="5">
|
<th colspan="5">
|
||||||
{{#if versionCheck.upToDate}}
|
{{#if versionCheck.upToDate}}
|
||||||
<a href="{{href}}" data-auto-route="true">
|
<a href="{{href}}" data-auto-route="true">
|
||||||
|
|
@ -11,4 +12,5 @@
|
||||||
</a>
|
</a>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
</th>
|
</th>
|
||||||
|
</tr>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import getURL from "discourse-common/lib/get-url";
|
||||||
import Component from "@ember/component";
|
import Component from "@ember/component";
|
||||||
|
|
||||||
export default class extends Component {
|
export default class extends Component {
|
||||||
tagName = "tr";
|
tagName = "";
|
||||||
|
|
||||||
get href() {
|
get href() {
|
||||||
return getURL("/admin/upgrade");
|
return getURL("/admin/upgrade");
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
{{output}}
|
<div class="logs">
|
||||||
|
{{output}}
|
||||||
|
</div>
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ import { observer } from "@ember/object";
|
||||||
import { scheduleOnce } from "@ember/runloop";
|
import { scheduleOnce } from "@ember/runloop";
|
||||||
|
|
||||||
export default Component.extend({
|
export default Component.extend({
|
||||||
classNameBindings: [":logs"],
|
tagName: "",
|
||||||
|
|
||||||
_outputChanged: observer("output", function () {
|
_outputChanged: observer("output", function () {
|
||||||
scheduleOnce("afterRender", this, "_scrollBottom");
|
scheduleOnce("afterRender", this, "_scrollBottom");
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue