-
Notifications
You must be signed in to change notification settings - Fork 183
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MWPW-164660: [3-in-1][Milo] Implement a link converter for CTAs using an iFrame #3564
MWPW-164660: [3-in-1][Milo] Implement a link converter for CTAs using an iFrame #3564
Conversation
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## stage #3564 +/- ##
==========================================
- Coverage 96.53% 96.51% -0.03%
==========================================
Files 274 277 +3
Lines 61849 62209 +360
==========================================
+ Hits 59705 60039 +334
- Misses 2144 2170 +26 ☔ View full report in Codecov by Sentry. |
40e1011
to
b4bf8e9
Compare
libs/blocks/merch/threeInOne.js
Outdated
loading: 'lazy', | ||
class: 'loading', | ||
}); | ||
const pCircle = createTag('sp-progress-circle', { label: 'progress circle', indeterminate: true, size: 'l' }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think if the loading doesn't finish in certain amount of time, we should kill the spinner and show some kind of error message.
to be checked with Nick.
This pull request is not passing all required checks. Please see this discussion for information on how to get all checks passing. Inconsistent checks can be manually retried. If a test absolutely can not pass for a good reason, please add a comment with an explanation to the PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small request to remove checkout builder package from dependencies.
rest looks good to me
libs/blocks/merch/merch.js
Outdated
@@ -496,7 +497,13 @@ export async function openModal(e, url, offerType, hash, extraOptions) { | |||
const fragmentPath = url.split(/(hlx|aem).(page|live)/).pop(); | |||
modal = await openFragmentModal(fragmentPath, getModal); | |||
} else { | |||
modal = await openExternalModal(url, getModal, extraOptions); | |||
const isThreeInOneModal = [MODAL_TYPE_3_IN_1.CRM, MODAL_TYPE_3_IN_1.D2P, MODAL_TYPE_3_IN_1.TWP].includes(el?.getAttribute('data-modal-type')) && el?.href; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we add additional modal types we would need to maintain the code in two places. Why not use Object.values
to create an array from the values?
libs/blocks/merch/threeInOne.js
Outdated
document.querySelector('.three-in-one iframe')?.classList?.remove('loading'); | ||
document.querySelector('.three-in-one sp-theme')?.remove(); | ||
break; | ||
case MSG_SUBTYPE.EXTERNAL: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see the same action being executed for MSG_SUBTYPE.EXTERNAL
, MSG_SUBTYPE.SWITCH
, MSG_SUBTYPE.RETURN_BACK
. Maybe the code can be refactored a bit here.
libs/blocks/merch/merch.js
Outdated
@@ -496,7 +497,13 @@ export async function openModal(e, url, offerType, hash, extraOptions) { | |||
const fragmentPath = url.split(/(hlx|aem).(page|live)/).pop(); | |||
modal = await openFragmentModal(fragmentPath, getModal); | |||
} else { | |||
modal = await openExternalModal(url, getModal, extraOptions); | |||
const isThreeInOneModal = [MODAL_TYPE_3_IN_1.CRM, MODAL_TYPE_3_IN_1.D2P, MODAL_TYPE_3_IN_1.TWP].includes(el?.getAttribute('data-modal-type')) && el?.href; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The constants are part of merch, but the code looks like it could be any type of modal, without a direct connection to merch. We should either a) make this more explicit, b) make the modal types more general so they can be used outside of merch
scope.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The 'trial with purchase' (twp), 'direct to purchase' (d2p), and 'content rich modal' are the only three types of modals we have on catalog and plans pages, and all three are directly connected to merch context, because they are opened by clicking the checkout CTAs. I'm not sure we should make is more general, because this logic is relevant only for these three types of modals.
@@ -359,6 +386,13 @@ | |||
width: 80%; | |||
} | |||
|
|||
.dialog-modal.three-in-one { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see .dialog-modal.upgrade-flow-modal
has the exact properties, can we combine them somehow?
libs/blocks/merch/merch.css
Outdated
.three-in-one sp-theme { | ||
width: max-content; | ||
height: max-content; | ||
left: 50%; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would this handle RTL accordingly?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, corrected 👍
libs/blocks/merch/merch.js
Outdated
@@ -489,14 +490,28 @@ export async function openModal(e, url, offerType, hash, extraOptions) { | |||
const prevHash = window.location.hash.replace('#', '') === hash ? '' : window.location.hash; | |||
window.location.hash = hash; | |||
window.addEventListener('milo:modal:closed', () => { | |||
window.history.pushState({}, document.title, `#${prevHash}`); | |||
if (prevHash === '') { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not do something like
window.history.pushState({}, document.title, prevHash !== '' ? `#${prevHash}` : `${window.location.pathname}${window.location.search}`)
libs/blocks/merch/merch.js
Outdated
modal = await openExternalModal(url, getModal, extraOptions); | ||
const isThreeInOneModal = Object.values(MODAL_TYPE_3_IN_1).includes(el?.getAttribute('data-modal-type')) && el?.href; | ||
if (isThreeInOneModal) { | ||
const { default: openThreeInOneModal } = await import('./threeInOne.js'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Camel case for file naming seems odd. Please instead use kebab case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder whether we should be using Milo modal to display the 3-in-1 or use SWC to render the modal from MAS directly.
Thus, the integration will be re-usable outside adobe.com.
@mirafedas I don't know how much work is this, especially given the timelines.
this is just to start the reflection on it.
cc: @npeltier @3ch023
libs/blocks/merch/constants.js
Outdated
@@ -0,0 +1,7 @@ | |||
export const MODAL_TYPE_3_IN_1 = { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This constant is duplicated at https://github.com/adobecom/milo/pull/3564/files#diff-e91eb0b5a655ea856ec40025c1071fb88ac9908264c11f760b6208130e1099f0R106.
Wherever it is used, it should import it from mas feature.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to avoid confusion, I recommend to remove this file.
libs/blocks/merch/merch.js
Outdated
}, { once: true }); | ||
} | ||
if (isInternalModal(url)) { | ||
const fragmentPath = url.split(/(hlx|aem).(page|live)/).pop(); | ||
modal = await openFragmentModal(fragmentPath, getModal); | ||
} else { | ||
modal = await openExternalModal(url, getModal, extraOptions); | ||
const isThreeInOneModal = Object.values(MODAL_TYPE_3_IN_1).includes(el?.getAttribute('data-modal-type')) && el?.href; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this logic could be a helper function in MAS checkout-mixin some related files.
libs/blocks/merch/three-in-one.js
Outdated
|
||
export async function createContent(iframeUrl, modalType) { | ||
const { base } = getConfig(); | ||
await Promise.all([ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
these imports can go to top of the file.
this is blocking the loading for no reason IMO.
libs/blocks/merch/three-in-one.js
Outdated
const pCircle = createTag('sp-progress-circle', { label: 'progress circle', indeterminate: true, size: 'l' }); | ||
const theme = createTag('sp-theme', { theme: 'spectrum', color: 'light', scale: 'medium', dir: 'ltr' }); | ||
theme.append(pCircle); | ||
content.append(theme); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
dark theme support?
also since the markup being generated static, you could also do:
content.innerHTML = '<sp-theme ....>...</sp-theme>'
;
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I rewrote it to use .innerHTML, and regarding the dark theme - if support is needed, I can work on it in the scope of the follow-up tickets, because this has to be aligned with the commerce team, in the current task it is not mentioned, and it would be good to avoid adding more changes to this PR to get it merged before the RCP
libs/blocks/merch/three-in-one.js
Outdated
const modalType = el?.getAttribute('data-modal-type'); | ||
if (!modalType || !iframeUrl) return undefined; | ||
|
||
window.addEventListener('message', handle3in1IFrameEvents); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might we be registering more events that intended if the user closes / re-opens the modal?
I would register the even handler in the module scope, and ignore the messages if the modal is not open.
libs/blocks/modal/modal.css
Outdated
padding-bottom: 0; | ||
height: 100%; | ||
} | ||
|
||
.dialog-modal.commerce-frame.height-fit-content, .dialog-modal.dynamic-height.height-fit-content { | ||
.dialog-modal.commerce-frame.height-fit-content, | ||
.dialog-modal.dynamic-height.height-fit-content { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if this is only code formatting, I would omit these changes from your PR.
return modalParam; | ||
} | ||
} catch (error) { | ||
// do nothing |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
log using this.masElement.log
@@ -1,9 +1,4 @@ | |||
// This file aliases and re-exports commonly used external dependencies | |||
import { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❤️
be4444b
to
600c6e9
Compare
@yesil thank you for reviewing, I addressed all comments. Regarding the comment about rendering the modal as SWC directly from MAS - I would wait for the commerce team to develop their web component (as they mentioned at the meeting) |
content.innerHTML = `<sp-theme system="light" color="light" scale="medium" dir="ltr"> | ||
<sp-progress-circle label="progress circle" indeterminate="" size="l" dir="ltr" role="progressbar" aria-label="progress circle"></sp-progress-circle> | ||
</sp-theme> | ||
<iframe src="${iframeUrl}" title="${modalType === MODAL_TYPE_3_IN_1.CRM ? 'Single App' : modalType}" frameborder="0" marginwidth="0" marginheight="0" allowfullscreen="true" loading="lazy" class="loading" style="height: 100%;"></iframe>`; |
Check warning
Code scanning / CodeQL
DOM text reinterpreted as HTML Medium
DOM text
libs/features/mas/build.mjs
Outdated
@@ -38,6 +38,19 @@ await build({ | |||
outfile: `${outfolder}/mas.js`, | |||
}); | |||
|
|||
// constants.js | |||
await build({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not part of mas.js
tho? @mirafedas @npeltier @3ch023 @yesil
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, just one question and one recommendation, both trivial.
} catch (error) { | ||
this.masElement.log?.error('Failed to add 3-in-1 modal parameters', error); | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add a catch()
here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is already a catch statement here :)
This PR has not been updated recently and will be closed in 7 days if no action is taken. Please ensure all checks are passing, https://github.com/orgs/adobecom/discussions/997 provides instructions. If the PR is ready to be merged, please mark it with the "Ready for Stage" label. |
@Roycethan hi, could you please verify again? |
Post CLI fix reviewed https://mwpw-164660-3-in-1-modal--milo--mirafedas.hlx.page/drafts/mirafedas/3in1-test-page?martech=off twp: https://commerce.adobe.com/store/segmentation?ms=COM&ot=TRIAL&pa=phsp_direct_individual&cli=mini_plans&ctx=if&co=US&lang=en&af=uc_new_user_iframe%2Cuc_new_system_close Note: Loading time for content still takes a bit longer time , i think its already a known issue we know, spinner exist during load |
… an iFrame (#3564) * added 3-in-1 modal * moved event listener * updated tests * addressed comments * fixed unit test * moved constants.js into mas.js * added cli param
… Tab as Android (#3766) * [MWPW-159511] Create anchor (ID) elements (#3714) * [MWPW-159511] Create anchor (ID) elements * address feedback * address feedback * [MWPW-167031] top tooltip rtl fix (#3618) * [MWPW-167031] tooltip top rtl fix * [MWPW-167031] spacing corrections * [MWPW-167031] css optimization * [MWPW-167031] replaced css with js logic * [MWPW-167031] optimization * [MWPW-167031] optimization * MWPW-164492: Plans Card via MAS (#3649) * first draft * add callout * fix stock js issue * fix plans variant * remove sitemap * fix unit tests * add nala tests * MWPW-167305 [Plans Milo] Callout grey block: authoring improvement (#3663) Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> * use consonant cta for plans * add plans.md * fix review comments * fix merge issue * revert obsolete change * fix nala tests * address review comments * merge in stage * Fix regression * fix nala tests comments --------- Co-authored-by: Bozo Jovicic <37440641+bozojovicic@users.noreply.github.com> Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> * MWPW-160954 Marketo Multi-step (#3671) * MWPW-160954 Marketo Multi-step * PR Changes * QA Fixes * Next button fix * Adding support for first localnav menu being a dropdown (#3693) * Adding support for localnav item being a dropdown * Fix for button text * wip * Updating title for dropdown * Updating mock for localnav * Fixing button text * Lint fix * Replacing button text after copying * Lint fix * [MWPW-162639] youtube block a tag fix (#3703) * [MWPW-162639] youtube block a tag fix * [MWPW-162639] condition update * [MWPW-162639] clause fix * [MWPW-162639] code removal * Fix(mwpw-163031): Typo fix long-form (#3710) * new event added for autoplay videos * combining the fixe for 163031 * Update adobetv.js * Upgrading standalone gnav version to 0.0.5 (#3712) Upgrading gnav version to 0.0.5 * MWPW-167455: Remove node cloning (#3715) * MWPW-167455: Remove node cloning * MWPW-167455: Remove redundant code * MWPW-167455: Remove video test * MWPW-167455: Remove unnecessary code * MWPW-167455: Change test name * Add fix for galaxy tab * [MWPW-167349] - Added a default logo for the 'A' icon displayed on the right side of GNAV. (#3728) * Added default case adobe 'A' logo on right side for GNAV(Adobe logo block) * Added default case adobe 'A' logo on right side for GNAV(Adobe logo block) --------- Co-authored-by: Dev Ashish Sardana <glo77801@adobe.com> * MWPW-164660: [3-in-1][Milo] Implement a link converter for CTAs using an iFrame (#3564) * added 3-in-1 modal * moved event listener * updated tests * addressed comments * fixed unit test * moved constants.js into mas.js * added cli param * MWPW-167928 Override Marketo POI (#3702) * replace overflow x with contain layout (#3706) * replace overflow x with contain layout * add a fix for breaking mobile gnav * move fix to existing media block * [MWPW-168309] 2 small MEP button updates (#3719) * Revert "MWPW-140452 - Icon authoring in milo using the federal repo a… (#3357) Revert "MWPW-140452 - Icon authoring in milo using the federal repo and individual SVG assets (#3259)" This reverts commit 81a5770. * [Release] Stage to Main (#3497) MWPW-165774 [Mobile-GNAV] page is not scrollable in live page (#3495) * check for new nav when disabling ios scroll * shortened the check from the previous commit Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> * Initial checkin. * Remove white space. --------- Co-authored-by: milo-pr-merge[bot] <169241390+milo-pr-merge[bot]@users.noreply.github.com> Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com> Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> * MWPW-168334 Load georoutingv2.json and georoutingv2.js in parallel (#3720) * load georoutingv2.json in parallel with georoutingv2.js * remove performance marks * fixed unit tests * Small refactoring * fallback for the jsonPromise * fix unit tests * [MWPW-167309] - Table h tags replace (#3721) * [MWPW-167749] table h header replaced * [MWPW-167749] optimization * [MWPW-167749] naming changes * [MWPW-167749] optimization * [MWPW-167749] code optimization * [MWPW-167749] col role removal * [MWPW-167749] code style update * [MWPW-167309] code improvement * [MWPW-167309] - header role paragraph * MWPW-166176 - Stop initial tabs click propagation (#3726) * MWPW-166176 - Stop initial tabs click propagation * PR feedback --------- Co-authored-by: Ryan Clayton <rclayton@adobe.com> * Fix(mwpw-168006): Viewport bug fix. (#3730) viewport bug fix * Remove file overlap condition from merge to stage workflow (#3736) Remove file overlap condition * Revert "replace overflow x with contain layout" (#3776) Revert "replace overflow x with contain layout (#3706)" This reverts commit 0f54535. * Adding a class to convert group link title to a simple header instead of a link (#3769) Adding a class to convert group link title to a simple header instead of link * MWPW-164093: Adobe Home "Try Buy Widget" merch card (#3651) * MWPW-164093: Adobe Home 'Pricing Widget' merch card Co-Authored-By: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> * styles * cr fixes * refactored swc cta creation * wip * Revert "wip" This reverts commit ebede48. * wip * wip * wip * removed loading promise from race * tacocat update * new fragment mapping approach * typo fix * adobe home card improvements * Enhance merch card background and border color handling - Refactored background color processing to support custom color mapping - Updated border color processing to use CSS custom properties - Added more flexible color configuration for merch cards - Improved test coverage for color-related functions - Removed hardcoded color and border styling in favor of dynamic properties * truncate fixes * benchmarks duration update * truncation error handling * reubens comments * updated deps * unit test fix * data-href for event capture * Delete .cursor.zip * Update .gitignore * bubbled click event * dataset url * wip * Move SWC buttons to light DOM (#3734) * Move SWC buttons to light DOM * fix doc * css padding reset * remove .cursor rules * NALA tests * improved nala tests * lcp improvements on docs page * lcp improvements * Revert "lcp improvements" This reverts commit bb26697. * Revert "lcp improvements on docs page" This reverts commit 936cf14. * Update MAS package.json version * fixed nala tests * lint fixes * nala test title fixed * fixed test * conflicts resolved for the nth time * conflicts resolved * no source maps * right bg color for ah try card * sp-button analytics * data-analytics-id in sp-button * MWPW-169143: AH Try/Buy Widget sizing fixes * data-analytics-id on checkoutButton * version bump --------- Co-authored-by: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> Co-authored-by: astatescu <angelostatescu.adobe@gmail.com> Co-authored-by: Ilyas Türkben <tuerkben@adobe.com> Co-authored-by: Ilyas Türkben <ilyas@adobe.com> * [MWPW-167752] Loop focus in modals containing iframes (#3716) * MWPW-163228: Preflight svg issue (#3725) * WIP: Pushing just for preview purposes * Added messaging to clairfy the status of the SVG * Strange issues with dev tools, removing fetch to avoid possible CORS, adding external url to show authors where content lives * Updating tags and errortype for PEP lana logs (#3731) Lana log message fix * MWPW-151376: Check sharepoint url (#3733) * [MWPW-167759] Hero marquee bg-bottom-tablet fix (#3735) * MWPW-166689 Add video support to Article Header (#3737) * MWPW-163320 Gnav Promo CTA overflowing issue - BACOM Global Nav (#3739) * MWPW-163320 Gnav Promo CTA overflowing issue - BACOM Global Nav * apply fix specific to button inside feds promo --------- Co-authored-by: Narcis Radu <github@narcisradu.ro> Co-authored-by: Dušan Kosanović <dusan.kosanovic@hitthecode.com> Co-authored-by: Mariia Lukianets <lukianet@adobe.com> Co-authored-by: Bozo Jovicic <37440641+bozojovicic@users.noreply.github.com> Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> Co-authored-by: Brandon Marshall <bmarshal@adobe.com> Co-authored-by: Bandana Laishram <bandanalaishram@gmail.com> Co-authored-by: sharathkannan <138484653+sharath-kannan@users.noreply.github.com> Co-authored-by: Ratko Zagorac <90400759+zagi25@users.noreply.github.com> Co-authored-by: Dev Ashish Saradhana <41122199+Deva309@users.noreply.github.com> Co-authored-by: Dev Ashish Sardana <glo77801@adobe.com> Co-authored-by: Mira Fedas <30750556+mirafedas@users.noreply.github.com> Co-authored-by: Prince Patel <prpatel0949@gmail.com> Co-authored-by: Dave Linhart <132396886+AdobeLinhart@users.noreply.github.com> Co-authored-by: milo-pr-merge[bot] <169241390+milo-pr-merge[bot]@users.noreply.github.com> Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com> Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> Co-authored-by: Ryan Clayton <rgclayton@gmail.com> Co-authored-by: Ryan Clayton <rclayton@adobe.com> Co-authored-by: Axel Cureno Basurto <axelcureno@gmail.com> Co-authored-by: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> Co-authored-by: astatescu <angelostatescu.adobe@gmail.com> Co-authored-by: Ilyas Türkben <tuerkben@adobe.com> Co-authored-by: Ilyas Türkben <ilyas@adobe.com> Co-authored-by: Rares Munteanu <overmyheadandbody@gmail.com> Co-authored-by: Jason Slavin <slavin@adobe.com> Co-authored-by: Megan Thomas <methomas@adobe.com>
* [MEP][AJO] POC to integrate AJO with MEP (#3654) * Add ajo integration * Remove AJO references from pznv2 for now * Remove another ajo reference * revert formatting * Remove hard-coded url * Add tests for enabling ajo * MWPW-167217 [MEP] preserve hash in normalizePath (#3751) * Update normalizePath to retain hash * Revert change that will go in separate PR * Update tests * Update to align with getFederatedUrl * Refactor * MWPW-169117[MEP][MILO] Update Personalization Tabs to identity Galaxy Tab as Android (#3766) * [MWPW-159511] Create anchor (ID) elements (#3714) * [MWPW-159511] Create anchor (ID) elements * address feedback * address feedback * [MWPW-167031] top tooltip rtl fix (#3618) * [MWPW-167031] tooltip top rtl fix * [MWPW-167031] spacing corrections * [MWPW-167031] css optimization * [MWPW-167031] replaced css with js logic * [MWPW-167031] optimization * [MWPW-167031] optimization * MWPW-164492: Plans Card via MAS (#3649) * first draft * add callout * fix stock js issue * fix plans variant * remove sitemap * fix unit tests * add nala tests * MWPW-167305 [Plans Milo] Callout grey block: authoring improvement (#3663) Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> * use consonant cta for plans * add plans.md * fix review comments * fix merge issue * revert obsolete change * fix nala tests * address review comments * merge in stage * Fix regression * fix nala tests comments --------- Co-authored-by: Bozo Jovicic <37440641+bozojovicic@users.noreply.github.com> Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> * MWPW-160954 Marketo Multi-step (#3671) * MWPW-160954 Marketo Multi-step * PR Changes * QA Fixes * Next button fix * Adding support for first localnav menu being a dropdown (#3693) * Adding support for localnav item being a dropdown * Fix for button text * wip * Updating title for dropdown * Updating mock for localnav * Fixing button text * Lint fix * Replacing button text after copying * Lint fix * [MWPW-162639] youtube block a tag fix (#3703) * [MWPW-162639] youtube block a tag fix * [MWPW-162639] condition update * [MWPW-162639] clause fix * [MWPW-162639] code removal * Fix(mwpw-163031): Typo fix long-form (#3710) * new event added for autoplay videos * combining the fixe for 163031 * Update adobetv.js * Upgrading standalone gnav version to 0.0.5 (#3712) Upgrading gnav version to 0.0.5 * MWPW-167455: Remove node cloning (#3715) * MWPW-167455: Remove node cloning * MWPW-167455: Remove redundant code * MWPW-167455: Remove video test * MWPW-167455: Remove unnecessary code * MWPW-167455: Change test name * Add fix for galaxy tab * [MWPW-167349] - Added a default logo for the 'A' icon displayed on the right side of GNAV. (#3728) * Added default case adobe 'A' logo on right side for GNAV(Adobe logo block) * Added default case adobe 'A' logo on right side for GNAV(Adobe logo block) --------- Co-authored-by: Dev Ashish Sardana <glo77801@adobe.com> * MWPW-164660: [3-in-1][Milo] Implement a link converter for CTAs using an iFrame (#3564) * added 3-in-1 modal * moved event listener * updated tests * addressed comments * fixed unit test * moved constants.js into mas.js * added cli param * MWPW-167928 Override Marketo POI (#3702) * replace overflow x with contain layout (#3706) * replace overflow x with contain layout * add a fix for breaking mobile gnav * move fix to existing media block * [MWPW-168309] 2 small MEP button updates (#3719) * Revert "MWPW-140452 - Icon authoring in milo using the federal repo a… (#3357) Revert "MWPW-140452 - Icon authoring in milo using the federal repo and individual SVG assets (#3259)" This reverts commit 81a5770. * [Release] Stage to Main (#3497) MWPW-165774 [Mobile-GNAV] page is not scrollable in live page (#3495) * check for new nav when disabling ios scroll * shortened the check from the previous commit Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> * Initial checkin. * Remove white space. --------- Co-authored-by: milo-pr-merge[bot] <169241390+milo-pr-merge[bot]@users.noreply.github.com> Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com> Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> * MWPW-168334 Load georoutingv2.json and georoutingv2.js in parallel (#3720) * load georoutingv2.json in parallel with georoutingv2.js * remove performance marks * fixed unit tests * Small refactoring * fallback for the jsonPromise * fix unit tests * [MWPW-167309] - Table h tags replace (#3721) * [MWPW-167749] table h header replaced * [MWPW-167749] optimization * [MWPW-167749] naming changes * [MWPW-167749] optimization * [MWPW-167749] code optimization * [MWPW-167749] col role removal * [MWPW-167749] code style update * [MWPW-167309] code improvement * [MWPW-167309] - header role paragraph * MWPW-166176 - Stop initial tabs click propagation (#3726) * MWPW-166176 - Stop initial tabs click propagation * PR feedback --------- Co-authored-by: Ryan Clayton <rclayton@adobe.com> * Fix(mwpw-168006): Viewport bug fix. (#3730) viewport bug fix * Remove file overlap condition from merge to stage workflow (#3736) Remove file overlap condition * Revert "replace overflow x with contain layout" (#3776) Revert "replace overflow x with contain layout (#3706)" This reverts commit 0f54535. * Adding a class to convert group link title to a simple header instead of a link (#3769) Adding a class to convert group link title to a simple header instead of link * MWPW-164093: Adobe Home "Try Buy Widget" merch card (#3651) * MWPW-164093: Adobe Home 'Pricing Widget' merch card Co-Authored-By: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> * styles * cr fixes * refactored swc cta creation * wip * Revert "wip" This reverts commit ebede48. * wip * wip * wip * removed loading promise from race * tacocat update * new fragment mapping approach * typo fix * adobe home card improvements * Enhance merch card background and border color handling - Refactored background color processing to support custom color mapping - Updated border color processing to use CSS custom properties - Added more flexible color configuration for merch cards - Improved test coverage for color-related functions - Removed hardcoded color and border styling in favor of dynamic properties * truncate fixes * benchmarks duration update * truncation error handling * reubens comments * updated deps * unit test fix * data-href for event capture * Delete .cursor.zip * Update .gitignore * bubbled click event * dataset url * wip * Move SWC buttons to light DOM (#3734) * Move SWC buttons to light DOM * fix doc * css padding reset * remove .cursor rules * NALA tests * improved nala tests * lcp improvements on docs page * lcp improvements * Revert "lcp improvements" This reverts commit bb26697. * Revert "lcp improvements on docs page" This reverts commit 936cf14. * Update MAS package.json version * fixed nala tests * lint fixes * nala test title fixed * fixed test * conflicts resolved for the nth time * conflicts resolved * no source maps * right bg color for ah try card * sp-button analytics * data-analytics-id in sp-button * MWPW-169143: AH Try/Buy Widget sizing fixes * data-analytics-id on checkoutButton * version bump --------- Co-authored-by: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> Co-authored-by: astatescu <angelostatescu.adobe@gmail.com> Co-authored-by: Ilyas Türkben <tuerkben@adobe.com> Co-authored-by: Ilyas Türkben <ilyas@adobe.com> * [MWPW-167752] Loop focus in modals containing iframes (#3716) * MWPW-163228: Preflight svg issue (#3725) * WIP: Pushing just for preview purposes * Added messaging to clairfy the status of the SVG * Strange issues with dev tools, removing fetch to avoid possible CORS, adding external url to show authors where content lives * Updating tags and errortype for PEP lana logs (#3731) Lana log message fix * MWPW-151376: Check sharepoint url (#3733) * [MWPW-167759] Hero marquee bg-bottom-tablet fix (#3735) * MWPW-166689 Add video support to Article Header (#3737) * MWPW-163320 Gnav Promo CTA overflowing issue - BACOM Global Nav (#3739) * MWPW-163320 Gnav Promo CTA overflowing issue - BACOM Global Nav * apply fix specific to button inside feds promo --------- Co-authored-by: Narcis Radu <github@narcisradu.ro> Co-authored-by: Dušan Kosanović <dusan.kosanovic@hitthecode.com> Co-authored-by: Mariia Lukianets <lukianet@adobe.com> Co-authored-by: Bozo Jovicic <37440641+bozojovicic@users.noreply.github.com> Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> Co-authored-by: Brandon Marshall <bmarshal@adobe.com> Co-authored-by: Bandana Laishram <bandanalaishram@gmail.com> Co-authored-by: sharathkannan <138484653+sharath-kannan@users.noreply.github.com> Co-authored-by: Ratko Zagorac <90400759+zagi25@users.noreply.github.com> Co-authored-by: Dev Ashish Saradhana <41122199+Deva309@users.noreply.github.com> Co-authored-by: Dev Ashish Sardana <glo77801@adobe.com> Co-authored-by: Mira Fedas <30750556+mirafedas@users.noreply.github.com> Co-authored-by: Prince Patel <prpatel0949@gmail.com> Co-authored-by: Dave Linhart <132396886+AdobeLinhart@users.noreply.github.com> Co-authored-by: milo-pr-merge[bot] <169241390+milo-pr-merge[bot]@users.noreply.github.com> Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com> Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> Co-authored-by: Ryan Clayton <rgclayton@gmail.com> Co-authored-by: Ryan Clayton <rclayton@adobe.com> Co-authored-by: Axel Cureno Basurto <axelcureno@gmail.com> Co-authored-by: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> Co-authored-by: astatescu <angelostatescu.adobe@gmail.com> Co-authored-by: Ilyas Türkben <tuerkben@adobe.com> Co-authored-by: Ilyas Türkben <ilyas@adobe.com> Co-authored-by: Rares Munteanu <overmyheadandbody@gmail.com> Co-authored-by: Jason Slavin <slavin@adobe.com> Co-authored-by: Megan Thomas <methomas@adobe.com> --------- Co-authored-by: Mark Perry <124626043+markpadbe@users.noreply.github.com> Co-authored-by: Narcis Radu <github@narcisradu.ro> Co-authored-by: Dušan Kosanović <dusan.kosanovic@hitthecode.com> Co-authored-by: Mariia Lukianets <lukianet@adobe.com> Co-authored-by: Bozo Jovicic <37440641+bozojovicic@users.noreply.github.com> Co-authored-by: Bozo Jovicic <bozo@hitthecode.com> Co-authored-by: Brandon Marshall <bmarshal@adobe.com> Co-authored-by: Bandana Laishram <bandanalaishram@gmail.com> Co-authored-by: sharathkannan <138484653+sharath-kannan@users.noreply.github.com> Co-authored-by: Ratko Zagorac <90400759+zagi25@users.noreply.github.com> Co-authored-by: Dev Ashish Saradhana <41122199+Deva309@users.noreply.github.com> Co-authored-by: Dev Ashish Sardana <glo77801@adobe.com> Co-authored-by: Mira Fedas <30750556+mirafedas@users.noreply.github.com> Co-authored-by: Prince Patel <prpatel0949@gmail.com> Co-authored-by: Dave Linhart <132396886+AdobeLinhart@users.noreply.github.com> Co-authored-by: milo-pr-merge[bot] <169241390+milo-pr-merge[bot]@users.noreply.github.com> Co-authored-by: Okan Sahin <39759830+mokimo@users.noreply.github.com> Co-authored-by: Raghav Sharma <118168183+sharmrj@users.noreply.github.com> Co-authored-by: Ryan Clayton <rgclayton@gmail.com> Co-authored-by: Ryan Clayton <rclayton@adobe.com> Co-authored-by: Axel Cureno Basurto <axelcureno@gmail.com> Co-authored-by: Angelo Statescu <176400439+st-angelo-adobe@users.noreply.github.com> Co-authored-by: astatescu <angelostatescu.adobe@gmail.com> Co-authored-by: Ilyas Türkben <tuerkben@adobe.com> Co-authored-by: Ilyas Türkben <ilyas@adobe.com> Co-authored-by: Rares Munteanu <overmyheadandbody@gmail.com> Co-authored-by: Jason Slavin <slavin@adobe.com> Co-authored-by: Megan Thomas <methomas@adobe.com>
To display the content of the 3-in-1 modal, we replace the iFrame link from the checkout-link.xlsx file with a link to the appropriate commerce page that includes the segmentation step for the given offer. This replacement occurs only if the link contains the
modal=twp
,modal=crm
, ormodal=d2p
parameters.In the
threeInOne.js
module, we handle the communication protocol to respond to events emitted by the commerce page rendered inside the iFrame, and render our custom loader.A delay in loading the commerce page content is expected, as we cannot preload the page displayed within the iFrame (similar to the behavior of the upgrade modal).
Authoring:
For commerce CTAs (created in https://milo.adobe.com/tools/ost):
workflowStep=segmentation
andmodal=true
parameters,e.g.
https://milo.adobe.com/tools/ost?osi=L2C9cKHNNDaFtBVB6GVsyNI88RlyimSlzVfkMM2gH4A&type=checkoutUrl&text=free-trial&workflowStep=segmentation&modal=true
modal
parameter set. The value should be the modal type:modal=twp
,modal=crm
, ormodal=d2p
.I added these values in the file and previewed it, but I have not published it yet.
Resolves: MWPW-164660
Test URLs: