Skip to content

Commit

Permalink
Merge pull request #599 from hpi-studyu/dev
Browse files Browse the repository at this point in the history
hotfix(studyu_designer_v2@1.6.3): Disable freetext UI
  • Loading branch information
johannesvedder authored Mar 26, 2024
2 parents 2ad9096 + a2cce7f commit c31f486
Show file tree
Hide file tree
Showing 10 changed files with 4,148 additions and 4,122 deletions.
21 changes: 21 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,27 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.

## 2024-03-26

### Changes

---

Packages with breaking changes:

- There are no breaking changes in this release.

Packages with other changes:

- [`studyu_designer_v2` - `v1.6.3`](#studyu_designer_v2---v163)

---

#### `studyu_designer_v2` - `v1.6.3`

- **FIX**: disable freetext for Designer UI surveys. ([7e3988eb](https://github.com/hpi-studyu/studyu/commit/7e3988ebc80620be52636077a6fb13a180c1802a))


## 2024-03-25

### Changes
Expand Down
4 changes: 4 additions & 0 deletions designer_v2/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 1.6.3

- **FIX**: disable freetext for Designer UI surveys. ([7e3988eb](https://github.com/hpi-studyu/studyu/commit/7e3988ebc80620be52636077a6fb13a180c1802a))

## 1.6.2

- Graduate package to a stable release. See pre-releases prior to this version for changelog entries.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,8 @@ class _SurveyQuestionFormViewState extends ConsumerState<SurveyQuestionFormView>

_buildResponseTypeHeader(BuildContext context) {
final theme = Theme.of(context);

final noFreeText = formViewModel.questionTypeControlOptions;
noFreeText.removeWhere((element) => element.value == SurveyQuestionType.freeText);
return Column(
children: [
FormTableLayout(
Expand All @@ -106,7 +107,7 @@ class _SurveyQuestionFormViewState extends ConsumerState<SurveyQuestionFormView>
data: theme.copyWith(inputDecorationTheme: ThemeConfig.dropdownInputDecorationTheme(theme)),
child: ReactiveDropdownField<SurveyQuestionType>(
formControl: formViewModel.questionTypeControl,
items: formViewModel.questionTypeControlOptions.map((option) {
items: noFreeText.map((option) {
final menuItemTheme = ThemeConfig.dropdownMenuItemTheme(theme);
final iconTheme = menuItemTheme.iconTheme ?? theme.iconTheme;
return DropdownMenuItem(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ enum SurveyQuestionType {
ScaleQuestion.questionType: SurveyQuestionType.scale,
AnnotatedScaleQuestion.questionType: SurveyQuestionType.scale,
VisualAnalogueQuestion.questionType: SurveyQuestionType.scale,
// FreeTextQuestion.questionType: SurveyQuestionType.freeText,
FreeTextQuestion.questionType: SurveyQuestionType.freeText,
};
if (!typeMapping.containsKey(question.type)) {
throw UnimplementedError("Missing SurveyQuestionType for question of type: ${question.type}");
Expand Down
2 changes: 1 addition & 1 deletion designer_v2/pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: studyu_designer_v2
version: 1.6.2
version: 1.6.3
description: Implement digital N-of-1 studies seamlessly with the StudyU Health Designer
publish_to: none
homepage: https://studyu.health
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
788 changes: 394 additions & 394 deletions docs/uml/designer_v2/lib/features/design/shared/questionnaire/uml.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit c31f486

Please sign in to comment.