replace remaining instances of ds-card with base-card

This commit is contained in:
Alina Beck 2020-02-11 17:45:32 +01:00
parent 60818c5902
commit 9895c32b0b
28 changed files with 156 additions and 124 deletions

View File

@ -1,11 +1,12 @@
<template>
<ds-card :header="$t('admin.categories.name')">
<base-card>
<h2 class="title">{{ $t('admin.categories.name') }}</h2>
<ds-table :data="Category" :fields="fields" condensed>
<template slot="icon" slot-scope="scope">
<base-icon :name="scope.row.icon" />
</template>
</ds-table>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,5 +1,6 @@
<template>
<ds-card :header="$t('admin.donations.name')">
<base-card>
<h2 class="title">{{ $t('admin.donations.name') }}</h2>
<ds-form v-model="formData" @submit="submit">
<ds-input model="goal" :label="$t('admin.donations.goal')" placeholder="15000" icon="money" />
<ds-input
@ -12,7 +13,7 @@
{{ $t('actions.save') }}
</base-button>
</ds-form>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,5 +1,6 @@
<template>
<ds-card :header="$t('admin.hashtags.name')">
<base-card>
<h2 class="title">{{ $t('admin.hashtags.name') }}</h2>
<ds-table :data="Tag" :fields="fields" condensed>
<template slot="index" slot-scope="scope">{{ scope.index + 1 }}.</template>
<template slot="id" slot-scope="scope">
@ -8,7 +9,7 @@
</nuxt-link>
</template>
</ds-table>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,5 +1,5 @@
<template>
<ds-card>
<base-card>
<ApolloQuery :query="Statistics">
<template v-slot="{ result: { loading, error, data } }">
<template v-if="loading">
@ -123,7 +123,7 @@
</template>
</template>
</ApolloQuery>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,13 +1,12 @@
<template>
<!-- This registration form will be visible to the public as soon as the registration is open to the public. -->
<ds-section>
<ds-space>
<ds-heading size="h3">{{ $t('admin.invites.title') }}</ds-heading>
<ds-text>{{ $t('admin.invites.description') }}</ds-text>
</ds-space>
<ds-card class="signup">
<base-card>
<signup :invitation="true" />
</ds-card>
</base-card>
</ds-section>
</template>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('admin.notifications.name')">
<base-card>
<h2 class="title">{{ $t('admin.notifications.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('admin.organizations.name')">
<base-card>
<h2 class="title">{{ $t('admin.organizations.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('admin.pages.name')">
<base-card>
<h2 class="title">{{ $t('admin.pages.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('admin.settings.name')">
<base-card>
<h2 class="title">{{ $t('admin.settings.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,24 +1,23 @@
<template>
<div>
<ds-space>
<ds-card :header="$t('admin.users.name')">
<ds-form v-model="form" @submit="submit">
<ds-flex gutter="small">
<ds-flex-item width="90%">
<ds-input
model="query"
:placeholder="$t('admin.users.form.placeholder')"
icon="search"
/>
</ds-flex-item>
<ds-flex-item width="30px">
<base-button filled circle type="submit" icon="search" :loading="$apollo.loading" />
</ds-flex-item>
</ds-flex>
</ds-form>
</ds-card>
</ds-space>
<ds-card v-if="User && User.length">
<div class="admin-users">
<base-card>
<h2 class="title">{{ $t('admin.users.name') }}</h2>
<ds-form v-model="form" @submit="submit">
<ds-flex gutter="small">
<ds-flex-item width="90%">
<ds-input
model="query"
:placeholder="$t('admin.users.form.placeholder')"
icon="search"
/>
</ds-flex-item>
<ds-flex-item width="30px">
<base-button filled circle type="submit" icon="search" :loading="$apollo.loading" />
</ds-flex-item>
</ds-flex>
</ds-form>
</base-card>
<base-card v-if="User && User.length">
<ds-table :data="User" :fields="fields" condensed>
<template slot="index" slot-scope="scope">{{ scope.row.index + 1 }}.</template>
<template slot="name" slot-scope="scope">
@ -51,10 +50,10 @@
</template>
</ds-table>
<pagination-buttons :hasNext="hasNext" :hasPrevious="hasPrevious" @next="next" @back="back" />
</ds-card>
<ds-card v-else>
</base-card>
<base-card v-else>
<ds-placeholder>{{ $t('admin.users.empty') }}</ds-placeholder>
</ds-card>
</base-card>
</div>
</template>
@ -178,3 +177,9 @@ export default {
},
}
</script>
<style lang="scss">
.admin-users >.base-card:first-child {
margin-bottom: $space-small;
}
</style>

View File

@ -1,5 +1,5 @@
<template>
<ds-card space="small">
<base-card>
<ds-flex class="notifications-page-flex">
<ds-flex-item :width="{ lg: '85%' }">
<ds-heading tag="h3">{{ $t('notifications.title') }}</ds-heading>
@ -16,7 +16,7 @@
:notifications="notifications"
/>
<pagination-buttons :hasNext="hasNext" :hasPrevious="hasPrevious" @back="back" @next="next" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,6 +1,6 @@
<template>
<ds-card>
<h2 style="margin-bottom: .2em;">{{ $t('post.moreInfo.title') }}</h2>
<base-card>
<h2 class="title">{{ $t('post.moreInfo.title') }}</h2>
<p>{{ $t('post.moreInfo.description') }}</p>
<ds-space />
<h3>{{ $t('post.moreInfo.titleOfCategoriesSection') }}</h3>
@ -33,7 +33,7 @@
</masonry-grid>
<hc-empty v-else margin="large" icon="file" message="No related Posts" />
</ds-section>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card header="Werde aktiv!">
<base-card>
<h2 class="title">Werde aktiv!</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<div>
<ds-space>
<ds-card :header="$t('settings.blocked-users.name')">
<base-card>
<h2 class="title">{{ $t('settings.blocked-users.name') }}</h2>
<ds-text>
{{ $t('settings.blocked-users.explanation.intro') }}
</ds-text>
@ -16,9 +17,9 @@
{{ $t('settings.blocked-users.explanation.notifications') }}
</ds-list-item>
</ds-list>
</ds-card>
</base-card>
</ds-space>
<ds-card v-if="blockedUsers && blockedUsers.length">
<base-card v-if="blockedUsers && blockedUsers.length">
<ds-table :data="blockedUsers" :fields="fields" condensed>
<template #avatar="scope">
<nuxt-link
@ -55,8 +56,8 @@
<base-button circle size="small" @click="unblockUser(scope)" icon="user-plus" />
</template>
</ds-table>
</ds-card>
<ds-card v-else>
</base-card>
<base-card v-else>
<ds-space>
<ds-placeholder>
{{ $t('settings.blocked-users.empty') }}
@ -67,7 +68,7 @@
{{ $t('settings.blocked-users.how-to') }}
</ds-text>
</ds-space>
</ds-card>
</base-card>
</div>
</template>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('settings.download.name')">
<base-card>
<h2 class="title">{{ $t('settings.download.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,5 +1,6 @@
<template>
<ds-card :header="$t('settings.embeds.name')">
<base-card>
<h2 class="title">{{ $t('settings.embeds.name') }}</h2>
<ds-section>
<ds-text>
{{ $t('settings.embeds.status.description') }}
@ -31,7 +32,7 @@
</li>
</ul>
</ds-section>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-form v-model="form" :schema="formSchema" @submit="submit">
<template slot-scope="{ errors }">
<ds-card :header="$t('settings.data.name')">
<base-card>
<h2 class="title">{{ $t('settings.data.name') }}</h2>
<ds-input
id="name"
model="name"
@ -35,7 +36,7 @@
{{ $t('actions.save') }}
</base-button>
</template>
</ds-card>
</base-card>
</template>
</ds-form>
</template>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('settings.invites.name')">
<base-card>
<h2 class="title">{{ $t('settings.invites.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('settings.languages.name')">
<base-card>
<h2 class="title">{{ $t('settings.languages.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<div>
<ds-space>
<ds-card :header="$t('settings.muted-users.name')">
<base-card>
<h2 class="title">{{ $t('settings.muted-users.name') }}</h2>
<ds-text>
{{ $t('settings.muted-users.explanation.intro') }}
</ds-text>
@ -13,9 +14,9 @@
{{ $t('settings.muted-users.explanation.search') }}
</ds-list-item>
</ds-list>
</ds-card>
</base-card>
</ds-space>
<ds-card v-if="mutedUsers && mutedUsers.length">
<base-card v-if="mutedUsers && mutedUsers.length">
<ds-table :data="mutedUsers" :fields="fields" condensed>
<template #avatar="scope">
<nuxt-link
@ -52,8 +53,8 @@
<base-button circle size="small" @click="unmuteUser(scope)" icon="user-plus" />
</template>
</ds-table>
</ds-card>
<ds-card v-else>
</base-card>
<base-card v-else>
<ds-space>
<ds-placeholder>
{{ $t('settings.muted-users.empty') }}
@ -64,7 +65,7 @@
{{ $t('settings.muted-users.how-to') }}
</ds-text>
</ds-space>
</ds-card>
</base-card>
</div>
</template>

View File

@ -1,7 +1,8 @@
<template>
<ds-form v-model="form" :schema="formSchema" @submit="submit">
<template slot-scope="{ errors }">
<ds-card :header="$t('settings.email.name')">
<base-card>
<h2 class="title">{{ $t('settings.email.name') }}</h2>
<ds-input
id="email"
model="email"
@ -15,13 +16,15 @@
icon="question-circle"
:label="$t('settings.email.labelNonce')"
/>
<template slot="footer">
<base-button class="submit-button" icon="check" :disabled="errors" type="submit" filled>
{{ $t('actions.save') }}
</base-button>
</template>
</ds-card>
<base-button
icon="check"
:disabled="errors"
type="submit"
filled
>
{{ $t('actions.save') }}
</base-button>
</base-card>
</template>
</ds-form>
</template>

View File

@ -1,29 +1,27 @@
<template>
<ds-card centered v-if="data">
<base-card v-if="data">
<transition name="ds-transition-fade">
<sweetalert-icon icon="info" />
</transition>
<ds-text v-html="submitMessage" />
</ds-card>
</base-card>
<ds-form v-else v-model="form" :schema="formSchema" @submit="submit">
<template slot-scope="{ errors }">
<ds-card :header="$t('settings.email.name')">
<base-card>
<h2 class="title">{{ $t('settings.email.name') }}</h2>
<ds-input
id="email"
model="email"
icon="envelope"
:label="$t('settings.email.labelEmail')"
/>
<template slot="footer">
<ds-space class="backendErrors" v-if="backendErrors">
<ds-text align="center" bold color="danger">{{ backendErrors.message }}</ds-text>
</ds-space>
<base-button icon="check" :disabled="errors" type="submit" filled>
{{ $t('actions.save') }}
</base-button>
</template>
</ds-card>
<ds-space class="backendErrors" v-if="backendErrors">
<ds-text align="center" bold color="danger">{{ backendErrors.message }}</ds-text>
</ds-space>
<base-button icon="check" :disabled="errors" type="submit" filled>
{{ $t('actions.save') }}
</base-button>
</base-card>
</template>
</ds-form>
</template>

View File

@ -1,5 +1,5 @@
<template>
<ds-card>
<base-card>
<transition name="ds-transition-fade">
<client-only>
<sweetalert-icon :icon="sweetAlertIcon" />
@ -34,7 +34,7 @@
</client-only>
</ds-space>
</template>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('settings.organizations.name')">
<base-card>
<h2 class="title">{{ $t('settings.organizations.name') }}</h2>
<hc-empty icon="tasks" message="Coming Soon…" />
</ds-card>
</base-card>
</template>
<script>

View File

@ -6,7 +6,8 @@
@input-valid="handleInputValid"
@submit="handleSubmitSocialMedia"
>
<ds-card :header="$t('settings.social-media.name')">
<base-card>
<h2 class="title">{{ $t('settings.social-media.name') }}</h2>
<ds-space v-if="socialMediaLinks" margin-top="base" margin="x-small">
<ds-list>
<ds-list-item v-for="link in socialMediaLinks" :key="link.id" class="list-item--high">
@ -62,7 +63,7 @@
</base-button>
</ds-space>
</ds-space>
</ds-card>
</base-card>
</ds-form>
</template>

View File

@ -1,11 +1,12 @@
<template>
<ds-card :header="$t('settings.privacy.name')">
<base-card>
<h2 class="title">{{ $t('settings.privacy.name') }}</h2>
<ds-space margin-bottom="small">
<input id="allow-shouts" type="checkbox" v-model="shoutsAllowed" />
<label for="allow-shouts">{{ $t('settings.privacy.make-shouts-public') }}</label>
</ds-space>
<base-button filled @click="submit" :disabled="disabled">{{ $t('actions.save') }}</base-button>
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,7 +1,8 @@
<template>
<ds-card :header="$t('settings.security.name')">
<base-card>
<h2 class="title">{{ $t('settings.security.name') }}</h2>
<change-password />
</ds-card>
</base-card>
</template>
<script>

View File

@ -1,27 +1,21 @@
<template>
<ds-container width="medium">
<ds-card icon="balance-scale" :header="$t(`termsAndConditions.newTermsAndConditions`)" centered>
<p>
<nuxt-link :to="{ name: 'terms-and-conditions' }" target="_blank">
<base-button>
{{ $t(`termsAndConditions.termsAndConditionsNewConfirmText`) }}
</base-button>
</nuxt-link>
</p>
<ds-text>
<input id="checkbox" type="checkbox" v-model="checked" :checked="checked" />
<label
for="checkbox"
v-html="$t('termsAndConditions.termsAndConditionsNewConfirm')"
></label>
</ds-text>
<template slot="footer">
<base-button filled @click="submit" :disabled="!checked">
{{ $t(`actions.save`) }}
<ds-container width="medium" class="terms-and-conditions-confirm">
<base-card>
<base-icon name="balance-scale" />
<h2 class="title">{{ $t(`termsAndConditions.newTermsAndConditions`) }}</h2>
<nuxt-link :to="{ name: 'terms-and-conditions' }" target="_blank">
<base-button>
{{ $t(`termsAndConditions.termsAndConditionsNewConfirmText`) }}
</base-button>
</template>
</ds-card>
</nuxt-link>
<label for="checkbox">
<input id="checkbox" type="checkbox" v-model="checked" :checked="checked" />
{{ $t('termsAndConditions.termsAndConditionsNewConfirm') }}
</label>
<base-button filled @click="submit" :disabled="!checked">
{{ $t(`actions.save`) }}
</base-button>
</base-card>
</ds-container>
</template>
@ -91,3 +85,17 @@ export default {
},
}
</script>
<style lang="scss">
.terms-and-conditions-confirm > .base-card {
height: 280px;
display: flex;
flex-direction: column;
align-items: center;
justify-content: space-between;
> .base-icon {
font-size: $font-size-xxx-large;
}
}
</style>