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: project identifier cursor behaviour in create project modal. #3320

Merged
merged 1 commit into from
Jan 5, 2024

Conversation

prateekshourya29
Copy link
Member

@prateekshourya29 prateekshourya29 commented Jan 5, 2024

Problem

Steps to reproduce:

  • Type an Identifier in the Project create modal
  • Put the cursor in the beginning of the typed identifier
  • Observe - it will automatically move to end if you type anything

The cursor is behaving weird when typing happens and user puts it at the beginning of the Identifier.

Solution

The issue occured because of using toUpperCase on every change mutated the entire identifier to uppercase, causing the cursor to move unexpectedly. To solve this, I removed all toUpperCase methods to prevent unintended changes. Instead, I applied the uppercase Tailwind class to visually display the identifier in uppercase for users. And before sending it to our API endpoint, we still convert the data to uppercase, ensuring consistency without disrupting user input.

project.identifier.1.mp4

@prateekshourya29 prateekshourya29 added this to the v0.14.3-dev milestone Jan 5, 2024
@prateekshourya29 prateekshourya29 self-assigned this Jan 5, 2024
@sriramveeraghanta sriramveeraghanta merged commit cf64c7b into develop Jan 5, 2024
6 of 8 checks passed
@sriramveeraghanta sriramveeraghanta deleted the fix/project-identifier-cursor branch January 5, 2024 09:08
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

Successfully merging this pull request may close these issues.

2 participants