diff options
author | Olivier Hallot <olivier.hallot@libreoffice.org> | 2017-09-02 11:48:43 -0300 |
---|---|---|
committer | Olivier Hallot <olivier.hallot@edx.srv.br> | 2017-09-02 16:58:52 +0200 |
commit | de0193157e3b09f5da4ac1a1f17625cc3bf62c14 (patch) | |
tree | 24c31fc28b06014ac4346e62fd9a72ca7be5575c /help3xsl/online_transform.xsl | |
parent | c23137d31109336ceed3d429aa60c360c62eba25 (diff) |
Add localization to helponline UI
* Add support for localization in helponline UI.
+ translate 4 words
+ prepare for focused google search
* Tweak the index search, open search index for all modules.
Change-Id: Id7ad4fd63fe1f9d1334fb65febdee6f60c24361a
Reviewed-on: https://gerrit.libreoffice.org/41839
Reviewed-by: Olivier Hallot <olivier.hallot@edx.srv.br>
Tested-by: Olivier Hallot <olivier.hallot@edx.srv.br>
Diffstat (limited to 'help3xsl/online_transform.xsl')
-rw-r--r-- | help3xsl/online_transform.xsl | 40 |
1 files changed, 25 insertions, 15 deletions
diff --git a/help3xsl/online_transform.xsl b/help3xsl/online_transform.xsl index 857109c39b..22ed9ff28f 100644 --- a/help3xsl/online_transform.xsl +++ b/help3xsl/online_transform.xsl @@ -21,7 +21,7 @@ <xsl:output indent="yes" method="html" doctype-system= "about:legacy-compat"/> - +<xsl:include href="localized.xsl"/> <!-- ############################ # Variables and Parameters # @@ -143,7 +143,7 @@ </a> <xsl:if test="$online"> <input id="langs" name="language-menu" type="checkbox"/> - <label for="langs" role="button">Language ▼</label> + <label for="langs"><xsl:call-template name="getLanguage"><xsl:with-param name="lang" select="$lang"/></xsl:call-template> ▼</label> <ul> <li><a href="{$productversion}/en-US{$htmlpage}">EN-US</a></li> <li><a href="{$productversion}/am{$htmlpage}">AM</a></li> @@ -227,13 +227,13 @@ <div class="accordion"> <div class="acc-panel"> <input id="accordion-1" name="accordion-menu" type="checkbox"/> - <label for="accordion-1">Contents</label> + <label for="accordion-1"><xsl:call-template name="getContents"><xsl:with-param name="lang" select="$lang"/></xsl:call-template></label> <div id="Contents" class="contents-treeview"></div> </div> <xsl:if test="$online"> <div class="acc-panel"> <input id="accordion-2" name="accordion-menu" type="checkbox"/> - <label for="accordion-2">Search</label> + <label for="accordion-2"><xsl:call-template name="getSearch"><xsl:with-param name="lang" select="$lang"/></xsl:call-template></label> <div id="content-2"> <script type="text/javascript"> <![CDATA[ @@ -254,21 +254,30 @@ </xsl:if> <div class="acc-panel"> <input id="accordion-3" name="accordion-menu" type="checkbox"/> - <label for="accordion-3">Index</label> + <label for="accordion-3"><xsl:call-template name="getIndex"><xsl:with-param name="lang" select="$lang"/></xsl:call-template></label> <div id="Index"> <div id="SearchBox"> <p>  🔎  <input id="search-bar" type="text"/></p> </div> <div id="Bookmarks"> - <ul id="bookmarkCALC" hidden="true"></ul> - <ul id="bookmarkCHART" hidden="true"></ul> - <ul id="bookmarkWRITER" hidden="true"></ul> - <ul id="bookmarkDRAW" hidden="true"></ul> - <ul id="bookmarkIMPRESS" hidden="true"></ul> - <ul id="bookmarkMATH" hidden="true"></ul> - <ul id="bookmarkBASE" hidden="true"></ul> + <p>CALC</p> + <ul id="bookmarkCALC"></ul> + <p>CHART</p> + <ul id="bookmarkCHART"></ul> + <p>WRITER</p> + <ul id="bookmarkWRITER"></ul> + <p>DRAW</p> + <ul id="bookmarkDRAW" ></ul> + <p>IMPRESS</p> + <ul id="bookmarkIMPRESS"></ul> + <p>MATH</p> + <ul id="bookmarkMATH"></ul> + <p>BASE</p> + <ul id="bookmarkBASE"></ul> + <p>BASIC</p> + <ul id="bookmarkBASIC"></ul> + <p>GLOBAL</p> <ul id="bookmarkSHARED"></ul> - <ul id="bookmarkBASIC" hidden="true"></ul> </div> </div> </div> @@ -292,14 +301,15 @@ <xsl:when test="$online"> <script type="text/javascript"> <![CDATA[ + var userLang = navigator.language || navigator.userLanguage; var module = getParameterByName("DbPAR"); setModule(module); var system = getParameterByName("System"); setSystem(system); fixURL(module,system); var dbg = getParameterByName("Debug"); - //if (dbg == null){dbg=1} - dbg=1 + if (dbg == null){dbg=1} + //dbg=1 document.getElementById("DEBUG").style.display = (dbg == 0) ? "none":"block"; document.getElementById("bm_module").innerHTML ="Module is: "+module; document.getElementById("bm_system").innerHTML ="System is: "+system; |