mirror of
https://github.com/LemmyNet/joinlemmy-site.git
synced 2024-11-25 05:41:16 +00:00
Dont list instances with closed signups
This commit is contained in:
parent
686c773534
commit
53d24a6d24
1 changed files with 48 additions and 43 deletions
|
@ -86,51 +86,56 @@ export class Instances extends Component<any, any> {
|
||||||
<div>
|
<div>
|
||||||
<h2>{header}</h2>
|
<h2>{header}</h2>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
{instances.map(instance => {
|
{instances
|
||||||
let domain = instance.domain;
|
.filter(
|
||||||
let users_active_month =
|
i =>
|
||||||
instance.site_info.site_view.counts.users_active_month;
|
i.site_info.site_view.local_site.registration_mode != "closed"
|
||||||
let description = instance.site_info.site_view.site.description;
|
)
|
||||||
let icon = instance.site_info.site_view.site.icon;
|
.map(instance => {
|
||||||
let require_application =
|
let domain = instance.domain;
|
||||||
instance.site_info.site_view.site.require_application;
|
let users_active_month =
|
||||||
return (
|
instance.site_info.site_view.counts.users_active_month;
|
||||||
<div class="card col-6">
|
let description = instance.site_info.site_view.site.description;
|
||||||
<header>
|
let icon = instance.site_info.site_view.site.icon;
|
||||||
<div class="row">
|
let require_application =
|
||||||
<h4 class="col">{domain}</h4>
|
instance.site_info.site_view.site.require_application;
|
||||||
<h4 class="col text-right">
|
return (
|
||||||
<i>
|
<div class="card col-6">
|
||||||
{i18n.t("users_active_per_month", {
|
<header>
|
||||||
count: users_active_month,
|
<div class="row">
|
||||||
formattedCount: numToSI(users_active_month),
|
<h4 class="col">{domain}</h4>
|
||||||
})}
|
<h4 class="col text-right">
|
||||||
</i>
|
<i>
|
||||||
</h4>
|
{i18n.t("users_active_per_month", {
|
||||||
|
count: users_active_month,
|
||||||
|
formattedCount: numToSI(users_active_month),
|
||||||
|
})}
|
||||||
|
</i>
|
||||||
|
</h4>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
|
<div class="is-center">
|
||||||
|
<img
|
||||||
|
class="join-banner"
|
||||||
|
src={icon || "/static/assets/images/lemmy.svg"}
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
</header>
|
<br />
|
||||||
<div class="is-center">
|
<p class="join-desc">{description}</p>
|
||||||
<img
|
<footer>
|
||||||
class="join-banner"
|
{require_application ? (
|
||||||
src={icon || "/static/assets/images/lemmy.svg"}
|
<a class="button primary" href={`https://${domain}`}>
|
||||||
/>
|
{i18n.t("apply_to_join")}
|
||||||
|
</a>
|
||||||
|
) : (
|
||||||
|
<a class="button primary" href={`https://${domain}`}>
|
||||||
|
{i18n.t("join")}
|
||||||
|
</a>
|
||||||
|
)}
|
||||||
|
</footer>
|
||||||
</div>
|
</div>
|
||||||
<br />
|
);
|
||||||
<p class="join-desc">{description}</p>
|
})}
|
||||||
<footer>
|
|
||||||
{require_application ? (
|
|
||||||
<a class="button primary" href={`https://${domain}`}>
|
|
||||||
{i18n.t("apply_to_join")}
|
|
||||||
</a>
|
|
||||||
) : (
|
|
||||||
<a class="button primary" href={`https://${domain}`}>
|
|
||||||
{i18n.t("join")}
|
|
||||||
</a>
|
|
||||||
)}
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
);
|
|
||||||
})}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in a new issue