-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Different warning when Weebassembly is not enable #660
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Your commits are not signed/verified. Please sign your commits.
function showWebAssemblyCompatibilityWarning() { | ||
|
||
var imgpath = OC.filePath('passwords', 'img', 'warning.png'); | ||
container = document.getElementById('main'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be either var container
or the previous line should have a comma. I don't think you need imgpath at all.
container = document.getElementById('main'); | ||
container.innerHTML = | ||
'<div class="passwords-browser-compatibility passwords-jit-compatibility">' + | ||
'<div class="message"><img class="warning-icon" src="' + imgpath +'"/>'+OC.L10N.translate('passwords', 'To view this website properly, please enable Javascript JIT.') + |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a broken image here. But i also don't think we need a warning icon for this.
'<div class="message"><img class="warning-icon" src="' + imgpath +'"/>'+OC.L10N.translate('passwords', 'To view this website properly, please enable Javascript JIT.') + | ||
'</div><div class="info" >' + | ||
'<h3 class="howto">' + OC.L10N.translate('passwords', 'How to enable it') + '</h3>' + | ||
'<p>' + OC.L10N.translate('passwords', 'JavaScript JIT might be disabled in your browser in order to render web content in a more secure configuration. You can always enable Javascript JIT in the settings, depending on your web browser.') + '</p><br />' + |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This text is placed directly onto the background image. This could be unreadable.
Its also very verbose. Additionally, neither Chromium nor Firefox do have a setting for this, both put it into the config / flags page. Additionally, calling the feature JIT may be cause them to misconfigure things in FF as typing JIT into the search of about:config will not show the actual setting to disable WASM.
I feel like it would be better to keep the message short and just tell users that "This app requires WASM/WebAssembly to be enabled. Please check our Wiki to learn how to enable it" and then create a page in the wiki like /Enable-WebAssembly
. This would also have the benefit that admins can provide a custom help page instead of users doing things they find on Google
Signed-off-by: Marius David Wieschollek <[email protected]>
I had some time over the weekend and just implemented the warning with the changes i requested |
@marius-wieschollek hi, thanks you ! Would it be possible to use "OC.L10N.translate" which is practical to translate or customize text ? Thanks ! |
Hi
Currently when users don't have webassembly enable, they only see an error telling them their browser is not supported. In some cases, with some advanced privacy settings, some browsers can disable webassembly by default. The purpose of this MR is to ask user to check in settings if they can enable webassembly !