+2
-2
api.js
+2
-2
api.js
···
159
159
160
160
if (did) {
161
161
this.handleCache.setHandleDid(handle, did);
162
-
return did;
162
+
return did;
163
163
} else {
164
164
throw new ResponseDataError('Missing DID in response: ' + JSON.stringify(json));
165
165
}
···
236
236
let json = await this.getRequest('blue.feeds.post.getReplies', { uri });
237
237
return json.replies;
238
238
}
239
-
239
+
240
240
/** @param {string} uri, @returns {Promise<number>} */
241
241
242
242
async getQuoteCount(uri) {
+1
-1
embed_component.js
+1
-1
embed_component.js
+1
-1
models.js
+1
-1
models.js
···
110
110
case 'app.bsky.feed.defs#threadViewPost':
111
111
let post = new Post(json.post, { level: level, absoluteLevel: absoluteLevel });
112
112
113
-
post.pageRoot = pageRoot ?? post;
113
+
post.pageRoot = pageRoot ?? post;
114
114
115
115
if (json.replies) {
116
116
let replies = json.replies.map(x => Post.parseThreadPost(x, post.pageRoot, level + 1, absoluteLevel + 1));
+4
-4
post_component.js
+4
-4
post_component.js
···
44
44
/** @returns {string} */
45
45
get linkToAuthor() {
46
46
if (this.post.author.handle != 'handle.invalid') {
47
-
return 'https://bsky.app/profile/' + this.post.author.handle;
47
+
return 'https://bsky.app/profile/' + this.post.author.handle;
48
48
} else {
49
49
return 'https://bsky.app/profile/' + this.post.author.did;
50
50
}
···
109
109
return div;
110
110
} else if (this.post instanceof DetachedQuotePost) {
111
111
this.buildDetachedQuoteElement(div);
112
-
return div;
112
+
return div;
113
113
} else if (this.post instanceof MissingPost) {
114
114
this.buildMissingPostElement(div);
115
-
return div;
115
+
return div;
116
116
}
117
117
118
118
let header = this.buildPostHeader();
···
583
583
alert("Sorry, this post is blocked.");
584
584
});
585
585
} else {
586
-
showDialog(loginDialog);
586
+
showDialog(loginDialog);
587
587
}
588
588
return;
589
589
}
+6
-6
skythread.js
+6
-6
skythread.js
···
24
24
} else {
25
25
e.stopPropagation();
26
26
}
27
-
});
27
+
});
28
28
29
29
dialog.querySelector('.close')?.addEventListener('click', (e) => {
30
30
hideDialog(dialog);
···
324
324
let params = new URLSearchParams(location.search);
325
325
let page = params.get('page');
326
326
if (page) {
327
-
openPage(page);
327
+
openPage(page);
328
328
}
329
329
})
330
330
.catch((error) => {
···
335
335
if (error.code == 401 && error.json.error == 'AuthFactorTokenRequired') {
336
336
alert("Please log in using an \"app password\" if you have 2FA enabled.");
337
337
} else {
338
-
window.setTimeout(() => alert(error), 10);
338
+
window.setTimeout(() => alert(error), 10);
339
339
}
340
340
});
341
341
}
···
410
410
function openPage(page) {
411
411
if (!accountAPI.isLoggedIn) {
412
412
toggleDialog(loginDialog);
413
-
return;
413
+
return;
414
414
}
415
415
416
416
if (page == 'notif') {
···
486
486
console.log(error);
487
487
isLoading = false;
488
488
});
489
-
});
489
+
});
490
490
}
491
491
492
492
/** @param {Post} post */
···
657
657
658
658
if (root instanceof Post) {
659
659
setPageTitle(root);
660
-
loadQuoteCount = blueAPI.getQuoteCount(root.uri);
660
+
loadQuoteCount = blueAPI.getQuoteCount(root.uri);
661
661
662
662
if (root.parent) {
663
663
let p = buildParentLink(root.parent);