mirror of
https://git.joinsharkey.org/Sharkey/Sharkey.git
synced 2024-12-23 21:43:09 +02:00
[Client:Desktop] Fix bug
This commit is contained in:
parent
e6e63f0679
commit
17677e00f2
3 changed files with 13 additions and 15 deletions
|
@ -1,7 +1,7 @@
|
||||||
{
|
{
|
||||||
"name": "misskey",
|
"name": "misskey",
|
||||||
"author": "syuilo <i@syuilo.com>",
|
"author": "syuilo <i@syuilo.com>",
|
||||||
"version": "0.0.1475",
|
"version": "0.0.1479",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"description": "A miniblog-based SNS",
|
"description": "A miniblog-based SNS",
|
||||||
"bugs": "https://github.com/syuilo/misskey/issues",
|
"bugs": "https://github.com/syuilo/misskey/issues",
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<mk-recommended-polls-home-widget>
|
<mk-recommended-polls-home-widget>
|
||||||
<p class="title"><i class="fa fa-pie-chart"></i>投票</p>
|
<p class="title"><i class="fa fa-pie-chart"></i>投票</p>
|
||||||
<button onclick={ refresh } title="他を見る"><i class="fa fa-refresh"></i></button>
|
<button onclick={ fetch } title="他を見る"><i class="fa fa-refresh"></i></button>
|
||||||
<div class="poll" if={ !loading && poll != null }>
|
<div class="poll" if={ !loading && poll != null }>
|
||||||
<p class="text" if={ poll.text }>{ poll.text }</p>
|
<p class="text" if={ poll.text }>{ poll.text }</p>
|
||||||
<mk-poll post={ poll }></mk-poll>
|
<mk-poll post={ poll }></mk-poll>
|
||||||
|
@ -87,17 +87,16 @@
|
||||||
offset: this.offset
|
offset: this.offset
|
||||||
}).then(posts => {
|
}).then(posts => {
|
||||||
const poll = posts ? posts[0] : null;
|
const poll = posts ? posts[0] : null;
|
||||||
if (poll == null) this.offset = 0;
|
if (post == null) {
|
||||||
|
this.offset = 0;
|
||||||
|
} else {
|
||||||
|
this.offset++;
|
||||||
|
}
|
||||||
this.update({
|
this.update({
|
||||||
loading: false,
|
loading: false,
|
||||||
poll: poll
|
poll: poll
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
this.refresh = () => {
|
|
||||||
this.offset++;
|
|
||||||
this.fetch();
|
|
||||||
};
|
|
||||||
</script>
|
</script>
|
||||||
</mk-recommended-polls-home-widget>
|
</mk-recommended-polls-home-widget>
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
<mk-trends-home-widget>
|
<mk-trends-home-widget>
|
||||||
<p class="title"><i class="fa fa-fire"></i>トレンド</p>
|
<p class="title"><i class="fa fa-fire"></i>トレンド</p>
|
||||||
<button onclick={ refresh } title="他を見る"><i class="fa fa-refresh"></i></button>
|
<button onclick={ fetch } title="他を見る"><i class="fa fa-refresh"></i></button>
|
||||||
<div class="post" if={ !loading && post != null }>
|
<div class="post" if={ !loading && post != null }>
|
||||||
<p class="text">{ post.text }</p>
|
<p class="text">{ post.text }</p>
|
||||||
<p class="author">―<a href="/{ post.user.username }">@{ post.user.username }</a></p>
|
<p class="author">―<a href="/{ post.user.username }">@{ post.user.username }</a></p>
|
||||||
|
@ -96,17 +96,16 @@
|
||||||
poll: false
|
poll: false
|
||||||
}).then(posts => {
|
}).then(posts => {
|
||||||
const post = posts ? posts[0] : null;
|
const post = posts ? posts[0] : null;
|
||||||
if (post == null) this.offset = 0;
|
if (post == null) {
|
||||||
|
this.offset = 0;
|
||||||
|
} else {
|
||||||
|
this.offset++;
|
||||||
|
}
|
||||||
this.update({
|
this.update({
|
||||||
loading: false,
|
loading: false,
|
||||||
post: post
|
post: post
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
this.refresh = () => {
|
|
||||||
this.offset++;
|
|
||||||
this.fetch();
|
|
||||||
};
|
|
||||||
</script>
|
</script>
|
||||||
</mk-trends-home-widget>
|
</mk-trends-home-widget>
|
||||||
|
|
Loading…
Reference in a new issue