This repository was archived by the owner on Mar 4, 2020. It is now read-only.
fix(fela): plugin order, invokeKeyframes#1741
Merged
Conversation
Contributor
Author
|
This PR is to be merged after #1744 |
lucivpav
commented
Aug 2, 2019
| }) | ||
| }) | ||
|
|
||
| test('does not transform a list of strings', () => { |
Contributor
Author
There was a problem hiding this comment.
Maybe the felaInvokeKeyframesPlugin fix and test should be moved into a separate commit? The reason for this fix is that screener tests are failing, if the order of plugins is changed.
Contributor
Author
There was a problem hiding this comment.
The checkboxStyles definition contains root: display: ['inline-grid', '-ms-inline-grid']. This gets processed by felaInvokeKeyframesPlugin incorrectly, rendering it as root: display: { 0: 'inline-grid', 1: '-ms-inline-grid' }.
layershifter
reviewed
Aug 2, 2019
miroslavstastny
approved these changes
Aug 8, 2019
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
plugin order
This PR resolves and tests a problem with
felaRenderer. The order of plugins being executed actually matters. The problem is thatfelaPluginFallbackValue()comes beforefelaInvokeKeyframesPlugin().felaPluginFallbackValue()does the following:Input
{
color: [ 'rgba(0, 0, 0, 0.5)', '#ccc']
}
Output
{
color: 'rgba(0, 0, 0, 0.5);color:#ccc'
}
But if we have, say, an Animation with
keyframeParams=[ '0%', '50%', '100%' ], the array would be processedfelaPluginFallbackValue(). If thekeyframefunction expects an array, we get an error, because thekeyFrameParamsis no longer an array.invokeKeyframes
The
checkboxStylesdefinition containsroot: display: ['inline-grid', '-ms-inline-grid']. This gets processed byfelaInvokeKeyframesPluginincorrectly, rendering it asroot: display: { 0: 'inline-grid', 1: '-ms-inline-grid' }.