Bug 124245 - Offline-Help: Incompatible with IE11
Summary: Offline-Help: Incompatible with IE11
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Documentation (show other bugs)
Version:
(earliest affected)
6.2.1.2 release
Hardware: All All
: medium normal
Assignee: Buovjaga
URL:
Whiteboard: target:6.3.0
Keywords:
: 123546 (view as bug list)
Depends on:
Blocks:
 
Reported: 2019-03-21 18:01 UTC by himajin100000
Modified: 2019-04-18 10:20 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description himajin100000 2019-03-21 18:01:24 UTC
Description:
see steps to reproduce

1. 
First of all, help/help2.js installed in LibreOffice 6.2.1.2 release did not work with IE11
due to unsupported arrow function
https://gerrit.libreoffice.org/#/c/69005/

the part should be cherry-picked to 6.2 branch if it's not yet.

2. When I displayed the source in IE11, there was another error reported in the debugger.

help/index.html complained that there is no definition for getParameterByName as defined in help/help.html
https://opengrok.libreoffice.org/xref/help/help3xsl/help.html?r=5ccfc30b#16

I copied all the code to index.html, without understanding well.

3. I did several tries for the same steps to reproduce after each fix for the following problems. 

3-1.
IE11 complained that there is no startsWith.
https://opengrok.libreoffice.org/search?full=startsWith&project=help
https://stackoverflow.com/questions/36213455/add-startswith-in-ie-11/36213464

3-2.
IE11 does not support Element.matches
https://stackoverflow.com/questions/37304037/why-my-code-dont-working-in-ie11
https://opengrok.libreoffice.org/xref/help/help3xsl/help.js?r=a678c053#125
https://opengrok.libreoffice.org/xref/help/help3xsl/help.js?r=a678c053#129

3-3.
:scope in querySelectorAll is not supported
https://github.com/ademilter/bricklayer/issues/13#issuecomment-219662153

4. Even when I resolved all these above with tentative fix on my own machine, I tried the Step To Reproduce to see if it works,and it didn't.

because LibreOffice tried to search for the "en-US" help that I did not install.
C:\Program Files\LibreOffice\help\en-US\text\shared\guide\startcenter.html

the cause was that IE11 did not return correct value for has() method in Set Object
https://opengrok.libreoffice.org/xref/help/help3xsl/help2.js?r=3d0fcf7a#143
and the existingLang function returned en-US.

5. Still rendering/layout issue seems remaining, but I'm not an expert in that area. at least no complaints are given by the debugger now.


Steps to Reproduce:
1. Install LibreOffice 6.2.1.2( Other than en-US is preferable, I used ja)
2. Install Offline Help pack( Don't install the help pack for en-US)
3. Set your default web browser to IE11
4. Run LibreOffice
5. Press F1


Actual Results:
Help is not shown even after accepting scripts.

Expected Results:
Help is shown in UI locale Language


Reproducible: Always


User Profile Reset: No



Additional Info:
バージョン: 6.2.1.2 (x64)
Build ID: 7bcb35dc3024a62dea0caee87020152d1ee96e71
CPU threads: 4; OS:Windows 10.0; UI render: GL; VCL: win; 
ロケール: ja-JP (ja_JP); UIの言語: ja-JP
Calc: CL
Comment 1 himajin100000 2019-03-21 18:03:21 UTC
forgot to add the source code pointer for :scope
https://opengrok.libreoffice.org/xref/help/help3xsl/help.js?r=a678c053#132
Comment 2 Buovjaga 2019-03-21 19:37:28 UTC
Thanks a lot for testing and the research. I will look into these tomorrow. Going to use a bunch of polyfills for most of them.

Regarding the CSS layout, IE11 will see the mobile layout. I don't think it makes sense to invest in replicating the CSS grid setup with IE (even though it is possible with https://github.com/postcss/autoprefixer ). I think starting from next year we should think of dropping support for IE11. Maybe not for the crucial JavaScript bits that do the redirection, but mostly anyway.
Comment 3 Buovjaga 2019-03-22 10:13:37 UTC
A more fundamental problem is that IE11 users have to enable this setting to even use local JS: https://stackoverflow.com/a/40675005/3057764
Something we cannot do anything about.
Comment 4 Commit Notification 2019-03-27 08:43:24 UTC
Ilmari Lauhakangas committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/help/+/ca2a6bf2c3c59d106f1c6ad432eab21f696c23fc%5E%21

tdf#124245 Polyfills and fixes for IE11
Comment 5 himajin100000 2019-03-28 18:31:20 UTC
TODO:
search for how to resolve merge conflict when I click "cherry-pick" to branch libreoffice-6-2
Comment 6 Buovjaga 2019-03-28 18:39:51 UTC
(In reply to himajin100000 from comment #5)
> TODO:
> search for how to resolve merge conflict when I click "cherry-pick" to
> branch libreoffice-6-2

Olivier had to do some special work to get the previous changes into 6.2: https://gerrit.libreoffice.org/#/c/69511/
Comment 7 Buovjaga 2019-04-18 10:20:09 UTC
*** Bug 123546 has been marked as a duplicate of this bug. ***