-
Notifications
You must be signed in to change notification settings - Fork 0
/
background.js
48 lines (41 loc) · 1.19 KB
/
background.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
$(function(){
transfer();
});
$('.follow-text').load(function(){
transfer();
});
$('.unfollow-text').load(function(){
transfer();
});
$('.following-text').load(function(){
transfer();
});
$('.block-text').load(function(){
transfer();
});
$('.mute-user-item').load(function(){
transfer();
});
function transfer(){
$('.follow-text').each(function(i,elem) {
if ($(elem).html().match(/フォローする/)) {
$(elem).html('<span class="Icon Icon--follow"></span> 博士課程に送る');
}
});
$('.unfollow-text').each(function(i,elem) {
if ($(elem).html().match(/解除/)) {
$(elem).html("学位を与える");
}
});
$('.following-text').each(function(i,elem) {
if ($(elem).html().match(/フォロー中/)) {
$(elem).html("博士課程に在学中");
}
});
$('.block-text').each(function(i,elem) {
$(elem).html('<button type="button" class="dropdown-link">博士課程を退学する</button>');
});
$('.mute-user-item').each(function(i,elem) {
$(elem).html('<button type="button" class="dropdown-link">博士課程を休学する</button>');
});
}