Skip to content

Conversation

@minhle35
Copy link

@minhle35 minhle35 commented Apr 14, 2025

Overview
This PR implements the five question component types requested in issue #540. These components enhance the application's form capabilities by supporting various response formats.
Key Changes

  • Implemented five question component types: ShortAnswer, Dropdown, MultiChoice, MultiSelect, and Ranking
  • Created a test route for component demonstration and validation

Testing

  • Currently using the test route /question-components-test for manual testing of these components. Below are screenshots of the current implementation.

Screenshot 2025-04-14 at 11 34 37 AM
Screenshot 2025-04-14 at 11 34 53 AM
Screenshot 2025-04-14 at 11 35 25 AM


Fixes per request

  1. Short Answer: extend the width and height (Increased width of textarea using cols attribute)
short_answers_fixed
  1. Dropdown box: add borderline, improve hover effects, and highlight selected options
drop_down_fixed_initial_state drop_down_after_select
  1. Ranking: improve UI by integrating React DnD
ranking_fixed_initial_state ranking_after_ranked

- Add five question component types: ShortAnswer, Dropdown, MultiChoice, MultiSelect, and Ranking
- Create test route for component demonstration
- Modify ApplicationForm to handle different question types
- Update typing for question data structure
…elected options

- Added prominent border for dropdown box
- Implemented light blue hover effect for options
- Added conditional highlighting for selected options with checkmark
- Increased width of textarea using cols attribute
- Set default height to 3 rows
- Improved visual presentation of text input area
- Reflect dependency resolution changes from recent package updates
@gyoumi
Copy link

gyoumi commented May 1, 2025

Looks mostly good, a few things which could be fixed:

  1. Short Answer
  • It would be good if the border of the textbox was visible even if not selected, just so it is clear where the textbox is and where it ends
  • It shows in your screenshots, but in the browsers I have tested (Chrome, Opera, Vivaldi) the text indicator does not appear when I click into the textbox. It would be good if we can have it be visible and flashing so that users can know when the textbox is active and ready to accept text
  1. Ranking
  • Similarly with the textbox, would be good if we could see exactly where and when each draggable element begins and ends.
  • It would also be good if the draggable icon was inline with the rest of the element. You can try putting it on the left or right side (or remove it entirely) and see which looks best

@minhle35
Copy link
Author

minhle35 commented Jun 6, 2025

Fixed two components

  1. Short answer: Replaced current textarea with existing TextArea component
    • Improves UI consistency
    • Adds focus states and hover effects
image
  1. Ranking: Added interactive hover effects for drag-and-drop items
Screen.Recording.2025-06-06.at.1.53.55.PM.mov

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