Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add skeleton loaders #36

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 12 additions & 7 deletions src/views/OfficeBearers.vue
Original file line number Diff line number Diff line change
@@ -1,17 +1,22 @@
<template lang="pug">
v-content.justify-center(justify-center v-if="!$apollo.queries.societies.loading")
v-card.text-center(class="blue text-center mx-auto" max-width="800").mt-4
<template lang="pug" v-slot:placeholder>
riddhisera marked this conversation as resolved.
Show resolved Hide resolved
v-content.justify-center()
v-card.text-center(class="blue text-center mx-auto" max-width="800" v-if="!$apollo.queries.societies.loading").mt-4
v-card-text(class="white--text")
h1.font-weight-regular Office Bearers
h1.font-weight-regular Office Bearers
v-skeleton-loader(v-else loading="loading" type="heading" align="center" tile)
riddhisera marked this conversation as resolved.
Show resolved Hide resolved
v-container(v-for="({ node }, i) in societies.edges" :key="i" v-if=" node.mentor || node.secretary || node.jointSecretary ")
v-card-title.display-1.justify-center {{ node.name }}
v-skeleton-loader(v-if="$apollo.queries.societies.loading" loading="loading" type="heading" align="center" tile)
v-row.justify-space-around(v-if=" node.mentor || node.secretary || node.jointSecretary ")
v-col(cols="12" lg="4" sm="6" v-if="node.mentor")
OfficeBearerCard(:avatarSize="120" :profile="node.mentor" :designation="'Mentor'")
OfficeBearerCard(:avatarSize="120" :profile="node.mentor" :designation="'Mentor'" v-if="!$apollo.queries.societies.loading" )
v-skeleton-loader(v-else loading="loading" type="card-avatar, actions")
v-col(cols="12" lg="4" sm="6" v-if="node.secretary")
OfficeBearerCard(:avatarSize="120" :profile="node.secretary" :designation="'Secretary'")
OfficeBearerCard(:avatarSize="120" :profile="node.secretary" :designation="'Secretary'" v-if="!$apollo.queries.societies.loading")
v-skeleton-loader(v-else loading="loading" type="card-avatar, actions")
v-col(cols="12" lg="4" sm="6" v-if="node.jointSecretary")
OfficeBearerCard(:avatarSize="120" :profile="node.jointSecretary" :designation="'Joint Secretary'")
OfficeBearerCard(:avatarSize="120" :profile="node.jointSecretary" :designation="'Joint Secretary'" v-if="!$apollo.queries.societies.loading")
v-skeleton-loader(v-else loading="loading" type="card-avatar, actions")
</template>

<script>
Expand Down