@pie-element/number-line 13.1.2-next.0 → 13.1.2-next.1
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/dist/author/index.js +19 -19
- package/dist/author/main.js +152 -152
- package/dist/browser/author/index.js +7079 -7256
- package/dist/browser/author/index.js.map +1 -1
- package/dist/browser/controller/index.js +165 -419
- package/dist/browser/controller/index.js.map +1 -1
- package/dist/browser/delivery/index.js +2 -2
- package/dist/browser/{delivery-Dh8QdqpO.js → delivery-Ci_kZyOM.js} +2178 -2225
- package/dist/browser/delivery-Ci_kZyOM.js.map +1 -0
- package/dist/browser/dist-D5T-OaLo.js +19038 -0
- package/dist/browser/dist-D5T-OaLo.js.map +1 -0
- package/dist/browser/impureFunctionsAny.generated-Bqfato71.js +10162 -0
- package/dist/browser/impureFunctionsAny.generated-Bqfato71.js.map +1 -0
- package/dist/controller/index.d.ts +15 -1
- package/dist/controller/index.js +60 -65
- package/dist/controller/tickUtils.d.ts +3 -2
- package/dist/controller/tickUtils.js +64 -66
- package/dist/delivery/index.js +9 -9
- package/dist/delivery/number-line/graph/elements/line.js +56 -57
- package/dist/delivery/number-line/graph/elements/ray.js +54 -54
- package/dist/delivery/number-line/graph/index.d.ts +2 -2
- package/dist/delivery/number-line/graph/tick-utils.d.ts +16 -9
- package/dist/delivery/number-line/graph/tick-utils.js +73 -75
- package/dist/delivery/number-line/index.d.ts +1 -1
- package/dist/delivery/number-line/index.js +55 -58
- package/dist/index.iife.js +59 -63
- package/dist/runtime-support.d.ts +12 -0
- package/dist/runtime-support.js +12 -0
- package/package.json +14 -10
- package/dist/browser/_baseSet-ycZx94p7.js +0 -8672
- package/dist/browser/_baseSet-ycZx94p7.js.map +0 -1
- package/dist/browser/delivery-Dh8QdqpO.js.map +0 -1
- package/dist/browser/uniqWith-CKN50xMI.js +0 -17886
- package/dist/browser/uniqWith-CKN50xMI.js.map +0 -1
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_DataView.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Hash.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_ListCache.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Map.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_MapCache.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Promise.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Set.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_SetCache.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Stack.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Symbol.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_Uint8Array.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_WeakMap.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_apply.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayEach.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayFilter.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludes.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayIncludesWith.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayLikeKeys.js +0 -15
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayMap.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arrayPush.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_arraySome.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_assignMergeValue.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_assignValue.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_assocIndexOf.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssign.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssignIn.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseAssignValue.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseClone.js +0 -57
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseCreate.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseFindIndex.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseFor.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGet.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGetAllKeys.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseGetTag.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseHasIn.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIndexOf.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsArguments.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsEqual.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsEqualDeep.js +0 -30
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsMap.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsMatch.js +0 -26
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsNaN.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsNative.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsSet.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIsTypedArray.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseIteratee.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseKeys.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseKeysIn.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMatches.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMatchesProperty.js +0 -17
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMerge.js +0 -19
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseMergeDeep.js +0 -31
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_basePickBy.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseProperty.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_basePropertyDeep.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseRest.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseSet.js +0 -22
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseSetToString.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseTimes.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseToString.js +0 -15
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseTrim.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseUnary.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_baseUniq.js +0 -27
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cacheHas.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_castPath.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneArrayBuffer.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneBuffer.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneDataView.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneRegExp.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneSymbol.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_cloneTypedArray.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copyArray.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copyObject.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copySymbols.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_copySymbolsIn.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_coreJsData.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createAssigner.js +0 -15
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createBaseFor.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createFind.js +0 -19
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_createSet.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_defineProperty.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalArrays.js +0 -35
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalByTag.js +0 -35
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_equalObjects.js +0 -32
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_freeGlobal.js +0 -4
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getAllKeys.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getAllKeysIn.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getMapData.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getMatchData.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getNative.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getPrototype.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getRawTag.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getSymbols.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getSymbolsIn.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getTag.js +0 -23
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_getValue.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hasPath.js +0 -18
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashClear.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashDelete.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashGet.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashHas.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_hashSet.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneArray.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneByTag.js +0 -33
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_initCloneObject.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isIndex.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isIterateeCall.js +0 -12
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isKey.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isKeyable.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isMasked.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isPrototype.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_isStrictComparable.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheClear.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheDelete.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheGet.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheHas.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_listCacheSet.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheClear.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheDelete.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheGet.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheHas.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapCacheSet.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_mapToArray.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_matchesStrictComparable.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_memoizeCapped.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeCreate.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeKeys.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nativeKeysIn.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_nodeUtil.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_objectToString.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_overArg.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_overRest.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_root.js +0 -5
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_safeGet.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setCacheAdd.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setCacheHas.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setToArray.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_setToString.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_shortOut.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackClear.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackDelete.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackGet.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackHas.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stackSet.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_strictIndexOf.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_stringToPath.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_toKey.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_toSource.js +0 -15
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/_trimmedEndIndex.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/cloneDeep.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/constant.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/eq.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/find.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/findIndex.js +0 -13
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/get.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/hasIn.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/identity.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArguments.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArray.js +0 -4
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArrayLike.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isArrayLikeObject.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isBuffer.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEmpty.js +0 -21
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEqual.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isEqualWith.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isFunction.js +0 -11
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isLength.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isMap.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isNumber.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isObject.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isObjectLike.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isPlainObject.js +0 -14
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isSet.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isSymbol.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/isTypedArray.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/keys.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/keysIn.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/memoize.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/merge.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/negate.js +0 -17
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/noop.js +0 -4
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/omitBy.js +0 -9
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/pickBy.js +0 -16
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/property.js +0 -10
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/stubArray.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/stubFalse.js +0 -6
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toFinite.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toInteger.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toNumber.js +0 -19
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toPlainObject.js +0 -8
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/toString.js +0 -7
- package/dist/node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/uniqWith.js +0 -7
|
@@ -1,15 +1,14 @@
|
|
|
1
|
-
import e from "
|
|
2
|
-
import t from "
|
|
3
|
-
import {
|
|
4
|
-
import r from "
|
|
5
|
-
import {
|
|
6
|
-
import a from "
|
|
7
|
-
import {
|
|
8
|
-
import
|
|
9
|
-
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
1
|
+
import { Draggable as e } from "../../../draggable/index.js";
|
|
2
|
+
import t from "./point.js";
|
|
3
|
+
import { basePropTypes as n } from "./base.js";
|
|
4
|
+
import r from "react";
|
|
5
|
+
import { styled as i } from "@mui/material/styles";
|
|
6
|
+
import a from "prop-types";
|
|
7
|
+
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
8
|
+
import { isEqual as c, isNumber as l } from "@pie-element/shared-lodash";
|
|
10
9
|
import { color as u } from "@pie-lib/render-ui";
|
|
11
10
|
//#region src/delivery/number-line/graph/elements/line.tsx
|
|
12
|
-
var d = "150ms", f =
|
|
11
|
+
var d = "150ms", f = i("g")(({ $disabled: e, $selected: t, $correct: n }) => ({
|
|
13
12
|
"& .line-handle": {
|
|
14
13
|
stroke: u.primary(),
|
|
15
14
|
cursor: "pointer",
|
|
@@ -38,25 +37,25 @@ var d = "150ms", f = o("g")(({ $disabled: e, $selected: t, $correct: n }) => ({
|
|
|
38
37
|
cursor: "inherit",
|
|
39
38
|
stroke: u.incorrect()
|
|
40
39
|
} }
|
|
41
|
-
})), p = class extends
|
|
40
|
+
})), p = class extends r.Component {
|
|
42
41
|
static propTypes = {
|
|
43
|
-
...
|
|
44
|
-
empty:
|
|
45
|
-
left:
|
|
46
|
-
right:
|
|
42
|
+
...n(),
|
|
43
|
+
empty: a.shape({
|
|
44
|
+
left: a.bool.isRequired,
|
|
45
|
+
right: a.bool.isRequired
|
|
47
46
|
}).isRequired,
|
|
48
|
-
position:
|
|
49
|
-
left:
|
|
50
|
-
right:
|
|
47
|
+
position: a.shape({
|
|
48
|
+
left: a.number.isRequired,
|
|
49
|
+
right: a.number.isRequired
|
|
51
50
|
}).isRequired,
|
|
52
|
-
y:
|
|
53
|
-
selected:
|
|
54
|
-
disabled:
|
|
55
|
-
correct:
|
|
56
|
-
onMoveLine:
|
|
57
|
-
onToggleSelect:
|
|
58
|
-
onDragStart:
|
|
59
|
-
onDragStop:
|
|
51
|
+
y: a.number,
|
|
52
|
+
selected: a.bool,
|
|
53
|
+
disabled: a.bool,
|
|
54
|
+
correct: a.bool,
|
|
55
|
+
onMoveLine: a.func.isRequired,
|
|
56
|
+
onToggleSelect: a.func.isRequired,
|
|
57
|
+
onDragStart: a.func,
|
|
58
|
+
onDragStop: a.func
|
|
60
59
|
};
|
|
61
60
|
static defaultProps = {
|
|
62
61
|
selected: !1,
|
|
@@ -65,8 +64,8 @@ var d = "150ms", f = o("g")(({ $disabled: e, $selected: t, $correct: n }) => ({
|
|
|
65
64
|
correct: void 0
|
|
66
65
|
};
|
|
67
66
|
static contextTypes = {
|
|
68
|
-
xScale:
|
|
69
|
-
snapValue:
|
|
67
|
+
xScale: a.func.isRequired,
|
|
68
|
+
snapValue: a.func.isRequired
|
|
70
69
|
};
|
|
71
70
|
constructor(e) {
|
|
72
71
|
super(e), this.state = {
|
|
@@ -98,48 +97,48 @@ var d = "150ms", f = o("g")(({ $disabled: e, $selected: t, $correct: n }) => ({
|
|
|
98
97
|
r[e] = t, this.props.onMoveLine(r);
|
|
99
98
|
}
|
|
100
99
|
render() {
|
|
101
|
-
let { interval:
|
|
100
|
+
let { interval: n, empty: r, position: i, domain: a, y: u, selected: d, disabled: p, correct: m } = this.props, { xScale: h } = this.context, { onDrag: g, onMove: _ } = this, v = _.bind(this, "left"), y = _.bind(this, "right"), b = g.bind(this, "left"), x = g.bind(this, "right"), S = l(this.state.left) ? this.state.left : i.left, C = l(this.state.right) ? this.state.right : i.right, w = h(n) - h(0), T = (e) => e.nativeEvent.preventDefault(), E = () => {
|
|
102
101
|
this.props.onToggleSelect();
|
|
103
102
|
}, D = () => {
|
|
104
103
|
this.props.onToggleSelect();
|
|
105
|
-
}, O = (
|
|
106
|
-
if (Math.abs(
|
|
104
|
+
}, O = (e) => {
|
|
105
|
+
if (Math.abs(e) < w / 10) {
|
|
107
106
|
this.props.onToggleSelect();
|
|
108
107
|
return;
|
|
109
108
|
}
|
|
110
|
-
let
|
|
111
|
-
left:
|
|
112
|
-
right:
|
|
109
|
+
let t = h.invert(e + h(0)), n = {
|
|
110
|
+
left: i.left + t,
|
|
111
|
+
right: i.right + t
|
|
113
112
|
};
|
|
114
|
-
|
|
113
|
+
c(n, this.props.position) || this.props.onMoveLine(n);
|
|
115
114
|
}, k = {
|
|
116
|
-
left: (
|
|
117
|
-
right: (
|
|
115
|
+
left: (a.min - i.left) / n * w,
|
|
116
|
+
right: (a.max - i.right) / n * w
|
|
118
117
|
}, A = {
|
|
119
|
-
interval:
|
|
118
|
+
interval: n,
|
|
120
119
|
selected: d,
|
|
121
120
|
disabled: p,
|
|
122
121
|
correct: m
|
|
123
122
|
};
|
|
124
|
-
return /* @__PURE__ */
|
|
125
|
-
id: `line-${
|
|
123
|
+
return /* @__PURE__ */ o(e, {
|
|
124
|
+
id: `line-${i.left}-${i.right}-${u}`,
|
|
126
125
|
disabled: p,
|
|
127
126
|
grid: [w],
|
|
128
127
|
bounds: k,
|
|
129
128
|
onMouseDown: T,
|
|
130
129
|
onDragEnd: O,
|
|
131
|
-
children: ({ setNodeRef: e, attributes:
|
|
130
|
+
children: ({ setNodeRef: e, attributes: n, listeners: c, translateX: l, isDragging: g, onMouseDown: _ }) => /* @__PURE__ */ o(f, {
|
|
132
131
|
ref: e,
|
|
133
132
|
$disabled: p,
|
|
134
133
|
$selected: d,
|
|
135
134
|
$correct: m,
|
|
136
135
|
className: g ? "dnd-kit-dragging" : void 0,
|
|
137
136
|
onMouseDown: _,
|
|
138
|
-
...
|
|
139
|
-
children: /* @__PURE__ */
|
|
140
|
-
transform: `translate(${
|
|
137
|
+
...n,
|
|
138
|
+
children: /* @__PURE__ */ s("g", {
|
|
139
|
+
transform: `translate(${l}, ${u})`,
|
|
141
140
|
children: [
|
|
142
|
-
/* @__PURE__ */
|
|
141
|
+
/* @__PURE__ */ o("rect", {
|
|
143
142
|
x: h(S),
|
|
144
143
|
width: Math.abs(h(C) - h(S)),
|
|
145
144
|
fill: "red",
|
|
@@ -148,33 +147,33 @@ var d = "150ms", f = o("g")(({ $disabled: e, $selected: t, $correct: n }) => ({
|
|
|
148
147
|
height: 16,
|
|
149
148
|
onClick: D
|
|
150
149
|
}),
|
|
151
|
-
/* @__PURE__ */
|
|
150
|
+
/* @__PURE__ */ o("line", {
|
|
152
151
|
className: "line-handle",
|
|
153
152
|
x1: h(S),
|
|
154
153
|
x2: h(C),
|
|
155
154
|
onClick: E,
|
|
156
|
-
...
|
|
155
|
+
...c
|
|
157
156
|
}),
|
|
158
|
-
/* @__PURE__ */
|
|
157
|
+
/* @__PURE__ */ o(t, {
|
|
159
158
|
...A,
|
|
160
|
-
empty:
|
|
159
|
+
empty: r.left,
|
|
161
160
|
bounds: {
|
|
162
|
-
left:
|
|
163
|
-
right:
|
|
161
|
+
left: a.min - i.left,
|
|
162
|
+
right: a.max - i.left
|
|
164
163
|
},
|
|
165
|
-
position:
|
|
164
|
+
position: i.left,
|
|
166
165
|
onDrag: b,
|
|
167
166
|
onMove: v,
|
|
168
167
|
onClick: D
|
|
169
168
|
}),
|
|
170
|
-
/* @__PURE__ */
|
|
169
|
+
/* @__PURE__ */ o(t, {
|
|
171
170
|
...A,
|
|
172
|
-
empty:
|
|
171
|
+
empty: r.right,
|
|
173
172
|
bounds: {
|
|
174
|
-
left:
|
|
175
|
-
right:
|
|
173
|
+
left: a.min - i.right,
|
|
174
|
+
right: a.max - i.right
|
|
176
175
|
},
|
|
177
|
-
position:
|
|
176
|
+
position: i.right,
|
|
178
177
|
onDrag: x,
|
|
179
178
|
onMove: y,
|
|
180
179
|
onClick: D
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import e from "
|
|
2
|
-
import t from "./
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import o from "
|
|
6
|
-
import s from "
|
|
7
|
-
import
|
|
8
|
-
import l from "
|
|
9
|
-
import {
|
|
1
|
+
import e from "./point.js";
|
|
2
|
+
import { basePropTypes as t } from "./base.js";
|
|
3
|
+
import { correct as n, incorrect as r, selected as i } from "../../colors.js";
|
|
4
|
+
import a from "../arrow.js";
|
|
5
|
+
import o from "react";
|
|
6
|
+
import { styled as s } from "@mui/material/styles";
|
|
7
|
+
import c from "prop-types";
|
|
8
|
+
import { jsx as l, jsxs as u } from "react/jsx-runtime";
|
|
9
|
+
import { isNumber as d } from "@pie-element/shared-lodash";
|
|
10
10
|
import { color as f } from "@pie-lib/render-ui";
|
|
11
11
|
//#region src/delivery/number-line/graph/elements/ray.tsx
|
|
12
|
-
var p =
|
|
12
|
+
var p = s("g")(({ $selected: e, $correct: t }) => ({
|
|
13
13
|
"& line": {
|
|
14
14
|
cursor: "pointer",
|
|
15
15
|
strokeWidth: "5px",
|
|
@@ -17,55 +17,55 @@ var p = c("g")(({ $selected: e, $correct: t }) => ({
|
|
|
17
17
|
},
|
|
18
18
|
"& line, & .arrow": { transition: "stroke 150ms linear, fill 150ms linear" },
|
|
19
19
|
...e && {
|
|
20
|
-
"& line": { stroke:
|
|
20
|
+
"& line": { stroke: i },
|
|
21
21
|
"& .arrow": {
|
|
22
|
-
fill:
|
|
22
|
+
fill: i,
|
|
23
23
|
strokeWidth: "1px",
|
|
24
|
-
stroke:
|
|
24
|
+
stroke: i
|
|
25
25
|
}
|
|
26
26
|
},
|
|
27
27
|
...t === !0 && {
|
|
28
|
-
"& line": { stroke:
|
|
28
|
+
"& line": { stroke: n },
|
|
29
29
|
"& .arrow": {
|
|
30
|
-
fill:
|
|
30
|
+
fill: n,
|
|
31
31
|
strokeWidth: "1px",
|
|
32
|
-
stroke:
|
|
32
|
+
stroke: n
|
|
33
33
|
}
|
|
34
34
|
},
|
|
35
35
|
...t === !1 && {
|
|
36
|
-
"& line": { stroke:
|
|
36
|
+
"& line": { stroke: r },
|
|
37
37
|
"& .arrow": {
|
|
38
|
-
fill:
|
|
38
|
+
fill: r,
|
|
39
39
|
strokeWidth: "1px",
|
|
40
|
-
stroke:
|
|
40
|
+
stroke: r
|
|
41
41
|
}
|
|
42
42
|
}
|
|
43
|
-
})), m =
|
|
43
|
+
})), m = s(a)(({ $correct: e, $selected: t }) => ({
|
|
44
44
|
fill: f.primary(),
|
|
45
45
|
...e === !0 && {
|
|
46
|
+
fill: n,
|
|
47
|
+
"--arrow-color": n
|
|
48
|
+
},
|
|
49
|
+
...e === !1 && {
|
|
46
50
|
fill: r,
|
|
47
51
|
"--arrow-color": r
|
|
48
52
|
},
|
|
49
|
-
...
|
|
53
|
+
...t && {
|
|
50
54
|
fill: i,
|
|
51
55
|
"--arrow-color": i
|
|
52
|
-
},
|
|
53
|
-
...t && {
|
|
54
|
-
fill: a,
|
|
55
|
-
"--arrow-color": a
|
|
56
56
|
}
|
|
57
|
-
})), h = class extends
|
|
57
|
+
})), h = class extends o.Component {
|
|
58
58
|
static propTypes = {
|
|
59
|
-
...
|
|
60
|
-
width:
|
|
61
|
-
selected:
|
|
62
|
-
disabled:
|
|
63
|
-
empty:
|
|
64
|
-
direction:
|
|
65
|
-
y:
|
|
66
|
-
position:
|
|
67
|
-
onMove:
|
|
68
|
-
onToggleSelect:
|
|
59
|
+
...t(),
|
|
60
|
+
width: c.number.isRequired,
|
|
61
|
+
selected: c.bool,
|
|
62
|
+
disabled: c.bool,
|
|
63
|
+
empty: c.bool,
|
|
64
|
+
direction: c.oneOf(["positive", "negative"]),
|
|
65
|
+
y: c.number,
|
|
66
|
+
position: c.number.isRequired,
|
|
67
|
+
onMove: c.func.isRequired,
|
|
68
|
+
onToggleSelect: c.func.isRequired
|
|
69
69
|
};
|
|
70
70
|
static defaultProps = {
|
|
71
71
|
selected: !1,
|
|
@@ -74,8 +74,8 @@ var p = c("g")(({ $selected: e, $correct: t }) => ({
|
|
|
74
74
|
disabled: !1
|
|
75
75
|
};
|
|
76
76
|
static contextTypes = {
|
|
77
|
-
xScale:
|
|
78
|
-
snapValue:
|
|
77
|
+
xScale: c.func.isRequired,
|
|
78
|
+
snapValue: c.func.isRequired
|
|
79
79
|
};
|
|
80
80
|
constructor(e) {
|
|
81
81
|
super(e), this.state = { dragPosition: null };
|
|
@@ -88,38 +88,38 @@ var p = c("g")(({ $selected: e, $correct: t }) => ({
|
|
|
88
88
|
this.setState({ dragPosition: null });
|
|
89
89
|
}
|
|
90
90
|
render() {
|
|
91
|
-
let { interval:
|
|
92
|
-
return /* @__PURE__ */
|
|
93
|
-
$selected:
|
|
91
|
+
let { interval: t, empty: n, position: r, direction: i, domain: a, y: o, selected: s, disabled: c, width: f, correct: h } = this.props, { xScale: g } = this.context, _ = this.drag.bind(this), v = this.stopDrag.bind(this), y = d(this.state.dragPosition) ? this.state.dragPosition : r, b = i === "positive", x = b ? y : a.min, S = b ? a.max : y, C = b ? g(x) : 8, w = b ? f - 8 : g(S), T = b ? f : 0, E = b ? "right" : "left";
|
|
92
|
+
return /* @__PURE__ */ u(p, {
|
|
93
|
+
$selected: s,
|
|
94
94
|
$correct: h,
|
|
95
|
-
transform: `translate(0, ${
|
|
95
|
+
transform: `translate(0, ${o})`,
|
|
96
96
|
children: [
|
|
97
|
-
/* @__PURE__ */
|
|
98
|
-
onClick:
|
|
97
|
+
/* @__PURE__ */ l("line", {
|
|
98
|
+
onClick: c ? () => {} : this.props.onToggleSelect,
|
|
99
99
|
className: "line-handle",
|
|
100
100
|
x1: C,
|
|
101
101
|
x2: w
|
|
102
102
|
}),
|
|
103
|
-
/* @__PURE__ */
|
|
104
|
-
disabled:
|
|
103
|
+
/* @__PURE__ */ l(e, {
|
|
104
|
+
disabled: c,
|
|
105
105
|
correct: h,
|
|
106
|
-
selected:
|
|
107
|
-
empty:
|
|
108
|
-
interval:
|
|
106
|
+
selected: s,
|
|
107
|
+
empty: n,
|
|
108
|
+
interval: t,
|
|
109
109
|
bounds: {
|
|
110
|
-
left:
|
|
111
|
-
right:
|
|
110
|
+
left: a.min - r,
|
|
111
|
+
right: a.max - r
|
|
112
112
|
},
|
|
113
|
-
position:
|
|
113
|
+
position: r,
|
|
114
114
|
onDrag: _,
|
|
115
115
|
onDragStop: v,
|
|
116
116
|
onMove: this.props.onMove,
|
|
117
117
|
onClick: this.props.onToggleSelect
|
|
118
118
|
}),
|
|
119
|
-
/* @__PURE__ */
|
|
119
|
+
/* @__PURE__ */ l(m, {
|
|
120
120
|
x: T,
|
|
121
121
|
$correct: h,
|
|
122
|
-
$selected:
|
|
122
|
+
$selected: s,
|
|
123
123
|
direction: E
|
|
124
124
|
})
|
|
125
125
|
]
|
|
@@ -42,10 +42,10 @@ export declare class NumberLineGraph extends React.Component {
|
|
|
42
42
|
};
|
|
43
43
|
constructor(props: any);
|
|
44
44
|
xScaleFn(): any;
|
|
45
|
-
snapValueFn(): (value: any) =>
|
|
45
|
+
snapValueFn(): (value: any) => number;
|
|
46
46
|
getChildContext(): {
|
|
47
47
|
xScale: any;
|
|
48
|
-
snapValue: (value: any) =>
|
|
48
|
+
snapValue: (value: any) => number;
|
|
49
49
|
};
|
|
50
50
|
/**
|
|
51
51
|
* Note: we use d3 click + pointer to give us domain values directly.
|
|
@@ -6,6 +6,7 @@
|
|
|
6
6
|
* Manual edits will be overwritten on next sync.
|
|
7
7
|
* To make changes, edit the upstream JavaScript file and run sync again.
|
|
8
8
|
*/
|
|
9
|
+
import * as math from 'mathjs';
|
|
9
10
|
export declare const decimalTickValues: number[];
|
|
10
11
|
export declare const fractionTickValues: string[];
|
|
11
12
|
export declare const labelMultiplier: {
|
|
@@ -38,27 +39,30 @@ export declare const zeroBasedRange: (start: any, end: any, interval: any) => an
|
|
|
38
39
|
* such that it was hard to round the numbers.
|
|
39
40
|
* This is a more simplistic version but makes rounding work.
|
|
40
41
|
*/
|
|
41
|
-
export declare const simpleRange: (start: any, end: any, interval: any) =>
|
|
42
|
+
export declare const simpleRange: (start: any, end: any, interval: any) => (string | math.MathType)[];
|
|
42
43
|
export declare const closeTo: (a: any, b: any, precision: any) => boolean;
|
|
43
44
|
export declare const getMinorLimits: (domain: any, width: any) => {
|
|
44
|
-
min:
|
|
45
|
-
max:
|
|
45
|
+
min: number & (number | math.MathCollection<math.MathNumericType>);
|
|
46
|
+
max: number;
|
|
46
47
|
};
|
|
47
|
-
export declare const isMultiple: (multiple: any, src: any) =>
|
|
48
|
+
export declare const isMultiple: (multiple: any, src: any) => boolean | math.MathCollection<math.MathNumericType>;
|
|
48
49
|
/**
|
|
49
50
|
* Accepts a fraction object {n,d,s} or number.
|
|
50
51
|
* @param {*} v
|
|
51
52
|
* @return mathjs.fraction
|
|
52
53
|
*/
|
|
53
|
-
export declare const fraction: (v: any) =>
|
|
54
|
+
export declare const fraction: (v: any) => math.Fraction | undefined;
|
|
54
55
|
export declare const normalizeTicks: (domain: any, width: any, ticks: any, opts: any) => {
|
|
55
|
-
minor: any;
|
|
56
56
|
major: any;
|
|
57
|
+
minor: any;
|
|
57
58
|
};
|
|
58
59
|
/**
|
|
59
60
|
* Build ticks as an array of mathjs Fractions
|
|
60
61
|
*/
|
|
61
|
-
export declare const buildTickDataAsFractions: (domain: any, width: any, ticks: any, opts: any) =>
|
|
62
|
+
export declare const buildTickDataAsFractions: (domain: any, width: any, ticks: any, opts: any) => {
|
|
63
|
+
x: string | math.MathType;
|
|
64
|
+
type: string;
|
|
65
|
+
}[];
|
|
62
66
|
export declare const generateMinorValues: (minorLimits: any) => {
|
|
63
67
|
fraction: never[];
|
|
64
68
|
decimal: never[];
|
|
@@ -67,7 +71,10 @@ export declare const generateMajorValuesForMinor: (minor: any, domain: any, widt
|
|
|
67
71
|
decimal: never[];
|
|
68
72
|
fraction: never[];
|
|
69
73
|
};
|
|
70
|
-
export declare const buildTickData: (domain: any, width: any, ticks: any, opts: any) =>
|
|
74
|
+
export declare const buildTickData: (domain: any, width: any, ticks: any, opts: any) => {
|
|
75
|
+
x: string | math.MathType;
|
|
76
|
+
type: string;
|
|
77
|
+
}[];
|
|
71
78
|
export declare const fractionSnapTo: (min: any, max: any, interval: any, value: any) => any;
|
|
72
|
-
export declare const snapTo: (min: any, max: any, interval: any, value: any) =>
|
|
79
|
+
export declare const snapTo: (min: any, max: any, interval: any, value: any) => number;
|
|
73
80
|
export declare const snapElements: (domain: any, ticks: any, elements: any) => any;
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import { __exportAll as e } from "../../../_virtual/_rolldown/runtime.js";
|
|
2
|
-
import t from "
|
|
3
|
-
import n from "
|
|
4
|
-
import r from "../../../node_modules/.bun/lodash-es@4.18.1/node_modules/lodash-es/uniqWith.js";
|
|
5
|
-
import * as i from "mathjs";
|
|
2
|
+
import * as t from "mathjs";
|
|
3
|
+
import { isNumber as n, isObject as r, uniqWith as i } from "@pie-element/shared-lodash";
|
|
6
4
|
//#region src/delivery/number-line/graph/tick-utils.ts
|
|
7
5
|
var a = /* @__PURE__ */ e({
|
|
8
6
|
buildTickData: () => w,
|
|
@@ -176,116 +174,116 @@ var a = /* @__PURE__ */ e({
|
|
|
176
174
|
8,
|
|
177
175
|
10
|
|
178
176
|
]
|
|
179
|
-
}, l = (e,
|
|
180
|
-
let
|
|
181
|
-
if (!
|
|
182
|
-
if (
|
|
183
|
-
let a =
|
|
184
|
-
if (o === "negative" &&
|
|
185
|
-
if (o === "positive" &&
|
|
177
|
+
}, l = (e, n, r) => {
|
|
178
|
+
let i = t.mod(t.abs(e), t.abs(r));
|
|
179
|
+
if (!t.equal(i, 0)) throw Error("start point must be divisible by interval");
|
|
180
|
+
if (t.equal(e, n)) return [];
|
|
181
|
+
let a = t.subtract(n, t.mod(n, t.abs(r))), o = t.larger(r, 0) ? "positive" : "negative";
|
|
182
|
+
if (o === "negative" && t.largerEq(n, e)) throw Error("start must be > than end when doing a negative decrement");
|
|
183
|
+
if (o === "positive" && t.smallerEq(n, e)) throw Error("start must be < end when doing increments");
|
|
186
184
|
let s;
|
|
187
|
-
s = o === "positive" ?
|
|
185
|
+
s = o === "positive" ? t.smallerEq : t.equal(a, n) ? t.largerEq : t.larger;
|
|
188
186
|
let c = [], l = e;
|
|
189
|
-
for (; s(l, a);) c.push(l), l =
|
|
187
|
+
for (; s(l, a);) c.push(l), l = t.add(l, r);
|
|
190
188
|
return c;
|
|
191
|
-
}, u = (e, t) => `Can only do a positive or negative range, but got: start: ${e} and end:${t}`, d = (e,
|
|
192
|
-
e =
|
|
193
|
-
let
|
|
194
|
-
if (
|
|
189
|
+
}, u = (e, t) => `Can only do a positive or negative range, but got: start: ${e} and end:${t}`, d = (e, n, r) => {
|
|
190
|
+
e = t.fraction(e), n = t.fraction(n), r = t.fraction(r);
|
|
191
|
+
let i = t.abs(t.subtract(n, e));
|
|
192
|
+
if (t.larger(i, t.abs(n))) throw Error(u(e, n));
|
|
195
193
|
let a = {
|
|
196
|
-
start:
|
|
197
|
-
end:
|
|
198
|
-
interval:
|
|
199
|
-
multiplier:
|
|
200
|
-
}, o =
|
|
201
|
-
return
|
|
202
|
-
}, f = (e,
|
|
203
|
-
e =
|
|
204
|
-
let a =
|
|
205
|
-
return
|
|
194
|
+
start: t.abs(e),
|
|
195
|
+
end: t.abs(n),
|
|
196
|
+
interval: t.abs(r),
|
|
197
|
+
multiplier: t.smaller(r, 0) ? -1 : 1
|
|
198
|
+
}, o = t.mod(a.start, a.interval), s = l(t.larger(o, 0) ? t.add(t.subtract(a.start, o), a.interval) : a.start, a.end, a.interval), c = a.multiplier === -1 ? s.map((e) => t.multiply(e, -1)) : s;
|
|
199
|
+
return t.smaller(r, 0) && c.reverse(), c;
|
|
200
|
+
}, f = (e, n) => (e = t.fraction(e), n = t.fraction(n), t.smaller(e, n) ? e : n), p = (e, n) => (e = t.fraction(e), n = t.fraction(n), t.larger(e, n) ? e : n), m = (e, n, r) => {
|
|
201
|
+
e = t.fraction(e), n = t.fraction(n), r = t.fraction(r);
|
|
202
|
+
let a = t.larger(n, 0) ? d(p(0, e), n, r) : [];
|
|
203
|
+
return i((t.smaller(e, 0) ? d(f(0, n), e, t.multiply(r, -1)) : []).concat(a), t.equal);
|
|
206
204
|
}, h = (e, t, n) => {
|
|
207
205
|
n ||= 2;
|
|
208
206
|
let r = 10 ** -n / 2;
|
|
209
207
|
return Math.abs(e - t) < r;
|
|
210
|
-
}, g = (e,
|
|
211
|
-
let
|
|
208
|
+
}, g = (e, n, r) => t.smaller(y(e), y(n)) ? n : t.larger(y(e), y(r)) ? r : e, _ = (e, n) => {
|
|
209
|
+
let r = e.max - e.min, i = t.number(t.multiply(10, t.divide(t.fraction(r), n)));
|
|
212
210
|
return {
|
|
213
|
-
min:
|
|
214
|
-
max:
|
|
211
|
+
min: i,
|
|
212
|
+
max: t.number(t.multiply(20, i))
|
|
215
213
|
};
|
|
216
|
-
}, v = (e,
|
|
217
|
-
let
|
|
218
|
-
return
|
|
214
|
+
}, v = (e, n) => {
|
|
215
|
+
let r = t.mod(e, n);
|
|
216
|
+
return t.equal(r, 0);
|
|
219
217
|
}, y = (e) => {
|
|
220
|
-
if (
|
|
221
|
-
if (n(e)) return
|
|
222
|
-
}, b = (e,
|
|
223
|
-
let a =
|
|
218
|
+
if (r(e)) return t.fraction(e.n * e.s, e.d);
|
|
219
|
+
if (n(e)) return t.fraction(e);
|
|
220
|
+
}, b = (e, n, r, i) => {
|
|
221
|
+
let a = i ? i.limit !== !1 : !0, o = _(e, n), s = a ? g(y(r.minor), o.min, o.max) : y(r.minor), c = a ? g(y(r.major), s, t.multiply(s, 20)) : y(r.major);
|
|
224
222
|
if (!v(c, s)) {
|
|
225
|
-
let e =
|
|
223
|
+
let e = t.divide(c, s), n = e <= 2 ? 2 : Math.round(e);
|
|
226
224
|
return {
|
|
227
225
|
minor: s,
|
|
228
|
-
major:
|
|
226
|
+
major: t.multiply(s, n)
|
|
229
227
|
};
|
|
230
228
|
}
|
|
231
229
|
return {
|
|
232
230
|
major: c,
|
|
233
231
|
minor: s
|
|
234
232
|
};
|
|
235
|
-
}, x = (e,
|
|
236
|
-
let
|
|
237
|
-
return h(
|
|
233
|
+
}, x = (e, n, r, i) => (r = b(e, n, r, i), m(e.min, e.max, r.minor).filter((n) => t.smallerEq(n, t.fraction(e.max))).map((e) => {
|
|
234
|
+
let n = "minor", i = t.mod(e, r.major);
|
|
235
|
+
return h(t.number(i), 0) && (n = "major"), {
|
|
238
236
|
x: e,
|
|
239
|
-
type:
|
|
237
|
+
type: n
|
|
240
238
|
};
|
|
241
239
|
})), S = (e) => {
|
|
242
|
-
let
|
|
240
|
+
let n = {
|
|
243
241
|
fraction: [],
|
|
244
242
|
decimal: []
|
|
245
243
|
};
|
|
246
|
-
return o.forEach((
|
|
247
|
-
|
|
248
|
-
}), s.forEach((
|
|
249
|
-
let
|
|
250
|
-
|
|
251
|
-
}),
|
|
252
|
-
}, C = (e,
|
|
253
|
-
let
|
|
244
|
+
return o.forEach((t) => {
|
|
245
|
+
t >= e.min && t <= e.max && n.decimal.push(t);
|
|
246
|
+
}), s.forEach((r) => {
|
|
247
|
+
let i = t.number(t.fraction(r));
|
|
248
|
+
i >= e.min && i <= e.max && n.fraction.push(r);
|
|
249
|
+
}), n;
|
|
250
|
+
}, C = (e, n, r) => {
|
|
251
|
+
let i = {
|
|
254
252
|
decimal: [],
|
|
255
253
|
fraction: []
|
|
256
|
-
}, a =
|
|
254
|
+
}, a = t.fraction(t.number(t.number(e))), o = a.n, s = a.d;
|
|
257
255
|
if (o >= 1 && s === 1) for (let a = 1; a <= 10; a++) {
|
|
258
|
-
let s =
|
|
259
|
-
w(
|
|
256
|
+
let s = t.number(t.multiply(o, a));
|
|
257
|
+
w(n, r, {
|
|
260
258
|
minor: e,
|
|
261
259
|
major: s
|
|
262
|
-
}, { fraction: void 0 }).filter((e) => e.type === "major").length > 1 && (
|
|
260
|
+
}, { fraction: void 0 }).filter((e) => e.type === "major").length > 1 && (i.fraction.push(s.toString()), i.decimal.push(s));
|
|
263
261
|
}
|
|
264
262
|
else for (let a in c[s]) {
|
|
265
|
-
let l =
|
|
266
|
-
w(
|
|
263
|
+
let l = t.multiply(t.fraction(o, s), c[s][a]);
|
|
264
|
+
w(n, r, {
|
|
267
265
|
minor: e,
|
|
268
|
-
major:
|
|
269
|
-
}, { fraction: void 0 }).filter((e) => e.type === "major").length > 1 && (l.d === 1 ?
|
|
266
|
+
major: t.number(l)
|
|
267
|
+
}, { fraction: void 0 }).filter((e) => e.type === "major").length > 1 && (l.d === 1 ? i.fraction.push(l.n.toString()) : i.fraction.push(l.n + "/" + l.d), i.decimal.push(t.number(l)));
|
|
270
268
|
}
|
|
271
|
-
return
|
|
272
|
-
}, w = (e,
|
|
269
|
+
return i;
|
|
270
|
+
}, w = (e, n, r, i) => x(e, n, r, i).map((e) => i.fraction ? e : {
|
|
273
271
|
...e,
|
|
274
|
-
x:
|
|
275
|
-
}), T = (e,
|
|
276
|
-
|
|
277
|
-
let a =
|
|
278
|
-
if (
|
|
279
|
-
let e =
|
|
280
|
-
o =
|
|
272
|
+
x: t.number(e.x) || 0
|
|
273
|
+
}), T = (e, n, r, i) => {
|
|
274
|
+
i = p(f(i, n), e);
|
|
275
|
+
let a = i.mod(r), o, s = r.div(2);
|
|
276
|
+
if (t.largerEq(t.abs(a), s)) {
|
|
277
|
+
let e = r.sub(t.abs(a)), n = t.largerEq(i, 0) ? "add" : "sub";
|
|
278
|
+
o = i[n](e);
|
|
281
279
|
} else {
|
|
282
|
-
let e =
|
|
283
|
-
o =
|
|
280
|
+
let e = t.largerEq(i, 0) ? "sub" : "add";
|
|
281
|
+
o = i[e](t.abs(a));
|
|
284
282
|
}
|
|
285
283
|
return o;
|
|
286
|
-
}, E = (e,
|
|
287
|
-
let a = T(
|
|
288
|
-
return
|
|
284
|
+
}, E = (e, n, r, i) => {
|
|
285
|
+
let a = T(t.fraction(e), t.fraction(n), t.fraction(r), t.fraction(i));
|
|
286
|
+
return t.number(a);
|
|
289
287
|
}, D = (e, t, n) => n.map((n) => {
|
|
290
288
|
let r = Number.isFinite(n.size) ? E(0, n.size, t.minor, n.size) : void 0, i = E(e.min, e.max, t.minor, n.domainPosition), a = {
|
|
291
289
|
...n,
|
|
@@ -24,7 +24,7 @@ export declare class NumberLine extends React.Component {
|
|
|
24
24
|
toggleElement(index: any): void;
|
|
25
25
|
elementTypeSelected(t: any): void;
|
|
26
26
|
addElement(x: any): void;
|
|
27
|
-
hasMaxNoOfPoints():
|
|
27
|
+
hasMaxNoOfPoints(): boolean;
|
|
28
28
|
UNSAFE_componentWillReceiveProps(nextProps: any): void;
|
|
29
29
|
deselectElements(): void;
|
|
30
30
|
getSize(type: any, min: any, max: any, defaultValue: any): any;
|