source: trunk/plugins/language_switch/flags.tpl @ 20943

Last change on this file since 20943 was 20943, checked in by flop25, 7 years ago

bug:2837
render the same display in rtl and ltr

  • Property svn:eol-style set to LF
  • Property svn:keywords set to Author Date Id Revision
File size: 1.9 KB
Line 
1<li id="languageSwitch">{strip}<a id="languageSwitchLink" title="{'Language'|@translate}" class="pwg-state-default pwg-button" rel="nofollow">
2  <span class="pwg-icon flags langflag-{$lang_switch.Active.code}" >&nbsp;</span><span class="pwg-button-text">{'Language'|@translate}</span>
3</a>
4<div id="languageSwitchBox" class="switchBox">
5  <div class="switchBoxTitle">{'Language'|@translate}</div>
6  {foreach from=$lang_switch.flags item=flag name=f}
7  <a rel="nofollow" href="{$flag.url}">
8    {if $lang_info.direction=="ltr"}<span class="pwg-icon flags langflag-{$flag.code}">{$flag.alt}</span>{$flag.title}{else}{$flag.title}<span class="pwg-icon flags langflag-{$flag.code}">{$flag.alt}</span>{/if}
9  </a>
10  {if ($smarty.foreach.f.index+1)%3 == 0}<br>{/if}
11  {/foreach}
12</div>
13{/strip}</li>
14
15{footer_script require='jquery'}{literal}
16jQuery("#languageSwitchLink").click(function() {
17        var elt = jQuery("#languageSwitchBox");
18        elt.css("left", Math.min(jQuery(this).offset().left, jQuery(window).width() - elt.outerWidth(true) - 5))
19                .css("top", jQuery(this).offset().top + jQuery(this).outerHeight(true))
20                .toggle();
21});
22jQuery("#languageSwitchBox").on("mouseleave", function() {
23        jQuery(this).hide();
24});
25{/literal}{/footer_script}
26
27{* <!-- switchBox structure for theme which don't include default style --> *}
28{if $themeconf.parent != 'default' or (isset($themeconf.load_parent_local_head) and $themeconf.load_parent_local_head == false) }
29{combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"default.css"}
30{/if}
31
32{* <!-- stylish for non core themes (should be removed when all themes are updated) --> *}
33{if $themeconf.name != 'clear' and $themeconf.name != 'dark' and $themeconf.name != 'elegant' and $themeconf.name != 'Sylvia'}
34{combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"style.css"}
35{/if}
36
37{* <!-- common style specific for LanguageSwitch --> *}
38{combine_css path=$LANGUAGE_SWITCH_PATH|@cat:"language_switch.css"}
Note: See TracBrowser for help on using the repository browser.