CTATTextArea - CMUCTAT/CTAT GitHub Wiki
This uses a <textarea> as its base and is meant be used for larger text entry.
<div id="textarea" class="CTATTextArea"></div>-
id: Required. The name of the component, must be a valid html id name. -
class: Required. The class list, must includeCTATTextAreaand no other CTAT<component> classes. -
data-ctat-enabled:trueorfalse. Default istrue. Controls if the component will accept student interaction. -
data-ctat-tutor:trueorfalse. Default istrue. Controls if direct actions on the component trigger grading. -
data-ctat-show-feedback:trueorfalse. Default istrueunlessdata-ctat-tutor="false". Determines if grading feedback is shown on the component. -
data-ctat-show-hint-highlight:trueorfalse. Default istrue. Determines if hint highlighting is shown on the component. -
data-ctat-disable-on-correct:trueorfalse. Default istrue. Determines if the component becomes locked when it is graded as correct. -
data-ctat-tab-on-enter:trueorfalse. Default istrue`. Determines if pressing the enter key will act like hitting tab which will advance to the next entity in the tab order and initiate grading, if grading is enabled. Set this to 'false' if you would like to let students format text with newlines. -
data-ctat-submit-on-blur:trueorfalse. Default istrue. CTATv4.5 and later Iffalsethe component will not submit the content for grading when the user presses the Tab key or clicks on another CTAT component. -
data-ctat-track-selection: (experimental, in versions after 2023-09-01)trueorfalse. Default isfalse. If true, the component will generateselectTextactions when the user selects part of the text.
In addition to the common Actions listed in Often Used TPAs this component supports the following actions:
| Action | Input | Notes |
|---|---|---|
| UpdateTextArea | a string | Modifies the text |
.CTATTextArea { display: inline-block; }
.CTATTextArea>textarea {
overflow: hidden;
resize: none;
width: inherit;
height: inherit;
}