From 7e7bca7ff00368c966885d38b2ffa9fad242f8b3 Mon Sep 17 00:00:00 2001 From: Kevin Ansfield Date: Thu, 21 May 2020 10:00:14 +0100 Subject: [PATCH] Added loading state for member list rows no issue - with the sparsely loaded list you can scroll to an area which is being loaded in the background - if a list row is being loaded, display a "loading" version of the row so it doesn't look like you're stuck on a blank screen --- .../app/components/gh-members-list-item.hbs | 67 ++++++++++--------- ghost/admin/app/templates/members.hbs | 2 +- 2 files changed, 38 insertions(+), 31 deletions(-) diff --git a/ghost/admin/app/components/gh-members-list-item.hbs b/ghost/admin/app/components/gh-members-list-item.hbs index a8b72371fa..b3ddff3ca6 100644 --- a/ghost/admin/app/components/gh-members-list-item.hbs +++ b/ghost/admin/app/components/gh-members-list-item.hbs @@ -1,37 +1,44 @@ -
  • - -
    - -
    -

    {{or @member.name @member.email}}

    - {{#if @member.name}} -

    {{@member.email}}

    - {{/if}} +
  • + {{#if @member.is_loading}} +
    +
    +
    +
    + {{else}} + +
    + +
    +

    {{or @member.name @member.email}}

    + {{#if @member.name}} +

    {{@member.email}}

    + {{/if}} +
    - -
    + - - {{#if @member.geolocation}} - {{#if (eq @member.geolocation.country_code "US")}} - {{@member.geolocation.region}}, US + + {{#if @member.geolocation}} + {{#if (eq @member.geolocation.country_code "US")}} + {{@member.geolocation.region}}, US + {{else}} + {{@member.geolocation.country}} + {{/if}} {{else}} - {{@member.geolocation.country}} + Unknown {{/if}} - {{else}} - Unknown - {{/if}} - + - - {{#if @member.createdAtUTC}} - {{moment-format @member.createdAtUTC "MMM DD, YYYY"}} ({{this.memberSince}}) - {{/if}} - + + {{#if @member.createdAtUTC}} + {{moment-format @member.createdAtUTC "MMM DD, YYYY"}} ({{this.memberSince}}) + {{/if}} + - -
    - {{svg-jar "arrow-right" class="w6 h6 fill-midgrey pa1"}} -
    -
    + +
    + {{svg-jar "arrow-right" class="w6 h6 fill-midgrey pa1"}} +
    +
    + {{/if}}
  • \ No newline at end of file diff --git a/ghost/admin/app/templates/members.hbs b/ghost/admin/app/templates/members.hbs index 3843911c31..981ea9cdbc 100644 --- a/ghost/admin/app/templates/members.hbs +++ b/ghost/admin/app/templates/members.hbs @@ -66,7 +66,7 @@
    Created
    - + {{else}}