[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/help2.js
help3xsl/default.css | 14 +++--- help3xsl/help2.js| 14 +++--- 2 files changed, 14 insertions(+), 14 deletions(-) New commits: commit 77d02e65e9acae649867fe67cdba46f30e58a7e0 Author: Adolfo Jayme Barrientos AuthorDate: Tue Dec 13 05:01:43 2022 -0600 Commit: Adolfo Jayme Barrientos CommitDate: Tue Dec 13 05:01:48 2022 -0600 tdf#152491 Update CSS coloring to match new icons https://wiki.documentfoundation.org/Design/Branding#LibreOffice_application_colors Change-Id: I914ddfd14f0ca351f4eed5eb14ed8ea6ed904422 diff --git a/help3xsl/default.css b/help3xsl/default.css index 3740504722..abf75f69c1 100644 --- a/help3xsl/default.css +++ b/help3xsl/default.css @@ -540,42 +540,42 @@ aside input[type=checkbox]:checked ~ .contents-treeview { display: block; font-size: 22px; font-weight: bold; -color: #0369a3; +color: #083fa6; } #CALC::before { content: "Calc"; display: block; font-size: 22px; font-weight: bold; -color: #43c330; +color: #007c3c; } #IMPRESS::before { content: "Impress"; display: block; font-size: 22px; font-weight: bold; -color: #a33e03; +color: #d0120d; } #DRAW::before { content: "Draw"; display: block; font-size: 22px; font-weight: bold; -color: #c99c00; +color: #cb6d30; } #BASE::before { content: "Base"; display: block; font-size: 22px; font-weight: bold; -color: #8e03a3; +color: #7324a9; } #MATH::before { content: "Math"; display: block; font-size: 22px; font-weight: bold; -color: darkslategray; +color: #c10018; } #CHART::before { content: "Chart"; @@ -596,7 +596,7 @@ aside input[type=checkbox]:checked ~ .contents-treeview { display: block; font-size: 22px; font-weight: bold; -color: gray; +color: darkslategray; } .pagination-container { text-align: center; diff --git a/help3xsl/help2.js b/help3xsl/help2.js index 5b9b2a970b..728453134b 100644 --- a/help3xsl/help2.js +++ b/help3xsl/help2.js @@ -70,15 +70,15 @@ function setSystemSpan(spanZ) { function moduleColor (module) { switch (module){ -case "WRITER" : {color="#0369A3"; break;} -case "CALC" : {color="#43C330"; break;} +case "WRITER" : {color="#083fa6"; break;} +case "CALC" : {color="#007c3c"; break;} case "CHART" : {color="darkcyan"; break;} -case "IMPRESS": {color="#A33E03"; break;} -case "DRAW" : {color="#C99C00"; break;} -case "BASE" : {color="#8E03A3"; break;} +case "IMPRESS": {color="#d0120d"; break;} +case "DRAW" : {color="#cb6d30"; break;} +case "BASE" : {color="#7324a9"; break;} case "BASIC" : {color="black"; break;} -case "MATH" : {color="darkslategray"; break;} -case "SHARED" : {color="gray"; break;} +case "MATH" : {color="#c10018"; break;} +case "SHARED" : {color="darkslategray"; break;} default : {color="#18A303"; break;} } document.getElementById("TopLeftHeader").style.background = color;
[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/help2.js Package_html_media.mk source/media
Package_html_media.mk |1 + help3xsl/default.css |6 +- help3xsl/help2.js |1 + source/media/navigation/libo-symbol-black.svg |1 + 4 files changed, 8 insertions(+), 1 deletion(-) New commits: commit eb1bf86ac137d050daaaed114a70c29002acc4fe Author: Ilmari Lauhakangas AuthorDate: Thu Jan 13 16:25:47 2022 +0200 Commit: Olivier Hallot CommitDate: Thu Jan 13 16:12:10 2022 +0100 tdf#123318 Add navigation menu entry LibreOffice for Shared Change-Id: Ibd46738e03721127e07ee1575e0a925fc36fbe9d Reviewed-on: https://gerrit.libreoffice.org/c/help/+/128382 Tested-by: Jenkins Reviewed-by: Olivier Hallot diff --git a/Package_html_media.mk b/Package_html_media.mk index 66cd339f1..784486c3f 100644 --- a/Package_html_media.mk +++ b/Package_html_media.mk @@ -378,6 +378,7 @@ $(eval $(call gb_Package_add_files_with_dir,helpcontent2_html_media,$(LIBO_SHARE navigation/libo-draw.svg \ navigation/libo-impress.svg \ navigation/libo-math.svg \ +navigation/libo-symbol-black.svg \ navigation/libo-symbol-white.svg \ navigation/libo-writer.svg \ screenshots/modules/scalc/ui/deletecells/DeleteCellsDialog.png \ diff --git a/help3xsl/default.css b/help3xsl/default.css index 66dd59271..ad65b34a5 100644 --- a/help3xsl/default.css +++ b/help3xsl/default.css @@ -630,6 +630,7 @@ li.disabled a { display: none; } +.libreoffice-icon, .calc-icon, .chart-icon, .writer-icon, @@ -643,6 +644,9 @@ li.disabled a { position: relative; margin-right: 5px; } +.libreoffice-icon { +background-image: url(media/navigation/libo-symbol-black.svg); +} .calc-icon { background-image: url(media/navigation/libo-calc.svg); } @@ -777,7 +781,7 @@ li.disabled a { flex-direction: column; overflow-y: auto; overflow-x: hidden; -max-width: 120px; +max-width: 160px; max-height: 480px; position: absolute; } diff --git a/help3xsl/help2.js b/help3xsl/help2.js index f40492afb..3a45f7f60 100644 --- a/help3xsl/help2.js +++ b/help3xsl/help2.js @@ -187,6 +187,7 @@ function setupModules(lang) { var modulesNav = document.getElementById('modules-nav'); if (!modulesNav.classList.contains('loaded')) { var html = +'LibreOffice' + 'Writer' + 'Calc' + 'Impress' + diff --git a/source/media/navigation/libo-symbol-black.svg b/source/media/navigation/libo-symbol-black.svg new file mode 100644 index 0..b4756d5fe --- /dev/null +++ b/source/media/navigation/libo-symbol-black.svg @@ -0,0 +1 @@ +http://www.w3.org/2000/svg;> \ No newline at end of file
[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/help2.js
help3xsl/default.css |2 -- help3xsl/help2.js| 27 +++ 2 files changed, 27 insertions(+), 2 deletions(-) New commits: commit 4d6b5e5f74c50cc440a46fada8fa89ad2f946749 Author: Olivier Hallot AuthorDate: Tue Apr 28 15:51:38 2020 -0300 Commit: Olivier Hallot CommitDate: Wed Apr 29 14:29:05 2020 +0200 Apply module brand color to Help page Change page header and headings to module colors Module colors from branding wiki page https://wiki.documentfoundation.org/Marketing/Branding#Colors Based on ideas of Beatriz Fonseca (@beatorizu) betri...@gmail.com Change-Id: Ia855872185a9c5ff6bcf3c351cc78e57e5a7901c Reviewed-on: https://gerrit.libreoffice.org/c/help/+/93100 Tested-by: Jenkins Reviewed-by: Olivier Hallot diff --git a/help3xsl/default.css b/help3xsl/default.css index f9a1edd4a..ceb591253 100644 --- a/help3xsl/default.css +++ b/help3xsl/default.css @@ -210,7 +210,6 @@ table, th, td { margin-top: 0px; } .tableheadcell { -background: #148603; color: white; vertical-align:top; } @@ -349,7 +348,6 @@ h6 { } header { color: #fff; -background-color: #18A303; height: 64px; padding: 8px 8px 8px 16px; } diff --git a/help3xsl/help2.js b/help3xsl/help2.js index 8c2b60d72..9eb35c003 100644 --- a/help3xsl/help2.js +++ b/help3xsl/help2.js @@ -66,6 +66,32 @@ function setSystemSpan(spanZ) { } } +// paint headers and headings with appl color + +function moduleColor (module) { +switch (module){ +case "WRITER" : {color="#0369A3"; break;} +case "CALC" : {color="#43C330"; break;} +case "CHART" : {color="darkcyan"; break;} +case "DRAW" : {color="#A33E03"; break;} +case "IMPRESS": {color="#C99C00"; break;} +case "BASE" : {color="#8E03A3"; break;} +case "BASIC" : {color="black"; break;} +case "MATH" : {color="darkslategray"; break;} +case "SHARED" : {color="gray"; break;} +default : {color="#18A303"; break;} +} +document.getElementById("TopLeftHeader").style.background = color; +document.getElementById("SearchFrame").style.background = color; +document.getElementById("DonationFrame").style.background = color; +var cols = document.getElementsByClassName('tableheadcell'); +for(i = 0; i < cols.length; i++) {cols[i].style.backgroundColor = color;}; +for (j of [1,2,3,4,5,6]) { +var hh = document.getElementsByTagName("H" + j); +for(i = 0; i < hh.length; i++) {hh[i].style.color = color;} +} +} + // Find spans that need the switch treatment and give it to them var spans = document.querySelectorAll("[class^=switch]"); var n = spans.length; @@ -205,6 +231,7 @@ if (document.body.getElementsByTagName('meta')) { var module = getParameterByName("DbPAR"); var helpID = getParameterByName("HID"); fixURL(module,system); +moduleColor(module); function debugInfo(dbg) { if (dbg == null) return; ___ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/help2.js help3xsl/help.js help3xsl/index2.html help3xsl/online_transform.xsl help3xsl/paginathing.js help3xsl/polyfills.js Package_html_st
Package_html_static.mk|1 help3xsl/default.css |3 - help3xsl/help.js |2 help3xsl/help2.js | 23 --- help3xsl/index2.html | 100 +- help3xsl/online_transform.xsl | 21 +++ help3xsl/paginathing.js | 25 help3xsl/polyfills.js | 122 ++ 8 files changed, 203 insertions(+), 94 deletions(-) New commits: commit ca2a6bf2c3c59d106f1c6ad432eab21f696c23fc Author: Ilmari Lauhakangas AuthorDate: Fri Mar 22 12:06:44 2019 +0200 Commit: Olivier Hallot CommitDate: Wed Mar 27 09:42:01 2019 +0100 tdf#124245 Polyfills and fixes for IE11 The polyfills can be removed after we drop IE11 support. Other IE11 fixes: Change from document.URL to window.location.pathname because otherwise we get local Windows paths with backward slashes. Use clear: left; for google-donation element so it doesn't float on top of other elements. Don't use defer to load fuzzysort.js and prism.js. Change-Id: I6c0143eab555c8b1fbdbde8e749a24baed2f69c8 Reviewed-on: https://gerrit.libreoffice.org/69549 Tested-by: Jenkins Reviewed-by: himajin10 Reviewed-by: Olivier Hallot diff --git a/Package_html_static.mk b/Package_html_static.mk index a53929878..d1e1b 100644 --- a/Package_html_static.mk +++ b/Package_html_static.mk @@ -23,6 +23,7 @@ $(eval $(call gb_Package_add_files,helpcontent2_html_static,$(LIBO_SHARE_HELP_FO help2.js \ normalize.css \ paginathing.js \ + polyfills.js \ prism.js \ prism.css \ )) diff --git a/help3xsl/default.css b/help3xsl/default.css index 391403e72..91b0a9adc 100644 --- a/help3xsl/default.css +++ b/help3xsl/default.css @@ -349,7 +349,7 @@ h6 { background-color: #18A303; z-index: 1000; } -header { +header { color: #fff; height: 64px; padding: 8px 8px 8px 16px; @@ -793,6 +793,7 @@ li.disabled a { top: 0px; background-color: #FCFCFC; box-shadow: none; +clear: left; } .donation { max-width: 400px; diff --git a/help3xsl/help.js b/help3xsl/help.js index e806eeed4..7789c17ae 100644 --- a/help3xsl/help.js +++ b/help3xsl/help.js @@ -8,7 +8,7 @@ */ // Pagination and fuzzy search -var url = document.URL; +var url = window.location.pathname; var moduleRegex = new RegExp('text\\/(\\w+)\\/'); var regexArray = moduleRegex.exec(url); var currentModule = null; diff --git a/help3xsl/help2.js b/help3xsl/help2.js index 0003b72d8..f62105dc6 100644 --- a/help3xsl/help2.js +++ b/help3xsl/help2.js @@ -82,13 +82,14 @@ for (z = 0; z < n; z++) { /* add = and = to the links in DisplayArea div */ /* skip for object files */ function fixURL(module, system) { -var itemlink = document.getElementById("DisplayArea").getElementsByTagName("a"); +if ((DisplayArea = document.getElementById("DisplayArea")) === null) return; +var itemlink = DisplayArea.getElementsByTagName("a"); var pSystem = (system === null) ? getSystem() : system; var pAppl = (module === null) ? "WRITER" : module; var n = itemlink.length; for (var i = 0; i < n; i++) { -if (itemlink[i].getAttribute("class") != "objectfiles"){ -setURLParam(itemlink[i], pSystem, pAppl); +if (itemlink[i].getAttribute("class") != "objectfiles") { +setURLParam(itemlink[i], pSystem, pAppl); } } } @@ -203,12 +204,16 @@ if (document.body.getElementsByTagName('meta')) { var module = getParameterByName("DbPAR"); var helpID = getParameterByName("HID"); fixURL(module,system); -var dbg = getParameterByName("Debug"); -if (dbg == null) { dbg=0; } -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; -document.getElementById("bm_HID").innerHTML ="HID is: "+helpID; + +function debugInfo(dbg) { +if (dbg == null) return; +document.getElementById("DEBUG").style.display = "block"; +document.getElementById("bm_module").innerHTML = "Module is: "+module; +document.getElementById("bm_system").innerHTML = "System is: "+system; +document.getElementById("bm_HID").innerHTML = "HID is: "+helpID; +} + +debugInfo(getParameterByName("Debug")); // Mobile devices need the modules and langs on page load if (Math.max(document.documentElement.clientWidth, window.innerWidth || 0) < 960) { diff --git a/help3xsl/index2.html b/help3xsl/index2.html index 0321b7a39..3f761885f 100644 --- a/help3xsl/index2.html +++ b/help3xsl/index2.html @@ -10,61 +10,65 @@ - + + -var url = window.location.href; -var n = url.indexOf('index.html?'); -if (n != -1) { -// the URL came from LibreOffice help (F1) -var
[Libreoffice-commits] help.git: help3xsl/default.css help3xsl/help2.js help3xsl/online_transform.xsl
help3xsl/default.css |6 +++ help3xsl/help2.js | 42 +- help3xsl/online_transform.xsl | 67 -- 3 files changed, 60 insertions(+), 55 deletions(-) New commits: commit 54e3236790baca8a55d0bea3b1dd3e8de5ec5dd5 Author: Ilmari Lauhakangas AuthorDate: Sun Mar 10 10:57:34 2019 +0200 Commit: Olivier Hallot CommitDate: Sun Mar 10 19:22:22 2019 +0100 Show module & lang navigation on mobile Module & languages menus were not shown on screen widths < 960. Changed module & languages menu background to span the whole width, when on mobile. An arrow function was used in help2.js, which means it was broken on IE. Moved all src .js files to head and used defer for all. Moved inline Piwik & system info JS into help2.js and added a test for onlineness targeting the first meta element in the body. Change-Id: Ic1a928b53ce9029f9f655117977cd511b7e3246d Reviewed-on: https://gerrit.libreoffice.org/69005 Tested-by: Jenkins Reviewed-by: Olivier Hallot diff --git a/help3xsl/default.css b/help3xsl/default.css index 75798d2db..5c68d4118 100644 --- a/help3xsl/default.css +++ b/help3xsl/default.css @@ -600,12 +600,16 @@ li.disabled a { } .modules { border-bottom: 2px solid #f3f3f3; +background-color: #26; } .modules label:after, .lang label:after { font-size: 30px; color: #fff; content:"⌄"; } +.lang { +background-color: #26; +} .lang label, .modules label { display: none; } @@ -796,6 +800,7 @@ li.disabled a { position: absolute; top: 0; left: 200px; +background-color: transparent; } .modules { width: 120px; @@ -803,6 +808,7 @@ li.disabled a { top: 0; left: 80px; border: none; +background-color: transparent; } #DisplayArea { box-shadow: 0 2px 8px 0 rgba(0,0,0,.05); diff --git a/help3xsl/help2.js b/help3xsl/help2.js index 505dcaf8e..5a48c394f 100644 --- a/help3xsl/help2.js +++ b/help3xsl/help2.js @@ -75,7 +75,7 @@ function fixURL(module, system) { for (var i = 0; i < n; i++) { if (itemlink[i].getAttribute("class") != "objectfiles"){ setURLParam(itemlink[i], pSystem, pAppl); -}; +} } } //Set the params inside URL @@ -159,11 +159,49 @@ function setupLanguages(target, page) { var langNav = document.getElementById('langs-nav'); if (!langNav.classList.contains('loaded')) { var html = ''; -languagesSet.forEach(lang => { +languagesSet.forEach(function(lang) { html += '' + ((lang in languageNames)? languageNames[lang]: lang) + ''; }); langNav.innerHTML = html; langNav.classList.add('loaded'); } } + +// Test, if we are online +if (document.body.getElementsByTagName('meta')[0].getAttribute('itemprop') === 'version') { +var _paq = _paq || []; +/* tracker methods like "setCustomDimension" should be called before "trackPageView" */ +_paq.push(['disableCookies']); +_paq.push(['trackPageView']); +_paq.push(['enableLinkTracking']); +(function() { +var u="//piwik.documentfoundation.org/"; +_paq.push(['setTrackerUrl', u+'piwik.php']); +_paq.push(['setSiteId', '68']); +var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0]; +g.type='text/javascript'; g.async=true; g.defer=true; g.src=u+'piwik.js'; s.parentNode.insertBefore(g,s); +})(); +var system = getParameterByName("System"); +} else { +var system = getSystem(); +} + +var module = getParameterByName("DbPAR"); +var helpID = getParameterByName("HID"); +fixURL(module,system); +var dbg = getParameterByName("Debug"); +if (dbg == null) { dbg=0; } +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; +document.getElementById("bm_HID").innerHTML ="HID is: "+helpID; + +// Mobile devices need the modules and langs on page load +if (Math.max(document.documentElement.clientWidth, window.innerWidth || 0) < 960) { +var e = new Event('change'); +var modules = document.getElementById('modules'); +var langs = document.getElementById('langs'); +modules.dispatchEvent(e); +langs.dispatchEvent(e); +} /* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */ diff --git a/help3xsl/online_transform.xsl b/help3xsl/online_transform.xsl index 02a669a56..33a9537d3 100644 --- a/help3xsl/online_transform.xsl +++ b/help3xsl/online_transform.xsl @@ -145,21 +145,24 @@ - - - - - - - - - - + + + + + + +