Просмотр исходного кода

:radio_button: button to load more queue results with pagination

tags/0.0.3^2
juancarbajal98 3 лет назад
Родитель
Сommit
67ee85cddf
2 измененных файлов: 8 добавлений и 6 удалений
  1. 3
    0
      frontend/src/components/ProfileCardList.vue
  2. 5
    6
      frontend/src/views/HomeView.vue

+ 3
- 0
frontend/src/components/ProfileCardList.vue Просмотреть файл

62
         display: flex
62
         display: flex
63
         flex-wrap: wrap
63
         flex-wrap: wrap
64
         flex-direction: column
64
         flex-direction: column
65
+
66
+.more-results
67
+    margin-bottom: 2em
65
 </style>
68
 </style>

+ 5
- 6
frontend/src/views/HomeView.vue Просмотреть файл

1
 <template lang="pug">
1
 <template lang="pug">
2
 main.view--home
2
 main.view--home
3
-    p {{cP._profile.user_name}}
3
+    p {{ cP._profile.user_name }}
4
     article.w-flex.column.align-center
4
     article.w-flex.column.align-center
5
         template(v-if='isLoading')
5
         template(v-if='isLoading')
6
             w-spinner(bounce)
6
             w-spinner(bounce)
7
 
7
 
8
         template(v-else-if='!isLoading && cards.length > 0')
8
         template(v-else-if='!isLoading && cards.length > 0')
9
-            ProfileCardList(
10
-                :cards='cards' 
11
-                @loadMore='onLoadMore'
12
-            )
9
+            ProfileCardList(:cards='cards' @loadMore='onLoadMore')
13
 
10
 
14
         template(v-else-if='cards.length === 0')
11
         template(v-else-if='cards.length === 0')
15
             p No profiles in match_queue.
12
             p No profiles in match_queue.
71
         }
68
         }
72
     },
69
     },
73
     computed: {
70
     computed: {
74
-        cP() {return currentProfile},
71
+        cP() {
72
+            return currentProfile
73
+        },
75
         cards() {
74
         cards() {
76
             let initialCards = currentProfile.queue.map(qProfile =>
75
             let initialCards = currentProfile.queue.map(qProfile =>
77
                 convertToCard(qProfile),
76
                 convertToCard(qProfile),

Загрузка…
Отмена
Сохранить