Change repos-empty view to a component
This commit is contained in:
parent
da10f0a839
commit
aa22f7bb61
5
app/components/repos-empty.coffee
Normal file
5
app/components/repos-empty.coffee
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
`import Ember from 'ember'`
|
||||||
|
|
||||||
|
ReposEmptyComponent = Ember.Component.extend()
|
||||||
|
|
||||||
|
`export default ReposEmptyComponent`
|
|
@ -1,7 +1,7 @@
|
||||||
<div id="repo" class="{{view.className}} repo">
|
<div id="repo" class="{{view.className}} repo">
|
||||||
|
|
||||||
{{#if view.isEmpty}}
|
{{#if view.isEmpty}}
|
||||||
{{view 'repos-empty'}}
|
{{repos-empty}}
|
||||||
{{else}}
|
{{else}}
|
||||||
|
|
||||||
{{#if repo.isLoaded}}
|
{{#if repo.isLoaded}}
|
||||||
|
|
|
@ -32,12 +32,4 @@ View = BasicView.extend Polling,
|
||||||
view.appendTo($('body'))
|
view.appendTo($('body'))
|
||||||
return false
|
return false
|
||||||
|
|
||||||
ReposEmptyView: BasicView.extend
|
|
||||||
template: (->
|
|
||||||
if config.pro
|
|
||||||
'pro/repos/show/empty'
|
|
||||||
else
|
|
||||||
''
|
|
||||||
).property()
|
|
||||||
|
|
||||||
`export default View`
|
`export default View`
|
||||||
|
|
Loading…
Reference in New Issue
Block a user