Skip to content

MWPW-205543 Copy Fields: Group CTAs as a blob - #1197

Open
Blainegunn wants to merge 11 commits into
mainfrom
MWPW-205543
Open

MWPW-205543 Copy Fields: Group CTAs as a blob #1197
Blainegunn wants to merge 11 commits into
mainfrom
MWPW-205543

Conversation

@Blainegunn

@Blainegunn Blainegunn commented Sep 1, 2026

Copy link
Copy Markdown
Contributor

Resolves https://jira.corp.adobe.com/browse/MWPW-205543
Copy/Paste all CTAs for Headless use cases.
3 Style variants supported: default/link, bold/primary, italics/secondary
Test Page

Screenshot 2026-09-02 at 10 23 39 AM Screenshot 2026-09-02 at 10 23 22 AM Screenshot 2026-09-02 at 10 23 15 AM

QA Checklist: https://wiki.corp.adobe.com/display/adobedotcom/M@S+Engineering+QA+Use+Cases

Please do the steps below before submitting your PR for a code review or QA

  • C1. Cover code with Unit Tests
  • C2. Add a Nala test (double check with #fishbags if nala test is needed)
  • C3. Verify all Checks are green (unit tests, nala tests)
  • C4. PR description contains working Test Page link where the feature can be tested
  • C5: you are ready to do a demo from Test Page in PR (bonus: write a working demo script that you'll use on Thursday, you can eventually put in your PR)
  • C.6 read your Jira one more time to validate that you've addressed all AC's and nothing is missing

🧪 Nala E2E Tests

Nala tests run automatically when you open this PR.

To run Nala tests again:

  1. Add the run nala label to this PR (in the right sidebar)
  2. Tests will run automatically on the current commit
  3. Any future commits will also trigger tests as long as the label remains

To stop automatic Nala tests:

  • Remove the run nala label

Note: Tests only run on commits if the run nala label is present. Add the label whenever you need tests to run on new changes.

Test URLs:

@aem-code-sync

aem-code-sync Bot commented Sep 1, 2026

Copy link
Copy Markdown

Hello, I'm the AEM Code Sync Bot and I will run some actions to deploy your branch.
In case there are problems, just click the checkbox below to rerun the respective action.

  • Re-sync branch
Commits

# Conflicts:
#	studio/src/editors/variation-utils.js
#	studio/src/mas-side-nav.js
#	web-components/dist/commerce.js
#	web-components/dist/mas-field.js
#	web-components/dist/mas.js
#	web-components/dist/merch-card.js
@codecov

codecov Bot commented Sep 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.82%. Comparing base (6729934) to head (38a5113).

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1197      +/-   ##
==========================================
+ Coverage   90.76%   90.82%   +0.06%     
==========================================
  Files         318      319       +1     
  Lines      101699   102055     +356     
==========================================
+ Hits        92304    92691     +387     
+ Misses       9395     9364      -31     
Files with missing lines Coverage Δ
studio/src/editors/merch-card-editor.js 88.02% <100.00%> (+0.02%) ⬆️
studio/src/editors/variation-utils.js 78.12% <100.00%> (+2.09%) ⬆️
studio/src/mas-side-nav.js 94.88% <100.00%> (+0.12%) ⬆️
studio/src/rte/link-variant-utils.js 100.00% <100.00%> (ø)
studio/src/rte/rte-field.js 84.85% <100.00%> (+0.66%) ⬆️
studio/src/rte/rte-link-editor.js 98.29% <100.00%> (+0.11%) ⬆️
web-components/src/hydrate.js 92.26% <100.00%> (+0.46%) ⬆️
web-components/src/mas-field.js 98.93% <100.00%> (+0.02%) ⬆️
web-components/src/variants/banner-blade.js 100.00% <100.00%> (ø)
web-components/src/variants/headless.css.js 100.00% <100.00%> (ø)
... and 2 more

... and 11 files with indirect coverage changes


Continue to review full report in Codecov by Harness.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6729934...38a5113. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

…review styling

Widen the 3-option CTA variant picker (Primary/Secondary/Link) from the
headless template to Marquee and Banner/Blade, and match the rendered
preview: gap between CTAs, a comma separator, and a subtle gray variant
label next to each button.
# Conflicts:
#	web-components/dist/mas.js
#	web-components/dist/merch-card-collection.js
#	web-components/dist/merch-card.js

@Roycethan Roycethan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@Blainegunn Feedbacks:

  1. CTA links are now not showing the commitment step/workflow in the editor and in the links:
Image

Expected:

Image

ON DA.live page:
Image

  1. Standalone CTA when copied they are rendering as 3 copies of CTA's with lost button styling ( See Buy now: and Free_trial:) in the page:
    https://main--da-cc--adobecom.aem.page/fragments/reuben/head-marquee?maslibs=mwpw-205543&milolibs=mwpw-205543
image

* CTAs with no real <strong>/<em> wrapper (see variation-utils.js#parseCtas). */
export function getCtaEmphasis(className) {
if (!className) return null;
if (className.includes('primary') && !className.includes('-link')) return 'bold';

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Returns null for accent, but resolveHeadlessDisplayVariant returns 'primary', copies without <strong>. whatabout? if (className.includes('accent')) return 'bold';

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

good catch

# Conflicts:
#	web-components/dist/mas.js
#	web-components/dist/merch-card-collection.js
#	web-components/dist/merch-card.js
@Roycethan

Copy link
Copy Markdown
Collaborator

@Blainegunn Feedbacks:

  1. CTA links are now not showing the commitment step/workflow in the editor and in the links:
Image Expected: Image ON DA.live page: Image
  1. Standalone CTA when copied they are rendering as 3 copies of CTA's with lost button styling ( See Buy now: and Free_trial:) in the page:
    https://main--da-cc--adobecom.aem.page/fragments/reuben/head-marquee?maslibs=mwpw-205543&milolibs=mwpw-205543
image

Fixed

@Roycethan
Roycethan self-requested a review September 3, 2026 22:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants