New Sink: table.cellEditable


#1

cellEditable(row, column): true will set a specific table cell to be user-editable, overriding any other settings.

cellEditable(row, column): false will set a specific table cell to be user-editable, overriding any other settings.

You can change whether a cell is editable based on any test in CL, e.g:

cellContent(1,1): input.latex
cellEditable(1,1): isEmpty(input.latex)

#2

Nice! I’ve been waiting for this for an activity where I want students to either fill out a column in a table manually, one cell at a time, or all at once by entering an equation into a math input field.

Here’s the CL script, in case anyone wants to do something similar:

time = input9.timeSinceSubmit

cellContent(3,2): when time > 0 "${graph5.number("y_3")}" otherwise ""
cellContent(4,2): when time > 0.25 "${graph5.number("y_4")}" otherwise ""
cellContent(5,2): when time > 0.5 "${graph5.number("y_5")}" otherwise ""
cellContent(6,2): when time > 0.75 "${graph5.number("y_6")}" otherwise ""
cellContent(7,2): when time > 1 "${graph5.number("y_7")}" otherwise ""
cellContent(8,2): when time > 1.25 "${graph5.number("y_8")}" otherwise ""
cellContent(9,2): when time > 1.5 "${graph5.number("y_9")}" otherwise ""
cellContent(10,2): when time > 1.75 "${graph5.number("y_{10}")}" otherwise ""

cellEditable(3,2): time = 0
cellEditable(4,2): time = 0
cellEditable(5,2): time = 0
cellEditable(6,2): time = 0
cellEditable(7,2): time = 0
cellEditable(8,2): time = 0
cellEditable(9,2): time = 0
cellEditable(10,2): time = 0