summaryrefslogtreecommitdiff
path: root/help3xsl/help2.js
AgeCommit message (Collapse)Author
2023-10-25Improve accessibility of dropdown menusIlmari Lauhakangas
Now the opened menus can be closed with Esc key, so we conform to the dismissible success criterion in WCAG 2.1: https://www.w3.org/WAI/WCAG21/Understanding/content-on-hover-or-focus.html To simplify things, now the navigation lists are populated upon page load in all cases. Change-Id: I0a7daaea122d3e03de36c322ccb012c546b271e0 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/158429 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2023-09-26tdf#157360 Local help should not phone homeOlivier Hallot
+ Remove call to matomo TDF server instance when help is local + Keep when Help is online. + refactor javascript Change-Id: I285b426531c91ff558c01798f803bf3f89720b1f Reviewed-on: https://gerrit.libreoffice.org/c/help/+/157255 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2023-07-31More fix in product nameOlivier Hallot
Change-Id: I1de6ee379dc116b40794c81e8d6e505d51e7e5f8 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/155047 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2023-07-31Fix mistake in product nameOlivier Hallot
Change-Id: I33022758a73117e6b12ad882963f008005ce334a Reviewed-on: https://gerrit.libreoffice.org/c/help/+/155045 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2023-07-31tdf#144859 - fix switch javascript logic.Olivier Hallot
Change-Id: I7add8db42f1944052ea5907e24b889cb9e504d3f Reviewed-on: https://gerrit.libreoffice.org/c/help/+/155097 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2022-12-13tdf#152491 Update CSS coloring to match new iconsAdolfo Jayme Barrientos
https://wiki.documentfoundation.org/Design/Branding#LibreOffice_application_colors Change-Id: I914ddfd14f0ca351f4eed5eb14ed8ea6ed904422
2022-02-18tdf#123318 Use SHARED as the default module instead of WRITERIlmari Lauhakangas
Change-Id: I78c3f71a862ad0896cc13b105cac46dca99b4195 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/130079 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2022-01-25tdf#123318 tdf#129697 Don't hardcode product name in CSS and JSIlmari Lauhakangas
Change-Id: I0ef315146fed188eb1cf33c416ff5f3e9899bbae Reviewed-on: https://gerrit.libreoffice.org/c/help/+/128524 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2022-01-13tdf#123318 Add navigation menu entry LibreOffice for SharedIlmari Lauhakangas
Change-Id: Ibd46738e03721127e07ee1575e0a925fc36fbe9d Reviewed-on: https://gerrit.libreoffice.org/c/help/+/128382 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2020-06-17Add better 404 errorOlivier Hallot
Missing help pages or links with bad HID were redirected to module entry page, masking the real issue in Help. This patch activated the 404 page and add HID information for debug and fix. Change-Id: I0d55f1c36d9a6c3fab0096d5e3cd171087729691 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/96401 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2020-06-11Fix applicaiton color and h1 underline CSSOlivier Hallot
Change-Id: Ia8a18f4a8e1bd12c40a092528e68ec2f12846ac1 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/96162 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2020-05-16Refactor database help pageOlivier Hallot
Open a new module sdatabase and add one entry file. Later, and very slowly, move database help pages from shared/explorer/database/* to sdatabase/* Note: Each move will trigger translation so better move only a few files per translation cycle, not to overload translators. Translation memory should easy the traslation job. Change-Id: I8e2be9c9355b966775fb5dacc5d63b852be7187a Reviewed-on: https://gerrit.libreoffice.org/c/help/+/94362 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2020-04-29Apply module brand color to Help pageOlivier Hallot
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) betrizaf@gmail.com Change-Id: Ia855872185a9c5ff6bcf3c351cc78e57e5a7901c Reviewed-on: https://gerrit.libreoffice.org/c/help/+/93100 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2020-02-10Don't hardcode version in links in online helpMike Kaganski
... so that when current page URL is like https://help.libreoffice.org/latest/en-US/text/shared/05/new_help.html links from it will lead to other pages under 'latest', not to https://help.libreoffice.org/6.3/... The problem reason was that in online help, HTML referred to resources with relative URLs starting with version number, like 'href="6.3/media/navigation/favicon.ico"'. The links didn't include the version level in local help: 'href="media/navigation/favicon.ico"'. This was naturally accompanied by <base href="../../../../../"> (online) and '<base href="../../../../">' (local), coming from "tokenize" in help3xsl/online_transform.xsl. This unifies online help behaviour with that of local help. Change-Id: I486cbfbd680d52d00ef99ade9af5ecac2967c115 Reviewed-on: https://gerrit.libreoffice.org/c/help/+/87768 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2019-11-08Fix switch selection when embedded in other pagesOlivier Hallot
Emebed exerpts with switch tags were unable to perform the correct switch because of the use of the same id= in several places in the page. The new logic fixes that. Change-Id: I1e1084170e023c89f3c695c3d1c5a6c7deee7374 Reviewed-on: https://gerrit.libreoffice.org/82277 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2019-05-18Improve accessibility for modules and lang menusIlmari Lauhakangas
Ever since the contents of the modules and lang menus started being populated upon click, the flow for screenreader users has been potentially confusing. This patch introduces a11y-toggle into the mix: https://github.com/edenspiekermann/a11y-toggle Checkboxes were changed into buttons. This hopefully makes it clear we want the user to click them. The contents tree still uses the checkbox hack, because its items are populated upon page load. Change-Id: I3482bea0c8669f96794498fc37d9d18fe3f829d5 Reviewed-on: https://gerrit.libreoffice.org/72467 Tested-by: Jenkins Tested-by: Olivier Hallot <olivier.hallot@libreoffice.org> Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2019-03-27tdf#124245 Polyfills and fixes for IE11Ilmari Lauhakangas
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: himajin100000 <himajin100000@gmail.com> Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2019-03-13New approach to switch casesIlmari Lauhakangas
My previous JS patch broke the sys and appl switch behaviour. This patch removes the inline function calls from online_transform.xsl. Instead, help2.js now finds the relevant spans and calls the functions for them. Change-Id: I45d5b75bdb70a7c18eaa0b215beb57e3e1b6719a Reviewed-on: https://gerrit.libreoffice.org/69137 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2019-03-10Show module & lang navigation on mobileIlmari Lauhakangas
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 <olivier.hallot@libreoffice.org>
2018-08-16Generate the modules dropdown content on demand too.Jan Holesovsky
Change-Id: Ibcbd8faac4f31d41398d8ae98314d83690136ab6 Reviewed-on: https://gerrit.libreoffice.org/59152 Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk> Tested-by: Miklos Vajna <vmiklos@collabora.co.uk> Reviewed-on: https://gerrit.libreoffice.org/59153 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2018-08-16Translate the language names in JS.Jan Holesovsky
Change-Id: I7185a7d0981abbacef4a152ee6ac5352ebe970cd Reviewed-on: https://gerrit.libreoffice.org/59150 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2018-08-16Don't embed links to all the languages into every page.Jan Holesovsky
Change-Id: I31f140919a18db55ef5afab9f229afa7eed3e36c Reviewed-on: https://gerrit.libreoffice.org/59149 Tested-by: Jenkins Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>
2018-08-16Limit the online help only to the built languages.Jan Holesovsky
Change-Id: Ib81dbd9a4047d9bb63761a43ef0b183a450b03f1 Reviewed-on: https://gerrit.libreoffice.org/59047 Tested-by: Jenkins Reviewed-by: Jan Holesovsky <kendy@collabora.com>
2018-04-17Fix index in sidebarOlivier Hallot
The last commit of online_transform.xsl instrpduced a bug in index search on the left. This one fixes it. Change-Id: I8055389a324d1fc5fde90ac2b76ff6f0a4a42493 Reviewed-on: https://gerrit.libreoffice.org/53011 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Olivier Hallot <olivier.hallot@libreoffice.org>