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

Add Mark inline formatting #943

Merged
merged 1 commit into from
Dec 3, 2021
Merged

Add Mark inline formatting #943

merged 1 commit into from
Dec 3, 2021

Conversation

geriux
Copy link

@geriux geriux commented Nov 16, 2021

This PR is a follow-up of #939 to wrap up adding Mark formatting support.

To test this feature, use the iOS build from this PR that uses this feature.

Fix

Adds Mark formatting capabilities.

Test

For test cases, you can check the description of this PR.

Review

@antonis

Make sure strings will be translated:

  • If there are new strings that have to be translated, I have added them to the client's strings.xml as a part of the integration PR.

@geriux
Copy link
Author

geriux commented Nov 17, 2021

Hey there @hypest @mchowning 👋

I'm having an issue with this feature and I saw you have worked on this project before, I was wondering if any of you might have some insight 😄

Currently, if you have a word typed in, and an empty <mark> tag at the end, if you focus at the end to write something within the tag, it will let you add content but while you do so, the first word is wrapped by another <mark> tag with the CSS attributes of the original mark tag. The desired result would be to leave the first word as it was and be able to type content within the mark tag that's at the end.

Screenrecorder-2021-11-17-10-47-01-827.mp4

Have you seen this before? I updated the demo app content to show the current issue. Any guidance would be appreciated. Thanks!

@hypest
Copy link
Contributor

hypest commented Nov 17, 2021

👋 @geriux , thanks for the ping!

Haven't really dug deeply into this yet, but thought of sharing this in case it helps in the meantime: I wonder if there's some mixup with inline and block level elements handling here that leads to that separate to appear. For example, I see that it's the blockFormatter used here instead of the inlineFormatter. I understand that the mark tag is an inline-level HTML tag, right? So, I'd expect to only see it being handled by the inline elements related classes. Again, I haven't tried to really debug this so, take the above with a grain of salt :)

@geriux geriux changed the title [WIP] Feature - Mark inline formatting Add Mark inline formatting Nov 30, 2021
@geriux geriux marked this pull request as ready for review November 30, 2021 16:20
@geriux geriux requested a review from antonis November 30, 2021 16:20
Copy link
Contributor

@antonis antonis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work @geriux 👍
I tested with the Gutenberg PR and everything works as expected. The code also LGTM 🎉

I added a couple of comments that do not affect the code functionally :)

@geriux geriux force-pushed the feature/mark-formatting branch from 96a3deb to 3823851 Compare December 2, 2021 14:28
@geriux geriux merged commit 2878796 into develop Dec 3, 2021
@geriux geriux deleted the feature/mark-formatting branch December 3, 2021 09:35
@geriux geriux mentioned this pull request Mar 18, 2024
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants