[FIX] ie11 support (#16682)

pull/16674/head
gabriellsh 5 years ago committed by Diego Sampaio
parent 0068bdb80d
commit be97a51e49
No known key found for this signature in database
GPG Key ID: E060152B30502562
  1. 16
      app/ui-sidenav/client/userPresence.js
  2. 1
      imports/client/query-string
  3. 1
      imports/client/scheduler
  4. 1
      imports/client/split-on-first
  5. 1
      imports/client/strict-uri-encode

@ -67,7 +67,9 @@ const handleEntries = function(entries) {
getAll();
};
const observer = new IntersectionObserver(handleEntries, options);
const featureExists = !!window.IntersectionObserver;
const observer = featureExists && new IntersectionObserver(handleEntries, options);
Tracker.autorun(() => {
if (!Meteor.userId() || !Meteor.status().connected) {
@ -75,13 +77,23 @@ Tracker.autorun(() => {
}
mem.clear(get);
if (featureExists) {
for (const node of data.keys()) {
observer.unobserve(node);
observer.observe(node);
}
}
get(this.data.uid);
getAll();
});
Template.userPresence.onRendered(function() {
data.set(this.firstNode, this.data);
observer.observe(this.firstNode);
if (featureExists) {
return observer.observe(this.firstNode);
}
get(this.data.uid);
getAll();
});

@ -0,0 +1 @@
../../node_modules/query-string/

@ -0,0 +1 @@
../../node_modules/scheduler/

@ -0,0 +1 @@
../../node_modules/split-on-first/

@ -0,0 +1 @@
../../node_modules/strict-uri-encode/
Loading…
Cancel
Save