[PR #1593] [MERGED] fix: unable to check on the checkbox field #1740

Closed
opened 2026-02-26 20:30:51 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/documenso/documenso/pull/1593
Author: @ephraimduncan
Created: 1/19/2025
Status: Merged
Merged: 2/1/2025
Merged by: @Mythie

Base: mainHead: fix/checkbox-field-bug


📝 Commits (2)

  • 31cb7d0 fix: unable to check on the checkbox field
  • 0768450 Merge branch 'main' into fix/checkbox-field-bug

📊 Changes

1 file changed (+12 additions, -16 deletions)

View changed files

📝 apps/web/src/app/(signing)/sign/[token]/checkbox-field.tsx (+12 -16)

📄 Description

Before

https://github.com/user-attachments/assets/de18a53d-1065-4647-b612-6eba109a9bfb

After

https://github.com/user-attachments/assets/a486e280-ebd8-4abe-b9a4-465762e350bf

Description

This change prevents race conditions between state updates and API operations by updating local state immediately before making async calls.

Changes Made

  • Refactored the handleCheckboxOptionClick function to consolidate API calls:
  • Fixed a bug where checkedValues was being used in toCheckboxValue before being updated

Checklist

  • I have tested these changes locally and they work as expected.
  • I have added/updated tests that prove the effectiveness of these changes.
  • I have updated the documentation to reflect these changes, if applicable.
  • I have followed the project's coding style guidelines.
  • I have addressed the code review feedback from the previous submission, if applicable.

Additional Notes


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/documenso/documenso/pull/1593 **Author:** [@ephraimduncan](https://github.com/ephraimduncan) **Created:** 1/19/2025 **Status:** ✅ Merged **Merged:** 2/1/2025 **Merged by:** [@Mythie](https://github.com/Mythie) **Base:** `main` ← **Head:** `fix/checkbox-field-bug` --- ### 📝 Commits (2) - [`31cb7d0`](https://github.com/documenso/documenso/commit/31cb7d0291a37947166893701af9609113455e32) fix: unable to check on the checkbox field - [`0768450`](https://github.com/documenso/documenso/commit/07684506c7e82cd6572f88edd623aece86177114) Merge branch 'main' into fix/checkbox-field-bug ### 📊 Changes **1 file changed** (+12 additions, -16 deletions) <details> <summary>View changed files</summary> 📝 `apps/web/src/app/(signing)/sign/[token]/checkbox-field.tsx` (+12 -16) </details> ### 📄 Description ## Before https://github.com/user-attachments/assets/de18a53d-1065-4647-b612-6eba109a9bfb ## After https://github.com/user-attachments/assets/a486e280-ebd8-4abe-b9a4-465762e350bf ## Description This change prevents race conditions between state updates and API operations by updating local state immediately before making async calls. ## Changes Made - Refactored the `handleCheckboxOptionClick` function to consolidate API calls: - Fixed a bug where `checkedValues` was being used in `toCheckboxValue` before being updated ## Checklist - [x] I have tested these changes locally and they work as expected. - [ ] I have added/updated tests that prove the effectiveness of these changes. - [ ] I have updated the documentation to reflect these changes, if applicable. - [x] I have followed the project's coding style guidelines. - [x] I have addressed the code review feedback from the previous submission, if applicable. ## Additional Notes --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-26 20:30:51 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/documenso#1740
No description provided.