Skip to content

FORMS-26972: Enable hidden core components - #1969

Open
akshayvas wants to merge 6 commits into
devfrom
enable-comps
Open

akshayvas wants to merge 6 commits into
devfrom
enable-comps

Conversation

@akshayvas

@akshayvas akshayvas commented Aug 26, 2026 •

Copy link
Copy Markdown
Contributor

Description

Enables the hidden core components (switch, review, table, image choice) by fixing the ui.af.apps/pom.xml replacements, and fixes the issues found while enabling the review component and its tests.

Enablement

  • ui.af.apps/pom.xml: corrected the .core-adaptiveform replacement paths for switch and review (pointed at the version folder, now at the component node), and added or re-enabled table and imagechoice.
  • Review specs renamed from .spec.js to .cy.js so CI runs them (they never ran before).

Product fixes

  • Review rendered nothing in the basic test form: fd:linkedPanels held the panel id (tab1_id), but reviewview.js#getLinkedPanels matches on name. Test content now uses the panel name.
  • Wrong field focused on Edit of a repeated panel: the tab switch called focusToFirstVisibleField, whose setTimeout(0) overrode the correct focus with the first field of the tab (instance 1). FormPanel.js now skips this when focus is already inside the active tab.
  • Edit action default (Java): the "Field" default was intended but never implemented. ReviewImpl.getEditModeAction() returned null when fd:editModeAction was not authored (a Review dropped on a form and never saved from its dialog), so the model exported a null action and reviewview.js rendered no Edit buttons. It now falls back to "field".
  • Review dialog default: "Field" was always meant to be the default for "Enable edit mode actions for", but the dialog did not implement it. value="field" on the select does not mark an option as selected. The field option is now selected="{Boolean}true" and the select-level value is removed, so the dialog matches the Java default.
  • Edit button label i18n: the aria-label uses the form language (edit key added to the 10 runtime i18n files) instead of Granite.I18n, which is not available at publish.

Test fixes

  • review.repeatability.runtime.cy.js (checkSecondPanel, used by the 2nd and 4th tests):
    • What it did before: it expected the "All addres" panel, which wraps the repeatable Address panel, to render a label container and an Edit button, and failed on that assertion.
    • Why that was wrong: "All addres" has "Hide title" (hideTitle) checked, so its model exports label.visible = false and reviewview.js removes its label container, and with it the Edit button. The component works as designed. The test expectation was wrong.
    • Now: the test asserts that "All addres" has no label container (direct child only, using cy.root().children(...)), asserts its content wrapper exists, and checks the label and Edit button on the nested repeatable "Address" panel, which does have a visible label.
  • review.authoring.cy.js:
    • a jQuery element was passed where a selector string is required ("Recursion limit reached");
    • reviewPath was wrong, now tabsPath + "/review";
    • the configure dialog hid the toolbar, so Cancel is clicked before delete;
    • the drop zone is selected by path instead of :last.
  • ReviewImplTest: two new tests and fixtures (reviewDefaultAction, reviewPanelAction) cover the default and authored fd:editModeAction.

Related Issue

FORMS-26972

Motivation and Context

Some core components were hidden in the authoring UI and the review component tests were never executed. Enabling them exposed real runtime and test bugs, listed above.

How Has This Been Tested?

  • Local AEM 4502: all 13 review Cypress tests pass (authoring 1, repeatability 5, runtime 7).
  • mvn test -pl bundles/af-core -Dtest=ReviewImplTest: 7 tests, 0 failures.
  • CI: all checks pass on the latest run (build-java-11, build-java-21, both cypress-chrome-cloudready jobs, build-and-release). An earlier telephoneinput.authoring failure ("Recursion limit reached") was unrelated and passed on re-run.
  • The tabsontop, wizard and verticaltabs specs (affected by the FormPanel.js change) run in the CI Cypress jobs, which pass.

Screenshots (if appropriate):

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 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 and the overall coverage did not decrease.
  • All unit tests pass on CircleCi.
  • I ran all tests locally and they pass.

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

4 similar comments
@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
page-has-heading-one moderate
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

1 similar comment
@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@codecov

codecov Bot commented Oct 26, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
...components/internal/models/v1/form/ReviewImpl.java 0.00% 0 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

2 similar comments
@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
page-has-heading-one moderate
target-size serious

@adobe-bot

Copy link
Copy Markdown

Accessibility Violations Found

Id Impact
aria-required-attr critical
empty-heading minor
label-title-only serious
target-size serious

This branch has not been deployed

No deployments
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.

2 participants