From 68b34874b02c912e31eb6163c2fa0baec712b9c3 Mon Sep 17 00:00:00 2001 From: Owen Leonard Date: Tue, 30 Jun 2009 14:56:28 -0500 Subject: [PATCH] Changes to lists to improve behavior for users with no javascript This patch moves the creation of some js-based function links to the script so that non-functioning links will not display when javascript is turned off. Other links which require TMPL processing are hidden with CSS and shown with JS. Signed-off-by: Galen Charlton --- koha-tmpl/opac-tmpl/prog/en/css/opac.css | 6 ++- .../prog/en/modules/opac-shelves.tmpl | 46 ++++++++++--------- 2 files changed, 30 insertions(+), 22 deletions(-) diff --git a/koha-tmpl/opac-tmpl/prog/en/css/opac.css b/koha-tmpl/opac-tmpl/prog/en/css/opac.css index 90b28940ea..a87dc1fe89 100644 --- a/koha-tmpl/opac-tmpl/prog/en/css/opac.css +++ b/koha-tmpl/opac-tmpl/prog/en/css/opac.css @@ -463,13 +463,16 @@ a .term { #toolbar a.send { background-image: url(../../images/send.gif); } - +.sendlist { + display : none; +} a.send { background-image: url(../../images/send.gif); background-position : 0px center; background-repeat : no-repeat; text-decoration : none; padding-left : 21px; + padding-right : 5px; } a.hold, #placehold input.submit { @@ -1747,6 +1750,7 @@ input.newshelf,a.newshelf { border : 0; color : #006699; cursor : pointer; + font-size : 100%; margin:0pt 0.5em; padding-left : 15px; text-decoration : none; diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tmpl b/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tmpl index fed1c914df..84cff33d37 100644 --- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tmpl +++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-shelves.tmpl @@ -72,8 +72,14 @@ function tagAdded() { } $(function() { - $("span.clearall").html("Clear All"); - $("span.checkall").html("Select All"); + $("span.clearall").html("Clear All<\/a>"); + $("span.checkall").html("Select All<\/a>"); + $(".sendlist").show(); + $("#placehold").html("Place Hold<\/a>"); + $("a.hold").click(function(){ + holdSelections(); + return false; + }); $("#listcontents").tablesorter({ widgets : ['zebra'], @@ -105,14 +111,12 @@ $(function() { $(".checkboxed").unCheckCheckboxes(); return false; }); -}); - -$(document).ready(function(){ - - $(".hold").html("Place Hold"); - - $("#tagsel_tag").text("Tag"); + $("#addtags").click(function(){ + tagSelected(); + return false; + }); + $("#addtags").html("Tag<\/a>"); $("#tagsel_button").click(function(){ tagAdded(); return false; @@ -179,7 +183,7 @@ $(document).ready(function(){ | - + ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100'); return false; ">Send List &op=modif">Edit List
@@ -189,12 +193,11 @@ $(document).ready(function(){ "/>
- ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100')">Send List - + - - + + + -
','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100')">Send List | Log in to place holds or add tags
+
','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100'); return false; ">Send List | Log in to place holds or add tags
@@ -350,7 +354,7 @@ $(document).ready(function(){ - &sortfield="> + &sortfield="> item(s) @@ -359,8 +363,9 @@ $(document).ready(function(){ Open + ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100'); return false; ">Send List - + " /> @@ -378,7 +383,6 @@ $(document).ready(function(){
  - ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100')">Send List @@ -418,7 +422,7 @@ $(document).ready(function(){ - &sortfield="> + &sortfield="> item(s) @@ -427,8 +431,9 @@ $(document).ready(function(){ Open + ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100'); return false; ">Send List -
+ " /> @@ -444,7 +449,6 @@ $(document).ready(function(){
  - ','win_form','dependant=yes,scrollbars=no,resizable=no,height=300,width=450,top=50,left=100')">Send List -- 2.39.5