@unicom-cloud/utils 0.1.48 → 0.1.50
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/.virtual/_rolldown/runtime.js +1 -1
- package/.vite/manifest.json +192 -24
- package/array/index.js +1 -1
- package/assert/index.js +1 -1
- package/case-name/index.js +1 -1
- package/class-name/index.js +1 -1
- package/clipboard-copy/index.js +1 -1
- package/constant/address.js +1 -1
- package/constant/chineseCharacters.js +1 -1
- package/constant/constellations.js +1 -1
- package/constant/domain.js +1 -1
- package/constant/identity.js +1 -1
- package/constant/index.js +1 -1
- package/constant/keyboardCode.js +1 -1
- package/constant/licensePlate.js +1 -1
- package/constant/name.js +1 -1
- package/constant/platform.js +1 -1
- package/constant/protocol.js +1 -1
- package/constant/string.js +1 -1
- package/constant/ui.js +1 -1
- package/content-disposition/index.js +1 -1
- package/cookie/api.js +1 -1
- package/cookie/assign.js +1 -1
- package/cookie/converter.js +1 -1
- package/cookie/index.js +1 -1
- package/css/cssSupported.js +1 -1
- package/css/index.js +1 -1
- package/date/convertTime.js +1 -1
- package/date/convertToDuration.js +1 -1
- package/date/index.js +1 -1
- package/decimal/decimal.js +1 -1
- package/decimal/index.js +1 -1
- package/dom-align/LICENSE.md +9 -0
- package/dom-align/adjustForViewport.d.ts +2 -0
- package/dom-align/adjustForViewport.js +13 -0
- package/dom-align/align/align.d.ts +15 -0
- package/dom-align/align/align.js +88 -0
- package/dom-align/align/alignElement.d.ts +16 -0
- package/dom-align/align/alignElement.js +18 -0
- package/dom-align/align/alignPoint.d.ts +14 -0
- package/dom-align/align/alignPoint.js +21 -0
- package/dom-align/getAlignOffset.d.ts +8 -0
- package/dom-align/getAlignOffset.js +12 -0
- package/dom-align/getElFuturePos.d.ts +5 -0
- package/dom-align/getElFuturePos.js +13 -0
- package/dom-align/getOffsetParent.d.ts +2 -0
- package/dom-align/getOffsetParent.js +14 -0
- package/dom-align/getRegion.d.ts +5 -0
- package/dom-align/getRegion.js +18 -0
- package/dom-align/getVisibleRectForElement.d.ts +10 -0
- package/dom-align/getVisibleRectForElement.js +34 -0
- package/dom-align/index.d.ts +4 -0
- package/dom-align/index.js +8 -0
- package/dom-align/isAncestorFixed.d.ts +1 -0
- package/dom-align/isAncestorFixed.js +13 -0
- package/dom-align/propertyUtils.d.ts +8 -0
- package/dom-align/propertyUtils.js +57 -0
- package/dom-align/utils.d.ts +28 -0
- package/dom-align/utils.js +220 -0
- package/dom-helpers/activeElement.js +1 -1
- package/dom-helpers/addClass.js +1 -1
- package/dom-helpers/addEventListener.js +1 -1
- package/dom-helpers/animate.js +1 -1
- package/dom-helpers/animationFrame.js +1 -1
- package/dom-helpers/attribute.js +1 -1
- package/dom-helpers/camelize.js +1 -1
- package/dom-helpers/camelizeStyle.js +1 -1
- package/dom-helpers/canUseDOM.js +1 -1
- package/dom-helpers/childElements.js +1 -1
- package/dom-helpers/childNodes.js +1 -1
- package/dom-helpers/clear.js +1 -1
- package/dom-helpers/closest.js +1 -1
- package/dom-helpers/collectElements.js +1 -1
- package/dom-helpers/collectSiblings.js +1 -1
- package/dom-helpers/contains.js +1 -1
- package/dom-helpers/css.js +1 -1
- package/dom-helpers/filterEventHandler.js +1 -1
- package/dom-helpers/getComputedStyle.js +1 -1
- package/dom-helpers/getElementCoordinates.js +1 -1
- package/dom-helpers/getScrollAccessor.js +1 -1
- package/dom-helpers/hasClass.js +1 -1
- package/dom-helpers/height.js +1 -1
- package/dom-helpers/hyphenate.js +1 -1
- package/dom-helpers/hyphenateStyle.js +1 -1
- package/dom-helpers/index.js +1 -1
- package/dom-helpers/insertAfter.js +1 -1
- package/dom-helpers/isDocument.js +1 -1
- package/dom-helpers/isInput.js +1 -1
- package/dom-helpers/isTransform.js +1 -1
- package/dom-helpers/isVisible.js +1 -1
- package/dom-helpers/isWindow.js +1 -1
- package/dom-helpers/listen.js +1 -1
- package/dom-helpers/matches.js +1 -1
- package/dom-helpers/nextUntil.js +1 -1
- package/dom-helpers/offset.js +1 -1
- package/dom-helpers/offsetParent.js +1 -1
- package/dom-helpers/ownerDocument.js +1 -1
- package/dom-helpers/ownerWindow.js +1 -1
- package/dom-helpers/parents.js +1 -1
- package/dom-helpers/position.js +1 -1
- package/dom-helpers/prepend.js +1 -1
- package/dom-helpers/querySelectorAll.js +1 -1
- package/dom-helpers/reflow.js +1 -1
- package/dom-helpers/remove.js +1 -1
- package/dom-helpers/removeClass.js +1 -1
- package/dom-helpers/removeEventListener.js +1 -1
- package/dom-helpers/scrollLeft.js +1 -1
- package/dom-helpers/scrollParent.js +1 -1
- package/dom-helpers/scrollTo.js +1 -1
- package/dom-helpers/scrollTop.js +1 -1
- package/dom-helpers/scrollbarSize.js +1 -1
- package/dom-helpers/siblings.js +1 -1
- package/dom-helpers/text.js +1 -1
- package/dom-helpers/toggleClass.js +1 -1
- package/dom-helpers/transitionEnd.js +1 -1
- package/dom-helpers/triggerEvent.js +1 -1
- package/dom-helpers/types.js +1 -1
- package/dom-helpers/width.js +1 -1
- package/emitter/index.js +1 -1
- package/emoji/emoji.js +1 -1
- package/emoji/emojis.js +1 -1
- package/emoji/index.js +1 -1
- package/escape/index.js +1 -1
- package/fflate/index.js +1 -1
- package/fflate/src/index.js +6 -6
- package/fflate/src/worker.js +1 -1
- package/file/fileRead.js +1 -1
- package/file/fileToDataURL.js +1 -1
- package/file/img.js +1 -1
- package/file/index.js +1 -1
- package/file/saveAs.js +1 -1
- package/filesize/index.js +1 -1
- package/filesize/src/constants.js +1 -1
- package/filesize/src/filesize.js +1 -1
- package/filesize/src/helpers.js +1 -1
- package/function/index.js +1 -1
- package/idb/async-iterators.js +1 -1
- package/idb/database-extras.js +1 -1
- package/idb/entry.js +1 -1
- package/idb/index-.js +1 -1
- package/idb/index.js +1 -1
- package/idb/util.js +1 -1
- package/idb/wrap-idb-value.js +1 -1
- package/index.js +1 -1
- package/invariant/index.js +1 -1
- package/is/index.d.ts +5 -2
- package/is/index.js +11 -2
- package/is/lib/isAscii.js +1 -1
- package/is/lib/isBase64.js +1 -1
- package/is/lib/isChinese.js +1 -1
- package/is/lib/isDataURI.js +1 -1
- package/is/lib/isEmail.js +1 -1
- package/is/lib/isFQDN.js +1 -1
- package/is/lib/isFullWidth.js +1 -1
- package/is/lib/isHSL.js +1 -1
- package/is/lib/isHalfWidth.js +1 -1
- package/is/lib/isHash.js +1 -1
- package/is/lib/isHexColor.js +1 -1
- package/is/lib/isIMEI.js +1 -1
- package/is/lib/isIP.js +1 -1
- package/is/lib/isIPRange.js +1 -1
- package/is/lib/isIdentityCard.js +1 -1
- package/is/lib/isJWT.js +1 -1
- package/is/lib/isMACAddress.js +1 -1
- package/is/lib/isMD5.js +1 -1
- package/is/lib/isMimeType.js +1 -1
- package/is/lib/isMobilePhone.js +1 -1
- package/is/lib/isPort.js +1 -1
- package/is/lib/isRgbColor.js +1 -1
- package/is/lib/isSemVer.js +1 -1
- package/is/lib/isSlug.js +1 -1
- package/is/lib/isStrongPassword.js +1 -1
- package/is/lib/isURL.js +1 -1
- package/is/lib/isUUID.js +1 -1
- package/is/lib/isVariableWidth.js +1 -1
- package/lodash/_DataView.js +1 -1
- package/lodash/_Hash.js +1 -1
- package/lodash/_LazyWrapper.js +1 -1
- package/lodash/_ListCache.js +1 -1
- package/lodash/_LodashWrapper.js +1 -1
- package/lodash/_Map.js +1 -1
- package/lodash/_MapCache.js +1 -1
- package/lodash/_Promise.js +1 -1
- package/lodash/_Set.js +1 -1
- package/lodash/_SetCache.js +1 -1
- package/lodash/_Stack.js +1 -1
- package/lodash/_Symbol.js +1 -1
- package/lodash/_Uint8Array.js +1 -1
- package/lodash/_WeakMap.js +1 -1
- package/lodash/_addMapEntry.js +1 -1
- package/lodash/_addSetEntry.js +1 -1
- package/lodash/_apply.js +1 -1
- package/lodash/_arrayAggregator.js +1 -1
- package/lodash/_arrayEach.js +1 -1
- package/lodash/_arrayEachRight.js +1 -1
- package/lodash/_arrayEvery.js +1 -1
- package/lodash/_arrayFilter.js +1 -1
- package/lodash/_arrayIncludes.js +1 -1
- package/lodash/_arrayIncludesWith.js +1 -1
- package/lodash/_arrayLikeKeys.js +1 -1
- package/lodash/_arrayMap.js +1 -1
- package/lodash/_arrayPush.js +1 -1
- package/lodash/_arrayReduce.js +1 -1
- package/lodash/_arrayReduceRight.js +1 -1
- package/lodash/_arraySample.js +1 -1
- package/lodash/_arraySampleSize.js +1 -1
- package/lodash/_arrayShuffle.js +1 -1
- package/lodash/_arraySome.js +1 -1
- package/lodash/_asciiSize.js +1 -1
- package/lodash/_asciiToArray.js +1 -1
- package/lodash/_asciiWords.js +1 -1
- package/lodash/_assignMergeValue.js +1 -1
- package/lodash/_assignValue.js +1 -1
- package/lodash/_assocIndexOf.js +1 -1
- package/lodash/_baseAggregator.js +1 -1
- package/lodash/_baseAssign.js +1 -1
- package/lodash/_baseAssignIn.js +1 -1
- package/lodash/_baseAssignValue.js +1 -1
- package/lodash/_baseAt.js +1 -1
- package/lodash/_baseClamp.js +1 -1
- package/lodash/_baseClone.js +1 -1
- package/lodash/_baseConforms.js +1 -1
- package/lodash/_baseConformsTo.js +1 -1
- package/lodash/_baseCreate.js +1 -1
- package/lodash/_baseDelay.js +1 -1
- package/lodash/_baseDifference.js +1 -1
- package/lodash/_baseEach.js +1 -1
- package/lodash/_baseEachRight.js +1 -1
- package/lodash/_baseEvery.js +1 -1
- package/lodash/_baseExtremum.js +1 -1
- package/lodash/_baseFill.js +1 -1
- package/lodash/_baseFilter.js +1 -1
- package/lodash/_baseFindIndex.js +1 -1
- package/lodash/_baseFindKey.js +1 -1
- package/lodash/_baseFlatten.js +1 -1
- package/lodash/_baseFor.js +1 -1
- package/lodash/_baseForOwn.js +1 -1
- package/lodash/_baseForOwnRight.js +1 -1
- package/lodash/_baseForRight.js +1 -1
- package/lodash/_baseFunctions.js +1 -1
- package/lodash/_baseGet.js +1 -1
- package/lodash/_baseGetAllKeys.js +1 -1
- package/lodash/_baseGetTag.js +1 -1
- package/lodash/_baseGt.js +1 -1
- package/lodash/_baseHas.js +1 -1
- package/lodash/_baseHasIn.js +1 -1
- package/lodash/_baseInRange.js +1 -1
- package/lodash/_baseIndexOf.js +1 -1
- package/lodash/_baseIndexOfWith.js +1 -1
- package/lodash/_baseIntersection.js +1 -1
- package/lodash/_baseInverter.js +1 -1
- package/lodash/_baseInvoke.js +1 -1
- package/lodash/_baseIsArguments.js +1 -1
- package/lodash/_baseIsArrayBuffer.js +1 -1
- package/lodash/_baseIsDate.js +1 -1
- package/lodash/_baseIsEqual.js +1 -1
- package/lodash/_baseIsEqualDeep.js +1 -1
- package/lodash/_baseIsMap.js +1 -1
- package/lodash/_baseIsMatch.js +1 -1
- package/lodash/_baseIsNaN.js +1 -1
- package/lodash/_baseIsNative.js +1 -1
- package/lodash/_baseIsRegExp.js +1 -1
- package/lodash/_baseIsSet.js +1 -1
- package/lodash/_baseIsTypedArray.js +1 -1
- package/lodash/_baseIteratee.js +1 -1
- package/lodash/_baseKeys.js +1 -1
- package/lodash/_baseKeysIn.js +1 -1
- package/lodash/_baseLodash.js +1 -1
- package/lodash/_baseLt.js +1 -1
- package/lodash/_baseMap.js +1 -1
- package/lodash/_baseMatches.js +1 -1
- package/lodash/_baseMatchesProperty.js +1 -1
- package/lodash/_baseMean.js +1 -1
- package/lodash/_baseMerge.js +1 -1
- package/lodash/_baseMergeDeep.js +1 -1
- package/lodash/_baseNth.js +1 -1
- package/lodash/_baseOrderBy.js +1 -1
- package/lodash/_basePick.js +1 -1
- package/lodash/_basePickBy.js +1 -1
- package/lodash/_baseProperty.js +1 -1
- package/lodash/_basePropertyDeep.js +1 -1
- package/lodash/_basePropertyOf.js +1 -1
- package/lodash/_basePullAll.js +1 -1
- package/lodash/_basePullAt.js +1 -1
- package/lodash/_baseRandom.js +1 -1
- package/lodash/_baseRange.js +1 -1
- package/lodash/_baseReduce.js +1 -1
- package/lodash/_baseRepeat.js +1 -1
- package/lodash/_baseRest.js +1 -1
- package/lodash/_baseSample.js +1 -1
- package/lodash/_baseSampleSize.js +1 -1
- package/lodash/_baseSet.js +1 -1
- package/lodash/_baseSetData.js +1 -1
- package/lodash/_baseSetToString.js +1 -1
- package/lodash/_baseShuffle.js +1 -1
- package/lodash/_baseSlice.js +1 -1
- package/lodash/_baseSome.js +1 -1
- package/lodash/_baseSortBy.js +1 -1
- package/lodash/_baseSortedIndex.js +1 -1
- package/lodash/_baseSortedIndexBy.js +1 -1
- package/lodash/_baseSortedUniq.js +1 -1
- package/lodash/_baseSum.js +1 -1
- package/lodash/_baseTimes.js +1 -1
- package/lodash/_baseToNumber.js +1 -1
- package/lodash/_baseToPairs.js +1 -1
- package/lodash/_baseToString.js +1 -1
- package/lodash/_baseTrim.js +1 -1
- package/lodash/_baseUnary.js +1 -1
- package/lodash/_baseUniq.js +1 -1
- package/lodash/_baseUnset.js +1 -1
- package/lodash/_baseUpdate.js +1 -1
- package/lodash/_baseValues.js +1 -1
- package/lodash/_baseWhile.js +1 -1
- package/lodash/_baseWrapperValue.js +1 -1
- package/lodash/_baseXor.js +1 -1
- package/lodash/_baseZipObject.js +1 -1
- package/lodash/_cacheHas.js +1 -1
- package/lodash/_castArrayLikeObject.js +1 -1
- package/lodash/_castFunction.js +1 -1
- package/lodash/_castPath.js +1 -1
- package/lodash/_castRest.js +1 -1
- package/lodash/_castSlice.js +1 -1
- package/lodash/_charsEndIndex.js +1 -1
- package/lodash/_charsStartIndex.js +1 -1
- package/lodash/_cloneArrayBuffer.js +1 -1
- package/lodash/_cloneBuffer.js +1 -1
- package/lodash/_cloneDataView.js +1 -1
- package/lodash/_cloneMap.js +1 -1
- package/lodash/_cloneRegExp.js +1 -1
- package/lodash/_cloneSet.js +1 -1
- package/lodash/_cloneSymbol.js +1 -1
- package/lodash/_cloneTypedArray.js +1 -1
- package/lodash/_compareAscending.js +1 -1
- package/lodash/_compareMultiple.js +1 -1
- package/lodash/_composeArgs.js +1 -1
- package/lodash/_composeArgsRight.js +1 -1
- package/lodash/_copyArray.js +1 -1
- package/lodash/_copyObject.js +1 -1
- package/lodash/_copySymbols.js +1 -1
- package/lodash/_copySymbolsIn.js +1 -1
- package/lodash/_coreJsData.js +1 -1
- package/lodash/_countHolders.js +1 -1
- package/lodash/_createAggregator.js +1 -1
- package/lodash/_createAssigner.js +1 -1
- package/lodash/_createBaseEach.js +1 -1
- package/lodash/_createBaseFor.js +1 -1
- package/lodash/_createBind.js +1 -1
- package/lodash/_createCaseFirst.js +1 -1
- package/lodash/_createCompounder.js +1 -1
- package/lodash/_createCtor.js +1 -1
- package/lodash/_createCurry.js +1 -1
- package/lodash/_createFind.js +1 -1
- package/lodash/_createFlow.js +1 -1
- package/lodash/_createHybrid.js +1 -1
- package/lodash/_createInverter.js +1 -1
- package/lodash/_createMathOperation.js +1 -1
- package/lodash/_createOver.js +1 -1
- package/lodash/_createPadding.js +1 -1
- package/lodash/_createPartial.js +1 -1
- package/lodash/_createRange.js +1 -1
- package/lodash/_createRecurry.js +1 -1
- package/lodash/_createRelationalOperation.js +1 -1
- package/lodash/_createRound.js +1 -1
- package/lodash/_createSet.js +1 -1
- package/lodash/_createToPairs.js +1 -1
- package/lodash/_createWrap.js +1 -1
- package/lodash/_customDefaultsAssignIn.js +1 -1
- package/lodash/_customDefaultsMerge.js +1 -1
- package/lodash/_customOmitClone.js +1 -1
- package/lodash/_deburrLetter.js +1 -1
- package/lodash/_defineProperty.js +1 -1
- package/lodash/_equalArrays.js +1 -1
- package/lodash/_equalByTag.js +1 -1
- package/lodash/_equalObjects.js +1 -1
- package/lodash/_escapeHtmlChar.js +1 -1
- package/lodash/_escapeStringChar.js +1 -1
- package/lodash/_flatRest.js +1 -1
- package/lodash/_freeGlobal.js +1 -1
- package/lodash/_getAllKeys.js +1 -1
- package/lodash/_getAllKeysIn.js +1 -1
- package/lodash/_getData.js +1 -1
- package/lodash/_getFuncName.js +1 -1
- package/lodash/_getHolder.js +1 -1
- package/lodash/_getMapData.js +1 -1
- package/lodash/_getMatchData.js +1 -1
- package/lodash/_getNative.js +1 -1
- package/lodash/_getPrototype.js +1 -1
- package/lodash/_getRawTag.js +1 -1
- package/lodash/_getSymbols.js +1 -1
- package/lodash/_getSymbolsIn.js +1 -1
- package/lodash/_getTag.js +1 -1
- package/lodash/_getValue.js +1 -1
- package/lodash/_getView.js +1 -1
- package/lodash/_getWrapDetails.js +1 -1
- package/lodash/_hasPath.js +1 -1
- package/lodash/_hasUnicode.js +1 -1
- package/lodash/_hasUnicodeWord.js +1 -1
- package/lodash/_hashClear.js +1 -1
- package/lodash/_hashDelete.js +1 -1
- package/lodash/_hashGet.js +1 -1
- package/lodash/_hashHas.js +1 -1
- package/lodash/_hashSet.js +1 -1
- package/lodash/_initCloneArray.js +1 -1
- package/lodash/_initCloneByTag.js +1 -1
- package/lodash/_initCloneObject.js +1 -1
- package/lodash/_insertWrapDetails.js +1 -1
- package/lodash/_isFlattenable.js +1 -1
- package/lodash/_isIndex.js +1 -1
- package/lodash/_isIterateeCall.js +1 -1
- package/lodash/_isKey.js +1 -1
- package/lodash/_isKeyable.js +1 -1
- package/lodash/_isLaziable.js +1 -1
- package/lodash/_isMaskable.js +1 -1
- package/lodash/_isMasked.js +1 -1
- package/lodash/_isPrototype.js +1 -1
- package/lodash/_isStrictComparable.js +1 -1
- package/lodash/_iteratorToArray.js +1 -1
- package/lodash/_lazyClone.js +1 -1
- package/lodash/_lazyReverse.js +1 -1
- package/lodash/_lazyValue.js +1 -1
- package/lodash/_listCacheClear.js +1 -1
- package/lodash/_listCacheDelete.js +1 -1
- package/lodash/_listCacheGet.js +1 -1
- package/lodash/_listCacheHas.js +1 -1
- package/lodash/_listCacheSet.js +1 -1
- package/lodash/_mapCacheClear.js +1 -1
- package/lodash/_mapCacheDelete.js +1 -1
- package/lodash/_mapCacheGet.js +1 -1
- package/lodash/_mapCacheHas.js +1 -1
- package/lodash/_mapCacheSet.js +1 -1
- package/lodash/_mapToArray.js +1 -1
- package/lodash/_matchesStrictComparable.js +1 -1
- package/lodash/_memoizeCapped.js +1 -1
- package/lodash/_mergeData.js +1 -1
- package/lodash/_metaMap.js +1 -1
- package/lodash/_nativeCreate.js +1 -1
- package/lodash/_nativeKeys.js +1 -1
- package/lodash/_nativeKeysIn.js +1 -1
- package/lodash/_nodeUtil.js +1 -1
- package/lodash/_objectToString.js +1 -1
- package/lodash/_overArg.js +1 -1
- package/lodash/_overRest.js +1 -1
- package/lodash/_parent.js +1 -1
- package/lodash/_reEscape.js +1 -1
- package/lodash/_reEvaluate.js +1 -1
- package/lodash/_reInterpolate.js +1 -1
- package/lodash/_realNames.js +1 -1
- package/lodash/_reorder.js +1 -1
- package/lodash/_replaceHolders.js +1 -1
- package/lodash/_root.js +1 -1
- package/lodash/_safeGet.js +1 -1
- package/lodash/_setCacheAdd.js +1 -1
- package/lodash/_setCacheHas.js +1 -1
- package/lodash/_setData.js +1 -1
- package/lodash/_setToArray.js +1 -1
- package/lodash/_setToPairs.js +1 -1
- package/lodash/_setToString.js +1 -1
- package/lodash/_setWrapToString.js +1 -1
- package/lodash/_shortOut.js +1 -1
- package/lodash/_shuffleSelf.js +1 -1
- package/lodash/_stackClear.js +1 -1
- package/lodash/_stackDelete.js +1 -1
- package/lodash/_stackGet.js +1 -1
- package/lodash/_stackHas.js +1 -1
- package/lodash/_stackSet.js +1 -1
- package/lodash/_strictIndexOf.js +1 -1
- package/lodash/_strictLastIndexOf.js +1 -1
- package/lodash/_stringSize.js +1 -1
- package/lodash/_stringToArray.js +1 -1
- package/lodash/_stringToPath.js +1 -1
- package/lodash/_toKey.js +1 -1
- package/lodash/_toSource.js +1 -1
- package/lodash/_trimmedEndIndex.js +1 -1
- package/lodash/_unescapeHtmlChar.js +1 -1
- package/lodash/_unicodeSize.js +1 -1
- package/lodash/_unicodeToArray.js +1 -1
- package/lodash/_unicodeWords.js +1 -1
- package/lodash/_updateWrapDetails.js +1 -1
- package/lodash/_wrapperClone.js +1 -1
- package/lodash/add.js +1 -1
- package/lodash/after.js +1 -1
- package/lodash/array.default.js +1 -1
- package/lodash/array.js +1 -1
- package/lodash/ary.js +1 -1
- package/lodash/assign.js +1 -1
- package/lodash/assignIn.js +1 -1
- package/lodash/assignInWith.js +1 -1
- package/lodash/assignWith.js +1 -1
- package/lodash/at.js +1 -1
- package/lodash/attempt.js +1 -1
- package/lodash/before.js +1 -1
- package/lodash/bind.js +1 -1
- package/lodash/bindAll.js +1 -1
- package/lodash/bindKey.js +1 -1
- package/lodash/camelCase.js +1 -1
- package/lodash/capitalize.js +1 -1
- package/lodash/castArray.js +1 -1
- package/lodash/ceil.js +1 -1
- package/lodash/chain.js +1 -1
- package/lodash/chunk.js +1 -1
- package/lodash/clamp.js +1 -1
- package/lodash/clone.js +1 -1
- package/lodash/cloneDeep.js +1 -1
- package/lodash/cloneDeepWith.js +1 -1
- package/lodash/cloneWith.js +1 -1
- package/lodash/collection.default.js +1 -1
- package/lodash/collection.js +1 -1
- package/lodash/commit.js +1 -1
- package/lodash/compact.js +1 -1
- package/lodash/concat.js +1 -1
- package/lodash/cond.js +1 -1
- package/lodash/conforms.js +1 -1
- package/lodash/conformsTo.js +1 -1
- package/lodash/constant.js +1 -1
- package/lodash/countBy.js +1 -1
- package/lodash/create.js +1 -1
- package/lodash/curry.js +1 -1
- package/lodash/curryRight.js +1 -1
- package/lodash/date.default.js +1 -1
- package/lodash/date.js +1 -1
- package/lodash/debounce.js +1 -1
- package/lodash/deburr.js +1 -1
- package/lodash/defaultTo.js +1 -1
- package/lodash/defaults.js +1 -1
- package/lodash/defaultsDeep.js +1 -1
- package/lodash/defer.js +1 -1
- package/lodash/delay.js +1 -1
- package/lodash/difference.js +1 -1
- package/lodash/differenceBy.js +1 -1
- package/lodash/differenceWith.js +1 -1
- package/lodash/divide.js +1 -1
- package/lodash/drop.js +1 -1
- package/lodash/dropRight.js +1 -1
- package/lodash/dropRightWhile.js +1 -1
- package/lodash/dropWhile.js +1 -1
- package/lodash/each.js +1 -1
- package/lodash/eachRight.js +1 -1
- package/lodash/endsWith.js +1 -1
- package/lodash/entries.js +1 -1
- package/lodash/entriesIn.js +1 -1
- package/lodash/eq.js +1 -1
- package/lodash/escape.js +1 -1
- package/lodash/escapeRegExp.js +1 -1
- package/lodash/every.js +1 -1
- package/lodash/extend.js +1 -1
- package/lodash/extendWith.js +1 -1
- package/lodash/fill.js +1 -1
- package/lodash/filter.js +1 -1
- package/lodash/find.js +1 -1
- package/lodash/findIndex.js +1 -1
- package/lodash/findKey.js +1 -1
- package/lodash/findLast.js +1 -1
- package/lodash/findLastIndex.js +1 -1
- package/lodash/findLastKey.js +1 -1
- package/lodash/first.js +1 -1
- package/lodash/flatMap.js +1 -1
- package/lodash/flatMapDeep.js +1 -1
- package/lodash/flatMapDepth.js +1 -1
- package/lodash/flatten.js +1 -1
- package/lodash/flattenDeep.js +1 -1
- package/lodash/flattenDepth.js +1 -1
- package/lodash/flip.js +1 -1
- package/lodash/floor.js +1 -1
- package/lodash/flow.js +1 -1
- package/lodash/flowRight.js +1 -1
- package/lodash/forEach.js +1 -1
- package/lodash/forEachRight.js +1 -1
- package/lodash/forIn.js +1 -1
- package/lodash/forInRight.js +1 -1
- package/lodash/forOwn.js +1 -1
- package/lodash/forOwnRight.js +1 -1
- package/lodash/fromPairs.js +1 -1
- package/lodash/function.default.js +1 -1
- package/lodash/function.js +1 -1
- package/lodash/functions.js +1 -1
- package/lodash/functionsIn.js +1 -1
- package/lodash/get.js +1 -1
- package/lodash/groupBy.js +1 -1
- package/lodash/gt.js +1 -1
- package/lodash/gte.js +1 -1
- package/lodash/has.js +1 -1
- package/lodash/hasIn.js +1 -1
- package/lodash/head.js +1 -1
- package/lodash/identity.js +1 -1
- package/lodash/inRange.js +1 -1
- package/lodash/includes.js +1 -1
- package/lodash/index.js +1 -1
- package/lodash/indexOf.js +1 -1
- package/lodash/initial.js +1 -1
- package/lodash/intersection.js +1 -1
- package/lodash/intersectionBy.js +1 -1
- package/lodash/intersectionWith.js +1 -1
- package/lodash/invert.js +1 -1
- package/lodash/invertBy.js +1 -1
- package/lodash/invoke.js +1 -1
- package/lodash/invokeMap.js +1 -1
- package/lodash/isArguments.js +1 -1
- package/lodash/isArray.js +1 -1
- package/lodash/isArrayBuffer.js +1 -1
- package/lodash/isArrayLike.js +1 -1
- package/lodash/isArrayLikeObject.js +1 -1
- package/lodash/isBoolean.js +1 -1
- package/lodash/isBuffer.js +1 -1
- package/lodash/isDate.js +1 -1
- package/lodash/isElement.js +1 -1
- package/lodash/isEmpty.js +1 -1
- package/lodash/isEqual.js +1 -1
- package/lodash/isEqualWith.js +1 -1
- package/lodash/isError.js +1 -1
- package/lodash/isFinite.js +1 -1
- package/lodash/isFunction.js +1 -1
- package/lodash/isInteger.js +1 -1
- package/lodash/isLength.js +1 -1
- package/lodash/isMap.js +1 -1
- package/lodash/isMatch.js +1 -1
- package/lodash/isMatchWith.js +1 -1
- package/lodash/isNaN.js +1 -1
- package/lodash/isNative.js +1 -1
- package/lodash/isNil.js +1 -1
- package/lodash/isNull.js +1 -1
- package/lodash/isNumber.js +1 -1
- package/lodash/isObject.js +1 -1
- package/lodash/isObjectLike.js +1 -1
- package/lodash/isPlainObject.js +1 -1
- package/lodash/isPromise.js +1 -1
- package/lodash/isRegExp.js +1 -1
- package/lodash/isSafeInteger.js +1 -1
- package/lodash/isSet.js +1 -1
- package/lodash/isString.js +1 -1
- package/lodash/isSymbol.js +1 -1
- package/lodash/isTypedArray.js +1 -1
- package/lodash/isUndefined.js +1 -1
- package/lodash/isWeakMap.js +1 -1
- package/lodash/isWeakSet.js +1 -1
- package/lodash/iteratee.js +1 -1
- package/lodash/join.js +1 -1
- package/lodash/kebabCase.js +1 -1
- package/lodash/keyBy.js +1 -1
- package/lodash/keys.js +1 -1
- package/lodash/keysIn.js +1 -1
- package/lodash/lang.default.js +1 -1
- package/lodash/lang.js +1 -1
- package/lodash/last.js +1 -1
- package/lodash/lastIndexOf.js +1 -1
- package/lodash/lodash.default.js +1 -1
- package/lodash/lodash.js +1 -1
- package/lodash/lowerCase.js +1 -1
- package/lodash/lowerFirst.js +1 -1
- package/lodash/lt.js +1 -1
- package/lodash/lte.js +1 -1
- package/lodash/map.js +1 -1
- package/lodash/mapKeys.js +1 -1
- package/lodash/mapValues.js +1 -1
- package/lodash/matches.js +1 -1
- package/lodash/matchesProperty.js +1 -1
- package/lodash/math.default.js +1 -1
- package/lodash/math.js +1 -1
- package/lodash/max.js +1 -1
- package/lodash/maxBy.js +1 -1
- package/lodash/mean.js +1 -1
- package/lodash/meanBy.js +1 -1
- package/lodash/memoize.js +1 -1
- package/lodash/merge.js +1 -1
- package/lodash/mergeWith.js +1 -1
- package/lodash/method.js +1 -1
- package/lodash/methodOf.js +1 -1
- package/lodash/min.js +1 -1
- package/lodash/minBy.js +1 -1
- package/lodash/mixin.js +1 -1
- package/lodash/multiply.js +1 -1
- package/lodash/negate.js +1 -1
- package/lodash/next.js +1 -1
- package/lodash/noop.js +1 -1
- package/lodash/now.js +1 -1
- package/lodash/nth.js +1 -1
- package/lodash/nthArg.js +1 -1
- package/lodash/number.default.js +1 -1
- package/lodash/number.js +1 -1
- package/lodash/object.default.js +1 -1
- package/lodash/object.js +1 -1
- package/lodash/omit.js +1 -1
- package/lodash/omitBy.js +1 -1
- package/lodash/once.js +1 -1
- package/lodash/orderBy.js +1 -1
- package/lodash/over.js +1 -1
- package/lodash/overArgs.js +1 -1
- package/lodash/overEvery.js +1 -1
- package/lodash/overSome.js +1 -1
- package/lodash/pad.js +1 -1
- package/lodash/padEnd.js +1 -1
- package/lodash/padStart.js +1 -1
- package/lodash/parseInt.js +1 -1
- package/lodash/partial.js +1 -1
- package/lodash/partialRight.js +1 -1
- package/lodash/partition.js +1 -1
- package/lodash/pick.js +1 -1
- package/lodash/pickBy.js +1 -1
- package/lodash/plant.js +1 -1
- package/lodash/property.js +1 -1
- package/lodash/propertyOf.js +1 -1
- package/lodash/pull.js +1 -1
- package/lodash/pullAll.js +1 -1
- package/lodash/pullAllBy.js +1 -1
- package/lodash/pullAllWith.js +1 -1
- package/lodash/pullAt.js +1 -1
- package/lodash/random.js +1 -1
- package/lodash/range.js +1 -1
- package/lodash/rangeRight.js +1 -1
- package/lodash/rearg.js +1 -1
- package/lodash/reduce.js +1 -1
- package/lodash/reduceRight.js +1 -1
- package/lodash/reject.js +1 -1
- package/lodash/remove.js +1 -1
- package/lodash/repeat.js +1 -1
- package/lodash/replace.js +1 -1
- package/lodash/rest.js +1 -1
- package/lodash/result.js +1 -1
- package/lodash/reverse.js +1 -1
- package/lodash/round.js +1 -1
- package/lodash/sample.js +1 -1
- package/lodash/sampleSize.js +1 -1
- package/lodash/seq.default.js +1 -1
- package/lodash/seq.js +1 -1
- package/lodash/set.js +1 -1
- package/lodash/setWith.js +1 -1
- package/lodash/shuffle.js +1 -1
- package/lodash/size.js +1 -1
- package/lodash/slice.js +1 -1
- package/lodash/snakeCase.js +1 -1
- package/lodash/some.js +1 -1
- package/lodash/sortBy.js +1 -1
- package/lodash/sortedIndex.js +1 -1
- package/lodash/sortedIndexBy.js +1 -1
- package/lodash/sortedIndexOf.js +1 -1
- package/lodash/sortedLastIndex.js +1 -1
- package/lodash/sortedLastIndexBy.js +1 -1
- package/lodash/sortedLastIndexOf.js +1 -1
- package/lodash/sortedUniq.js +1 -1
- package/lodash/sortedUniqBy.js +1 -1
- package/lodash/split.js +1 -1
- package/lodash/spread.js +1 -1
- package/lodash/startCase.js +1 -1
- package/lodash/startsWith.js +1 -1
- package/lodash/string.default.js +1 -1
- package/lodash/string.js +1 -1
- package/lodash/stubArray.js +1 -1
- package/lodash/stubFalse.js +1 -1
- package/lodash/stubObject.js +1 -1
- package/lodash/stubString.js +1 -1
- package/lodash/stubTrue.js +1 -1
- package/lodash/subtract.js +1 -1
- package/lodash/sum.js +1 -1
- package/lodash/sumBy.js +1 -1
- package/lodash/tail.js +1 -1
- package/lodash/take.js +1 -1
- package/lodash/takeRight.js +1 -1
- package/lodash/takeRightWhile.js +1 -1
- package/lodash/takeWhile.js +1 -1
- package/lodash/tap.js +1 -1
- package/lodash/template.js +1 -1
- package/lodash/templateSettings.js +1 -1
- package/lodash/throttle.js +1 -1
- package/lodash/thru.js +1 -1
- package/lodash/times.js +1 -1
- package/lodash/toArray.js +1 -1
- package/lodash/toFinite.js +1 -1
- package/lodash/toInteger.js +1 -1
- package/lodash/toIterator.js +1 -1
- package/lodash/toJSON.js +1 -1
- package/lodash/toLength.js +1 -1
- package/lodash/toLower.js +1 -1
- package/lodash/toNumber.js +1 -1
- package/lodash/toPairs.js +1 -1
- package/lodash/toPairsIn.js +1 -1
- package/lodash/toPath.js +1 -1
- package/lodash/toPlainObject.js +1 -1
- package/lodash/toSafeInteger.js +1 -1
- package/lodash/toString.js +1 -1
- package/lodash/toUpper.js +1 -1
- package/lodash/transform.js +1 -1
- package/lodash/trim.js +1 -1
- package/lodash/trimEnd.js +1 -1
- package/lodash/trimStart.js +1 -1
- package/lodash/truncate.js +1 -1
- package/lodash/unary.js +1 -1
- package/lodash/unescape.js +1 -1
- package/lodash/union.js +1 -1
- package/lodash/unionBy.js +1 -1
- package/lodash/unionWith.js +1 -1
- package/lodash/uniq.js +1 -1
- package/lodash/uniqBy.js +1 -1
- package/lodash/uniqWith.js +1 -1
- package/lodash/uniqueId.js +1 -1
- package/lodash/unset.js +1 -1
- package/lodash/unzip.js +1 -1
- package/lodash/unzipWith.js +1 -1
- package/lodash/update.js +1 -1
- package/lodash/updateWith.js +1 -1
- package/lodash/upperCase.js +1 -1
- package/lodash/upperFirst.js +1 -1
- package/lodash/util.default.js +1 -1
- package/lodash/util.js +1 -1
- package/lodash/value.js +1 -1
- package/lodash/valueOf.js +1 -1
- package/lodash/values.js +1 -1
- package/lodash/valuesIn.js +1 -1
- package/lodash/without.js +1 -1
- package/lodash/words.js +1 -1
- package/lodash/wrap.js +1 -1
- package/lodash/wrapperAt.js +1 -1
- package/lodash/wrapperChain.js +1 -1
- package/lodash/wrapperLodash.js +1 -1
- package/lodash/wrapperReverse.js +1 -1
- package/lodash/wrapperValue.js +1 -1
- package/lodash/xor.js +1 -1
- package/lodash/xorBy.js +1 -1
- package/lodash/xorWith.js +1 -1
- package/lodash/zip.js +1 -1
- package/lodash/zipObject.js +1 -1
- package/lodash/zipObjectDeep.js +1 -1
- package/lodash/zipWith.js +1 -1
- package/math/index.js +1 -1
- package/md5/index.js +1 -1
- package/mock/MockWebSocket.js +1 -1
- package/mock/MockXMLHttpRequest.js +1 -1
- package/mock/index.js +1 -1
- package/mousetrap/LICENSE +178 -0
- package/mousetrap/Mousetrap.d.ts +115 -0
- package/mousetrap/Mousetrap.js +261 -0
- package/mousetrap/index.d.ts +3 -0
- package/mousetrap/index.js +8 -0
- package/mousetrap/plugins/bind-dictionary/index.d.ts +1 -0
- package/mousetrap/plugins/bind-dictionary/index.js +10 -0
- package/mousetrap/plugins/global-bind/index.d.ts +1 -0
- package/mousetrap/plugins/global-bind/index.js +15 -0
- package/mousetrap/plugins/index.d.ts +1 -0
- package/mousetrap/plugins/index.js +6 -0
- package/mousetrap/plugins/pause/index.d.ts +1 -0
- package/mousetrap/plugins/pause/index.js +13 -0
- package/mousetrap/plugins/record/index.d.ts +1 -0
- package/mousetrap/plugins/record/index.js +46 -0
- package/normalize-wheel/ExecutionEnvironment.js +1 -1
- package/normalize-wheel/UserAgent_DEPRECATED.js +1 -1
- package/normalize-wheel/index.js +1 -1
- package/normalize-wheel/isEventSupported.js +1 -1
- package/number-to-chinese/index.js +1 -1
- package/nzh/cn.js +1 -1
- package/nzh/hk.js +1 -1
- package/nzh/index.js +1 -1
- package/nzh/nzh.js +1 -1
- package/nzh/src/autoGet.js +1 -1
- package/nzh/src/index.js +1 -1
- package/nzh/src/langs/cn_b.js +1 -1
- package/nzh/src/langs/cn_s.js +1 -1
- package/nzh/src/langs/hk_b.js +1 -1
- package/nzh/src/langs/hk_s.js +1 -1
- package/nzh/src/utils.js +1 -1
- package/object/index.js +1 -1
- package/package.json +1 -1
- package/pinyin/index.js +1 -1
- package/pinyin/lib/common/constant.js +1 -1
- package/pinyin/lib/common/segmentit/AC.js +1 -1
- package/pinyin/lib/common/segmentit/TrieNode.js +1 -1
- package/pinyin/lib/common/segmentit/index.js +1 -1
- package/pinyin/lib/common/segmentit/max-probability.js +1 -1
- package/pinyin/lib/common/segmentit/min-tokenization.js +1 -1
- package/pinyin/lib/common/segmentit/reverse-max-match.js +1 -1
- package/pinyin/lib/common/utils.js +1 -1
- package/pinyin/lib/core/convert/index.js +1 -1
- package/pinyin/lib/core/custom/index.js +1 -1
- package/pinyin/lib/core/dict/index.js +1 -1
- package/pinyin/lib/core/html/index.js +1 -1
- package/pinyin/lib/core/match/index.js +1 -1
- package/pinyin/lib/core/pinyin/handle.js +1 -1
- package/pinyin/lib/core/pinyin/index.js +1 -1
- package/pinyin/lib/core/pinyin/middlewares.js +1 -1
- package/pinyin/lib/core/polyphonic/index.js +1 -1
- package/pinyin/lib/core/segment/index.js +1 -1
- package/pinyin/lib/core/segment/middlewares.js +1 -1
- package/pinyin/lib/core/traditional/index.js +1 -1
- package/pinyin/lib/data/dict1.js +1 -1
- package/pinyin/lib/data/dict2.js +1 -1
- package/pinyin/lib/data/dict3.js +1 -1
- package/pinyin/lib/data/dict4.js +1 -1
- package/pinyin/lib/data/dict5.js +1 -1
- package/pinyin/lib/data/special.js +1 -1
- package/pinyin/lib/data/surname.js +1 -1
- package/pinyin/lib/index.js +1 -1
- package/query-string/index.d.ts +55 -2
- package/query-string/index.js +264 -4
- package/random/address.js +1 -1
- package/random/constellation.js +1 -1
- package/random/image.js +1 -1
- package/random/index.js +1 -1
- package/random/licensePlate.js +1 -1
- package/random/name.js +1 -1
- package/random/number.js +1 -1
- package/random/text.js +1 -1
- package/random/time.js +1 -1
- package/random/web.js +1 -1
- package/sanitize-url/index.js +1 -1
- package/screenfull/index.js +1 -1
- package/sleep/index.js +1 -1
- package/snapdom/index.browser.js +1 -1
- package/snapdom/index.js +1 -1
- package/snapdom/src/api/preCache.d.ts +1 -1
- package/snapdom/src/api/preCache.js +1 -1
- package/snapdom/src/api/snapdom.js +6 -2
- package/snapdom/src/core/cache.js +2 -2
- package/snapdom/src/core/capture.js +1 -1
- package/snapdom/src/core/clone.js +119 -116
- package/snapdom/src/core/context.js +1 -1
- package/snapdom/src/core/plugins.d.ts +0 -5
- package/snapdom/src/core/plugins.js +2 -2
- package/snapdom/src/core/prepare.js +7 -7
- package/snapdom/src/exporters/download.js +1 -1
- package/snapdom/src/exporters/toBlob.js +1 -1
- package/snapdom/src/exporters/toCanvas.js +1 -1
- package/snapdom/src/exporters/toImg.js +1 -1
- package/snapdom/src/index.browser.js +1 -1
- package/snapdom/src/index.js +1 -1
- package/snapdom/src/modules/CSSVar.js +1 -1
- package/snapdom/src/modules/background.js +5 -5
- package/snapdom/src/modules/changeCSS.js +1 -1
- package/snapdom/src/modules/counter.d.ts +2 -34
- package/snapdom/src/modules/counter.js +1 -1
- package/snapdom/src/modules/fonts.js +34 -29
- package/snapdom/src/modules/iconFonts.js +49 -48
- package/snapdom/src/modules/images.js +1 -1
- package/snapdom/src/modules/lineClamp.js +1 -1
- package/snapdom/src/modules/pictureResolver.js +1 -1
- package/snapdom/src/modules/pseudo.d.ts +1 -1
- package/snapdom/src/modules/pseudo.js +59 -41
- package/snapdom/src/modules/rasterize.js +1 -1
- package/snapdom/src/modules/snapFetch.js +1 -1
- package/snapdom/src/modules/styles.js +75 -73
- package/snapdom/src/modules/svgDefs.js +1 -1
- package/snapdom/src/utils/browser.js +1 -1
- package/snapdom/src/utils/capture.helpers.js +1 -1
- package/snapdom/src/utils/clone.helpers.js +1 -1
- package/snapdom/src/utils/css.js +1 -1
- package/snapdom/src/utils/debug.js +1 -1
- package/snapdom/src/utils/helpers.js +1 -1
- package/snapdom/src/utils/image.js +6 -6
- package/snapdom/src/utils/index.js +1 -1
- package/snapdom/src/utils/prepare.helpers.js +1 -1
- package/snapdom/src/utils/transforms.helpers.js +68 -45
- package/string/chars.js +1 -1
- package/string/index.js +1 -1
- package/tinycolor/conversion.js +1 -1
- package/tinycolor/css-color-names.js +4 -3
- package/tinycolor/format-input.js +1 -1
- package/tinycolor/from-ratio.js +1 -1
- package/tinycolor/index.js +1 -1
- package/tinycolor/interfaces.js +1 -1
- package/tinycolor/public_api.js +1 -1
- package/tinycolor/random.js +1 -1
- package/tinycolor/readability.js +1 -1
- package/tinycolor/to-ms-filter.js +1 -1
- package/tinycolor/umd_api.js +1 -1
- package/tinycolor/utils.js +1 -1
- package/tree/index.js +1 -1
- package/tree/searchTree.js +1 -1
- package/tween/easing.js +1 -1
- package/tween/index.js +1 -1
- package/tween/tween.js +1 -1
- package/ui-color/compareColorByRange.js +1 -1
- package/ui-color/index.js +1 -1
- package/url-toolkit/index.js +1 -1
- package/validate/index.js +1 -1
- package/validate/interface.js +1 -1
- package/validate/locale/en-US.js +1 -1
- package/validate/locale/index.js +1 -1
- package/validate/locale/zh-CN.js +1 -1
- package/validate/rules/array.js +1 -1
- package/validate/rules/base.js +1 -1
- package/validate/rules/boolean.js +1 -1
- package/validate/rules/custom.js +1 -1
- package/validate/rules/number.js +1 -1
- package/validate/rules/object.js +1 -1
- package/validate/rules/string.js +1 -1
- package/validate/rules/type.js +1 -1
- package/version/index.js +1 -1
- package/xlsx/crc32.js +1 -1
- package/xlsx/index.js +1 -1
- package/xlsx/xlsx.js +1 -1
- package/query-string/LICENSE +0 -20
- package/query-string/base.d.ts +0 -11
- package/query-string/base.js +0 -255
- package/query-string/splitOnFirst.d.ts +0 -1
- package/query-string/splitOnFirst.js +0 -12
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 潘启宝 2026-
|
|
1
|
+
/* 潘启宝 2026-06-02 17:39:50 星期二 山东省济南市 */
|
|
2
2
|
import { isFirefox as e } from "../utils/browser.js";
|
|
3
3
|
import { NO_CAPTURE_TAGS as t } from "../utils/css.js";
|
|
4
4
|
import { debugWarn as n } from "../utils/debug.js";
|
|
@@ -7,173 +7,176 @@ import { inlineAllStyles as r } from "../modules/styles.js";
|
|
|
7
7
|
import { buildSeedCustomPropsRule as i, collectCustomPropsFromCSS as a, createCheckboxRadioReplacement as o, extractShadowCSS as s, freezeImgSrcset as c, getUnscaledDimensions as l, idleCallback as u, injectScopedStyle as d, markSlottedSubtree as f, nextShadowScopeId as p, rasterizeIframe as m, rewriteShadowCSS as h } from "../utils/clone.helpers.js";
|
|
8
8
|
import { isInSvgTemplate as g, resolveCSSVars as _ } from "../modules/CSSVar.js";
|
|
9
9
|
//#region utils/snapdom/src/core/clone.js
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
if (y.id === "snapdom-sandbox" || y.hasAttribute("data-snapdom-sandbox") || t.has(e)) return null;
|
|
16
|
-
if (e === "foreignobject" && y.parentElement?.closest?.("foreignObject")) return n(b, "Nested <foreignObject> skipped (SVG spec limitation — not rendered by browsers)"), null;
|
|
10
|
+
function v(e) {
|
|
11
|
+
let { width: t, height: n } = l(e), r = t, i = n;
|
|
12
|
+
if (!r || !i) {
|
|
13
|
+
let t = e.getBoundingClientRect();
|
|
14
|
+
r = r || t.width || 0, i = i || t.height || 0;
|
|
17
15
|
}
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
16
|
+
let a = document.createElement("div");
|
|
17
|
+
return a.style.cssText = `display:inline-block;width:${r}px;height:${i}px;visibility:hidden;`, a;
|
|
18
|
+
}
|
|
19
|
+
async function y(b, x, S) {
|
|
20
|
+
if (!b) throw Error("Invalid node");
|
|
21
|
+
let C = /* @__PURE__ */ new Set(), w = null, T = null;
|
|
22
|
+
if (b.nodeType === Node.ELEMENT_NODE) {
|
|
23
|
+
let e = (b.localName || b.tagName || "").toLowerCase();
|
|
24
|
+
if (b.id === "snapdom-sandbox" || b.hasAttribute("data-snapdom-sandbox") || t.has(e)) return null;
|
|
25
|
+
if (e === "foreignobject" && b.parentElement?.closest?.("foreignObject")) return n(x, "Nested <foreignObject> skipped (SVG spec limitation — not rendered by browsers)"), null;
|
|
26
|
+
}
|
|
27
|
+
if (b.nodeType === Node.TEXT_NODE || b.nodeType !== Node.ELEMENT_NODE) return b.cloneNode(!0);
|
|
28
|
+
if (b.getAttribute("data-capture") === "exclude") {
|
|
29
|
+
if (S.excludeMode === "hide") return v(b);
|
|
30
|
+
if (S.excludeMode === "remove") return null;
|
|
24
31
|
}
|
|
25
|
-
if (
|
|
26
|
-
if (
|
|
27
|
-
if (
|
|
28
|
-
|
|
29
|
-
return e.style.cssText = `display:inline-block;width:${r}px;height:${i}px;visibility:hidden;`, e;
|
|
30
|
-
} else if (x.excludeMode === "remove") return null;
|
|
32
|
+
if (S.exclude && Array.isArray(S.exclude)) for (let e of S.exclude) try {
|
|
33
|
+
if (b.matches?.(e)) {
|
|
34
|
+
if (S.excludeMode === "hide") return v(b);
|
|
35
|
+
if (S.excludeMode === "remove") return null;
|
|
31
36
|
}
|
|
32
37
|
} catch (t) {
|
|
33
38
|
console.warn(`Invalid selector in exclude option: ${e}`, t);
|
|
34
39
|
}
|
|
35
|
-
if (typeof
|
|
36
|
-
if (!
|
|
37
|
-
if (
|
|
38
|
-
|
|
39
|
-
return e.style.cssText = `display:inline-block;width:${r}px;height:${i}px;visibility:hidden;`, e;
|
|
40
|
-
} else if (x.filterMode === "remove") return null;
|
|
40
|
+
if (typeof S.filter == "function") try {
|
|
41
|
+
if (!S.filter(b)) {
|
|
42
|
+
if (S.filterMode === "hide") return v(b);
|
|
43
|
+
if (S.filterMode === "remove") return null;
|
|
41
44
|
}
|
|
42
45
|
} catch (e) {
|
|
43
46
|
console.warn("Error in filter function:", e);
|
|
44
47
|
}
|
|
45
|
-
if (
|
|
48
|
+
if (b.tagName === "IFRAME") {
|
|
46
49
|
let e = !1;
|
|
47
50
|
try {
|
|
48
|
-
e = !!(
|
|
51
|
+
e = !!(b.contentDocument || b.contentWindow?.document);
|
|
49
52
|
} catch (e) {
|
|
50
|
-
n(
|
|
53
|
+
n(x, "iframe same-origin probe failed", e);
|
|
51
54
|
}
|
|
52
55
|
if (e) try {
|
|
53
|
-
return await m(
|
|
56
|
+
return await m(b, x, S);
|
|
54
57
|
} catch (e) {
|
|
55
58
|
console.warn("[SnapDOM] iframe rasterization failed, fallback:", e);
|
|
56
59
|
}
|
|
57
|
-
if (e || console.warn("[snapdom] cross-origin <iframe> skipped (cannot access content). Use options.placeholders to show a placeholder instead.",
|
|
58
|
-
let { width: e, height: t } = l(
|
|
59
|
-
return n.style.cssText = `width:${e}px;height:${t}px;background-image:repeating-linear-gradient(45deg,#ddd,#ddd 5px,#f9f9f9 5px,#f9f9f9 10px);display:flex;align-items:center;justify-content:center;font-size:12px;color:#555;border:1px solid #aaa;`, r(
|
|
60
|
+
if (e || console.warn("[snapdom] cross-origin <iframe> skipped (cannot access content). Use options.placeholders to show a placeholder instead.", b), S.placeholders) {
|
|
61
|
+
let { width: e, height: t } = l(b), n = document.createElement("div");
|
|
62
|
+
return n.style.cssText = `width:${e}px;height:${t}px;background-image:repeating-linear-gradient(45deg,#ddd,#ddd 5px,#f9f9f9 5px,#f9f9f9 10px);display:flex;align-items:center;justify-content:center;font-size:12px;color:#555;border:1px solid #aaa;`, r(b, n, x, S), n;
|
|
60
63
|
} else {
|
|
61
|
-
let { width: e, height: t } = l(
|
|
62
|
-
return n.style.cssText = `display:inline-block;width:${e}px;height:${t}px;visibility:hidden;`, r(
|
|
64
|
+
let { width: e, height: t } = l(b), n = document.createElement("div");
|
|
65
|
+
return n.style.cssText = `display:inline-block;width:${e}px;height:${t}px;visibility:hidden;`, r(b, n, x, S), n;
|
|
63
66
|
}
|
|
64
67
|
}
|
|
65
|
-
if (
|
|
66
|
-
let e =
|
|
67
|
-
|
|
68
|
+
if (b.getAttribute("data-capture") === "placeholder") {
|
|
69
|
+
let e = b.cloneNode(!1);
|
|
70
|
+
x.nodeMap.set(e, b), r(b, e, x, S);
|
|
68
71
|
let t = document.createElement("div");
|
|
69
|
-
return t.textContent =
|
|
72
|
+
return t.textContent = b.getAttribute("data-placeholder-text") || "", t.style.cssText = "color:#666;font-size:12px;text-align:center;line-height:1.4;padding:0.5em;box-sizing:border-box;", e.appendChild(t), e;
|
|
70
73
|
}
|
|
71
|
-
if (
|
|
74
|
+
if (b.tagName === "CANVAS") {
|
|
72
75
|
let e = "";
|
|
73
76
|
try {
|
|
74
|
-
let t =
|
|
77
|
+
let t = b.getContext("2d", { willReadFrequently: !0 });
|
|
75
78
|
try {
|
|
76
79
|
t && t.getImageData(0, 0, 1, 1);
|
|
77
80
|
} catch {}
|
|
78
|
-
if (await new Promise((e) => requestAnimationFrame(e)), e =
|
|
81
|
+
if (await new Promise((e) => requestAnimationFrame(e)), e = b.toDataURL("image/png"), !e || e === "data:,") {
|
|
79
82
|
try {
|
|
80
83
|
t && t.getImageData(0, 0, 1, 1);
|
|
81
84
|
} catch {}
|
|
82
|
-
if (await new Promise((e) => requestAnimationFrame(e)), e =
|
|
85
|
+
if (await new Promise((e) => requestAnimationFrame(e)), e = b.toDataURL("image/png"), !e || e === "data:,") {
|
|
83
86
|
let t = document.createElement("canvas");
|
|
84
|
-
t.width =
|
|
87
|
+
t.width = b.width, t.height = b.height;
|
|
85
88
|
let n = t.getContext("2d");
|
|
86
|
-
n && (n.drawImage(
|
|
89
|
+
n && (n.drawImage(b, 0, 0), e = t.toDataURL("image/png"));
|
|
87
90
|
}
|
|
88
91
|
}
|
|
89
92
|
} catch (e) {
|
|
90
|
-
n(
|
|
93
|
+
n(x, "Canvas toDataURL failed, using empty/fallback", e);
|
|
91
94
|
}
|
|
92
95
|
let t = document.createElement("img");
|
|
93
96
|
try {
|
|
94
97
|
t.decoding = "sync", t.loading = "eager";
|
|
95
98
|
} catch (e) {
|
|
96
|
-
n(
|
|
99
|
+
n(x, "img decoding/loading hints failed", e);
|
|
97
100
|
}
|
|
98
|
-
e && (t.src = e), t.width =
|
|
99
|
-
let { width: i, height: a } = l(
|
|
100
|
-
return i > 0 && (t.style.width = `${i}px`), a > 0 && (t.style.height = `${a}px`),
|
|
101
|
+
e && (t.src = e), t.width = b.width, t.height = b.height;
|
|
102
|
+
let { width: i, height: a } = l(b);
|
|
103
|
+
return i > 0 && (t.style.width = `${i}px`), a > 0 && (t.style.height = `${a}px`), x.nodeMap.set(t, b), r(b, t, x, S), t;
|
|
101
104
|
}
|
|
102
|
-
if (
|
|
105
|
+
if (b.tagName === "VIDEO") {
|
|
103
106
|
let e = "";
|
|
104
107
|
try {
|
|
105
108
|
let t = document.createElement("canvas");
|
|
106
|
-
t.width =
|
|
109
|
+
t.width = b.videoWidth || b.offsetWidth || 320, t.height = b.videoHeight || b.offsetHeight || 240;
|
|
107
110
|
let n = t.getContext("2d");
|
|
108
|
-
n && (n.drawImage(
|
|
111
|
+
n && (n.drawImage(b, 0, 0, t.width, t.height), e = t.toDataURL("image/png"), (!e || e === "data:,") && (e = ""));
|
|
109
112
|
} catch (e) {
|
|
110
|
-
n(
|
|
113
|
+
n(x, "Video frame capture failed, using poster fallback", e);
|
|
111
114
|
}
|
|
112
115
|
let t = document.createElement("img");
|
|
113
116
|
try {
|
|
114
117
|
t.decoding = "sync", t.loading = "eager";
|
|
115
118
|
} catch {}
|
|
116
|
-
e ? t.src = e :
|
|
117
|
-
let { width: i, height: a } = l(
|
|
118
|
-
return i > 0 && (t.style.width = `${i}px`), a > 0 && (t.style.height = `${a}px`), t.style.objectFit = "contain",
|
|
119
|
+
e ? t.src = e : b.poster && (t.src = b.poster), t.width = b.videoWidth || b.offsetWidth || 0, t.height = b.videoHeight || b.offsetHeight || 0;
|
|
120
|
+
let { width: i, height: a } = l(b);
|
|
121
|
+
return i > 0 && (t.style.width = `${i}px`), a > 0 && (t.style.height = `${a}px`), t.style.objectFit = "contain", x.nodeMap.set(t, b), r(b, t, x, S), t;
|
|
119
122
|
}
|
|
120
|
-
let
|
|
123
|
+
let E;
|
|
121
124
|
try {
|
|
122
|
-
if (
|
|
123
|
-
for (let e of
|
|
125
|
+
if (E = b.cloneNode(!1), E.attributes?.length) try {
|
|
126
|
+
for (let e of E.attributes) /[\x00-\x08\x0B\x0C\x0E-\x1F\uFFFE\uFFFF]/.test(e.value) && E.setAttribute(e.name, e.value.replace(/[\x00-\x08\x0B\x0C\x0E-\x1F\uFFFE\uFFFF]/g, ""));
|
|
124
127
|
} catch {}
|
|
125
|
-
if (_(
|
|
126
|
-
c(
|
|
128
|
+
if (_(b, E), x.nodeMap.set(E, b), b.tagName === "IMG") {
|
|
129
|
+
c(b, E);
|
|
127
130
|
try {
|
|
128
|
-
let { width: e, height: t } = l(
|
|
129
|
-
n && (
|
|
131
|
+
let { width: e, height: t } = l(b), n = Math.round(e || 0), r = Math.round(t || 0);
|
|
132
|
+
n && (E.dataset.snapdomWidth = String(n)), r && (E.dataset.snapdomHeight = String(r));
|
|
130
133
|
} catch (e) {
|
|
131
|
-
n(
|
|
134
|
+
n(x, "getUnscaledDimensions for IMG failed", e);
|
|
132
135
|
}
|
|
133
136
|
try {
|
|
134
|
-
let e =
|
|
137
|
+
let e = b.getAttribute("style") || "", t = window.getComputedStyle(b), n = (n) => {
|
|
135
138
|
let r = e.match(RegExp(`${n}\\s*:\\s*([^;]+)`, "i")), i = r ? r[1].trim() : t.getPropertyValue(n);
|
|
136
139
|
return /%|auto/i.test(String(i || ""));
|
|
137
|
-
}, r = parseInt(
|
|
138
|
-
a && r && (
|
|
140
|
+
}, r = parseInt(E.dataset.snapdomWidth || "0", 10), i = parseInt(E.dataset.snapdomHeight || "0", 10), a = n("width") || !r, o = n("height") || !i;
|
|
141
|
+
a && r && (E.style.width = `${r}px`), o && i && (E.style.height = `${i}px`);
|
|
139
142
|
let s = t.getPropertyValue("object-fit"), c = t.getPropertyValue("object-position");
|
|
140
|
-
s && s !== "fill" ? (
|
|
143
|
+
s && s !== "fill" ? (E.style.objectFit = s, c && (E.style.objectPosition = c)) : (r && (E.style.minWidth = `${r}px`), i && (E.style.minHeight = `${i}px`));
|
|
141
144
|
} catch (e) {
|
|
142
|
-
n(
|
|
145
|
+
n(x, "IMG dimension freeze failed", e);
|
|
143
146
|
}
|
|
144
147
|
}
|
|
145
148
|
} catch (e) {
|
|
146
|
-
throw console.error("[Snapdom] Failed to clone node:",
|
|
149
|
+
throw console.error("[Snapdom] Failed to clone node:", b, e), e;
|
|
147
150
|
}
|
|
148
|
-
let
|
|
149
|
-
if (
|
|
150
|
-
let { width: e, height: t } = l(
|
|
151
|
-
n && (
|
|
151
|
+
let D = null;
|
|
152
|
+
if (b instanceof HTMLTextAreaElement) {
|
|
153
|
+
let { width: e, height: t } = l(b), n = e || b.getBoundingClientRect().width || 0, r = t || b.getBoundingClientRect().height || 0;
|
|
154
|
+
n && (E.style.width = `${n}px`), r && (E.style.height = `${r}px`);
|
|
152
155
|
}
|
|
153
|
-
if (
|
|
154
|
-
let t = (
|
|
156
|
+
if (b instanceof HTMLInputElement) {
|
|
157
|
+
let t = (b.type || "text").toLowerCase();
|
|
155
158
|
if ((t === "checkbox" || t === "radio") && e()) {
|
|
156
|
-
let { el: e, applyVisual: t } = o(
|
|
157
|
-
|
|
158
|
-
} else
|
|
159
|
+
let { el: e, applyVisual: t } = o(b);
|
|
160
|
+
x.nodeMap.set(e, b), D = t, E = e;
|
|
161
|
+
} else E.value = b.value, E.setAttribute("value", b.value), b.checked !== void 0 && (E.checked = b.checked, b.checked && E.setAttribute("checked", ""), b.indeterminate && (E.indeterminate = b.indeterminate));
|
|
159
162
|
}
|
|
160
|
-
if ((
|
|
161
|
-
let e = window.getComputedStyle(
|
|
163
|
+
if ((b instanceof HTMLInputElement || b instanceof HTMLTextAreaElement) && !b.value && b.placeholder) try {
|
|
164
|
+
let e = window.getComputedStyle(b, "::placeholder"), t = e && e.color;
|
|
162
165
|
if (t && t !== "rgba(0, 0, 0, 0)") {
|
|
163
166
|
let n = "snapdom-ph-" + (Math.random() * 1e6 | 0);
|
|
164
|
-
|
|
167
|
+
E.classList.add(n);
|
|
165
168
|
let r = document.createElement("style");
|
|
166
|
-
r.textContent = `.${n}::placeholder{color:${t}!important;opacity:${e.opacity || "1"}!important;}`,
|
|
169
|
+
r.textContent = `.${n}::placeholder{color:${t}!important;opacity:${e.opacity || "1"}!important;-webkit-text-fill-color:${t}!important;}`, E.prepend(r);
|
|
167
170
|
}
|
|
168
171
|
} catch {}
|
|
169
|
-
if (
|
|
170
|
-
|
|
171
|
-
let e =
|
|
172
|
-
e.min !== void 0 && e.min !== "" &&
|
|
173
|
-
let t =
|
|
174
|
-
t !== null &&
|
|
172
|
+
if (b instanceof HTMLSelectElement && (w = b.value), b instanceof HTMLTextAreaElement && (T = b.value), b instanceof HTMLInputElement || b instanceof HTMLTextAreaElement || b instanceof HTMLSelectElement) {
|
|
173
|
+
b.disabled && E.setAttribute("disabled", ""), b.required && E.setAttribute("required", ""), b.readOnly && E.setAttribute("readonly", "");
|
|
174
|
+
let e = b;
|
|
175
|
+
e.min !== void 0 && e.min !== "" && E.setAttribute("min", e.min), e.max !== void 0 && e.max !== "" && E.setAttribute("max", e.max), e.pattern !== void 0 && e.pattern !== "" && E.setAttribute("pattern", e.pattern);
|
|
176
|
+
let t = b.getAttribute("aria-invalid");
|
|
177
|
+
t !== null && E.setAttribute("aria-invalid", t);
|
|
175
178
|
}
|
|
176
|
-
if (g(
|
|
179
|
+
if (g(b) || r(b, E, x, S), D && D(), b instanceof SVGElement && !g(b)) {
|
|
177
180
|
let e = [
|
|
178
181
|
"fill",
|
|
179
182
|
"stroke",
|
|
@@ -196,16 +199,16 @@ async function v(y, b, x) {
|
|
|
196
199
|
"display"
|
|
197
200
|
];
|
|
198
201
|
try {
|
|
199
|
-
let t = window.getComputedStyle(
|
|
202
|
+
let t = window.getComputedStyle(b);
|
|
200
203
|
for (let n of e) {
|
|
201
204
|
let e = t.getPropertyValue(n);
|
|
202
|
-
e &&
|
|
205
|
+
e && E.style.setProperty(n, e);
|
|
203
206
|
}
|
|
204
207
|
} catch {}
|
|
205
208
|
}
|
|
206
|
-
if (
|
|
209
|
+
if (b.shadowRoot) {
|
|
207
210
|
try {
|
|
208
|
-
let e =
|
|
211
|
+
let e = b.shadowRoot.querySelectorAll("slot");
|
|
209
212
|
for (let t of e) {
|
|
210
213
|
let e = [];
|
|
211
214
|
try {
|
|
@@ -213,54 +216,54 @@ async function v(y, b, x) {
|
|
|
213
216
|
} catch {
|
|
214
217
|
e = t.assignedNodes?.() || [];
|
|
215
218
|
}
|
|
216
|
-
for (let t of e)
|
|
219
|
+
for (let t of e) C.add(t);
|
|
217
220
|
}
|
|
218
221
|
} catch {}
|
|
219
|
-
let e = p(
|
|
222
|
+
let e = p(x), t = `[data-sd="${e}"]`;
|
|
220
223
|
try {
|
|
221
|
-
|
|
224
|
+
E.setAttribute("data-sd", e);
|
|
222
225
|
} catch {}
|
|
223
|
-
let n = s(
|
|
224
|
-
d(
|
|
226
|
+
let n = s(b.shadowRoot), r = h(n, t), o = i(b, a(n), t);
|
|
227
|
+
d(E, o + r, e);
|
|
225
228
|
let c = document.createDocumentFragment();
|
|
226
229
|
function l(e, t) {
|
|
227
230
|
if (e.nodeType === Node.ELEMENT_NODE && e.tagName === "STYLE") return t(null);
|
|
228
|
-
|
|
231
|
+
y(e, x, S).then((e) => {
|
|
229
232
|
t(e || null);
|
|
230
233
|
}).catch(() => {
|
|
231
234
|
t(null);
|
|
232
235
|
});
|
|
233
236
|
}
|
|
234
|
-
let f = await u(Array.from(
|
|
235
|
-
c.append(...f.filter((e) => !!e)),
|
|
237
|
+
let f = await u(Array.from(b.shadowRoot.childNodes), l, S.fast);
|
|
238
|
+
c.append(...f.filter((e) => !!e)), E.appendChild(c);
|
|
236
239
|
}
|
|
237
|
-
if (
|
|
238
|
-
let e =
|
|
240
|
+
if (b.tagName === "SLOT") {
|
|
241
|
+
let e = b.assignedNodes?.({ flatten: !0 }) || [], t = e.length > 0 ? e : Array.from(b.childNodes), n = document.createDocumentFragment();
|
|
239
242
|
function r(e, t) {
|
|
240
|
-
|
|
243
|
+
y(e, x, S).then((e) => {
|
|
241
244
|
e && f(e), t(e || null);
|
|
242
245
|
}).catch(() => {
|
|
243
246
|
t(null);
|
|
244
247
|
});
|
|
245
248
|
}
|
|
246
|
-
let i = await u(Array.from(t), r,
|
|
249
|
+
let i = await u(Array.from(t), r, S.fast);
|
|
247
250
|
return n.append(...i.filter((e) => !!e)), n;
|
|
248
251
|
}
|
|
249
|
-
function
|
|
250
|
-
if (
|
|
251
|
-
|
|
252
|
+
function O(e, t) {
|
|
253
|
+
if (C.has(e)) return t(null);
|
|
254
|
+
y(e, x, S).then((e) => {
|
|
252
255
|
t(e || null);
|
|
253
256
|
}).catch(() => {
|
|
254
257
|
t(null);
|
|
255
258
|
});
|
|
256
259
|
}
|
|
257
|
-
let
|
|
258
|
-
if (
|
|
259
|
-
|
|
260
|
-
for (let e of
|
|
260
|
+
let k = await u(Array.from(b.childNodes), O, S.fast);
|
|
261
|
+
if (E.append(...k.filter((e) => !!e)), w !== null && E instanceof HTMLSelectElement) {
|
|
262
|
+
E.value = w;
|
|
263
|
+
for (let e of E.options) e.value === w ? e.setAttribute("selected", "") : e.removeAttribute("selected");
|
|
261
264
|
}
|
|
262
|
-
return
|
|
265
|
+
return T !== null && E instanceof HTMLTextAreaElement && (E.textContent = T), E;
|
|
263
266
|
}
|
|
264
267
|
//#endregion
|
|
265
|
-
export {
|
|
268
|
+
export { y as deepClone };
|
|
266
269
|
/* 独立思考,明辨是非 */
|
|
@@ -27,11 +27,6 @@ export function runHook(name: string, context: any, payload: any): Promise<any>;
|
|
|
27
27
|
* @param {any} payload
|
|
28
28
|
*/
|
|
29
29
|
export function runAll(name: string, context: any, payload: any): Promise<any[]>;
|
|
30
|
-
/**
|
|
31
|
-
* Return a shallow copy of currently registered global plugins.
|
|
32
|
-
* @returns {any[]}
|
|
33
|
-
*/
|
|
34
|
-
export function pluginsList(): any[];
|
|
35
30
|
/** Clear all globally registered plugins (mostly for tests). */
|
|
36
31
|
export function clearPlugins(): void;
|
|
37
32
|
/**
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 潘启宝 2026-
|
|
1
|
+
/* 潘启宝 2026-06-02 17:39:50 星期二 山东省济南市 */
|
|
2
2
|
//#region utils/snapdom/src/core/plugins.js
|
|
3
3
|
var e = [];
|
|
4
4
|
function t(e) {
|
|
@@ -21,7 +21,7 @@ function n(...n) {
|
|
|
21
21
|
}
|
|
22
22
|
}
|
|
23
23
|
function r(t) {
|
|
24
|
-
return
|
|
24
|
+
return t && Array.isArray(t.plugins) ? t.plugins : e;
|
|
25
25
|
}
|
|
26
26
|
async function i(e, t, n) {
|
|
27
27
|
let i = n, a = r(t);
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 潘启宝 2026-
|
|
1
|
+
/* 潘启宝 2026-06-02 17:39:50 星期二 山东省济南市 */
|
|
2
2
|
import { cache as e } from "./cache.js";
|
|
3
3
|
import { generateCSSClasses as t, getStyle as n } from "../utils/css.js";
|
|
4
4
|
import { debugWarn as r } from "../utils/debug.js";
|
|
@@ -20,11 +20,6 @@ async function f(f, p = {}) {
|
|
|
20
20
|
}, h, g = "", _ = "";
|
|
21
21
|
u(f);
|
|
22
22
|
let v = l(f);
|
|
23
|
-
try {
|
|
24
|
-
s(f);
|
|
25
|
-
} catch (e) {
|
|
26
|
-
console.warn("inlineExternal defs or symbol failed:", e);
|
|
27
|
-
}
|
|
28
23
|
try {
|
|
29
24
|
h = await d(f, m, p);
|
|
30
25
|
} catch (e) {
|
|
@@ -32,6 +27,11 @@ async function f(f, p = {}) {
|
|
|
32
27
|
} finally {
|
|
33
28
|
v();
|
|
34
29
|
}
|
|
30
|
+
try {
|
|
31
|
+
s(h);
|
|
32
|
+
} catch (e) {
|
|
33
|
+
console.warn("inlineExternal defs or symbol failed:", e);
|
|
34
|
+
}
|
|
35
35
|
try {
|
|
36
36
|
await o(f, h, m, p);
|
|
37
37
|
} catch (e) {
|
|
@@ -75,7 +75,7 @@ async function f(f, p = {}) {
|
|
|
75
75
|
}
|
|
76
76
|
} catch {}
|
|
77
77
|
let t = document.createElement("div");
|
|
78
|
-
for (t.style.transform = `translate(${-n}px, ${-r}px)`, t.style.willChange = "transform", t.style.display = "inline-block", t.style.width = "100%"; e.firstChild;) t.appendChild(e.firstChild);
|
|
78
|
+
for (t.style.all = "unset", t.style.transform = `translate(${-n}px, ${-r}px)`, t.style.willChange = "transform", t.style.display = "inline-block", t.style.width = "100%"; e.firstChild;) t.appendChild(e.firstChild);
|
|
79
79
|
e.appendChild(t);
|
|
80
80
|
}
|
|
81
81
|
}
|
package/snapdom/src/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* 潘启宝 2026-
|
|
1
|
+
/* 潘启宝 2026-06-02 17:39:50 星期二 山东省济南市 */
|
|
2
2
|
import { getStyle as e, splitBackgroundImage as t } from "../utils/css.js";
|
|
3
3
|
import { inlineSingleBackgroundEntry as n } from "../utils/image.js";
|
|
4
4
|
import "../utils/index.js";
|
|
@@ -56,8 +56,8 @@ async function r(r, i, a, o = {}) {
|
|
|
56
56
|
let p = (() => {
|
|
57
57
|
let e = f.getPropertyValue("border-image"), t = f.getPropertyValue("border-image-source");
|
|
58
58
|
return e && e !== "none" || t && t !== "none";
|
|
59
|
-
})();
|
|
60
|
-
for (let e of u) {
|
|
59
|
+
})(), m = f.getPropertyValue("background-image"), h = f.getPropertyValue("background-color");
|
|
60
|
+
if (m && m !== "none" || h && h !== "rgba(0, 0, 0, 0)" && h !== "transparent" || /url\s*\(|gradient\s*\(/i.test(f.getPropertyValue("background") || "")) for (let e of u) {
|
|
61
61
|
let t = f.getPropertyValue(e);
|
|
62
62
|
t && i.style.setProperty(e, t);
|
|
63
63
|
}
|
|
@@ -79,8 +79,8 @@ async function r(r, i, a, o = {}) {
|
|
|
79
79
|
let t = f.getPropertyValue(e);
|
|
80
80
|
!t || t === "initial" || i.style.setProperty(e, t);
|
|
81
81
|
}
|
|
82
|
-
let
|
|
83
|
-
for (let e = 0; e < Math.min(
|
|
82
|
+
let g = r.shadowRoot ? Array.from(r.shadowRoot.children).filter((e) => e.tagName !== "STYLE") : Array.from(r.children), _ = Array.from(i.children).filter((e) => !(e.dataset?.snapdomPseudo || e.tagName === "STYLE" && e.dataset?.sd));
|
|
83
|
+
for (let e = 0; e < Math.min(g.length, _.length); e++) s.push([g[e], _[e]]);
|
|
84
84
|
}
|
|
85
85
|
}
|
|
86
86
|
//#endregion
|
|
@@ -9,8 +9,6 @@
|
|
|
9
9
|
*/
|
|
10
10
|
/** Detects if a content string uses counter()/counters(). */
|
|
11
11
|
export function hasCounters(input: any): boolean;
|
|
12
|
-
/** Replace every CSS string token "..." with its raw content (keeps single quotes). */
|
|
13
|
-
export function unquoteDoubleStrings(s: any): any;
|
|
14
12
|
/**
|
|
15
13
|
* Build a counter context by walking the DOM once.
|
|
16
14
|
* It stores, for each Element, a Map<counterName, number[]> (stack).
|
|
@@ -32,9 +30,8 @@ export function buildCounterContext(root: Document | Element): {
|
|
|
32
30
|
/**
|
|
33
31
|
* Resolves counter()/counters() calls inside a content string for a specific node,
|
|
34
32
|
* returning the content with counter() expanded but quoted-string tokens preserved.
|
|
35
|
-
* The caller is responsible for joining tokens
|
|
36
|
-
*
|
|
37
|
-
* collapseCssContent tokenize properly so source whitespace between adjacent
|
|
33
|
+
* The caller (pseudo.js) is responsible for joining tokens and stripping quotes —
|
|
34
|
+
* keeping quotes here lets its tokenizer work so source whitespace between adjacent
|
|
38
35
|
* tokens (e.g. `counter(x) ")"`) doesn't leak into the rendered text.
|
|
39
36
|
*
|
|
40
37
|
* @param {string} raw
|
|
@@ -45,32 +42,3 @@ export function resolveCountersInContent(raw: string, node: Element, ctx: {
|
|
|
45
42
|
get(node: Element, name: string): number;
|
|
46
43
|
getStack(node: Element, name: string): number[];
|
|
47
44
|
}): string;
|
|
48
|
-
/**
|
|
49
|
-
* Create a derived counter context that applies a pseudo's counter-reset /
|
|
50
|
-
* counter-increment *for this node only*, before resolving content.
|
|
51
|
-
* Works with ::before / ::after (and any pseudo with content).
|
|
52
|
-
*
|
|
53
|
-
* @param {Element} node
|
|
54
|
-
* @param {CSSStyleDeclaration|null} pseudoStyle getComputedStyle(node, '::before' | '::after')
|
|
55
|
-
* @param {{get(node: Element, name: string): number, getStack(node: Element, name: string): number[]}} baseCtx
|
|
56
|
-
*/
|
|
57
|
-
export function deriveCounterCtxForPseudo(node: Element, pseudoStyle: CSSStyleDeclaration | null, baseCtx: {
|
|
58
|
-
get(node: Element, name: string): number;
|
|
59
|
-
getStack(node: Element, name: string): number[];
|
|
60
|
-
}): {
|
|
61
|
-
get(_node: any, name: any): any;
|
|
62
|
-
getStack(_node: any, name: any): any;
|
|
63
|
-
};
|
|
64
|
-
/**
|
|
65
|
-
* Convenience helper: resolve the final text to render for a pseudo's `content`,
|
|
66
|
-
* correctly applying the pseudo's own counter-reset/increment before evaluation.
|
|
67
|
-
*
|
|
68
|
-
* @param {Element} node
|
|
69
|
-
* @param {'::before'|'::after'} pseudo
|
|
70
|
-
* @param {{get(node: Element, name: string): number, getStack(node: Element, name: string): number[]}} baseCtx
|
|
71
|
-
* @returns {string} resolved content (without surrounding double quotes)
|
|
72
|
-
*/
|
|
73
|
-
export function resolvePseudoContent(node: Element, pseudo: "::before" | "::after", baseCtx: {
|
|
74
|
-
get(node: Element, name: string): number;
|
|
75
|
-
getStack(node: Element, name: string): number[];
|
|
76
|
-
}): string;
|