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(kit): Number + postfix (with leading space) adds unnecessary spaces on paste value with trailing spaces #1865

Merged

Conversation

AndreiBelokopytov
Copy link
Contributor

@AndreiBelokopytov AndreiBelokopytov commented Nov 25, 2024

Fixes #1820

UPD: The addition of an extra space happens in the postfix postprocessor because it believes the mask was changed and tries to find a symbol in the original string that also exists in the mask.

To modify this behavior, the check within the postfixPostprocessor was updated to exclude cases where text outside the postfix is changed. Since the postfixPostprocessor no longer handles cases where a prefix symbol changes, the extractAffixes function was modified to take over processing these cases.

Additionally, the guessValidValueByRegExp function was corrected to prevent situations where the selection becomes greater than the new value, thus falling inside the postfix.

@AndreiBelokopytov AndreiBelokopytov requested a review from a team as a code owner November 25, 2024 06:13
@AndreiBelokopytov AndreiBelokopytov requested review from MarsiBarsi, waterplea, nsbarsukov, vladimirpotekhin and mdlufy and removed request for a team November 25, 2024 06:13
@AndreiBelokopytov AndreiBelokopytov changed the title fix: зrevent extra spaces from being added by postfix-postprocessor fix: prevent extra spaces from being added by postfix-postprocessor Nov 25, 2024
@nsbarsukov nsbarsukov changed the title fix: prevent extra spaces from being added by postfix-postprocessor fix(kit): Number + postfix (with leading space) adds unnecessary spaces on paste value with trailing spaces Nov 28, 2024
@nsbarsukov nsbarsukov added the community contribution This issue was closed by a PR from the community label Nov 29, 2024
@nsbarsukov nsbarsukov merged commit c37b1d6 into taiga-family:main Nov 29, 2024
30 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community contribution This issue was closed by a PR from the community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

🐞 - Number + postfix (with leading space) adds unnecessary spaces on paste of decimal number
2 participants