Add 'open in nitter' button

This commit is contained in:
Wire 2020-07-19 11:05:50 +02:00
parent 6b645c691b
commit f3897529d0
4 changed files with 19 additions and 9 deletions

View File

@ -272,7 +272,7 @@ def getFeed(urls):
newPost.userProfilePic = rssFeed.channel.image.url
except:
newPost.profilePicture = ""
newPost.urlToPost = post.link
newPost.url = post.link
newPost.content = Markup(post.description)
if "Pinned" in post.title.split(":")[0]:
@ -310,7 +310,7 @@ def getPosts(account):
newPost.userProfilePic = rssFeed.channel.image.url
except:
newPost.profilePicture = ""
newPost.urlToPost = post.link
newPost.url = post.link
newPost.content = Markup(post.description)
if "Pinned" in post.title.split(":")[0]:

View File

@ -5,6 +5,10 @@
<div class="left floated author">
<img class="ui avatar image" src="{{ url_for('static',filename='img/avatars/')}}{{range(1, 12) | random}}.png">
</div>
<a href="{{post.url}}"><span class="right floated star">
<i class="share square outline icon"></i>
</span></a>
</div>
<div class="header" id="author"><a href="user/{{post.op.replace('@','')}}">{{ post.op }}</a></div>
<div class="meta">

View File

@ -5,6 +5,10 @@
<div class="left floated author">
<img class="ui avatar image" src="{{ post.profilePic }}">
</div>
<a href="{{post.url}}"><span class="right floated star">
<i class="share square outline icon"></i>
</span></a>
</div>
<div class="header" id="author"><a href="user/{{post.op.replace('@','')}}">{{ post.op }}</a></div>
<div class="meta">
@ -17,13 +21,11 @@
<p>{{post.content}}</p>
</div>
<div class="extra content">
<p>
<form class="ui form" action="{{ url_for('savePost', url=post.urlToPost.replace('/', '~')) }}" method="post">
<button type="submit" class="ui icon button">
<i class="bookmark outline icon"></i>
</button>
</form>
</p>
<form class="ui form" action="{{ url_for('savePost', url=post.urlToPost.replace('/', '~')) }}" method="post">
<button type="submit" class="ui icon button">
<i class="bookmark outline icon"></i>
</button>
</form>
</div>
</div>
<!--<div class="extra content">

View File

@ -5,6 +5,10 @@
<div class="left floated author">
<img class="ui avatar image" src="{{ url_for('static',filename='img/avatars/')}}{{range(1, 12) | random}}.png">
</div>
<a href="{{post.url}}"><span class="right floated star">
<i class="share square outline icon"></i>
</span></a>
</div>
<div class="header" id="author"><a href="user/{{post.username}}">@{{ post.username }}</a></div>
<div class="meta">