# HG changeset patch
# User bsw
# Date 1328650248 -3600
# Node ID d13b27a37ad59253ea079a2798c833219378539b
# Parent 08a5e1226da25b947cce336c307af286c321e2a0
Optical enhancements, some repositioning of ui elements
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/_layout/default.html
--- a/app/main/_layout/default.html Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/_layout/default.html Tue Feb 07 22:30:48 2012 +0100
@@ -47,6 +47,9 @@
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/area/show.lua
--- a/app/main/area/show.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/area/show.lua Tue Feb 07 22:30:48 2012 +0100
@@ -14,17 +14,18 @@
slot.select("title", function()
+ ui.tag{ content = area.name }
+
if not config.single_unit_id then
+ slot.put(" · ")
ui.link{
content = area.unit.name,
module = "area",
view = "list",
params = { unit_id = area.unit_id }
}
- slot.put(" · ")
end
- ui.tag{ content = area.name }
end)
@@ -37,6 +38,17 @@
if app.session.member_id then
+ execute.view{
+ module = "membership",
+ view = "_show_box",
+ params = { area = area }
+ }
+
+ execute.view{
+ module = "delegation",
+ view = "_show_box",
+ params = { area_id = area.id }
+ }
slot.select("actions", function()
ui.link{
@@ -50,17 +62,6 @@
}
end)
- execute.view{
- module = "membership",
- view = "_show_box",
- params = { area = area }
- }
-
- execute.view{
- module = "delegation",
- view = "_show_box",
- params = { area_id = area.id }
- }
end
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/initiative/_current_draft.lua
--- a/app/main/initiative/_current_draft.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/initiative/_current_draft.lua Tue Feb 07 22:30:48 2012 +0100
@@ -13,4 +13,18 @@
params = { initiative_id = initiative.id }
}
end
+
+if initiator and initiator.accepted and not initiative.issue.half_frozen and not initiative.issue.closed and not initiative.revoked then
+ ui.link{
+ attr = { class = "action", style = "float: right;" },
+ content = function()
+ ui.image{ static = "icons/16/script_delete.png" }
+ slot.put(_"Revoke initiative")
+ end,
+ module = "initiative",
+ view = "revoke",
+ id = initiative.id
+ }
+end
+
execute.view{ module = "draft", view = "_show", params = { draft = initiative.current_draft } }
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/initiative/show_static.lua
--- a/app/main/initiative/show_static.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/initiative/show_static.lua Tue Feb 07 22:30:48 2012 +0100
@@ -4,6 +4,13 @@
initiative = Initiative:new_selector():add_where{ "id = ?", param.get_id()}:single_object_mode():exec()
end
+execute.view{
+ module = "issue",
+ view = "_show_head",
+ params = { issue = initiative.issue,
+ initiative = initiative }
+}
+
slot.select("actions", function()
ui.link{
content = function()
@@ -21,13 +28,6 @@
}
end)
-execute.view{
- module = "issue",
- view = "_show_head",
- params = { issue = initiative.issue,
- initiative = initiative }
-}
-
--slot.put_into("html_head", '')
if app.session.member_id then
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/initiative/show_support.lua
--- a/app/main/initiative/show_support.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/initiative/show_support.lua Tue Feb 07 22:30:48 2012 +0100
@@ -22,18 +22,6 @@
view = "_show_box",
params = { initiative = initiative }
}
- if initiator and initiator.accepted and not initiative.issue.half_frozen and not initiative.issue.closed and not initiative.revoked then
- ui.link{
- attr = { class = "action", style = "float: left;" },
- content = function()
- ui.image{ static = "icons/16/script_delete.png" }
- slot.put(_"Revoke initiative")
- end,
- module = "initiative",
- view = "revoke",
- id = initiative.id
- }
- end
end
}
end
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/issue/_show_box.lua
--- a/app/main/issue/_show_box.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/issue/_show_box.lua Tue Feb 07 22:30:48 2012 +0100
@@ -1,44 +0,0 @@
-local issue = param.get("issue", "table")
-
-slot.select("issue_info", function()
- ui.tag{
- tag = "div",
- content = function()
- ui.tag{
- tag = "label",
- attr = { class = "ui_field_label" },
- content = _"Policy",
- }
- ui.tag{
- content = function()
- ui.link{
- text = issue.policy.name,
- module = "policy",
- view = "show",
- id = issue.policy.id
- }
- end
- }
-
- end
- }
-
- ui.field.text{
- label = _"State",
- value = issue.state_name
- }
- local time_left = issue.state_time_left
- if time_left then
- ui.field.text{
- label = _"Time left",
- value = time_left
- }
- end
- local next_state_names = issue.next_states_names
- if next_state_names then
- ui.field.text{
- label = _"Next state",
- value = next_state_names
- }
- end
-end)
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/issue/_show_head.lua
--- a/app/main/issue/_show_head.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/issue/_show_head.lua Tue Feb 07 22:30:48 2012 +0100
@@ -16,36 +16,67 @@
end)
slot.select("title", function()
- if not config.single_unit_id then
- ui.link{
- content = issue.area.unit.name,
- module = "area",
- view = "list",
- params = { unit_id = issue.area.unit_id }
- }
+ ui.link{
+ content = _("Issue ##{id}", { id = issue.id }),
+ module = "issue",
+ view = "show",
+ id = issue.id
+ }
slot.put(" · ")
- end
ui.link{
content = issue.area.name,
module = "area",
view = "show",
id = issue.area.id
}
- slot.put(" · ")
- ui.link{
- content = _("Issue ##{id}", { id = issue.id }),
- module = "issue",
- view = "show",
- id = issue.id
- }
- slot.put(" · ")
- ui.tag{
- tag = "span",
- content = issue.state_name,
- }
+ if not config.single_unit_id then
+ slot.put(" · ")
+ ui.link{
+ content = issue.area.unit.name,
+ module = "area",
+ view = "list",
+ params = { unit_id = issue.area.unit_id }
+ }
+ end
end)
+slot.select("title2", function()
+ ui.tag{
+ tag = "div",
+ content = function()
+ ui.tag{
+ content = function()
+ ui.link{
+ text = issue.policy.name,
+ module = "policy",
+ view = "show",
+ id = issue.policy.id
+ }
+ end
+ }
+ slot.put(" · ")
+ ui.tag{ content = issue.state_name }
+
+ slot.put(" · ")
+ local time_left = issue.state_time_left
+ if time_left then
+ ui.tag{ content = _("#{time_left} left", { time_left = time_left }) }
+ end
+
+ slot.put(" · ")
+ local next_state_names = issue.next_states_names
+ if next_state_names then
+ ui.tag{ content = _("Next state: #{state}", { state = next_state_names }) }
+ end
+ end
+ }
+
+
+end)
+
+
+ --[[
slot.select("content_navigation", function()
if app.session.member_id then
@@ -117,7 +148,6 @@
end
end
- --[[
records = issues_selector:exec()
for i,cissue in ipairs(records) do
@@ -162,11 +192,11 @@
mk_link(-1, _("Previous initiative"), "resultset_previous.png", "initiative")
mk_link(1, _("Next initiative"), "resultset_next.png", "initiative")
end
- --]]
end
end
)
+ --]]
slot.select("actions", function()
@@ -221,11 +251,9 @@
end)
-execute.view{
- module = "issue",
- view = "_show_box",
- params = { issue = issue }
-}
+local issue = param.get("issue", "table")
+
+
-- ui.twitter("http://example.com/t" .. tostring(issue.id))
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/member/_profile.lua
--- a/app/main/member/_profile.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/member/_profile.lua Tue Feb 07 22:30:48 2012 +0100
@@ -36,12 +36,6 @@
end
}
- if member.admin then
- ui.field.boolean{ label = _"Admin?", name = "admin" }
- end
- if member.locked then
- ui.field.boolean{ label = _"Locked?", name = "locked" }
- end
if member.ident_number then
ui.field.text{ label = _"Ident number", name = "ident_number" }
end
@@ -111,6 +105,12 @@
}
end
+ if member.admin then
+ ui.field.boolean{ label = _"Admin?", name = "admin" }
+ end
+ if member.locked then
+ ui.field.boolean{ label = _"Locked?", name = "locked" }
+ end
ui.field.text{ label = _"Last activity (updated daily)", value = format.date(member.last_activity) or _"not yet" }
end
diff -r 08a5e1226da2 -r d13b27a37ad5 app/main/member/show.lua
--- a/app/main/member/show.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/app/main/member/show.lua Tue Feb 07 22:30:48 2012 +0100
@@ -74,7 +74,7 @@
ui.link{
content = function()
ui.image{ static = "icons/16/clock_edit.png" }
- slot.put(encode.html(_"Show name history"))
+ slot.put(encode.html(_"Show member history"))
end,
module = "member",
view = "history",
diff -r 08a5e1226da2 -r d13b27a37ad5 config/default.lua
--- a/config/default.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/config/default.lua Tue Feb 07 22:30:48 2012 +0100
@@ -52,7 +52,7 @@
config.feature_rss_enabled = false -- feature is broken
-config.feature_units_enabled = true
+config.single_unit_id = false
-- OpenID authentication is not fully implemented yet, DO NOT USE BEFORE THIS NOTICE HAS BEEN REMOVED!
config.auth_openid_enabled = false
diff -r 08a5e1226da2 -r d13b27a37ad5 config/development.lua
--- a/config/development.lua Tue Feb 07 20:03:31 2012 +0100
+++ b/config/development.lua Tue Feb 07 22:30:48 2012 +0100
@@ -31,7 +31,7 @@
config.motd_public = "==Public motd=="
-config.motd_intern = "==Internal motd=="
+--config.motd_intern = "==Internal motd=="
config.public_access = "anonymous"
diff -r 08a5e1226da2 -r d13b27a37ad5 static/style.css
--- a/static/style.css Tue Feb 07 20:03:31 2012 +0100
+++ b/static/style.css Tue Feb 07 22:30:48 2012 +0100
@@ -113,15 +113,26 @@
*/
.topbar {
- background-color: #444;
+ xbackground-color: #444;
color: #fff;
font-size: 75%;
line-height: 140%;
- margin-bottom: 1.8ex;
+ background: -webkit-gradient(
+ linear, left bottom, left top,
+ color-stop(0%,#4c4c4c),
+ color-stop(12%,#595959),
+ color-stop(25%,#666666),
+ color-stop(39%,#474747),
+ color-stop(50%,#2c2c2c),
+ color-stop(51%,#000000),
+ color-stop(60%,#111111),
+ color-stop(76%,#2b2b2b),
+ color-stop(91%,#1c1c1c),
+ color-stop(100%,#131313)
+ );
}
.topbar a {
- background-color: #444;
color: #fff;
}
@@ -192,9 +203,14 @@
*/
.title_bar {
- border-bottom: 1px solid #777;
- padding-top: 1ex;
- padding-bottom: 0.5ex;
+ padding-top: 2ex;
+ padding-bottom: 1ex;
+ xbackground-color: #def;
+ background: -webkit-gradient(linear, left top, left bottom,
+
+color-stop(0%,#abd3ee), color-stop(100%,#ffffff)
+
+ );
}
.title_bar_content {
@@ -222,22 +238,30 @@
.title {
color: #000;
- margin-bottom: 0.5ex;
+ margin-bottom: 1ex;
}
.slot_title {
}
.title div {
- font-weight: bold;
- font-size: 135%;
+ font-size: 125%;
line-height: 110%;
}
+.title div a {
+ xfont-weight: bold;
+}
+
.title a {
color: #000;
}
+.title2 div {
+ margin-bottom: 2ex;
+ xline-height: 130%;
+}
+
.member_image_avatar {
float: left;
margin-right: 0.5em;
@@ -258,6 +282,7 @@
padding: 1px 0.5em 1px 0.0em;
margin-right: 1em;
vertical-align: middle;
+ border-radius: 5px;
}
.content_navigation {
@@ -288,6 +313,10 @@
background-color: #d7d7d7;
}
+.title_bar .actions a:hover {
+ background-color: #fff;
+}
+
.actions img {
padding-left: 0.2em;
padding-right: 0.2em;
@@ -451,15 +480,19 @@
*/
.ui_tabs_links {
- margin-top: 4ex;
+ margin-top: 2ex;
+ margin-bottom: 2ex;
font-size: 75%;
}
.ui_tabs_links a {
padding: 1ex;
- line-height: 200%;
+ line-height: 300%;
background-color: #e7e7e7;
white-space: nowrap;
+ border-radius: 5px;
+ margin-right: 5px;
+ font-weight: bold;
}
.ui_tabs_links a:hover {
@@ -474,8 +507,8 @@
}
.ui_tabs_content {
- border: 1px solid #444;
- padding: 1ex 1ex 1ex 1ex;
+ xborder: 1px solid #444;
+ xpadding: 1ex 1ex 1ex 1ex;
}
.web10 .ui_tabs_accordeon_head {