From b7be63f3a8aeefba8bad13f74af4b77e625edeb9 Mon Sep 17 00:00:00 2001 From: James Allen Date: Thu, 3 May 2018 17:34:51 +0100 Subject: [PATCH 1/2] Import Overleaf v1 theme from sharelatex/ace --- .../web/public/js/ace-1.2.5/theme-overleaf.js | 72 +++++++++++++++++++ 1 file changed, 72 insertions(+) create mode 100644 services/web/public/js/ace-1.2.5/theme-overleaf.js diff --git a/services/web/public/js/ace-1.2.5/theme-overleaf.js b/services/web/public/js/ace-1.2.5/theme-overleaf.js new file mode 100644 index 0000000000..85bd3b0737 --- /dev/null +++ b/services/web/public/js/ace-1.2.5/theme-overleaf.js @@ -0,0 +1,72 @@ +ace.define("ace/theme/overleaf",["require","exports","module","ace/lib/dom"], function(require, exports, module) { +"use strict"; + +exports.isDark = false; +exports.cssClass = "ace-overleaf"; +exports.cssText = ".ace-overleaf .ace_gutter {\ +background: #f0f0f0;\ +color: #333;\ +}\ +.ace-overleaf .ace_print-margin {\ +width: 1px;\ +background: #e8e8e8;\ +}\ +.ace-overleaf {\ +background-color: #FFFFFF;\ +color: black;\ +}\ +.ace-overleaf .ace_cursor {\ +color: black;\ +}\ +.ace-overleaf .ace_marker-layer .ace_selection {\ +background: rgb(181, 213, 255);\ +}\ +.ace-overleaf.ace_multiselect .ace_selection.ace_start {\ +box-shadow: 0 0 3px 0px white;\ +}\ +.ace-overleaf .ace_marker-layer .ace_step {\ +background: rgb(252, 255, 0);\ +}\ +.ace-overleaf .ace_marker-layer .ace_bracket {\ +margin: -1px 0 0 -1px;\ +border: 1px solid #cc7;\ +}\ +.ace-overleaf .ace_marker-layer .ace_active-line {\ +background: rgba(0, 0, 0, 0.07);\ +}\ +.ace-overleaf .ace_gutter-active-line {\ +background-color: #dcdcdc;\ +}\ +.ace-overleaf .ace_marker-layer .ace_selected-word {\ +background: rgb(250, 250, 255);\ +border: 1px solid rgb(200, 200, 250);\ +}\ +.ace-overleaf .ace_fold {\ +background-color: #6B72E6;\ +}\ +.ace-overleaf .ace_comment {\ +color: #0080FF;\ +font-style: italic;\ +}\ +.ace-overleaf .ace_storage,\ +.ace-overleaf .ace_keyword {\ +color: #3F7F7F;\ +}\ +.ace-overleaf .ace_variable,\ +.ace-overleaf .ace_string {\ +color: #5A5CAD;\ +}\ +"; +exports.$id = "ace/theme/overleaf"; + +var dom = require("../lib/dom"); +dom.importCssString(exports.cssText, exports.cssClass); +}); + (function() { + ace.require(["ace/theme/overleaf"], function(m) { + if (typeof module == "object" && typeof exports == "object" && module) { + module.exports = m; + } + }); + })(); + \ No newline at end of file From 049fe6e176f29be592d43a5232fd4ff9899b15c3 Mon Sep 17 00:00:00 2001 From: James Allen Date: Fri, 11 May 2018 10:24:58 +0100 Subject: [PATCH 2/2] Update bracket border colour --- services/web/public/js/ace-1.2.5/theme-overleaf.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/services/web/public/js/ace-1.2.5/theme-overleaf.js b/services/web/public/js/ace-1.2.5/theme-overleaf.js index 85bd3b0737..f2162a542c 100644 --- a/services/web/public/js/ace-1.2.5/theme-overleaf.js +++ b/services/web/public/js/ace-1.2.5/theme-overleaf.js @@ -28,8 +28,7 @@ box-shadow: 0 0 3px 0px white;\ background: rgb(252, 255, 0);\ }\ .ace-overleaf .ace_marker-layer .ace_bracket {\ -margin: -1px 0 0 -1px;\ -border: 1px solid #cc7;\ +border: 1px solid #5A5CAD;\ }\ .ace-overleaf .ace_marker-layer .ace_active-line {\ background: rgba(0, 0, 0, 0.07);\