|
@@ -23,7 +23,13 @@
|
|
/>
|
|
/>
|
|
</div>
|
|
</div>
|
|
|
|
|
|
- <EditFixPoint v-if="edit" @quit="edit = null" v-model:text="edit.text" ref="dom" />
|
|
|
|
|
|
+ <EditFixPoint
|
|
|
|
+ v-if="edit"
|
|
|
|
+ @quit="edit = null"
|
|
|
|
+ v-model:text="edit.text"
|
|
|
|
+ ref="dom"
|
|
|
|
+ :key="edit.id"
|
|
|
|
+ />
|
|
</template>
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
<script setup lang="ts">
|
|
@@ -35,6 +41,12 @@ import ActionMenus from "@/components/group-button/index.vue";
|
|
import EditFixPoint from "@/components/edit-fix-point/index.vue";
|
|
import EditFixPoint from "@/components/edit-fix-point/index.vue";
|
|
|
|
|
|
const edit = ref<FixPoint>();
|
|
const edit = ref<FixPoint>();
|
|
|
|
+watchEffect(() => {
|
|
|
|
+ if (edit.value !== customMap.activeFixPoint) {
|
|
|
|
+ edit.value = null;
|
|
|
|
+ }
|
|
|
|
+});
|
|
|
|
+
|
|
const activeActionMenus = [
|
|
const activeActionMenus = [
|
|
{
|
|
{
|
|
key: "edit",
|
|
key: "edit",
|
|
@@ -45,6 +57,8 @@ const activeActionMenus = [
|
|
onClick() {
|
|
onClick() {
|
|
edit.value =
|
|
edit.value =
|
|
edit.value === customMap.activeFixPoint ? null : customMap.activeFixPoint;
|
|
edit.value === customMap.activeFixPoint ? null : customMap.activeFixPoint;
|
|
|
|
+
|
|
|
|
+ console.log(edit.value);
|
|
},
|
|
},
|
|
},
|
|
},
|
|
{
|
|
{
|