@pie-element/explicit-constructed-response 11.1.1-next.11 → 11.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/_virtual/_rolldown/runtime.js +4 -0
- package/dist/author/alternateResponses.d.ts +34 -0
- package/dist/author/alternateResponses.js +116 -0
- package/dist/author/alternateSection.d.ts +58 -0
- package/dist/author/alternateSection.js +215 -0
- package/dist/author/defaults.d.ts +186 -0
- package/dist/author/defaults.js +128 -0
- package/dist/author/ecr-toolbar.d.ts +41 -0
- package/dist/author/ecr-toolbar.js +100 -0
- package/dist/author/index.d.ts +42 -0
- package/dist/author/index.js +97 -0
- package/dist/author/main.d.ts +38 -0
- package/dist/author/main.js +294 -0
- package/dist/author/markupUtils.d.ts +14 -0
- package/dist/author/markupUtils.js +13 -0
- package/dist/author/utils.d.ts +9 -0
- package/dist/author/utils.js +7 -0
- package/dist/browser/author/index.js +3498 -0
- package/dist/browser/author/index.js.map +1 -0
- package/dist/browser/browser-DbR93LB7.js +950 -0
- package/dist/browser/browser-DbR93LB7.js.map +1 -0
- package/dist/browser/controller/index.js +4183 -0
- package/dist/browser/controller/index.js.map +1 -0
- package/dist/browser/delivery/index.js +96 -0
- package/dist/browser/delivery/index.js.map +1 -0
- package/dist/browser/dist-D9ARZhQk.js +1426 -0
- package/dist/browser/dist-D9ARZhQk.js.map +1 -0
- package/dist/browser/dist-DnL6t4VO.js +46135 -0
- package/dist/browser/dist-DnL6t4VO.js.map +1 -0
- package/dist/browser/explicit-constructed-response.css +2 -0
- package/dist/browser/main-V_e6PRBN.js +941 -0
- package/dist/browser/main-V_e6PRBN.js.map +1 -0
- package/dist/browser/print/index.js +40 -0
- package/dist/browser/print/index.js.map +1 -0
- package/dist/browser/reduce-Bqz7DMQ0.js +172 -0
- package/dist/browser/reduce-Bqz7DMQ0.js.map +1 -0
- package/dist/controller/defaults.d.ts +25 -0
- package/dist/controller/defaults.js +19 -0
- package/dist/controller/index.d.ts +64 -0
- package/dist/controller/index.js +142 -0
- package/dist/delivery/index.d.ts +20 -0
- package/dist/delivery/index.js +66 -0
- package/dist/delivery/main.d.ts +48 -0
- package/dist/delivery/main.js +117 -0
- package/dist/explicit-constructed-response.css +2 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.iife.d.ts +8 -0
- package/dist/index.iife.js +393 -0
- package/dist/index.js +2 -0
- package/dist/node_modules/.bun/he@1.2.0/node_modules/he/he.js +3993 -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/_arrayFilter.js +10 -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/_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/_baseEach.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseExtremum.js +11 -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/_baseGt.js +6 -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/_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/_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/_basePick.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_basePickBy.js +13 -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/_basePropertyOf.js +8 -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/_baseSet.js +22 -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/_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/_baseTrim.js +8 -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/_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/_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/_createFind.js +19 -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/_escapeHtmlChar.js +11 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_flatRest.js +9 -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/_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/_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/_trimmedEndIndex.js +8 -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/constant.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/debounce.js +50 -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/eq.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/escape.js +9 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/find.js +6 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/findIndex.js +13 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/flatten.js +7 -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/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/map.js +10 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/max.js +9 -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/now.js +7 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/pick.js +8 -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/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/throttle.js +15 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toFinite.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toInteger.js +8 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toNumber.js +19 -0
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toString.js +7 -0
- package/dist/print/index.d.ts +15 -0
- package/dist/print/index.js +40 -0
- package/package.json +86 -22
- package/CHANGELOG.json +0 -1102
- package/CHANGELOG.md +0 -2183
- package/LICENSE.md +0 -5
- package/README.md +0 -1
- package/configure/CHANGELOG.json +0 -652
- package/configure/CHANGELOG.md +0 -1924
- package/configure/lib/alternateResponses.js +0 -199
- package/configure/lib/alternateResponses.js.map +0 -1
- package/configure/lib/alternateSection.js +0 -329
- package/configure/lib/alternateSection.js.map +0 -1
- package/configure/lib/defaults.js +0 -184
- package/configure/lib/defaults.js.map +0 -1
- package/configure/lib/ecr-toolbar.js +0 -181
- package/configure/lib/ecr-toolbar.js.map +0 -1
- package/configure/lib/index.js +0 -161
- package/configure/lib/index.js.map +0 -1
- package/configure/lib/main.js +0 -501
- package/configure/lib/main.js.map +0 -1
- package/configure/lib/markupUtils.js +0 -70
- package/configure/lib/markupUtils.js.map +0 -1
- package/configure/lib/utils.js +0 -15
- package/configure/lib/utils.js.map +0 -1
- package/configure/package.json +0 -22
- package/controller/CHANGELOG.json +0 -517
- package/controller/CHANGELOG.md +0 -1340
- package/controller/lib/defaults.js +0 -23
- package/controller/lib/defaults.js.map +0 -1
- package/controller/lib/index.js +0 -368
- package/controller/lib/index.js.map +0 -1
- package/controller/package.json +0 -18
- package/docs/config-schema.json +0 -2629
- package/docs/config-schema.json.md +0 -1941
- package/docs/demo/config.js +0 -8
- package/docs/demo/generate.js +0 -20
- package/docs/demo/index.html +0 -1
- package/docs/demo/session.js +0 -10
- package/docs/pie-schema.json +0 -1130
- package/docs/pie-schema.json.md +0 -814
- package/lib/index.js +0 -91
- package/lib/index.js.map +0 -1
- package/lib/main.js +0 -205
- package/lib/main.js.map +0 -1
- package/lib/print.js +0 -71
- package/lib/print.js.map +0 -1
- package/module/configure.js +0 -1
- package/module/controller.js +0 -6534
- package/module/demo.js +0 -45
- package/module/element.js +0 -1
- package/module/index.html +0 -21
- package/module/manifest.json +0 -18
- package/module/print-demo.js +0 -83
- package/module/print.html +0 -18
- package/module/print.js +0 -1
package/configure.js
ADDED
package/controller.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './dist/controller/index.js';
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/explicit-constructed-response/configure/src/alternateResponses.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 AlternateResponses extends React.Component {
|
|
12
|
+
static propTypes: {
|
|
13
|
+
choicesErrors: PropTypes.Requireable<object>;
|
|
14
|
+
model: PropTypes.Validator<object>;
|
|
15
|
+
onChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
16
|
+
onLengthChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
17
|
+
maxLengthPerChoiceEnabled: PropTypes.Validator<boolean>;
|
|
18
|
+
spellCheck: PropTypes.Requireable<boolean>;
|
|
19
|
+
pluginProps: PropTypes.Requireable<object>;
|
|
20
|
+
};
|
|
21
|
+
state: {
|
|
22
|
+
maxLengthPerChoice: any;
|
|
23
|
+
};
|
|
24
|
+
UNSAFE_componentWillReceiveProps(nextProps: any): void;
|
|
25
|
+
componentDidMount(): void;
|
|
26
|
+
updateChoicesIfNeeded: any;
|
|
27
|
+
getRemainingChoices: any;
|
|
28
|
+
onChoiceChanged: any;
|
|
29
|
+
onChoiceRemoved: any;
|
|
30
|
+
onSectionSelect: any;
|
|
31
|
+
onLengthChanged: any;
|
|
32
|
+
render(): React.JSX.Element;
|
|
33
|
+
}
|
|
34
|
+
export default AlternateResponses;
|
|
@@ -0,0 +1,116 @@
|
|
|
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/map.js";
|
|
3
|
+
import n from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEqual.js";
|
|
4
|
+
import r from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/reduce.js";
|
|
5
|
+
import i from "./alternateSection.js";
|
|
6
|
+
import a from "react";
|
|
7
|
+
import o from "prop-types";
|
|
8
|
+
import { jsx as s, jsxs as c } from "react/jsx-runtime";
|
|
9
|
+
//#region src/author/alternateResponses.tsx
|
|
10
|
+
var l = class extends a.Component {
|
|
11
|
+
static propTypes = {
|
|
12
|
+
choicesErrors: o.object,
|
|
13
|
+
model: o.object.isRequired,
|
|
14
|
+
onChange: o.func.isRequired,
|
|
15
|
+
onLengthChange: o.func.isRequired,
|
|
16
|
+
maxLengthPerChoiceEnabled: o.bool.isRequired,
|
|
17
|
+
spellCheck: o.bool,
|
|
18
|
+
pluginProps: o.object
|
|
19
|
+
};
|
|
20
|
+
state = { maxLengthPerChoice: e(this.props.model.maxLengthPerChoice) };
|
|
21
|
+
UNSAFE_componentWillReceiveProps(e) {
|
|
22
|
+
this.updateChoicesIfNeeded(e);
|
|
23
|
+
}
|
|
24
|
+
componentDidMount() {
|
|
25
|
+
this.updateChoicesIfNeeded(this.props);
|
|
26
|
+
}
|
|
27
|
+
updateChoicesIfNeeded = (t) => {
|
|
28
|
+
if (!this.state.choices || !n(this.state.choices, t.model.choices) || !n(t.model.choices, this.props.model.choices) || this.state.values && Object.keys(this.state.values).length !== Object.keys(this.props.model.choices).length || t.maxLengthPerChoiceEnabled !== this.props.maxLengthPerChoiceEnabled) {
|
|
29
|
+
let { choices: n, maxLengthPerChoice: i } = t.model, a = r(n, (e, n, r) => (n && (t.maxLengthPerChoiceEnabled || n.length > 1) && (e[r] = n[0]), e), {});
|
|
30
|
+
this.setState({
|
|
31
|
+
choices: t.model.choices,
|
|
32
|
+
values: a,
|
|
33
|
+
maxLengthPerChoice: e(i)
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
};
|
|
37
|
+
getRemainingChoices = (e) => {
|
|
38
|
+
let { choices: t } = this.state;
|
|
39
|
+
return r(t, (t, n, r) => (n && n.length === 1 && !e && t.push({
|
|
40
|
+
label: n[0].label,
|
|
41
|
+
value: r
|
|
42
|
+
}), t), []);
|
|
43
|
+
};
|
|
44
|
+
onChoiceChanged = (e, t) => {
|
|
45
|
+
let { onChange: n } = this.props, { choices: r } = this.state, i = r[t] || [], a = !i.find((t) => t.value === e.value), o = i.reduce((t, n) => {
|
|
46
|
+
let r = n.value === e.value ? e : n;
|
|
47
|
+
return t.push(r), t;
|
|
48
|
+
}, []);
|
|
49
|
+
a && o.push(e), n({
|
|
50
|
+
...r,
|
|
51
|
+
[t]: o
|
|
52
|
+
});
|
|
53
|
+
};
|
|
54
|
+
onChoiceRemoved = (e, t) => {
|
|
55
|
+
let { onChange: n } = this.props, { choices: r } = this.state, i = (r[t] || []).reduce((t, n) => (n.value === e || t.push(n), t), []);
|
|
56
|
+
n({
|
|
57
|
+
...r,
|
|
58
|
+
[t]: i
|
|
59
|
+
});
|
|
60
|
+
};
|
|
61
|
+
onSectionSelect = (e, t) => {
|
|
62
|
+
let { onChange: n } = this.props, { choices: r, values: i } = this.state;
|
|
63
|
+
r[t] && r[t].length > 1 ? e || n({
|
|
64
|
+
...r,
|
|
65
|
+
[t]: [r[t][0]]
|
|
66
|
+
}) : this.setState({
|
|
67
|
+
choices: {
|
|
68
|
+
...r,
|
|
69
|
+
[t]: [...r[t], {
|
|
70
|
+
label: "",
|
|
71
|
+
value: "1"
|
|
72
|
+
}]
|
|
73
|
+
},
|
|
74
|
+
values: {
|
|
75
|
+
...i,
|
|
76
|
+
[t]: r[t][0]
|
|
77
|
+
}
|
|
78
|
+
});
|
|
79
|
+
};
|
|
80
|
+
onLengthChanged = (e, t) => {
|
|
81
|
+
let { model: n, onLengthChange: r } = this.props, { maxLengthPerChoice: i } = n;
|
|
82
|
+
i[t] = e, r(i);
|
|
83
|
+
};
|
|
84
|
+
render() {
|
|
85
|
+
let { choices: e } = this.state, { model: { maxLengthPerChoice: n, maxLengthPerChoiceEnabled: r }, spellCheck: a, choicesErrors: o, pluginProps: l } = this.props;
|
|
86
|
+
return /* @__PURE__ */ c("div", { children: [t(e, (e, t) => {
|
|
87
|
+
if (e && (r || e.length > 1)) {
|
|
88
|
+
let c = this.state.values[t];
|
|
89
|
+
return /* @__PURE__ */ s(i, {
|
|
90
|
+
value: c && c.value,
|
|
91
|
+
errors: o && o[t],
|
|
92
|
+
onSelect: (e) => this.onSectionSelect(e, t),
|
|
93
|
+
choiceChanged: (e) => this.onChoiceChanged(e, t),
|
|
94
|
+
choiceRemoved: (e) => this.onChoiceRemoved(e, t),
|
|
95
|
+
lengthChanged: (e) => this.onLengthChanged(e, t),
|
|
96
|
+
selectChoices: [c],
|
|
97
|
+
choices: e,
|
|
98
|
+
maxLength: n[t],
|
|
99
|
+
showMaxLength: r,
|
|
100
|
+
spellCheck: a,
|
|
101
|
+
pluginProps: l
|
|
102
|
+
}, t);
|
|
103
|
+
}
|
|
104
|
+
}), e && Object.keys(this.state.values).length !== Object.keys(e).length && /* @__PURE__ */ s(i, {
|
|
105
|
+
value: "",
|
|
106
|
+
onSelect: (e) => this.onSectionSelect(e, e.value),
|
|
107
|
+
choiceChanged: (e) => this.onChoiceChanged(e),
|
|
108
|
+
choiceRemoved: (e) => this.onChoiceRemoved(e),
|
|
109
|
+
selectChoices: this.getRemainingChoices(),
|
|
110
|
+
spellCheck: a,
|
|
111
|
+
pluginProps: l
|
|
112
|
+
})] });
|
|
113
|
+
}
|
|
114
|
+
};
|
|
115
|
+
//#endregion
|
|
116
|
+
export { l as default };
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/explicit-constructed-response/configure/src/alternateSection.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 Choice extends React.Component {
|
|
12
|
+
static propTypes: {
|
|
13
|
+
error: PropTypes.Requireable<string>;
|
|
14
|
+
markup: PropTypes.Requireable<string>;
|
|
15
|
+
onChange: PropTypes.Validator<(...args: any[]) => any>;
|
|
16
|
+
onDelete: PropTypes.Validator<(...args: any[]) => any>;
|
|
17
|
+
value: PropTypes.Requireable<string>;
|
|
18
|
+
spellCheck: PropTypes.Requireable<boolean>;
|
|
19
|
+
showMaxLength: PropTypes.Requireable<boolean>;
|
|
20
|
+
pluginProps: PropTypes.Requireable<object>;
|
|
21
|
+
};
|
|
22
|
+
state: {
|
|
23
|
+
value: any;
|
|
24
|
+
};
|
|
25
|
+
updateText: any;
|
|
26
|
+
UNSAFE_componentWillReceiveProps(nextProps: any): void;
|
|
27
|
+
onChange: any;
|
|
28
|
+
onKeyDown: any;
|
|
29
|
+
render(): React.JSX.Element;
|
|
30
|
+
}
|
|
31
|
+
export declare class AlternateSection extends React.Component {
|
|
32
|
+
static propTypes: {
|
|
33
|
+
choices: PropTypes.Requireable<any[]>;
|
|
34
|
+
selectChoices: PropTypes.Validator<any[]>;
|
|
35
|
+
errors: PropTypes.Requireable<object>;
|
|
36
|
+
onSelect: PropTypes.Validator<(...args: any[]) => any>;
|
|
37
|
+
choiceChanged: PropTypes.Validator<(...args: any[]) => any>;
|
|
38
|
+
lengthChanged: PropTypes.Requireable<(...args: any[]) => any>;
|
|
39
|
+
choiceRemoved: PropTypes.Validator<(...args: any[]) => any>;
|
|
40
|
+
value: PropTypes.Requireable<string>;
|
|
41
|
+
maxLength: PropTypes.Requireable<number>;
|
|
42
|
+
showMaxLength: PropTypes.Requireable<boolean>;
|
|
43
|
+
spellCheck: PropTypes.Requireable<boolean>;
|
|
44
|
+
pluginProps: PropTypes.Requireable<object>;
|
|
45
|
+
};
|
|
46
|
+
state: {};
|
|
47
|
+
UNSAFE_componentWillReceiveProps(nextProps: any): void;
|
|
48
|
+
componentDidMount(): void;
|
|
49
|
+
updateChoicesIfNeeded: any;
|
|
50
|
+
handleSelect: any;
|
|
51
|
+
onAddChoice: any;
|
|
52
|
+
onChoiceChanged: any;
|
|
53
|
+
onRemoveChoice: any;
|
|
54
|
+
getChoicesMaxLength: any;
|
|
55
|
+
changeLength: any;
|
|
56
|
+
render(): React.JSX.Element;
|
|
57
|
+
}
|
|
58
|
+
export default AlternateSection;
|
|
@@ -0,0 +1,215 @@
|
|
|
1
|
+
import e from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/debounce.js";
|
|
2
|
+
import t from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEqual.js";
|
|
3
|
+
import n from "../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/max.js";
|
|
4
|
+
import { decodeHTML as r, getAdjustedLength as i, stripHtmlTags as a } from "./markupUtils.js";
|
|
5
|
+
import o from "react";
|
|
6
|
+
import s from "prop-types";
|
|
7
|
+
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
8
|
+
import { styled as u } from "@mui/material/styles";
|
|
9
|
+
import d from "@pie-lib/editable-html-tip-tap";
|
|
10
|
+
import f from "@mui/material/Button";
|
|
11
|
+
import p from "@mui/icons-material/Delete";
|
|
12
|
+
import m from "@mui/material/IconButton";
|
|
13
|
+
import h from "@mui/material/MenuItem";
|
|
14
|
+
import g from "@mui/material/Select";
|
|
15
|
+
import _ from "@mui/material/TextField";
|
|
16
|
+
//#region src/author/alternateSection.tsx
|
|
17
|
+
var v = u("div")(({ theme: e }) => ({ marginBottom: e.spacing(.5) })), y = u("div")(({ theme: e }) => ({
|
|
18
|
+
alignItems: "flex-start",
|
|
19
|
+
flexDirection: "column",
|
|
20
|
+
display: "flex",
|
|
21
|
+
paddingTop: e.spacing(2.5),
|
|
22
|
+
"& > *": {
|
|
23
|
+
marginBottom: e.spacing(2.5),
|
|
24
|
+
width: "100%"
|
|
25
|
+
}
|
|
26
|
+
})), b = u(d)(({ theme: e, hasError: t }) => ({
|
|
27
|
+
flex: "1",
|
|
28
|
+
marginRight: e.spacing(2.5),
|
|
29
|
+
...t && {
|
|
30
|
+
border: `2px solid ${e.palette.error.main}`,
|
|
31
|
+
borderRadius: "6px"
|
|
32
|
+
}
|
|
33
|
+
})), x = u(m)(({ theme: e }) => ({ "& svg": { fill: e.palette.grey[600] } })), S = u("div")({
|
|
34
|
+
alignItems: "flex-end",
|
|
35
|
+
display: "flex",
|
|
36
|
+
justifyContent: "space-between",
|
|
37
|
+
width: "100%"
|
|
38
|
+
}), C = u("div")({
|
|
39
|
+
alignItems: "center",
|
|
40
|
+
display: "flex"
|
|
41
|
+
}), w = u(_)(({ theme: e }) => ({
|
|
42
|
+
width: "230px",
|
|
43
|
+
marginRight: e.spacing(2.5),
|
|
44
|
+
"& .MuiInput-underline:before": { borderBottomColor: e.palette.divider },
|
|
45
|
+
"& .MuiInput-underline:hover:not(.Mui-disabled):before": { borderBottomColor: e.palette.text.primary },
|
|
46
|
+
"& .MuiInput-underline:after": { borderBottomColor: e.palette.primary.main }
|
|
47
|
+
})), T = u("div")(({ theme: e }) => ({
|
|
48
|
+
fontSize: e.typography.fontSize - 2,
|
|
49
|
+
color: e.palette.error.main,
|
|
50
|
+
paddingTop: e.spacing(.5)
|
|
51
|
+
})), E = u("div")({
|
|
52
|
+
alignItems: "center",
|
|
53
|
+
display: "flex",
|
|
54
|
+
justifyContent: "space-between"
|
|
55
|
+
}), D = class extends o.Component {
|
|
56
|
+
static propTypes = {
|
|
57
|
+
error: s.string,
|
|
58
|
+
markup: s.string,
|
|
59
|
+
onChange: s.func.isRequired,
|
|
60
|
+
onDelete: s.func.isRequired,
|
|
61
|
+
value: s.string,
|
|
62
|
+
spellCheck: s.bool,
|
|
63
|
+
showMaxLength: s.bool,
|
|
64
|
+
pluginProps: s.object
|
|
65
|
+
};
|
|
66
|
+
state = { value: this.props.markup };
|
|
67
|
+
updateText = e(this.props.onChange, 300);
|
|
68
|
+
UNSAFE_componentWillReceiveProps(e) {
|
|
69
|
+
e.markup && this.setState({ value: e.markup });
|
|
70
|
+
}
|
|
71
|
+
onChange = (e) => {
|
|
72
|
+
let t = a(e);
|
|
73
|
+
this.setState({ value: t }), this.updateText(t);
|
|
74
|
+
};
|
|
75
|
+
onKeyDown = (e) => {
|
|
76
|
+
if (e.key === "Enter") return !0;
|
|
77
|
+
};
|
|
78
|
+
render() {
|
|
79
|
+
let { value: e } = this.state, { onDelete: t, spellCheck: n, error: r, showMaxLength: i, pluginProps: a } = this.props, s = i ? {} : { maxLength: 25 };
|
|
80
|
+
return /* @__PURE__ */ l(o.Fragment, { children: [/* @__PURE__ */ l(E, { children: [/* @__PURE__ */ c(b, {
|
|
81
|
+
hasError: !!r,
|
|
82
|
+
disableUnderline: !0,
|
|
83
|
+
onChange: this.onChange,
|
|
84
|
+
onKeyDown: this.onKeyDown,
|
|
85
|
+
markup: e || "",
|
|
86
|
+
activePlugins: ["languageCharacters"],
|
|
87
|
+
pluginProps: a,
|
|
88
|
+
languageCharactersProps: [{ language: "spanish" }],
|
|
89
|
+
spellCheck: n,
|
|
90
|
+
autoWidthToolbar: !0,
|
|
91
|
+
toolbarOpts: {
|
|
92
|
+
minWidth: "auto",
|
|
93
|
+
isHidden: !!a?.characters?.disabled
|
|
94
|
+
},
|
|
95
|
+
...s
|
|
96
|
+
}), /* @__PURE__ */ c(x, {
|
|
97
|
+
"aria-label": "delete",
|
|
98
|
+
onClick: t,
|
|
99
|
+
size: "large",
|
|
100
|
+
children: /* @__PURE__ */ c(p, {})
|
|
101
|
+
})] }), r && /* @__PURE__ */ c(T, { children: r })] });
|
|
102
|
+
}
|
|
103
|
+
}, O = class extends o.Component {
|
|
104
|
+
static propTypes = {
|
|
105
|
+
choices: s.array,
|
|
106
|
+
selectChoices: s.array.isRequired,
|
|
107
|
+
errors: s.object,
|
|
108
|
+
onSelect: s.func.isRequired,
|
|
109
|
+
choiceChanged: s.func.isRequired,
|
|
110
|
+
lengthChanged: s.func,
|
|
111
|
+
choiceRemoved: s.func.isRequired,
|
|
112
|
+
value: s.string,
|
|
113
|
+
maxLength: s.number,
|
|
114
|
+
showMaxLength: s.bool,
|
|
115
|
+
spellCheck: s.bool,
|
|
116
|
+
pluginProps: s.object
|
|
117
|
+
};
|
|
118
|
+
state = {};
|
|
119
|
+
UNSAFE_componentWillReceiveProps(e) {
|
|
120
|
+
this.updateChoicesIfNeeded(e);
|
|
121
|
+
}
|
|
122
|
+
componentDidMount() {
|
|
123
|
+
this.updateChoicesIfNeeded(this.props);
|
|
124
|
+
}
|
|
125
|
+
updateChoicesIfNeeded = (e) => {
|
|
126
|
+
(!this.state.choices || !t(e.choices, this.state.choices) || !t(e.choices, this.props.choices)) && this.setState({ choices: e.choices });
|
|
127
|
+
};
|
|
128
|
+
handleSelect = (e) => {
|
|
129
|
+
let { onSelect: t, selectChoices: n } = this.props, { value: r } = e.target;
|
|
130
|
+
t(n.find((e) => e.value === r));
|
|
131
|
+
};
|
|
132
|
+
onAddChoice = () => {
|
|
133
|
+
let { choices: e } = this.state;
|
|
134
|
+
if (e.length && e[e.length - 1].label !== "") {
|
|
135
|
+
let t = n(e.map((e) => parseInt(e.value)).filter((e) => !isNaN(e))) || 0;
|
|
136
|
+
this.setState({ choices: [...e, {
|
|
137
|
+
value: `${t + 1}`,
|
|
138
|
+
label: ""
|
|
139
|
+
}] });
|
|
140
|
+
}
|
|
141
|
+
};
|
|
142
|
+
onChoiceChanged = (e, t, n) => {
|
|
143
|
+
let { choiceChanged: a, lengthChanged: o, maxLength: s, choices: c } = this.props, l = c.map((e) => r(e.label || "").length);
|
|
144
|
+
l[n] = r(t).length;
|
|
145
|
+
let u = Math.max(...l);
|
|
146
|
+
a({
|
|
147
|
+
...e,
|
|
148
|
+
label: t
|
|
149
|
+
}), (u > s || u + 10 <= s) && o(i(u));
|
|
150
|
+
};
|
|
151
|
+
onRemoveChoice = (e) => {
|
|
152
|
+
let { choiceRemoved: t } = this.props;
|
|
153
|
+
t(e.value);
|
|
154
|
+
};
|
|
155
|
+
getChoicesMaxLength = () => {
|
|
156
|
+
let { choices: e } = this.state;
|
|
157
|
+
if (!e) return 1;
|
|
158
|
+
let t = e.map((e) => r(e.label || "").length);
|
|
159
|
+
return Math.max(...t);
|
|
160
|
+
};
|
|
161
|
+
changeLength = (e) => {
|
|
162
|
+
let { lengthChanged: t } = this.props, n = parseInt(e.target.value, 10), r = this.getChoicesMaxLength();
|
|
163
|
+
n && n >= r && n <= r + 10 && t(n);
|
|
164
|
+
};
|
|
165
|
+
render() {
|
|
166
|
+
let { selectChoices: e, maxLength: t, showMaxLength: n, value: i, spellCheck: a, errors: o, pluginProps: s } = this.props, { choices: u } = this.state, d = this.getChoicesMaxLength();
|
|
167
|
+
return /* @__PURE__ */ l(v, { children: [
|
|
168
|
+
/* @__PURE__ */ l(S, { children: [/* @__PURE__ */ l(g, {
|
|
169
|
+
variant: "standard",
|
|
170
|
+
displayEmpty: !0,
|
|
171
|
+
onChange: this.handleSelect,
|
|
172
|
+
value: i || "",
|
|
173
|
+
readOnly: n,
|
|
174
|
+
MenuProps: { transitionDuration: {
|
|
175
|
+
enter: 225,
|
|
176
|
+
exit: 195
|
|
177
|
+
} },
|
|
178
|
+
children: [/* @__PURE__ */ c(h, {
|
|
179
|
+
value: "",
|
|
180
|
+
children: /* @__PURE__ */ c("em", { children: i ? "Remove selection" : "Select a response" })
|
|
181
|
+
}), e.map((e, t) => /* @__PURE__ */ c(h, {
|
|
182
|
+
value: e?.value,
|
|
183
|
+
children: r(e?.label)
|
|
184
|
+
}, t))]
|
|
185
|
+
}), u && u.length > 0 && /* @__PURE__ */ l(C, { children: [t && n && /* @__PURE__ */ c(w, {
|
|
186
|
+
variant: "standard",
|
|
187
|
+
label: "Maximum length (characters)",
|
|
188
|
+
type: "number",
|
|
189
|
+
inputProps: {
|
|
190
|
+
min: d,
|
|
191
|
+
max: d + 10
|
|
192
|
+
},
|
|
193
|
+
value: t,
|
|
194
|
+
onChange: this.changeLength
|
|
195
|
+
}), /* @__PURE__ */ c(f, {
|
|
196
|
+
variant: "contained",
|
|
197
|
+
color: "primary",
|
|
198
|
+
onClick: this.onAddChoice,
|
|
199
|
+
children: "Add"
|
|
200
|
+
})] })] }),
|
|
201
|
+
o && o[0] && /* @__PURE__ */ c(T, { children: o[0] }),
|
|
202
|
+
/* @__PURE__ */ c(y, { children: u && u.map((e, t) => t > 0 && /* @__PURE__ */ c(D, {
|
|
203
|
+
markup: e.label,
|
|
204
|
+
onChange: (n) => this.onChoiceChanged(e, n, t),
|
|
205
|
+
onDelete: () => this.onRemoveChoice(e),
|
|
206
|
+
spellCheck: a,
|
|
207
|
+
error: o && o[t],
|
|
208
|
+
showMaxLength: n,
|
|
209
|
+
pluginProps: s
|
|
210
|
+
}, t)) })
|
|
211
|
+
] });
|
|
212
|
+
}
|
|
213
|
+
};
|
|
214
|
+
//#endregion
|
|
215
|
+
export { O as default };
|
|
@@ -0,0 +1,186 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @synced-from pie-elements/packages/explicit-constructed-response/configure/src/defaults.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
|
+
declare const _default: {
|
|
10
|
+
model: {
|
|
11
|
+
choices: {};
|
|
12
|
+
displayType: string;
|
|
13
|
+
markup: string;
|
|
14
|
+
maxLengthPerChoiceEnabled: boolean;
|
|
15
|
+
playerSpellCheckEnabled: boolean;
|
|
16
|
+
prompt: string;
|
|
17
|
+
promptEnabled: boolean;
|
|
18
|
+
rationale: string;
|
|
19
|
+
rationaleEnabled: boolean;
|
|
20
|
+
spellCheckEnabled: boolean;
|
|
21
|
+
studentInstructionsEnabled: boolean;
|
|
22
|
+
teacherInstructions: string;
|
|
23
|
+
teacherInstructionsEnabled: boolean;
|
|
24
|
+
toolbarEditorPosition: string;
|
|
25
|
+
responseAreaInputConfiguration: {};
|
|
26
|
+
};
|
|
27
|
+
configuration: {
|
|
28
|
+
baseInputConfiguration: {
|
|
29
|
+
h3: {
|
|
30
|
+
disabled: boolean;
|
|
31
|
+
};
|
|
32
|
+
html: {
|
|
33
|
+
disabled: boolean;
|
|
34
|
+
};
|
|
35
|
+
audio: {
|
|
36
|
+
disabled: boolean;
|
|
37
|
+
};
|
|
38
|
+
video: {
|
|
39
|
+
disabled: boolean;
|
|
40
|
+
};
|
|
41
|
+
image: {
|
|
42
|
+
disabled: boolean;
|
|
43
|
+
};
|
|
44
|
+
textAlign: {
|
|
45
|
+
disabled: boolean;
|
|
46
|
+
};
|
|
47
|
+
showParagraphs: {
|
|
48
|
+
disabled: boolean;
|
|
49
|
+
};
|
|
50
|
+
separateParagraphs: {
|
|
51
|
+
disabled: boolean;
|
|
52
|
+
};
|
|
53
|
+
};
|
|
54
|
+
prompt: {
|
|
55
|
+
settings: boolean;
|
|
56
|
+
label: string;
|
|
57
|
+
inputConfiguration: {
|
|
58
|
+
audio: {
|
|
59
|
+
disabled: boolean;
|
|
60
|
+
};
|
|
61
|
+
video: {
|
|
62
|
+
disabled: boolean;
|
|
63
|
+
};
|
|
64
|
+
image: {
|
|
65
|
+
disabled: boolean;
|
|
66
|
+
};
|
|
67
|
+
};
|
|
68
|
+
required: boolean;
|
|
69
|
+
};
|
|
70
|
+
partialScoring: {
|
|
71
|
+
settings: boolean;
|
|
72
|
+
label: string;
|
|
73
|
+
};
|
|
74
|
+
rationale: {
|
|
75
|
+
settings: boolean;
|
|
76
|
+
label: string;
|
|
77
|
+
inputConfiguration: {
|
|
78
|
+
audio: {
|
|
79
|
+
disabled: boolean;
|
|
80
|
+
};
|
|
81
|
+
video: {
|
|
82
|
+
disabled: boolean;
|
|
83
|
+
};
|
|
84
|
+
image: {
|
|
85
|
+
disabled: boolean;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
required: boolean;
|
|
89
|
+
};
|
|
90
|
+
settingsPanelDisabled: boolean;
|
|
91
|
+
spellCheck: {
|
|
92
|
+
label: string;
|
|
93
|
+
settings: boolean;
|
|
94
|
+
enabled: boolean;
|
|
95
|
+
};
|
|
96
|
+
editSource: {
|
|
97
|
+
label: string;
|
|
98
|
+
settings: boolean;
|
|
99
|
+
enabled: boolean;
|
|
100
|
+
};
|
|
101
|
+
playerSpellCheck: {
|
|
102
|
+
label: string;
|
|
103
|
+
settings: boolean;
|
|
104
|
+
enabled: boolean;
|
|
105
|
+
};
|
|
106
|
+
teacherInstructions: {
|
|
107
|
+
settings: boolean;
|
|
108
|
+
label: string;
|
|
109
|
+
inputConfiguration: {
|
|
110
|
+
audio: {
|
|
111
|
+
disabled: boolean;
|
|
112
|
+
};
|
|
113
|
+
video: {
|
|
114
|
+
disabled: boolean;
|
|
115
|
+
};
|
|
116
|
+
image: {
|
|
117
|
+
disabled: boolean;
|
|
118
|
+
};
|
|
119
|
+
};
|
|
120
|
+
required: boolean;
|
|
121
|
+
};
|
|
122
|
+
template: {
|
|
123
|
+
inputConfiguration: {
|
|
124
|
+
audio: {
|
|
125
|
+
disabled: boolean;
|
|
126
|
+
};
|
|
127
|
+
video: {
|
|
128
|
+
disabled: boolean;
|
|
129
|
+
};
|
|
130
|
+
image: {
|
|
131
|
+
disabled: boolean;
|
|
132
|
+
};
|
|
133
|
+
h3: {
|
|
134
|
+
disabled: boolean;
|
|
135
|
+
};
|
|
136
|
+
blockquote: {
|
|
137
|
+
disabled: boolean;
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
maxLengthPerChoice: {
|
|
142
|
+
settings: boolean;
|
|
143
|
+
label: string;
|
|
144
|
+
};
|
|
145
|
+
maxResponseAreas: number;
|
|
146
|
+
maxImageWidth: {
|
|
147
|
+
teacherInstructions: number;
|
|
148
|
+
prompt: number;
|
|
149
|
+
rationale: number;
|
|
150
|
+
};
|
|
151
|
+
maxImageHeight: {
|
|
152
|
+
teacherInstructions: number;
|
|
153
|
+
prompt: number;
|
|
154
|
+
rationale: number;
|
|
155
|
+
};
|
|
156
|
+
withRubric: {
|
|
157
|
+
settings: boolean;
|
|
158
|
+
label: string;
|
|
159
|
+
};
|
|
160
|
+
mathMlOptions: {
|
|
161
|
+
mmlOutput: boolean;
|
|
162
|
+
mmlEditing: boolean;
|
|
163
|
+
};
|
|
164
|
+
language: {
|
|
165
|
+
settings: boolean;
|
|
166
|
+
label: string;
|
|
167
|
+
enabled: boolean;
|
|
168
|
+
};
|
|
169
|
+
languageChoices: {
|
|
170
|
+
label: string;
|
|
171
|
+
options: never[];
|
|
172
|
+
};
|
|
173
|
+
responseAreaInputConfiguration: {
|
|
174
|
+
inputConfiguration: {
|
|
175
|
+
characters: {
|
|
176
|
+
disabled: boolean;
|
|
177
|
+
};
|
|
178
|
+
};
|
|
179
|
+
};
|
|
180
|
+
spanishButton: {
|
|
181
|
+
settings: boolean;
|
|
182
|
+
label: string;
|
|
183
|
+
};
|
|
184
|
+
};
|
|
185
|
+
};
|
|
186
|
+
export default _default;
|