dozy 1.0.102 → 1.0.103
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/index.d.ts +8 -2
- package/dist/index.js +7 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -717,6 +717,12 @@ declare function $copy(content: string): Promise<boolean | undefined>;
|
|
|
717
717
|
* @returns 当 `document.execCommand('copy')` 返回成功时为 `true`,否则为 `false`。
|
|
718
718
|
*/
|
|
719
719
|
declare function $fallbackCopy(content: string): boolean;
|
|
720
|
+
/**
|
|
721
|
+
* 替换当前地址栏的 hash 部分,保留 pathname 和 search 不变。
|
|
722
|
+
*
|
|
723
|
+
* @param hash 目标 hash 值;传入时不需要带 `#` 前缀(会自动补上)。传空字符串则清除 hash。
|
|
724
|
+
*/
|
|
725
|
+
declare function web$replaceHash(hash: string): void;
|
|
720
726
|
/**
|
|
721
727
|
* 将当前页面的路径、查询参数和哈希编码成一个 URI 片段字符串。
|
|
722
728
|
*
|
|
@@ -1463,6 +1469,6 @@ declare function toRgbString(input: string | Color | any): string | undefined;
|
|
|
1463
1469
|
*/
|
|
1464
1470
|
declare function toHslString(input: string | Color | any): string | undefined;
|
|
1465
1471
|
|
|
1466
|
-
declare const DOZY = "1.0.
|
|
1472
|
+
declare const DOZY = "1.0.103";
|
|
1467
1473
|
|
|
1468
|
-
export { $Headers, $Request, $Response, $URL, $URLSearchParams, $arrayFrom, $arrayIsArray, $assign, $backgroundColor, $borderColor, $capitalize, $checkValidEmailWithUnicode, $clamp, $clearInterval, $clearTimeout, $clone, $compressImage, $compressImageBase64, $compressImageDefaultOptions, $copy, $crypto, $date, $decodeBase64ToBinary, $decodeBase64ToUnicode, $deepClone, $defineProperty, $document, $encodeUnicodeToBase64, $ensureUrl, $entries, $escapeHTML, $fallbackCopy, $fetch, $fileToBase64, $formatDate, $formatK, $formatPoints, $formatPointsWithChange, $formatWithCommas, $freeze, $genSSF, $getFileType, $getHue, $getTimeString, $hasKey, $humanizeBytes, $if, $inRange, $inRange2, $inferExtensionFormPureBase64, $inferMimeTypeFormPureBase64, $is, $isObject, $isPlainClass, $isValidEmailWithUnicode, $isValidOrBriefURL, $jsonParse, $jsonStringify, $keys, $lastIndex, $lindex, $loadOpt, $location, $log, $lplus, $magic, $math, $now, $numberIsFinite, $numberIsNaN, $oc, $open, $parseParams, $promise, $pureText, $purifyBase64, $randomByte, $replaceHolesWithUndefined, $rmvSlash, $rsValue, $rsetValue, $rvalue, $s, $sc, $setInterval, $setRange, $setTimeout, $stringFromCharCode, $stringFromCodePoint, $stringToRange, $strings, $toDataUrlFromBase64, $validName, $values, $window, type Any, type Atoa, type Coord, type Coord3, DEFAULT_XLS_MAX_ASPECT_RATIO, DOZY, type DozyConfig, type DozyConfigItem, type FileType, Gens, type Hel, type IOpt, type Items, type Null, type Nullable, RainbowGen, RepoStore, type ScaleComputer, type ScaleIniter, type ScaleResponsiveOptions, StringObfuscator, type UNumber, __GensDirectives, _res, boxShadow, dozy, enableScaler, err403, errArg, errCode, errContent, errMsg, errNotLoggedIn, errToString, getBrightness, getColorMap, isNowAroundUtcHour, isNull, isValidColor, maybeString, registerCustomColor, s, shanghaiDateFormatter, smallChance, smartParse, smartString, standardIniter, textShadow, toHexString, toHslString, toRgbString, toRgbaArray, web$enableHttpsRedirect, web$enableProdProtector, web$encodeURI, web$pathStartData, web$redirectToDomain, web$setPathTarget, xtrim };
|
|
1474
|
+
export { $Headers, $Request, $Response, $URL, $URLSearchParams, $arrayFrom, $arrayIsArray, $assign, $backgroundColor, $borderColor, $capitalize, $checkValidEmailWithUnicode, $clamp, $clearInterval, $clearTimeout, $clone, $compressImage, $compressImageBase64, $compressImageDefaultOptions, $copy, $crypto, $date, $decodeBase64ToBinary, $decodeBase64ToUnicode, $deepClone, $defineProperty, $document, $encodeUnicodeToBase64, $ensureUrl, $entries, $escapeHTML, $fallbackCopy, $fetch, $fileToBase64, $formatDate, $formatK, $formatPoints, $formatPointsWithChange, $formatWithCommas, $freeze, $genSSF, $getFileType, $getHue, $getTimeString, $hasKey, $humanizeBytes, $if, $inRange, $inRange2, $inferExtensionFormPureBase64, $inferMimeTypeFormPureBase64, $is, $isObject, $isPlainClass, $isValidEmailWithUnicode, $isValidOrBriefURL, $jsonParse, $jsonStringify, $keys, $lastIndex, $lindex, $loadOpt, $location, $log, $lplus, $magic, $math, $now, $numberIsFinite, $numberIsNaN, $oc, $open, $parseParams, $promise, $pureText, $purifyBase64, $randomByte, $replaceHolesWithUndefined, $rmvSlash, $rsValue, $rsetValue, $rvalue, $s, $sc, $setInterval, $setRange, $setTimeout, $stringFromCharCode, $stringFromCodePoint, $stringToRange, $strings, $toDataUrlFromBase64, $validName, $values, $window, type Any, type Atoa, type Coord, type Coord3, DEFAULT_XLS_MAX_ASPECT_RATIO, DOZY, type DozyConfig, type DozyConfigItem, type FileType, Gens, type Hel, type IOpt, type Items, type Null, type Nullable, RainbowGen, RepoStore, type ScaleComputer, type ScaleIniter, type ScaleResponsiveOptions, StringObfuscator, type UNumber, __GensDirectives, _res, boxShadow, dozy, enableScaler, err403, errArg, errCode, errContent, errMsg, errNotLoggedIn, errToString, getBrightness, getColorMap, isNowAroundUtcHour, isNull, isValidColor, maybeString, registerCustomColor, s, shanghaiDateFormatter, smallChance, smartParse, smartString, standardIniter, textShadow, toHexString, toHslString, toRgbString, toRgbaArray, web$enableHttpsRedirect, web$enableProdProtector, web$encodeURI, web$pathStartData, web$redirectToDomain, web$replaceHash, web$setPathTarget, xtrim };
|
package/dist/index.js
CHANGED
|
@@ -11955,6 +11955,11 @@ function $fallbackCopy(content) {
|
|
|
11955
11955
|
document.body.removeChild(textArea);
|
|
11956
11956
|
}
|
|
11957
11957
|
}
|
|
11958
|
+
function web$replaceHash(hash) {
|
|
11959
|
+
if (typeof window === "undefined") return;
|
|
11960
|
+
const h = hash ? hash.startsWith("#") ? hash : "#" + hash : "";
|
|
11961
|
+
window.history.replaceState(null, "", window.location.pathname + window.location.search + h);
|
|
11962
|
+
}
|
|
11958
11963
|
function web$encodeURI(hash) {
|
|
11959
11964
|
if (typeof window === "undefined") throw "";
|
|
11960
11965
|
let h = location.hash;
|
|
@@ -27586,7 +27591,7 @@ var lodash_default_default = wrapperLodash_default;
|
|
|
27586
27591
|
|
|
27587
27592
|
// src/index.ts
|
|
27588
27593
|
var import_crypto_js = __toESM(require_crypto_js(), 1);
|
|
27589
|
-
var DOZY = "1.0.
|
|
27594
|
+
var DOZY = "1.0.103";
|
|
27590
27595
|
var export_Cryptojs = import_crypto_js.default;
|
|
27591
27596
|
export {
|
|
27592
27597
|
$Headers,
|
|
@@ -27749,6 +27754,7 @@ export {
|
|
|
27749
27754
|
web$encodeURI,
|
|
27750
27755
|
web$pathStartData,
|
|
27751
27756
|
web$redirectToDomain,
|
|
27757
|
+
web$replaceHash,
|
|
27752
27758
|
web$setPathTarget,
|
|
27753
27759
|
xtrim
|
|
27754
27760
|
};
|