liquid_feedback_frontend
annotate env/ui/sidebar.lua @ 1091:20680a81c3e1
Fixed view for creating new initiatives in polling mode
| author | bsw | 
|---|---|
| date | Fri Oct 17 11:30:09 2014 +0200 (2014-10-17) | 
| parents | 701a5cf6b067 | 
| children | 
| rev | line source | 
|---|---|
| bsw@1045 | 1 function ui.sidebar ( arg1, arg2 ) | 
| bsw@1045 | 2 | 
| bsw@1045 | 3 local class = "sidebarSection" | 
| bsw@1045 | 4 local content | 
| bsw@1045 | 5 | 
| bsw@1045 | 6 if arg2 then | 
| bsw@1045 | 7 class = class .. " " .. arg1 | 
| bsw@1045 | 8 content = arg2 | 
| bsw@1045 | 9 else | 
| bsw@1045 | 10 content = arg1 | 
| bsw@1045 | 11 end | 
| bsw@1045 | 12 | 
| bsw@1045 | 13 slot.select ( "sidebar", function () | 
| bsw@1045 | 14 ui.container { attr = { class = class }, content = content } | 
| bsw@1045 | 15 end ) | 
| bsw@1045 | 16 | 
| bsw@1045 | 17 end |