Thread viewer for Bluesky

show message about a liked post being blocked inline

Changed files
+16 -2
+10 -2
post_component.js
··· 699 699 // continue down 700 700 } 701 701 } else { 702 - // no data 703 - alert("Sorry, this post is blocked or was deleted."); 702 + this.showPostAsBlocked(); 704 703 return; 705 704 } 706 705 } else { ··· 726 725 } 727 726 } catch (error) { 728 727 showError(error); 728 + } 729 + } 730 + 731 + showPostAsBlocked() { 732 + let stats = $(this.rootElement.querySelector(':scope > .content > p.stats')); 733 + 734 + if (!stats.querySelector('.blocked-info')) { 735 + let span = $tag('span.blocked-info', { text: '🚫 Post unavailable' }); 736 + stats.append(span); 729 737 } 730 738 } 731 739
+6
style.css
··· 680 680 margin-right: 10px; 681 681 } 682 682 683 + .post .stats .blocked-info { 684 + color: #a02020; 685 + font-weight: bold; 686 + margin-left: 5px; 687 + } 688 + 683 689 .post img.loader { 684 690 width: 24px; 685 691 animation: rotation 3s infinite linear;