docs: explain configuration inputs and authentication components
This commit is contained in:
1 parent
dc32a74d7a
commit
3a53d2e58f
19 files changed
+72
No files matched your search
@@ -1,4 +1,5 @@
|
||||
<script>
|
||||
/** 磁盘容量选择卡:options 定义离散值或步长区间,v-model 保存容量,change 通知父级重算报价。 */
|
||||
import "~/assets/styles/ConfigDiskCard.Dx9IqqQ_.css";
|
||||
import { nextTick } from "vue";
|
||||
import { toDisplayString } from "vue";
|
||||
@@ -96,6 +97,7 @@ var m = {
|
||||
: `容量 ${T.value}–${E.value} ${S.unit}`,
|
||||
);
|
||||
function A(e) {
|
||||
// 在所有有效区间中寻找最近合法档位,不能只按全局 min/max 截断后提交任意数值。
|
||||
let t = T.value,
|
||||
n = 1 / 0;
|
||||
for (let r of w.value) {
|
||||
@@ -127,6 +129,7 @@ var m = {
|
||||
(C(`update:modelValue`, n), t && C(`change`));
|
||||
}
|
||||
function M(e) {
|
||||
// 拖动时更新容量但不逐帧重算;结束交互由 N 单独发出 change。
|
||||
let t = e.target,
|
||||
n = Number(t.value);
|
||||
(j(n, !1), (t.value = String(A(n))));
|
||||
@@ -135,6 +138,7 @@ var m = {
|
||||
!S.disabled && !D.value && C(`change`);
|
||||
}
|
||||
function P(e) {
|
||||
// 方向键跨区间寻找下一合法档位,避免跨越不允许购买的容量空档。
|
||||
let t = [`ArrowRight`, `ArrowUp`].includes(e.key)
|
||||
? 1
|
||||
: [`ArrowLeft`, `ArrowDown`].includes(e.key)
|
||||
@@ -165,6 +169,7 @@ var m = {
|
||||
!S.disabled && S.removable && C(`remove`);
|
||||
}
|
||||
async function I(t) {
|
||||
// PrimeVue 完成内部输入更新后再同步合法值与 aria 状态,避免显示值和实际容量不一致。
|
||||
(await Promise.resolve(), await nextTick());
|
||||
let n = t.originalEvent.target;
|
||||
((n.value = String(O.value)),
|
||||
|
||||
Reference in new issue
Block a user