@pie-element/placement-ordering 14.1.1 → 14.1.2-next.0
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/configure.js +2 -0
- package/controller.js +1 -0
- package/dist/author/choice-editor.d.ts +39 -0
- package/dist/author/choice-editor.js +157 -0
- package/dist/author/choice-tile.d.ts +40 -0
- package/dist/author/choice-tile.js +132 -0
- package/dist/author/defaults.d.ts +213 -0
- package/dist/author/defaults.js +159 -0
- package/dist/author/design.d.ts +21 -0
- package/dist/author/design.js +274 -0
- package/dist/author/help.d.ts +11 -0
- package/dist/author/index.d.ts +45 -0
- package/dist/author/index.js +85 -0
- package/dist/author/utils.d.ts +15 -0
- package/dist/author/utils.js +62 -0
- package/dist/browser/author/index.js +40986 -0
- package/dist/browser/author/index.js.map +1 -0
- package/dist/browser/browser-CvJkn_Ec.js +1019 -0
- package/dist/browser/browser-CvJkn_Ec.js.map +1 -0
- package/dist/browser/controller/index.js +319 -0
- package/dist/browser/controller/index.js.map +1 -0
- package/dist/browser/delivery/index.js +1032 -0
- package/dist/browser/delivery/index.js.map +1 -0
- package/dist/browser/dist-BTHiIs74.js +1610 -0
- package/dist/browser/dist-BTHiIs74.js.map +1 -0
- package/dist/browser/drag-provider-DaPxkh4j.js +10833 -0
- package/dist/browser/drag-provider-DaPxkh4j.js.map +1 -0
- package/dist/browser/last-D7N4Qfx4.js +9 -0
- package/dist/browser/last-D7N4Qfx4.js.map +1 -0
- package/dist/browser/placement-ordering.css +2 -0
- package/dist/controller/defaults.d.ts +31 -0
- package/dist/controller/defaults.js +25 -0
- package/dist/controller/index.d.ts +29 -0
- package/dist/controller/index.js +128 -0
- package/dist/controller/scoring.d.ts +27 -0
- package/dist/controller/scoring.js +32 -0
- package/dist/delivery/index.d.ts +26 -0
- package/dist/delivery/index.js +70 -0
- package/dist/delivery/main.d.ts +19 -0
- package/dist/delivery/main.js +22 -0
- package/dist/delivery/ordering.d.ts +18 -0
- package/dist/delivery/ordering.js +96 -0
- package/dist/delivery/placement-ordering.d.ts +28 -0
- package/dist/delivery/placement-ordering.js +215 -0
- package/dist/delivery/tile.d.ts +28 -0
- package/dist/delivery/tile.js +165 -0
- package/dist/delivery/tiler.d.ts +42 -0
- package/dist/delivery/tiler.js +89 -0
- package/dist/delivery/utils.d.ts +9 -0
- package/dist/delivery/utils.js +8 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.iife.d.ts +8 -0
- package/dist/index.iife.js +152 -0
- package/dist/index.js +2 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_DataView.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Hash.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_ListCache.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Map.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_MapCache.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Promise.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Set.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_SetCache.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Stack.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Symbol.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Uint8Array.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_WeakMap.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_apply.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayEach.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayEvery.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayFilter.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludes.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludesWith.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayLikeKeys.js +15 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayMap.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayPush.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayReduce.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayShuffle.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arraySome.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_assignValue.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_assocIndexOf.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssign.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssignIn.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssignValue.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseClone.js +57 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseCreate.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseDifference.js +23 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseEach.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseEvery.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseFindIndex.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseFlatten.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseFor.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseForOwn.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGet.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGetAllKeys.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGetTag.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseHasIn.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIndexOf.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsArguments.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsEqual.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsEqualDeep.js +30 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsMap.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsMatch.js +26 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsNaN.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsNative.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsSet.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsTypedArray.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIteratee.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseKeys.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseKeysIn.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMap.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMatches.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMatchesProperty.js +17 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseProperty.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_basePropertyDeep.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseRandom.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseReduce.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseRest.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseSetToString.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseShuffle.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseTimes.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseToString.js +15 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseUnary.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseUniq.js +27 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseValues.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cacheHas.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_castPath.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneArrayBuffer.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneBuffer.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneDataView.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneRegExp.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneSymbol.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneTypedArray.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copyArray.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copyObject.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copySymbols.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copySymbolsIn.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_coreJsData.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createAssigner.js +15 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createBaseEach.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createBaseFor.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createSet.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_defineProperty.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalArrays.js +35 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalByTag.js +35 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalObjects.js +32 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_freeGlobal.js +4 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getAllKeys.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getAllKeysIn.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getMapData.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getMatchData.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getNative.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getPrototype.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getRawTag.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getSymbols.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getSymbolsIn.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getTag.js +23 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getValue.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hasPath.js +18 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashClear.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashDelete.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashGet.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashHas.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashSet.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneArray.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneByTag.js +33 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneObject.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isFlattenable.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isIndex.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isIterateeCall.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isKey.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isKeyable.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isMasked.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isPrototype.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isStrictComparable.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheClear.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheDelete.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheGet.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheHas.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheSet.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheClear.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheDelete.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheGet.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheHas.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheSet.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapToArray.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_matchesStrictComparable.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_memoizeCapped.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeCreate.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeKeys.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeKeysIn.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nodeUtil.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_objectToString.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_overArg.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_overRest.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_root.js +5 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setCacheAdd.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setCacheHas.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setToArray.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setToString.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_shortOut.js +14 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_shuffleSelf.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackClear.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackDelete.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackGet.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackHas.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackSet.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_strictIndexOf.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stringToPath.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_toKey.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_toSource.js +15 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/assign.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/cloneDeep.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/compact.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/constant.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/defaults.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/difference.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/differenceWith.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/eq.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/every.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/get.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/hasIn.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/identity.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArguments.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArray.js +4 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArrayLike.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArrayLikeObject.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isBuffer.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEmpty.js +21 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEqual.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isFunction.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isLength.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isMap.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isObject.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isObjectLike.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isSet.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isSymbol.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isTypedArray.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/keys.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/keysIn.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/last.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/map.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/memoize.js +16 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/noop.js +4 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/property.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/reduce.js +12 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/shuffle.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/stubArray.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/stubFalse.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toString.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/uniq.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/uniqueId.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/values.js +8 -0
- package/package.json +81 -17
- package/CHANGELOG.json +0 -1312
- package/CHANGELOG.md +0 -2432
- package/LICENSE.md +0 -5
- package/README.md +0 -57
- package/configure/CHANGELOG.json +0 -952
- package/configure/CHANGELOG.md +0 -2127
- package/configure/lib/choice-editor.js +0 -252
- package/configure/lib/choice-editor.js.map +0 -1
- package/configure/lib/choice-tile.js +0 -205
- package/configure/lib/choice-tile.js.map +0 -1
- package/configure/lib/defaults.js +0 -211
- package/configure/lib/defaults.js.map +0 -1
- package/configure/lib/design.js +0 -427
- package/configure/lib/design.js.map +0 -1
- package/configure/lib/help.js +0 -14
- package/configure/lib/help.js.map +0 -1
- package/configure/lib/index.js +0 -155
- package/configure/lib/index.js.map +0 -1
- package/configure/lib/utils.js +0 -108
- package/configure/lib/utils.js.map +0 -1
- package/configure/package.json +0 -26
- package/controller/CHANGELOG.json +0 -517
- package/controller/CHANGELOG.md +0 -1518
- package/controller/lib/defaults.js +0 -29
- package/controller/lib/defaults.js.map +0 -1
- package/controller/lib/index.js +0 -285
- package/controller/lib/index.js.map +0 -1
- package/controller/lib/scoring.js +0 -109
- package/controller/lib/scoring.js.map +0 -1
- package/controller/package.json +0 -15
- package/docs/config-schema.json +0 -2964
- package/docs/config-schema.json.md +0 -2190
- package/docs/demo/config.js +0 -8
- package/docs/demo/generate.js +0 -50
- package/docs/demo/index.html +0 -1
- package/docs/demo/session.js +0 -7
- package/docs/pie-schema.json +0 -1613
- package/docs/pie-schema.json.md +0 -973
- package/icon.png +0 -0
- package/lib/index.js +0 -122
- package/lib/index.js.map +0 -1
- package/lib/main.js +0 -32
- package/lib/main.js.map +0 -1
- package/lib/ordering.js +0 -165
- package/lib/ordering.js.map +0 -1
- package/lib/placement-ordering.js +0 -419
- package/lib/placement-ordering.js.map +0 -1
- package/lib/tile.js +0 -259
- package/lib/tile.js.map +0 -1
- package/lib/tiler.js +0 -165
- package/lib/tiler.js.map +0 -1
- package/lib/utils.js +0 -18
- package/lib/utils.js.map +0 -1
|
@@ -0,0 +1,159 @@
|
|
|
1
|
+
//#region src/author/defaults.ts
|
|
2
|
+
var e = {
|
|
3
|
+
model: {
|
|
4
|
+
choiceLabel: "",
|
|
5
|
+
choiceLabelEnabled: !0,
|
|
6
|
+
choices: [],
|
|
7
|
+
correctResponse: [],
|
|
8
|
+
feedbackEnabled: !1,
|
|
9
|
+
numberedGuides: !1,
|
|
10
|
+
orientation: "vertical",
|
|
11
|
+
partialScoring: !0,
|
|
12
|
+
placementArea: !1,
|
|
13
|
+
prompt: "",
|
|
14
|
+
promptEnabled: !0,
|
|
15
|
+
rationale: "",
|
|
16
|
+
rationaleEnabled: !0,
|
|
17
|
+
removeTilesAfterPlacing: !0,
|
|
18
|
+
scoringType: "auto",
|
|
19
|
+
studentInstructionsEnabled: !0,
|
|
20
|
+
targetLabel: "",
|
|
21
|
+
teacherInstructions: "",
|
|
22
|
+
teacherInstructionsEnabled: !0,
|
|
23
|
+
toolbarEditorPosition: "bottom"
|
|
24
|
+
},
|
|
25
|
+
configuration: {
|
|
26
|
+
baseInputConfiguration: {
|
|
27
|
+
h3: { disabled: !0 },
|
|
28
|
+
audio: { disabled: !1 },
|
|
29
|
+
video: { disabled: !1 },
|
|
30
|
+
image: { disabled: !1 },
|
|
31
|
+
textAlign: { disabled: !0 },
|
|
32
|
+
showParagraphs: { disabled: !1 },
|
|
33
|
+
separateParagraphs: { disabled: !0 }
|
|
34
|
+
},
|
|
35
|
+
choiceLabel: {
|
|
36
|
+
settings: !0,
|
|
37
|
+
label: "Choice label",
|
|
38
|
+
inputConfiguration: {
|
|
39
|
+
audio: { disabled: !1 },
|
|
40
|
+
video: { disabled: !1 },
|
|
41
|
+
image: { disabled: !1 }
|
|
42
|
+
}
|
|
43
|
+
},
|
|
44
|
+
choices: {
|
|
45
|
+
settings: !0,
|
|
46
|
+
label: "Choices",
|
|
47
|
+
inputConfiguration: {
|
|
48
|
+
audio: { disabled: !0 },
|
|
49
|
+
video: { disabled: !0 },
|
|
50
|
+
image: { disabled: !0 }
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
feedback: {
|
|
54
|
+
settings: !0,
|
|
55
|
+
label: "Feedback",
|
|
56
|
+
enabled: !0
|
|
57
|
+
},
|
|
58
|
+
prompt: {
|
|
59
|
+
settings: !0,
|
|
60
|
+
label: "Item Stem",
|
|
61
|
+
required: !1,
|
|
62
|
+
inputConfiguration: {
|
|
63
|
+
audio: { disabled: !1 },
|
|
64
|
+
video: { disabled: !1 },
|
|
65
|
+
image: { disabled: !1 }
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
numberedGuides: {
|
|
69
|
+
settings: !0,
|
|
70
|
+
label: "Numbered guides"
|
|
71
|
+
},
|
|
72
|
+
orientation: {
|
|
73
|
+
settings: !0,
|
|
74
|
+
label: "Orientation"
|
|
75
|
+
},
|
|
76
|
+
partialScoring: {
|
|
77
|
+
settings: !1,
|
|
78
|
+
label: "Allow Partial Scoring"
|
|
79
|
+
},
|
|
80
|
+
placementArea: {
|
|
81
|
+
settings: !0,
|
|
82
|
+
label: "Placement Area"
|
|
83
|
+
},
|
|
84
|
+
rationale: {
|
|
85
|
+
settings: !0,
|
|
86
|
+
label: "Rationale",
|
|
87
|
+
required: !1,
|
|
88
|
+
inputConfiguration: {
|
|
89
|
+
audio: { disabled: !1 },
|
|
90
|
+
video: { disabled: !1 },
|
|
91
|
+
image: { disabled: !1 }
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
removeTilesAfterPlacing: {
|
|
95
|
+
settings: !1,
|
|
96
|
+
label: "Remove Tiles after placing"
|
|
97
|
+
},
|
|
98
|
+
settingsPanelDisabled: !1,
|
|
99
|
+
scoringType: {
|
|
100
|
+
settings: !1,
|
|
101
|
+
label: "Scoring Type"
|
|
102
|
+
},
|
|
103
|
+
studentInstructions: {
|
|
104
|
+
settings: !1,
|
|
105
|
+
label: "Student Instructions"
|
|
106
|
+
},
|
|
107
|
+
targetLabel: {
|
|
108
|
+
settings: !0,
|
|
109
|
+
label: "Target label"
|
|
110
|
+
},
|
|
111
|
+
spellCheck: {
|
|
112
|
+
label: "Spellcheck",
|
|
113
|
+
settings: !1,
|
|
114
|
+
enabled: !0
|
|
115
|
+
},
|
|
116
|
+
teacherInstructions: {
|
|
117
|
+
settings: !0,
|
|
118
|
+
label: "Teacher Instructions",
|
|
119
|
+
required: !1,
|
|
120
|
+
inputConfiguration: {
|
|
121
|
+
audio: { disabled: !1 },
|
|
122
|
+
video: { disabled: !1 },
|
|
123
|
+
image: { disabled: !1 }
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
maxImageWidth: {
|
|
127
|
+
teacherInstructions: 300,
|
|
128
|
+
prompt: 300,
|
|
129
|
+
rationale: 300,
|
|
130
|
+
choicesWithPlacementArea: 240,
|
|
131
|
+
choicesWithoutPlacementArea: 300
|
|
132
|
+
},
|
|
133
|
+
maxImageHeight: {
|
|
134
|
+
teacherInstructions: 300,
|
|
135
|
+
prompt: 300,
|
|
136
|
+
rationale: 300,
|
|
137
|
+
choices: 150
|
|
138
|
+
},
|
|
139
|
+
withRubric: {
|
|
140
|
+
settings: !1,
|
|
141
|
+
label: "Add Rubric"
|
|
142
|
+
},
|
|
143
|
+
mathMlOptions: {
|
|
144
|
+
mmlOutput: !1,
|
|
145
|
+
mmlEditing: !1
|
|
146
|
+
},
|
|
147
|
+
language: {
|
|
148
|
+
settings: !1,
|
|
149
|
+
label: "Specify Language",
|
|
150
|
+
enabled: !1
|
|
151
|
+
},
|
|
152
|
+
languageChoices: {
|
|
153
|
+
label: "Language Choices",
|
|
154
|
+
options: []
|
|
155
|
+
}
|
|
156
|
+
}
|
|
157
|
+
};
|
|
158
|
+
//#endregion
|
|
159
|
+
export { e as default };
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/placement-ordering/configure/src/design.jsx
|
|
3
|
+
* @auto-generated
|
|
4
|
+
*
|
|
5
|
+
* This file is automatically synced from pie-elements and converted to TypeScript.
|
|
6
|
+
* Manual edits will be overwritten on next sync.
|
|
7
|
+
* To make changes, edit the upstream JavaScript file and run sync again.
|
|
8
|
+
*/
|
|
9
|
+
import React from 'react';
|
|
10
|
+
import PropTypes from 'prop-types';
|
|
11
|
+
export declare class Design extends React.Component {
|
|
12
|
+
static propTypes: {
|
|
13
|
+
uploadSoundSupport: PropTypes.Requireable<object>;
|
|
14
|
+
};
|
|
15
|
+
static defaultProps: {};
|
|
16
|
+
constructor(props: any);
|
|
17
|
+
componentDidMount(): void;
|
|
18
|
+
onDragEnd: any;
|
|
19
|
+
render(): React.JSX.Element;
|
|
20
|
+
}
|
|
21
|
+
export default Design;
|
|
@@ -0,0 +1,274 @@
|
|
|
1
|
+
import e from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/cloneDeep.js";
|
|
2
|
+
import t from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEmpty.js";
|
|
3
|
+
import n from "./choice-editor.js";
|
|
4
|
+
import { buildTiles as r, generateValidationMessage as i, normalizeIndex as a, updateResponseOrChoices as o } from "./utils.js";
|
|
5
|
+
import s from "react";
|
|
6
|
+
import c from "debug";
|
|
7
|
+
import l from "prop-types";
|
|
8
|
+
import { styled as u } from "@mui/material/styles";
|
|
9
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
10
|
+
import { DragProvider as p } from "@pie-lib/drag";
|
|
11
|
+
import { get as m, set as h } from "nested-property";
|
|
12
|
+
import g from "pluralize";
|
|
13
|
+
import ee from "@mui/icons-material/Info";
|
|
14
|
+
import te from "@mui/material/Tooltip";
|
|
15
|
+
import { FeedbackConfig as ne, FormSection as _, InputContainer as v, layout as re, settings as y } from "@pie-lib/config-ui";
|
|
16
|
+
import b from "@pie-lib/editable-html-tip-tap";
|
|
17
|
+
//#region src/author/design.tsx
|
|
18
|
+
var x = c("@pie-element:placement-ordering:design"), { Panel: ie, toggle: S, radio: ae, dropdown: oe } = y, se = (e) => g.isPlural(e) ? {
|
|
19
|
+
singularLabel: g.singular(e),
|
|
20
|
+
pluralLabel: e
|
|
21
|
+
} : {
|
|
22
|
+
singularLabel: e,
|
|
23
|
+
pluralLabel: g(e)
|
|
24
|
+
}, C = u(v)(({ theme: e }) => ({
|
|
25
|
+
width: "100%",
|
|
26
|
+
paddingTop: e.spacing(2),
|
|
27
|
+
marginBottom: e.spacing(2)
|
|
28
|
+
})), ce = u("div")({
|
|
29
|
+
display: "grid",
|
|
30
|
+
gridAutoFlow: "column",
|
|
31
|
+
gridAutoColumns: "1fr",
|
|
32
|
+
gridGap: "8px"
|
|
33
|
+
}), le = u(_)(({ theme: e }) => ({
|
|
34
|
+
marginTop: 0,
|
|
35
|
+
marginBottom: e.spacing(2.5)
|
|
36
|
+
})), ue = u("div")({
|
|
37
|
+
display: "inline-flex",
|
|
38
|
+
position: "absolute"
|
|
39
|
+
}), de = u("div")(({ theme: e }) => ({
|
|
40
|
+
fontSize: e.typography.fontSize - 2,
|
|
41
|
+
color: e.palette.error.main,
|
|
42
|
+
paddingTop: e.spacing(1)
|
|
43
|
+
})), w = class extends s.Component {
|
|
44
|
+
static propTypes = { uploadSoundSupport: l.object };
|
|
45
|
+
static defaultProps = {};
|
|
46
|
+
constructor(t) {
|
|
47
|
+
super(t), this.applyUpdate = (t) => {
|
|
48
|
+
let { model: n, onModelChanged: r } = this.props;
|
|
49
|
+
r(t(e(n)));
|
|
50
|
+
}, this.changeHandler = (e, t) => (n) => {
|
|
51
|
+
x("[changeHandler] value: ", n);
|
|
52
|
+
let r = t ? m(n, t) : n;
|
|
53
|
+
this.applyUpdate((t) => (h(t, e, r), t));
|
|
54
|
+
}, this.onPromptChange = this.changeHandler("prompt"), this.onTeacherInstructionsChange = this.changeHandler("teacherInstructions"), this.onRationaleChange = this.changeHandler("rationale"), this.onChoiceAreaLabelChange = this.changeHandler("choiceLabel", "target.value"), this.onAnswerAreaLabelChange = this.changeHandler("targetLabel", "target.value"), this.onFeedbackChange = this.changeHandler("feedback"), this.onChoiceEditorChange = (t, n) => {
|
|
55
|
+
let { model: r, onModelChanged: i } = this.props, a = e(r);
|
|
56
|
+
a.choices = t, a.correctResponse = n, i(a);
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
componentDidMount() {
|
|
60
|
+
let { model: t, onModelChanged: n } = this.props || {}, { feedback: r } = t || {}, i = e(t);
|
|
61
|
+
r || (i.feedbackEnabled = !1, n(i));
|
|
62
|
+
}
|
|
63
|
+
onDragEnd = (e, t) => {
|
|
64
|
+
let { active: n, over: r } = e;
|
|
65
|
+
if (!r || !n) return;
|
|
66
|
+
let i = r.data.current, s = n.data.current, c = t.tiles.find((e) => e.id === s.id && e.type === s.type), l = i, u = {
|
|
67
|
+
...c,
|
|
68
|
+
index: a(c, t)
|
|
69
|
+
}, d = {
|
|
70
|
+
...l,
|
|
71
|
+
index: a(l, t)
|
|
72
|
+
}, { response: f, choices: p } = o(t.response, t.choices, u, d);
|
|
73
|
+
this.onChoiceEditorChange(p, f);
|
|
74
|
+
};
|
|
75
|
+
render() {
|
|
76
|
+
let { model: e, imageSupport: a, uploadSoundSupport: o, onModelChanged: s, configuration: c, onConfigurationChanged: l } = this.props, { baseInputConfiguration: u = {}, choiceLabel: m = {}, choices: h = {}, contentDimensions: g = {}, feedback: _ = {}, prompt: v = {}, placementArea: y = {}, maxImageWidth: x = {}, maxImageHeight: w = {}, numberedGuides: T = {}, orientation: E = {}, partialScoring: D = {}, rationale: O = {}, removeTilesAfterPlacing: k = {}, settingsPanelDisabled: fe, studentInstructions: A = {}, spellCheck: j = {}, scoringType: M = {}, targetLabel: N = {}, teacherInstructions: P = {}, withRubric: F = {}, mathMlOptions: I = {}, language: L = {}, languageChoices: R = {} } = c || {}, { choiceLabelEnabled: pe, errors: z, extraCSSRules: me, feedbackEnabled: he, promptEnabled: ge, rationaleEnabled: _e, spellCheckEnabled: B, teacherInstructionsEnabled: ve, toolbarEditorPosition: ye, correctResponse: V } = e || {}, { prompt: H, rationale: U, teacherInstructions: W } = z || {}, G = {
|
|
77
|
+
choices: e.choices,
|
|
78
|
+
response: !V || t(V) ? Array(e.choices.length) : V,
|
|
79
|
+
tiles: r(e.choices, V)
|
|
80
|
+
}, be = i(), { singularLabel: K = "", pluralLabel: q = "" } = h?.label && se(h.label) || {}, J = x && x.prompt, Y = w && w.prompt, X = x && e.placementArea ? x.choicesWithPlacementArea : x.choicesWithoutPlacementArea || J, Z = w && w.choices || Y, Q = { position: ye === "top" ? "top" : "bottom" }, xe = {
|
|
81
|
+
choiceLabelEnabled: m.settings && S(m.label),
|
|
82
|
+
placementArea: y.settings && S(y.label),
|
|
83
|
+
numberedGuides: T.settings && e.placementArea && S(T.label),
|
|
84
|
+
orientation: E.settings && ae(E.label, ["vertical", "horizontal"]),
|
|
85
|
+
removeTilesAfterPlacing: k.settings && S(k.label),
|
|
86
|
+
partialScoring: D.settings && S(D.label),
|
|
87
|
+
feedbackEnabled: _.settings && S(_.label),
|
|
88
|
+
"language.enabled": L.settings && S(L.label, !0),
|
|
89
|
+
language: L.settings && L.enabled && oe(R.label, R.options)
|
|
90
|
+
}, Se = {
|
|
91
|
+
teacherInstructionsEnabled: P.settings && S(P.label),
|
|
92
|
+
studentInstructionsEnabled: A.settings && S(A.label),
|
|
93
|
+
rationaleEnabled: O.settings && S(O.label),
|
|
94
|
+
promptEnabled: v.settings && S(v.label),
|
|
95
|
+
spellCheckEnabled: j.settings && S(j.label),
|
|
96
|
+
scoringType: M.settings && ae(M.label, ["auto", "rubric"]),
|
|
97
|
+
rubricEnabled: F?.settings && S(F?.label)
|
|
98
|
+
}, $ = (e = {}) => ({
|
|
99
|
+
...u,
|
|
100
|
+
...e
|
|
101
|
+
});
|
|
102
|
+
return /* @__PURE__ */ d(p, {
|
|
103
|
+
onDragEnd: (e) => this.onDragEnd(e, G),
|
|
104
|
+
children: /* @__PURE__ */ f(re.ConfigLayout, {
|
|
105
|
+
extraCSSRules: me,
|
|
106
|
+
dimensions: g,
|
|
107
|
+
hideSettings: fe,
|
|
108
|
+
settings: /* @__PURE__ */ d(ie, {
|
|
109
|
+
model: e,
|
|
110
|
+
configuration: c,
|
|
111
|
+
onChangeModel: (e) => s(e),
|
|
112
|
+
onChangeConfiguration: (e) => l(e, !0),
|
|
113
|
+
groups: {
|
|
114
|
+
Settings: xe,
|
|
115
|
+
Properties: Se
|
|
116
|
+
}
|
|
117
|
+
}),
|
|
118
|
+
children: [
|
|
119
|
+
ve && /* @__PURE__ */ f(C, {
|
|
120
|
+
label: P.label,
|
|
121
|
+
children: [/* @__PURE__ */ d(b, {
|
|
122
|
+
className: "prompt",
|
|
123
|
+
markup: e.teacherInstructions || "",
|
|
124
|
+
onChange: this.onTeacherInstructionsChange,
|
|
125
|
+
imageSupport: a,
|
|
126
|
+
nonEmpty: !1,
|
|
127
|
+
error: W,
|
|
128
|
+
toolbarOpts: Q,
|
|
129
|
+
pluginProps: $(P?.inputConfiguration),
|
|
130
|
+
spellCheck: B,
|
|
131
|
+
maxImageWidth: x && x.teacherInstructions || J,
|
|
132
|
+
maxImageHeight: w && w.teacherInstructions || Y,
|
|
133
|
+
uploadSoundSupport: o,
|
|
134
|
+
languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
|
|
135
|
+
mathMlOptions: I
|
|
136
|
+
}), W && /* @__PURE__ */ d("div", {
|
|
137
|
+
className: "errorText",
|
|
138
|
+
children: W
|
|
139
|
+
})]
|
|
140
|
+
}),
|
|
141
|
+
ge && /* @__PURE__ */ f(C, {
|
|
142
|
+
label: v && v.label,
|
|
143
|
+
children: [/* @__PURE__ */ d(b, {
|
|
144
|
+
className: "prompt",
|
|
145
|
+
markup: e.prompt,
|
|
146
|
+
onChange: this.onPromptChange,
|
|
147
|
+
imageSupport: a,
|
|
148
|
+
error: H,
|
|
149
|
+
toolbarOpts: Q,
|
|
150
|
+
pluginProps: $(v?.inputConfiguration),
|
|
151
|
+
spellCheck: B,
|
|
152
|
+
maxImageWidth: x && x.prompt,
|
|
153
|
+
maxImageHeight: w && w.prompt,
|
|
154
|
+
uploadSoundSupport: o,
|
|
155
|
+
languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
|
|
156
|
+
mathMlOptions: I
|
|
157
|
+
}), H && /* @__PURE__ */ d("div", {
|
|
158
|
+
className: "errorText",
|
|
159
|
+
children: H
|
|
160
|
+
})]
|
|
161
|
+
}),
|
|
162
|
+
/* @__PURE__ */ f(le, {
|
|
163
|
+
label: `Define ${q}`,
|
|
164
|
+
labelExtraStyle: { display: "inline-flex" },
|
|
165
|
+
children: [
|
|
166
|
+
/* @__PURE__ */ d(ue, { children: /* @__PURE__ */ d(te, {
|
|
167
|
+
slotProps: { tooltip: { sx: {
|
|
168
|
+
fontSize: 14,
|
|
169
|
+
whiteSpace: "pre",
|
|
170
|
+
maxWidth: "500px"
|
|
171
|
+
} } },
|
|
172
|
+
disableFocusListener: !0,
|
|
173
|
+
disableTouchListener: !0,
|
|
174
|
+
placement: "right",
|
|
175
|
+
title: be,
|
|
176
|
+
children: /* @__PURE__ */ d(ee, {
|
|
177
|
+
fontSize: "small",
|
|
178
|
+
color: "primary",
|
|
179
|
+
style: { marginLeft: "8px" }
|
|
180
|
+
})
|
|
181
|
+
}) }),
|
|
182
|
+
/* @__PURE__ */ f(ce, { children: [pe && /* @__PURE__ */ d(C, {
|
|
183
|
+
label: m && m.label && `${K} label`,
|
|
184
|
+
children: /* @__PURE__ */ d(b, {
|
|
185
|
+
...e.placementArea && { autoWidthToolbar: !0 },
|
|
186
|
+
className: "prompt",
|
|
187
|
+
markup: e.choiceLabel,
|
|
188
|
+
onChange: this.onChoiceAreaLabelChange,
|
|
189
|
+
toolbarOpts: Q,
|
|
190
|
+
pluginProps: $(m?.inputConfiguration),
|
|
191
|
+
spellCheck: B,
|
|
192
|
+
maxImageWidth: X,
|
|
193
|
+
maxImageHeight: Z,
|
|
194
|
+
uploadSoundSupport: o,
|
|
195
|
+
languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
|
|
196
|
+
mathMlOptions: I
|
|
197
|
+
})
|
|
198
|
+
}), N.settings && e.placementArea && /* @__PURE__ */ d(C, {
|
|
199
|
+
label: N && N.label && N.label,
|
|
200
|
+
children: /* @__PURE__ */ d(b, {
|
|
201
|
+
autoWidthToolbar: !0,
|
|
202
|
+
className: "prompt",
|
|
203
|
+
markup: e.targetLabel,
|
|
204
|
+
onChange: this.onAnswerAreaLabelChange,
|
|
205
|
+
toolbarOpts: Q,
|
|
206
|
+
spellCheck: B,
|
|
207
|
+
maxImageWidth: x && x.choicesWithPlacementArea || J,
|
|
208
|
+
maxImageHeight: Z,
|
|
209
|
+
uploadSoundSupport: o,
|
|
210
|
+
languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
|
|
211
|
+
mathMlOptions: I
|
|
212
|
+
})
|
|
213
|
+
})] }),
|
|
214
|
+
h.settings && /* @__PURE__ */ d(n, {
|
|
215
|
+
correctResponse: V,
|
|
216
|
+
choices: e.choices,
|
|
217
|
+
onChange: this.onChoiceEditorChange,
|
|
218
|
+
imageSupport: a,
|
|
219
|
+
toolbarOpts: Q,
|
|
220
|
+
pluginProps: $(h?.inputConfiguration),
|
|
221
|
+
choicesLabel: h.label,
|
|
222
|
+
placementArea: e.placementArea,
|
|
223
|
+
singularChoiceLabel: K,
|
|
224
|
+
pluralChoiceLabel: q,
|
|
225
|
+
spellCheck: B,
|
|
226
|
+
maxImageWidth: X,
|
|
227
|
+
maxImageHeight: Z,
|
|
228
|
+
errors: z || {},
|
|
229
|
+
mathMlOptions: I,
|
|
230
|
+
ordering: G
|
|
231
|
+
})
|
|
232
|
+
]
|
|
233
|
+
}),
|
|
234
|
+
_e && /* @__PURE__ */ f(C, {
|
|
235
|
+
label: O.label,
|
|
236
|
+
children: [/* @__PURE__ */ d(b, {
|
|
237
|
+
className: "prompt",
|
|
238
|
+
markup: e.rationale || "",
|
|
239
|
+
onChange: this.onRationaleChange,
|
|
240
|
+
imageSupport: a,
|
|
241
|
+
error: U,
|
|
242
|
+
toolbarOpts: Q,
|
|
243
|
+
pluginProps: $(O?.inputConfiguration),
|
|
244
|
+
spellCheck: B,
|
|
245
|
+
maxImageWidth: x && x.rationale || J,
|
|
246
|
+
maxImageHeight: w && w.rationale || Y,
|
|
247
|
+
uploadSoundSupport: o,
|
|
248
|
+
languageCharactersProps: [{ language: "spanish" }, { language: "special" }],
|
|
249
|
+
mathMlOptions: I
|
|
250
|
+
}), U && /* @__PURE__ */ d(de, { children: U })]
|
|
251
|
+
}),
|
|
252
|
+
he && /* @__PURE__ */ d(ne, {
|
|
253
|
+
feedback: e.feedback,
|
|
254
|
+
onChange: this.onFeedbackChange,
|
|
255
|
+
imageSupport: a,
|
|
256
|
+
toolbarOpts: Q
|
|
257
|
+
})
|
|
258
|
+
]
|
|
259
|
+
})
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
};
|
|
263
|
+
w.defaultProps = {
|
|
264
|
+
onModelChanged: () => {},
|
|
265
|
+
onConfigurationChanged: () => {}
|
|
266
|
+
}, w.propTypes = {
|
|
267
|
+
model: l.object.isRequired,
|
|
268
|
+
configuration: l.object.isRequired,
|
|
269
|
+
onModelChanged: l.func,
|
|
270
|
+
onConfigurationChanged: l.func,
|
|
271
|
+
imageSupport: l.object
|
|
272
|
+
};
|
|
273
|
+
//#endregion
|
|
274
|
+
export { w as default };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/placement-ordering/configure/src/help.jsx
|
|
3
|
+
* @auto-generated
|
|
4
|
+
*
|
|
5
|
+
* This file is automatically synced from pie-elements and converted to TypeScript.
|
|
6
|
+
* Manual edits will be overwritten on next sync.
|
|
7
|
+
* To make changes, edit the upstream JavaScript file and run sync again.
|
|
8
|
+
*/
|
|
9
|
+
import React from 'react';
|
|
10
|
+
declare const Comp: () => React.JSX.Element;
|
|
11
|
+
export default Comp;
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/placement-ordering/configure/src/index.js
|
|
3
|
+
* @auto-generated
|
|
4
|
+
*
|
|
5
|
+
* This file is automatically synced from pie-elements and converted to TypeScript.
|
|
6
|
+
* Manual edits will be overwritten on next sync.
|
|
7
|
+
* To make changes, edit the upstream JavaScript file and run sync again.
|
|
8
|
+
*/
|
|
9
|
+
export declare const addWeightToCorrectResponse: (correctResponse: any) => any;
|
|
10
|
+
/**
|
|
11
|
+
* assuming that the correct response will be set via ui, not via config,
|
|
12
|
+
* correctResponse (if not set) will be initialized with choices default order
|
|
13
|
+
*/
|
|
14
|
+
export default class PlacementOrdering extends HTMLElement {
|
|
15
|
+
static createDefaultModel: (model?: {}) => {
|
|
16
|
+
choiceLabel: string;
|
|
17
|
+
choiceLabelEnabled: boolean;
|
|
18
|
+
choices: never[];
|
|
19
|
+
correctResponse: never[];
|
|
20
|
+
feedbackEnabled: boolean;
|
|
21
|
+
numberedGuides: boolean;
|
|
22
|
+
orientation: string;
|
|
23
|
+
partialScoring: boolean;
|
|
24
|
+
placementArea: boolean;
|
|
25
|
+
prompt: string;
|
|
26
|
+
promptEnabled: boolean;
|
|
27
|
+
rationale: string;
|
|
28
|
+
rationaleEnabled: boolean;
|
|
29
|
+
removeTilesAfterPlacing: boolean;
|
|
30
|
+
scoringType: string;
|
|
31
|
+
studentInstructionsEnabled: boolean;
|
|
32
|
+
targetLabel: string;
|
|
33
|
+
teacherInstructions: string;
|
|
34
|
+
teacherInstructionsEnabled: boolean;
|
|
35
|
+
toolbarEditorPosition: string;
|
|
36
|
+
};
|
|
37
|
+
constructor();
|
|
38
|
+
dispatchUpdate(reset: any): void;
|
|
39
|
+
set model(s: any);
|
|
40
|
+
set configuration(c: any);
|
|
41
|
+
insertSound(handler: any): void;
|
|
42
|
+
onDeleteSound(src: any, done: any): void;
|
|
43
|
+
_rerender(): void;
|
|
44
|
+
disconnectedCallback(): void;
|
|
45
|
+
}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import e from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/defaults.js";
|
|
2
|
+
import t from "./design.js";
|
|
3
|
+
import n from "./defaults.js";
|
|
4
|
+
import r from "react";
|
|
5
|
+
import { createRoot as i } from "react-dom/client";
|
|
6
|
+
import { DeleteImageEvent as a, DeleteSoundEvent as o, InsertImageEvent as s, InsertSoundEvent as c, ModelUpdatedEvent as l } from "@pie-element/shared-configure-events";
|
|
7
|
+
//#region src/author/index.ts
|
|
8
|
+
var u = (t, r) => ({
|
|
9
|
+
configuration: e(t, n.configuration),
|
|
10
|
+
model: r
|
|
11
|
+
}), d = (e) => e && e.map((e) => e.weight === void 0 ? {
|
|
12
|
+
id: e.id || e,
|
|
13
|
+
weight: 0
|
|
14
|
+
} : {
|
|
15
|
+
id: e.id,
|
|
16
|
+
weight: e.weight
|
|
17
|
+
}), f = class e extends HTMLElement {
|
|
18
|
+
static createDefaultModel = (e = {}) => {
|
|
19
|
+
let t = d(e.correctResponse) || ((e) => e && e.map((e) => ({
|
|
20
|
+
id: e.id,
|
|
21
|
+
weight: 0
|
|
22
|
+
})))(e.choices), r = {
|
|
23
|
+
...n.model,
|
|
24
|
+
...e
|
|
25
|
+
};
|
|
26
|
+
return t && (r.correctResponse = t), r;
|
|
27
|
+
};
|
|
28
|
+
constructor() {
|
|
29
|
+
super(), this._root = null, this._model = e.createDefaultModel(), this._configuration = n.configuration, this.onModelChanged = (e, t) => {
|
|
30
|
+
this._model = e, this._rerender(), this.dispatchUpdate(t);
|
|
31
|
+
}, this.onConfigurationChanged = (e) => {
|
|
32
|
+
this._configuration = u(e).configuration, this.onModelChanged(this._model), this._rerender();
|
|
33
|
+
}, this.insertImage = (e) => {
|
|
34
|
+
this.dispatchEvent(new s(e));
|
|
35
|
+
}, this.deleteImage = (e, t) => {
|
|
36
|
+
this.dispatchEvent(new a(e, t));
|
|
37
|
+
};
|
|
38
|
+
}
|
|
39
|
+
dispatchUpdate(e) {
|
|
40
|
+
this.dispatchEvent(new l(this._model, e));
|
|
41
|
+
}
|
|
42
|
+
set model(t) {
|
|
43
|
+
this._model = e.createDefaultModel(t), this._rerender();
|
|
44
|
+
}
|
|
45
|
+
set configuration(e) {
|
|
46
|
+
let t = u(e, this._model);
|
|
47
|
+
this.onModelChanged(t.model);
|
|
48
|
+
let r = {
|
|
49
|
+
...n.configuration,
|
|
50
|
+
...t.configuration
|
|
51
|
+
};
|
|
52
|
+
this._configuration = r, r?.language?.enabled ? r?.languageChoices?.options?.length && (this._model.language = r?.languageChoices.options[0].value) : r.language.settings && this._model.language ? (this._configuration.language.enabled = !0, (!this._configuration.languageChoices.options || !this._configuration.languageChoices.options.length) && (this._configuration.languageChoices.options = []), this._configuration.languageChoices.options.find((e) => e.value === this._model.language) || this._configuration.languageChoices.options.push({
|
|
53
|
+
value: this._model.language,
|
|
54
|
+
label: this._model.language
|
|
55
|
+
})) : delete this._model.language, this._rerender();
|
|
56
|
+
}
|
|
57
|
+
insertSound(e) {
|
|
58
|
+
this.dispatchEvent(new c(e));
|
|
59
|
+
}
|
|
60
|
+
onDeleteSound(e, t) {
|
|
61
|
+
this.dispatchEvent(new o(e, t));
|
|
62
|
+
}
|
|
63
|
+
_rerender() {
|
|
64
|
+
let e = r.createElement(t, {
|
|
65
|
+
model: this._model,
|
|
66
|
+
configuration: this._configuration,
|
|
67
|
+
onModelChanged: this.onModelChanged,
|
|
68
|
+
onConfigurationChanged: this.onConfigurationChanged,
|
|
69
|
+
imageSupport: {
|
|
70
|
+
add: this.insertImage,
|
|
71
|
+
delete: this.deleteImage
|
|
72
|
+
},
|
|
73
|
+
uploadSoundSupport: {
|
|
74
|
+
add: this.insertSound.bind(this),
|
|
75
|
+
delete: this.onDeleteSound.bind(this)
|
|
76
|
+
}
|
|
77
|
+
});
|
|
78
|
+
this._root ||= i(this), this._root.render(e);
|
|
79
|
+
}
|
|
80
|
+
disconnectedCallback() {
|
|
81
|
+
this._root && this._root.unmount();
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
//#endregion
|
|
85
|
+
export { d as addWeightToCorrectResponse, f as default };
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/placement-ordering/configure/src/utils.js
|
|
3
|
+
* @auto-generated
|
|
4
|
+
*
|
|
5
|
+
* This file is automatically synced from pie-elements and converted to TypeScript.
|
|
6
|
+
* Manual edits will be overwritten on next sync.
|
|
7
|
+
* To make changes, edit the upstream JavaScript file and run sync again.
|
|
8
|
+
*/
|
|
9
|
+
export declare const generateValidationMessage: () => string;
|
|
10
|
+
export declare function normalizeIndex(tile: any, ordering: any): any;
|
|
11
|
+
export declare function updateResponseOrChoices(response: any, choices: any, from: any, to: any): {
|
|
12
|
+
response: any;
|
|
13
|
+
choices: any;
|
|
14
|
+
};
|
|
15
|
+
export declare function buildTiles(choices: any, response: any): any;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import e from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/cloneDeep.js";
|
|
2
|
+
//#region src/author/utils.ts
|
|
3
|
+
var t = () => "Validation requirements:\nThere should be at least 3 tokens.\nThe tokens should not be empty and should be unique.\nThe correct ordering should not be identical to the initial ordering.";
|
|
4
|
+
function n(e, t) {
|
|
5
|
+
return e.type === "target" ? t.response.findIndex((t) => t.id === e.id) : e.type === "choice" ? t.choices.findIndex((t) => t.id === e.id) : -1;
|
|
6
|
+
}
|
|
7
|
+
function r(t, n, r, i) {
|
|
8
|
+
let { type: a, index: o } = r, { type: s, index: c } = i;
|
|
9
|
+
if (a === "target" && s === "target") {
|
|
10
|
+
let { movedItem: r, remainingItems: i } = (e(t) || []).reduce((e, t, n) => (n === o ? e.movedItem = t : e.remainingItems.push(t), e), {
|
|
11
|
+
movedItem: null,
|
|
12
|
+
remainingItems: []
|
|
13
|
+
});
|
|
14
|
+
return {
|
|
15
|
+
response: [
|
|
16
|
+
...i.slice(0, c),
|
|
17
|
+
r,
|
|
18
|
+
...i.slice(c)
|
|
19
|
+
],
|
|
20
|
+
choices: n
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
if (a === "choice" && s === "choice") {
|
|
24
|
+
let { movedItem: a, remainingItems: o, toIndex: s } = (e(n) || []).reduce((e, t, n) => (t.id === r.id ? e.movedItem = t : e.remainingItems.push(t), t.id === i.id && (e.toIndex = n), e), {
|
|
25
|
+
movedItem: null,
|
|
26
|
+
remainingItems: [],
|
|
27
|
+
toIndex: null
|
|
28
|
+
});
|
|
29
|
+
return {
|
|
30
|
+
response: t,
|
|
31
|
+
choices: [
|
|
32
|
+
...o.slice(0, s),
|
|
33
|
+
a,
|
|
34
|
+
...o.slice(s)
|
|
35
|
+
]
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
return {
|
|
39
|
+
response: t,
|
|
40
|
+
choices: n
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
function i(e, t) {
|
|
44
|
+
let n = t.map((t, n) => {
|
|
45
|
+
let r = t && t.id;
|
|
46
|
+
return {
|
|
47
|
+
type: "target",
|
|
48
|
+
...e.find((e) => r != null && e.id === r),
|
|
49
|
+
draggable: !0,
|
|
50
|
+
index: n,
|
|
51
|
+
editable: !1
|
|
52
|
+
};
|
|
53
|
+
});
|
|
54
|
+
return e.map((e) => Object.assign({}, e, {
|
|
55
|
+
type: "choice",
|
|
56
|
+
droppable: !1,
|
|
57
|
+
draggable: !0,
|
|
58
|
+
editable: !0
|
|
59
|
+
})).concat(n);
|
|
60
|
+
}
|
|
61
|
+
//#endregion
|
|
62
|
+
export { i as buildTiles, t as generateValidationMessage, n as normalizeIndex, r as updateResponseOrChoices };
|