Skip to content
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

Fix bug where cloned Neo/Matrix blocks get incorrect LJ Color Picker field values #2

Closed

Conversation

ttempleton
Copy link

This fixes a bug in the field's getInputHtml() method, where the field value is set to the default colour if $this->isFresh($element) is true, regardless of whether the $value passed into getInputHtml() is set or not. Not also checking whether $value === null causes pasted/cloned Neo blocks, and Matrix blocks pasted/cloned using Smith, to have the default colour set on the clone block instead of the colour value from the block that was copied/cloned. This pull request ensures that $value === null is checked.

Fixes #1.

@ttempleton
Copy link
Author

Closing this pull request in favour of #4.

@ttempleton ttempleton closed this Dec 20, 2022
@ttempleton ttempleton deleted the fix-neo-smith-clone branch December 20, 2022 10:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Color styles missing on cloning the blocks
1 participant