st-comp 0.0.119 → 0.0.121

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "st-comp",
3
3
  "public": true,
4
- "version": "0.0.119",
4
+ "version": "0.0.121",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "vite",
@@ -5,7 +5,7 @@ import { InfoFilled } from "@element-plus/icons-vue";
5
5
  import { defaultShowConfig } from "./tools";
6
6
  import { debounce } from "st-func";
7
7
 
8
- const segmentedValue = ref(null);
8
+ const segmentedValue = ref("ruleForm");
9
9
  const visible = defineModel("visible", { default: false });
10
10
  const emit = defineEmits(["add", "delete", "enabled", "closed", "shortcutAdd", "shortcutDelete"]);
11
11
  const props = defineProps({
@@ -161,6 +161,9 @@ watch(
161
161
  segmentedValue.value = props.allowOperation ? "ruleForm" : "table";
162
162
  handleResetForm();
163
163
  }
164
+ },
165
+ {
166
+ immediate: true,
164
167
  }
165
168
  );
166
169
  </script>
@@ -265,36 +268,35 @@ watch(
265
268
  label="预警次数:"
266
269
  prop="totalCount"
267
270
  >
268
- <el-input-number
269
- v-model="ruleForm.totalCount"
270
- :min="1"
271
- controls-position="right"
272
- style="margin-right: 20px"
273
- />
274
- <template v-if="shortcutData.length">
275
- <el-button
276
- v-for="item in shortcutData"
277
- :key="item.id"
278
- @click="handleFastControls(item)"
271
+ <div style="display: flex; align-items: start">
272
+ <el-input-number
273
+ v-model="ruleForm.totalCount"
274
+ :min="1"
275
+ controls-position="right"
276
+ style="margin-right: 20px"
277
+ />
278
+ <div
279
+ v-if="shortcutData.length"
280
+ style="flex: 1"
279
281
  >
280
- {{ item.shortcutName }}
281
- </el-button>
282
- <el-tooltip
283
- effect="dark"
284
- content="通过快捷配置添加的因子有效预警次数上限为10"
285
- placement="right-start"
282
+ <el-button
283
+ v-for="item in shortcutData"
284
+ :key="item.id"
285
+ @click="handleFastControls(item)"
286
+ style="margin: 0 12px 4px 0"
287
+ >
288
+ {{ item.shortcutName }}
289
+ </el-button>
290
+ </div>
291
+ <el-text
292
+ v-else
293
+ type="primary"
294
+ style="cursor: pointer"
295
+ @click="() => (segmentedValue = 'shortcut')"
286
296
  >
287
- <el-icon style="margin-left: 10px"><InfoFilled /></el-icon>
288
- </el-tooltip>
289
- </template>
290
- <el-text
291
- v-else
292
- type="primary"
293
- style="cursor: pointer"
294
- @click="() => (segmentedValue = 'shortcut')"
295
- >
296
- 暂无快捷配置, 是否点击前往自定义配置?
297
- </el-text>
297
+ 暂无快捷配置, 是否点击前往自定义配置?
298
+ </el-text>
299
+ </div>
298
300
  </el-form-item>
299
301
  <!-- 价格范围 -->
300
302
  <el-form-item