You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by se...@apache.org on 2021/03/19 23:03:40 UTC
[whimsy] branch master updated: Add date to tab title
This is an automated email from the ASF dual-hosted git repository.
sebb 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 c277085 Add date to tab title
c277085 is described below
commit c277085198807f9a2aafae53daa6d8294af6e8b1
Author: Sebb <se...@apache.org>
AuthorDate: Fri Mar 19 23:03:33 2021 +0000
Add date to tab title
---
www/board/agenda/views/layout/main.js.rb | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/www/board/agenda/views/layout/main.js.rb b/www/board/agenda/views/layout/main.js.rb
index bf71842..4a62e7f 100644
--- a/www/board/agenda/views/layout/main.js.rb
+++ b/www/board/agenda/views/layout/main.js.rb
@@ -71,7 +71,13 @@ class Main < Vue
# update title to match the item title whenever page changes
if defined? document and route.item
- document.getElementsByTagName('title')[0].textContent = route.item.title
+ date = Agenda.date
+ title = route.item.title
+ if date != title # don't duplicate the date
+ document.getElementsByTagName('title')[0].textContent = date + ' ' + title
+ else
+ document.getElementsByTagName('title')[0].textContent = title
+ end
end
end