-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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(indicate typos): letters not displaying correctly in RTL languages or with ligatures when set to below (NadAlaba) #5113
Merged
Conversation
This file contains 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
P.S. There has to be better ways of checking current language in sync functions |
Miodec
reviewed
Feb 26, 2024
If you only type incorrect letters, the hints jump right after each keypress. |
Miodec
added
the
waiting for update
Pull requests or issues that require changes/comments before continuing
label
Feb 26, 2024
Please test with english. |
Done! Edited my first comment to reflect chagnes. |
Also, make the functions resetCaretPosition() and update() async, in order to check for current language inside them with await Misc.getCurrentLanguage().
Also, make the function updateWordElement() async, in order to check for current language inside it with await Misc.getCurrentLanguage(), and make all calls to this function void updateWordElement() in input-controller.ts and test-ui.ts.
instead of triggering hint clustering (joining) as a word only in languages that have 'ligatures' = true, hints are now joined only if there is overlap between hint characters.
@Miodec Any feedback? |
Will check soon. |
Miodec
added
waiting for review
Pull requests that require a review before continuing
and removed
waiting for update
Pull requests or issues that require changes/comments before continuing
labels
Mar 11, 2024
Miodec
added
waiting for update
Pull requests or issues that require changes/comments before continuing
and removed
waiting for review
Pull requests that require a review before continuing
labels
Mar 11, 2024
Done!
|
Miodec
changed the title
fix: Indicate typos below disjoining letters in languages with ligatures (NadAlaba)
fix(indicate typos): disjoining letters in RTL languages or with ligatures when set to below (NadAlaba)
Mar 25, 2024
Miodec
changed the title
fix(indicate typos): disjoining letters in RTL languages or with ligatures when set to below (NadAlaba)
fix(indicate typos): letters not displaying correctly in RTL languages or with ligatures when set to below (NadAlaba)
Mar 25, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
frontend
User interface or web stuff
waiting for update
Pull requests or issues that require changes/comments before continuing
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.
Description
<hint>
elements from<letter .incorrect>
to<.word>
, because hints were messing the joining of letters in languages with cursive attachments "withLigatures". Hint characters, that correspond to adjacent incorrect letters, now join together as a word when there is an overlap between them, which can happen in non monospaced fonts regardless if the current language has "ligatures" or not (Intest-ui.ts
: New functionscreateHintsHtml()
andasync function joinOverlappingHints()
, and changes toupdateWordElement()
).test-ui.ts
: Newasync function updateHintsPosition()
)updateWordElement()
async in order to callawait joinOverlappingHints();
, and made all calls to this functionvoid updateWordWlement();
(Ininput-controller.ts
andtest-ui.ts
)<.word>
asposition: relative
instead of.word letter.incorrect {position: relative}
, in order to be able to position<hint>
s absolutely relative to the corresponding<.word>
(Instyles/test.scss
).<.word>
relative,<letter>
s were givingoffsetLeft
andoffsetTop
relative to the<.word>
instead of relative to<#wordsWrapper>
, so had to add the offset position of<.word .active>
to the position of the caret. (Incaret.ts
: Changes toupdatePosition()
).pace-caret.ts
: Changes toupdate()
).resetCaretPosition()
andupdate()
async
in order to check if current language is RTL (to be able to callawait Misc.getCurrentLanguage();
), and made the call toupdate()
void update()
infunction start() {}
(Inpace-caret.ts
: Changes toresetCaretPosition()
,update()
, andstart()
).Checks
_list.json
,_groups.json
and addlanguages.json
?