whimsical-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject [whimsy] branch master updated: track hidden form to current page; retab
Date Mon, 02 Apr 2018 22:05:45 GMT
This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new fe10de9  track hidden form to current page; retab
fe10de9 is described below

commit fe10de9af453d00ed7faf244a9ab52388f460fd8
Author: Sam Ruby <rubys@intertwingly.net>
AuthorDate: Mon Apr 2 18:05:21 2018 -0400

    track hidden form to current page; retab
---
 www/board/agenda/views/buttons/post.js.rb | 17 +++++++++--------
 1 file changed, 9 insertions(+), 8 deletions(-)

diff --git a/www/board/agenda/views/buttons/post.js.rb b/www/board/agenda/views/buttons/post.js.rb
index a5af2380..4c6f937 100644
--- a/www/board/agenda/views/buttons/post.js.rb
+++ b/www/board/agenda/views/buttons/post.js.rb
@@ -102,6 +102,7 @@ class Post < Vue
   def mounted()
     jQuery('#post-report-form').on 'show.bs.modal' do
       # update contents when modal is about to be shown
+      @button = @@button.text
       self.retitle()
     end
 
@@ -118,16 +119,16 @@ class Post < Vue
   # set focus, scroll
   def reposition()
     # set focus once modal is shown
-		title = document.getElementById("post-report-title")
-		text = document.getElementById("post-report-text")
+    title = document.getElementById("post-report-title")
+    text = document.getElementById("post-report-text")
 
-		if title || text
-			(title || text).focus()
+    if title || text
+      (title || text).focus()
 
-			# scroll to the top
-			setTimeout 0 do
-				text.scrollTop = 0 if text
-			end
+      # scroll to the top
+      setTimeout 0 do
+        text.scrollTop = 0 if text
+      end
     end
 
     Post.header == @header

-- 
To stop receiving notification emails like this one, please contact
rubys@apache.org.

Mime
View raw message