Skip to content

Conversation

@pedrobonamin
Copy link
Contributor

@pedrobonamin pedrobonamin commented Jan 29, 2026

Description

Adds visual error styling (critical tone) to form inputs when they have validation errors. Inputs now display a red border/background when invalid.

Closes #11915

Updated inputs:

BooleanInput - Card gets critical tone on error

Screenshot 2026-01-29 at 09 13 31

SelectInput - Card/Radio gets critical tone on error

Screenshot 2026-01-29 at 09 14 10 Screenshot 2026-01-29 at 09 14 12

DateInput / DateTimeInput - Passes validationError to show native input validation

Screenshot 2026-01-29 at 09 15 22

ReferenceInput - Passes customValidity for native input validation

Screenshot 2026-01-29 at 09 15 12

ListArrayInput / GridArrayInput / ArrayOfPrimitivesInput - Container card gets critical tone on error

Screenshot 2026-01-29 at 09 15 56

What to review

  1. Trigger validation errors on different input types and verify the red styling appears
  2. Test with the validation test schema in the test studio

Testing

Manual testing with the test studio , through the validation document https://test-studio-git-gh-11915.sanity.dev/test/structure/input-debug;validationTest;86ca4c51-e3e1-4f7b-a78c-159096105523

Notes for release

Inputs now consistently display critical tones when they have validation errors.

@vercel
Copy link

vercel bot commented Jan 29, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
page-building-studio Ready Ready Preview, Comment Jan 29, 2026 8:17am
test-studio Ready Ready Preview, Comment Jan 29, 2026 8:17am
3 Skipped Deployments
Project Deployment Review Updated (UTC)
e2e-studio Ignored Ignored Jan 29, 2026 8:17am
studio-workshop Ignored Ignored Jan 29, 2026 8:17am
test-next-studio Ignored Ignored Jan 29, 2026 8:17am

Request Review

@github-actions
Copy link
Contributor

github-actions bot commented Jan 29, 2026

🧪 E2E Preview environment

🔑 Environment Variables for Local Testing

This is the preview URL for the E2E tests: https://e2e-studio-ckvvh000w.sanity.dev

To run the E2E tests locally, you can use the following environment variables, then run pnpm test:e2e --ui to open the Playwright test runner.

💬 Remember to build the project first with pnpm build:e2e.

  SANITY_E2E_PROJECT_ID=ittbm412
  SANITY_E2E_BASE_URL=https://e2e-studio-ckvvh000w.sanity.dev
  SANITY_E2E_DATASET="update depending the project you want to test (pr-12002-chromium-21470709348 || pr-12002-firefox-21470709348 )"
  SANITY_E2E_DATASET_CHROMIUM=pr-12002-chromium-21470709348
  SANITY_E2E_DATASET_FIREFOX=pr-12002-firefox-21470709348

@github-actions
Copy link
Contributor

github-actions bot commented Jan 29, 2026

📊 Playwright Test Report

Download Full E2E Report

This report contains test results, including videos of failing tests.

@github-actions
Copy link
Contributor

github-actions bot commented Jan 29, 2026

⚡️ Editor Performance Report

Updated Thu, 29 Jan 2026 08:29:07 GMT

Benchmark reference
latency of sanity@latest
experiment
latency of this branch
Δ (%)
latency difference
article (title) 35.7 efps (28ms) 40.0 efps (25ms) -3ms (-10.7%)
article (body) 50.8 efps (20ms) 52.9 efps (19ms) -1ms (-4.1%)
article (string inside object) 47.6 efps (21ms) 47.6 efps (21ms) +0ms (-/-%)
article (string inside array) 47.6 efps (21ms) 47.6 efps (21ms) +0ms (-/-%)
recipe (name) 99.9+ efps (9ms) 99.9+ efps (9ms) +0ms (-/-%)
recipe (description) 58.8 efps (17ms) 62.5 efps (16ms) -1ms (-5.9%)
recipe (instructions) 99.9+ efps (5ms) 99.9+ efps (5ms) -1ms (-/-%)
singleString (stringField) 99.9+ efps (5ms) 99.9+ efps (6ms) +1ms (-/-%)
synthetic (title) 62.5 efps (16ms) 58.8 efps (17ms) +1ms (+6.3%)
synthetic (string inside object) 71.4 efps (14ms) 58.8 efps (17ms) +3ms (+21.4%) 🔴

efps — editor "frames per second". The number of updates assumed to be possible within a second.

Derived from input latency. efps = 1000 / input_latency

Detailed information

🏠 Reference result

The performance result of sanity@latest

Benchmark latency p75 p90 p99 blocking time test duration
article (title) 28ms 31ms 40ms 77ms 57ms 7.8s
article (body) 20ms 24ms 46ms 102ms 281ms 5.4s
article (string inside object) 21ms 29ms 35ms 85ms 0ms 6.3s
article (string inside array) 21ms 23ms 30ms 75ms 0ms 6.5s
recipe (name) 9ms 13ms 16ms 34ms 0ms 4.9s
recipe (description) 17ms 20ms 23ms 38ms 0ms 4.3s
recipe (instructions) 5ms 9ms 10ms 25ms 0ms 3.0s
singleString (stringField) 5ms 8ms 13ms 23ms 0ms 4.3s
synthetic (title) 16ms 19ms 21ms 91ms 1200ms 9.1s
synthetic (string inside object) 14ms 19ms 32ms 97ms 1060ms 8.6s

🧪 Experiment result

The performance result of this branch

Benchmark latency p75 p90 p99 blocking time test duration
article (title) 25ms 29ms 37ms 101ms 36ms 7.4s
article (body) 19ms 22ms 27ms 82ms 246ms 5.2s
article (string inside object) 21ms 27ms 46ms 61ms 20ms 6.3s
article (string inside array) 21ms 24ms 29ms 50ms 6ms 6.3s
recipe (name) 9ms 12ms 20ms 47ms 9ms 5.1s
recipe (description) 16ms 18ms 21ms 35ms 0ms 4.2s
recipe (instructions) 5ms 7ms 8ms 17ms 0ms 2.9s
singleString (stringField) 6ms 9ms 11ms 40ms 31ms 4.4s
synthetic (title) 17ms 20ms 24ms 92ms 489ms 8.2s
synthetic (string inside object) 17ms 18ms 32ms 93ms 588ms 8.0s

📚 Glossary

column definitions

  • benchmark — the name of the test, e.g. "article", followed by the label of the field being measured, e.g. "(title)".
  • latency — the time between when a key was pressed and when it was rendered. derived from a set of samples. the median (p50) is shown to show the most common latency.
  • p75 — the 75th percentile of the input latency in the test run. 75% of the sampled inputs in this benchmark were processed faster than this value. this provides insight into the upper range of typical performance.
  • p90 — the 90th percentile of the input latency in the test run. 90% of the sampled inputs were faster than this. this metric helps identify slower interactions that occurred less frequently during the benchmark.
  • p99 — the 99th percentile of the input latency in the test run. only 1% of sampled inputs were slower than this. this represents the worst-case scenarios encountered during the benchmark, useful for identifying potential performance outliers.
  • blocking time — the total time during which the main thread was blocked, preventing user input and UI updates. this metric helps identify performance bottlenecks that may cause the interface to feel unresponsive.
  • test duration — how long the test run took to complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant