From: gfawcett Date: Sat, 14 Feb 2009 22:24:17 +0000 (+0000) Subject: mostly navigation and appearance changes. X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=563ae57a211ad1a39ce8129036b0bdb33a97569e;p=Syrup.git mostly navigation and appearance changes. - no longer showing an expanded tree of all course items; it's overwhelming in full sites. Only show first level elements; - cleaned up the in-course breadcrumbs a bit; - fixed page width to a 960px layout; - put course-name and department information in a coloured band to separate from the course content. - etc. git-svn-id: svn://svn.open-ils.org/ILS-Contrib/servres/trunk@122 6d9bc8c9-1ec2-4278-b937-99fde70a366f --- diff --git a/conifer/static/main.css b/conifer/static/main.css index c2430fb..b2eaaf1 100644 --- a/conifer/static/main.css +++ b/conifer/static/main.css @@ -4,11 +4,20 @@ pre, code { font-family: monospace; } body, html { margin: 0; padding: 0; } + body { + background-color: #005; + font-size: normal; +} + +div#outer { background-color: white; - font-size: normal; + width: 960; margin-bottom: 50; + margin-left: auto; margin-right: auto; +} +#mainpanel { background-color: white; padding: 0 12 24 12; +min-height: 300; } -#mainpanel { background-color: white; padding: 0 12 24 12; } /* General headers and footers */ @@ -33,10 +42,11 @@ body { #header a:hover { background-color: #fb7; color: black; text-decoration: none; } #footer { - margin-top: 12; + margin: 12; padding-bottom: 12; background-color: #ddf; color: black; + border-bottom: white 10px solid; } h1 { font-size: 150%; } @@ -88,14 +98,14 @@ a:hover { text-decoration: underline; } /* item trees (tree of headings and items in a course */ .itemtree { - margin-left: 30; +padding-left: 25; list-style-type: none; list-style-position: inside; } .itemtree .itemtree { margin-left: 0;} -.itemtree li { width: 400; } +/* .itemtree li { width: 400; } */ .itemtree .metalink { padding-left: 8; color: gray; } .itemtree .metalink a { @@ -103,27 +113,29 @@ a:hover { text-decoration: underline; } } .itemtree .editlinks { padding-left: 12; color: gray; - position: absolute; left: 0; font-size: small; } .itemtree .editlinks a { color: navy; } .itemadd { - margin-left: 30; /* should match .itemtree{margin-left} */ - margin-top: 30; + margin-top: 30; font-size: smaller; + padding: 10; background-color: #eef; } +.itemadd a { color: navy; } + /* specialized display of items in tree, by type */ .itemtree li.item_HEADING { + list-style-image: url(tango/folder.png); margin-top: 4; } .itemtree li.item_HEADING > a { - font-weight: bold; color: navy; + color: navy; } .itemtree li.item_ELEC { - list-style-image: url(tango/view_detailed.png); + list-style-image: url(tango/document.png); margin-top: 4; } @@ -168,3 +180,12 @@ p.todo, div.todo { background-color: #fdd; padding: 6; margin: 12; border-left: .newsitem { max-width: 600; } + +.menublockopener { color: gray !important; font-weight: normal !important; } +.menublock { background-color: #f0f0e0; font-size: 95%; padding: 1 4; } + +#coursebanner { background-color: #f2e4cc; margin: -12 -12 0 -12; padding: 8; } + +#coursebanner h1 { padding: 0; font-size: 110%; } + +.breadcrumbs { margin: 8 8 8 0; } diff --git a/conifer/static/menublocks.js b/conifer/static/menublocks.js new file mode 100644 index 0000000..192b524 --- /dev/null +++ b/conifer/static/menublocks.js @@ -0,0 +1,20 @@ +function init_blocks() { + $('span.menublock').each(make_opener); +} + +var blocknum = 0; +function make_opener() { + var menublock = $(this); + var blockid = 'menublock' + (blocknum++); + menublock.attr('id', blockid); + var opener = '»'; + menublock.before(opener); + menublock.hide(); +} + +function openblock(bid) { + $('span.menublock').hide(); + $('#' + bid).fadeIn('fast'); +} + +$(init_blocks); \ No newline at end of file diff --git a/conifer/static/tango/big/folder.png b/conifer/static/tango/big/folder.png new file mode 100644 index 0000000..0171b09 Binary files /dev/null and b/conifer/static/tango/big/folder.png differ diff --git a/conifer/static/tango/document.png b/conifer/static/tango/document.png new file mode 100644 index 0000000..d18082e Binary files /dev/null and b/conifer/static/tango/document.png differ diff --git a/conifer/static/tango/folder.png b/conifer/static/tango/folder.png new file mode 100644 index 0000000..901edc9 Binary files /dev/null and b/conifer/static/tango/folder.png differ diff --git a/conifer/syrup/views.py b/conifer/syrup/views.py index bb6f581..338e2d3 100644 --- a/conifer/syrup/views.py +++ b/conifer/syrup/views.py @@ -240,7 +240,7 @@ def item_add(request, course_id, item_id): last_modified=datetime.now(), url = url) item.save() - return HttpResponseRedirect(item_url(item) + 'meta/') + return HttpResponseRedirect(item_url(item, 'meta/')) elif item_type == 'ELEC': title = request.POST.get('title', '').strip() upload = request.FILES.get('file') @@ -257,7 +257,7 @@ def item_add(request, course_id, item_id): item.fileobj.save(upload.name, upload) item.save() - return HttpResponseRedirect(item_url(item) + 'meta/') + return HttpResponseRedirect(item_url(item, 'meta/')) else: raise NotImplementedError diff --git a/conifer/templates/components/item.xhtml b/conifer/templates/components/item.xhtml index d1355fc..5db74be 100644 --- a/conifer/templates/components/item.xhtml +++ b/conifer/templates/components/item.xhtml @@ -7,32 +7,31 @@
- Top » +
- + diff --git a/conifer/templates/course_detail.xhtml b/conifer/templates/course_detail.xhtml index 4d961e3..368838d 100644 --- a/conifer/templates/course_detail.xhtml +++ b/conifer/templates/course_detail.xhtml @@ -10,10 +10,13 @@ is_editor = course.can_edit(request.user) ${title} +