diff --git a/src/components/ui/VnImg.vue b/src/components/ui/VnImg.vue
index 2d3f5758..af078d6a 100644
--- a/src/components/ui/VnImg.vue
+++ b/src/components/ui/VnImg.vue
@@ -53,6 +53,10 @@ const props = defineProps({
editImageName: {
type: String,
default: ''
+ },
+ alwaysShowEditButton: {
+ type: Boolean,
+ default: false
}
});
@@ -69,9 +73,10 @@ const url = computed(() => {
v-if="props.editable"
icon="add_a_photo"
class="show-edit-button absolute-top-left"
+ :class="{ hide: !props.alwaysShowEditButton }"
round
text-color="black"
- @click.stop="showEditForm = !showEditForm"
+ @click.stop.prevent="showEditForm = !showEditForm"
/>
+ >
+
+
+
+
+
+
@@ -102,7 +115,7 @@ const url = computed(() => {
@@ -127,8 +140,11 @@ const url = computed(() => {
min-width: 50px;
}
-.show-edit-button {
+.hide {
visibility: hidden;
+}
+
+.show-edit-button {
cursor: pointer;
background-color: $gray-light;
z-index: 1;
diff --git a/src/pages/Admin/NewsDetails.vue b/src/pages/Admin/NewsDetails.vue
index a7813652..b569ecf6 100644
--- a/src/pages/Admin/NewsDetails.vue
+++ b/src/pages/Admin/NewsDetails.vue
@@ -97,6 +97,7 @@ onMounted(async () => {
rounded
editable
edit-schema="catalog"
+ always-show-edit-button
/>