Merge branch 'new-router'
Conflicts: Gemfile.lock public/javascripts/application.js public/stylesheets/application.css
This commit is contained in:
commit
0447f62a19
5
Gemfile
5
Gemfile
|
@ -27,3 +27,8 @@ group :assets do
|
|||
gem 'tilt'
|
||||
gem 'guard'
|
||||
end
|
||||
|
||||
group :development do
|
||||
gem 'foreman'
|
||||
gem 'rerun'
|
||||
end
|
||||
|
|
|
@ -155,6 +155,8 @@ GEM
|
|||
multi_json (~> 1.0)
|
||||
faraday (0.8.4)
|
||||
multipart-post (~> 1.1)
|
||||
foreman (0.59.0)
|
||||
thor (>= 0.13.6)
|
||||
fssm (0.2.9)
|
||||
guard (1.3.3)
|
||||
listen (>= 0.4.2)
|
||||
|
@ -215,6 +217,8 @@ GEM
|
|||
json (~> 1.4)
|
||||
redcarpet (2.1.1)
|
||||
redis (3.0.1)
|
||||
rerun (0.7.1)
|
||||
listen
|
||||
rollout (1.1.0)
|
||||
sass (3.2.1)
|
||||
signature (0.1.4)
|
||||
|
@ -259,7 +263,7 @@ DEPENDENCIES
|
|||
bunny
|
||||
coffee-script
|
||||
compass
|
||||
debugger
|
||||
foreman
|
||||
gh!
|
||||
guard
|
||||
hubble!
|
||||
|
@ -268,6 +272,7 @@ DEPENDENCIES
|
|||
rack-contrib!
|
||||
rake-pipeline!
|
||||
rake-pipeline-web-filters!
|
||||
rerun
|
||||
sinatra
|
||||
sinatra-contrib
|
||||
tilt
|
||||
|
|
|
@ -21,13 +21,13 @@ require 'data/sponsors'
|
|||
|
||||
Travis.reopen
|
||||
App: Em.Application.extend
|
||||
autoinit: false
|
||||
currentUserBinding: 'auth.user'
|
||||
accessTokenBinding: 'auth.user.accessToken'
|
||||
authStateBinding: 'auth.state'
|
||||
|
||||
init: ->
|
||||
@_super()
|
||||
@connect()
|
||||
@_super.apply this, arguments
|
||||
|
||||
@store = Travis.Store.create()
|
||||
@store.loadMany(Travis.Sponsor, Travis.SPONSORS)
|
||||
|
@ -35,7 +35,7 @@ Travis.reopen
|
|||
@set('auth', Travis.Auth.create(store: @store, endpoint: Travis.config.api_endpoint))
|
||||
|
||||
@slider = new Travis.Slider()
|
||||
@routes = new Travis.Routes()
|
||||
|
||||
@pusher = new Travis.Pusher()
|
||||
@tailing = new Travis.Tailing()
|
||||
|
||||
|
@ -44,28 +44,17 @@ Travis.reopen
|
|||
|
||||
signOut: ->
|
||||
@get('auth').signOut()
|
||||
@routes.route('')
|
||||
|
||||
render: (name, action, params) ->
|
||||
layout = @connectLayout(name)
|
||||
layout.activate(action, params || {})
|
||||
$('body').attr('id', name)
|
||||
|
||||
receive: ->
|
||||
@store.receive.apply(@store, arguments)
|
||||
|
||||
connectLayout: (name) ->
|
||||
unless @get('layout.name') == name
|
||||
name = $.camelize(name)
|
||||
viewClass = Travis["#{name}Layout"]
|
||||
@layout = Travis["#{name}Controller"].create(parent: @controller)
|
||||
@controller.connectOutlet(outletName: 'layout', controller: @layout, viewClass: viewClass)
|
||||
@layout
|
||||
|
||||
connect: ->
|
||||
@controller = Em.Controller.create()
|
||||
view = Em.View.create
|
||||
template: Em.Handlebars.compile('{{outlet layout}}')
|
||||
controller: @controller
|
||||
view.appendTo(@get('rootElement') || 'body')
|
||||
toggleSidebar: ->
|
||||
$('body').toggleClass('maximized')
|
||||
# TODO gotta force redraws here :/
|
||||
element = $('<span></span>')
|
||||
$('#top .profile').append(element)
|
||||
Em.run.later (-> element.remove()), 10
|
||||
element = $('<span></span>')
|
||||
$('#repository').append(element)
|
||||
Em.run.later (-> element.remove()), 10
|
||||
|
||||
|
|
|
@ -3,16 +3,6 @@ require 'travis/ticker'
|
|||
|
||||
Travis.reopen
|
||||
Controller: Em.Controller.extend
|
||||
init: ->
|
||||
for name in Array.prototype.slice.apply(arguments)
|
||||
name = "#{$.camelize(name, false)}Controller"
|
||||
klass = Travis[$.camelize(name)] || Em.Controller
|
||||
this[name] = klass.create(parent: this, namespace: Travis, controllers: this)
|
||||
|
||||
connectTop: ->
|
||||
@connectOutlet(outletName: 'top', controller: @topController, viewClass: Travis.TopView)
|
||||
@topController.set('tab', @get('name'))
|
||||
|
||||
connectOutlet: ->
|
||||
view = @_super.apply(this, arguments)
|
||||
|
||||
|
@ -28,6 +18,10 @@ Travis.reopen
|
|||
|
||||
TopController: Em.Controller.extend
|
||||
userBinding: 'Travis.app.currentUser'
|
||||
ApplicationController: Em.Controller.extend()
|
||||
MainController: Em.Controller.extend()
|
||||
StatsLayoutController: Em.Controller.extend()
|
||||
ProfileLayoutController: Em.Controller.extend()
|
||||
|
||||
require 'controllers/accounts'
|
||||
require 'controllers/builds'
|
||||
|
|
|
@ -2,6 +2,7 @@ Travis.AccountsController = Ember.ArrayController.extend
|
|||
defaultTab: 'accounts'
|
||||
|
||||
init: ->
|
||||
@_super()
|
||||
@activate(@defaultTab)
|
||||
|
||||
activate: (tab, params) ->
|
||||
|
@ -10,3 +11,6 @@ Travis.AccountsController = Ember.ArrayController.extend
|
|||
|
||||
viewAccounts: ->
|
||||
@set('content', Travis.Account.filter())
|
||||
|
||||
findByLogin: (login) ->
|
||||
@find (account) -> account.get('login') == 'login'
|
||||
|
|
|
@ -1,13 +1 @@
|
|||
Travis.HomeController = Travis.Controller.extend
|
||||
name: 'home'
|
||||
|
||||
init: ->
|
||||
@_super('top', 'repositories', 'repository', 'sidebar')
|
||||
|
||||
@connectTop()
|
||||
@connectOutlet outletName: 'left', controller: @repositoriesController, viewClass: Travis.RepositoriesView
|
||||
@connectOutlet outletName: 'main', controller: @repositoryController, viewClass: Travis.RepositoryView
|
||||
@connectOutlet outletName: 'right', controller: @sidebarController, viewClass: Travis.SidebarView
|
||||
|
||||
activate: (action, params) ->
|
||||
@repositoryController.activate(action, params)
|
||||
Travis.HomeController = Travis.Controller.extend()
|
||||
|
|
0
assets/javascripts/app/controllers/job.coffee
Normal file
0
assets/javascripts/app/controllers/job.coffee
Normal file
|
@ -1,17 +1,11 @@
|
|||
Travis.ProfileController = Travis.Controller.extend
|
||||
name: 'profile'
|
||||
userBinding: 'Travis.app.currentUser'
|
||||
|
||||
init: ->
|
||||
@_super('top', 'accounts')
|
||||
@connectTop()
|
||||
@connectOutlet outletName: 'left', controller: @accountsController, viewClass: Travis.AccountsView
|
||||
@connectOutlet(outletName: 'main', controller: this, viewClass: Travis.ProfileView)
|
||||
@accounts = @accountsController.get('content')
|
||||
accountsBinding: 'Travis.app.router.accountsController'
|
||||
|
||||
account: (->
|
||||
login = @get('params.login') || Travis.app.get('currentUser.login')
|
||||
@accounts.toArray().filter((account) -> account if account.get('login') == login)[0]
|
||||
@get('accounts').filter((account) -> account if account.get('login') == login)[0]
|
||||
).property('accounts.length', 'params.login')
|
||||
|
||||
activate: (action, params) ->
|
||||
|
|
|
@ -3,7 +3,7 @@ Travis.RepositoryController = Travis.Controller.extend
|
|||
params: {}
|
||||
|
||||
init: ->
|
||||
@_super('builds', 'build', 'job')
|
||||
@_super.apply this, arguments
|
||||
Ember.run.later(@updateTimes.bind(this), Travis.INTERVALS.updateTimes)
|
||||
|
||||
updateTimes: ->
|
||||
|
|
|
@ -3,8 +3,7 @@ Travis.StatsController = Travis.Controller.extend
|
|||
|
||||
init: ->
|
||||
@_super('top')
|
||||
@connectTop()
|
||||
@connectOutlet(outletName: 'main', controller: this, viewClass: Travis.StatsView)
|
||||
#@connectOutlet(outletName: 'main', controller: this, viewClass: Travis.StatsView)
|
||||
|
||||
activate: (action, params) ->
|
||||
# noop
|
||||
|
|
|
@ -18,10 +18,6 @@ require 'travis/model'
|
|||
@get('state') == 'working'
|
||||
).property('state')
|
||||
|
||||
urlJob: (->
|
||||
"/#{@get('repository')}/jobs/#{@get('job_id')}" if @get('state') == 'working'
|
||||
).property('repository', 'job_id', 'state')
|
||||
|
||||
repository: (->
|
||||
@get('payload.repository.slug')
|
||||
).property('payload.repository.slug')
|
||||
|
@ -29,3 +25,7 @@ require 'travis/model'
|
|||
job_id: (->
|
||||
@get('payload.job.id')
|
||||
).property('payload.job.id')
|
||||
|
||||
job: (->
|
||||
Travis.Job.find @get('job_id')
|
||||
).property('job_id')
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
Travis.Pusher = ->
|
||||
@active_channels = []
|
||||
if Travis.config.pusher?.key?
|
||||
Pusher.warn = @warn
|
||||
@pusher = new Pusher(Travis.config.pusher.key)
|
||||
@subscribe(channel) for channel in Travis.Pusher.CHANNELS
|
||||
this
|
||||
|
@ -13,7 +14,7 @@ $.extend Travis.Pusher.prototype,
|
|||
subscribe: (channel) ->
|
||||
if @pusher && @active_channels.indexOf(channel) == -1
|
||||
@active_channels.push(channel)
|
||||
@pusher.subscribe(@prefix(channel)).bind_all (event, data) => @receive(event, data)
|
||||
@pusher.subscribe(@prefix(channel)).bind_all((event, data) => @receive(event, data))
|
||||
|
||||
unsubscribe: (channel) ->
|
||||
ix = @active_channels.indexOf(channel)
|
||||
|
@ -40,3 +41,5 @@ $.extend Travis.Pusher.prototype,
|
|||
when 'worker:added', 'worker:updated', 'worker:removed'
|
||||
{ worker: data }
|
||||
|
||||
warn: (type, error) ->
|
||||
console.warn(error) unless error.data?.message && error.data.message.indexOf('No current subscription') > -1
|
||||
|
|
|
@ -1,42 +1,225 @@
|
|||
Travis.Routes = ->
|
||||
unless Travis.Routes.initialized
|
||||
Ember.run.next =>
|
||||
Em.routes.set('usesHistory', true)
|
||||
Em.routes.set('wantsHistory', true)
|
||||
Em.routes.set('baseURI', @base_uri)
|
||||
Travis.Router = Ember.Router.extend
|
||||
location: 'history'
|
||||
enableLogging: true
|
||||
initialState: 'loading'
|
||||
|
||||
@add(route, target[0], target[1]) for route, target of Travis.ROUTES
|
||||
Travis.Routes.initialized = true
|
||||
|
||||
$.extend Travis.Routes.prototype,
|
||||
base_uri: "#{document.location.protocol}//#{document.location.host}"
|
||||
|
||||
add: (route, layout, action) ->
|
||||
Em.routes.add route, (params) =>
|
||||
@action(layout, action, params)
|
||||
|
||||
route: (location) ->
|
||||
location = $(event.target).closest('a')[0].href.replace("#{@base_uri}/", '') if typeof location != 'string'
|
||||
Em.routes.set('location', location)
|
||||
|
||||
action: (name, action, params) ->
|
||||
# this needs to be a global reference because Em.routes is global
|
||||
Travis.app.render(name, action, params) if @before(name, action, params)
|
||||
|
||||
before: (name, action, params) ->
|
||||
if @requiresAuth(name, action, params)
|
||||
@requireAuth(name, action, params)
|
||||
else
|
||||
true
|
||||
goToRoot: Ember.Route.transitionTo('root.home.show')
|
||||
goToStats: Ember.Route.transitionTo('root.stats')
|
||||
showRepository: Ember.Route.transitionTo('root.home.repository.show')
|
||||
showBuilds: Ember.Route.transitionTo('root.home.repository.builds.index')
|
||||
showBuild: Ember.Route.transitionTo('root.home.repository.builds.show')
|
||||
showPullRequests: Ember.Route.transitionTo('root.home.repository.pullRequests')
|
||||
showBranches: Ember.Route.transitionTo('root.home.repository.branches')
|
||||
showJob: Ember.Route.transitionTo('root.home.repository.job')
|
||||
showProfile: Ember.Route.transitionTo('root.profile')
|
||||
showAccount: Ember.Route.transitionTo('root.profile.account')
|
||||
showUserProfile: Ember.Route.transitionTo('root.profile.account.profile')
|
||||
|
||||
signedIn: ->
|
||||
!!Travis.app.get('currentUser')
|
||||
|
||||
requiresAuth: (name, action, params) ->
|
||||
name == 'profile' and not @signedIn()
|
||||
requiresAuth: (path) ->
|
||||
# TODO: not sure what the path is at the moment
|
||||
path == '/profile' && !@signedIn()
|
||||
|
||||
requireAuth: (name, action, params) ->
|
||||
Travis.app.set('returnTo', [name, action, params])
|
||||
# Travis.app.render('auth', 'show')
|
||||
@route('')
|
||||
false
|
||||
loading: Ember.Route.extend
|
||||
routePath: (router, path) ->
|
||||
router.set('lastAttemptedPath', path)
|
||||
if router.requiresAuth(path)
|
||||
router.send 'switchToUnauthenticated'
|
||||
else
|
||||
router.send 'switchToAuthenticated'
|
||||
|
||||
switchToUnauthenticated: Ember.State.transitionTo('unauthenticated.index')
|
||||
switchToAuthenticated: Ember.State.transitionTo('authenticated.index')
|
||||
|
||||
unauthenticated: Ember.Route.extend
|
||||
index: Ember.Route.extend
|
||||
route: '/'
|
||||
|
||||
connectOutlets: (router) ->
|
||||
router.transitionTo('login')
|
||||
|
||||
login: Ember.Route.extend
|
||||
route: '/login'
|
||||
|
||||
connectOutlets: (router) ->
|
||||
router.get('applicationController').connectOutlet('login')
|
||||
|
||||
authenticated: Ember.Route.extend
|
||||
index: Ember.Route.extend
|
||||
connectOutlets: (router) ->
|
||||
router.transitionTo('root')
|
||||
|
||||
path = router.get('lastAttemptedPath')
|
||||
if path && path != '/'
|
||||
router.route(path)
|
||||
|
||||
root: Ember.Route.extend
|
||||
initialState: 'home'
|
||||
loading: Ember.State.extend()
|
||||
|
||||
stats: Ember.Route.extend
|
||||
route: '/stats'
|
||||
connectOutlets: (router) ->
|
||||
router.get('applicationController').connectOutlet 'statsLayout'
|
||||
$('body').attr('id', 'stats')
|
||||
router.get('statsLayoutController').connectOutlet 'top', 'top'
|
||||
router.get('statsLayoutController').connectOutlet 'main', 'stats'
|
||||
|
||||
profile: Ember.Route.extend
|
||||
initialState: 'index'
|
||||
route: '/profile'
|
||||
connectOutlets: (router) ->
|
||||
router.get('applicationController').connectOutlet 'profileLayout'
|
||||
$('body').attr('id', 'profile')
|
||||
router.get('profileLayoutController').connectOutlet 'top', 'top'
|
||||
router.get('profileLayoutController').connectOutlet 'left', 'accounts'
|
||||
|
||||
index: Ember.Route.extend
|
||||
route: '/'
|
||||
connectOutlets: (router) ->
|
||||
router.get('profileLayoutController').connectOutlet 'main', 'profile'
|
||||
router.get('profileController').activate 'hooks'
|
||||
|
||||
account: Ember.Route.extend
|
||||
initialState: 'index'
|
||||
route: '/:login'
|
||||
|
||||
connectOutlets: (router, account) ->
|
||||
if account
|
||||
params = { login: account.get('login') }
|
||||
router.get('profileController').setParams(params)
|
||||
else
|
||||
router.send 'showProfile'
|
||||
|
||||
deserialize: (router, params) ->
|
||||
router.get('accountsController').findByLogin(params.login)
|
||||
|
||||
serialize: (router, account) ->
|
||||
if account
|
||||
{ login: account.get('login') }
|
||||
else
|
||||
{}
|
||||
|
||||
index: Ember.Route.extend
|
||||
route: '/'
|
||||
connectOutlets: (router) ->
|
||||
router.get('profileController').activate 'hooks'
|
||||
|
||||
profile: Ember.Route.extend
|
||||
route: '/profile'
|
||||
|
||||
connectOutlets: (router) ->
|
||||
router.get('profileController').activate 'user'
|
||||
|
||||
home: Ember.Route.extend
|
||||
initialState: 'show'
|
||||
route: '/'
|
||||
connectOutlets: (router) ->
|
||||
router.get('applicationController').connectOutlet 'home'
|
||||
$('body').attr('id', 'home')
|
||||
router.get('homeController').connectOutlet 'left', 'repositories'
|
||||
router.get('homeController').connectOutlet 'right', 'sidebar'
|
||||
router.get('homeController').connectOutlet 'top', 'top'
|
||||
router.get('homeController').connectOutlet 'main', 'repository'
|
||||
|
||||
show: Ember.Route.extend
|
||||
route: '/'
|
||||
connectOutlets: (router) ->
|
||||
router.get('repositoryController').activate('index')
|
||||
|
||||
repository: Ember.Route.extend
|
||||
initialState: 'show'
|
||||
route: '/:owner/:name'
|
||||
|
||||
connectOutlets: (router, repository) ->
|
||||
params = { owner: repository.get('owner'), name: repository.get('name') }
|
||||
|
||||
# TODO: we can just pass objects instead of params now, I'm leaving this
|
||||
# to not have to rewrite too much, but it would be nice to fix this
|
||||
# later
|
||||
router.get('repositoryController').setParams(params)
|
||||
|
||||
deserialize: (router, params) ->
|
||||
slug = "#{params.owner}/#{params.name}"
|
||||
repos = Travis.Repository.bySlug(slug)
|
||||
deferred = $.Deferred()
|
||||
|
||||
observer = ->
|
||||
if repos.get 'isLoaded'
|
||||
repos.removeObserver 'isLoaded', observer
|
||||
deferred.resolve repos.objectAt(0)
|
||||
|
||||
repos.addObserver 'isLoaded', observer
|
||||
|
||||
deferred.promise()
|
||||
|
||||
serialize: (router, repository) ->
|
||||
if repository
|
||||
{ owner: repository.get('owner'), name: repository.get('name') }
|
||||
else
|
||||
{}
|
||||
|
||||
show: Ember.Route.extend
|
||||
route: '/'
|
||||
connectOutlets: (router) ->
|
||||
router.get('repositoryController').activate('current')
|
||||
|
||||
builds: Ember.Route.extend
|
||||
route: '/builds'
|
||||
initialState: 'index'
|
||||
|
||||
index: Ember.Route.extend
|
||||
route: '/'
|
||||
connectOutlets: (router, repository) ->
|
||||
router.get('repositoryController').activate 'builds'
|
||||
|
||||
show: Ember.Route.extend
|
||||
route: '/:build_id'
|
||||
connectOutlets: (router, build) ->
|
||||
router.get('repositoryController').activate 'build', id: build.get('id')
|
||||
|
||||
deserialize: (router, params) ->
|
||||
# Something is wrong here. If I don't use deferred, id is not
|
||||
# initialized and url ends up being /jobs/null
|
||||
# This should not be needed, as id should be immediately set on the
|
||||
# record.
|
||||
# TODO: find out why it happens
|
||||
build = Travis.Build.find params.build_id
|
||||
deferred = $.Deferred()
|
||||
|
||||
observer = ->
|
||||
if build.get 'id'
|
||||
build.removeObserver 'id', observer
|
||||
deferred.resolve build
|
||||
|
||||
build.addObserver 'id', observer
|
||||
|
||||
deferred.promise()
|
||||
|
||||
pullRequests: Ember.Route.extend
|
||||
route: '/pull_requests'
|
||||
connectOutlets: (router, repository) ->
|
||||
router.get('repositoryController').activate 'pull_requests'
|
||||
|
||||
branches: Ember.Route.extend
|
||||
route: '/branches'
|
||||
connectOutlets: (router, repository) ->
|
||||
router.get('repositoryController').activate 'branches'
|
||||
|
||||
job: Ember.Route.extend
|
||||
route: '/jobs/:job_id'
|
||||
connectOutlets: (router, job) ->
|
||||
router.get('repositoryController').activate 'job', id: job.get('id')
|
||||
|
||||
deserialize: (router, params) ->
|
||||
job = Travis.Job.find params.job_id
|
||||
deferred = $.Deferred()
|
||||
|
||||
observer = ->
|
||||
if job.get 'id'
|
||||
job.removeObserver 'id', observer
|
||||
deferred.resolve job
|
||||
job.addObserver 'id', observer
|
||||
deferred.promise()
|
||||
|
|
6
assets/javascripts/app/templates/application.hbs
Normal file
6
assets/javascripts/app/templates/application.hbs
Normal file
|
@ -0,0 +1,6 @@
|
|||
{{! TODO apparently styles assume that there is more divs here...
|
||||
I should fix that later }}
|
||||
<div>
|
||||
{{outlet}}
|
||||
</div>
|
||||
|
|
@ -16,9 +16,11 @@
|
|||
<tr {{bindAttr class="view.color"}}>
|
||||
<td class="number">
|
||||
<span class="status"></span>
|
||||
<a {{bindAttr href="view.urlBuild"}} {{action route}}>
|
||||
{{number}}
|
||||
</a>
|
||||
{{#if id}}
|
||||
<a {{action showBuild this href=true}}>
|
||||
{{number}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</td>
|
||||
<td class="commit">
|
||||
<a {{bindAttr href="view.urlGithubCommit"}}>
|
||||
|
@ -39,7 +41,6 @@
|
|||
{{/each}}
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<p>
|
||||
<button {{action showMore on="click" target="this" isVisibleBinding="hasMore"}}>
|
||||
{{t builds.show_more}}
|
||||
|
|
|
@ -6,9 +6,9 @@
|
|||
<dt>{{t builds.name}}</dt>
|
||||
<dd class="number">
|
||||
<span class="status"></span>
|
||||
<a {{bindAttr href="urlBuild"}} {{action route}}>
|
||||
{{build.number}}
|
||||
</a>
|
||||
{{#if build.id}}
|
||||
<a {{action showBuild build href=true}}>{{build.number}}</a>
|
||||
{{/if}}
|
||||
</dd>
|
||||
<dt class="finished_at_label">{{t builds.finished_at}}</dt>
|
||||
<dd class="finished_at timeago" {{bindAttr title="finishedAt"}}>{{formatTime build.finishedAt}}</dd>
|
||||
|
|
|
@ -8,7 +8,7 @@
|
|||
<table id="allowed_failure_jobs" class="list">
|
||||
<caption>
|
||||
{{t jobs.allowed_failures}}
|
||||
<a title="What's this?" class="help" name="help-allowed_failures" {{action popup}}></a>
|
||||
<a title="What's this?" class="help" name="help-allowed_failures" {{action toggleHelp target="view"}}></a>
|
||||
</caption>
|
||||
{{/if}}
|
||||
<thead>
|
||||
|
@ -23,9 +23,9 @@
|
|||
{{#view Travis.JobsItemView contextBinding="job"}}
|
||||
<td class="number">
|
||||
<span class="status"></span>
|
||||
<a {{bindAttr href="view.urlJob"}} {{action route}}>
|
||||
{{number}}
|
||||
</a>
|
||||
{{#if job.id}}
|
||||
<a {{action showJob repository job href=true}}>{{number}}</a>
|
||||
{{/if}}
|
||||
</td>
|
||||
<td class="duration" {{bindAttr title="startedAt"}}>
|
||||
{{formatDuration duration}}
|
||||
|
|
|
@ -4,7 +4,11 @@
|
|||
<dl id="summary">
|
||||
<div class="left">
|
||||
<dt>Job</dt>
|
||||
<dd class="number"><a {{bindAttr href="view.urlJob"}} {{action route}}>{{job.number}}</a></dd>
|
||||
<dd class="number">
|
||||
{{#if job.id}}
|
||||
<a {{action showJob repository job href=true}}>{{job.number}}</a>
|
||||
{{/if}}
|
||||
</dd>
|
||||
<dt class="finished_at_label">{{t jobs.finished_at}}</dt>
|
||||
<dd class="finished_at timeago" {{bindAttr title="finishedAt"}}>{{formatTime job.finishedAt}}</dd>
|
||||
<dt>{{t jobs.duration}}</dt>
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
<a href="/" {{action route}}>
|
||||
<a {{action goToRoot href=true}}>
|
||||
<h1>Travis</h1>
|
||||
</a>
|
||||
|
||||
<ul id="navigation">
|
||||
<li {{bindAttr class="view.classHome"}}>
|
||||
<a href="/" {{action route}}>Home</a>
|
||||
<a {{action goToRoot href=true}}>Home</a>
|
||||
</li>
|
||||
<li {{bindAttr class="view.classStats"}}>
|
||||
<a href="/stats" {{action route}}>Stats</a>
|
||||
<a {{action goToStats href=true}}>Stats</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="http://about.travis-ci.org/blog">Blog</a>
|
||||
|
@ -18,12 +18,12 @@
|
|||
<li {{bindAttr class="view.classProfile"}}>
|
||||
<p class="handle">
|
||||
<a class="signed-out" href="#" {{action signIn target="Travis.app"}}>{{t layouts.top.github_login}}</a>
|
||||
<a class="signed-in" href="/profile" {{action route}}><img {{bindAttr src="view.gravatarUrl"}}>{{user.name}}</a>
|
||||
<a class="signed-in" {{action showProfile href=true}}><img {{bindAttr src="view.gravatarUrl"}}>{{user.name}}</a>
|
||||
<span class="signing-in">Signing in</span>
|
||||
</p>
|
||||
<ul>
|
||||
<li>
|
||||
<a href="/profile" {{action route}}>{{t layouts.top.profile}}</a>
|
||||
<a {{action showProfile href=true}}>{{t layouts.top.profile}}</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="/" {{action signOut target="Travis.app"}}>{{t layouts.top.sign_out}}</a>
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
|
||||
<div class="tab">
|
||||
{{#collection Travis.AccountsListView contentBinding="controller"}}
|
||||
<a {{bindAttr href="view.urlAccount"}} {{action route}} class="name">{{view.name}}</a>
|
||||
<a {{action showAccount view.account href=true}} class="name">{{view.name}}</a>
|
||||
<p class="summary">
|
||||
<span class="repos_label">Repositories:</span>
|
||||
<abbr class="repos">{{view.content.reposCount}}</abbr>
|
||||
|
|
|
@ -6,4 +6,3 @@
|
|||
{{outlet pane}}
|
||||
</div>
|
||||
|
||||
|
||||
|
|
|
@ -1,13 +1,13 @@
|
|||
<ul class="tabs">
|
||||
<li id="tab_hooks" {{bindAttr class="view.classHooks"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlAccount"}} {{action route}}>Repositories</a>
|
||||
<a {{action showAccount view.account href=true}}>Repositories</a>
|
||||
</h5>
|
||||
</li>
|
||||
{{#if view.displayUser}}
|
||||
<li id="tab_user" {{bindAttr class="view.classUser"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlUser"}} {{action route}}>Profile</a>
|
||||
<a {{action showUserProfile view.account href=true}}>Profile</a>
|
||||
</h5>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
|
|
@ -11,9 +11,13 @@
|
|||
{{#with view.repository}}
|
||||
<div class="slug-and-status">
|
||||
<span class="status"></span>
|
||||
<a {{bindAttr href="view.urlRepository"}} {{action route}} class="slug">{{slug}}</a>
|
||||
{{#if slug}}
|
||||
<a {{action showRepository this href=true}} class="slug">{{slug}}</a>
|
||||
{{/if}}
|
||||
</div>
|
||||
<a {{bindAttr href="view.urlLastBuild"}} {{action route}} class="last_build">{{lastBuildNumber}}</a>
|
||||
{{#if lastBuild.id}}
|
||||
<a {{action showBuild this lastBuild href=true}} class="last_build">#{{lastBuildNumber}}</a>
|
||||
{{/if}}
|
||||
|
||||
<p class="summary">
|
||||
<span class="duration_label">{{t repositories.duration}}:</span>
|
||||
|
|
|
@ -1,12 +1,12 @@
|
|||
<ul class="tabs">
|
||||
<li id="tab_recent" {{bindAttr class="view.classRecent"}}>
|
||||
<h5><a name="recent" {{action activate}}>{{t layouts.application.recent}}</a></h5>
|
||||
<h5><a name="recent" {{action activate target="view"}}>{{t layouts.application.recent}}</a></h5>
|
||||
</li>
|
||||
<li id="tab_owned" {{bindAttr class="view.classOwned"}}>
|
||||
<h5><a name="owned" {{action activate}}>{{t layouts.application.my_repositories}}</a></h5>
|
||||
<h5><a name="owned" {{action activate target="view"}}>{{t layouts.application.my_repositories}}</a></h5>
|
||||
</li>
|
||||
<li id="tab_search" {{bindAttr class="view.classSearch"}}>
|
||||
<h5><a name="search" {{action activate}}>{{t layouts.application.search}}</a></h5>
|
||||
<h5><a name="search" {{action activate target="view"}}>{{t layouts.application.search}}</a></h5>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -1,44 +1,56 @@
|
|||
<ul class="tabs">
|
||||
<li id="tab_current" {{bindAttr class="view.classCurrent"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlRepository"}} {{action route}}>
|
||||
{{#if view.repository.slug}}
|
||||
<a {{action showRepository view.repository href=true}}>
|
||||
{{t repositories.tabs.current}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
<li id="tab_builds" {{bindAttr class="view.classBuilds"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlBuilds"}} {{action route}}>
|
||||
{{#if view.repository.slug}}
|
||||
<a {{action showBuilds view.repository href=true}}>
|
||||
{{t repositories.tabs.build_history}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
<li id="tab_pull_requests" {{bindAttr class="view.classPullRequests"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlPullRequests"}} {{action route}}>
|
||||
{{#if view.repository.slug}}
|
||||
<a {{action showPullRequests view.repository href=true}}>
|
||||
{{t repositories.tabs.pull_requests}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
<li id="tab_branches" {{bindAttr class="view.classBranches"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlBranches"}} {{action route}}>
|
||||
{{#if view.repository.slug}}
|
||||
<a {{action showBranches view.repository href=true}}>
|
||||
{{t repositories.tabs.branches}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
<li id="tab_build" {{bindAttr class="view.classBuild"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlBuild"}} {{action route}}>
|
||||
{{t repositories.tabs.build}} {{view.build.number}}
|
||||
{{#if view.build.id}}
|
||||
<a {{action showBuild view.build href=true}}>
|
||||
{{t repositories.tabs.build}} #{{view.build.number}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
<li id="tab_job" {{bindAttr class="view.classJob"}}>
|
||||
<h5>
|
||||
<a {{bindAttr href="view.urlJob"}} {{action route}}>
|
||||
{{t repositories.tabs.job}} {{view.job.number}}
|
||||
{{#if view.job.id}}
|
||||
<a {{action showBuild view.job href=true}}>
|
||||
{{t repositories.tabs.job}} #{{view.job.number}}
|
||||
</a>
|
||||
{{/if}}
|
||||
</h5>
|
||||
</li>
|
||||
</ul>
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
{{#each group in controller.groups}}
|
||||
{{#view Travis.WorkersListView}}
|
||||
<li class="group">
|
||||
<h5 {{action toggle}}>
|
||||
<h5 {{action toggle target="view"}}>
|
||||
{{group.firstObject.host}}
|
||||
</h5>
|
||||
<ul>
|
||||
|
@ -16,9 +16,11 @@
|
|||
<li class="worker">
|
||||
<div class="status"></div>
|
||||
{{#if worker.isWorking}}
|
||||
<a {{bindAttr href="worker.urlJob"}} {{bindAttr title="worker.lastSeenAt"}} {{action route}}>
|
||||
{{view.display}}
|
||||
</a>
|
||||
{{#if view.job.id}}
|
||||
<a {{bindAttr title="worker.lastSeenAt"}} {{action showJob view.job href=true}}>
|
||||
{{view.display}}
|
||||
</a>
|
||||
{{/if}}
|
||||
{{else}}
|
||||
{{view.display}}
|
||||
{{/if}}
|
||||
|
|
|
@ -2,16 +2,14 @@ require 'ext/ember/namespace'
|
|||
|
||||
@Travis.reopen
|
||||
View: Em.View.extend
|
||||
route: (event) ->
|
||||
Travis.app.routes.route(event)
|
||||
|
||||
popup: (event) ->
|
||||
$("##{event.target.name}").remove().appendTo('body').toggle()
|
||||
|
||||
@Travis.reopen
|
||||
HomeLayout: Travis.View.extend(templateName: 'layouts/home')
|
||||
ProfileLayout: Travis.View.extend(templateName: 'layouts/profile')
|
||||
StatsLayout: Travis.View.extend(templateName: 'layouts/simple')
|
||||
HomeView: Travis.View.extend(templateName: 'layouts/home')
|
||||
ProfileLayoutView: Travis.View.extend(templateName: 'layouts/profile')
|
||||
StatsLayoutView: Travis.View.extend(templateName: 'layouts/simple')
|
||||
ApplicationView: Travis.View.extend(templateName: 'application')
|
||||
|
||||
require 'views/build'
|
||||
require 'views/job'
|
||||
|
|
|
@ -53,13 +53,7 @@
|
|||
'active' if @get('tab') == 'user'
|
||||
).property('tab')
|
||||
|
||||
urlAccount: (->
|
||||
Travis.Urls.account(@get('controller.account.login'))
|
||||
).property('controller.account.login')
|
||||
|
||||
urlUser: (->
|
||||
Travis.Urls.user(@get('controller.user.login'))
|
||||
).property('controller.user.login')
|
||||
accountBinding: 'controller.account'
|
||||
|
||||
displayUser: (->
|
||||
@get('controller.account.login') == @get('controller.user.login')
|
||||
|
|
|
@ -57,30 +57,6 @@
|
|||
'active display-inline' if @get('tab') == 'job'
|
||||
).property('tab')
|
||||
|
||||
urlRepository: (->
|
||||
Travis.Urls.repository(@get('repository.slug'))
|
||||
).property('repository.slug')
|
||||
|
||||
urlBuilds: (->
|
||||
Travis.Urls.builds(@get('repository.slug'))
|
||||
).property('repository.slug')
|
||||
|
||||
urlPullRequests: (->
|
||||
Travis.Urls.pullRequests(@get('repository.slug'))
|
||||
).property('repository.slug')
|
||||
|
||||
urlBranches: (->
|
||||
Travis.Urls.branches(@get('repository.slug'))
|
||||
).property('repository.slug')
|
||||
|
||||
urlBuild: (->
|
||||
Travis.Urls.build(@get('repository.slug'), @get('build.id'))
|
||||
).property('repository.slug', 'build.id')
|
||||
|
||||
urlJob: (->
|
||||
Travis.Urls.job(@get('repository.slug'), @get('job.id'))
|
||||
).property('repository.slug', 'job.id')
|
||||
|
||||
RepoShowToolsView: Travis.View.extend
|
||||
templateName: 'repos/show/tools'
|
||||
|
||||
|
|
|
@ -40,5 +40,14 @@ require 'ext/ember/namespace'
|
|||
|
||||
run: (attrs) ->
|
||||
console.log "Connecting to #{Travis.config.api_endpoint}"
|
||||
@app = Travis.App.create(attrs || {})
|
||||
app = Travis.App.create(attrs || {})
|
||||
# TODO: router expects the classes for controllers on main namespace, so
|
||||
# if we want to keep app at Travis.app, we need to copy that, it would
|
||||
# be ideal to send a patch to ember and get rid of this
|
||||
$.each Travis, (key, value) ->
|
||||
app[key] = value if value && value.isClass && key != 'constructor'
|
||||
|
||||
@app = app
|
||||
@store = app.store
|
||||
|
||||
app.initialize()
|
||||
|
|
23
assets/javascripts/vendor/ember-data.js
vendored
23
assets/javascripts/vendor/ember-data.js
vendored
|
@ -1748,6 +1748,7 @@ DS.Store = Ember.Object.extend({
|
|||
|
||||
loadMany: function(type, ids, hashes) {
|
||||
var clientIds = Ember.A([]);
|
||||
|
||||
if (hashes === undefined) {
|
||||
hashes = ids;
|
||||
ids = [];
|
||||
|
@ -3131,8 +3132,8 @@ DS.Model = Ember.Object.extend(Ember.Evented, {
|
|||
if (cachedValue) {
|
||||
var key = association.options.key || get(this, 'namingConvention').keyToJSONKey(name),
|
||||
ids = data.get(key) || [];
|
||||
|
||||
var clientIds;
|
||||
|
||||
var clientIds;
|
||||
if(association.options.embedded) {
|
||||
clientIds = store.loadMany(association.type, ids).clientIds;
|
||||
} else {
|
||||
|
@ -3140,7 +3141,7 @@ DS.Model = Ember.Object.extend(Ember.Evented, {
|
|||
return store.clientIdForId(association.type, id);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
set(cachedValue, 'content', Ember.A(clientIds));
|
||||
cachedValue.fetch();
|
||||
}
|
||||
|
@ -3155,7 +3156,7 @@ DS.Model = Ember.Object.extend(Ember.Evented, {
|
|||
also call methods with the given name.
|
||||
*/
|
||||
trigger: function(name) {
|
||||
this[name].apply(this, [].slice.call(arguments, 1));
|
||||
Ember.tryInvoke(this, name, [].slice.call(arguments, 1));
|
||||
this._super.apply(this, arguments);
|
||||
}
|
||||
});
|
||||
|
@ -3671,8 +3672,8 @@ DS.Adapter = Ember.Object.extend({
|
|||
(function() {
|
||||
var set = Ember.set;
|
||||
|
||||
Ember.onLoad('application', function(app) {
|
||||
app.registerInjection({
|
||||
Ember.onLoad('Ember.Application', function(Application) {
|
||||
Application.registerInjection({
|
||||
name: "store",
|
||||
before: "controllers",
|
||||
|
||||
|
@ -3683,11 +3684,11 @@ Ember.onLoad('application', function(app) {
|
|||
}
|
||||
});
|
||||
|
||||
app.registerInjection({
|
||||
Application.registerInjection({
|
||||
name: "giveStoreToControllers",
|
||||
|
||||
injection: function(app, stateManager, property) {
|
||||
if (property.match(/Controller$/)) {
|
||||
if (/^[A-Z].*Controller$/.test(property)) {
|
||||
var controllerName = property.charAt(0).toLowerCase() + property.substr(1);
|
||||
var store = stateManager.get('store');
|
||||
var controller = stateManager.get(controllerName);
|
||||
|
@ -3765,7 +3766,7 @@ DS.FixtureAdapter = DS.Adapter.extend({
|
|||
return ids.indexOf(item.id) !== -1;
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
if (fixtures) {
|
||||
this.simulateRemoteCall(function() {
|
||||
store.loadMany(type, fixtures);
|
||||
|
@ -3785,7 +3786,7 @@ DS.FixtureAdapter = DS.Adapter.extend({
|
|||
|
||||
findQuery: function(store, type, query, array) {
|
||||
var fixtures = this.fixturesForType(type);
|
||||
|
||||
|
||||
Ember.assert("Unable to find fixtures for model type "+type.toString(), !!fixtures);
|
||||
|
||||
fixtures = this.queryFixtures(fixtures, query);
|
||||
|
@ -3846,7 +3847,7 @@ var get = Ember.get, set = Ember.set;
|
|||
|
||||
DS.RESTAdapter = DS.Adapter.extend({
|
||||
bulkCommit: false,
|
||||
|
||||
|
||||
createRecord: function(store, type, record) {
|
||||
var root = this.rootForType(type);
|
||||
|
||||
|
|
8146
assets/javascripts/vendor/ember.js
vendored
8146
assets/javascripts/vendor/ember.js
vendored
File diff suppressed because it is too large
Load Diff
|
@ -17,6 +17,6 @@
|
|||
});
|
||||
</script>
|
||||
</head>
|
||||
<body></body>
|
||||
<body id="home"></body>
|
||||
</html>
|
||||
|
||||
|
|
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
|
@ -6334,8 +6334,13 @@ table.list .red .number a {
|
|||
#main #tab_job {
|
||||
display: none;
|
||||
}
|
||||
/* line 56, /Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/tabs.sass */
|
||||
#main #tab_build.display,
|
||||
#main #tab_job.display {
|
||||
display: inline-block !important;
|
||||
}
|
||||
|
||||
/* line 59, /Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/tabs.sass */
|
||||
/* line 61, /Users/sven/Development/projects/travis/travis-ember/assets/stylesheets/tabs.sass */
|
||||
#profile #main .tab {
|
||||
margin: 30px 0 0 12px;
|
||||
}
|
||||
|
|
|
@ -1,79 +0,0 @@
|
|||
#HTMLReporter { font-size: 11px; font-family: Monaco, "Lucida Console", monospace; line-height: 14px; color: #333333; }
|
||||
#HTMLReporter a { text-decoration: none; }
|
||||
#HTMLReporter a:hover { text-decoration: underline; }
|
||||
#HTMLReporter p, #HTMLReporter h1, #HTMLReporter h2, #HTMLReporter h3, #HTMLReporter h4, #HTMLReporter h5, #HTMLReporter h6 { margin: 0; line-height: 14px; }
|
||||
#HTMLReporter .banner, #HTMLReporter .symbolSummary, #HTMLReporter .summary, #HTMLReporter .resultMessage, #HTMLReporter .specDetail .description, #HTMLReporter .alert .bar, #HTMLReporter .stackTrace { padding-left: 9px; padding-right: 9px; }
|
||||
#HTMLReporter #jasmine_content { position: fixed; right: 100%; }
|
||||
#HTMLReporter .version { color: #aaaaaa; }
|
||||
#HTMLReporter .banner { margin-top: 14px; }
|
||||
#HTMLReporter .duration { color: #aaaaaa; float: right; }
|
||||
#HTMLReporter .symbolSummary { overflow: hidden; *zoom: 1; margin: 14px 0; }
|
||||
#HTMLReporter .symbolSummary li { display: block; float: left; height: 7px; width: 14px; margin-bottom: 7px; font-size: 16px; }
|
||||
#HTMLReporter .symbolSummary li.passed { font-size: 14px; }
|
||||
#HTMLReporter .symbolSummary li.passed:before { color: #5e7d00; content: "\02022"; }
|
||||
#HTMLReporter .symbolSummary li.failed { line-height: 9px; }
|
||||
#HTMLReporter .symbolSummary li.failed:before { color: #b03911; content: "x"; font-weight: bold; margin-left: -1px; }
|
||||
#HTMLReporter .symbolSummary li.skipped { font-size: 14px; }
|
||||
#HTMLReporter .symbolSummary li.skipped:before { color: #bababa; content: "\02022"; }
|
||||
#HTMLReporter .symbolSummary li.pending { line-height: 11px; }
|
||||
#HTMLReporter .symbolSummary li.pending:before { color: #aaaaaa; content: "-"; }
|
||||
#HTMLReporter .bar { line-height: 28px; font-size: 14px; display: block; color: #eee; }
|
||||
#HTMLReporter .runningAlert { background-color: #666666; }
|
||||
#HTMLReporter .skippedAlert { background-color: #aaaaaa; }
|
||||
#HTMLReporter .skippedAlert:first-child { background-color: #333333; }
|
||||
#HTMLReporter .skippedAlert:hover { text-decoration: none; color: white; text-decoration: underline; }
|
||||
#HTMLReporter .passingAlert { background-color: #a6b779; }
|
||||
#HTMLReporter .passingAlert:first-child { background-color: #5e7d00; }
|
||||
#HTMLReporter .failingAlert { background-color: #cf867e; }
|
||||
#HTMLReporter .failingAlert:first-child { background-color: #b03911; }
|
||||
#HTMLReporter .results { margin-top: 14px; }
|
||||
#HTMLReporter #details { display: none; }
|
||||
#HTMLReporter .resultsMenu, #HTMLReporter .resultsMenu a { background-color: #fff; color: #333333; }
|
||||
#HTMLReporter.showDetails .summaryMenuItem { font-weight: normal; text-decoration: inherit; }
|
||||
#HTMLReporter.showDetails .summaryMenuItem:hover { text-decoration: underline; }
|
||||
#HTMLReporter.showDetails .detailsMenuItem { font-weight: bold; text-decoration: underline; }
|
||||
#HTMLReporter.showDetails .summary { display: none; }
|
||||
#HTMLReporter.showDetails #details { display: block; }
|
||||
#HTMLReporter .summaryMenuItem { font-weight: bold; text-decoration: underline; }
|
||||
#HTMLReporter .summary { margin-top: 14px; }
|
||||
#HTMLReporter .summary .suite .suite, #HTMLReporter .summary .specSummary { margin-left: 14px; }
|
||||
#HTMLReporter .summary .specSummary.passed a { color: #5e7d00; }
|
||||
#HTMLReporter .summary .specSummary.failed a { color: #b03911; }
|
||||
#HTMLReporter .description + .suite { margin-top: 0; }
|
||||
#HTMLReporter .suite { margin-top: 14px; }
|
||||
#HTMLReporter .suite a { color: #333333; }
|
||||
#HTMLReporter #details .specDetail { margin-bottom: 28px; }
|
||||
#HTMLReporter #details .specDetail .description { display: block; color: white; background-color: #b03911; }
|
||||
#HTMLReporter .resultMessage { padding-top: 14px; color: #333333; }
|
||||
#HTMLReporter .resultMessage span.result { display: block; }
|
||||
#HTMLReporter .stackTrace { margin: 5px 0 0 0; max-height: 224px; overflow: auto; line-height: 18px; color: #666666; border: 1px solid #ddd; background: white; white-space: pre; }
|
||||
|
||||
#TrivialReporter { padding: 8px 13px; clear: both; overflow-y: scroll; background-color: white; font-family: "Helvetica Neue Light", "Lucida Grande", "Calibri", "Arial", sans-serif; /*.resultMessage {*/ /*white-space: pre;*/ /*}*/ }
|
||||
#TrivialReporter a:visited, #TrivialReporter a { color: #303; }
|
||||
#TrivialReporter a:hover, #TrivialReporter a:active { color: blue; }
|
||||
#TrivialReporter .run_spec { float: right; padding-right: 5px; font-size: .8em; text-decoration: none; }
|
||||
#TrivialReporter .banner { color: #303; background-color: #fef; padding: 5px; }
|
||||
#TrivialReporter .logo { float: left; font-size: 1.1em; padding-left: 5px; }
|
||||
#TrivialReporter .logo .version { font-size: .6em; padding-left: 1em; }
|
||||
#TrivialReporter .runner.running { background-color: yellow; }
|
||||
#TrivialReporter .options { text-align: right; font-size: .8em; }
|
||||
#TrivialReporter .suite { border: 1px outset gray; margin: 5px 0; padding-left: 1em; }
|
||||
#TrivialReporter .suite .suite { margin: 5px; }
|
||||
#TrivialReporter .suite.passed { background-color: #dfd; }
|
||||
#TrivialReporter .suite.failed { background-color: #fdd; }
|
||||
#TrivialReporter .spec { margin: 5px; padding-left: 1em; clear: both; }
|
||||
#TrivialReporter .spec.failed, #TrivialReporter .spec.passed, #TrivialReporter .spec.skipped { padding-bottom: 5px; border: 1px solid gray; }
|
||||
#TrivialReporter .spec.failed { background-color: #fbb; border-color: red; }
|
||||
#TrivialReporter .spec.passed { background-color: #bfb; border-color: green; }
|
||||
#TrivialReporter .spec.skipped { background-color: #bbb; }
|
||||
#TrivialReporter .messages { border-left: 1px dashed gray; padding-left: 1em; padding-right: 1em; }
|
||||
#TrivialReporter .passed { background-color: #cfc; display: none; }
|
||||
#TrivialReporter .failed { background-color: #fbb; }
|
||||
#TrivialReporter .skipped { color: #777; background-color: #eee; display: none; }
|
||||
#TrivialReporter .resultMessage span.result { display: block; line-height: 2em; color: black; }
|
||||
#TrivialReporter .resultMessage .mismatch { color: black; }
|
||||
#TrivialReporter .stackTrace { white-space: pre; font-size: .8em; margin-left: 10px; max-height: 5em; overflow: auto; border: 1px inset red; padding: 1em; background: #eef; }
|
||||
#TrivialReporter .finished-at { padding-left: 1em; font-size: .6em; }
|
||||
#TrivialReporter.show-passed .passed, #TrivialReporter.show-skipped .skipped { display: block; }
|
||||
#TrivialReporter #jasmine_content { position: fixed; right: 100%; }
|
||||
#TrivialReporter .runner { border: 1px solid gray; display: block; margin: 5px 0; padding: 2px 0 2px 10px; }
|
Loading…
Reference in New Issue
Block a user