allura-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jetm...@apache.org
Subject [35/50] [abbrv] allura git commit: [#7897] ticket:814 Focus editor by click & fix z-index for help & preview
Date Tue, 14 Jul 2015 15:03:16 GMT
[#7897] ticket:814 Focus editor by click & fix z-index for help & preview


Project: http://git-wip-us.apache.org/repos/asf/allura/repo
Commit: http://git-wip-us.apache.org/repos/asf/allura/commit/bc26ab1f
Tree: http://git-wip-us.apache.org/repos/asf/allura/tree/bc26ab1f
Diff: http://git-wip-us.apache.org/repos/asf/allura/diff/bc26ab1f

Branch: refs/heads/ib/7897
Commit: bc26ab1ff7b40aafc268b84d308a9a5de28f40d7
Parents: 542841d
Author: Igor Bondarenko <jetmind2@gmail.com>
Authored: Tue Jul 7 17:26:09 2015 +0300
Committer: Igor Bondarenko <jetmind2@gmail.com>
Committed: Tue Jul 14 11:46:02 2015 +0300

----------------------------------------------------------------------
 Allura/allura/lib/widgets/resources/css/markitup_sf.css | 5 +++++
 Allura/allura/lib/widgets/resources/js/sf_markitup.js   | 3 +++
 2 files changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/allura/blob/bc26ab1f/Allura/allura/lib/widgets/resources/css/markitup_sf.css
----------------------------------------------------------------------
diff --git a/Allura/allura/lib/widgets/resources/css/markitup_sf.css b/Allura/allura/lib/widgets/resources/css/markitup_sf.css
index 2c12807..5310c69 100644
--- a/Allura/allura/lib/widgets/resources/css/markitup_sf.css
+++ b/Allura/allura/lib/widgets/resources/css/markitup_sf.css
@@ -51,3 +51,8 @@
 .markdown_edit .editor-preview {
   padding: 5px;
 }
+
+
+.markdown_edit .editor-preview {
+  z-index: 1001;  /* should always be under help modal */
+}

http://git-wip-us.apache.org/repos/asf/allura/blob/bc26ab1f/Allura/allura/lib/widgets/resources/js/sf_markitup.js
----------------------------------------------------------------------
diff --git a/Allura/allura/lib/widgets/resources/js/sf_markitup.js b/Allura/allura/lib/widgets/resources/js/sf_markitup.js
index f3f2c44..4c0cd20 100644
--- a/Allura/allura/lib/widgets/resources/js/sf_markitup.js
+++ b/Allura/allura/lib/widgets/resources/js/sf_markitup.js
@@ -60,6 +60,9 @@ $(window).load(function() {
             });
             editor.render();
 
+            // focus editor by clicking anywhere on it, not only on the first few lines
+            $('.CodeMirror').click(function () { cm.focus(); });
+
             function show_help(editor) {
               $help_contents.html('Loading...');
               $.get($help_contents.attr('data-url'), function (data) {


Mime
View raw message