mumuki-laboratory
mumuki-laboratory copied to clipboard
"One line code" in Editor Type
There are exercises where only one line of code is necessary, so a whole textarea is too much.
For example:
This exercise type technically exists, and is called text
: https://github.com/mumuki/mumuki-laboratory/blob/master/app/views/layouts/exercise_inputs/editors/_text.html.erb.
However, it looks like it is not actually working - you can create one exercise of that type in bibliotheca and laboratory will not reflect those changes.
Also, the name text
is really bad and obscure. I'd recommend renaming it to one_liner
.
Also, see https://github.com/mumuki/mumuki-laboratory/issues/726
@flbulgarelli what should the reset button do? clear the field?
Yes. It should behave exactly like the code-editor reset button.
The reset button should only clear the field in the UI, not in the backend.
Also, you should use a one-linear code-mirror editor, not a text-field
@Gustrucco Do we need this feature for an specific exercise or it's just a general improvement?
As far as I remember is a general improvement for exercises where you only need to write one line of code.
We have to make sure that the reset button and format button works properly