summaryrefslogtreecommitdiffstats
path: root/client/components/sidebar
diff options
context:
space:
mode:
authorJoel Louzado <jlouzado@gmail.com>2017-02-15 21:30:03 +0530
committerJoel Louzado <jlouzado@gmail.com>2017-02-15 21:30:03 +0530
commit7393818fc0ec5e9d32815ada51bf434c2ba79dec (patch)
tree8e64dfe013ed63ff27c3c1083a276cbcbfdf0a2c /client/components/sidebar
parentbe9adfaad4032ddb3d78a7ce4ede23d4a7053ab8 (diff)
downloadwekan-7393818fc0ec5e9d32815ada51bf434c2ba79dec.tar.gz
wekan-7393818fc0ec5e9d32815ada51bf434c2ba79dec.tar.bz2
wekan-7393818fc0ec5e9d32815ada51bf434c2ba79dec.zip
Added dynamic tooltip for sidebar tongue
Diffstat (limited to 'client/components/sidebar')
-rw-r--r--client/components/sidebar/sidebar.jade2
-rw-r--r--client/components/sidebar/sidebar.js7
2 files changed, 8 insertions, 1 deletions
diff --git a/client/components/sidebar/sidebar.jade b/client/components/sidebar/sidebar.jade
index cb0845af..572890b6 100644
--- a/client/components/sidebar/sidebar.jade
+++ b/client/components/sidebar/sidebar.jade
@@ -1,7 +1,7 @@
template(name="sidebar")
.board-sidebar.sidebar(class="{{#if isOpen}}is-open{{/if}}")
a.sidebar-tongue.js-toggle-sidebar(
- class="{{#if isTongueHidden}}is-hidden{{/if}}")
+ class="{{#if isTongueHidden}}is-hidden{{/if}}")(title="{{showTongueTitle}}")
i.fa.fa-angle-left
.sidebar-shadow
.sidebar-content.sidebar-shortcuts
diff --git a/client/components/sidebar/sidebar.js b/client/components/sidebar/sidebar.js
index 9eab1656..6e9a1be9 100644
--- a/client/components/sidebar/sidebar.js
+++ b/client/components/sidebar/sidebar.js
@@ -89,6 +89,13 @@ BlazeComponent.extendComponent({
return TAPi18n.__(viewTitles[this.getView()]);
},
+ showTongueTitle() {
+ if (this.isOpen())
+ return `${TAPi18n.__('sidebar-close')}`;
+ else
+ return `${TAPi18n.__('sidebar-open')}`;
+ },
+
events() {
return [{
'click .js-hide-sidebar': this.hide,