Unify checklist text refs behind discriminated union (#483)#492
Conversation
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (28)
📝 WalkthroughWalkthroughThis pull request refactors the checklist text-access API by consolidating three separate callback functions ( Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes Possibly related PRs
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
getTextRef(params: {sectionKey?, fieldKey?, questionKey?})shape onChecklistOperationswith a discriminatedTextRefunion (AMSTAR2 | ROBINS_I | ROB2), and applies the same shape tosetTextValue.This is the text-ref portion of #483. Subsequent commits will:
getTextRef/setTextValueonproject.checklist.TextRefend-to-end.getQuestionNote/getRobinsText/getRob2Textmethods.The other two parts of #483 (typed
project.*singleton,ConnectionPhaseenum) are already in place onmain.Test plan
pnpm --filter web typechecksetTextValuestill copies reviewer comments into the reconciled checklist.Refs #483.
Summary by CodeRabbit