Proyectos de Subversion LeadersLinked - Antes de SPA

Rev

Rev 690 | Mostrar el archivo completo | | | Autoría | Ultima modificación | Ver Log |

Rev 690 Rev 691
Línea 151... Línea 151...
151
  const handleChangeTab = (tab) => {
151
  const handleChangeTab = (tab) => {
152
    setActiveTab(tab);
152
    setActiveTab(tab);
153
  };
153
  };
Línea 154... Línea 154...
154
 
154
 
-
 
155
  useEffect(() => {
155
  useEffect(() => {
156
    let entities = [];
156
    clearInterval(heartBeatInterval);
157
    clearInterval(heartBeatInterval);
157
    heartBeatInterval = setInterval(async() => {
158
    heartBeatInterval = setInterval(async() => {
158
      const entities = await heartBeat();
-
 
159
 
-
 
160
      console.log('>>: entities > effect > ', entities)
159
      entities = await heartBeat() || [];
-
 
160
    }, chatInterval);
-
 
161
    if((entities === fullChats) && (chatInterval !== defaultChatInterval * 2)){
-
 
162
      clearInterval(heartBeatInterval);
-
 
163
      setChatInterval(defaultChatInterval * 2);
161
    }, chatInterval);
164
    }
162
    return () => {
165
    return () => {
163
      clearInterval(heartBeatInterval);
166
      clearInterval(heartBeatInterval);
164
    };
167
    };
165
  }, [chatInterval, fullChats]);
168
  }, [chatInterval, fullChats]);
166
  useEffect(() => {
-
 
167
    console.log('>>: chats > ', fullChats)
-
 
168
  }, [fullChats])
-
 
169
  useEffect(() => {
169
  useEffect(() => {
170
    emojione.imageType = "png";
170
    emojione.imageType = "png";
171
    emojione.sprites = false;
171
    emojione.sprites = false;
172
    emojione.ascii = true;
172
    emojione.ascii = true;
173
    emojione.imagePathPNG = props.emojiOnePath;
173
    emojione.imagePathPNG = props.emojiOnePath;