VIVO-532: modified display of language selectors
This commit is contained in:
parent
d9fc640da6
commit
27c62c26cc
5 changed files with 141 additions and 20 deletions
|
@ -247,6 +247,85 @@ ul.dropdown ul ul {
|
|||
ul.dropdown li:hover > ul {
|
||||
visibility: visible;
|
||||
}
|
||||
/* -------------------------------------------------> */
|
||||
/* DROP DOWN LANGUAGE MENU ------------------------> */
|
||||
/* -------------------------------------------------> */
|
||||
ul.language-dropdown {
|
||||
position: relative;
|
||||
}
|
||||
ul.language-dropdown li {
|
||||
float: left;
|
||||
zoom: 1;
|
||||
padding: 0 !important;
|
||||
}
|
||||
ul.language-dropdown li a {
|
||||
display: block;
|
||||
font-size: 1.4em;
|
||||
}
|
||||
ul.language-dropdown li#language-menu {
|
||||
background: url(../images/arrowDownOverAccount.gif) right 9px no-repeat;
|
||||
min-width:110px;
|
||||
position: relative;
|
||||
margin-right: -10px !important;
|
||||
}
|
||||
ul.language-dropdown li#language-menu a {
|
||||
margin-right: 28px;
|
||||
margin-left:10px;
|
||||
}
|
||||
ul.language-dropdown li#language-menu.hover,
|
||||
ul.language-dropdown li#language-menu:hover {
|
||||
color: #000 !important;
|
||||
position: relative;
|
||||
background: #fff url(../images/arrowDownAccount.gif) right 9px no-repeat;
|
||||
border-bottom: 1px solid #cdcfcf;
|
||||
}
|
||||
ul.language-dropdown li.hover a,
|
||||
ul.language-dropdown li:hover a {
|
||||
color: #000 !important;
|
||||
margin-left:10px;
|
||||
}
|
||||
/* LEVEL TWO */
|
||||
ul.language-dropdown ul.sub_menu {
|
||||
font-size: 1.4em;
|
||||
visibility: hidden;
|
||||
position: absolute;
|
||||
top: 100%;
|
||||
right: 0;
|
||||
z-index: 999;
|
||||
color: #000;
|
||||
width: 100%;
|
||||
}
|
||||
ul.language-dropdown ul.sub_menu li {
|
||||
float: none;
|
||||
clear: both;
|
||||
padding-left: 14px !important;
|
||||
width: 100%;
|
||||
border-right: none !important;
|
||||
border-bottom: 1px solid #cdcfcf;
|
||||
background: #fff url('../images/arrowMenuAccount.gif') no-repeat scroll 7px 8px ;
|
||||
}
|
||||
/* IE 6 & 7 Needs Inline Block */
|
||||
/* ADD IN IE6.css and IE7.css*/
|
||||
ul.language-dropdown ul.sub_menu li a {
|
||||
width: 90%;
|
||||
display: inline-block;
|
||||
color: #000 !important;
|
||||
background-color: #fff url('../images/arrowMenuAccount.gif') no-repeat scroll 7px 8px ;
|
||||
padding: 0;
|
||||
padding-left: 0;
|
||||
height: 24px;
|
||||
}
|
||||
ul.language-dropdown ul.sub_menu li.inactive {
|
||||
color: #aab0ae !important;
|
||||
font-size: 1em !important;
|
||||
width: 88px; */
|
||||
}
|
||||
ul.language-dropdown ul.sub_menu li a:hover,
|
||||
ul.language-dropdown ul.sub_menu li a.hover {
|
||||
color: #999 !important;
|
||||
opacity: 0.6;
|
||||
filter: alpha(opacity=60); /* For IE8 and earlier */
|
||||
}
|
||||
/* ------ MANAGE LABELS ------ */
|
||||
section#rdfsLabels {
|
||||
margin-left:20px;
|
||||
|
|
|
@ -238,7 +238,8 @@ verbose_turn_on = Turn on
|
|||
verbose_turn_off = Turn off
|
||||
resource_uri = Resource URI
|
||||
|
||||
individual_not_found = Individual Not Found
|
||||
individual_not_found = Individual not found:
|
||||
entity_to_query_for = This id is the id of the entity to query for. netid also works.
|
||||
|
||||
menu_ordering = Menu Ordering
|
||||
refresh_page_after_reordering = Refresh page after reordering menu items
|
||||
|
@ -335,11 +336,11 @@ we_have_an_error = There was an error in the system.
|
|||
error_was_reported = This error has been reported to the site administrator.
|
||||
error_message = Error message
|
||||
stack_trace = Stack trace
|
||||
trace_available = full trace available in the {0} log
|
||||
trace_available = full trace available in the vivo log
|
||||
caused_by = Caused by
|
||||
requested_url = Requested url
|
||||
error_occurred = An error occurred on the {0} site
|
||||
error_occurred_at = An error occurred on your {0} site at {1}.
|
||||
error_occurred = An error occurred on the VIVO site
|
||||
error_occurred_at = An error occurred on your VIVO site at {0}.
|
||||
|
||||
#
|
||||
# login templates ( /templates/freemarker/body/login )
|
||||
|
@ -425,7 +426,7 @@ undo_camelcasing = Uncamelcasing
|
|||
run_sdb_setup = Run SDB Setup
|
||||
|
||||
unrecognized_user = Unrecognized user
|
||||
no_individual_associated_with_id = For some reason, there is no individual in {0} that is associated with your Net ID. Perhaps you should contact your {0} administrator.
|
||||
no_individual_associated_with_id = For some reason, there is no individual in VIVO that is associated with your Net ID. Perhaps you should contact your VIVO administrator.
|
||||
|
||||
#
|
||||
# site admin templates ( /templates/freemarker/body/siteAdmin )
|
||||
|
@ -601,7 +602,7 @@ operation_successful = The operation was successful.
|
|||
operation_unsuccessful = The operation was unsuccessful. Full details can be found in the system log.
|
||||
relate_editors_profiles = Relate profile editors and profiles
|
||||
info_icon = info icon
|
||||
profile_editing_title = The editors you select on the left hand side will have the ability to edit the {0} profiles you select on the right hand side. You can select multiple editors and multiple profiles, but you must select a minimum of 1 each.
|
||||
profile_editing_title = The editors you select on the left hand side will have the ability to edit the VIVO profiles you select on the right hand side. You can select multiple editors and multiple profiles, but you must select a minimum of 1 each.
|
||||
select_editors = Select editors
|
||||
select_last_name = Select an existing last name
|
||||
processing_indicator = processing time indicator
|
||||
|
@ -877,4 +878,5 @@ view_labels_for = View Labels for
|
|||
|
||||
select_an_existing_document = Select an existing document
|
||||
|
||||
datetime_year_required = Date/time intervals must begin with a year. Enter either a Start Year, an End Year or both.
|
||||
datetime_year_required = Date/time intervals must begin with a year. Enter either a Start Year, an End Year or both.
|
||||
select_a_language = Select a language
|
29
webapp/web/js/languageMenuUtils.js
Normal file
29
webapp/web/js/languageMenuUtils.js
Normal file
|
@ -0,0 +1,29 @@
|
|||
/* $This file is distributed under the terms of the license in /doc/license.txt$ */
|
||||
|
||||
$(function() {
|
||||
|
||||
$.extend(this, i18nStringsLangMenu);
|
||||
var theText = this.selectLanguage;
|
||||
var imgHTML = "";
|
||||
$("ul.language-dropdown li#language-menu").hover(function(){
|
||||
$("a#lang-link").html(theText);
|
||||
$(this).addClass("hover");
|
||||
$('ul:first',this).css('visibility', 'visible');
|
||||
$("ul.language-dropdown ul.sub_menu li").css('width', ($("ul.language-dropdown").width() - 4) + 'px');
|
||||
|
||||
}, function(){
|
||||
$("a#lang-link").html(imgHTML);
|
||||
$(this).removeClass("hover");
|
||||
$('ul:first',this).css('visibility', 'hidden');
|
||||
});
|
||||
|
||||
$("ul.language-dropdown li ul li:has(ul)").find("a:first").append(" » ");
|
||||
|
||||
$("ul.language-dropdown ul.sub_menu li").each(function() {
|
||||
if ( $(this).attr("status") == "selected" ) {
|
||||
$("a#lang-link").html($(this).children("a").html());
|
||||
imgHTML = $(this).children("a").html();
|
||||
}
|
||||
});
|
||||
|
||||
});
|
|
@ -7,14 +7,16 @@
|
|||
-->
|
||||
|
||||
<#-- This is included by identity.ftl -->
|
||||
<#if selectLocale??>
|
||||
<#if selectLocale??>
|
||||
<li><ul class="language-dropdown"> <li id="language-menu"><a id="lang-link" href="#" title="user">${i18n().select_a_language}</a><ul class="sub_menu">
|
||||
<#list selectLocale.locales as locale>
|
||||
<li>
|
||||
<a href="${selectLocale.selectLocaleUrl}?selection=${locale.code}" title="${i18n().select_locale} -- ${locale.label}" <#if locale.selected>style="padding-bottom:1px;border-bottom: 1px solid #ccdfe6"</#if>>
|
||||
<img src="${locale.imageUrl}" height="15" style="vertical-align:middle" alt="${locale.label}"/>
|
||||
</a>
|
||||
</li>
|
||||
|
||||
<li <#if locale.selected>status="selected"</#if>>
|
||||
<a href="${selectLocale.selectLocaleUrl}?selection=${locale.code}" title="${i18n().select_locale} -- ${locale.label}"><img src="${locale.imageUrl}" title="${i18n().select_locale} -- ${locale.label}" height="15" style="vertical-align:middle" alt="${locale.label}"/></a>
|
||||
</li>
|
||||
</#list>
|
||||
</ul>
|
||||
</li></ul></li>
|
||||
</#if>
|
||||
|
||||
<#--
|
||||
|
@ -26,4 +28,11 @@
|
|||
* -- label (tooltip relative to the current Locale)
|
||||
* -- imageUrl
|
||||
* -- selected (boolean)
|
||||
-->
|
||||
-->
|
||||
<script type="text/javascript">
|
||||
var i18nStringsLangMenu = {
|
||||
selectLanguage: "${i18n().select_a_language}"
|
||||
};
|
||||
</script>
|
||||
|
||||
${scripts.add('<script type="text/javascript" src="${urls.base}/js/languageMenuUtils.js"></script>')}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue