Activity system #3

Merged
tscholten merged 23 commits from tiago/activities into master 2026-10-17 15:51:00 +00:00
Showing only changes of commit 0c1683c74b - Show all commits

View File

@ -1,5 +1,5 @@
from enum import StrEnum from enum import StrEnum
from typing import Literal from typing import Literal, get_args
''' '''
This category is used to differentiate types of form elements This category is used to differentiate types of form elements
@ -17,3 +17,6 @@ FormTextCategory = Literal[
FormElementCategory.text_piece, FormElementCategory.text_piece,
FormElementCategory.title_text FormElementCategory.title_text
] ]
def is_question_category(category: FormElementCategory) -> bool:
return category in get_args(FormQuestionCategory)