suggested approach to implement buttons and score bar
Submitted by otacke on Wed, 08/16/2017 - 00:14
Forums:
If I wanted to add a "check" button and a score bar just like some other content types do (possibly a "retry" button an a "show solution" button, too), which would be the suggested approach to go -- in keywords? I know that some UI related things have been changed and are about to change, so I think it's a good idea to ask.
tim
Wed, 08/16/2017 - 10:39
Permalink
Yup, you're right otacke -
Yup, you're right otacke - things have a changed slightly.
I would look at how Drag Text adds buttons:
https://github.com/h5p/h5p-drag-text/blob/master/src/scripts/drag-text.js#L389
And make sure you have the latest h5p-question and h5p-joubel-ui code. Make sure to pull from the release branch.
otacke
Wed, 08/16/2017 - 11:39
Permalink
Thanks a lot, Tim!
Thanks a lot, Tim!
otacke
Fri, 08/18/2017 - 00:19
Permalink
Do you already have some
Do you already have some documentation about the types that can be registered using h5p-question or the library in general? In particular: What's 'introduction' and 'content'?
I am working on a content type that uses h5p-text-input-field. If I guess correctly, I should register the task description field as introduction and the textarea as content, right?
tim
Fri, 08/18/2017 - 10:16
Permalink
Yes, that should be fine.
Yes, that should be fine.
otacke
Fri, 08/18/2017 - 11:31
Permalink
Great! I guess I'll have
Great! I guess I'll have enough time to finish a demo version this weekend then.