Skip to content

feat(app-builder): add Content Hub UI extension support (scaffold, UI patterns, deploy) - #372

Open
saksbhardwaj wants to merge 18 commits into
adobe:mainfrom
saksbhardwaj:pr/262
Open

saksbhardwaj wants to merge 18 commits into
adobe:mainfrom
saksbhardwaj:pr/262

Conversation

@saksbhardwaj

@saksbhardwaj saksbhardwaj commented Sep 17, 2026

Copy link
Copy Markdown

Description

Adds first-class Content Hub UI extensibility support to the App Builder skills, so Claude Code can scaffold, build, and deploy a Content Hub extension for the unified aem/assets/contenthub/1 extension point from scratch. The work spans three skills:

  • appbuilder-project-init — scaffolds a complete Content Hub extension end-to-end (Console setup → file generation → npm installaio app use → build → dev server → open in Content Hub). Adds:
    • references/contenthub-scaffolding.md — the full interactive workflow (namespace selection, workspace/org resolution, cert page, auto-open).
    • references/contenthub-templates.md — every generated file (package.json, ext.config.yaml, App.js, ExtensionRegistration.js, Constants.js, per-namespace components, modals, actions).
    • SKILL.md wiring + evals.
  • appbuilder-ui-scaffolderreferences/aem-extensions.md documents the three Content Hub namespaces and their exact host contracts, plus SKILL.md and evals.
  • appbuilder-cicd-pipelinereferences/contenthub-deploy.md covers workspace switch, deploy, Extension Manager approval, and troubleshooting.

The three namespaces and their contracts (aligned with the host in AEM-Assets-Adobe/contenthub and the reference sample in adobe/aem-uix-examples PR #70):

  • assetDetails — custom tab panels in the Asset Details Dialog.
  • card — action buttons on asset cards and collection tiles. getActionButtons(actionContext) receives actionContext.context ('assets' | 'collections'); onActionClick(resourceType, buttonId, resourceId).
  • selectionBar — bulk action buttons. getActionButtons() (no args); onActionClick(buttonId, assetIds).

Constants export SourceType/ResourceType (two-value model), and the card/selection-bar modals follow Content Hub dialog conventions (heading + divider + labeled rows + right-aligned actions).

Related Issue

N/A — enhancement to the App Builder skill set for Content Hub extensibility.

Motivation and Context

Content Hub is a distinct App Builder extension point with contracts that differ from the other AEM surfaces (no sharedContext; openDialog takes a single config object; card/selectionBar gated by the EXTENSIBILITY_AEM_CONTENTHUB flag). Without dedicated skill guidance, scaffolds used the wrong signatures. These references encode the verified contracts so generated extensions match the live host and the reference sample.

How Has This Been Tested?

  • Scaffolded a Content Hub extension from the templates and verified aio app build succeeds and the extension registers against the live Content Hub host.
  • Verified all three namespaces render (asset-details panel, card actions on asset cards + collection tiles, selection-bar bulk actions) against the contenthub host build.
  • Cross-checked every namespace signature against the host (useExtensionCardActions / useExtensionBulkActionBar) and the reference sample (aem-uix-examples PR adobe-skills-issues-69 - updated package with Distributor #70).
  • evals.json for each skill updated and validated as parseable JSON.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have signed the Adobe Open Source CLA.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Naradasi Tejaswi and others added 8 commits July 9, 2026 16:08
Removed redundant line break in SKILL.md for clarity.
…e#70)

- card.getActionButtons(actionContext) now receives context ('assets' | 'collections');
  selectionBar.getActionButtons() takes no args — were previously documented backwards
- Constants.js template exports SourceType/ResourceType; ExtensionRegistration imports SourceType
- Card/SelectionBar modals restyled Content Hub-like (Heading + Divider + labeled rows,
  right-aligned Cancel/Done, colorScheme light) to match the sample
- Update ui-scaffolder eval to assert card getActionButtons(actionContext)

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
# Conflicts:
#	plugins/app-builder/skills/appbuilder-project-init/SKILL.md
#	plugins/app-builder/skills/appbuilder-project-init/evals/evals.json
@saksbhardwaj saksbhardwaj changed the title Pr/262 feat(app-builder): add Content Hub UI extension support (scaffold, UI patterns, deploy) Sep 17, 2026
saksbhardwaj and others added 2 commits September 18, 2026 02:00
The main-merge combined the rewritten description with the re-inserted Content
Hub sentence, pushing it to 1195 chars and failing `validate`. Condensed to
1007 chars while keeping the Content Hub scaffolding mention and key triggers.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…rop hand-written templates

Content Hub has no aio app init generator, so instead of maintaining a
hand-written 1051-line template + a dedicated scaffolding workflow + a deploy
reference (all duplicating the maintained sample), scaffold directly from the
sample app — the official documented path:

  aio app init --repo adobe/aem-uix-examples/aem-assets-contenthub-sample --github-pat <pat>

- Delete contenthub-templates.md, contenthub-scaffolding.md, contenthub-deploy.md
- Add a "Content Hub extension" entry to the templates.md catalog (scaffold cmd +
  post-init: extensionId, allowedRepos, namespace pruning, UI edit map, test URL,
  panel-not-visible troubleshooting, post-scaffold sanity check)
- Fold the Content Hub deploy delta into appbuilder-cicd-pipeline SKILL.md
- Repoint project-init SKILL.md + README to the catalog entry
- Rewrite the id:8 eval to assert the --repo scaffold flow

Single source of truth is now the sample (aem-uix-examples), eliminating drift.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…MyExchange admin

Earlier "no approval step for Content Hub" was wrong. UIX extensions (Content
Hub included) DO require approval, and it's the SAME flow for all surfaces:
local preview -> deploy Stage -> deploy Production -> Submit for approval in
Adobe Developer Console (Production workspace) -> org admin approves in
MyExchange (exchange.adobe.com) -> available to that org's Content Hub.
Re-deploy after publish needs revoke + new request. It's via MyExchange, NOT
Extension Manager.

Since it's identical across surfaces, replace the Content-Hub-specific deploy
section with a generic "Deploy & Approval (UI Extensions)" section in the
cicd skill; quick-ref row and project-init pointer point to it.

Also includes the --repo scaffold hardening (PAT prompt, clone/cp must wire
.aio/.env, workspace + allowedRepos prompts, test URL).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Re-apply the &repo= fix (kept getting reset). The Content Hub local preview URL
needs all four params — ext, devMode, repo (points at the delivery instance,
needed even with allowedRepos=[]), and the #/assets/contenthub/ hash:
  https://experience.adobe.com/?devMode=true&ext=https://localhost:9080&repo=<delivery-repo>#/assets/contenthub/
Fixed in templates.md, cicd SKILL.md, aem-extensions.md; told the agent not to
use the custom-apps or content-hub.html URLs.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

@mohitar1 mohitar1 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.

As discussed evals and approach needs to be re-visited

Comment thread plugins/app-builder/skills/appbuilder-cicd-pipeline/evals/evals.json Outdated
Comment thread plugins/app-builder/skills/appbuilder-cicd-pipeline/SKILL.md Outdated
saksbhardwaj and others added 2 commits September 21, 2026 15:47
Verified against the Content Hub host code: it reads the delivery repository from
the `repoId` URL param (userSettings.ts `externalParams.get('repoId')`), not
`repo`. The `repo` param is only the sample's own allowedRepos gate. Correct
local test URL:
  https://experience.adobe.com/?devMode=true&ext=https://localhost:9080&repoId=<delivery-repo>#/assets/contenthub/
Fixed in templates.md and aem-extensions.md.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
…/wrong test-URL note

- allowedRepos must contain each repo's FULL delivery hostname
  (delivery-pXXX-eYYY.adobeaemcloud.com) — the extension receives the full
  hostname, so a short form won't match allowedRepos.includes(repo) and
  registration is silently skipped (real gotcha hit during testing).
- aem-extensions.md: remove the wrong "No &repo= needed" note (repoId is always
  required to load the delivery instance) and a corrupted trailing fragment.
…uses

Remove Bash(mkdir|lsof|kill|open):* — the --repo/init.sh flow doesn't run these
directly (aio creates dirs; URLs are presented, not opened; lsof/kill only in one
rare port-in-use tip that can prompt). Add Edit for post-init file customization
(allowedRepos, extensionId, components). Net: Bash(aio|npm|node:*) Read Write Edit.
…he eval

Asset metadata is already built into Content Hub, so it's not a realistic custom
extension. Change the eval prompt to a real custom use case (submit asset to an
external review/approval workflow). Contract assertions unchanged.

This branch is waiting to be deployed

1 waiting deployment
eval cb06209f Waiting Sep 22, 2026 by saksbhardwaj via tessl-eval #855
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.

3 participants