Use draft-07 consistently in backend and frontend.

Aligns the PHP and JS JSON-Schema validators on draft-07:

  • composer.json — bumps justinrainbow/json-schema from ^6.6.2 to ^6.8.0 (draft-07 support landed in 6.8).
  • src/CanvasServiceProvider.php — calls setDefaultDialect(DraftIdentifiers::DRAFT_7) on the JsonSchema\Constraints\Factory service definition. Without this the library defaults to draft-06.
  • ui/src/utils/ajv.ts (new) — shared createAjv() helper that builds an Ajv instance with defaultMeta: 'http://json-schema.org/draft-07/schema#' and layers in ajv-formats plus ajv-formats-draft2019. defaultMeta makes the dialect explicit at the construction site rather than relying on Ajv 8's built-in default. The draft-2019 package only adds string format validators (idn-email, iri, duration, …) — it does not change the dialect.
  • ui/src/components/form/formUtil.ts and ui/src/components/form/inputBehaviors.tsx — both now consume createAjv() instead of constructing new Ajv() directly, so the two call sites can no longer drift apart.

AI-Generated: Yes (Used Claude - Opus 4.7 to create MR).

Closes #3591028

Edited by Christian López Espínola

Merge request reports

Loading