Просмотр исходного кода

fix(sidebar): bug when a tab title could be stuck in loading mode

Jocelyn Boullier 5 лет назад
Родитель
Сommit
a2d4009ed0
1 измененных файлов с 1 добавлено и 4 удалено
  1. 1 4
      src/Sidebar.purs

+ 1 - 4
src/Sidebar.purs

@@ -89,10 +89,7 @@ updateTabInfo tid cinfo' tab' = do
   let
   let
     newTitle = case cinfo.status of
     newTitle = case cinfo.status of
       Just "loading" -> Just "Loading ..."
       Just "loading" -> Just "Loading ..."
-      -- only change the title if we did receive a new title
-      -- prevent some flickering when the status `complete` but the tab title
-      -- info is empty
-      _ -> cinfo.title 
+      _ -> Just tab.title
   maybe (pure unit) (\t -> setText t tabTitleDiv) newTitle
   maybe (pure unit) (\t -> setText t tabTitleDiv) newTitle
 
 
   tabFaviconDiv <- select ("#" <> (show tid) <> " > .tab-favicon")
   tabFaviconDiv <- select ("#" <> (show tid) <> " > .tab-favicon")