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

Highlights don't match up with text #34

Open
ftzdomino opened this issue Nov 7, 2017 · 0 comments
Open

Highlights don't match up with text #34

ftzdomino opened this issue Nov 7, 2017 · 0 comments

Comments

@ftzdomino
Copy link

The div/span that display the backgrounded highlighted text are 16px/medium in Chrome's default user agent stylesheet. They inherit from this from table. This can be fixed to match the .ant-input font-size of 12px via the following diff:

diff --git a/src/components/TextEditor.js b/src/components/TextEditor.js
index ac50572..6fedea1 100644
--- a/src/components/TextEditor.js
+++ b/src/components/TextEditor.js
@@ -14,6 +14,7 @@ const styles = {
     pointerEvents: 'none',
     padding: '5px 8px',
     whiteSpace: 'pre',
+    fontSize: '12px'
   },
   zeroPos: {
     position: 'absolute',
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

No branches or pull requests

1 participant