Skip to content

Gallery 2 schema resolver#57

Open
jgindin wants to merge 4 commits into
mainfrom
gallery-2-schema-resolver
Open

Gallery 2 schema resolver#57
jgindin wants to merge 4 commits into
mainfrom
gallery-2-schema-resolver

Conversation

@jgindin

@jgindin jgindin commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

Description

Adds CatalogSchemaResolver to recursively resolve allOf arrays and internal $defs schema references within catalog component definitions. Maps properties into clean type objects for tabular representation.

This is the 2nd in a series of PRs which culminates in a dynamically generated page to show the components of the current catalog:
image

Pre-launch Checklist

  • I signed the [CLA].
  • I read the [Contributors Guide].
  • I read the [Style Guide].
  • I have added updates to the [CHANGELOG].
  • I updated/added relevant documentation.
  • My code changes (if any) have tests.
  • If my branch is on fork, I have verified that scripts/e2e_test.sh passes.

jgindin added 3 commits June 19, 2026 16:17
Enables correct rendering of material icons inside the sandboxed preview
iframe running the ng-basic-catalog app.
* Use `QueryParser.` instead of `this.` when calling static functions
* Ensure returned config.json doesn't have "JSON hijacking" prefixes
Remove the showComponentsGallery signal to expose
the components gallery link in the primary navigation sidebar.
Adds test coverage checking link visibility using shell harnesses.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the CatalogSchemaResolver class to parse and resolve component properties from catalog schemas, along with comprehensive unit tests. It also makes the Components Gallery navigation link visible by default, updates related tests and harnesses, refactors QueryParser to use static calls, and enhances StartupResolution to strip JSON safety prefixes from fetched configurations. The code review feedback identifies several critical issues in the new CatalogSchemaResolver, including a potential prototype pollution vulnerability during JSON pointer resolution, incorrect merging of null and array types, potential prototype lookup bugs, and the need to strip $ref and allOf properties from resolved schemas.

Comment thread shell/src/app/gallery/schema/catalog-schema-resolver.ts
Comment thread shell/src/app/gallery/schema/catalog-schema-resolver.ts
Comment thread shell/src/app/gallery/schema/catalog-schema-resolver.ts
Comment thread shell/src/app/gallery/schema/catalog-schema-resolver.ts
Comment thread shell/src/app/gallery/schema/catalog-schema-resolver.ts
@github-actions

github-actions Bot commented Jun 19, 2026

Copy link
Copy Markdown
Contributor

⚡ A2UI Composer PR Preview

Your automated preview is successfully live:
👉 Launch PR Preview

Note: This environment will be wiped automatically when the PR is merged or closed.

@jgindin jgindin force-pushed the gallery-2-schema-resolver branch from bcb0d7d to c21b061 Compare June 19, 2026 21:17
@jgindin jgindin requested a review from sugoi-yuzuru June 19, 2026 21:20
Adds CatalogSchemaResolver to recursively resolve allOf arrays and
internal $defs schema references within catalog component definitions.
Maps properties into clean type objects for tabular representation.
@jgindin jgindin force-pushed the gallery-2-schema-resolver branch from c21b061 to 85edd26 Compare June 19, 2026 22:19
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