codeforpdx / PASS

PASS project - with HMIS module integration
MIT License
24 stars 23 forks source link

[Enhancement] - Fix NewMessageModal width changes #639

Open andycwilliams opened 1 month ago

andycwilliams commented 1 month ago

Describe the Current Behavior/Feature:

Despite all modals being subject to the set width, NewMessageModal reacts to them strangely.

2024-05-22 (5) 2024-05-22 (4)

Rationale:

It has to do with the oldMessage conditional that converts the modal from a new message into a reply. Specifically with how that conditional is being implemented on around line 183 with the previousMessage TextField.

Proposed Changes:

Reply To is properly formatted the way all the other modals are. It's just New Message that squashes the content.

Ensure the modal retains the preferred formatting in both conditions.

andycwilliams commented 1 month ago

@ofu997 This could be a separate issue, but if you're willing, could you disable the Submit button until the required fields are filled? We already do this with Add Contact and Upload Document, so it should be pretty simple to just copy from those.

Totally fine if not. It's outside this specific scope and I can leave it for another issue. Just thought it might save a bit of time doing it at the same time.

ofu997 commented 1 month ago

@andycwilliams The issue seems to be that the number of inputs affects how wide the input group is.

Screenshot 2024-05-31 161818 Screenshot 2024-05-31 161717

andycwilliams commented 1 month ago

@ofu997 How annoying. I haven't experimented with it much but one possible workaround is shortening the width from '600px' down to '475px'. Not the ideal solution, though.