Skip to content

fix(create-tag): fix issue where save button remains disabled after creating a new tag.#1814

Closed
ThisChirag wants to merge 3 commits intodubinc:mainfrom
ThisChirag:fix/new-tag-save-issue
Closed

fix(create-tag): fix issue where save button remains disabled after creating a new tag.#1814
ThisChirag wants to merge 3 commits intodubinc:mainfrom
ThisChirag:fix/new-tag-save-issue

Conversation

@ThisChirag
Copy link

Problem

Creating a new tag in the "Tags" field while editing a URL did not activate the "Save Changes" button (#1781).

Solution

This fix includes:

  • The form's state is marked as dirty (shouldDirty: true) when a new tag is added.
  • Rollback logic is introduced to restore the previous state if new tag creation fails.

Testing

Testing included:

  • Ensuring the "Save Changes" button becomes clickable after creating and assigning a new tag.
  • Rollback and error handling.

Fixes #1781

…reating a new tag

Resolves the issue where creating a new tag in the "Tags" field while editing a URL did not activate the "Save Changes" button (dubinc#1781).

This fix includes:
- The form's state is marked as dirty (`shouldDirty: true`) when a new tag is added.
- Rollback logic is introduced to restore the previous state if new tag creation fails.

Testing included:
- Ensuring the "Save Changes" button becomes clickable after creating and assigning a new tag.
- rollback and error handling.

Fixes dubinc#1781

Signed-off-by: Chirag Sharma <er.chiragsharma.atemail@gmail.com>
@vercel
Copy link
Contributor

vercel bot commented Dec 19, 2024

@ThisChirag is attempting to deploy a commit to the Dub Team on Vercel.

A member of the Team first needs to authorize it.

@steven-tey
Copy link
Collaborator

Closing this in favor of #1823, but thank you for your contribution!

@steven-tey steven-tey closed this Dec 22, 2024
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.

bug: creating a new tag in the edit link modal doesn't allow to save the edit

2 participants