|
165 | 165 | } |
166 | 166 | }; |
167 | 167 | } |
168 | | - var contentArea='.entry-content'; |
169 | | - var commArea="comment-content"; |
170 | 168 | var t, curSite; |
| 169 | + var contentArea='.entry-content', commArea="comment-content"; |
| 170 | + var originTitile = document.title; |
171 | 171 | var isHttps=location.protocol=="https:"; |
172 | 172 | if(isHttps){ |
173 | 173 | var refMeta = document.createElement('meta'); |
|
282 | 282 | } |
283 | 283 | } |
284 | 284 | }else if (config.sites.findSite("reimu").regex.test(location.href)){ |
285 | | - var OriginTitile = document.title; |
286 | 285 | var titleTime; |
287 | 286 | document.addEventListener('visibilitychange', function() { |
288 | 287 | if (document.hidden) { |
289 | | - document.title = '\u6765\u556a\u0038\u5566~(*´∇`*) ' + OriginTitile; |
| 288 | + document.title = '\u6765\u556a\u0038\u5566~(*´∇`*) ' + originTitile; |
290 | 289 | clearTimeout(titleTime); |
291 | 290 | } |
292 | 291 | else { |
293 | | - document.title = '\u624d\u4e0d\u7ed9\u556a(╯‵□′)╯︵┻━┻ ' + OriginTitile; |
| 292 | + document.title = '\u624d\u4e0d\u7ed9\u556a(╯‵□′)╯︵┻━┻ ' + originTitile; |
294 | 293 | titleTime = setTimeout(function() { |
295 | | - document.title = OriginTitile; |
| 294 | + document.title = originTitile; |
296 | 295 | }, 2000); |
297 | 296 | } |
298 | 297 | }); |
|
331 | 330 | }else if(config.sites.findSite("hacg").regex.test(location.href)){ |
332 | 331 | var has8=false; |
333 | 332 | var comms=document.querySelectorAll("span.fn"); |
| 333 | + var msg = "…" + quote;pos = 0; |
| 334 | + function scrollMSG() { |
| 335 | + document.title = msg.substring(pos, msg.length) + msg.substring(0, pos); |
| 336 | + pos++; |
| 337 | + if (pos > msg.length) { |
| 338 | + pos = 0; |
| 339 | + document.title = originTitile; |
| 340 | + }else{ |
| 341 | + setTimeout(scrollMSG,150); |
| 342 | + } |
| 343 | + } |
| 344 | + scrollMSG(); |
334 | 345 | for(var comm of comms){ |
335 | 346 | if(comm.innerHTML == "\u5c0f\u0038\u9171"){ |
336 | 347 | has8=true; |
|
0 commit comments