qti3-item-player-vue3 0.1.2 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -76,9 +76,6 @@ npm run build
76
76
 
77
77
  ## Usage
78
78
 
79
- The [Demo TestRunner](https://github.com/amp-up-io/qti3-item-player-controller) is a good way to get familiar with QTI 3 Player usage. Specifically, please see the [TestRunner.vue](https://github.com/amp-up-io/qti3-item-player-controller/blob/main/src/views/TestRunner.vue) sub-component.
80
-
81
-
82
79
  ### 1. Import QTI 3 Player and QTI 3 Player CSS
83
80
 
84
81
  ```js
@@ -228,9 +225,14 @@ QTI 3 Player triggers a `notifyQti3ItemReady` event upon completion of the Playe
228
225
  * @description Event handler for the QTI3Player component's 'notifyQti3ItemReady'
229
226
  * event. This event is fired upon completion of the qti-assessment-item
230
227
  * component's loading of XML.
228
+ * The inner qti-assessment-item component is passed in the event.
229
+ * @param {Component} item - the qti-assessment-item component itself
231
230
  */
232
- handleItemReady () {
231
+ handleItemReady (item) {
233
232
  console.log('QTI 3 Item XML is loaded and rendered! The latest "attempt" has officially begun.')
233
+ // The item argument is the qti-assessment-item component
234
+ // with all exposed properties and methods.
235
+ this.item = item
234
236
  }
235
237
  ```
236
238
  <p align="right">(<a href="#top">back to top</a>)</p>
@@ -248,7 +250,7 @@ After item XML is loaded and an attempt has begun, a test controller may retriev
248
250
 
249
251
  * **suspendAttempt**
250
252
 
251
- This performs response validation (if `validateResponses: true`) and produces the state of all item variables. _No response processing is executed._ Typical use is when `submissionMode: "simultaneous"`.
253
+ This performs response validation (if `validateResponses: true`) and produces the state of all item variables. _No response processing is executed._ Typical use is when `submissionMode: "simultaneous"`.
252
254
 
253
255
  The `endAttempt` and `suspendAttempt` methods may take a considerable amount of time to complete. QTI 3 Player triggers the `notifyQti3EndAttemptCompleted` and `notifyQti3SuspendAttemptCompleted` events, respectively, upon completion of an `endAttempt` or a `suspendAttempt` method call.
254
256
 
@@ -722,7 +724,7 @@ Distributed under the MIT License. See `LICENSE` for more information.
722
724
 
723
725
  ## Built With
724
726
 
725
- The QTI3 Item Player is built with the Vue 3 (v3.4.34) framework.
727
+ The QTI3 Item Player is built with the Vue 3.4 (v3.4.34) framework and Vite.
726
728
 
727
729
  * [Vue.js](https://vuejs.org/)
728
730
 
@@ -749,5 +751,5 @@ This component would not be possible were it not for a fortuitous decision by th
749
751
  <p align="right">(<a href="#top">back to top</a>)</p>
750
752
 
751
753
 
752
- [license-shield]: https://img.shields.io/github/license/amp-up-io/qti3-item-player?label=License&style=for-the-badge
753
- [license-url]: https://github.com/amp-up-io/qti3-item-player/blob/main/LICENSE
754
+ [license-shield]: https://img.shields.io/github/license/amp-up-io/qti3-item-player-vue3?label=License&style=for-the-badge
755
+ [license-url]: https://github.com/amp-up-io/qti3-item-player-vue3/blob/main/LICENSE