View Source DeliveryElementProps
oli / Exports / DeliveryElementProps
Interface: DeliveryElementProps<T>
Delivery web component properties made available via the
render
method.
Type parameters
Name | Type |
---|---|
T | extends ActivityModelSchema |
Table of contents
Properties
Methods
- onReadUserState
- onRequestHint
- onResetActivity
- onResetPart
- onSaveActivity
- onSavePart
- onSubmitActivity
- onSubmitEvaluations
- onSubmitPart
- onWriteUserState
Properties
context
• context: ActivityContext
The larger context that this activity operates within.
Defined in
src/components/activities/DeliveryElement.ts:89
mode
• mode: DeliveryMode
The current delivery mode.
Defined in
src/components/activities/DeliveryElement.ts:94
model
• model: T
The model of the activity, pruned to remove the authoring specific portion.
Defined in
src/components/activities/DeliveryElement.ts:79
mountPoint
• Optional
mountPoint: HTMLElement
The HTML div element reference created by the abstract component for use in rendering by the concrete implementation.
Defined in
src/components/activities/DeliveryElement.ts:105
state
• state: ActivityState
The state of the activity and part attempts.
Defined in
src/components/activities/DeliveryElement.ts:84
Methods
onReadUserState
▸ Optional
onReadUserState(attemptGuid
, partAttemptGuid
, payload
): Promise
<any
>
Allows read access to the user state.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
payload | any |
Returns
Promise
<any
>
Defined in
src/components/activities/DeliveryElement.ts:110
onRequestHint
▸ onRequestHint(attemptGuid
, partAttemptGuid
): Promise
<RequestHintResponse
>
Requests a hint for a specific part.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
Returns
Promise
<RequestHintResponse
>
Defined in
src/components/activities/DeliveryElement.ts:138
onResetActivity
▸ onResetActivity(attemptGuid
): Promise
<ResetActivityResponse
>
Resets this activity attempt to create a new attempt.
Parameters
Name | Type |
---|---|
attemptGuid | string |
Returns
Promise
<ResetActivityResponse
>
Defined in
src/components/activities/DeliveryElement.ts:133
onResetPart
▸ onResetPart(attemptGuid
, partAttemptGuid
): Promise
<PartActivityResponse
>
Resets the attempt for one part.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
Returns
Promise
<PartActivityResponse
>
Defined in
src/components/activities/DeliveryElement.ts:161
onSaveActivity
▸ onSaveActivity(attemptGuid
, partResponses
): Promise
<Success
>
Initiates saving of the student response for all parts.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partResponses | PartResponse [] |
Returns
Promise
<Success
>
Defined in
src/components/activities/DeliveryElement.ts:120
onSavePart
▸ onSavePart(attemptGuid
, partAttemptGuid
, response
): Promise
<Success
>
Saves the state of a specific part.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
response | StudentResponse |
Returns
Promise
<Success
>
Defined in
src/components/activities/DeliveryElement.ts:143
onSubmitActivity
▸ onSubmitActivity(attemptGuid
, partResponses
): Promise
<EvaluationResponse
>
Submits all parts of the attempt for evaluation.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partResponses | PartResponse [] |
Returns
Promise
<EvaluationResponse
>
Defined in
src/components/activities/DeliveryElement.ts:125
onSubmitEvaluations
▸ onSubmitEvaluations(attemptGuid
, clientEvaluations
): Promise
<EvaluationResponse
>
Submits client-side evaluations.
Parameters
Name | Type |
---|---|
attemptGuid | string |
clientEvaluations | ClientEvaluation [] |
Returns
Promise
<EvaluationResponse
>
Defined in
src/components/activities/DeliveryElement.ts:166
onSubmitPart
▸ onSubmitPart(attemptGuid
, partAttemptGuid
, response
): Promise
<EvaluationResponse
>
Submits for evaluation one part.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
response | StudentResponse |
Returns
Promise
<EvaluationResponse
>
Defined in
src/components/activities/DeliveryElement.ts:152
onWriteUserState
▸ Optional
onWriteUserState(attemptGuid
, partAttemptGuid
, payload
): Promise
<any
>
Allows writing to the user state.
Parameters
Name | Type |
---|---|
attemptGuid | string |
partAttemptGuid | string |
payload | any |
Returns
Promise
<any
>