Removed background color from paragraph. Fixed contrast checker on transparent colors. #5845
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.
Until now, the paragraph block had a background set to white.
With the recent nesting addition, this is causing us some problems. As noted in the discussions in #5658. In the cover image nesting PR #5452 the background rule is also problematic so this PR removes this rule.
This PR also fixes the contrast checking mechanism to not display an error if the colors we are dealing with contain transparencies. Because if the colors contain transparency we don't know what is below them (it can even be an image) with a big contrast.
How Has This Been Tested?
No noticeable changes should be seen in the paragraph.
If no background is set for a paragraph the contrast checker should never display errors (as in this case the background is transparent) and the theme may have a color with high contrast. If set a background color for the paragraph the contrast checker should work as expected.
If we set a background color for a paragraph using a CSS rule the contrast checking should work as expected in accordance with the background rule set with CSS.
Example css rule.