Changeset View
Changeset View
Standalone View
Standalone View
src/resources/vue/Widgets/Status.vue
<template> | <template> | ||||
<div v-if="!state.isReady" id="status-box" :class="'p-4 mb-3 rounded process-' + className"> | <div v-if="!state.isReady" id="status-box" :class="'p-4 mb-3 rounded process-' + className"> | ||||
<div v-if="state.step != 'domain-confirmed'" class="d-flex align-items-start"> | <div v-if="state.step != 'domain-confirmed'" class="d-flex align-items-start"> | ||||
<p id="status-body" class="flex-grow-1"> | <p id="status-body" class="flex-grow-1"> | ||||
<span v-if="scope == 'dashboard'">We are preparing your account.</span> | <span v-if="scope == 'dashboard'">{{ $t('status.prepare-account') }}</span> | ||||
<span v-else-if="scope == 'domain'">We are preparing the domain.</span> | <span v-else-if="scope == 'domain'">{{ $t('status.prepare-domain') }}</span> | ||||
<span v-else-if="scope == 'distlist'">We are preparing the distribution list.</span> | <span v-else-if="scope == 'distlist'">{{ $t('status.prepare-distlist') }}</span> | ||||
<span v-else>We are preparing the user account.</span> | <span v-else>{{ $t('status.prepare-user') }}</span> | ||||
<br> | <br> | ||||
Some features may be missing or readonly at the moment.<br> | {{ $t('status.prepare-hint') }} | ||||
<span id="refresh-text" v-if="refresh">The process never ends? Press the "Refresh" button, please.</span> | <br> | ||||
<span id="refresh-text" v-if="refresh">{{ $t('status.prepare-refresh') }}</span> | |||||
</p> | </p> | ||||
<button v-if="refresh" id="status-refresh" href="#" class="btn btn-secondary" @click="statusRefresh"> | <button v-if="refresh" id="status-refresh" href="#" class="btn btn-secondary" @click="statusRefresh"> | ||||
<svg-icon icon="sync-alt"></svg-icon> Refresh | <svg-icon icon="sync-alt"></svg-icon> {{ $t('btn.refresh') }} | ||||
</button> | </button> | ||||
</div> | </div> | ||||
<div v-else class="d-flex align-items-start"> | <div v-else class="d-flex align-items-start"> | ||||
<p id="status-body" class="flex-grow-1"> | <p id="status-body" class="flex-grow-1"> | ||||
<span v-if="scope == 'dashboard'">Your account is almost ready.</span> | <span v-if="scope == 'dashboard'">{{ $t('status.ready-account') }}</span> | ||||
<span v-else-if="scope == 'domain'">The domain is almost ready.</span> | <span v-else-if="scope == 'domain'">{{ $t('status.ready-domain') }}</span> | ||||
<span v-else-if="scope == 'distlist'">The distribution list is almost ready.</span> | <span v-else-if="scope == 'distlist'">{{ $t('status.ready-distlist') }}</span> | ||||
<span v-else>The user account is almost ready.</span> | <span v-else>{{ $t('status.ready-user') }}</span> | ||||
<br> | <br> | ||||
Verify your domain to finish the setup process. | {{ $t('status.verify') }} | ||||
</p> | </p> | ||||
<div v-if="scope == 'domain'"> | <div v-if="scope == 'domain'"> | ||||
<button id="status-verify" class="btn btn-secondary text-nowrap" @click="confirmDomain"> | <button id="status-verify" class="btn btn-secondary text-nowrap" @click="confirmDomain"> | ||||
<svg-icon icon="sync-alt"></svg-icon> Verify | <svg-icon icon="sync-alt"></svg-icon> {{ $t('btn.verify') }} | ||||
</button> | </button> | ||||
</div> | </div> | ||||
<div v-else-if="state.link && scope != 'domain'"> | <div v-else-if="state.link && scope != 'domain'"> | ||||
<router-link id="status-link" class="btn btn-secondary" :to="{ path: state.link }">Verify domain</router-link> | <router-link id="status-link" class="btn btn-secondary" :to="{ path: state.link }">{{ $t('status.verify-domain') }}</router-link> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
<div class="status-progress text-center"> | <div class="status-progress text-center"> | ||||
<div class="progress"> | <div class="progress"> | ||||
<div class="progress-bar" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div> | <div class="progress-bar" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100"></div> | ||||
</div> | </div> | ||||
<span class="progress-label">{{ state.title || 'Initializing...' }}</span> | <span class="progress-label">{{ state.title || $t('msg.initializing') }}</span> | ||||
</div> | </div> | ||||
</div> | </div> | ||||
</template> | </template> | ||||
<script> | <script> | ||||
export default { | export default { | ||||
props: { | props: { | ||||
status: { type: Object, default: () => {} } | status: { type: Object, default: () => {} } | ||||
▲ Show 20 Lines • Show All 155 Lines • Show Last 20 Lines |