fix: POCD-348 fix ie11 issues - #207
Merged
Merged
Conversation
jakubjasinsky
previously approved these changes
Jul 25, 2025
edwin-joseph-cko
force-pushed
the
fix/POCD-348-fix-ie11-issues
branch
from
July 25, 2025 09:55
5ba9fb3 to
6775b8d
Compare
jakubjasinsky
previously approved these changes
Jul 25, 2025
jakubjasinsky
approved these changes
Jul 25, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR addresses IE11 compatibility issues by replacing ES2020 features (ternary operators and nullish coalescing operators) with IE-compatible alternatives throughout the APM codebase.
Solution
? :) with IE-compatible if-else statements across 16 files in thesrc/apmdirectory??) with logical OR (||) operators??=) with proper if-else logicFiles Modified:
src/apm/views/Pending.ts- Replaced ternary operators in step rendering and button logicsrc/apm/Theme.ts- Replaced ternary operators in color scheme handling and CSS generationsrc/apm/elements/qr.ts- Replaced ternary operators in QR code color configurationsrc/apm/elements/otp.ts- Replaced ternary operators in input validation and attributessrc/apm/views/utils/form.ts- Replaced ternary operators in form field handlingsrc/apm/utils.ts- Replaced ternary operators in utility functionssrc/apm/views/View.ts- Replaced ternary operators in DOM property handlingsrc/apm/views/Success.ts- Replaced ternary operators in timeout initializationsrc/apm/views/NextSteps.ts- Replaced ternary operators in form validation and button renderingsrc/apm/elements/header.ts- Replaced ternary operators in component props handlingsrc/apm/elements/subheader.ts- Replaced ternary operators in component props handlingsrc/apm/elements/page.ts- Replaced ternary operators in component props handlingsrc/apm/elements/button.ts- Replaced ternary operators in component props handlingsrc/apm/views/Redirect.ts- Replaced ternary operators in button renderingsrc/apm/views/Error.ts- Replaced ternary operators in button renderingsrc/apm/elements/markdown.ts- Replaced ternary operators in content processing and stylingsrc/apm/events/EventListener.ts- Replaced ternary operators in event handlingDemo
The changes ensure that the APM components work correctly in Internet Explorer 11 and other older browsers that don't support ES2020 features. All functionality remains the same, but now uses IE-compatible JavaScript syntax.
Checklist
yarn bump-versionNote
??(nullish coalescing) and||(logical OR) was considered, but in this codebase the substitution works correctly for the intended behaviourJira Issue
POCD-348