Skip to content

Fix component kit lifecycle, overlays, and editor correctness - #588

Merged
blove merged 20 commits into
mainfrom
codex/component-kit-audit
Sep 9, 2026
Merged

Fix component kit lifecycle, overlays, and editor correctness#588
blove merged 20 commits into
mainfrom
codex/component-kit-audit

Conversation

@blove

@blove blove commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Complete the component-kit audit and repair its lifecycle, control, overlay and editor defects.

  • Prevent edits from saving before permission resolves or saving twice; recover from callback failures and ignore stale sessions.
  • Preserve canonical enum choices across duplicate labels, formatting and option changes; support clearing and composition-safe keyboard commands.
  • Retain commit direction through controlled-row acknowledgement, including delayed saves and cancellation. Calendar browsing now leaves the draft unchanged until an explicit choice.
  • Add native Textarea and route editor fields/actions through replacement slots with stable, cleanup-aware refs.
  • Repair Select roster/typeahead state, nested portal dismissal, explicit scoped overlay hosts, live popup anchoring, disabled and forced-color states.
  • Correct documentation, add regression/browser fixtures and recorded visual comparisons, and patch the two js-yaml versions flagged by the required security audit.

Validation

  • pnpm lint and pnpm format
  • pnpm test: 469 script tests and 4,522 workspace Vitest tests, including 2,043 React tests
  • pnpm typecheck plus public type tests and type-performance guard
  • Production website build; full workspace build checked before opening
  • pnpm api:check
  • pnpm lint:packaging; packed React 18.0.0, 18.3.1 and 19.2.8 compatibility
  • 34 focused Chromium/WebKit production checks, then all 14 editor checks repeated after the error-title addition
  • Direct Chrome MCP interaction, accessibility references, text selection and clean console
  • pnpm security:audit: no known vulnerabilities
  • Independent spec and quality reviews, including browser-discovered corrections

Physical OS IME and human screen-reader passes were not performed. Synthetic composition events, DOM/accessibility-tree inspection and forced-color emulation are recorded as automated evidence only. No benchmark performance claim is made.

Release Notes

  • Changesets added for the package behavior and public API changes.

Upgrade React and UI together. Rich Select labels now require textValue; active-option styling uses data-pretable-active. Configure PretableOverlayProvider with a host inside a local theme/direction scope when needed. Replacement fields must forward refs, native events, ARIA and data attributes. See updated component/editing docs for enum and date behavior changes and the new Textarea slot.

Screenshots Or Benchmarks

Matched production screenshots and measurements: docs/research/assets/sp4c/ and docs/research/assets/sp4d/. Audit and verification records: docs/research/2026-09-08-component-kit-audit.md and the SP4A–SP4D plans.

Contributor Checklist

  • I read CONTRIBUTING.md.
  • I followed CODE_OF_CONDUCT.md.
  • I am not disclosing a security vulnerability publicly; the dependency updates address an already-published advisory.

blove added 20 commits September 8, 2026 13:19
Reject ordinary draft writes during checking, validating, and saving while retaining editing/error changes and existing null and Object.is no-ops.

TDD: changed pending draft regressions failed in all three phases before the fix; all 177 grid-core tests pass after restoration. Mutation remove-pending-draft-phase-guard: removing the three status predicates fails checking/validating/saving preserves-the-entire-editing-state regressions (3 failed, 174 passed). Guard restored and formatted; final suite 177 passed.
Record permission and active session identity; guard callbacks and retries with a synchronous core draft barrier. Read live core state in the controller adapter and retain saving until controlled reconciliation.

Validation: 95 controller/editing/boolean tests; React typecheck; owned-file ESLint and Prettier. TDD: nine initial regressions plus formatter replacement failed before fixes. Five mutants killed: admission, permission denial, generation/session retirement, adapter identity, and core validating draft barrier.
Contain rejected parser results before validation/save and exercise successful recovery after callback failures and a failed replacement of an in-flight save.

Validation: 105 focused controller/editing/boolean tests, React typecheck, ESLint and Prettier. RED: 9 async parser regressions; removing parser await kills the same nine tests.
Consume pending commit keys and guard draft and enum selection changes. Defer enum seed normalization until editing and preserve later corrections.

Validation: 119 focused editor/surface tests, React typecheck, scoped ESLint and Prettier. RED regressions observed; pending-key, normalization-permission and correction mutants killed and restored.
Store callback cleanup for null detach while exposing a React 18-compatible void callback. Preserve composed hook identity for stable refs and integrate Checkbox/TextInput.

Validation: real-control RED regressions, helper null-detach contract, ref replacement and StrictMode, cleanup mutation killed and restored; 20 focused tests pass with Select integration tests pending root integration. Scoped lint/format clean.
@vercel

vercel Bot commented Sep 9, 2026

Copy link
Copy Markdown

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

1 Skipped Deployment
Project Deployment Actions Updated
pretable Ignored Ignored Sep 9, 2026 5:08am UTC

Request Review

@github-actions

github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

Vercel preview ready

Preview: https://pretable-ztutn7f86-cacheplane.vercel.app
Commit: e55d531bb799a248c98a5ac60c9043d8692f13cc

Updated automatically by the deploy-preview job.

@blove
blove merged commit 5d8e30a into main Sep 9, 2026
21 checks passed
@blove
blove deleted the codex/component-kit-audit branch September 9, 2026 05:27
@blove blove mentioned this pull request Sep 9, 2026
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