Show alert when there are no comments.
authorAlexandre Segura <mex.zktk@gmail.com>
Mon, 20 Feb 2017 19:52:22 +0100
changeset 328 c23659daa42d
parent 327 44a122f0f2de
child 329 3d9fc1b920ec
Show alert when there are no comments.
src_js/iconolab-bundle/src/components/editor/CommentList.vue
--- a/src_js/iconolab-bundle/src/components/editor/CommentList.vue	Mon Feb 20 19:05:48 2017 +0100
+++ b/src_js/iconolab-bundle/src/components/editor/CommentList.vue	Mon Feb 20 19:52:22 2017 +0100
@@ -1,6 +1,7 @@
 <template>
-    <div v-show="comments.length > 0">
+    <div v-show="annotation">
         <label class="form-label">Commentaires</label>
+        <div v-show="comments.length === 0" class="alert alert-info">Pas de commentaire pour le moment.</div>
         <comment
             v-for="comment in comments"
             v-bind:comment="comment.comment"
@@ -40,3 +41,10 @@
     }
 
 </script>
+
+<style scoped>
+.alert {
+    padding: 10px;
+    font-size: 12px;
+}
+</style>