diff --git a/app/components/elements/Button.module.css b/app/components/elements/Button.module.css index 21990bd92..9dccff3e5 100644 --- a/app/components/elements/Button.module.css +++ b/app/components/elements/Button.module.css @@ -21,8 +21,7 @@ .button[data-focus-visible], .button:focus-visible { - outline-style: solid; - outline-width: 2px; + outline: var(--field-focus-ring); outline-offset: 1px; } diff --git a/app/components/elements/DatePicker.module.css b/app/components/elements/DatePicker.module.css index 5518b7d01..3c5cb3ecc 100644 --- a/app/components/elements/DatePicker.module.css +++ b/app/components/elements/DatePicker.module.css @@ -34,6 +34,7 @@ } .button { + padding: 0; margin-inline-start: auto; background-color: transparent; border: none; @@ -41,6 +42,7 @@ } .icon { - fill: var(--color-text-high); - width: 17.5px; + color: var(--color-text-high); + width: var(--field-icon-width); + height: var(--field-icon-width); } diff --git a/app/components/elements/Switch.module.css b/app/components/elements/Switch.module.css index c37b4302d..542a312f9 100644 --- a/app/components/elements/Switch.module.css +++ b/app/components/elements/Switch.module.css @@ -19,26 +19,29 @@ background: var(--color-bg); border: var(--border-style); border-radius: calc(var(--radius-selector) * 2); + padding: 2px; + display: inline-grid; + justify-items: center; + grid-template-columns: 0fr 1fr 1fr; + transition: grid-template-columns 200ms; &:before { content: ""; - display: block; - margin: 2px; - width: calc(var(--height) - 8px); - height: calc(var(--height) - 8px); + height: 100%; aspect-ratio: 1 / 1; background: var(--color-border); border-radius: var(--radius-selector); - transition: transform 200ms; + grid-row-start: 1; + grid-column-start: 2; } } .root[data-selected] .indicator { background: var(--color-text-accent); border-color: var(--color-text-accent); + grid-template-columns: 1fr 1fr 0fr; &:before { - transform: translateX(calc(var(--height) * 0.75)); background: var(--color-text-inverse); } } diff --git a/app/features/components-showcase/routes/components.tsx b/app/features/components-showcase/routes/components.tsx index 0ebdc0130..7ee8c491f 100644 --- a/app/features/components-showcase/routes/components.tsx +++ b/app/features/components-showcase/routes/components.tsx @@ -2058,7 +2058,11 @@ function FormFieldsSection({ id }: { id: string }) { with Zod schemas that generate both UI and validation.
-