瀏覽代碼

fix(word): update

gemercheung 1 年之前
父節點
當前提交
058c113219
共有 2 個文件被更改,包括 12 次插入16 次删除
  1. 10 15
      src/components/single-input.vue
  2. 2 1
      src/view/pano/pano.vue

+ 10 - 15
src/components/single-input.vue

@@ -1,17 +1,7 @@
 <template>
-  <el-dialog
-    :model-value="visible"
-    @update:model-value="(val) => emit('update:visible', val)"
-    :title="title"
-    width="500"
-  >
-    <el-input
-      v-model.trim="ivalue"
-      :maxlength="100"
-      show-word-limit
-      type="textarea"
-      placeholder="请输入"
-    />
+  <el-dialog :model-value="visible" @update:model-value="(val) => emit('update:visible', val)" :title="title"
+    width="500">
+    <el-input v-model.trim="ivalue" :maxlength="100" show-word-limit type="textarea" :placeholder="placeholder" />
     <template #footer>
       <div class="dialog-footer">
         <el-button @click="emit('update:visible', false)">取消</el-button>
@@ -25,12 +15,17 @@
 import { ElMessage } from "element-plus";
 import { ref, watchEffect } from "vue";
 
-const props = defineProps<{
+
+
+const props = withDefaults(defineProps<{
   visible: boolean;
   value: string;
   title: string;
+  placeholder: string;
   updateValue: (value: string) => void;
-}>();
+}>(), {
+  placeholder: '请输入',
+})
 const emit = defineEmits<{
   (e: "update:visible", visible: boolean): void;
 }>();

+ 2 - 1
src/view/pano/pano.vue

@@ -35,7 +35,8 @@
     @update:visible="update = false"
     :value="point.name || ''"
     :update-value="tex => updateScenePointName(point!, tex)"
-    title="修改点位名称"
+    title="测点说明"
+    placeholder="请填写测点说明"
   />
 </template>