-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Open
Labels
cleanupRemove non-functional or unnecessary codeRemove non-functional or unnecessary coderefactorRefactoring tasksRefactoring tasksunapproved
Description
Context
As part of the repository-wide translation compliance cleanup (post #7364), this batch focuses on EventListCard modals and associated logic files that are currently passing t as a prop instead of calling useTranslation() locally.
These components are modal-driven and interconnected, so care must be taken to avoid breaking preview, update, or delete flows.
Affected Files
- src/shared-components/EventListCard/Modal/EventListCardModals.tsx
- src/shared-components/EventListCard/Modal/updateLogic.ts
- src/shared-components/EventListCard/Modal/Delete/EventListCardDeleteModal.tsx
- src/shared-components/EventListCard/Modal/Preview/EventListCardPreviewModal.tsx
- src/shared-components/posts/helperFunctions.ts
Required Refactor
For each affected file:
- Remove
tfrom props and parameters - Eliminate
tprop drilling chains - Import
useTranslationfromreact-i18next - Call
const { t } = useTranslation()locally within components - For non-component utility files, refactor to avoid requiring
tas a parameter (move translation responsibility to component level where possible) - Update related tests and mocks as needed
No functional, modal, or data update behavior should change.
Acceptance Criteria
- No component in this batch receives
tas a prop - Utility functions do not require
tas a parameter - All translation calls originate from local
useTranslation() - Modal flows (Preview, Update, Delete) remain fully functional
- Tests pass with no coverage regression
- Translation lint checks pass in CI
- Changes are strictly limited to EventListCard domain
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
cleanupRemove non-functional or unnecessary codeRemove non-functional or unnecessary coderefactorRefactoring tasksRefactoring tasksunapproved
Type
Projects
Status
Backlog