Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion fill-the-blanks/src/binding.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,20 @@
padding: 3px;
margin: 2px;
}
input.ftb-xs {
width: 40px;
}
input.ftb-sm {
width: 80px;
}
input.ftb-md {
width: 150px;
width: 160px;
}
input.ftb-lg {
width: 240px;
}
input.ftb-xl {
width: 320px;
}
input.st-incomplete {
background-color: #FFFF77;
Expand Down
7 changes: 5 additions & 2 deletions fill-the-blanks/src/handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,9 +120,12 @@ def _get_length_class(text: str, hint: str):
return "ftb-xs"
elif size <= 10:
return "ftb-sm"
elif size > 20:
elif size <= 20:
return "ftb-md"
elif size <= 30:
return "ftb-lg"
return "ftb-md"
else:
return "ftb-xl"


def on_show_question():
Expand Down