document the single UI stack and strengthen resize focus coverage
This commit is contained in:
1 parent
5c2342d4c5
commit
ec918674ee
5 files changed
+20
-4
No files matched your search
@@ -1,5 +1,5 @@
|
||||
<script setup>
|
||||
/** 复用 PrimeVue 的密码/反馈状态,只统一原生输入语义与可键盘访问的显隐操作。 */
|
||||
/** 复用 OpenVue 的密码/反馈状态,只统一原生输入语义与可键盘访问的显隐操作。 */
|
||||
import { computed, nextTick, ref, useSlots } from "vue";
|
||||
import Password from "openvue/password";
|
||||
|
||||
@@ -22,7 +22,7 @@ const nativeProps = computed(() => ({
|
||||
const toggleButton = ref(null);
|
||||
async function togglePassword(callback) {
|
||||
callback();
|
||||
// PrimeVue切换两个显隐slot时会替换按钮;把焦点交回新按钮,键盘才能连续显示/隐藏。
|
||||
// OpenVue切换两个显隐slot时会替换按钮;把焦点交回新按钮,键盘才能连续显示/隐藏。
|
||||
await nextTick();
|
||||
toggleButton.value?.focus();
|
||||
}
|
||||
@@ -71,7 +71,7 @@ async function togglePassword(callback) {
|
||||
.password-field {
|
||||
--password-toggle-size: 44px;
|
||||
}
|
||||
/* PrimeVue公开的输入样式类位于子组件内;操作宽度与逻辑末端留白必须同源,避免文字被按钮截获。 */
|
||||
/* OpenVue公开的输入样式类位于子组件内;操作宽度与逻辑末端留白必须同源,避免文字被按钮截获。 */
|
||||
.password-field:has(.password-toggle) :deep(.p-password-input) {
|
||||
padding-inline-end: calc(
|
||||
var(--password-toggle-size) + var(--p-form-field-padding-x)
|
||||
|
||||
Reference in new issue
Block a user