Closed mcocolla closed 5 years ago
The contacts app also does appear to load not correctly as well. @mcocolla can you try that out with your setup?
Well, if the Tasks app does not work in a Beta release of Chrome, but does work in the stable releases, I would consider this a bug in Chrome, not in the app. The replace
function is a standard javascript function for strings and should work without problems.
It is blank also in Firefox 68.0.2.
The JS error here appears to be: TypeError: "t.displayName is undefined"
It is blank also in Firefox 68.0.2.
The JS error here appears to be: TypeError: "t.displayName is undefined"
I cannot confirm this, the app works fine on this Firefox version:
Please provide the whole broswerlog and best fill the issue template https://github.com/nextcloud/tasks/blob/master/issue_template.md
The contacts app also does appear to load not correctly as well. @mcocolla can you try that out with your setup?
I installed the Contacts app, and initially could not even create a contact but once I was able to add a contact it would not display the contact when I loaded the main navigation link fresh. I could navigate the contact's direct link but not from the main interface at "apps/contacts/All%20contacts"
When it loads "apps/contacts/All%20contacts", it is also throwing errors in the browser's console:
contacts.js?v=1ee059fb-11:1014 Error during the check: missing FN t {jCal: Array(3), addressbook: {…}, vCard: t, conflict: false, dav: e} TypeError: t(...).toLowerCase is not a function
at Object.run (contacts.js?v=1ee059fb-11:1014)
at contacts.js?v=1ee059fb-11:1014
at Array.forEach (
contacts.js?v=1ee059fb-11:7 TypeError: t.name.localeCompare is not a function
at contacts.js?v=1ee059fb-11:1014
at Array.sort (
Somehow the behaviour of Chrome changed with Chrome 77 Beta. t(...)
now yields a TrustedHTML
object instead of a string. This object does not have .replace
function obviously. I can provide a fix for this, but I wonder whether this will change for the stable release of Chrome. Especially since this will most likely affect all of Nextcloud (as you see on the Contacts app already).
hm...
https://github.com/nextcloud/tasks/pull/591 will partially solve the issue. The app is usable again but we still get a lot of warnings because the property type check failed for some vue components, e.g.:
[Vue warn]: Invalid prop: type check failed for prop "message". Expected String with value "This will delete the calendar "Calendar with really very long name" and all corresponding events and tasks.", got TrustedHTML
found in
---> <PopoverMenu> at src/components/Confirmation.vue
<PopoverMenu> at src/components/PopoverMenu.vue
<RouterLink>
<Draggable>
<TheList> at src/components/TheList.vue
<App> at src/app.vue
<Root>
While #591 is a general improvement, fixing the error above might need some workaround just for Chrome (Beta). We could do a .toString()
on the TrustedHTML
object in order to get a string. While this would be superfluous for the other browsers it would at least not lead to a warning or error there.
I just saw that opening the details view still fails. We would really need to adjust the t(..)
function for the translation here. Summoning @nextcloud/javascript now 😉 .
Adding something like
Vue.prototype.$t = function() {
return t.apply(null, arguments).toString()
}
would probably help, but this should be ideally done on server I think.
PR is in #593 but please see https://github.com/nextcloud/tasks/pull/593#issue-315078456.
Fixed with #593, although this probably needs a fix in server as well. Will report it there when I find the time.
Steps to reproduce
Expected behaviour
Tasks lists and tasks from those lists should show on the screen.
Actual behaviour
JavaScript throws 3 errors from tasks.js and the screen is blank. Add list does not work either. Errors are listed below in the Browser log section.
Stable versions of Chrome, Firefox, IE11, and Edge currently work as expected. Not sure if it is a bug in Chrome Beta or if it is a change to the JavaScript engine that is permanent.
Client configuration
Browser: Chrome Beta 77.0.3865.42
Operating system: Windows 10 1903
Browser log