liquid_feedback_frontend
diff env/ui/tabs.lua @ 57:4f39f0a0d5b5
Listing of updated drafts on start page; Code cleanup; Minor bugfix
MOTD, initiator invite, issues to vote and listing of updated drafts shown as tabs on start page;
Bugfix: Initiator icon only shown when initiatorship has been accepted
MOTD, initiator invite, issues to vote and listing of updated drafts shown as tabs on start page;
Bugfix: Initiator icon only shown when initiatorship has been accepted
author | bsw |
---|---|
date | Sat Apr 17 21:59:02 2010 +0200 (2010-04-17) |
parents | 00d1004545f1 |
children | d4b4adb9a4df |
line diff
1.1 --- a/env/ui/tabs.lua Fri Apr 16 14:51:30 2010 +0200 1.2 +++ b/env/ui/tabs.lua Sat Apr 17 21:59:02 2010 +0200 1.3 @@ -77,9 +77,9 @@ 1.4 attr = { 1.5 name = "tab_" .. tab.name, 1.6 class = ( 1.7 - tab.name == current_tab and "ui_tabs_accordeon_head selected" or 1.8 - not current_tab and i == 1 and "ui_tabs_accordeon_head selected" or 1.9 - "ui_tabs_accordeon_head" 1.10 + tab.name == current_tab and "ui_tabs_accordeon_head selected" .. (tab.class and (" " .. tab.class) or "") or 1.11 + not current_tab and i == 1 and "ui_tabs_accordeon_head selected" .. (tab.class and (" " .. tab.class) or "") or 1.12 + "ui_tabs_accordeon_head" .. (tab.class and (" " .. tab.class) or "") 1.13 ), 1.14 id = "tab" .. unique_string .. "_head_" .. tab.name, 1.15 onclick = onclick, 1.16 @@ -105,7 +105,7 @@ 1.17 local expanded = active or not request.get_json_request_slots() and config.user_tab_mode == "accordeon_all_expanded" and not current_tabs_string 1.18 ui.container{ 1.19 attr = { 1.20 - class = "ui_tabs_accordeon_content", 1.21 + class = "ui_tabs_accordeon_content" .. (tab.class and (" " .. tab.class) or ""), 1.22 style = not expanded and "display: none;" or nil, 1.23 id = "tab" .. unique_string .. "_content_" .. tab.name 1.24 }, 1.25 @@ -198,9 +198,9 @@ 1.26 ui.link{ 1.27 attr = { 1.28 class = ( 1.29 - tab.name == current_tab and "selected" or 1.30 - not current_tab and i == 1 and "selected" or 1.31 - "" 1.32 + tab.name == current_tab and "selected" .. (tab.class and (" " .. tab.class) or "") or 1.33 + not current_tab and i == 1 and "selected" .. (tab.class and (" " .. tab.class) or "") or 1.34 + "" .. (tab.class and (" " .. tab.class) or "") 1.35 ) 1.36 }, 1.37 module = request.get_module(),