refactor(platform): 统一控件 - 收敛下拉选择与按钮输入交互样式

This commit is contained in:
ddcat666 committed 2026-09-25 00:01:09 +08:00
1 parent c0d223f357
commit 8a691f76c9
61 files changed
+661 -237

No files matched your search

+28
View File
@@ -0,0 +1,28 @@
/* 鼠标点击后 Chrome 仍可能给按钮 :focus-visible。统一按钮只在键盘导航时显示焦点。 */
:where(button, .ant-btn):focus:not(:focus-visible),
:where(button, .ant-btn):focus-visible:not([data-input-modality="keyboard"]) {
outline: none !important;
box-shadow: none !important;
}
:where(button, .ant-btn):focus-visible[data-input-modality="keyboard"] {
outline: 1px solid color-mix(in srgb, var(--foreground) 36%, transparent) !important;
outline-offset: 1px !important;
box-shadow: none !important;
}
/* 带文字的按钮不要贴着左边缘。纯图标按钮保持正方形,不额外加水平内边距。 */
:where(button:not(.ant-btn-icon-only), .ant-btn:not(.ant-btn-icon-only)):not(:has(> svg:only-child)) {
padding-inline: max(12px, var(--space-3));
}
.ant-select.app-unified-select[data-input-modality="keyboard"]:not(.ant-select-open) {
outline: none !important;
box-shadow: none !important;
}
.ant-select.app-unified-select .ant-select-content,
.ant-select.app-unified-select .ant-select-selection-item,
.ant-select.app-unified-select .ant-select-placeholder {
padding-inline-start: 10px !important;
}