blob: f06d48ee4f54f4039cb163e791eacbabafa089c9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
<script>
import { mapState, mapGetters, mapActions } from 'vuex';
import { GlSkeletonLoader } from '@gitlab/ui';
import EditArea from './edit_area.vue';
export default {
components: {
EditArea,
GlSkeletonLoader,
},
computed: {
...mapState(['content', 'isLoadingContent']),
...mapGetters(['isContentLoaded']),
},
mounted() {
this.loadContent();
},
methods: {
...mapActions(['loadContent']),
},
};
</script>
<template>
<div class="d-flex justify-content-center h-100">
<div v-if="isLoadingContent" class="w-50 h-50 mt-2">
<gl-skeleton-loader :width="500" :height="102">
<rect width="500" height="16" rx="4" />
<rect y="20" width="375" height="16" rx="4" />
<rect x="380" y="20" width="120" height="16" rx="4" />
<rect y="40" width="250" height="16" rx="4" />
<rect x="255" y="40" width="150" height="16" rx="4" />
<rect x="410" y="40" width="90" height="16" rx="4" />
</gl-skeleton-loader>
</div>
<edit-area v-if="isContentLoaded" class="w-75 h-100 shadow-none" :value="content" />
</div>
</template>
|