From dee359114709c6b7868edcf39e4d9c0adac19a12 Mon Sep 17 00:00:00 2001 From: Sven Fuchs Date: Sat, 13 Oct 2012 04:34:30 +0200 Subject: [PATCH] some tweaks --- AssetFile | 12 +- Gemfile.lock | 2 +- assets/scripts/app/routes.coffee | 4 +- assets/scripts/app/templates/auth/signin.hbs | 4 +- assets/scripts/app/views/signin.coffee | 2 +- assets/static/index.html | 19 -- public/scripts/app.js | 2 +- public/scripts/min/app.js | 2 +- public/styles/app.css | 213 +++++++++++++++++++ public/version | 2 +- 10 files changed, 228 insertions(+), 34 deletions(-) delete mode 100644 assets/static/index.html diff --git a/AssetFile b/AssetFile index 50ea9beb..d6b72c0f 100644 --- a/AssetFile +++ b/AssetFile @@ -57,9 +57,9 @@ input assets.images do end end -output 'public' -input assets.static do - match '**/*' do - copy - end -end +# output 'public' +# input assets.static do +# match '**/*' do +# copy +# end +# end diff --git a/Gemfile.lock b/Gemfile.lock index 4f3ccd70..f71dddb6 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -43,7 +43,7 @@ GIT GIT remote: git://github.com/travis-ci/travis-api.git - revision: 272c1275f49cd33668dd5c4a324d49491dd29496 + revision: 2705e23bb60c1c1e140912c18f6f20ada8ad0139 specs: travis-api (0.0.1) backports (~> 2.5) diff --git a/assets/scripts/app/routes.coffee b/assets/scripts/app/routes.coffee index 0339ca2f..07160706 100644 --- a/assets/scripts/app/routes.coffee +++ b/assets/scripts/app/routes.coffee @@ -145,7 +145,7 @@ Travis.Router = Ember.Router.extend !!Travis.app.get('auth.user') needsAuth: (path) -> - path.indexOf('/profile') == 0 && !@signedIn() + path.indexOf('/profile') == 0 authenticate: -> @app.get('router').transitionTo('authenticated') @@ -155,7 +155,7 @@ Travis.Router = Ember.Router.extend router.saveLineNumberHash(path) sessionStorage.setItem('travis.path', path) - if router.needsAuth(path) + if !router.signedIn() && router.needsAuth(path) router.transitionTo('root.auth') Travis.app.signIn() else diff --git a/assets/scripts/app/templates/auth/signin.hbs b/assets/scripts/app/templates/auth/signin.hbs index 29ad1483..17b32579 100644 --- a/assets/scripts/app/templates/auth/signin.hbs +++ b/assets/scripts/app/templates/auth/signin.hbs @@ -1,12 +1,12 @@ {{#if view.signingIn}} -

Signing in

+

Signing in ...

Trying to authenticate with GitHub.

{{else}}

Sign in

- Sign in with GitHub + Please sign in with GitHub.

{{/if}} diff --git a/assets/scripts/app/views/signin.coffee b/assets/scripts/app/views/signin.coffee index a61ca5bc..afb75fb6 100644 --- a/assets/scripts/app/views/signin.coffee +++ b/assets/scripts/app/views/signin.coffee @@ -3,5 +3,5 @@ templateName: 'auth/signin' signingIn: (-> - Travis.app.get('authState') + Travis.app.get('authState') == 'signing-in' ).property('Travis.app.authState') diff --git a/assets/static/index.html b/assets/static/index.html deleted file mode 100644 index 4a22cdb1..00000000 --- a/assets/static/index.html +++ /dev/null @@ -1,19 +0,0 @@ - - - - - - - - Travis CI - Distributed Continuous Integration Platform for the Open Source Community - - - - - - - - diff --git a/public/scripts/app.js b/public/scripts/app.js index e299751d..9d8ef832 100644 --- a/public/scripts/app.js +++ b/public/scripts/app.js @@ -29619,4 +29619,4 @@ var _require=function(){function c(a,c){document.addEventListener?a.addEventList ++g&&setTimeout(c,0)})}}(); (function(){!window.WebSocket&&window.MozWebSocket&&(window.WebSocket=window.MozWebSocket);if(window.WebSocket)Pusher.Transport=window.WebSocket,Pusher.TransportType="native";var c=(document.location.protocol=="http:"?Pusher.cdn_http:Pusher.cdn_https)+Pusher.VERSION,a=[];window.JSON||a.push(c+"/json2"+Pusher.dependency_suffix+".js");if(!window.WebSocket)window.WEB_SOCKET_DISABLE_AUTO_INITIALIZATION=!0,a.push(c+"/flashfallback"+Pusher.dependency_suffix+".js");var b=function(){return window.WebSocket?function(){Pusher.ready()}: function(){window.WebSocket?(Pusher.Transport=window.WebSocket,Pusher.TransportType="flash",window.WEB_SOCKET_SWF_LOCATION=c+"/WebSocketMain.swf",WebSocket.__addTask(function(){Pusher.ready()}),WebSocket.__initialize()):(Pusher.Transport=null,Pusher.TransportType="none",Pusher.ready())}}(),e=function(a){var b=function(){document.body?a():setTimeout(b,0)};b()},g=function(){e(b)};a.length>0?_require(a,g):g()})(); -;minispade.register('app', "(function() {(function() {\nminispade.require('auth');\nminispade.require('controllers');\nminispade.require('helpers');\nminispade.require('models');\nminispade.require('pusher');\nminispade.require('routes');\nminispade.require('slider');\nminispade.require('store');\nminispade.require('tailing');\nminispade.require('templates');\nminispade.require('views');\nminispade.require('config/locales');\nminispade.require('data/sponsors');\n\n Travis.reopen({\n App: Em.Application.extend({\n autoinit: false,\n currentUserBinding: 'auth.user',\n authStateBinding: 'auth.state',\n init: function() {\n this._super.apply(this, arguments);\n this.store = Travis.Store.create();\n this.store.loadMany(Travis.Sponsor, Travis.SPONSORS);\n this.set('auth', Travis.Auth.create({\n app: this,\n endpoint: Travis.config.api_endpoint\n }));\n this.slider = new Travis.Slider();\n this.pusher = new Travis.Pusher(Travis.config.pusher_key);\n return this.tailing = new Travis.Tailing();\n },\n signIn: function() {\n return this.get('auth').signIn();\n },\n signOut: function() {\n this.get('auth').signOut();\n return this.get('router').send('showRoot');\n },\n receive: function() {\n return this.store.receive.apply(this.store, arguments);\n },\n toggleSidebar: function() {\n var element;\n $('body').toggleClass('maximized');\n element = $('');\n $('#top .profile').append(element);\n Em.run.later((function() {\n return element.remove();\n }), 10);\n element = $('');\n $('#repo').append(element);\n return Em.run.later((function() {\n return element.remove();\n }), 10);\n }\n })\n });\n\n}).call(this);\n\n})();\n//@ sourceURL=app");minispade.register('auth', "(function() {(function() {\n\n this.Travis.Auth = Ember.Object.extend({\n iframe: $('