Skip to content

Yk/Pantry Bugbash - #211

Merged
Yurika-Kan merged 6 commits into
mainfrom
yk/pantry-bugbash
Sep 6, 2026
Merged

Yk/Pantry Bugbash#211
Yurika-Kan merged 6 commits into
mainfrom
yk/pantry-bugbash

Conversation

@Yurika-Kan

Copy link
Copy Markdown
Collaborator

ℹ️ Issue

ssf bugbash sheet

bash deez bugs of pantry last huzzah

📝 Description

  • Additional Information field had no word cap → added 250-word guard, mirrors Feedback field
  • Clearing Country/Address Line 2 silently reverted → send null not undefined, updated DTO type
  • "How many clients" dropdown skipped required check → added missing required attr
  • Unauthorized page unstyled → rebuilt with PageEmptyState, centered

✔️ Verification

replicated bug then fixed bug then smoke tested

Yurika-Kan and others added 5 commits September 5, 2026 17:10
…odal

Field accepted unbounded text while sibling Feedback field and both
fields in the New/Resubmit modal enforce the cap.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
getCurrentUserPantryId() rejection was unhandled, leaving pantryId
unset with no alert and a silently no-op New Request button.
Line 2 and Country fields mapped blank input to undefined, which gets
dropped from the PATCH body, so the field silently kept its old value
despite a success toast. Use null instead, matching activitiesComments.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
…uthorized page

allergenClients NativeSelect was missing the required HTML attribute
present on its sibling selects, so the browser let the form submit
without an answer despite the red required asterisk.

Also restyle the bare unauthorized page using the existing
PageEmptyState component, centered on the page.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 5, 2026 22:05

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The changes are localized, consistent with existing patterns in the codebase, and align with the PR’s stated bug-fix goals without introducing evident correctness or API-contract issues.

Pull request overview

This PR addresses several UX and data-submission issues in the Pantry workflows by tightening form validation/input limits, fixing “clear field” update semantics, and standardizing empty/unauthorized UI states.

Changes:

  • Added a 250-word cap to the “Additional Information” textarea (consistent with other capped fields).
  • Updated pantry application update DTO typing and payload construction to send null (not undefined) when clearing optional address fields.
  • Improved required-field enforcement and user feedback for invalid deeplinks / missing records, and rebuilt the Unauthorized page using PageEmptyState.
File summaries
File Description
apps/frontend/src/types/types.ts Updates UpdatePantryApplicationDto to allow null for optional address fields that must be explicitly cleared.
apps/frontend/src/containers/unauthorized.tsx Replaces the unstyled unauthorized markup with a centered PageEmptyState and a navigation CTA.
apps/frontend/src/containers/pantryOrderManagement.tsx Adds an error alert when a deeplinked order ID is not found and fixes hook dependencies.
apps/frontend/src/containers/formRequests.tsx Adds error handling for pantry lookup failures, alerts on invalid deeplinks, and shows a page-level empty state when there are no requests.
apps/frontend/src/components/forms/requestDetailsModal.tsx Adds a 250-word guard to the “Additional Information” field, matching existing word-limit behavior elsewhere.
apps/frontend/src/components/forms/pantryApplicationForm.tsx Adds missing required attribute to the “How many clients…” select to enforce required validation on submit.
apps/frontend/src/components/forms/editablePantryApplication.tsx Sends null for cleared optional address fields so the backend can persist the cleared state instead of silently reverting.
Review details
  • Files reviewed: 7/7 changed files
  • Comments generated: 0
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Role-gating and the unauthorized page redesign are being handled
together on yk/volunteer-bugbash; keep this branch's copy plain to
avoid duplicate/conflicting styling.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>

@dburkhart07 dburkhart07 left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtmmmmmmmm

@Yurika-Kan
Yurika-Kan merged commit 7171326 into main Sep 6, 2026
6 checks passed
@Yurika-Kan
Yurika-Kan deleted the yk/pantry-bugbash branch September 6, 2026 05:40
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.

3 participants