@citolab/qti-components 7.0.6-next.0 → 7.0.6
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/cdn/chunk-4DFVJE2A.js +48 -0
- package/cdn/chunk-4I75QSIL.js +8 -0
- package/cdn/chunk-5WCOPF7O.js +73 -0
- package/cdn/chunk-66PERJA3.js +939 -0
- package/cdn/chunk-6WNSQ7U6.js +939 -0
- package/cdn/chunk-A536ZOJJ.js +43 -0
- package/cdn/chunk-AT2C24P4.js +8 -0
- package/cdn/chunk-BLKKKK6C.js +11 -0
- package/cdn/chunk-DC2R556M.js +5 -0
- package/cdn/chunk-GALSGMIP.js +5 -0
- package/cdn/chunk-IXSX4SJX.js +1 -0
- package/cdn/chunk-KYOTSBCX.js +1 -0
- package/cdn/chunk-L4TDHAKL.js +24 -0
- package/cdn/chunk-M6AATWPS.js +59 -0
- package/cdn/{chunk-L26FOTPN.js → chunk-MFWSHIPH.js} +1 -1
- package/cdn/chunk-QGKK4T2J.js +8 -0
- package/cdn/chunk-ROXN2HIJ.js +8 -0
- package/cdn/chunk-SQDSHH6N.js +3539 -0
- package/cdn/chunk-TJMODUN5.js +8 -0
- package/cdn/chunk-Z6SKK5ZX.js +8 -0
- package/cdn/chunks/chunk-3V6LA7B3.js +8 -0
- package/cdn/chunks/chunk-4ILXLVT5.js +3545 -0
- package/cdn/chunks/chunk-4PEUIMDK.js +8 -0
- package/cdn/{chunk-DLMFCDQX.js → chunks/chunk-4UJBK6JO.js} +1 -1
- package/cdn/chunks/chunk-4WXQYE2P.js +8 -0
- package/cdn/chunks/chunk-5BR5CJFH.js +24 -0
- package/cdn/chunks/chunk-5FCXUJAG.js +23 -0
- package/cdn/chunks/chunk-5GCSZ3CH.js +73 -0
- package/cdn/chunks/chunk-5P7CTN7Q.js +11 -0
- package/cdn/chunks/chunk-5X76K77R.js +8 -0
- package/cdn/chunks/chunk-6MCYE7P5.js +1 -0
- package/cdn/chunks/chunk-6S4CDN3T.js +43 -0
- package/cdn/chunks/chunk-76VGZJCP.js +934 -0
- package/cdn/chunks/chunk-7XYBFL7U.js +934 -0
- package/cdn/chunks/chunk-AJJJAZWM.js +1 -0
- package/cdn/chunks/chunk-ARHBUT6F.js +5 -0
- package/cdn/chunks/chunk-AUHO2E7V.js +934 -0
- package/cdn/chunks/chunk-CZ3CSGCE.js +934 -0
- package/cdn/chunks/chunk-D3GR6AUG.js +43 -0
- package/cdn/chunks/chunk-DZCKF45D.js +5 -0
- package/cdn/chunks/chunk-EFU4L43Q.js +8 -0
- package/cdn/chunks/chunk-FM5C34DM.js +934 -0
- package/cdn/chunks/chunk-FRS2J3OS.js +59 -0
- package/cdn/chunks/chunk-GMK2YRB2.js +934 -0
- package/cdn/chunks/chunk-H2V2RXUW.js +11 -0
- package/cdn/chunks/chunk-HUMOYGEM.js +43 -0
- package/cdn/chunks/chunk-IAP2CEE7.js +1 -0
- package/cdn/chunks/chunk-IMJOPCFR.js +1 -0
- package/cdn/chunks/chunk-IQZ7AOCQ.js +8 -0
- package/cdn/chunks/chunk-J3JSSCM6.js +5 -0
- package/cdn/chunks/chunk-KHLUVO6Y.js +8 -0
- package/cdn/chunks/chunk-KWPDTFYH.js +1 -0
- package/cdn/chunks/chunk-L4CUWIE6.js +17 -0
- package/cdn/chunks/chunk-LARBLB7K.js +8 -0
- package/cdn/chunks/chunk-LNFCEHB3.js +934 -0
- package/cdn/chunks/chunk-LZZB4VGC.js +48 -0
- package/cdn/chunks/chunk-MJMONWKB.js +3539 -0
- package/cdn/chunks/chunk-N5OHGRGG.js +8 -0
- package/cdn/chunks/chunk-NDHSIO2G.js +8 -0
- package/cdn/chunks/chunk-NRY3WHJD.js +5 -0
- package/cdn/chunks/chunk-PKT2SJQD.js +8 -0
- package/cdn/chunks/chunk-PPWEIKLT.js +1 -0
- package/cdn/chunks/chunk-PT523RSK.js +8 -0
- package/cdn/chunks/chunk-QD3NT5PG.js +934 -0
- package/cdn/chunks/chunk-QQCGUVEV.js +1 -0
- package/cdn/chunks/chunk-QTK4CPHP.js +8 -0
- package/cdn/chunks/chunk-QV6I5NVQ.js +8 -0
- package/cdn/chunks/chunk-R33OODNX.js +1 -0
- package/cdn/chunks/chunk-RIXTWE2H.js +8 -0
- package/cdn/chunks/chunk-ROZIP5LG.js +8 -0
- package/cdn/chunks/chunk-RPZVSBLM.js +8 -0
- package/cdn/chunks/chunk-RXKI3AO4.js +1 -0
- package/cdn/chunks/chunk-SXM25YH3.js +934 -0
- package/cdn/chunks/chunk-T2KKTMAT.js +934 -0
- package/cdn/chunks/chunk-TEYXRLTI.js +8 -0
- package/cdn/chunks/chunk-TQBDBMWL.js +5 -0
- package/cdn/chunks/chunk-TV3SPOLH.js +8 -0
- package/cdn/chunks/chunk-TVDTF6P6.js +934 -0
- package/cdn/chunks/chunk-U2TE6TOV.js +934 -0
- package/cdn/chunks/chunk-UJP4TGD3.js +1 -0
- package/cdn/chunks/chunk-W5Y3ZU2W.js +5 -0
- package/cdn/chunks/chunk-WPGJ54IP.js +1 -0
- package/cdn/chunks/chunk-X2KBNXRO.js +6 -0
- package/cdn/chunks/chunk-YHWMZAZD.js +43 -0
- package/cdn/chunks/chunk-YVZ742ID.js +934 -0
- package/cdn/chunks/chunk-YWH4TGMA.js +5 -0
- package/cdn/chunks/chunk-YXR6KSZI.js +11 -0
- package/cdn/exports/interaction.js +1 -0
- package/cdn/exports/item.context.js +1 -0
- package/cdn/exports/qti-assessment-item.context.js +1 -0
- package/cdn/exports/qti-condition-expression.js +1 -0
- package/cdn/exports/qti-expression.js +1 -0
- package/cdn/index.global.js +56 -107
- package/cdn/index.js +1 -1
- package/cdn/qti-components/index.global.js +1 -1
- package/cdn/qti-components/index.js +1 -1
- package/cdn/qti-item/components/index.js +3549 -1
- package/cdn/qti-item/components/item-container.js +3549 -1
- package/cdn/qti-item/core/index.global.js +149 -0
- package/cdn/qti-item/core/index.js +1 -0
- package/cdn/qti-item/index.js +3549 -1
- package/cdn/qti-item/qti-item.js +1 -1
- package/cdn/qti-loader/index.js +1 -1
- package/cdn/qti-test/components/index.global.js +1 -36
- package/cdn/qti-test/components/index.js +1 -1
- package/cdn/qti-test/components/styles.js +1 -1
- package/cdn/qti-test/components/test-component.abstract.js +1 -1
- package/cdn/qti-test/components/test-container.js +3549 -1
- package/cdn/qti-test/components/test-end-attempt.js +1 -0
- package/cdn/qti-test/components/test-item-link.js +1 -1
- package/cdn/qti-test/components/test-next.js +1 -1
- package/cdn/qti-test/components/test-next.spec.css +1 -0
- package/cdn/qti-test/components/test-next.spec.global.js +1 -234
- package/cdn/qti-test/components/test-next.spec.js +240 -240
- package/cdn/qti-test/components/test-paging-buttons-stamp.js +1 -1
- package/cdn/qti-test/components/test-prev.js +1 -1
- package/cdn/qti-test/components/test-show-correct-response.js +1 -0
- package/cdn/qti-test/components/test-view.js +1 -1
- package/cdn/qti-test/context/index.js +1 -1
- package/cdn/qti-test/context/test.context.js +1 -1
- package/cdn/qti-test/core/index.global.js +205 -0
- package/cdn/qti-test/core/index.js +1 -0
- package/cdn/qti-test/index.js +3598 -1
- package/cdn/qti-test/mixins/index.js +23 -1
- package/cdn/qti-test/mixins/test-loader.mixin.js +23 -1
- package/cdn/qti-test/mixins/test-navigation.mixin.js +1 -1
- package/cdn/qti-test/mixins/test-view.mixin.js +1 -1
- package/cdn/qti-test/qti-assessment-test/index.js +1 -1
- package/cdn/qti-test/qti-assessment-test/qti-assessment-item-ref.js +1 -1
- package/cdn/qti-test/qti-assessment-test/qti-assessment-section.js +1 -1
- package/cdn/qti-test/qti-assessment-test/qti-assessment-test.js +1 -1
- package/cdn/qti-test/qti-assessment-test/qti-test-part.js +1 -1
- package/cdn/qti-test/qti-test.js +23 -1
- package/cdn/qti-test/test-base.js +1 -1
- package/cdn/qti-transformers/index.js +1 -1
- package/dist/{chunk-3WLCQQN7.js → chunk-2CHF3TMY.js} +2 -2
- package/dist/chunk-2CHF3TMY.js.map +1 -0
- package/dist/chunk-2LWLX7WV.js +6307 -0
- package/dist/chunk-2LWLX7WV.js.map +1 -0
- package/dist/{chunk-VODOQFTJ.js → chunk-3G364JZC.js} +2 -2
- package/dist/chunk-6TUE644E.js +569 -0
- package/dist/chunk-6TUE644E.js.map +1 -0
- package/dist/{chunk-JDHBXMKF.js → chunk-6ZMD232X.js} +2 -2
- package/dist/{chunk-L7MBIXEX.js → chunk-AYRSHIHA.js} +4 -4
- package/dist/{chunk-GTYLWGDG.js → chunk-BN32D5J2.js} +4 -4
- package/dist/{chunk-TXRSYXG3.js → chunk-CJRXRBRQ.js} +4 -4
- package/dist/{chunk-ENVUIH2A.js → chunk-GPJ6WTE5.js} +5 -5
- package/dist/chunk-GPJ6WTE5.js.map +1 -0
- package/dist/chunk-KAUHKHPH.js +50 -0
- package/dist/chunk-KAUHKHPH.js.map +1 -0
- package/dist/chunk-MAC76UNI.js +1 -0
- package/dist/{chunk-XNBWN7N2.js → chunk-QYN5S4EM.js} +20 -7
- package/dist/chunk-QYN5S4EM.js.map +1 -0
- package/dist/chunk-UJTJIU3C.js +43 -0
- package/dist/chunk-UJTJIU3C.js.map +1 -0
- package/dist/chunk-XVQZ5JI5.js +50 -0
- package/dist/chunk-XVQZ5JI5.js.map +1 -0
- package/dist/{chunk-EUCEENQQ.js → chunk-XW3PQRKW.js} +100 -47
- package/dist/chunk-XW3PQRKW.js.map +1 -0
- package/dist/{chunk-R4HSV7U7.js → chunk-YQ7EXOAK.js} +2 -2
- package/dist/chunk-YQ7EXOAK.js.map +1 -0
- package/dist/chunks/chunk-2V6LQV2K.js +50 -0
- package/dist/chunks/chunk-2V6LQV2K.js.map +1 -0
- package/dist/chunks/chunk-3EU75IUF.js +118 -0
- package/dist/chunks/chunk-3EU75IUF.js.map +1 -0
- package/dist/chunks/chunk-3QQFMVDS.js +118 -0
- package/dist/chunks/chunk-3QQFMVDS.js.map +1 -0
- package/dist/chunks/chunk-4GNVYCBN.js +627 -0
- package/dist/chunks/chunk-4GNVYCBN.js.map +1 -0
- package/dist/chunks/chunk-4MQV5IRV.js +59 -0
- package/dist/chunks/chunk-4MQV5IRV.js.map +1 -0
- package/dist/chunks/chunk-4O5F7WV7.js +30 -0
- package/dist/chunks/chunk-4O5F7WV7.js.map +1 -0
- package/dist/chunks/chunk-4WVLWWYJ.js +50 -0
- package/dist/chunks/chunk-4WVLWWYJ.js.map +1 -0
- package/dist/chunks/chunk-5KVGRLYT.js +10 -0
- package/dist/chunks/chunk-5KVGRLYT.js.map +1 -0
- package/dist/chunks/chunk-5PCD2B62.js +6091 -0
- package/dist/chunks/chunk-5PCD2B62.js.map +1 -0
- package/dist/chunks/chunk-5RTLOB3Q.js +59 -0
- package/dist/chunks/chunk-5RTLOB3Q.js.map +1 -0
- package/dist/chunks/chunk-6JXR63MH.js +50 -0
- package/dist/chunks/chunk-6JXR63MH.js.map +1 -0
- package/dist/chunks/chunk-6PAEJQSQ.js +6058 -0
- package/dist/chunks/chunk-6PAEJQSQ.js.map +1 -0
- package/dist/chunks/chunk-6QT4LIPL.js +623 -0
- package/dist/chunks/chunk-6QT4LIPL.js.map +1 -0
- package/dist/chunks/chunk-7QMCKYDR.js +43 -0
- package/dist/chunks/chunk-7QMCKYDR.js.map +1 -0
- package/dist/chunks/chunk-A24F75DB.js +72 -0
- package/dist/chunks/chunk-A24F75DB.js.map +1 -0
- package/dist/chunks/chunk-AUWATZ65.js +10 -0
- package/dist/chunks/chunk-AUWATZ65.js.map +1 -0
- package/dist/chunks/chunk-AXTEKPP5.js +6084 -0
- package/dist/chunks/chunk-AXTEKPP5.js.map +1 -0
- package/dist/chunks/chunk-B6MJCAOF.js +6063 -0
- package/dist/chunks/chunk-B6MJCAOF.js.map +1 -0
- package/dist/chunks/chunk-BJ2JLJIJ.js +623 -0
- package/dist/chunks/chunk-BJ2JLJIJ.js.map +1 -0
- package/dist/chunks/chunk-BPHQLJWE.js +102 -0
- package/dist/chunks/chunk-BPHQLJWE.js.map +1 -0
- package/dist/chunks/chunk-CD3E4M5Y.js +107 -0
- package/dist/chunks/chunk-CD3E4M5Y.js.map +1 -0
- package/dist/chunks/chunk-CEXAR7BF.js +52 -0
- package/dist/chunks/chunk-CEXAR7BF.js.map +1 -0
- package/dist/chunks/chunk-CWYAQA25.js +6067 -0
- package/dist/chunks/chunk-CWYAQA25.js.map +1 -0
- package/dist/chunks/chunk-D3QX5N57.js +6117 -0
- package/dist/chunks/chunk-D3QX5N57.js.map +1 -0
- package/dist/{chunk-4CSM2PCC.js → chunks/chunk-D3RGDWKP.js} +1 -1
- package/dist/chunks/chunk-D3RGDWKP.js.map +1 -0
- package/dist/chunks/chunk-DLUJN2FW.js +22 -0
- package/dist/chunks/chunk-DLUJN2FW.js.map +1 -0
- package/dist/chunks/chunk-DNHDFXTV.js +59 -0
- package/dist/chunks/chunk-DNHDFXTV.js.map +1 -0
- package/dist/chunks/chunk-E4TWZ2DL.js +6088 -0
- package/dist/chunks/chunk-E4TWZ2DL.js.map +1 -0
- package/dist/chunks/chunk-ELDMXTUQ.js +31 -0
- package/dist/chunks/chunk-ELDMXTUQ.js.map +1 -0
- package/dist/{chunk-IAFQ5ZPI.js → chunks/chunk-FV7HWK54.js} +2 -2
- package/dist/chunks/chunk-FV7HWK54.js.map +1 -0
- package/dist/chunks/chunk-GQ5P3NWC.js +46 -0
- package/dist/chunks/chunk-GQ5P3NWC.js.map +1 -0
- package/dist/chunks/chunk-GSWZT6N2.js +50 -0
- package/dist/chunks/chunk-GSWZT6N2.js.map +1 -0
- package/dist/chunks/chunk-H2JE6IVU.js +15 -0
- package/dist/chunks/chunk-HHVRU3AJ.js +107 -0
- package/dist/chunks/chunk-HHVRU3AJ.js.map +1 -0
- package/dist/chunks/chunk-HOTNM5DT.js +1 -0
- package/dist/chunks/chunk-IWG66KQQ.js +107 -0
- package/dist/chunks/chunk-IWG66KQQ.js.map +1 -0
- package/{cdn/chunk-Y63VPWCG.js → dist/chunks/chunk-J2SHENRN.js} +8 -2
- package/dist/chunks/chunk-J2SHENRN.js.map +1 -0
- package/dist/chunks/chunk-K6ATVWMP.js +6091 -0
- package/dist/chunks/chunk-K6ATVWMP.js.map +1 -0
- package/dist/chunks/chunk-KOEILLVS.js +8 -0
- package/dist/chunks/chunk-KOEILLVS.js.map +1 -0
- package/dist/chunks/chunk-KYAIMBP5.js +78 -0
- package/dist/chunks/chunk-KYAIMBP5.js.map +1 -0
- package/dist/chunks/chunk-LNISKMIL.js +6063 -0
- package/dist/chunks/chunk-LNISKMIL.js.map +1 -0
- package/dist/chunks/chunk-LNKJEW5E.js +627 -0
- package/dist/chunks/chunk-LNKJEW5E.js.map +1 -0
- package/dist/chunks/chunk-LXJA3VP2.js +72 -0
- package/dist/chunks/chunk-LXJA3VP2.js.map +1 -0
- package/dist/chunks/chunk-MLT7V47R.js +100 -0
- package/dist/chunks/chunk-MLT7V47R.js.map +1 -0
- package/dist/chunks/chunk-N5FPZNMX.js +43 -0
- package/dist/chunks/chunk-N5FPZNMX.js.map +1 -0
- package/dist/chunks/chunk-NHA53UTY.js +52 -0
- package/dist/chunks/chunk-NHA53UTY.js.map +1 -0
- package/dist/chunks/chunk-NZQKGIJP.js +3535 -0
- package/dist/chunks/chunk-NZQKGIJP.js.map +1 -0
- package/dist/chunks/chunk-O6WEZVEM.js +43 -0
- package/dist/chunks/chunk-O6WEZVEM.js.map +1 -0
- package/dist/chunks/chunk-OIRWOI3E.js +72 -0
- package/dist/chunks/chunk-OIRWOI3E.js.map +1 -0
- package/dist/chunks/chunk-PWOY6REC.js +6064 -0
- package/dist/chunks/chunk-PWOY6REC.js.map +1 -0
- package/dist/chunks/chunk-QJELKGWM.js +6061 -0
- package/dist/chunks/chunk-QJELKGWM.js.map +1 -0
- package/dist/chunks/chunk-QUB54PXZ.js +50 -0
- package/dist/chunks/chunk-QUB54PXZ.js.map +1 -0
- package/dist/chunks/chunk-RX3BRYYI.js +59 -0
- package/dist/chunks/chunk-RX3BRYYI.js.map +1 -0
- package/dist/chunks/chunk-UEEMM6H2.js +6090 -0
- package/dist/chunks/chunk-UEEMM6H2.js.map +1 -0
- package/dist/chunks/chunk-UFYWCLXF.js +10 -0
- package/dist/chunks/chunk-UFYWCLXF.js.map +1 -0
- package/dist/chunks/chunk-UN2IFSGC.js +1 -0
- package/dist/chunks/chunk-VAPB5TN4.js +46 -0
- package/dist/chunks/chunk-VAPB5TN4.js.map +1 -0
- package/dist/chunks/chunk-VBF3GCZK.js +50 -0
- package/dist/chunks/chunk-VBF3GCZK.js.map +1 -0
- package/dist/chunks/chunk-W4272Q5U.js +46 -0
- package/dist/chunks/chunk-W4272Q5U.js.map +1 -0
- package/dist/chunks/chunk-WWN5AD6V.js +81 -0
- package/dist/chunks/chunk-WWN5AD6V.js.map +1 -0
- package/dist/chunks/chunk-X226BX2U.js +78 -0
- package/dist/chunks/chunk-X226BX2U.js.map +1 -0
- package/dist/chunks/chunk-XCHS3RTZ.js +107 -0
- package/dist/chunks/chunk-XCHS3RTZ.js.map +1 -0
- package/dist/chunks/chunk-XDMSEAYC.js +294 -0
- package/dist/chunks/chunk-XDMSEAYC.js.map +1 -0
- package/dist/chunks/chunk-XSI6FXGD.js +19 -0
- package/dist/chunks/chunk-XSI6FXGD.js.map +1 -0
- package/dist/chunks/chunk-YFC3BVN2.js +78 -0
- package/dist/chunks/chunk-YFC3BVN2.js.map +1 -0
- package/dist/chunks/chunk-YOXF6JPS.js +623 -0
- package/dist/chunks/chunk-YOXF6JPS.js.map +1 -0
- package/dist/chunks/chunk-YQB6YLNW.js +78 -0
- package/dist/chunks/chunk-YQB6YLNW.js.map +1 -0
- package/dist/chunks/chunk-Z5THRO6Z.js +46 -0
- package/dist/chunks/chunk-Z5THRO6Z.js.map +1 -0
- package/dist/chunks/chunk-ZHAJ3CMP.js +6091 -0
- package/dist/chunks/chunk-ZHAJ3CMP.js.map +1 -0
- package/dist/chunks/chunk-ZPNJ2HP5.js +71 -0
- package/dist/chunks/chunk-ZPNJ2HP5.js.map +1 -0
- package/dist/chunks/chunk-ZQXZ6PK7.js +649 -0
- package/dist/chunks/chunk-ZQXZ6PK7.js.map +1 -0
- package/dist/custom-element-eslint-rules.js +337 -0
- package/dist/custom-elements.json +27158 -0
- package/dist/exports/expression-result.d.ts +19 -0
- package/dist/exports/expression-result.js +1 -0
- package/dist/exports/interaction.d.ts +23 -0
- package/dist/exports/interaction.interface.d.ts +13 -0
- package/dist/exports/interaction.interface.js +1 -0
- package/dist/exports/interaction.js +8 -0
- package/dist/exports/item.context.d.ts +12 -0
- package/dist/exports/item.context.js +8 -0
- package/dist/exports/qti-assessment-item.context.d.ts +10 -0
- package/dist/exports/qti-assessment-item.context.js +8 -0
- package/dist/exports/qti-assessment-item.context.js.map +1 -0
- package/dist/exports/qti-condition-expression.d.ts +13 -0
- package/dist/exports/qti-condition-expression.js +10 -0
- package/dist/exports/qti-condition-expression.js.map +1 -0
- package/dist/exports/qti-expression.d.ts +21 -0
- package/dist/exports/qti-expression.js +9 -0
- package/dist/exports/qti-expression.js.map +1 -0
- package/dist/exports/variables.d.ts +3 -0
- package/dist/exports/variables.js +1 -0
- package/dist/exports/variables.js.map +1 -0
- package/dist/index.d.ts +14 -8
- package/dist/index.js +41 -63
- package/dist/item.css +8 -2
- package/dist/loader/index.d.ts +20 -0
- package/dist/loader/index.js +310 -0
- package/dist/loader/index.js.map +1 -0
- package/dist/qti-components/index.cjs +6773 -0
- package/dist/qti-components/index.cjs.map +1 -0
- package/dist/qti-components/index.d.cts +150 -0
- package/dist/qti-components/index.d.ts +36 -9
- package/dist/qti-components/index.js +10 -17
- package/dist/qti-components-jsx.d.ts +360 -639
- package/dist/qti-item/components/index.js +3852 -8
- package/dist/qti-item/components/index.js.map +1 -1
- package/dist/qti-item/components/item-container.js +3852 -7
- package/dist/qti-item/components/item-container.js.map +1 -1
- package/dist/qti-item/core/index.d.ts +61 -0
- package/dist/qti-item/core/index.js +13 -0
- package/dist/qti-item/core/index.js.map +1 -0
- package/dist/qti-item/index.cjs +89 -0
- package/dist/qti-item/index.cjs.map +1 -0
- package/dist/qti-item/index.d.cts +24 -0
- package/dist/qti-item/index.js +3864 -12
- package/dist/qti-item/index.js.map +1 -1
- package/dist/qti-item/qti-item.js +22 -4
- package/dist/qti-item/qti-item.js.map +1 -1
- package/dist/qti-loader/index.cjs +332 -0
- package/dist/qti-loader/index.cjs.map +1 -0
- package/dist/qti-loader/index.d.cts +20 -0
- package/dist/qti-loader/index.d.ts +7 -1
- package/dist/qti-loader/index.js +3 -3
- package/dist/qti-response-declaration-DAeBp8HH.d.ts +1008 -0
- package/dist/qti-response-declaration-Di9CsqiJ.d.ts +1012 -0
- package/dist/qti-response-declaration-ucAqd0qK.d.ts +1034 -0
- package/dist/qti-simple-choice-3M44uWiN.d.ts +1153 -0
- package/dist/qti-simple-choice-B5GnzbqW.d.ts +1080 -0
- package/dist/qti-simple-choice-BOLF9wXz.d.ts +1170 -0
- package/dist/qti-simple-choice-BeixIkA0.d.ts +1088 -0
- package/dist/qti-simple-choice-BiEjEO6s.d.ts +1152 -0
- package/dist/qti-simple-choice-Bo_ikO6H.d.ts +1198 -0
- package/dist/qti-simple-choice-C0CcrtK5.d.ts +1169 -0
- package/dist/qti-simple-choice-Cgh1-Jbr.d.cts +1185 -0
- package/dist/qti-simple-choice-Cgh1-Jbr.d.ts +1185 -0
- package/dist/qti-simple-choice-Cn5y-Ta8.d.ts +1158 -0
- package/dist/qti-simple-choice-D0GiMrqD.d.ts +1168 -0
- package/dist/qti-simple-choice-R_LxBTp8.d.ts +1158 -0
- package/dist/qti-simple-choice-hAIyfF0z.d.ts +1114 -0
- package/dist/qti-simple-choice-o4rje1RA.d.ts +1176 -0
- package/dist/qti-simple-choice-v2GxpPNh.d.ts +1181 -0
- package/dist/qti-test/components/index.d.ts +10 -4
- package/dist/qti-test/components/index.js +19 -18
- package/dist/qti-test/components/styles.js +2 -2
- package/dist/qti-test/components/test-component.abstract.d.ts +8 -5
- package/dist/qti-test/components/test-component.abstract.js +5 -6
- package/dist/qti-test/components/test-container.js +3778 -7
- package/dist/qti-test/components/test-container.js.map +1 -1
- package/dist/qti-test/components/test-end-attempt.d.ts +26 -0
- package/dist/qti-test/components/test-end-attempt.js +13 -0
- package/dist/qti-test/components/test-end-attempt.js.map +1 -0
- package/dist/qti-test/components/test-item-link.d.ts +9 -3
- package/dist/qti-test/components/test-item-link.js +7 -8
- package/dist/qti-test/components/test-next.d.ts +9 -3
- package/dist/qti-test/components/test-next.js +7 -8
- package/dist/qti-test/components/test-next.spec.css +2481 -0
- package/dist/qti-test/components/test-next.spec.css.map +1 -0
- package/dist/qti-test/components/test-next.spec.d.ts +4 -7
- package/dist/qti-test/components/test-next.spec.js +13 -32
- package/dist/qti-test/components/test-next.spec.js.map +1 -1
- package/dist/qti-test/components/test-paging-buttons-stamp.d.ts +8 -3
- package/dist/qti-test/components/test-paging-buttons-stamp.js +6 -7
- package/dist/qti-test/components/test-prev.d.ts +9 -3
- package/dist/qti-test/components/test-prev.js +7 -8
- package/dist/qti-test/components/test-show-correct-response.d.ts +26 -0
- package/dist/qti-test/components/test-show-correct-response.js +13 -0
- package/dist/qti-test/components/test-show-correct-response.js.map +1 -0
- package/dist/qti-test/components/test-view.d.ts +9 -3
- package/dist/qti-test/components/test-view.js +6 -7
- package/dist/qti-test/context/index.js +4 -6
- package/dist/qti-test/context/index.js.map +1 -1
- package/dist/qti-test/context/test.context.js +4 -5
- package/dist/qti-test/context/test.context.js.map +1 -1
- package/dist/qti-test/core/index.d.ts +132 -0
- package/dist/qti-test/core/index.js +27 -0
- package/dist/qti-test/core/index.js.map +1 -0
- package/dist/qti-test/index.cjs +4823 -0
- package/dist/qti-test/index.cjs.map +1 -0
- package/dist/qti-test/index.d.cts +304 -0
- package/dist/qti-test/index.js +4729 -55
- package/dist/qti-test/index.js.map +1 -1
- package/dist/qti-test/mixins/index.js +344 -12
- package/dist/qti-test/mixins/index.js.map +1 -1
- package/dist/qti-test/mixins/test-loader.mixin.js +236 -5
- package/dist/qti-test/mixins/test-loader.mixin.js.map +1 -1
- package/dist/qti-test/mixins/test-navigation.mixin.js +60 -4
- package/dist/qti-test/mixins/test-navigation.mixin.js.map +1 -1
- package/dist/qti-test/mixins/test-view.mixin.js +46 -4
- package/dist/qti-test/mixins/test-view.mixin.js.map +1 -1
- package/dist/qti-test/qti-assessment-test/index.js +214 -16
- package/dist/qti-test/qti-assessment-test/index.js.map +1 -1
- package/dist/qti-test/qti-assessment-test/qti-assessment-item-ref.js +81 -6
- package/dist/qti-test/qti-assessment-test/qti-assessment-item-ref.js.map +1 -1
- package/dist/qti-test/qti-assessment-test/qti-assessment-section.js +69 -6
- package/dist/qti-test/qti-assessment-test/qti-assessment-section.js.map +1 -1
- package/dist/qti-test/qti-assessment-test/qti-assessment-test.js +50 -6
- package/dist/qti-test/qti-assessment-test/qti-assessment-test.js.map +1 -1
- package/dist/qti-test/qti-assessment-test/qti-test-part.js +58 -4
- package/dist/qti-test/qti-assessment-test/qti-test-part.js.map +1 -1
- package/dist/qti-test/qti-test.js +496 -12
- package/dist/qti-test/qti-test.js.map +1 -1
- package/dist/qti-test/test-base.js +133 -6
- package/dist/qti-test/test-base.js.map +1 -1
- package/dist/qti-transformers/index.cjs +316 -0
- package/dist/qti-transformers/index.cjs.map +1 -0
- package/dist/qti-transformers/index.d.cts +75 -0
- package/dist/qti-transformers/index.js +2 -2
- package/dist/test.context-Bx-606B3.d.ts +99 -0
- package/dist/test.context-C2LBA3w4.d.ts +101 -0
- package/dist/test.context-CB5V4xJz.d.ts +99 -0
- package/dist/test.context-CaENAJNk.d.ts +101 -0
- package/dist/test.context-CmsDQ8k2.d.ts +99 -0
- package/dist/transformers/index.d.ts +76 -0
- package/dist/transformers/index.js +293 -0
- package/dist/transformers/index.js.map +1 -0
- package/dist/variables-cO3DzqJy.d.ts +33 -0
- package/dist/vscode.html-custom-data.json +247 -295
- package/package.json +83 -76
- package/cdn/chunk-3DWLPGTE.js +0 -1
- package/cdn/chunk-7BKWTY4S.js +0 -1
- package/cdn/chunk-7CQ4ETXL.js +0 -1
- package/cdn/chunk-7ENNZNJ4.js +0 -1
- package/cdn/chunk-7LGM2TQA.js +0 -1
- package/cdn/chunk-DPR6SGCZ.js +0 -1
- package/cdn/chunk-EQGXFSYL.js +0 -8
- package/cdn/chunk-F5VW77RE.js +0 -1
- package/cdn/chunk-FNVXN5CO.js +0 -1
- package/cdn/chunk-GBB54IPA.js +0 -8
- package/cdn/chunk-IV7UP34N.js +0 -5
- package/cdn/chunk-JNT54FPI.js +0 -1
- package/cdn/chunk-JS4S7ZI7.js +0 -1
- package/cdn/chunk-POT65ZY7.js +0 -1
- package/cdn/chunk-Q7PVZA43.js +0 -5
- package/cdn/chunk-QJPHXAUE.js +0 -1
- package/cdn/chunk-QP57JHGY.js +0 -11
- package/cdn/chunk-RB6CONZW.js +0 -3
- package/cdn/chunk-RSRX5JYB.js +0 -1
- package/cdn/chunk-TG6AE3DB.js +0 -0
- package/cdn/chunk-V6YPUNZC.js +0 -0
- package/cdn/chunk-W7X6GNEX.js +0 -902
- package/cdn/chunk-ZEX7TYC7.js +0 -8
- package/dist/chunk-37X6KZO3.js +0 -1
- package/dist/chunk-3WLCQQN7.js.map +0 -1
- package/dist/chunk-3YVIK6LO.js +0 -1
- package/dist/chunk-4CSM2PCC.js.map +0 -1
- package/dist/chunk-7A6KCSAU.js +0 -44
- package/dist/chunk-7A6KCSAU.js.map +0 -1
- package/dist/chunk-ENVUIH2A.js.map +0 -1
- package/dist/chunk-ENZVY5X6.js +0 -20
- package/dist/chunk-ENZVY5X6.js.map +0 -1
- package/dist/chunk-EUCEENQQ.js.map +0 -1
- package/dist/chunk-FNFNAV3G.js +0 -56
- package/dist/chunk-FNFNAV3G.js.map +0 -1
- package/dist/chunk-GSFDTSLL.js +0 -1
- package/dist/chunk-IAFQ5ZPI.js.map +0 -1
- package/dist/chunk-LYFMLDNV.js +0 -1
- package/dist/chunk-NNPTSZGC.js +0 -1
- package/dist/chunk-NQM35JUI.js +0 -1
- package/dist/chunk-ODUHPWTX.js +0 -65
- package/dist/chunk-ODUHPWTX.js.map +0 -1
- package/dist/chunk-OGHHCP23.js +0 -36
- package/dist/chunk-OGHHCP23.js.map +0 -1
- package/dist/chunk-OQZW2B47.js +0 -75
- package/dist/chunk-OQZW2B47.js.map +0 -1
- package/dist/chunk-OXDOQVRL.js +0 -63
- package/dist/chunk-OXDOQVRL.js.map +0 -1
- package/dist/chunk-PBSMP6VF.js +0 -128
- package/dist/chunk-PBSMP6VF.js.map +0 -1
- package/dist/chunk-Q7OPFS4A.js +0 -1
- package/dist/chunk-R4HSV7U7.js.map +0 -1
- package/dist/chunk-U3RLYKL5.js +0 -51
- package/dist/chunk-U3RLYKL5.js.map +0 -1
- package/dist/chunk-VW7VIQBE.js +0 -34
- package/dist/chunk-VW7VIQBE.js.map +0 -1
- package/dist/chunk-X4ZBUCOD.js +0 -94
- package/dist/chunk-X4ZBUCOD.js.map +0 -1
- package/dist/chunk-XFHB6KQW.js +0 -1
- package/dist/chunk-XNBWN7N2.js.map +0 -1
- /package/cdn/{chunk-CYJMNT76.js → chunk-22HAPLRD.js} +0 -0
- /package/cdn/{chunk-GB7DLBFM.js → chunks/chunk-3GO57DNP.js} +0 -0
- /package/cdn/{chunk-H4A34YRT.js → chunks/chunk-6PW2L463.js} +0 -0
- /package/cdn/{chunk-GPDDPZFH.js → chunks/chunk-EHK76KRT.js} +0 -0
- /package/cdn/{chunk-25BMUTLC.js → chunks/chunk-XUJ7TXHW.js} +0 -0
- /package/cdn/{chunk-ITXNNGVQ.js → exports/expression-result.js} +0 -0
- /package/cdn/{chunk-IZZ36JQV.js → exports/interaction.interface.js} +0 -0
- /package/cdn/{chunk-LA7TBIPQ.js → exports/variables.js} +0 -0
- /package/dist/{chunk-VODOQFTJ.js.map → chunk-3G364JZC.js.map} +0 -0
- /package/dist/{chunk-JDHBXMKF.js.map → chunk-6ZMD232X.js.map} +0 -0
- /package/dist/{chunk-L7MBIXEX.js.map → chunk-AYRSHIHA.js.map} +0 -0
- /package/dist/{chunk-GTYLWGDG.js.map → chunk-BN32D5J2.js.map} +0 -0
- /package/dist/{chunk-TXRSYXG3.js.map → chunk-CJRXRBRQ.js.map} +0 -0
- /package/dist/{chunk-37X6KZO3.js.map → chunk-MAC76UNI.js.map} +0 -0
- /package/dist/{chunk-3YVIK6LO.js.map → chunks/chunk-H2JE6IVU.js.map} +0 -0
- /package/dist/{chunk-GSFDTSLL.js.map → chunks/chunk-HOTNM5DT.js.map} +0 -0
- /package/dist/{chunk-LYFMLDNV.js.map → chunks/chunk-UN2IFSGC.js.map} +0 -0
- /package/dist/{chunk-NNPTSZGC.js.map → exports/expression-result.js.map} +0 -0
- /package/dist/{chunk-NQM35JUI.js.map → exports/interaction.interface.js.map} +0 -0
- /package/dist/{chunk-Q7OPFS4A.js.map → exports/interaction.js.map} +0 -0
- /package/dist/{chunk-XFHB6KQW.js.map → exports/item.context.js.map} +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
TestComponent
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
4
4
|
import {
|
|
5
5
|
__decorateClass
|
|
6
6
|
} from "./chunk-44VE5POH.js";
|
|
@@ -75,4 +75,4 @@ TestPagingButtonsStamp = __decorateClass([
|
|
|
75
75
|
export {
|
|
76
76
|
TestPagingButtonsStamp
|
|
77
77
|
};
|
|
78
|
-
//# sourceMappingURL=chunk-
|
|
78
|
+
//# sourceMappingURL=chunk-6ZMD232X.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import {
|
|
2
|
+
TestComponent
|
|
3
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
1
4
|
import {
|
|
2
5
|
btn,
|
|
3
6
|
dis
|
|
4
7
|
} from "./chunk-UB5K44DB.js";
|
|
5
|
-
import {
|
|
6
|
-
TestComponent
|
|
7
|
-
} from "./chunk-ENVUIH2A.js";
|
|
8
8
|
import {
|
|
9
9
|
__decorateClass
|
|
10
10
|
} from "./chunk-44VE5POH.js";
|
|
@@ -47,4 +47,4 @@ TestNext = __decorateClass([
|
|
|
47
47
|
export {
|
|
48
48
|
TestNext
|
|
49
49
|
};
|
|
50
|
-
//# sourceMappingURL=chunk-
|
|
50
|
+
//# sourceMappingURL=chunk-AYRSHIHA.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import {
|
|
2
|
+
TestComponent
|
|
3
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
1
4
|
import {
|
|
2
5
|
btn,
|
|
3
6
|
dis
|
|
4
7
|
} from "./chunk-UB5K44DB.js";
|
|
5
|
-
import {
|
|
6
|
-
TestComponent
|
|
7
|
-
} from "./chunk-ENVUIH2A.js";
|
|
8
8
|
import {
|
|
9
9
|
__decorateClass
|
|
10
10
|
} from "./chunk-44VE5POH.js";
|
|
@@ -40,4 +40,4 @@ TestItemLink = __decorateClass([
|
|
|
40
40
|
export {
|
|
41
41
|
TestItemLink
|
|
42
42
|
};
|
|
43
|
-
//# sourceMappingURL=chunk-
|
|
43
|
+
//# sourceMappingURL=chunk-BN32D5J2.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
+
import {
|
|
2
|
+
TestComponent
|
|
3
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
1
4
|
import {
|
|
2
5
|
btn,
|
|
3
6
|
dis
|
|
4
7
|
} from "./chunk-UB5K44DB.js";
|
|
5
|
-
import {
|
|
6
|
-
TestComponent
|
|
7
|
-
} from "./chunk-ENVUIH2A.js";
|
|
8
8
|
import {
|
|
9
9
|
__decorateClass
|
|
10
10
|
} from "./chunk-44VE5POH.js";
|
|
@@ -47,4 +47,4 @@ TestPrev = __decorateClass([
|
|
|
47
47
|
export {
|
|
48
48
|
TestPrev
|
|
49
49
|
};
|
|
50
|
-
//# sourceMappingURL=chunk-
|
|
50
|
+
//# sourceMappingURL=chunk-CJRXRBRQ.js.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import {
|
|
2
|
-
watch
|
|
3
|
-
} from "./chunk-4YG2FPKK.js";
|
|
4
1
|
import {
|
|
5
2
|
testContext,
|
|
6
3
|
testElement
|
|
7
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-YQ7EXOAK.js";
|
|
5
|
+
import {
|
|
6
|
+
watch
|
|
7
|
+
} from "./chunk-4YG2FPKK.js";
|
|
8
8
|
import {
|
|
9
9
|
__decorateClass
|
|
10
10
|
} from "./chunk-44VE5POH.js";
|
|
@@ -115,4 +115,4 @@ __decorateClass([
|
|
|
115
115
|
export {
|
|
116
116
|
TestComponent
|
|
117
117
|
};
|
|
118
|
-
//# sourceMappingURL=chunk-
|
|
118
|
+
//# sourceMappingURL=chunk-GPJ6WTE5.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/qti-test/components/test-component.abstract.ts","../src/lib/decorators/prop-internal-state.ts"],"sourcesContent":["import { consume } from '@lit/context';\nimport { LitElement } from 'lit';\nimport { state } from 'lit/decorators.js';\nimport { propInternalState } from '../../decorators';\nimport { testContext, testElement, TestElement, TestContext } from '../core/context';\nimport { watch } from '../../decorators/watch';\n\nexport abstract class TestComponent extends LitElement {\n @propInternalState({\n type: Boolean,\n reflect: true,\n aria: 'ariaDisabled' // Maps to `aria-disabled` attribute\n })\n public disabled = true;\n\n @state()\n @consume({ context: testContext, subscribe: true })\n protected _testContext?: TestContext;\n\n @state()\n @consume({ context: testElement, subscribe: true })\n protected _testElement?: TestElement;\n @watch('_testElement')\n _handleTestElementChange(_oldValue: TestElement, newValue: TestElement) {\n if (newValue.el) {\n this.disabled = false;\n }\n }\n\n protected _internals: ElementInternals;\n\n protected items;\n protected itemIndex;\n protected view;\n\n constructor() {\n super();\n this._internals = this.attachInternals();\n }\n\n protected willUpdate(changedProperties: Map<string | number | symbol, unknown>) {\n if (changedProperties.has('_testContext')) {\n const { items = [], navItemId } = this._testContext ?? {};\n this.itemIndex = items.findIndex(item => item.identifier === navItemId);\n this.items = items;\n this.view = this._testContext?.view;\n }\n }\n\n protected _switchView(view: string) {\n this.dispatchEvent(\n new CustomEvent('on-test-switch-view', {\n composed: true,\n bubbles: true,\n detail: view\n })\n );\n }\n\n protected _requestItem(identifier: string): void {\n this.dispatchEvent(\n new CustomEvent('qti-request-test-item', {\n composed: true,\n bubbles: true,\n detail: identifier\n })\n );\n }\n}\n","import { ReactiveElement } from 'lit';\nimport { property } from 'lit/decorators.js';\nimport { PropertyDeclaration } from 'lit';\n\n// Extended decorator options\ninterface InternalStateOptions extends PropertyDeclaration {\n aria?: string; // Corresponding ARIA attribute, e.g., 'aria-disabled'\n}\n\nexport function propInternalState(options: InternalStateOptions) {\n return (protoOrDescriptor: any, name: string) => {\n // Apply the default Lit `@property` decorator\n property(options)(protoOrDescriptor, name);\n\n // Intercept the property descriptor to enhance functionality\n const key = `__${name}`; // Internal backing field\n\n Object.defineProperty(protoOrDescriptor, name, {\n get() {\n return this[key];\n },\n set(value: any) {\n const oldValue = this[key];\n this[key] = value;\n\n // Trigger updates if value changes\n if (oldValue !== value) {\n // Update internals state\n if (this._internals?.states) {\n const stateName = name.toLowerCase();\n if (value) {\n this._internals.states.add(`--${stateName}`);\n } else {\n this._internals.states.delete(`--${stateName}`);\n }\n }\n\n // Update ARIA attributes if specified\n if (options.aria && this._internals) {\n const ariaAttribute = options.aria;\n if (value) {\n this._internals[ariaAttribute] = 'true';\n } else {\n this._internals[ariaAttribute] = null;\n }\n }\n\n // Request an update\n (this as ReactiveElement).requestUpdate(name, oldValue);\n }\n },\n configurable: true,\n enumerable: true\n });\n };\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAS,eAAe;AACxB,SAAS,kBAAkB;AAC3B,SAAS,aAAa;;;ACDtB,SAAS,gBAAgB;AAQlB,SAAS,kBAAkB,SAA+B;AAC/D,SAAO,CAAC,mBAAwB,SAAiB;AAE/C,aAAS,OAAO,EAAE,mBAAmB,IAAI;AAGzC,UAAM,MAAM,KAAK,IAAI;AAErB,WAAO,eAAe,mBAAmB,MAAM;AAAA,MAC7C,MAAM;AACJ,eAAO,KAAK,GAAG;AAAA,MACjB;AAAA,MACA,IAAI,OAAY;AACd,cAAM,WAAW,KAAK,GAAG;AACzB,aAAK,GAAG,IAAI;AAGZ,YAAI,aAAa,OAAO;AAEtB,cAAI,KAAK,YAAY,QAAQ;AAC3B,kBAAM,YAAY,KAAK,YAAY;AACnC,gBAAI,OAAO;AACT,mBAAK,WAAW,OAAO,IAAI,KAAK,SAAS,EAAE;AAAA,YAC7C,OAAO;AACL,mBAAK,WAAW,OAAO,OAAO,KAAK,SAAS,EAAE;AAAA,YAChD;AAAA,UACF;AAGA,cAAI,QAAQ,QAAQ,KAAK,YAAY;AACnC,kBAAM,gBAAgB,QAAQ;AAC9B,gBAAI,OAAO;AACT,mBAAK,WAAW,aAAa,IAAI;AAAA,YACnC,OAAO;AACL,mBAAK,WAAW,aAAa,IAAI;AAAA,YACnC;AAAA,UACF;AAGA,UAAC,KAAyB,cAAc,MAAM,QAAQ;AAAA,QACxD;AAAA,MACF;AAAA,MACA,cAAc;AAAA,MACd,YAAY;AAAA,IACd,CAAC;AAAA,EACH;AACF;;;ADhDO,IAAe,gBAAf,cAAqC,WAAW;AAAA,EA4BrD,cAAc;AACZ,UAAM;AAvBR,SAAO,WAAW;AAwBhB,SAAK,aAAa,KAAK,gBAAgB;AAAA,EACzC;AAAA,EAfA,yBAAyB,WAAwB,UAAuB;AACtE,QAAI,SAAS,IAAI;AACf,WAAK,WAAW;AAAA,IAClB;AAAA,EACF;AAAA,EAaU,WAAW,mBAA2D;AAC9E,QAAI,kBAAkB,IAAI,cAAc,GAAG;AACzC,YAAM,EAAE,QAAQ,CAAC,GAAG,UAAU,IAAI,KAAK,gBAAgB,CAAC;AACxD,WAAK,YAAY,MAAM,UAAU,UAAQ,KAAK,eAAe,SAAS;AACtE,WAAK,QAAQ;AACb,WAAK,OAAO,KAAK,cAAc;AAAA,IACjC;AAAA,EACF;AAAA,EAEU,YAAY,MAAc;AAClC,SAAK;AAAA,MACH,IAAI,YAAY,uBAAuB;AAAA,QACrC,UAAU;AAAA,QACV,SAAS;AAAA,QACT,QAAQ;AAAA,MACV,CAAC;AAAA,IACH;AAAA,EACF;AAAA,EAEU,aAAa,YAA0B;AAC/C,SAAK;AAAA,MACH,IAAI,YAAY,yBAAyB;AAAA,QACvC,UAAU;AAAA,QACV,SAAS;AAAA,QACT,QAAQ;AAAA,MACV,CAAC;AAAA,IACH;AAAA,EACF;AACF;AAvDS;AAAA,EALN,kBAAkB;AAAA,IACjB,MAAM;AAAA,IACN,SAAS;AAAA,IACT,MAAM;AAAA;AAAA,EACR,CAAC;AAAA,GALmB,cAMb;AAIG;AAAA,EAFT,MAAM;AAAA,EACN,QAAQ,EAAE,SAAS,aAAa,WAAW,KAAK,CAAC;AAAA,GAT9B,cAUV;AAIA;AAAA,EAFT,MAAM;AAAA,EACN,QAAQ,EAAE,SAAS,aAAa,WAAW,KAAK,CAAC;AAAA,GAb9B,cAcV;AAEV;AAAA,EADC,MAAM,cAAc;AAAA,GAfD,cAgBpB;","names":[]}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import {
|
|
2
|
+
btn,
|
|
3
|
+
dis
|
|
4
|
+
} from "./chunk-UB5K44DB.js";
|
|
5
|
+
import {
|
|
6
|
+
TestComponent
|
|
7
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
8
|
+
import {
|
|
9
|
+
__decorateClass
|
|
10
|
+
} from "./chunk-44VE5POH.js";
|
|
11
|
+
|
|
12
|
+
// src/lib/qti-test/components/test-next.ts
|
|
13
|
+
import { css, html } from "lit";
|
|
14
|
+
import { customElement } from "lit/decorators.js";
|
|
15
|
+
var TestNext = class extends TestComponent {
|
|
16
|
+
constructor() {
|
|
17
|
+
super();
|
|
18
|
+
this._internals.role = "button";
|
|
19
|
+
this._internals.ariaLabel = "Next item";
|
|
20
|
+
this.addEventListener("click", (e) => {
|
|
21
|
+
e.preventDefault();
|
|
22
|
+
if (!this.disabled) this._requestItem(this.items[this.itemIndex + 1].identifier);
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
willUpdate(changedProperties) {
|
|
26
|
+
super.willUpdate(changedProperties);
|
|
27
|
+
if (changedProperties.has("_testContext")) {
|
|
28
|
+
this.disabled = !this._testElement?.el || this.itemIndex < 0 || this.itemIndex >= this.items.length - 1;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
render() {
|
|
32
|
+
return html`<slot></slot>`;
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
TestNext.styles = css`
|
|
36
|
+
:host {
|
|
37
|
+
${btn};
|
|
38
|
+
}
|
|
39
|
+
:host([disabled]) {
|
|
40
|
+
${dis};
|
|
41
|
+
}
|
|
42
|
+
`;
|
|
43
|
+
TestNext = __decorateClass([
|
|
44
|
+
customElement("test-next")
|
|
45
|
+
], TestNext);
|
|
46
|
+
|
|
47
|
+
export {
|
|
48
|
+
TestNext
|
|
49
|
+
};
|
|
50
|
+
//# sourceMappingURL=chunk-KAUHKHPH.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/qti-test/components/test-next.ts"],"sourcesContent":["import { css, html } from 'lit';\nimport { customElement } from 'lit/decorators.js';\nimport * as styles from './styles';\nimport { TestComponent } from './test-component.abstract';\n\n/**\n * Represents a custom element for navigating to the next test item.\n *\n * @remarks\n * This element provides functionality for navigating to the next test item.\n *\n * @example\n * ```html\n * <test-next></test-next>\n * ```\n */\n@customElement('test-next')\nexport class TestNext extends TestComponent {\n static styles = css`\n :host {\n ${styles.btn};\n }\n :host([disabled]) {\n ${styles.dis};\n }\n `;\n\n constructor() {\n super();\n this._internals.role = 'button';\n this._internals.ariaLabel = 'Next item';\n\n this.addEventListener('click', e => {\n e.preventDefault();\n if (!this.disabled) this._requestItem(this.items[this.itemIndex + 1].identifier);\n });\n }\n\n willUpdate(changedProperties: Map<string | number | symbol, unknown>) {\n super.willUpdate(changedProperties);\n if (changedProperties.has('_testContext')) {\n this.disabled = !this._testElement?.el || this.itemIndex < 0 || this.itemIndex >= this.items.length - 1;\n }\n }\n\n render() {\n return html`<slot></slot>`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-next': TestNext;\n }\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAS,KAAK,YAAY;AAC1B,SAAS,qBAAqB;AAgBvB,IAAM,WAAN,cAAuB,cAAc;AAAA,EAU1C,cAAc;AACZ,UAAM;AACN,SAAK,WAAW,OAAO;AACvB,SAAK,WAAW,YAAY;AAE5B,SAAK,iBAAiB,SAAS,OAAK;AAClC,QAAE,eAAe;AACjB,UAAI,CAAC,KAAK,SAAU,MAAK,aAAa,KAAK,MAAM,KAAK,YAAY,CAAC,EAAE,UAAU;AAAA,IACjF,CAAC;AAAA,EACH;AAAA,EAEA,WAAW,mBAA2D;AACpE,UAAM,WAAW,iBAAiB;AAClC,QAAI,kBAAkB,IAAI,cAAc,GAAG;AACzC,WAAK,WAAW,CAAC,KAAK,cAAc,MAAM,KAAK,YAAY,KAAK,KAAK,aAAa,KAAK,MAAM,SAAS;AAAA,IACxG;AAAA,EACF;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,EACT;AACF;AA/Ba,SACJ,SAAS;AAAA;AAAA,QAEH,GAAG;AAAA;AAAA;AAAA,QAGH,GAAG;AAAA;AAAA;AANL,WAAN;AAAA,EADN,cAAc,WAAW;AAAA,GACb;","names":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=chunk-MAC76UNI.js.map
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
item_default
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
import {
|
|
5
|
-
watch
|
|
6
|
-
} from "./chunk-4YG2FPKK.js";
|
|
3
|
+
} from "./chunk-2CHF3TMY.js";
|
|
7
4
|
import {
|
|
8
5
|
qtiTransformItem
|
|
9
6
|
} from "./chunk-2OA7E3E7.js";
|
|
7
|
+
import {
|
|
8
|
+
watch
|
|
9
|
+
} from "./chunk-4YG2FPKK.js";
|
|
10
10
|
import {
|
|
11
11
|
__decorateClass
|
|
12
12
|
} from "./chunk-44VE5POH.js";
|
|
13
13
|
|
|
14
|
-
// src/lib/qti-item/components/item-container.ts
|
|
14
|
+
// src/lib/qti-item/core/components/item-container.ts
|
|
15
15
|
import { LitElement, html } from "lit";
|
|
16
16
|
import { customElement, property, state } from "lit/decorators.js";
|
|
17
17
|
import { until } from "lit/directives/until.js";
|
|
@@ -88,7 +88,20 @@ ItemContainer = __decorateClass([
|
|
|
88
88
|
customElement("item-container")
|
|
89
89
|
], ItemContainer);
|
|
90
90
|
|
|
91
|
+
// src/lib/qti-item/core/qti-item.ts
|
|
92
|
+
import { html as html2, LitElement as LitElement2 } from "lit";
|
|
93
|
+
import { customElement as customElement2 } from "lit/decorators.js";
|
|
94
|
+
var QtiItem = class extends LitElement2 {
|
|
95
|
+
render() {
|
|
96
|
+
return html2`<slot></slot>`;
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
QtiItem = __decorateClass([
|
|
100
|
+
customElement2("qti-item")
|
|
101
|
+
], QtiItem);
|
|
102
|
+
|
|
91
103
|
export {
|
|
92
|
-
ItemContainer
|
|
104
|
+
ItemContainer,
|
|
105
|
+
QtiItem
|
|
93
106
|
};
|
|
94
|
-
//# sourceMappingURL=chunk-
|
|
107
|
+
//# sourceMappingURL=chunk-QYN5S4EM.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/qti-item/core/components/item-container.ts","../src/lib/qti-item/core/qti-item.ts"],"sourcesContent":["import { LitElement, html } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport { until } from 'lit/directives/until.js';\nimport { watch } from '../../../decorators/watch';\nimport itemCss from '../../../../item.css?inline';\nimport { qtiTransformItem } from '../../../qti-transformers';\n\n/**\n * `<item-container>` is a custom element designed for hosting the qti-assessment-item.\n * The `qti-assessment-item` will be placed inside the shadow DOM of this element.\n * The element loads the item from the provided URL and renders it inside the shadow DOM.\n *\n * ### Styling\n * Add a class to the element for styling.\n *\n * ```html\n * <qti-item>\n * <item-container class=\"m-4 bg-white\" item-url=\"./path/to/item.xml\"></item-container>\n * </qti-item>\n * ```\n */\n@customElement('item-container')\nexport class ItemContainer extends LitElement {\n /** URL of the item to load */\n @property({ type: String, attribute: 'item-url' })\n itemURL: string = null;\n\n /** A parsed HTML document */\n @state()\n itemDoc: DocumentFragment = null;\n\n /** The raw XML string */\n @state()\n itemXML: string = null;\n\n /** Template content if provided */\n private templateContent = null;\n\n @watch('itemURL', { waitUntilFirstUpdate: true })\n protected async handleItemURLChange() {\n if (!this.itemURL) return;\n try {\n const api = await qtiTransformItem().load(this.itemURL);\n this.itemDoc = api.htmlDoc();\n } catch (error) {\n console.error('Error loading or parsing XML:', error);\n }\n }\n\n @watch('itemXML', { waitUntilFirstUpdate: true })\n protected handleItemXMLChange() {\n if (!this.itemXML) return;\n try {\n this.itemDoc = qtiTransformItem().parse(this.itemXML).htmlDoc();\n } catch (error) {\n console.error('Error parsing XML:', error);\n }\n }\n\n async connectedCallback(): Promise<void> {\n super.connectedCallback();\n this.initializeTemplateContent();\n this.applyStyles();\n if (this.itemURL) {\n this.handleItemURLChange();\n }\n if (this.itemXML) {\n this.handleItemXMLChange();\n }\n }\n\n private initializeTemplateContent() {\n const template = this.querySelector('template') as HTMLTemplateElement;\n this.templateContent = template ? template.content : html``;\n }\n\n private applyStyles() {\n const sheet = new CSSStyleSheet();\n sheet.replaceSync(itemCss);\n this.shadowRoot.adoptedStyleSheets = [sheet];\n }\n\n render() {\n return html`\n ${this.templateContent}\n <slot></slot>\n ${until(this.itemDoc, html`<span>Loading...</span>`)}\n `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'item-container': ItemContainer;\n }\n}\n","import { html, LitElement } from 'lit';\nimport { customElement } from 'lit/decorators.js';\n\n/**\n * `<qti-item>` is a custom element designed for rendering a single `qti-assessment-item`.\n * It can also host some functionalities to interact with the item like scoring, showing feedback, etc.\n * Placing a mandatory `<item-container>` inside '<qti-item>' will load or parse the item and render it.\n * See `<item-container>` for more details.\n *\n * ```html\n * <qti-item>\n * <item-container class=\"m-4 bg-white\" item-url=\"./path/to/item.xml\"></item-container>\n * </qti-item>\n * ```\n */\n@customElement('qti-item')\nexport class QtiItem extends LitElement {\n render() {\n return html`<slot></slot>`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'qti-item': QtiItem;\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AAAA,SAAS,YAAY,YAAY;AACjC,SAAS,eAAe,UAAU,aAAa;AAC/C,SAAS,aAAa;AAoBf,IAAM,gBAAN,cAA4B,WAAW;AAAA,EAAvC;AAAA;AAGL,mBAAkB;AAIlB,mBAA4B;AAI5B,mBAAkB;AAGlB;AAAA,SAAQ,kBAAkB;AAAA;AAAA,EAG1B,MAAgB,sBAAsB;AACpC,QAAI,CAAC,KAAK,QAAS;AACnB,QAAI;AACF,YAAM,MAAM,MAAM,iBAAiB,EAAE,KAAK,KAAK,OAAO;AACtD,WAAK,UAAU,IAAI,QAAQ;AAAA,IAC7B,SAAS,OAAO;AACd,cAAQ,MAAM,iCAAiC,KAAK;AAAA,IACtD;AAAA,EACF;AAAA,EAGU,sBAAsB;AAC9B,QAAI,CAAC,KAAK,QAAS;AACnB,QAAI;AACF,WAAK,UAAU,iBAAiB,EAAE,MAAM,KAAK,OAAO,EAAE,QAAQ;AAAA,IAChE,SAAS,OAAO;AACd,cAAQ,MAAM,sBAAsB,KAAK;AAAA,IAC3C;AAAA,EACF;AAAA,EAEA,MAAM,oBAAmC;AACvC,UAAM,kBAAkB;AACxB,SAAK,0BAA0B;AAC/B,SAAK,YAAY;AACjB,QAAI,KAAK,SAAS;AAChB,WAAK,oBAAoB;AAAA,IAC3B;AACA,QAAI,KAAK,SAAS;AAChB,WAAK,oBAAoB;AAAA,IAC3B;AAAA,EACF;AAAA,EAEQ,4BAA4B;AAClC,UAAM,WAAW,KAAK,cAAc,UAAU;AAC9C,SAAK,kBAAkB,WAAW,SAAS,UAAU;AAAA,EACvD;AAAA,EAEQ,cAAc;AACpB,UAAM,QAAQ,IAAI,cAAc;AAChC,UAAM,YAAY,YAAO;AACzB,SAAK,WAAW,qBAAqB,CAAC,KAAK;AAAA,EAC7C;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,QACH,KAAK,eAAe;AAAA;AAAA,QAEpB,MAAM,KAAK,SAAS,6BAA6B,CAAC;AAAA;AAAA,EAExD;AACF;AAhEE;AAAA,EADC,SAAS,EAAE,MAAM,QAAQ,WAAW,WAAW,CAAC;AAAA,GAFtC,cAGX;AAIA;AAAA,EADC,MAAM;AAAA,GANI,cAOX;AAIA;AAAA,EADC,MAAM;AAAA,GAVI,cAWX;AAMgB;AAAA,EADf,MAAM,WAAW,EAAE,sBAAsB,KAAK,CAAC;AAAA,GAhBrC,cAiBK;AAWN;AAAA,EADT,MAAM,WAAW,EAAE,sBAAsB,KAAK,CAAC;AAAA,GA3BrC,cA4BD;AA5BC,gBAAN;AAAA,EADN,cAAc,gBAAgB;AAAA,GAClB;;;ACtBb,SAAS,QAAAA,OAAM,cAAAC,mBAAkB;AACjC,SAAS,iBAAAC,sBAAqB;AAevB,IAAM,UAAN,cAAsBC,YAAW;AAAA,EACtC,SAAS;AACP,WAAOC;AAAA,EACT;AACF;AAJa,UAAN;AAAA,EADNC,eAAc,UAAU;AAAA,GACZ;","names":["html","LitElement","customElement","LitElement","html","customElement"]}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import {
|
|
2
|
+
btn,
|
|
3
|
+
dis
|
|
4
|
+
} from "./chunk-UB5K44DB.js";
|
|
5
|
+
import {
|
|
6
|
+
TestComponent
|
|
7
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
8
|
+
import {
|
|
9
|
+
__decorateClass
|
|
10
|
+
} from "./chunk-44VE5POH.js";
|
|
11
|
+
|
|
12
|
+
// src/lib/qti-test/components/test-item-link.ts
|
|
13
|
+
import { css, html } from "lit";
|
|
14
|
+
import { customElement, property } from "lit/decorators.js";
|
|
15
|
+
var TestItemLink = class extends TestComponent {
|
|
16
|
+
constructor() {
|
|
17
|
+
super();
|
|
18
|
+
this.itemId = null;
|
|
19
|
+
this.addEventListener("click", () => this._requestItem(this.itemId));
|
|
20
|
+
}
|
|
21
|
+
render() {
|
|
22
|
+
return html` <slot></slot> `;
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
TestItemLink.styles = css`
|
|
26
|
+
:host {
|
|
27
|
+
${btn};
|
|
28
|
+
}
|
|
29
|
+
:host([disabled]) {
|
|
30
|
+
${dis};
|
|
31
|
+
}
|
|
32
|
+
`;
|
|
33
|
+
__decorateClass([
|
|
34
|
+
property({ type: String, attribute: "item-id" })
|
|
35
|
+
], TestItemLink.prototype, "itemId", 2);
|
|
36
|
+
TestItemLink = __decorateClass([
|
|
37
|
+
customElement("test-item-link")
|
|
38
|
+
], TestItemLink);
|
|
39
|
+
|
|
40
|
+
export {
|
|
41
|
+
TestItemLink
|
|
42
|
+
};
|
|
43
|
+
//# sourceMappingURL=chunk-UJTJIU3C.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/qti-test/components/test-item-link.ts"],"sourcesContent":["import { css, html } from 'lit';\nimport { customElement, property } from 'lit/decorators.js';\nimport { TestComponent } from './test-component.abstract';\nimport * as styles from './styles';\n\n@customElement('test-item-link')\nexport class TestItemLink extends TestComponent {\n static styles = css`\n :host {\n ${styles.btn};\n }\n :host([disabled]) {\n ${styles.dis};\n }\n `;\n\n @property({ type: String, attribute: 'item-id' })\n private itemId: string = null;\n\n constructor() {\n super();\n this.addEventListener('click', () => this._requestItem(this.itemId));\n }\n\n render() {\n return html` <slot></slot> `;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-item-link': TestItemLink;\n }\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAS,KAAK,YAAY;AAC1B,SAAS,eAAe,gBAAgB;AAKjC,IAAM,eAAN,cAA2B,cAAc;AAAA,EAa9C,cAAc;AACZ,UAAM;AAHR,SAAQ,SAAiB;AAIvB,SAAK,iBAAiB,SAAS,MAAM,KAAK,aAAa,KAAK,MAAM,CAAC;AAAA,EACrE;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,EACT;AACF;AArBa,aACJ,SAAS;AAAA;AAAA,QAEH,GAAG;AAAA;AAAA;AAAA,QAGH,GAAG;AAAA;AAAA;AAKR;AAAA,EADP,SAAS,EAAE,MAAM,QAAQ,WAAW,UAAU,CAAC;AAAA,GAVrC,aAWH;AAXG,eAAN;AAAA,EADN,cAAc,gBAAgB;AAAA,GAClB;","names":[]}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import {
|
|
2
|
+
btn,
|
|
3
|
+
dis
|
|
4
|
+
} from "./chunk-UB5K44DB.js";
|
|
5
|
+
import {
|
|
6
|
+
TestComponent
|
|
7
|
+
} from "./chunk-GPJ6WTE5.js";
|
|
8
|
+
import {
|
|
9
|
+
__decorateClass
|
|
10
|
+
} from "./chunk-44VE5POH.js";
|
|
11
|
+
|
|
12
|
+
// src/lib/qti-test/components/test-prev.ts
|
|
13
|
+
import { css, html } from "lit";
|
|
14
|
+
import { customElement } from "lit/decorators.js";
|
|
15
|
+
var TestPrev = class extends TestComponent {
|
|
16
|
+
constructor() {
|
|
17
|
+
super();
|
|
18
|
+
this._internals.role = "button";
|
|
19
|
+
this._internals.ariaLabel = "Next item";
|
|
20
|
+
this.addEventListener("click", (e) => {
|
|
21
|
+
e.preventDefault();
|
|
22
|
+
if (!this.disabled) this._requestItem(this.items[this.itemIndex - 1].identifier);
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
willUpdate(changedProperties) {
|
|
26
|
+
super.willUpdate(changedProperties);
|
|
27
|
+
if (changedProperties.has("_testContext")) {
|
|
28
|
+
this.disabled = !this._testElement?.el || this.itemIndex === 0 || this.itemIndex === -1;
|
|
29
|
+
}
|
|
30
|
+
}
|
|
31
|
+
render() {
|
|
32
|
+
return html`<slot></slot>`;
|
|
33
|
+
}
|
|
34
|
+
};
|
|
35
|
+
TestPrev.styles = css`
|
|
36
|
+
:host {
|
|
37
|
+
${btn};
|
|
38
|
+
}
|
|
39
|
+
:host([disabled]) {
|
|
40
|
+
${dis};
|
|
41
|
+
}
|
|
42
|
+
`;
|
|
43
|
+
TestPrev = __decorateClass([
|
|
44
|
+
customElement("test-prev")
|
|
45
|
+
], TestPrev);
|
|
46
|
+
|
|
47
|
+
export {
|
|
48
|
+
TestPrev
|
|
49
|
+
};
|
|
50
|
+
//# sourceMappingURL=chunk-XVQZ5JI5.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../src/lib/qti-test/components/test-prev.ts"],"sourcesContent":["import { css, html } from 'lit';\nimport { customElement } from 'lit/decorators.js';\nimport { TestComponent } from './test-component.abstract';\nimport * as styles from './styles';\n\n/**\n * Represents a custom element for navigating to the previous test item.\n *\n * @remarks\n * This element provides functionality for navigating to the previous test item.\n *\n * @example\n * ```html\n * <test-prev></test-prev>\n * ```\n */\n@customElement('test-prev')\nexport class TestPrev extends TestComponent {\n static styles = css`\n :host {\n ${styles.btn};\n }\n :host([disabled]) {\n ${styles.dis};\n }\n `;\n\n constructor() {\n super();\n this._internals.role = 'button';\n this._internals.ariaLabel = 'Next item';\n\n this.addEventListener('click', e => {\n e.preventDefault();\n if (!this.disabled) this._requestItem(this.items[this.itemIndex - 1].identifier);\n });\n }\n\n willUpdate(changedProperties: Map<string | number | symbol, unknown>) {\n super.willUpdate(changedProperties);\n if (changedProperties.has('_testContext')) {\n this.disabled = !this._testElement?.el || this.itemIndex === 0 || this.itemIndex === -1;\n }\n }\n\n render() {\n return html`<slot></slot>`;\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'test-previous': TestPrev;\n }\n}\n"],"mappings":";;;;;;;;;;;;AAAA,SAAS,KAAK,YAAY;AAC1B,SAAS,qBAAqB;AAgBvB,IAAM,WAAN,cAAuB,cAAc;AAAA,EAU1C,cAAc;AACZ,UAAM;AACN,SAAK,WAAW,OAAO;AACvB,SAAK,WAAW,YAAY;AAE5B,SAAK,iBAAiB,SAAS,OAAK;AAClC,QAAE,eAAe;AACjB,UAAI,CAAC,KAAK,SAAU,MAAK,aAAa,KAAK,MAAM,KAAK,YAAY,CAAC,EAAE,UAAU;AAAA,IACjF,CAAC;AAAA,EACH;AAAA,EAEA,WAAW,mBAA2D;AACpE,UAAM,WAAW,iBAAiB;AAClC,QAAI,kBAAkB,IAAI,cAAc,GAAG;AACzC,WAAK,WAAW,CAAC,KAAK,cAAc,MAAM,KAAK,cAAc,KAAK,KAAK,cAAc;AAAA,IACvF;AAAA,EACF;AAAA,EAEA,SAAS;AACP,WAAO;AAAA,EACT;AACF;AA/Ba,SACJ,SAAS;AAAA;AAAA,QAEH,GAAG;AAAA;AAAA;AAAA,QAGH,GAAG;AAAA;AAAA;AANL,WAAN;AAAA,EADN,cAAc,WAAW;AAAA,GACb;","names":[]}
|
|
@@ -1,12 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
} from "./chunk-
|
|
2
|
+
qtiTransformItem
|
|
3
|
+
} from "./chunk-2OA7E3E7.js";
|
|
4
4
|
import {
|
|
5
5
|
watch
|
|
6
6
|
} from "./chunk-4YG2FPKK.js";
|
|
7
|
-
import {
|
|
8
|
-
qtiTransformItem
|
|
9
|
-
} from "./chunk-2OA7E3E7.js";
|
|
10
7
|
import {
|
|
11
8
|
__decorateClass
|
|
12
9
|
} from "./chunk-44VE5POH.js";
|
|
@@ -1134,13 +1131,13 @@ var QtiExtendedTextInteraction = class extends Interaction {
|
|
|
1134
1131
|
}
|
|
1135
1132
|
}
|
|
1136
1133
|
get value() {
|
|
1137
|
-
return this._value;
|
|
1134
|
+
return this._value || null;
|
|
1138
1135
|
}
|
|
1139
1136
|
set value(val) {
|
|
1140
|
-
if (typeof val === "string") {
|
|
1141
|
-
this._value = val;
|
|
1137
|
+
if (typeof val === "string" || val === null) {
|
|
1138
|
+
this._value = val || "";
|
|
1142
1139
|
const formData = new FormData();
|
|
1143
|
-
formData.append(this.responseIdentifier,
|
|
1140
|
+
formData.append(this.responseIdentifier, this._value);
|
|
1144
1141
|
this._internals.setFormValue(formData);
|
|
1145
1142
|
this.validate();
|
|
1146
1143
|
} else {
|
|
@@ -1338,13 +1335,13 @@ var QtiTextEntryInteraction = class extends Interaction {
|
|
|
1338
1335
|
this.inputRef = createRef();
|
|
1339
1336
|
}
|
|
1340
1337
|
get value() {
|
|
1341
|
-
return this._value;
|
|
1338
|
+
return this._value || null;
|
|
1342
1339
|
}
|
|
1343
1340
|
set value(val) {
|
|
1344
|
-
if (typeof val === "string") {
|
|
1345
|
-
this._value = val;
|
|
1341
|
+
if (typeof val === "string" || val === null) {
|
|
1342
|
+
this._value = val || "";
|
|
1346
1343
|
const formData = new FormData();
|
|
1347
|
-
formData.append(this.responseIdentifier,
|
|
1344
|
+
formData.append(this.responseIdentifier, this._value);
|
|
1348
1345
|
this._internals.setFormValue(formData);
|
|
1349
1346
|
this.validate();
|
|
1350
1347
|
} else {
|
|
@@ -1462,13 +1459,18 @@ var ChoicesMixin = (superClass, selector) => {
|
|
|
1462
1459
|
this._determineInputType();
|
|
1463
1460
|
}
|
|
1464
1461
|
get value() {
|
|
1462
|
+
if (Array.isArray(this._value) && this._value.length === 0) {
|
|
1463
|
+
return null;
|
|
1464
|
+
} else if (this._value === "") {
|
|
1465
|
+
return null;
|
|
1466
|
+
}
|
|
1465
1467
|
return Array.isArray(this._value) ? this._value.join(",") : this._value;
|
|
1466
1468
|
}
|
|
1467
1469
|
set value(val) {
|
|
1468
|
-
if (this.maxChoices > 1 && typeof val === "string") {
|
|
1469
|
-
this._value = val.split(",");
|
|
1470
|
+
if (this.maxChoices > 1 && (typeof val === "string" || val === null)) {
|
|
1471
|
+
this._value = !val ? [] : val.toString().split(",");
|
|
1470
1472
|
} else {
|
|
1471
|
-
this._value = val;
|
|
1473
|
+
this._value = val || "";
|
|
1472
1474
|
}
|
|
1473
1475
|
if (Array.isArray(this._value)) {
|
|
1474
1476
|
const formData = new FormData();
|
|
@@ -1728,14 +1730,14 @@ var QtiInlineChoiceInteraction = class extends Interaction {
|
|
|
1728
1730
|
}
|
|
1729
1731
|
set value(value) {
|
|
1730
1732
|
this.options = this.options.map((option) => {
|
|
1731
|
-
if (value === option.value) {
|
|
1733
|
+
if (value && value === option.value) {
|
|
1732
1734
|
option.selected = true;
|
|
1733
1735
|
}
|
|
1734
1736
|
return option;
|
|
1735
1737
|
});
|
|
1736
1738
|
}
|
|
1737
1739
|
get value() {
|
|
1738
|
-
return this.options.find((option) => option.selected)
|
|
1740
|
+
return this.options.find((option) => option.selected)?.value || null;
|
|
1739
1741
|
}
|
|
1740
1742
|
set correctResponse(value) {
|
|
1741
1743
|
if (value === "") {
|
|
@@ -2502,9 +2504,6 @@ function qtiAndMixin(Base) {
|
|
|
2502
2504
|
};
|
|
2503
2505
|
}
|
|
2504
2506
|
|
|
2505
|
-
// src/lib/qti-components/qti-response-processing/qti-expression/qti-and/index.ts
|
|
2506
|
-
customElements.define("qti-and", QtiAnd);
|
|
2507
|
-
|
|
2508
2507
|
// src/lib/qti-components/qti-response-processing/qti-expression/qti-basevalue/qti-basevalue.ts
|
|
2509
2508
|
import { property as property17 } from "lit/decorators.js";
|
|
2510
2509
|
var QtiBaseValue = class extends QtiExpression {
|
|
@@ -3160,9 +3159,6 @@ function qtiSubtractMixin(Base) {
|
|
|
3160
3159
|
};
|
|
3161
3160
|
}
|
|
3162
3161
|
|
|
3163
|
-
// src/lib/qti-components/qti-response-processing/qti-expression/qti-subtract/index.ts
|
|
3164
|
-
customElements.define("qti-subtract", QtiSubtract);
|
|
3165
|
-
|
|
3166
3162
|
// src/lib/qti-components/qti-response-processing/qti-expression/qti-string-match/qti-string-match.ts
|
|
3167
3163
|
import { property as property23 } from "lit/decorators.js";
|
|
3168
3164
|
var QtiStringMatch = class extends QtiExpression {
|
|
@@ -3539,7 +3535,42 @@ var FlippablesMixin = (superClass, _droppablesSel, _draggablesSel) => {
|
|
|
3539
3535
|
|
|
3540
3536
|
// src/lib/qti-components/qti-interaction/internal/drag-drop/drag-drop-interaction-mixin.ts
|
|
3541
3537
|
import { property as property25 } from "lit/decorators.js";
|
|
3542
|
-
|
|
3538
|
+
|
|
3539
|
+
// src/lib/decorators/live-query.ts
|
|
3540
|
+
function liveQuery(querySelector, _options) {
|
|
3541
|
+
let observer;
|
|
3542
|
+
return (proto, decoratedFnName) => {
|
|
3543
|
+
const { connectedCallback, disconnectedCallback } = proto;
|
|
3544
|
+
proto.connectedCallback = function() {
|
|
3545
|
+
connectedCallback.call(this);
|
|
3546
|
+
const callback = (mutationList) => {
|
|
3547
|
+
const elementsToWatch = Array.from(this.querySelectorAll(querySelector)).concat(
|
|
3548
|
+
Array.from(this.shadowRoot?.querySelectorAll(querySelector) || [])
|
|
3549
|
+
);
|
|
3550
|
+
for (const mutation of mutationList) {
|
|
3551
|
+
const addedNodes = Array.from(mutation.addedNodes).map((e) => e);
|
|
3552
|
+
const removedNodes = Array.from(mutation.addedNodes).map((e) => e);
|
|
3553
|
+
if (mutation.type === "childList" && addedNodes.find((n) => elementsToWatch.includes(n))) {
|
|
3554
|
+
this[decoratedFnName](addedNodes, removedNodes);
|
|
3555
|
+
}
|
|
3556
|
+
}
|
|
3557
|
+
};
|
|
3558
|
+
observer = new MutationObserver(callback);
|
|
3559
|
+
observer.observe(this, { childList: true, subtree: true });
|
|
3560
|
+
const elementsAdded = Array.from(this.querySelectorAll(querySelector)).concat(
|
|
3561
|
+
Array.from(this.shadowRoot?.querySelectorAll(querySelector) || [])
|
|
3562
|
+
);
|
|
3563
|
+
this[decoratedFnName](Array.from(elementsAdded), []);
|
|
3564
|
+
};
|
|
3565
|
+
proto.disconnectedCallback = function() {
|
|
3566
|
+
disconnectedCallback.call(this);
|
|
3567
|
+
observer.disconnect();
|
|
3568
|
+
};
|
|
3569
|
+
};
|
|
3570
|
+
}
|
|
3571
|
+
|
|
3572
|
+
// src/lib/qti-components/qti-interaction/internal/drag-drop/drag-drop-interaction-mixin.ts
|
|
3573
|
+
var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelector, dragContainersSelector, appendClone = "default") => {
|
|
3543
3574
|
class DragDropInteractionElement extends FlippablesMixin(
|
|
3544
3575
|
superClass,
|
|
3545
3576
|
droppablesSelector,
|
|
@@ -3975,7 +4006,7 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
3975
4006
|
});
|
|
3976
4007
|
this._internals.setFormValue(formData);
|
|
3977
4008
|
} else {
|
|
3978
|
-
this._internals.setFormValue(value);
|
|
4009
|
+
this._internals.setFormValue(value || "");
|
|
3979
4010
|
}
|
|
3980
4011
|
}
|
|
3981
4012
|
placeResponse(response) {
|
|
@@ -3994,7 +4025,6 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
3994
4025
|
}
|
|
3995
4026
|
const moveElement = () => {
|
|
3996
4027
|
draggable.style.transform = "translate(0, 0)";
|
|
3997
|
-
console.log("droppable", droppable);
|
|
3998
4028
|
droppable.appendChild(draggable);
|
|
3999
4029
|
this.checkAllMaxAssociations();
|
|
4000
4030
|
};
|
|
@@ -4108,6 +4138,32 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
4108
4138
|
event["dataTransfer"] = this.dataTransfer;
|
|
4109
4139
|
element.dispatchEvent(event);
|
|
4110
4140
|
}
|
|
4141
|
+
appendClone() {
|
|
4142
|
+
const interaction = this.findParentInteractionElement(this.dragSource);
|
|
4143
|
+
if (appendClone == "default") {
|
|
4144
|
+
if (interaction) {
|
|
4145
|
+
interaction.appendChild(this.dragClone);
|
|
4146
|
+
} else if (this.rootNode instanceof ShadowRoot) {
|
|
4147
|
+
this.rootNode.host.appendChild(this.dragClone);
|
|
4148
|
+
} else if (this.rootNode instanceof Document) {
|
|
4149
|
+
document.body.appendChild(this.dragClone);
|
|
4150
|
+
}
|
|
4151
|
+
} else if (appendClone == "interaction") {
|
|
4152
|
+
if (interaction) {
|
|
4153
|
+
interaction.appendChild(this.dragClone);
|
|
4154
|
+
} else {
|
|
4155
|
+
console.error("No interaction found to append the drag clone");
|
|
4156
|
+
}
|
|
4157
|
+
} else if (appendClone == "host") {
|
|
4158
|
+
if (this.rootNode instanceof ShadowRoot) {
|
|
4159
|
+
this.rootNode.host.appendChild(this.dragClone);
|
|
4160
|
+
} else {
|
|
4161
|
+
console.error("No host found to append the drag clone");
|
|
4162
|
+
}
|
|
4163
|
+
} else if (appendClone == "body") {
|
|
4164
|
+
document.body.appendChild(this.dragClone);
|
|
4165
|
+
}
|
|
4166
|
+
}
|
|
4111
4167
|
handleTouchStart(e) {
|
|
4112
4168
|
const { x, y } = this.getEventCoordinates(e);
|
|
4113
4169
|
this.dropzoneOriginalParent = e.currentTarget.parentElement;
|
|
@@ -4124,17 +4180,15 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
4124
4180
|
this.cloneOffset.x = x - rect.left;
|
|
4125
4181
|
this.cloneOffset.y = y - rect.top;
|
|
4126
4182
|
this.dragClone = draggableInDragContainer.cloneNode(true);
|
|
4183
|
+
const computedStyles = window.getComputedStyle(this.dragSource);
|
|
4184
|
+
for (let i = 0; i < computedStyles.length; i++) {
|
|
4185
|
+
const key = computedStyles[i];
|
|
4186
|
+
this.dragClone.style.setProperty(key, computedStyles.getPropertyValue(key));
|
|
4187
|
+
}
|
|
4127
4188
|
if (rect) {
|
|
4128
4189
|
this.setDragCloneStyles(rect);
|
|
4129
4190
|
}
|
|
4130
|
-
|
|
4131
|
-
if (interaction) {
|
|
4132
|
-
interaction.appendChild(this.dragClone);
|
|
4133
|
-
} else if (this.rootNode instanceof ShadowRoot) {
|
|
4134
|
-
this.rootNode.host.appendChild(this.dragClone);
|
|
4135
|
-
} else if (this.rootNode instanceof Document) {
|
|
4136
|
-
document.body.appendChild(this.dragClone);
|
|
4137
|
-
}
|
|
4191
|
+
this.appendClone();
|
|
4138
4192
|
const matchMax = this.getMatchMaxValue(this.dragSource);
|
|
4139
4193
|
const currentDraggables = this.draggables.filter(
|
|
4140
4194
|
(d) => d.getAttribute("identifier") === this.dragSource.getAttribute("identifier")
|
|
@@ -4150,15 +4204,8 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
4150
4204
|
this.enableDroppable(parent);
|
|
4151
4205
|
this.dragClone = this.dragSource;
|
|
4152
4206
|
this.dragSource = this.findDraggableInDraggableContainer(this.dragSource.getAttribute("identifier"));
|
|
4153
|
-
const interaction = this.findParentInteractionElement(this.dragSource);
|
|
4154
4207
|
const rect = this.dragClone.getBoundingClientRect();
|
|
4155
|
-
|
|
4156
|
-
interaction.appendChild(this.dragClone);
|
|
4157
|
-
} else if (this.rootNode instanceof ShadowRoot) {
|
|
4158
|
-
this.rootNode.host.appendChild(this.dragClone);
|
|
4159
|
-
} else if (this.rootNode instanceof Document) {
|
|
4160
|
-
document.body.appendChild(this.dragClone);
|
|
4161
|
-
}
|
|
4208
|
+
this.appendClone();
|
|
4162
4209
|
if (rect) {
|
|
4163
4210
|
this.setDragCloneStyles(rect);
|
|
4164
4211
|
}
|
|
@@ -4177,8 +4224,13 @@ var DragDropInteractionMixin = (superClass, draggablesSelector, droppablesSelect
|
|
|
4177
4224
|
if (container.getAttribute("identifier") === identifier) {
|
|
4178
4225
|
return container;
|
|
4179
4226
|
}
|
|
4180
|
-
|
|
4181
|
-
|
|
4227
|
+
let elements;
|
|
4228
|
+
if (container instanceof HTMLSlotElement) {
|
|
4229
|
+
elements = Array.from(container.assignedElements() || []);
|
|
4230
|
+
} else {
|
|
4231
|
+
elements = Array.from(container.querySelectorAll(draggablesSelector));
|
|
4232
|
+
}
|
|
4233
|
+
const foundElement = elements.find((e) => e.getAttribute("identifier") === identifier);
|
|
4182
4234
|
if (foundElement) {
|
|
4183
4235
|
return foundElement;
|
|
4184
4236
|
}
|
|
@@ -5162,7 +5214,8 @@ var QtiMatchInteraction = class extends DragDropInteractionMixin(
|
|
|
5162
5214
|
Interaction,
|
|
5163
5215
|
"qti-simple-match-set:first-of-type qti-simple-associable-choice, qti-simple-match-set:last-of-type > qti-simple-associable-choice > qti-simple-associable-choice",
|
|
5164
5216
|
"qti-simple-match-set:last-of-type > qti-simple-associable-choice",
|
|
5165
|
-
"qti-simple-match-set:first-of-type"
|
|
5217
|
+
"qti-simple-match-set:first-of-type",
|
|
5218
|
+
"body"
|
|
5166
5219
|
) {
|
|
5167
5220
|
constructor() {
|
|
5168
5221
|
super(...arguments);
|
|
@@ -6250,4 +6303,4 @@ export {
|
|
|
6250
6303
|
QtiInlineChoice,
|
|
6251
6304
|
QtiSimpleChoice
|
|
6252
6305
|
};
|
|
6253
|
-
//# sourceMappingURL=chunk-
|
|
6306
|
+
//# sourceMappingURL=chunk-XW3PQRKW.js.map
|