diff --git a/web/components/SourcePicker.vue b/web/components/SourcePicker.vue index b1e14e8..ef978dd 100644 --- a/web/components/SourcePicker.vue +++ b/web/components/SourcePicker.vue @@ -175,12 +175,6 @@ function onFocusOut(event: FocusEvent) { font-size: var(--t-sm); } -/* 焦点态由整个框的描边表达,框里的输入不再自己画一圈 */ -.box input:focus, -.box input:focus-visible { - outline: none; -} - /* 浮在上面,不能把下面几行顶下去 */ .menu { position: absolute; diff --git a/web/styles/tokens.css b/web/styles/tokens.css index 05bd77b..ea89a2f 100644 --- a/web/styles/tokens.css +++ b/web/styles/tokens.css @@ -150,6 +150,14 @@ kbd, outline-offset: 2px; } +/* 文本输入的焦点态统一为描边变色,不叠外圈(订阅选择器的形态)。按钮保留外圈,那是键盘可达性 */ +input:focus-visible, +select:focus-visible, +textarea:focus-visible { + outline: none; + border-color: var(--c-accent); +} + /* 交互控件的颜色过渡。只过渡颜色类属性,不碰布局;时长以「感知得到但不等待」为准 */ button, input, diff --git a/web/views/InboundForm.vue b/web/views/InboundForm.vue index 4210318..b7b57ef 100644 --- a/web/views/InboundForm.vue +++ b/web/views/InboundForm.vue @@ -280,12 +280,6 @@ select { background-position: right var(--s-3) center; } -input:focus, -select:focus { - border-color: var(--c-accent); - outline: none; -} - .note { font-size: var(--t-xs); color: var(--c-text-faint); diff --git a/web/views/TokenGate.vue b/web/views/TokenGate.vue index 1a0d216..1df866c 100644 --- a/web/views/TokenGate.vue +++ b/web/views/TokenGate.vue @@ -62,11 +62,6 @@ h1 { background: var(--c-surface); } -.field:focus { - border-color: var(--c-accent); - outline: none; -} - .go { padding: var(--s-3) var(--s-4); border: 1px solid transparent;