a2ui-project / a2ui-project/a2ui

fix(docs): Catalog composition examples in catalogs.md use invalid allOf under components

Abierto
#2,219 0 comentarios 0 reacciones 0 asignados Ver en GitHub
component: specification P2 status: first-line-handled type: documentation
Lenguaje dominante
TypeScript
Estrellas
16.4k
Forks
1.3k
Merge medio
2 d 13 h
PR fusionados (30 d)
134

Descripción

## Problem Page(s)

- `docs/public/concepts/catalogs.md` (Sections: "#### Example: Extending the Basic Catalog" and "#### Example: Cherry-picking Components")

## Describe the Issue

In `docs/public/concepts/catalogs.md`, the documentation examples for catalog composition and imports show an `"allOf"` key with an array value placed directly under the `"components"` map:

```json
{
"$id": "https://github.com/.../hello_world_with_all_basic/v1/catalog.json",
"catalogId": "https://github.com/.../hello_world_with_all_basic/v1/catalog.json",
"components": {
"allOf": [
{"$ref": "basic_catalog_definition.json#/components"},
{
"SuggestionChips": {
"type": "object",
...
}
}
]
}
}
```

In the A2UI Catalog Schema definition (`specification/v1_0/json/catalog_definition.json` and protocol specs), `components` is defined as an object where each property name is a component type and its value must be a valid JSON Schema:

```json
"components": {
"type": "object",
"description": "Definitions for UI components supported by this catalog.",
"additionalProperties": {
"$ref": "https://json-schema.org/draft/2020-12/schema"
}
}
```

Placing `"allOf": [...]` inside `components` fails JSON Schema validation against the Catalog meta-schema because:
1. `"allOf"` is treated as a component name rather than a JSON Schema composition keyword.
2. The value is an array, which is not a valid JSON Schema object.

## Proposed Changes

Update the catalog composition examples in `docs/public/concepts/catalogs.md` to reflect valid schema syntax (e.g. structuring composition at the root catalog schema level, or demonstrating valid multi-catalog linking patterns).

## Additional Context

Flagged during review of #2184.

Guía de contribución

Abrir la guía de contribución

Evaluación

Este issue todavía no se ha evaluado.

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.