diff --git a/addons/git/addon-built.js b/addons/git/addon-built.js index 4a3a2583..583fbacb 100644 --- a/addons/git/addon-built.js +++ b/addons/git/addon-built.js @@ -1 +1 @@ -define("require-tools/less/normalize",[],function(){function r(e,r,i){if(e.indexOf("data:")===0)return e;e=t(e);var u=i.match(n),a=r.match(n);return a&&(!u||u[1]!=a[1]||u[2]!=a[2])?s(e,r):o(s(e,r),i)}function s(e,t){e.substr(0,2)=="./"&&(e=e.substr(2));if(e.match(/^\//)||e.match(n))return e;var r=t.split("/"),i=e.split("/");r.pop();while(curPart=i.shift())curPart==".."?r.pop():r.push(curPart);return r.join("/")}function o(e,t){var n=t.split("/");n.pop(),t=n.join("/")+"/",i=0;while(t.substr(i,1)==e.substr(i,1))i++;while(t.substr(i,1)!="/")i--;t=t.substr(i+1),e=e.substr(i+1),n=t.split("/");var r=e.split("/");out="";while(n.shift())out+="../";while(curPart=r.shift())out+=curPart+"/";return out.substr(0,out.length-1)}var e=/([^:])\/+/g,t=function(t){return t.replace(e,"$1/")},n=/[^\:\/]*:\/\/([^\/])*/,u=function(e,n,i){n=t(n),i=t(i);var s=/@import\s*("([^"]*)"|'([^']*)')|url\s*\(\s*(\s*"([^"]*)"|'([^']*)'|[^\)]*\s*)\s*\)/ig,o,u,e;while(o=s.exec(e)){u=o[3]||o[2]||o[5]||o[6]||o[4];var a;a=r(u,n,i);var f=o[5]||o[6]?1:0;e=e.substr(0,s.lastIndex-u.length-f-1)+a+e.substr(s.lastIndex-f-1),s.lastIndex=s.lastIndex+(a.length-u.length)}return e};return u.convertURIBase=r,u.absoluteURI=s,u.relativeURI=o,u}),define("require-tools/less/less",["require"],function(e){var t={};t.pluginBuilder="./less-builder";if(typeof window=="undefined")return t.load=function(e,t,n){n()},less;t.normalize=function(e,t){return e.substr(e.length-5,5)==".less"&&(e=e.substr(0,e.length-5)),e=t(e),e};var n=document.getElementsByTagName("head")[0],r=window.location.href.split("/");r[r.length-1]="",r=r.join("/");var i;window.less=window.less||{env:"development"};var s=0,o;t.inject=function(e){s<31&&(o=document.createElement("style"),o.type="text/css",n.appendChild(o),s++),o.styleSheet?o.styleSheet.cssText+=e:o.appendChild(document.createTextNode(e))};var u;return t.load=function(n,s,o,a){e(["./lessc","./normalize"],function(a,f){if(!i){var l=e.toUrl("base_url").split("/");l[l.length-1]="",i=f.absoluteURI(l.join("/"),r)+"/"}var c=s.toUrl(n+".less");c=f.absoluteURI(c,i),u=u||new a.Parser(window.less),u.parse('@import "'+c+'";',function(e,n){if(e)return o.error(e);t.inject(f(n.toCSS(),c,r)),setTimeout(o,7)})})},t}),define("require-tools/less/less!stylesheets/git",[],function(){}),define("views/dialog",["less!stylesheets/git.less"],function(){var e=codebox.require("views/dialogs/base"),t=codebox.require("core/box"),n=e.extend({className:"addon-git-dialog modal fade",templateLoader:"addon.git.templates",template:"dialog.html",events:_.extend({},e.prototype.events,{"submit .git-commit":"submit"}),initialize:function(e){var r=this;return n.__super__.initialize.apply(this,arguments),r.git=null,t.gitStatus().then(function(e){r.git=e,r.render()}),this},templateContext:function(){return{git:this.git}},render:function(){return this.git?n.__super__.render.apply(this,arguments):this},finish:function(){return n.__super__.finish.apply(this,arguments)},submit:function(e){e&&e.preventDefault();var n=this,r=this.$(".git-commit .btn-git-sync").hasClass("active"),i=this.$(".git-commit textarea").val();if(i.length==0)return;t.commit({message:i}).then(function(){if(r)return t.sync()}).then(function(){n.close()})}});return n}),define("client",["views/dialog"],function(e){var t=codebox.require("core/commands"),n=codebox.require("core/app"),r=codebox.require("utils/dialogs");t.register("addons.git",{title:"GIT",icon:"code-fork"},function(){r.open(e)})}),function(e){var t=document,n="appendChild",r="styleSheet",i=t.createElement("style");i.type="text/css",t.getElementsByTagName("head")[0][n](i),i[r]?i[r].cssText=e:i[n](t.createTextNode(e))}(".addon-git-dialog .modal-body{padding:0}.addon-git-dialog .modal-footer,.addon-git-dialog .navbar{margin:0}.addon-git-dialog .git-commit{padding:10px;background:#f8f8f8}.addon-git-dialog .git-changes{list-style:none;margin:0;padding:0}.addon-git-dialog .git-changes .file{margin:5px 3px;background:#f5f5f5;border-left:5px solid transparent;padding:5px}.addon-git-dialog .git-changes .file.type-M{border-left-color:#3498db}.addon-git-dialog .git-changes .file.type-A{border-left-color:#2ecc71}.addon-git-dialog .git-changes .file.type-R{border-left-color:#e74c3c}") \ No newline at end of file +define("require-tools/less/normalize",[],function(){function r(e,r,i){if(e.indexOf("data:")===0)return e;e=t(e);var u=i.match(n),a=r.match(n);return a&&(!u||u[1]!=a[1]||u[2]!=a[2])?s(e,r):o(s(e,r),i)}function s(e,t){e.substr(0,2)=="./"&&(e=e.substr(2));if(e.match(/^\//)||e.match(n))return e;var r=t.split("/"),i=e.split("/");r.pop();while(curPart=i.shift())curPart==".."?r.pop():r.push(curPart);return r.join("/")}function o(e,t){var n=t.split("/");n.pop(),t=n.join("/")+"/",i=0;while(t.substr(i,1)==e.substr(i,1))i++;while(t.substr(i,1)!="/")i--;t=t.substr(i+1),e=e.substr(i+1),n=t.split("/");var r=e.split("/");out="";while(n.shift())out+="../";while(curPart=r.shift())out+=curPart+"/";return out.substr(0,out.length-1)}var e=/([^:])\/+/g,t=function(t){return t.replace(e,"$1/")},n=/[^\:\/]*:\/\/([^\/])*/,u=function(e,n,i){n=t(n),i=t(i);var s=/@import\s*("([^"]*)"|'([^']*)')|url\s*\(\s*(\s*"([^"]*)"|'([^']*)'|[^\)]*\s*)\s*\)/ig,o,u,e;while(o=s.exec(e)){u=o[3]||o[2]||o[5]||o[6]||o[4];var a;a=r(u,n,i);var f=o[5]||o[6]?1:0;e=e.substr(0,s.lastIndex-u.length-f-1)+a+e.substr(s.lastIndex-f-1),s.lastIndex=s.lastIndex+(a.length-u.length)}return e};return u.convertURIBase=r,u.absoluteURI=s,u.relativeURI=o,u}),define("require-tools/less/less",["require"],function(e){var t={};t.pluginBuilder="./less-builder";if(typeof window=="undefined")return t.load=function(e,t,n){n()},less;t.normalize=function(e,t){return e.substr(e.length-5,5)==".less"&&(e=e.substr(0,e.length-5)),e=t(e),e};var n=document.getElementsByTagName("head")[0],r=window.location.href.split("/");r[r.length-1]="",r=r.join("/");var i;window.less=window.less||{env:"development"};var s=0,o;t.inject=function(e){s<31&&(o=document.createElement("style"),o.type="text/css",n.appendChild(o),s++),o.styleSheet?o.styleSheet.cssText+=e:o.appendChild(document.createTextNode(e))};var u;return t.load=function(n,s,o,a){e(["./lessc","./normalize"],function(a,f){if(!i){var l=e.toUrl("base_url").split("/");l[l.length-1]="",i=f.absoluteURI(l.join("/"),r)+"/"}var c=s.toUrl(n+".less");c=f.absoluteURI(c,i),u=u||new a.Parser(window.less),u.parse('@import "'+c+'";',function(e,n){if(e)return o.error(e);t.inject(f(n.toCSS(),c,r)),setTimeout(o,7)})})},t}),define("require-tools/less/less!stylesheets/git",[],function(){}),define("views/dialog",["less!stylesheets/git.less"],function(){var e=codebox.require("views/dialogs/base"),t=codebox.require("core/box"),n=e.extend({className:"addon-git-dialog modal fade",templateLoader:"addon.git.templates",template:"dialog.html",events:_.extend({},e.prototype.events,{"submit .git-commit":"submit"}),initialize:function(e){var r=this;return n.__super__.initialize.apply(this,arguments),r.git=null,t.gitStatus().then(function(e){r.git=e,r.render()}),this},templateContext:function(){return{git:this.git}},render:function(){return this.git?n.__super__.render.apply(this,arguments):this},finish:function(){return n.__super__.finish.apply(this,arguments)},submit:function(e){e&&e.preventDefault();var n=this,r=this.$(".git-commit .btn-git-sync").hasClass("active"),i=this.$(".git-commit textarea").val();if(i.length==0)return;t.commit({message:i}).then(function(){if(r)return t.sync()}).then(function(){n.close()})}});return n}),define("client",["views/dialog"],function(e){var t=codebox.require("core/commands"),n=codebox.require("core/app"),r=codebox.require("utils/dialogs");t.register("addons.git",{title:"GIT",icon:"code-fork"},function(){r.open(e)})}),function(e){var t=document,n="appendChild",r="styleSheet",i=t.createElement("style");i.type="text/css",t.getElementsByTagName("head")[0][n](i),i[r]?i[r].cssText=e:i[n](t.createTextNode(e))}(".addon-git-dialog .modal-body{padding:0}.addon-git-dialog .modal-footer,.addon-git-dialog .navbar{margin:0}.addon-git-dialog .git-commit{padding:10px;background:#f8f8f8}.addon-git-dialog .git-changes{list-style:none;margin:0;padding:0}.addon-git-dialog .git-changes .file{background:#f5f5f5;border-left:5px solid transparent;border-top:1px solid #ddd;padding:10px}.addon-git-dialog .git-changes .file.type-M{border-left-color:#3498db}.addon-git-dialog .git-changes .file.type-A{border-left-color:#2ecc71}.addon-git-dialog .git-changes .file.type-R{border-left-color:#e74c3c}") \ No newline at end of file diff --git a/addons/git/stylesheets/git.less b/addons/git/stylesheets/git.less index fadf8c1c..73db6216 100644 --- a/addons/git/stylesheets/git.less +++ b/addons/git/stylesheets/git.less @@ -21,10 +21,10 @@ padding: 0px; .file { - margin: 5px 3px; background: #f5f5f5; border-left: 5px solid transparent; - padding: 5px; + border-top: 1px solid #ddd; + padding: 10px; &.type-M { border-left-color: #3498db; diff --git a/package.json b/package.json index 84083d82..42191b94 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "codebox", "description": "Open Cloud IDE", "homepage": "https://www.codebox.io", - "version": "0.2.10", + "version": "0.2.11", "author": "contact@friendco.de", "dependencies": { "q": "0.9.6",