Introduction
Dialog boxes (also called modals or pop-ups) are windows that appear over the main interface to help you enter information, make decisions, or confirm important actions. CAREFUL uses dialog boxes extensively for creating actions, editing patient information, managing teams, and confirming critical operations like patient discharge.
Before You Start
No special permissions are required to interact with dialog boxes. However, the specific dialog boxes you can access depend on your role:
- Team Members can access patient and action-related dialogs for their teams
- Team Owners can additionally access team management dialogs
- Administrators can access organization-wide dialogs
Understanding Dialog Box Components
Every dialog box in CAREFUL follows a consistent structure:
Header Section:
- Title: Clearly identifies the purpose (e.g., "Create new action for patient John SMITH")
- Close button (X): Located in the top-right corner to dismiss the dialog
Content Section:
- Form fields: Text inputs, dropdowns, date pickers, or search fields for entering information
- Required fields: Must be completed before you can submit (indicated by validation errors if left empty)
- Optional fields: Labeled as "Optional Information" when grouped together
Footer Section:
- Action button: Primary button (usually labeled "Submit", "Save", or "Confirm") to complete the action
- Additional options: May include checkboxes like "Create another after submit"
Working with Dialog Boxes
Opening a Dialog Box:
- Dialog boxes open automatically when you trigger an action from the main interface
- Common triggers include clicking the Add Action button, selecting an item from a kebab menu (⋮), or clicking edit icons
- The dialog appears centered on your screen with a semi-transparent dark overlay behind it
Filling Out Forms:
- Focus automatically moves to the first empty field when the dialog opens
- For search fields (like Assignee selection), start typing to see matching results
- Use the autocomplete dropdown to select from available options
- Invalid selections show a reason in parentheses and cannot be selected (e.g., "Jane Doe (not a team member)")
- For date fields, use the dropdown selectors for day, month, and year
- For time fields, select hours and minutes (increments in 5-minute steps)
- To upload attachments, use the file uploader and click to select files from your device
Form Validation:
- Required fields show an error message if you try to submit without completing them
- Incomplete dates (e.g., only selecting day and month) trigger a validation error: "Please complete the date or clear it"
- The Submit button becomes disabled if required fields are empty or invalid
- Validation errors appear inline below each field with specific guidance
Submitting or Canceling:
- Click the Submit button (or equivalent action button) when ready
- The button shows a "pending" state (loading indicator) while processing
- If validation errors occur, they appear inline and the dialog stays open for corrections
- To cancel without saving, click the X close button in the top right corner
- Important: The ESCAPE key does not close dialog boxes in CAREFUL - this prevents accidental data loss
After Submission:
- On success, the dialog closes automatically and you return to the previous screen
- A success message may appear confirming the action
- If you checked "Create another after submit", the dialog stays open with a fresh form (your previous selections like assignee are preserved for convenience)
Common Dialog Box Types
Data Entry Dialogs:
- Used for creating or editing records (actions, patients, teams)
- Include multiple form fields with validation
- Example: Create Action Dialog with Title, Assignee, Due Date, Attachments, and Description fields
Confirmation Dialogs:
- Ask you to confirm important or irreversible actions
- Typically show a warning message with two buttons
- Example: "Are you sure you want to discharge this patient?"
- Usually have a colored confirmation button (often red for destructive actions) and a Cancel button
Information Dialogs:
- Display read-only information like clinical summaries or attachments
- May include navigation (like attachment carousel with previous/next buttons)
- Close using the X button when finished
Mobile Considerations
On mobile devices (iOS and Android):
- Dialog boxes automatically adjust when the keyboard appears
- The dialog repositions itself so the focused field remains visible
- Scroll within the dialog content area if needed
- The keyboard accessory bar is hidden for a cleaner interface
- Use "tap" instead of "click" for all interactions
Tips
- Don't lose your work: Always use the X close button to cancel, not the browser back button or ESCAPE key
- Multiple files: The file uploader supports multiple attachments - upload them one at a time or all together
- "Create another" workflow: When creating multiple similar items (like actions), check "Create another after submit" to save time - your previous selections remain pre-filled
- Search fields: In assignee or user search fields, you can search by first name, last name, or both
- Incomplete selections: If a dropdown or search field shows invalid options with reasons, you cannot proceed until you select a valid option
- Validation messages: Read validation error messages carefully - they tell you exactly what's wrong and how to fix it
Related Features
- Actions: Create, close, reassign, and manage patient actions using specialized dialog boxes
- Patient Management: Edit demographics, update status, and manage patient information through dialogs
- Team Management: Invite users, update team settings, and manage team categories via dialogs
- Handovers: Begin handover processes using multi-step dialog workflows