Skip to content

feat: date pick question#796

Open
ibrahimozkn wants to merge 15 commits intodevfrom
feat/date-question
Open

feat: date pick question#796
ibrahimozkn wants to merge 15 commits intodevfrom
feat/date-question

Conversation

@ibrahimozkn
Copy link
Contributor

This pull request introduces support for a new DateQuestion type in the questionnaire system, including backend model, serialization, designer form controls, and frontend UI integration. The changes enable date and date-time questions with validation, customizable formats, and localization. The most important changes are grouped below:

Backend Model & Serialization:

  • Added the new DateQuestion model with fields for minimum/maximum date, format presets, and initial value, including JSON serialization and deserialization (date_question.dart, date_question.g.dart, date_format_preset.dart). [1] [2] [3]
  • Registered DateQuestion in the questionnaire question factory and exported it in the questions module (question.dart, questions.dart). [1] [2]

Designer Form Integration:

  • Added form controls and validation helpers for date questions in the designer, including controls for min/max/initial date and format preset, and auto-correction logic for initial value outside range (question_form_controller.dart). [1] [2] [3] [4]

Frontend UI Integration:

  • Implemented the DateQuestionWidget for the app, supporting date and time picking, validation, formatting, clearing, and submission, with localization support (date_question_widget.dart, question_container.dart). [1] [2] [3]

Localization:

  • Added new localization keys and translations for date picker UI and validation messages in English and German, and updated the localization interface (app_en.arb, app_localizations.dart, app_localizations_en.dart, app_localizations_de.dart). [1] [2] [3] [4]

Miscellaneous:

  • Minor import and type registration updates to support the new question type and designer integration (question_form_controller.dart).

These changes collectively enable robust date and date-time questions in both the study designer and participant app, with full localization and validation support.

…uestionnaires

- Introduced DateQuestion model with minDate, maxDate, dateFormatPreset, and initialDate properties.
- Created DateFormatPreset enum for various date formats.
- Implemented DateQuestionWidget to handle date selection with optional time.
- Added localization support for date-related strings in English and German.
- Updated questionnaire form to include date question handling and validation.
- Enhanced UI with date picker and time picker functionalities.
@github-actions
Copy link

github-actions bot commented Feb 12, 2026

Visit the preview URL for this PR (updated for commit f6ee10f):

(expires Fri, 13 Mar 2026 10:10:21 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 2149dad49ed83535217e50d5c18c0c8c90da629b

@gitguardian
Copy link

gitguardian bot commented Mar 1, 2026

⚠️ GitGuardian has uncovered 1 secret following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secret in your pull request
GitGuardian id GitGuardian status Secret Commit Filename
23178981 Triggered JSON Web Token e405d05 flutter_common/lib/envs/.env.dev View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secret safely. Learn here the best practices.
  3. Revoke and rotate this secret.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

…ation

- Updated DateQuestionFormData to include input type, min/max time, and default options for date/time.
- Modified DateQuestionFormView to dynamically display input fields based on selected input type (date, time, datetime).
- Added new localization strings for time input, date input types, and validation messages in both English and German.
- Improved UI to handle specific default date/time selections and constraints for min/max dates and times.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants