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

refactor native beforeinput handling #2063

Merged
merged 2 commits into from
Aug 9, 2018

Conversation

ianstormtaylor
Copy link
Owner

Is this adding or improving a feature or fixing a bug?

Debt.

What's the new behavior?

Moves the native beforeinput event handling into the Before/AfterPlugin and out of the <Content> component, so that all event handling remains in plugins.

Have you checked that...?

  • The new code matches the existing patterns and styles.
  • The tests pass with yarn test.
  • The linter passes with yarn lint. (Fix errors with yarn prettier.)
  • The relevant examples still work. (Run examples with yarn watch.)

Does this fix any issues or need any specific reviewers?

Fixes: #2059

@codecov
Copy link

codecov bot commented Aug 9, 2018

Codecov Report

Merging #2063 into master will decrease coverage by 0.07%.
The diff coverage is 23.61%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2063      +/-   ##
==========================================
- Coverage   66.94%   66.86%   -0.08%     
==========================================
  Files          68       68              
  Lines        5624     5635      +11     
==========================================
+ Hits         3765     3768       +3     
- Misses       1859     1867       +8
Impacted Files Coverage Δ
packages/slate-react/src/plugins/after.js 5.3% <0%> (-0.68%) ⬇️
packages/slate-react/src/components/content.js 27.35% <0%> (+5.71%) ⬆️
packages/slate-react/src/plugins/before.js 11.57% <0%> (-0.13%) ⬇️
packages/slate-dev-environment/src/index.js 51.35% <48.57%> (-3.83%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a396d01...b70dd90. Read the comment docs.

@ianstormtaylor ianstormtaylor merged commit f812816 into master Aug 9, 2018
@ianstormtaylor ianstormtaylor deleted the refactor-native-beforeinput branch August 22, 2018 19:47
jtadmor pushed a commit to jtadmor/slate that referenced this pull request Jan 22, 2019
* refactor native beforeinput handling

* fix lint
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

move onNativeBeforeInput logic into the AfterPlugin
1 participant