Closed hana-branch closed 1 year ago
@hana-branch : aria-label can be set inside addDynamicCtaText
method itself. Dont need to repeat the code in a new method.
journeys_utils.addDynamicCtaText = function (iframe, ctaText) {
var doc = iframe.contentWindow.document;
if (doc && doc.getElementById('branch-mobile-action')) {
var mobileAction = doc.getElementById('branch-mobile-action');
mobileAction.innerHTML = ctaText;
mobileAction.setAttribute('aria-label', ctaText);
}
}
@JagadeeshKaricherla-branch Thanks for reviewing this, I just changed the code based on your feedback, could you please re-review the change? thanks
Pull Request Template
Description
To improve the Journeys Accessibility Audit WCAG 2.1, changed that the visual label of a CTA is the same as the programmatical name.
Fixes # BUX-1856
Type of change
Please delete options that are not relevant.
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
JS Budget Check
Please mention the size in kb before and after this PR
Checklist:
Mentions:
List the person or team responsible for reviewing proposed changes.
cc @BranchMetrics/saas-sdk-devs for visibility.