-<div class='item_detail_extras_tabs' style='width:98%; padding:5px;'>
-
-[%
+<a name='addedcontent'></a> <!-- for page focus -->
+<div class='item_detail_extras_tabs'>
+[%-
ac_types = {
reviews => l('Reviews'),
anotes => l('Author Notes'),
toc => l('Table of Contents'),
excerpt => l('Excerpt'),
- summary => l('Summary')
+ summary => l('Smmary')
};
selected_type = CGI.param('ac');
# content, do not render the link if it's known to not have content. If
# the content status is unknown, render the link, but hide the link via CSS
# if dojo is enabled. If dojo is not enabled, render and display the link.
-%]
+-%]
- <div id='ac_tab_wrapper'>
- [%
+ [%-
all_hidden = 1;
FOR type IN ac_types.keys;
- tab_class = 'ac_tab';
- SET tab_class = tab_class _ ' ac_tab_selected' IF type == selected_type;
+ tab_class = '';
+ SET tab_class = 'ac_tab_selected' IF type == selected_type;
IF ctx.added_content.$type.status != '2'; # no content
all_hidden = 0;
IF ctx.added_content.$type.status == '3' AND want_dojo; # status unknown
tab_class = tab_class _ ' hidden';
END %]
- <div class="[% tab_class %]" id="ac:[% type %]">
- <a href="[% mkurl('', {ac => type}) _ '#addedcontent' %]">[% ac_types.$type %]</a>
- </div>
+ <a class="[% tab_class %]" id="ac:[% type %]" href="[% mkurl('', {ac => type}) _ '#addedcontent' %]">[% ac_types.$type %]</a>
[% END;
END;
%]
- </div>
+ <div class="clear"> </div>
+</div>
- <div class='clear'></div>
+<div style='width:98%; padding:5px;'>
<div id='ac_content'>
[%
IF selected_type;
content = ctx.added_content.$selected_type.content;
- '<hr/>';
IF content;
content;
ELSE;
background:#e3e3e3;\r
}\r
\r
-.item_detail_extras_tabs a,\r
-.item_detail_extras_tabs div.selected {\r
+.item_detail_extras_tabs a {\r
display:block;\r
float:left;\r
padding:14px 35px;\r
margin-right:10px;\r
}\r
\r
-.item_detail_extras_tabs a.selected,\r
-.item_detail_extras_tabs div.selected {\r
+.item_detail_extras_tabs a.ac_tab_selected,\r
+.item_detail_extras_tabs div.ac_tab_selected {\r
background:white;\r
color:#424242;\r
}\r